Closed sunmingtao closed 4 years ago
.center { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }
How to comprehend the minus percentage in translate function?
When using percentage in translate, it refers to width or height of itself.
https://stackoverflow.com/a/21175671/920554
How to comprehend the minus percentage in translate function?
When using percentage in translate, it refers to width or height of itself.
https://stackoverflow.com/a/21175671/920554