/**index.wxss**/ page{ background: #F4F6F8; } .container { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: space-between; box-sizing: border-box; background: #fff; margin-bottom: 16rpx; } ec-canvas { width: 100%; height: 50vh; } .title{ border-left: 4px solid #FF5151; color: #FF5151; font-size: 32rpx; font-weight: 500; padding-left: 20rpx; padding-right: 40rpx; margin-bottom: 20rpx; position: relative; } .part{ background: #fff; padding: 30rpx 0; margin-bottom: 16rpx; } .title image{ position: absolute; right: 0; top: -15rpx; width: 240rpx; height: 75rpx; } .rank{ position: absolute; top: -15rpx; right: 0rpx; color: #FF5151; padding-right: 24rpx; } .rank text{ font-size: 44rpx; margin-right: 10rpx; color: #FF5151; position: relative; top: 6rpx; display: inline-block; width: 70rpx; text-align: center; height: 60rpx; } .part1{ padding: 30rpx; margin-bottom: 1px; } .item{ margin-bottom: 20rpx; font-weight: 500; } .item text{ font-weight: 400; margin-right: 20rpx; } .item .tag{ display: inline-block; color: #FFF; font-size: 20rpx; background: #333; border-radius: 4rpx; padding: 0 3px; } .item .red{ background: #FF5151; } .item .blue{ background: #4587FF; } .item .border{ background: #fff; border: 1px solid #333; color: #333; } .list{ display: inline-block; width: 85%; vertical-align: top; } .list view{ display: inline-block; padding: 16rpx; background: #F4F6F8; border-radius: 8rpx; margin-bottom: 10rpx; margin-right: 10rpx; } .list text{ display: block; color: #999; } /*首页跑马灯效果*/ @keyframes around { from { margin-left: 90%; } to { /* var接受传入的变量 */ margin-left: -100%; } } .zd{ width: 80px; height: 100%; position: absolute; left: 0; top: 0; background: #fff; } .marquee_container{ width: 100%; background: #fff; margin-top: 12px; box-shadow:0px 4px 12px 0px rgba(0,0,0,0.08); border-radius:4px; padding: 10px 12px; position: relative; overflow: hidden; } .marquee_container:hover{ /* 不起作用 */ animation-play-state: paused; } .marquee_text{ color:#333; font-size: 28rpx; display: flex; white-space: nowrap; animation-name: around; animation-duration: 10s; /*过渡时间*/ animation-iteration-count: infinite; animation-timing-function:linear; } .marquee_text navigator{ margin-right: 20px; } .marquee_container image{ width: 53px; max-height: 30px; position: absolute; left: 10px; top: 15px; }