简体   繁体   English

Rails Foundation Row样式

[英]Rails Foundation Row style

I have followed the railscast for Zurb Foundation and I've set up a row with two divs: <%= yield %> 我遵循Zurb Foundation的规则,并设置了两个div行:<%= yield%>

sidebar 侧边栏

When I first load the page, unlike Ryan's example, the row seems to be centered (in the RailsCast example, everything is up against the left side of the screen). 当我第一次加载页面时,与Ryan的示例不同,该行似乎居中(在RailsCast示例中,所有内容都位于屏幕的左侧)。 when I examine the styling of the row, it has a margin-left: auto. 当我检查行的样式时,它的左边距为:自动。 If I turn this "off", everything shifts to the left as in the example. 如果我将此“关闭”,则所有示例都将向左移动。 Is there a place where this is set in foundation? 是否有放置基础的地方? I downloaded the source code, and didn't see where the .row styling is specified. 我下载了源代码,但没有看到指定.row样式的位置。 I could add the styling to a secondary stylesheet, but I'd rather have it set in one place. 我可以将样式添加到辅助样式表中,但我希望将其设置在一个地方。

modifying the value for $row-width: rem-calc(2000); 修改$ row-width的值:rem-calc(2000);

seems to be getting the results I expected, though I'm still unclear on how rem-calc works... 尽管我仍然不清楚rem-calc的工作原理,但似乎正在获得预期的结果...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM