mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-19 16:54:24 +01:00
grid cleanup, nav rearranging
This commit is contained in:
parent
a63c066e3d
commit
46f1fbe746
@ -16,18 +16,6 @@
|
||||
- title: License FAQs
|
||||
- title: Translations
|
||||
|
||||
- title: Scaffolding
|
||||
pages:
|
||||
- title: Normalize
|
||||
- title: Base
|
||||
- title: Typography
|
||||
sections:
|
||||
- title: Scale
|
||||
- title: Body copy
|
||||
- title: Headings
|
||||
- title: Images
|
||||
- title: Print
|
||||
|
||||
- title: Layout
|
||||
pages:
|
||||
- title: Grid
|
||||
@ -36,16 +24,16 @@
|
||||
|
||||
- title: Components
|
||||
pages:
|
||||
# - title: Scaffolding
|
||||
- title: Scaffolding
|
||||
# - title: Grid
|
||||
# sections:
|
||||
# - title: Overview
|
||||
# - title: Typography
|
||||
# sections:
|
||||
# - title: Scale
|
||||
# - title: Body copy
|
||||
# - title: Headings
|
||||
# - title: Images
|
||||
- title: Typography
|
||||
sections:
|
||||
- title: Scale
|
||||
- title: Body copy
|
||||
- title: Headings
|
||||
- title: Images
|
||||
- title: Code
|
||||
sections:
|
||||
- title: Inline code
|
||||
|
@ -1,13 +1,10 @@
|
||||
<a id="grid"></a>
|
||||
|
||||
# Grid system
|
||||
---
|
||||
layout: page
|
||||
title: Grid system
|
||||
---
|
||||
|
||||
Bootstrap includes a responsive, mobile first fluid grid system that appropriately scales up to 12 columns as the device or viewport size increases. It includes [predefined classes](#grid-example-basic) for easy layout options, as well as powerful [mixins for generating more semantic layouts](#grid-semantic).
|
||||
|
||||
|
||||
|
||||
<a id="grid-intro"></a>
|
||||
|
||||
### Introduction
|
||||
|
||||
Grid systems are used for creating page layouts through a series of rows and columns that house your content. Here's how the Bootstrap grid system works:
|
||||
@ -24,10 +21,6 @@ Grid systems are used for creating page layouts through a series of rows and col
|
||||
|
||||
Look to the examples for applying these principles to your code.
|
||||
|
||||
|
||||
|
||||
<a id="grid-media-queries"></a>
|
||||
|
||||
### Media queries
|
||||
|
||||
We use the following media queries in our Less files to create the key breakpoints in our grid system.
|
||||
@ -55,10 +48,6 @@ We occasionally expand on these media queries to include a <code>max-width</code
|
||||
@media (min-width: @screen-lg-min) { ... }
|
||||
{% endhighlight %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-options"></a>
|
||||
|
||||
### Grid options
|
||||
|
||||
See how aspects of the Bootstrap grid system work across multiple devices with a handy table.
|
||||
@ -137,10 +126,6 @@ See how aspects of the Bootstrap grid system work across multiple devices with a
|
||||
</table>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<a id="grid-semantic"></a>
|
||||
|
||||
### Example: Semantic grid mixins
|
||||
|
||||
In addition to [prebuilt grid classes](#grid-example-basic) for fast layouts, Bootstrap includes Less variables and mixins for quickly generating your own simple, semantic layouts.
|
||||
@ -237,10 +222,6 @@ See it in action in <a href="http://jsbin.com/qiqet/3/edit">this rendered exampl
|
||||
</div>
|
||||
{% endhighlight %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-example-basic"></a>
|
||||
|
||||
### Example: Stacked-to-horizontal
|
||||
|
||||
Using a single set of `.col-md-*` grid classes, you can create a basic grid system that starts out stacked on mobile devices and tablet devices (the extra small to small range) before becoming horizontal on desktop (medium) devices. Place grid columns in any `.row`.
|
||||
@ -275,10 +256,6 @@ Using a single set of `.col-md-*` grid classes, you can create a basic grid syst
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-example-fluid"></a>
|
||||
|
||||
### Example: Fluid container
|
||||
|
||||
Turn any fixed-width grid layout into a full-width layout by changing your outermost `.container` to `.container-fluid`.
|
||||
@ -291,10 +268,6 @@ Turn any fixed-width grid layout into a full-width layout by changing your outer
|
||||
</div>
|
||||
{% endhighlight %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-example-mixed"></a>
|
||||
|
||||
### Example: Mobile and desktop
|
||||
|
||||
Don't want your columns to simply stack in smaller devices? Use the extra small and medium device grid classes by adding `.col-xs-*` and `.col-md-*` to your columns. See the example below for a better idea of how it all works.
|
||||
@ -320,10 +293,6 @@ Don't want your columns to simply stack in smaller devices? Use the extra small
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-example-complete"></a>
|
||||
|
||||
### Example: Mobile, tablet, desktops
|
||||
|
||||
Build on the previous example by creating even more dynamic and powerful layouts with tablet `.col-sm-*` classes.
|
||||
@ -342,10 +311,6 @@ Build on the previous example by creating even more dynamic and powerful layouts
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-example-wrapping"></a>
|
||||
|
||||
### Example: Column wrapping
|
||||
|
||||
If more than 12 columns are placed within a single row, each group of extra columns will, as one unit, wrap onto a new line.
|
||||
@ -358,10 +323,6 @@ If more than 12 columns are placed within a single row, each group of extra colu
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-responsive-resets"></a>
|
||||
|
||||
### Example: Responsive column resets
|
||||
|
||||
With the four tiers of grids available you're bound to run into issues where, at certain breakpoints, your columns don't clear quite right as one is taller than the other. To fix that, use a combination of a `.clearfix` and our [responsive utility classes](#responsive-utilities).
|
||||
@ -393,10 +354,6 @@ In addition to column clearing at responsive breakpoints, you may need to **rese
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-offsetting"></a>
|
||||
|
||||
### Example: Offsetting columns
|
||||
|
||||
Move columns to the right using `.col-md-offset-*` classes. These classes increase the left margin of a column by `*` columns. For example, `.col-md-offset-4` moves `.col-md-4` over four columns.
|
||||
@ -415,10 +372,6 @@ Move columns to the right using `.col-md-offset-*` classes. These classes increa
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-nesting"></a>
|
||||
|
||||
### Example: Nesting columns
|
||||
|
||||
To nest your content with the default grid, add a new `.row` and set of `.col-sm-*` columns within an existing `.col-sm-*` column. Nested rows should include a set of columns that add up to 12 or less (it is not required that you use all 12 available columns).
|
||||
@ -439,10 +392,6 @@ To nest your content with the default grid, add a new `.row` and set of `.col-sm
|
||||
</div>
|
||||
{% endexample %}
|
||||
|
||||
|
||||
|
||||
<a id="grid-column-ordering"></a>
|
||||
|
||||
### Example: Column ordering
|
||||
|
||||
Easily change the order of our built-in grid columns with `.col-md-push-*` and `.col-md-pull-*` modifier classes.
|
Loading…
x
Reference in New Issue
Block a user