feat: 接入 gpui-kit 全部 38 个官方主题预设 + 按语言拆分 locales + 0.7.3 升级
主题预设("我全都要"): - gpui-app/themes/ 内嵌官方捆绑 21 个文件 36 变体 + Default Light/Dark - theme.rs:register_bundled_themes(bootstrap 注册)/ apply_theme_preset (Theme::update + apply_config 整包应用)/ theme_preset_names - settings.theme_preset 字段(serde 默认 linear);保存/启动按预设分派, 外观模式与跟随系统监听仅对 Linear 生效(预设自带明暗不被冲掉) - 设置页「主题预设」下拉(Linear + 38 注册名),切换即时生效 语言包按语言分文件(用户要求): - locales/ui.yml → locales/en.yml + locales/zh-CN.yml (rust-i18n 文件名 stem 即 locale,扁平 "ns.key": "value") - i18n.rs 测试改为双文件键集合一致性 + 占位符强制 修复:设置对话框打开即栈溢出 - gpui-kit 0.7.0→0.7.3 无法解决;根因是 Windows 主线程 8MB 栈对 Dialog 覆盖层内 Select 渲染的深调用链不足,注册多主题后越过阈值 (64MB 试验栈下不复现,证实深调用链而非无限递归) - .cargo/config.toml:Windows 主线程栈 8MB→64MB - 注册时机移到 bootstrap(main 的 init_themes,gpui_kit::init 后、 窗口创建前),对齐官方 story 示例的注册姿势 - 误伤修复:gpui-app/Cargo.toml 被批量编辑误删 bin.name 与 build-dependencies 段;examples/flood.rs 误删已恢复 官方 skill 同步:npx skills add 被墙,gh-proxy 镜像克隆后手动覆盖 ~/.agents/skills 与 ~/.zcode/skills 的 gpui-kit + gpui-kit-design-guides。
This commit is contained in:
@@ -0,0 +1,147 @@
|
||||
{
|
||||
"$schema": "https://github.com/longbridge/gpui-kit/raw/refs/heads/main/.theme-schema.json",
|
||||
"name": "Asciinema",
|
||||
"author": "asciinema.org",
|
||||
"url": "https://asciinema.org",
|
||||
"themes": [
|
||||
{
|
||||
"name": "Asciinema",
|
||||
"mode": "dark",
|
||||
"colors": {
|
||||
"accent.background": "#262829",
|
||||
"accent.foreground": "#cccccc",
|
||||
"background": "#121314",
|
||||
"border": "#303030",
|
||||
"danger.background": "#dd3c69",
|
||||
"danger.active.background": "#dd3c69",
|
||||
"danger.hover.background": "#e94f7a",
|
||||
"foreground": "#cccccc",
|
||||
"input.border": "#3a3a3a",
|
||||
"link.active.foreground": "#26b0d7",
|
||||
"link.foreground": "#26b0d7",
|
||||
"link.hover.foreground": "#3cc0e7",
|
||||
"list.active.background": "#1a1b1c",
|
||||
"list.active.border": "#cccccc",
|
||||
"list.even.background": "#1a1b1c",
|
||||
"list.head.background": "#121314",
|
||||
"muted.background": "#1a1b1c",
|
||||
"muted.foreground": "#6d6d6d",
|
||||
"panel.background": "#181919",
|
||||
"primary.active.background": "#26b0d799",
|
||||
"primary.background": "#26b0d7",
|
||||
"primary.foreground": "#ffffff",
|
||||
"primary.hover.background": "#26b0d7AA",
|
||||
"scrollbar.background": "#12131400",
|
||||
"scrollbar.thumb.background": "#2a2a2a",
|
||||
"secondary.background": "#181919",
|
||||
"secondary.active.background": "#1f2020",
|
||||
"secondary.foreground": "#cccccc",
|
||||
"secondary.hover.background": "#1f202099",
|
||||
"tab.active.background": "#121314",
|
||||
"tab.active.foreground": "#cccccc",
|
||||
"tab.background": "#12131400",
|
||||
"tab.foreground": "#6d6d6d",
|
||||
"table.row.border": "#2a2a2a70",
|
||||
"title_bar.background": "#181919",
|
||||
"title_bar.border": "#303030",
|
||||
"ring": "#5d5d5d",
|
||||
"base.blue": "#26b0d7",
|
||||
"base.cyan": "#54e1b9",
|
||||
"base.green": "#4ebf22",
|
||||
"base.magenta": "#b954e1",
|
||||
"base.red": "#dd3c69",
|
||||
"base.yellow": "#ddaf3c"
|
||||
},
|
||||
"highlight": {
|
||||
"editor.foreground": "#cccccc",
|
||||
"editor.background": "#121314",
|
||||
"editor.active_line.background": "#1a1b1c",
|
||||
"editor.line_number": "#6d6d6d",
|
||||
"editor.active_line_number": "#cccccc",
|
||||
"editor.invisible": "#6d6d6d66",
|
||||
"conflict": "#dd3c69",
|
||||
"created": "#4ebf22",
|
||||
"error": "#dd3c69",
|
||||
"hidden": "#6d6d6d",
|
||||
"hint": "#b954e1",
|
||||
"info": "#26b0d7",
|
||||
"modified": "#ddaf3c",
|
||||
"predictive": "#2a2a2a",
|
||||
"syntax": {
|
||||
"attribute": {
|
||||
"color": "#ddaf3c"
|
||||
},
|
||||
"boolean": {
|
||||
"color": "#b954e1"
|
||||
},
|
||||
"comment": {
|
||||
"color": "#5d5d5d"
|
||||
},
|
||||
"comment.doc": {
|
||||
"color": "#5d5d5d"
|
||||
},
|
||||
"constant": {
|
||||
"color": "#b954e1"
|
||||
},
|
||||
"constructor": {
|
||||
"color": "#26b0d7"
|
||||
},
|
||||
"embedded": {
|
||||
"color": "#cccccc"
|
||||
},
|
||||
"function": {
|
||||
"color": "#54e1b9"
|
||||
},
|
||||
"keyword": {
|
||||
"color": "#dd3c69"
|
||||
},
|
||||
"link_text": {
|
||||
"color": "#26b0d7",
|
||||
"font_style": "normal"
|
||||
},
|
||||
"link_uri": {
|
||||
"color": "#54e1b9",
|
||||
"font_style": "italic"
|
||||
},
|
||||
"number": {
|
||||
"color": "#b954e1"
|
||||
},
|
||||
"string": {
|
||||
"color": "#4ebf22"
|
||||
},
|
||||
"string.escape": {
|
||||
"color": "#54e1b9"
|
||||
},
|
||||
"string.regex": {
|
||||
"color": "#4ebf22"
|
||||
},
|
||||
"string.special": {
|
||||
"color": "#ddaf3c"
|
||||
},
|
||||
"string.special.symbol": {
|
||||
"color": "#ddaf3c"
|
||||
},
|
||||
"tag": {
|
||||
"color": "#dd3c69"
|
||||
},
|
||||
"text.literal": {
|
||||
"color": "#cccccc"
|
||||
},
|
||||
"title": {
|
||||
"color": "#ddaf3c",
|
||||
"font_weight": 600
|
||||
},
|
||||
"type": {
|
||||
"color": "#26b0d7"
|
||||
},
|
||||
"property": {
|
||||
"color": "#cccccc"
|
||||
},
|
||||
"variable.special": {
|
||||
"color": "#dd3c69"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user