mirror of
https://github.com/servo/servo.git
synced 2025-08-15 18:35:33 +01:00
script: support inline SVG by serializing the subtree (#38188)
This patch adds support for rendering static inline SVG documents in the DOM tree by serializing the SVGElement's subtree and leveraging the existing resvg based SVG stack for rendering. Serialiing the subtree is necessary as resvg's tree representation (roxmltree) is immutable, so we can't construct the tree incrementally. Few other design choices here: 1. The `SVGSVGElement` is now treated as a replaced element and the layout code is responsible for plumbing the serialized SVG source (encoded as a base64 data: url) into the image cache, much like how background images are handled. 2. The serialization is done on the script thread after an initial layout pass. This is necessary because the serialization code asserts that it is invoked from script thread i.e we can't call it from layout workers. 3. The serialized SVG data: url is cached to avoid recomputing it on subsequent layouts. The cache is invalidated when the SVGSVGElement's subtree is mutated. The original SVGSVGElement code was behind the `dom_svg_enabled` pref. This patch also removes the preference and make SVG support using resvg available unconditionally. Below is the analysis of the new test failures: These tests use inline SVG but used to pass by accident. They now fail because they contain SVG with no intrinsic sizing which is not handled by resvg in a way that would allows us to distinguish it from the sized case. The same limitation applies to non-inline SVG. - /css/CSS2/positioning/absolute-replaced-width-003a.xht - /css/CSS2/positioning/absolute-replaced-width-003b.xht - /css/CSS2/positioning/absolute-replaced-width-003c.xht These tests employ CSS styles in the HTML that target the elements in inline SVG, which is not currently supported. - /css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg-basic.html - /css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg.html This is a tentative test that uses the unsupported 'border-shape' CSS property. The ref uses SVG, so it used to pass accidentally. The ref still doesn't render correctly since it also relies on styling SVG elements using CSS classes in the HTML (instead of inline in SVG). - /css/css-borders/tentative/border-shape/border-shape-stroke.html These tests use the attribute 'clip-path=circle(...)' in the test, but this doesn't seem to work in resvg. - /css/css-masking/clip-path/clip-path-borderBox-1b.html - /css/css-masking/clip-path/clip-path-contentBox-1b.html - /css/css-masking/clip-path/clip-path-contentBox-1c.html - /css/css-masking/clip-path/clip-path-fillBox-1b.html - /css/css-masking/clip-path/clip-path-marginBox-1a.html - /css/css-masking/clip-path/clip-path-paddingBox-1b.html - /css/css-masking/clip-path/clip-path-strokeBox-1b.html - /css/css-masking/clip-path/clip-path-strokeBox-1c.html - /css/css-masking/clip-path/clip-path-viewBox-1a.html - /css/css-masking/clip-path/clip-path-viewBox-1b.html - /css/css-masking/clip-path/clip-path-viewBox-1d.html - /css/css-masking/clip-path/svg-clip-path-circle-offset.html - /css/css-masking/clip-path/svg-clip-path-ellipse-offset.html Additionally, the below two tests use a `foreignObject` SVG element which embeds a html div fragment. This is also not supported by resvg. - /css/css-masking/clip-path/clip-path-viewBox-1d.html - /css/css-masking/clip-path/clip-path-fillBox-1b.html The following test fails because of apparent pixel differences between a circle rendered purely using CSS clip-path vs a circle rendered in SVG using resvg. - /css/css-masking/clip-path/clip-path-contentBox-1c.html These tests style the inline SVG elements using CSS in the HTML or separate stylesheet. This is not supported by this implementation. - /css-transforms/document-styles/svg-document-styles-{001..004}.html - /css-transforms/document-styles/svg-document-styles-012.html - /css-transforms/external-styles/svg-external-styles-{001..004}.html - /css-transforms/external-styles/svg-external-styles-014.html These tests seem like they should pass, but they fail because of what seems like an anti-aliasing issue in the rendering engine. The transformed element has a thin outline which is causing pixel difference with the ref: - /css/css-transforms/group/svg-transform-group-008.html - /css/css-transforms/group/svg-transform-group-009.html - /css/css-transforms/group/svg-transform-nested-009.html - /css/css-transforms/group/svg-transform-nested-013.html - /css/css-transforms/group/svg-transform-nested-014.html - /css/css-transforms/group/svg-transform-nested-018.html - /css/css-transforms/group/svg-transform-nested-019.html - /css/css-transforms/group/svg-transform-nested-008.html The below tests fail because resvg is calculating the wrong size for the 'rect' inside the SVG. The dimensions of the SVG are established via the CSS in the HTML, so it seems resvg is using incorrect coordinates for the children of the svg when explict width/height are not specified in the root svg element. - /css/css-transforms/group/svg-transform-group-011.html - /css/css-transforms/group/svg-transform-nested-021.html - /css/css-transforms/group/svg-transform-nested-029.html All these tests use an SVG that doesn't have width nor height attributes and this causes resvg to use incorrect coordinates for the SVG's children. In addition, the following tests use the CSS syntax for transforms inside the SVG (using style attribute) which is not supported by resvg (it only supports the SVG 1.1 transform syntax). - /css/css-transforms/inline-styles/svg-inline-styles-{001..004}.html - /css/css-transforms/inline-styles/svg-inline-styles-012.html In the case of these four tests, the `style` attribute specifies an invalid transform, but resvg doesn't fallback to the transform specified via the `transform` attribute on the same element. - /css/css-transforms/inline-styles/svg-inline-styles-005.html - /css/css-transforms/inline-styles/svg-inline-styles-006.html - /css/css-transforms/inline-styles/svg-inline-styles-010.html - /css/css-transforms/inline-styles/svg-inline-styles-013.html The following test fails because of the lack of width/height in SVG as described above but it also exposes gaps in our CSS tranform implementation. - /css/css-transforms/preserve3d-and-filter-with-perspective.html These tests failure because resvg doesn't handle the SVG without explicit width and height, but specified via CSS in the HTML. In addition, there are pixel differences between the ref due to antialiasing issues. - /css/css-transforms/matrix/svg-matrix-{005...008}.html - /css/css-transforms/matrix/svg-matrix-010.html - /css/css-transforms/matrix/svg-matrix-012.html - /css/css-transforms/matrix/svg-matrix-{015..069}.html - /css/css-transforms/rotate/svg-rotate-angle-45-001.html - /css/css-transforms/rotate/svg-rotate-angle-45-011.html - /css/css-transforms/rotate/svg-rotate-angle-45-022.html - /css/css-transforms/scale/svg-scale-006.html - /css/css-transforms/scale/svg-scale-007.html These tests seem to be failing due to some sort of antialiasing issue, where a transformed SVG element has a thin border that causes pixel differences compared to the solid colored reference. - /css/css-transforms/skewX/svg-skewx-001.html - /css/css-transforms/skewX/svg-skewx-006.html - /css/css-transforms/skewX/svg-skewx-011.html - /css/css-transforms/skewX/svg-skewx-016.html - /css/css-transforms/skewX/svg-skewx-021.html - /css/css-transforms/skewX/svg-skewxy-001.html - /css/css-transforms/skewY/svg-skewy-001.html - /css/css-transforms/skewY/svg-skewy-006.html - /css/css-transforms/skewY/svg-skewy-011.html - /css/css-transforms/skewY/svg-skewy-016.html - /css/css-transforms/skewY/svg-skewy-021.html These tests specify several SVG attributes such as transform, vector-effect etc via CSS in the HTML (rather than inline in SVG). The current implementation doesn't support this. - /css/css-transforms/transform-box/stroke-box-mutation-001.html - /css/css-transforms/transform-box/stroke-box-mutation-002.html - /css/css-transforms/transform-box/stroke-box-mutation-003.html - /css/css-transforms/transform-box/stroke-box-mutation-004.html - /css/css-transforms/transform-box/svgbox-stroke-box-002.html - /css/css-transforms/transform-box/svgbox-stroke-box-003.html - /css/css-transforms/transform-box/svgbox-stroke-box-004.html - /css/css-transforms/transform-box/svgbox-stroke-box-005.html These tests depend on 'transform-origin' specified on an element inside an SVG, but this transform is influenced by the 'tranform-box' set via CSS in the HTML itself (not the SVG). The current implementation doesn't support styling the SVG using document styles, so these tests just fail. - /css/css-transforms/transform-origin/svg-origin-relative-length-*.html These tests check the fallback behaviour when invalid syntax is encountered in the 'transform-origin' value. resvg doesn't correctly fallback to 0,0 causing the tests to fail. - /css/css-transforms/transform-origin/svg-origin-relative-length-invalid-001.html - /css/css-transforms/transform-origin/svg-origin-relative-length-invalid-002.html - /css/css-transforms/transform-origin/svg-origin-relative-length-invalid-003.html - /css/css-transforms/transform-origin/svg-origin-relative-length-invalid-004.html These tests use unimplemented Canvas APIs like 'beginLayer' and the 'CanvasFilter' constructor and hence fail at runtime. - /html/canvas/element/filters/2d.filter.canvasFilterObject.gaussianBlur.tentative.html - /html/canvas/element/filters/2d.filter.layers.gaussianBlur.tentative.html - /html/canvas/element/layers/2d.layer.anisotropic-blur.isotropic.tentative.html - /html/canvas/element/layers/2d.layer.anisotropic-blur.mostly-x.tentative.html - /html/canvas/element/layers/2d.layer.anisotropic-blur.mostly-y.tentative.html - /html/canvas/element/layers/2d.layer.anisotropic-blur.x-only.tentative.html - /html/canvas/element/layers/2d.layer.anisotropic-blur.y-only.tentative.html - /html/canvas/element/layers/2d.layer.css-filters.blur-and-shadow.tentative.html - /html/canvas/element/layers/2d.layer.css-filters.blur.tentative.html - /html/canvas/element/layers/2d.layer.css-filters.shadow.tentative.html - /html/canvas/element/layers/2d.layer.ctm.layer-filter.tentative.html - /html/canvas/offscreen/filters/2d.filter.canvasFilterObject.dropShadow.tentative.html - /html/canvas/offscreen/filters/2d.filter.canvasFilterObject.gaussianBlur.tentative.html - /html/canvas/offscreen/filters/2d.filter.layers.dropShadow.tentative.html - /html/canvas/offscreen/filters/2d.filter.layers.gaussianBlur.tentative.html - /html/canvas/offscreen/layers/2d.layer.anisotropic-blur.isotropic.tentative.html - /html/canvas/offscreen/layers/2d.layer.anisotropic-blur.mostly-x.tentative.html - /html/canvas/offscreen/layers/2d.layer.anisotropic-blur.mostly-y.tentative.html - /html/canvas/offscreen/layers/2d.layer.anisotropic-blur.x-only.tentative.html - /html/canvas/offscreen/layers/2d.layer.anisotropic-blur.y-only.tentative.html - /html/canvas/offscreen/layers/2d.layer.css-filters.blur-and-shadow.tentative.html - /html/canvas/offscreen/layers/2d.layer.css-filters.blur.tentative.html - /html/canvas/offscreen/layers/2d.layer.css-filters.shadow.tentative.html - /html/canvas/offscreen/layers/2d.layer.ctm.layer-filter.tentative.html These tests fail because resvg doesn't seem to honour the 'translate' CSS property specified on an SVG element using an inline 'style' attribute. - /css/css-transforms/translate/svg-translate-with-units.html - /css/css-transforms/translate/translate-and-transform-attribute-in-svg.html - /css/css-transforms/translate/translate-and-transform-css-property-in-svg.html - /css/css-transforms/translate/translate-in-svg.html These tests seem to fail due to the filter effect implementation in resvg either not being complete or spec compliant. - /css/filter-effects/feconvolve-divisor.html - /css/filter-effects/feconvolve-region-001.html - /css/filter-effects/feconvolve-region-002.html - /css/filter-effects/filter-subregion-01.html - /css/filter-effects/svg-feimage-002.html - /css/filter-effects/svg-feimage-003.html - /css/filter-effects/svg-feimage-004.html - /css/filter-effects/svg-feoffset-001.html The test /css/filter-effects/svg-feimage-004.html should ideally PASS but currently fails because we don't propagate height/width set using CSS in HTML element to the root SVG, so resvg uses the wrong dimensions when rendering the children of the SVG. These failures are due to deficienies in our current implementation i.e we don't support styling SVG elements using CSS in HTML. - /css/css-transforms/gradientTransform/svg-gradientTransform-combination-001.html - /css/selectors/sharing-in-svg-use.html The below test fails as our current implementation relies on resvg to tell us the intrinsic ratio of the SVG, but this doesn't always work correctly. - /css/css-sizing/svg-intrinsic-size-005.html This failure is due to lack of proper fallback to no-op transform in resvg when the `rotate()` syntax is specified with an invalid list e.g `rotate(90,)`. - /css/css-transforms/rotate/svg-rotate-3args-invalid-002.html This test only passes in CI and based on the raw log output, it seems that no text inside the SVG is rendered in the CI. This could be an font stack related issue. - /css/css-display/display-contents-svg-elements.html This test asserts that the CSP blocks loads triggered using `use` elements in SVG. It used to TIMEOUT as without inline SVG support, no CSP violation event was triggered. It fails now since the event is now triggered for the load of the SVG itself (our current implementation loads inline SVGs as serialized base64 data: urls). This doesn't match the blocked URL in the use element though. - /content-security-policy/img-src/svg-use-blocked.tentative.html Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
This commit is contained in:
parent
be7625fc1e
commit
4c05758ded
293 changed files with 653 additions and 156 deletions
|
@ -110,7 +110,6 @@ pub struct Preferences {
|
|||
pub dom_serviceworker_timeout_seconds: i64,
|
||||
pub dom_servo_helpers_enabled: bool,
|
||||
pub dom_servoparser_async_html_tokenizer_enabled: bool,
|
||||
pub dom_svg_enabled: bool,
|
||||
pub dom_testable_crash_enabled: bool,
|
||||
pub dom_testbinding_enabled: bool,
|
||||
pub dom_testbinding_prefcontrolled_enabled: bool,
|
||||
|
@ -290,7 +289,6 @@ impl Preferences {
|
|||
dom_serviceworker_timeout_seconds: 60,
|
||||
dom_servo_helpers_enabled: false,
|
||||
dom_servoparser_async_html_tokenizer_enabled: false,
|
||||
dom_svg_enabled: false,
|
||||
dom_testable_crash_enabled: false,
|
||||
dom_testbinding_enabled: false,
|
||||
dom_testbinding_prefcontrolled2_enabled: false,
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
use std::sync::Arc;
|
||||
|
||||
use embedder_traits::UntrustedNodeAddress;
|
||||
use euclid::Size2D;
|
||||
use fnv::FnvHashMap;
|
||||
use fonts::FontContext;
|
||||
|
@ -19,7 +20,7 @@ use parking_lot::{Mutex, RwLock};
|
|||
use pixels::RasterImage;
|
||||
use servo_url::{ImmutableOrigin, ServoUrl};
|
||||
use style::context::SharedStyleContext;
|
||||
use style::dom::OpaqueNode;
|
||||
use style::dom::{OpaqueNode, TNode};
|
||||
use style::values::computed::image::{Gradient, Image};
|
||||
use webrender_api::units::{DeviceIntSize, DeviceSize};
|
||||
|
||||
|
@ -84,6 +85,13 @@ pub(crate) struct ImageResolver {
|
|||
/// size determined by layout. This will be shared with the script thread.
|
||||
pub pending_rasterization_images: Mutex<Vec<PendingRasterizationImage>>,
|
||||
|
||||
/// A list of `SVGSVGElement`s encountered during layout that are not
|
||||
/// serialized yet. This is needed to support inline SVGs as they are treated
|
||||
/// as replaced elements and the layout is responsible for triggering the
|
||||
/// network load for the corresponding serialzed data: urls (similar to
|
||||
/// background images).
|
||||
pub pending_svg_elements_for_serialization: Mutex<Vec<UntrustedNodeAddress>>,
|
||||
|
||||
/// A shared reference to script's map of DOM nodes with animated images. This is used
|
||||
/// to manage image animations in script and inform the script about newly animating
|
||||
/// nodes.
|
||||
|
@ -103,6 +111,11 @@ impl Drop for ImageResolver {
|
|||
if !std::thread::panicking() {
|
||||
assert!(self.pending_images.lock().is_empty());
|
||||
assert!(self.pending_rasterization_images.lock().is_empty());
|
||||
assert!(
|
||||
self.pending_svg_elements_for_serialization
|
||||
.lock()
|
||||
.is_empty()
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -172,7 +185,7 @@ impl ImageResolver {
|
|||
}
|
||||
}
|
||||
|
||||
fn get_cached_image_for_url(
|
||||
pub(crate) fn get_cached_image_for_url(
|
||||
&self,
|
||||
node: OpaqueNode,
|
||||
url: ServoUrl,
|
||||
|
@ -232,6 +245,15 @@ impl ImageResolver {
|
|||
result
|
||||
}
|
||||
|
||||
pub(crate) fn queue_svg_element_for_serialization(
|
||||
&self,
|
||||
element: script::layout_dom::ServoLayoutNode<'_>,
|
||||
) {
|
||||
self.pending_svg_elements_for_serialization
|
||||
.lock()
|
||||
.push(element.opaque().into())
|
||||
}
|
||||
|
||||
pub(crate) fn resolve_image<'a>(
|
||||
&self,
|
||||
node: Option<OpaqueNode>,
|
||||
|
|
|
@ -12,7 +12,8 @@ use layout_api::wrapper_traits::{
|
|||
LayoutDataTrait, LayoutNode, ThreadSafeLayoutElement, ThreadSafeLayoutNode,
|
||||
};
|
||||
use layout_api::{
|
||||
GenericLayoutDataTrait, LayoutDamage, LayoutElementType, LayoutNodeType as ScriptLayoutNodeType,
|
||||
GenericLayoutDataTrait, LayoutDamage, LayoutElementType,
|
||||
LayoutNodeType as ScriptLayoutNodeType, SVGElementData,
|
||||
};
|
||||
use malloc_size_of_derive::MallocSizeOf;
|
||||
use net_traits::image_cache::Image;
|
||||
|
@ -232,6 +233,7 @@ pub(crate) trait NodeExt<'dom> {
|
|||
fn as_canvas(&self) -> Option<(CanvasInfo, PhysicalSize<f64>)>;
|
||||
fn as_iframe(&self) -> Option<(PipelineId, BrowsingContextId)>;
|
||||
fn as_video(&self) -> Option<(Option<webrender_api::ImageKey>, Option<PhysicalSize<f64>>)>;
|
||||
fn as_svg(&self) -> Option<SVGElementData>;
|
||||
fn as_typeless_object_with_data_attribute(&self) -> Option<String>;
|
||||
fn style(&self, context: &SharedStyleContext) -> ServoArc<ComputedValues>;
|
||||
|
||||
|
@ -273,6 +275,10 @@ impl<'dom> NodeExt<'dom> for ServoLayoutNode<'dom> {
|
|||
Some((resource, PhysicalSize::new(width, height)))
|
||||
}
|
||||
|
||||
fn as_svg(&self) -> Option<SVGElementData> {
|
||||
self.to_threadsafe().svg_data()
|
||||
}
|
||||
|
||||
fn as_video(&self) -> Option<(Option<webrender_api::ImageKey>, Option<PhysicalSize<f64>>)> {
|
||||
let node = self.to_threadsafe();
|
||||
let data = node.media_data()?;
|
||||
|
|
|
@ -704,6 +704,7 @@ impl LayoutThread {
|
|||
resolved_images_cache: self.resolved_images_cache.clone(),
|
||||
pending_images: Mutex::default(),
|
||||
pending_rasterization_images: Mutex::default(),
|
||||
pending_svg_elements_for_serialization: Mutex::default(),
|
||||
node_to_animating_image_map: reflow_request.node_to_animating_image_map.clone(),
|
||||
animation_timeline_value: reflow_request.animation_timeline_value,
|
||||
});
|
||||
|
@ -730,11 +731,14 @@ impl LayoutThread {
|
|||
let pending_images = std::mem::take(&mut *image_resolver.pending_images.lock());
|
||||
let pending_rasterization_images =
|
||||
std::mem::take(&mut *image_resolver.pending_rasterization_images.lock());
|
||||
let pending_svg_elements_for_serialization =
|
||||
std::mem::take(&mut *image_resolver.pending_svg_elements_for_serialization.lock());
|
||||
|
||||
Some(ReflowResult {
|
||||
reflow_phases_run,
|
||||
pending_images,
|
||||
pending_rasterization_images,
|
||||
pending_svg_elements_for_serialization,
|
||||
iframe_sizes: Some(iframe_sizes),
|
||||
})
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@ use embedder_traits::ViewportDetails;
|
|||
use euclid::{Scale, Size2D};
|
||||
use layout_api::IFrameSize;
|
||||
use malloc_size_of_derive::MallocSizeOf;
|
||||
use net_traits::image_cache::{Image, ImageOrMetadataAvailable, UsePlaceholder};
|
||||
use net_traits::image_cache::{Image, ImageOrMetadataAvailable, UsePlaceholder, VectorImage};
|
||||
use script::layout_dom::ServoLayoutNode;
|
||||
use servo_arc::Arc as ServoArc;
|
||||
use style::Zero;
|
||||
|
@ -117,6 +117,7 @@ pub(crate) enum ReplacedContentKind {
|
|||
IFrame(IFrameInfo),
|
||||
Canvas(CanvasInfo),
|
||||
Video(Option<VideoInfo>),
|
||||
SVGElement(VectorImage),
|
||||
}
|
||||
|
||||
impl ReplacedContents {
|
||||
|
@ -155,6 +156,39 @@ impl ReplacedContents {
|
|||
ReplacedContentKind::Video(image_key.map(|key| VideoInfo { image_key: key })),
|
||||
natural_size_in_dots,
|
||||
)
|
||||
} else if let Some(svg_data) = element.as_svg() {
|
||||
let svg_source = match svg_data.source {
|
||||
None => {
|
||||
// The SVGSVGElement is not yet serialized, so we add it to a list
|
||||
// and hand it over to script to peform the serialization.
|
||||
context
|
||||
.image_resolver
|
||||
.queue_svg_element_for_serialization(element);
|
||||
return None;
|
||||
},
|
||||
Some(Err(_)) => {
|
||||
// Don't attempt to serialize if previous attempt had errored.
|
||||
return None;
|
||||
},
|
||||
Some(Ok(svg_source)) => svg_source,
|
||||
};
|
||||
|
||||
let result = context
|
||||
.image_resolver
|
||||
.get_cached_image_for_url(element.opaque(), svg_source, UsePlaceholder::No)
|
||||
.ok()?;
|
||||
|
||||
let Image::Vector(vector_image) = result else {
|
||||
unreachable!("SVG element can't contain a raster image.")
|
||||
};
|
||||
let physical_size = PhysicalSize::new(
|
||||
vector_image.metadata.width as f64,
|
||||
vector_image.metadata.height as f64,
|
||||
);
|
||||
(
|
||||
ReplacedContentKind::SVGElement(vector_image),
|
||||
Some(physical_size),
|
||||
)
|
||||
} else {
|
||||
return None;
|
||||
}
|
||||
|
@ -392,6 +426,28 @@ impl ReplacedContents {
|
|||
image_key: Some(image_key),
|
||||
}))]
|
||||
},
|
||||
ReplacedContentKind::SVGElement(vector_image) => {
|
||||
let scale = layout_context.style_context.device_pixel_ratio();
|
||||
let width = object_fit_size.width.scale_by(scale.0).to_px();
|
||||
let height = object_fit_size.height.scale_by(scale.0).to_px();
|
||||
let size = Size2D::new(width, height);
|
||||
let tag = self.base_fragment_info.tag.unwrap();
|
||||
layout_context
|
||||
.image_resolver
|
||||
.rasterize_vector_image(vector_image.id, size, tag.node)
|
||||
.and_then(|image| image.id)
|
||||
.map(|image_key| {
|
||||
Fragment::Image(ArcRefCell::new(ImageFragment {
|
||||
base: self.base_fragment_info.into(),
|
||||
style: style.clone(),
|
||||
rect,
|
||||
clip,
|
||||
image_key: Some(image_key),
|
||||
}))
|
||||
})
|
||||
.into_iter()
|
||||
.collect()
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -41,6 +41,15 @@ use crate::resource_thread::CoreResourceThreadPool;
|
|||
// something in higher resolution.
|
||||
const FALLBACK_RIPPY: &[u8] = include_bytes!("../../resources/rippy.png");
|
||||
|
||||
/// The current SVG stack relies on `resvg` to provide the natural dimensions of
|
||||
/// the SVG, which it automatically infers from the width/height/viewBox properties
|
||||
/// of the SVG. Since these can be arbitrarily large, this can cause us to allocate
|
||||
/// a pixmap with very large dimensions leading to the process being killed due to
|
||||
/// memory exhaustion. For example, the `/css/css-transforms/perspective-svg-001.html`
|
||||
/// test uses very large values for viewBox. Hence, we just clamp the maximum
|
||||
/// width/height of the pixmap allocated for rasterization.
|
||||
const MAX_SVG_PIXMAP_DIMENSION: u32 = 5000;
|
||||
|
||||
//
|
||||
// TODO(gw): Remaining work on image cache:
|
||||
// * Make use of the prefetch support in various parts of the code.
|
||||
|
@ -907,8 +916,16 @@ impl ImageCache for ImageCacheImpl {
|
|||
self.thread_pool.spawn(move || {
|
||||
let natural_size = vector_image.svg_tree.size().to_int_size();
|
||||
let tinyskia_requested_size = {
|
||||
let width = requested_size.width.try_into().unwrap_or(0);
|
||||
let height = requested_size.height.try_into().unwrap_or(0);
|
||||
let width = requested_size
|
||||
.width
|
||||
.try_into()
|
||||
.unwrap_or(0)
|
||||
.min(MAX_SVG_PIXMAP_DIMENSION);
|
||||
let height = requested_size
|
||||
.height
|
||||
.try_into()
|
||||
.unwrap_or(0)
|
||||
.min(MAX_SVG_PIXMAP_DIMENSION);
|
||||
tiny_skia::IntSize::from_wh(width, height).unwrap_or(natural_size)
|
||||
};
|
||||
let transform = tiny_skia::Transform::from_scale(
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
use html5ever::{LocalName, Prefix, QualName, local_name, ns};
|
||||
use js::rust::HandleObject;
|
||||
use servo_config::pref;
|
||||
|
||||
use crate::dom::bindings::error::{report_pending_exception, throw_dom_exception};
|
||||
use crate::dom::bindings::reflector::DomGlobal;
|
||||
|
@ -110,10 +109,6 @@ fn create_svg_element(
|
|||
})
|
||||
);
|
||||
|
||||
if !pref!(dom_svg_enabled) {
|
||||
return Element::new(name.local, name.ns, prefix, document, proto, CanGc::note());
|
||||
}
|
||||
|
||||
match name.local {
|
||||
local_name!("image") => make!(SVGImageElement),
|
||||
local_name!("svg") => make!(SVGSVGElement),
|
||||
|
|
|
@ -27,7 +27,7 @@ use js::rust::HandleObject;
|
|||
use keyboard_types::Modifiers;
|
||||
use layout_api::{
|
||||
GenericLayoutData, HTMLCanvasData, HTMLMediaData, LayoutElementType, LayoutNodeType, QueryMsg,
|
||||
SVGSVGData, StyleData, TrustedNodeAddress,
|
||||
SVGElementData, StyleData, TrustedNodeAddress,
|
||||
};
|
||||
use libc::{self, c_void, uintptr_t};
|
||||
use malloc_size_of::{MallocSizeOf, MallocSizeOfOps};
|
||||
|
@ -1673,7 +1673,7 @@ pub(crate) trait LayoutNodeHelpers<'dom> {
|
|||
fn image_data(self) -> Option<(Option<Image>, Option<ImageMetadata>)>;
|
||||
fn canvas_data(self) -> Option<HTMLCanvasData>;
|
||||
fn media_data(self) -> Option<HTMLMediaData>;
|
||||
fn svg_data(self) -> Option<SVGSVGData>;
|
||||
fn svg_data(self) -> Option<SVGElementData>;
|
||||
fn iframe_browsing_context_id(self) -> Option<BrowsingContextId>;
|
||||
fn iframe_pipeline_id(self) -> Option<PipelineId>;
|
||||
fn opaque(self) -> OpaqueNode;
|
||||
|
@ -1962,7 +1962,7 @@ impl<'dom> LayoutNodeHelpers<'dom> for LayoutDom<'dom, Node> {
|
|||
.map(|media| media.data())
|
||||
}
|
||||
|
||||
fn svg_data(self) -> Option<SVGSVGData> {
|
||||
fn svg_data(self) -> Option<SVGElementData> {
|
||||
self.downcast::<SVGSVGElement>().map(|svg| svg.data())
|
||||
}
|
||||
|
||||
|
|
|
@ -2,29 +2,34 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use std::cell::RefCell;
|
||||
|
||||
use base64::Engine as _;
|
||||
use dom_struct::dom_struct;
|
||||
use html5ever::{LocalName, Prefix, local_name, ns};
|
||||
use html5ever::{LocalName, Prefix};
|
||||
use js::rust::HandleObject;
|
||||
use layout_api::SVGSVGData;
|
||||
use style::attr::AttrValue;
|
||||
use layout_api::SVGElementData;
|
||||
use servo_url::ServoUrl;
|
||||
use xml5ever::serialize::TraversalScope;
|
||||
|
||||
use crate::dom::attr::Attr;
|
||||
use crate::dom::bindings::inheritance::Castable;
|
||||
use crate::dom::bindings::root::{DomRoot, LayoutDom};
|
||||
use crate::dom::bindings::str::DOMString;
|
||||
use crate::dom::document::Document;
|
||||
use crate::dom::element::{AttributeMutation, Element, LayoutElementHelpers};
|
||||
use crate::dom::element::AttributeMutation;
|
||||
use crate::dom::node::Node;
|
||||
use crate::dom::svggraphicselement::SVGGraphicsElement;
|
||||
use crate::dom::virtualmethods::VirtualMethods;
|
||||
use crate::script_runtime::CanGc;
|
||||
|
||||
const DEFAULT_WIDTH: u32 = 300;
|
||||
const DEFAULT_HEIGHT: u32 = 150;
|
||||
|
||||
#[dom_struct]
|
||||
pub(crate) struct SVGSVGElement {
|
||||
svggraphicselement: SVGGraphicsElement,
|
||||
// The XML source of subtree rooted at this SVG element, serialized into
|
||||
// a base64 encoded `data:` url. This is cached to avoid recomputation
|
||||
// on each layout and must be invalidated when the subtree changes.
|
||||
#[no_trace]
|
||||
cached_serialized_data_url: RefCell<Option<Result<ServoUrl, ()>>>,
|
||||
}
|
||||
|
||||
impl SVGSVGElement {
|
||||
|
@ -35,6 +40,7 @@ impl SVGSVGElement {
|
|||
) -> SVGSVGElement {
|
||||
SVGSVGElement {
|
||||
svggraphicselement: SVGGraphicsElement::new_inherited(local_name, prefix, document),
|
||||
cached_serialized_data_url: Default::default(),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -53,23 +59,42 @@ impl SVGSVGElement {
|
|||
can_gc,
|
||||
)
|
||||
}
|
||||
|
||||
pub(crate) fn serialize_and_cache_subtree(&self) {
|
||||
let Ok(xml_source) = self
|
||||
.upcast::<Node>()
|
||||
.xml_serialize(TraversalScope::IncludeNode)
|
||||
else {
|
||||
*self.cached_serialized_data_url.borrow_mut() = Some(Err(()));
|
||||
return;
|
||||
};
|
||||
|
||||
let xml_source: String = xml_source.into();
|
||||
let base64_encoded_source = base64::engine::general_purpose::STANDARD.encode(xml_source);
|
||||
let data_url = format!("data:image/svg+xml;base64,{}", base64_encoded_source);
|
||||
match ServoUrl::parse(&data_url) {
|
||||
Ok(url) => *self.cached_serialized_data_url.borrow_mut() = Some(Ok(url)),
|
||||
Err(error) => error!("Unable to parse serialized SVG data url: {error}"),
|
||||
};
|
||||
}
|
||||
|
||||
fn invalidate_cached_serialized_subtree(&self) {
|
||||
*self.cached_serialized_data_url.borrow_mut() = None;
|
||||
}
|
||||
}
|
||||
|
||||
pub(crate) trait LayoutSVGSVGElementHelpers {
|
||||
fn data(self) -> SVGSVGData;
|
||||
fn data(self) -> SVGElementData;
|
||||
}
|
||||
|
||||
impl LayoutSVGSVGElementHelpers for LayoutDom<'_, SVGSVGElement> {
|
||||
fn data(self) -> SVGSVGData {
|
||||
let width_attr = self
|
||||
.upcast::<Element>()
|
||||
.get_attr_for_layout(&ns!(), &local_name!("width"));
|
||||
let height_attr = self
|
||||
.upcast::<Element>()
|
||||
.get_attr_for_layout(&ns!(), &local_name!("height"));
|
||||
SVGSVGData {
|
||||
width: width_attr.map_or(DEFAULT_WIDTH, |val| val.as_uint()),
|
||||
height: height_attr.map_or(DEFAULT_HEIGHT, |val| val.as_uint()),
|
||||
fn data(self) -> SVGElementData {
|
||||
SVGElementData {
|
||||
source: self
|
||||
.unsafe_get()
|
||||
.cached_serialized_data_url
|
||||
.borrow()
|
||||
.clone(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -83,16 +108,15 @@ impl VirtualMethods for SVGSVGElement {
|
|||
self.super_type()
|
||||
.unwrap()
|
||||
.attribute_mutated(attr, mutation, can_gc);
|
||||
|
||||
self.invalidate_cached_serialized_subtree();
|
||||
}
|
||||
|
||||
fn parse_plain_attribute(&self, name: &LocalName, value: DOMString) -> AttrValue {
|
||||
match *name {
|
||||
local_name!("width") => AttrValue::from_u32(value.into(), DEFAULT_WIDTH),
|
||||
local_name!("height") => AttrValue::from_u32(value.into(), DEFAULT_HEIGHT),
|
||||
_ => self
|
||||
.super_type()
|
||||
.unwrap()
|
||||
.parse_plain_attribute(name, value),
|
||||
fn children_changed(&self, mutation: &super::node::ChildrenMutation) {
|
||||
if let Some(super_type) = self.super_type() {
|
||||
super_type.children_changed(mutation);
|
||||
}
|
||||
|
||||
self.invalidate_cached_serialized_subtree();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -94,6 +94,7 @@ use webrender_api::units::{DeviceIntSize, DevicePixel, LayoutPixel, LayoutPoint}
|
|||
|
||||
use super::bindings::codegen::Bindings::MessagePortBinding::StructuredSerializeOptions;
|
||||
use super::bindings::trace::HashMapTracedValues;
|
||||
use super::types::SVGSVGElement;
|
||||
use crate::dom::bindings::cell::{DomRefCell, Ref};
|
||||
use crate::dom::bindings::codegen::Bindings::DocumentBinding::{
|
||||
DocumentMethods, DocumentReadyState, NamedPropertyValue,
|
||||
|
@ -2269,6 +2270,7 @@ impl Window {
|
|||
self.handle_pending_images_post_reflow(
|
||||
reflow_result.pending_images,
|
||||
reflow_result.pending_rasterization_images,
|
||||
reflow_result.pending_svg_elements_for_serialization,
|
||||
);
|
||||
|
||||
if let Some(iframe_sizes) = reflow_result.iframe_sizes {
|
||||
|
@ -3040,6 +3042,7 @@ impl Window {
|
|||
&self,
|
||||
pending_images: Vec<PendingImage>,
|
||||
pending_rasterization_images: Vec<PendingRasterizationImage>,
|
||||
pending_svg_element_for_serialization: Vec<UntrustedNodeAddress>,
|
||||
) {
|
||||
let pipeline_id = self.pipeline_id();
|
||||
for image in pending_images {
|
||||
|
@ -3088,6 +3091,13 @@ impl Window {
|
|||
nodes.push(Dom::from_ref(&*node));
|
||||
}
|
||||
}
|
||||
|
||||
for node in pending_svg_element_for_serialization.into_iter() {
|
||||
let node = unsafe { from_untrusted_node_address(node) };
|
||||
let svg = node.downcast::<SVGSVGElement>().unwrap();
|
||||
svg.serialize_and_cache_subtree();
|
||||
node.dirty(NodeDamage::Other);
|
||||
}
|
||||
}
|
||||
|
||||
pub fn handle_refresh_cursor(&self, cursor_position: Point2D<f32, CSSPixel>) {
|
||||
|
|
|
@ -12,7 +12,7 @@ use fonts_traits::ByteIndex;
|
|||
use html5ever::{local_name, ns};
|
||||
use layout_api::wrapper_traits::{LayoutDataTrait, LayoutNode, ThreadSafeLayoutNode};
|
||||
use layout_api::{
|
||||
GenericLayoutData, HTMLCanvasData, HTMLMediaData, LayoutNodeType, SVGSVGData, StyleData,
|
||||
GenericLayoutData, HTMLCanvasData, HTMLMediaData, LayoutNodeType, SVGElementData, StyleData,
|
||||
TrustedNodeAddress,
|
||||
};
|
||||
use net_traits::image_cache::Image;
|
||||
|
@ -399,7 +399,7 @@ impl<'dom> ThreadSafeLayoutNode<'dom> for ServoThreadSafeLayoutNode<'dom> {
|
|||
this.media_data()
|
||||
}
|
||||
|
||||
fn svg_data(&self) -> Option<SVGSVGData> {
|
||||
fn svg_data(&self) -> Option<SVGElementData> {
|
||||
let this = unsafe { self.get_jsmanaged() };
|
||||
this.svg_data()
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://svgwg.org/svg2-draft/types.html#InterfaceSVGElement
|
||||
[Exposed=Window, Pref="dom_svg_enabled"]
|
||||
[Exposed=Window]
|
||||
interface SVGElement : Element {
|
||||
|
||||
//[SameObject] readonly attribute SVGAnimatedString className;
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
// boolean clipped = false;
|
||||
//};
|
||||
|
||||
[Exposed=Window, Abstract, Pref="dom_svg_enabled"]
|
||||
[Exposed=Window, Abstract]
|
||||
interface SVGGraphicsElement : SVGElement {
|
||||
//[SameObject] readonly attribute SVGAnimatedTransformList transform;
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://svgwg.org/svg2-draft/embedded.html#InterfaceSVGImageElement
|
||||
[Exposed=Window, Pref="dom_svg_enabled"]
|
||||
[Exposed=Window]
|
||||
interface SVGImageElement : SVGGraphicsElement {
|
||||
//[SameObject] readonly attribute SVGAnimatedLength x;
|
||||
//[SameObject] readonly attribute SVGAnimatedLength y;
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
// https://svgwg.org/svg2-draft/struct.html#InterfaceSVGSVGElement
|
||||
[Exposed=Window, Pref="dom_svg_enabled"]
|
||||
[Exposed=Window]
|
||||
interface SVGSVGElement : SVGGraphicsElement {
|
||||
|
||||
//[SameObject] readonly attribute SVGAnimatedLength x;
|
||||
|
|
|
@ -132,9 +132,9 @@ pub struct HTMLCanvasData {
|
|||
pub height: u32,
|
||||
}
|
||||
|
||||
pub struct SVGSVGData {
|
||||
pub width: u32,
|
||||
pub height: u32,
|
||||
pub struct SVGElementData {
|
||||
/// The SVG's XML source represented as a base64 encoded `data:` url.
|
||||
pub source: Option<Result<ServoUrl, ()>>,
|
||||
}
|
||||
|
||||
/// The address of a node known to be valid. These are sent from script to layout.
|
||||
|
@ -395,6 +395,10 @@ pub struct ReflowResult {
|
|||
pub pending_images: Vec<PendingImage>,
|
||||
/// The list of vector images that were encountered that still need to be rasterized.
|
||||
pub pending_rasterization_images: Vec<PendingRasterizationImage>,
|
||||
/// The list of `SVGSVGElement`s encountered in the DOM that need to be serialized.
|
||||
/// This is needed to support inline SVGs as the serialization needs to happen on
|
||||
/// the script thread.
|
||||
pub pending_svg_elements_for_serialization: Vec<UntrustedNodeAddress>,
|
||||
/// The list of iframes in this layout and their sizes, used in order
|
||||
/// to communicate them with the Constellation and also the `Window`
|
||||
/// element of their content pages. Returning None if incremental reflow
|
||||
|
|
|
@ -26,7 +26,7 @@ use style::stylist::RuleInclusion;
|
|||
|
||||
use crate::{
|
||||
FragmentType, GenericLayoutData, GenericLayoutDataTrait, HTMLCanvasData, HTMLMediaData,
|
||||
LayoutNodeType, SVGSVGData, StyleData,
|
||||
LayoutNodeType, SVGElementData, StyleData,
|
||||
};
|
||||
|
||||
pub trait LayoutDataTrait: GenericLayoutDataTrait + Default + Send + Sync + 'static {}
|
||||
|
@ -226,7 +226,7 @@ pub trait ThreadSafeLayoutNode<'dom>: Clone + Copy + Debug + NodeInfo + PartialE
|
|||
|
||||
fn canvas_data(&self) -> Option<HTMLCanvasData>;
|
||||
|
||||
fn svg_data(&self) -> Option<SVGSVGData>;
|
||||
fn svg_data(&self) -> Option<SVGElementData>;
|
||||
|
||||
fn media_data(&self) -> Option<HTMLMediaData>;
|
||||
|
||||
|
|
|
@ -596,7 +596,6 @@ pub(crate) fn parse_command_line_arguments(args: Vec<String>) -> ArgumentParsing
|
|||
"dom_offscreen_canvas_enabled",
|
||||
"dom_permissions_enabled",
|
||||
"dom_resize_observer_enabled",
|
||||
"dom_svg_enabled",
|
||||
"dom_trusted_types_enabled",
|
||||
"dom_webgl2_enabled",
|
||||
"dom_webgpu_enabled",
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
[svg-use-blocked.tentative.html]
|
||||
expected: TIMEOUT
|
||||
[Blocked SVG <use> element]
|
||||
expected: TIMEOUT
|
||||
expected: FAIL
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
[float-replaced-width-008.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[float-replaced-width-009.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[inline-svg-margin-padding-border.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[inline-block-replaced-width-003.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[inline-replaced-width-003.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-003.xht]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003a.xht.ini
vendored
Normal file
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003a.xht.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[absolute-replaced-width-003a.xht]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003b.xht.ini
vendored
Normal file
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003b.xht.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[absolute-replaced-width-003b.xht]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003c.xht.ini
vendored
Normal file
2
tests/wpt/meta/css/CSS2/positioning/absolute-replaced-width-003c.xht.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[absolute-replaced-width-003c.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-004.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-010.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-011.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-024.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-025.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-031.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-032.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-038.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-039.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-052.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-053.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-066.xht]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[absolute-replaced-width-067.xht]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg-basic.html.ini
vendored
Normal file
2
tests/wpt/meta/css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg-basic.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[mix-blend-mode-plus-lighter-svg-basic.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg.html.ini
vendored
Normal file
2
tests/wpt/meta/css/compositing/mix-blend-mode/mix-blend-mode-plus-lighter-svg.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[mix-blend-mode-plus-lighter-svg.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[mix-blend-mode-svg.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[mix-blend-mode-svg-rectangle.html]
|
||||
expected: FAIL
|
14
tests/wpt/meta/css/css-borders/tentative/border-shape/border-shape-stroke.html.ini
vendored
Normal file
14
tests/wpt/meta/css/css-borders/tentative/border-shape/border-shape-stroke.html.ini
vendored
Normal file
|
@ -0,0 +1,14 @@
|
|||
[border-shape-stroke.html?class=beveljoin]
|
||||
expected: FAIL
|
||||
|
||||
[border-shape-stroke.html?class=roundjoin]
|
||||
expected: FAIL
|
||||
|
||||
[border-shape-stroke.html?class=nostroke]
|
||||
expected: FAIL
|
||||
|
||||
[border-shape-stroke.html?class=percent]
|
||||
expected: FAIL
|
||||
|
||||
[border-shape-stroke.html?class=solid]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[svg-foreignobject-no-size-container.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[svg-g-no-size-container.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[display-contents-svg-elements.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[svg-root-as-flex-item-001.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-002.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[masonry-columns-item-containing-block-is-grid-content-width.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[clip-path-borderBox-1a.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-borderBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-borderBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-borderBox-1b.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[clip-path-borderBox-1c.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-contentBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-contentBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-contentBox-1b.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-contentBox-1c.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-contentBox-1c.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-contentBox-1c.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-fillBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-fillBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-fillBox-1b.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-marginBox-1a.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-marginBox-1a.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-marginBox-1a.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-paddingBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-paddingBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-paddingBox-1b.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-strokeBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-strokeBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-strokeBox-1b.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-strokeBox-1c.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-strokeBox-1c.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-strokeBox-1c.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1a.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1a.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-viewBox-1a.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1b.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1b.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-viewBox-1b.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1d.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/clip-path-viewBox-1d.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[clip-path-viewBox-1d.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/svg-clip-path-circle-offset.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/svg-clip-path-circle-offset.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-clip-path-circle-offset.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-masking/clip-path/svg-clip-path-ellipse-offset.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-masking/clip-path/svg-clip-path-ellipse-offset.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-clip-path-ellipse-offset.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[display-flex-svg-overflow-default.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-007.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-008.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-011.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-015.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-element-016.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[intrinsic-percent-replaced-020.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-aspect-ratio-stretch-fit-001.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-aspect-ratio-stretch-fit-002.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[replaced-aspect-ratio-stretch-fit-003.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-sizing/svg-intrinsic-size-005.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-sizing/svg-intrinsic-size-005.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-intrinsic-size-005.html]
|
||||
expected: FAIL
|
|
@ -1,2 +0,0 @@
|
|||
[2d-rotate-001.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-001.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-001.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-document-styles-001.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-002.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-002.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-document-styles-002.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-003.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-003.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-document-styles-003.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-004.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-004.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-document-styles-004.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-012.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/document-styles/svg-document-styles-012.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-document-styles-012.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-001.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-001.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-external-styles-001.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-002.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-002.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-external-styles-002.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-003.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-003.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-external-styles-003.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-004.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-004.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-external-styles-004.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-014.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/external-styles/svg-external-styles-014.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-external-styles-014.html]
|
||||
expected: FAIL
|
|
@ -0,0 +1,2 @@
|
|||
[svg-gradientTransform-combination-001.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-008.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-008.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-group-008.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-009.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-009.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-group-009.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-011.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-group-011.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-group-011.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-008.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-008.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-008.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-009.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-009.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-009.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-013.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-013.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-013.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-014.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-014.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-014.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-018.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-018.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-018.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-019.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-019.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-019.html]
|
||||
expected: FAIL
|
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-021.html.ini
vendored
Normal file
2
tests/wpt/meta/css/css-transforms/group/svg-transform-nested-021.html.ini
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
[svg-transform-nested-021.html]
|
||||
expected: FAIL
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue