Skip to content

Commit 166029f

Browse files
authored
Merge pull request #505 from NOirBRight/codex/post-release-workspace
release: prepare 0.2.1 workspace fixes
2 parents ede89c6 + 4af87ee commit 166029f

96 files changed

Lines changed: 4270 additions & 1331 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

config/model_pricing_snapshot.json

Lines changed: 609 additions & 0 deletions
Large diffs are not rendered by default.

design.md

Lines changed: 47 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545

4646
## 字体、边框与阴影
4747

48-
- 正文与控件默认 12 px;辅助说明 11 px;日期等紧凑元数据最低 10 px。标题按层级 14–20 px,关键概览数字 24–26 px。
48+
- 正文与控件默认 13 px;辅助说明 12 px;日期等紧凑元数据最低 11 px。标题按层级 14–20 px,关键概览数字 24–26 px。整体默认缩放 110%;Linux 使用原生 WebView zoom,其余环境沿用 FitStage 缩放,布局按缩放后的可用宽高重排
4949
- 普通文字 400–500,控件与标签 500–600,指标 600–700。避免同层级文字同时出现过多字号。
5050
- 边框统一 1 px `--ws-line`。焦点使用 2 px `--ws-accent`,偏移 2 px;键盘操作不能仅依赖悬停。
5151
- 控件、面板、浮层和模态框分别使用 `--ws-shadow-control``--ws-shadow-surface``--ws-shadow-floating``--ws-shadow-overlay`。不为每个按钮发明阴影。
@@ -73,3 +73,49 @@
7373
- 统计时间筛选容器为 8 px,内部按钮为 6 px,未覆盖日历单元和图例圆点。
7474
- 深色 840 × 600 下,模型开/关状态分别使用强调色/边框色,滑块为白色;OpenAI 顶部实际高度与滚动高度同为 276 px。
7575
- 此记录覆盖代码静态规则和上述浏览器状态;未声称穷举所有错误弹窗、平台或系统缩放组合。
76+
77+
## 0.2.0 发布后反馈
78+
79+
- Gateway 独立为顶层页面:连接参数与已保存的三个接口地址固定在上方,真实 Gateway 模型目录在下方独立滚动,按 Provider 分组并可折叠,可按来源和模型名称/ID 筛选并复制。
80+
- 概览移除底部重复导航;统计图例不加顶部分割线。
81+
- Provider 与 Clients 页移除底部说明/跳转栏。Gateway 三个接口地址并排展示,标题在上、URL 在下,保留完整地址 tooltip 和复制按钮,移除可见复制说明。设置与 Gateway 的 Save/Discard 放在顶层 Tab 右侧,不占用底部高度;只读 About 无草稿时隐藏操作。
82+
- 全局 Toast 与页面使用同一组文档级主题变量,包含正文、状态图标、操作和关闭按钮;不能假设浮层在 `.workspace-root` 内。
83+
- Linux 窗口采用 RGBA 透明宿主:正常窗口预留 12 px 透明阴影区,内容面板圆角 14 px,以两层低透明度黑色阴影形成柔和渐变;圆角外不得出现白底或不透明矩形。最大化/全屏取消阴影区并铺满窗口。GTK 样式只作用于主窗口,输入区域保留完整矩形以支持拖动与缩放;验证必须同时覆盖真实 Wayland 合成与 X11 点击。
84+
- Usage 图表只保留一层背景容器,不再叠加带内边距的内层背景框。110% 缩放、1076×820 窗口下,Workspace 与 Provider 列表必须完整显示至少四项;缩减行内留白,保留字体大小和操作控件。
85+
- 品牌图标采用用户确认的 `reference-aligned-b.svg` 描摹版。界面源文件为 `frontend/src/assets/brand/codexhub-icon.svg`,所有打包 PNG/ICO 由该 SVG 通过 `cargo tauri icon` 生成;保留原图比例、灰紫配色与透明外边距,禁止单独重画平台版本。后续更改造型仍需用户确认。
86+
87+
### Scroll regions
88+
89+
- Reserve a stable scrollbar gutter for scrollable lists, settings, dialogs,
90+
menus and previews. Keep an additional 8 px content clearance on unpadded
91+
list regions so overlay scrollbars cannot cover switches or copy buttons.
92+
- Scroll rails stay at the scroll container edge, outside the cards. Provider
93+
is the sole stable exception: its dedicated list may reserve and compensate
94+
for its known right rail width in the page gutter, so cards retain symmetric
95+
margins and no control sits beneath the rail. Do not use conditional negative
96+
margins for other model or provider content.
97+
- Verify both fitting and overflowing content at 110% on native Linux;
98+
scrollbar appearance must not change card widths or hide the final controls.
99+
100+
### Refresh and compact client cards
101+
102+
- Quota panels paint their last successful cached values immediately, then
103+
replace them after a successful refresh. A transient refresh failure keeps
104+
those values; confirmed sign-out clears account quota caches.
105+
- Provider card model previews omit the containing provider's redundant name
106+
prefix. Official models use the same preview treatment.
107+
- At 110% scale, client cards must fit two complete rows at 820 px viewport
108+
height, including configuration path, connection status and switch.
109+
- Search fields with an icon share one background across the wrapper; the
110+
nested input remains transparent.
111+
112+
### Default-window density
113+
114+
- Validate overview density at the default 1024×768 native window, accounting
115+
for 110% zoom and transparent shadow insets: all four resource rows fit.
116+
- Provider cards retain symmetric page margins. Position the scroll rail in
117+
the right page gutter, compensating for the platform's actual rail width.
118+
- Model previews use available width and a single-line ellipsis, never a fixed
119+
two-model limit. Keep enable counts and reorder controls visible.
120+
- The Usage page places its content directly at normal page margins without
121+
an extra outer card, background, border or shadow.

docs/agents/linux-packaging.md

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Linux packaging
22

3-
Linux is a first-class CodexHub surface on the same 0.1.9 train as Windows.
3+
Linux is a first-class CodexHub surface on the same release train as Windows.
44
Do not fork a `linux-main`. Rebase campaign work onto `main` and ship Linux
55
artifacts from the same tag.
66

@@ -32,6 +32,29 @@ groups and capabilities before touching that user's launcher directory.
3232
AppImage upgrades likewise rewrite one stable managed user launcher rather
3333
than adding per-version entries.
3434

35+
Portable builds register the same managed user launcher, pointing at the
36+
running executable (including paths containing spaces). Detection requires
37+
the archive's `CodexHub` executable name and adjacent
38+
`src-python/codex_proxy.py` and `config/providers.toml` resources;
39+
development and system binaries do not create portable launchers. GTK uses
40+
the configured application identifier so GNOME can associate Wayland windows
41+
with this launcher. Customized user launchers remain untouched.
42+
Development binaries also leave existing managed launchers untouched; runtime
43+
cleanup is restricted to the installed `/usr/bin/codexhub` target.
44+
45+
Linux runtime icons refresh all supported hicolor sizes and use a content-hashed
46+
icon name in the managed launcher, preventing GNOME from reusing a cached
47+
older image. Normal windows use an RGBA surface, a rounded panel and a
48+
12-pixel transparent shadow inset; maximized/fullscreen windows omit the
49+
inset. Debian post-install migration recognizes this managed absolute icon
50+
format and archives the portable launcher before installing the package entry.
51+
Verify the packaged build on Wayland as well as X11.
52+
53+
For the GNOME 50 menu-label initialization race and its separately applied,
54+
reversible desktop compatibility patch, see
55+
[GNOME support](../../support/gnome/README.md). Do not count reloading the
56+
indicator as a restart regression test.
57+
3558
Updater platform key: `linux-x86_64`. Add that platform to the existing
3659
`latest.json` / `latest-debug.json` payload; do not invent a second product
3760
channel.
@@ -98,6 +121,22 @@ This host's accepted floors are the same numeric floors as Windows: Codex
98121
Desktop `26.715.8383.0` (Debian package `chatgpt`) and ZCode `3.3.6`.
99122
`open_codex_app` on Linux launches `/usr/bin/chatgpt` / `codex-launcher`.
100123

124+
GNOME dock identity regression includes first launch followed by an upgrade
125+
between two distinct portable directories. The `linux_window` Rust tests load the
126+
resulting desktop entry through GIO and assert both the current executable and
127+
fingerprinted icon file. Run `cargo test --locked --manifest-path
128+
src-tauri/Cargo.toml linux_window`. A portable candidate must also pass
129+
`./scripts/codexhub-python.sh scripts/e2e_linux_dock_icon.py --bin <portable>/CodexHub`.
130+
This starts an isolated headless GNOME session with a populated stale icon cache,
131+
resolves the running window through Shell.WindowTracker, and verifies that its
132+
actual GIcon can load. The release builder runs this check before archiving, so
133+
both first launch and portable-directory upgrade must pass. It requires
134+
GNOME Shell, gdbus, gsettings, and gtk-update-icon-cache; missing dependencies
135+
must not be reported as a pass. Desktop acceptance additionally checks that
136+
the running window resolves to the CodexHub icon rather than the generic gear.
137+
Use isolated test directories; do not include real user paths, configuration,
138+
credentials, or unrelated desktop contents in shared evidence.
139+
101140
Windows CLI real-client E2E remains required for the Windows candidate. It is
102141
not a substitute for the Linux CLI gate, and the Linux gate is not a substitute
103142
for Windows.

