【问题标题】:Color of the bootstrap links (light blue?) in rgb?rgb 中引导链接的颜色(浅蓝色?)?
【发布时间】:2014-05-30 10:49:51
【问题描述】:

尝试在带有引导程序样式的链接周围设置边框(似乎是浅蓝色)。在 css 文件中找不到颜色。边框位于链接周围的另一个 div 中。我想在边框和链接之间有相同的颜色。

【问题讨论】:

  • 仔细看……它就在那里。
  • netgfx.com/RGBaZRrgb(66,139,202)
  • 然而,这里有一个有趣的事实,你不需要知道链接的颜色来应用相同颜色的边框。有一种颜色 keyword --- currentColor 可以正常工作:border:1px solid currentColor; 见 - jsfiddle.net/Paulie_D/wd7wj/7

标签: css twitter-bootstrap colors hyperlink


【解决方案1】:

我认为您正在寻找这部分:

a {
  color: $link-color;
  text-decoration: none;
  &:hover,
  &:focus {
    color: $link-hover-color;
    text-decoration: underline;
  }
  &:focus {
    @include tab-focus();
  }
}

这是在 _scaffolding.scss 上,然后是它的调用 tab-focus mixin。

注意这是scss版本的bootstrap。

基本上你必须覆盖这个:

a:focus {
  outline: thin dotted;
  outline: 5px auto color;
  outline-offset: -2px;
}

把它放在你的 bs 导入的底部,然后用你想要的改变颜色。

PS:这是解决方法,但我所说的不是与BS合作的正确方法,但我不知道你是在编译BS还是使用min。版本。

希望对你有帮助

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2019-07-02
    • 1970-01-01
    • 1970-01-01
    • 2018-02-16
    • 1970-01-01
    • 2015-01-25
    • 2014-03-25
    • 1970-01-01
    相关资源
    最近更新 更多