yglt-uniapp/pages/index/index.vue

90 lines
1.2 KiB
Vue
Raw Permalink Normal View History

2025-01-02 01:52:16 +00:00
<template>
<view class="content">
2025-01-13 11:42:02 +00:00
<div class="top">
2025-01-15 08:37:42 +00:00
<ul>
<li></li>
<li></li>
</ul>
2025-01-13 11:42:02 +00:00
</div>
<div class="bottom">
2025-01-15 08:37:42 +00:00
<Menu :type="0" />
2025-01-13 11:42:02 +00:00
</div>
2025-01-02 01:52:16 +00:00
</view>
</template>
2025-01-13 11:42:02 +00:00
<script setup>
import Menu from '../../components/Menu.vue'
2025-01-02 01:52:16 +00:00
</script>
2025-01-13 11:42:02 +00:00
<style scoped>
2025-01-02 01:52:16 +00:00
.content {
display: flex;
flex-direction: column;
2025-01-13 11:42:02 +00:00
height: 100%;
background: url('~@/static/home.jpg') no-repeat;
background-size: 100% 100%;
2025-01-02 01:52:16 +00:00
}
2025-01-13 11:42:02 +00:00
.top {
flex: 12;
2025-01-02 01:52:16 +00:00
}
2025-01-13 11:42:02 +00:00
.bottom {
flex: 1;
2025-01-15 08:37:42 +00:00
}
* {
margin: 0;
padding: 0;
}
ul {
height: 330rpx;
animation: change 1s linear 0s infinite alternate;
position: relative;
overflow: hidden;
top: -200rpx;
}
ul li {
list-style: none;
width: 400%;
height: 100%;
position: absolute;
left: 0;
top: 0;
background-size: 300rpx 300rpx;
}
ul li:nth-child(1) {
background-image: url('~@/static/cloud1.png');
animation: one 60s linear 0s infinite alternate;
}
ul li:nth-child(2) {
background-image: url('~@/static/cloud2.png');
animation: tow 50s linear 0s infinite alternate;
margin: 30rpx;
}
@keyframes one {
from {
margin-left: 0;
}
to {
margin-left: -100%;
}
}
@keyframes tow {
from {
margin-left: -20%;
}
to {
margin-left: -200%;
}
2025-01-02 01:52:16 +00:00
}
2025-01-08 03:10:04 +00:00
</style>