Commit Graph

64 Commits

Author SHA1 Message Date
wangxiaoji 6b73f5b6b9 Token 使用趋势添加时间范围控制栏:粒度选择器与刷新按钮 2026-06-30 14:06:05 +08:00
wangxiaoji dd5474f500 修复 Token 使用趋势日期标签与迷你图对齐:日期均匀分布匹配数据点 2026-06-30 14:05:22 +08:00
wangxiaoji 715487fda7 Token 使用趋势日期标签可读性优化:非峰值日期颜色从浅灰改为中灰,确保可见 2026-06-30 10:04:32 +08:00
wangxiaoji 847c2bd9d3 Token 使用趋势 X 轴标签从星期改为具体日期(月/日 格式) 2026-06-30 09:59:15 +08:00
wangxiaoji 6a99f229e3 修复控制台最近调用显示失败的问题:isSuccess 将 LogTypeConsume(2) 和 LogTypeTopup(1) 也识别为成功 2026-06-30 09:30:34 +08:00
wangxiaoji 8e8f19fc10 将控制台页面和首页底部的 TokenFactory 改为从 getSystemName() 动态读取,统一品牌名称为 TuringToken 2026-06-29 17:21:31 +08:00
wangxiaoji dd1b881cf1 重新设计登录页面:采用分栏布局,左侧品牌展示区(深色背景+Logo+标语+色彩装饰),右侧登录表单区 2026-06-29 17:05:08 +08:00
wangxiaoji dc1ba114e5 修改:默认 logo 路径改为 /logo.jpg 2026-06-29 16:53:30 +08:00
wangxiaoji af2abaee09 修改:系统名称改为 TuringToken 2026-06-29 16:43:53 +08:00
wangxiaoji f32c114f1a 修复:添加缺失的 logo.png 文件 2026-06-29 15:43:33 +08:00
wangxiaoji 8ed621ed76 修复:补全缺失的前端文件并取消忽略 vite.config.js 2026-06-29 15:20:20 +08:00
wangxiaoji 3fb6326f4a feat: 重构控制台 Dashboard + 新增 API 快速测试页
- 新增 Bento 风格 Dashboard 组件:TopBar、Hero、BentoStats、BentoTrend、MonthlyForecast、RecentActivity、Sparkline
- 新增 /console/api-tester API 快速测试页:支持 OpenAI/Anthropic 协议切换、多家国产模型预设、Key 清洗、流式/非流式切换、cURL 一键复制
- 注释和提示语统一中文化
- App.jsx 新增 /console/api-tester 路由(PrivateRoute 守卫)
2026-06-26 16:16:30 +08:00
xiezhouwei 1e3ce2c0d2 feat: remove channel ID and username search fields from usage log filters 2026-06-23 14:11:36 +08:00
xiezhouwei b6293434e9 feat: hide channel, user, and retry columns in usage log table by default\n\n- Set CHANNEL/USERNAME/RETRY default visibility to false for all users\n- Remove admin-only override logic (no longer differentiate by role)\n- Exclude these 3 columns from 'Select All' operation 2026-06-23 14:06:26 +08:00
xiezhouwei a9d2fc2abe fix: billing total display now consistently uses 2 decimals, floor 0.01 for tiny positive amounts\n\n- Previous 6-decimal fallback caused visual inconsistency with list (shows 0.01)\n- Now: raw>0 and toFixed(2)>0 -> normal 2-decimal display\n- Now: raw>0 but toFixed(2)==0 -> floor to 0.01 (minimum visible unit)\n- Matches list column display format, no more '= 0.000125' in detail 2026-06-23 11:49:21 +08:00
xiezhouwei 4d5dd30668 fix: prevent billing process total from rounding to 0 for very small amounts (e.g. low-ratio channel-only models)
- Add formatBillingTotalDisplay: auto-scales from 2 to 6 decimal places when amount < 0.005
- Replace formatBillingDisplayPrice with formatBillingTotalDisplay in the billing total line
- Prevents '= \' display when actual cost is a tiny positive value (e.g. 0.00002 USD)
2026-06-23 11:39:18 +08:00
xiezhouwei 648c9917ab fix: hide cache prices on model card, show only input and output prices 2026-06-23 11:15:24 +08:00
xiezhouwei a93c04ce28 fix: show all configured channel prices (output/cache/createCache) on model card surface, not just input 2026-06-23 11:09:12 +08:00
xiezhouwei d676e2200f fix: show output/cache/create_cache prices when channel-level pricing provides the ratio, not only when global pricing has it 2026-06-23 11:00:44 +08:00
xiezhouwei a7759c5767 refine: show only avatar circle on homepage hero when logged in, remove username text 2026-06-22 11:58:07 +08:00
xiezhouwei c44cebeb18 fix: apply admin theme/language toggle to homepage hero section as well 2026-06-22 11:53:12 +08:00
xiezhouwei 09d6a7305e feat: add admin-controlled toggles for header theme/language display in system settings 2026-06-22 11:46:31 +08:00
xiezhouwei 3e79e956f0 Revert "fix: restrict theme toggle and language selector to console routes only, hide on public pages"
This reverts commit ff522958de.
2026-06-22 11:41:24 +08:00
xiezhouwei ff522958de fix: restrict theme toggle and language selector to console routes only, hide on public pages 2026-06-22 11:35:22 +08:00
xiezhouwei 7d30717cd1 fix: unify homepage hero button styles - rounded login button, console-style user avatar with dynamic color 2026-06-22 11:27:28 +08:00
xiezhouwei 4f85cad331 fix: show user info on homepage hero when logged in instead of always showing login button 2026-06-22 10:59:30 +08:00
xiezhouwei 0ab319143b feat: restructure docs page to left-center-right 3-column layout with page TOC sidebar 2026-06-22 10:08:09 +08:00
xiezhouwei e028f6f93a fix: adjust docs page scroll offset to prevent fixed header occlusion 2026-06-22 09:56:23 +08:00
xiezhouwei 64a4a68a6f feat: add in-app docs page with sidebar navigation and quickstart guide, replace /docs redirect with built-in page 2026-06-22 09:30:31 +08:00
xiezhouwei dfa7ccbd97 Revert "fix: remove '文档' nav link from homepage hero section"
This reverts commit 4429de2448.
2026-06-22 09:23:57 +08:00
xiezhouwei 4429de2448 fix: remove '文档' nav link from homepage hero section 2026-06-22 09:21:09 +08:00
xiezhouwei 6a880c08ba fix: add /docs redirect middleware to forward docs paths to configured docs_link 2026-06-22 09:16:31 +08:00
xiezhouwei 9f47782442 fix: homepage '文档' nav link now uses dynamic same-origin docs URL instead of hardcoded docs.new-api.cc 2026-06-22 09:09:02 +08:00
xiezhouwei 59cc502e6e fix: homepage '开始使用' button now links to API Key (/console/token) instead of register 2026-06-21 19:00:13 +08:00
xiezhouwei 86bb4ee0cf rename: 体验馆 → 体验 (menu, settings, i18n across 11 locales) 2026-06-21 18:26:24 +08:00
xiezhouwei 07a6e29c1e fix: allow vendor_id=0 to be passed as model_type in experience button jump 2026-06-21 16:47:42 +08:00
xiezhouwei 4f8cde37d8 refactor: replace api.tokendance.space with api.turingtoken.ai on homepage 2026-06-21 16:40:30 +08:00
xiezhouwei 6eec903060 refactor: remove about link and GitHub display from homepage DarkFooter 2026-06-21 16:37:23 +08:00
xiezhouwei 0d798c2fbc fix: convert model_type URL param to number so Select matches optionList value type 2026-06-19 10:37:41 +08:00
xiezhouwei 2165430d87 feat: pass model_type (vendor_id) from model detail to playground settings panel 2026-06-19 10:30:32 +08:00
xiezhouwei 977e9e8bf5 feat: add experience button in model detail side sheet to jump to playground with model preset 2026-06-19 10:17:00 +08:00
xiezhouwei 46819578de fix: model page tab filter not working and sidebar tag order 2026-06-18 17:01:50 +08:00
xiezhouwei 77b885b190 refactor: streamline model card to show only logo, name, description, and IO prices 2026-06-18 16:50:02 +08:00
xiezhouwei 4fbdafee1c fix: remove supplier filter from model page sidebar 2026-06-18 16:36:52 +08:00
xiezhouwei 825954e43f fix: 模型页面右侧列表被固定导航栏遮挡\n\n根因:PageLayout.jsx 第 325 行 <Header> 为 position: fixed; top: 0\n(h-14, 56px),在 /pricing 路径下也显示。但 models-page-layout\n使用 height: calc(100vh - 60px) 而非 padding-top 偏移,导致\n布局从视口顶部(y=0)开始,内容被固定头部遮盖。\n\n修改:\n- models-page-layout: padding: 56px 24px 0 + height: 100vh +\n box-sizing: border-box,使内容从固定头部下方开始\n- models-sidebar: 移除顶部 padding(padding: 0 16px 24px 0),\n 避免与外层 padding-top 叠加 2026-06-17 16:28:04 +08:00
xiezhouwei 61b0d902b6 refactor: 模型页面布局调整为左右结构(类 tokendance.models)
新增:
- ModelsSidebar.jsx 左侧筛选面板(作者/服务商/输入模态/供应商)
- ModelsContent.jsx 右侧内容区(全部/文本/图像/音频/视频 Tab + 搜索)
- index.css models-* 样式类

