Commit Graph
12 Commits
Author SHA1 Message Date
yetone 8e9b048b65 settings: a row's explanation shows on hover, not under every name
The owner (11-02, a screenshot of Settings › 模型): hide the lines that
explain a setting and show them on hover, so the page reads quiet and
open ("很简洁,很有呼吸感"). Settings' rows now rest as a name and a
control. The pointer resting on a row (450ms, so passing over rows shows
nothing), or a key reaching its control, shows its explanation whole in a
card under the row's name, or over the row where the window ends; the
card takes no pointer and no row moves. It goes when the pointer or focus
leaves, a key is pressed, or the page scrolls (focus's card follows its
row instead, as Tab scrolls it into sight).

- app.css: in #view-settings, under (hover: hover), a .row.pref's plain
  .sub lines are clipped out of sight, not removed, so a screen reader
  and the search still read them; each carries --hint: 1, which the card
  reads. A search shows them in place again, as before. A touch screen
  keeps them all.
- Stays in sight: errors (.err, .bad), states (.say, [role=status],
  .proxy-check), warnings (.image-gen-hidden, .sync-sign-in,
  .vision-not-marked), .no-names, .pv-hits, .feat-why, .font-note, the
  proxy in use (#proxySub), and any line with a button, link, input,
  code or a search provider's failure note in it (.acts, which
  settingshints.js sets on each such line as it is drawn, through a
  MutationObserver, so before it is painted: Safari before 15.4 has no
  :has(), and old-webkit holds the styles to 15.0). Disclosures stay too: what tracing sends (otel's
  sessions row) and the allow list's addresses, as do a disabled
  pattern's matches. .say is new, on the lines that are a state, not an
  explanation: the version row's update state, a sync's last sync, the
  sync notice, the web page's "Served" line, the local masking model's
  state (downloading, on, failed; its two explaining lines, before it is
  on, are hidden) and what Check in now came to.
- One-line rows are one height: a row left with its name alone was 48
  to 51px by its control (the owner, 10-22: one-line rows of one
  height), so under (hover: hover) every Settings .row.pref has a 27px
  content-box min-height, 51px with its padding, its line above outside
  it. Check in now's row aligns to its top, so its result line grows the
  row down and the button stays where it was pressed.
