feat: add the opt-in maxInputLength option, which rejects a selector longer than the limit before parsing it
feat: support the case-sensitive attribute flag s per Selectors Level 4, on Attribute#sensitive and Attribute#sensitiveFlag. [a=b s] previously left insensitive: false and filed the flag in raws.insensitiveFlag (#327 by @abhu85)
docs: add a threat model to SECURITY.md: resource consumption caused by unbounded untrusted input is now handled as a regular bug
docs: document the raw-value helpers (stringifyProperty, valueToString, setPropertyAndEscape, appendToPropertyAndEscape, setPropertyWithoutEscape), the seventeen type guards, and the clone() overrides argument (#231)
fix: forward the default options given to the parser factory, so parser(fn, { maxInputLength }) and the other options take effect there as documented (#345 by @Aurantium-47)
fix: preserve the spaces declared on selector and root containers, through rawSpaceBefore and rawSpaceAfter (#356 by @Aschenbath)
fix: preserve selector delimiters after an escaped backslash, so .a\\.b parses as two classes (#354 by @wozhenbang2004)
fix: escape class values supplied to the constructor, matching what the value setter already did (#349 by @SAY-5)
fix: escape values assigned to an id through the value setter, and replace a stale raws.value on assignment (#326 by @mahirhir)
fix: keep $ in an attribute name inside a preprocessor interpolation, so [#{$attr}] in SCSS and [@{attr}] in Less round-trip (#336 by @theRizwan)
fix: reject an attribute selector with no valid attribute name, instead of throwing a raw TypeError or emitting the literal text undefined (#335 by @theRizwan)
fix: keep the processor's entry points usable when destructured, as in const { process } = parser() (#145)
Behaviour notes
className and id values are escaped when passed to a constructor or assigned through value, so an already-escaped value is now escaped twice. setPropertyWithoutEscape() is the escape hatch.
[a=b s] sets sensitive: true rather than filing the flag in raws.insensitiveFlag. Serialization is byte-identical for i, I, s, S and non-standard flags.
Selector and Root emit their own rawSpaceBefore and rawSpaceAfter, which changes serialization for ASTs that set them.
An attribute selector with no attribute name raises the parser's own error rather than throwing a raw TypeError or serializing the text undefined: [ns|*] and [ * ] are affected. A trailing *, $, ^, ~ or | after a valid name is dropped, as [href=] already was.
fix: parse selectors in linear time on four more kinds of crafted input, closing a CPU exhaustion vulnerability (GHSA-67xj-gfww-g738, reported by @zachariah-mithani)
chore: replace the cssesc dependency with an internal copy, whose redundant space removal is linear
Configuration
📅Schedule: (UTC)
Branch creation
At any time (no schedule defined)
Automerge
At any time (no schedule defined)
🚦Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕Ignore: Close this PR and you won't be reminded about this update again.
If you want to rebase/retry this PR, check this box
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
| [postcss-selector-parser](https://github.com/postcss/postcss-selector-parser) | pnpm-workspace.overrides | minor | [`7.1.7` → `7.2.0`](https://renovatebot.com/diffs/npm/postcss-selector-parser/7.1.7/7.2.0) |
---
### Release Notes
<details>
<summary>postcss/postcss-selector-parser (postcss-selector-parser)</summary>
### [`v7.2.0`](https://github.com/postcss/postcss-selector-parser/blob/HEAD/CHANGELOG.md#720---2026-11-08)
[Compare Source](https://github.com/postcss/postcss-selector-parser/compare/7.1.8...7.2.0)
- feat: add the opt-in `maxInputLength` option, which rejects a selector longer than the limit before parsing it
- feat: support the case-sensitive attribute flag `s` per Selectors Level 4, on `Attribute#sensitive` and `Attribute#sensitiveFlag`. `[a=b s]` previously left `insensitive: false` and filed the flag in `raws.insensitiveFlag` ([#​327](https://github.com/postcss/postcss-selector-parser/pull/327) by [@​abhu85](https://github.com/abhu85))
- docs: add a threat model to `SECURITY.md`: resource consumption caused by unbounded untrusted input is now handled as a regular bug
- docs: document the raw-value helpers (`stringifyProperty`, `valueToString`, `setPropertyAndEscape`, `appendToPropertyAndEscape`, `setPropertyWithoutEscape`), the seventeen type guards, and the `clone()` overrides argument ([#​231](https://github.com/postcss/postcss-selector-parser/issues/231))
- fix: forward the default options given to the parser factory, so `parser(fn, { maxInputLength })` and the other options take effect there as documented ([#​345](https://github.com/postcss/postcss-selector-parser/pull/345) by [@​Aurantium-47](https://github.com/Aurantium-47))
- fix: preserve the spaces declared on selector and root containers, through `rawSpaceBefore` and `rawSpaceAfter` ([#​356](https://github.com/postcss/postcss-selector-parser/pull/356) by [@​Aschenbath](https://github.com/Aschenbath))
- fix: preserve selector delimiters after an escaped backslash, so `.a\\.b` parses as two classes ([#​354](https://github.com/postcss/postcss-selector-parser/pull/354) by [@​wozhenbang2004](https://github.com/wozhenbang2004))
- fix: escape class values supplied to the constructor, matching what the `value` setter already did ([#​349](https://github.com/postcss/postcss-selector-parser/pull/349) by [@​SAY-5](https://github.com/SAY-5))
- fix: escape values assigned to an id through the `value` setter, and replace a stale `raws.value` on assignment ([#​326](https://github.com/postcss/postcss-selector-parser/pull/326) by [@​mahirhir](https://github.com/mahirhir))
- fix: keep `$` in an attribute name inside a preprocessor interpolation, so `[#{$attr}]` in SCSS and `[@{attr}]` in Less round-trip ([#​336](https://github.com/postcss/postcss-selector-parser/pull/336) by [@​theRizwan](https://github.com/theRizwan))
- fix: reject an attribute selector with no valid attribute name, instead of throwing a raw `TypeError` or emitting the literal text `undefined` ([#​335](https://github.com/postcss/postcss-selector-parser/pull/335) by [@​theRizwan](https://github.com/theRizwan))
- fix: keep the processor's entry points usable when destructured, as in `const { process } = parser()` ([#​145](https://github.com/postcss/postcss-selector-parser/issues/145))
##### Behaviour notes
- `className` and `id` values are escaped when passed to a constructor or assigned through `value`, so an already-escaped value is now escaped twice. `setPropertyWithoutEscape()` is the escape hatch.
- `[a=b s]` sets `sensitive: true` rather than filing the flag in `raws.insensitiveFlag`. Serialization is byte-identical for `i`, `I`, `s`, `S` and non-standard flags.
- `Selector` and `Root` emit their own `rawSpaceBefore` and `rawSpaceAfter`, which changes serialization for ASTs that set them.
- An attribute selector with no attribute name raises the parser's own error rather than throwing a raw `TypeError` or serializing the text `undefined`: `[ns|*]` and `[ * ]` are affected. A trailing `*`, `$`, `^`, `~` or `|` after a valid name is dropped, as `[href=]` already was.
### [`v7.1.8`](https://github.com/postcss/postcss-selector-parser/blob/HEAD/CHANGELOG.md#718---2026-11-08)
[Compare Source](https://github.com/postcss/postcss-selector-parser/compare/7.1.7...7.1.8)
- fix: parse selectors in linear time on four more kinds of crafted input, closing a CPU exhaustion vulnerability ([GHSA-67xj-gfww-g738](https://github.com/advisories/GHSA-67xj-gfww-g738), reported by [@​zachariah-mithani](https://github.com/zachariah-mithani))
- chore: replace the `cssesc` dependency with an internal copy, whose redundant space removal is linear
</details>
---
### Configuration
📅 **Schedule**: (UTC)
- Branch creation
- At any time (no schedule defined)
- Automerge
- At any time (no schedule defined)
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box
---
This PR has been generated by [Mend Renovate CLI](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4yMTYuNCIsInVwZGF0ZWRJblZlciI6IjQ0LjIxNi40IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
Here are some key observations to aid the review process:
⏱️Estimated effort to review: 1 🔵⚪⚪⚪⚪
🧪No relevant tests
🔒No security concerns identified
⚡No major issues detected
## PR Reviewer Guide 🔍
<!-- pr-agent:review:full -->
Here are some key observations to aid the review process:
<table>
<tr><td>⏱️ <strong>Estimated effort to review</strong>: 1 🔵⚪⚪⚪⚪</td></tr>
<tr><td>🧪 <strong>No relevant tests</strong></td></tr>
<tr><td>🔒 <strong>No security concerns identified</strong></td></tr>
<tr><td>⚡ <strong>No major issues detected</strong></td></tr>
</table>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
This PR contains the following updates:
7.1.7→7.2.0Release Notes
postcss/postcss-selector-parser (postcss-selector-parser)
v7.2.0Compare Source
maxInputLengthoption, which rejects a selector longer than the limit before parsing itsper Selectors Level 4, onAttribute#sensitiveandAttribute#sensitiveFlag.[a=b s]previously leftinsensitive: falseand filed the flag inraws.insensitiveFlag(#327 by @abhu85)SECURITY.md: resource consumption caused by unbounded untrusted input is now handled as a regular bugstringifyProperty,valueToString,setPropertyAndEscape,appendToPropertyAndEscape,setPropertyWithoutEscape), the seventeen type guards, and theclone()overrides argument (#231)parser(fn, { maxInputLength })and the other options take effect there as documented (#345 by @Aurantium-47)rawSpaceBeforeandrawSpaceAfter(#356 by @Aschenbath).a\\.bparses as two classes (#354 by @wozhenbang2004)valuesetter already did (#349 by @SAY-5)valuesetter, and replace a staleraws.valueon assignment (#326 by @mahirhir)$in an attribute name inside a preprocessor interpolation, so[#{$attr}]in SCSS and[@{attr}]in Less round-trip (#336 by @theRizwan)TypeErroror emitting the literal textundefined(#335 by @theRizwan)const { process } = parser()(#145)Behaviour notes
classNameandidvalues are escaped when passed to a constructor or assigned throughvalue, so an already-escaped value is now escaped twice.setPropertyWithoutEscape()is the escape hatch.[a=b s]setssensitive: truerather than filing the flag inraws.insensitiveFlag. Serialization is byte-identical fori,I,s,Sand non-standard flags.SelectorandRootemit their ownrawSpaceBeforeandrawSpaceAfter, which changes serialization for ASTs that set them.TypeErroror serializing the textundefined:[ns|*]and[ * ]are affected. A trailing*,$,^,~or|after a valid name is dropped, as[href=]already was.v7.1.8Compare Source
cssescdependency with an internal copy, whose redundant space removal is linearConfiguration
📅 Schedule: (UTC)
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate CLI.
Failed to update PR description
PR Reviewer Guide 🔍
Here are some key observations to aid the review process: