diff --git a/src/components/settings_modal/tabs/appearance_tab.js b/src/components/settings_modal/tabs/appearance_tab.js index 9a7803ce..7ea4a09a 100644 --- a/src/components/settings_modal/tabs/appearance_tab.js +++ b/src/components/settings_modal/tabs/appearance_tab.js @@ -141,11 +141,12 @@ const AppearanceTab = { cOrange = '#E3FF00' ] = v palette = { key, name, bg, fg, text, link, cRed, cBlue, cGreen, cOrange } - this.bundledPalettes.push() } else { palette = { key, ...v } } - this.bundledPalettes.push(palette) + if (!palette.key.startsWith('style.')) { + this.bundledPalettes.push(palette) + } })) }) @@ -214,6 +215,7 @@ const AppearanceTab = { const result = { name: `${meta.directives.name || this.$t('settings.style.themes3.palette.imported')}: ${variant}`, + key: `style.${variant.toLowerCase().replace(/ /g, '_')}`, bg, fg, text, diff --git a/src/components/settings_modal/tabs/appearance_tab.vue b/src/components/settings_modal/tabs/appearance_tab.vue index a6a84ba2..d8d3ff15 100644 --- a/src/components/settings_modal/tabs/appearance_tab.vue +++ b/src/components/settings_modal/tabs/appearance_tab.vue @@ -114,8 +114,8 @@ v-for="p in stylePalettes || []" :key="p.name" class="btn button-default palette-entry" - :class="{ toggled: isPaletteActive('style.' + p.key) }" - @click="() => setPaletteCustom(p)" + :class="{ toggled: isPaletteActive(p.key) }" + @click="() => setPalette(p.key, p)" >