diff --git a/src/display/draw_layer.js b/src/display/draw_layer.js index 3d4fa72d6..ad96bafc0 100644 --- a/src/display/draw_layer.js +++ b/src/display/draw_layer.js @@ -154,6 +154,7 @@ class DrawLayer { use.setAttribute("stroke", "none"); use.setAttribute("fill", "black"); use.setAttribute("fill-rule", "nonzero"); + use.classList.add("mask"); } const use1 = DrawLayer._svgFactory.createElement("use"); diff --git a/web/draw_layer_builder.css b/web/draw_layer_builder.css index 4fa803959..2adeebc81 100644 --- a/web/draw_layer_builder.css +++ b/web/draw_layer_builder.css @@ -18,19 +18,22 @@ transform: none; &[data-main-rotation="90"] { - use:not(.clip) { + mask, + use:not(.clip, .mask) { transform: matrix(0, 1, -1, 0, 1, 0); } } &[data-main-rotation="180"] { - use:not(.clip) { + mask, + use:not(.clip, .mask) { transform: matrix(-1, 0, 0, -1, 1, 1); } } &[data-main-rotation="270"] { - use:not(.clip) { + mask, + use:not(.clip, .mask) { transform: matrix(0, -1, 1, 0, 0, 1); } }