mirror of
https://github.com/BTMuli/TeyvatGuide.git
synced 2025-12-09 08:48:21 +08:00
🔥 删除无用代码
This commit is contained in:
@@ -37,11 +37,9 @@
|
||||
|
||||
<script lang="ts" setup>
|
||||
// vue
|
||||
import { computed, inject } from "vue";
|
||||
import { computed } from "vue";
|
||||
import TOverlay from "../main/t-overlay.vue";
|
||||
|
||||
const test = inject("hide");
|
||||
|
||||
interface TOConfirmProps {
|
||||
title: string;
|
||||
subtitle?: string;
|
||||
@@ -72,26 +70,30 @@ const props = withDefaults(defineProps<TOConfirmProps>(), {
|
||||
|
||||
const visible = computed({
|
||||
get: () => props.modelValue,
|
||||
set: (v) => emits("update:modelValue", v),
|
||||
set: (v) => {
|
||||
emits("update:modelValue", v);
|
||||
},
|
||||
});
|
||||
|
||||
const inputVal = computed({
|
||||
get: () => props.modelInput,
|
||||
set: (v) => emits("update:modelInput", v),
|
||||
set: (v) => {
|
||||
emits("update:modelInput", v);
|
||||
},
|
||||
});
|
||||
|
||||
const onCancel = () => {
|
||||
function onCancel(): void {
|
||||
visible.value = false;
|
||||
emits("cancel");
|
||||
};
|
||||
}
|
||||
|
||||
const onConfirm = () => {
|
||||
function onConfirm(): void {
|
||||
visible.value = false;
|
||||
emits("confirm");
|
||||
if (props.isInput) {
|
||||
inputVal.value = "";
|
||||
}
|
||||
};
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
Reference in New Issue
Block a user