Last active
January 21, 2019 20:21
-
-
Save wesruv/367dd52a8377ff31a31ee2a724ff43a4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
layout: _includes/layout-basic.njk | |
title: Collapsible Box | |
tags: | |
- component | |
- component_medium | |
contentTitle: Collapsible Box | |
content: <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate veli esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p> | |
--- | |
{% macro collapsibleBox(contentTitle, content) %} | |
<details class="collapsible-box"> | |
<summary class="collapsible-box__title"> | |
{{ contentTitle }} | |
</summary> | |
<div class="collapsible-box__content-wrapper"> | |
{{ content | safe }} | |
</div> | |
</details> | |
{% endmacro %} | |
{{ collapsibleBox(contentTitle, content) }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
layout: _includes/layout-basic.njk | |
title: FAQ | |
tags: | |
- section | |
contentTitle: Frequently Asked Questions | |
--- | |
{% include "component/collapsible-box.njk" as collapsibleBox %} | |
<section class="faq"> | |
<h2 class="faq__title"> | |
{{ contentTitle }} | |
</h2> | |
{{ collapsibleBox.( | |
'This is my question?', | |
'This is my answer!' | |
) }} | |
</section> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment