[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-116452":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":17,"stars90d":15,"forks30d":15,"starsTrendScore":18,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":23,"hasPages":21,"topics":24,"createdAt":10,"pushedAt":31,"updatedAt":32,"readmeContent":33,"aiSummary":34,"trendingCount":15,"starSnapshotCount":15,"syncStatus":35,"lastSyncTime":36,"discoverSource":37},116452,"antigravity-codex-theme","nkjDSLcvanv\u002Fantigravity-codex-theme","nkjDSLcvanv","Google Antigravity 桌面端增强插件：Codex 昼夜双主题、原生设置页与一键热更新、1,900+ 中文汉化、四态状态灯与实时用量监控（含旁路提问 \u002F SSH 远端）、可选 Tab 下一句预测。不改安装包，模块化按需安装。","",null,"JavaScript",508,28,8,0,116,390,619,94.14,"MIT License",false,"main",true,[25,26,27,28,29,30],"antigravity","chinese","codex-theme","localization","theme","token-usage","2026-11-23 07:51:18","2026-11-23 20:31:51","\u003Cdiv align=\"center\">\n\n\u003Ch1>antigravity-codex-theme\u003C\u002Fh1>\n\n\u003Cp>\u003Cstrong>Google Antigravity 的 Codex 风格昼夜主题、中文界面与实时会话统计插件\u003C\u002Fstrong>\u003C\u002Fp>\n\n\u003Cp>\n  \u003Ca href=\"#快速安装\">快速安装\u003C\u002Fa> ·\n  \u003Ca href=\"#按需安装\">按需安装\u003C\u002Fa> ·\n  \u003Ca href=\"#功能详解\">功能详解\u003C\u002Fa> ·\n  \u003Ca href=\"#自定义与卸载\">自定义与卸载\u003C\u002Fa> ·\n  \u003Ca href=\"#致谢与协议\">致谢与协议\u003C\u002Fa> ·\n  \u003Ca href=\"#english-overview\">English\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003Cp>\n  不修改安装包，通过本地 CDP 实时注入 Codex 昼夜主题、中文界面、四态会话指示与每轮 Token 统计。\u003Cbr>\n  核心代码拆分为 27 个独立模块，支持 \u003Ccode>--only\u003C\u002Fcode> 按需安装与 Fork 自由定制。\n\u003C\u002Fp>\n\n\u003Cp>\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002FnkjDSLcvanv\u002Fantigravity-codex-theme\u002Factions\u002Fworkflows\u002Fci.yml\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Factions\u002Fworkflow\u002Fstatus\u002FnkjDSLcvanv\u002Fantigravity-codex-theme\u002Fci.yml?branch=main&label=CI&labelColor=363636&logo=githubactions&logoColor=white\" alt=\"CI\">\u003C\u002Fa>\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=Antigravity&message=2.30.x%20~%202.34.0%2B&color=2B7FFF&labelColor=363636\" alt=\"Antigravity 2.30.x ~ 2.34.0+\">\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=Node.js&message=%3E%3D%2022.13.0&color=339933&labelColor=363636&logo=nodedotjs&logoColor=white\" alt=\"Node.js >= 22.13.0\">\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=platform&message=macOS%20%C2%B7%20Windows%20%C2%B7%20Linux&color=4B5563&labelColor=363636\" alt=\"macOS · Windows · Linux\">\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=version&message=v1.2.0&color=2B7FFF&labelColor=363636\" alt=\"version v1.2.0\">\n  \u003Ca href=\"LICENSE\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=license&message=MIT&color=10B981&labelColor=363636\" alt=\"MIT License\">\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003Cp>\n  \u003Ca href=\"#命令行安装\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=CLI%20INSTALL&message=v1.2.0&color=2B7FFF&style=for-the-badge&labelColor=181818&logo=gnubash&logoColor=white\" alt=\"CLI Install\">\u003C\u002Fa>\n  \u003Ca href=\"#ai-一键安装\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=AI%20ONE-CLICK&message=SKILL.md&color=0D9488&style=for-the-badge&labelColor=181818&logo=googlegemini&logoColor=white\" alt=\"AI One-Click Install\">\u003C\u002Fa>\n  \u003Ca href=\"#按需安装\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=SELECTIVE%20INSTALL&message=--only&color=6366F1&style=for-the-badge&labelColor=181818&logo=codesandbox&logoColor=white\" alt=\"Selective Install\">\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003C\u002Fdiv>\n\nhttps:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Fe42ae3d6-c261-442c-bc6d-3c14ff830664\n\n![Codex 浅色与深色模式对比](assets\u002Flight-dark-themes.png)\n\n- 提供浅色 (`codex-pure-white`) 与深色 (`codex-dark`) 两套配色，无外部字体依赖，随 IDE 明暗外观自动切换。\n- 底部工具栏实时指示会话状态与用量摘要，支持展开两级明细面板；每轮回复末尾附带 Token 统计，悬停约 `80ms` 显示详情拆解卡，并同步支持右侧旁路提问（Side Question）面板。\n- 内置 `1,900+` 条中文界面词条；4 个核心模块相互独立，可通过 `--only` 按需安装。\n\n![一级概览、二级详情、上下文预警及每轮对话尾部统计](assets\u002Ftelemetry-bento-panels.png)\n\n## 快速安装\n\n> 前置要求：**Node.js >= 22.13.0**（与 [package.json](package.json) 一致）与 Google Antigravity（`2.30.x` 至 `2.34.0+`），已在 **macOS \u002F Windows \u002F Linux 桌面端**完成实机安装与卸载验证。安装仅部署至 `~\u002F.gemini\u002Fantigravity\u002Fcodex-theme`、配置本地调试端口并注册后台自启，**不修改安装包本体**；若安装前应用已在无调试端口状态下运行，重启一次或在外部终端执行 `node install.mjs relaunch` 即可生效。\n\n\u003Cdetails>\n\u003Csummary>查看各平台实测细节与 Antigravity 2.33.0+ 调试端口说明\u003C\u002Fsummary>\n\n- **实机验证范围**：已在 macOS、Windows 与 Linux 桌面端完成安装、实时注入与卸载还原测试（覆盖 Antigravity `2.31.0` \u002F `2.32.1` \u002F `2.33.0` \u002F `2.34.0`、macOS `LaunchAgent`、Windows `schtasks` \u002F VBS \u002F 注册表与 `.lnk` 参数配置、Linux `systemd --user` 与 `.desktop` 启动项）；GitHub Actions CI 在 `ubuntu-latest` 上持续执行 `npm run check` 与 `npm test`。\n- **Antigravity `2.33.0+` 适配**：新版本默认关闭本地 `DevToolsActivePort`，需携带 `--remote-debugging-port=0` 启动。macOS 默认采用单图标模式，后台守护进程仅在冷启动前 `12s`（自动更新重启时 `25s`）内补参接力重启，不中断已在运行中的会话；Windows 与 Linux 则为快捷方式或 `.desktop` 启动项追加该参数，并保留 `~\u002F.antigravity\u002Fargv.json` 兼容写入。\n\n\u003C\u002Fdetails>\n\n### 命令行安装\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FnkjDSLcvanv\u002Fantigravity-codex-theme.git\ncd antigravity-codex-theme\nnode install.mjs install\nnode --disable-warning=ExperimentalWarning install.mjs doctor\n```\n\n### AI 一键安装\n\n将以下提示词发送给 AI 助手（Antigravity \u002F Claude Code \u002F Codex \u002F Cursor 等），自动完成拉取、部署与状态校验：\n\n> 请读取 `https:\u002F\u002Fgithub.com\u002FnkjDSLcvanv\u002Fantigravity-codex-theme.git`，使用 `git clone --depth=1 --filter=blob:none --sparse` 拉取核心文件（参考仓库内的 `SKILL.md`，跳过 `assets\u002F` 和 `tests\u002F`；如需只装部分功能可追加 `--only` 参数），运行 `node install.mjs install`、`node --disable-warning=ExperimentalWarning install.mjs doctor` 和 `verify` 完成安装并确认实时注入正常。\n\n### 按需安装\n\n支持通过 `--only` 从 `theme`、`i18n`、`metrics`、`fixes` 四个独立模块中按需组合：\n\n```bash\n# 示例：仅启用中文界面与实时统计，保留 Antigravity 原生配色\nnode install.mjs install --only i18n,metrics\n```\n\n\u003Cdetails>\n\u003Csummary>查看模块说明与精简拉取命令（跳过截图或单模块下载）\u003C\u002Fsummary>\n\n| 模块 | 说明 |\n| :--- | :--- |\n| `theme` | Codex 浅色 (`codex-pure-white`) 与深色 (`codex-dark`) 昼夜主题 |\n| `i18n` | 中文界面本地化（`1,900+` 条词条，`WeakMap` 原地更新） |\n| `metrics` | 实时会话状态指示、一\u002F二级用量统计面板与每轮对话尾部统计（含旁路提问面板） |\n| `fixes` | 设置弹窗路由死锁修复与 `Cmd\u002FCtrl + -\u002F=\u002F0` 界面缩放快捷键 |\n\n**1. 跳过 `assets\u002F` 与 `tests\u002F`，仅拉取运行核心文件（全平台通用）：**\n\n```bash\ngit clone --depth=1 --filter=blob:none --sparse https:\u002F\u002Fgithub.com\u002FnkjDSLcvanv\u002Fantigravity-codex-theme.git\ncd antigravity-codex-theme\ngit sparse-checkout set core user\nnode install.mjs install --only i18n,metrics\n```\n\n**2. 仅下载目标模块对应文件（`--no-cone` 单模块拉取，适用于 macOS \u002F Linux \u002F Git Bash）：**\n\n```bash\n# 示例：仅下载并安装中文界面模块 (i18n)\ngit clone --depth=1 --filter=blob:none --sparse https:\u002F\u002Fgithub.com\u002FnkjDSLcvanv\u002Fantigravity-codex-theme.git\ncd antigravity-codex-theme\ngit sparse-checkout set --no-cone \\\n  \u002Finstall.mjs \u002Fpackage.json \u002FSKILL.md \u002FLICENSE \\\n  \u002Fuser\u002Fconfig.json \u002Fuser\u002Fcustom.css \u002Fuser\u002Fcustom.js \u002Fuser\u002Fi18n.override.json \\\n  \u002Fcore\u002Fdaemon.mjs \u002Fcore\u002Fshared.mjs \u002Fcore\u002Fmanifest.json \u002Fcore\u002Finstaller \\\n  \u002Fcore\u002Fdaemon\u002Fpaths.mjs \u002Fcore\u002Fdaemon\u002Fcdp-bridge.mjs \u002Fcore\u002Fdaemon\u002Fcdp-relaunch.mjs \\\n  \u002Fcore\u002Fruntime\u002F00-head.js \u002Fcore\u002Fruntime\u002F90-tail.js \\\n  \u002Fcore\u002Fi18n.json \u002Fcore\u002Fruntime\u002F60-i18n-engine.js\nnode install.mjs install --only i18n --minimal\n```\n\n若已执行 `git sparse-checkout set core user`，可通过 `node install.mjs sparse-paths --only theme,metrics` 查询任意模块组合对应的文件列表。\n\n\u003C\u002Fdetails>\n\n\u003Cdetails>\n\u003Csummary>常用运维、回滚与测试命令\u003C\u002Fsummary>\n\n| 命令 | 用途 |\n| :--- | :--- |\n| `node install.mjs install [--channel auto\\|stable\\|insiders] [--only \u003Cfeatures>] [--minimal] [--with-launcher] [--sync-user]` | 部署或升级插件并注册后台自启服务 |\n| `node install.mjs relaunch [--channel auto\\|stable\\|insiders] [--force]` | 携带 `--remote-debugging-port=0` 重启 Antigravity 并完成注入校验（含 15s 活跃会话保护） |\n| `node --disable-warning=ExperimentalWarning install.mjs doctor` | 检查 Node 版本、Antigravity 版本与 CDP 状态、`core\u002Fmanifest.json` 哈希及页面挂载结果 |\n| `node --disable-warning=ExperimentalWarning install.mjs verify [--safe-mode]` | 执行单次注入并校验挂载状态；`--safe-mode` 可跳过 `user\u002F` 自定义脚本排障 |\n| `node install.mjs sparse-paths --only \u003Cfeatures>` | 输出指定模块组合的文件路径列表 |\n| `node install.mjs rollback` | 回滚至上一份备份的 `core\u002F` 版本 |\n| `node install.mjs uninstall` | 停止服务、清理自启项与启动参数，并恢复默认英文界面与原生样式 |\n| `npm run check` | 对所有 `.mjs` 脚本与拼接后的 `core\u002Fruntime\u002F*.js` 执行语法检查 |\n| `npm test` | 运行 `tests\u002F*.test.mjs` 单元测试（协议解析、状态机、模块打包、`2.33.0` 重启门禁与仓库校验） |\n\n\u003C\u002Fdetails>\n\n## 功能详解\n\n### 实时会话状态与用量统计\n\n在输入框底部工具栏中部（模型选择器与权限\u002F发送按钮之间）嵌入紧凑的会话状态指示与摘要栏，悬停时显示 `会话状态：...` 提示：\n\n```text\n● 248 tok\u002Fs · Ctx 42% · Cache 90.9%\n```\n\n| 会话状态 | 圆点样式 | 触发条件 |\n| :--- | :--- | :--- |\n| 就绪 | **蓝色常亮** | 会话连接正常且处于空闲状态；主动取消生成后立即恢复 |\n| 执行中 | **蓝色闪烁** | 模型流式生成、`\u002Fcompact` 压缩或工具调用正在进行 |\n| 等待或重试 | **黄色脉冲** | 首字或单步等待超过 `60s`（如切换模型后 `\u002Fcompact` 重算 KV 缓存）、模型不可用自动重试，或建连耗时 `3s ~ 11s` |\n| 连接或执行异常 | **红色脉冲** | 网络离线、建连超时 `>= 12s`、API 或步骤报错（不含主动取消），或后台统计进程心跳超时 `>= 90s` |\n\n![会话状态：就绪、执行中、等待或重试、连接或执行异常](assets\u002Fled-status-states.png)\n\n\u003Cp align=\"center\">\u003Cem>会话状态：就绪、执行中、等待或重试、连接或执行异常\u003C\u002Fem>\u003C\u002Fp>\n\n#### 用量面板与上下文预警\n\n- 悬停在状态栏上可预览一级面板，单击可固定展开，展示最近一次调用的生成速度（`tok\u002Fs` 与端到端均值）、上下文占比与剩余容量、累计缓存命中率、当前上下文分段条（新增 \u002F 写缓存 \u002F 读缓存 \u002F 剩余）以及等待或异常原因。\n- 再次点击状态栏（或点击面板内的「展开明细」）可展开二级面板，补充首字延迟（TTFT）、流式耗时、思考与正文输出拆分、本轮多步汇总及会话累计输入输出；点击空白处、按 `Esc` 或第三次点击状态栏即可收起。\n- 上下文占比达到 `>= 75%` 时转为黄色预警，`>= 90%` 时转为红色提示；执行 `\u002Fcompact` 期间实时显示压缩进度（跨模型切换压缩时提示 KV 缓存重算），完成后以绿色标记展示摘要大小（面板效果见文首总览图）。\n\n#### 状态栏自适应布局\n\n底部状态栏支持三种显示形态，可通过 [user\u002Fconfig.json](user\u002Fconfig.json) 中的 `telemetryLayout` 切换：\n\n- `compact`（默认）：在工具栏居中显示核心指标（`tok\u002Fs`、`Ctx`、`Cache`）。\n- `detailed`：补充展示首字延迟（`TTFT`）、精确上下文与本步输出（`Out`）。\n- 窄侧栏自适应：工具栏宽度不足时自动移至输入框底部独立虚线行，不遮挡模型选择器与发送按钮。\n\n![白日模式下状态栏三种自适应布局](assets\u002Ftelemetry-layouts.png)\n\n\u003Cp align=\"center\">\u003Cem>状态栏三种自适应布局：默认紧凑、详细模式与窄侧栏自动换行\u003C\u002Fem>\u003C\u002Fp>\n\n#### 每轮对话尾部统计\n\n每条助手回复底部的操作栏左侧附带当轮统计摘要，包含模型名称、输入输出 Token、缓存命中率与生成速度。鼠标悬停约 `80ms` 弹出详情卡，展示当轮步数、精确上下文占比、思考与正文\u002F工具输出拆分、新增与读缓存输入，以及流式与总耗时：\n\n![每轮对话尾部统计悬浮详情卡](assets\u002Fturn-hover-card.png)\n\n\u003Cp align=\"center\">\u003Cem>每轮助手回复尾部统计与悬浮详情卡\u003C\u002Fem>\u003C\u002Fp>\n\n### 中文界面汉化\n\n内置 `1,900+` 条界面词条，覆盖 Antigravity `2.30.x` 至 `2.34.0+` 的设置面板（含 Orchestrator 设置与沙箱权限）、菜单、权限选项、侧边栏、旁路提问、插件管理与工具审批状态。通过 `WeakMap` 在原文本节点直接替换，不克隆节点，不影响 React 事件绑定。可通过 [user\u002Fi18n.override.json](user\u002Fi18n.override.json) 自定义或覆盖词条，也可在配置中关闭 `i18n` 恢复英文界面。\n\n### Codex 昼夜主题与实用修复\n\n- 浅色 (`codex-pure-white`)：`#FFFFFF` 画布、`#F9F9F9` 侧边栏、`#EFEFEF` 选中项、`#2B7FFF` 主按钮，搭配 `#F3F4F6` 外托盘与 `#FFFFFF` 内卡片的双层圆角输入框。\n- 深色 (`codex-dark`)：采用 Codex 桌面端中性炭灰配色，包含 `#181818` 主背景、`#232323` 侧边栏、`#353535` 选中项、`#282828` 外托盘、`#363636` 输入卡片与 `#2C67C5` 主按钮。\n- 实用修复：修复设置弹窗路由死锁，补充 macOS (`Cmd + -\u002F=\u002F0`) 与 Windows\u002FLinux (`Ctrl + -\u002F=\u002F0`) 界面缩放快捷键，并支持 Antigravity `2.33.0+` 单图标冷启动自动接力。\n\n## 自定义与卸载\n\n日常调整配色、词条或功能开关只需修改 `user\u002F` 目录下的配置文件；若需深度修改主题样式或统计面板，可直接 Fork 仓库并调整 `core\u002F` 下的对应模块。\n\n### 配置与热重载（`user\u002F` 目录）\n\n个人配置位于 `~\u002F.gemini\u002Fantigravity\u002Fcodex-theme\u002Fuser\u002F`，升级插件时不会被覆盖。保存后约 2.5 秒自动同步至已打开的 Antigravity 窗口，无需重启：\n\n- [user\u002Fconfig.json](user\u002Fconfig.json)\n  - `preset`：`\"codex-pure-white\"` 或 `\"codex-dark\"`\n  - `themeVars`：按需覆盖 `--background`、`--sidebar`、`--primary`、`--ag-composer-*`、`--ag-dark-*` 等 CSS 变量\n  - `telemetryLayout`：`\"compact\"`（默认紧凑样式）或 `\"detailed\"`（显示 `TTFT`、精确上下文与 `Out`）\n  - `telemetryCacheMode`：`\"session\"`（会话累计命中率）或 `\"step\"`（单步命中率）\n  - `modules`：独立控制 `theme`、`i18n`、`metrics`、`deadlockHealer`、`zoomShortcuts`、`cdpAutoRelaunch`、`customCss`、`customJs` 开关\n- [user\u002Fi18n.override.json](user\u002Fi18n.override.json)：追加或覆盖界面翻译词条。\n- [user\u002Fcustom.css](user\u002Fcustom.css) 与 [user\u002Fcustom.js](user\u002Fcustom.js)：注入自定义样式与前端脚本钩子，支持热重载自动清理。\n\n### 源码定制（`core\u002F` 目录）\n\n核心代码拆分为 27 个独立模块，配套 27 项 `node:test` 单元测试，可按职责定位修改：\n\n| 定制方向 | 对应文件 |\n| :--- | :--- |\n| 替换浅色或深色主题样式 | [core\u002Fstyles\u002F10-light-codex.css](core\u002Fstyles\u002F10-light-codex.css)、[core\u002Fstyles\u002F20-dark-codex.css](core\u002Fstyles\u002F20-dark-codex.css)（公共布局位于 `00-base.css`） |\n| 调整状态判定阈值或统计面板渲染 | [core\u002Fruntime\u002F40-status-machine.js](core\u002Fruntime\u002F40-status-machine.js)、[core\u002Fdaemon\u002Ftelemetry-renderer.mjs](core\u002Fdaemon\u002Ftelemetry-renderer.mjs)、[core\u002Fstyles\u002F30-telemetry.css](core\u002Fstyles\u002F30-telemetry.css) |\n| 增删 `--only` 模块分组 | [core\u002Finstaller\u002Ffeatures.mjs](core\u002Finstaller\u002Ffeatures.mjs) |\n| 修改词典或文本替换规则 | [core\u002Fi18n.json](core\u002Fi18n.json)、[core\u002Fruntime\u002F60-i18n-engine.js](core\u002Fruntime\u002F60-i18n-engine.js) |\n\n修改 `core\u002F` 后，执行以下命令即可更新文件哈希清单、完成语法与单元测试并部署至本机：\n\n```bash\nnode install.mjs build-manifest && npm run check && npm test && node install.mjs install\n```\n\n\u003Cdetails>\n\u003Csummary>查看仓库目录结构\u003C\u002Fsummary>\n\n```text\nantigravity-codex-theme\u002F\n├── assets\u002F                     # README 展示截图\n├── core\u002F\n│   ├── daemon\u002F                 # 后台同步服务（配置热加载 \u002F Protobuf 解析 \u002F 重试日志 \u002F 面板渲染 \u002F SQLite \u002F CDP \u002F 2.33.0 冷启动接力）\n│   ├── runtime\u002F                # 按序拼接注入的前端脚本（生命周期 \u002F 修复补丁 \u002F 明暗同步 \u002F 状态机 \u002F 统计界面 \u002F 汉化引擎）\n│   ├── styles\u002F                 # 样式模块（基础结构 \u002F Codex 浅色 \u002F Codex 深色 \u002F 状态与统计面板）\n│   ├── installer\u002F              # 模块分组 \u002F Manifest 校验与打包 \u002F 环境探测 \u002F 跨平台自启与 CDP 启动管理\n│   ├── daemon.mjs              # 后台服务入口\n│   ├── shared.mjs              # 公共工具函数\n│   ├── i18n.json               # 1,900+ 界面词典\n│   └── manifest.json           # core\u002F 文件 SHA-256 清单\n├── tests\u002F                      # 27 项 node:test 单元测试\n├── user\u002F                       # 个人配置与热重载目录\n├── install.mjs                 # 安装、重启与运维 CLI\n├── SKILL.md                    # AI Agent 操作说明\n└── LICENSE                     # MIT License\n```\n\n\u003C\u002Fdetails>\n\n### 卸载与保留说明\n\n执行 `node install.mjs uninstall` 时的处理范围：\n\n- **移除与还原**：停止后台同步进程，删除系统自启项（macOS `LaunchAgent` plist、Linux `systemd --user` unit、Windows 计划任务与启动脚本）及托管的 CDP 启动参数，并将已打开的 Antigravity 窗口恢复为默认英文界面与原生样式。\n- **保留项**：保留个人配置目录 `~\u002F.gemini\u002Fantigravity\u002Fcodex-theme\u002Fuser\u002F`（`config.json`、`i18n.override.json`、`custom.css`、`custom.js`）、历史版本备份 `backups\u002F` 与 `core.prev\u002F`，以及安装时写入 `~\u002F.antigravity\u002Fargv.json`（或 `~\u002F.antigravity-insiders\u002Fargv.json`）中的 `\"remote-debugging-port\"` 字段。如需彻底清除，手动删除上述目录与配置字段即可。\n\n## 致谢与协议\n\n本项目早期在调研 Antigravity 的 CDP 运行时注入、`WeakMap` 原地文本替换、SQLite 增量读取及 `2.33.0` `--remote-debugging-port=0` 启动接力方案时，参考了 [Anarcadia\u002Fchuanban-antigravity-theme-patch](https:\u002F\u002Fgithub.com\u002FAnarcadia\u002Fchuanban-antigravity-theme-patch)（MIT），特此致谢。\n\n在此基础上，本项目对代码结构与核心功能进行了重写与扩展，主要区别包括：\n\n- 将单文件实现重构为 `core\u002F{daemon,runtime,styles,installer}` 下的 27 个独立模块，补充 27 项 `node:test` 单元测试与 GitHub Actions CI。\n- 重新设计无外部字体依赖的 Codex 浅色 \u002F 深色双主题与双层圆角输入框。\n- 新增四态会话状态机（结合 React Fiber 状态探测、Language Server 重试日志与后台心跳监测）、可逐级展开的一\u002F二级用量面板，以及每轮回复 `80ms` 悬浮详情卡。\n- 支持 `--only` \u002F `--without` \u002F `--minimal` \u002F `sparse-paths` 按需安装，分离 `user\u002F` 热重载配置层与 `core\u002F` 模块层以便二次定制。\n\n本项目基于 [MIT License](LICENSE) 开源，欢迎自由 Fork 与定制。\n\n## English Overview\n\n`antigravity-codex-theme` provides Codex light and dark themes, Chinese UI localization, and live session telemetry for Google Antigravity (`2.30.x` to `2.34.0+`). The codebase is organized into 27 modules under `core\u002F{daemon,runtime,styles,installer}` with 27 `node:test` unit tests, supporting hot-reloaded customization in `user\u002F` as well as deeper modifications in `core\u002F`.\n\n- Light (`codex-pure-white`) and dark (`codex-dark`) themes with zero external font dependencies and automatic light\u002Fdark switching.\n- A live bottom status bar tracking four session states (ready, running, waiting or retrying, error) via React Fiber probes, Language Server logs, and SQLite telemetry, paired with two-level usage panels and per-turn token stats with an `80ms` hover breakdown card across both main conversations and Side Question panes.\n- Chinese UI localization (`1,900+` entries) applied in place through a `WeakMap` observer, customizable via `user\u002Fi18n.override.json`.\n- Selective module installation via `--only` (`theme`, `i18n`, `metrics`, `fixes`), Git sparse checkout, and `--minimal` pruning.\n- Antigravity `2.33.0+` \u002F `2.34.0+` support with a single-icon `--remote-debugging-port=0` cold-start relay (`cdpAutoRelaunch`) and `node install.mjs relaunch` with active-WAL protection. End-to-end installation and uninstall are verified across macOS, Windows, and Linux desktops (Antigravity `2.31.0`, `2.32.1`, `2.33.0`, and `2.34.0`; requires Node.js `>= 22.13.0`), alongside Ubuntu CI syntax checks and unit tests.\n\nEarly research drew inspiration from [Anarcadia\u002Fchuanban-antigravity-theme-patch](https:\u002F\u002Fgithub.com\u002FAnarcadia\u002Fchuanban-antigravity-theme-patch) (MIT) for CDP runtime injection, `WeakMap` localization, SQLite telemetry, and `2.33.0` opt-in launch handling. This repository rebuilds the architecture into modular components and adds the Codex light\u002Fdark themes, four-state session monitor, two-level usage panels, per-turn hover cards, and selective installs under the [MIT License](LICENSE).\n","这是一个为 Google Antigravity 客户端定制的 Codex 风格主题增强插件，提供浅色与深色 UI 主题、简体中文界面本地化、实时会话状态指示及每轮对话 Token 使用量统计。其采用非侵入式设计，通过 Chrome DevTools Protocol（CDP）动态注入样式与逻辑，全程不修改 Antigravity 原始安装包；核心功能模块化拆分，支持按需安装（如仅启用汉化或仅启用 Token 统计）。适用于需要提升可读性、多语言支持与开发调试透明度的本地 AI 交互场景，尤其适合关注提示工程效率与资源消耗的中文用户。",2,"2026-11-24 04:53:34","CREATED_QUERY"]