From 14c5a1b8d3dee7cfc8dfeb9314a0178c33197145 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fausto=20N=C3=BA=C3=B1ez=20Alberro?= Date: Sat, 22 Jul 2017 17:35:30 +0200 Subject: [PATCH] Introduce ComputedUrl Add web platform tests for computed URL styles Mark url with no original or resolved unreachable Update the WPT manifest for new url tests --- .../helpers/animated_properties.mako.rs | 6 +-- components/style/servo/url.rs | 33 +++++++++++++ components/style/values/animated/mod.rs | 4 ++ .../style/values/computed/basic_shape.rs | 6 +-- components/style/values/computed/image.rs | 6 +-- components/style/values/computed/mod.rs | 49 ++++++++++++++++++- components/style/values/computed/svg.rs | 5 +- .../style/values/generics/basic_shape.rs | 11 ++--- components/style/values/generics/image.rs | 19 ++++--- components/style/values/generics/svg.rs | 15 +++--- .../style/values/specified/basic_shape.rs | 6 +-- components/style/values/specified/image.rs | 4 +- components/style/values/specified/mod.rs | 3 +- components/style/values/specified/svg.rs | 6 +-- tests/wpt/mozilla/meta/MANIFEST.json | 10 ++++ .../css/get-computed-style-for-url.html.ini | 11 +++++ .../tests/css/get-computed-style-for-url.html | 49 +++++++++++++++++++ 17 files changed, 197 insertions(+), 46 deletions(-) create mode 100644 tests/wpt/mozilla/meta/css/get-computed-style-for-url.html.ini create mode 100644 tests/wpt/mozilla/tests/css/get-computed-style-for-url.html diff --git a/components/style/properties/helpers/animated_properties.mako.rs b/components/style/properties/helpers/animated_properties.mako.rs index 88dc2272f00..07031c2f67a 100644 --- a/components/style/properties/helpers/animated_properties.mako.rs +++ b/components/style/properties/helpers/animated_properties.mako.rs @@ -44,7 +44,7 @@ use values::animated::effects::FilterList as AnimatedFilterList; use values::animated::effects::TextShadowList as AnimatedTextShadowList; use values::computed::{Angle, LengthOrPercentageOrAuto, LengthOrPercentageOrNone}; use values::computed::{BorderCornerRadius, ClipRect}; -use values::computed::{CalcLengthOrPercentage, Color, Context, ComputedValueAsSpecified}; +use values::computed::{CalcLengthOrPercentage, Color, Context, ComputedValueAsSpecified, ComputedUrl}; use values::computed::{LengthOrPercentage, MaxLength, MozLength, Percentage, ToComputedValue}; use values::computed::{NonNegativeAu, NonNegativeNumber, PositiveIntegerOrAuto}; use values::computed::length::{NonNegativeLengthOrAuto, NonNegativeLengthOrNormal}; @@ -2974,10 +2974,10 @@ impl ToAnimatedZero for IntermediateColor { } /// Animatable SVGPaint -pub type IntermediateSVGPaint = SVGPaint; +pub type IntermediateSVGPaint = SVGPaint; /// Animatable SVGPaintKind -pub type IntermediateSVGPaintKind = SVGPaintKind; +pub type IntermediateSVGPaintKind = SVGPaintKind; impl Animatable for IntermediateSVGPaint { #[inline] diff --git a/components/style/servo/url.rs b/components/style/servo/url.rs index ef257bacfe3..4736f2967d8 100644 --- a/components/style/servo/url.rs +++ b/components/style/servo/url.rs @@ -12,6 +12,7 @@ use std::fmt; // the threshold. use std::sync::Arc; use style_traits::{ToCss, ParseError}; +use values::computed::{Context, ToComputedValue, ComputedUrl}; /// A specified url() value for servo. /// @@ -126,3 +127,35 @@ impl ToCss for SpecifiedUrl { dest.write_str(")") } } + +impl ToComputedValue for SpecifiedUrl { + type ComputedValue = ComputedUrl; + + // If we can't resolve the URL from the specified one, we fall back to the original + // but still return it as a ComputedUrl::Invalid + fn to_computed_value(&self, _: &Context) -> Self::ComputedValue { + match self.resolved { + Some(ref url) => ComputedUrl::Valid(url.clone()), + None => match self.original { + Some(ref url) => ComputedUrl::Invalid(url.clone()), + None => { + unreachable!("Found specified url with neither resolved or original URI!"); + }, + } + } + } + + fn from_computed_value(computed: &ComputedUrl) -> Self { + match *computed { + ComputedUrl::Valid(ref url) => SpecifiedUrl { + original: None, + resolved: Some(url.clone()), + }, + ComputedUrl::Invalid(ref url) => SpecifiedUrl { + original: Some(url.clone()), + resolved: None, + } + } + } +} + diff --git a/components/style/values/animated/mod.rs b/components/style/values/animated/mod.rs index 49a53938e1e..464dbf86040 100644 --- a/components/style/values/animated/mod.rs +++ b/components/style/values/animated/mod.rs @@ -13,6 +13,8 @@ use smallvec::SmallVec; use std::cmp::max; use values::computed::Angle as ComputedAngle; use values::computed::BorderCornerRadius as ComputedBorderCornerRadius; +#[cfg(feature = "servo")] +use values::computed::ComputedUrl; use values::computed::GreaterThanOrEqualToOneNumber as ComputedGreaterThanOrEqualToOneNumber; use values::computed::MaxLength as ComputedMaxLength; use values::computed::MozLength as ComputedMozLength; @@ -95,6 +97,8 @@ pub trait AnimatedValueAsComputed {} impl AnimatedValueAsComputed for Au {} impl AnimatedValueAsComputed for ComputedAngle {} impl AnimatedValueAsComputed for SpecifiedUrl {} +#[cfg(feature = "servo")] +impl AnimatedValueAsComputed for ComputedUrl {} impl AnimatedValueAsComputed for bool {} impl AnimatedValueAsComputed for f32 {} diff --git a/components/style/values/computed/basic_shape.rs b/components/style/values/computed/basic_shape.rs index 2b3cebb869b..b9c82be1fb9 100644 --- a/components/style/values/computed/basic_shape.rs +++ b/components/style/values/computed/basic_shape.rs @@ -9,17 +9,17 @@ use std::fmt; use style_traits::ToCss; -use values::computed::LengthOrPercentage; +use values::computed::{LengthOrPercentage, ComputedUrl}; use values::generics::basic_shape::{BasicShape as GenericBasicShape}; use values::generics::basic_shape::{Circle as GenericCircle, ClippingShape as GenericClippingShape}; use values::generics::basic_shape::{Ellipse as GenericEllipse, FloatAreaShape as GenericFloatAreaShape}; use values::generics::basic_shape::{InsetRect as GenericInsetRect, ShapeRadius as GenericShapeRadius}; /// A specified clipping shape. -pub type ClippingShape = GenericClippingShape; +pub type ClippingShape = GenericClippingShape; /// A specified float area shape. -pub type FloatAreaShape = GenericFloatAreaShape; +pub type FloatAreaShape = GenericFloatAreaShape; /// A computed basic shape. pub type BasicShape = GenericBasicShape; diff --git a/components/style/values/computed/image.rs b/components/style/values/computed/image.rs index dc4a27f205f..a4a51b7bae6 100644 --- a/components/style/values/computed/image.rs +++ b/components/style/values/computed/image.rs @@ -12,7 +12,7 @@ use std::f32::consts::PI; use std::fmt; use style_traits::ToCss; use values::{Either, None_}; -use values::computed::{Angle, Context, Length, LengthOrPercentage, NumberOrPercentage, ToComputedValue}; +use values::computed::{Angle, ComputedUrl, Context, Length, LengthOrPercentage, NumberOrPercentage, ToComputedValue}; use values::computed::position::Position; use values::generics::image::{CompatMode, ColorStop as GenericColorStop, EndingShape as GenericEndingShape}; use values::generics::image::{Gradient as GenericGradient, GradientItem as GenericGradientItem}; @@ -27,7 +27,7 @@ pub type ImageLayer = Either; /// Computed values for an image according to CSS-IMAGES. /// https://drafts.csswg.org/css-images/#image-values -pub type Image = GenericImage; +pub type Image = GenericImage; /// Computed values for a CSS gradient. /// https://drafts.csswg.org/css-images/#gradients @@ -76,7 +76,7 @@ pub type GradientItem = GenericGradientItem; pub type ColorStop = GenericColorStop; /// Computed values for `-moz-image-rect(...)`. -pub type MozImageRect = GenericMozImageRect; +pub type MozImageRect = GenericMozImageRect; impl GenericLineDirection for LineDirection { fn points_downwards(&self) -> bool { diff --git a/components/style/values/computed/mod.rs b/components/style/values/computed/mod.rs index a1206529f80..791104500f5 100644 --- a/components/style/values/computed/mod.rs +++ b/components/style/values/computed/mod.rs @@ -12,10 +12,14 @@ use media_queries::Device; #[cfg(feature = "gecko")] use properties; use properties::{ComputedValues, StyleBuilder}; +#[cfg(feature = "servo")] +use servo_url::ServoUrl; use std::f32; use std::f64; use std::f64::consts::PI; use std::fmt; +#[cfg(feature = "servo")] +use std::sync::Arc; use style_traits::ToCss; use super::{CSSFloat, CSSInteger}; use super::generics::{GreaterThanOrEqualToOne, NonNegative}; @@ -39,9 +43,8 @@ pub use self::image::{Gradient, GradientItem, Image, ImageLayer, LineDirection, pub use self::gecko::ScrollSnapPoint; pub use self::rect::LengthOrNumberRect; pub use super::{Auto, Either, None_}; -pub use super::specified::{BorderStyle, UrlOrNone}; +pub use super::specified::BorderStyle; pub use super::generics::grid::GridLine; -pub use super::specified::url::SpecifiedUrl; pub use self::length::{CalcLengthOrPercentage, Length, LengthOrNone, LengthOrNumber, LengthOrPercentage}; pub use self::length::{LengthOrPercentageOrAuto, LengthOrPercentageOrNone, MaxLength, MozLength}; pub use self::length::NonNegativeLengthOrPercentage; @@ -684,3 +687,45 @@ impl ToComputedValue for specified::Percentage { specified::Percentage::new(computed.0) } } + +/// The computed value of a CSS `url()`, resolved relative to the stylesheet URL. +#[cfg(feature = "servo")] +#[derive(Clone, Debug, HeapSizeOf, Serialize, Deserialize, PartialEq)] +pub enum ComputedUrl { + /// The `url()` was invalid or it wasn't specified by the user. + Invalid(Arc), + /// The resolved `url()` relative to the stylesheet URL. + Valid(ServoUrl), +} + +/// TODO: Properly build ComputedUrl for gecko +#[cfg(feature = "gecko")] +pub type ComputedUrl = specified::url::SpecifiedUrl; + +#[cfg(feature = "servo")] +impl ComputedUrl { + /// Returns the resolved url if it was valid. + pub fn url(&self) -> Option<&ServoUrl> { + match *self { + ComputedUrl::Valid(ref url) => Some(url), + _ => None, + } + } +} + +#[cfg(feature = "servo")] +impl ToCss for ComputedUrl { + fn to_css(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { + let string = match *self { + ComputedUrl::Valid(ref url) => url.as_str(), + ComputedUrl::Invalid(ref invalid_string) => invalid_string, + }; + + dest.write_str("url(")?; + string.to_css(dest)?; + dest.write_str(")") + } +} + +/// | +pub type UrlOrNone = Either; diff --git a/components/style/values/computed/svg.rs b/components/style/values/computed/svg.rs index 43613baa8c4..88cdbd5009e 100644 --- a/components/style/values/computed/svg.rs +++ b/components/style/values/computed/svg.rs @@ -8,12 +8,13 @@ use app_units::Au; use values::{Either, RGBA}; use values::computed::{LengthOrPercentageOrNumber, Opacity}; use values::computed::{NonNegativeAu, NonNegativeLengthOrPercentageOrNumber}; +use values::computed::ComputedUrl; use values::generics::svg as generic; /// Computed SVG Paint value -pub type SVGPaint = generic::SVGPaint; +pub type SVGPaint = generic::SVGPaint; /// Computed SVG Paint Kind value -pub type SVGPaintKind = generic::SVGPaintKind; +pub type SVGPaintKind = generic::SVGPaintKind; impl Default for SVGPaint { fn default() -> Self { diff --git a/components/style/values/generics/basic_shape.rs b/components/style/values/generics/basic_shape.rs index e7cfdbd25fe..98f9cd7690b 100644 --- a/components/style/values/generics/basic_shape.rs +++ b/components/style/values/generics/basic_shape.rs @@ -11,10 +11,9 @@ use values::computed::ComputedValueAsSpecified; use values::generics::border::BorderRadius; use values::generics::position::Position; use values::generics::rect::Rect; -use values::specified::url::SpecifiedUrl; /// A clipping shape, for `clip-path`. -pub type ClippingShape = ShapeSource; +pub type ClippingShape = ShapeSource; /// https://drafts.fxtf.org/css-masking-1/#typedef-geometry-box #[allow(missing_docs)] @@ -29,7 +28,7 @@ pub enum GeometryBox { impl ComputedValueAsSpecified for GeometryBox {} /// A float area shape, for `shape-outside`. -pub type FloatAreaShape = ShapeSource; +pub type FloatAreaShape = ShapeSource; // https://drafts.csswg.org/css-shapes-1/#typedef-shape-box define_css_keyword_enum!(ShapeBox: @@ -44,8 +43,8 @@ add_impls_for_keyword_enum!(ShapeBox); #[allow(missing_docs)] #[cfg_attr(feature = "servo", derive(HeapSizeOf))] #[derive(Clone, Debug, PartialEq, ToComputedValue, ToCss)] -pub enum ShapeSource { - Url(SpecifiedUrl), +pub enum ShapeSource { + Url(UrlShapeSource), Shape(BasicShape, Option), Box(ReferenceBox), None, @@ -121,7 +120,7 @@ define_css_keyword_enum!(FillRule: ); add_impls_for_keyword_enum!(FillRule); -impl HasViewportPercentage for ShapeSource { +impl HasViewportPercentage for ShapeSource { #[inline] fn has_viewport_percentage(&self) -> bool { false } } diff --git a/components/style/values/generics/image.rs b/components/style/values/generics/image.rs index 5da5a68563c..867364e3df3 100644 --- a/components/style/values/generics/image.rs +++ b/components/style/values/generics/image.rs @@ -12,16 +12,15 @@ use custom_properties::SpecifiedValue; use std::fmt; use style_traits::{HasViewportPercentage, ToCss}; use values::computed::ComputedValueAsSpecified; -use values::specified::url::SpecifiedUrl; /// An [image]. /// /// [image]: https://drafts.csswg.org/css-images/#image-values #[derive(Clone, PartialEq, ToComputedValue)] #[cfg_attr(feature = "servo", derive(HeapSizeOf))] -pub enum Image { +pub enum Image { /// A `` image. - Url(SpecifiedUrl), + Url(ImageUrl), /// A `` image. Gradient(Gradient), /// A `-moz-image-rect` image @@ -168,16 +167,16 @@ impl ToCss for PaintWorklet { #[cfg_attr(feature = "servo", derive(HeapSizeOf))] #[css(comma, function)] #[derive(Clone, Debug, PartialEq, ToComputedValue, ToCss)] -pub struct MozImageRect { - pub url: SpecifiedUrl, +pub struct MozImageRect { + pub url: MozImageRectUrl, pub top: NumberOrPercentage, pub right: NumberOrPercentage, pub bottom: NumberOrPercentage, pub left: NumberOrPercentage, } -impl fmt::Debug for Image - where G: fmt::Debug, R: fmt::Debug, +impl fmt::Debug for Image + where G: fmt::Debug, R: fmt::Debug, U: fmt::Debug + ToCss { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { match *self { @@ -195,8 +194,8 @@ impl fmt::Debug for Image } } -impl ToCss for Image - where G: ToCss, R: ToCss, +impl ToCss for Image + where G: ToCss, R: ToCss, U: ToCss { fn to_css(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { match *self { @@ -214,7 +213,7 @@ impl ToCss for Image } } -impl HasViewportPercentage for Image +impl HasViewportPercentage for Image where G: HasViewportPercentage { fn has_viewport_percentage(&self) -> bool { diff --git a/components/style/values/generics/svg.rs b/components/style/values/generics/svg.rs index 557a63fd24c..05e0e66248f 100644 --- a/components/style/values/generics/svg.rs +++ b/components/style/values/generics/svg.rs @@ -8,16 +8,15 @@ use cssparser::Parser; use parser::{Parse, ParserContext}; use std::fmt; use style_traits::{ParseError, StyleParseError, ToCss}; -use values::specified::url::SpecifiedUrl; /// An SVG paint value /// /// https://www.w3.org/TR/SVG2/painting.html#SpecifyingPaint #[cfg_attr(feature = "servo", derive(HeapSizeOf))] #[derive(Clone, Debug, PartialEq, ToAnimatedValue, ToComputedValue, ToCss)] -pub struct SVGPaint { +pub struct SVGPaint { /// The paint source - pub kind: SVGPaintKind, + pub kind: SVGPaintKind, /// The fallback color pub fallback: Option, } @@ -29,20 +28,20 @@ pub struct SVGPaint { /// properties have a fallback as well. #[cfg_attr(feature = "servo", derive(HeapSizeOf))] #[derive(Clone, Debug, PartialEq, ToAnimatedValue, ToComputedValue, ToCss)] -pub enum SVGPaintKind { +pub enum SVGPaintKind { /// `none` None, /// `` Color(ColorType), /// `url(...)` - PaintServer(SpecifiedUrl), + PaintServer(UrlPaintServer), /// `context-fill` ContextFill, /// `context-stroke` ContextStroke, } -impl SVGPaintKind { +impl SVGPaintKind { /// Parse a keyword value only fn parse_ident<'i, 't>(input: &mut Parser<'i, 't>) -> Result> { try_match_ident_ignore_ascii_case! { input.expect_ident()?, @@ -66,9 +65,9 @@ fn parse_fallback<'i, 't, ColorType: Parse>(context: &ParserContext, } } -impl Parse for SVGPaint { +impl Parse for SVGPaint { fn parse<'i, 't>(context: &ParserContext, input: &mut Parser<'i, 't>) -> Result> { - if let Ok(url) = input.try(|i| SpecifiedUrl::parse(context, i)) { + if let Ok(url) = input.try(|i| UrlPaintServer::parse(context, i)) { Ok(SVGPaint { kind: SVGPaintKind::PaintServer(url), fallback: parse_fallback(context, input), diff --git a/components/style/values/specified/basic_shape.rs b/components/style/values/specified/basic_shape.rs index 4ce3adb2968..cabed5994ed 100644 --- a/components/style/values/specified/basic_shape.rs +++ b/components/style/values/specified/basic_shape.rs @@ -26,10 +26,10 @@ use values::specified::position::{HorizontalPosition, Position, PositionComponen use values::specified::url::SpecifiedUrl; /// A specified clipping shape. -pub type ClippingShape = GenericClippingShape; +pub type ClippingShape = GenericClippingShape; /// A specified float area shape. -pub type FloatAreaShape = GenericFloatAreaShape; +pub type FloatAreaShape = GenericFloatAreaShape; /// A specified basic shape. pub type BasicShape = GenericBasicShape; @@ -49,7 +49,7 @@ pub type ShapeRadius = GenericShapeRadius; /// The specified value of `Polygon` pub type Polygon = GenericPolygon; -impl Parse for ShapeSource { +impl Parse for ShapeSource { fn parse<'i, 't>(context: &ParserContext, input: &mut Parser<'i, 't>) -> Result> { if input.try(|i| i.expect_ident_matching("none")).is_ok() { return Ok(ShapeSource::None) diff --git a/components/style/values/specified/image.rs b/components/style/values/specified/image.rs index 687c6f17d43..42f44043328 100644 --- a/components/style/values/specified/image.rs +++ b/components/style/values/specified/image.rs @@ -38,7 +38,7 @@ pub type ImageLayer = Either; /// Specified values for an image according to CSS-IMAGES. /// https://drafts.csswg.org/css-images/#image-values -pub type Image = GenericImage; +pub type Image = GenericImage; /// Specified values for a CSS gradient. /// https://drafts.csswg.org/css-images/#gradients @@ -125,7 +125,7 @@ pub type ColorStop = GenericColorStop; /// Specified values for `moz-image-rect` /// -moz-image-rect(, top, right, bottom, left); -pub type MozImageRect = GenericMozImageRect; +pub type MozImageRect = GenericMozImageRect; impl Parse for Image { #[cfg_attr(not(feature = "gecko"), allow(unused_mut))] diff --git a/components/style/values/specified/mod.rs b/components/style/values/specified/mod.rs index 0c95e9a3693..e8bfad406ad 100644 --- a/components/style/values/specified/mod.rs +++ b/components/style/values/specified/mod.rs @@ -76,6 +76,7 @@ pub mod url { use cssparser::Parser; use parser::{Parse, ParserContext}; use style_traits::ParseError; +#[cfg(feature = "gecko")] use values::computed::ComputedValueAsSpecified; #[cfg(feature = "servo")] @@ -92,7 +93,7 @@ impl Parse for SpecifiedUrl { impl Eq for SpecifiedUrl {} -// TODO(emilio): Maybe consider ComputedUrl to save a word in style structs? +#[cfg(feature = "gecko")] impl ComputedValueAsSpecified for SpecifiedUrl {} no_viewport_percentage!(SpecifiedUrl); diff --git a/components/style/values/specified/svg.rs b/components/style/values/specified/svg.rs index 8ee5736bbd7..980162ccd2d 100644 --- a/components/style/values/specified/svg.rs +++ b/components/style/values/specified/svg.rs @@ -8,16 +8,16 @@ use cssparser::Parser; use parser::{Parse, ParserContext}; use style_traits::{CommaWithSpace, ParseError, Separator, StyleParseError}; use values::generics::svg as generic; -use values::specified::{LengthOrPercentageOrNumber, NonNegativeLengthOrPercentageOrNumber, Opacity}; +use values::specified::{LengthOrPercentageOrNumber, NonNegativeLengthOrPercentageOrNumber, Opacity, SpecifiedUrl}; use values::specified::color::RGBAColor; /// Specified SVG Paint value -pub type SVGPaint = generic::SVGPaint; +pub type SVGPaint = generic::SVGPaint; no_viewport_percentage!(SVGPaint); /// Specified SVG Paint Kind value -pub type SVGPaintKind = generic::SVGPaintKind; +pub type SVGPaintKind = generic::SVGPaintKind; #[cfg(feature = "gecko")] fn is_context_value_enabled() -> bool { diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index 155f9a504d4..324185389bf 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -13536,6 +13536,12 @@ {} ] ], + "css/get-computed-style-for-url.html": [ + [ + "/_mozilla/css/get-computed-style-for-url.html", + {} + ] + ], "css/import_serialization.html": [ [ "/_mozilla/css/import_serialization.html", @@ -23357,6 +23363,10 @@ "13a3f8dd23fa28c0b2ad2fe0662d29a27a569e74", "support" ], + "css/get-computed-style-for-url.html": [ + "2e90c0abd6c83bb11113f39a557a4c1c1c24364b", + "testharness" + ], "css/green.png": [ "15e39f6df8def787cefcfb30e27de5f43da65c9a", "support" diff --git a/tests/wpt/mozilla/meta/css/get-computed-style-for-url.html.ini b/tests/wpt/mozilla/meta/css/get-computed-style-for-url.html.ini new file mode 100644 index 00000000000..3f3945a8eb3 --- /dev/null +++ b/tests/wpt/mozilla/meta/css/get-computed-style-for-url.html.ini @@ -0,0 +1,11 @@ +[get-computed-style-for-url.html] + type: testharness + + [getComputedStyle(elem) for url() listStyle uses the resolved URL and elem.style uses the original URL] + expected: FAIL + bug: https://github.com/servo/servo/issues/18015 + + [getComputedStyle(elem) for url() listStyleImage uses the resolved URL and elem.style uses the original URL] + expected: FAIL + bug: https://github.com/servo/servo/issues/18015 + diff --git a/tests/wpt/mozilla/tests/css/get-computed-style-for-url.html b/tests/wpt/mozilla/tests/css/get-computed-style-for-url.html new file mode 100644 index 00000000000..06ec9dc5571 --- /dev/null +++ b/tests/wpt/mozilla/tests/css/get-computed-style-for-url.html @@ -0,0 +1,49 @@ + + +Computed styles for URLs use the resolved URL and specified styles use the original URL + + +
+ +