Skip to content

[SETTINGS-002] Apply theme and language preferences - #75

Closed
chev0004 wants to merge 6 commits into
developfrom
feat/settings-002
Closed

[SETTINGS-002] Apply theme and language preferences#75
chev0004 wants to merge 6 commits into
developfrom
feat/settings-002

Conversation

@chev0004

Copy link
Copy Markdown
Owner

Outline

Summary

Makes the settings theme and application-language preferences actually drive the app: the theme switches the interface live and persists across refresh, and the language preference navigates to the matching locale and is restored after login.


Changes & Enhancements

  • Type of Change:
    • Feature
    • Bugfix
    • Refactor
    • Chore
  • Changes:
    • (theme):
      • Add a ThemeProvider that applies the theme to <html data-theme> and persists it to a polycord_theme cookie and localStorage.
      • Add light-mode design tokens so the existing surfaces, text, and borders flip with the theme.
      • Read the theme cookie in the root layout and render it server-side to avoid a flash.
      • Wire the settings theme picker to apply live, commit on save, and revert on discard.
    • (settings):
      • Limit the application-language picker to the locales the app actually ships.
      • Navigate to the selected locale when a new application language is saved.
    • (auth):
      • Restore the user's saved theme and application language on Discord login.

Page / App Changes

Affected Next.js Routes (Local):

  • /[lang]/settings
  • /[lang] (theme now applies app-wide)
Before (Screenshot)
After (Screenshot)

Settings appearance, dark and light:

Settings appearance dark

Settings appearance light

Application language limited to shipped locales (Japanese):

Settings appearance Japanese

Theme applies across the app (discovery in light mode):

Discovery light


Component / Storybook Changes

Affected Storybook Components (Local):

Before (Screenshot)
After (Screenshot)

Not Doing


Other (Remarks)


Checklists

  • Code is well-documented (comments, JSDoc, etc.).
  • Existing comments were updated as needed.
  • No out-of-scope changes are included.
  • Write TODO comments where future work is required.
  • Removed unnecessary debug code (e.g., console.log, debugger).
  • Self-reviewed and tested locally.

@chev0004 chev0004 self-assigned this Jun 22, 2026
@chev0004 chev0004 closed this Jun 22, 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