如何用jq获取伪类元素并修改其属性

RainLucky
  • 433

现在要动态改变.program::before的left值,该如何获取到呢??

.program{
    width: 60%;
    height: 4px;
    background: gray;
    border-radius: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    position: absolute;
    bottom: -6px;
    left: 110px;
    }
  .program::before {
    content: '';
    width: 25%;
    height: 4px;
    background: pink;
    display: inline-block;
    position: absolute;
    left: 0px;
    border-radius: 10px;
}
<div class="program"></div>
回复
阅读 4.4k
宣传栏