Created
June 3, 2013 15:43
-
-
Save exarcheia-web/5699084 to your computer and use it in GitHub Desktop.
Box Model - old and new
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
| /* Box Model - old and new */ | |
| html { | |
| background: #f06; | |
| background: linear-gradient(45deg, #f06, yellow); | |
| min-height: 100%; | |
| font-family:Tahoma,sans-serif; | |
| } | |
| * { | |
| margin: 0; | |
| padding: 0; | |
| } | |
| .old-model { | |
| background: white; | |
| float: left; | |
| width: 80px; | |
| height: 80px; | |
| border: 20px solid black; | |
| padding: 20px; | |
| margin: 20px; | |
| } | |
| .new-model { | |
| box-sizing: border-box; | |
| background: white; | |
| float: left; | |
| width: 160px; | |
| height: 160px; | |
| border: 20px solid black; | |
| padding: 20px; | |
| margin: 20px; | |
| } |
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
| <div class="old-model">Box Model</div> | |
| <div class="new-model">Box Model</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
| // alert('Hello world!'); |
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