【问题标题】:How to add/subtract Hue, Brigtness or Saturation of a hexadecimal RGB color, using SASS?如何使用 SASS 添加/减去十六进制 RGB 颜色的色相、亮度或饱和度?
【发布时间】:2012-03-28 22:35:58
【问题描述】:

例如,我有一个颜色#3e779d。如果我减去 5 的亮度,我得到 #396d8f。

我在纯 SASS(带函数?)中搜索方法,而不是 SASS 扩展(如https://gist.github.com/1932866)。

有可能吗?

谢谢!

【问题讨论】:

    标签: sass


    【解决方案1】:

    查看RGB functions 和HSL functions。他们是 SASS 原生的。

    【讨论】:

    • 谢谢!我没想到SASS中的所有这些功能。 'lighten' 显示为我需要的功能。
    猜你喜欢
    • 2018-10-22
    • 2014-07-05
    • 2017-12-26
    • 2011-05-17
    • 2018-12-23
    • 2023-03-25
    • 1970-01-01
    相关资源
    最近更新 更多