加林森 发表于 2022-3-2 21:12

本帖最后由 加林森 于 2022-6-2 21:00 编辑 <br /><br />大猫咪 发表于 2022-3-2 21:09
嗯这颜色猫喜欢
老黑的专版里有,你可以去看看。

<style>

.outer { left: -214px; width: 1024px; height: 673px; box-shadow: 2px 2px 4px #333; background: teal url('https://pic.imgdb.cn/item/6298b34709475431296e88e5.jpg') no-repeat; position: relative; }
.ele1 { position: absolute; left: 60px; top: 60px; width: 80px; height: 80px; border-radius: 50%;background: #ccc linear-gradient(transparent 49%,rgba(255,0,0,.65) 50%,transparent 0) no-repeat; background-size: 0% 100%; box-shadow: 5px 5px 30px 0 gray; cursor:pointer; }
.ele1::before, .ele1::after { position: absolute; content: ''; width: inherit; height: inherit; border-radius: inherit; }
.ele1::before { background: linear-gradient(transparent,rgba(0,0,0,0)); animation: flash 1s linear infinite; }
.ele1::after { background: radial-gradient(circle at 30% 30%,transparent,rgba(0,255,0,.25)); }
@keyframes flash { to { background: linear-gradient(transparent,rgba(0,0,0,.6)); } }

</style>

<div class="outer">
        <div class="ele1"></div>
</div>
<audio id="aud" src="https://music.163.com/song/media/outer/url?id=1331592936.mp3" autoplay="autoplay" loop="loop"></audio>

<script>

let ele1 = document.querySelector('.ele1'), aud = document.querySelector('#aud');
ele1.onclick = () => aud.paused ? aud.play() : aud.pause();
aud.addEventListener('timeupdate',() => ele1.style.backgroundSize = 100 * aud.currentTime / aud.duration + '% 100%');

</script>

大猫咪 发表于 2022-3-2 21:14

加林森 发表于 2022-3-2 21:12
老黑的专版里有,你可以去看看。

好 {:4_187:}

加林森 发表于 2022-3-2 21:14

大猫咪 发表于 2022-3-2 21:14


嗯嗯
页: 1 [2]
查看完整版本: 《风中的承诺》 李翊君