diff --git a/docs/4.0/getting-started/theming.md b/docs/4.0/getting-started/theming.md index 33623f4d0a..bc7b5f466f 100644 --- a/docs/4.0/getting-started/theming.md +++ b/docs/4.0/getting-started/theming.md @@ -93,7 +93,9 @@ Repeat as necessary for any variable in Bootstrap, including the global options Bootstrap 4 includes a handful of Sass maps, key value pairs that make it easier to generate families of related CSS. We use Sass maps for our colors, grid breakpoints, and more. Just like Sass variables, all Sass maps include the `!default` flag and can be overridden and extended. -For example, to modify an existing color in our `$theme-colors` map, add the following to your custom Sass file: +Some of our Sass maps are merged into empty ones by default. This is done to allow easy expansion of a given Sass map, but comes at the cost of making _removing_ items from a map slightly more difficult. + +To modify an existing color in our `$theme-colors` map, add the following to your custom Sass file: {% highlight scss %} $theme-colors: ( @@ -110,6 +112,12 @@ $theme-colors: ( ); {% endhighlight %} +To remove colors from `$theme-colors`, or any other map, use `map-remove`: + +{% highlight scss %} +$theme-colors: map-remove($theme-colors, "success", "info", "danger"); +{% endhighlight %} + ### Functions Bootstrap utilizes several Sass functions, but only a subset are applicable to general theming. We've included three functions for getting values from the color maps: