We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e9732d commit 468da34Copy full SHA for 468da34
lib/Sabberworm/CSS/Value/Size.php
@@ -41,7 +41,7 @@ public static function parse(ParserState $oParserState, $bIsColorComponent = fal
41
$aSizeUnits = self::getSizeUnits();
42
$iMaxSizeUnitLength = max(array_keys($aSizeUnits));
43
44
- if ( preg_match( '/^[a-zA-Z0-9%]+/', $oParserState->peek($iMaxSizeUnitLength), $matches ) ) {
+ if ( preg_match( '/^(%|[a-zA-Z0-9]+)/', $oParserState->peek($iMaxSizeUnitLength), $matches ) ) {
45
$sUnit = strtolower($matches[0]);
46
$iUnitLength = strlen($sUnit);
47
0 commit comments