我试图让 susy 在指南针中正确工作。
查看以下 html 示例(正文部分):
<div class='page'>
<header class='header border'>
<nav class='nav border'>
<ul>
<li>Nav1</li>
<li>Nav2</li>
<li>Nav3</li>
<li>Nav4</li>
<li>Nav5</li>
</ul>
</nav>
<section class='test border'>TEST</section>
</header>
<section class='section border'>Section 1</section>
<section class='section border'>Section 2</section>
<section class='section border'>Section 3</section>
<section class='section border'>Section 4</section>
<section class='section border'>Section 5</section>
<section class='section border'>Section 6</section>
<section class='section border'>Section 7</section>
<section class='section border'>Section 8</section>
<section class='section border'>Section 9</section>
<section class='section border'>Section 10</section>
<footer class='footer border'>Footer</footer>
</div>
...以及相应的 sass 代码:
@import "compass"
@import "susy"
$total-columns : 6
$column-width : 4em
$gutter-width : 1em
$grid-padding : $gutter-width
.page
+container($total-columns)
+susy-grid-background
.header
+span-columns($total-columns)
.nav
+span-columns($total-columns)
.test
+span-columns($total-columns)
.footer
+span-columns($total-columns)
.section
+span-columns(3)
&:last-child
+span-columns(3 omega)
.border
border: 1px solid black
2“Section X”项目在这里应该在一行(span-columns设置为3,3 + 3是$total-columns的数量?),但看起来像这样(仅堆叠):
http://i.imgur.com/3LdJVX3.png
删除测试边界也不起作用。我在这里做错了什么?