Skip to content

[_]: feat/add appearance section in General tab (Preferences)#27

Merged
xabg2 merged 3 commits intomasterfrom
feature/appearance
Mar 25, 2026
Merged

[_]: feat/add appearance section in General tab (Preferences)#27
xabg2 merged 3 commits intomasterfrom
feature/appearance

Conversation

@xabg2
Copy link
Contributor

@xabg2 xabg2 commented Mar 25, 2026

Add new section in General tab (Preferences) to allow the user to switch the theme for the app (light, dark or system default config).

@xabg2 xabg2 self-assigned this Mar 25, 2026
@xabg2 xabg2 added the enhancement New feature or request label Mar 25, 2026
@xabg2 xabg2 requested a review from larryrider March 25, 2026 08:37
const toggleTheme = (theme: Theme) => setCurrentTheme(theme);

const persistDarkTheme = (value: boolean) => {
LocalStorageService.instance.set('theme:isDark', value ? 'true' : 'false');

Choose a reason for hiding this comment

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

isnt value ? 'true' : 'false' the same as just value?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

local storage only allows strings as value, not boolean


useEffect(() => {
const root = rootRef.current;
if (!root || currentTheme === undefined) return;

Choose a reason for hiding this comment

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

isnt it better to if (!root || !currentTheme) return;

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed

@xabg2 xabg2 requested a review from larryrider March 25, 2026 10:20
Base automatically changed from feature/settings-dialog to master March 25, 2026 10:20
@sonarqubecloud
Copy link

@xabg2 xabg2 merged commit efe1c79 into master Mar 25, 2026
4 checks passed
@xabg2 xabg2 deleted the feature/appearance branch March 25, 2026 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants