aboutsummaryrefslogtreecommitdiff
path: root/docs/_includes
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2014-04-08 20:51:56 -0700
committerMark Otto <[email protected]>2014-04-08 20:51:56 -0700
commit11a835f56662f8a93e2f8d27038c683d901a5a72 (patch)
treee731f33d712272472b82c7c6b5de660735a78217 /docs/_includes
parentb57396944a39b21571848728b6ad479cd50537cd (diff)
parent9863344e9a7ef47379c8308baa5647a07d332799 (diff)
downloadbootstrap-11a835f56662f8a93e2f8d27038c683d901a5a72.tar.xz
bootstrap-11a835f56662f8a93e2f8d27038c683d901a5a72.zip
Merge branch 'master' into equal-height-experiment
Diffstat (limited to 'docs/_includes')
-rw-r--r--docs/_includes/components/glyphicons.html4
-rw-r--r--docs/_includes/components/navbar.html12
-rw-r--r--docs/_includes/css/tables.html2
-rw-r--r--docs/_includes/css/type.html4
-rw-r--r--docs/_includes/getting-started/browser-device-support.html12
-rw-r--r--docs/_includes/getting-started/download.html6
-rw-r--r--docs/_includes/header.html2
-rw-r--r--docs/_includes/js/alerts.html2
-rw-r--r--docs/_includes/js/buttons.html24
-rw-r--r--docs/_includes/js/carousel.html8
-rw-r--r--docs/_includes/js/dropdowns.html12
-rw-r--r--docs/_includes/js/popovers.html5
-rw-r--r--docs/_includes/js/scrollspy.html2
-rw-r--r--docs/_includes/js/tabs.html2
-rw-r--r--docs/_includes/nav/main.html4
15 files changed, 65 insertions, 36 deletions
diff --git a/docs/_includes/components/glyphicons.html b/docs/_includes/components/glyphicons.html
index 6900e0dfa..0f932f45c 100644
--- a/docs/_includes/components/glyphicons.html
+++ b/docs/_includes/components/glyphicons.html
@@ -21,6 +21,10 @@
<h4>Don't mix with other components</h4>
<p>Icon classes cannot be directly combined with other components. They should not be used along with other classes on the same element. Instead, add a nested <code>&lt;span&gt;</code> and apply the icon classes to the <code>&lt;span&gt;</code>.</p>
</div>
+ <div class="bs-callout bs-callout-danger">
+ <h4>Only for use on empty elements</h4>
+ <p>Icon classes should only be used on elements that contain no text content and have no child elements.</p>
+ </div>
{% highlight html %}
<span class="glyphicon glyphicon-search"></span>
{% endhighlight %}
diff --git a/docs/_includes/components/navbar.html b/docs/_includes/components/navbar.html
index ab78e5853..02f4fbcfa 100644
--- a/docs/_includes/components/navbar.html
+++ b/docs/_includes/components/navbar.html
@@ -17,6 +17,10 @@
<h4>Requires JavaScript</h4>
<p>If JavaScript is disabled and the viewport is narrow enough that the navbar collapses, it will be impossible to expand the navbar and view the content within the <code>.navbar-collapse</code>.</p>
</div>
+ <div class="bs-callout bs-callout-info">
+ <h4>Changing the collapsed mobile navbar breakpoint</h4>
+ <p>The navbar collapses into its vertical mobile view when the viewport is narrower than <code>@grid-float-breakpoint</code>, and expands into its horizontal non-mobile view when the viewport is at least <code>@grid-float-breakpoint</code> in width. Adjust this variable in the Less source to control when the navbar collapses/expands. The default value is <code>768px</code> (the smallest "small" or "tablet" screen).</p>
+ </div>
<div class="bs-example">
<nav class="navbar navbar-default" role="navigation">
@@ -38,7 +42,7 @@
<li class="active"><a href="#">Link</a></li>
<li><a href="#">Link</a></li>
<li class="dropdown">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
@@ -59,7 +63,7 @@
<ul class="nav navbar-nav navbar-right">
<li><a href="#">Link</a></li>
<li class="dropdown">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
@@ -93,7 +97,7 @@
<li class="active"><a href="#">Link</a></li>
<li><a href="#">Link</a></li>
<li class="dropdown">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
@@ -114,7 +118,7 @@
<ul class="nav navbar-nav navbar-right">
<li><a href="#">Link</a></li>
<li class="dropdown">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
diff --git a/docs/_includes/css/tables.html b/docs/_includes/css/tables.html
index 99db2af72..affe17ffa 100644
--- a/docs/_includes/css/tables.html
+++ b/docs/_includes/css/tables.html
@@ -348,7 +348,7 @@
<h2 id="tables-responsive">Responsive tables</h2>
- <p>Create responsive tables by wrapping any <code>.table</code> in <code>.table-responsive</code> to make them scroll horizontally up to small devices (under 768px). When viewing on anything larger than 768px wide, you will not see any difference in these tables.</p>
+ <p>Create responsive tables by wrapping any <code>.table</code> in <code>.table-responsive</code> to make them scroll horizontally on small devices (under 768px). When viewing on anything larger than 768px wide, you will not see any difference in these tables.</p>
<div class="bs-example">
<div class="table-responsive">
<table class="table">
diff --git a/docs/_includes/css/type.html b/docs/_includes/css/type.html
index 2ea046519..da81d7414 100644
--- a/docs/_includes/css/type.html
+++ b/docs/_includes/css/type.html
@@ -146,10 +146,10 @@ You can use the mark tag to <mark>highlight</mark> text.
<h3>Underlined text</h3>
<p>To underline text use the <code>&lt;u&gt;</code> tag.</p>
<div class="bs-example">
- <p><u>This line of text is will render as underlined</u></p>
+ <p><u>This line of text will render as underlined</u></p>
</div>
{% highlight html %}
-<u>This line of text is will render as underlined</u>
+<u>This line of text will render as underlined</u>
{% endhighlight %}
<p>Make use of HTML's default emphasis tags with lightweight styles.</p>
diff --git a/docs/_includes/getting-started/browser-device-support.html b/docs/_includes/getting-started/browser-device-support.html
index 3e1dd3e66..183bb7668 100644
--- a/docs/_includes/getting-started/browser-device-support.html
+++ b/docs/_includes/getting-started/browser-device-support.html
@@ -176,11 +176,13 @@ if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
<p>On <code>&lt;select&gt;</code> elements, the Android stock browser will not display the side controls if there is a <code>border-radius</code> and/or <code>border</code> applied. Use the snippet of code below to remove the offending CSS and render the <code>&lt;select&gt;</code> as an unstyled element on the Android stock browser. The user agent sniffing avoids interference with Chrome, Safari, and Mozilla browsers.</p>
{% highlight html %}
<script>
-var nua = navigator.userAgent
-var isAndroid = (nua.indexOf('Mozilla/5.0') > -1 && nua.indexOf('Android ') > -1 && nua.indexOf('AppleWebKit') > -1 && nua.indexOf('Chrome') === -1)
-if (isAndroid) {
- $('select.form-control').removeClass('form-control').css('width', '100%')
-}
+$(function () {
+ var nua = navigator.userAgent
+ var isAndroid = (nua.indexOf('Mozilla/5.0') > -1 && nua.indexOf('Android ') > -1 && nua.indexOf('AppleWebKit') > -1 && nua.indexOf('Chrome') === -1)
+ if (isAndroid) {
+ $('select.form-control').removeClass('form-control').css('width', '100%')
+ }
+})
</script>
{% endhighlight %}
<p>Want to see an example? <a href="http://jsbin.com/OyaqoDO/2">Check out this JS Bin demo.</a></p>
diff --git a/docs/_includes/getting-started/download.html b/docs/_includes/getting-started/download.html
index e3adffd8b..c89c8b9e4 100644
--- a/docs/_includes/getting-started/download.html
+++ b/docs/_includes/getting-started/download.html
@@ -8,21 +8,21 @@
<h3 id="download-bootstrap">Bootstrap</h3>
<p>Compiled and minified CSS, JavaScript, and fonts. No docs or original source files are included.</p>
<p>
- <a href="{{ site.download.dist }}" class="btn btn-lg btn-outline" role="button" onclick="_gaq.push(['_trackEvent', 'Getting started', 'Download', 'Download compiled']);">Download Bootstrap</a>
+ <a href="{{ site.download.dist }}" class="btn btn-lg btn-outline" role="button" onclick="ga('send', 'event', 'Getting started', 'Download', 'Download compiled');">Download Bootstrap</a>
</p>
</div>
<div class="col-sm-4">
<h3 id="download-source">Source code</h3>
<p>Source Less, JavaScript, and font files, along with our docs. <strong>Requires a Less compiler and <a href="{{ site.repo }}#compiling-css-and-javascript">some setup.</a></strong></p>
<p>
- <a href="{{ site.download.source }}" class="btn btn-lg btn-outline" role="button" onclick="_gaq.push(['_trackEvent', 'Getting started', 'Download', 'Download source']);">Download source</a>
+ <a href="{{ site.download.source }}" class="btn btn-lg btn-outline" role="button" onclick="ga('send', 'event', 'Getting started', 'Download', 'Download source');">Download source</a>
</p>
</div>
<div class="col-sm-4">
<h3 id="download-sass">Sass</h3>
<p><a href="{{ site.sass_repo }}">Bootstrap ported from Less to Sass</a> for easy inclusion in Rails, Compass, or Sass-only projects.</p>
<p>
- <a href="{{ site.download.sass }}" class="btn btn-lg btn-outline" role="button" onclick="_gaq.push(['_trackEvent', 'Getting started', 'Download', 'Download Sass']);">Download Sass</a>
+ <a href="{{ site.download.sass }}" class="btn btn-lg btn-outline" role="button" onclick="ga('send', 'event', 'Getting started', 'Download', 'Download Sass');">Download Sass</a>
</p>
</div>
</div>
diff --git a/docs/_includes/header.html b/docs/_includes/header.html
index 212981ed6..37f7a7597 100644
--- a/docs/_includes/header.html
+++ b/docs/_includes/header.html
@@ -35,6 +35,8 @@
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
ga('create', 'UA-146052-10', 'getbootstrap.com');
ga('send', 'pageview');
+
</script>
diff --git a/docs/_includes/js/alerts.html b/docs/_includes/js/alerts.html
index 04bbd43cf..de2ae9b84 100644
--- a/docs/_includes/js/alerts.html
+++ b/docs/_includes/js/alerts.html
@@ -64,7 +64,7 @@
</table>
</div><!-- /.table-responsive -->
{% highlight js %}
-$('#my-alert').bind('closed.bs.alert', function () {
+$('#my-alert').on('closed.bs.alert', function () {
// do something…
})
{% endhighlight %}
diff --git a/docs/_includes/js/buttons.html b/docs/_includes/js/buttons.html
index 5af374228..154320e48 100644
--- a/docs/_includes/js/buttons.html
+++ b/docs/_includes/js/buttons.html
@@ -37,10 +37,14 @@
<h4>Checkbox</h4>
<p>Add <code>data-toggle="buttons"</code> to a group of checkboxes for checkbox style toggling on btn-group.</p>
+ <div class="bs-callout bs-callout-warning">
+ <h4>Pre-checked options need <code>.active</code></h4>
+ <p>For pre-checked options, you must add the <code>.active</code> class to the input's <code>label</code> yourself.</p>
+ </div>
<div class="bs-example" style="padding-bottom: 24px;">
<div class="btn-group" data-toggle="buttons">
- <label class="btn btn-primary">
- <input type="checkbox"> Option 1
+ <label class="btn btn-primary active">
+ <input type="checkbox" checked> Option 1 (pre-checked)
</label>
<label class="btn btn-primary">
<input type="checkbox"> Option 2
@@ -52,8 +56,8 @@
</div><!-- /example -->
{% highlight html %}
<div class="btn-group" data-toggle="buttons">
- <label class="btn btn-primary">
- <input type="checkbox"> Option 1
+ <label class="btn btn-primary active">
+ <input type="checkbox" checked> Option 1 (pre-checked)
</label>
<label class="btn btn-primary">
<input type="checkbox"> Option 2
@@ -66,10 +70,14 @@
<h4>Radio</h4>
<p>Add <code>data-toggle="buttons"</code> to a group of radio inputs for radio style toggling on btn-group.</p>
+ <div class="bs-callout bs-callout-warning">
+ <h4>Preselected options need <code>.active</code></h4>
+ <p>For preselected options, you must add the <code>.active</code> class to the input's <code>label</code> yourself.</p>
+ </div>
<div class="bs-example" style="padding-bottom: 24px;">
<div class="btn-group" data-toggle="buttons">
- <label class="btn btn-primary">
- <input type="radio" name="options" id="option1"> Option 1
+ <label class="btn btn-primary active">
+ <input type="radio" name="options" id="option1" checked> Option 1 (preselected)
</label>
<label class="btn btn-primary">
<input type="radio" name="options" id="option2"> Option 2
@@ -81,8 +89,8 @@
</div><!-- /example -->
{% highlight html %}
<div class="btn-group" data-toggle="buttons">
- <label class="btn btn-primary">
- <input type="radio" name="options" id="option1"> Option 1
+ <label class="btn btn-primary active">
+ <input type="radio" name="options" id="option1" checked> Option 1 (preselected)
</label>
<label class="btn btn-primary">
<input type="radio" name="options" id="option2"> Option 2
diff --git a/docs/_includes/js/carousel.html b/docs/_includes/js/carousel.html
index 945910c75..b0665dba8 100644
--- a/docs/_includes/js/carousel.html
+++ b/docs/_includes/js/carousel.html
@@ -46,6 +46,12 @@
...
</div>
</div>
+ <div class="item">
+ <img src="..." alt="...">
+ <div class="carousel-caption">
+ ...
+ </div>
+ </div>
...
</div>
@@ -105,7 +111,7 @@
</div>
</div><!-- /example -->
{% highlight html %}
-<div class="item active">
+<div class="item">
<img src="..." alt="...">
<div class="carousel-caption">
<h3>...</h3>
diff --git a/docs/_includes/js/dropdowns.html b/docs/_includes/js/dropdowns.html
index 6b8c26ed5..27b06fe95 100644
--- a/docs/_includes/js/dropdowns.html
+++ b/docs/_includes/js/dropdowns.html
@@ -20,7 +20,7 @@
<div class="collapse navbar-collapse bs-example-js-navbar-collapse">
<ul class="nav navbar-nav">
<li class="dropdown">
- <a id="drop1" href="#" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a id="drop1" href="#" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu" aria-labelledby="drop1">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
@@ -30,7 +30,7 @@
</ul>
</li>
<li class="dropdown">
- <a href="#" id="drop2" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown 2 <b class="caret"></b></a>
+ <a href="#" id="drop2" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown 2 <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu" aria-labelledby="drop2">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
@@ -42,7 +42,7 @@
</ul>
<ul class="nav navbar-nav navbar-right">
<li id="fat-menu" class="dropdown">
- <a href="#" id="drop3" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown 3 <b class="caret"></b></a>
+ <a href="#" id="drop3" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown 3 <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu" aria-labelledby="drop3">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
@@ -62,7 +62,7 @@
<ul class="nav nav-pills">
<li class="active"><a href="#">Regular link</a></li>
<li class="dropdown">
- <a id="drop4" role="button" data-toggle="dropdown" href="#">Dropdown <b class="caret"></b></a>
+ <a id="drop4" role="button" data-toggle="dropdown" href="#">Dropdown <span class="caret"></span></a>
<ul id="menu1" class="dropdown-menu" role="menu" aria-labelledby="drop4">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
@@ -72,7 +72,7 @@
</ul>
</li>
<li class="dropdown">
- <a id="drop5" role="button" data-toggle="dropdown" href="#">Dropdown 2 <b class="caret"></b></a>
+ <a id="drop5" role="button" data-toggle="dropdown" href="#">Dropdown 2 <span class="caret"></span></a>
<ul id="menu2" class="dropdown-menu" role="menu" aria-labelledby="drop5">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
@@ -82,7 +82,7 @@
</ul>
</li>
<li class="dropdown">
- <a id="drop6" role="button" data-toggle="dropdown" href="#">Dropdown 3 <b class="caret"></b></a>
+ <a id="drop6" role="button" data-toggle="dropdown" href="#">Dropdown 3 <span class="caret"></span></a>
<ul id="menu3" class="dropdown-menu" role="menu" aria-labelledby="drop6">
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Action</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="http://twitter.com/fat">Another action</a></li>
diff --git a/docs/_includes/js/popovers.html b/docs/_includes/js/popovers.html
index 739d86bce..95868af1a 100644
--- a/docs/_includes/js/popovers.html
+++ b/docs/_includes/js/popovers.html
@@ -193,7 +193,10 @@ $('.popover-dismiss').popover({
<td>content</td>
<td>string | function</td>
<td>''</td>
- <td>Default content value if <code>data-content</code> attribute isn't present</td>
+ <td>
+ <p>Default content value if <code>data-content</code> attribute isn't present.</p>
+ <p>If a function is given, it will be called with 1 argument, which is the element that the popover is attached to.</p>
+ </td>
</tr>
<tr>
<td>delay</td>
diff --git a/docs/_includes/js/scrollspy.html b/docs/_includes/js/scrollspy.html
index 959807a2f..989c7ea5e 100644
--- a/docs/_includes/js/scrollspy.html
+++ b/docs/_includes/js/scrollspy.html
@@ -20,7 +20,7 @@
<li><a href="#fat">@fat</a></li>
<li><a href="#mdo">@mdo</a></li>
<li class="dropdown">
- <a href="#" id="navbarDrop1" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" id="navbarDrop1" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu" aria-labelledby="navbarDrop1">
<li><a href="#one" tabindex="-1">one</a></li>
<li><a href="#two" tabindex="-1">two</a></li>
diff --git a/docs/_includes/js/tabs.html b/docs/_includes/js/tabs.html
index 8ada59028..c6c3e0df6 100644
--- a/docs/_includes/js/tabs.html
+++ b/docs/_includes/js/tabs.html
@@ -8,7 +8,7 @@
<li class="active"><a href="#home" data-toggle="tab">Home</a></li>
<li><a href="#profile" data-toggle="tab">Profile</a></li>
<li class="dropdown">
- <a href="#" id="myTabDrop1" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
+ <a href="#" id="myTabDrop1" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu" aria-labelledby="myTabDrop1">
<li><a href="#dropdown1" tabindex="-1" data-toggle="tab">@fat</a></li>
<li><a href="#dropdown2" tabindex="-1" data-toggle="tab">@mdo</a></li>
diff --git a/docs/_includes/nav/main.html b/docs/_includes/nav/main.html
index 9f449f258..6f773d2c1 100644
--- a/docs/_includes/nav/main.html
+++ b/docs/_includes/nav/main.html
@@ -28,8 +28,8 @@
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
- <li><a href="{{ site.expo }}" onclick="_gaq.push(['_trackEvent', 'Navbar', 'Community links', 'Expo']);">Expo</a></li>
- <li><a href="{{ site.blog }}" onclick="_gaq.push(['_trackEvent', 'Navbar', 'Community links', 'Blog']);">Blog</a></li>
+ <li><a href="{{ site.expo }}" onclick="ga('send', 'event', 'Navbar', 'Community links', 'Expo');">Expo</a></li>
+ <li><a href="{{ site.blog }}" onclick="ga('send', 'event', 'Navbar', 'Community links', 'Blog');">Blog</a></li>
</ul>
</nav>
</div>