Whenever I insert SVG into my grid layout it 1) doesn't center, and 2) breaks the layout of the grid. How do I fix this please, so that the play icon shows in the same way the play text does.
Here's the layout that's breaking:
.body { background-color: hsl(0,0%,10%); color: white; font-size: 32px; }
.center_children { display: flex; justify-content: center; }
.timer
{
width: 12rem; height: 12rem; border-radius: 50%;
background-color: hsl(0, 50%, 50%);
display:grid; grid-template-rows: 2fr 1fr; gap: 1.5rem;
}
<div class="body">
<br />
<div class="timer">
<div class="center_children">
<div class="play">Play</div>
</div>
<div class="center_children">1:39</div>
</div>
<br />
</div>
<br /><br />
<div class="body">
<br />
<div class="timer">
<div class="center_children">
<div class="play">
<svg width="100%" height="100%" viewBox="0 0 100 100" ><polygon points="0,0 75,50 0,100" style="fill:#fff;" /></svg>
</div>
</div>
<div class="center_children">1:39</div>
</div>
<br />
</div>