Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

So it's equivalent to setting:

    left: x%;
    top: y%;
    transform: translate(-x%, -y%);


I use this all the time. One of the best ways to reliably center absolute elements.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: