@@ -4,14 +4,7 @@
|
|||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"description": "GPT Load Balancer Frontend - A modern Vue 3 frontend for GPT load balancing service",
|
"description": "GPT Load Balancer Frontend - A modern Vue 3 frontend for GPT load balancing service",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"keywords": [
|
"keywords": ["vue3", "typescript", "vite", "naive-ui", "gpt-load", "frontend"],
|
||||||
"vue3",
|
|
||||||
"typescript",
|
|
||||||
"vite",
|
|
||||||
"naive-ui",
|
|
||||||
"gpt-load",
|
|
||||||
"frontend"
|
|
||||||
],
|
|
||||||
"author": "tbphp",
|
"author": "tbphp",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
@@ -12,7 +12,7 @@ const animatedValues = ref<Record<string, number>>({});
|
|||||||
// 格式化数值显示
|
// 格式化数值显示
|
||||||
const formatValue = (value: number, type: "count" | "rate" = "count"): string => {
|
const formatValue = (value: number, type: "count" | "rate" = "count"): string => {
|
||||||
if (type === "rate") {
|
if (type === "rate") {
|
||||||
return `${value.toFixed(2)}%`;
|
return `${value.toFixed(1)}%`;
|
||||||
}
|
}
|
||||||
if (value >= 1000) {
|
if (value >= 1000) {
|
||||||
return `${(value / 1000).toFixed(1)}K`;
|
return `${(value / 1000).toFixed(1)}K`;
|
||||||
|
@@ -675,6 +675,8 @@ onMounted(() => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.chart-svg {
|
.chart-svg {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
background: white;
|
background: white;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
||||||
|
@@ -57,12 +57,7 @@ function renderMenuItem(key: string, label: string, icon: string): MenuOption {
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<n-menu
|
<n-menu :mode="mode" :options="menuOptions" :value="activeMenu" class="modern-menu" />
|
||||||
:mode="mode"
|
|
||||||
:options="menuOptions"
|
|
||||||
:value="activeMenu"
|
|
||||||
class="modern-menu"
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@@ -127,10 +127,7 @@ function handleGroupCreated(group: Group) {
|
|||||||
</n-button>
|
</n-button>
|
||||||
</div>
|
</div>
|
||||||
</n-card>
|
</n-card>
|
||||||
<group-form-modal
|
<group-form-modal v-model:show="showGroupModal" @success="handleGroupCreated" />
|
||||||
v-model:show="showGroupModal"
|
|
||||||
@success="handleGroupCreated"
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@@ -322,7 +322,14 @@ function changePageSize(size: number) {
|
|||||||
<!-- 表格 -->
|
<!-- 表格 -->
|
||||||
<div class="table-container">
|
<div class="table-container">
|
||||||
<n-spin :show="loading">
|
<n-spin :show="loading">
|
||||||
<n-data-table :columns="columns" :data="logs" :bordered="false" remote size="small" />
|
<n-data-table
|
||||||
|
:columns="columns"
|
||||||
|
:data="logs"
|
||||||
|
:bordered="false"
|
||||||
|
remote
|
||||||
|
size="small"
|
||||||
|
:scroll-x="1840"
|
||||||
|
/>
|
||||||
</n-spin>
|
</n-spin>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user