Skip to content

Releases: styled-components/polished

v3.6.6

30 Aug 13:54
Compare
Choose a tag to compare
  • Security updates to build dependencies
  • Changes to support the transition from master to main as default branch

v3.6.5

11 Jun 22:42
Compare
Choose a tag to compare

Bug Fix

  • cssVar: Properly handles the exception where the document object is not available in non-browser environments (#518). This simply throws a proper error. It does not enable cssVar to work server-side.

v3.6.4

29 May 12:20
Compare
Choose a tag to compare

Bug Fix

  • rgbToString: Fixes an issue where passing a rgba color with 0 alpha was incorrectly returning a hex value (#515)

v3.6.3

10 May 14:59
Compare
Choose a tag to compare

Bug Fix

  • normalize: Updates to normalize.css 8.0.1 to fix a regression to fix a regression with main not being set to display: block.

v3.6.2

06 May 10:11
Compare
Choose a tag to compare

Bug Fix

  • Removes esmodules: true from the esm build to fix an issue with ES5 support.

v3.6.1

05 May 01:21
Compare
Choose a tag to compare

Bug Fix

  • Remove extraneous jsnext:main bundle reference that was not pointing to an ES5 compatible build.

v3.6.0

02 May 17:40
Compare
Choose a tag to compare

Build Enhancements

  • Build a commonjs bundle and make it the new main bundle.
  • Target only browsers that support ESModules for the esm bundle and leverage bugfixes: true.
  • Add specific brower support to non-esm bundles.
  • Replace uglify with terser on minified standalone build.
  • Standalone build now comes with runtime helpers on board.
  • Upgrade dependencies.

v3.5.2

19 Apr 04:29
Compare
Choose a tag to compare

Bug Fixes

  • cssVar: fixed issue where CSS variables set my stylesheets were returning with a leading space and breaking other polished modules when passed the return value. (#493)

v3.5.1

22 Mar 15:56
Compare
Choose a tag to compare

Bug Fixes

  • between, modularScale, triangle: fixed issue where these modules were calling deprecated functionality in stripUnit and creating unnecessary console noise (and subsequent performance problems).

v3.5.0

20 Mar 10:33
Compare
Choose a tag to compare

Introducing polished.js v3.5.0!

We're super stoked to announce that polished.js v3.5.0 is officially out! It is available via your package manager of choice. This will be the final non-patch release before v4.

npm install polished
yarn add polished

Release Highlights

New Modules

  • cssVar: We've introduced a new module to handle fetching CSS Variable values. We chose to make this a standalone module as opposed to integrating it into all modules to keep module size down.

Improvements

  • readableColor: You can now turn on strict mode for custom provided return colors. This will ensure that they still meet AA contrasting standards. Otherwise, they will return black or white as normal. This mode is off by default in v3.5. (Thanks @mrmckeb).

Bug Fixes

  • mix, tint, shade: Fixed a bug where mix was improperly weighting alpha channels to the second provided color instead of the first. This fix also impacts tint and shade which implement mix.

Contributors

  • Build has been updated to use Rollup 2.
  • Moved CI to GitHub Actions.
  • We now test the build in macOS, Ubuntu, and Windows to ensure all contributors are covered for compatibility.

Future Deprecations

  • Deprecation: stripUnit: The optional unit return will be deprecated in v4. Previously, this was implemented to replace getValueAndUnit. However, we've decided to keep the extra module and simplify stripUnit
  • Deprecation: readableColor: strict mode will be enabled by default in v4, it is currently disabled by default.