- app.js stays in the core budget (1,533,799 of 1,533,802 at this
  head, on main's 1,533,789) with three comments shortened, no raise.
- settingshints.js: the card and the .acts marks, a module app.js
  imports at start, not in index.html (one line in app.js; old-webkit's
  list of such modules names it). Its :focus-visible check is in a try,
  as Safari before 15.4 throws on it.

Tests, run on mote (macOS) at this tree:
- settings-hints.test.cjs (new): Chromium and WebKit, 1100 and 420px,
  en/zh/zh-TW/ja/de, Settings › Models. At rest the Image recognition MCP
  server's line is out of sight and still in the page; a gone model's
  error and an unticked image model's warning stay in sight; hover shows
  the whole line in a card off the row's name, inside the window, no row
  box moved, pointer-events none; the pointer leaving hides it; Tab (or
  Option-Tab in WebKit) to the row's copy button shows it; a search shows
  it in place; a line given a link shows at once and rests again when
  the link goes. 20/20 green.
- Broken by hand: with the clipping rule's body gone, 20/20 red on "the
  explanation shows at rest"; with app.js's import line gone, 20/20 red
  waiting for the card; with the .acts observer gone, Chromium 10/10 red
  on the link line. Before the kept lines and the row height were
  in, checkin-now-account was 20 red (the result line hidden, then the
  button moved 7px) and settings-general 10 red at 1000px (one-line rows
  48, 50 and 51px); both green with them.
- settings-lines-wrap.test.cjs: a hidden explanation is skipped by its
  "cut short" measure and checked whole in its card instead (#visionMcpRow
  and the searcher row). 20/20 green.
- 22 more GUI files checked a Settings explanation's text, width or
  wrapping in place; each now checks the text and that it is hinted, and
  skips its geometry (redact-*, privacy-model, settings-general,
  searcher-pick, disabled-models, the *-setting rows, images-codex-one,
  and reply-model-setting, new on main since: red 20 of 22 on ".sub
  fits" until it got the same check, then 22/22).
  These 24 files: 536 pass, 2 fail, both images-codex-one's #pop picker
  race, red the same on untouched origin/main 173b7e274 alone (13/18;
  #4618, commented).
- At this tree, on mote: those 25 files, old-webkit and i18n-keys, all
  green but images-codex-one's #4618 race (3 red). After the last
  rebase (ae060550b, 1a92a97ca) and the comments cut: privacy-model,
  settings-hints, old-webkit, desktop-tiers, i18n-keys green, and
  -run 'Budget|Core' ./internal/gui ok. old-webkit was red before .acts (":has()
  (Safari 15.4)" and settingshints.js unlisted). go test -count=1
  ./internal/gui: ok but TestMainWindowCorners (#3949, macOS 27).
- The whole GUI suite on mote (concurrency 3), one commit before .acts:
  cut short when mote went down mid-run (it rebooted). 25 files had
  reds by then. The 4 that open Settings are main's filed reds
  (gateway-caller-keys #3797, omarchy #4624, mobile-web #3952,
  images-codex-one #4618); the other 21 don't open Settings. Run on
  Linux (wsl-run, magpie-desktop), those 21: 269 pass, 98 fail here;
  270 pass, 97 fail on untouched origin/main 173b7e274, the same files
  red. The one difference was old-webkit, fixed above.
  The whole suite was not run again after .acts.

Not tried: the real app's WebKitGTK (Linux) and WebView2 (Windows), and
a real touch screen; the (hover: none) path is only by the media query.
2026-11-03 09:47:25 +08:00
yetone ed978e560f gui: the Quit question's Don't ask again, and Settings › General › Ask before quitting (zhujiu on Discord)
zhujiu (Discord #feedback) asked for a 不再提示 on the question a tray
Quit asks while agents go through magpie (8826a15ea), and a switch in
Settings to turn it on and off again.

- The question (quitask.js, an in-app sheet) has a "Don't ask again"
  checkbox above its buttons, unticked each time. It goes with the Quit
  chosen: Quit and Disconnect and quit post window/quit?now=1&noAsk=1,
  which saves settings.quitNoAsk (settings.SetQuitNoAsk, under the file
  lock) before quitting; a failed save keeps magpie open. Cancel saves
  nothing.
- AskQuit quits at once when quitNoAsk is set (quitAtOnce); otherwise as
  before. The default is unchanged: it asks.
- Settings › General has "Ask before quitting" On/Off (segs, app-only),
  after Open at login. settingsapi.Keys lists quitNoAsk, and Merge carries
  it when a save doesn't send it, so the tray panel or an older page
  can't turn the question back on.
- zh, zh-TW, ja, de strings. Five app.js comments shortened to stay in
  the core script budget (no raise).

Run at the pushed head (on origin/main f95bacdfb), on mote:
- gofmt clean; go vet darwin, linux, windows (nogui too).
- go test internal/settings, internal/settingsapi ok; internal/gui
  -run "Budget|Quit" ok.
- internal/cli: TestEveryRouteHasACommandOrIsNamed red for
  POST /api/usage/checkin-account, from e87140242, filed as #4826; this
  change adds no route.
- GUI, chromium and webkit: quit-ask-setting (25: en, zh, zh-TW, ja, de
  at 1100 and 420), quit-ask (35), settings-general, settings-sections,
  settings-search, settings-tabs-stick, wsl-agents-setting, agent-prefs,
  i18n-keys, old-webkit, auto-backup, all pass.

Broken by hand, each red:
- api.go's noAsk ignored: TestQuitDontAskAgain "wasn't saved".
- quitAtOnce not reading the setting: TestQuitDontAskAgain "still asks".
- Merge carry dropped: TestQuitNoAskKeptUnlessSent.
- SetQuitNoAsk saving false: TestSetQuitNoAsk.
- quitask.js without &noAsk=1: quit-ask's two Don't ask again tests.

Not tried: a real tray Quit with the box ticked in the built app on
macOS, Windows or Linux; only the sheet in Playwright and the handler
in Go. Not the whole GUI suite.
2026-11-02 18:53:07 +08:00
yetone ce8b67de37 gui tests: a page's first load gets a minute, not a click's 5s (#4470)
claude-switch-only set page.setDefaultTimeout(5000) and then called
page.goto with no timeout of its own, so Playwright held the first load
of app.js, i18n.js and the plugins to the 5s bar meant for clicks. On a
busy box (a whole-suite run at load 130-160) that load took longer and
goto timed out. The same pattern is in 988 GUI test files (1174 pages):
every one of them now also sets setDefaultNavigationTimeout(60000) on
the same page, right after its default, so goto, reload and waitForURL
wait on the load itself with room, while clicks and waits keep their
short bar. group-from-model-add's own 20s navigation bar is raised to the
same minute. claude-switch-only also gives its first provider row (drawn
from the page's first reads) a minute before clicking it.

nav-timeout.test.cjs (no browser) reads every GUI test file and names
each page given a default under a minute without a navigation timeout of
at least a minute, so a new file can't bring the pattern back.

What was run (WSL magpie-desktop, Playwright 1.62.0, load 70-260 from
other sessions):
- node --check on every file in internal/gui/tests: all parse.
- nav-timeout.test.cjs against origin/main's test files: red (names the
  1174 pages); against this tree: its only reds were my own probe copies
  of the old files, since removed.
- By hand: claude-switch-only with app.js served 7s late (a busy box's
  first load), --test-name-pattern "1100 en": origin/main's file 4 of 4
  red with "page.goto: Timeout 5000ms exceeded"; this file 4 of 4 green.
- claude-switch-only.test.cjs, both engines, en/zh/ja/de, 1100 and 420:
  32 of 32. group-from-model-add, usage-access-key-card and i18n-keys:
  green. agent-plugin-agents: Chromium green; WebKit's de 420 subtest red
  on a 5s waitForFunction at line 115 (a wait after load, not the
  navigation), at load ~230.

Not tried: the whole GUI suite (about 1000 files; the change is one
mechanical line per page), Windows or mote (mote's browsers, #4125).
2026-10-31 02:09:18 +08:00
yetone f463a8aaf7 gui: Settings has Loading bird, which keeps magpie's bird off skeletons and stops looking for them
Yayoi_no_yume on X, agreed by GymlinZhu: they run magpie on a 1-core,
1GB server and asked for a way to turn the loading bird off. The owner
wanted the bird, so it stays on by default. Settings -> General now has
"Loading bird" (Off / On), below Reduce motion.

- settings.json keeps noBird (omitted when the bird is on), and boot.js
  passes it. A POST that leaves it out keeps it, as with the other prefs.
  theme.js sets data-bird="off" on <html> before the first paint, and
  applyPrefs changes it.
- skelBird (app.js): with the bird off, nothing looks for skeletons at
  all. No 250ms interval and no observer run. Turning it off mid-hop ends
  the hops, and the bird flies off.
- With the bird on, the look is driven by events. Before, the 250ms
  setInterval ran forever, scanning the DOM for .skeleton whether or not
  one existed. Now a MutationObserver watches for an added node that is or
  holds a skeleton, the 250ms look runs only while one is in the page,
  and the look stops itself once none are left.
- The README's bird (plugins.js bounceLoader): with the bird off, the four
  lines stand straight with no bird, and the box goes when the README
  comes.
- Strings are in en, zh, zh-TW, ja and de. App.js is 1,294,016 bytes, under
  its budget, which is not raised.

Tests:
- skeleton-bird.test.cjs adds three tests:
  - with no skeleton left, the look stops, and a skeleton added later
    starts it again;
  - with the setting saved off, no bird, no dip and no look ever starts
    (setInterval is wrapped to count the look);
  - the Settings row shows On by default; Off posts noBird:true, stops a
    running look, and a skeleton added after that starts none; On posts
    false and the look starts again.
- plugin-readme-bird.test.cjs: with the setting off, the lines stay
  straight, no .sk-bird is drawn, and the box goes at once.
- settings-general: #birdSegs is in the list of bare rows.
- TestSettingsNoBird: off by default, kept by a POST that leaves it out,
  cleared by false, in settings.json and boot.js.

Run at this head (rebased on e15b2277c):
- mote: go test -run "Budget|TestSettings|TestBoot|TestI18n"
  ./internal/gui ./internal/settings: ok. GOOS=linux, windows and darwin
  go vet -tags nogui of both: clean (on the pre-rebase base aad6546cd,
  with no Go change between the two). gofmt -l: clean.
- wsl-run (Linux), both engines: skeleton-bird, plugin-readme-bird,
  settings-general, reduce-motion and i18n-keys: 43 of 44 pass. The one
  red is skeleton-bird's original hopping test in WebKit. It is red 2 of
  2 on origin/main e15b2277c in the same place, filed as #4176 (also one
  line of #4120).
- Before the rebase, on mote in Chromium, the same five files all passed.
- wsl-run Chromium: settings-groups, settings-lines-wrap, settings-search,
  settings-sections, settings-shortcut, settings-tabs-stick, text-size,
  menu-scroll and i18n-keys: 76 of 76 pass.

Broken by hand:
- With birdOff() always false, the three new off tests go red (README,
  skeletons, Settings row).
- With the look never stopping itself, "with no skeleton left" goes red.

Not tried:
- WebKit on mote. Playwright's WebKit never launched there (180s launch
  timeouts at load 65-300), so macOS WebKit wasn't run; WebKit ran only on
  Linux.
- The whole GUI suite (970 files), because mote was under heavy load.
- The real app on any OS, and a real 1c1g server. The CPU saved wasn't
  measured.
2026-10-29 13:12:36 +08:00
yetone 9e33962c05 gui: Settings has Reduce motion, stilling magpie as the system's does (#3813)
CupOfBread asked for a switch that turns magpie's motion off to save
resources on the desktop, and linull24 saw the Routing page keep a
phone's browser busy. magpie already stills its animations under the
system's Reduce Motion: 46 @media (prefers-reduced-motion: reduce)
rules across app.css and the plugins' styles, and calm() in the
scripts. Settings -> General now has "Reduce motion" (Off / On) that
does the same without the system setting.

- settings.json keeps reduceMotion; boot.js passes it; a POST that
  leaves it out keeps it, as the other prefs.
- theme.js's holdStill(on) sets data-motion="reduce" on <html> and sets
  the media of every stylesheet rule written for reduced motion to
  "all" (and back when turned off), so the same rules apply and no CSS
  is written twice. layout.js calls it before the first paint when the
  saved setting is on; applyPrefs calls it on a change.
- calm() is true when data-motion is reduce too, so the scripts'
  motion (Routing's stage, Library, Usage) holds still with it.
- routing.css: the reduced-motion rule for the live dot was
  .rt-livedot, which lost to .rt-livedot.on's animation; it is now
  .rt-livedot.on, so the dot stands still with either setting.

Measured on mote (Chromium 390x844, 4x CPU throttle, live Routing
traffic, CDP Performance over 10s, two runs each): main-thread task time
0.18 and 0.22 s/s with it off, 0.090 and 0.085 s/s on; style recalc
0.021/0.025 off, 0.008/0.011 on.

Tests: reduce-motion.test.cjs (new, both engines): saved on, the
reduced-motion rules apply from the start (a probe's live dot has no
animation, calm() is true); Off restores them and posts false; On again
posts true. TestSettingsReduceMotion: off by default, kept by a POST
that leaves it out, cleared by false, in settings.json and boot.js.
The Settings row is in settings-general's list of rows.

Run on mote at this head (rebased on e8c7dddcb): go test -run
"TestCoreScriptBudget|TestAppScriptBudget|TestSettings|TestBoot|TestI18n"
./internal/gui ./internal/settings: ok (the core budget not raised);
GOOS=linux, windows and darwin go vet -tags nogui of both: clean.
reduce-motion, settings-general, i18n-keys, routing-live-calm,
codex-descriptions, codex-predictions, codex-titles and old-webkit:
61 pass, 1 fail, the Safari 15.0 styles check below.
gofmt -l: clean.

Not tried: the real Linux (WebKitGTK) and Windows (WebView2) apps; the
setting changes only which existing CSS rules apply. old-webkit's
"Safari 15.0" check is red on origin/main from c490165b1's :has() in
.proto-menu (#4020), not from this change.
2026-10-28 16:50:16 +08:00
yetone 208bd5c48b gui: Settings descriptions wrap instead of ending in … (arculongus on Discord)
arculongus (English UI, screenshot) couldn't read many Settings rows: the
line under a setting's name ended in "…". The generic `.row .sub` rule holds
a row's line to one line with an ellipsis; a few Settings rows opted out
(`.wraps`) and the rest were cut, among them Image generation's ChatGPT
note, Image recognition MCP server and Web search's Searches for other
models.

Fixed for the class, not the rows in the screenshot: every setting row's
line (`.row.pref .sub`) now wraps whole beside its control. That covers
every Settings part, Plugins › Built-in and an agent's own settings (the
same rows). The control keeps its size (`.prefs .val` is `flex: none`,
max 60%), and nothing else in the layout moves. The window is never
narrower than 560pt, so a row stays a few lines at most. Lines elsewhere (provider
and account cards, chips, URLs) stay one line; their full text is already
reachable through the hover title.

Tests:
- New settings-lines-wrap.test.cjs checks every visible Settings part plus
  Plugins › Built-in, in chromium and webkit, en/zh/zh-TW/ja/de, at
  1000px and 440px. No row's line is cut or nowrap, each control stays
  inside its row, and the page never scrolls sideways (more than 30 rows
  checked). It also checks the three reported rows by name.
- Tests that assumed one-line rows now follow the taller rows:
  - searcher-pick: the help wraps rather than ellipsizing with a title.
  - settings-general: one line only at 1000px, never cut at either width.
  - reader.cjs reach(): goes up to 8,000px, not 2,400.
  - member-model-setting, turn-done, connect-address-kept, tray-cost and
    tray-totals: wheel to the control with reach() before
    clicking, not scrollIntoViewIfNeeded or Playwright's own scroll, which
    the app undoes.
  - update-download, update-restart and tray-totals: a click whose row
    grows a line may scroll, but only to keep the clicked control under
    the pointer (the app's hold, #2134). tray-totals allows 2px, because
    WebKit's whole-pixel scrolls drifted 1.3px over four holds.
  - mobile-web: compares against an origin/main baseline without this
    change.
- Docs: gui-shell.md and gateway-routing.md.

Run (worktree from origin/main a6399dd49, then rebased):
- The new test passes 20/20. Broken by hand: pointed at the old assets
  (MAGPIE_WRAP_ASSETS), it is red 10/10 in chromium and red in webkit
  ("general: a row's line is cut short").
- Whole GUI suite (872 files) in two runs, at concurrency 3-4 and load
  20-150:
  - The 170 Settings-reaching files first: 2515/2575.
  - Then the other 702: 9767/9920.
  - Each red was rerun on settings-wrap-base. The files this change made
    red (settings-general, turn-done, update-download, update-restart,
    member-model-setting, codex-auto-reset-settings, mobile-web,
    connect-address-kept, quota-reads, tray-cost, tray-totals) are fixed
    above and pass on rerun: 86/86, 34/34, 112/112 and 50/50.
  - Also red on origin/main, already filed:
    - redact-words-any-case: #3500
    - s3-sync webkit: #2448
    - usage-checkin Qoder tab: #2549
    - plugin-card-update: #3079
    - builtins and gateway-mode masking tab: #3498
    - fonts webkit: #3227
  - The other files red on origin/main 31bff66be, run alone at a
    comparable count, all have issues: routing-pause #3410,
    routing-rule-effort #3411, routing-rule-remove #3094/#3096,
    routing-intent-entry #3408, routing-live-patch #2174, routing-manual
    #3409, routing-steady #3412, menu-input-scroll #3402, header-centre
    #3479, gateway-caller-keys #2572, gateway-key-models #2648,
    gateway-key-limit #3523, quota-count-wrap #3404, usage-agents-hide
    #3414, usage-fold #3415, usage-ledger #3001/#3104, sidebar and
    gateway-mode #3498, account-discovery #3497, sidebar-overlay-scrollbar
    #1863, account-alias #2984.
  - provider-user-agent failed only on browserType.launch timeouts (load)
    and passed on rerun.
- After the rebase onto b027ca264, these were run again at the pushed head: the
  14 changed or affected GUI files (the new test, the eleven above,
  quota-reads, which main already wheels, and i18n-keys) passed 302/302.
  go test -tags nogui ./internal/gui (budgets included) was ok, with no
  budget raised.
- Before and after screenshots, Settings › Models at 1000px and 700px,
  chromium and webkit, were looked at: the rows that ended in an ellipsis
  now read whole, and each control has the size and place it had before.

Not tried: the real app (WKWebView, WebKitGTK, WebView2). This is a CSS
white-space change with no motion and no new API.
2026-10-25 09:21:42 +08:00
yetone 46176fc14f settings: every row has its line and the same room above and below its words
The owner (10-22, a screenshot of Settings → General): no line above
"Open at login", and the rows' space above and below differed.

- The line between rows is `.row + .row`; Settings' agent-pref link box
  (#agentPrefLinks, empty but while searching) sits between "Provider in
  model names" and "Open at login", so that row had none. The row after
  the box, and the box's own first row, now get it.
- In the window every row had `body.window .row`'s 7px, which beat
  `.row.pref` on specificity: one-line rows were centred by min-height
  (13-15px around their words), a row with a line under its name had
  7-8px. Every settings row now has 12px above and below; the Language
  and Session terminal buttons are 26px as the segments are, so every
  one-line row is 51px and a two-line row 61px, in both engines.
- A row's new line now grows it ~12px (was 1-2px under min-height).
  hold() kept a view at its top only while the clicked control moved
  less than half its height, so turning automatic updates off scrolled
  About 12px (#2134 says the view stays at its top). The bound is now the
  control's height; #961's ~138px stage still holds the bar.
- turn-done, reset-reminder and usage-alert clicked a switch left under
  the window's foot or the tabs; Playwright's scroll to it read as the
  page moving. They now reach() it first; update-restart's at-top bound
  is "less than the switch's height", not 4px.

Run at this tree (worktree magpie-wt/setrows, base 86254d404):
- settings-general: 20/20 (chromium+webkit, 5 languages, 1000/440).
  Red with the old CSS (fullContextRow 7px above), and red with only
  the line rule taken out ("loginRow has no line above it").
- The 94 GUI files that touch settings rows: 1559 pass, 61 red; against
  the old CSS 56 of them passed. Those 56 are fixed above:
  update-restart + update-auto 32/32, turn-done + reset-reminder +
  usage-alert 36/36. mobile-web's desktop screenshots differ from
  origin/main by design (the change itself).
- Red on the old CSS too: s3-sync (webkit en), usage-checkin (webkit en,
  zh).
- go test ./internal/gui ok.
Not run before push: the whole GUI suite (830 files) is running now;
reds it finds go in their own commits.
2026-10-22 18:51:56 +08:00
yetone 9691997bb0 gui: Long conversations stays in Settings when no Codex or Claude Code is here to hold it (Linka)
Linka on Discord runs magpie in Docker, with no agent installed. f1e4516da
(10-20) moved Long conversations (#fullContextRow: Compact at / Full
window) into Codex's and Claude Code's settings on the Agents page. In
gateway mode agentPrefsOf is null, and with neither agent present nothing
shows the row, so the compaction threshold couldn't be changed at all.
The setting still applies there: settings.Compact() sets the windows the
gateway serves, which agents on other computers read.

renderAgentPrefLinks now puts the row in Settings › General (before the
search-link rows) when no present agent owns it, and sends it back to
#agentPrefRows when one appears. With Codex or Claude Code present,
nothing changes. No new page. The backend is unchanged, so a compactAt
saved before is read and shown as it was.

Tests:
- agent-prefs.test.cjs: in gateway mode and with only Pi present, the row
  is in General. It shows the saved 200K, a typed 150k posts
  settings/full-context {on:false, at:150000}, and no other agent row is
  in Settings.
- settings-general.test.cjs: its no-agent fixture now leaves
  fullContextRow out of the "not in Settings" check.

Broken by hand: with HEAD's app.js the two new cases are red in Chromium
(the row never appears in General).

Not tried: magpie in a real Docker container; the GUI test fakes gateway mode.

Run for this batch of seven commits (devin, routing zh, qoder, masked words
any case, Long conversations, Claude subagents, user-select), in a worktree,
sandbox HOME, never against live configs:
- At e352cc823 (tree ea497c9f5, on origin/main 7dd965ed2): go test
  -timeout 45m ./... with pipefail, tee'd: 68 packages ok, exit 0, no
  ENOSPC. gofmt -l clean; go vet ./... for darwin, GOOS=linux -tags nogui
  and GOOS=windows: clean.
- The whole GUI suite at e352cc823 (node --test --test-concurrency=3
  internal/gui/tests/*.test.cjs, Chromium and WebKit, every language):
  11725 tests, 11679 pass, 46 fail, none ENOSPC. Each red file run alone at
  both 7dd965ed2 and e352cc823 gives the same counts on both, so none is
  from this batch: usage-agents-hide 5/16 (#2276), usage-ledger 28/34
  (#3104), usage-fold, quota-count-wrap, quota-name-translated (#2399),
  usage-checkin 26/28 (#2549), plugin-github 14/18 (#3218), s3-sync 3/4
  (#2448), modal-morph (#3179), fonts (filed as #3227, 1 in 9 alone on
  main). tray-usages (#2453), plugin-card-update (#3079) and
  proto-menu-overflow (filed as #3229) were red only under the full run
  and pass alone on both.
- Rebased onto origin/main 4a87c4476 (only Zed's mover min changed), tree
  8944b5dbb: go test ./internal/provider ./internal/gui (TestCoreScriptBudget
  and the app.js budget) ./internal/redact ./internal/settings
  ./internal/agent: all five ok; gofmt -l clean.
2026-10-22 10:52:04 +08:00
yetone f1e4516da2 gui: Codex's and Claude Code's own settings are in the agent's row on the Agents page, not in Settings
The owner, 10-20: Settings › General held Codex subagents, Long
conversations, Codex background compaction, thread titles, thread
descriptions, composer predictions, the auto-review model and the
memories model, apart from the agents they set; "很割裂、很分散,不直观".

They now sit with their agent (AGENT_PREFS): in its opened row on the
Agents page (a Settings list in connectPanel), in a sheet from the
tray panel's row ("Settings" line, openAgentPrefs) and from the agent's
menu ("{agent} settings"). Each row is the one element moved between
those places, so its handlers and state go with it. Settings' search
still finds them, with a row that opens the agent's sheet
(#agentPrefLinks). A gateway has no Agents page and none of them.
Strings for zh, zh-TW, ja and de; docs (reference, agent-wiring,
gui-shell) point at the new place. app.js 1,277,298 bytes and the core
scripts 1,469,058, so both budgets rise.

Run on 6416d639c (the dialog morph, on origin/main 75e769a9f), macOS,
playwright 1.62.0:
- agent-prefs.test.cjs (new) plus the 10 migrated files (codex-titles,
  codex-descriptions, codex-auto-review, codex-predictions,
  codex-memories-settings, codex-async-compact, compact-at,
  settings-general, bare-ids, gateway-mode) and modal-morph: 152/152,
  chromium and webkit, every language, wide and 420px.
- go test ./internal/gui/: ok after the budget rise.
- gofmt -l clean; go vet darwin, GOOS=linux -tags nogui, GOOS=windows.

Two GUI tests leaned on the Agents page's old height and are moved with it:
agent-models-loading clicked "elsewhere" at (900, 650), which is now
Codex's Disconnect button in its opened row, so it clicks the page's lead
line; agent-expand-steady clicked Goose's row while Codex's opened row
(~554px with its settings) pushed it out of a 560px view, so it wheels
Goose's link into sight first (reader.cjs reach). codex-subagents-lead
and agent-models-redraw clicked controls below Codex's opened row and
timed out in WebKit ("outside of the viewport"); they wait for the row to
finish sliding open, then wheel the control into sight. With Settings ›
General shorter, segs-press-redraw's sweep left Usage's warm-up tabs
above the view in WebKit; it wheels them back when they are. panel-effort
opened Kimi's row below Codex's opened one the same way. login-allow's
wheel loop read the shorter General page's button 50ms after each wheel and
clicked beside it (de, 440px); it uses reach. mobile-web shut each agent
picker by tapping the Agents tab, which a picker opened low in Codex's
taller row covers on a phone; it taps the header's name (the lead line
can sit under the header's tabs, and a tap there opened Library), wheels
each row and field into sight before tapping it, and says which agent and
field a step timed out on. All seven pass in Chromium and WebKit.

After the rebase onto main (32 commits on), with the test fixes above:
- go test ./internal/gui/ ./internal/plugin/ ./internal/agent/ ok;
  gofmt -l clean; go vet GOOS=linux -tags nogui and GOOS=windows.
- 95 GUI files (every agent-, codex-, claude-, settings- and modal- file,
  and every file either side changed): 1375 pass; the 8 reds were
  segs-press-redraw, fixed above. The 16 other files that click an
  Agents row: 369/370, rail-tip red on main too (#3091).
- The full suite's reds are listed in the dialog morph's commit; each was
  run alone on this head and on origin/main.
- mobile-web's "desktop matches origin/main" compares Settings and the
  Agents page with main's assets, so it is red until this is on main; its
  phone checks pass in Chromium and WebKit.
2026-10-21 02:06:23 +08:00
chenluzhouandDevin a7a38193f5 gui, settings: colorblind mode for quota curves and chart series (#2073)
In Usage -> Allowances, the 5-hour and weekly quota curves and their
legend dots took --c1 and --c2, which are both shades of blue in light
(#4f46e5, #0ea5e9) and dark (#a5b4fc, #7dd3fc) themes, with identical
solid lines and 7px round dots and the 5-hour line dimmed to .45 over a
week (#2073, chenlz22550).

- settings.Colorblind ("colorblind" in settings.json), passed in GET
  /boot.js when on and applied before first paint by theme.js and on
  every state/settings read by applyPrefs as data-colorblind="1" on
  :root.
- Settings -> General adds a Colorblind mode row (#colorblindRow,
  #colorblindSegs) under Appearance, in en, zh, zh-TW, ja and de.
- Under :root[data-colorblind="1"], --c1...--c7 switch to an Okabe-Ito
  qualitative palette in both light and dark themes so adjacent series
  differ in hue and lightness across quota curves, tray sparklines, the
  usage ledger and context charts.
- drawQuotaPlot and quotaCurve's drawLegend tag each series with
  data-series on path.qc-line and .qc-key; in colorblind mode series 0
  and series 1+ use distinct stroke-dasharray patterns and legend swatch
  shapes (filled circle vs hollow square/diamond), and .qc-line.qc-short
  keeps .85 opacity so short windows stay legible over a weekly span.
- docs/subsystems/gui-shell.md documents the boot and Settings contract.

Run (on origin/main f074996d9, sandbox HOME, pinned GOPATH/GOMODCACHE/GOCACHE):
- quota-curve.test.cjs in chromium and webkit (en, zh, zh-TW, ja, de):
  25/25 pass; with HEAD's assets via MAGPIE_QUOTA_ASSETS, all 10 new
  colorblind subtests fail (TimeoutError waiting for #colorblindRow).
- TestSettingsColorblindMode (new in internal/gui): passes; fails when
  boot.js omits colorblind.
- i18n-keys.test.cjs, gui-zh-tw.test.cjs, gui-ja.test.cjs,
  gui-de.test.cjs: 12/12 pass.
- settings-general.test.cjs (chromium 10/10), settings-sections.test.cjs,
  settings-search.test.cjs, omarchy.test.cjs, lightweight.test.cjs,
  keep-awake.test.cjs, segs-glide.test.cjs, api-key-theme.test.cjs,
  seg-contrast.test.cjs, balance-curve.test.cjs,
  usage-ledger-chart.test.cjs in chromium and webkit: 140/140 pass.
- node --check on app.js, theme.js, i18n.js: clean.
- gofmt -l: clean. With set -o pipefail: go vet ./..., GOOS=linux go vet
  -tags nogui ./..., GOOS=windows go vet ./..., go build, GOOS=linux go
  build -tags nogui, GOOS=windows go build: all clean.
- go test -tags nogui ./...: all packages ok.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-10-14 16:28:05 +08:00
yetone 269fc93e8e gui tests: settings-general reads the language button's place once the page's animations end
The test compares the language button's place before and after a language
pick. The context has no reducedMotion, so the Settings page's entrance
animation could still be running when `before` was read. Under load, the
reads came out like 175.07 or 175.98 against a resting 175: 20 such reads
in 18 runs, 6 at a time. One run went red on ja at 440px, with before at
200.5 and after at 199.19 while the view had scrolled 24. It was red alone
on origin/main a75de4c21 too, 1 run of 3.

Both reads now wait for document.getAnimations() to finish.

Run: 18 runs, 6 at a time, chromium: no read taken mid-animation, fail 0.
The whole file 2× in both engines: 20/20.
2026-10-13 22:06:17 +08:00
yetone f36e744c30 gui: Settings › General says each setting's name alone where it says enough, and Language is one menu (1ooogle on X)
1ooogle's mockup on X redrew Settings › General the way macOS System
Settings reads it. The owner approved, and this follows it.

Rows that now show only their name:
- Appearance, Text size, Interface and Code font, the tray click,
  Provider in model names, the Codex titles, auto-review and memories
  model rows, Open at login and Show in Dock.
- A font row's line shows only while its fonts are loading or have
  failed.
- The text size keys (⌘0 / Ctrl+0) move into the choices' tooltip.

Rows that keep one short line, because the name alone doesn't explain
the setting or what it costs:
- Codex subagents, Long conversations, Lightweight mode, Prevent sleep
  and Session terminal.

Renames:
- "Tray icon" becomes "Click the tray icon to", with the choices "Open
  the quick panel" and "Open the main window" (点击托盘图标: 打开快捷面板 /
  打开主窗口).
- "Keep awake while agents work" becomes "Prevent sleep" (防止休眠: 在
  magpie 运行任务时,让电脑保持唤醒状态).
- "Dock" becomes "Show in Dock" (显示程序坞).

Language is one button showing the language picked (renderLangPick).
It opens in the app's own menu (openProtoMenu, styled like Session
terminal's sess-pick), not a native <select> and not six segments.

Every language gets the same text: en, zh, zh-TW, ja and de. The 25
strings no longer used are removed from all four translations.

Tests:
- New: settings-general.test.cjs. In Chromium and WebKit, en, zh,
  zh-TW, ja and de, at 1000 and 440 px, on a Mac, it checks that:
  - the rows that should show only their name have no line;
  - the kept lines are one line each, and none is cut short at 1000px;
  - Language is a button showing the language, and its menu lists all
    six;
  - a pick saves lang and redraws the page in that language, with the
    button staying under the pointer;
  - nothing has a left stripe and nothing scrolls sideways.
  I broke it by hand twice and saw it fail both times: once by giving
  the Dock row a line back, once by making the pick save nothing.
- Updated to the new text and controls: codex-titles,
  codex-auto-review, codex-memories-settings, model-suffix-own,
  plain-names, lightweight, keep-awake, text-size, gateway-mode,
  omarchy, settings-search, gui-zh-tw (Language's button and menu fit
  at 1000/440px), header-relang (picks through the menu) and
  readable-focus (the first shown line).
- German's long-conversations line was shortened to fit on one line at
  1000px.

What was run:
- go test -tags nogui ./internal/gui passes; gofmt -l is clean; go vet
  passes on darwin, linux and windows.
- The whole GUI suite (601 files, --test-concurrency=4): 6584 passed,
  33 failed. Every failing file was then run alone:
  - mobile-web fails on purpose. It compares desktop screenshots with
    origin/main, and only the Settings page differs.
  - routing-group-fold, text-size, routing-sessions and pick-skills
    are #1672; searcher-pick is #1745. Each also fails alone on
    origin/main 260ded9af.
  - routing-provider-off, routing-steady and usage-sum-whole pass when
    run alone, both here and on main.
- Screenshots before and after (zh, en and de light at 1000px, zh at
  440px, zh dark) were looked at.

Not tried in the real Wails window.
2026-10-12 22:51:53 +08:00