|
|
|
@ -1,27 +1,57 @@
|
|
|
|
|
/* prettier-ignore */
|
|
|
|
|
/* This file is also parsed in JS to build theme styles, see theme-vars.js */
|
|
|
|
|
@function set-theme-vars($t) {
|
|
|
|
|
@return map-merge(
|
|
|
|
|
$t,
|
|
|
|
|
(
|
|
|
|
|
muted-color: mix(map-get($t, medium-color), map-get($t, background-color), map-get($t, mute-percent)),
|
|
|
|
|
muted-color-border: mix(map-get($t, medium-color), map-get($t, background-color), semi-mute-percent(map-get($t, mute-percent))),
|
|
|
|
|
muted-color:
|
|
|
|
|
mix(
|
|
|
|
|
map-get($t, medium-color),
|
|
|
|
|
map-get($t, background-color),
|
|
|
|
|
map-get($t, mute-percent)
|
|
|
|
|
),
|
|
|
|
|
muted-color-border:
|
|
|
|
|
mix(
|
|
|
|
|
map-get($t, medium-color),
|
|
|
|
|
map-get($t, background-color),
|
|
|
|
|
semi-mute-percent(map-get($t, mute-percent))
|
|
|
|
|
),
|
|
|
|
|
text-selection-bg-color: rgba(map-get($t, action-color), 0.3),
|
|
|
|
|
text-selection-bg-color-error: rgba(map-get($t, error-color), 0.8),
|
|
|
|
|
text-semi-muted-color: mix(map-get($t, action-color), map-get($t, text-color), 0.5),
|
|
|
|
|
text-contrast-action-color: text-contrast-color(map-get($t, action-color), map-get($t, color-lightness-shift), map-get($t, background-color), map-get($t, text-color)),
|
|
|
|
|
text-contrast-error-color: text-contrast-color(map-get($t, error-color), map-get($t, color-lightness-shift), map-get($t, background-color), map-get($t, text-color)),
|
|
|
|
|
text-contrast-action-color:
|
|
|
|
|
text-contrast-color(
|
|
|
|
|
map-get($t, action-color),
|
|
|
|
|
map-get($t, color-lightness-shift),
|
|
|
|
|
map-get($t, background-color),
|
|
|
|
|
map-get($t, text-color)
|
|
|
|
|
),
|
|
|
|
|
text-contrast-error-color:
|
|
|
|
|
text-contrast-color(
|
|
|
|
|
map-get($t, error-color),
|
|
|
|
|
map-get($t, color-lightness-shift),
|
|
|
|
|
map-get($t, background-color),
|
|
|
|
|
map-get($t, text-color)
|
|
|
|
|
),
|
|
|
|
|
base-border-color: mix(map-get($t, medium-color), map-get($t, background-color), 50%),
|
|
|
|
|
accent-border-color: mix(map-get($t, medium-color), map-get($t, background-color), 65%),
|
|
|
|
|
light-border-color: mix(map-get($t, medium-color), map-get($t, background-color), map-get($t, light-border-percent)),
|
|
|
|
|
form-box-border-color-focus: mix(map-get($t, action-color), map-get($t, text-color), 70%),
|
|
|
|
|
form-box-shadow-color-focus: rgba(mix(map-get($t, action-color), map-get($t, text-color), 70%), 0.7),
|
|
|
|
|
form-box-shadow-color-hover: rgba(mix(map-get($t, action-color), map-get($t, text-color), 70%), 0.5),
|
|
|
|
|
light-border-color:
|
|
|
|
|
mix(
|
|
|
|
|
map-get($t, medium-color),
|
|
|
|
|
map-get($t, background-color),
|
|
|
|
|
map-get($t, light-border-percent)
|
|
|
|
|
),
|
|
|
|
|
form-box-border-color-focus:
|
|
|
|
|
mix(map-get($t, action-color), map-get($t, text-color), 70%),
|
|
|
|
|
form-box-shadow-color-focus:
|
|
|
|
|
rgba(mix(map-get($t, action-color), map-get($t, text-color), 70%), 0.7),
|
|
|
|
|
form-box-shadow-color-hover:
|
|
|
|
|
rgba(mix(map-get($t, action-color), map-get($t, text-color), 70%), 0.5),
|
|
|
|
|
form-box-shadow-color-focus-error: lightness-alpha(map-get($t, error-color), -5%, -0.3),
|
|
|
|
|
dropdown-box-shadow-color: rgba(map-get($t, medium-color), 0.05),
|
|
|
|
|
secondary-background-color: mix(map-get($t, medium-color), map-get($t, background-color), 10%),
|
|
|
|
|
intermediate-background-color: mix(map-get($t, medium-color), map-get($t, background-color), 3%),
|
|
|
|
|
intermediate-pressed-background-color: mix(map-get($t, medium-color), map-get($t, background-color), 2.6%),
|
|
|
|
|
secondary-background-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 10%),
|
|
|
|
|
intermediate-background-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 3%),
|
|
|
|
|
intermediate-pressed-background-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 2.6%),
|
|
|
|
|
disabled-background-color: shade(map-get($t, background-color), 5%),
|
|
|
|
|
action-background-color-focus: shade(map-get($t, action-color), 20%),
|
|
|
|
|
action-background-color-focus-tr: rgba(shade(map-get($t, action-color), 20%), 0.1),
|
|
|
|
@ -34,9 +64,13 @@
|
|
|
|
|
modal-background-color: rgba(map-get($t, background-color), map-get($t, modal-opacity)),
|
|
|
|
|
modal-background-color-tr: rgba(map-get($t, background-color), 0),
|
|
|
|
|
selected-item-color: mix(map-get($t, action-color), map-get($t, background-color), 85%),
|
|
|
|
|
selected-on-secondary-item-color: mix(map-get($t, medium-color), map-get($t, background-color), 30%),
|
|
|
|
|
selectable-on-secondary-item-color: mix(map-get($t, medium-color), map-get($t, background-color), 14%),
|
|
|
|
|
clickable-on-secondary-color: mix(map-get($t, medium-color), map-get($t, background-color), 75%),
|
|
|
|
|
)
|
|
|
|
|
selected-on-secondary-item-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 30%),
|
|
|
|
|
selectable-on-secondary-item-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 14%),
|
|
|
|
|
clickable-on-secondary-color:
|
|
|
|
|
mix(map-get($t, medium-color), map-get($t, background-color), 75%)
|
|
|
|
|
),
|
|
|
|
|
$t
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|