Commit Graph
1 Commits
Author SHA1 Message Date
yetone 5f3a492541 gui: Settings › Usage turns each Codex account's auto-use resets on and off (Avalon on Discord)
Avalon followed up on foobra12's report (a Codex reset used by itself,
"这个设置在哪儿找呢"): the switch seemed reachable only from the quota in
the tray. The window's Usage page has it on each Codex card, but nothing
in Settings named it, so a search there found nothing.

Change: Settings › Usage gets "Codex: auto-use resets", with a line on
when a reset is used (week used up and no other account can answer, or
before one expires unused; off until turned on, account by account) and
an Off/On row per signed-in Codex account (s.codexUsers, plus any account
still in codexAutoReset that is no longer signed in, so it can be turned
off). A pick posts settings/codex-auto-reset, the same call as the card's
switch; the card's switch redraws these rows. The row is hidden with no
Codex account. Strings in zh, zh-TW, ja and de.

Run (playwright 1.62.0, NODE_PATH to it):
- new codex-auto-reset-settings.test.cjs: 22/22, chromium and webkit,
  en/zh/zh-TW/ja/de at 1100 and 420, plus the no-account case. With the
  renderAutoResetOwn call removed by hand it goes red.
- click-scroll, codex-auto-reset, codex-resets-used, gui-de, gui-ja,
  gui-zh-tw, i18n-keys, reset-reminder, settings-search,
  settings-sections, settings-general, warm-at-own, warm-at-times,
  routing-auto-reset: all green.
- old-webkit: 5/6. The red is app.css's ":has()" (Safari 15.4) at
  ~2836, which is on origin/main 42216ea60 without this change; this
  commit doesn't touch app.css.
- gofmt -l; go vet darwin, linux -tags nogui, windows on internal/gui;
  go test -tags nogui ./internal/gui/: ok.
Not tried: the real app window with a real Codex account; the full GUI
suite.
2026-10-13 17:57:12 +08:00