mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-08 06:09:58 +00:00
LibWeb: Ignore non-animatable properties in keyframes
Gains us 21 WPT tests
This commit is contained in:
parent
ed0b741a26
commit
2447b8a759
Notes:
github-actions[bot]
2025-11-02 22:55:29 +00:00
Author: https://github.com/Calme1709
Commit: 2447b8a759
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6642
Reviewed-by: https://github.com/AtkinsSJ ✅
3 changed files with 166 additions and 0 deletions
|
|
@ -2778,6 +2778,9 @@ void StyleComputer::make_rule_cache_for_cascade_origin(CascadeOrigin cascade_ori
|
||||||
auto key = static_cast<u64>(keyframe.key().value() * Animations::KeyframeEffect::AnimationKeyFrameKeyScaleFactor);
|
auto key = static_cast<u64>(keyframe.key().value() * Animations::KeyframeEffect::AnimationKeyFrameKeyScaleFactor);
|
||||||
auto const& keyframe_style = *keyframe.style();
|
auto const& keyframe_style = *keyframe.style();
|
||||||
for (auto const& it : keyframe_style.properties()) {
|
for (auto const& it : keyframe_style.properties()) {
|
||||||
|
if (!is_animatable_property(it.property_id))
|
||||||
|
continue;
|
||||||
|
|
||||||
// Unresolved properties will be resolved in collect_animation_into()
|
// Unresolved properties will be resolved in collect_animation_into()
|
||||||
for_each_property_expanding_shorthands(it.property_id, it.value, [&](PropertyID shorthand_id, StyleValue const& shorthand_value) {
|
for_each_property_expanding_shorthands(it.property_id, it.value, [&](PropertyID shorthand_id, StyleValue const& shorthand_value) {
|
||||||
animated_properties.set(shorthand_id);
|
animated_properties.set(shorthand_id);
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,131 @@
|
||||||
|
Harness status: OK
|
||||||
|
|
||||||
|
Found 126 tests
|
||||||
|
|
||||||
|
126 Pass
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-duration> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-duration> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-duration> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-duration> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (-0.3) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (0) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (0.3) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (0.5) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (0.6) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (1) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-duration> from [1s] to [2s] at (1.5) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (-0.3) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (0) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (0.3) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (0.5) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (0.6) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (1) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-duration> from [1s] to [2s] at (1.5) should be [0s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-delay> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-delay> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions: property <transition-delay> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (-0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (0) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (0.3) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (0.5) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (0.6) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (1) should be [2s]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-delay> from [1s] to [2s] at (1.5) should be [2s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (-0.3) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (0) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (0.3) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (0.5) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (0.6) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (1) should be [0s]
|
||||||
|
Pass CSS Animations: property <transition-delay> from [1s] to [2s] at (1.5) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (-0.3) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (0) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (0.3) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (0.5) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (0.6) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (1) should be [0s]
|
||||||
|
Pass Web Animations: property <transition-delay> from [1s] to [2s] at (1.5) should be [0s]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (-0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (0) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (0.5) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (0.6) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (1) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-behavior:allow-discrete: property <transition-property> from [color] to [background-color] at (1.5) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (-0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (0) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (0.5) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (0.6) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (1) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <transition-property> from [color] to [background-color] at (1.5) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (-0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (0) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (0.5) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (0.6) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (1) should be [background-color]
|
||||||
|
Pass CSS Transitions: property <transition-property> from [color] to [background-color] at (1.5) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (-0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (0) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (0.3) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (0.5) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (0.6) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (1) should be [background-color]
|
||||||
|
Pass CSS Transitions with transition: all: property <transition-property> from [color] to [background-color] at (1.5) should be [background-color]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (-0.3) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (0) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (0.3) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (0.5) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (0.6) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (1) should be [all]
|
||||||
|
Pass CSS Animations: property <transition-property> from [color] to [background-color] at (1.5) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (-0.3) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (0) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (0.3) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (0.5) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (0.6) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (1) should be [all]
|
||||||
|
Pass Web Animations: property <transition-property> from [color] to [background-color] at (1.5) should be [all]
|
||||||
|
|
@ -0,0 +1,32 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<link rel=author href="mailto:jarhar@chromium.org">
|
||||||
|
<link rel="help" href="https://www.w3.org/TR/css-transitions-1/#transition-duration-property">
|
||||||
|
<link rel="help" href="https://www.w3.org/TR/css-transitions-1/#transition-delay-property">
|
||||||
|
<link rel="help" href="https://www.w3.org/TR/css-transitions-1/#transition-property-property">
|
||||||
|
<script src="../../resources/testharness.js"></script>
|
||||||
|
<script src="../../resources/testharnessreport.js"></script>
|
||||||
|
<script src="../../css/support/interpolation-testcommon.js"></script>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<script>
|
||||||
|
test_not_animatable({
|
||||||
|
property: 'transition-duration',
|
||||||
|
from: '1s',
|
||||||
|
to: '2s',
|
||||||
|
underlying: '0s',
|
||||||
|
});
|
||||||
|
|
||||||
|
test_not_animatable({
|
||||||
|
property: 'transition-delay',
|
||||||
|
from: '1s',
|
||||||
|
to: '2s',
|
||||||
|
underlying: '0s',
|
||||||
|
});
|
||||||
|
|
||||||
|
test_not_animatable({
|
||||||
|
property: 'transition-property',
|
||||||
|
from: 'color',
|
||||||
|
to: 'background-color',
|
||||||
|
underlying: 'all',
|
||||||
|
});
|
||||||
|
</script>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue