mirror of
https://github.com/zadam/trilium.git
synced 2025-12-01 04:54:25 +01:00
style/note colors: use a more elegant way to retrieve the theme-aware note color
This commit is contained in:
parent
288595ce5d
commit
66f2d0c7dc
@ -44,7 +44,7 @@ function createClassForColor(colorString: string | null) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return clsx(className, colorsWithHue.has(className) && "with-hue");
|
return clsx("use-note-color", className, colorsWithHue.has(className) && "with-hue");
|
||||||
}
|
}
|
||||||
|
|
||||||
function parseColor(color: string) {
|
function parseColor(color: string) {
|
||||||
|
|||||||
@ -109,3 +109,6 @@ body .todo-list input[type="checkbox"]:not(:checked):before {
|
|||||||
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6) !important;
|
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.use-note-color {
|
||||||
|
--custom-color: var(--dark-theme-custom-color);
|
||||||
|
}
|
||||||
@ -92,3 +92,7 @@ html {
|
|||||||
.board-note {
|
.board-note {
|
||||||
color: var(--light-theme-custom-color, inherit);
|
color: var(--light-theme-custom-color, inherit);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.use-note-color {
|
||||||
|
--custom-color: var(--light-theme-custom-color);
|
||||||
|
}
|
||||||
@ -309,3 +309,7 @@ body .todo-list input[type="checkbox"]:not(:checked):before {
|
|||||||
--modal-border-color: hsl(var(--custom-color-hue), 9.4%, 25.1%);
|
--modal-border-color: hsl(var(--custom-color-hue), 9.4%, 25.1%);
|
||||||
--promoted-attribute-card-background-color: hsl(var(--custom-color-hue), 13.2%, 20.8%);
|
--promoted-attribute-card-background-color: hsl(var(--custom-color-hue), 13.2%, 20.8%);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.use-note-color {
|
||||||
|
--custom-color: var(--dark-theme-custom-color);
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user