diff options
| author | Volpeon <git@volpeon.ink> | 2022-02-05 12:26:35 +0100 |
|---|---|---|
| committer | Volpeon <git@volpeon.ink> | 2022-02-05 12:26:35 +0100 |
| commit | 144b7a2ea83507c98544d14ad9435cc5e51ac071 (patch) | |
| tree | 7b18227482fa9f5d29d358ce1540b7a6d105febd /src/_vars.scss | |
| parent | Init (diff) | |
| download | iro-design-144b7a2ea83507c98544d14ad9435cc5e51ac071.tar.gz iro-design-144b7a2ea83507c98544d14ad9435cc5e51ac071.tar.bz2 iro-design-144b7a2ea83507c98544d14ad9435cc5e51ac071.zip | |
Update
Diffstat (limited to 'src/_vars.scss')
| -rw-r--r-- | src/_vars.scss | 85 |
1 files changed, 47 insertions, 38 deletions
diff --git a/src/_vars.scss b/src/_vars.scss index 5a6c1d0..d2bdf38 100644 --- a/src/_vars.scss +++ b/src/_vars.scss | |||
| @@ -1,13 +1,14 @@ | |||
| 1 | @use 'iro-sass/src/index' as iro; | 1 | @use 'iro-sass/src/index' as iro; |
| 2 | @use 'include-media/dist/include-media' as media; | ||
| 2 | 3 | ||
| 3 | iro.$vars-root-size: 16px; | 4 | iro.$vars-root-size: 16px; |
| 4 | 5 | ||
| 5 | $breakpoints: ( | 6 | media.$breakpoints: ( |
| 6 | md: 40rem, | 7 | md: 40rem, |
| 7 | sm: 28rem | 8 | sm: 28rem |
| 8 | ); | 9 | ); |
| 9 | 10 | ||
| 10 | $unit-intervals: ( | 11 | media.$unit-intervals: ( |
| 11 | 'px': 1, | 12 | 'px': 1, |
| 12 | 'em': .01, | 13 | 'em': .01, |
| 13 | 'rem': .01, | 14 | 'rem': .01, |
| @@ -22,45 +23,15 @@ $font--main: ( | |||
| 22 | ); | 23 | ); |
| 23 | 24 | ||
| 24 | $font--headline: ( | 25 | $font--headline: ( |
| 25 | family: ('IBM Plex Sans', 'Open Sans', 'Segoe UI', 'Droid Sans', Roboto, Oxygen, 'Helvetica Neue', Helvetica, Tahoma, Arial, sans-serif), | 26 | family: ('IBM Plex Sans', 'Open Sans', 'Segoe UI', 'Droid Sans', Roboto, Oxygen, 'Helvetica Neue', Helvetica, Tahoma, Arial, sans-serif), |
| 26 | line-height: 1.2, | 27 | line-height: 1.2, |
| 27 | weight: 700, | 28 | weight: 700, |
| 28 | ); | 29 | ); |
| 29 | 30 | ||
| 30 | $line-height: map-get($font--main, line-height); | 31 | $line-height: map-get($font--main, line-height); |
| 31 | 32 | ||
| 32 | // | 33 | // |
| 33 | 34 | ||
| 34 | $theme-light: ( | ||
| 35 | --gray1: hsl(210, 0%, 100%), // 1.11 | ||
| 36 | --gray2: hsl(210, 0%, 98%), // 1.07 | ||
| 37 | --gray3: hsl(210, 0%, 95%), // 1 | ||
| 38 | --gray4: hsl(210, 0%, 90%), // 1.11 | ||
| 39 | --gray5: hsl(210, 0%, 87%), // 1.2 | ||
| 40 | --gray6: hsl(210, 0%, 78%), // 1.51 | ||
| 41 | --gray7: hsl(210, 0%, 69%), // 1.93 | ||
| 42 | --gray8: hsl(210, 0%, 55%), // 3 | ||
| 43 | --gray9: hsl(210, 0%, 38%), // 5.53 | ||
| 44 | --gray10: hsl(210, 0%, 19%), // 11.78 | ||
| 45 | --gray11: hsl(210, 0%, 0%), // 18.75 | ||
| 46 | ); | ||
| 47 | |||
| 48 | $theme-lighter: ( | ||
| 49 | --gray1: hsl(210, 0%, 100%), // 1 | ||
| 50 | --gray2: hsl(210, 0%, 100%), // 1 | ||
| 51 | --gray3: hsl(210, 0%, 100%), // 1 | ||
| 52 | --gray4: hsl(210, 0%, 95%), // 1.11 | ||
| 53 | --gray5: hsl(210, 0%, 92%), // 1.19 | ||
| 54 | --gray6: hsl(210, 0%, 82%), // 1.52 | ||
| 55 | --gray7: hsl(210, 0%, 73%), // 1.94 | ||
| 56 | --gray8: hsl(210, 0%, 58%), // 3.03 | ||
| 57 | --gray9: hsl(210, 0%, 41%), // 5.48 | ||
| 58 | --gray10: hsl(210, 0%, 22%), // 11.72 | ||
| 59 | --gray11: hsl(210, 0%, 0%), // 21 | ||
| 60 | ); | ||
| 61 | |||
| 62 | // | ||
| 63 | |||
| 64 | @include iro.fn-execute { | 35 | @include iro.fn-execute { |
| 65 | $primary-accent-base: hsl(222, 49.8%, 52.4%); | 36 | $primary-accent-base: hsl(222, 49.8%, 52.4%); |
| 66 | $error-accent-base: hsl(352, 49.8%, 52.4%); | 37 | $error-accent-base: hsl(352, 49.8%, 52.4%); |
| @@ -119,6 +90,18 @@ $theme-lighter: ( | |||
| 119 | ), | 90 | ), |
| 120 | 91 | ||
| 121 | --colors: ( | 92 | --colors: ( |
| 93 | --gray1: hsl(210, 0%, 100%), // 1.11 | ||
| 94 | --gray2: hsl(210, 0%, 98%), // 1.07 | ||
| 95 | --gray3: hsl(210, 0%, 95%), // 1 | ||
| 96 | --gray4: hsl(210, 0%, 90%), // 1.11 | ||
| 97 | --gray5: hsl(210, 0%, 87%), // 1.2 | ||
| 98 | --gray6: hsl(210, 0%, 78%), // 1.51 | ||
| 99 | --gray7: hsl(210, 0%, 69%), // 1.93 | ||
| 100 | --gray8: hsl(210, 0%, 55%), // 3 | ||
| 101 | --gray9: hsl(210, 0%, 38%), // 5.53 | ||
| 102 | --gray10: hsl(210, 0%, 19%), // 11.78 | ||
| 103 | --gray11: hsl(210, 0%, 0%), // 18.75 | ||
| 104 | |||
| 122 | --bg-hi2: iro.props-get(--colors --gray1, null), // Lightest background | 105 | --bg-hi2: iro.props-get(--colors --gray1, null), // Lightest background |
| 123 | --bg-hi: iro.props-get(--colors --gray2, null), // Lighter background | 106 | --bg-hi: iro.props-get(--colors --gray2, null), // Lighter background |
| 124 | --bg: iro.props-get(--colors --gray3, null), // Background | 107 | --bg: iro.props-get(--colors --gray3, null), // Background |
| @@ -183,18 +166,44 @@ $theme-lighter: ( | |||
| 183 | ), | 166 | ), |
| 184 | ), | 167 | ), |
| 185 | )); | 168 | )); |
| 169 | |||
| 170 | @include iro.props-store(( | ||
| 171 | --colors: ( | ||
| 172 | --gray1: hsl(210, 0%, 100%), // 1 | ||
| 173 | --gray2: hsl(210, 0%, 100%), // 1 | ||
| 174 | --gray3: hsl(210, 0%, 100%), // 1 | ||
| 175 | --gray4: hsl(210, 0%, 95%), // 1.11 | ||
| 176 | --gray5: hsl(210, 0%, 92%), // 1.19 | ||
| 177 | --gray6: hsl(210, 0%, 82%), // 1.52 | ||
| 178 | --gray7: hsl(210, 0%, 73%), // 1.94 | ||
| 179 | --gray8: hsl(210, 0%, 58%), // 3.03 | ||
| 180 | --gray9: hsl(210, 0%, 41%), // 5.48 | ||
| 181 | --gray10: hsl(210, 0%, 22%), // 11.72 | ||
| 182 | --gray11: hsl(210, 0%, 0%), // 21 | ||
| 183 | ) | ||
| 184 | ), 'light-raised'); | ||
| 186 | } | 185 | } |
| 187 | 186 | ||
| 188 | // | 187 | // |
| 189 | 188 | ||
| 190 | @include iro.fn-execute { | 189 | @include iro.fn-execute { |
| 191 | @include iro.props-store((), 'dark'); | 190 | @include iro.fn-execute { |
| 191 | @include iro.props-store(( | ||
| 192 | --colors: () | ||
| 193 | ), 'dark'); | ||
| 194 | } | ||
| 195 | |||
| 196 | @include iro.fn-execute { | ||
| 197 | @include iro.props-store(( | ||
| 198 | --colors: () | ||
| 199 | ), 'dark-raised'); | ||
| 200 | } | ||
| 192 | } | 201 | } |
| 193 | 202 | ||
| 194 | // | 203 | // |
| 195 | 204 | ||
| 196 | @each $breakpoint in map-keys($breakpoints) { | 205 | @each $breakpoint in map-keys(media.$breakpoints) { |
| 197 | @include media('<=#{$breakpoint}') { | 206 | @include media.media('<=#{$breakpoint}') { |
| 198 | @include iro.props-store(( | 207 | @include iro.props-store(( |
| 199 | --colors: () | 208 | --colors: () |
| 200 | ), $breakpoint); | 209 | ), $breakpoint); |
