refactor: confirm modal (#18238)

This commit is contained in:
Jason Rasmussen 2025-05-12 18:02:49 -04:00 committed by GitHub
parent 93ee6ee0a5
commit 7280331b76
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 45 additions and 44 deletions

View file

@ -1,4 +1,4 @@
import ConfirmDialog from '$lib/components/shared-components/dialog/confirm-dialog.svelte';
import ConfirmModal from '$lib/modals/ConfirmModal.svelte';
import { mount, unmount, type Component, type ComponentProps } from 'svelte';
type OnCloseData<T> = T extends { onClose: (data?: infer R) => void } ? R : never;
@ -34,8 +34,8 @@ class ModalManager {
};
}
showDialog(options: Omit<ComponentProps<typeof ConfirmDialog>, 'onClose'>) {
return this.show(ConfirmDialog, options);
showDialog(options: Omit<ComponentProps<typeof ConfirmModal>, 'onClose'>) {
return this.show(ConfirmModal, options);
}
}