How does spotify center their middle play svg?

How do they center it?

What is used?

It uses button instead of a div, and so I think that has something to do with it.

Spotify:
https://jsfiddle.net/pdvL5w16/1/

My Code:
https://jsfiddle.net/hsekcr5d/6/

I’m just guessing and would first of all remove the hard-coded statement ***margin-left: 180px;***.

I would then treat the button similar to text by using text-align: center then look to how to set the vertical position middle.

I managed to make a replication here.
https://jsfiddle.net/bwg251uv/2/

Is the new version doing everything you want it to do?

Here’s a full page version which I far prefer because it is easier to validate :slight_smile:

Error : The character encoding was not declared. Proceeding using windows-1252 .

https://johns-jokes.com/downloads/sp-j/sp-unzip/DOWNLOADS/Asasass-001/