docs/agents/pricing-snapshot.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Estimated API prices
2+
3+
`config/model_pricing_snapshot.json` is a prices-only Models.dev snapshot.
4+
Its source URL, retrieval date and SHA-256 identify the reviewed input. It does
5+
not modify the model catalog, capabilities, provider settings or credentials.
6+
7+
Estimates use each model lab's base API tariff in USD per million tokens,
8+
including cache-read rates when available. They do not represent subscription
9+
payments, reseller discounts, peak/off-peak billing or long-context surcharges.
10+
DeepSeek uses its official ordinary tariff regardless of the gateway provider.
11+
Existing explicit Fast model tariffs remain separate.
12+
13+
Refresh with a downloaded, reviewed `https://models.dev/api.json`:
14+
15+
```sh
16+
./scripts/codexhub-python.sh scripts/update_pricing_snapshot.py /path/to/api.json --date YYYY-MM-DD
17+
```
18+
19+
Review the JSON diff before shipping. The importer only selects allowlisted
20+
original labs and known model IDs from maintained visible presets. Explicit
21+
aliases cover selected channel and Ollama names. Missing prices, zero-priced
22+
input/output offers and unresolved aliases remain unknown. No network fetch
23+
occurs while serving requests. The bundled snapshot supersedes stale cached
24+
rates when estimating both historical and new usage; it does not rewrite
25+
usage events. This makes historical figures estimates at snapshot prices,
26+
not reconstructed invoices.
27+
28+
2026-09-07: GPT-5.4 mini cache reads update from the legacy bundled $0.0375
29+
to the snapshot's ordinary API rate of $0.075 per million tokens.

docs/releases/0.2.1.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# CodexHub 0.2.1
2+
3+
This maintenance release completes the workspace UI feedback cycle and improves Linux desktop packaging.
4+
5+
- Compact workspace, Provider, Client, Gateway, and usage layouts now fit the default window size without obscuring controls or list content.
6+
- Provider quota values render cached data before refresh, model labels omit redundant provider prefixes, and draft Gateway keys are copied accurately.
7+
- Linux windows retain transparent rounded corners and shadows. GNOME dock identity uses the current CodexHub icon across first launch and portable-directory upgrades.
8+
- The Linux release builder recovers a verified AppImage runtime bootstrap failure with a pinned runtime and produces a fresh updater signature.

docs/ui/icon-proposals/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Icon exploration
2+
3+
Status: reference-aligned SVG approved by the user and applied to the UI and Tauri PNG/ICO resources.
4+
5+
- Initial flat A/B/C directions rejected as too simple.
6+
- `modern-concepts.png`: built-in image_gen exploration; user preferred B, requested flat style.
7+
- `theme-flat-b.png`: built-in image_gen refinement to theme gray-purple and a three-face cube. This raster contains a checkerboard, so it is reference-only, not a valid transparent shipping asset.
8+
- `refined-b.svg`: rejected manual reinterpretation; its proportions differed from the reference.
9+
- `reference-aligned-b.svg`: current review candidate, traced from the selected reference with transparent outer margins and a lighter cube divider.
10+
- `reference-review.html`: original, SVG and 50% overlay comparison, plus small-size previews. Browser inspection found no obvious doubled silhouette at the displayed comparison scale.
11+
- `trace_reference.py`: reproducible contour extraction; run using `./scripts/codexhub-python.sh docs/ui/icon-proposals/trace_reference.py`.
12+
13+
Generation prompts requested a model-connection hub with a central core and symmetric enclosure, then removed glass/metal/light effects, changed the palette to #8971A7 / #BCA2D8 / gray-purple, and added three cube faces. The current SVG uses traced vector contours rather than an embedded raster. Cube face colors are flat; the original's subtle raster texture is omitted.

docs/ui/icon-proposals/a.svg

Lines changed: 1 addition & 0 deletions
Loading

docs/ui/icon-proposals/b.svg

Lines changed: 1 addition & 0 deletions
Loading

docs/ui/icon-proposals/c.svg

Lines changed: 1 addition & 0 deletions
Loading

docs/ui/icon-proposals/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<!doctype html><meta charset="utf-8"><meta http-equiv="refresh" content="0;url=reference-review.html"><a href="reference-review.html">原图与 SVG 对照</a>

0 commit comments

Comments
 (0)