Skip to content

emrg: gui renderer Batch 5 slice 6 — SettingsDialog wiring (settings panel) - #1021

Merged
argszero merged 1 commit into
masterfrom
feature/batch5-settings-panel
Aug 26, 2026
Merged

emrg: gui renderer Batch 5 slice 6 — SettingsDialog wiring (settings panel)#1021
argszero merged 1 commit into
masterfrom
feature/batch5-settings-panel

Conversation

@argszero

Copy link
Copy Markdown
Owner

Batch 5 slice 6 of the React migration: replace the placeholder settings section in WorkspaceView with a fully wired SettingsPanel (vanilla dialogs.js showSettings/saveSettings/renderModelList parity).

Changes:

  • New components/SettingsPanel.tsx with five tabs: model service / GitHub / appearance / language / about
  • Model tab: loads settings via window.emrg getSettings (apiKey, baseUrl, model list), supports add/edit/delete/set-default of [[llm.models]] entries, persists via saveSettings
  • GitHub tab: githubStatus display + connect (PAT) / disconnect through the bridge
  • Appearance tab: light/dark/system theme applied to document.documentElement data-theme attr (vanilla applyTheme parity)
  • Language tab: i18n setLocale (zh/en/follow-system)
  • About tab: version + evolution count injected from Shell appState
  • WorkspaceView renders SettingsPanel (data-testid panel-settings preserved); Shell passes version/evolutionCount props
  • New SettingsPanel.test.tsx: 13 tests (tabs, model CRUD, save payload, github connect/disconnect, theme, locale, about, bridge-less degradation)

Verification: renderer typecheck clean, 411 renderer tests pass (was 398), renderer build OK, GUI suite 257 pass/0 fail (8 skip), Python pytest 1106 passed/1 skipped, doc-count 4/4.

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle (cyc20260827-025722)

Independent review of the full diff (5 files, +876/−16):

  • SettingsPanel.tsx: five-tab settings panel (model/github/appearance/language/about) wiring via window.emrg getSettings/saveSettings/githubStatus/githubConnect/githubDisconnect, with vanilla dialogs.js showSettings/saveSettings/renderModelList parity. Bridge-less degradation matches DialogHost strategy.
  • Model CRUD: add/edit/delete/set-default with dedup guards (duplicate name / duplicate-default rejection), saveSettings payload merges default model correctly.
  • Theme: data-theme attr apply/remove matches vanilla applyTheme; i18n setLocale via module spy in tests.
  • WorkspaceView keeps data-testid=panel-settings; Shell passes version/evolutionCount from appState.
  • 13 new renderer tests cover tabs, model CRUD, save payload, empty-apiKey block, github connect/disconnect, theme, locale, about, no-bridge degradation.

CI: test + test-windows double-green (run 33001935597). Local verification last cycle: typecheck + 411/411 renderer tests + build + GUI 257/0 fail + pytest 1106+1 + doc-count 4/4 all green.

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle (cyc20260827-030858)

Re-verified: head 41a653e unchanged, MERGEABLE/CLEAN, CI double-green (run 33001935597). Full diff re-reviewed last cycle (5 files +876/−16): five-tab SettingsPanel wiring (model CRUD + dedup guards + saveSettings payload / github connect-disconnect / theme data-theme / i18n setLocale / about version+evolutionCount / bridge-less degradation), 13 tests, panel-settings testid preserved, Shell passes appState props. LGTM 2/3.

@argszeroargszero left a comment

Copy link
Copy Markdown
OwnerAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle (cyc20260827-031621)

Third consecutive approval (cyc025722 → cyc030858 → cyc031621, no ❌ in between). Re-verified: head 41a653e unchanged, MERGEABLE/CLEAN, CI double-green (run 33001935597). Full diff independently reviewed in prior cycles (SettingsPanel five-tab wiring + 13 tests + Shell/WorkspaceView integration).

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@argszero