<template>
  <CusDialog
      title="这里是弹窗的标题"
      :show="show"
      @close="$emit('update:show', false)"
      @submit="$emit('update:show', false)"
      closeConfirm
      :closeConfirmText="closeConfirmText"
  >
    <div>
      closeConfirm属性开启关闭时的确认弹窗<br/>
      也可以单独设置关闭确认框的各文本<br/>
      <CusFormColumn :span="24" label="标题" v-model:param="closeConfirmText.title"/>
      <CusFormColumn :span="24" label="内容" v-model:param="closeConfirmText.message"/>
      <CusFormColumn :span="24" label="确定" v-model:param="closeConfirmText.submit"/>
      <CusFormColumn :span="24" label="取消" v-model:param="closeConfirmText.close"/>
    </div>
  </CusDialog>
</template>

<script lang="ts">
import {
  defineComponent,
  computed,
  onMounted,
  ref,
  reactive,
  watch,
  getCurrentInstance,
  ComponentInternalInstance,
  toRefs,
  nextTick
} from 'vue'
import {useStore} from 'vuex'
import {useRouter, useRoute} from 'vue-router'

export default defineComponent({
  name: '',
  components: {},
  props: {
    show: {}
  },
  setup(props, {emit}) {
    const store = useStore();
    const router = useRouter();
    const route = useRoute();
    const that = (getCurrentInstance() as ComponentInternalInstance).appContext.config.globalProperties
    const state = reactive({
      closeConfirmText: {}
    })
    return {
      ...toRefs(state)
    }
  },
})
</script>

<style scoped lang="scss">
</style>
