Prevent the addition of space in type() with + (#19516)

Co-authored-by: fisker Cheung <lionkay@gmail.com>
This commit is contained in:
Andrew Hudsonandfisker Cheung authored and GitHub committed 2026-07-09 12:56:57 +08:00
1 parent 3d063b57b1
commit a4e6f7a026
5 files changed
+114

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
#### Prevent addition space in `type()` with `+` (#19516 by @bigandy)
This fixes the addition space before `+` in CSS `type()` declaration. For example `type(<number>+)` was being converted into `type(<number> +)` which is invalid CSS and does not work.
<!-- prettier-ignore -->
```css
/* Input */
div {
border-radius: attr(br type(<length>+));
}
/* Prettier stable */
div {
border-radius: attr(br type(<length> +));
}
/* Prettier main */
div {
border-radius: attr(br type(<length>+));
}
```