Created
May 15, 2012 01:33
-
-
Save Cyborg572/2698433 to your computer and use it in GitHub Desktop.
Camera effect
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
/** | |
* Camera effect | |
*/ | |
body{ | |
background: #f06; | |
background: linear-gradient(45deg, #f06, yellow); | |
background-attachment: fixed; | |
background-size: 100px; | |
min-height: 100%; | |
} | |
#screen { | |
margin:550px 20px; | |
position: relative; | |
width: 100px; | |
height: 50px; | |
border: 1px solid black; | |
} | |
#screen::before{ | |
content: ""; | |
position: absolute; | |
top: 0; right: 0; bottom: 0; left: 0; | |
background: linear-gradient(45deg, #f06, yellow) repeat; | |
background-attachment: fixed; | |
background-size: 100px; | |
border: 1px solid blue; | |
transform: translate(100px, -50px) rotate(3deg) scale(2) | |
} |
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
<!-- content to be placed inside <body>…</body> --> | |
<div id="screen"></div> |
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
{"view":"split-vertical","fontsize":"100","seethrough":"","prefixfree":"1","page":"all"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment