Add Light/Dark card appearance toggle#52
Conversation
Adds an Appearance row to the UI (Dark/Light buttons) that applies a .card-theme-light modifier class to #capture, switching the card to GitHub's light-mode palette (white background, #f6f8fa header, #d0d7de borders). The Terminal template's internal window stays dark in light mode. applyTemplate() now re-applies the card theme class after resetting card.className so switching templates preserves the chosen appearance. https://claude.ai/code/session_019mFhzJHWmUB8cTbLksb6ev
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Caution Review failedThe pull request is closed. βΉοΈ Recent review infoβοΈ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: π Files selected for processing (2)
π WalkthroughWalkthroughAdds a card appearance toggle: new Dark/Light UI controls, a Changes
Estimated code review effortπ― 2 (Simple) | β±οΈ ~10 minutes Possibly related issues
Possibly related PRs
Suggested labels
Poem
π₯ Pre-merge checks | β 2 | β 1β Failed checks (1 warning)
β Passed checks (2 passed)
βοΈ Tip: You can configure your own custom pre-merge checks in the settings. β¨ Finishing Touchesπ Generate docstrings
π§ͺ Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
AI Analysis SummaryThe added Light/Dark card appearance toggle may introduce accessibility issues. Review the code to ensure it meets accessibility standards. Consider adding ARIA attributes to the toggle buttons to improve screen reader support. Severity: Full details: #53 |
Adds role="group" + aria-label to the .card-theme-row and aria-pressed state to each button, kept in sync by applyCardTheme(). This addresses the accessibility issue raised in #53. https://claude.ai/code/session_019mFhzJHWmUB8cTbLksb6ev
Summary
.card-theme-lightmodifier class to#capturewhen Light is selected, switching the card to GitHub's actual light-mode palette (white background,#f6f8faheader/footer,#d0d7deborders, dark text)applyTemplate()now re-applies the current card theme class after resettingcard.className, so switching templates preserves the chosen appearance#0d1117) stays dark even when the card is in light modeChanges
index.htmlβ new.card-theme-rowdiv withdata-card-themebuttons after.platform-rowassets/css/styles.cssβ.card-theme-row/.card-theme-labelstyles (reusing existing.platform-rowpattern) + full.card-theme-lightmodifier blockassets/js/app.jsβcurrentCardThemestate,applyCardTheme()function, event binding inbindEvents(),applyTemplate()updated to preserve theme class,applyCardTheme('dark')init callassets/js/dom.jsβcardThemeButtonsadded togetElements()return objectTest plan
card-theme-lightclass#0d1117) in Light card modehttps://claude.ai/code/session_019mFhzJHWmUB8cTbLksb6ev
Summary by CodeRabbit