Refactor use of translation key in vue template slightly

This commit is contained in:
Julie Lenaerts 2024-09-20 14:02:36 +02:00
parent 9732b80298
commit c1c632dcb0

View File

@ -17,7 +17,7 @@
<slot name="body"></slot>
</div>
<div class="modal-footer" v-if="!hideFooter">
<button class="btn btn-cancel" @click="$emit('close')">{{ trans(modalActionClose) }}</button>
<button class="btn btn-cancel" @click="$emit('close')">{{ trans(MODAL_ACTION_CLOSE) }}</button>
<slot name="footer"></slot>
</div>
</div>
@ -56,10 +56,8 @@ export default defineComponent({
},
emits: ['close'],
setup() {
const modalActionClose = MODAL_ACTION_CLOSE;
return {
modalActionClose,
MODAL_ACTION_CLOSE,
trans
};
},