在群里水,突然发现泽泽社长发了一篇给网站添加雷姆拉姆文章,手痒就给自己网站整上了
原文地址在https://blog.zezeshe.com/archives/xlog-ram-rem.html
效果如图
之前写过个插件,给 Typecho 和 WordPress 加上雷姆和拉姆的 gif 动图,核心源码如下
html 代码:
<div class="remram">
<div class="rem"></div>
<div class="ram"></div>
</div>
css 代码:
.remram {
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: -1;
display: flex;
position: fixed;
justify-content: space-between;
}
/*高分辨率下加载图片素材*/
@media (min-width: 1420px){
.remram div {
background-repeat:no-repeat;
background-size: 250px;
background-image: url('./remram.gif') !important;
width: 125px;
}
.remram .rem{
background-position: -125px bottom;
}
.remram .ram{
background-position: 0 bottom;
}
}