aboutsummaryrefslogtreecommitdiff
path: root/docs/_includes/js
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2015-01-18 12:24:29 -0800
committerMark Otto <[email protected]>2015-01-18 12:24:29 -0800
commit1bf1ba7103cf4de0364dfd8ec78a31eb813d7b8f (patch)
tree7a63ae1a434fae8cb51835fafd1b531d5f5da64e /docs/_includes/js
parentdbe47654160d389c6991a312c9cecd2eeb9b6122 (diff)
parent22b79dae3c9307c329e6722ff1be8aa0a4143812 (diff)
downloadbootstrap-1bf1ba7103cf4de0364dfd8ec78a31eb813d7b8f.tar.xz
bootstrap-1bf1ba7103cf4de0364dfd8ec78a31eb813d7b8f.zip
Merge branch 'master' into pr/15278
Conflicts: dist/css/bootstrap.css.map dist/css/bootstrap.min.css docs/assets/js/customize.min.js docs/assets/js/raw-files.min.js docs/dist/css/bootstrap.css.map docs/dist/css/bootstrap.min.css
Diffstat (limited to 'docs/_includes/js')
-rw-r--r--docs/_includes/js/alerts.html9
-rw-r--r--docs/_includes/js/buttons.html4
-rw-r--r--docs/_includes/js/carousel.html4
-rw-r--r--docs/_includes/js/collapse.html2
-rw-r--r--docs/_includes/js/modal.html18
-rw-r--r--docs/_includes/js/overview.html6
-rw-r--r--docs/_includes/js/popovers.html9
-rw-r--r--docs/_includes/js/scrollspy.html2
-rw-r--r--docs/_includes/js/tabs.html2
-rw-r--r--docs/_includes/js/tooltips.html8
10 files changed, 35 insertions, 29 deletions
diff --git a/docs/_includes/js/alerts.html b/docs/_includes/js/alerts.html
index 8a207cc7f..399cd732f 100644
--- a/docs/_includes/js/alerts.html
+++ b/docs/_includes/js/alerts.html
@@ -4,14 +4,14 @@
<h2 id="alerts-examples">Example alerts</h2>
<p>Add dismiss functionality to all alert messages with this plugin.</p>
<p>When using a <code>.close</code> button, it must be the first child of the <code>.alert-dismissible</code> and no text content may come before it in the markup.</p>
- <div class="bs-example bs-example-standalone">
+ <div class="bs-example bs-example-standalone" data-example-id="dismissible-alert-js">
<div class="alert alert-warning alert-dismissible fade in" role="alert">
- <button type="button" class="close" data-dismiss="alert"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<strong>Holy guacamole!</strong> Best check yo self, you're not looking too good.
</div>
<div class="alert alert-danger alert-dismissible fade in" role="alert">
- <button type="button" class="close" data-dismiss="alert"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4>Oh snap! You got an error!</h4>
<p>Change this and that and try again. Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit. Cras mattis consectetur purus sit amet fermentum.</p>
<p>
@@ -27,9 +27,8 @@
<p>Just add <code>data-dismiss="alert"</code> to your close button to automatically give an alert close functionality. Closing an alert removes it from the DOM.</p>
{% highlight html %}
-<button type="button" class="close" data-dismiss="alert">
+<button type="button" class="close" data-dismiss="alert" aria-label="Close">
<span aria-hidden="true">&times;</span>
- <span class="sr-only">Close</span>
</button>
{% endhighlight %}
diff --git a/docs/_includes/js/buttons.html b/docs/_includes/js/buttons.html
index 44588b5b3..83bf0bfaa 100644
--- a/docs/_includes/js/buttons.html
+++ b/docs/_includes/js/buttons.html
@@ -60,7 +60,7 @@
<h4>Visual checked state only updated on click</h4>
<p>If the checked state of a checkbox button is updated without firing a <code>click</code> event on the button (e.g. via <code>&lt;input type="reset"&gt;</code> or via setting the <code>checked</code> property of the input), you will need to toggle the <code>.active</code> class on the input's <code>label</code> yourself.</p>
</div>
- <div class="bs-example">
+ <div class="bs-example" data-example-id="buttons-checkbox">
<div class="btn-group" data-toggle="buttons">
<label class="btn btn-primary active">
<input type="checkbox" checked autocomplete="off"> Checkbox 1 (pre-checked)
@@ -87,7 +87,7 @@
</div>
{% endhighlight %}
- <div class="bs-example">
+ <div class="bs-example" data-example-id="buttons-radio">
<div class="btn-group" data-toggle="buttons">
<label class="btn btn-primary active">
<input type="radio" name="options" id="option1" autocomplete="off" checked> Radio 1 (preselected)
diff --git a/docs/_includes/js/carousel.html b/docs/_includes/js/carousel.html
index abd2890b8..bf2fbecec 100644
--- a/docs/_includes/js/carousel.html
+++ b/docs/_includes/js/carousel.html
@@ -4,7 +4,7 @@
<p>A slideshow component for cycling through elements, like a carousel. <strong>Nested carousels are not supported.</strong></p>
<h2 id="carousel-examples">Examples</h2>
- <div class="bs-example">
+ <div class="bs-example" data-example-id="simple-carousel">
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
<ol class="carousel-indicators">
<li data-target="#carousel-example-generic" data-slide-to="0" class="active"></li>
@@ -87,7 +87,7 @@
<h3>Optional captions</h3>
<p>Add captions to your slides easily with the <code>.carousel-caption</code> element within any <code>.item</code>. Place just about any optional HTML within there and it will be automatically aligned and formatted.</p>
- <div class="bs-example">
+ <div class="bs-example" data-example-id="carousel-with-captions">
<div id="carousel-example-captions" class="carousel slide" data-ride="carousel">
<ol class="carousel-indicators">
<li data-target="#carousel-example-captions" data-slide-to="0" class="active"></li>
diff --git a/docs/_includes/js/collapse.html b/docs/_includes/js/collapse.html
index ec85cc922..ca84ac857 100644
--- a/docs/_includes/js/collapse.html
+++ b/docs/_includes/js/collapse.html
@@ -49,7 +49,7 @@
<h2 id="collapse-example-accordion">Accordion example</h2>
<p>Extend the default collapse behavior to create an accordion with the panel component.</p>
- <div class="bs-example">
+ <div class="bs-example" data-example-id="collapse-accordion">
<div class="panel-group" id="accordion" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="headingOne">
diff --git a/docs/_includes/js/modal.html b/docs/_includes/js/modal.html
index 6f7fa9cf9..f5861f4a5 100644
--- a/docs/_includes/js/modal.html
+++ b/docs/_includes/js/modal.html
@@ -26,12 +26,12 @@
<h3>Static example</h3>
<p>A rendered modal with header, body, and set of actions in the footer.</p>
- <div class="bs-example bs-example-modal">
+ <div class="bs-example bs-example-modal" data-example-id="static-modal">
<div class="modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title">Modal title</h4>
</div>
<div class="modal-body">
@@ -50,7 +50,7 @@
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title">Modal title</h4>
</div>
<div class="modal-body">
@@ -73,7 +73,7 @@
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="myModalLabel">Modal title</h4>
</div>
<div class="modal-body">
@@ -124,7 +124,7 @@
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="myModalLabel">Modal title</h4>
</div>
<div class="modal-body">
@@ -186,7 +186,7 @@
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="myLargeModalLabel">Large modal</h4>
</div>
<div class="modal-body">
@@ -200,7 +200,7 @@
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="mySmallModalLabel">Small modal</h4>
</div>
<div class="modal-body">
@@ -230,7 +230,7 @@
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="exampleModalLabel">New message</h4>
</div>
<div class="modal-body">
@@ -263,7 +263,7 @@
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
- <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="exampleModalLabel">New message</h4>
</div>
<div class="modal-body">
diff --git a/docs/_includes/js/overview.html b/docs/_includes/js/overview.html
index b95bb6c5f..89030966c 100644
--- a/docs/_includes/js/overview.html
+++ b/docs/_includes/js/overview.html
@@ -70,6 +70,12 @@ $('#myModal').on('show.bs.modal', function (e) {
})
{% endhighlight %}
+ <h3 id="js-version-nums">Version numbers</h3>
+ <p>The version of each of Bootstrap's jQuery plugins can be accessed via the <code>VERSION</code> property of the plugin's constructor. For example, for the tooltip plugin:</p>
+{% highlight js %}
+$.fn.tooltip.Constructor.VERSION // => "{{ site.current_version }}"
+{% endhighlight %}
+
<h3 id="js-disabled">No special fallbacks when JavaScript is disabled</h3>
<p>Bootstrap's plugins don't fall back particularly gracefully when JavaScript is disabled. If you care about the user experience in this case, use <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/noscript"><code>&lt;noscript&gt;</code></a> to explain the situation (and how to re-enable JavaScript) to your users, and/or add your own custom fallbacks.</p>
diff --git a/docs/_includes/js/popovers.html b/docs/_includes/js/popovers.html
index ab33baccb..56d8ce8b1 100644
--- a/docs/_includes/js/popovers.html
+++ b/docs/_includes/js/popovers.html
@@ -38,7 +38,7 @@ $(function () {
<h2 id="popovers-examples">Examples</h2>
<h3>Static popover</h3>
<p>Four options are available: top, right, bottom, and left aligned.</p>
- <div class="bs-example bs-example-popover">
+ <div class="bs-example bs-example-popover" data-example-id="static-popovers">
<div class="popover top">
<div class="arrow"></div>
<h3 class="popover-title">Popover top</h3>
@@ -252,20 +252,21 @@ sagittis lacus vel augue laoreet rutrum faucibus.">
<p>Initializes popovers for an element collection.</p>
<h4>.popover('show')</h4>
- <p>Reveals an element's popover. Popovers whose both title and content are zero-length are never displayed.</p>
+ <p>Reveals an element's popover. <strong>Returns to the caller before the popover has actually been shown</strong> (i.e. before the <code>shown.bs.popover</code> event occurs). This is considered a "manual" triggering of the popover. Popovers whose both title and content are zero-length are never displayed.</p>
{% highlight js %}$('#element').popover('show'){% endhighlight %}
<h4>.popover('hide')</h4>
- <p>Hides an element's popover.</p>
+ <p>Hides an element's popover. <strong>Returns to the caller before the popover has actually been hidden</strong> (i.e. before the <code>hidden.bs.popover</code> event occurs). This is considered a "manual" triggering of the popover.</p>
{% highlight js %}$('#element').popover('hide'){% endhighlight %}
<h4>.popover('toggle')</h4>
- <p>Toggles an element's popover.</p>
+ <p>Toggles an element's popover. <strong>Returns to the caller before the popover has actually been shown or hidden</strong> (i.e. before the <code>shown.bs.popover</code> or <code>hidden.bs.popover</code> event occurs). This is considered a "manual" triggering of the popover.</p>
{% highlight js %}$('#element').popover('toggle'){% endhighlight %}
<h4>.popover('destroy')</h4>
<p>Hides and destroys an element's popover.</p>
{% highlight js %}$('#element').popover('destroy'){% endhighlight %}
+
<h3 id="popovers-events">Events</h3>
<div class="table-responsive">
<table class="table table-bordered table-striped bs-events-table">
diff --git a/docs/_includes/js/scrollspy.html b/docs/_includes/js/scrollspy.html
index 2b42e8492..602373172 100644
--- a/docs/_includes/js/scrollspy.html
+++ b/docs/_includes/js/scrollspy.html
@@ -3,7 +3,7 @@
<h2 id="scrollspy-examples">Example in navbar</h2>
<p>The ScrollSpy plugin is for automatically updating nav targets based on scroll position. Scroll the area below the navbar and watch the active class change. The dropdown sub items will be highlighted as well.</p>
- <div class="bs-example">
+ <div class="bs-example" data-example-id="embedded-scrollspy">
<nav id="navbar-example2" class="navbar navbar-default navbar-static">
<div class="container-fluid">
<div class="navbar-header">
diff --git a/docs/_includes/js/tabs.html b/docs/_includes/js/tabs.html
index 90fda3537..ffb20345d 100644
--- a/docs/_includes/js/tabs.html
+++ b/docs/_includes/js/tabs.html
@@ -3,7 +3,7 @@
<h2 id="tabs-examples">Example tabs</h2>
<p>Add quick, dynamic tab functionality to transition through panes of local content, even via dropdown menus.</p>
- <div class="bs-example bs-example-tabs" role="tabpanel">
+ <div class="bs-example bs-example-tabs" role="tabpanel" data-example-id="togglable-tabs">
<ul id="myTab" class="nav nav-tabs" role="tablist">
<li role="presentation" class="active"><a href="#home" id="home-tab" role="tab" data-toggle="tab" aria-controls="home" aria-expanded="true">Home</a></li>
<li role="presentation"><a href="#profile" role="tab" id="profile-tab" data-toggle="tab" aria-controls="profile">Profile</a></li>
diff --git a/docs/_includes/js/tooltips.html b/docs/_includes/js/tooltips.html
index ae553e0df..90fa37208 100644
--- a/docs/_includes/js/tooltips.html
+++ b/docs/_includes/js/tooltips.html
@@ -11,7 +11,7 @@
<h3>Static tooltip</h3>
<p>Four options are available: top, right, bottom, and left aligned.</p>
- <div class="bs-example bs-example-tooltip">
+ <div class="bs-example bs-example-tooltip" data-example-id="static-tooltips">
<div class="tooltip left" role="tooltip">
<div class="tooltip-arrow"></div>
<div class="tooltip-inner">
@@ -213,15 +213,15 @@ $('#example').tooltip(options)
<p>Attaches a tooltip handler to an element collection.</p>
<h4>.tooltip('show')</h4>
- <p>Reveals an element's tooltip. Tooltips with zero-length titles are never displayed.</p>
+ <p>Reveals an element's tooltip. <strong>Returns to the caller before the tooltip has actually been shown</strong> (i.e. before the <code>shown.bs.tooltip</code> event occurs). This is considered a "manual" triggering of the tooltip. Tooltips with zero-length titles are never displayed.</p>
{% highlight js %}$('#element').tooltip('show'){% endhighlight %}
<h4>.tooltip('hide')</h4>
- <p>Hides an element's tooltip.</p>
+ <p>Hides an element's tooltip. <strong>Returns to the caller before the tooltip has actually been hidden</strong> (i.e. before the <code>hidden.bs.tooltip</code> event occurs). This is considered a "manual" triggering of the tooltip.</p>
{% highlight js %}$('#element').tooltip('hide'){% endhighlight %}
<h4>.tooltip('toggle')</h4>
- <p>Toggles an element's tooltip.</p>
+ <p>Toggles an element's tooltip. <strong>Returns to the caller before the tooltip has actually been shown or hidden</strong> (i.e. before the <code>shown.bs.tooltip</code> or <code>hidden.bs.tooltip</code> event occurs). This is considered a "manual" triggering of the tooltip.</p>
{% highlight js %}$('#element').tooltip('toggle'){% endhighlight %}
<h4>.tooltip('destroy')</h4>