feat: 格式化分组名称显示

This commit is contained in:
tbphp
2025-07-05 10:47:36 +08:00
parent f390d5de36
commit 85452b64a7
4 changed files with 45 additions and 4 deletions

View File

@@ -1,6 +1,7 @@
<script setup lang="ts">
import { keysApi } from "@/api/keys";
import type { Group } from "@/types/models";
import { getGroupDisplayName } from "@/utils/display";
import { NButton, NCard, NEmpty, NInput, NSpin, NTag, useMessage } from "naive-ui";
import { computed, ref } from "vue";
@@ -115,7 +116,7 @@ async function createDemoGroup() {
<span v-else>🔧</span>
</div>
<div class="group-content">
<div class="group-name">{{ group.display_name || group.name }}</div>
<div class="group-name">{{ getGroupDisplayName(group) }}</div>
<div class="group-meta">
<n-tag size="tiny" :type="getChannelTagType(group.channel_type)">
{{ group.channel_type }}