diff options
author | olOwOlo <26087907+olOwOlo@users.noreply.github.com> | 2018-02-01 21:35:04 +0800 |
---|---|---|
committer | olOwOlo <26087907+olOwOlo@users.noreply.github.com> | 2018-02-01 21:35:04 +0800 |
commit | df28365582e7b95666729a975924496124801732 (patch) | |
tree | 81fa947d843a292de27fb9610e1ae78e5a745898 /exampleSite/content | |
parent | 57c8a3adeaa00a603bb9059cdef0349bb61c1df1 (diff) |
docs: update README
Diffstat (limited to 'exampleSite/content')
-rw-r--r-- | exampleSite/content/post/shortcodes.md | 146 |
1 files changed, 146 insertions, 0 deletions
diff --git a/exampleSite/content/post/shortcodes.md b/exampleSite/content/post/shortcodes.md new file mode 100644 index 0000000..bdd742d --- /dev/null +++ b/exampleSite/content/post/shortcodes.md @@ -0,0 +1,146 @@ +--- +title: "Shortcodes" +date: 2016-08-30T16:01:23+08:00 +lastmod: 2018-02-01T18:01:23+08:00 +draft: false +tags: ["shortcodes"] +categories: ["shortcodes"] + +# You can also close(false) or open(true) something for this content. +# P.S. comment can only be closed +# comment: false +# toc: false +# autoCollapseToc: false +# postMetaInFooter: false +# You can also define another contentCopyright. e.g. contentCopyright: "This is another copyright." +# contentCopyright: false +# reward: false +# mathjax: false +--- + +# center, right, left + +``` +## default +![img](/path/to/img.gif "img") + +{{%/* center */%}} +## center +![img](/path/to/img.gif "img") +{{%/* /center */%}} + +{{%/* right */%}} +## right +![img](/path/to/img.gif "img") +{{%/* /right */%}} + +{{%/* left */%}} +## left +![img](/path/to/img.gif "img") +{{%/* /left */%}} +``` +<!--more--> + +## default +![img](https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg "img") + +{{% center %}} +## center +![img](https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg "img") +{{% /center %}} + +{{% right %}} +## right +![img](https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg "img") +{{% /right %}} + +{{% left %}} +## left +![img](https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg "img") +{{% /left %}} + +--- + +## figure with class + +``` +{{%/* figure src="/path/to/img.gif" title="default" alt="img" */%}} +{{%/* figure class="center" src="/path/to/img.gif" title="center" alt="img" */%}} +{{%/* figure class="right" src="/path/to/img.gif" title="right" alt="img" */%}} +{{%/* figure class="left" src="/path/to/img.gif" title="left" alt="img" */%}} +``` + +{{% figure src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="default" alt="img" %}} +{{% figure class="center" src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="center" alt="img" %}} +{{% figure class="right" src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="right" alt="img" %}} +{{% figure class="left" src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="left" alt="img" %}} + +--- + +``` +{{%/* center */%}} + +## hybrid in center +{{%/* figure src="/path/to/img.gif" title="default" alt="img" */%}} +{{%/* figure class="right" src="/path/to/img.gif" title="right" alt="img" */%}} + +{{%/* left */%}} +{{%/* figure src="/path/to/img.gif" title="default in left" alt="img" */%}} +{{%/* /left */%}} + +{{%/* /center */%}} +``` + +{{% center %}} +## hybrid in center +{{% figure src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="default" alt="img" %}} +{{% figure class="right" src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="right" alt="img" %}} +{{% left %}} +{{% figure src="https://wx1.sinaimg.cn/small/006SToa6ly1fm07summ2gj30qo0qomzu.jpg" title="default in left" alt="img" %}} +{{% /left %}} +{{% /center %}} + +--- + +# Music 163 + +## Params +- `id` + - required param + - you can extract from music url + - url format http://music.163.com/#/song?id=28196554 + +- Fiddle `auto` + - optional param + - default value 0 + - you can overwrite it with 1 + +## Examples + +- Simple + +``` +{{%/* music "28196554" */%}} +{{%/* music "28196554" "1" */%}} +``` + +- Named Params + +``` +{{%/* music id="28196554" */%}} +{{%/* music id="28196554" auto="1" */%}} +``` + +- Example + +``` +{{%/* music "28196554" */%}} +``` + +{{% music "28196554" %}} + +<style> +.post-content img { + height: 64px; +} +</style> |