Created
June 14, 2012 10:34
-
-
Save leechy/2929503 to your computer and use it in GitHub Desktop.
Блок по центру экрана, с максимальной шириной и ограничением
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
/** | |
* Блок по центру экрана, с максимальной шириной и ограничением | |
*/ | |
/* стили для блока с ограничением */ | |
.b-limited-content { | |
max-width: 1000px; | |
margin: 0 auto 1.2em 200px; | |
height: 100px; | |
background: rgb(0, 127, 255); | |
} | |
/* вспомагательные стили */ | |
body { | |
margin: 0; | |
} | |
.b-layout { | |
position: relative; | |
min-width: 800px; | |
overflow: hidden; | |
} | |
.b-content { | |
max-width: 1200px; | |
margin: 0 auto 1.2em; | |
height: 100px; | |
background: rgb(255, 200, 200); | |
} | |
.b-limit { | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 197px; | |
height: 300px; | |
border-right: 3px dashed red; | |
} |
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
<div class="b-layout"> | |
<div class="b-content"> | |
<div style="float: left; color: black;">«</div> | |
<div style="float: right; color: black;">»</div> | |
</div> | |
<!-- необходимо править как раз b-limited-content, допускается добавление дополнительных элементов --> | |
<div class="b-limited-content"> | |
<div style="float: left; color: white;">«</div> | |
<div style="float: right; color: white;">»</div> | |
</div> | |
<div class="b-limit"></div> | |
</div> |
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
{"view":"split","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