SVGFEComponentTransferElement: y property
Baseline
Widely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2015.
Thuộc tính chỉ đọc y của giao diện SVGFEComponentTransferElement mô tả tọa độ dọc của vị trí primitive bộ lọc SVG dưới dạng SVGAnimatedLength.
Nó phản ánh giá trị thuộc tính bộ lọc primitive y của phần tử <feComponentTransfer>. Thuộc tính là <length> hoặc <percentage>. <coordinate> là độ dài trong hệ tọa độ người dùng xác định khoảng cách từ gốc bộ lọc dọc theo trục y. Nếu thuộc tính y là giá trị phần trăm, giá trị thuộc tính là tương đối so với chiều cao của vùng bộ lọc theo đơn vị hệ tọa độ người dùng. Giá trị mặc định là 0.
Giá trị
Một SVGAnimatedLength.
Ví dụ
js
const feComponentTransfer = document.querySelector("feComponentTransfer");
const topPosition = feComponentTransfer.y;
console.log(topPosition.baseVal.value); // giá trị `y`
Thông số kỹ thuật
| Specification |
|---|
| Filter Effects Module Level 1> # dom-svgfilterprimitivestandardattributes-y> |