diff --git a/packages/vue3/src/_dev/App.vue b/packages/vue3/src/_dev/App.vue index 127dae2d..eaae299c 100644 --- a/packages/vue3/src/_dev/App.vue +++ b/packages/vue3/src/_dev/App.vue @@ -1,15 +1,42 @@ - + + + The quick brown fox jumps over the lazy dog. + + + + + + + Open Modal + @@ -23,4 +50,9 @@ const date = ref(); height: 100vh; gap: 40px; } + +.footer { + display: flex; + justify-content: end; +} diff --git a/packages/vue3/src/components/Modal/Modal.vue b/packages/vue3/src/components/Modal/Modal.vue index d2c8bded..267bef1c 100644 --- a/packages/vue3/src/components/Modal/Modal.vue +++ b/packages/vue3/src/components/Modal/Modal.vue @@ -11,9 +11,11 @@ const props = withDefaults(defineProps(), { }); const emit = defineEmits(['update:visible', 'onConfirm']); + const close = () => { emit('update:visible', false); }; + const handleKeypress = (event: KeyboardEvent) => { if (props.visible && event.key === 'Escape') { close(); @@ -45,15 +47,20 @@ onUnmounted(() => { @@ -84,7 +91,7 @@ onUnmounted(() => { } .modal .header, -.modal .footer { +.modal .footer-content { display: flex; flex-direction: row-reverse; align-items: center;
+ The quick brown fox jumps over the lazy dog. +