You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -41,7 +42,8 @@ This project adheres to [Semantic Versioning](https://semver.org/).
41
42
- Fix type errors in PHP strict mode (#664)
42
43
- Fix comment parsing to support multiple comments (#672)
43
44
- Fix undefined local variable in `CalcFunction::parse()` (#593)
44
-
- Fix PHP notice caused by parsing invalid color values having less than 6 characters (#485)
45
+
- Fix PHP notice caused by parsing invalid color values having less than 6
46
+
characters (#485)
45
47
- Fix (regression) failure to parse at-rules with strict parsing (#456)
46
48
47
49
@ziegenberg is a new contributor to this release and did a lot of the heavy
@@ -69,7 +71,8 @@ lifting. Thanks! :heart:
69
71
70
72
* Support for PHP 8.x
71
73
* PHPDoc annotations
72
-
* Allow usage of CSS variables inside color functions (by parsing them as regular functions)
74
+
* Allow usage of CSS variables inside color functions (by parsing them as
75
+
regular functions)
73
76
* Use PSR-12 code style
74
77
**No deprecations*
75
78
@@ -84,7 +87,10 @@ lifting. Thanks! :heart:
84
87
* Allow a file to end after an `@import`
85
88
* Preserve case of CSS variables as specced
86
89
* Allow identifiers to use escapes the same way as strings
87
-
* No longer use `eval` for the comparison in `getSelectorsBySpecificity`, in case it gets passed untrusted input (CVE-2020-13756). Also fixed in 8.3.1, 8.2.1, 8.1.1, 8.0.1, 7.0.4, 6.0.2, 5.2.1, 5.1.3, 5.0.9, 4.0.1, 3.0.1, 2.0.1, 1.0.1.
90
+
* No longer use `eval` for the comparison in `getSelectorsBySpecificity`, in
91
+
case it gets passed untrusted input (CVE-2020-13756). Also fixed in 8.3.1,
* Prevent an infinite loop when parsing invalid grid line names
89
95
* Remove invalid unit `vm`
90
96
* Retain rule order after expanding shorthands
@@ -96,28 +102,37 @@ lifting. Thanks! :heart:
96
102
97
103
## 8.3.0 (2019-02-22)
98
104
99
-
* Refactor parsing logic to mostly reside in the class files whose data structure is to be parsed (this should eventually allow us to unit-test specific parts of the parsing logic individually).
100
-
* Fix error in parsing `calc` expessions when the first operand is a negative number, thanks to @raxbg.
101
-
* Support parsing CSS4 colors in hex notation with alpha values, thanks to @raxbg.
105
+
* Refactor parsing logic to mostly reside in the class files whose data
106
+
structure is to be parsed (this should eventually allow us to unit-test
107
+
specific parts of the parsing logic individually).
108
+
* Fix error in parsing `calc` expessions when the first operand is a negative
109
+
number, thanks to @raxbg.
110
+
* Support parsing CSS4 colors in hex notation with alpha values, thanks to
111
+
@raxbg.
102
112
* Swallow more errors in lenient mode, thanks to @raxbg.
103
-
* Allow specifying arbitrary strings to output before and after declaration blocks, thanks to @westonruter.
113
+
* Allow specifying arbitrary strings to output before and after declaration
114
+
blocks, thanks to @westonruter.
104
115
**No backwards-incompatible changes*
105
116
**No deprecations*
106
117
107
118
## 8.2.0 (2018-07-13)
108
119
109
120
* Support parsing `calc()`, thanks to @raxbg.
110
121
* Support parsing grid-lines, again thanks to @raxbg.
111
-
* Support parsing legacy IE filters (`progid:`) in lenient mode, thanks to @FMCorz
122
+
* Support parsing legacy IE filters (`progid:`) in lenient mode, thanks to
123
+
@FMCorz
112
124
* Performance improvements parsing large files, again thanks to @FMCorz
113
125
**No backwards-incompatible changes*
114
126
**No deprecations*
115
127
116
128
## 8.1.0 (2016-07-19)
117
129
118
-
* Comments are no longer silently ignored but stored with the object with which they appear (no render support, though). Thanks to @FMCorz.
119
-
* The IE hacks using `\0` and `\9` can now be parsed (and rendered) in lenient mode. Thanks (again) to @FMCorz.
120
-
* Media queries with or without spaces before the query are parsed. Still no *real* parsing support, though. Sorry…
130
+
* Comments are no longer silently ignored but stored with the object with which
131
+
they appear (no render support, though). Thanks to @FMCorz.
132
+
* The IE hacks using `\0` and `\9` can now be parsed (and rendered) in lenient
133
+
mode. Thanks (again) to @FMCorz.
134
+
* Media queries with or without spaces before the query are parsed. Still no
135
+
*real* parsing support, though. Sorry…
121
136
* PHPUnit is now listed as a dev-dependency in composer.json.
122
137
**No backwards-incompatible changes*
123
138
**No deprecations*
@@ -129,7 +144,8 @@ lifting. Thanks! :heart:
129
144
130
145
### Backwards-incompatible changes
131
146
132
-
* Unrecoverable parser errors throw an exception of type `Sabberworm\CSS\Parsing\SourceException` instead of `\Exception`.
147
+
* Unrecoverable parser errors throw an exception of type
148
+
`Sabberworm\CSS\Parsing\SourceException` instead of `\Exception`.
133
149
134
150
## 7.0.3 (2016-04-27)
135
151
@@ -139,7 +155,8 @@ lifting. Thanks! :heart:
139
155
140
156
## 7.0.2 (2016-02-11)
141
157
142
-
* 150 time performance boost thanks to @[ossinkine](https://github.com/ossinkine)
158
+
* 150 time performance boost thanks
159
+
to @[ossinkine](https://github.com/ossinkine)
143
160
**No backwards-incompatible changes*
144
161
**No deprecations*
145
162
@@ -156,7 +173,8 @@ lifting. Thanks! :heart:
156
173
157
174
### Backwards-incompatible changes
158
175
159
-
* The `Sabberworm\CSS\Value\String` class has been renamed to `Sabberworm\CSS\Value\CSSString`.
176
+
* The `Sabberworm\CSS\Value\String` class has been renamed to
177
+
`Sabberworm\CSS\Value\CSSString`.
160
178
161
179
## 6.0.1 (2015-08-24)
162
180
@@ -170,22 +188,27 @@ lifting. Thanks! :heart:
170
188
171
189
### Deprecations
172
190
173
-
* The parse() method replaces __toString with an optional argument (instance of the OutputFormat class)
191
+
* The parse() method replaces __toString with an optional argument (instance of
192
+
the OutputFormat class)
174
193
175
194
## 5.2.0 (2014-06-30)
176
195
177
-
* Support removing a selector from a declaration block using `$oBlock->removeSelector($mSelector)`
178
-
* Introduce a specialized exception (Sabberworm\CSS\Parsing\OuputException) for exceptions during output rendering
196
+
* Support removing a selector from a declaration block using
197
+
`$oBlock->removeSelector($mSelector)`
198
+
* Introduce a specialized exception (Sabberworm\CSS\Parsing\OuputException) for
199
+
exceptions during output rendering
179
200
180
201
**No deprecations*
181
202
182
203
#### Backwards-incompatible changes
183
204
184
-
* Outputting a declaration block that has no selectors throws an OuputException instead of outputting an invalid ` {…}` into the CSS document.
205
+
* Outputting a declaration block that has no selectors throws an OuputException
206
+
instead of outputting an invalid ` {…}` into the CSS document.
185
207
186
208
## 5.1.2 (2013-10-30)
187
209
188
-
* Remove the use of consumeUntil in comment parsing. This makes it possible to parse comments such as `/** Perfectly valid **/`
210
+
* Remove the use of consumeUntil in comment parsing. This makes it possible to
211
+
parse comments such as `/** Perfectly valid **/`
189
212
* Add fr relative size unit
190
213
* Fix some issues with HHVM
191
214
**No backwards-incompatible changes*
@@ -200,13 +223,15 @@ lifting. Thanks! :heart:
200
223
## 5.1.0 (2013-10-24)
201
224
202
225
* Performance enhancements by Michael M Slusarz
203
-
* More rescue entry points for lenient parsing (unexpected tokens between declaration blocks and unclosed comments)
226
+
* More rescue entry points for lenient parsing (unexpected tokens between
227
+
declaration blocks and unclosed comments)
204
228
**No backwards-incompatible changes*
205
229
**No deprecations*
206
230
207
231
## 5.0.8 (2013-08-15)
208
232
209
-
* Make default settings’ multibyte parsing option dependent on whether or not the mbstring extension is actually installed.
233
+
* Make default settings’ multibyte parsing option dependent on whether or not
234
+
the mbstring extension is actually installed.
210
235
**No backwards-incompatible changes*
211
236
**No deprecations*
212
237
@@ -224,7 +249,9 @@ lifting. Thanks! :heart:
224
249
225
250
## 5.0.5 (2013-04-17)
226
251
227
-
* Initial support for lenient parsing (setting this parser option will catch some exceptions internally and recover the parser’s state as neatly as possible).
252
+
* Initial support for lenient parsing (setting this parser option will catch
253
+
some exceptions internally and recover the parser’s state as neatly as
254
+
possible).
228
255
**No backwards-incompatible changes*
229
256
**No deprecations*
230
257
@@ -261,18 +288,22 @@ lifting. Thanks! :heart:
261
288
262
289
### Backwards-incompatible changes
263
290
264
-
*`Sabberworm\CSS\Value\Color`’s `__toString` method overrides `CSSList`’s to maybe return something other than `type(value, …)` (see above).
291
+
*`Sabberworm\CSS\Value\Color`’s `__toString` method overrides `CSSList`’s to
292
+
maybe return something other than `type(value, …)` (see above).
265
293
266
294
## 4.0.0 (2013-03-19)
267
295
268
296
* Support for more @-rules
269
-
* Generic interface `Sabberworm\CSS\Property\AtRule`, implemented by all @-rule classes
297
+
* Generic interface `Sabberworm\CSS\Property\AtRule`, implemented by all @-rule
298
+
classes
270
299
**No deprecations*
271
300
272
301
### Backwards-incompatible changes
273
302
274
303
*`Sabberworm\CSS\RuleSet\AtRule` renamed to `Sabberworm\CSS\RuleSet\AtRuleSet`
275
-
*`Sabberworm\CSS\CSSList\MediaQuery` renamed to `Sabberworm\CSS\RuleSet\CSSList\AtRuleBlockList` with differing semantics and API (which also works for other block-list-based @-rules like `@supports`).
304
+
*`Sabberworm\CSS\CSSList\MediaQuery` renamed to
305
+
`Sabberworm\CSS\RuleSet\CSSList\AtRuleBlockList` with differing semantics and
306
+
API (which also works for other block-list-based @-rules like `@supports`).
276
307
277
308
## 3.0.0 (2013-03-06)
278
309
@@ -281,19 +312,32 @@ lifting. Thanks! :heart:
281
312
282
313
### Backwards-incompatible changes
283
314
284
-
* All properties (like whether or not to use `mb_`-functions, which default charset to use and – new – whether or not to be forgiving when parsing) are now encapsulated in an instance of `Sabberworm\CSS\Settings` which can be passed as the second argument to `Sabberworm\CSS\Parser->__construct()`.
285
-
* Specifying a charset as the second argument to `Sabberworm\CSS\Parser->__construct()` is no longer supported. Use `Sabberworm\CSS\Settings::create()->withDefaultCharset('some-charset')` instead.
286
-
* Setting `Sabberworm\CSS\Parser->bUseMbFunctions` has no effect. Use `Sabberworm\CSS\Settings::create()->withMultibyteSupport(true/false)` instead.
287
-
*`Sabberworm\CSS\Parser->parse()` may throw a `Sabberworm\CSS\Parsing\UnexpectedTokenException` when in strict parsing mode.
315
+
* All properties (like whether or not to use `mb_`-functions, which default
316
+
charset to use and – new – whether or not to be forgiving when parsing) are
317
+
now encapsulated in an instance of `Sabberworm\CSS\Settings` which can be
318
+
passed as the second argument to `Sabberworm\CSS\Parser->__construct()`.
319
+
* Specifying a charset as the second argument to
320
+
`Sabberworm\CSS\Parser->__construct()` is no longer supported. Use
`Sabberworm\CSS\Parsing\UnexpectedTokenException` when in strict parsing mode.
288
327
289
328
## 2.0.0 (2013-01-29)
290
329
291
330
* Allow multiple rules of the same type per rule set
292
331
293
332
### Backwards-incompatible changes
294
333
295
-
*`Sabberworm\CSS\RuleSet->getRules()` returns an index-based array instead of an associative array. Use `Sabberworm\CSS\RuleSet->getRulesAssoc()` (which eliminates duplicate rules and lets the later rule of the same name win).
296
-
*`Sabberworm\CSS\RuleSet->removeRule()` works as it did before except when passed an instance of `Sabberworm\CSS\Rule\Rule`, in which case it would only remove the exact rule given instead of all the rules of the same type. To get the old behaviour, use `Sabberworm\CSS\RuleSet->removeRule($oRule->getRule()`;
334
+
*`Sabberworm\CSS\RuleSet->getRules()` returns an index-based array instead of
335
+
an associative array. Use `Sabberworm\CSS\RuleSet->getRulesAssoc()` (which
336
+
eliminates duplicate rules and lets the later rule of the same name win).
337
+
*`Sabberworm\CSS\RuleSet->removeRule()` works as it did before except when
338
+
passed an instance of `Sabberworm\CSS\Rule\Rule`, in which case it would only
339
+
remove the exact rule given instead of all the rules of the same type. To get
340
+
the old behaviour, use `Sabberworm\CSS\RuleSet->removeRule($oRule->getRule()`;
0 commit comments