diff options
author | Volpeon <git@volpeon.ink> | 2024-06-28 14:22:27 +0200 |
---|---|---|
committer | Volpeon <git@volpeon.ink> | 2024-06-28 14:22:27 +0200 |
commit | f98a5c58c830a283d07d8efad4502281a5e0369e (patch) | |
tree | 84c4abdd260e595c7b314d79ae7af58bd406bf67 /tpl/objects | |
parent | Add card (diff) | |
download | iro-design-f98a5c58c830a283d07d8efad4502281a5e0369e.tar.gz iro-design-f98a5c58c830a283d07d8efad4502281a5e0369e.tar.bz2 iro-design-f98a5c58c830a283d07d8efad4502281a5e0369e.zip |
Update
Diffstat (limited to 'tpl/objects')
-rw-r--r-- | tpl/objects/button.pug | 2 | ||||
-rw-r--r-- | tpl/objects/card.pug | 11 |
2 files changed, 9 insertions, 4 deletions
diff --git a/tpl/objects/button.pug b/tpl/objects/button.pug index b5fb8da..1fa3347 100644 --- a/tpl/objects/button.pug +++ b/tpl/objects/button.pug | |||
@@ -5,7 +5,7 @@ mixin a-button | |||
5 | 'o-button--block': attributes.block, | 5 | 'o-button--block': attributes.block, |
6 | 'o-button--primary': attributes.primary, | 6 | 'o-button--primary': attributes.primary, |
7 | 'o-button--outline': attributes.outline, | 7 | 'o-button--outline': attributes.outline, |
8 | 'o-button--round': !!attributes.icon | 8 | 'o-button--round': !!attributes.icon && !block |
9 | } | 9 | } |
10 | if (attributes.variant) { | 10 | if (attributes.variant) { |
11 | classes['o-button--' + attributes.variant] = true | 11 | classes['o-button--' + attributes.variant] = true |
diff --git a/tpl/objects/card.pug b/tpl/objects/card.pug index d61393d..d7595d1 100644 --- a/tpl/objects/card.pug +++ b/tpl/objects/card.pug | |||
@@ -1,7 +1,12 @@ | |||
1 | mixin card | 1 | mixin card |
2 | - | 2 | - |
3 | let classes = { | 3 | let classes = { |
4 | 'o-card': true, | 4 | 'o-card': true, |
5 | 'o-card--quiet': !!attributes.quiet, | ||
6 | } | ||
7 | |||
8 | if (attributes.class) { | ||
9 | classes[attributes.class] = true; | ||
5 | } | 10 | } |
6 | 11 | ||
7 | if attributes.href | 12 | if attributes.href |
@@ -13,10 +18,10 @@ mixin card | |||
13 | 18 | ||
14 | mixin card-image | 19 | mixin card-image |
15 | .o-card__image | 20 | .o-card__image |
16 | img.o-card__image-img(src=attributes.src) | 21 | img.o-card__image-img(src=attributes.src style=attributes.style) |
17 | 22 | ||
18 | mixin card-body | 23 | mixin card-body |
19 | .o-card__body | 24 | .o-card__body(style=attributes.style) |
20 | block | 25 | block |
21 | 26 | ||
22 | mixin card-title | 27 | mixin card-title |