<pclass="lead">Bootstrap includes a responsive, percent-based grid system that appropriately scales up to 12 columns as the device or viewport size increases—in other words, it's mobile first. It includes <ahref="#grid-example">predefined classes</a> for this, as well as powerful <ahref="#grid-less">mixins for generating semantic layouts</a>.</p>
<h3id="grid-example">Grid example</h3>
<p>On mobile devices, the grid starts out stacked. Above 768px, it becomes horizontal as media queries kick in to apply <code>float</code>s and <code>width</code>s. To create a basic grid layout, wrap a series of <code>.col-span-*</code> elements within a <code>.row</code>. As this is a 12-column grid, each <code>.span*</code> spans a number of those 12 columns, and should always add up to 12 for each row (or the number of columns in the parent), even at mobile resolutions.</p>
<p>On mobile devices, the grid starts out stacked. Above 768px, it becomes horizontal as media queries kick in to apply <code>float</code>s and <code>width</code>s. To create a basic grid layout, wrap a series of <code>.col-span-*</code> elements within a <code>.row</code>. As this is a 12-column grid, each <code>.col-span-*</code> spans a number of those 12 columns, and should always add up to 12 for each row (or the number of columns in the parent), even at mobile resolutions.</p>
<divclass="bs-docs-grid">
<divclass="row show-grid">
<divclass="col-span-1">1</div>
...
...
@@ -1172,8 +1172,8 @@ For example, <code><section></code> should be wrapped as inline.
<p>Use contextual classes to color table rows.</p>
<tableclass="table table-bordered table-striped">
<colgroup>
<colclass="span1">
<colclass="span7">
<colclass="col-span-1">
<colclass="col-span-7">
</colgroup>
<thead>
<tr>
...
...
@@ -1640,12 +1640,12 @@ For example, <code><section></code> should be wrapped as inline.
<p>Add text or buttons before, after, or on both sides of any text-based input. Use <code>.input-group</code> with a <code>.add-on</code> to prepend or append elements to an <code><input></code>.</p>
<p>Avoid using <code><select></code> elements here as they cannot be fully styled in WebKit browsers.</p>
<formclass="bs-docs-example">
<divclass="input-group span9">
<divclass="input-group col-span-9">
<spanclass="input-group-addon">@</span>
<inputtype="text"placeholder="Username">
</div>
<br>
<divclass="input-group span6">
<divclass="input-group col-span-6">
<inputtype="text">
<spanclass="input-group-addon">.00</span>
</div>
...
...
@@ -1657,12 +1657,12 @@ For example, <code><section></code> should be wrapped as inline.
</div>
</form>
{% highlight html linenos %}
<divclass="input-group span9">
<divclass="input-group col-span-9">
<spanclass="input-group-addon">@</span>
<inputtype="text"placeholder="Username">
</div>
<divclass="input-group span6">
<divclass="input-group col-span-6">
<inputtype="text">
<spanclass="input-group-addon">.00</span>
</div>
...
...
@@ -1677,33 +1677,33 @@ For example, <code><section></code> should be wrapped as inline.
<h4>Optional sizes</h4>
<p>Add the relative form sizing classes to the `.input-group-addon`.</p>
@@ -1712,14 +1712,14 @@ For example, <code><section></code> should be wrapped as inline.
<h4>Buttons instead of text</h4>
<p>Buttons in input groups are a bit different and require one extra level of nesting. Instead of <code>.input-group-addon</code>, you'll need to use <code>.input-group-btn</code> to wrap the buttons. This is required due to default browser styles that cannot be overridden.</p>
<formclass="bs-docs-example">
<divclass="input-group span7">
<divclass="input-group col-span-7">
<spanclass="input-group-btn">
<buttonclass="btn"type="button">Go!</button>
</span>
<inputtype="text">
</div>
<br>
<divclass="input-group span7">
<divclass="input-group col-span-7">
<inputtype="text">
<spanclass="input-group-btn">
<buttonclass="btn"type="button">Go!</button>
...
...
@@ -1727,14 +1727,14 @@ For example, <code><section></code> should be wrapped as inline.
</div>
</form>
{% highlight html linenos %}
<divclass="input-group span7">
<divclass="input-group col-span-7">
<spanclass="input-group-btn">
<buttonclass="btn"type="button">Go!</button>
</span>
<inputtype="text">
</div>
<divclass="input-group span7">
<divclass="input-group col-span-7">
<inputtype="text">
<spanclass="input-group-btn">
<buttonclass="btn"type="button">Go!</button>
...
...
@@ -1745,7 +1745,7 @@ For example, <code><section></code> should be wrapped as inline.
@@ -3598,7 +3598,7 @@ For example, <code><section></code> should be wrapped as inline.
{% endhighlight %}
<divclass="alert alert-info">
<strong>Heads up!</strong> The responsive navbar requires the <ahref="./javascript.html#collapse">collapse plugin</a> and <ahref="./scaffolding.html#responsive">responsive Bootstrap CSS file</a>.
<strong>Heads up!</strong> The responsive navbar requires the <ahref="#collapse">collapse plugin</a>.
</div>
...
...
@@ -3632,7 +3632,7 @@ For example, <code><section></code> should be wrapped as inline.