@@ -135,7 +135,6 @@ protected function css2( MatcherFactory $matcherFactory ) {
135135 $ props ['clip ' ] = new Alternative ( [
136136 $ auto , new FunctionMatcher ( 'rect ' , Quantifier::hash ( $ autoLength , 4 , 4 ) ),
137137 ] );
138- $ props ['visibility ' ] = new KeywordMatcher ( [ 'visible ' , 'hidden ' , 'collapse ' ] );
139138
140139 // https://www.w3.org/TR/2011/REC-CSS2-20110607/generate.html
141140 $ props ['list-style-type ' ] = new KeywordMatcher ( [
@@ -197,7 +196,7 @@ protected function css2( MatcherFactory $matcherFactory ) {
197196
198197 /**
199198 * Properties for CSS Display Module Level 3
200- * @see https://www.w3.org/TR/2019 /CR-css-display-3-20190711 /
199+ * @see https://www.w3.org/TR/2023 /CR-css-display-3-20230330 /
201200 * @param MatcherFactory $matcherFactory Factory for Matchers
202201 * @return Matcher[] Array mapping declaration names (lowercase) to Matchers for the values
203202 */
@@ -236,6 +235,10 @@ protected function cssDisplay3( MatcherFactory $matcherFactory ) {
236235 ] ),
237236 ] );
238237
238+ $ props ['visibility ' ] = new KeywordMatcher ( [ 'visible ' , 'hidden ' , 'collapse ' ] );
239+
240+ $ props ['order ' ] = $ matcherFactory ->integer ();
241+
239242 $ this ->cache [__METHOD__ ] = $ props ;
240243 return $ props ;
241244 }
@@ -945,7 +948,6 @@ protected function cssFlexbox3( MatcherFactory $matcherFactory ) {
945948 ] );
946949 $ props ['flex-wrap ' ] = new KeywordMatcher ( [ 'nowrap ' , 'wrap ' , 'wrap-reverse ' ] );
947950 $ props ['flex-flow ' ] = UnorderedGroup::someOf ( [ $ props ['flex-direction ' ], $ props ['flex-wrap ' ] ] );
948- $ props ['order ' ] = $ matcherFactory ->integer ();
949951 $ props ['flex-grow ' ] = $ matcherFactory ->number ();
950952 $ props ['flex-shrink ' ] = $ matcherFactory ->number ();
951953 $ props ['flex-basis ' ] = new Alternative ( [
@@ -968,6 +970,11 @@ protected function cssFlexbox3( MatcherFactory $matcherFactory ) {
968970 $ props ['align-self ' ] = $ align ['align-self ' ];
969971 $ props ['align-content ' ] = $ align ['align-content ' ];
970972
973+ // 'order' was copied into display-3 in CR 2023-03-30
974+ // Removed from flexbox in the ED as of 2025-03-10, it can be removed
975+ // here once we update our flexbox version.
976+ $ props ['order ' ] = $ this ->cssDisplay3 ( $ matcherFactory )['order ' ];
977+
971978 $ this ->cache [__METHOD__ ] = $ props ;
972979 return $ props ;
973980 }
@@ -1490,10 +1497,6 @@ protected function cssGrid1( MatcherFactory $matcherFactory ) {
14901497 $ props ['justify-content ' ] = $ align ['justify-content ' ];
14911498 $ props ['align-content ' ] = $ align ['align-content ' ];
14921499
1493- // Grid uses Flexbox's order property too. Copying is ok as long as
1494- // it's the identical object.
1495- $ props ['order ' ] = $ this ->cssFlexbox3 ( $ matcherFactory )['order ' ];
1496-
14971500 $ this ->cache [__METHOD__ ] = $ props ;
14981501 return $ props ;
14991502 }
0 commit comments