refactor: refine scheme color semantics
This commit is contained in:
+14
-14
@@ -280,8 +280,8 @@ spec:
|
|||||||
label: 配色
|
label: 配色
|
||||||
formSchema:
|
formSchema:
|
||||||
- $formkit: select
|
- $formkit: select
|
||||||
name: default_scheme_mode
|
name: default_appearance
|
||||||
label: 默认模式
|
label: 默认外观
|
||||||
value: "light"
|
value: "light"
|
||||||
help: 控制访客首次访问时使用的外观模式
|
help: 控制访客首次访问时使用的外观模式
|
||||||
options:
|
options:
|
||||||
@@ -392,14 +392,14 @@ spec:
|
|||||||
label: 主文本色
|
label: 主文本色
|
||||||
validation: "required"
|
validation: "required"
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
name: action
|
name: accent
|
||||||
label: 交互强调色
|
label: 基础强调色
|
||||||
validation: "required"
|
validation: "required"
|
||||||
- $formkit: checkbox
|
- $formkit: checkbox
|
||||||
name: advanced
|
name: advanced
|
||||||
label: 高级颜色设置
|
label: 高级颜色设置
|
||||||
value: false
|
value: false
|
||||||
help: 开启后可以单独设置辅助文本, 标题, 标签, 导航, 控件, 边框和代码等语义颜色
|
help: 开启后可以基于基础色单独设置文字, 导航, 控件, 边框和代码等语义颜色
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
if: "$value.advanced === true"
|
if: "$value.advanced === true"
|
||||||
key: scheme-text-secondary
|
key: scheme-text-secondary
|
||||||
@@ -417,19 +417,19 @@ spec:
|
|||||||
label: 反色文字颜色
|
label: 反色文字颜色
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
if: "$value.advanced === true"
|
if: "$value.advanced === true"
|
||||||
key: scheme-heading
|
key: scheme-text-accent
|
||||||
name: heading
|
name: text_accent
|
||||||
label: 标题颜色
|
label: 强调文字颜色
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
if: "$value.advanced === true"
|
if: "$value.advanced === true"
|
||||||
key: scheme-label
|
key: scheme-text-label
|
||||||
name: label
|
name: text_label
|
||||||
label: 标签颜色
|
label: 标签文字颜色
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
if: "$value.advanced === true"
|
if: "$value.advanced === true"
|
||||||
key: scheme-link
|
key: scheme-text-link
|
||||||
name: link
|
name: text_link
|
||||||
label: 链接颜色
|
label: 链接文字颜色
|
||||||
- $formkit: color
|
- $formkit: color
|
||||||
if: "$value.advanced === true"
|
if: "$value.advanced === true"
|
||||||
key: scheme-navigation
|
key: scheme-navigation
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ export function syncColorSchemePicker() {
|
|||||||
|
|
||||||
if (storedScheme && !hasStoredOption) {
|
if (storedScheme && !hasStoredOption) {
|
||||||
const storedMode = getStoredPreference(PREFERENCE_KEYS.themeMode)
|
const storedMode = getStoredPreference(PREFERENCE_KEYS.themeMode)
|
||||||
|| window.TerminalThemeConfig?.defaultMode
|
|| window.TerminalThemeConfig?.defaultAppearance
|
||||||
|| "system";
|
|| "system";
|
||||||
|
|
||||||
window.applyTheme?.(storedMode, {clearColorScheme: true});
|
window.applyTheme?.(storedMode, {clearColorScheme: true});
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ const APPEARANCE_MODES = ["light", "dark", "system"];
|
|||||||
function getAppearanceMode() {
|
function getAppearanceMode() {
|
||||||
const mode = document.documentElement.dataset.themeMode
|
const mode = document.documentElement.dataset.themeMode
|
||||||
|| getStoredPreference(PREFERENCE_KEYS.themeMode)
|
|| getStoredPreference(PREFERENCE_KEYS.themeMode)
|
||||||
|| window.TerminalThemeConfig?.defaultMode;
|
|| window.TerminalThemeConfig?.defaultAppearance;
|
||||||
|
|
||||||
return APPEARANCE_MODES.includes(mode) ? mode : "system";
|
return APPEARANCE_MODES.includes(mode) ? mode : "system";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ a.button.wide {
|
|||||||
|
|
||||||
a.button.inline {
|
a.button.inline {
|
||||||
background: none;
|
background: none;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
padding: initial;
|
padding: initial;
|
||||||
margin: initial;
|
margin: initial;
|
||||||
border: initial;
|
border: initial;
|
||||||
|
|||||||
+16
-15
@@ -3,16 +3,16 @@ comment-widget {
|
|||||||
--halo-cw-base-rounded: var(--radius-theme-border) !important;
|
--halo-cw-base-rounded: var(--radius-theme-border) !important;
|
||||||
--halo-cw-base-font-size: var(--size-theme-font) !important;
|
--halo-cw-base-font-size: var(--size-theme-font) !important;
|
||||||
|
|
||||||
--halo-cw-primary-1-color: var(--color-theme-action) !important;
|
--halo-cw-primary-1-color: var(--color-theme-accent) !important;
|
||||||
--halo-cw-primary-2-color: var(--color-theme-action-muted) !important;
|
--halo-cw-primary-2-color: var(--color-theme-accent) !important;
|
||||||
--halo-cw-primary-3-color: var(--color-theme-action-subtle) !important;
|
--halo-cw-primary-3-color: var(--color-theme-accent) !important;
|
||||||
|
|
||||||
--halo-cw-text-1-color: var(--color-theme-text) !important;
|
--halo-cw-text-1-color: var(--color-theme-text) !important;
|
||||||
--halo-cw-text-2-color: var(--color-theme-text-secondary) !important;
|
--halo-cw-text-2-color: var(--color-theme-text-secondary) !important;
|
||||||
--halo-cw-text-3-color: var(--color-theme-text-secondary) !important;
|
--halo-cw-text-3-color: var(--color-theme-text-secondary) !important;
|
||||||
|
|
||||||
--halo-cw-muted-1-color: var(--color-theme-text-muted) !important;
|
--halo-cw-muted-1-color: var(--color-theme-text-muted) !important;
|
||||||
--halo-cw-muted-2-color: var(--color-theme-action-subtle) !important;
|
--halo-cw-muted-2-color: var(--color-theme-surface) !important;
|
||||||
--halo-cw-muted-3-color: var(--color-theme-surface) !important;
|
--halo-cw-muted-3-color: var(--color-theme-surface) !important;
|
||||||
|
|
||||||
--halo-cw-emoji-picker-rgb-color: var(--color-theme-background) !important;
|
--halo-cw-emoji-picker-rgb-color: var(--color-theme-background) !important;
|
||||||
@@ -20,7 +20,7 @@ comment-widget {
|
|||||||
--halo-cw-emoji-picker-rgb-background: var(--color-theme-background) !important;
|
--halo-cw-emoji-picker-rgb-background: var(--color-theme-background) !important;
|
||||||
--halo-cw-emoji-picker-rgb-input: var(--color-theme-text) !important;
|
--halo-cw-emoji-picker-rgb-input: var(--color-theme-text) !important;
|
||||||
--halo-cw-emoji-picker-color-border: var(--color-theme-border-muted) !important;
|
--halo-cw-emoji-picker-color-border: var(--color-theme-border-muted) !important;
|
||||||
--halo-cw-emoji-picker-color-border-over: var(--color-theme-border-accent) !important;
|
--halo-cw-emoji-picker-color-border-over: var(--color-theme-border-muted) !important;
|
||||||
|
|
||||||
// --halo-cw-avatar-rounded:
|
// --halo-cw-avatar-rounded:
|
||||||
// --halo-cw-avatar-size
|
// --halo-cw-avatar-size
|
||||||
@@ -35,26 +35,27 @@ comment-widget {
|
|||||||
--halo-comment-widget-component-form-input-color: var(--color-theme-text) !important;
|
--halo-comment-widget-component-form-input-color: var(--color-theme-text) !important;
|
||||||
--halo-comment-widget-component-form-input-border-color: var(--color-theme-border-muted) !important;
|
--halo-comment-widget-component-form-input-border-color: var(--color-theme-border-muted) !important;
|
||||||
--halo-comment-widget-component-form-input-border-color-focus: var(--color-theme-border-accent) !important;
|
--halo-comment-widget-component-form-input-border-color-focus: var(--color-theme-border-accent) !important;
|
||||||
--halo-comment-widget-component-form-input-box-shadow-focus: var(--color-theme-action) !important;
|
--halo-comment-widget-component-form-input-box-shadow-focus: var(--color-theme-accent) !important;
|
||||||
--halo-comment-widget-component-form-button-login-bg-color: var(--color-theme-background) !important;
|
--halo-comment-widget-component-form-button-login-bg-color: var(--color-theme-background) !important;
|
||||||
--halo-comment-widget-component-form-button-login-bg-color-hover: var(--color-theme-surface-hover) !important;
|
// Keep plugin hover tokens visually identical to their resting states.
|
||||||
|
--halo-comment-widget-component-form-button-login-bg-color-hover: var(--color-theme-background) !important;
|
||||||
--halo-comment-widget-component-form-button-login-border-color: var(--color-theme-border-muted) !important;
|
--halo-comment-widget-component-form-button-login-border-color: var(--color-theme-border-muted) !important;
|
||||||
--halo-comment-widget-component-form-button-submit-bg-color: var(--color-theme-action) !important;
|
--halo-comment-widget-component-form-button-submit-bg-color: var(--color-theme-accent) !important;
|
||||||
--halo-comment-widget-component-form-button-submit-color: var(--color-theme-text-inverse) !important;
|
--halo-comment-widget-component-form-button-submit-color: var(--color-theme-text-inverse) !important;
|
||||||
--halo-comment-widget-component-form-button-submit-border-color: var(--color-theme-border-accent) !important;
|
--halo-comment-widget-component-form-button-submit-border-color: var(--color-theme-border-accent) !important;
|
||||||
--halo-comment-widget-component-form-button-submit-border-color-hover: var(--color-theme-action-muted) !important;
|
--halo-comment-widget-component-form-button-submit-border-color-hover: var(--color-theme-border-accent) !important;
|
||||||
--halo-comment-widget-component-form-button-emoji-color: var(--color-theme-action) !important;
|
--halo-comment-widget-component-form-button-emoji-color: var(--color-theme-text-accent) !important;
|
||||||
--halo-comment-widget-component-comment-item-action-bg-color-hover: var(--color-theme-surface-hover) !important;
|
--halo-comment-widget-component-comment-item-action-bg-color-hover: transparent !important;
|
||||||
--halo-comment-widget-component-comment-item-action-color-hover: var(--color-theme-action) !important;
|
--halo-comment-widget-component-comment-item-action-color-hover: currentColor !important;
|
||||||
--halo-comment-widget-component-pagination-button-bg-color-hover: var(--color-theme-surface-hover) !important;
|
--halo-comment-widget-component-pagination-button-bg-color-hover: transparent !important;
|
||||||
--halo-comment-widget-component-pagination-button-bg-color-active: var(--color-theme-surface-hover) !important;
|
--halo-comment-widget-component-pagination-button-bg-color-active: var(--color-theme-surface-strong) !important;
|
||||||
--halo-comment-widget-component-pagination-button-border-color-active: var(--color-theme-border-accent) !important;
|
--halo-comment-widget-component-pagination-button-border-color-active: var(--color-theme-border-accent) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-rgb-color: var(--color-theme-background) !important;
|
--halo-comment-widget-component-emoji-picker-rgb-color: var(--color-theme-background) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-rgb-accent: var(--color-theme-text) !important;
|
--halo-comment-widget-component-emoji-picker-rgb-accent: var(--color-theme-text) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-rgb-background: var(--color-theme-background) !important;
|
--halo-comment-widget-component-emoji-picker-rgb-background: var(--color-theme-background) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-rgb-input: var(--color-theme-text) !important;
|
--halo-comment-widget-component-emoji-picker-rgb-input: var(--color-theme-text) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-color-border: var(--color-theme-border-muted) !important;
|
--halo-comment-widget-component-emoji-picker-color-border: var(--color-theme-border-muted) !important;
|
||||||
--halo-comment-widget-component-emoji-picker-color-border-over: var(--color-theme-border-accent) !important;
|
--halo-comment-widget-component-emoji-picker-color-border-over: var(--color-theme-border-muted) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.comment {
|
.comment {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ halo-contact-form {
|
|||||||
--halo-contact-form-line-height: var(--height-theme-line) !important;
|
--halo-contact-form-line-height: var(--height-theme-line) !important;
|
||||||
--halo-contact-form-border-radius: var(--radius-theme-border) !important;
|
--halo-contact-form-border-radius: var(--radius-theme-border) !important;
|
||||||
--halo-contact-form-width-submit: auto !important;
|
--halo-contact-form-width-submit: auto !important;
|
||||||
--halo-contact-form-color-primary: var(--color-theme-action) !important;
|
--halo-contact-form-color-primary: var(--color-theme-accent) !important;
|
||||||
--halo-contact-form-color-label: var(--color-theme-text) !important;
|
--halo-contact-form-color-label: var(--color-theme-text) !important;
|
||||||
--halo-contact-form-color-input: var(--color-theme-text) !important;
|
--halo-contact-form-color-input: var(--color-theme-text) !important;
|
||||||
--halo-contact-form-color-input-selection: var(--color-theme-selection) !important;
|
--halo-contact-form-color-input-selection: var(--color-theme-selection) !important;
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
|
|
||||||
> span {
|
> span {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
padding: 0.1em 0.45em;
|
padding: 0.1em 0.45em;
|
||||||
border-top: var(--width-theme-border) var(--style-theme-border) var(--color-theme-border-accent);
|
border-top: var(--width-theme-border) var(--style-theme-border) var(--color-theme-border-accent);
|
||||||
border-bottom: var(--width-theme-border) var(--style-theme-border) var(--color-theme-border-accent);
|
border-bottom: var(--width-theme-border) var(--style-theme-border) var(--color-theme-border-accent);
|
||||||
@@ -133,7 +133,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
&-required {
|
&-required {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
font-style: normal;
|
font-style: normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -182,7 +182,7 @@
|
|||||||
border: calc(var(--width-theme-border) / 2) var(--style-theme-border) var(--color-theme-border-accent);
|
border: calc(var(--width-theme-border) / 2) var(--style-theme-border) var(--color-theme-border-accent);
|
||||||
|
|
||||||
span {
|
span {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
font-size: calc(var(--size-theme-font) * 0.75);
|
font-size: calc(var(--size-theme-font) * 0.75);
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
@@ -192,7 +192,7 @@
|
|||||||
&-apply-message {
|
&-apply-message {
|
||||||
margin-bottom: calc(var(--size-theme-font) * 1);
|
margin-bottom: calc(var(--size-theme-font) * 1);
|
||||||
padding: calc(var(--size-theme-font) * 0.5) 0;
|
padding: calc(var(--size-theme-font) * 0.5) 0;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
border-bottom: calc(var(--width-theme-border) / 2) var(--style-theme-table-border) var(--color-theme-border-accent);
|
border-bottom: calc(var(--width-theme-border) / 2) var(--style-theme-table-border) var(--color-theme-border-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+14
-14
@@ -163,7 +163,7 @@ table {
|
|||||||
}
|
}
|
||||||
|
|
||||||
a {
|
a {
|
||||||
color: var(--color-theme-link);
|
color: var(--color-theme-text-link);
|
||||||
text-decoration: var(--text-decoration-theme-link);
|
text-decoration: var(--text-decoration-theme-link);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -174,7 +174,7 @@ button {
|
|||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
padding: calc(var(--size-theme-font) * 0.2) calc(var(--size-theme-font) * .7);
|
padding: calc(var(--size-theme-font) * 0.2) calc(var(--size-theme-font) * .7);
|
||||||
border: calc(var(--width-theme-border) * 1.25) var(--style-theme-border) var(--color-theme-border-accent);
|
border: calc(var(--width-theme-border) * 1.25) var(--style-theme-border) var(--color-theme-border-accent);
|
||||||
border-radius: var(--radius-theme-border);
|
border-radius: var(--radius-theme-border);
|
||||||
@@ -186,7 +186,7 @@ button {
|
|||||||
|
|
||||||
button:focus-visible,
|
button:focus-visible,
|
||||||
a:focus-visible {
|
a:focus-visible {
|
||||||
outline: 1px solid var(--color-theme-action);
|
outline: 1px solid var(--color-theme-accent);
|
||||||
outline-offset: 2px;
|
outline-offset: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -241,7 +241,7 @@ textarea:active,
|
|||||||
select:focus-visible,
|
select:focus-visible,
|
||||||
select:active {
|
select:active {
|
||||||
border-color: var(--color-theme-border-accent);
|
border-color: var(--color-theme-border-accent);
|
||||||
outline: calc(var(--size-theme-font) * 0.0625) var(--style-theme-border) var(--color-theme-action);
|
outline: calc(var(--size-theme-font) * 0.0625) var(--style-theme-border) var(--color-theme-accent);
|
||||||
outline-offset: calc(var(--size-theme-font) * 0.125);
|
outline-offset: calc(var(--size-theme-font) * 0.125);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -274,7 +274,7 @@ input[type="checkbox"] {
|
|||||||
}
|
}
|
||||||
|
|
||||||
input[type="checkbox"]:checked {
|
input[type="checkbox"]:checked {
|
||||||
background: var(--color-theme-action);
|
background: var(--color-theme-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
@@ -322,7 +322,7 @@ figure video {
|
|||||||
}
|
}
|
||||||
|
|
||||||
figure figcaption {
|
figure figcaption {
|
||||||
background: var(--color-theme-action);
|
background: var(--color-theme-accent);
|
||||||
color: var(--color-theme-text-inverse);
|
color: var(--color-theme-text-inverse);
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: var(--size-theme-font);
|
font-size: var(--size-theme-font);
|
||||||
@@ -355,7 +355,7 @@ ol li {
|
|||||||
}
|
}
|
||||||
|
|
||||||
li::marker {
|
li::marker {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
code {
|
code {
|
||||||
@@ -374,8 +374,8 @@ kbd {
|
|||||||
}
|
}
|
||||||
|
|
||||||
kbd {
|
kbd {
|
||||||
background: var(--color-theme-surface-hover);
|
background: var(--color-theme-surface-strong);
|
||||||
border-top: calc(var(--width-theme-border) / 2) solid var(--color-theme-action-subtle);
|
border-top: calc(var(--width-theme-border) / 2) solid var(--color-theme-accent-subtle);
|
||||||
border-left: calc(var(--width-theme-border) / 2) solid var(--color-theme-border-accent);
|
border-left: calc(var(--width-theme-border) / 2) solid var(--color-theme-border-accent);
|
||||||
border-right: calc(var(--width-theme-border) / 2) solid var(--color-theme-border-accent);
|
border-right: calc(var(--width-theme-border) / 2) solid var(--color-theme-border-accent);
|
||||||
border-bottom: calc(var(--width-theme-border) * 2) solid var(--color-theme-border-accent);
|
border-bottom: calc(var(--width-theme-border) * 2) solid var(--color-theme-border-accent);
|
||||||
@@ -420,7 +420,7 @@ sup {
|
|||||||
abbr {
|
abbr {
|
||||||
position: relative;
|
position: relative;
|
||||||
text-decoration-style: wavy;
|
text-decoration-style: wavy;
|
||||||
text-decoration-color: var(--color-theme-action);
|
text-decoration-color: var(--color-theme-accent);
|
||||||
cursor: help;
|
cursor: help;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -466,7 +466,7 @@ td {
|
|||||||
|
|
||||||
th {
|
th {
|
||||||
border-style: var(--style-theme-table-border);
|
border-style: var(--style-theme-table-border);
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
letter-spacing: calc(var(--size-theme-font) * 0.04);
|
letter-spacing: calc(var(--size-theme-font) * 0.04);
|
||||||
@@ -475,7 +475,7 @@ th {
|
|||||||
hr {
|
hr {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border: none;
|
border: none;
|
||||||
background: var(--color-theme-action);
|
background: var(--color-theme-accent);
|
||||||
height: calc(var(--size-theme-font) * 0.125);
|
height: calc(var(--size-theme-font) * 0.125);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -510,7 +510,7 @@ blockquote.twitter-tweet {
|
|||||||
}
|
}
|
||||||
|
|
||||||
blockquote.twitter-tweet a {
|
blockquote.twitter-tweet a {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
text-decoration: var(--text-decoration-theme-post-link);
|
text-decoration: var(--text-decoration-theme-post-link);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -519,7 +519,7 @@ blockquote.twitter-tweet::before {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
top: calc(var(--size-theme-font) * 1.25);
|
top: calc(var(--size-theme-font) * 1.25);
|
||||||
left: calc(var(--size-theme-font) * 1.25);
|
left: calc(var(--size-theme-font) * 1.25);
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -112,7 +112,7 @@
|
|||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
background: var(--color-theme-background);
|
background: var(--color-theme-background);
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
border: calc(var(--size-theme-font) * 0.125) solid var(--color-theme-navigation);
|
border: calc(var(--size-theme-font) * 0.125) solid var(--color-theme-navigation);
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: calc(var(--size-theme-font) * 0.3125);
|
padding: calc(var(--size-theme-font) * 0.3125);
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
&.active {
|
&.active {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
hr {
|
hr {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
background-color: var(--color-theme-action-muted);
|
background-color: var(--color-theme-accent-muted);
|
||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|||||||
@@ -41,7 +41,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-card-label {
|
.portfolio-card-label {
|
||||||
color: var(--color-theme-label);
|
color: var(--color-theme-text-label);
|
||||||
font-size: calc(var(--size-theme-font) * 0.86);
|
font-size: calc(var(--size-theme-font) * 0.86);
|
||||||
line-height: calc(var(--size-theme-font) * 1.4);
|
line-height: calc(var(--size-theme-font) * 1.4);
|
||||||
}
|
}
|
||||||
@@ -93,7 +93,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-meta .portfolio-term {
|
.portfolio-meta .portfolio-term {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-meta .portfolio-term:not(:last-child),
|
.portfolio-meta .portfolio-term:not(:last-child),
|
||||||
@@ -104,7 +104,7 @@
|
|||||||
|
|
||||||
.portfolio-item .portfolio-tags,
|
.portfolio-item .portfolio-tags,
|
||||||
.portfolio-item .portfolio-tags .portfolio-tag {
|
.portfolio-item .portfolio-tags .portfolio-tag {
|
||||||
color: var(--color-theme-label);
|
color: var(--color-theme-text-label);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-detail-post .portfolio-meta-line,
|
.portfolio-detail-post .portfolio-meta-line,
|
||||||
@@ -119,7 +119,7 @@
|
|||||||
|
|
||||||
.portfolio-detail-post .portfolio-techs,
|
.portfolio-detail-post .portfolio-techs,
|
||||||
.portfolio-detail-post .portfolio-techs .portfolio-term {
|
.portfolio-detail-post .portfolio-techs .portfolio-term {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-item .post-excerpt {
|
.portfolio-item .post-excerpt {
|
||||||
@@ -143,18 +143,18 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-action {
|
.portfolio-action {
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
font-size: calc(var(--size-theme-font) * 0.92);
|
font-size: calc(var(--size-theme-font) * 0.92);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-action::before {
|
.portfolio-action::before {
|
||||||
content: "[ ";
|
content: "[ ";
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-action::after {
|
.portfolio-action::after {
|
||||||
content: " ]";
|
content: " ]";
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-empty {
|
.portfolio-empty {
|
||||||
|
|||||||
@@ -42,7 +42,7 @@
|
|||||||
|
|
||||||
.post-title {
|
.post-title {
|
||||||
position: relative;
|
position: relative;
|
||||||
color: var(--color-theme-heading);
|
color: var(--color-theme-text-accent);
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
margin-bottom: calc(var(--size-theme-font) * 0.9375);
|
margin-bottom: calc(var(--size-theme-font) * 0.9375);
|
||||||
padding-bottom: calc(var(--size-theme-font) * 0.9375);
|
padding-bottom: calc(var(--size-theme-font) * 0.9375);
|
||||||
@@ -73,7 +73,7 @@
|
|||||||
|
|
||||||
.post-title a {
|
.post-title a {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
color: var(--color-theme-heading);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-time {
|
.post-time {
|
||||||
@@ -87,11 +87,11 @@
|
|||||||
.post-tags {
|
.post-tags {
|
||||||
margin-bottom: calc(var(--size-theme-font) * 0.3125);
|
margin-bottom: calc(var(--size-theme-font) * 0.3125);
|
||||||
font-size: inherit;
|
font-size: inherit;
|
||||||
color: var(--color-theme-label);
|
color: var(--color-theme-text-label);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-tag {
|
.post-tag {
|
||||||
color: var(--color-theme-label);
|
color: var(--color-theme-text-label);
|
||||||
|
|
||||||
a {
|
a {
|
||||||
color: inherit;
|
color: inherit;
|
||||||
@@ -125,7 +125,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.post-body a {
|
.post-body a {
|
||||||
color: var(--color-theme-link);
|
color: var(--color-theme-text-link);
|
||||||
text-decoration: var(--text-decoration-theme-post-link);
|
text-decoration: var(--text-decoration-theme-post-link);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -157,7 +157,7 @@
|
|||||||
|
|
||||||
.hanchor {
|
.hanchor {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
margin-left: calc(var(--size-theme-font) * 0.625);
|
margin-left: calc(var(--size-theme-font) * 0.625);
|
||||||
visibility: hidden;
|
visibility: hidden;
|
||||||
|
|||||||
+35
-35
@@ -3,48 +3,48 @@
|
|||||||
:root {
|
:root {
|
||||||
--color-theme-background: #f4f4f4;
|
--color-theme-background: #f4f4f4;
|
||||||
--color-theme-text: #3e3e3e;
|
--color-theme-text: #3e3e3e;
|
||||||
|
--color-theme-accent: #003e8a;
|
||||||
--color-theme-text-secondary: color-mix(in srgb, var(--color-theme-text) 85%, var(--color-theme-background));
|
--color-theme-text-secondary: color-mix(in srgb, var(--color-theme-text) 85%, var(--color-theme-background));
|
||||||
--color-theme-text-muted: #2e6cba;
|
--color-theme-text-muted: #2e6cba;
|
||||||
--color-theme-text-inverse: var(--color-theme-background);
|
--color-theme-text-inverse: var(--color-theme-background);
|
||||||
--color-theme-heading: #003e8a;
|
--color-theme-text-accent: var(--color-theme-accent);
|
||||||
--color-theme-label: #07962a;
|
--color-theme-text-label: #07962a;
|
||||||
--color-theme-link: #003e8a;
|
--color-theme-text-link: var(--color-theme-accent);
|
||||||
--color-theme-action: #003e8a;
|
--color-theme-accent-muted: color-mix(in srgb, var(--color-theme-accent) 60%, var(--color-theme-background));
|
||||||
--color-theme-action-muted: color-mix(in srgb, var(--color-theme-action) 60%, var(--color-theme-background));
|
--color-theme-accent-subtle: color-mix(in srgb, var(--color-theme-accent) 30%, var(--color-theme-background));
|
||||||
--color-theme-action-subtle: color-mix(in srgb, var(--color-theme-action) 30%, var(--color-theme-background));
|
|
||||||
--color-theme-navigation: #3e3e3e;
|
--color-theme-navigation: #3e3e3e;
|
||||||
--color-theme-control: #3e3e3e;
|
--color-theme-control: #3e3e3e;
|
||||||
--color-theme-surface: color-mix(in srgb, var(--color-theme-text) 5%, var(--color-theme-background));
|
--color-theme-surface: color-mix(in srgb, var(--color-theme-text) 5%, var(--color-theme-background));
|
||||||
--color-theme-surface-hover: color-mix(in srgb, var(--color-theme-text) 10%, var(--color-theme-background));
|
--color-theme-surface-strong: color-mix(in srgb, var(--color-theme-text) 10%, var(--color-theme-background));
|
||||||
--color-theme-border: var(--color-theme-text);
|
--color-theme-border: var(--color-theme-text);
|
||||||
--color-theme-border-muted: color-mix(in srgb, var(--color-theme-text) 18%, var(--color-theme-background));
|
--color-theme-border-muted: color-mix(in srgb, var(--color-theme-text) 18%, var(--color-theme-background));
|
||||||
--color-theme-border-accent: var(--color-theme-action);
|
--color-theme-border-accent: var(--color-theme-accent);
|
||||||
--color-theme-border-emphasis: #970b16;
|
--color-theme-border-emphasis: #970b16;
|
||||||
--color-theme-selection: color-mix(in srgb, var(--color-theme-action) 45%, var(--color-theme-background));
|
--color-theme-selection: color-mix(in srgb, var(--color-theme-accent) 45%, var(--color-theme-background));
|
||||||
--color-theme-overlay: rgb(0 0 0 / 80%);
|
--color-theme-overlay: rgb(0 0 0 / 80%);
|
||||||
--color-theme-scrollbar: color-mix(in srgb, var(--color-theme-text) 45%, var(--color-theme-background)) transparent;
|
--color-theme-scrollbar: color-mix(in srgb, var(--color-theme-text) 45%, var(--color-theme-background)) transparent;
|
||||||
--color-theme-code-text: var(--color-theme-text);
|
--color-theme-code-text: var(--color-theme-text);
|
||||||
--color-theme-code-background: var(--color-theme-surface-hover);
|
--color-theme-code-background: var(--color-theme-surface-strong);
|
||||||
--color-theme-caret: #970b16;
|
--color-theme-caret: #970b16;
|
||||||
}
|
}
|
||||||
|
|
||||||
html[data-theme-color-scheme] {
|
html[data-theme-color-scheme] {
|
||||||
--color-theme-text-muted: var(--color-theme-text);
|
--color-theme-text-muted: var(--color-theme-text);
|
||||||
--color-theme-heading: var(--color-theme-action);
|
--color-theme-text-accent: var(--color-theme-accent);
|
||||||
--color-theme-label: var(--color-theme-action);
|
--color-theme-text-label: var(--color-theme-accent);
|
||||||
--color-theme-link: var(--color-theme-action);
|
--color-theme-text-link: var(--color-theme-accent);
|
||||||
--color-theme-navigation: var(--color-theme-action);
|
--color-theme-navigation: var(--color-theme-accent);
|
||||||
--color-theme-control: var(--color-theme-action);
|
--color-theme-control: var(--color-theme-accent);
|
||||||
--color-theme-border-emphasis: var(--color-theme-action);
|
--color-theme-border-emphasis: var(--color-theme-accent);
|
||||||
--color-theme-caret: var(--color-theme-action);
|
--color-theme-caret: var(--color-theme-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
$color-schemes: (
|
$color-schemes: (
|
||||||
"day": (
|
"day": (
|
||||||
"background": #f4f4f4,
|
"background": #f4f4f4,
|
||||||
"text": #3e3e3e,
|
"text": #3e3e3e,
|
||||||
"action": #003e8a,
|
"accent": #003e8a,
|
||||||
"label": #07962a,
|
"text-label": #07962a,
|
||||||
"text-muted": #2e6cba,
|
"text-muted": #2e6cba,
|
||||||
"border-emphasis": #970b16,
|
"border-emphasis": #970b16,
|
||||||
"caret": #970b16,
|
"caret": #970b16,
|
||||||
@@ -54,8 +54,8 @@ $color-schemes: (
|
|||||||
"night": (
|
"night": (
|
||||||
"background": #101216,
|
"background": #101216,
|
||||||
"text": #8b949e,
|
"text": #8b949e,
|
||||||
"action": #6ca4f8,
|
"accent": #6ca4f8,
|
||||||
"label": #56d364,
|
"text-label": #56d364,
|
||||||
"text-muted": #6ca4f8,
|
"text-muted": #6ca4f8,
|
||||||
"border-emphasis": #f78166,
|
"border-emphasis": #f78166,
|
||||||
"caret": #f78166,
|
"caret": #f78166,
|
||||||
@@ -65,19 +65,19 @@ $color-schemes: (
|
|||||||
"niello": (
|
"niello": (
|
||||||
"background": #1a170f,
|
"background": #1a170f,
|
||||||
"text": #eceae5,
|
"text": #eceae5,
|
||||||
"action": #eec35e
|
"accent": #eec35e
|
||||||
),
|
),
|
||||||
"matrix": (
|
"matrix": (
|
||||||
"background": #000000,
|
"background": #000000,
|
||||||
"text": #4eee85,
|
"text": #4eee85,
|
||||||
"action": #4eee85
|
"accent": #4eee85
|
||||||
),
|
),
|
||||||
"ink": (
|
"ink": (
|
||||||
"background": #121212,
|
"background": #121212,
|
||||||
"text": #C3C3C3,
|
"text": #C3C3C3,
|
||||||
"text-secondary": #C1C1C1,
|
"text-secondary": #C1C1C1,
|
||||||
"action": #FFFFFF,
|
"accent": #FFFFFF,
|
||||||
"link": #5AC8FA,
|
"text-link": #5AC8FA,
|
||||||
"text-muted": #C1C1C1,
|
"text-muted": #C1C1C1,
|
||||||
"code-text": #FFFFFF,
|
"code-text": #FFFFFF,
|
||||||
"code-background": #1F1F1F
|
"code-background": #1F1F1F
|
||||||
@@ -86,8 +86,8 @@ $color-schemes: (
|
|||||||
"background": #FFFFFF,
|
"background": #FFFFFF,
|
||||||
"text": #1B1B1B,
|
"text": #1B1B1B,
|
||||||
"text-secondary": #595959,
|
"text-secondary": #595959,
|
||||||
"action": #000000,
|
"accent": #000000,
|
||||||
"link": #406ED2,
|
"text-link": #406ED2,
|
||||||
"text-muted": #595959,
|
"text-muted": #595959,
|
||||||
"code-text": #1B1B1B,
|
"code-text": #1B1B1B,
|
||||||
"code-background": #EBEBEB
|
"code-background": #EBEBEB
|
||||||
@@ -95,33 +95,33 @@ $color-schemes: (
|
|||||||
"hopbush": (
|
"hopbush": (
|
||||||
"background": #fff6f6,
|
"background": #fff6f6,
|
||||||
"text": #462d2d,
|
"text": #462d2d,
|
||||||
"action": #cc6099
|
"accent": #cc6099
|
||||||
),
|
),
|
||||||
"pistachio": (
|
"pistachio": (
|
||||||
"background": #1d2021,
|
"background": #1d2021,
|
||||||
"text": #ebdbb2,
|
"text": #ebdbb2,
|
||||||
"action": #8ec07c
|
"accent": #8ec07c
|
||||||
),
|
),
|
||||||
"blue": (
|
"blue": (
|
||||||
"background": #153489,
|
"background": #153489,
|
||||||
"text": #eceae5,
|
"text": #eceae5,
|
||||||
"action": #5ea5ee
|
"accent": #5ea5ee
|
||||||
),
|
),
|
||||||
"vanilla": (
|
"vanilla": (
|
||||||
"background": #fff4f2,
|
"background": #fff4f2,
|
||||||
"text": #424140,
|
"text": #424140,
|
||||||
"action": #8f6a5e
|
"accent": #8f6a5e
|
||||||
),
|
),
|
||||||
"studio": (
|
"studio": (
|
||||||
"background": #f7f4ff,
|
"background": #f7f4ff,
|
||||||
"text": #403352,
|
"text": #403352,
|
||||||
"action": #6f49ab
|
"accent": #6f49ab
|
||||||
),
|
),
|
||||||
"blood": (
|
"blood": (
|
||||||
"background": #221f29,
|
"background": #221f29,
|
||||||
"text": #ffffff,
|
"text": #ffffff,
|
||||||
"action": #ff6266,
|
"accent": #ff6266,
|
||||||
"text-muted": var(--color-theme-action),
|
"text-muted": var(--color-theme-accent),
|
||||||
"navigation": var(--color-theme-text)
|
"navigation": var(--color-theme-text)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
@@ -132,7 +132,7 @@ $color-schemes: (
|
|||||||
--color-theme-#{$role}: #{$color};
|
--color-theme-#{$role}: #{$color};
|
||||||
}
|
}
|
||||||
|
|
||||||
@if map.get($scheme-colors, "text") == map.get($scheme-colors, "action") {
|
@if map.get($scheme-colors, "text") == map.get($scheme-colors, "accent") {
|
||||||
--text-decoration-theme-post-link: underline;
|
--text-decoration-theme-post-link: underline;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ search-modal {
|
|||||||
--halo-search-widget-base-font-size: var(--size-theme-font) !important;
|
--halo-search-widget-base-font-size: var(--size-theme-font) !important;
|
||||||
--halo-search-widget-base-font-family: var(--family-theme-font) !important;
|
--halo-search-widget-base-font-family: var(--family-theme-font) !important;
|
||||||
--halo-search-widget-base-bg-color: var(--color-theme-background) !important;
|
--halo-search-widget-base-bg-color: var(--color-theme-background) !important;
|
||||||
--halo-search-widget-primary-color: var(--color-theme-action) !important;
|
--halo-search-widget-primary-color: var(--color-theme-accent) !important;
|
||||||
--halo-search-widget-muted-color: var(--color-theme-text-muted) !important;
|
--halo-search-widget-muted-color: var(--color-theme-text-muted) !important;
|
||||||
--halo-search-widget-content-color: var(--color-theme-text) !important;
|
--halo-search-widget-content-color: var(--color-theme-text) !important;
|
||||||
--halo-search-widget-hit-bg-color: var(--color-theme-background) !important;
|
--halo-search-widget-hit-bg-color: var(--color-theme-background) !important;
|
||||||
@@ -17,9 +17,9 @@ search-modal {
|
|||||||
--halo-search-widget-color-form-divider: var(--color-theme-border-muted) !important;
|
--halo-search-widget-color-form-divider: var(--color-theme-border-muted) !important;
|
||||||
--halo-search-widget-color-result-empty: var(--color-theme-text-muted) !important;
|
--halo-search-widget-color-result-empty: var(--color-theme-text-muted) !important;
|
||||||
--halo-search-widget-color-result-item-bg: var(--color-theme-background) !important;
|
--halo-search-widget-color-result-item-bg: var(--color-theme-background) !important;
|
||||||
--halo-search-widget-color-result-item-hover-bg: var(--color-theme-surface-hover) !important;
|
--halo-search-widget-color-result-item-hover-bg: var(--color-theme-background) !important;
|
||||||
--halo-search-widget-color-result-item-title: var(--color-theme-action) !important;
|
--halo-search-widget-color-result-item-title: var(--color-theme-text-accent) !important;
|
||||||
--halo-search-widget-color-result-item-content: var(--color-theme-text-muted) !important;
|
--halo-search-widget-color-result-item-content: var(--color-theme-text-muted) !important;
|
||||||
--halo-search-widget-color-command-kbd-item: var(--color-theme-action) !important;
|
--halo-search-widget-color-command-kbd-item: var(--color-theme-text-accent) !important;
|
||||||
--halo-search-widget-color-command-kbd-borde: var(--color-theme-border-accent) !important;
|
--halo-search-widget-color-command-kbd-borde: var(--color-theme-border-accent) !important;
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -76,13 +76,13 @@
|
|||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
}
|
}
|
||||||
|
|
||||||
&.is-active-link,
|
&.is-active-link,
|
||||||
.is-active-li > & {
|
.is-active-li > & {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--color-theme-action);
|
color: var(--color-theme-text-accent);
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -86,7 +86,7 @@
|
|||||||
html[data-theme-color-scheme="[(${scheme.id})]"] {
|
html[data-theme-color-scheme="[(${scheme.id})]"] {
|
||||||
--color-theme-background: [(${scheme.background})];
|
--color-theme-background: [(${scheme.background})];
|
||||||
--color-theme-text: [(${#strings.isEmpty(scheme.text) ? scheme.foreground : scheme.text})];
|
--color-theme-text: [(${#strings.isEmpty(scheme.text) ? scheme.foreground : scheme.text})];
|
||||||
--color-theme-action: [(${#strings.isEmpty(scheme.action) ? scheme.accent : scheme.action})];
|
--color-theme-accent: [(${#strings.isEmpty(scheme.accent) ? scheme.action : scheme.accent})];
|
||||||
|
|
||||||
[# th:if="${not #strings.isEmpty(scheme.text_secondary) or not #strings.isEmpty(scheme.foreground_muted)}"]
|
[# th:if="${not #strings.isEmpty(scheme.text_secondary) or not #strings.isEmpty(scheme.foreground_muted)}"]
|
||||||
--color-theme-text-secondary: [(${#strings.isEmpty(scheme.text_secondary) ? scheme.foreground_muted : scheme.text_secondary})];
|
--color-theme-text-secondary: [(${#strings.isEmpty(scheme.text_secondary) ? scheme.foreground_muted : scheme.text_secondary})];
|
||||||
@@ -100,16 +100,16 @@
|
|||||||
--color-theme-text-inverse: [(${scheme.text_inverse})];
|
--color-theme-text-inverse: [(${scheme.text_inverse})];
|
||||||
[/]
|
[/]
|
||||||
|
|
||||||
[# th:if="${not #strings.isEmpty(scheme.heading) or not #strings.isEmpty(scheme.title)}"]
|
[# th:if="${not #strings.isEmpty(scheme.text_accent) or not #strings.isEmpty(scheme.heading) or not #strings.isEmpty(scheme.title)}"]
|
||||||
--color-theme-heading: [(${#strings.isEmpty(scheme.heading) ? scheme.title : scheme.heading})];
|
--color-theme-text-accent: [(${not #strings.isEmpty(scheme.text_accent) ? scheme.text_accent : (not #strings.isEmpty(scheme.heading) ? scheme.heading : scheme.title)})];
|
||||||
[/]
|
[/]
|
||||||
|
|
||||||
[# th:if="${not #strings.isEmpty(scheme.label) or not #strings.isEmpty(scheme.tag)}"]
|
[# th:if="${not #strings.isEmpty(scheme.text_label) or not #strings.isEmpty(scheme.label) or not #strings.isEmpty(scheme.tag)}"]
|
||||||
--color-theme-label: [(${#strings.isEmpty(scheme.label) ? scheme.tag : scheme.label})];
|
--color-theme-text-label: [(${not #strings.isEmpty(scheme.text_label) ? scheme.text_label : (not #strings.isEmpty(scheme.label) ? scheme.label : scheme.tag)})];
|
||||||
[/]
|
[/]
|
||||||
|
|
||||||
[# th:if="${not #strings.isEmpty(scheme.link)}"]
|
[# th:if="${not #strings.isEmpty(scheme.text_link) or not #strings.isEmpty(scheme.link)}"]
|
||||||
--color-theme-link: [(${scheme.link})];
|
--color-theme-text-link: [(${#strings.isEmpty(scheme.text_link) ? scheme.link : scheme.text_link})];
|
||||||
[/]
|
[/]
|
||||||
|
|
||||||
[# th:if="${not #strings.isEmpty(scheme.navigation) or not #strings.isEmpty(scheme.menu)}"]
|
[# th:if="${not #strings.isEmpty(scheme.navigation) or not #strings.isEmpty(scheme.menu)}"]
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
lightTheme: /*[[${theme.config.color_scheme.light_color_scheme}]]*/ "light",
|
lightTheme: /*[[${theme.config.color_scheme.light_color_scheme}]]*/ "light",
|
||||||
customDarkTheme: /*[[${theme.config.color_scheme.custom_dark_scheme}]]*/ "",
|
customDarkTheme: /*[[${theme.config.color_scheme.custom_dark_scheme}]]*/ "",
|
||||||
customLightTheme: /*[[${theme.config.color_scheme.custom_light_scheme}]]*/ "",
|
customLightTheme: /*[[${theme.config.color_scheme.custom_light_scheme}]]*/ "",
|
||||||
defaultMode: /*[[${theme.config.color_scheme.default_scheme_mode}]]*/ "system",
|
defaultAppearance: /*[[${theme.config.color_scheme.default_appearance}]]*/ "light",
|
||||||
preferTTL: /*[[${theme.config.general.prefer_ttl ?: 24}]]*/ 24,
|
preferTTL: /*[[${theme.config.general.prefer_ttl ?: 24}]]*/ 24,
|
||||||
pixelStyle: /*[[${theme.config.global_style.pixel_style}]]*/ false,
|
pixelStyle: /*[[${theme.config.global_style.pixel_style}]]*/ false,
|
||||||
pixelCssHref: /*[[@{/assets/dist/pixel.css?v={version}(version=${theme.spec.version})}]]*/ "",
|
pixelCssHref: /*[[@{/assets/dist/pixel.css?v={version}(version=${theme.spec.version})}]]*/ "",
|
||||||
@@ -153,7 +153,7 @@
|
|||||||
|
|
||||||
function syncThemeMode() {
|
function syncThemeMode() {
|
||||||
const storedMode = getStoredPreference(storageKeys.themeMode)
|
const storedMode = getStoredPreference(storageKeys.themeMode)
|
||||||
|| config.defaultMode
|
|| config.defaultAppearance
|
||||||
|| "system";
|
|| "system";
|
||||||
|
|
||||||
applyTheme(storedMode);
|
applyTheme(storedMode);
|
||||||
@@ -179,7 +179,7 @@
|
|||||||
|
|
||||||
window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", () => {
|
window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", () => {
|
||||||
const mode = getStoredPreference(storageKeys.themeMode)
|
const mode = getStoredPreference(storageKeys.themeMode)
|
||||||
|| config.defaultMode
|
|| config.defaultAppearance
|
||||||
|| "system";
|
|| "system";
|
||||||
if (mode === "system") {
|
if (mode === "system") {
|
||||||
applyTheme("system");
|
applyTheme("system");
|
||||||
|
|||||||
Reference in New Issue
Block a user