Prune a cloned SVG subtree to match what is actually visible on screen.
Walks the live original and its clone in parallel and drops clone nodes
whose original element is hidden (display:none / visibility:hidden / opacity 0),
so the exported SVG reflects the current layer state without needing the
engine's CSS rules embedded.
Prune a cloned SVG subtree to match what is actually visible on screen. Walks the live
originaland itsclonein parallel and drops clone nodes whose original element is hidden (display:none / visibility:hidden / opacity 0), so the exported SVG reflects the current layer state without needing the engine's CSS rules embedded.