【问题标题】:Lighten instead of darken the background of a button使按钮的背景变亮而不是变暗
【发布时间】:2013-04-28 23:30:33
【问题描述】:

在 Zurb Foundation 中,可以通过将 _settings.sass 文件中的 $anchor-font-color-hoverdarken() 调整为 lighten() 来更改悬停效果以点亮链接。

但是对于按钮(和其他背景),没有这样的选项。如何使所有按钮的悬停效果为lighten 而不是darken

【问题讨论】:

    标签: sass zurb-foundation


    【解决方案1】:

    _buttons.scss 中编辑button-style mixin:

    @mixin button-style($bg:$primary-color, $radius:false, $disabled:false) {
      ...
        &:hover,
        &:focus { background-color: lighten($bg, $button-function-factor);
      ... }
    

    Github

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2020-04-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-07-08
      • 1970-01-01
      相关资源
      最近更新 更多