Created
June 13, 2012 20:50
-
-
Save bleathem/2926443 to your computer and use it in GitHub Desktop.
Simple CSS media detection
This file contains hidden or 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
| /* portrait screen width */ | |
| @media screen and (max-device-width: 480px) { | |
| .portrait { | |
| } | |
| .landscape { | |
| display:none; | |
| } | |
| } | |
| /* landscape device widths */ | |
| @media screen and (min-device-width: 481px) { | |
| .portrait { | |
| display:none; | |
| } | |
| .landscape { | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment