抛砖引玉:如何将steemit投票按钮的颜色改为之前的蓝色?

daijia(56)
Published in
#cn
Words
332
Reading
2 min
Listen
Play
9y

steemit前阵子改版了,同时将主色从蓝色更换为绿色。
不知道是不是有人怀念之前的蓝色系,其实要想变回去的话,还是有办法的。下面我以投票按钮为例,来说说任何将颜色改为之前的蓝色。

  1. 先祭出神器:Stylish
    一个Chrome浏览器的扩展,通过增加CSS,为网站自定义样式。

    添加的地址:
    Chrome商店
    Firefox商店
    Opera商店
  2. 为steemit设置修改样式
    点击stylish的图标后,会出现一个简单的弹出层。

    再点击右上角的点点,在弹出菜单上点击“新建样式”。
  3. 粘贴样式代码
    将下面的样式代码填入到代码文本框中。
    然后给这个样式起一个名字,如steemit,保存后切换到steemit页面后,没有意外的话投票按钮就变成蓝色啦。
.theme-original .Voting .dropdown-pane{border:1px solid #788187}
.theme-light .Voting .dropdown-pane{border:1px solid #788187}
.theme-original .Voting__about-flag .button{background-color:#1A5099;box-shadow:0 0 0 0 transparent,5px 5px 0 0 transparent;color:#fcfcfc}
.theme-light .Voting__about-flag .button{background-color:#171F24;box-shadow:0 0 0 0 transparent,5px 5px 0 0 #4BA2F2;color:#fcfcfc}
.theme-original .Voting__about-flag .button:focus,.theme-original .Voting__about-flag .button:hover{background-color:#4BA2F2;box-shadow:2px 2px 2px 0 rgba(0,0,0,.1),7px 7px 0 0;color:#fcfcfc;text-shadow:0 1px 0 rgba(0,0,0,.2)}
.theme-light .Voting__about-flag .button:focus,.theme-light .Voting__about-flag .button:hover{background-color:#4BA2F2;box-shadow:2px 2px 2px 0 rgba(0,0,0,.1),7px 7px 0 0 #171F24;color:#fff;text-shadow:0 1px 0 rgba(0,0,0,.2)}
.theme-original .Voting__button-up path{fill:#4BA2F2}
.theme-light .Voting__button-up path{fill:#4BA2F2}
.theme-original .Voting__button-up circle{stroke:#4BA2F2}
.theme-light .Voting__button-up circle{stroke:#4BA2F2}
@media screen and (min-width:39.9375em){.Voting__button-up .Icon:hover{box-shadow:0 0 0 rgba(75, 162, 242, 1);-webkit-animation:pulse 2s infinite;animation:pulse 2s infinite}
.Voting__button-up>a:hover path,a.confirm_weight:hover path{fill:#fff}
.theme-original .Voting__button-up>a:hover circle,.theme-original a.confirm_weight:hover circle{fill:#4BA2F2;stroke:#4BA2F2}
.theme-light .Voting__button-up>a:hover circle,.theme-light a.confirm_weight:hover circle{fill:#4BA2F2;stroke:#4BA2F2}
.Voting__button-up.votingUp svg{border:1px solid #4BA2F2;border-radius:50%;border-right-color:transparent;border-top-color:transparent;-webkit-animation:loading .5s infinite linear;animation:loading .5s infinite linear}
.Voting__button-down.votingDown svg{border:1px solid #ff0264;border-radius:50%;border-right-color:transparent;border-top-color:transparent;-webkit-animation:loading .5s infinite linear;animation:loading .5s infinite linear}
.Voting__button-down .Voting__button-downvotes{color:#aaa;font-size:80%;vertical-align:15%;padding-right:.1rem}
.Voting__button-down a:hover path{fill:#ff0264}
.Voting__button--upvoted path{fill:#fff!important}
.theme-original .Voting__button--upvoted circle{fill:#4BA2F2;stroke:#4BA2F2}
.theme-light .Voting__button--upvoted circle{fill:#4BA2F2;stroke:#4BA2F2}
.Voting__button--upvoted a:hover path{fill:#fff!important}
.theme-original .Voting__button--upvoted a:hover circle{fill:#4BA2F2;stroke:#4BA2F2}
.theme-light .Voting__button--upvoted a:hover circle{fill:#258DEB;stroke:#258DEB}
.Voting__button--downvoted path{fill:#ff0264}
.theme-original .DropdownMenu.Voting__voters_list ul li>span{color:#788187}
.theme-light .DropdownMenu.Voting__voters_list ul li>span{color:#788187}
.Voting__adjust_weight_down .weight-display{color:#ff0264!important}
.Voting__adjust_weight .rangeslider .rangeslider__handle:active,.Voting__adjust_weight_down .rangeslider .rangeslider__handle:active{background:#4BA2F2}
.Voting__adjust_weight .rangeslider-horizontal .rangeslider__fill,.Voting__adjust_weight_down .rangeslider-horizontal .rangeslider__fill{height:100%;background:#4BA2F2;box-shadow:none;left:0}

本文只是抛砖引玉,提供一个方法和思路。深入挖掘的话,能把页面样式弄个天翻地覆。

最后,stylish的官网提供了不少网友制作的样式,可以通过关键字搜索。比如之前有一些,可以狠狠按这里查看

抛砖引玉:如何将steemit投票按钮的颜色改为之前的蓝色? | Ecency