feat: add Confirmation modal to prompt users to confirm or cancel dangerous actions
This commit is contained in:
parent
574ebe8850
commit
78b7732411
3 changed files with 64 additions and 0 deletions
|
@ -25,6 +25,11 @@ onMounted(() => {
|
|||
if (props.onCancel) dialog.value.addEventListener("cancel", props.onCancel);
|
||||
}
|
||||
});
|
||||
|
||||
function close() { dialog.value?.close() }
|
||||
|
||||
defineExpose({ close });
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue