Web/API/SVGMaskElement

From Get docs


The SVGMaskElement interface provides access to the properties of <mask> elements, as well as methods to manipulate them.

Properties

This interface also inherits properties from its parent, SVGElement.

SVGMaskElement.maskUnits Read only
An SVGAnimatedEnumeration corresponding to the maskUnits attribute of the given <mask> element. Takes one of the constants defined in SVGUnitTypes.
SVGMaskElement.maskContentUnits Read only
An SVGAnimatedEnumeration corresponding to the maskContentUnits attribute of the given <mask> element. Takes one of the constants defined in SVGUnitTypes.
SVGMaskElement.x Read only
An SVGAnimatedLength corresponding to the x attribute of the given <mask> element.
SVGMaskElement.y Read only
An SVGAnimatedLength corresponding to the y attribute of the given <mask> element.
SVGMaskElement.width Read only
An SVGAnimatedLength corresponding to the width attribute of the given <mask> element.
SVGMaskElement.height Read only
An SVGAnimatedLength corresponding to the height attribute of the given <mask> element.

Methods

This interface doesn't implement any specific methods, but inherits methods from its parent interface, SVGElement.

Specifications

Specification Status Comment
CSS Masking Module Level 1The definition of 'SVGMaskElement' in that specification. Candidate Recommendation Removed the implemented interfaces SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, and SVGTransformable.
Scalable Vector Graphics (SVG) 1.1 (Second Edition)The definition of 'SVGMaskElement' in that specification. Recommendation Initial definition

Browser compatibility

Update compatibility data on GitHub

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
SVGMaskElement Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

Full support 9

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

height Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

maskContentUnits Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

maskUnits Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

width Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

x Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

y Chrome

Full support Yes

Edge

Full support 12

Firefox

Full support Yes

IE

?

Opera

Full support Yes

Safari

Full support Yes

WebView Android

Full support Yes

Chrome Android

Full support Yes

Firefox Android

Full support Yes

Opera Android

Full support Yes

Safari iOS

Full support Yes

Samsung Internet Android

Full support Yes

Legend

Full support  
Full support
Compatibility unknown  
Compatibility unknown


See also