chore(frontend): introduce prettier + eslint and prune unused code
- Add Prettier 3 with prettier-plugin-organize-imports (sorts/removes unused imports) - Add ESLint 10 flat config with typescript-eslint + eslint-plugin-vue + eslint-config-prettier - Add root scripts: format, format:check, lint, lint:fix - Reformat 257 files across admin-web, ops-web, desktop-client, packages - Remove unused locals/exports flagged by --noUnusedLocals/--noUnusedParameters - Fix duplicate localTabLabel key, surrogate-pair regex u-flag, NBSP literal in regex - Skip server/ (Go) and apps/browser-extension/ (deprecated per ADR) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1 +1 @@
|
||||
export * from "./ai-platforms.ts";
|
||||
export * from './ai-platforms.ts'
|
||||
|
||||
@@ -1,76 +1,76 @@
|
||||
export interface AIPlatformCatalogItem {
|
||||
id: string;
|
||||
label: string;
|
||||
shortName: string;
|
||||
accent: string;
|
||||
description: string;
|
||||
loginUrl: string;
|
||||
consoleUrl: string;
|
||||
id: string
|
||||
label: string
|
||||
shortName: string
|
||||
accent: string
|
||||
description: string
|
||||
loginUrl: string
|
||||
consoleUrl: string
|
||||
}
|
||||
|
||||
export const aiPlatformCatalog: readonly AIPlatformCatalogItem[] = [
|
||||
{
|
||||
id: "yuanbao",
|
||||
label: "混元 / 元宝",
|
||||
shortName: "元",
|
||||
accent: "#19bf6b",
|
||||
description: "腾讯系 AI 平台账号绑定与静默监测",
|
||||
loginUrl: "https://yuanbao.tencent.com/",
|
||||
consoleUrl: "https://yuanbao.tencent.com/",
|
||||
id: 'yuanbao',
|
||||
label: '混元 / 元宝',
|
||||
shortName: '元',
|
||||
accent: '#19bf6b',
|
||||
description: '腾讯系 AI 平台账号绑定与静默监测',
|
||||
loginUrl: 'https://yuanbao.tencent.com/',
|
||||
consoleUrl: 'https://yuanbao.tencent.com/',
|
||||
},
|
||||
{
|
||||
id: "kimi",
|
||||
label: "Kimi",
|
||||
shortName: "K",
|
||||
accent: "#111827",
|
||||
description: "Moonshot AI 账号绑定与静默监测",
|
||||
loginUrl: "https://www.kimi.com/",
|
||||
consoleUrl: "https://www.kimi.com/",
|
||||
id: 'kimi',
|
||||
label: 'Kimi',
|
||||
shortName: 'K',
|
||||
accent: '#111827',
|
||||
description: 'Moonshot AI 账号绑定与静默监测',
|
||||
loginUrl: 'https://www.kimi.com/',
|
||||
consoleUrl: 'https://www.kimi.com/',
|
||||
},
|
||||
{
|
||||
id: "wenxin",
|
||||
label: "文心一言",
|
||||
shortName: "文",
|
||||
accent: "#20c6d7",
|
||||
description: "百度文心账号绑定与静默监测",
|
||||
loginUrl: "https://yiyan.baidu.com/",
|
||||
consoleUrl: "https://yiyan.baidu.com/",
|
||||
id: 'wenxin',
|
||||
label: '文心一言',
|
||||
shortName: '文',
|
||||
accent: '#20c6d7',
|
||||
description: '百度文心账号绑定与静默监测',
|
||||
loginUrl: 'https://yiyan.baidu.com/',
|
||||
consoleUrl: 'https://yiyan.baidu.com/',
|
||||
},
|
||||
{
|
||||
id: "deepseek",
|
||||
label: "DeepSeek",
|
||||
shortName: "D",
|
||||
accent: "#4468ff",
|
||||
description: "DeepSeek 账号绑定与静默监测",
|
||||
loginUrl: "https://chat.deepseek.com/",
|
||||
consoleUrl: "https://chat.deepseek.com/",
|
||||
id: 'deepseek',
|
||||
label: 'DeepSeek',
|
||||
shortName: 'D',
|
||||
accent: '#4468ff',
|
||||
description: 'DeepSeek 账号绑定与静默监测',
|
||||
loginUrl: 'https://chat.deepseek.com/',
|
||||
consoleUrl: 'https://chat.deepseek.com/',
|
||||
},
|
||||
{
|
||||
id: "doubao",
|
||||
label: "豆包",
|
||||
shortName: "豆",
|
||||
accent: "#ff9348",
|
||||
description: "字节豆包账号绑定与静默监测",
|
||||
loginUrl: "https://www.doubao.com/",
|
||||
consoleUrl: "https://www.doubao.com/",
|
||||
id: 'doubao',
|
||||
label: '豆包',
|
||||
shortName: '豆',
|
||||
accent: '#ff9348',
|
||||
description: '字节豆包账号绑定与静默监测',
|
||||
loginUrl: 'https://www.doubao.com/',
|
||||
consoleUrl: 'https://www.doubao.com/',
|
||||
},
|
||||
{
|
||||
id: "qwen",
|
||||
label: "通义千问",
|
||||
shortName: "通",
|
||||
accent: "#276ef1",
|
||||
description: "阿里千问账号绑定与静默监测",
|
||||
loginUrl: "https://www.qianwen.com/",
|
||||
consoleUrl: "https://www.qianwen.com/",
|
||||
id: 'qwen',
|
||||
label: '通义千问',
|
||||
shortName: '通',
|
||||
accent: '#276ef1',
|
||||
description: '阿里千问账号绑定与静默监测',
|
||||
loginUrl: 'https://www.qianwen.com/',
|
||||
consoleUrl: 'https://www.qianwen.com/',
|
||||
},
|
||||
] as const;
|
||||
] as const
|
||||
|
||||
const aiPlatformMap = new Map(aiPlatformCatalog.map((item) => [item.id, item]));
|
||||
const aiPlatformMap = new Map(aiPlatformCatalog.map((item) => [item.id, item]))
|
||||
|
||||
export function getAIPlatformCatalogItem(platformId: string): AIPlatformCatalogItem | null {
|
||||
return aiPlatformMap.get(platformId) ?? null;
|
||||
return aiPlatformMap.get(platformId) ?? null
|
||||
}
|
||||
|
||||
export function isAIPlatformId(platformId: string): boolean {
|
||||
return aiPlatformMap.has(platformId);
|
||||
return aiPlatformMap.has(platformId)
|
||||
}
|
||||
|
||||
+1178
-1177
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user