diff options
| author | Mark Otto <[email protected]> | 2016-05-08 13:39:47 -0700 |
|---|---|---|
| committer | Mark Otto <[email protected]> | 2016-05-08 13:39:47 -0700 |
| commit | 5e84ed1425ce9a5e3a5f0c94ad5a86a2b11a5f85 (patch) | |
| tree | d718375da11031dd15974b716951ac6ac711058a /docs/layout | |
| parent | 3b62fc0806ecf5b763f88dce08f40c138a1f772f (diff) | |
| parent | 3e40121cf87f10651d138f44b7f9c1a314bb6f2a (diff) | |
| download | bootstrap-5e84ed1425ce9a5e3a5f0c94ad5a86a2b11a5f85.tar.xz bootstrap-5e84ed1425ce9a5e3a5f0c94ad5a86a2b11a5f85.zip | |
Merge pull request #19793 from bassjobsen/patch-38
Update overview.md
Diffstat (limited to 'docs/layout')
| -rw-r--r-- | docs/layout/overview.md | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/docs/layout/overview.md b/docs/layout/overview.md index c8652cb7a..44a12aee6 100644 --- a/docs/layout/overview.md +++ b/docs/layout/overview.md @@ -111,3 +111,46 @@ Once again, these media queries are also available via Sass mixins: @include media-breakpoint-down(md) { ... } @include media-breakpoint-down(lg) { ... } {% endhighlight %} + +We also have media between the breakpoint's minimum and maximum widths for only the given screen size: + +{% highlight scss %} +// Extra small devices (portrait phones, less than 544px) +@media (max-width: 543px) { ... } + +// Small devices (landscape phones, 544px and up) +@media (min-width: 544px) and (max-width: 767px) { ... } + +// Medium devices (tablets, 768px and up) +@media (min-width: 768px) and (max-width: 991px) { ... } + +// Large devices (desktops, 992px and up) +@media (min-width: 992px) and (max-width: 1199px) { ... } + +// Extra large devices (large desktops, 1200px and up) +@media (min-width: 1200px) { ... } +{% endhighlight %} + +These media queries are also available via Sass mixins: + +{% highlight scss %} +@include media-breakpoint-only(xs) { ... } +@include media-breakpoint-only(sm) { ... } +@include media-breakpoint-only(md) { ... } +@include media-breakpoint-only(lg) { ... } +@include media-breakpoint-only(xl) { ... } +{% endhighlight %} + +And finally media that spans multiple breakpoint widths: + +{% highlight scss %} +// Example +// Medium devices (tablets, 768px and up) and Large devices (desktops, 992px and up) +@media (min-width: 768px) and (max-width: 1199px) { ... } +{% endhighlight %} + +The Sass mixin for the above example look like that shown beneath: + +{% highlight scss %} +@include media-breakpoint-between(md, lg) { ... } +{% endhighlight %} |
