summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2024-10-20 17:37:56 +0200
committerVolpeon <git@volpeon.ink>2024-10-20 17:37:56 +0200
commita6b944d7ed813a20d7042926fce38542a4df9e54 (patch)
treeb1c99adc8ca2ee6648b186f17635358a591225a1
parentUpdate (diff)
downloadiro-design-a6b944d7ed813a20d7042926fce38542a4df9e54.tar.gz
iro-design-a6b944d7ed813a20d7042926fce38542a4df9e54.tar.bz2
iro-design-a6b944d7ed813a20d7042926fce38542a4df9e54.zip
Use flex for card
-rw-r--r--src/objects/_card.scss14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/objects/_card.scss b/src/objects/_card.scss
index abc691b..2eb16bc 100644
--- a/src/objects/_card.scss
+++ b/src/objects/_card.scss
@@ -11,7 +11,8 @@
11 @include materialize-at-root(meta.module-variables('vars')); 11 @include materialize-at-root(meta.module-variables('vars'));
12 12
13 @include iro.bem-object('card') { 13 @include iro.bem-object('card') {
14 display: block; 14 display: flex;
15 flex-direction: column;
15 margin: calc(-1 * props.get(vars.$key-focus--border-width)); 16 margin: calc(-1 * props.get(vars.$key-focus--border-width));
16 background-color: props.get(vars.$bg-color); 17 background-color: props.get(vars.$bg-color);
17 background-clip: content-box; 18 background-clip: content-box;
@@ -43,10 +44,11 @@
43 } 44 }
44 45
45 @include iro.bem-elem('image') { 46 @include iro.bem-elem('image') {
46 display: block; 47 display: block;
47 inline-size: 100%; 48 flex: 0 0 auto;
48 object-fit: cover; 49 inline-size: 100%;
49 transition: transform .2s, opacity .2s; 50 object-fit: cover;
51 transition: transform .2s, opacity .2s;
50 52
51 &:first-child { 53 &:first-child {
52 border-start-start-radius: props.get(vars.$rounding); 54 border-start-start-radius: props.get(vars.$rounding);
@@ -64,6 +66,7 @@
64 } 66 }
65 67
66 @include iro.bem-elem('body') { 68 @include iro.bem-elem('body') {
69 flex: 1 0 auto;
67 padding-block: props.get(vars.$pad-b); 70 padding-block: props.get(vars.$pad-b);
68 padding-inline: props.get(vars.$pad-i); 71 padding-inline: props.get(vars.$pad-i);
69 72
@@ -79,6 +82,7 @@
79 } 82 }
80 83
81 @include iro.bem-elem('footer') { 84 @include iro.bem-elem('footer') {
85 flex: 0 0 auto;
82 padding-block: 0 props.get(vars.$pad-b); 86 padding-block: 0 props.get(vars.$pad-b);
83 padding-inline: props.get(vars.$pad-i); 87 padding-inline: props.get(vars.$pad-i);
84 margin-block-start: calc(-1 * props.get(vars.$pad-b)); 88 margin-block-start: calc(-1 * props.get(vars.$pad-b));