diff options
Diffstat (limited to 'site/content/docs')
-rw-r--r-- | site/content/docs/5.2/components/alerts.md | 2 | ||||
-rw-r--r-- | site/content/docs/5.2/components/modal.md | 2 | ||||
-rw-r--r-- | site/content/docs/5.2/components/popovers.md | 10 | ||||
-rw-r--r-- | site/content/docs/5.2/components/toasts.md | 2 | ||||
-rw-r--r-- | site/content/docs/5.2/components/tooltips.md | 4 | ||||
-rw-r--r-- | site/content/docs/5.2/forms/checks-radios.md | 2 |
6 files changed, 11 insertions, 11 deletions
diff --git a/site/content/docs/5.2/components/alerts.md b/site/content/docs/5.2/components/alerts.md index 12cad35881..6962b7155f 100644 --- a/site/content/docs/5.2/components/alerts.md +++ b/site/content/docs/5.2/components/alerts.md @@ -27,7 +27,7 @@ Alerts are available for any length of text, as well as an optional close button Click the button below to show an alert (hidden with inline styles to start), then dismiss (and destroy) it with the built-in close button. -{{< example >}} +{{< example js_snippet="true" >}} <div id="liveAlertPlaceholder"></div> <button type="button" class="btn btn-primary" id="liveAlertBtn">Show live alert</button> {{< /example >}} diff --git a/site/content/docs/5.2/components/modal.md b/site/content/docs/5.2/components/modal.md index a2354eb855..4acfe4a751 100644 --- a/site/content/docs/5.2/components/modal.md +++ b/site/content/docs/5.2/components/modal.md @@ -444,7 +444,7 @@ Have a bunch of buttons that all trigger the same modal with slightly different Below is a live demo followed by example HTML and JavaScript. For more information, [read the modal events docs](#events) for details on `relatedTarget`. -{{< example >}} +{{< example js_snippet="true" >}} <button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#exampleModal" data-bs-whatever="@mdo">Open modal for @mdo</button> <button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#exampleModal" data-bs-whatever="@fat">Open modal for @fat</button> <button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#exampleModal" data-bs-whatever="@getbootstrap">Open modal for @getbootstrap</button> diff --git a/site/content/docs/5.2/components/popovers.md b/site/content/docs/5.2/components/popovers.md index b6d3b304df..a08850f94c 100644 --- a/site/content/docs/5.2/components/popovers.md +++ b/site/content/docs/5.2/components/popovers.md @@ -46,7 +46,7 @@ const popoverList = [...popoverTriggerList].map(popoverTriggerEl => new bootstra We use JavaScript similar to the snippet above to render the following live popover. Titles are set via `title` attribute and body content is set via `data-bs-content`. -{{< example >}} +{{< example js_snippet="true" >}} <button type="button" class="btn btn-lg btn-danger" data-bs-toggle="popover" title="Popover title" data-bs-content="And here's some amazing content. It's very engaging. Right?">Click to toggle popover</button> {{< /example >}} @@ -54,7 +54,7 @@ We use JavaScript similar to the snippet above to render the following live popo Four options are available: top, right, bottom, and left. Directions are mirrored when using Bootstrap in RTL. Set `data-bs-placement` to change the direction. -{{< example >}} +{{< example js_snippet="true" >}} <button type="button" class="btn btn-secondary" data-bs-container="body" data-bs-toggle="popover" data-bs-placement="top" data-bs-content="Top popover"> Popover on top </button> @@ -87,7 +87,7 @@ You can customize the appearance of popovers using [CSS variables](#variables). {{< scss-docs name="custom-popovers" file="site/assets/scss/_component-examples.scss" >}} -{{< example class="custom-popover-demo" >}} +{{< example class="custom-popover-demo" js_snippet="true" >}} <button type="button" class="btn btn-secondary" data-bs-toggle="popover" data-bs-placement="right" data-bs-custom-class="custom-popover" @@ -107,7 +107,7 @@ Use the `focus` trigger to dismiss popovers on the user's next click of a differ For proper cross-browser and cross-platform behavior, you must use the `<a>` tag, _not_ the `<button>` tag, and you also must include a [`tabindex`](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex) attribute. {{< /callout >}} -{{< example >}} +{{< example js_snippet="true" >}} <a tabindex="0" class="btn btn-lg btn-danger" role="button" data-bs-toggle="popover" data-bs-trigger="focus" title="Dismissible popover" data-bs-content="And here's some amazing content. It's very engaging. Right?">Dismissible popover</a> {{< /example >}} @@ -123,7 +123,7 @@ Elements with the `disabled` attribute aren't interactive, meaning users cannot For disabled popover triggers, you may also prefer `data-bs-trigger="hover focus"` so that the popover appears as immediate visual feedback to your users as they may not expect to _click_ on a disabled element. -{{< example >}} +{{< example js_snippet="true" >}} <span class="d-inline-block" tabindex="0" data-bs-toggle="popover" data-bs-trigger="hover focus" data-bs-content="Disabled popover"> <button class="btn btn-primary" type="button" disabled>Disabled button</button> </span> diff --git a/site/content/docs/5.2/components/toasts.md b/site/content/docs/5.2/components/toasts.md index 8c46d9a825..3cae1998b0 100644 --- a/site/content/docs/5.2/components/toasts.md +++ b/site/content/docs/5.2/components/toasts.md @@ -197,7 +197,7 @@ Building on the above example, you can create different toast color schemes with Place toasts with custom CSS as you need them. The top right is often used for notifications, as is the top middle. If you're only ever going to show one toast at a time, put the positioning styles right on the `.toast`. -{{< example >}} +{{< example js_snippet="true" >}} <form> <div class="mb-3"> <label for="selectToastPlacement">Toast placement</label> diff --git a/site/content/docs/5.2/components/tooltips.md b/site/content/docs/5.2/components/tooltips.md index 458301620a..ef5944b489 100644 --- a/site/content/docs/5.2/components/tooltips.md +++ b/site/content/docs/5.2/components/tooltips.md @@ -45,7 +45,7 @@ const tooltipList = [...tooltipTriggerList].map(tooltipTriggerEl => new bootstra Hover over the links below to see tooltips: -{{< example class="tooltip-demo" >}} +{{< example class="tooltip-demo" js_snippet="true" >}} <p class="muted">Placeholder text to demonstrate some <a href="#" data-bs-toggle="tooltip" title="Default tooltip">inline links</a> with tooltips. This is now just filler, no killer. Content placed here just to mimic the presence of <a href="#" data-bs-toggle="tooltip" title="Another tooltip">real text</a>. And all that just to give you an idea of how tooltips would look when used in real-world situations. So hopefully you've now seen how <a href="#" data-bs-toggle="tooltip" title="Another one here too">these tooltips on links</a> can work in practice, once you use them on <a href="#" data-bs-toggle="tooltip" title="The last tip!">your own</a> site or project. </p> {{< /example >}} @@ -59,7 +59,7 @@ You can customize the appearance of tooltips using [CSS variables](#variables). {{< scss-docs name="custom-tooltip" file="site/assets/scss/_component-examples.scss" >}} -{{< example class="tooltip-demo" >}} +{{< example class="tooltip-demo" js_snippet="true" >}} <button type="button" class="btn btn-secondary" data-bs-toggle="tooltip" data-bs-placement="top" data-bs-custom-class="custom-tooltip" diff --git a/site/content/docs/5.2/forms/checks-radios.md b/site/content/docs/5.2/forms/checks-radios.md index 812e7c198e..d719689d3b 100644 --- a/site/content/docs/5.2/forms/checks-radios.md +++ b/site/content/docs/5.2/forms/checks-radios.md @@ -36,7 +36,7 @@ Our checks use custom Bootstrap icons to indicate checked or indeterminate state Checkboxes can utilize the `:indeterminate` pseudo class when manually set via JavaScript (there is no available HTML attribute for specifying it). -{{< example class="bd-example-indeterminate">}} +{{< example class="bd-example-indeterminate" js_snippet="true" >}} <div class="form-check"> <input class="form-check-input" type="checkbox" value="" id="flexCheckIndeterminate"> <label class="form-check-label" for="flexCheckIndeterminate"> |