mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Implement translation with Symfony translator within vue component
This commit is contained in:
parent
c602c27b39
commit
9732b80298
@ -17,7 +17,7 @@
|
|||||||
<slot name="body"></slot>
|
<slot name="body"></slot>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer" v-if="!hideFooter">
|
<div class="modal-footer" v-if="!hideFooter">
|
||||||
<button class="btn btn-cancel" @click="$emit('close')">{{ closeKey }}</button>
|
<button class="btn btn-cancel" @click="$emit('close')">{{ trans(modalActionClose) }}</button>
|
||||||
<slot name="footer"></slot>
|
<slot name="footer"></slot>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -55,12 +55,14 @@ export default defineComponent({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
emits: ['close'],
|
emits: ['close'],
|
||||||
computed: {
|
setup() {
|
||||||
closeKey() {
|
const modalActionClose = MODAL_ACTION_CLOSE;
|
||||||
console.log('close key', trans(MODAL_ACTION_CLOSE))
|
|
||||||
return trans(MODAL_ACTION_CLOSE)
|
return {
|
||||||
}
|
modalActionClose,
|
||||||
}
|
trans
|
||||||
|
};
|
||||||
|
},
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user