Alternative to #30193. This ended up being a couple changes in one, hence the length title, but the two are connected.
De-duped .table-dark
Rather than deviate from the $theme-colors
pattern we have elsewhere, this PR removes the .table-dark
for changing the background, color, and border of a .table
. Instead, this can be accomplished through all utilities.
Also removes thead-dark/thead-light modifiers for utilities.
New border-color utils
To support the utilities-driven approach for replacing .table-dark
, I've added a few new border-color
utilities. These are a subset of our available grays, but I do believe they provide an improved set of options without including all the grays (and thus duplicating $gray-900
and $dark
options). The new options have been added to the borders utilities docs page.
New background-color utils
To match the border utilities, I've added one tint lighter for two gray backgrounds (didn't add $gray-100
as it's the same as $light
). This way you can choose from additional gray backgrounds and still have a slight contrast in the border colors. Definitely interested in thoughts on this.
Updated table docs
This also obviously updates the examples in the tables docs to reflect the new dark table approach, but also clarifies how inheritance comes into play with the table styles and the table borders. It also adds a new multiple <tbody>
example and tweaks a few other bits and pieces.
https://deploy-preview-30342--twbs-bootstrap.netlify.com/docs/4.3/content/tables/
Closes #28480 (closed), fixes #27879 (closed), nullifies #30046, fixes #28160 (closed), and fixes #24529 (closed).