fogact 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +244 -0
- package/README.zh-CN.md +244 -0
- package/bin/cli.js +9 -0
- package/bin/web-server.js +1434 -0
- package/config/upstream.example.json +14 -0
- package/frontend/activate.html +249 -0
- package/frontend/admin/admin-panel-v2.js +1899 -0
- package/frontend/admin/index.html +705 -0
- package/frontend/assets/market-ui.css +1876 -0
- package/frontend/color-test.html +136 -0
- package/frontend/index.html +191 -0
- package/frontend/user/assets/AnnouncementDetail-Dvxmwz0A.js +12 -0
- package/frontend/user/assets/Announcements-CS1tF2mx.js +11 -0
- package/frontend/user/assets/CardBind-CsCxihhP.js +21 -0
- package/frontend/user/assets/CardContent.vue_vue_type_script_setup_true_lang-D2L-uqSl.js +1 -0
- package/frontend/user/assets/CardDescription.vue_vue_type_script_setup_true_lang-D-v5Pl7F.js +1 -0
- package/frontend/user/assets/CardTitle.vue_vue_type_script_setup_true_lang-a0CCN6D5.js +1 -0
- package/frontend/user/assets/Dashboard-rPsmltm5.js +51 -0
- package/frontend/user/assets/DashboardLayout-BUCWGlXC.css +1 -0
- package/frontend/user/assets/DashboardLayout-DDkxHYFj.js +80 -0
- package/frontend/user/assets/Input.vue_vue_type_script_setup_true_lang-B0SyPmYb.js +6 -0
- package/frontend/user/assets/Label.vue_vue_type_script_setup_true_lang-CxYORSgN.js +1 -0
- package/frontend/user/assets/Progress.vue_vue_type_script_setup_true_lang-2_QbPsEQ.js +1 -0
- package/frontend/user/assets/QuotaPack-B_tJ7Psm.js +6 -0
- package/frontend/user/assets/Renewal-BSDhDmwv.js +6 -0
- package/frontend/user/assets/ScrollArea.vue_vue_type_script_setup_true_lang-DMYwcfpz.js +1 -0
- package/frontend/user/assets/Separator.vue_vue_type_script_setup_true_lang-Ckg8EXj_.js +1 -0
- package/frontend/user/assets/Settings-CBdAa3lw.js +11 -0
- package/frontend/user/assets/TooltipTrigger.vue_vue_type_script_setup_true_lang-DtSBjzGo.js +16 -0
- package/frontend/user/assets/Welcome-7IfzEli4.css +1 -0
- package/frontend/user/assets/Welcome-Dtfp6oER.js +1 -0
- package/frontend/user/assets/_plugin-vue_export-helper-5cjT4u0R.js +16 -0
- package/frontend/user/assets/activity-wYWtyqTJ.js +6 -0
- package/frontend/user/assets/announcement-35mOnjRL.js +16 -0
- package/frontend/user/assets/calendar-BFNuCata.js +6 -0
- package/frontend/user/assets/chart-vendor-CULJE59K.js +37 -0
- package/frontend/user/assets/chevron-down-kDbuU1Py.js +6 -0
- package/frontend/user/assets/chevron-right-BayASIm0.js +6 -0
- package/frontend/user/assets/eye-CY62vip0.js +6 -0
- package/frontend/user/assets/gauge-C5NQ-mV8.js +6 -0
- package/frontend/user/assets/index-B8QSyYhS.css +1 -0
- package/frontend/user/assets/index-Da98HOxL.js +91 -0
- package/frontend/user/assets/link-2-DT5R5nGO.js +6 -0
- package/frontend/user/assets/package-rUbExUEn.js +6 -0
- package/frontend/user/assets/plus-CQc6C8wG.js +11 -0
- package/frontend/user/assets/refresh-cw-Y9hCloPL.js +6 -0
- package/frontend/user/assets/useUserPageRefresh-BYZvpNR9.js +1 -0
- package/frontend/user/assets/zap-l5zbZqrM.js +11 -0
- package/frontend/user/index.html +67 -0
- package/install.sh +402 -0
- package/lib/commands/activate.js +144 -0
- package/lib/commands/restore.js +102 -0
- package/lib/commands/test.js +40 -0
- package/lib/config/claude.js +81 -0
- package/lib/config/codex.js +164 -0
- package/lib/config/upstream.js +79 -0
- package/lib/index.js +164 -0
- package/lib/platforms/claude-code.js +35 -0
- package/lib/platforms/codex-cli.js +35 -0
- package/lib/platforms/editor-codex.js +138 -0
- package/lib/platforms/index.js +32 -0
- package/lib/platforms/openclaw.js +118 -0
- package/lib/platforms/opencode.js +89 -0
- package/lib/services/activation-orchestrator.js +666 -0
- package/lib/services/backup-service.js +162 -0
- package/lib/services/cliproxy-api.js +174 -0
- package/lib/services/database.js +461 -0
- package/lib/services/newapi.js +97 -0
- package/lib/services/node-service.js +49 -0
- package/lib/utils/json-file.js +33 -0
- package/package.json +53 -0
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html class="light" lang="zh-CN">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
|
+
<title>配色方案测试 | FogIDC Activator</title>
|
|
7
|
+
<link href="https://fonts.googleapis.com/css2?family=Manrope:wght@600;700;800&family=Inter:wght@400;500;600&display=swap" rel="stylesheet">
|
|
8
|
+
<script src="https://cdn.tailwindcss.com"></script>
|
|
9
|
+
<script>
|
|
10
|
+
tailwind.config = {
|
|
11
|
+
darkMode: "class",
|
|
12
|
+
theme: {
|
|
13
|
+
extend: {
|
|
14
|
+
colors: {
|
|
15
|
+
"background": "hsl(210, 40%, 98%)",
|
|
16
|
+
"surface": "hsl(210, 40%, 98%)",
|
|
17
|
+
"surface-container-lowest": "#ffffff",
|
|
18
|
+
"surface-container-low": "hsl(210, 40%, 96%)",
|
|
19
|
+
"surface-container": "hsl(210, 30%, 94%)",
|
|
20
|
+
"surface-container-high": "hsl(210, 25%, 92%)",
|
|
21
|
+
"primary": "hsl(210, 100%, 50%)",
|
|
22
|
+
"on-surface": "hsl(210, 10%, 15%)",
|
|
23
|
+
"on-surface-variant": "hsl(210, 8%, 45%)",
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
</script>
|
|
29
|
+
<style>
|
|
30
|
+
.dark .bg-background { background-color: hsl(240, 10%, 3.9%) !important; }
|
|
31
|
+
.dark .bg-surface { background-color: hsl(240, 10%, 3.9%) !important; }
|
|
32
|
+
.dark .bg-surface-container-lowest { background-color: hsl(240, 10%, 6%) !important; }
|
|
33
|
+
.dark .bg-surface-container-low { background-color: hsl(240, 10%, 8%) !important; }
|
|
34
|
+
.dark .bg-surface-container { background-color: hsl(240, 10%, 10%) !important; }
|
|
35
|
+
.dark .text-on-surface { color: hsl(0, 0%, 95%) !important; }
|
|
36
|
+
.dark .text-on-surface-variant { color: hsl(0, 0%, 70%) !important; }
|
|
37
|
+
</style>
|
|
38
|
+
</head>
|
|
39
|
+
<body class="bg-surface text-on-surface min-h-screen p-8">
|
|
40
|
+
<div class="max-w-6xl mx-auto">
|
|
41
|
+
<div class="flex justify-between items-center mb-8">
|
|
42
|
+
<h1 class="text-3xl font-bold">配色方案测试</h1>
|
|
43
|
+
<button onclick="toggleTheme()" class="px-4 py-2 bg-primary text-white rounded-lg">
|
|
44
|
+
切换主题
|
|
45
|
+
</button>
|
|
46
|
+
</div>
|
|
47
|
+
|
|
48
|
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
|
|
49
|
+
<!-- 背景色卡片 -->
|
|
50
|
+
<div class="bg-surface-container-lowest p-6 rounded-2xl">
|
|
51
|
+
<h2 class="text-xl font-bold mb-4">背景色层级</h2>
|
|
52
|
+
<div class="space-y-3">
|
|
53
|
+
<div class="bg-surface p-4 rounded-lg">
|
|
54
|
+
<p class="text-sm font-medium">Surface (基础)</p>
|
|
55
|
+
<p class="text-xs text-on-surface-variant">hsl(210, 40%, 98%)</p>
|
|
56
|
+
</div>
|
|
57
|
+
<div class="bg-surface-container-lowest p-4 rounded-lg">
|
|
58
|
+
<p class="text-sm font-medium">Container Lowest</p>
|
|
59
|
+
<p class="text-xs text-on-surface-variant">#ffffff</p>
|
|
60
|
+
</div>
|
|
61
|
+
<div class="bg-surface-container-low p-4 rounded-lg">
|
|
62
|
+
<p class="text-sm font-medium">Container Low</p>
|
|
63
|
+
<p class="text-xs text-on-surface-variant">hsl(210, 40%, 96%)</p>
|
|
64
|
+
</div>
|
|
65
|
+
<div class="bg-surface-container p-4 rounded-lg">
|
|
66
|
+
<p class="text-sm font-medium">Container</p>
|
|
67
|
+
<p class="text-xs text-on-surface-variant">hsl(210, 30%, 94%)</p>
|
|
68
|
+
</div>
|
|
69
|
+
</div>
|
|
70
|
+
</div>
|
|
71
|
+
|
|
72
|
+
<!-- 主色卡片 -->
|
|
73
|
+
<div class="bg-surface-container-lowest p-6 rounded-2xl">
|
|
74
|
+
<h2 class="text-xl font-bold mb-4">主色系统</h2>
|
|
75
|
+
<div class="space-y-3">
|
|
76
|
+
<div class="bg-primary text-white p-4 rounded-lg">
|
|
77
|
+
<p class="text-sm font-medium">Primary</p>
|
|
78
|
+
<p class="text-xs opacity-90">hsl(210, 100%, 50%)</p>
|
|
79
|
+
</div>
|
|
80
|
+
<div class="p-4 rounded-lg border-2 border-primary">
|
|
81
|
+
<p class="text-sm font-medium text-primary">Primary Border</p>
|
|
82
|
+
<p class="text-xs text-on-surface-variant">用于边框和强调</p>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
</div>
|
|
86
|
+
|
|
87
|
+
<!-- 文字颜色 -->
|
|
88
|
+
<div class="bg-surface-container-lowest p-6 rounded-2xl">
|
|
89
|
+
<h2 class="text-xl font-bold mb-4">文字颜色</h2>
|
|
90
|
+
<div class="space-y-3">
|
|
91
|
+
<p class="text-on-surface text-lg">主要文字 (on-surface)</p>
|
|
92
|
+
<p class="text-on-surface-variant">次要文字 (on-surface-variant)</p>
|
|
93
|
+
<p class="text-on-surface-variant text-sm">辅助说明文字</p>
|
|
94
|
+
</div>
|
|
95
|
+
</div>
|
|
96
|
+
|
|
97
|
+
<!-- 示例卡片 -->
|
|
98
|
+
<div class="bg-surface-container-lowest p-6 rounded-2xl">
|
|
99
|
+
<h2 class="text-xl font-bold mb-4">示例组件</h2>
|
|
100
|
+
<div class="space-y-3">
|
|
101
|
+
<button class="w-full px-4 py-3 bg-primary text-white rounded-lg font-medium hover:opacity-90">
|
|
102
|
+
主要按钮
|
|
103
|
+
</button>
|
|
104
|
+
<button class="w-full px-4 py-3 bg-surface-container text-on-surface rounded-lg font-medium hover:bg-surface-container-high">
|
|
105
|
+
次要按钮
|
|
106
|
+
</button>
|
|
107
|
+
<input type="text" placeholder="输入框示例" class="w-full px-4 py-3 bg-surface-container-low rounded-lg border-none outline-none focus:ring-2 ring-primary/20">
|
|
108
|
+
</div>
|
|
109
|
+
</div>
|
|
110
|
+
</div>
|
|
111
|
+
|
|
112
|
+
<div class="mt-8 bg-surface-container-lowest p-6 rounded-2xl">
|
|
113
|
+
<h2 class="text-xl font-bold mb-4">配色说明</h2>
|
|
114
|
+
<div class="space-y-2 text-sm text-on-surface-variant">
|
|
115
|
+
<p>✅ 浅色模式:使用 hsl(210, 40%, 98%) 作为基础背景色,营造清爽的蓝灰色调</p>
|
|
116
|
+
<p>✅ 深色模式:使用 hsl(240, 10%, 3.9%) 作为基础背景色,提供舒适的深色体验</p>
|
|
117
|
+
<p>✅ 主色:hsl(210, 100%, 50%) 明亮的蓝色,用于强调和交互元素</p>
|
|
118
|
+
<p>✅ 与用户端页面完全统一的配色体系</p>
|
|
119
|
+
</div>
|
|
120
|
+
</div>
|
|
121
|
+
</div>
|
|
122
|
+
|
|
123
|
+
<script>
|
|
124
|
+
function toggleTheme() {
|
|
125
|
+
const html = document.documentElement;
|
|
126
|
+
if (html.classList.contains('dark')) {
|
|
127
|
+
html.classList.remove('dark');
|
|
128
|
+
html.classList.add('light');
|
|
129
|
+
} else {
|
|
130
|
+
html.classList.remove('light');
|
|
131
|
+
html.classList.add('dark');
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
</script>
|
|
135
|
+
</body>
|
|
136
|
+
</html>
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="zh-CN">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>FogIDC Activator | 动态激活控制台</title>
|
|
7
|
+
<meta name="description" content="FogIDC Activator 的用户中心、管理后台与激活码入口。" />
|
|
8
|
+
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
9
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
10
|
+
<link href="https://fonts.googleapis.com/css2?family=Manrope:wght@600;700;800&family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet" />
|
|
11
|
+
<link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" rel="stylesheet" />
|
|
12
|
+
<link rel="stylesheet" href="/assets/market-ui.css?v=20260616-upstream2" />
|
|
13
|
+
</head>
|
|
14
|
+
<body class="market-page">
|
|
15
|
+
<span class="market-mouse-light" aria-hidden="true"></span>
|
|
16
|
+
|
|
17
|
+
<div class="market-shell">
|
|
18
|
+
<header class="market-topbar">
|
|
19
|
+
<a class="market-brand" href="/">
|
|
20
|
+
<span class="market-logo">F</span>
|
|
21
|
+
<span>
|
|
22
|
+
<span class="market-brand-title">FogIDC Activator</span>
|
|
23
|
+
<span class="market-brand-subtitle">Motion control surface</span>
|
|
24
|
+
</span>
|
|
25
|
+
</a>
|
|
26
|
+
|
|
27
|
+
<nav class="market-nav" aria-label="主导航">
|
|
28
|
+
<a href="/user/">用户中心</a>
|
|
29
|
+
<a href="/admin/">管理后台</a>
|
|
30
|
+
<a href="/activate.html">激活 CDK</a>
|
|
31
|
+
</nav>
|
|
32
|
+
|
|
33
|
+
<div class="market-actions">
|
|
34
|
+
<a class="market-button" href="/api/stats">API</a>
|
|
35
|
+
<a class="market-button market-button-primary" href="/user/">
|
|
36
|
+
<span class="material-symbols-outlined">bolt</span>
|
|
37
|
+
进入控制台
|
|
38
|
+
</a>
|
|
39
|
+
</div>
|
|
40
|
+
</header>
|
|
41
|
+
|
|
42
|
+
<main>
|
|
43
|
+
<section class="market-hero" aria-labelledby="hero-title">
|
|
44
|
+
<div class="market-hero-main">
|
|
45
|
+
<div class="market-kicker"><span class="market-kicker-dot"></span> living interface for CLI activation</div>
|
|
46
|
+
<h1 id="hero-title" class="market-title">不是工具页,是一个会呼吸的 <span>激活工作台</span></h1>
|
|
47
|
+
<p class="market-copy">
|
|
48
|
+
参考 21st.dev 的浏览式组件结构,但不照搬卡片模板:这里用轨道、错位、光扫、浮动组件和指针跟随做出更有辨识度的首页。
|
|
49
|
+
</p>
|
|
50
|
+
|
|
51
|
+
<label class="market-search" aria-label="搜索功能入口">
|
|
52
|
+
<span class="material-symbols-outlined">travel_explore</span>
|
|
53
|
+
<input type="search" placeholder="搜索:Codex、Claude、激活码、额度、用户" />
|
|
54
|
+
<span class="market-search-key">⌘ K</span>
|
|
55
|
+
</label>
|
|
56
|
+
|
|
57
|
+
<div class="market-ambient-dock" aria-label="服务状态">
|
|
58
|
+
<span class="market-ambient-item"><span class="material-symbols-outlined">terminal</span></span>
|
|
59
|
+
<span class="market-ambient-item"><span class="material-symbols-outlined">cloud_sync</span></span>
|
|
60
|
+
<span class="market-ambient-item"><span class="material-symbols-outlined">key_vertical</span></span>
|
|
61
|
+
<span class="market-ambient-item"><span class="material-symbols-outlined">query_stats</span></span>
|
|
62
|
+
</div>
|
|
63
|
+
|
|
64
|
+
<div class="market-orbit-stage" aria-hidden="true">
|
|
65
|
+
<span class="market-orbit-node material-symbols-outlined">code</span>
|
|
66
|
+
<span class="market-orbit-node material-symbols-outlined">vpn_key</span>
|
|
67
|
+
<span class="market-orbit-node material-symbols-outlined">monitoring</span>
|
|
68
|
+
<span class="market-orbit-node material-symbols-outlined">hub</span>
|
|
69
|
+
<span class="market-signal-line"></span>
|
|
70
|
+
</div>
|
|
71
|
+
</div>
|
|
72
|
+
|
|
73
|
+
<aside class="market-hero-side" aria-label="动态状态概览">
|
|
74
|
+
<div class="market-preview-stack">
|
|
75
|
+
<div class="market-mini-card">
|
|
76
|
+
<span class="market-icon material-symbols-outlined">auto_awesome_motion</span>
|
|
77
|
+
<div>
|
|
78
|
+
<p class="market-mini-title">动效层已启用</p>
|
|
79
|
+
<p class="market-mini-copy">光扫、浮动、错位网格、指针光晕、卡片内组件各自运动。</p>
|
|
80
|
+
</div>
|
|
81
|
+
<span class="market-status-pill">Motion</span>
|
|
82
|
+
</div>
|
|
83
|
+
<div class="market-mini-card">
|
|
84
|
+
<span class="market-icon material-symbols-outlined">gesture</span>
|
|
85
|
+
<div>
|
|
86
|
+
<p class="market-mini-title">非模板化卡片</p>
|
|
87
|
+
<p class="market-mini-copy">每张卡片的预览内容、节奏和视觉重心都不同。</p>
|
|
88
|
+
</div>
|
|
89
|
+
<span class="market-status-pill">Custom</span>
|
|
90
|
+
</div>
|
|
91
|
+
<div class="market-mini-card">
|
|
92
|
+
<span class="market-icon material-symbols-outlined">speed</span>
|
|
93
|
+
<div>
|
|
94
|
+
<p class="market-mini-title">轻量 CSS 动画</p>
|
|
95
|
+
<p class="market-mini-copy">保留静态部署,不引入新前端构建链。</p>
|
|
96
|
+
</div>
|
|
97
|
+
<span class="market-status-pill">CSS</span>
|
|
98
|
+
</div>
|
|
99
|
+
</div>
|
|
100
|
+
|
|
101
|
+
<div class="market-panel" style="border-radius: 26px; padding: 18px;">
|
|
102
|
+
<div class="market-card-footer">
|
|
103
|
+
<span class="market-tag">Local server</span>
|
|
104
|
+
<span class="market-status-pill"><span class="market-kicker-dot"></span> 34020</span>
|
|
105
|
+
</div>
|
|
106
|
+
<p class="market-mini-copy" style="margin-top: 14px; font-size: 14px; line-height: 1.7;">
|
|
107
|
+
这一版把“统一样式”换成“动态产品感”:首页负责记忆点,后台和用户端继承氛围但不打断功能。
|
|
108
|
+
</p>
|
|
109
|
+
</div>
|
|
110
|
+
</aside>
|
|
111
|
+
</section>
|
|
112
|
+
|
|
113
|
+
<section aria-labelledby="section-title">
|
|
114
|
+
<div class="market-section-head">
|
|
115
|
+
<div>
|
|
116
|
+
<h2 id="section-title">工作区入口</h2>
|
|
117
|
+
<p>卡片不再是同一个模板复制三次,而是分别表达“监控、管理、激活”的动作状态。</p>
|
|
118
|
+
</div>
|
|
119
|
+
<a class="market-button" href="/admin/">打开管理中心</a>
|
|
120
|
+
</div>
|
|
121
|
+
|
|
122
|
+
<div class="market-grid">
|
|
123
|
+
<a class="market-card market-card-lab" href="/user/">
|
|
124
|
+
<div class="market-card-canvas">
|
|
125
|
+
<span class="market-widget market-widget-meter"></span>
|
|
126
|
+
<span class="market-widget market-widget-graph"><i></i><i></i><i></i><i></i></span>
|
|
127
|
+
</div>
|
|
128
|
+
<div class="market-card-content">
|
|
129
|
+
<h3>用户用量雷达</h3>
|
|
130
|
+
<p>用浮动指标卡和脉冲柱状图表达实时额度、请求量和用户状态。</p>
|
|
131
|
+
<div class="market-card-footer"><span class="market-tag">Portal</span><span class="market-arrow">→</span></div>
|
|
132
|
+
</div>
|
|
133
|
+
</a>
|
|
134
|
+
|
|
135
|
+
<a class="market-card market-card-lab" href="/admin/">
|
|
136
|
+
<div class="market-card-canvas">
|
|
137
|
+
<span class="market-widget market-widget-code"><span></span><span></span><span></span></span>
|
|
138
|
+
<span class="market-widget market-widget-ring"></span>
|
|
139
|
+
</div>
|
|
140
|
+
<div class="market-card-content">
|
|
141
|
+
<h3>管理控制台</h3>
|
|
142
|
+
<p>像组件面板一样管理用户、激活码、日志和设置,重点是效率而不是装饰。</p>
|
|
143
|
+
<div class="market-card-footer"><span class="market-tag">Console</span><span class="market-arrow">→</span></div>
|
|
144
|
+
</div>
|
|
145
|
+
</a>
|
|
146
|
+
|
|
147
|
+
<a class="market-card market-card-lab" href="/activate.html">
|
|
148
|
+
<div class="market-card-canvas">
|
|
149
|
+
<span class="market-widget market-widget-key"></span>
|
|
150
|
+
<span class="market-widget market-widget-toggle"></span>
|
|
151
|
+
<span class="market-widget market-widget-badge material-symbols-outlined">bolt</span>
|
|
152
|
+
</div>
|
|
153
|
+
<div class="market-card-content">
|
|
154
|
+
<h3>CDK 点火流程</h3>
|
|
155
|
+
<p>把激活动作做成“点火”体验,强调输入、校验、开通的连续反馈。</p>
|
|
156
|
+
<div class="market-card-footer"><span class="market-tag">Activation</span><span class="market-arrow">→</span></div>
|
|
157
|
+
</div>
|
|
158
|
+
</a>
|
|
159
|
+
</div>
|
|
160
|
+
</section>
|
|
161
|
+
</main>
|
|
162
|
+
</div>
|
|
163
|
+
|
|
164
|
+
<script>
|
|
165
|
+
const body = document.body;
|
|
166
|
+
let raf = 0;
|
|
167
|
+
|
|
168
|
+
window.addEventListener('load', () => {
|
|
169
|
+
requestAnimationFrame(() => body.classList.add('motion-ready'));
|
|
170
|
+
}, { once: true });
|
|
171
|
+
|
|
172
|
+
window.addEventListener('pointermove', (event) => {
|
|
173
|
+
if (raf) return;
|
|
174
|
+
raf = requestAnimationFrame(() => {
|
|
175
|
+
body.classList.add('is-pointer-active');
|
|
176
|
+
body.style.setProperty('--cursor-x', `${event.clientX}px`);
|
|
177
|
+
body.style.setProperty('--cursor-y', `${event.clientY}px`);
|
|
178
|
+
raf = 0;
|
|
179
|
+
});
|
|
180
|
+
});
|
|
181
|
+
|
|
182
|
+
document.querySelectorAll('.market-card-lab').forEach((card) => {
|
|
183
|
+
card.addEventListener('pointermove', (event) => {
|
|
184
|
+
const rect = card.getBoundingClientRect();
|
|
185
|
+
card.style.setProperty('--mx', `${((event.clientX - rect.left) / rect.width) * 100}%`);
|
|
186
|
+
card.style.setProperty('--my', `${((event.clientY - rect.top) / rect.height) * 100}%`);
|
|
187
|
+
});
|
|
188
|
+
});
|
|
189
|
+
</script>
|
|
190
|
+
</body>
|
|
191
|
+
</html>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import{c as Vt,a1 as gn,b as hn,_ as Tn,J as It,ay as An,t as En}from"./index-Da98HOxL.js";import{a as J,_ as de}from"./CardContent.vue_vue_type_script_setup_true_lang-D2L-uqSl.js";import{a as Mt,_ as kt}from"./CardTitle.vue_vue_type_script_setup_true_lang-a0CCN6D5.js";import{_ as Pt}from"./Separator.vue_vue_type_script_setup_true_lang-Ckg8EXj_.js";import{u as yn,M as Sn,P as bn,C as xn}from"./announcement-35mOnjRL.js";import{j as lt,x as le,y as W,D as Ce,u as m,E as x,A as p,F as Kt,B as vn,J as Rn,Q as X,r as _e,d as Je,w as Ut,L as wn,M as Ln,z as Qe,H as d,P as te,n as Ft}from"./chart-vendor-CULJE59K.js";import{_ as Dn}from"./ScrollArea.vue_vue_type_script_setup_true_lang-DMYwcfpz.js";import{a as On}from"./useUserPageRefresh-BYZvpNR9.js";/**
|
|
2
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const Cn=Vt("ChevronLeftIcon",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
|
|
7
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the ISC license.
|
|
10
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/const Nn=Vt("HistoryIcon",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/*! @license DOMPurify 3.3.2 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.2/LICENSE */const{entries:Zt,setPrototypeOf:Ht,isFrozen:In,getPrototypeOf:Mn,getOwnPropertyDescriptor:kn}=Object;let{freeze:C,seal:H,create:Ne}=Object,{apply:rt,construct:it}=typeof Reflect<"u"&&Reflect;C||(C=function(n){return n});H||(H=function(n){return n});rt||(rt=function(n,i){for(var s=arguments.length,l=new Array(s>2?s-2:0),_=2;_<s;_++)l[_-2]=arguments[_];return n.apply(i,l)});it||(it=function(n){for(var i=arguments.length,s=new Array(i>1?i-1:0),l=1;l<i;l++)s[l-1]=arguments[l];return new n(...s)});const De=N(Array.prototype.forEach),Pn=N(Array.prototype.lastIndexOf),zt=N(Array.prototype.pop),ge=N(Array.prototype.push),Un=N(Array.prototype.splice),Ie=N(String.prototype.toLowerCase),et=N(String.prototype.toString),tt=N(String.prototype.match),he=N(String.prototype.replace),Fn=N(String.prototype.indexOf),Hn=N(String.prototype.trim),F=N(Object.prototype.hasOwnProperty),O=N(RegExp.prototype.test),Te=zn(TypeError);function N(a){return function(n){n instanceof RegExp&&(n.lastIndex=0);for(var i=arguments.length,s=new Array(i>1?i-1:0),l=1;l<i;l++)s[l-1]=arguments[l];return rt(a,n,s)}}function zn(a){return function(){for(var n=arguments.length,i=new Array(n),s=0;s<n;s++)i[s]=arguments[s];return it(a,i)}}function u(a,n){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Ie;Ht&&Ht(a,null);let s=n.length;for(;s--;){let l=n[s];if(typeof l=="string"){const _=i(l);_!==l&&(In(n)||(n[s]=_),l=_)}a[l]=!0}return a}function Bn(a){for(let n=0;n<a.length;n++)F(a,n)||(a[n]=null);return a}function G(a){const n=Ne(null);for(const[i,s]of Zt(a))F(a,i)&&(Array.isArray(s)?n[i]=Bn(s):s&&typeof s=="object"&&s.constructor===Object?n[i]=G(s):n[i]=s);return n}function Ae(a,n){for(;a!==null;){const s=kn(a,n);if(s){if(s.get)return N(s.get);if(typeof s.value=="function")return N(s.value)}a=Mn(a)}function i(){return null}return i}const Bt=C(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),nt=C(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ot=C(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Gn=C(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),at=C(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Wn=C(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Gt=C(["#text"]),Wt=C(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),st=C(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),$t=C(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Oe=C(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),$n=H(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Yn=H(/<%[\w\W]*|[\w\W]*%>/gm),jn=H(/\$\{[\w\W]*/gm),qn=H(/^data-[\-\w.\u00B7-\uFFFF]+$/),Xn=H(/^aria-[\-\w]+$/),Jt=H(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Vn=H(/^(?:\w+script|data):/i),Kn=H(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Qt=H(/^html$/i),Zn=H(/^[a-z][.\w]*(-[.\w]+)+$/i);var Yt=Object.freeze({__proto__:null,ARIA_ATTR:Xn,ATTR_WHITESPACE:Kn,CUSTOM_ELEMENT:Zn,DATA_ATTR:qn,DOCTYPE_NAME:Qt,ERB_EXPR:Yn,IS_ALLOWED_URI:Jt,IS_SCRIPT_OR_DATA:Vn,MUSTACHE_EXPR:$n,TMPLIT_EXPR:jn});const Ee={element:1,text:3,progressingInstruction:7,comment:8,document:9},Jn=function(){return typeof window>"u"?null:window},Qn=function(n,i){if(typeof n!="object"||typeof n.createPolicy!="function")return null;let s=null;const l="data-tt-policy-suffix";i&&i.hasAttribute(l)&&(s=i.getAttribute(l));const _="dompurify"+(s?"#"+s:"");try{return n.createPolicy(_,{createHTML(h){return h},createScriptURL(h){return h}})}catch{return console.warn("TrustedTypes policy "+_+" could not be created."),null}},jt=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function en(){let a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Jn();const n=r=>en(r);if(n.version="3.3.2",n.removed=[],!a||!a.document||a.document.nodeType!==Ee.document||!a.Element)return n.isSupported=!1,n;let{document:i}=a;const s=i,l=s.currentScript,{DocumentFragment:_,HTMLTemplateElement:h,Node:k,Element:w,NodeFilter:A,NamedNodeMap:P=a.NamedNodeMap||a.MozNamedAttrMap,HTMLFormElement:ce,DOMParser:ue,trustedTypes:$}=a,U=w.prototype,Me=Ae(U,"cloneNode"),ke=Ae(U,"remove"),Pe=Ae(U,"nextSibling"),Ue=Ae(U,"childNodes"),V=Ae(U,"parentNode");if(typeof h=="function"){const r=i.createElement("template");r.content&&r.content.ownerDocument&&(i=r.content.ownerDocument)}let f,c="";const{implementation:I,createNodeIterator:K,createDocumentFragment:y,getElementsByTagName:tn}=i,{importNode:nn}=s;let D=jt();n.isSupported=typeof Zt=="function"&&typeof V=="function"&&I&&I.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:Fe,ERB_EXPR:He,TMPLIT_EXPR:ze,DATA_ATTR:on,ARIA_ATTR:an,IS_SCRIPT_OR_DATA:sn,ATTR_WHITESPACE:ct,CUSTOM_ELEMENT:rn}=Yt;let{IS_ALLOWED_URI:ut}=Yt,b=null;const ft=u({},[...Bt,...nt,...ot,...at,...Gt]);let v=null;const mt=u({},[...Wt,...st,...$t,...Oe]);let T=Object.seal(Ne(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),fe=null,ye=null;const Z=Object.seal(Ne(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let pt=!0,Be=!0,dt=!1,_t=!0,ne=!1,Se=!0,Q=!1,Ge=!1,We=!1,oe=!1,be=!1,xe=!1,gt=!0,ht=!1;const ln="user-content-";let $e=!0,me=!1,ae={},z=null;const Ye=u({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Tt=null;const At=u({},["audio","video","img","source","image","track"]);let je=null;const Et=u({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),ve="http://www.w3.org/1998/Math/MathML",Re="http://www.w3.org/2000/svg",Y="http://www.w3.org/1999/xhtml";let se=Y,qe=!1,Xe=null;const cn=u({},[ve,Re,Y],et);let we=u({},["mi","mo","mn","ms","mtext"]),Le=u({},["annotation-xml"]);const un=u({},["title","style","font","a","script"]);let pe=null;const fn=["application/xhtml+xml","text/html"],mn="text/html";let S=null,re=null;const pn=i.createElement("form"),yt=function(e){return e instanceof RegExp||e instanceof Function},Ve=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(re&&re===e)){if((!e||typeof e!="object")&&(e={}),e=G(e),pe=fn.indexOf(e.PARSER_MEDIA_TYPE)===-1?mn:e.PARSER_MEDIA_TYPE,S=pe==="application/xhtml+xml"?et:Ie,b=F(e,"ALLOWED_TAGS")?u({},e.ALLOWED_TAGS,S):ft,v=F(e,"ALLOWED_ATTR")?u({},e.ALLOWED_ATTR,S):mt,Xe=F(e,"ALLOWED_NAMESPACES")?u({},e.ALLOWED_NAMESPACES,et):cn,je=F(e,"ADD_URI_SAFE_ATTR")?u(G(Et),e.ADD_URI_SAFE_ATTR,S):Et,Tt=F(e,"ADD_DATA_URI_TAGS")?u(G(At),e.ADD_DATA_URI_TAGS,S):At,z=F(e,"FORBID_CONTENTS")?u({},e.FORBID_CONTENTS,S):Ye,fe=F(e,"FORBID_TAGS")?u({},e.FORBID_TAGS,S):G({}),ye=F(e,"FORBID_ATTR")?u({},e.FORBID_ATTR,S):G({}),ae=F(e,"USE_PROFILES")?e.USE_PROFILES:!1,pt=e.ALLOW_ARIA_ATTR!==!1,Be=e.ALLOW_DATA_ATTR!==!1,dt=e.ALLOW_UNKNOWN_PROTOCOLS||!1,_t=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ne=e.SAFE_FOR_TEMPLATES||!1,Se=e.SAFE_FOR_XML!==!1,Q=e.WHOLE_DOCUMENT||!1,oe=e.RETURN_DOM||!1,be=e.RETURN_DOM_FRAGMENT||!1,xe=e.RETURN_TRUSTED_TYPE||!1,We=e.FORCE_BODY||!1,gt=e.SANITIZE_DOM!==!1,ht=e.SANITIZE_NAMED_PROPS||!1,$e=e.KEEP_CONTENT!==!1,me=e.IN_PLACE||!1,ut=e.ALLOWED_URI_REGEXP||Jt,se=e.NAMESPACE||Y,we=e.MATHML_TEXT_INTEGRATION_POINTS||we,Le=e.HTML_INTEGRATION_POINTS||Le,T=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&yt(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(T.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&yt(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(T.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(T.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ne&&(Be=!1),be&&(oe=!0),ae&&(b=u({},Gt),v=Ne(null),ae.html===!0&&(u(b,Bt),u(v,Wt)),ae.svg===!0&&(u(b,nt),u(v,st),u(v,Oe)),ae.svgFilters===!0&&(u(b,ot),u(v,st),u(v,Oe)),ae.mathMl===!0&&(u(b,at),u(v,$t),u(v,Oe))),F(e,"ADD_TAGS")||(Z.tagCheck=null),F(e,"ADD_ATTR")||(Z.attributeCheck=null),e.ADD_TAGS&&(typeof e.ADD_TAGS=="function"?Z.tagCheck=e.ADD_TAGS:(b===ft&&(b=G(b)),u(b,e.ADD_TAGS,S))),e.ADD_ATTR&&(typeof e.ADD_ATTR=="function"?Z.attributeCheck=e.ADD_ATTR:(v===mt&&(v=G(v)),u(v,e.ADD_ATTR,S))),e.ADD_URI_SAFE_ATTR&&u(je,e.ADD_URI_SAFE_ATTR,S),e.FORBID_CONTENTS&&(z===Ye&&(z=G(z)),u(z,e.FORBID_CONTENTS,S)),e.ADD_FORBID_CONTENTS&&(z===Ye&&(z=G(z)),u(z,e.ADD_FORBID_CONTENTS,S)),$e&&(b["#text"]=!0),Q&&u(b,["html","head","body"]),b.table&&(u(b,["tbody"]),delete fe.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!="function")throw Te('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Te('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');f=e.TRUSTED_TYPES_POLICY,c=f.createHTML("")}else f===void 0&&(f=Qn($,l)),f!==null&&typeof c=="string"&&(c=f.createHTML(""));C&&C(e),re=e}},St=u({},[...nt,...ot,...Gn]),bt=u({},[...at,...Wn]),dn=function(e){let t=V(e);(!t||!t.tagName)&&(t={namespaceURI:se,tagName:"template"});const o=Ie(e.tagName),g=Ie(t.tagName);return Xe[e.namespaceURI]?e.namespaceURI===Re?t.namespaceURI===Y?o==="svg":t.namespaceURI===ve?o==="svg"&&(g==="annotation-xml"||we[g]):!!St[o]:e.namespaceURI===ve?t.namespaceURI===Y?o==="math":t.namespaceURI===Re?o==="math"&&Le[g]:!!bt[o]:e.namespaceURI===Y?t.namespaceURI===Re&&!Le[g]||t.namespaceURI===ve&&!we[g]?!1:!bt[o]&&(un[o]||!St[o]):!!(pe==="application/xhtml+xml"&&Xe[e.namespaceURI]):!1},B=function(e){ge(n.removed,{element:e});try{V(e).removeChild(e)}catch{ke(e)}},ee=function(e,t){try{ge(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch{ge(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),e==="is")if(oe||be)try{B(t)}catch{}else try{t.setAttribute(e,"")}catch{}},xt=function(e){let t=null,o=null;if(We)e="<remove></remove>"+e;else{const E=tt(e,/^[\r\n\t ]+/);o=E&&E[0]}pe==="application/xhtml+xml"&&se===Y&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const g=f?f.createHTML(e):e;if(se===Y)try{t=new ue().parseFromString(g,pe)}catch{}if(!t||!t.documentElement){t=I.createDocument(se,"template",null);try{t.documentElement.innerHTML=qe?c:g}catch{}}const L=t.body||t.documentElement;return e&&o&&L.insertBefore(i.createTextNode(o),L.childNodes[0]||null),se===Y?tn.call(t,Q?"html":"body")[0]:Q?t.documentElement:L},vt=function(e){return K.call(e.ownerDocument||e,e,A.SHOW_ELEMENT|A.SHOW_COMMENT|A.SHOW_TEXT|A.SHOW_PROCESSING_INSTRUCTION|A.SHOW_CDATA_SECTION,null)},Ke=function(e){return e instanceof ce&&(typeof e.nodeName!="string"||typeof e.textContent!="string"||typeof e.removeChild!="function"||!(e.attributes instanceof P)||typeof e.removeAttribute!="function"||typeof e.setAttribute!="function"||typeof e.namespaceURI!="string"||typeof e.insertBefore!="function"||typeof e.hasChildNodes!="function")},Rt=function(e){return typeof k=="function"&&e instanceof k};function j(r,e,t){De(r,o=>{o.call(n,e,t,re)})}const wt=function(e){let t=null;if(j(D.beforeSanitizeElements,e,null),Ke(e))return B(e),!0;const o=S(e.nodeName);if(j(D.uponSanitizeElement,e,{tagName:o,allowedTags:b}),Se&&e.hasChildNodes()&&!Rt(e.firstElementChild)&&O(/<[/\w!]/g,e.innerHTML)&&O(/<[/\w!]/g,e.textContent)||e.nodeType===Ee.progressingInstruction||Se&&e.nodeType===Ee.comment&&O(/<[/\w]/g,e.data))return B(e),!0;if(!(Z.tagCheck instanceof Function&&Z.tagCheck(o))&&(!b[o]||fe[o])){if(!fe[o]&&Dt(o)&&(T.tagNameCheck instanceof RegExp&&O(T.tagNameCheck,o)||T.tagNameCheck instanceof Function&&T.tagNameCheck(o)))return!1;if($e&&!z[o]){const g=V(e)||e.parentNode,L=Ue(e)||e.childNodes;if(L&&g){const E=L.length;for(let M=E-1;M>=0;--M){const q=Me(L[M],!0);q.__removalCount=(e.__removalCount||0)+1,g.insertBefore(q,Pe(e))}}}return B(e),!0}return e instanceof w&&!dn(e)||(o==="noscript"||o==="noembed"||o==="noframes")&&O(/<\/no(script|embed|frames)/i,e.innerHTML)?(B(e),!0):(ne&&e.nodeType===Ee.text&&(t=e.textContent,De([Fe,He,ze],g=>{t=he(t,g," ")}),e.textContent!==t&&(ge(n.removed,{element:e.cloneNode()}),e.textContent=t)),j(D.afterSanitizeElements,e,null),!1)},Lt=function(e,t,o){if(ye[t]||gt&&(t==="id"||t==="name")&&(o in i||o in pn))return!1;if(!(Be&&!ye[t]&&O(on,t))){if(!(pt&&O(an,t))){if(!(Z.attributeCheck instanceof Function&&Z.attributeCheck(t,e))){if(!v[t]||ye[t]){if(!(Dt(e)&&(T.tagNameCheck instanceof RegExp&&O(T.tagNameCheck,e)||T.tagNameCheck instanceof Function&&T.tagNameCheck(e))&&(T.attributeNameCheck instanceof RegExp&&O(T.attributeNameCheck,t)||T.attributeNameCheck instanceof Function&&T.attributeNameCheck(t,e))||t==="is"&&T.allowCustomizedBuiltInElements&&(T.tagNameCheck instanceof RegExp&&O(T.tagNameCheck,o)||T.tagNameCheck instanceof Function&&T.tagNameCheck(o))))return!1}else if(!je[t]){if(!O(ut,he(o,ct,""))){if(!((t==="src"||t==="xlink:href"||t==="href")&&e!=="script"&&Fn(o,"data:")===0&&Tt[e])){if(!(dt&&!O(sn,he(o,ct,"")))){if(o)return!1}}}}}}}return!0},Dt=function(e){return e!=="annotation-xml"&&tt(e,rn)},Ot=function(e){j(D.beforeSanitizeAttributes,e,null);const{attributes:t}=e;if(!t||Ke(e))return;const o={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:v,forceKeepAttr:void 0};let g=t.length;for(;g--;){const L=t[g],{name:E,namespaceURI:M,value:q}=L,ie=S(E),Ze=q;let R=E==="value"?Ze:Hn(Ze);if(o.attrName=ie,o.attrValue=R,o.keepAttr=!0,o.forceKeepAttr=void 0,j(D.uponSanitizeAttribute,e,o),R=o.attrValue,ht&&(ie==="id"||ie==="name")&&(ee(E,e),R=ln+R),Se&&O(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,R)){ee(E,e);continue}if(ie==="attributename"&&tt(R,"href")){ee(E,e);continue}if(o.forceKeepAttr)continue;if(!o.keepAttr){ee(E,e);continue}if(!_t&&O(/\/>/i,R)){ee(E,e);continue}ne&&De([Fe,He,ze],Nt=>{R=he(R,Nt," ")});const Ct=S(e.nodeName);if(!Lt(Ct,ie,R)){ee(E,e);continue}if(f&&typeof $=="object"&&typeof $.getAttributeType=="function"&&!M)switch($.getAttributeType(Ct,ie)){case"TrustedHTML":{R=f.createHTML(R);break}case"TrustedScriptURL":{R=f.createScriptURL(R);break}}if(R!==Ze)try{M?e.setAttributeNS(M,E,R):e.setAttribute(E,R),Ke(e)?B(e):zt(n.removed)}catch{ee(E,e)}}j(D.afterSanitizeAttributes,e,null)},_n=function r(e){let t=null;const o=vt(e);for(j(D.beforeSanitizeShadowDOM,e,null);t=o.nextNode();)j(D.uponSanitizeShadowNode,t,null),wt(t),Ot(t),t.content instanceof _&&r(t.content);j(D.afterSanitizeShadowDOM,e,null)};return n.sanitize=function(r){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=null,o=null,g=null,L=null;if(qe=!r,qe&&(r="<!-->"),typeof r!="string"&&!Rt(r))if(typeof r.toString=="function"){if(r=r.toString(),typeof r!="string")throw Te("dirty is not a string, aborting")}else throw Te("toString is not a function");if(!n.isSupported)return r;if(Ge||Ve(e),n.removed=[],typeof r=="string"&&(me=!1),me){if(r.nodeName){const q=S(r.nodeName);if(!b[q]||fe[q])throw Te("root node is forbidden and cannot be sanitized in-place")}}else if(r instanceof k)t=xt("<!---->"),o=t.ownerDocument.importNode(r,!0),o.nodeType===Ee.element&&o.nodeName==="BODY"||o.nodeName==="HTML"?t=o:t.appendChild(o);else{if(!oe&&!ne&&!Q&&r.indexOf("<")===-1)return f&&xe?f.createHTML(r):r;if(t=xt(r),!t)return oe?null:xe?c:""}t&&We&&B(t.firstChild);const E=vt(me?r:t);for(;g=E.nextNode();)wt(g),Ot(g),g.content instanceof _&&_n(g.content);if(me)return r;if(oe){if(be)for(L=y.call(t.ownerDocument);t.firstChild;)L.appendChild(t.firstChild);else L=t;return(v.shadowroot||v.shadowrootmode)&&(L=nn.call(s,L,!0)),L}let M=Q?t.outerHTML:t.innerHTML;return Q&&b["!doctype"]&&t.ownerDocument&&t.ownerDocument.doctype&&t.ownerDocument.doctype.name&&O(Qt,t.ownerDocument.doctype.name)&&(M="<!DOCTYPE "+t.ownerDocument.doctype.name+`>
|
|
12
|
+
`+M),ne&&De([Fe,He,ze],q=>{M=he(M,q," ")}),f&&xe?f.createHTML(M):M},n.setConfig=function(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ve(r),Ge=!0},n.clearConfig=function(){re=null,Ge=!1},n.isValidAttribute=function(r,e,t){re||Ve({});const o=S(r),g=S(e);return Lt(o,g,t)},n.addHook=function(r,e){typeof e=="function"&&ge(D[r],e)},n.removeHook=function(r,e){if(e!==void 0){const t=Pn(D[r],e);return t===-1?void 0:Un(D[r],t,1)[0]}return zt(D[r])},n.removeHooks=function(r){D[r]=[]},n.removeAllHooks=function(){D=jt()},n}var eo=en();const qt=/^(#[0-9a-fA-F]{3,8}|rgb(a)?\([^)]{1,64}\)|hsl(a)?\([^)]{1,64}\)|var\(--[a-zA-Z0-9-_]+\))$/,to=/^(https?:|mailto:|tel:|\/|#)/i;function no(a){var s;const n=((s=a.getAttribute("href"))==null?void 0:s.trim())||"";if(!n||!to.test(n)){a.removeAttribute("href"),a.removeAttribute("target"),a.removeAttribute("rel");return}/^https?:/i.test(n)?(a.setAttribute("target","_blank"),a.setAttribute("rel","noopener noreferrer nofollow")):(a.removeAttribute("target"),a.removeAttribute("rel"))}function oo(a){const n=a.style.color.trim(),i=a.style.backgroundColor.trim(),s=[];n&&qt.test(n)&&s.push(`color: ${n}`),i&&qt.test(i)&&s.push(`background-color: ${i}`),s.length>0?a.setAttribute("style",s.join("; ")):a.removeAttribute("style")}function ao(a){var w;const n=eo.sanitize(a||"",{USE_PROFILES:{html:!0},FORBID_TAGS:["script","style","iframe","object","embed"],ADD_ATTR:["target","rel","style","data-color","class"]});if(typeof window>"u"||typeof DOMParser>"u")return{html:n,plainText:"",headings:[],readingMinutes:1};const l=new DOMParser().parseFromString(`<div data-announcement-root="true">${n}</div>`,"text/html").body.querySelector('[data-announcement-root="true"]');if(!l)return{html:n,plainText:"",headings:[],readingMinutes:1};l.querySelectorAll("[style]").forEach(oo),l.querySelectorAll("a").forEach(no),l.querySelectorAll('[data-type="taskItem"] > label input[type="checkbox"]').forEach(A=>{A.disabled=!0,A.tabIndex=-1,A.setAttribute("aria-disabled","true")});const _=[];l.querySelectorAll("h1, h2, h3, h4").forEach((A,P)=>{var U;const ce=((U=A.textContent)==null?void 0:U.replace(/\s+/g," ").trim())||`章节 ${P+1}`,ue=Number(A.tagName.slice(1)),$=`announcement-heading-${P+1}`;A.id=$,A.dataset.announcementHeading="true",_.push({id:$,text:ce,level:ue})});const h=((w=l.textContent)==null?void 0:w.replace(/\s+/g," ").trim())||"",k=Math.max(1,Math.ceil(h.length/320));return{html:l.innerHTML,plainText:h,headings:_,readingMinutes:k}}const so=["innerHTML"],ro=lt({__name:"AnnouncementHtmlContent",props:{html:{}},setup(a){return(n,i)=>(W(),le("article",{class:"announcement-content",innerHTML:a.html},null,8,so))}}),io={class:"space-y-1.5"},lo=["onClick"],co={class:"line-clamp-2 block"},uo=lt({__name:"AnnouncementTocCard",props:{headings:{},activeId:{}},emits:["select"],setup(a,{emit:n}){const i=a,s=n;function l(h){switch(h){case 1:return"pl-3.5";case 2:return"pl-7";case 3:return"pl-10";default:return"pl-12"}}function _(h){return h===1?"font-medium":"font-normal"}return(h,k)=>(W(),Ce(m(Dn),{class:"max-h-[360px] pr-2"},{default:x(()=>[p("div",io,[(W(!0),le(Kt,null,vn(i.headings,w=>(W(),le("button",{key:w.id,type:"button",class:Rn(["block w-full rounded-md px-3.5 py-2.5 text-left text-sm leading-5 transition-colors duration-150",[l(w.level),_(w.level),i.activeId===w.id?"bg-muted text-foreground":"text-muted-foreground hover:bg-muted/35 hover:text-foreground"]]),onClick:A=>s("select",w.id)},[p("span",co,X(w.text),1)],10,lo))),128))])]),_:1}))}}),fo={class:"mx-auto flex w-full max-w-7xl flex-col gap-5"},mo={key:0,class:"space-y-4"},po={class:"grid gap-6 xl:grid-cols-[minmax(0,1fr)_280px]"},_o={class:"mt-2 text-sm text-muted-foreground"},go={class:"space-y-3"},ho={class:"flex flex-wrap items-center gap-x-3 gap-y-2 border-b border-border/50 bg-background/30 px-5 py-3.5 text-[11px] text-muted-foreground sm:px-6 sm:text-xs"},To={class:"inline-flex items-center gap-1"},Ao={class:"inline-flex items-center gap-1"},Eo={class:"space-y-3 px-5 py-5 sm:px-6 sm:py-6"},yo={class:"break-words text-xl font-semibold leading-tight tracking-tight text-foreground sm:text-2xl"},So={class:"break-words text-sm leading-6 text-muted-foreground"},bo={class:"grid gap-6 xl:grid-cols-[minmax(0,1fr)_280px] xl:items-start"},xo={class:"min-w-0"},vo={class:"space-y-4 self-start xl:sticky xl:top-24"},Ro={class:"overflow-hidden rounded-xl border border-border/60 bg-background/40"},wo={class:"flex items-center justify-between gap-4 px-4 py-3.5"},Lo={class:"text-sm font-semibold text-foreground"},Do={class:"flex items-center justify-between gap-4 px-4 py-3.5"},Oo={class:"text-sm font-semibold text-foreground"},Co={class:"flex items-start justify-between gap-4 px-4 py-3.5"},No={class:"text-right text-xs font-medium leading-5 text-foreground sm:text-sm"},Xt=140,Bo=lt({__name:"AnnouncementDetail",setup(a){const n=gn(),i=hn(),s=yn(),l=_e(null),_=_e(!1),h=_e(""),k=_e(""),w=_e(null);let A=0;s.hydrate();const P=Je(()=>{var f;return ao(((f=l.value)==null?void 0:f.content_html)||"")}),ce=Je(()=>P.value.readingMinutes),ue=Je(()=>P.value.headings.length>1);function $(){const f=w.value;return f?P.value.headings.map(c=>{const I=f.querySelector(`#${c.id}`);return I?{id:c.id,top:I.getBoundingClientRect().top+window.scrollY}:null}).filter(c=>c!==null):[]}function U(){if(P.value.headings.length===0){k.value="";return}const f=$();if(f.length===0){k.value="";return}const c=window.scrollY+Xt,I=f.reduce((K,y)=>y.top<=c?y.id:K,f[0].id);k.value=I}function Me(f){const c=w.value;if(!c)return;const I=c.querySelector(`#${f}`);if(!I)return;const K=I.getBoundingClientRect().top+window.scrollY-(Xt-20);window.scrollTo({top:Math.max(0,K),behavior:"smooth"}),k.value=f}async function ke(){var c,I,K;const f=++A;_.value=!0,h.value="";try{const y=await An.getById(n.params.id);if(f!==A)return;l.value=y,s.trackAnnouncements([y]),s.markAsRead(y.id,y),await Ft(),window.scrollTo({top:0,behavior:"auto"}),U()}catch(y){f===A&&(l.value=null,h.value=((I=(c=y==null?void 0:y.response)==null?void 0:c.data)==null?void 0:I.error)||(y==null?void 0:y.message)||"请稍后重试",((K=y==null?void 0:y.response)==null?void 0:K.status)!==404&&En.error("加载公告失败",h.value))}finally{f===A&&(_.value=!1)}}const{reload:Pe}=On(async()=>{await ke()},{resetBeforeLoad:()=>{_.value=!0,l.value=null,h.value="",k.value=""}});function Ue(){if(window.history.length>1){i.back();return}i.push({name:"announcements"})}function V(f){return new Date(f).toLocaleString("zh-CN",{hour12:!1,year:"numeric",month:"numeric",day:"numeric",hour:"2-digit",minute:"2-digit"})}return Ut(()=>P.value.html,async()=>{await Ft(),U()}),Ut(()=>n.params.id,()=>{Pe("route-change")}),wn(()=>{window.addEventListener("scroll",U,{passive:!0})}),Ln(()=>{window.removeEventListener("scroll",U)}),(f,c)=>(W(),le("div",fo,[_.value&&!l.value?(W(),le("div",mo,[c[0]||(c[0]=p("div",{class:"h-8 w-32 rounded-md bg-muted/70 animate-pulse"},null,-1)),d(m(J),{class:"glass min-h-[180px] animate-pulse"}),p("div",po,[d(m(J),{class:"glass min-h-[60vh] animate-pulse"}),d(m(J),{class:"glass hidden min-h-[280px] animate-pulse xl:block"})])])):h.value?(W(),Ce(m(J),{key:1,class:"glass shadow-none"},{default:x(()=>[d(m(de),{class:"py-16 text-center"},{default:x(()=>[d(m(Sn),{class:"mx-auto mb-3 h-10 w-10 text-muted-foreground/50"}),c[1]||(c[1]=p("h2",{class:"text-base font-medium"},"公告不存在或已禁用",-1)),p("p",_o,X(h.value),1)]),_:1})]),_:1})):l.value?(W(),le(Kt,{key:2},[p("div",go,[d(m(Tn),{variant:"ghost",size:"sm",class:"-ml-1.5 h-8 w-fit px-1.5 text-muted-foreground hover:text-foreground",onClick:Ue},{default:x(()=>[d(m(Cn),{class:"mr-1 h-3.5 w-3.5"}),c[2]||(c[2]=te("返回公告列表 ",-1))]),_:1}),d(m(J),{class:"glass overflow-hidden shadow-none"},{default:x(()=>[d(m(de),{class:"p-0"},{default:x(()=>[p("div",ho,[d(m(It),{variant:"outline",class:"rounded-full border-primary/20 bg-primary/10 text-[11px] text-primary"},{default:x(()=>[...c[3]||(c[3]=[te(" 系统公告 ",-1)])]),_:1}),l.value.is_pinned?(W(),Ce(m(It),{key:0,variant:"outline",class:"rounded-full border-orange-500/30 bg-orange-500/10 text-[11px] font-medium text-orange-600"},{default:x(()=>[d(m(bn),{class:"h-3 w-3"}),c[4]||(c[4]=te("置顶 ",-1))]),_:1})):Qe("",!0),p("span",To,[d(m(xn),{class:"h-3.5 w-3.5"}),te(" "+X(V(l.value.published_at)),1)]),p("span",Ao,[d(m(Nn),{class:"h-3.5 w-3.5"}),te(" 更新于 "+X(V(l.value.updated_at)),1)])]),p("div",Eo,[p("h1",yo,X(l.value.title),1),p("p",So,X(l.value.intro||"暂无简介"),1)])]),_:1})]),_:1})]),p("div",bo,[p("div",xo,[d(m(J),{class:"glass shadow-none"},{default:x(()=>[d(m(de),{class:"p-5 sm:p-6"},{default:x(()=>[p("div",{ref_key:"contentScrollElement",ref:w,class:"pr-1 sm:pr-2"},[d(ro,{html:P.value.html},null,8,["html"])],512)]),_:1})]),_:1})]),p("div",vo,[ue.value?(W(),Ce(m(J),{key:0,class:"glass overflow-hidden shadow-none"},{default:x(()=>[d(m(Mt),{class:"pb-3"},{default:x(()=>[d(m(kt),{class:"text-sm sm:text-base"},{default:x(()=>[...c[5]||(c[5]=[te("章节定位",-1)])]),_:1})]),_:1}),d(m(de),{class:"pt-0"},{default:x(()=>[d(uo,{headings:P.value.headings,"active-id":k.value,onSelect:Me},null,8,["headings","active-id"])]),_:1})]),_:1})):Qe("",!0),d(m(J),{class:"glass overflow-hidden shadow-none"},{default:x(()=>[d(m(Mt),{class:"pb-3"},{default:x(()=>[d(m(kt),{class:"text-sm sm:text-base"},{default:x(()=>[...c[6]||(c[6]=[te("文章信息",-1)])]),_:1})]),_:1}),d(m(de),{class:"pt-0"},{default:x(()=>[p("div",Ro,[p("div",wo,[c[7]||(c[7]=p("p",{class:"text-xs font-medium text-muted-foreground"},"阅读时长",-1)),p("p",Lo,X(ce.value)+" 分钟",1)]),d(m(Pt),{class:"opacity-60"}),p("div",Do,[c[8]||(c[8]=p("p",{class:"text-xs font-medium text-muted-foreground"},"章节数",-1)),p("p",Oo,X(P.value.headings.length)+" 个章节",1)]),d(m(Pt),{class:"opacity-60"}),p("div",Co,[c[9]||(c[9]=p("p",{class:"pt-0.5 text-xs font-medium text-muted-foreground"},"最后更新",-1)),p("p",No,X(V(l.value.updated_at)),1)])])]),_:1})]),_:1})])])],64)):Qe("",!0)]))}});export{Bo as default};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import{c as I,a0 as J,J as A,A as U,_ as H,ay as Q,t as G}from"./index-Da98HOxL.js";import{_ as y,a as w}from"./CardContent.vue_vue_type_script_setup_true_lang-D2L-uqSl.js";import{a as K,_ as O}from"./CardTitle.vue_vue_type_script_setup_true_lang-a0CCN6D5.js";import{_ as W}from"./CardDescription.vue_vue_type_script_setup_true_lang-D-v5Pl7F.js";import{u as X,M as j,P as Y,C as Z}from"./announcement-35mOnjRL.js";import{a as ee}from"./useUserPageRefresh-BYZvpNR9.js";import{R as te}from"./refresh-cw-Y9hCloPL.js";import{j as se,r as f,d as ae,x as u,A as t,H as a,E as l,u as s,y as d,Q as c,P as m,z as k,F as $,B as T,D as C,J as oe}from"./chart-vendor-CULJE59K.js";/**
|
|
2
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const ne=I("BellRingIcon",[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M22 8c0-2.3-.8-4.3-2-6",key:"5bb3ad"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}],["path",{d:"M4 2C2.8 3.7 2 5.7 2 8",key:"tap9e0"}]]);/**
|
|
7
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the ISC license.
|
|
10
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/const re=I("Clock3Icon",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16.5 12",key:"1aq6pp"}]]),le={class:"mx-auto flex w-full max-w-7xl flex-col gap-5"},de={class:"grid gap-4 sm:grid-cols-2 xl:grid-cols-3"},ie={class:"flex items-start gap-4 sm:items-center"},ue={class:"min-w-0 flex-1"},ce={class:"mt-1.5 text-xl font-semibold text-foreground sm:text-2xl"},me={class:"flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-chart-1/10"},fe={class:"flex items-start gap-4 sm:items-center"},xe={class:"min-w-0 flex-1"},ge={class:"mt-1.5 text-xl font-semibold text-foreground sm:text-2xl"},_e={class:"flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-destructive/10"},pe={class:"flex items-start gap-4 sm:items-center"},be={class:"min-w-0 flex-1"},ve={class:"mt-1.5 text-sm font-semibold leading-6 text-foreground sm:text-base"},he={class:"flex h-10 w-10 shrink-0 items-center justify-center rounded-lg bg-chart-2/10"},ye={key:0,class:"min-h-96 overflow-hidden rounded-xl border border-border/60 bg-background/40"},we={key:1,class:"flex min-h-96 flex-col items-center justify-center rounded-xl border border-dashed border-border/70 bg-background/40 py-14 text-center"},ke={class:"mb-4 flex h-12 w-12 items-center justify-center rounded-xl border border-border/60 bg-background/80 text-destructive"},Ce={class:"mt-2 max-w-md text-sm leading-6 text-muted-foreground"},Ae={key:2,class:"flex min-h-96 flex-col items-center justify-center rounded-xl border border-dashed border-border/70 bg-background/40 py-14 text-center"},je={class:"mb-4 flex h-12 w-12 items-center justify-center rounded-xl border border-border/60 bg-background/80 text-primary"},De={key:3,class:"overflow-hidden rounded-xl border border-border/60 bg-background/40"},Me={class:"flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between sm:gap-6"},Re={class:"min-w-0 flex-1 space-y-2"},Be={class:"flex flex-wrap items-center gap-2 text-[11px] text-muted-foreground sm:text-xs"},Le={class:"inline-flex items-center gap-1 text-muted-foreground"},Se={class:"space-y-1.5"},$e={class:"break-words text-sm font-medium leading-6 text-foreground transition-colors group-hover:text-foreground sm:text-base"},Te={class:"break-words text-xs leading-6 text-muted-foreground sm:text-sm"},Ie={class:"hidden shrink-0 items-center gap-1.5 text-xs font-medium text-muted-foreground transition-colors group-hover:text-foreground sm:inline-flex"},Ne={key:4,class:"flex justify-center pt-5"},Pe={key:1},qe={key:2},Ke=se({__name:"Announcements",setup(Ve){const _=X(),i=f([]),p=f(!1),b=f(!1),v=f(""),x=f(!1),g=f("");let h=0;_.hydrate();function N(n,e){if(n.is_pinned!==e.is_pinned)return n.is_pinned?-1:1;const o=new Date(e.published_at).getTime()-new Date(n.published_at).getTime();return o!==0?o:e.id.localeCompare(n.id)}function P(n){return[...n].sort(N)}const q=ae(()=>{if(i.value.length===0)return"暂无公告";const n=i.value.reduce((e,o)=>e?new Date(o.published_at).getTime()>new Date(e).getTime()?o.published_at:e:o.published_at,"");return n?M(n):"暂无公告"});async function D(n=!1){var o,R,B,L;const e=++h;n?b.value=!0:p.value=!0;try{const r=await Q.getList({cursor:n?v.value:void 0,limit:10}),F=n?[...i.value,...r.items]:r.items,S=P(F);if(e!==h)return;_.trackAnnouncements(S),i.value=S,v.value=r.next_cursor||"",x.value=r.has_more,g.value=""}catch(r){e===h&&(g.value=((R=(o=r==null?void 0:r.response)==null?void 0:o.data)==null?void 0:R.error)||(r==null?void 0:r.message)||"请稍后重试",G.error("加载公告失败",((L=(B=r==null?void 0:r.response)==null?void 0:B.data)==null?void 0:L.error)||(r==null?void 0:r.message)||"请稍后重试"))}finally{e===h&&(p.value=!1,b.value=!1)}}ee(async()=>{await D(!1)},{resetBeforeLoad:()=>{p.value=!0,i.value=[],v.value="",x.value=!1,g.value=""}});async function V(){!x.value||!v.value||await D(!0)}function M(n){return new Date(n).toLocaleString("zh-CN",{hour12:!1})}function z(n){return!_.isAnnouncementRead(n)}function E(n){return"hover:bg-muted/35"}return(n,e)=>(d(),u("div",le,[t("div",de,[a(s(w),{class:"glass shadow-none"},{default:l(()=>[a(s(y),{class:"p-5"},{default:l(()=>[t("div",ie,[t("div",ue,[e[0]||(e[0]=t("p",{class:"text-xs font-medium text-muted-foreground"},"已发布公告",-1)),t("h3",ce,c(i.value.length),1)]),t("div",me,[a(s(j),{class:"h-5 w-5 text-chart-1"})])])]),_:1})]),_:1}),a(s(w),{class:"glass shadow-none"},{default:l(()=>[a(s(y),{class:"p-5"},{default:l(()=>[t("div",fe,[t("div",xe,[e[1]||(e[1]=t("p",{class:"text-xs font-medium text-muted-foreground"},"未读公告",-1)),t("h3",ge,c(s(_).unreadCount),1)]),t("div",_e,[a(s(ne),{class:"h-5 w-5 text-destructive"})])])]),_:1})]),_:1}),a(s(w),{class:"glass shadow-none sm:col-span-2 xl:col-span-1"},{default:l(()=>[a(s(y),{class:"p-5"},{default:l(()=>[t("div",pe,[t("div",be,[e[2]||(e[2]=t("p",{class:"text-xs font-medium text-muted-foreground"},"最新发布时间",-1)),t("h3",ve,c(q.value),1)]),t("div",he,[a(s(re),{class:"h-5 w-5 text-chart-2"})])])]),_:1})]),_:1})]),a(s(w),{class:"glass shadow-none"},{default:l(()=>[a(s(K),{class:"pb-4"},{default:l(()=>[a(s(O),{class:"text-base sm:text-lg"},{default:l(()=>[...e[3]||(e[3]=[m("公告列表",-1)])]),_:1}),a(s(W),{class:"text-xs sm:text-sm"},{default:l(()=>[...e[4]||(e[4]=[m("置顶公告优先展示,其余公告按发布时间倒序排列",-1)])]),_:1})]),_:1}),a(s(y),null,{default:l(()=>[p.value&&i.value.length===0?(d(),u("div",ye,[(d(),u($,null,T(3,o=>t("div",{key:o,class:"animate-pulse space-y-3 border-b border-border/60 px-4 py-4 last:border-b-0 sm:px-5"},[...e[5]||(e[5]=[t("div",{class:"flex items-center gap-2"},[t("div",{class:"h-5 w-16 rounded-full bg-muted"}),t("div",{class:"h-3 w-28 rounded-full bg-muted"})],-1),t("div",{class:"h-4 w-2/5 rounded bg-muted"},null,-1),t("div",{class:"h-3 w-full rounded bg-muted"},null,-1),t("div",{class:"h-3 w-3/4 rounded bg-muted"},null,-1)])])),64))])):g.value&&i.value.length===0?(d(),u("div",we,[t("div",ke,[a(s(j),{class:"h-5 w-5"})]),e[6]||(e[6]=t("h2",{class:"text-base font-semibold"},"公告加载失败",-1)),t("p",Ce,c(g.value),1)])):i.value.length===0?(d(),u("div",Ae,[t("div",je,[a(s(j),{class:"h-5 w-5"})]),e[7]||(e[7]=t("h2",{class:"text-base font-semibold"},"暂时还没有公告",-1)),e[8]||(e[8]=t("p",{class:"mt-2 max-w-md text-sm leading-6 text-muted-foreground"}," 当前没有已发布的公告内容,稍后再来看看吧。 ",-1))])):(d(),u("div",De,[(d(!0),u($,null,T(i.value,o=>(d(),C(s(J),{key:o.id,to:{name:"announcement-detail",params:{id:o.id}},class:oe(["group block border-b border-border/60 px-4 py-4 transition-colors last:border-b-0 sm:px-5",E(o)])},{default:l(()=>[t("div",Me,[t("div",Re,[t("div",Be,[a(s(A),{variant:"outline",class:"rounded-full border-primary/20 bg-primary/10 text-[11px] text-primary"},{default:l(()=>[...e[9]||(e[9]=[m(" 系统公告 ",-1)])]),_:1}),o.is_pinned?(d(),C(s(A),{key:0,variant:"outline",class:"rounded-full border-orange-500/30 bg-orange-500/10 text-[11px] font-medium text-orange-600"},{default:l(()=>[a(s(Y),{class:"h-3 w-3"}),e[10]||(e[10]=m("置顶 ",-1))]),_:1})):k("",!0),z(o.id)?(d(),C(s(A),{key:1,variant:"outline",class:"rounded-full border-destructive/20 bg-destructive/10 text-[11px] text-destructive"},{default:l(()=>[...e[11]||(e[11]=[m(" 未读 ",-1)])]),_:1})):k("",!0),t("span",Le,[a(s(Z),{class:"h-3.5 w-3.5"}),m(" "+c(M(o.published_at)),1)])]),t("div",Se,[t("h2",$e,c(o.title),1),t("p",Te,c(o.intro||"暂无简介"),1)])]),t("div",Ie,[e[12]||(e[12]=m(" 查看详情 ",-1)),a(s(U),{class:"h-3.5 w-3.5 transition-transform group-hover:translate-x-0.5"})])])]),_:2},1032,["to","class"]))),128))])),i.value.length>0?(d(),u("div",Ne,[a(s(H),{variant:"outline",disabled:!x.value||b.value,onClick:V},{default:l(()=>[b.value?(d(),C(s(te),{key:0,class:"mr-2 h-4 w-4 animate-spin"})):k("",!0),x.value?(d(),u("span",Pe,"加载更多")):(d(),u("span",qe,"没有更多公告了"))]),_:1},8,["disabled"])])):k("",!0)]),_:1})]),_:1})]))}});export{Ke as default};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import{j as Xe,r as _,d as h,x,A as t,D as v,H as n,u as a,E as i,F as se,z as g,P as u,Q as d,y as r,I as Fe,J as P,B as ge,Z as Ge}from"./chart-vendor-CULJE59K.js";import{c as Z,u as Je,aq as Qe,L as K,ac as H,_ as k,aa as Oe,ar as _e,ag as ye,aj as he,J as q,$ as ke,ai as we,as as We,C as Ce,E as $e,G as qe,H as je,M as Ie,N as Ee,X as M,W as ae,a2 as Ze,at as X,t as w}from"./index-Da98HOxL.js";import{_ as D,a as S}from"./CardContent.vue_vue_type_script_setup_true_lang-D2L-uqSl.js";import{_ as Ye,E as et}from"./Input.vue_vue_type_script_setup_true_lang-B0SyPmYb.js";import{_ as le}from"./Progress.vue_vue_type_script_setup_true_lang-2_QbPsEQ.js";import{_ as tt}from"./Separator.vue_vue_type_script_setup_true_lang-Ckg8EXj_.js";import{a as st}from"./useUserPageRefresh-BYZvpNR9.js";import{L as Pe,P as Ke}from"./plus-CQc6C8wG.js";import{A as at}from"./activity-wYWtyqTJ.js";import{C as lt}from"./calendar-BFNuCata.js";import{L as ne}from"./link-2-DT5R5nGO.js";import{E as nt}from"./eye-CY62vip0.js";import{C as ot}from"./chevron-right-BayASIm0.js";import{C as it}from"./chevron-down-kDbuU1Py.js";/**
|
|
2
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const rt=Z("ArrowDownIcon",[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]]);/**
|
|
7
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the ISC license.
|
|
10
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/const dt=Z("ArrowUpIcon",[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]]);/**
|
|
12
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
13
|
+
*
|
|
14
|
+
* This source code is licensed under the ISC license.
|
|
15
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
16
|
+
*/const ut=Z("ListIcon",[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]]);/**
|
|
17
|
+
* @license lucide-vue-next v0.468.0 - ISC
|
|
18
|
+
*
|
|
19
|
+
* This source code is licensed under the ISC license.
|
|
20
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
21
|
+
*/const De=Z("UnlinkIcon",[["path",{d:"m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71",key:"yqzxt4"}],["path",{d:"m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71",key:"4qinb0"}],["line",{x1:"8",x2:"8",y1:"2",y2:"5",key:"1041cp"}],["line",{x1:"2",x2:"5",y1:"8",y2:"8",key:"14m1p5"}],["line",{x1:"16",x2:"16",y1:"19",y2:"22",key:"rzdirn"}],["line",{x1:"19",x2:"22",y1:"16",y2:"16",key:"ox905f"}]]),ct={class:"max-w-7xl mx-auto space-y-6"},mt={key:0,class:"flex items-center justify-center py-20"},ft={class:"mx-auto max-w-md text-center space-y-4"},vt={class:"w-14 h-14 rounded-2xl bg-red-500/10 flex items-center justify-center mx-auto"},pt={class:"space-y-2"},xt={class:"text-sm text-muted-foreground"},bt={key:0,class:"rounded-lg border border-blue-200 dark:border-blue-500/20 bg-blue-50 dark:bg-blue-500/5 p-4"},gt={class:"flex gap-3"},_t={class:"shrink-0 mt-0.5"},yt={class:"text-sm"},ht={class:"font-medium text-blue-800 dark:text-blue-400"},kt={class:"font-mono"},wt={key:1,class:"rounded-lg border border-red-200 dark:border-red-500/20 bg-red-50 dark:bg-red-500/5 p-4"},Ct={class:"flex gap-3"},$t={class:"shrink-0 mt-0.5"},qt={key:2,class:"rounded-lg border border-amber-200 dark:border-amber-500/20 bg-amber-50 dark:bg-amber-500/5 p-4"},jt={class:"flex gap-3"},It={class:"shrink-0 mt-0.5"},Et={class:"flex items-center gap-2 text-base font-semibold"},Pt={class:"w-8 h-8 rounded-lg bg-primary/10 flex items-center justify-center"},Kt={class:"grid grid-cols-2 lg:grid-cols-4 gap-4"},Dt={class:"rounded-xl border border-border/60 bg-muted/20 p-4"},St={class:"flex items-center justify-between mb-2"},Ut={class:"relative flex items-center justify-center"},Bt={class:"w-10 h-10 -rotate-90"},Mt={class:"absolute text-[9px] font-bold text-primary"},At={class:"text-lg font-bold tabular-nums"},zt={class:"text-xs text-muted-foreground mt-0.5"},Vt={class:"rounded-xl border border-border/60 bg-muted/20 p-4"},Lt={class:"flex items-center justify-between mb-2"},Nt={class:"w-10 h-10 rounded-lg bg-emerald-500/10 flex items-center justify-center"},Rt={class:"text-lg font-bold tabular-nums"},Tt={class:"text-sm text-muted-foreground font-normal"},Ht={class:"rounded-xl border border-border/60 bg-muted/20 p-4"},Xt={class:"flex items-center justify-between mb-2"},Ft={class:"w-10 h-10 rounded-lg bg-amber-500/10 flex items-center justify-center"},Gt={class:"text-lg font-bold tabular-nums"},Jt={class:"text-xs text-muted-foreground mt-0.5"},Qt={class:"rounded-xl border border-border/60 bg-muted/20 p-4"},Ot={class:"flex items-center justify-between mb-2"},Wt={class:"w-10 h-10 rounded-lg bg-blue-500/10 flex items-center justify-center"},Zt={class:"text-lg font-bold tabular-nums"},Yt={class:"text-xs text-muted-foreground mt-0.5"},es={class:"space-y-2"},ts={class:"flex items-center justify-between text-sm"},ss={class:"font-semibold tabular-nums"},as={class:"flex items-center gap-2 text-base font-semibold"},ls={class:"w-8 h-8 rounded-lg bg-primary/10 flex items-center justify-center"},ns={class:"relative"},os={class:"rounded-xl border border-border/60 bg-muted/20 p-4"},is={class:"flex items-start gap-3"},rs={class:"flex-1 min-w-0"},ds={class:"flex items-center gap-2 flex-wrap"},us={class:"font-mono text-sm font-medium"},cs={class:"mt-2 flex items-center gap-2 flex-wrap"},ms={class:"truncate"},fs={class:"border-t border-border/30 mt-2 pt-2 space-y-1.5"},vs={class:"flex items-center justify-between gap-2 text-xs"},ps={class:"text-muted-foreground"},xs={class:"flex items-center gap-3"},bs={class:"flex-1"},gs={class:"text-xs font-medium tabular-nums text-muted-foreground"},_s={key:0},ys={class:"flex items-start gap-3"},hs={class:"w-7 h-7 rounded-full bg-muted flex items-center justify-center text-xs font-bold text-muted-foreground shrink-0 mt-0.5"},ks={class:"flex-1 min-w-0"},ws={class:"flex items-center justify-between gap-2"},Cs={class:"flex items-center gap-2 flex-wrap min-w-0"},$s={class:"font-mono text-sm"},qs={class:"flex items-center shrink-0"},js={class:"flex items-center gap-0.5"},Is={class:"mt-2 flex items-center gap-2 flex-wrap"},Es={class:"truncate"},Ps={key:0,class:"border-t border-border/30 mt-2 pt-2"},Ks={key:1,class:"border-t border-border/30 mt-2 pt-2 space-y-1.5"},Ds={class:"flex items-center justify-between gap-2 text-xs"},Ss={class:"text-muted-foreground"},Us={class:"flex items-center gap-3"},Bs={class:"flex-1"},Ms={class:"text-xs font-medium tabular-nums text-muted-foreground"},As={key:1,class:"text-xs text-muted-foreground flex items-center gap-1.5 mt-3 ml-10"},zs={class:"text-center"},Vs={class:"w-14 h-14 rounded-2xl bg-primary/10 flex items-center justify-center mx-auto mb-3"},Ls={class:"flex items-center gap-2 text-base font-semibold"},Ns={class:"w-8 h-8 rounded-lg bg-blue-500/10 flex items-center justify-center"},Rs={class:"rounded-xl border border-blue-200/60 dark:border-blue-500/20 bg-blue-50/50 dark:bg-blue-500/5 p-4"},Ts={class:"font-mono text-base font-semibold"},Hs={key:0,class:"mt-2 text-xs leading-5 text-amber-700 dark:text-amber-300"},Xs={class:"flex items-center justify-between gap-3 rounded-xl border border-border/60 bg-background/70 p-4"},Fs={class:"flex items-center gap-2 text-base font-semibold"},Gs={class:"w-8 h-8 rounded-lg bg-emerald-500/10 flex items-center justify-center"},Js={class:"flex gap-2"},Qs={class:"relative flex-1"},Os={key:0,class:"space-y-3"},Ws={class:"text-sm font-medium text-muted-foreground"},Zs={class:"flex flex-wrap gap-2"},Ys={class:"font-mono text-xs"},ea=["onClick"],ta={class:"font-mono font-medium"},sa={class:"font-mono font-medium"},Se=10,ga=Xe({__name:"CardBind",setup(aa){const F=Je(),C=_(null),A=_(!1),z=_(null),V=_(""),G=_(!1),y=_([]),U=_(!1),B=_(!1),j=_(!1),I=_(!1),L=_(!1),J=_(null),Y=_(""),N=_(!1),Q=_(!1),$=h(()=>F.apiKeyInfo),ee=h(()=>{var s;return((s=C.value)==null?void 0:s.role)||"independent"}),p=h(()=>{var s;return((s=C.value)==null?void 0:s.chain)||[]}),te=h(()=>{var s;return((s=C.value)==null?void 0:s.primary_key_preview)||""}),Ue=h(()=>{var s;return!!((s=C.value)!=null&&s.orphaned_primary)}),oe=h(()=>!!z.value&&!C.value),ie=h(()=>ee.value==="independent"),R=h(()=>ee.value==="primary"),re=h(()=>ee.value==="child"),E=h(()=>R.value?p.value.slice(1):[]),de=h(()=>y.value.length<Se),Be=h(()=>{var s,e;return!oe.value&&(ie.value||R.value)&&((s=$.value)==null?void 0:s.status)!=="disabled"&&((e=$.value)==null?void 0:e.status)!=="expired"}),b=h(()=>{var s;return!R.value||p.value.length===0?null:Qe(p.value,((s=$.value)==null?void 0:s.billing_type)||"quota")});function ue(s){return s==="active"?"border-emerald-200 bg-emerald-50 text-emerald-700 dark:border-emerald-800 dark:bg-emerald-950 dark:text-emerald-300":s==="disabled"?"border-red-200 bg-red-50 text-red-700 dark:border-red-800 dark:bg-red-950 dark:text-red-300":"border-border bg-muted text-muted-foreground"}function ce(s){return s.status_label?s.status_label:{active:"正常",disabled:"已禁用"}[s.status]||s.status}function me(s){var c;const e=s.billing_type||((c=$.value)==null?void 0:c.billing_type)||"";if(e==="duration"){const m=s.daily_remaining??0,l=s.daily_quota||0;let o=`今日剩余 ${M(m)} / ${M(l)} 每日`;const f=ae(s.quota_pack_expires_at)&&s.quota_pack_remaining||0;return f>0&&(o+=` · 配额包 ${M(f)}`),o}if(e==="quota"){const m=s.remaining_quota??0,l=s.total_quota??0;let o=`剩余 ${M(m)} / ${M(l)}`;const f=ae(s.quota_pack_expires_at)&&s.quota_pack_remaining||0;return f>0&&(o+=` · 配额包 ${M(f)}`),o}if(e==="count"){const m=s.remaining_requests??s.remaining_count??0,l=s.max_requests??0;let o=`剩余 ${m} / ${l} 次`;const f=ae(s.requests_pack_expires_at)&&s.requests_pack_remaining||0;return f>0&&(o+=` · 请求包 ${f} 次`),o}return"-"}function O(s){if(s.total_quota!==void 0&&s.total_quota>0){const e=s.remaining_quota||0;return Math.round((s.total_quota-e)/s.total_quota*100)}if(s.max_requests!==void 0&&s.max_requests>0){const e=s.remaining_requests??s.remaining_count??0;return Math.round((s.max_requests-e)/s.max_requests*100)}if(s.daily_quota!==void 0&&s.daily_quota>0){const e=s.daily_remaining??0;return Math.round((s.daily_quota-e)/s.daily_quota*100)}return 0}function fe(s){if(s.expires_at){const e=ye(s.expires_at);return e==="已过期"?"已过期":`${he(s.expires_at,"yyyy-MM-dd")} 到期 (${e})`}return s.validity_days&&s.validity_days>0?`${s.validity_days} 天(激活后计算)`:"永久有效"}function ve(s){if(!s.expires_at)return!1;const e=new Date(s.expires_at).getTime()-Date.now();return e>0&&e<7*86400*1e3}function pe(s){return s.status_label==="未激活"||!s.activated&&s.status!=="active"}function W(s){return Ze(s.service_type||"",s.sub_service_type_name)}async function Me({isLatest:s}){var e,c,m,l;A.value=!0;try{const o=await X.getBindInfo();if(!s())return;z.value=null,C.value=o}catch(o){if(s()){const f=((c=(e=o==null?void 0:o.response)==null?void 0:e.data)==null?void 0:c.message)||((l=(m=o==null?void 0:o.response)==null?void 0:m.data)==null?void 0:l.error)||(o==null?void 0:o.message)||"获取绑定信息失败";z.value=f,w.error("加载失败",f)}}finally{s()&&(A.value=!1)}}const{reload:T}=st(Me,{resetBeforeLoad:s=>{A.value=!0,(s==="initial"||s==="active-key-change"||s==="manual-refresh")&&(C.value=null),z.value=null}});function xe(){const s=V.value.trim();if(!s)return;if(y.value.includes(s)){w.warning("该卡已在列表中");return}const e=F.activeKey;if(e&&e.key===s){w.error("不能绑定自己");return}if(!de.value){w.warning(`单次最多绑定 ${Se} 张卡`);return}y.value.push(s),V.value=""}function Ae(s){y.value.splice(s,1)}async function ze(){var s,e,c,m;if(y.value.length!==0){U.value=!0;try{const l=await X.cardBind(y.value);w.success("绑定成功",l.message||`成功绑定 ${y.value.length} 张卡`),y.value=[],await F.fetchInfo(),await T("bind-mutation")}catch(l){const o=((e=(s=l==null?void 0:l.response)==null?void 0:s.data)==null?void 0:e.message)||((m=(c=l==null?void 0:l.response)==null?void 0:c.data)==null?void 0:m.error)||(l==null?void 0:l.message)||"绑定失败";w.error("绑定失败",o)}finally{U.value=!1}}}function Ve(s){J.value=s.id,Y.value=s.key_preview,L.value=!0}async function Le(){var s,e,c,m;if(J.value){B.value=!0;try{const l=await X.cardUnbind([J.value]);w.success("解绑成功",l.message||"已成功解绑"),L.value=!1,J.value=null,Y.value="",await T("unbind-mutation")}catch(l){const o=((e=(s=l==null?void 0:l.response)==null?void 0:s.data)==null?void 0:e.message)||((m=(c=l==null?void 0:l.response)==null?void 0:c.data)==null?void 0:m.error)||(l==null?void 0:l.message)||"解绑失败";w.error("解绑失败",o)}finally{B.value=!1}}}async function Ne(){var s,e,c,m;I.value=!0;try{const l=await X.cardUnbindSelf();w.success("解绑成功",l.message||"已从主卡解绑"),N.value=!1,await F.fetchInfo(),await T("unbind-self-mutation")}catch(l){const o=((e=(s=l==null?void 0:l.response)==null?void 0:s.data)==null?void 0:e.message)||((m=(c=l==null?void 0:l.response)==null?void 0:c.data)==null?void 0:m.error)||(l==null?void 0:l.message)||"解绑失败";w.error("解绑失败",o)}finally{I.value=!1}}async function Re(s){if(s<=0||j.value)return;const e=[...E.value],c=e[s];e[s]=e[s-1],e[s-1]=c,await be(e)}async function Te(s){if(s>=E.value.length-1||j.value)return;const e=[...E.value],c=e[s];e[s]=e[s+1],e[s+1]=c,await be(e)}async function be(s){var e,c,m,l;j.value=!0;try{const o=s.map(f=>f.id);await X.cardBindReorder(o),await T("reorder-mutation")}catch(o){const f=((c=(e=o==null?void 0:o.response)==null?void 0:e.data)==null?void 0:c.message)||((l=(m=o==null?void 0:o.response)==null?void 0:m.data)==null?void 0:l.error)||(o==null?void 0:o.message)||"排序失败";w.error("排序失败",f)}finally{j.value=!1}}function He(s){return s.length<=8?s:s.substring(0,6)+"****"+s.substring(s.length-4)}return(s,e)=>{var c,m;return r(),x("div",ct,[e[55]||(e[55]=t("div",{class:"space-y-1"},[t("h1",{class:"text-2xl font-semibold tracking-tight"},"叠卡"),t("p",{class:"text-sm text-muted-foreground"}," 管理 API Key 绑定关系,查看聚合资源池 ")],-1)),A.value&&!C.value?(r(),x("div",mt,[n(a(K),{class:"h-6 w-6 animate-spin text-muted-foreground"})])):oe.value?(r(),v(a(S),{key:1,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-8"},{default:i(()=>[t("div",ft,[t("div",vt,[n(a(H),{class:"h-7 w-7 text-red-500"})]),t("div",pt,[e[9]||(e[9]=t("h3",{class:"text-base font-semibold"},"绑定信息加载失败",-1)),t("p",xt,d(z.value),1),e[10]||(e[10]=t("p",{class:"text-xs text-muted-foreground"}," 当前无法确认这张卡的真实绑定状态,已暂时隐藏绑定入口,请稍后重试。 ",-1))]),n(a(k),{variant:"outline",onClick:e[0]||(e[0]=l=>a(T)("manual-refresh"))},{default:i(()=>[A.value?(r(),v(a(K),{key:0,class:"h-4 w-4 mr-2 animate-spin"})):g("",!0),e[11]||(e[11]=u(" 重新加载 ",-1))]),_:1})])]),_:1})]),_:1})):(r(),x(se,{key:2},[re.value?(r(),x("div",bt,[t("div",gt,[t("div",_t,[n(a(Oe),{class:"h-5 w-5 text-blue-500"})]),t("div",yt,[t("p",ht,[e[12]||(e[12]=u(" 此卡已绑定到主卡 ",-1)),t("span",kt,d(te.value),1),e[13]||(e[13]=u(",通过主卡消耗额度 ",-1))]),e[14]||(e[14]=t("p",{class:"mt-1 text-blue-700/80 dark:text-blue-400/70"}," 子卡不能独立消耗额度,所有请求将通过主卡的消耗链进行扣费。 ",-1))])])])):g("",!0),((c=$.value)==null?void 0:c.status)==="disabled"?(r(),x("div",wt,[t("div",Ct,[t("div",$t,[n(a(H),{class:"h-5 w-5 text-red-500"})]),e[15]||(e[15]=t("div",{class:"text-sm"},[t("p",{class:"font-medium text-red-800 dark:text-red-400"}," 当前 Key 已被禁用 "),t("p",{class:"mt-1 text-red-700/80 dark:text-red-400/70"}," 已禁用的 Key 无法进行绑定操作。 ")],-1))])])):((m=$.value)==null?void 0:m.status)==="expired"?(r(),x("div",qt,[t("div",jt,[t("div",It,[n(a(H),{class:"h-5 w-5 text-amber-500"})]),e[16]||(e[16]=t("div",{class:"text-sm"},[t("p",{class:"font-medium text-amber-800 dark:text-amber-400"}," 当前 Key 已过期 "),t("p",{class:"mt-1 text-amber-700/80 dark:text-amber-400/70"}," 已过期的 Key 无法进行绑定操作。 ")],-1))])])):g("",!0),R.value&&b.value?(r(),v(a(S),{key:3,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-6 space-y-5"},{default:i(()=>{var l,o;return[t("div",Et,[t("div",Pt,[n(a(Pe),{class:"h-4 w-4 text-primary"})]),e[17]||(e[17]=u(" 聚合资源概览 ",-1))]),t("div",Kt,[t("div",Dt,[t("div",St,[e[19]||(e[19]=t("p",{class:"text-xs text-muted-foreground font-medium"},"总额度",-1)),t("div",Ut,[(r(),x("svg",Bt,[e[18]||(e[18]=t("circle",{cx:"20",cy:"20",r:"16",stroke:"currentColor","stroke-width":"3",fill:"none",class:"text-primary/15"},null,-1)),t("circle",{cx:"20",cy:"20",r:"16",stroke:"currentColor","stroke-width":"3",fill:"none","stroke-linecap":"round",class:"text-primary",style:Fe({strokeDasharray:`${b.value.usagePercent*1.005} 100.5`,transition:"stroke-dasharray 600ms ease"})},null,4)])),t("span",Mt,d(b.value.usagePercent)+"%",1)])]),t("p",At,d(a(_e)(b.value.totalRemaining,((l=$.value)==null?void 0:l.billing_type)||"")),1),t("p",zt," / "+d(a(_e)(b.value.totalCapacity,((o=$.value)==null?void 0:o.billing_type)||"")),1)]),t("div",Vt,[t("div",Lt,[e[20]||(e[20]=t("p",{class:"text-xs text-muted-foreground font-medium"}," 活跃卡数 ",-1)),t("div",Nt,[n(a(at),{class:"h-4 w-4 text-emerald-500"})])]),t("p",Rt,[u(d(b.value.activeCount),1),t("span",Tt," / "+d(b.value.totalCount)+" 张",1)]),e[21]||(e[21]=t("p",{class:"text-xs text-muted-foreground mt-0.5"},"活跃 / 总数",-1))]),t("div",Ht,[t("div",Xt,[e[22]||(e[22]=t("p",{class:"text-xs text-muted-foreground font-medium"}," 最远到期 ",-1)),t("div",Ft,[n(a(lt),{class:"h-4 w-4 text-amber-500"})])]),t("p",Gt,d(b.value.latestExpiry?a(ye)(b.value.latestExpiry):b.value.latestValidityDays?`${b.value.latestValidityDays}天`:"永久"),1),t("p",Jt,d(b.value.latestExpiry?a(he)(b.value.latestExpiry,"yyyy-MM-dd HH:mm:ss"):b.value.latestValidityDays?"激活后计算":"无过期时间"),1)]),t("div",Qt,[t("div",Ot,[e[23]||(e[23]=t("p",{class:"text-xs text-muted-foreground font-medium"},"消耗链",-1)),t("div",Wt,[n(a(ut),{class:"h-4 w-4 text-blue-500"})])]),t("p",Zt,[u(d(p.value.length),1),e[24]||(e[24]=t("span",{class:"text-sm text-muted-foreground font-normal"}," 张卡",-1))]),t("p",Yt," 1 主卡 + "+d(E.value.length)+" 子卡 ",1)])]),t("div",es,[t("div",ts,[e[25]||(e[25]=t("span",{class:"text-muted-foreground"},"使用率",-1)),t("span",ss,d(b.value.usagePercent)+"%",1)]),n(a(le),{"model-value":b.value.usagePercent,class:"h-2"},null,8,["model-value"])])]}),_:1})]),_:1})):g("",!0),R.value&&p.value.length>0?(r(),v(a(S),{key:4,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-6 space-y-4"},{default:i(()=>[t("div",null,[t("div",as,[t("div",ls,[n(a(ne),{class:"h-4 w-4 text-primary"})]),e[26]||(e[26]=u(" 消耗链 ",-1))]),e[27]||(e[27]=t("p",{class:"text-sm text-muted-foreground mt-1 ml-10"}," 请求按此顺序依次消耗各卡额度 ",-1))]),t("div",ns,[t("div",os,[t("div",is,[e[29]||(e[29]=t("div",{class:"w-7 h-7 rounded-full bg-muted flex items-center justify-center text-xs font-bold text-muted-foreground shrink-0 mt-0.5"}," 1 ",-1)),t("div",rs,[t("div",ds,[t("span",us,d(p.value[0].key_preview),1),n(a(q),{variant:"outline",class:"text-[10px] px-1.5 py-0 h-[18px]"},{default:i(()=>[...e[28]||(e[28]=[u(" 主卡 ",-1)])]),_:1}),n(a(q),{variant:"outline",class:P(["text-[10px] px-1.5 py-0 h-[18px]",ue(p.value[0].status)])},{default:i(()=>[u(d(ce(p.value[0])),1)]),_:1},8,["class"])]),t("div",cs,[n(a(q),{variant:"outline",class:P(["max-w-full text-[10px] px-1.5 py-0 h-[18px]",a(ke)(p.value[0].service_type||"").badge]),title:W(p.value[0])},{default:i(()=>[t("span",ms,d(W(p.value[0])),1)]),_:1},8,["class","title"]),n(a(q),{variant:"outline",class:"text-[10px] px-1.5 py-0 h-[18px]"},{default:i(()=>[u(d(a(we)(p.value[0].billing_type||"")),1)]),_:1})]),t("div",fs,[t("div",vs,[t("span",ps,d(me(p.value[0])),1),t("span",{class:P(ve(p.value[0])?"text-red-500":"text-muted-foreground")},d(fe(p.value[0])),3)]),t("div",xs,[t("div",bs,[n(a(le),{"model-value":O(p.value[0]),class:"h-1.5"},null,8,["model-value"])]),t("span",gs,d(O(p.value[0]))+"%",1)])])])])]),E.value.length>0?(r(),x("div",_s,[(r(!0),x(se,null,ge(E.value,(l,o)=>(r(),x("div",{key:l.id},[e[32]||(e[32]=t("div",{class:"border-l-2 border-dashed border-primary/30 h-3 ml-4"},null,-1)),t("div",{class:P(["rounded-xl border p-4 transition-colors",pe(l)?"border-dashed border-border/50 bg-muted/10":"border-border/60 bg-muted/20 hover:bg-muted/30"])},[t("div",ys,[t("div",hs,d(o+2),1),t("div",ks,[t("div",ws,[t("div",Cs,[t("span",$s,d(l.key_preview),1),n(a(q),{variant:"outline",class:"text-[10px] px-1.5 py-0 h-[18px]"},{default:i(()=>[...e[30]||(e[30]=[u(" 子卡 ",-1)])]),_:1}),n(a(q),{variant:"outline",class:P(["text-[10px] px-1.5 py-0 h-[18px]",ue(l.status)])},{default:i(()=>[u(d(ce(l)),1)]),_:2},1032,["class"])]),t("div",qs,[t("div",js,[n(a(k),{variant:"ghost",size:"icon",class:"h-7 w-7",disabled:o===0||j.value,onClick:f=>Re(o),title:"上移"},{default:i(()=>[n(a(dt),{class:"h-3.5 w-3.5"})]),_:1},8,["disabled","onClick"]),n(a(k),{variant:"ghost",size:"icon",class:"h-7 w-7",disabled:o===E.value.length-1||j.value,onClick:f=>Te(o),title:"下移"},{default:i(()=>[n(a(rt),{class:"h-3.5 w-3.5"})]),_:1},8,["disabled","onClick"])]),n(a(tt),{orientation:"vertical",class:"mx-1.5 h-4"}),n(a(k),{variant:"ghost",size:"icon",class:"h-7 w-7 text-red-500 hover:text-red-600 hover:bg-red-50 dark:hover:bg-red-500/10",disabled:B.value,onClick:f=>Ve(l),title:"解绑"},{default:i(()=>[n(a(De),{class:"h-3.5 w-3.5"})]),_:1},8,["disabled","onClick"])])]),t("div",Is,[n(a(q),{variant:"outline",class:P(["max-w-full text-[10px] px-1.5 py-0 h-[18px]",a(ke)(l.service_type||"").badge]),title:W(l)},{default:i(()=>[t("span",Es,d(W(l)),1)]),_:2},1032,["class","title"]),n(a(q),{variant:"outline",class:"text-[10px] px-1.5 py-0 h-[18px]"},{default:i(()=>[u(d(a(we)(l.billing_type||"")),1)]),_:2},1024)]),pe(l)?(r(),x("div",Ps,[...e[31]||(e[31]=[t("p",{class:"text-xs text-muted-foreground"}," 排到时自动激活,开始计算有效期 ",-1)])])):(r(),x("div",Ks,[t("div",Ds,[t("span",Ss,d(me(l)),1),t("span",{class:P(ve(l)?"text-red-500":"text-muted-foreground")},d(fe(l)),3)]),t("div",Us,[t("div",Bs,[n(a(le),{"model-value":O(l),class:"h-1.5"},null,8,["model-value"])]),t("span",Ms,d(O(l))+"%",1)])]))])])],2)]))),128))])):g("",!0),j.value?(r(),x("p",As,[n(a(K),{class:"h-3.5 w-3.5 animate-spin"}),e[33]||(e[33]=u(" 正在更新排序... ",-1))])):g("",!0)])]),_:1})]),_:1})):g("",!0),ie.value?(r(),v(a(S),{key:5,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-8"},{default:i(()=>[t("div",zs,[t("div",Vs,[n(a(Pe),{class:"h-7 w-7 text-primary/60"})]),e[34]||(e[34]=t("h3",{class:"text-base font-semibold"},"独立卡模式",-1)),e[35]||(e[35]=t("p",{class:"text-sm text-muted-foreground mt-1"}," 尚未绑定任何卡片,在下方添加子卡建立消耗链 ",-1))])]),_:1})]),_:1})):g("",!0),re.value?(r(),v(a(S),{key:6,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-6 space-y-4"},{default:i(()=>[t("div",Ls,[t("div",Ns,[n(a(ne),{class:"h-4 w-4 text-blue-500"})]),e[36]||(e[36]=u(" 绑定信息 ",-1))]),t("div",Rs,[e[37]||(e[37]=t("p",{class:"text-sm text-muted-foreground mb-1"},"绑定的主卡",-1)),t("p",Ts,d(te.value),1),Ue.value?(r(),x("p",Hs," 主卡记录已不存在,请手动点击下方“解除绑定”清理当前绑定关系。 ")):g("",!0)]),t("div",Xs,[e[39]||(e[39]=t("div",{class:"space-y-1"},[t("p",{class:"text-sm font-medium text-foreground"},"解除绑定"),t("p",{class:"text-xs leading-5 text-muted-foreground"}," 解除后此卡将恢复为独立卡,可单独使用和管理。 ")],-1)),n(a(k),{variant:"secondary",size:"sm",class:"shrink-0",disabled:I.value,onClick:e[1]||(e[1]=l=>N.value=!0)},{default:i(()=>[I.value?(r(),v(a(K),{key:0,class:"h-4 w-4 animate-spin"})):(r(),v(a(De),{key:1,class:"h-4 w-4"})),e[38]||(e[38]=u(" 解除绑定 ",-1))]),_:1},8,["disabled"])])]),_:1})]),_:1})):g("",!0),Be.value?(r(),v(a(S),{key:7,class:"border-border/60 bg-card/80 backdrop-blur-xl"},{default:i(()=>[n(a(D),{class:"p-6 space-y-4"},{default:i(()=>[t("div",null,[t("div",Fs,[t("div",Gs,[n(a(Ke),{class:"h-4 w-4 text-emerald-500"})]),e[40]||(e[40]=u(" 绑定新卡 ",-1))]),e[41]||(e[41]=t("p",{class:"text-sm text-muted-foreground mt-1 ml-10"}," 输入子卡 API Key 进行绑定,子卡必须与主卡的服务类型、子服务类型和计费方式一致,且未绑定 ",-1))]),t("div",Js,[t("div",Qs,[n(a(Ye),{modelValue:V.value,"onUpdate:modelValue":e[2]||(e[2]=l=>V.value=l),type:G.value?"text":"password",placeholder:"请输入子卡 API Key",autocomplete:"off",spellcheck:"false",class:"pr-9 font-mono text-sm",disabled:U.value,onKeydown:Ge(xe,["enter"])},null,8,["modelValue","type","disabled"]),t("button",{type:"button",class:"absolute right-2.5 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground transition-colors",onClick:e[3]||(e[3]=l=>G.value=!G.value)},[G.value?(r(),v(a(nt),{key:0,class:"h-4 w-4"})):(r(),v(a(et),{key:1,class:"h-4 w-4"}))])]),n(a(k),{disabled:!V.value.trim()||!de.value||U.value,onClick:xe},{default:i(()=>[n(a(Ke),{class:"h-4 w-4 mr-1"}),e[42]||(e[42]=u(" 添加 ",-1))]),_:1},8,["disabled"])]),y.value.length>0?(r(),x("div",Os,[t("p",Ws," 待绑定("+d(y.value.length)+" 张) ",1),t("div",Zs,[(r(!0),x(se,null,ge(y.value,(l,o)=>(r(),x("div",{key:o,class:"inline-flex items-center gap-1.5 rounded-full border border-border/60 bg-muted/30 px-3 py-1 text-sm"},[t("span",Ys,d(He(l)),1),t("button",{type:"button",class:"text-muted-foreground hover:text-red-500 transition-colors",onClick:f=>Ae(o)},[n(a(We),{class:"h-3 w-3"})],8,ea)]))),128))])])):g("",!0),y.value.length>0?(r(),v(a(k),{key:1,class:"w-full",disabled:U.value,onClick:ze},{default:i(()=>[U.value?(r(),v(a(K),{key:0,class:"h-4 w-4 mr-2 animate-spin"})):(r(),v(a(ne),{key:1,class:"h-4 w-4 mr-2"})),u(" 绑定 "+d(y.value.length)+" 张卡 ",1)]),_:1},8,["disabled"])):g("",!0)]),_:1})]),_:1})):g("",!0),t("button",{type:"button",class:"flex items-center gap-1.5 text-sm text-muted-foreground hover:text-foreground transition-colors",onClick:e[4]||(e[4]=l=>Q.value=!Q.value)},[Q.value?(r(),v(a(it),{key:1,class:"h-4 w-4"})):(r(),v(a(ot),{key:0,class:"h-4 w-4"})),e[43]||(e[43]=u(" 绑定规则说明 ",-1))]),Q.value?(r(),v(a(S),{key:8,class:"border-border/40"},{default:i(()=>[n(a(D),{class:"p-5"},{default:i(()=>[...e[44]||(e[44]=[t("ul",{class:"space-y-2 text-sm text-muted-foreground"},[t("li",null,"1. 子卡必须与主卡类型(服务类型、子服务类型、计费方式)一致"),t("li",null,"2. 子卡不能是已绑定或已过期的卡"),t("li",null,'3. 绑定后子卡状态变为"已绑定",不再独立消耗额度'),t("li",null,"4. 消耗链按顺序使用,主卡额度耗尽后自动使用下一张子卡")],-1)])]),_:1})]),_:1})):g("",!0)],64)),n(a(Ee),{open:L.value,"onUpdate:open":e[6]||(e[6]=l=>L.value=l)},{default:i(()=>[n(a(Ce),{class:"sm:max-w-md"},{default:i(()=>[n(a($e),null,{default:i(()=>[n(a(qe),{class:"flex items-center gap-2"},{default:i(()=>[n(a(H),{class:"h-5 w-5 text-amber-500"}),e[45]||(e[45]=u(" 确认解绑 ",-1))]),_:1}),n(a(je),null,{default:i(()=>[e[46]||(e[46]=u(" 确定要解绑子卡 ",-1)),t("span",ta,d(Y.value),1),e[47]||(e[47]=u(" 吗?解绑后该卡将恢复为独立卡。 ",-1))]),_:1})]),_:1}),n(a(Ie),{class:"gap-2 sm:gap-3"},{default:i(()=>[n(a(k),{variant:"outline",disabled:B.value,onClick:e[5]||(e[5]=l=>L.value=!1)},{default:i(()=>[...e[48]||(e[48]=[u("取消",-1)])]),_:1},8,["disabled"]),n(a(k),{variant:"destructive",disabled:B.value,onClick:Le},{default:i(()=>[B.value?(r(),v(a(K),{key:0,class:"h-4 w-4 mr-2 animate-spin"})):g("",!0),e[49]||(e[49]=u(" 确认解绑 ",-1))]),_:1},8,["disabled"])]),_:1})]),_:1})]),_:1},8,["open"]),n(a(Ee),{open:N.value,"onUpdate:open":e[8]||(e[8]=l=>N.value=l)},{default:i(()=>[n(a(Ce),{class:"sm:max-w-md"},{default:i(()=>[n(a($e),null,{default:i(()=>[n(a(qe),{class:"flex items-center gap-2"},{default:i(()=>[n(a(H),{class:"h-5 w-5 text-amber-500"}),e[50]||(e[50]=u(" 确认解绑 ",-1))]),_:1}),n(a(je),null,{default:i(()=>[e[51]||(e[51]=u(" 确定要从主卡 ",-1)),t("span",sa,d(te.value),1),e[52]||(e[52]=u(" 解绑吗?解绑后此卡将恢复为独立卡。 ",-1))]),_:1})]),_:1}),n(a(Ie),{class:"gap-2 sm:gap-3"},{default:i(()=>[n(a(k),{variant:"outline",disabled:I.value,onClick:e[7]||(e[7]=l=>N.value=!1)},{default:i(()=>[...e[53]||(e[53]=[u("取消",-1)])]),_:1},8,["disabled"]),n(a(k),{variant:"destructive",disabled:I.value,onClick:Ne},{default:i(()=>[I.value?(r(),v(a(K),{key:0,class:"h-4 w-4 mr-2 animate-spin"})):g("",!0),e[54]||(e[54]=u(" 确认解绑 ",-1))]),_:1},8,["disabled"])]),_:1})]),_:1})]),_:1},8,["open"])])}}});export{ga as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Q as o}from"./index-Da98HOxL.js";import{j as n,d as c,x as d,y as l,G as p,C as u,u as _}from"./chart-vendor-CULJE59K.js";const g=n({__name:"Card",props:{class:{}},setup(a){const e=a,t=c(()=>{const{class:s,...r}=e;return r});return(s,r)=>(l(),d("div",u(t.value,{class:_(o)("rounded-xl border border-border/50 bg-card text-card-foreground",e.class)}),[p(s.$slots,"default")],16))}}),i=n({__name:"CardContent",props:{class:{}},setup(a){const e=a,t=c(()=>{const{class:s,...r}=e;return r});return(s,r)=>(l(),d("div",u(t.value,{class:_(o)("p-6 pt-0",e.class)}),[p(s.$slots,"default")],16))}});export{i as _,g as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Q as a}from"./index-Da98HOxL.js";import{j as n,d as c,x as p,y as l,C as d,u as m,G as u}from"./chart-vendor-CULJE59K.js";const i=n({__name:"CardDescription",props:{class:{}},setup(o){const e=o,r=c(()=>{const{class:s,...t}=e;return t});return(s,t)=>(l(),p("p",d(r.value,{class:m(a)("text-sm text-muted-foreground",e.class)}),[u(s.$slots,"default")],16))}});export{i as _};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Q as r}from"./index-Da98HOxL.js";import{j as n,d as c,x as l,y as p,G as d,C as u,u as m}from"./chart-vendor-CULJE59K.js";const i=n({__name:"CardHeader",props:{class:{}},setup(t){const e=t,o=c(()=>{const{class:s,...a}=e;return a});return(s,a)=>(p(),l("div",u(o.value,{class:m(r)("flex flex-col space-y-1.5 p-6",e.class)}),[d(s.$slots,"default")],16))}}),g=n({__name:"CardTitle",props:{class:{}},setup(t){const e=t,o=c(()=>{const{class:s,...a}=e;return a});return(s,a)=>(p(),l("h3",u(o.value,{class:m(r)("font-semibold leading-none tracking-tight",e.class)}),[d(s.$slots,"default")],16))}});export{g as _,i as a};
|