Merge pull request #345 from ThatOneCalculator/main

Add Rosé Pine Dawn theme
This commit is contained in:
Timothy Jaeryang Baek 2024-01-01 22:55:29 -05:00 committed by GitHub
commit 73ca167d70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 196 additions and 13 deletions

View File

@ -15,8 +15,9 @@
} else if (localStorage.theme === 'dark') {
document.documentElement.classList.add('dark');
} else {
document.documentElement.classList.add('dark');
document.documentElement.classList.add(localStorage.theme);
localStorage.theme.split(' ').forEach((e) => {
document.documentElement.classList.add(e);
});
}
</script>

View File

@ -34,7 +34,7 @@
// General
let API_BASE_URL = OLLAMA_API_BASE_URL;
let themes = ['dark', 'light', 'rose-pine'];
let themes = ['dark', 'light', 'rose-pine dark', 'rose-pine-dawn light'];
let theme = 'dark';
let notificationEnabled = false;
let system = '';
@ -994,21 +994,22 @@
themes
.filter((e) => e !== theme)
.forEach((e) => {
document.documentElement.classList.remove(e);
e.split(' ').forEach((e) => {
document.documentElement.classList.remove(e);
});
});
document.documentElement.classList.add(theme);
if (theme === 'rose-pine') {
document.documentElement.classList.add('dark');
}
theme.split(' ').forEach((e) => {
document.documentElement.classList.add(e);
});
console.log(theme);
}}
>
<option value="dark">Dark</option>
<option value="light">Light</option>
<option value="rose-pine">Rosé Pine</option>
<option value="rose-pine dark">Rosé Pine</option>
<option value="rose-pine-dawn light">Rosé Pine Dawn</option>
</select>
</div>
</div>

View File

@ -132,7 +132,7 @@
{/if}
<div class="px-2.5 mt-1 mb-2 flex justify-center space-x-2">
<div class="flex w-full">
<div class="flex w-full" id="chat-search">
<div class="self-center pl-3 py-2 rounded-l bg-gray-950">
<svg
xmlns="http://www.w3.org/2000/svg"

View File

@ -57,6 +57,7 @@
<title>Ollama</title>
<link rel="stylesheet" type="text/css" href="/themes/rosepine.css" />
<link rel="stylesheet" type="text/css" href="/themes/rosepine-dawn.css" />
</svelte:head>
{#if loaded}

View File

@ -0,0 +1,140 @@
.rose-pine-dawn * {
color: #575279 !important;
stroke: #d7827e !important;
}
.rose-pine-dawn .app > * {
background-color: #faf4ed !important;
}
.rose-pine-dawn #nav {
background-color: #fffaf3;
}
.rose-pine-dawn .py-2\.5.my-auto.flex.flex-col.justify-between.h-screen {
background: #f2e9e1;
}
.rose-pine-dawn .bg-white.dark\:bg-gray-800 {
background: #f2e9e1;
}
.rose-pine-dawn .w-4.h-4 {
fill: #ebbcba;
}
.rose-pine-dawn #chat-textarea {
background: #cecacd;
margin: 0.3rem;
padding: 0.5rem;
}
.rose-pine-dawn .bg-gradient-to-t.from-white.dark\:from-gray-800.from-40\%.pb-2 {
background: #f2e9e1 !important;
padding-top: 0.6rem;
}
.rose-pine-dawn
.text-white.bg-gray-100.dark\:text-gray-800.dark\:bg-gray-600.disabled.transition.rounded-lg.p-1.mr-0\.5.w-7.h-7.self-center {
background-color: #cecacd;
transition: background-color 0.2s ease-out linear;
}
.rose-pine-dawn
.bg-black.text-white.hover\:bg-gray-900.dark\:bg-white.dark\:text-black.dark\:hover\:bg-gray-100.transition.rounded-lg.p-1.mr-0\.5.w-7.h-7.self-center {
background-color: #286983;
transition: background-color 0.2s ease-out linear;
}
.rose-pine-dawn
.bg-black.text-white.hover\:bg-gray-900.dark\:bg-white.dark\:text-black.dark\:hover\:bg-gray-100.transition.rounded-lg.p-1.mr-0\.5.w-7.h-7.self-center
> * {
fill: #56949f !important;
transition: fill 0.2s ease-out linear;
}
.rose-pine-dawn
.w-full.flex.justify-between.rounded-md.px-3.py-2.hover\:bg-gray-900.bg-gray-900.transition.whitespace-nowrap.text-ellipsis {
background-color: #56526e;
font-weight: bold;
}
.rose-pine-dawn .hover\:bg-gray-900:hover {
--tw-bg-opacity: 1;
background-color: rgb(152 147 165 / var(--tw-bg-opacity));
}
.rose-pine-dawn .text-xs.text-gray-700.uppercase.bg-gray-50.dark\:bg-gray-700.dark\:text-gray-400 {
background-color: #403d52;
}
.rose-pine-dawn .scrollbar-hidden.relative.overflow-x-auto.whitespace-nowrap.svelte-3g4avz {
border-radius: 16px 16px 0 0;
}
.rose-pine-dawn .base.enter.svelte-ug60r4 {
background-color: #286983;
}
.rose-pine-dawn .message.svelte-1nauejd {
color: #e0def4 !important;
}
#dropdownDots {
background-color: #dfdad9;
}
.flex.py-2\.5.px-3\.5.w-full.hover\:bg-gray-800.transition:hover {
background: #cecacd;
}
.rose-pine-dawn #dropdownDots {
background-color: #dfdad9;
}
.rose-pine-dawn .flex.py-2\.5.px-3\.5.w-full.hover\:bg-gray-800.transition:hover {
background: #cecacd;
}
.rose-pine-dawn
.m-auto.rounded-xl.max-w-full.w-\[40rem\].mx-2.bg-gray-50.dark\:bg-gray-900.shadow-3xl {
background-color: #f2e9e1;
}
.rose-pine-dawn
.w-full.rounded.p-4.text-sm.dark\:text-gray-300.dark\:bg-gray-800.outline-none.resize-none {
background-color: #cecacd;
}
.rose-pine-dawn
.w-full.rounded.py-2.px-4.text-sm.dark\:text-gray-300.dark\:bg-gray-800.outline-none.svelte-1vx7r9s {
background-color: #cecacd;
}
.rose-pine-dawn
.px-2\.5.py-2\.5.min-w-fit.rounded-lg.flex-1.md\:flex-none.flex.text-right.transition.bg-gray-200.dark\:bg-gray-700 {
background-color: #dfdad9;
}
.rose-pine-dawn
.px-2\.5.py-2\.5.min-w-fit.rounded-lg.flex-1.md\:flex-none.flex.text-right.transition.hover\:bg-gray-300.dark\:hover\:bg-gray-800:hover {
background-color: #cecacd;
}
.rose-pine-dawn .px-4.py-2.bg-emerald-600.hover\:bg-emerald-700.text-gray-100.transition.rounded {
background-color: #56949f;
}
.rose-pine-dawn #chat-search > * {
background-color: #dfdad9 !important;
}
.rose-pine-dawn .svelte-1ee93ns {
--primary: #b4637a !important;
--secondary: #fffaf3 !important;
}
.rose-pine-dawn .svelte-11kvm4p {
--primary: #56949f !important;
--secondary: #fffaf3 !important;
}

