在Firefox上设置滚动条的样式如何摆脱滚动条上的黑色边框/轮廓?

问题描述

这是我用来设置垂直滚动条样式的CSS。

overflow-y: scroll;
  ::-webkit-scrollbar {
    width: 10px;
  }
  ::-webkit-scrollbar-track {
    background: #COLOR_1;
    border-radius: 2px;
  }
  ::-webkit-scrollbar-thumb {
    background: #COLOR_2;
    border-radius: 2px;
  }
    ::-webkit-scrollbar-thumb:hover {
    background: #COLOR_2;
  }
  scrollbar-color: ${props => "#COLOR_2" + " " + "#COLOR_1"};
  scrollbar-width: thin;

这是我期望的结果(可在Chrome上运行):

enter image description here

这是我在Firefox上得到的:

enter image description here

enter image description here

enter image description here

如何摆脱黑线?

它从顶部开始一直延伸到底部。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)