【问题标题】:jQuery ui change button to flat stylejQuery ui 将按钮更改为平面样式
【发布时间】:2016-04-02 07:41:41
【问题描述】:

我想手动更改 jQuery ui 中的按钮以适应我的页面主题。我设法改变了颜色,字体...... 但我想要一个扁平按钮,像这样:

我的按钮如下所示:

是否可以去除阴影?

这里是 css: (jquery 1.10.3)

.ui-dialog .ui-dialog-buttonpane {
        text-align: left;
        border-width: 1px 0 0 0;
        /*background-image: none;*/
        margin-top: .5em;
        padding: .3em 1em .5em .4em;
            outline: none;
            background: #a3cb38
    }
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset {
        float: right;
    }
.ui-dialog .ui-dialog-buttonpane button {
        /*margin: .5em .4em .5em 0;*/
        position: relative;
            top: 3px;
            left: 15px;
            width: 100px;
            height: 45px;
            cursor: pointer;
            color: #ffffff;   /* couleur police bouton */
            outline: none;
            font-family:Montserrat,"Helvetica Neue",Helvetica,Arial,sans-serif;
            background: #fed136;   /* couleur fond bouton */
            border-radius: 6px 6px 6px 6px; 
    }

我是 jquery 新手,按钮线太多了...

【问题讨论】:

  • 什么是按钮的css?
  • ksno:我已经编辑了我的问题,谢谢你的回答 guradio:谢谢我会看到

标签: jquery css jquery-ui flat


【解决方案1】:

这是你看到的默认按钮边框样式,像这样删除边框:

border:0;

【讨论】:

  • 很高兴为您提供帮助。不要忘记使用您的浏览器开发工具来检查元素,您将能够自己轻松识别这样的样式:)
  • 好吧,确实我没想过用它。只是萤火虫来查看 javascript 错误,但没有这种问题!再次感谢
猜你喜欢
  • 1970-01-01
  • 2018-08-25
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2018-10-14
  • 2011-01-28
  • 1970-01-01
  • 2011-03-23
相关资源
最近更新 更多