@@ -135,14 +135,25 @@ export const useKeyboardShortcuts = createSharedComposable(function useKeyboardS
135135export function useAccentColor ( ) {
136136 const { settings } = useSettings ( )
137137 const colorMode = useColorMode ( )
138+ const { t } = useI18n ( )
139+
140+ const accentColorLabels = computed < Record < AccentColorId , string > > ( ( ) => ( {
141+ sky : t ( 'settings.accent_colors.sky' ) ,
142+ coral : t ( 'settings.accent_colors.coral' ) ,
143+ amber : t ( 'settings.accent_colors.amber' ) ,
144+ emerald : t ( 'settings.accent_colors.emerald' ) ,
145+ violet : t ( 'settings.accent_colors.violet' ) ,
146+ magenta : t ( 'settings.accent_colors.magenta' ) ,
147+ neutral : t ( 'settings.clear_accent' ) ,
148+ } ) )
138149
139150 const accentColors = computed ( ( ) => {
140151 const isDark = colorMode . value === 'dark'
141152 const colors = isDark ? ACCENT_COLORS . dark : ACCENT_COLORS . light
142153
143154 return Object . entries ( colors ) . map ( ( [ id , value ] ) => ( {
144155 id : id as AccentColorId ,
145- name : id ,
156+ label : accentColorLabels . value [ id as AccentColorId ] ,
146157 value,
147158 } ) )
148159 } )
@@ -190,12 +201,24 @@ export function useSearchProvider() {
190201}
191202
192203export function useBackgroundTheme ( ) {
193- const backgroundThemes = Object . entries ( BACKGROUND_THEMES ) . map ( ( [ id , value ] ) => ( {
194- id : id as BackgroundThemeId ,
195- name : id ,
196- value,
204+ const { t } = useI18n ( )
205+
206+ const bgThemeLabels = computed < Record < BackgroundThemeId , string > > ( ( ) => ( {
207+ neutral : t ( 'settings.background_themes.neutral' ) ,
208+ stone : t ( 'settings.background_themes.stone' ) ,
209+ zinc : t ( 'settings.background_themes.zinc' ) ,
210+ slate : t ( 'settings.background_themes.slate' ) ,
211+ black : t ( 'settings.background_themes.black' ) ,
197212 } ) )
198213
214+ const backgroundThemes = computed ( ( ) =>
215+ Object . entries ( BACKGROUND_THEMES ) . map ( ( [ id , value ] ) => ( {
216+ id : id as BackgroundThemeId ,
217+ label : bgThemeLabels . value [ id as BackgroundThemeId ] ,
218+ value,
219+ } ) ) ,
220+ )
221+
199222 const { settings } = useSettings ( )
200223
201224 function setBackgroundTheme ( id : BackgroundThemeId | null ) {
0 commit comments