<script setup>
import DeleteDialog from './Dialogs/DeleteDialog.vue';

const props = defineProps({
  show: { type: Boolean, default: false },
  title: { type: String, default: 'Potrditev' },
  message: { type: String, default: 'Ali ste prepričani?' },
  confirmText: { type: String, default: 'Potrdi' },
  cancelText: { type: String, default: 'Prekliči' },
  danger: { type: Boolean, default: false },
  itemName: { type: String, default: null },
  processing: { type: Boolean, default: false },
});

const emit = defineEmits(['close', 'confirm']);

const onClose = () => emit('close');
const onConfirm = () => emit('confirm');
</script>

<template>
  <DeleteDialog
    :show="show"
    :title="title"
    :message="message"
    :item-name="itemName"
    :confirm-text="confirmText"
    :cancel-text="cancelText"
    :processing="processing"
    @close="onClose"
    @confirm="onConfirm"
  />
</template>
