Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Align use element inside the svg element

I am trying to align use element inside svg element, to extreme left. I tried text-align: left and text-anchor: start but still the use element is in middle of the svg element.

<div class="guy">
    <svg><use xlink:href="#guy"></use></svg>
</div>

Here is the fiddle

like image 875
Mr_Green Avatar asked Mar 15 '23 02:03

Mr_Green


1 Answers

Add preserveAspectRatio="xMinYMid" e.g.

<div style="display: none"><svg id="guy" viewBox="0 0 123.6 205.2" preserveAspectRatio="xMinYMid">

or as a fiddle

like image 102
Robert Longson Avatar answered Mar 28 '23 06:03

Robert Longson