mirror of
https://github.com/BTMuli/TeyvatGuide.git
synced 2025-12-18 10:18:14 +08:00
🎨 代码格式化
This commit is contained in:
@@ -7,7 +7,7 @@ import { computed } from "vue";
|
||||
import TItemBox, { TItemBoxData } from "../main/t-itembox.vue";
|
||||
|
||||
interface TibCalendarAvatarProps {
|
||||
modelValue: TGApp.App.Calendar.Item
|
||||
modelValue: TGApp.App.Calendar.Item;
|
||||
}
|
||||
|
||||
const props = defineProps<TibCalendarAvatarProps>();
|
||||
|
||||
@@ -7,19 +7,17 @@ import { onMounted, ref } from "vue";
|
||||
import TItemBox, { TItemBoxData } from "../main/t-itembox.vue";
|
||||
|
||||
interface TibUrAvatarProps {
|
||||
modelValue: TGApp.Sqlite.Record.Avatar
|
||||
modelValue: TGApp.Sqlite.Record.Avatar;
|
||||
}
|
||||
|
||||
const props = defineProps<TibUrAvatarProps>();
|
||||
const box = ref({} as TItemBoxData);
|
||||
const getName = () => {
|
||||
return (
|
||||
props.modelValue.id === 10000005
|
||||
? "旅行者-空"
|
||||
: props.modelValue.id === 10000007
|
||||
? "旅行者-荧"
|
||||
: props.modelValue.name
|
||||
);
|
||||
return props.modelValue.id === 10000005
|
||||
? "旅行者-空"
|
||||
: props.modelValue.id === 10000007
|
||||
? "旅行者-荧"
|
||||
: props.modelValue.name;
|
||||
};
|
||||
|
||||
onMounted(async () => {
|
||||
@@ -38,7 +36,7 @@ onMounted(async () => {
|
||||
};
|
||||
});
|
||||
|
||||
function showData () {
|
||||
function showData() {
|
||||
// todo @click 应该出来的是一个弹窗,而不是 console
|
||||
console.log(props.modelValue);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<TItemBox :model-value="box" style="cursor: pointer;" />
|
||||
<TItemBox :model-value="box" style="cursor: pointer" />
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
// vue
|
||||
@@ -7,7 +7,7 @@ import { computed } from "vue";
|
||||
import TItemBox, { TItemBoxData } from "../main/t-itembox.vue";
|
||||
|
||||
interface TibCalendarWeaponProps {
|
||||
modelValue: TGApp.App.Weapon.WikiBriefInfo
|
||||
modelValue: TGApp.App.Weapon.WikiBriefInfo;
|
||||
}
|
||||
|
||||
const props = defineProps<TibCalendarWeaponProps>();
|
||||
|
||||
Reference in New Issue
Block a user