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,150 @@
|
||||
{
|
||||
"$schema": "https://github.com/longbridge/gpui-kit/raw/refs/heads/main/.theme-schema.json",
|
||||
"name": "Harper",
|
||||
"author": "iTerm2-Color-Schemes",
|
||||
"url": "https://github.com/mbadolato/iTerm2-Color-Schemes",
|
||||
"themes": [
|
||||
{
|
||||
"name": "Harper",
|
||||
"mode": "dark",
|
||||
"colors": {
|
||||
"accent.background": "#27222c",
|
||||
"accent.foreground": "#a8a49d",
|
||||
"background": "#010101",
|
||||
"border": "#333333",
|
||||
"foreground": "#a8a49d",
|
||||
"input.border": "#333333",
|
||||
"list.active.background": "#B196C622",
|
||||
"list.active.border": "#B196C699",
|
||||
"list.even.background": "#18151B77",
|
||||
"muted.background": "#171717",
|
||||
"muted.foreground": "#726E69",
|
||||
"panel.background": "#003a5b",
|
||||
"popover.background": "#010101",
|
||||
"popover.foreground": "#a8a49d",
|
||||
"primary.background": "#B196C6",
|
||||
"primary.foreground": "#000000",
|
||||
"scrollbar.background": "#003a5b00",
|
||||
"scrollbar.thumb.background": "#726E69",
|
||||
"secondary.background": "#1b1b1b",
|
||||
"secondary.active.background": "#2c2632",
|
||||
"secondary.foreground": "#A8A49D",
|
||||
"secondary.hover.background": "#23232399",
|
||||
"tab.active.background": "#010101",
|
||||
"tab.active.foreground": "#a8a49d",
|
||||
"tab.foreground": "#787878",
|
||||
"title_bar.background": "#101010",
|
||||
"base.red": "#ff5874",
|
||||
"base.red.light": "#ff587499",
|
||||
"base.green": "#489e48",
|
||||
"base.green.light": "#489e4899",
|
||||
"base.blue": "#7fb5e1",
|
||||
"base.blue.light": "#7fb5e199",
|
||||
"base.cyan": "#bff5e5",
|
||||
"base.cyan.light": "#bff5e599",
|
||||
"base.magenta": "#b296c6",
|
||||
"base.magenta.light": "#b296c699",
|
||||
"base.yellow": "#f8b63f",
|
||||
"base.yellow.light": "#f8b63f99"
|
||||
},
|
||||
"highlight": {
|
||||
"editor.foreground": "#a8a49d",
|
||||
"editor.background": "#010101",
|
||||
"editor.active_line.background": "#18151B",
|
||||
"editor.line_number": "#726E69",
|
||||
"editor.active_line_number": "#a8a49d",
|
||||
"editor.invisible": "#726E6966",
|
||||
"conflict": "#ff5874",
|
||||
"created": "#489e48",
|
||||
"deleted": "#ff5874",
|
||||
"error": "#ff5874",
|
||||
"hidden": "#726E69",
|
||||
"hint": "#7fb5e1",
|
||||
"ignored": "#726E69",
|
||||
"info": "#7fb5e1",
|
||||
"modified": "#b296c6",
|
||||
"predictive": "#726E69",
|
||||
"renamed": "#b296c6",
|
||||
"success": "#489e48",
|
||||
"unreachable": "#726E69",
|
||||
"warning": "#f8b63f",
|
||||
"syntax": {
|
||||
"attribute": {
|
||||
"color": "#b296c6"
|
||||
},
|
||||
"boolean": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"comment": {
|
||||
"color": "#726E69",
|
||||
"font_style": "italic"
|
||||
},
|
||||
"comment.doc": {
|
||||
"color": "#726E69",
|
||||
"font_style": "italic"
|
||||
},
|
||||
"constant": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"constructor": {
|
||||
"color": "#b296c6"
|
||||
},
|
||||
"embedded": {
|
||||
"color": "#a8a49d"
|
||||
},
|
||||
"function": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"keyword": {
|
||||
"color": "#ff5874"
|
||||
},
|
||||
"link_text": {
|
||||
"color": "#7fb5e1",
|
||||
"font_style": "normal"
|
||||
},
|
||||
"link_uri": {
|
||||
"color": "#bff5e5",
|
||||
"font_style": "italic"
|
||||
},
|
||||
"number": {
|
||||
"color": "#ff5874"
|
||||
},
|
||||
"string": {
|
||||
"color": "#489e48"
|
||||
},
|
||||
"string.escape": {
|
||||
"color": "#489e48"
|
||||
},
|
||||
"string.regex": {
|
||||
"color": "#489e48"
|
||||
},
|
||||
"string.special": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"string.special.symbol": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"tag": {
|
||||
"color": "#b296c6"
|
||||
},
|
||||
"text.literal": {
|
||||
"color": "#f8b63f"
|
||||
},
|
||||
"title": {
|
||||
"color": "#b296c6",
|
||||
"font_weight": 600
|
||||
},
|
||||
"type": {
|
||||
"color": "#b296c6"
|
||||
},
|
||||
"property": {
|
||||
"color": "#a8a49d"
|
||||
},
|
||||
"variable.special": {
|
||||
"color": "#ff5874"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user