mirror of
https://github.com/fmhy/edit.git
synced 2026-01-13 15:31:07 +11:00
99% chance this wont work
This commit is contained in:
parent
aa5eb9c43b
commit
8b0df932b8
1 changed files with 8 additions and 2 deletions
|
|
@ -196,7 +196,13 @@ const normalizeColorName = (colorName: string) =>
|
||||||
colorName.slice(1).replaceAll(/-/g, ' ')
|
colorName.slice(1).replaceAll(/-/g, ' ')
|
||||||
|
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
// Don't auto-apply color theme - only apply when user explicitly selects
|
// apply saved theme on load
|
||||||
|
if (selectedColor.value) {
|
||||||
|
const theme = generateThemeFromColor(selectedColor.value)
|
||||||
|
themeRegistry[`color-${selectedColor.value}`] = theme
|
||||||
|
await nextTick()
|
||||||
|
setTheme(`color-${selectedColor.value}`)
|
||||||
|
}
|
||||||
// Wait for next tick to ensure theme handler is fully initialized
|
// Wait for next tick to ensure theme handler is fully initialized
|
||||||
await nextTick()
|
await nextTick()
|
||||||
})
|
})
|
||||||
|
|
@ -260,4 +266,4 @@ const toggleAmoled = () => {
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue