【问题标题】:Broken Skeleton grid - 12 and 4 columns破碎的骨架网格 - 12 和 4 列
【发布时间】:2014-02-13 19:56:20
【问题描述】:

我正在开发我的第一个基于 Skeleton 的 CSS 框架项目。到目前为止,一切都很顺利,但似乎我一直坚持一件事。代码如下:

<div class="sixteen columns">
        <div class="clear spacernews"></div>
    </div>

    <div class="twelve columns">
            <div class="four columns newspoint">1</div>
            <div class="four columns newspoint">2</div>
            <div class="four columns newspoint">3</div>

    </div>
    <div class="four columns">
        <h3>Docs &amp; Support</h3>
        <p>The easiest way to really get started with Skeleton is to check out the full docs and info at <a href="http://www.getskeleton.com">www.getskeleton.com.</a>. Skeleton is also open-source and has a <a href="https://github.com/dhgamache/skeleton">project on git</a>, so check that out if you want to report bugs or create a pull request. If you have any questions, thoughts, concerns or feedback, please don't hesitate to email me at <a href="mailto:hi@getskeleton.com">hi@getskeleton.com</a>.</p>
    </div>

问题如下 - 当我只有 12 列和 4 列时,它很酷。但是当我嵌套那些 3x 四列时,网格崩溃了。这是为什么?有什么想法吗?

【问题讨论】:

    标签: css grid multiple-columns skeleton-css-boilerplate


    【解决方案1】:

    如果您需要三列,则说明您选错了类。试试one-third column

    另一件事是,如果将列添加到列中,则必须将 alpha 和 omega 添加到第一列和最后一列。

    【讨论】:

      【解决方案2】:

      只需使用“column/columns omega”作为包装类。

      <div class="column omega">
              <div class="four columns newspoint">1</div>
              <div class="four columns newspoint">2</div>
              <div class="four columns newspoint">3</div>
      </div>
      

      这样就好了。

      【讨论】:

        猜你喜欢
        • 2016-12-12
        • 2015-05-09
        • 2016-02-01
        • 1970-01-01
        • 1970-01-01
        • 2021-06-07
        • 1970-01-01
        • 1970-01-01
        • 2013-03-10
        相关资源
        最近更新 更多