Left-aligned table headers

This commit is contained in:
Tetsuro
2015-07-25 17:09:54 -04:00
parent a3ceafbcd0
commit 7f550c8bce
24 changed files with 23 additions and 25 deletions
+1 -1
View File
@@ -5,7 +5,7 @@ title: capitalize
`capitalize` ensures the first character of your string is capitalized. `capitalize` ensures the first character of your string is capitalized.
| Input | Output | | Input | Output |
|-----------------------------------------------------------:|:-----------------| |:-----------------------------------------------------------|:-----------------|
| {% raw %}`{{ "title" | capitalize }}` {% endraw %} | "Title" | | {% raw %}`{{ "title" | capitalize }}` {% endraw %} | "Title" |
| {% raw %}`{{ "my great title" | capitalize }}`{% endraw %} | "My great title" | | {% raw %}`{{ "my great title" | capitalize }}`{% endraw %} | "My great title" |
+1 -1
View File
@@ -6,7 +6,7 @@ layout: default
`ceil` rounds the input up to the nearest whole number. `ceil` rounds the input up to the nearest whole number.
| Input | Output | | Input | Output |
|-------------------------------------------:|:-------| |:-------------------------------------------|:-------|
| {% raw %}`{{ 1.2 | ceil }}` {% endraw %} | 2 | | {% raw %}`{{ 1.2 | ceil }}` {% endraw %} | 2 |
| {% raw %}`{{ 1.7 | ceil }}` {% endraw %} | 2 | | {% raw %}`{{ 1.7 | ceil }}` {% endraw %} | 2 |
| {% raw %}`{{ 2.0 | ceil }}` {% endraw %} | 2 | | {% raw %}`{{ 2.0 | ceil }}` {% endraw %} | 2 |
+1 -1
View File
@@ -5,7 +5,7 @@ title: date
`date` converts a timestamp into another date format. `date` converts a timestamp into another date format.
| Input | Output | | Input | Output |
|--------------------------------------------------------------------------:|:---------------------| |:--------------------------------------------------------------------------|:---------------------|
| {% raw %}`{{ article.published_at | date: "%a, %b %d, %y" }}`{% endraw %} | Tue, Apr 22, 14 | | {% raw %}`{{ article.published_at | date: "%a, %b %d, %y" }}`{% endraw %} | Tue, Apr 22, 14 |
| {% raw %}`{{ article.published_at | date: "%Y" }}`{% endraw %} | 2014 | | {% raw %}`{{ article.published_at | date: "%Y" }}`{% endraw %} | 2014 |
+1 -1
View File
@@ -5,7 +5,7 @@ title: divided_by
This filter divides its input by its parameter. This filter divides its input by its parameter.
| Code | Output | | Code | Output |
|--------------------------------------------------:|:-------| |:--------------------------------------------------|:-------|
| {% raw %}`{{ 4 | divided_by: 2 }}` {% endraw %} | 2 | | {% raw %}`{{ 4 | divided_by: 2 }}` {% endraw %} | 2 |
| {% raw %}`{{ "16" | divided_by: 4 }}`{% endraw %} | 4 | | {% raw %}`{{ "16" | divided_by: 4 }}`{% endraw %} | 4 |
+1 -1
View File
@@ -5,7 +5,7 @@ title: downcase
This filter makes the entire input string the lower case version of each character within. This filter makes the entire input string the lower case version of each character within.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-----------------| |:-------------------------------------------------------|:-----------------|
| {% raw %}`{{ "Peter Parker" | downcase }}`{% endraw %} | `"peter parker"` | | {% raw %}`{{ "Peter Parker" | downcase }}`{% endraw %} | `"peter parker"` |
It doesn't modify strings which are already entirely lowercase. It works with anything that has a `#to_s` method. It doesn't modify strings which are already entirely lowercase. It works with anything that has a `#to_s` method.
+1 -1
View File
@@ -5,7 +5,7 @@ title: escape
Escapes a string by replacing characters with escape sequences (so that the string can be used in a URI). Escapes a string by replacing characters with escape sequences (so that the string can be used in a URI).
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ "Need tips? Ask a friend!" | escape }}`{% endraw %} | `"Need%20tips%3F%Ask%20a%20friend%21"` | | {% raw %}`{{ "Need tips? Ask a friend!" | escape }}`{% endraw %} | `"Need%20tips%3F%Ask%20a%20friend%21"` |
| {% raw %}`{{ "Nope" | escape }}`{% endraw %} | `"Nope"` | | {% raw %}`{{ "Nope" | escape }}`{% endraw %} | `"Nope"` |
+1 -1
View File
@@ -5,7 +5,7 @@ title: escape_once
Escapes a string without affecting existing escaped entities. Escapes a string without affecting existing escaped entities.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ "1 < 2 & 3" | escape_once }}`{% endraw %} | `"1 < 2 & 3"` | | {% raw %}`{{ "1 < 2 & 3" | escape_once }}`{% endraw %} | `"1 < 2 & 3"` |
| {% raw %}`{{ "<< Accept & Checkout" | escape_once }}`{% endraw %} | `"<< Accept & Checkout"` | | {% raw %}`{{ "<< Accept & Checkout" | escape_once }}`{% endraw %} | `"<< Accept & Checkout"` |
| {% raw %}`{{ "Nope" | escape_once }}`{% endraw %} | `"Nope"` | | {% raw %}`{{ "Nope" | escape_once }}`{% endraw %} | `"Nope"` |
+1 -1
View File
@@ -5,7 +5,7 @@ title: first
Return the first element of an array. Return the first element of an array.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ product.tags | first }}`{% endraw %} | `"sale"` | | {% raw %}`{{ product.tags | first }}`{% endraw %} | `"sale"` |
In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`. In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`.
+1 -1
View File
@@ -5,7 +5,7 @@ title: floor
`floor` rounds the input down to the nearest whole number. `floor` rounds the input down to the nearest whole number.
| Input | Output | | Input | Output |
|-------------------------------------------:|:-------| |:-------------------------------------------|:-------|
| {% raw %}`{{ 1.2 | floor }}` {% endraw %} | 1 | | {% raw %}`{{ 1.2 | floor }}` {% endraw %} | 1 |
| {% raw %}`{{ 1.7 | floor }}` {% endraw %} | 1 | | {% raw %}`{{ 1.7 | floor }}` {% endraw %} | 1 |
| {% raw %}`{{ 2.0 | floor }}` {% endraw %} | 2 | | {% raw %}`{{ 2.0 | floor }}` {% endraw %} | 2 |
+1 -1
View File
@@ -5,7 +5,7 @@ title: join
`join` joins the elements of an array, using the character you provide. `join` joins the elements of an array, using the character you provide.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ product.tags | join: ', ' }}`{% endraw %} | `"sale, mens, womens, awesome` | | {% raw %}`{{ product.tags | join: ', ' }}`{% endraw %} | `"sale, mens, womens, awesome` |
In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`. In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`.
+1 -1
View File
@@ -5,7 +5,7 @@ title: last
Return the last element of an array. Return the last element of an array.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ product.tags | last }}`{% endraw %} | `"awesome"` | | {% raw %}`{{ product.tags | last }}`{% endraw %} | `"awesome"` |
In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`. In the sample above, assume that `product.tags` resolves to: `["sale", "mens", "womens", "awesome"]`.
+1 -1
View File
@@ -5,5 +5,5 @@ title: lstrip
Strips all whitespace (tabs, spaces, and newlines) from the left side of a string. Strips all whitespace (tabs, spaces, and newlines) from the left side of a string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ ' too many spaces ' | lstrip }}`{% endraw %} | `"too many spaces "` | | {% raw %}`{{ ' too many spaces ' | lstrip }}`{% endraw %} | `"too many spaces "` |
+1 -1
View File
@@ -5,7 +5,7 @@ title: map
Collects an array of properties from a hash. Collects an array of properties from a hash.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ product | map: 'tag' }}`{% endraw %} | `["sale", "mens", "womens", "awesome"]` | | {% raw %}`{{ product | map: 'tag' }}`{% endraw %} | `["sale", "mens", "womens", "awesome"]` |
In the sample above, assume that `product` resolves to: `[{ tags: "sale"}, { tags: "mens"}, { tags: "womens"}, { tags: "awesome"}]`. In the sample above, assume that `product` resolves to: `[{ tags: "sale"}, { tags: "mens"}, { tags: "womens"}, { tags: "awesome"}]`.
+1 -1
View File
@@ -5,5 +5,5 @@ title: minus
Subtracts two numbers. Subtracts two numbers.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 100 | minus: 10 }}`{% endraw %} | `90` | | {% raw %}`{{ 100 | minus: 10 }}`{% endraw %} | `90` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: modulo
Performs a modulo operation (eg., fetches the remainder). Performs a modulo operation (eg., fetches the remainder).
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 2 | modulo: 2 }}`{% endraw %} | `1` | | {% raw %}`{{ 2 | modulo: 2 }}`{% endraw %} | `1` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: newline_to_br
Replace every newline (`n`) with an HTML break (`<br>`). Replace every newline (`n`) with an HTML break (`<br>`).
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ "hello\nthere" | newline_to_br }}`{% endraw %} | `hello<br/>there` | | {% raw %}`{{ "hello\nthere" | newline_to_br }}`{% endraw %} | `hello<br/>there` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: plus
Adds two numbers. Adds two numbers.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 100 | plus: 10 }}`{% endraw %} | `110` | | {% raw %}`{{ 100 | plus: 10 }}`{% endraw %} | `110` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: prepend
Prepends a string onto another. Prepends a string onto another.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 'world' | prepend: 'hello ' }}`{% endraw %} | `hello world` | | {% raw %}`{{ 'world' | prepend: 'hello ' }}`{% endraw %} | `hello world` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: remove
Removes every occurrence of a given string. Removes every occurrence of a given string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 'hello, hello world' | remove: 'hello' }}`{% endraw %} | `, world` | | {% raw %}`{{ 'hello, hello world' | remove: 'hello' }}`{% endraw %} | `, world` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: remove_first
Removes the first occurrence of a given string. Removes the first occurrence of a given string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 'hello, hello world' | remove_first: 'hello' }}`{% endraw %} | `, hello world` | | {% raw %}`{{ 'hello, hello world' | remove_first: 'hello' }}`{% endraw %} | `, hello world` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: replace_first
Replaces the first occurrence of a given string. Replaces the first occurrence of a given string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ 'hello, hello world' | replace_first: 'hello', 'goodbye' }}`{% endraw %} | `goodbye, hello world` | | {% raw %}`{{ 'hello, hello world' | replace_first: 'hello', 'goodbye' }}`{% endraw %} | `goodbye, hello world` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: rstrip
Strips all whitespace (tabs, spaces, and newlines) from the right side of a string. Strips all whitespace (tabs, spaces, and newlines) from the right side of a string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ ' too many spaces ' | rstrip }}`{% endraw %} | `"too many spaces "` | | {% raw %}`{{ ' too many spaces ' | rstrip }}`{% endraw %} | `"too many spaces "` |
+1 -1
View File
@@ -5,5 +5,5 @@ title: strip
Strips all whitespace (tabs, spaces, and newlines) from a string. Strips all whitespace (tabs, spaces, and newlines) from a string.
| Code | Output | | Code | Output |
|-------------------------------------------------------:|:-------------------| |:-------------------------------------------------------|:-------------------|
| {% raw %}`{{ ' too many spaces ' | strip }}`{% endraw %} | `"too many spaces"` | | {% raw %}`{{ ' too many spaces ' | strip }}`{% endraw %} | `"too many spaces"` |
-2
View File
@@ -45,8 +45,6 @@
<div class="content"> <div class="content">
{{ content }} {{ content }}
</div> </div>
<a href="{{ page.previous }}">Previous </a>
<a href="{{ page.next }}">Next </a>
</div> </div>
</div> </div>