Changeset 260335 in webkit
- Timestamp:
- Apr 19, 2020 6:46:15 AM (4 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r260319 r260335 1 2020-04-19 Emilio Cobos Álvarez <emilio@crisal.io> 2 3 Fix the logic to decide whether a property is enumerated in a computed style declaration. 4 https://bugs.webkit.org/show_bug.cgi?id=210695 5 6 Reviewed by Antti Koivisto. 7 8 Import the test from 9 https://github.com/web-platform-tests/wpt/pull/23088. One subtest is 10 failing, separate bug. 11 12 * web-platform-tests/css/cssom/getComputedStyle-logical-enumeration-expected.txt: Added. 13 * web-platform-tests/css/cssom/getComputedStyle-logical-enumeration.html: Added. 14 1 15 2020-04-18 Antti Koivisto <antti@apple.com> 2 16 -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt
r259006 r260335 28 28 PASS background-size 29 29 PASS baseline-shift 30 PASS border-block 31 PASS border-block-color 32 PASS border-block-end 33 PASS border-block-start 34 PASS border-block-style 35 PASS border-block-width 30 PASS block-size 31 PASS border-block-end-color 32 PASS border-block-end-style 33 PASS border-block-end-width 34 PASS border-block-start-color 35 PASS border-block-start-style 36 PASS border-block-start-width 36 37 PASS border-bottom-color 37 38 PASS border-bottom-left-radius … … 45 46 PASS border-image-source 46 47 PASS border-image-width 47 PASS border-inline 48 PASS border-inline- color49 PASS border-inline-end 50 PASS border-inline-start 51 PASS border-inline-st yle52 PASS border-inline- width48 PASS border-inline-end-color 49 PASS border-inline-end-style 50 PASS border-inline-end-width 51 PASS border-inline-start-color 52 PASS border-inline-start-style 53 PASS border-inline-start-width 53 54 PASS border-left-color 54 55 PASS border-left-style … … 141 142 PASS image-orientation 142 143 PASS image-rendering 143 PASS inset-block 144 PASS inset-inline 144 PASS inline-size 145 PASS inset-block-end 146 PASS inset-block-start 147 PASS inset-inline-end 148 PASS inset-inline-start 145 149 PASS isolation 146 150 PASS justify-content … … 156 160 PASS list-style-position 157 161 PASS list-style-type 158 PASS margin-block 162 PASS margin-block-end 163 PASS margin-block-start 159 164 PASS margin-bottom 160 PASS margin-inline 165 PASS margin-inline-end 166 PASS margin-inline-start 161 167 PASS margin-left 162 168 PASS margin-right … … 167 173 PASS mask 168 174 PASS mask-type 175 PASS max-block-size 169 176 PASS max-height 177 PASS max-inline-size 170 178 PASS max-width 179 PASS min-block-size 171 180 PASS min-height 181 PASS min-inline-size 172 182 PASS min-width 173 183 PASS mix-blend-mode … … 184 194 PASS overflow-x 185 195 PASS overflow-y 186 PASS padding-block 196 PASS padding-block-end 197 PASS padding-block-start 187 198 PASS padding-bottom 188 PASS padding-inline 199 PASS padding-inline-end 200 PASS padding-inline-start 189 201 PASS padding-left 190 202 PASS padding-right -
trunk/LayoutTests/platform/ios/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt
r259006 r260335 28 28 PASS background-size 29 29 PASS baseline-shift 30 PASS border-block 31 PASS border-block-color 32 PASS border-block-end 33 PASS border-block-start 34 PASS border-block-style 35 PASS border-block-width 30 PASS block-size 31 PASS border-block-end-color 32 PASS border-block-end-style 33 PASS border-block-end-width 34 PASS border-block-start-color 35 PASS border-block-start-style 36 PASS border-block-start-width 36 37 PASS border-bottom-color 37 38 PASS border-bottom-left-radius … … 45 46 PASS border-image-source 46 47 PASS border-image-width 47 PASS border-inline 48 PASS border-inline- color49 PASS border-inline-end 50 PASS border-inline-start 51 PASS border-inline-st yle52 PASS border-inline- width48 PASS border-inline-end-color 49 PASS border-inline-end-style 50 PASS border-inline-end-width 51 PASS border-inline-start-color 52 PASS border-inline-start-style 53 PASS border-inline-start-width 53 54 PASS border-left-color 54 55 PASS border-left-style … … 141 142 PASS image-orientation 142 143 PASS image-rendering 143 PASS inset-block 144 PASS inset-inline 144 PASS inline-size 145 PASS inset-block-end 146 PASS inset-block-start 147 PASS inset-inline-end 148 PASS inset-inline-start 145 149 PASS isolation 146 150 PASS justify-content … … 156 160 PASS list-style-position 157 161 PASS list-style-type 158 PASS margin-block 162 PASS margin-block-end 163 PASS margin-block-start 159 164 PASS margin-bottom 160 PASS margin-inline 165 PASS margin-inline-end 166 PASS margin-inline-start 161 167 PASS margin-left 162 168 PASS margin-right … … 167 173 PASS mask 168 174 PASS mask-type 175 PASS max-block-size 169 176 PASS max-height 177 PASS max-inline-size 170 178 PASS max-width 179 PASS min-block-size 171 180 PASS min-height 181 PASS min-inline-size 172 182 PASS min-width 173 183 PASS mix-blend-mode … … 184 194 PASS overflow-x 185 195 PASS overflow-y 186 PASS padding-block 196 PASS padding-block-end 197 PASS padding-block-start 187 198 PASS padding-bottom 188 PASS padding-inline 199 PASS padding-inline-end 200 PASS padding-inline-start 189 201 PASS padding-left 190 202 PASS padding-right -
trunk/Source/WebCore/ChangeLog
r260319 r260335 1 2020-04-19 Emilio Cobos Álvarez <emilio@crisal.io> 2 3 Fix the logic to decide whether a property is enumerated in a computed style declaration. 4 https://bugs.webkit.org/show_bug.cgi?id=210695 5 6 Reviewed by Antti Koivisto. 7 8 Fix the logic to decide whether a property is enumerated in a computed 9 style declaration. 10 11 Logical properties don't need stylebuilder code, but still should be 12 generated. Using the specification->category for this seems a bit 13 hacky, but unclear if it's worse than adding a new flag. 14 15 Tests: fast/css/getComputedStyle/computed-style-enumeration.html 16 imported/w3c/web-platform-tests/css/cssom/getComputedStyle-logical-enumeration.html 17 18 * css/makeprop.pl: 19 (skippedFromComputedStyle): 20 (isLogical): 21 (sortWithPrefixedPropertiesLast): 22 1 23 2020-04-18 Antti Koivisto <antti@apple.com> 2 24 -
trunk/Source/WebCore/css/makeprop.pl
r259720 r260335 32 32 use JSON::PP; 33 33 34 sub isLogical; 35 sub skippedFromComputedStyle; 36 sub isPropertyEnabled($$); 34 37 sub addProperty($$); 35 sub isPropertyEnabled($$);36 38 sub removeInactiveCodegenProperties($$); 37 39 … … 150 152 151 153 $propertyValue->{"codegen-properties"} = $matching_codegen_options; 154 } 155 156 sub skippedFromComputedStyle 157 { 158 my $name = shift; 159 160 if (exists($propertiesWithStyleBuilderOptions{$name}{"skip-builder"}) and not isLogical($name)) { 161 return 1; 162 } 163 164 if (grep { $_ eq $name } @internalProprerties) { 165 return 1; 166 } 167 168 if (exists($propertiesWithStyleBuilderOptions{$name}{"longhands"})) { 169 my @longhands = @{$propertiesWithStyleBuilderOptions{$name}{"longhands"}}; 170 if (scalar @longhands != 1) { 171 # Skip properties if they have a non-internal longhand property. 172 foreach my $longhand (@longhands) { 173 if (!skippedFromComputedStyle($longhand)) { 174 return 1; 175 } 176 } 177 } 178 } 179 180 return 0; 181 } 182 183 184 sub isLogical 185 { 186 my $name = shift; 187 my $value = $propertiesHashRef->{$name}; 188 189 if (!exists($value->{"specification"})) { 190 return 0; 191 } 192 193 my $spec_properties = $value->{"specification"}; 194 if (!exists($spec_properties->{"category"})) { 195 return 0; 196 } 197 198 return $spec_properties->{"category"} eq "css-logical-props" 152 199 } 153 200 … … 517 564 return $a cmp $b; 518 565 } 566 519 567 foreach my $name (sort sortWithPrefixedPropertiesLast @names) { 520 next if (exists($propertiesWithStyleBuilderOptions{$name}{"skip-builder"})); 521 next if (grep { $_ eq $name } @internalProprerties); 522 523 # Skip properties if they have a non-internal longhand property. 524 if (exists($propertiesWithStyleBuilderOptions{$name}{"longhands"})) { 525 my @longhands = @{$propertiesWithStyleBuilderOptions{$name}{"longhands"}}; 526 if (scalar @longhands != 1) { 527 my $hasNonInternalLonghand = 0; 528 foreach my $longhand (@longhands) { 529 if (!exists($propertiesWithStyleBuilderOptions{$longhand}{"skip-builder"}) && !grep { $_ eq $longhand } @internalProprerties) { 530 $hasNonInternalLonghand = 1; 531 last; 532 } 533 } 534 if ($hasNonInternalLonghand) { 535 next; 536 } 537 } 538 } 539 568 next if skippedFromComputedStyle($name); 540 569 print HEADER " CSSProperty" . $nameToId{$name} . ",\n"; 541 570 $numComputedPropertyIDs += 1;
Note: See TracChangeset
for help on using the changeset viewer.