Skip to content

Commit 42efbe3

Browse files
committed
feat: simplify AcceptModal by removing title prop and hardcoding unsaved changes message
1 parent 6394313 commit 42efbe3

2 files changed

Lines changed: 3 additions & 6 deletions

File tree

adminforth/spa/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@
115115
<Spinner class="w-8 h-8" />
116116
</div>
117117
</div>
118-
<AcceptModal title="There are unsaved changes." />
118+
<AcceptModal />
119119
<div v-if="toastStore.toasts.length>0" class="fixed bottom-5 right-5 flex gap-1 flex-col-reverse z-[100]">
120120
<transition-group
121121
name="fade"

adminforth/spa/src/components/AcceptModal.vue

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
</div>
2323
</div>
2424

25-
<h3 v-if="props.title" class="mb-4 text-2xl font-bold text-gray-900 dark:text-white">
26-
{{ title }}
25+
<h3 class="mb-4 text-2xl font-bold text-gray-900 dark:text-white">
26+
There are unsaved changes.
2727
</h3>
2828

2929
<div class="mb-2 text-[15px] text-gray-600 dark:text-gray-300">
@@ -70,9 +70,6 @@ import { useModalStore } from '@/stores/modal';
7070
import { Modal } from '@/afcl';
7171
import { IconClipboardDocumentSolid } from '@iconify-prerendered/vue-heroicons';
7272
73-
const props = defineProps<{
74-
title?: string
75-
}>()
7673
7774
const modalRef = ref();
7875
const modalStore = useModalStore();

0 commit comments

Comments
 (0)