Repository navigation
fix(pref): stack settings rows; close dropdown when opening prefs - #174
Merged
Merged
Conversation
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.
Contributor
There was a problem hiding this comment.
🟡 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, butAGENTS.md:449-450still 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 on lines
+10425
to
10429
| #user-pref ul { | ||
| margin-bottom: .55em; | ||
| padding-bottom: .5em; | ||
| } | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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.