diff options
| author | m5o <[email protected]> | 2018-03-14 16:44:38 +0100 |
|---|---|---|
| committer | XhmikosR <[email protected]> | 2018-03-14 17:44:38 +0200 |
| commit | d01b4eb02560ba67b61b1b2c0496e9f8281c154d (patch) | |
| tree | 9c32c81f44be15d729fc8351360921aa1b42e572 /docs/4.0/components/collapse.md | |
| parent | 03b7f52e820c80e244479c59c0920c541ee1277b (diff) | |
| download | bootstrap-d01b4eb02560ba67b61b1b2c0496e9f8281c154d.tar.xz bootstrap-d01b4eb02560ba67b61b1b2c0496e9f8281c154d.zip | |
Remove custom example plugin. (#25784)
Diffstat (limited to 'docs/4.0/components/collapse.md')
| -rw-r--r-- | docs/4.0/components/collapse.md | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/docs/4.0/components/collapse.md b/docs/4.0/components/collapse.md index d4894da77..86462492b 100644 --- a/docs/4.0/components/collapse.md +++ b/docs/4.0/components/collapse.md @@ -16,7 +16,7 @@ Click the buttons below to show and hide another element via class changes: You can use a link with the `href` attribute, or a button with the `data-target` attribute. In both cases, the `data-toggle="collapse"` is required. -{% example html %} +{% capture example %} <p> <a class="btn btn-primary" data-toggle="collapse" href="#collapseExample" role="button" aria-expanded="false" aria-controls="collapseExample"> Link with href @@ -30,14 +30,15 @@ You can use a link with the `href` attribute, or a button with the `data-target` Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. </div> </div> -{% endexample %} +{% endcapture %} +{% include example.html content=example %} ## Multiple targets A `<button>` or `<a>` can show and hide multiple elements by referencing them with a JQuery selector in its `href` or `data-target` attribute. Multiple `<button>` or `<a>` can show and hide an element if they each reference it with their `href` or `data-target` attribute -{% example html %} +{% capture example %} <p> <a class="btn btn-primary" data-toggle="collapse" href="#multiCollapseExample1" role="button" aria-expanded="false" aria-controls="multiCollapseExample1">Toggle first element</a> <button class="btn btn-primary" type="button" data-toggle="collapse" data-target="#multiCollapseExample2" aria-expanded="false" aria-controls="multiCollapseExample2">Toggle second element</button> @@ -59,13 +60,14 @@ Multiple `<button>` or `<a>` can show and hide an element if they each reference </div> </div> </div> -{% endexample %} +{% endcapture %} +{% include example.html content=example %} ## Accordion example Using the [card]({{ site.baseurl }}/docs/{{ site.docs_version }}/components/card/) component, you can extend the default collapse behavior to create an accordion. -{% example html %} +{% capture example %} <div class="accordion" id="accordion"> <div class="card"> <div class="card-header" id="headingOne"> @@ -111,7 +113,8 @@ Using the [card]({{ site.baseurl }}/docs/{{ site.docs_version }}/components/card </div> </div> </div> -{% endexample %} +{% endcapture %} +{% include example.html content=example %} ## Accessibility |
