I solve the problem of generating svg images, while it is important to arrange the elements correctly (under the image) in the overall image. It is very convenient to place images using the css grid, but unfortunately, it is impossible to use the css grid for svg sub-elements. At least, it does not work with a simple transfer of css properties.
So all the same, you can somehow use the css grid for svg, or is it just not implemented?
Example implementation of grid css: https://jsfiddle.net/Nic34/yh61nxru/
#wrapp { display: grid; grid: "w1 w2" "w1 w3"; width: 100px; height: 100px; grid-gap: 10px; background: burlywood; background: burlywood; border: 10px solid burlywood; } #wrapp div { background: bisque; } #w1 { grid-area: w1; } #w2 { grid-area: w2; } #w3 { grid-area: w3; } <div id=wrapp> <div id='w1'>1</div> <div id='w2'>2</div> <div id='w3'>3</div> </div> Example for svg: https://jsfiddle.net/Nic34/adm0ogy9/
#wrapp { display: grid; grid: "w1 w2" "w1 w3"; width: 100px; height: 100px; grid-gap: 10px; background: burlywood; background: burlywood; border: 10px solid burlywood; } #wrapp div { background: bisque; } #w1 { grid-area: w1; } #w2 { grid-area: w2; } #w3 { grid-area: w3; } <svg id=wrapp viewBox="0, 0, 100, 100"> <g id='w1'>1</g> <g id='w2'>2</g> <g id='w3'>3</g> </svg>