Swap around if/else logic around titles in templates

This commit is contained in:
Jeff Posnick 2015-07-20 13:16:35 -04:00
Родитель 4baa7c2266
Коммит 2a98b2d195
3 изменённых файлов: 33 добавлений и 27 удалений

Просмотреть файл

@ -1,11 +1,13 @@
{% if include.css %}
<style>{{ include.css }}</style>
{% if include.title != "" %}
<h3>{{ include.title }}</h3>
{% elsif include.title == null %}
<h3>CSS Snippet</h3>
{% endif %}
{% highlight css %}
{{ include.css }}
{% endhighlight %}
<style>{{ include.css }}</style>
{% if include.title == null %}
<h3>CSS Snippet</h3>
{% elsif include.title != "" %}
<h3>{{ include.title }}</h3>
{% endif %}
{% highlight css %}
{{ include.css }}
{% endhighlight %}
{% endif %}

Просмотреть файл

@ -1,11 +1,13 @@
{% if include.html %}
{{ include.html }}
{% if include.title != "" %}
<h3>{{ include.title }}</h3>
{% elsif include.title == null %}
<h3>HTML Snippet</h3>
{% endif %}
{% highlight html %}
{{ include.html }}
{% endhighlight %}
{{ include.html }}
{% if include.title == null %}
<h3>HTML Snippet</h3>
{% elsif include.title != "" %}
<h3>{{ include.title }}</h3>
{% endif %}
{% highlight html %}
{{ include.html }}
{% endhighlight %}
{% endif %}

Просмотреть файл

@ -1,11 +1,13 @@
{% if include.js %}
<script>{{ include.js }}</script>
{% if include.title != "" %}
<h3>{{ include.title }}</h3>
{% elsif include.title == null %}
<h3>JavaScript Snippet</h3>
{% endif %}
{% highlight js %}
{{ include.js }}
{% endhighlight %}
<script>{{ include.js }}</script>
{% if include.title == null %}
<h3>JavaScript Snippet</h3>
{% elsif include.title != "" %}
<h3>{{ include.title }}</h3>
{% endif %}
{% highlight js %}
{{ include.js }}
{% endhighlight %}
{% endif %}