更新
<div class="container">
<div class="row">
<div class="main 8 columns" >
<div class="row">
<div class="main 4 columns">
<a href="#" class="button" data-dropdown="drop1">Has Dropdown</a>
<ul id="drop1" class="f-dropdown" data-dropdown-content>
<li id="halfanhour">Half an Hour</li> <!-- in half an hour-->
<li><a href="#">This is another</a></li> <!-- in one hour -->
<li><a href="#">Yet another</a></li> <!-- in 1.5 hour -->
<li><a href="#">Yet another</a></li><!--in 2 hours-->
<li><a href="#">Yet another</a></li><!-- in 2.5 hours-->
</ul>
</div>
<div class="main 4 columns">
Estimated Wait Time
</div>
</div>
</div>
</div>
<div class="row">
<div class="main eight columns">
<div class="element">
<div class="waittime">
<%= @shakelines['average_line_wait_secs'][0]%><br/>
<div class="minute">
Minutes
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="eight columns">
<div class="footer">
POWERED BY PLACEMETER LABS
</div>
</div>
</div>
</div>
我有一个有行的容器。我将div列设置为八列。我想将这个div分成4列。第一列属于文本Estimated Wait time
,另一个下拉框应该处理四列中的其余列。我希望这会在一行中呈现,但Estimated Wait time
会在下拉框下方呈现。我希望估计的等待时间浮动到列的左侧,然后下拉框浮动到列的右侧。
答案 0 :(得分:1)
列类名应该使用最新的网格类名称语法。 您需要指定屏幕大小和数字。
例如,更改此内容:
class="main 4 columns"
对此:
class="main small-4 large-4 columns"
答案 1 :(得分:0)
如果您检查http://foundation.zurb.com/docs/components/grid.html上的文档,您会发现嵌套列也应该包含在.row
中:
<div class="container">
<div class="row">
<div class="main eight columns" >
<div class="row">
<div class="main four columns">
<a href="#" class="button" data-dropdown="drop1">Has Dropdown</a>
<ul id="drop1" class="f-dropdown" data-dropdown-content>
<li><a href="#">This is a link</a></li> <!-- in half an hour-->
<li><a href="#">This is another</a></li> <!-- in one hour -->
<li><a href="#">Yet another</a></li> <!-- in 1.5 hour -->
<li><a href="#">Yet another</a></li><!--in 2 hours-->
<li><a href="#">Yet another</a></li><!-- in 2.5 hours-->
</ul>
</div>
<div class="main four columns">
Estimated Wait time
</div>
</div>
</div>
</div>
</div>