diff options
author | Volpeon <git@volpeon.ink> | 2024-10-25 19:19:52 +0200 |
---|---|---|
committer | Volpeon <git@volpeon.ink> | 2024-10-25 19:19:52 +0200 |
commit | 5f45b25eb0a677138081b5fb72394a395934cc84 (patch) | |
tree | 9b4445392c74e9753cffe089d56e2f7029f46e28 /src | |
parent | Add emoji licenses (diff) | |
download | iro-sass-5f45b25eb0a677138081b5fb72394a395934cc84.tar.gz iro-sass-5f45b25eb0a677138081b5fb72394a395934cc84.tar.bz2 iro-sass-5f45b25eb0a677138081b5fb72394a395934cc84.zip |
Use list for prop metadata
Diffstat (limited to 'src')
-rw-r--r-- | src/_props.scss | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/_props.scss b/src/_props.scss index b0b02c3..42f866e 100644 --- a/src/_props.scss +++ b/src/_props.scss | |||
@@ -15,7 +15,7 @@ | |||
15 | @return true; | 15 | @return true; |
16 | } | 16 | } |
17 | 17 | ||
18 | @function def($name, $value: (), $metadata: null) { | 18 | @function def($name, $value: (), $metadata: ()) { |
19 | @return ('prop-ref' $name $value $metadata); | 19 | @return ('prop-ref' $name $value $metadata); |
20 | } | 20 | } |
21 | 21 | ||
@@ -92,13 +92,13 @@ | |||
92 | } | 92 | } |
93 | } | 93 | } |
94 | 94 | ||
95 | @mixin materialize($ref, $match-meta: nil) { | 95 | @mixin materialize($ref, $match-meta: null) { |
96 | @if is-prop-ref($ref) { | 96 | @if is-prop-ref($ref) { |
97 | $name: list.nth($ref, 2); | 97 | $name: list.nth($ref, 2); |
98 | $value: get(list.nth($ref, 3)); | 98 | $value: get(list.nth($ref, 3)); |
99 | $meta: get(list.nth($ref, 4)); | 99 | $meta: get(list.nth($ref, 4)); |
100 | 100 | ||
101 | @if $match-meta == nil or $meta == $match-meta { | 101 | @if $match-meta == null or list.index($meta, $match-meta) != null { |
102 | @include materialize-helper($name, $value); | 102 | @include materialize-helper($name, $value); |
103 | } | 103 | } |
104 | } @else if meta.type-of($ref) == 'list' { | 104 | } @else if meta.type-of($ref) == 'list' { |
@@ -108,7 +108,7 @@ | |||
108 | $value: get(list.nth($r, 3)); | 108 | $value: get(list.nth($r, 3)); |
109 | $meta: get(list.nth($r, 4)); | 109 | $meta: get(list.nth($r, 4)); |
110 | 110 | ||
111 | @if $match-meta == nil or $meta == $match-meta { | 111 | @if $match-meta == null or list.index($meta, $match-meta) != null { |
112 | @include materialize-helper($name, $value); | 112 | @include materialize-helper($name, $value); |
113 | } | 113 | } |
114 | } | 114 | } |