Adding the concept of a demo file to snippets.
This allows us to have demo files with more code and styling than the snippet, to make it look good without showing extraneous details to the user.master
parent
5950902c15
commit
93b91710b4
|
@ -3,7 +3,11 @@
|
||||||
<div class="snippet-demos">
|
<div class="snippet-demos">
|
||||||
<div class="snippet-demo"></div>
|
<div class="snippet-demo"></div>
|
||||||
{% for snippet in snippet_group %}
|
{% for snippet in snippet_group %}
|
||||||
|
{% if snippet.demo_file %}
|
||||||
|
{% set snippet_file = "../../src/" + component_name + "/snippets/" + snippet.demo_file %}
|
||||||
|
{% else %}
|
||||||
{% set snippet_file = "../../src/" + component_name + "/snippets/" + snippet.file %}
|
{% set snippet_file = "../../src/" + component_name + "/snippets/" + snippet.file %}
|
||||||
|
{% endif %}
|
||||||
<div class="snippet-demo">
|
<div class="snippet-demo">
|
||||||
<div class="snippet-demo-container">
|
<div class="snippet-demo-container">
|
||||||
{% include snippet_file ignore missing %}
|
{% include snippet_file ignore missing %}
|
||||||
|
|
Loading…
Reference in New Issue