diff options
33 files changed, 70 insertions, 106 deletions
diff --git a/Cargo.lock b/Cargo.lock index 6ed60471e95..d87c6078811 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1285,7 +1285,7 @@ dependencies = [ [[package]] name = "derive_common" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "darling", "proc-macro2", @@ -1415,6 +1415,14 @@ dependencies = [ ] [[package]] +name = "dom" +version = "0.0.1" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" +dependencies = [ + "bitflags 2.6.0", +] + +[[package]] name = "dom_struct" version = "0.0.1" dependencies = [ @@ -3727,13 +3735,14 @@ dependencies = [ [[package]] name = "malloc_size_of" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "accountable-refcell", "app_units", "content-security-policy", "crossbeam-channel", "cssparser", + "dom", "euclid", "http", "indexmap", @@ -4217,12 +4226,6 @@ dependencies = [ ] [[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] name = "nohash-hasher" version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -5199,6 +5202,7 @@ dependencies = [ "data-url", "deny_public_fields", "devtools_traits", + "dom", "dom_struct", "domobject_derive", "embedder_traits", @@ -5388,7 +5392,7 @@ dependencies = [ [[package]] name = "selectors" version = "0.24.0" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "bitflags 2.6.0", "cssparser", @@ -5676,9 +5680,8 @@ dependencies = [ [[package]] name = "servo_arc" version = "0.2.0" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ - "nodrop", "serde", "stable_deref_trait", ] @@ -5686,7 +5689,7 @@ dependencies = [ [[package]] name = "servo_atoms" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "string_cache", "string_cache_codegen", @@ -5874,7 +5877,7 @@ checksum = "38b58827f4464d87d377d175e90bf58eb00fd8716ff0a62f80356b5e61555d0d" [[package]] name = "size_of_test" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "static_assertions", ] @@ -6015,7 +6018,7 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "static_prefs" version = "0.1.0" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" [[package]] name = "strict-num" @@ -6052,7 +6055,7 @@ dependencies = [ [[package]] name = "style" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "app_units", "arrayvec", @@ -6061,6 +6064,7 @@ dependencies = [ "byteorder", "cssparser", "derive_more", + "dom", "encoding_rs", "euclid", "fxhash", @@ -6110,7 +6114,7 @@ dependencies = [ [[package]] name = "style_config" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "lazy_static", ] @@ -6118,7 +6122,7 @@ dependencies = [ [[package]] name = "style_derive" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "darling", "derive_common", @@ -6149,7 +6153,7 @@ dependencies = [ [[package]] name = "style_traits" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "app_units", "bitflags 2.6.0", @@ -6519,7 +6523,7 @@ dependencies = [ [[package]] name = "to_shmem" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "cssparser", "servo_arc", @@ -6532,7 +6536,7 @@ dependencies = [ [[package]] name = "to_shmem_derive" version = "0.0.1" -source = "git+https://github.com/servo/stylo?branch=2024-05-31#f6cb33f86468ba272d5329f64f78a75df8e9fcbe" +source = "git+https://github.com/servo/stylo?branch=2024-07-16#eceb838e855e3b73a28df602b69494899f6d168b" dependencies = [ "darling", "derive_common", diff --git a/Cargo.toml b/Cargo.toml index e011617bb31..a8af06a3f99 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -75,7 +75,7 @@ keyboard-types = "0.7" lazy_static = "1.5" libc = "0.2" log = "0.4" -malloc_size_of = { git = "https://github.com/servo/stylo", branch = "2024-05-31", features = ["servo"] } +malloc_size_of = { git = "https://github.com/servo/stylo", branch = "2024-07-16", features = ["servo"] } malloc_size_of_derive = "0.1" mime = "0.3.13" mime_guess = "2.0.5" @@ -97,30 +97,31 @@ rustls = { version = "0.21.12", features = ["dangerous_configuration"] } rustls-pemfile = "1.0.4" script_layout_interface = { path = "components/shared/script_layout" } script_traits = { path = "components/shared/script" } -selectors = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } +selectors = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } serde = "1.0.204" serde_bytes = "0.11" serde_json = "1.0" servo-media = { git = "https://github.com/servo/media" } servo-media-dummy = { git = "https://github.com/servo/media" } servo-media-gstreamer = { git = "https://github.com/servo/media" } -servo_arc = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } -servo_atoms = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } -size_of_test = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } +servo_arc = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } +servo_atoms = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } +size_of_test = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } smallbitvec = "2.5.3" smallvec = "1.13" sparkle = "0.1.26" string_cache = "0.8" string_cache_codegen = "0.5" -style = { git = "https://github.com/servo/stylo", branch = "2024-05-31", features = ["servo"] } -style_config = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } -style_traits = { git = "https://github.com/servo/stylo", branch = "2024-05-31", features = ["servo"] } +style = { git = "https://github.com/servo/stylo", branch = "2024-07-16", features = ["servo"] } +style_config = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } +style_dom = { git = "https://github.com/servo/stylo", package = "dom", branch = "2024-07-16" } +style_traits = { git = "https://github.com/servo/stylo", branch = "2024-07-16", features = ["servo"] } surfman = { version = "0.9", features = ["chains"] } syn = { version = "2", default-features = false, features = ["clone-impls", "derive", "parsing"] } synstructure = "0.13" thin-vec = "0.2.13" time = "0.1.41" -to_shmem = { git = "https://github.com/servo/stylo", branch = "2024-05-31" } +to_shmem = { git = "https://github.com/servo/stylo", branch = "2024-07-16" } tokio = "1" tokio-rustls = "0.24" tungstenite = "0.20" diff --git a/components/layout/block.rs b/components/layout/block.rs index 4ecdc44d2d1..620f45b9c36 100644 --- a/components/layout/block.rs +++ b/components/layout/block.rs @@ -3007,15 +3007,15 @@ pub trait ISizeAndMarginsComputer { ) => { // servo_left, servo_right, and servo_center are used to implement // the "align descendants" rule in HTML5 § 14.2. - if block_align == TextAlign::ServoCenter { + if block_align == TextAlign::MozCenter { // Ignore any existing margins, and make the inline-start and // inline-end margins equal. let margin = (available_inline_size - inline_size).scale_by(0.5); (margin, inline_size, margin) } else { let ignore_end_margin = match block_align { - TextAlign::ServoLeft => block_mode.is_bidi_ltr(), - TextAlign::ServoRight => !block_mode.is_bidi_ltr(), + TextAlign::MozLeft => block_mode.is_bidi_ltr(), + TextAlign::MozRight => !block_mode.is_bidi_ltr(), _ => parent_has_same_direction, }; if ignore_end_margin { diff --git a/components/layout/inline.rs b/components/layout/inline.rs index 03e5fc8b01f..6d8f49d34d0 100644 --- a/components/layout/inline.rs +++ b/components/layout/inline.rs @@ -1035,13 +1035,13 @@ impl InlineFlow { let is_ltr = fragments.fragments[0].style().writing_mode.is_bidi_ltr(); let line_align = match (line_align, is_ltr) { (TextAlign::Left, true) | - (TextAlign::ServoLeft, true) | + (TextAlign::MozLeft, true) | (TextAlign::Right, false) | - (TextAlign::ServoRight, false) => TextAlign::Start, + (TextAlign::MozRight, false) => TextAlign::Start, (TextAlign::Left, false) | - (TextAlign::ServoLeft, false) | + (TextAlign::MozLeft, false) | (TextAlign::Right, true) | - (TextAlign::ServoRight, true) => TextAlign::End, + (TextAlign::MozRight, true) => TextAlign::End, _ => line_align, }; @@ -1053,11 +1053,11 @@ impl InlineFlow { InlineFlow::justify_inline_fragments(fragments, line, slack_inline_size) }, TextAlign::Justify | TextAlign::Start => {}, - TextAlign::Center | TextAlign::ServoCenter => { + TextAlign::Center | TextAlign::MozCenter => { inline_start_position_for_fragment += slack_inline_size.scale_by(0.5) }, TextAlign::End => inline_start_position_for_fragment += slack_inline_size, - TextAlign::Left | TextAlign::ServoLeft | TextAlign::Right | TextAlign::ServoRight => { + TextAlign::Left | TextAlign::MozLeft | TextAlign::Right | TextAlign::MozRight => { unreachable!() }, } diff --git a/components/layout_2020/flow/inline/mod.rs b/components/layout_2020/flow/inline/mod.rs index b5f508e6f29..3c480466ff7 100644 --- a/components/layout_2020/flow/inline/mod.rs +++ b/components/layout_2020/flow/inline/mod.rs @@ -932,16 +932,16 @@ impl<'a, 'b> InlineFormattingContextState<'a, 'b> { let text_align = match text_align_keyword { TextAlignKeyword::Start => TextAlign::Start, - TextAlignKeyword::Center | TextAlignKeyword::ServoCenter => TextAlign::Center, + TextAlignKeyword::Center | TextAlignKeyword::MozCenter => TextAlign::Center, TextAlignKeyword::End => TextAlign::End, - TextAlignKeyword::Left | TextAlignKeyword::ServoLeft => { + TextAlignKeyword::Left | TextAlignKeyword::MozLeft => { if style.writing_mode.line_left_is_inline_start() { TextAlign::Start } else { TextAlign::End } }, - TextAlignKeyword::Right | TextAlignKeyword::ServoRight => { + TextAlignKeyword::Right | TextAlignKeyword::MozRight => { if style.writing_mode.line_left_is_inline_start() { TextAlign::End } else { diff --git a/components/layout_2020/flow/mod.rs b/components/layout_2020/flow/mod.rs index 409313f79ac..ff99397c1a3 100644 --- a/components/layout_2020/flow/mod.rs +++ b/components/layout_2020/flow/mod.rs @@ -1478,13 +1478,9 @@ fn justify_self_alignment(containing_block: &ContainingBlock, free_space: Au) -> let style = containing_block.style; debug_assert!(free_space >= Au::zero()); match style.clone_text_align() { - TextAlignKeyword::ServoCenter => free_space / 2, - TextAlignKeyword::ServoLeft if !style.writing_mode.line_left_is_inline_start() => { - free_space - }, - TextAlignKeyword::ServoRight if style.writing_mode.line_left_is_inline_start() => { - free_space - }, + TextAlignKeyword::MozCenter => free_space / 2, + TextAlignKeyword::MozLeft if !style.writing_mode.line_left_is_inline_start() => free_space, + TextAlignKeyword::MozRight if style.writing_mode.line_left_is_inline_start() => free_space, _ => Au::zero(), } } diff --git a/components/layout_2020/style_ext.rs b/components/layout_2020/style_ext.rs index 20a89bedf28..dc3bcbf79fa 100644 --- a/components/layout_2020/style_ext.rs +++ b/components/layout_2020/style_ext.rs @@ -718,6 +718,7 @@ impl From<stylo::Display> for Display { is_list_item: packed.is_list_item(), }, stylo::DisplayInside::Flex => DisplayInside::Flex, + stylo::DisplayInside::Grid => todo!("Grid support is not yet implemented."), // These should not be values of DisplayInside, but oh well stylo::DisplayInside::None => return Display::None, diff --git a/components/script/Cargo.toml b/components/script/Cargo.toml index 0bf0e4958b8..524fe423c45 100644 --- a/components/script/Cargo.toml +++ b/components/script/Cargo.toml @@ -102,6 +102,7 @@ servo_url = { path = "../url" } smallvec = { workspace = true, features = ["union"] } sparkle = { workspace = true } style = { workspace = true } +style_dom = { workspace = true } style_traits = { workspace = true } swapper = "0.1" tempfile = "3" diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index d33a410c335..ab00d3e0131 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -58,7 +58,7 @@ use style::stylesheets::{CssRuleType, UrlExtraData}; use style::values::generics::NonNegative; use style::values::{computed, specified, AtomIdent, AtomString, CSSFloat}; use style::{dom_apis, thread_state, CaseSensitivityExt}; -use style_traits::dom::ElementState; +use style_dom::ElementState; use xml5ever::serialize as xmlSerialize; use xml5ever::serialize::TraversalScope::{ ChildrenOnly as XmlChildrenOnly, IncludeNode as XmlIncludeNode, diff --git a/components/script/dom/htmlbuttonelement.rs b/components/script/dom/htmlbuttonelement.rs index 7241266add2..4ed72a7ce6d 100755 --- a/components/script/dom/htmlbuttonelement.rs +++ b/components/script/dom/htmlbuttonelement.rs @@ -8,7 +8,7 @@ use std::default::Default; use dom_struct::dom_struct; use html5ever::{local_name, namespace_url, LocalName, Prefix}; use js::rust::HandleObject; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::activation::Activatable; use crate::dom::attr::Attr; diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index 9e4cc20ccf9..00baabcab53 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -11,7 +11,7 @@ use html5ever::{local_name, namespace_url, ns, LocalName, Prefix}; use js::rust::HandleObject; use script_layout_interface::QueryMsg; use style::attr::AttrValue; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::activation::Activatable; use crate::dom::attr::Attr; diff --git a/components/script/dom/htmlfieldsetelement.rs b/components/script/dom/htmlfieldsetelement.rs index 8e30889bb64..bdc5c72507b 100644 --- a/components/script/dom/htmlfieldsetelement.rs +++ b/components/script/dom/htmlfieldsetelement.rs @@ -7,7 +7,7 @@ use std::default::Default; use dom_struct::dom_struct; use html5ever::{local_name, LocalName, Prefix}; use js::rust::HandleObject; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::Attr; use crate::dom::bindings::codegen::Bindings::HTMLFieldSetElementBinding::HTMLFieldSetElementMethods; diff --git a/components/script/dom/htmlformelement.rs b/components/script/dom/htmlformelement.rs index 6794dc1507c..840235416ca 100644 --- a/components/script/dom/htmlformelement.rs +++ b/components/script/dom/htmlformelement.rs @@ -20,7 +20,7 @@ use servo_atoms::Atom; use servo_rand::random; use style::attr::AttrValue; use style::str::split_html_space_chars; -use style_traits::dom::ElementState; +use style_dom::ElementState; use super::bindings::trace::{HashMapTracedValues, NoTrace}; use crate::body::Extractable; diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index a0f17a9871f..45385e786e7 100755 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -29,7 +29,7 @@ use script_traits::ScriptToConstellationChan; use servo_atoms::Atom; use style::attr::AttrValue; use style::str::{split_commas, str_join}; -use style_traits::dom::ElementState; +use style_dom::ElementState; use unicode_bidi::{bidi_class, BidiClass}; use url::Url; diff --git a/components/script/dom/htmloptgroupelement.rs b/components/script/dom/htmloptgroupelement.rs index f2a89284748..2141a5b9cc3 100644 --- a/components/script/dom/htmloptgroupelement.rs +++ b/components/script/dom/htmloptgroupelement.rs @@ -5,7 +5,7 @@ use dom_struct::dom_struct; use html5ever::{local_name, LocalName, Prefix}; use js::rust::HandleObject; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::Attr; use crate::dom::bindings::codegen::Bindings::HTMLOptGroupElementBinding::HTMLOptGroupElementMethods; diff --git a/components/script/dom/htmloptionelement.rs b/components/script/dom/htmloptionelement.rs index cd2136a517d..7c01172ef17 100644 --- a/components/script/dom/htmloptionelement.rs +++ b/components/script/dom/htmloptionelement.rs @@ -9,7 +9,7 @@ use dom_struct::dom_struct; use html5ever::{local_name, namespace_url, ns, LocalName, Prefix, QualName}; use js::rust::HandleObject; use style::str::{split_html_space_chars, str_join}; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::Attr; use crate::dom::bindings::codegen::Bindings::CharacterDataBinding::CharacterDataMethods; diff --git a/components/script/dom/htmlselectelement.rs b/components/script/dom/htmlselectelement.rs index f4f878adc1d..aa5e6f8f469 100755 --- a/components/script/dom/htmlselectelement.rs +++ b/components/script/dom/htmlselectelement.rs @@ -9,7 +9,7 @@ use dom_struct::dom_struct; use html5ever::{local_name, LocalName, Prefix}; use js::rust::HandleObject; use style::attr::AttrValue; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::Attr; use crate::dom::bindings::codegen::Bindings::ElementBinding::ElementMethods; diff --git a/components/script/dom/htmltextareaelement.rs b/components/script/dom/htmltextareaelement.rs index 30b199f7941..a6cfde252e5 100755 --- a/components/script/dom/htmltextareaelement.rs +++ b/components/script/dom/htmltextareaelement.rs @@ -11,7 +11,7 @@ use html5ever::{local_name, namespace_url, ns, LocalName, Prefix}; use js::rust::HandleObject; use script_traits::ScriptToConstellationChan; use style::attr::AttrValue; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::Attr; use crate::dom::bindings::cell::DomRefCell; diff --git a/components/script/dom/svgelement.rs b/components/script/dom/svgelement.rs index d79efda3c6d..3168903812b 100644 --- a/components/script/dom/svgelement.rs +++ b/components/script/dom/svgelement.rs @@ -5,7 +5,7 @@ use dom_struct::dom_struct; use html5ever::{local_name, namespace_url, ns, LocalName, Prefix}; use js::rust::HandleObject; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::bindings::codegen::Bindings::SVGElementBinding::SVGElementMethods; use crate::dom::bindings::inheritance::Castable; diff --git a/components/script/dom/svggraphicselement.rs b/components/script/dom/svggraphicselement.rs index 2a3f7f139c3..629cd582892 100644 --- a/components/script/dom/svggraphicselement.rs +++ b/components/script/dom/svggraphicselement.rs @@ -4,7 +4,7 @@ use dom_struct::dom_struct; use html5ever::{LocalName, Prefix}; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::bindings::inheritance::Castable; use crate::dom::document::Document; diff --git a/components/script/dom/validitystate.rs b/components/script/dom/validitystate.rs index d91fb345d60..8b2caa5526f 100755 --- a/components/script/dom/validitystate.rs +++ b/components/script/dom/validitystate.rs @@ -8,7 +8,7 @@ use std::fmt; use bitflags::bitflags; use dom_struct::dom_struct; use itertools::Itertools; -use style_traits::dom::ElementState; +use style_dom::ElementState; use super::bindings::codegen::Bindings::ElementInternalsBinding::ValidityStateFlags; use crate::dom::bindings::cell::{DomRefCell, Ref}; diff --git a/components/script/layout_dom/element.rs b/components/script/layout_dom/element.rs index 55855930a31..6af5e72bb1f 100644 --- a/components/script/layout_dom/element.rs +++ b/components/script/layout_dom/element.rs @@ -34,7 +34,7 @@ use style::shared_lock::Locked as StyleLocked; use style::values::computed::Display; use style::values::{AtomIdent, AtomString}; use style::CaseSensitivityExt; -use style_traits::dom::ElementState; +use style_dom::ElementState; use crate::dom::attr::AttrHelpersForLayout; use crate::dom::bindings::inheritance::{ diff --git a/resources/presentational-hints.css b/resources/presentational-hints.css index 547bb42f96f..36a0175bd45 100644 --- a/resources/presentational-hints.css +++ b/resources/presentational-hints.css @@ -7,9 +7,9 @@ https://html.spec.whatwg.org/multipage/#presentational-hints pre[wrap] { white-space: pre-wrap; } -div[align=left i] { text-align: -servo-left; } -div[align=right i] { text-align: -servo-right; } -div[align=center i], div[align=middle i] { text-align: -servo-center; } +div[align=left i] { text-align: -moz-left; } +div[align=right i] { text-align: -moz-right; } +div[align=center i], div[align=middle i] { text-align: -moz-center; } div[align=justify i] { text-align: justify; } diff --git a/resources/quirks-mode.css b/resources/quirks-mode.css index 78a3c2d8a9b..cb8d3028441 100644 --- a/resources/quirks-mode.css +++ b/resources/quirks-mode.css @@ -25,7 +25,7 @@ table { /* * FIXME(pcwalton): Actually saying `text-align: initial` above breaks `<table>` inside `<center>` * in quirks mode. This is because we (following Gecko, WebKit, and Blink) implement the HTML5 - * align-descendants rules with a special `text-align: -servo-center`. `text-align: initial`, if + * align-descendants rules with a special `text-align: -moz-center`. `text-align: initial`, if * placed on the `<table>` element per the spec, would break this behavior. So we place it on * `<tbody>` instead. */ diff --git a/resources/servo.css b/resources/servo.css index 372d8afcf9d..63172fe79b0 100644 --- a/resources/servo.css +++ b/resources/servo.css @@ -112,7 +112,7 @@ td[align="left"] { text-align: left; } td[align="center"] { text-align: center; } td[align="right"] { text-align: right; } -center { text-align: -servo-center; } +center { text-align: -moz-center; } label { cursor: default; } diff --git a/tests/wpt/meta-legacy-layout/css/css-values/rlh-unit-001.html.ini b/tests/wpt/meta-legacy-layout/css/css-values/rlh-unit-001.html.ini deleted file mode 100644 index 60dbcb52aed..00000000000 --- a/tests/wpt/meta-legacy-layout/css/css-values/rlh-unit-001.html.ini +++ /dev/null @@ -1,2 +0,0 @@ -[rlh-unit-001.html] - expected: FAIL diff --git a/tests/wpt/meta/css/css-cascade/scope-featureless.html.ini b/tests/wpt/meta/css/css-cascade/scope-featureless.html.ini deleted file mode 100644 index 7ad66440741..00000000000 --- a/tests/wpt/meta/css/css-cascade/scope-featureless.html.ini +++ /dev/null @@ -1,2 +0,0 @@ -[scope-featureless.html] - expected: FAIL diff --git a/tests/wpt/meta/css/css-tables/fixed-layout-2.html.ini b/tests/wpt/meta/css/css-tables/fixed-layout-2.html.ini deleted file mode 100644 index eeabc9ba890..00000000000 --- a/tests/wpt/meta/css/css-tables/fixed-layout-2.html.ini +++ /dev/null @@ -1,6 +0,0 @@ -[fixed-layout-2.html] - [Table-layout:fixed reports fixed when width is auto] - expected: FAIL - - [Table-layout:fixed reports fixed when width is max-content] - expected: FAIL diff --git a/tests/wpt/meta/css/css-tables/inheritance.html.ini b/tests/wpt/meta/css/css-tables/inheritance.html.ini index 62356a03798..d8ecf7548bb 100644 --- a/tests/wpt/meta/css/css-tables/inheritance.html.ini +++ b/tests/wpt/meta/css/css-tables/inheritance.html.ini @@ -1,9 +1,3 @@ [inheritance.html] [Property border-spacing has initial value 0px 0px] expected: FAIL - - [Property table-layout has initial value auto] - expected: FAIL - - [Property table-layout does not inherit] - expected: FAIL diff --git a/tests/wpt/meta/css/css-tables/parsing/table-layout-computed.html.ini b/tests/wpt/meta/css/css-tables/parsing/table-layout-computed.html.ini deleted file mode 100644 index 1eef0381bbb..00000000000 --- a/tests/wpt/meta/css/css-tables/parsing/table-layout-computed.html.ini +++ /dev/null @@ -1,6 +0,0 @@ -[table-layout-computed.html] - [Property table-layout value 'auto'] - expected: FAIL - - [Property table-layout value 'fixed'] - expected: FAIL diff --git a/tests/wpt/meta/css/css-tables/parsing/table-layout-valid.html.ini b/tests/wpt/meta/css/css-tables/parsing/table-layout-valid.html.ini deleted file mode 100644 index 39e82651a33..00000000000 --- a/tests/wpt/meta/css/css-tables/parsing/table-layout-valid.html.ini +++ /dev/null @@ -1,6 +0,0 @@ -[table-layout-valid.html] - [e.style['table-layout'\] = "auto" should set the property value] - expected: FAIL - - [e.style['table-layout'\] = "fixed" should set the property value] - expected: FAIL diff --git a/tests/wpt/meta/css/css-values/rlh-unit-001.html.ini b/tests/wpt/meta/css/css-values/rlh-unit-001.html.ini deleted file mode 100644 index 60dbcb52aed..00000000000 --- a/tests/wpt/meta/css/css-values/rlh-unit-001.html.ini +++ /dev/null @@ -1,2 +0,0 @@ -[rlh-unit-001.html] - expected: FAIL diff --git a/tests/wpt/meta/css/cssom/serialize-values.html.ini b/tests/wpt/meta/css/cssom/serialize-values.html.ini index 4718741f2dd..bae759a03f3 100644 --- a/tests/wpt/meta/css/cssom/serialize-values.html.ini +++ b/tests/wpt/meta/css/cssom/serialize-values.html.ini @@ -92,15 +92,6 @@ [direction: inherit] expected: FAIL - [table-layout: auto] - expected: FAIL - - [table-layout: fixed] - expected: FAIL - - [table-layout: inherit] - expected: FAIL - [unicode-bidi: normal] expected: FAIL |