新增闪耀周星
This commit is contained in:
41
view/peko/activity/smallWeekStar/css/index.css
Normal file
41
view/peko/activity/smallWeekStar/css/index.css
Normal file
@@ -0,0 +1,41 @@
|
||||
html,
|
||||
body {
|
||||
width: 100%;
|
||||
background: #450172;
|
||||
}
|
||||
|
||||
html .box,
|
||||
body .box {
|
||||
width: 10rem;
|
||||
height: 61.62667rem;
|
||||
background: url(../images/bg.png) no-repeat;
|
||||
background-size: 100% 100%;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
html .box .gift,
|
||||
body .box .gift {
|
||||
position: absolute;
|
||||
width: 7.32rem;
|
||||
height: 3.01333rem;
|
||||
top: 10.58667rem;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
|
||||
html .box .swiper,
|
||||
body .box .swiper {
|
||||
width: 8.98667rem;
|
||||
height: 14.8rem;
|
||||
position: absolute;
|
||||
top: 19.88rem;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
|
||||
html .box .swiper img,
|
||||
body .box .swiper img {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
42
view/peko/activity/smallWeekStar/css/index.scss
Normal file
42
view/peko/activity/smallWeekStar/css/index.scss
Normal file
@@ -0,0 +1,42 @@
|
||||
@function px2rem($px) {
|
||||
@return $px / 75+rem;
|
||||
}
|
||||
|
||||
html,
|
||||
body {
|
||||
width: 100%;
|
||||
// height: 100%;
|
||||
background: #450172;
|
||||
|
||||
.box {
|
||||
width: px2rem(750);
|
||||
height: px2rem(4622);
|
||||
background: url(../images/bg.png) no-repeat;
|
||||
background-size: 100% 100%;
|
||||
position: relative;
|
||||
|
||||
.gift {
|
||||
position: absolute;
|
||||
width: px2rem(549);
|
||||
height: px2rem(226);
|
||||
top: px2rem(794);
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
|
||||
.swiper {
|
||||
width: px2rem(674);
|
||||
height: px2rem(1110);
|
||||
position: absolute;
|
||||
top: px2rem(1491);
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
|
||||
img {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
13
view/peko/activity/smallWeekStar/css/swiper-bundle.min.css
vendored
Normal file
13
view/peko/activity/smallWeekStar/css/swiper-bundle.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
BIN
view/peko/activity/smallWeekStar/images/bg.png
Normal file
BIN
view/peko/activity/smallWeekStar/images/bg.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 458 KiB |
BIN
view/peko/activity/smallWeekStar/images/gift1.png
Normal file
BIN
view/peko/activity/smallWeekStar/images/gift1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 68 KiB |
BIN
view/peko/activity/smallWeekStar/images/gift2.png
Normal file
BIN
view/peko/activity/smallWeekStar/images/gift2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 20 KiB |
BIN
view/peko/activity/smallWeekStar/images/img1.png
Normal file
BIN
view/peko/activity/smallWeekStar/images/img1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 408 KiB |
BIN
view/peko/activity/smallWeekStar/images/img2.png
Normal file
BIN
view/peko/activity/smallWeekStar/images/img2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 128 KiB |
38
view/peko/activity/smallWeekStar/index.html
Normal file
38
view/peko/activity/smallWeekStar/index.html
Normal file
@@ -0,0 +1,38 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>闪耀周星</title>
|
||||
<link rel="stylesheet" href="../../common/css/reset.css">
|
||||
<link rel="stylesheet" href="./css/swiper-bundle.min.css">
|
||||
<link rel="stylesheet" href="./css/index.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="box">
|
||||
<img src="./images/gift1.png" alt="" class="gift">
|
||||
<div class="swiper">
|
||||
<div class="swiper-wrapper">
|
||||
<div class="swiper-slide">
|
||||
<img src="./images/img1.png" alt="">
|
||||
</div>
|
||||
<div class="swiper-slide">
|
||||
<img src="./images/img2.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
<script src="../../common/js/flexible.js"></script>
|
||||
<script src="../../common/js/jquery-3.2.1.min.js"></script>
|
||||
<script src="../../common/js/common2.js"></script>
|
||||
<script src="../../common/js/layer.js"></script>
|
||||
<script src="../../common/js/vconsole.min.js"></script>
|
||||
<script src="../../common/js/svga.min.js"></script>
|
||||
<script src="./js/swiper-bundle.min.js"></script>
|
||||
<script src="../../common/js/route-constant.js"></script>
|
||||
<script src="./js/index.js"></script>
|
37
view/peko/activity/smallWeekStar/js/index.js
Normal file
37
view/peko/activity/smallWeekStar/js/index.js
Normal file
@@ -0,0 +1,37 @@
|
||||
let urlPrefix = getUrlPrefix()
|
||||
let browser = checkVersion()
|
||||
let env = EnvCheck();
|
||||
if (env == 'test') {
|
||||
new VConsole();
|
||||
}
|
||||
// 初始化函数
|
||||
$(function () {
|
||||
getInfoFromClient()
|
||||
setTimeout(function () {
|
||||
// 页面全屏
|
||||
if (browser.app) {
|
||||
if (browser.android) {
|
||||
window.androidJsObj.initShowNav(false)
|
||||
} else {
|
||||
window.webkit.messageHandlers.initShowNav.postMessage(0)
|
||||
}
|
||||
};
|
||||
// 顶部返回事件
|
||||
$('.back').click(() => {
|
||||
if (browser.android) {
|
||||
window.androidJsObj.closeWebView()
|
||||
} else {
|
||||
window.webkit.messageHandlers.closeWebView.postMessage(null)
|
||||
}
|
||||
})
|
||||
// 礼物轮播
|
||||
var mySwiper = new Swiper('.swiper', {
|
||||
// direction: "vertical",
|
||||
loop: true,
|
||||
autoplay: {
|
||||
delay: 1500,//
|
||||
disableOnInteraction: false
|
||||
}
|
||||
})
|
||||
}, 100)
|
||||
})
|
14
view/peko/activity/smallWeekStar/js/swiper-bundle.min.js
vendored
Normal file
14
view/peko/activity/smallWeekStar/js/swiper-bundle.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user