mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2025-01-18 19:00:24 +00:00
rework expand documentation
This commit is contained in:
parent
86317356d6
commit
5f7cba3d97
2 changed files with 72 additions and 30 deletions
|
@ -4,7 +4,20 @@ description : "Displays an expandable/collapsible section of text on your page"
|
|||
---
|
||||
|
||||
The Expand shortcode displays an expandable/collapsible section of text on your page.
|
||||
Here is an example
|
||||
|
||||
## Usage
|
||||
|
||||
````
|
||||
{{%/*expand "Does this relearn theme rock?" */%}}
|
||||
Yes!
|
||||
{{%/* /expand*/%}}
|
||||
````
|
||||
|
||||
This shortcode takes one optional parameter to define the text that appears next to the expand/collapse icon. The default text is *"Expand me..."*.
|
||||
|
||||
## Examples
|
||||
|
||||
### Default text
|
||||
|
||||
{{%expand%}}
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
||||
|
@ -15,18 +28,8 @@ cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
|
|||
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
{{% /expand%}}
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
|
||||
this shortcode takes exactly one optional parameter to define the text that appears next to the expand/collapse icon. (default is "Expand me...")
|
||||
|
||||
{{%/*expand "Does this relearn theme rock?" */%}}Yes !.{{%/* /expand*/%}}
|
||||
|
||||
{{%expand "Does this relearn theme rock?" %}}Yes !{{% /expand%}}
|
||||
|
||||
# Demo
|
||||
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* expand */%}}
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
||||
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
|
@ -35,11 +38,50 @@ this shortcode takes exactly one optional parameter to define the text that appe
|
|||
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
|
||||
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
{{%/* /expand */%}}
|
||||
````
|
||||
{{% /expand%}}
|
||||
|
||||
### Arbitrary text
|
||||
|
||||
{{%expand "Show me endless possibilities" %}}
|
||||
Some expandable text.
|
||||
|
||||
You can add:
|
||||
|
||||
- multiple paragraphs
|
||||
- bullet point lists
|
||||
- *emphasized*, **bold** and even ***bold emphasized*** text
|
||||
- [links](https://example.com)
|
||||
- other shortcodes besides `expand`
|
||||
- etc.
|
||||
|
||||
```
|
||||
...and even source code
|
||||
```
|
||||
|
||||
> the possiblities are endless
|
||||
{{% /expand%}}
|
||||
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* expand "Show me endless possibilities" */%}}
|
||||
Some expandable text.
|
||||
|
||||
You can add:
|
||||
|
||||
- multiple paragraphs
|
||||
- bullet point lists
|
||||
- *emphasized*, **bold** and even ***bold emphasized*** text
|
||||
- [links](https://example.com)
|
||||
- other shortcodes besides `expand`
|
||||
- etc.
|
||||
|
||||
```
|
||||
...and even source code
|
||||
```
|
||||
|
||||
> the possiblities are endless
|
||||
{{%/* /expand */%}}
|
||||
````
|
||||
{{% /expand%}}
|
||||
|
||||
{{%expand%}}Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
||||
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
|
||||
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
|
||||
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
|
||||
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.{{% /expand%}}
|
|
@ -35,7 +35,7 @@ You can add:
|
|||
> the possiblities are endless
|
||||
{{% /notice %}}
|
||||
|
||||
{{% expand Code %}}
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* notice note */%}}
|
||||
A **notice** disclaimer
|
||||
|
@ -79,7 +79,7 @@ You can add:
|
|||
> the possiblities are endless
|
||||
{{% /notice %}}
|
||||
|
||||
{{% expand Code %}}
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* notice info */%}}
|
||||
An **information** disclaimer
|
||||
|
@ -123,7 +123,7 @@ You can add:
|
|||
> the possiblities are endless
|
||||
{{% /notice %}}
|
||||
|
||||
{{% expand Code %}}
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* notice tip */%}}
|
||||
A **tip** disclaimer
|
||||
|
@ -167,7 +167,7 @@ You can add:
|
|||
> the possiblities are endless
|
||||
{{% /notice %}}
|
||||
|
||||
{{% expand Code %}}
|
||||
{{% expand "Show markup" %}}
|
||||
````
|
||||
{{%/* notice warning */%}}
|
||||
A **warning** disclaimer
|
||||
|
|
Loading…
Reference in a new issue