Skip to content

feat(ui): unify component styling and live theme refresh - #41

Draft
sudo-tee wants to merge 4 commits into
feat/declarative-uifrom
codex/ui-style-baseline
Draft

sudo-tee wants to merge 4 commits into
feat/declarative-uifrom
codex/ui-style-baseline

Conversation

@sudo-tee

@sudo-tee sudo-tee commented Oct 28, 2026 •

Copy link
Copy Markdown
Owner

Buttons, tabs, list rows and panel chrome previously derived paint and interaction styles through separate paths. Route them through private component recipes and a flat computed-style normalizer while retaining existing raw styles, theme overrides and legacy geometry. Live span serialization writes directly into its output to avoid intermediate style snapshots.

  • Keep ui.styled canonical and provide ui.themed_style as a compatibility alias.
  • Share recipes across action/dialog buttons, tabs, select/palette/mux rows and panel chrome. Add opt-in button variants/sizes, disabled activation, selectable row styling, and explicit row/chrome override precedence.
  • Resolve hover/selection in a deterministic order, clear stale disabled callbacks, and copy shared styles before assigning bar IDs.
  • Share surface pixel normalization, support bar close-part tokens, and supply palette-owned row hover paint to native drawing through an additive optional field. Existing native fallback paints are inventoried and retained for incomplete producers.
  • Refresh open built-in widget palettes and default chrome on theme changes, preserving instance overrides and using weak references so closed widgets can be collected. Lazy child/chrome tokens use their widget's explicit palette.
  • Update LuaLS types, authoring examples, the implementation plan, and reproducible style/component/overlay benchmarks. The final contract is documented in docs/ui-computed-style.md.

Validation:

  • scripts/test-lua.sh: 598 successes, 0 failures/errors using LuaJIT/Busted.
  • StyLua checks pass on all touched Lua, including types.
  • Zig 0.17 fmt --check and git diff --check pass.
  • zig build test-lua and zig build test were attempted but external Ghostty/LuaJIT/font dependency downloads fail with HttpConnectionClosing. Native compilation, screenshots and DPI/hit-region acceptance remain unverified.

Lua render+overlay-serialization benchmark, baseline 68709b3 vs this change: 25 rows 0.953→0.896 ms; 100 rows 3.813→3.509 ms; 500 rows 25.380→24.408 ms. Allocated bytes/row increase about 3%; component-only allocations increase about 0.6%. These are host-specific Lua samples, not native frame-time claims. No generic style cache or synthetic pressed/focus behavior is introduced.

Row styles intentionally expose only supported text/background/radius/hover paint; unsupported row geometry fields error. Existing segment padding and native placement/hit-region calculations remain the compatibility boundary. Native visual/build acceptance is pending before merging.

@sudo-tee sudo-tee changed the title fix(ui): reconcile themed style API and capture styling baseline fix(ui): preserve styled API and capture styling baseline Oct 28, 2026
@github-actions

github-actions Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

📦 PR builds · 28 Oct 2026

Platform Download
🪟 Windows hollow-windows-pr-f898a9c
🐧 Linux hollow-linux-pr-f898a9c

Build details

Detail Value
🧬 Commit f898a9c
🕒 Started 28 Oct 2026, 22:05 UTC
✅ Completed 28 Oct 2026, 22:15 UTC
🔗 Build run #67

Artifacts expire after 7 days.

@sudo-tee sudo-tee changed the title fix(ui): preserve styled API and capture styling baseline feat(ui): unify component styling and presentation Oct 28, 2026
@sudo-tee sudo-tee changed the title feat(ui): unify component styling and presentation feat(ui): unify component styling and live theme refresh Oct 28, 2026
Sign up for free to 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