Status: PASS | Duration: 5ms | Subtests: 1/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi
/css/css-viewport/zoom/mask-border-width.html
<!DOCTYPE html> <title>CSS zoom applies to mask-border-width when specified and inherited</title> <link rel="help" href="https://drafts.csswg.org/css-viewport/"> <link rel="help" href="https://drafts.csswg.org/css-masking-1/#the-mask-border-width"> <link rel="match" href="mask-border-width-ref.html"> <style> .box { width: 50px; height: 50px; background-color: red; mask-border-slice: 10; mask-border-source: linear-gradient(45deg, pink, blue, white, black, green); mask-border-width: 8px; margin: 10px; } .zoom { zoom: 2; } </style> <div class="box"></div> <div class="zoom"> <div class="box"></div> </div> <div class="zoom box"></div>
/css/css-viewport/zoom/mask-border-width-ref.html
<!DOCTYPE html> <style> body { --scale: 1; } .box { width: calc(50px * var(--scale)); height: calc(50px * var(--scale)); background-color: red; mask-border-slice: 10; mask-border-source: linear-gradient(45deg, pink, blue, white, black, green); mask-border-width: calc(8px * var(--scale)); margin: calc(10px * var(--scale)); } .zoom { --scale: 2; } </style> <div class="box"></div> <div class="zoom"> <div class="box"></div> </div> <div class="zoom box"></div>