SVGFilterElement: width 屬性
SVGFilterElement 介面的只讀屬性 width 以 SVGAnimatedLength 物件的形式描述了 SVG 濾鏡圖元的水平尺寸。
它反映了 <filter> 元素的 width 屬性。該屬性是相對於濾鏡區域寬度的 <length> 或 <percentage>。預設值為 100%。屬性值是以使用者座標系單位表示的長度。
值
一個 SVGAnimatedLength 物件。
示例
js
const filter = document.querySelector("filter");
const horizontalSize = filter.width;
console.log(horizontalSize.baseVal.value); // the `width` value
規範
| 規範 |
|---|
| 濾鏡效果模組第 1 級 # dom-svgfilterelement-width |
瀏覽器相容性
載入中…
另見
- SVG 教程:濾鏡效果
- SVG 濾鏡基元屬性
- CSS
<blend-mode>資料型別 - CSS
mix-blend-mode屬性