Skip to content

Commit

Permalink
refactor(blockquote): fix responsive margins and sizes rems
Browse files Browse the repository at this point in the history
  • Loading branch information
tarantilis committed Feb 18, 2022
1 parent 7a24d9c commit 209f94f
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 16 deletions.
31 changes: 27 additions & 4 deletions theme/themes/eea/extras/blockquote.less
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,47 @@
*******************************/

.eea.blockquote {
border-left: @blockquoteBorderLeft;
border-left: @mobileBlockquoteBorderLeft;

.quote {
display: flex;
flex-direction: column;
margin: @quoteMargin;
margin: @mobileQuoteMargin;
gap: @quoteGap;
color: @quoteColor;
font-size: @quoteFontSize;
font-size: @mobileQuoteFontSize;
font-weight: @quoteFontWeight;

.meta {
margin: @metaMargin;
font-size: @metaFontSize;
font-size: @mobileMetaFontSize;
font-weight: @metaWeight;
align-self: @metaAlignSelf;
}
}
}

@media only screen and (min-width: @tabletBreakpoint) {
.eea.blockquote {
border-left: @tabletBlockquoteBorderLeft;
.quote {
margin: @tabletQuoteMargin;
font-size: @tabletQuoteFontSize;
.meta {
font-size: @tabletMetaFontSize;
}
}
}
}

@media only screen and (min-width: @computerBreakpoint) {
.eea.blockquote .quote {
margin: @computerQuoteMargin;
font-size: @computerQuoteFontSize;
.meta {
font-size: @computerMetaFontSize;
}
}
}

.loadUIOverrides();
31 changes: 19 additions & 12 deletions theme/themes/eea/extras/blockquote.variables
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,26 @@
Blockquote
*******************************/
/* Body */
@blockquoteBorderLeft : 10px solid @secondaryColor;
@childrenBorderLeft : none;
@mobileBlockquoteBorderLeft : @5px solid @secondaryColor;
@tabletBlockquoteBorderLeft : @10px solid @secondaryColor;
@childrenBorderLeft : none;

/* Quote */
@quoteColor : @secondaryColor;
@quoteMargin : @relative12px @relative30px;
@quoteGap : @relative12px;
@quoteColor : @japaneseIndigo;
@quoteFontSize : @h5;
@quoteFontWeight : 700;
@quoteColor : @secondaryColor;
@mobileQuoteMargin : 0.75rem 0.625rem;
@tabletQuoteMargin : 0.75rem 1rem;
@computerQuoteMargin : 0.75rem 1.25rem;
@quoteGap : 0.75rem;
@quoteColor : @japaneseIndigo;
@mobileQuoteFontSize : 0.688rem;
@tabletQuoteFontSize : @h6;
@computerQuoteFontSize : @h5;
@quoteFontWeight : 700;

/* Meta */
@metaMargin : 0;
@metaWeight : 400;
@metaFontSize : @h5;
@metaAlignSelf : start;
@metaMargin : 0;
@metaWeight : 400;
@mobileMetaFontSize : 0.688rem;
@tabletMetaFontSize : @h6;
@computerMetaFontSize : @h5;
@metaAlignSelf : start;

0 comments on commit 209f94f

Please sign in to comment.