File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
packages/stylesheet/src/transform Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " @react-pdf/stylesheet " : patch
3+ ---
4+
5+ feat: accept commas between transformations
Original file line number Diff line number Diff line change 11const parse = ( transformString ) => {
2- const transforms = transformString . trim ( ) . split ( / \) | \) / ) ;
2+ const transforms = transformString . trim ( ) . split ( / \) [ , ] | \) / ) ;
33
44 // Handle "initial", "inherit", "unset".
55 if ( transforms . length === 1 ) {
@@ -15,7 +15,7 @@ const parse = (transformString) => {
1515 const [ name , rawValue ] = transform . split ( '(' ) ;
1616 const splitChar = rawValue . indexOf ( ',' ) >= 0 ? ',' : ' ' ;
1717 const value = rawValue . split ( splitChar ) . map ( ( val ) => val . trim ( ) ) ;
18- parsed . push ( { operation : name , value } ) ;
18+ parsed . push ( { operation : name . trim ( ) , value } ) ;
1919 }
2020 }
2121
You can’t perform that action at this time.
0 commit comments