View File

@ -37,13 +37,13 @@
.rose-pine
.text-white.bg-gray-100.dark\:text-gray-800.dark\:bg-gray-600.disabled.transition.rounded-lg.p-1.mr-0\.5.w-7.h-7.self-center {
background-color: #6e6a86;
transition: background 0.2s ease-out linear;
transition: background-color 0.2s ease-out linear;
}
.rose-pine
.bg-black.text-white.hover\:bg-gray-900.dark\:bg-white.dark\:text-black.dark\:hover\:bg-gray-100.transition.rounded-lg.p-1.mr-0\.5.w-7.h-7.self-center {
background-color: #286983;
transition: background 0.2s ease-out linear;
transition: background-color 0.2s ease-out linear;
}
.rose-pine
@ -80,6 +80,46 @@
color: #e0def4 !important;
}
.rose-pine #dropdownDots {
background-color: #403d52;
}
.rose-pine .flex.py-2\.5.px-3\.5.w-full.hover\:bg-gray-800.transition:hover {
background: #524f67;
}
.rose-pine .m-auto.rounded-xl.max-w-full.w-\[40rem\].mx-2.bg-gray-50.dark\:bg-gray-900.shadow-3xl {
background-color: #26233a;
}
.rose-pine
.w-full.rounded.p-4.text-sm.dark\:text-gray-300.dark\:bg-gray-800.outline-none.resize-none {
background-color: #524f67;
}
.rose-pine
.w-full.rounded.py-2.px-4.text-sm.dark\:text-gray-300.dark\:bg-gray-800.outline-none.svelte-1vx7r9s {
background-color: #524f67;
}
.rose-pine
.px-2\.5.py-2\.5.min-w-fit.rounded-lg.flex-1.md\:flex-none.flex.text-right.transition.bg-gray-200.dark\:bg-gray-700 {
background-color: #403d52;
}
.rose-pine
.px-2\.5.py-2\.5.min-w-fit.rounded-lg.flex-1.md\:flex-none.flex.text-right.transition.hover\:bg-gray-300.dark\:hover\:bg-gray-800:hover {
background-color: #524f67;
}
.rose-pine .px-4.py-2.bg-emerald-600.hover\:bg-emerald-700.text-gray-100.transition.rounded {
background-color: #31748f;
}
.rose-pine #chat-search > * {
background-color: #403d52 !important;
}
.rose-pine .svelte-1ee93ns {
--primary: #eb6f92 !important;
--secondary: #e0def4 !important;