diff options
author | olOwOlo <26087907+olOwOlo@users.noreply.github.com> | 2018-02-01 21:28:11 +0800 |
---|---|---|
committer | olOwOlo <26087907+olOwOlo@users.noreply.github.com> | 2018-02-01 21:28:11 +0800 |
commit | 5a5d0fe0d9d144af434f8d6277a7bdc85eda2db4 (patch) | |
tree | 9980c868cd63502797e7cc7e5fd1dd6961942344 | |
parent | a6e116452f8d3f0e043107a1e0d047256514457b (diff) |
feat: add `center`, `right`, `left` shortcodes
-rw-r--r-- | layouts/shortcodes/center.html | 3 | ||||
-rw-r--r-- | layouts/shortcodes/left.html | 3 | ||||
-rw-r--r-- | layouts/shortcodes/right.html | 3 | ||||
-rw-r--r-- | src/css/_partial/_post/_content.scss | 12 |
4 files changed, 21 insertions, 0 deletions
diff --git a/layouts/shortcodes/center.html b/layouts/shortcodes/center.html new file mode 100644 index 0000000..e9022d0 --- /dev/null +++ b/layouts/shortcodes/center.html @@ -0,0 +1,3 @@ +<div class='align-center'> + {{ .Inner }} +</div>
\ No newline at end of file diff --git a/layouts/shortcodes/left.html b/layouts/shortcodes/left.html new file mode 100644 index 0000000..c2c5102 --- /dev/null +++ b/layouts/shortcodes/left.html @@ -0,0 +1,3 @@ +<div class='align-left'> + {{ .Inner }} +</div>
\ No newline at end of file diff --git a/layouts/shortcodes/right.html b/layouts/shortcodes/right.html new file mode 100644 index 0000000..37a9a33 --- /dev/null +++ b/layouts/shortcodes/right.html @@ -0,0 +1,3 @@ +<div class='align-right'> + {{ .Inner }} +</div>
\ No newline at end of file diff --git a/src/css/_partial/_post/_content.scss b/src/css/_partial/_post/_content.scss index 8bcf700..ddc809e 100644 --- a/src/css/_partial/_post/_content.scss +++ b/src/css/_partial/_post/_content.scss @@ -115,4 +115,16 @@ list-style: none; padding-left: 1.5rem; } + + .align-center { + text-align: center; + } + + .align-right { + text-align: right; + } + + .align-left { + text-align: left; + } } |