0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-11-29 11:24:18 +01:00
Commit Graph

781 Commits

Author SHA1 Message Date
Mark Otto
6a37612540 Add dedicated accordion component based on Collapse JS 2020-11-06 14:49:41 +02:00
Gaël Poupard
230a41f1d7
Form file docs and overrides (#32058) 2020-11-03 18:22:35 +01:00
Mark Otto
241f910dc5
Updated .rounded utilities (#31687)
* Updated rounded utilities to fix scale, but not rename anything else

* Rename rounded-pill to border-radius-pill to match

Also reorder some variables while I'm here to make more sense

* Updated rounded utilities to fix scale, but not rename anything else

* Rename rounded-pill to border-radius-pill to match

Also reorder some variables while I'm here to make more sense

* Small copy addition

* Add example modifier class for spacing

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-10-30 22:42:11 +02:00
Martijn Cuppens
ed1d867dd8
Remove explicit heights on form elements (#31993)
* Remove explicit heights

* Link to upstream bug

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-10-29 15:18:39 +02:00
Martijn Cuppens
f236667483 Drop custom file upload plugin in favor of CSS 2020-10-28 18:29:28 +01:00
Mark Otto
3e2f9ab237
v5: Floating labels (#30449)
* v5: Promote floating labels example to component

- Adds new .form-floating
- Stubs out basics of a docs page
- Removes existing Example

* Update floating labels to support .form-select, make inputs and selects more consistent

- To do this, I made the .form-control and .form-select consistent in min-height vs height
- Removed some unused variables now
- Updated -color to be the -color because I don't know why this was any different before
- Update page to include some examples for layout, validation, and value
- Rewrite styles to not modify padding, but instead transform and opacity

* Streamline and bulletproof some things

- Apply some optimizations from code review
- Removed unecessary properties from the label
- Add some comments for what properties are required
- Move from fixed height for labels to height 100% so we can support textareas
- Improve docs a little bit, add ToC

* Move some values to variables, switch from scaling font-size to scale, update transforms

* Bring over changes from #30966 and add to them to tighten things up

* Delete the now unused example images

* Fix typo

* Allowlist the calc function

* Add transform-origin, update transform values

* Test out autofill fix

* Fix linter issue

* Mention it in the migration guide

* Bump bundlesize

* Add one more variable per review

* Shave .25rem off the height

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-10-27 20:45:48 -07:00
Mark Otto
e5fa708491
v5: Add .fs-* utilities for font-size and rename font-weight/-style utilities (#30571)
* v5: Add .fs-* utilities for font-size

- Adds new font-sizes Sass map
- Generates six new classes for setting only font-size
- Updates docs to mention this, including a scss-docs reference

* Update font utilities

- Make .fs-* utils for font-size use RFS
- Rename .font-weight-* utils to .fw-*
- Rename .font-style-* utils to .f-*
- Update order of utilities a bit
- Update docs to match

* Update migration docs to make note of these changes

* Be more specific in font-size docs about scale

* Update font-style abbreviation to .fst

* Fix font-weight property

* Formatting & font style utility fix

* Move to Alpha 3 migration section

* Update migration guide for more details, splitting alpha 2 stuff back to the appropriate section in Migration guide

* Tweak language on example

Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-10-26 16:42:07 -07:00
Gaël Poupard
341bd5aa46
Handle the Ubuntu sans-serif case (#31657)
On Ubuntu, our native font-stack doesn't output the same font on Firefox and Chrome. This is [a known aliasing issue](http://fontfamily.io/sans-serif) — check at the bottom, Ubuntu 14.04. Ubuntu 18.04 (my current) doesn't use the same (Firefox uses Liberation Sans, Chrome uses the default system font Ubuntu).

I'm inclined to prefer Liberation Sans since it's closer to Arial / Helvetica. This patch already exists in Boosted, didn't notice it was missing in bootstrap until today…

BTW, our linked Smashing Magazine's system fonts post mentions this and is even more accurate since it targets the three major Linux distributions. AFAIK this is not needed since [Liberation Sans is available everywhere](http://fontfamily.io/Liberation_Sans) — but we might go back to `Oxygen, Ubuntu, Cantarell`if we want to stick to system fonts.

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-10-22 09:28:19 +03:00
Gaël Poupard
ed2f43e1b9
Apply smooth-scroll when prefers-reduced-motion: no-preference (#31877)
* feat(reboot): apply smooth-scroll when not prefers-reduced-motion

* docs(migration): mention scroll-behavior in alpha3

* docs(accessibility): mention scroll-behavior in reduced motion section

* docs(accessibility): rewording smooth scroll sentence

* feat(variable): introduce enable-smooth-scroll variable

* docs(accessibility): reword smooth-scroll sentence

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-10-19 12:00:37 +03:00
Martijn Cuppens
cdc12165a9
Colors rewrite (#30622) 2020-10-13 09:58:06 +02:00
Mark Otto
3cf51c6ac9
Add Sass variable for CSS variable prefix (#31684)
* Add Sass variable for CSS variable prefix

* Update other --bs-* var instances
2020-09-30 08:32:58 +03:00
Gaël Poupard
7e195a8d22
feat(colors): bump dark to gray-900 (#30550)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-29 22:09:38 +03:00
Nikita Mikhaylov
0cb880c7fb
Fix disabled checkbox toggle buttons (#31651)
* fix disabled checkbox toggle buttons

* add disabled checks-radios examples in documentation

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-29 21:49:50 +03:00
XhmikosR
c30b6df54b
Update stylelint to v13.7.2 (#31726) 2020-09-28 14:57:48 +03:00
XhmikosR
6f3a7b1bcf
_variables: change $btn-close-bg's attribute order (#31772)
Just to save a few bytes from the compressed files.
2020-09-28 13:18:12 +03:00
Martijn Cuppens
ca22578848
Restore rem unit (#31746)
Fix unintentional unit change in 1af79bbc52 (diff-d8ee409a461718bfb6240710c8c73382)
2020-09-25 12:12:00 +03:00
Mark Otto
f951be36a1
Carousel enhancements, including .carousel-dark (#31650)
* Replace existing carousel control icons with chevrons from Bootstrap Icons

* Add .carousel-dark variant

* Test

* Add variable for .carousel-dark filter

* Update _variables.scss

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-24 13:16:20 -07:00
Mark Otto
585b3ec532
Add .dropdown-menu-dark (#30171)
* Add .dropdown-menu-dark

* Match background color to navbar dark

* Update docs to include a navbar example

* Update dropdowns.md

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-24 18:55:15 +03:00
Mark Otto
54ac2c7b05 Match container gutters with row gutters
- Replaces make-container mixin's padding-x param with gutter to match naming
- Changes value of container padding variable to match grid gutter width variable
- Uses local CSS variable for container padding

Fixes #31642
2020-09-23 13:30:54 -07:00
Mark Otto
fe38a85839 Rename the classes and docs page, update everything accordingly 2020-09-23 13:30:11 -07:00
Mark Otto
18f8601d29 Updates responsive embeds with new class names and CSS variables
- Renames .embed-responsive-XbyY classes to .embed-responsive-XxY
- Simplifies the Sass map to just be key and value, ratio and percentage
- Builds .embed-responsive-* modifiers with CSS variables
- Updates docs to show power of CSS variables
- Add notes to the Migration guide
2020-09-23 13:30:11 -07:00
Martijn Cuppens
5280771883
Input group addon sass customization options (#31729) 2020-09-23 15:48:37 +02:00
Mark Otto
c0fe38364a Add more variables, add a comment for the 3 2020-09-22 16:49:02 -07:00
Mark Otto
fae9aef3db Update toasts dismiss (moving more styles to CSS instead of utilities), fix some more close examples, and add a new .btn-close-white variant 2020-09-22 16:49:02 -07:00
Mark Otto
95f81f8331 Add opacity variables, set opacity on disabled state 2020-09-22 16:49:02 -07:00
Mark Otto
1af79bbc52 Increase width of focus styles so it's more pixel perfect out of the box 2020-09-22 16:49:02 -07:00
Mark Otto
99777662c6 Rename .close to .btn-close, replace times sign with background SVG, update focus state 2020-09-22 16:49:02 -07:00
Mark Otto
fe77208a01 Add new variable for -padding-x 2020-09-22 10:06:08 -07:00
Jaume Sala
7bbfd439c9
Extra position utilities (#31280)
* Extra position utilities

Given that there are utilities for the *position* property, it seems logic to have utilities for the *top*, *left*, *bottom* and *right* propertires.

* Update extra position utilities

* add default position values map

* tweak examples

* add real life examples

* fix double colon

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-20 19:42:41 -07:00
XhmikosR
400b8a6754 Add spaces after commas 2020-09-15 11:57:36 +03:00
Mauricio Hernan Cabrera
6455c2e8aa
Add border width utility (#31484)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-09-09 11:28:52 +03:00
Samarth Arora
5512dde203 Add transition to Pagination buttons just like other Bootstrap buttons 2020-08-03 09:57:12 -07:00
Patrick H. Lauke
a21f605299
Add padding to badges (#31132)
* Add padding to badges

The current badges are very tightly padded, and because the top and bottom padding are the same, and aligned to the baseline, this makes badges with descenders (e.g. the "g" in "Danger") look uncomfortably close to the bottom. Adding more ample padding masks this a bit.
An alternative would be to have separate top and bottom padding, with the bottom one slightly larger than the top - but conversely, that then makes badges that contain no text with descenders, and particularly badges that contain all uppercase characters, look too bottom-heavy.
Also adding some left/right extra padding, as currently the pill badges look uncomfortably tight on the sides due to the rounding.
2020-08-02 16:28:23 +03:00
Mark Otto
16adcf2de9
Adjust sizing of checks and radios (#31383)
Moves from 1.25em to 1em to better support custom font-size-base values. Most common would probably be .875rem (14px) and current sizing garbles that into 1.09-ish, thus causing the rendering issues in #31269.

Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-07-31 16:49:28 +03:00
Mark Otto
6914efe8dd
v5: Tweak some colors (#31276)
* Tweak green and cyan colors, bump min contrast ratio to 4.5

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-07-13 21:23:38 +03:00
Mark Otto
2b4db023cd Add null variables for nav-link
Replaces #30498 by adding four new null default variables for .nav-link. Doesn't carry over font-style from the original PR though since that's rarely used, at least by default Bootstrap. Nullifies all values from that PR, too, since we count on some basic inheritance here and don't need color by default.
2020-07-11 11:56:29 -07:00
Jorge González
d33a560dd6
Fix table separator typo (#31162) 2020-06-24 18:28:47 +02:00
Patrick H. Lauke
02ff387daa
Darken dropdown divider (#31131)
currently, `$gray-200` is practically imperceptible. switch to reusing `$dropdown-border-color`.
2020-06-23 21:00:28 +01:00
Catalin Zalog
9f9e4d04a1
feat: adds th null var (#30781)
Inherit `font-weight: bold` that comes from user agent stylesheets.
2020-06-17 16:55:28 +03:00
Mark Otto
286f16b92c
v5: Redo blockquote attributions (#30814)
* v5: Redo blockquote attributions

- Renames -small-* variables to -footer-*
- Updates blockquote demos with attribution to place it outside the blockquote with a figure wrapper

* Updated class name

* docs(examples): refactor blockquotes in masonry example

Co-authored-by: Gaël Poupard <gael.poupard@orange.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-06-12 14:26:37 -07:00
Martijn Cuppens
e9f7a1d826
Fix undefined custom properties in reboot (#30981) 2020-06-09 10:20:53 +02:00
Martijn Cuppens
b531bda07c Improve gradients
- Use a semitransparent gradient from light to dark which works on any background-color
- Store the gradient as a custom property (--bs-gradient)
- Remove `.bg-gradient-*` variants in favour of `.bg-gradient` which works even when `$enable-gradients` are enabled
- Add gradients to navbar, active page links and badges when gradients are enabled
2020-05-15 15:03:12 +03:00
Mark Otto
bbeda10e37 v5: Update color on custom switch focus state
Replaces a custom hsla() value (dunno what I was thinking when I added this) with a reassigned existing variable. This variable goes up the stack and attaches to the component-active-bg variable, derived from our primary color out of the box. Fixes #30646.
2020-05-14 20:31:30 -07:00
Mark Otto
46d876314b
Split table cell padding variables (#30815) 2020-05-14 19:43:33 +02:00
Catalin Zalog
e6829fb7b6
style: removes space (#30782) 2020-05-12 10:28:59 +03:00
Mark Otto
3e73039936
v5: Unify spacing across components (#30564)
Co-Authored-By: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-04-30 15:17:08 +02:00
Mark Otto
88490fe81d Use scss-docs for color maps 2020-04-26 17:26:04 -07:00
Mark Otto
0408799ae5 Rename variables for brevity
- Rename `$enable-prefers-reduced-motion-media-query` to `$enable-reduced-motion`
- Rename `$enable-pointer-cursor-for-buttons` to `$enable-button-pointers`
2020-04-26 17:26:04 -07:00
Martijn Cuppens
6558664f4c Customizable table group seperator colors 2020-04-24 10:05:10 +02:00
Martijn Cuppens
d089a683c8 Prevent nested tables style leaks 2020-04-24 10:05:10 +02:00