Skip to content

Commit

Permalink
build: keep selector list in dist output of not pseudo-class
Browse files Browse the repository at this point in the history
A change in configuration had resulted in some regressions due to
increased specificity created in the dist output of :not selectors.
One issue was with a disabled Menu item showing a change in icon color
on hover.

The config override being removed here sets it back to the default
stage 2 configuration that allows multiple comma separated selectors
within :not(). The configuration had been converting each item in the
:not selector list into its own :not selector, increasing specificity
for each additional item.
  • Loading branch information
jawinn committed May 8, 2024
1 parent 3a18257 commit 8980ebb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .changeset/eight-spiders-help.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"@spectrum-css/calendar": patch
"@spectrum-css/combobox": patch
"@spectrum-css/datepicker": patch
"@spectrum-css/menu": patch
"@spectrum-css/picker": patch
"@spectrum-css/slider": patch
"@spectrum-css/stepper": patch
---

Build change to remove the `postcss-preset-env` polyfill for the dist output of `:not` selectors containing multiple selectors, to avoid an unintended increase in specificity, which caused some visual regressions.
1 change: 0 additions & 1 deletion postcss.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ module.exports = ({
// https://github.com/jsxtools/focus-within
"focus-within-pseudo-class": true,
"font-format-keywords": true,
"not-pseudo-class": true,
"opacity-percentage": true,
// https://github.com/csstools/postcss-plugins/tree/main/plugins/css-prefers-color-scheme
"prefers-color-scheme-query": true,
Expand Down

0 comments on commit 8980ebb

Please sign in to comment.