Skip to content

Commit

Permalink
GH-83: Fix Callout Component after Plugin's tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
wesleyboar committed Aug 21, 2021
1 parent 4494919 commit c76aedc
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ Callout
Interrupt or end Sections with a "call to action".
Markup:
<aside class="c-callout">
<!-- Has Figure -->
<aside class="c-callout c-callout--has-figure">
<h2 class="c-callout__title">
Quick Start Guide
</h2>
Expand All @@ -13,6 +14,15 @@ Markup:
</p>
<figure class="c-callout__figure">...</figure>
</aside>
<!-- No Figure -->
<aside class="c-callout">
<h2 class="c-callout__title">
Quick Start Guide
</h2>
<p class="c-callout__desc">
Explore the Frontera User Guide to learn how to get started, see what Frontera offers, and get answers to your questions.
</p>
</aside>
Styleguide Components.Callout
*/
Expand All @@ -29,12 +39,12 @@ Styleguide Components.Callout

padding: 20px;
}
.c-callout--has-children {
.c-callout--has-figure {
grid-template-areas:
'figure title'
'figure desc';
}
.c-callout:not(.c-callout--has-children) {
.c-callout:not(.c-callout--has-figure) {
grid-template-areas:
'title'
'desc';
Expand All @@ -45,11 +55,11 @@ Styleguide Components.Callout

/* To hide figure on narrow window */
@media only screen and (--narrow-and-below) {
.c-callout--has-children .c-callout { column-gap: 0px; }
.c-callout--has-children .c-callout__figure { display: none; }
.c-callout--has-figure { column-gap: 0px; }
.c-callout--has-figure .c-callout__figure { display: none; }
}
@media only screen and (--narrow-and-above) {
.c-callout--has-children .c-callout { column-gap: 40px; }
.c-callout--has-figure { column-gap: 40px; }
}

/* To align image to exact center */
Expand Down
2 changes: 1 addition & 1 deletion taccsite_cms/templates/snippets/c-callout.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<aside class="c-callout">
<aside class="c-callout c-callout--has-figure">
<h2 class="c-callout__title">Quick Start Guide</h2>
<p class="c-callout__desc">Explore the Frontera User Guide to learn how to get started, see what Frontera offers, and get answers to your questions.</p>
<figure class="c-callout__figure" style="width: 310px; height: 135px; background-color: white;"></figure>
Expand Down

0 comments on commit c76aedc

Please sign in to comment.