修改:
- PricingPage.jsx 布局改为 flex 左右结构替代 Semi UI Layout
- PricingCardView.jsx 新增 gridCols 参数支持 2 列网格布局
  当 gridCols=2 时:grid gap-4 + 卡片 !w-full

布局: 左 280px 筛选栏 + 右自适应内容区
Tab: 全部/文本/图像/音频/视频 (映射到 filterEndpointType)
卡片: 每行 2 个模型卡片
2026-06-17 14:33:53 +08:00
xiezhouwei 5fa5f87e1e fix: 补全主页独立导航栏顺序 - 模型→评测→文档→控制台
Home/index.jsx 第 153 行有自己的固定导航栏(fixed top-0 z-50),
完全独立于 HeaderBar 组件。其导航项数组仍是旧顺序
模型→控制台→评测→文档,现调整为:模型→评测→文档→控制台。

至此三处导航栏全部修正:
1. useNavigation.js(桌面 HeaderBar 导航)
2. MobileSiteNavDropdown.jsx(移动端下拉导航)
3. Home/index.jsx(主页独立固定导航栏)
2026-06-17 14:08:02 +08:00
xiezhouwei d33f55ad55 fix: 补全移动端导航栏顺序同步 - 模型→评测→文档→控制台
之前只修改了 useNavigation.js(桌面导航),漏掉了
MobileSiteNavDropdown.jsx 第34行硬编码的 PRIMARY_NAV_KEYS
数组,导致移动端下拉导航顺序仍为旧顺序。
2026-06-17 14:04:33 +08:00
xiezhouwei 3cb9c85ea8 feat: 调整首页导航栏顺序为 模型→评测→文档→控制台 2026-06-17 14:00:16 +08:00
xiezhouwei 5b5d7a95f3 fix: 评测页面顶部被固定导航栏遮挡 - 添加 pt-14 偏移\n\n根因:PageLayout.jsx 中 <Header> 使用 position: fixed; top: 0(h-14, 56px),但\n非 /console 路径的 <Content> padding 为 0,评测页面顶部内容被固定头部遮盖。\n\n修改:在外容器和 loading 容器添加 pt-14,精确匹配头部高度。 2026-06-17 11:47:48 +08:00