diff --git a/components.d.ts b/components.d.ts index e07d992..d6fb45b 100644 --- a/components.d.ts +++ b/components.d.ts @@ -34,6 +34,7 @@ declare module 'vue' { NModal: typeof import('naive-ui')['NModal'] NNotificationProvider: typeof import('naive-ui')['NNotificationProvider'] NotPassed: typeof import('./src/components/NotPassed.vue')['default'] + NPopconfirm: typeof import('naive-ui')['NPopconfirm'] NPopover: typeof import('naive-ui')['NPopover'] NPopselect: typeof import('naive-ui')['NPopselect'] NProgress: typeof import('naive-ui')['NProgress'] diff --git a/src/views/worksheet/aside/ListItem.vue b/src/views/worksheet/aside/ListItem.vue index cb9350c..acb324e 100644 --- a/src/views/worksheet/aside/ListItem.vue +++ b/src/views/worksheet/aside/ListItem.vue @@ -28,15 +28,16 @@ const props = defineProps({ default: () => [], }, }); -const isDismissTask = ref(false) const svgName = computed(() => { return props.selected ? "taskpack-select" : "taskpack"; }); +const popconfirmTarget: any = ref(null) +const popconfirmRef: any = ref(null) function handleDismissTask() { - isDismissTask.value = true emit('dismisClick', props.mouseOverTask.id) + popconfirmRef.value[0]?.setShow(false); // 关闭 popconfirm } onMounted(async () => { @@ -44,7 +45,7 @@ onMounted(async () => {