diff --git a/src/web/ThemeChange.tsx b/src/web/ThemeChange.tsx
index 38c29ca..3e7dbf3 100644
--- a/src/web/ThemeChange.tsx
+++ b/src/web/ThemeChange.tsx
@@ -1,42 +1,50 @@
import React from 'react'
-import { useColorMode, Menu, MenuButton, MenuList, MenuItem, IconButton, Box } from '@yamada-ui/react'
+import { useColorMode, HStack, Text, SegmentedControl, SegmentedControlButton, ColorModeWithSystem, CardBody, CardHeader } from '@yamada-ui/react'
import { MoonIcon, PaletteIcon, SunIcon, MonitorCogIcon } from '@yamada-ui/lucide'
+import { useTranslation } from 'react-i18next'
export const ThemeChange = () => {
const { changeColorMode, internalColorMode } = useColorMode()
+ const { t } = useTranslation()
- const isSystemColor = (internalColorMode == 'system') ? 'primary' : ''
- const isLightColor = (internalColorMode == 'light') ? 'primary' : ''
- const isDarkColor = (internalColorMode == 'dark') ? 'primary' : ''
+ const getColorModeWithSystem = (v: string): ColorModeWithSystem => {
+ if (v == 'system') return 'system'
+ if (v == 'light') return 'light'
+ if (v == 'dark') return 'dark'
+ return internalColorMode
+ }
return (
-
+ <>
+
+
+
+ {t('theme_select')}
+
+
+
+ changeColorMode(getColorModeWithSystem(v))}>
+
+
+
+ System
+
+
+
+
+
+ Light
+
+
+
+
+
+ Dark
+
+
+
+
+ >
)
}
diff --git a/src/web/VolumeChange.tsx b/src/web/VolumeChange.tsx
index 964cb8e..7d7a6b9 100644
--- a/src/web/VolumeChange.tsx
+++ b/src/web/VolumeChange.tsx
@@ -23,15 +23,14 @@ export const VolumeChange = () => {
}
const volumeIcon = (volume: number, mute: boolean) => {
- if (mute) return
- else if (volume <= 0.0) return
- else if (volume <= 0.5) return
- else return
+ if (mute) return
+ else if (volume <= 0.0) return
+ else if (volume <= 0.5) return
+ else return
}
return (
-