V9.2.0: New features and deprecations
·
38 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
Added
- Add
OutputFormat::setSpaceAroundSelectorCombinator()(#1504) - Add support for escaped quotes in the selectors (#1485, #1489)
- Provide line number in exception message for mismatched parentheses in
selector (#1435) - Add support for CSS container queries (#1400)
Changed
RuleSet\RuleContaineris renamed toRuleSet\DeclarationList(#1530, #1539)- Methods like
setRule()inRuleSetandDeclarationBlockhave been renamed
tosetDeclaration(), etc. (#1521) Rule\Ruleclass is renamed toProperty\Declaration
(#1508, #1512, #1513, #1522)Rule::setRule()andgetRule()are replaced withsetPropertyName()and
getPropertyName()(#1506)Selectoris now represented as a sequence ofSelector\Componentobjects
which can be accessed viagetComponents(), manipulated individually, or set
viasetComponents()(#1478, #1486, #1487, #1488, #1494, #1496, #1536, #1537)Selector::setSelector()andSelectorconstructor will now throw exception
upon provision of an invalid selectior (#1498, #1502)- Clean up extra whitespace in CSS selector (#1398)
- The array keys passed to
DeclarationBlock::setSelectors()are no longer
preserved (#1407)
Deprecated
RuleSet\RuleContaineris deprecated; useRuleSet\DeclarationListinstead
(#1530)- Methods like
setRule()inRuleSetandDeclarationBlockare deprecated;
there are direct replacements such assetDeclaration()(#1521) Rule\Ruleclass is deprecated;Property\Declarationis a direct
replacement (#1508)Rule::setRule()andgetRule()are deprecated and replaced with
setPropertyName()andgetPropertyName()(#1506, #1519)
Fixed
- Do not escape characters that do not need escaping in CSS string (#1444)
- Reject selector comprising only whitespace (#1433)
- Improve recovery parsing when a rogue
}is encountered (#1425, #1426) - Parse comment(s) immediately preceding a selector (#1421, #1424)
- Parse consecutive comments (#1421)
- Support attribute selectors with values containing commas in
DeclarationBlock::setSelectors()(#1419) - Allow
removeDeclarationBlockBySelector()to be order-insensitve (#1406) - Fix parsing of
calcexpressions when a newline immediately precedes or
follows a+or-operator (#1399) - Use typesafe versions of PHP functions (#1379, #1380, #1382, #1383, #1384)
New Contributors
- @scq made their first contribution in #1399
- @8ctopus made their first contribution in #1398
- @samuil-banti-wpenigne made their first contribution in #1485
Full Changelog: v9.1.0...v9.2.0