@@ -46,83 +46,85 @@ void loadCustomThemes()
4646 </script >
4747
4848<template >
49- <div class =" space-y-5" >
50- <UiMenuFormItem :label =" i18n.t('preferences:appearance.theme.label')" >
51- <Select .Select
52- :model-value =" currentThemeId"
53- @update:model-value =" onThemeChange"
54- >
55- <Select .SelectTrigger class =" w-64" >
56- <Select .SelectValue />
57- </Select .SelectTrigger >
58- <Select .SelectContent >
59- <Select .SelectGroup >
60- <Select .SelectLabel >
61- {{ i18n.t("preferences:appearance.theme.builtIn") }}
62- </Select .SelectLabel >
63- <Select .SelectItem
64- v-for =" theme in builtInThemes"
65- :key =" theme.id"
66- :value =" theme.id"
67- >
68- {{ theme.label }}
69- </Select .SelectItem >
70- </Select .SelectGroup >
71-
72- <template v-if =" customThemes .length " >
73- <Select .SelectSeparator />
74-
75- <Select .SelectGroup v-if =" customDarkThemes.length" >
49+ <div >
50+ <UiMenuFormSection :label =" i18n.t('preferences:appearance.label')" >
51+ <UiMenuFormItem :label =" i18n.t('preferences:appearance.theme.label')" >
52+ <Select .Select
53+ :model-value =" currentThemeId"
54+ @update:model-value =" onThemeChange"
55+ >
56+ <Select .SelectTrigger class =" w-64" >
57+ <Select .SelectValue />
58+ </Select .SelectTrigger >
59+ <Select .SelectContent >
60+ <Select .SelectGroup >
7661 <Select .SelectLabel >
77- {{
78- `${i18n.t("preferences:appearance.theme.custom")} · ${i18n.t("preferences:appearance.theme.dark")}`
79- }}
62+ {{ i18n.t("preferences:appearance.theme.builtIn") }}
8063 </Select .SelectLabel >
8164 <Select .SelectItem
82- v-for =" theme in customDarkThemes "
65+ v-for =" theme in builtInThemes "
8366 :key =" theme.id"
8467 :value =" theme.id"
8568 >
86- {{ theme.name }}
69+ {{ theme.label }}
8770 </Select .SelectItem >
8871 </Select .SelectGroup >
8972
90- <Select .SelectGroup v-if =" customLightThemes.length" >
91- <Select .SelectLabel >
92- {{
93- `${i18n.t("preferences:appearance.theme.custom")} · ${i18n.t("preferences:appearance.theme.light")}`
94- }}
95- </Select .SelectLabel >
96- <Select .SelectItem
97- v-for =" theme in customLightThemes"
98- :key =" theme.id"
99- :value =" theme.id"
100- >
101- {{ theme.name }}
102- </Select .SelectItem >
103- </Select .SelectGroup >
104- </template >
105- </Select .SelectContent >
106- </Select .Select >
107- </UiMenuFormItem >
73+ <template v-if =" customThemes .length " >
74+ <Select .SelectSeparator />
10875
109- <UiMenuFormItem :label =" i18n.t('preferences:appearance.theme.themesDir')" >
110- <template #description >
111- {{ i18n.t("preferences:appearance.theme.dirDescription") }}
112- </template >
113- <template #actions >
114- <div class =" flex gap-2" >
115- <Button
116- variant =" outline"
117- @click =" openThemesDir"
118- >
119- {{ i18n.t("preferences:appearance.theme.openDir") }}
120- </Button >
121- <Button @click =" createThemeTemplate" >
122- {{ i18n.t("preferences:appearance.theme.createTemplate") }}
123- </Button >
124- </div >
125- </template >
126- </UiMenuFormItem >
76+ <Select .SelectGroup v-if =" customDarkThemes.length" >
77+ <Select .SelectLabel >
78+ {{
79+ `${i18n.t("preferences:appearance.theme.custom")} · ${i18n.t("preferences:appearance.theme.dark")}`
80+ }}
81+ </Select .SelectLabel >
82+ <Select .SelectItem
83+ v-for =" theme in customDarkThemes"
84+ :key =" theme.id"
85+ :value =" theme.id"
86+ >
87+ {{ theme.name }}
88+ </Select .SelectItem >
89+ </Select .SelectGroup >
90+
91+ <Select .SelectGroup v-if =" customLightThemes.length" >
92+ <Select .SelectLabel >
93+ {{
94+ `${i18n.t("preferences:appearance.theme.custom")} · ${i18n.t("preferences:appearance.theme.light")}`
95+ }}
96+ </Select .SelectLabel >
97+ <Select .SelectItem
98+ v-for =" theme in customLightThemes"
99+ :key =" theme.id"
100+ :value =" theme.id"
101+ >
102+ {{ theme.name }}
103+ </Select .SelectItem >
104+ </Select .SelectGroup >
105+ </template >
106+ </Select .SelectContent >
107+ </Select .Select >
108+ </UiMenuFormItem >
109+
110+ <UiMenuFormItem :label =" i18n.t('preferences:appearance.theme.themesDir')" >
111+ <template #description >
112+ {{ i18n.t("preferences:appearance.theme.dirDescription") }}
113+ </template >
114+ <template #actions >
115+ <div class =" flex gap-2" >
116+ <Button
117+ variant =" outline"
118+ @click =" openThemesDir"
119+ >
120+ {{ i18n.t("preferences:appearance.theme.openDir") }}
121+ </Button >
122+ <Button @click =" createThemeTemplate" >
123+ {{ i18n.t("preferences:appearance.theme.createTemplate") }}
124+ </Button >
125+ </div >
126+ </template >
127+ </UiMenuFormItem >
128+ </UiMenuFormSection >
127129 </div >
128130</template >
0 commit comments