Skip to content

fix(pref): stack settings rows; close dropdown when opening prefs - #174

Merged
audreyt merged 2 commits into
mainfrom
fix/pref-panel-stacking-dropdown-close
Sep 14, 2026
Merged

audreyt merged 2 commits into
mainfrom
fix/pref-panel-stacking-dropdown-close

Conversation

@audreyt

@audreyt audreyt commented Sep 14, 2026 •

Copy link
Copy Markdown
Member

The React #user-pref markup nests its ul inside a wrapper div, so the legacy #user-pref>ul child-combinator rules never matched and Bootstrap's .btn-group inline-block tiled the settings rows side-by-side wherever two fit (labels merging into one unreadable line on narrow viewports). Now descendant selectors; rows stack with label above control.

Also close the dictionary dropdown when opening 偏好設定, matching the starred/language handlers, and bump LEGACY_STYLESHEET_VERSION to 20260914 to bust the stale edge CSS namespace.

Verified: unit 2150, integration, chromium e2e, webkit-romanization 16, visual 11; WebKit + on-device Android screenshots; staging deploy green.

The React #user-pref markup nests its ul inside a wrapper div, so the
legacy #user-pref>ul child-combinator rules never matched and Bootstrap's
.btn-group inline-block tiled the settings rows side-by-side wherever two
fit (labels merging into one unreadable line on narrow viewports).

Also close the dictionary dropdown when opening 偏好設定, matching the
starred/language handlers.

Tests: pref-row stacking (legacy-styles-regression), dropdown-close
(preferences).
Cache-bust the legacy stylesheet edge namespace so the #user-pref
stacking fix reaches browsers immediately instead of lingering behind
the previous ?v= entry's edge TTL.
Copilot AI lite review requested due to automatic review settings September 14, 2026 11:14

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The stylesheet asset synchronization issue remains unresolved, and the cache-version documentation needs updating.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Fixes preference-row layout, closes the dictionary dropdown when opening preferences, and refreshes the stylesheet cache version.

Changes:

  • Corrects legacy CSS selectors so preference rows stack vertically.
  • Adds dropdown and layout regression coverage.
  • Updates the stylesheet cache-busting version.
File summaries
File Summary
tests/e2e/preferences.spec.ts Tests dropdown closure.
tests/e2e/legacy-styles-regression.spec.ts Verifies stacked preference rows.
src/utils/media-cdn.ts Updates CSS cache version; documentation also needs updating.
src/components/navbar-normal.tsx Closes the dictionary dropdown before opening preferences.
data/assets/styles.css Fixes preference-row selectors; asset synchronization remains required for deployment.
Review details

Suppressed comments (1)

src/utils/media-cdn.ts:30

  • The version is now 20260914, but AGENTS.md:449-450 still says both stylesheet URLs use ?v=20260711. Because that file is the repository's cache/deployment guidance, the documented cache namespace is now inconsistent with the code and can mislead future stale-CSS diagnosis. Please update the documentation in the same change.
export const LEGACY_STYLESHEET_VERSION = "20260914";
  • Files reviewed: 5/5 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread data/assets/styles.css
Comment on lines +10425 to 10429
#user-pref ul {
margin-bottom: .55em;
padding-bottom: .5em;
}

@audreyt
audreyt merged commit 8e7ad8c into main Sep 14, 2026
7 checks passed
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.

2 participants