Skip to content
This repository has been archived by the owner on Dec 9, 2024. It is now read-only.

Commit

Permalink
correct fallback & add mobile card targeting
Browse files Browse the repository at this point in the history
  • Loading branch information
B77Mills committed Aug 26, 2024
1 parent 75b61b0 commit afeb7ac
Showing 1 changed file with 31 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,23 @@
.section-feed-content-node {
$self: &;

$image-size: 112px;
$image-width: $image-size;
$image-height: $image-size;
@function ab($a, $b: null) {
@if $b != null {
@return $b;
}
@return $a;
}

$image-size: 112px ;
$image-mobile-width: null !default;
$image-mobile-height: null !default;
$image-width: ab($image-size, $image-mobile-width);
$image-height: ab($image-size, $image-mobile-height);

$image-desktop-width: 250px;
$image-desktop-height: 167px;


display: flex;
width: 100%;

Expand Down Expand Up @@ -222,4 +232,22 @@
}
}
}
//@todo this should also be dependend on the image width/height differing from 112
@include media-breakpoint-down(sm) {
&--section-feed-mobile-cards {
.section-feed-content-node {
&:first-child {
border-top: none;
}
flex-direction: column-reverse;
.section-feed-content-node__image-wrapper {
margin-left: 0;
margin-bottom: map-get($spacers, block);
}
.section-feed-content-node__content-teaser {
display: initial;
}
}
}
}
}

0 comments on commit afeb7ac

Please sign in to comment.