32 lines
679 B
Vue
32 lines
679 B
Vue
<script setup lang="ts">
|
|
import type { LocalList } from '@/database/db'
|
|
import ConfirmDeleteModal from '@/components/ConfirmDeleteModal.vue'
|
|
|
|
const props = defineProps<{
|
|
list: LocalList
|
|
}>()
|
|
|
|
const emit = defineEmits<{
|
|
close: []
|
|
confirm: []
|
|
}>()
|
|
|
|
function handleClose() {
|
|
emit('close')
|
|
}
|
|
|
|
function handleConfirm() {
|
|
emit('confirm')
|
|
}
|
|
</script>
|
|
|
|
<template>
|
|
<ConfirmDeleteModal
|
|
:title="`Delete "${props.list.name}"?`"
|
|
description="Are you sure you want to delete this list? This action cannot be undone and all items in this list will be deleted."
|
|
confirm-label="Delete list"
|
|
@close="handleClose"
|
|
@confirm="handleConfirm"
|
|
/>
|
|
</template>
|