Created
December 5, 2012 20:03
-
-
Save nathanaelnsmith/4219004 to your computer and use it in GitHub Desktop.
A Mixin for horizontally centering a dynamic element
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The element the mixin is applied to must be a wrapper for the dynamic element | |
.horz-center(){ | |
*text-align: center; | |
> * { | |
display: table; | |
margin: 0px auto; | |
*display: inline; | |
*zoom: 1; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment