fix: properly insert stylesheet with useHead()
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful
ci/woodpecker/pull_request_closed/build-and-publish Pipeline was successful

This commit is contained in:
JustTemmie 2025-07-03 19:13:29 +02:00
parent 41a0f3f14b
commit 126ae5e18d
Signed by: justtemmie
SSH key fingerprint: SHA256:nBO+OwpTkd8LYhe38PIqdxmDvkIg9Vw2EbrRZM97dkU

10
app.vue
View file

@ -1,6 +1,5 @@
<template> <template>
<div> <div>
<link :href="'/themes/' + current_theme + '.css'" rel="stylesheet" type="text/css"></link>
<Banner v-if="banner" /> <Banner v-if="banner" />
<NuxtPage :keepalive="true" /> <NuxtPage :keepalive="true" />
</div> </div>
@ -15,6 +14,15 @@ const saved_theme = localStorage.getItem("selectedTheme");
if (saved_theme) { if (saved_theme) {
current_theme = saved_theme; current_theme = saved_theme;
} }
useHead({
link: [
{
rel: "stylesheet",
href: `/themes/${current_theme}.css`
}
]
})
</script> </script>
<style> <style>