Upgrade stylo to 2024-09-02 (#33370)

* Upgrade stylo to 2024-09-02

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

* Fixup for https://phabricator.services.mozilla.com/D217308

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

* Fixup for https://phabricator.services.mozilla.com/D217626

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

* Fixup for https://phabricator.services.mozilla.com/D218488

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

* Fixup for https://phabricator.services.mozilla.com/D219537

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

* Update test expectations

Signed-off-by: Oriol Brufau <obrufau@igalia.com>

---------

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
This commit is contained in:
Oriol Brufau 2024-09-13 17:59:57 +02:00 committed by GitHub
parent 261d60e456
commit a76daaf04c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 68 additions and 63 deletions

View file

@ -3,11 +3,16 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use style::color::{AbsoluteColor, ColorSpace};
use style::values::animated::{Animate, Procedure, ToAnimatedValue};
use style::properties::style_structs::Font;
use style::properties::ComputedValues;
use style::values::animated::{Animate, Context, Procedure, ToAnimatedValue};
fn interpolate_color(from: AbsoluteColor, to: AbsoluteColor, progress: f64) -> AbsoluteColor {
let from = from.to_animated_value();
let to = to.to_animated_value();
let context = Context {
style: &ComputedValues::initial_values_with_font_override(Font::initial_values()),
};
let from = from.to_animated_value(&context);
let to = to.to_animated_value(&context);
AbsoluteColor::from_animated_value(
from.animate(&to, Procedure::Interpolate { progress })
.unwrap(),

View file

@ -134,7 +134,7 @@ fn test_report_error_stylesheet() {
(
14,
52,
"Unsupported keyframe property declaration: 'margin: 0 invalid 0;'",
"Unsupported property declaration: 'margin: 0 invalid 0;'",
),
]);