WordPress主题美化 OneNav 主题底部添加动态波浪样式

21次阅读
没有评论

找到 OneNav 主题 根目录下 footer.php 文件

在最下面的前面添加如下代码

<div class="waveHorizontals mobile-hide">
<div id="waveHorizontal1" class="waveHorizontal"></div>
<div id="waveHorizontal2" class="waveHorizontal"></div>
<div id="waveHorizontal3" class="waveHorizontal"></div>
</div>

第二步:RiPlus 主题 /RiPro 主题目录 -> assets -> css -> diy.css 添加下方样式

.waveHorizontals {
width: 100%;
height: 20px;
position: relative;
overflow: hidden;
z-index: 1;
background-color:#25282a !important
}/*background-color:#25282a 背景底色,根据自己的美化选择颜色 */
.ripro-dark .waveHorizontals {
width: 100%;
height: 20px;
position: relative;
overflow: hidden;
z-index: 1;
background-color:#181616 !important
}
#waveHorizontal1 {-webkit-mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_001.svg);
mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_001.svg);
animation-delay: -2s;
animation-duration: 12s;
}
#waveHorizontal1, #waveHorizontal2, #waveHorizontal3 {background-image: linear-gradient(20deg,#f84270 0,#fe803b 100%)!important;
}
.ripro-dark #waveHorizontal1{background-color: #f1f1f1!important;}
.ripro-dark #waveHorizontal2{background-color: #f1f1f1!important;}
.ripro-dark #waveHorizontal3{background-color: #f1f1f1!important;}
.waveHorizontal {
width: 200%;
height: 100%;
display: block;
position: absolute;
left: 0;
bottom: 0;
background-repeat: repeat-x;
background-position: left bottom;
background-size: 350px 100%;
transform-origin: 0 100% 0;
animation-name: move;
animation-timing-function: linear;
animation-iteration-count: infinite;
}
@keyframes move{0%{transform:translate(-175px,0px) scale(1,1)}50%{transform:translate(-87px,0px) scale(1,0.5)}100%{transform:translate(0px,0px) scale(1,1)}}

#waveHorizontal2 {-webkit-mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_002.svg);
mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_002.svg);
animation-delay: -2s;
animation-duration: 5s;
}
#waveHorizontal3 {-webkit-mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_003.svg);
mask: url(https://www.mophp.cn/www.mophp.cn/wp-content/themes/riplus-child/assets/images/mophp_003.svg);
animation-delay: -1s;
animation-duration: 3s;
}
WordPress
每日忙乎
版权声明:本站原创文章,由 每日忙乎 2022-08-03发表,共计2160字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
评论(没有评论)
验证码
载入中...