Skip to content

Commit

Permalink
Merge pull request #58 from Lorg0n/Feature/SystemTheme
Browse files Browse the repository at this point in the history
Feature/system theme
  • Loading branch information
olexh authored Jul 3, 2024
2 parents dd2d212 + ec515ce commit 17303aa
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions features/modals/user-settings-modal/customization-form.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use client';

import { useTheme } from 'next-themes';
import * as React from 'react';
import MaterialSymbolsСomputerOutlineRounded from '~icons/material-symbols/computer-outline-rounded';
import MaterialSymbolsNightlightOutlineRounded from '~icons/material-symbols/nightlight-outline-rounded';
import MaterialSymbolsSunnyOutlineRounded from '~icons/material-symbols/sunny-outline-rounded';

Expand All @@ -26,12 +26,12 @@ const Component = () => {
setSettingsState!((prev) =>
prev
? {
...prev,
titleLanguage: value[0] as
| 'title_ua'
| 'title_en'
| 'title_ja',
}
...prev,
titleLanguage: value[0] as
| 'title_ua'
| 'title_en'
| 'title_ja',
}
: prev,
);

Expand Down Expand Up @@ -62,6 +62,12 @@ const Component = () => {
Світла тема
</div>
</SelectItem>
<SelectItem value="system">
<div className="flex items-center gap-2">
<MaterialSymbolsСomputerOutlineRounded className="text-[1.2rem]" />
Системна тема
</div>
</SelectItem>
</SelectGroup>
</SelectList>
</SelectContent>
Expand All @@ -75,7 +81,7 @@ const Component = () => {
onValueChange={handleChangeTitleLanguage}
>
<SelectTrigger>
<SelectValue placeholder="Виберіть тему..." />
<SelectValue placeholder="Виберіть мову..." />
</SelectTrigger>
<SelectContent>
<SelectList>
Expand Down

0 comments on commit 17303aa

Please sign in to comment.