diff --git a/_layouts/default.html b/_layouts/default.html index 62d066c..0be6b65 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -75,6 +75,7 @@
+

{{ page.title }}

{{ content }}
diff --git a/_sass/modules/_base.scss b/_sass/modules/_base.scss index 81fcdee..a2569c0 100644 --- a/_sass/modules/_base.scss +++ b/_sass/modules/_base.scss @@ -82,22 +82,22 @@ a { } h1 { - font-size: 2.5em; -} - -h2 { font-size: 2em; } -h3 { +h2 { font-size: 1.5em; } -h4 { - font-size: 1.5em; +h3 { + font-size: 1em; text-decoration: underline; } +h4 { + font-size: 1em; +} + blockquote { color: lighten($color-slate, 30%); border-left: 2px solid lighten($color-slate, 50%); diff --git a/_sass/modules/_content-area.scss b/_sass/modules/_content-area.scss index 3344bba..7edc6a1 100644 --- a/_sass/modules/_content-area.scss +++ b/_sass/modules/_content-area.scss @@ -7,8 +7,14 @@ } .content__list { + + h1 { + font-weight: bold; + } + h2 { font-weight: bold; + text-decoration: underline; &:not(:first-child) { margin-top: $spacing-unit * 2; diff --git a/docs/tags/control-flow/case-when.md b/docs/tags/control-flow/case-when.md new file mode 100644 index 0000000..ddc67c8 --- /dev/null +++ b/docs/tags/control-flow/case-when.md @@ -0,0 +1,32 @@ +--- +category: control-flow +--- + + +## case/when + +

Creates a switch statement to compare a variable with different values. case initializes the switch statement, and when compares its values.

+ +

Input

+ +
+{% highlight html %}{% raw %} +{% assign handle = 'cake' %} +{% case handle %} + {% when 'cake' %} + This is a cake + {% when 'cookie' %} + This is a cookie + {% else %} + This is not a cake nor a cookie +{% endcase %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +This is a cake +{% endraw %}{% endhighlight %} +
diff --git a/docs/tags/control-flow/elsif-else.md b/docs/tags/control-flow/elsif-else.md new file mode 100644 index 0000000..e08623d --- /dev/null +++ b/docs/tags/control-flow/elsif-else.md @@ -0,0 +1,26 @@ +## elsif / else + +

Adds more conditions within an if or unless block.

+ +

Input

+ +
+{% highlight html %}{% raw %} + + {% if customer.name == 'kevin' %} + Hey Kevin! + {% elsif customer.name == 'anonymous' %} + Hey Anonymous! + {% else %} + Hi Stranger! + {% endif %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +Hey Anonymous! +{% endraw %}{% endhighlight %} +
diff --git a/docs/tags/control-flow/if.md b/docs/tags/control-flow/if.md new file mode 100644 index 0000000..f41b842 --- /dev/null +++ b/docs/tags/control-flow/if.md @@ -0,0 +1,21 @@ +## if + +

Executes a block of code only if a certain condition is met.

+ +

Input

+ +
+{% highlight html %}{% raw %} +{% if product.title == 'Awesome Shoes' %} + These shoes are awesome! +{% endif %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +These shoes are awesome! +{% endraw %}{% endhighlight %} +
diff --git a/_docs/tags/control-flow/index.html b/docs/tags/control-flow/index.html similarity index 91% rename from _docs/tags/control-flow/index.html rename to docs/tags/control-flow/index.html index 7fca750..9d08db0 100644 --- a/_docs/tags/control-flow/index.html +++ b/docs/tags/control-flow/index.html @@ -2,8 +2,7 @@ layout: default --- -CONTROL FLOW HERE - sss +TAGS! {% for doc in site.collections["tags"].docs %}
diff --git a/docs/tags/control-flow/unless.md b/docs/tags/control-flow/unless.md new file mode 100644 index 0000000..3733404 --- /dev/null +++ b/docs/tags/control-flow/unless.md @@ -0,0 +1,31 @@ +## unless + +

Similar to if, but executes a block of code only if a certain condition is not met.

+ +

Input

+ +
+{% highlight html %}{% raw %} + {% unless product.title == 'Awesome Shoes' %} + These shoes are not awesome. + {% endunless %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +These shoes are not awesome. +{% endraw %}{% endhighlight %} +
+ +This would be the equivalent of doing the following: + +
+{% highlight html %}{% raw %} + {% if product.title != 'Awesome Shoes' %} + These shoes are not awesome. + {% endif %} +{% endraw %}{% endhighlight %} +
diff --git a/docs/tags/index.html b/docs/tags/index.html new file mode 100644 index 0000000..f0cf854 --- /dev/null +++ b/docs/tags/index.html @@ -0,0 +1,11 @@ +--- +layout: default +--- + +sss + +{{ site.collections["tags"] }} + +{% for doc in site.collections["tags"].docs %} + +{% endfor %} diff --git a/tags/control-flow/case-when.md b/tags/control-flow/case-when.md new file mode 100644 index 0000000..ddc67c8 --- /dev/null +++ b/tags/control-flow/case-when.md @@ -0,0 +1,32 @@ +--- +category: control-flow +--- + + +## case/when + +

Creates a switch statement to compare a variable with different values. case initializes the switch statement, and when compares its values.

+ +

Input

+ +
+{% highlight html %}{% raw %} +{% assign handle = 'cake' %} +{% case handle %} + {% when 'cake' %} + This is a cake + {% when 'cookie' %} + This is a cookie + {% else %} + This is not a cake nor a cookie +{% endcase %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +This is a cake +{% endraw %}{% endhighlight %} +
diff --git a/tags/control-flow/elsif-else.md b/tags/control-flow/elsif-else.md new file mode 100644 index 0000000..e08623d --- /dev/null +++ b/tags/control-flow/elsif-else.md @@ -0,0 +1,26 @@ +## elsif / else + +

Adds more conditions within an if or unless block.

+ +

Input

+ +
+{% highlight html %}{% raw %} + + {% if customer.name == 'kevin' %} + Hey Kevin! + {% elsif customer.name == 'anonymous' %} + Hey Anonymous! + {% else %} + Hi Stranger! + {% endif %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +Hey Anonymous! +{% endraw %}{% endhighlight %} +
diff --git a/tags/control-flow/if.md b/tags/control-flow/if.md new file mode 100644 index 0000000..f41b842 --- /dev/null +++ b/tags/control-flow/if.md @@ -0,0 +1,21 @@ +## if + +

Executes a block of code only if a certain condition is met.

+ +

Input

+ +
+{% highlight html %}{% raw %} +{% if product.title == 'Awesome Shoes' %} + These shoes are awesome! +{% endif %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +These shoes are awesome! +{% endraw %}{% endhighlight %} +
diff --git a/tags/control-flow/index.html b/tags/control-flow/index.html new file mode 100644 index 0000000..9d08db0 --- /dev/null +++ b/tags/control-flow/index.html @@ -0,0 +1,14 @@ +--- +layout: default +--- + +TAGS! + +{% for doc in site.collections["tags"].docs %} +
+

{{ doc.title }}

+
+ {{ doc.content }} +
+
+{% endfor %} diff --git a/tags/control-flow/unless.md b/tags/control-flow/unless.md new file mode 100644 index 0000000..3733404 --- /dev/null +++ b/tags/control-flow/unless.md @@ -0,0 +1,31 @@ +## unless + +

Similar to if, but executes a block of code only if a certain condition is not met.

+ +

Input

+ +
+{% highlight html %}{% raw %} + {% unless product.title == 'Awesome Shoes' %} + These shoes are not awesome. + {% endunless %} +{% endraw %}{% endhighlight %} +
+ +

Output

+ +
+{% highlight html %}{% raw %} +These shoes are not awesome. +{% endraw %}{% endhighlight %} +
+ +This would be the equivalent of doing the following: + +
+{% highlight html %}{% raw %} + {% if product.title != 'Awesome Shoes' %} + These shoes are not awesome. + {% endif %} +{% endraw %}{% endhighlight %} +