From 46b51efb65a7c26acc1110f17cec603613e7ca20 Mon Sep 17 00:00:00 2001 From: Volpeon Date: Fri, 18 Oct 2024 23:42:50 +0200 Subject: Update --- src/objects/_button.vars.scss | 69 ++++++++++++++++++++++--------------------- 1 file changed, 35 insertions(+), 34 deletions(-) (limited to 'src/objects') diff --git a/src/objects/_button.vars.scss b/src/objects/_button.vars.scss index 80d9274..237cb79 100644 --- a/src/objects/_button.vars.scss +++ b/src/objects/_button.vars.scss @@ -37,29 +37,47 @@ $sizes: ( $default-theme-override: () !default; $default-theme: props.def(--o-button, ( - --default: ( + --bg: props.get(core.$theme, --border-mute), + --label: props.get(core.$theme, --text), + --outline-border: props.get(core.$theme, --border), + --outline-label: props.get(core.$theme, --text), + + --hover: ( + --bg: props.get(core.$theme, --border), + --label: props.get(core.$theme, --heading), + ), + + --active: ( + --bg: props.get(core.$theme, --border-strong), + --label: props.get(core.$theme, --heading), + ), + + --disabled: ( --bg: props.get(core.$theme, --border-mute), - --label: props.get(core.$theme, --text), --outline-border: props.get(core.$theme, --border), + --label: props.get(core.$theme, --text-disabled), + ), + + --key-focus: ( + --label: props.get(core.$theme, --focus --text), + --border: props.get(core.$theme, --focus --border), + --outline: props.get(core.$theme, --focus --outline), + ), + + --primary: ( + --bg: props.get(core.$theme, --base, --800), + --label: props.get(core.$theme, --base, --800-text), + --outline-border: props.get(core.$theme, --base, --800), --outline-label: props.get(core.$theme, --text), --hover: ( - --bg: props.get(core.$theme, --border), - --label: props.get(core.$theme, --heading), + --bg: props.get(core.$theme, --base, --900), + --label: props.get(core.$theme, --base, --900-text), ), + --active: ( - --bg: props.get(core.$theme, --border-strong), - --label: props.get(core.$theme, --heading), - ), - --disabled: ( - --bg: props.get(core.$theme, --border-mute), - --outline-border: props.get(core.$theme, --border), - --label: props.get(core.$theme, --text-disabled), - ), - --key-focus: ( - --label: props.get(core.$theme, --focus --text), - --border: props.get(core.$theme, --focus --border), - --outline: props.get(core.$theme, --focus --outline), + --bg: props.get(core.$theme, --base, --900), + --label: props.get(core.$theme, --base, --900-text), ), ), )); @@ -122,24 +140,7 @@ $static-themes: props.def(--o-button); $themes-config: --accent --negative !default; -$themes: props.def(--o-button, ( - --primary: ( - --bg: props.get(core.$theme, --base, --800), - --label: props.get(core.$theme, --base, --800-text), - --outline-border: props.get(core.$theme, --base, --800), - --outline-label: props.get(core.$theme, --text), - - --hover: ( - --bg: props.get(core.$theme, --base, --900), - --label: props.get(core.$theme, --base, --900-text), - ), - - --active: ( - --bg: props.get(core.$theme, --base, --900), - --label: props.get(core.$theme, --base, --900-text), - ), - ), -)); +$themes: props.def(--o-button); @each $theme in $themes-config { $themes: props.merge($themes, ( -- cgit v1.2.3-70-g09d2