Bootstrap 5.3.0 emphasizes dark mode, custom colors

Bootstrap 5.3.0 emphasizes dark mode, custom colors

Color palette
ronstik/Shutterstock

Bootstrap 5.3.0, the latest version of the CSS, JavaScript, and HTML web framework, has arrived with an emphasis on dark mode and custom color modes.

The final stable release of this update to the mobile-first application framework was announced May 30 and can be accessed from GetBootstrap.com. In this version, Bootstrap’s core was rewritten to offer “first class” support for dark mode, which is opt-in by default. Bootstrap also now supports any number of color modes for building custom themes or more-nuanced color modes. Dark mode styles are generated via a new color-mode() Sass mixin, allowing developers to write styles specific to a particular color mode. A new _variables-dark.scss stylesheet, meanwhile, houses dark-mode-specific Sass variables. Also in Bootstrap 5.3.0:

  • A revamped color palette includes all new Sass variables, CSS variables, and utilities for setting color, background-color, and border-color.
  • Foreground and background colors have been expanded to include new secondary, tertiary, and emphasis colors, while theme colors have been expanded to include subtle background colors.
  • Link styling was improved, with new link helpers and utilities.
  • Navs have new :focus_visible styles that better match custom button focus styles.
  • CSS variable-based border-width utilities were reverted to set their property directly, as was the case prior to version 5.2.0. (This avoids inheritance issues across nested elements, including tables.)

Moving forward, plans for Bootstrap 5.4.0 call for improving the utilities API and related code. Patch releases for 5.3.x are planned to address any issues over the coming weeks.

Copyright © 2023 IDG Communications, Inc.

InfoWorld Technology of the Year Awards 2023. Now open for entries!
<!-- var slotName = 'bottomleaderboard'; var slotSize = []; if ($thm.deviceClass == 'mobile') { slotSize = [[300,50],[320,50],[300,250]]; } else if ($thm.deviceClass == 'tablet') { slotSize = [[728,90],[468,60]]; } else { slotSize = [[728,90],[970,90],[970,250]]; } IDG.GPT.addDisplayedAd(slotName, "true"); document.write('

'); IDG.GPT.defineGoogleTagSlot(slotName, slotSize, false, true); document.write('

'); $('#' + slotName).responsiveAd({screenSize:'971 1115', scriptTags: []}, true); //-->

Add a Comment