Specification link: 5.11 DOM interfaces

struct-defs-01-t ← index → struct-dom-02-b

Tests that contain the draft-watermark are under development and may be incorrectly testing a feature.

# struct-dom-01-b.svg
SVG Image | PNG Image

## Operator Script

Run the test. No interaction required.

## Pass Criteria

The test passes if:

- The text "This document's root identifier is: svg-root" is shown.
- A green rectangle with a black shadow is shown.

## Test Description

Verify the basic capability to handle the SVG DOM API.

The test is composed of a top level svg element with an 'onload' event handler and a rect element. Both the svg and the rect elements have an identifier. The 'onload' handler invokes SVG-specific DOM API methods which use these identifiers.

First, the handler gets the SVG element owner of the rect element and checks it has the expected identifier. Then, the handler accesses the coordinates of the rect element and uses them to build a 'shadow' rectangle under the existing one. Finally, the 'shadow' rectangle is created using the SVGSVGElement's createSVGRect method.

struct-defs-01-t ← index → struct-dom-02-b