- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
Foundation 5 上曾经有一个“圆形”类,可以将按钮组转换为具有圆形边缘。我如何在 Foundation 6 中执行此操作?
最佳答案
这在 Foundation 6 中是不可能的。为了减小文件大小,已经完全删除了规则和其他规则。最好的办法是将规则复制到 Foundation 6 css 文件或自定义 css 文件中(由您决定)。
以下是您需要的 css 规则(直接取自最新的 Foundation 5 文件,没有任何改动):
.button-group {
list-style: none;
margin: 0;
left: 0; }
.button-group:before, .button-group:after {
content: " ";
display: table; }
.button-group:after {
clear: both; }
.button-group.even-2 li {
display: inline-block;
margin: 0 -2px;
width: 50%; }
.button-group.even-2 li > button, .button-group.even-2 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-2 li:first-child button, .button-group.even-2 li:first-child .button {
border-left: 0; }
.button-group.even-2 li button, .button-group.even-2 li .button {
width: 100%; }
.button-group.even-3 li {
display: inline-block;
margin: 0 -2px;
width: 33.33333%; }
.button-group.even-3 li > button, .button-group.even-3 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-3 li:first-child button, .button-group.even-3 li:first-child .button {
border-left: 0; }
.button-group.even-3 li button, .button-group.even-3 li .button {
width: 100%; }
.button-group.even-4 li {
display: inline-block;
margin: 0 -2px;
width: 25%; }
.button-group.even-4 li > button, .button-group.even-4 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-4 li:first-child button, .button-group.even-4 li:first-child .button {
border-left: 0; }
.button-group.even-4 li button, .button-group.even-4 li .button {
width: 100%; }
.button-group.even-5 li {
display: inline-block;
margin: 0 -2px;
width: 20%; }
.button-group.even-5 li > button, .button-group.even-5 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-5 li:first-child button, .button-group.even-5 li:first-child .button {
border-left: 0; }
.button-group.even-5 li button, .button-group.even-5 li .button {
width: 100%; }
.button-group.even-6 li {
display: inline-block;
margin: 0 -2px;
width: 16.66667%; }
.button-group.even-6 li > button, .button-group.even-6 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-6 li:first-child button, .button-group.even-6 li:first-child .button {
border-left: 0; }
.button-group.even-6 li button, .button-group.even-6 li .button {
width: 100%; }
.button-group.even-7 li {
display: inline-block;
margin: 0 -2px;
width: 14.28571%; }
.button-group.even-7 li > button, .button-group.even-7 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-7 li:first-child button, .button-group.even-7 li:first-child .button {
border-left: 0; }
.button-group.even-7 li button, .button-group.even-7 li .button {
width: 100%; }
.button-group.even-8 li {
display: inline-block;
margin: 0 -2px;
width: 12.5%; }
.button-group.even-8 li > button, .button-group.even-8 li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.even-8 li:first-child button, .button-group.even-8 li:first-child .button {
border-left: 0; }
.button-group.even-8 li button, .button-group.even-8 li .button {
width: 100%; }
.button-group > li {
display: inline-block;
margin: 0 -2px; }
.button-group > li > button, .button-group > li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group > li:first-child button, .button-group > li:first-child .button {
border-left: 0; }
.button-group.stack > li {
display: block;
margin: 0;
float: none; }
.button-group.stack > li > button, .button-group.stack > li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.stack > li:first-child button, .button-group.stack > li:first-child .button {
border-left: 0; }
.button-group.stack > li > button, .button-group.stack > li .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.stack > li > button {
width: 100%; }
.button-group.stack > li:first-child button, .button-group.stack > li:first-child .button {
border-top: 0; }
.button-group.stack-for-small > li {
display: inline-block;
margin: 0 -2px; }
.button-group.stack-for-small > li > button, .button-group.stack-for-small > li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.stack-for-small > li:first-child button, .button-group.stack-for-small > li:first-child .button {
border-left: 0; }
@media only screen and (max-width: 40em) {
.button-group.stack-for-small > li {
display: block;
margin: 0;
width: 100%; }
.button-group.stack-for-small > li > button, .button-group.stack-for-small > li .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.stack-for-small > li:first-child button, .button-group.stack-for-small > li:first-child .button {
border-left: 0; }
.button-group.stack-for-small > li > button, .button-group.stack-for-small > li .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.stack-for-small > li > button {
width: 100%; }
.button-group.stack-for-small > li:first-child button, .button-group.stack-for-small > li:first-child .button {
border-top: 0; } }
.button-group.radius > * {
display: inline-block;
margin: 0 -2px; }
.button-group.radius > * > button, .button-group.radius > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.radius > *:first-child button, .button-group.radius > *:first-child .button {
border-left: 0; }
.button-group.radius > *,
.button-group.radius > * > a,
.button-group.radius > * > button,
.button-group.radius > * > .button {
border-radius: 0; }
.button-group.radius > *:first-child, .button-group.radius > *:first-child > a, .button-group.radius > *:first-child > button, .button-group.radius > *:first-child > .button {
-webkit-border-bottom-left-radius: 3px;
-webkit-border-top-left-radius: 3px;
border-bottom-left-radius: 3px;
border-top-left-radius: 3px; }
.button-group.radius > *:last-child, .button-group.radius > *:last-child > a, .button-group.radius > *:last-child > button, .button-group.radius > *:last-child > .button {
-webkit-border-bottom-right-radius: 3px;
-webkit-border-top-right-radius: 3px;
border-bottom-right-radius: 3px;
border-top-right-radius: 3px; }
.button-group.radius.stack > * {
display: block;
margin: 0; }
.button-group.radius.stack > * > button, .button-group.radius.stack > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.radius.stack > *:first-child button, .button-group.radius.stack > *:first-child .button {
border-left: 0; }
.button-group.radius.stack > * > button, .button-group.radius.stack > * .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.radius.stack > * > button {
width: 100%; }
.button-group.radius.stack > *:first-child button, .button-group.radius.stack > *:first-child .button {
border-top: 0; }
.button-group.radius.stack > *,
.button-group.radius.stack > * > a,
.button-group.radius.stack > * > button,
.button-group.radius.stack > * > .button {
border-radius: 0; }
.button-group.radius.stack > *:first-child, .button-group.radius.stack > *:first-child > a, .button-group.radius.stack > *:first-child > button, .button-group.radius.stack > *:first-child > .button {
-webkit-top-left-radius: 3px;
-webkit-top-right-radius: 3px;
border-top-left-radius: 3px;
border-top-right-radius: 3px; }
.button-group.radius.stack > *:last-child, .button-group.radius.stack > *:last-child > a, .button-group.radius.stack > *:last-child > button, .button-group.radius.stack > *:last-child > .button {
-webkit-bottom-left-radius: 3px;
-webkit-bottom-right-radius: 3px;
border-bottom-left-radius: 3px;
border-bottom-right-radius: 3px; }
@media only screen and (min-width: 40.0625em) {
.button-group.radius.stack-for-small > * {
display: inline-block;
margin: 0 -2px; }
.button-group.radius.stack-for-small > * > button, .button-group.radius.stack-for-small > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.radius.stack-for-small > *:first-child button, .button-group.radius.stack-for-small > *:first-child .button {
border-left: 0; }
.button-group.radius.stack-for-small > *,
.button-group.radius.stack-for-small > * > a,
.button-group.radius.stack-for-small > * > button,
.button-group.radius.stack-for-small > * > .button {
border-radius: 0; }
.button-group.radius.stack-for-small > *:first-child, .button-group.radius.stack-for-small > *:first-child > a, .button-group.radius.stack-for-small > *:first-child > button, .button-group.radius.stack-for-small > *:first-child > .button {
-webkit-border-bottom-left-radius: 3px;
-webkit-border-top-left-radius: 3px;
border-bottom-left-radius: 3px;
border-top-left-radius: 3px; }
.button-group.radius.stack-for-small > *:last-child, .button-group.radius.stack-for-small > *:last-child > a, .button-group.radius.stack-for-small > *:last-child > button, .button-group.radius.stack-for-small > *:last-child > .button {
-webkit-border-bottom-right-radius: 3px;
-webkit-border-top-right-radius: 3px;
border-bottom-right-radius: 3px;
border-top-right-radius: 3px; } }
@media only screen and (max-width: 40em) {
.button-group.radius.stack-for-small > * {
display: block;
margin: 0; }
.button-group.radius.stack-for-small > * > button, .button-group.radius.stack-for-small > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.radius.stack-for-small > *:first-child button, .button-group.radius.stack-for-small > *:first-child .button {
border-left: 0; }
.button-group.radius.stack-for-small > * > button, .button-group.radius.stack-for-small > * .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.radius.stack-for-small > * > button {
width: 100%; }
.button-group.radius.stack-for-small > *:first-child button, .button-group.radius.stack-for-small > *:first-child .button {
border-top: 0; }
.button-group.radius.stack-for-small > *,
.button-group.radius.stack-for-small > * > a,
.button-group.radius.stack-for-small > * > button,
.button-group.radius.stack-for-small > * > .button {
border-radius: 0; }
.button-group.radius.stack-for-small > *:first-child, .button-group.radius.stack-for-small > *:first-child > a, .button-group.radius.stack-for-small > *:first-child > button, .button-group.radius.stack-for-small > *:first-child > .button {
-webkit-top-left-radius: 3px;
-webkit-top-right-radius: 3px;
border-top-left-radius: 3px;
border-top-right-radius: 3px; }
.button-group.radius.stack-for-small > *:last-child, .button-group.radius.stack-for-small > *:last-child > a, .button-group.radius.stack-for-small > *:last-child > button, .button-group.radius.stack-for-small > *:last-child > .button {
-webkit-bottom-left-radius: 3px;
-webkit-bottom-right-radius: 3px;
border-bottom-left-radius: 3px;
border-bottom-right-radius: 3px; } }
.button-group.round > * {
display: inline-block;
margin: 0 -2px; }
.button-group.round > * > button, .button-group.round > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.round > *:first-child button, .button-group.round > *:first-child .button {
border-left: 0; }
.button-group.round > *,
.button-group.round > * > a,
.button-group.round > * > button,
.button-group.round > * > .button {
border-radius: 0; }
.button-group.round > *:first-child, .button-group.round > *:first-child > a, .button-group.round > *:first-child > button, .button-group.round > *:first-child > .button {
-webkit-border-bottom-left-radius: 1000px;
-webkit-border-top-left-radius: 1000px;
border-bottom-left-radius: 1000px;
border-top-left-radius: 1000px; }
.button-group.round > *:last-child, .button-group.round > *:last-child > a, .button-group.round > *:last-child > button, .button-group.round > *:last-child > .button {
-webkit-border-bottom-right-radius: 1000px;
-webkit-border-top-right-radius: 1000px;
border-bottom-right-radius: 1000px;
border-top-right-radius: 1000px; }
.button-group.round.stack > * {
display: block;
margin: 0; }
.button-group.round.stack > * > button, .button-group.round.stack > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.round.stack > *:first-child button, .button-group.round.stack > *:first-child .button {
border-left: 0; }
.button-group.round.stack > * > button, .button-group.round.stack > * .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.round.stack > * > button {
width: 100%; }
.button-group.round.stack > *:first-child button, .button-group.round.stack > *:first-child .button {
border-top: 0; }
.button-group.round.stack > *,
.button-group.round.stack > * > a,
.button-group.round.stack > * > button,
.button-group.round.stack > * > .button {
border-radius: 0; }
.button-group.round.stack > *:first-child, .button-group.round.stack > *:first-child > a, .button-group.round.stack > *:first-child > button, .button-group.round.stack > *:first-child > .button {
-webkit-top-left-radius: 1rem;
-webkit-top-right-radius: 1rem;
border-top-left-radius: 1rem;
border-top-right-radius: 1rem; }
.button-group.round.stack > *:last-child, .button-group.round.stack > *:last-child > a, .button-group.round.stack > *:last-child > button, .button-group.round.stack > *:last-child > .button {
-webkit-bottom-left-radius: 1rem;
-webkit-bottom-right-radius: 1rem;
border-bottom-left-radius: 1rem;
border-bottom-right-radius: 1rem; }
@media only screen and (min-width: 40.0625em) {
.button-group.round.stack-for-small > * {
display: inline-block;
margin: 0 -2px; }
.button-group.round.stack-for-small > * > button, .button-group.round.stack-for-small > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.round.stack-for-small > *:first-child button, .button-group.round.stack-for-small > *:first-child .button {
border-left: 0; }
.button-group.round.stack-for-small > *,
.button-group.round.stack-for-small > * > a,
.button-group.round.stack-for-small > * > button,
.button-group.round.stack-for-small > * > .button {
border-radius: 0; }
.button-group.round.stack-for-small > *:first-child, .button-group.round.stack-for-small > *:first-child > a, .button-group.round.stack-for-small > *:first-child > button, .button-group.round.stack-for-small > *:first-child > .button {
-webkit-border-bottom-left-radius: 1000px;
-webkit-border-top-left-radius: 1000px;
border-bottom-left-radius: 1000px;
border-top-left-radius: 1000px; }
.button-group.round.stack-for-small > *:last-child, .button-group.round.stack-for-small > *:last-child > a, .button-group.round.stack-for-small > *:last-child > button, .button-group.round.stack-for-small > *:last-child > .button {
-webkit-border-bottom-right-radius: 1000px;
-webkit-border-top-right-radius: 1000px;
border-bottom-right-radius: 1000px;
border-top-right-radius: 1000px; } }
@media only screen and (max-width: 40em) {
.button-group.round.stack-for-small > * {
display: block;
margin: 0; }
.button-group.round.stack-for-small > * > button, .button-group.round.stack-for-small > * .button {
border-left: 1px solid;
border-color: rgba(255, 255, 255, 0.5); }
.button-group.round.stack-for-small > *:first-child button, .button-group.round.stack-for-small > *:first-child .button {
border-left: 0; }
.button-group.round.stack-for-small > * > button, .button-group.round.stack-for-small > * .button {
border-color: rgba(255, 255, 255, 0.5);
border-left-width: 0;
border-top: 1px solid;
display: block;
margin: 0; }
.button-group.round.stack-for-small > * > button {
width: 100%; }
.button-group.round.stack-for-small > *:first-child button, .button-group.round.stack-for-small > *:first-child .button {
border-top: 0; }
.button-group.round.stack-for-small > *,
.button-group.round.stack-for-small > * > a,
.button-group.round.stack-for-small > * > button,
.button-group.round.stack-for-small > * > .button {
border-radius: 0; }
.button-group.round.stack-for-small > *:first-child, .button-group.round.stack-for-small > *:first-child > a, .button-group.round.stack-for-small > *:first-child > button, .button-group.round.stack-for-small > *:first-child > .button {
-webkit-top-left-radius: 1rem;
-webkit-top-right-radius: 1rem;
border-top-left-radius: 1rem;
border-top-right-radius: 1rem; }
.button-group.round.stack-for-small > *:last-child, .button-group.round.stack-for-small > *:last-child > a, .button-group.round.stack-for-small > *:last-child > button, .button-group.round.stack-for-small > *:last-child > .button {
-webkit-bottom-left-radius: 1rem;
-webkit-bottom-right-radius: 1rem;
border-bottom-left-radius: 1rem;
border-bottom-right-radius: 1rem; } }
.button-bar:before, .button-bar:after {
content: " ";
display: table; }
.button-bar:after {
clear: both; }
.button-bar .button-group {
float: left;
margin-right: 0.625rem; }
.button-bar .button-group div {
overflow: hidden; }
关于zurb-foundation - 如何在 Foundation 6 中制作圆形按钮组?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35534218/
我在 ZURB 的论坛上发布了一个问题,但我注意到任何帖子都没有答案。 因为我认为这个问题可能会发生在许多其他人身上,所以我认为把它放在 SO 上也是一个好主意。它来了: 我使用以下标记制作了一个最小
我有一个非常简单的 Foundation CSS 代码 Content goes here Side goes here 我希望列之间有边距。目前,只有填充。所以如果我添加 bac
根据对先前提出的问题的回答,我有一个全屏布局: CSS fullscreen grid layout (with some scrolling sections) 我正在使用的线框: 编辑:这是我希望
现在下拉菜单的内容默认在右下角。 有没有设置它的选项,让它转到左下角? (基础 5) 最佳答案 “正确”的风格是通过 JS 应用的。要覆盖它,只需提供 #contentDrop #contentDro
.grid-container的默认宽度是多少?在大屏幕上?我怎样才能改变它并使它变大?正确的做法是什么? 最佳答案 .grid-container 的默认宽度在_settings.css 文件中定义
.grid-container的默认宽度是多少?在大屏幕上?我怎样才能改变它并使它变大?正确的做法是什么? 最佳答案 .grid-container 的默认宽度在_settings.css 文件中定义
如何禁用中/小屏幕的顶部栏折叠? 我按照 Here 中的说明进行操作但无论我将最小宽度设置为什么,我都会得到相同的结果。 最佳答案 如果您使用的是 SCSS 版本,那么您可以修改断点。 $topbar
您是否遇到过 zurb 基金会的顶栏问题? 输入框不适合导航。我没有修改任何东西,只是粘贴了来自 foundation's page 的代码到他们包含在基础文件中的示例网站。将字体更改为 Open S
出于多种原因,复选框在最新的 Foundation (4.1.6) 中存在问题。有没有一种简单的方法可以阻止 Foundation 接管它们?我需要 custom我的类 form s 其他原因。我如何
我最近开始将 Zurb Foundation 4 用于 Asp MVC 网站,但我不太明白开关控件应该如何工作。文档没有说太多 http://foundation.zurb.com/docs/comp
我的问题是,在桌面上我喜欢先有菜单,然后是最右上角的标志。目前,当我将模板缩小到移动版本时, Logo 位于菜单下方,这并不令人满意。我想在菜单之前吃。我试过使用推/拉没有成功。 在移动 View 中
是否有任何文档解释foundation.css 中的每个类?我不擅长前端开发,而且似乎没有通过 zurb 网站上提供的粗略文档来掌握概念。提前致谢。 最佳答案 没有。我认为对他们来说,ZURBling
刚刚切换我的 Rails 项目以测试 Zurb Foundation 5,现在切换顶部栏菜单不起作用。 当视口(viewport)很小时,顶部栏菜单项消失并且菜单图标像以前一样显示,但是当我单击菜单图
我正在使用 Zurb Foundation 并具有以下 html: Tab 1 Content of section 1. Tab
我正在尝试使用 zurb Foundation 5 显示模式。但是当我单击按钮时它不起作用并且无法打开。我正在使用这个 html 代码。 index Awesome. I ha
有什么我可以在命令行中输入的东西来找出我正在运行的版本吗? 最佳答案 在不了解您的具体情况的情况下,最简单的方法是在初始化 Foundation ( $(document).foundation();
我正在使用 Zurb 的 Foundation 4.2.3,但是当我打印页面时,网格布局始终没有得到维护。 例如, XXX Lorem
我已经下载了新的 Zurb Foundation 6 完整包 ( Foundation for Sites )。存档文件包含以下文件和文件夹: [css] > app.css, foundation.
我正在尝试使用 zurb 的基础框架在网站上实现一个 offcanvas,用于移动查看,并且只是从文档中复制了它的代码,但它就是行不通。 代码如下: $(document).found
我喜欢 Zurb Foundation(SASS,尤其是 Zurb Foundation for Apps),但想将其与 Facebook ReactJS 和 Flux 一起使用 这就是删除 Angu
我是一名优秀的程序员,十分优秀!