Now navbars have their own float utility classes, mixin-ed versions of
`.pull-left` and `.pull-right`.
* Removed chained `.navbar-nav.pull-right`
* Added `.navbar-left` and `.navbar-right` as mixins of the default
float utilities, but only above the `@grid-float-breakpoint` to match
the new navbar behavior
* Updated components docs to match the new changeas
* Added callout about component alignment here to explain the new
classes
* Now responsive by default (fits better with mobile-first approach)
* Requires `.nav-header` to group `.navbar-brand` and `.navbar-toggle`
for proper mobile display.
* Changed `.nav-collapse` to `.navbar-collapse`
* Simplified examples in docs
Instead of applying `.btn-` or `.input-` to individual elements in
button and input groups, we now have new sizing classes to keep your
markup a little leaner.
* Add `.input-group-sm` or `.input-group-lg` to your `.input-group` to
replicate `.input-sm` and `.input-lg`, respectively.
* Add `.btn-group-xs`, `.btn-group-sm`, or `.btn-group-lg` to your
`.btn-group` to replicate `.btn-xs`, `.btn-sm`, and `. btn-lg`,
respectively.
Both sets of new sizing classes simply use the existing individual
sizing classes as mixins, so customization of them is automatically
inherited when compiling.
Grid classes have been changed to account for a fourth set of classes,
meaning we now have XS, S, M, and L options. Specifically, we made the
following changes:
* Renames `.col-` to `.col-xs-`
* Adds `.col-md-` for devices 992px wide and up
* Remaps `.col-lg-` for devices 1200px wide and up
Alongside that, we've updated our media queries to better handle
advanced grid layouts:
* All column classes now kick in when they hit a `min-width`, undoing
the #9128 fix in
https://github.com/twbs/bootstrap/commit/db45a60cc86190a060f0baf0b3961cb
c690f3a65
* All column offsets, pushes, and pulls are scoped to an appropriate
range, meaning a `min-width` and `max-width` (thanks for the idea,
@eratzlaff)
We've also modified the widths of our grid containers for the small
device grid (now a max 720px instead of 728px) and large device grid
(now a max 1140px instead of 1170px) to avoid horizontal scrollbar
problems in Firefox (likely due to box-sizing, which is why we didn't
see it in 2.x).
Similarly, we've updated the responsive ultility classes to match the
new four media query approach of the grid system. That means we've:
* Added new `.visible-xs` and `.hidden-xs` classes
* Reassigns visible and hidden classes for small, medium, and large to
matching grid system media queries
* Updates docs examples to match grid system and account for fourth
utility range
-----
Fixes the following:
* #9135: fourth grid tier
* #9302: undoes previous range change for small grid system, so no need
to update any docs here
* #8755: consistent grid and responsive utilities schemas)
* #9195, #9216, and #9227: no more horizontal scrollbars
* `.navbar-brand` is no longer centered, thus removing need for
max-width and a few lines of code
* Clear floats of `.navbar-brand` in the `.nav-collapse` like we did in
2.x, thus simplifying some clearing and other things.
* Restyle the `.navbar-toggle` button to align it's bars up with the
text and flow of the document.
* Restyle the `.navbar-brand` to not use padding on left/right as to
avoid negative margin and other fuckery. This limits the ability to put
a bg color on the brand, but I think that's fine for now.
This PR significantly improves Bootstrap's accessibility for users of assistive technology, such as screen readers. Some of the these changes add additional markup to the source examples, but we believe that the sacrifice in readability is worth achieving more widespread usage of accessibility best-practices.
What was done
- Added lots of [WAI-ARIA attributes](http://www.w3.org/WAI/intro/aria)
- Added `.sr-only` helper class, that is only readable by screen readers (and invisible for all other users). This lets us - make progress bars and paginations accessible to screen reading users.
- Advised users to always use label elements. For inline forms, they can hide them with `.sr-only`
- Added 'Skip navigation' link
- Added "Accessibility" section to getting-started.html.
What *wasn't* done
- Contrast issues (twbs#3572)
- Tooltips (twbs#8469)
- Documentation re: usage of icons, since they now live in a separate repo
Major props to all that contributed: @bensheldon, @jasonlally, @criscristina, and @louh. Feel free to chime in, guys, if I've left anything out.
- Also fixes the vertical alignment of labels in horizontal layouts on
account of the recent button and input padding changes
- Also changes the vertical alignment of the checkboxes and radios in
horizontal forms
- Spacing tweaks in the general mixins
- Add comments to transform mixins about IE support
- Remove `-ms-keyframes` because only IE10+ supports it, and without
prefix
- Add new mixin to generate and customize focus state as needed
- Adds variable to set default color
- Include clear disclaimer about customizing this—it's about users', so
don't go making everything bright red and expect them not to be
confused or alarmed.
Relevant issues: #2742, #4185, #7942, #8171, #8610, #9044
* Smaller padding on buttons and large buttons
* Same with inputs and large inputs
* Remove about 10px from height of large inputs/buttons and 4px from
regular ones
Fixes#8707 and #8700.
(Also relevant: #8711)
* Moves input groups CSS into separate file
* Moves input groups docs into the Components page
* Add support for radios and checkboxes in input groups to fix#8679
* No more need for `.row.form-group`--only need `.form-group`
* Change tag selectors for inline form to use `.form-control`
* Docs improved to explain what's happening
* Once again no longer applies to single inputs (this is a bit simpler,
but I'm open to new ideas) but the entire set of inputs, labels, and
help text within a particular element. However, the styles are not too
dependent on markup or layout, so they're super flexible.
* Simplified the markup in the validation docs examples to match latest
changes.
* Renamed `.form-state-validation` mixin to `.form-control-validation`
to match naming of prev commit.
* Reorganize forms.less
* Change from attribute selectors to `.form-control`. Few lines, less
specific (meaning easier overrides as `element[type=""]` is more
specific than a class), less intrusive, and more performant.
* Add `.form-group` for basic spacing in vertical forms.
* Remove (unnecessary?) `margin: 0;` from `form` element (as far as I
can tell no browser sets that anyway).
* Cuts close to 100 lines of CSS from the table CSS
* File size aside, this drastically simplifies CSS for folks looking to
build on top of the `.table-bordered` option as a starting point
This particular form control is wildly inaccurate across browsers, so
we're removing the `height` and `line-height`, but adding `display:
block` so it renders similarly to our other inputs.
Restores `font-size` and more to the `<select>` element while also
changing from `min-height` to `height` for input sizing.
Fixes#8520 as opened by @ShaunR (would've merged that PR but I moved
everything around right before).