Authored by 郝肖肖

'miniapp'

... ... @@ -99,59 +99,3 @@
color: #fff;
text-decoration: none;
}
.mini-app-dialog-bg,
.mini-app-dialog {
display: none;
}
.mini-app-dialog-bg {
background-color: #000;
opacity: .3;
position: fixed;
width: 100%;
z-index: 30;
height: 100%;
}
.mini-app-dialog {
text-align: center;
position: fixed;
z-index: 31;
left: 50%;
top: 50%;
width: 12.5rem;
border-radius: 0.2rem;
background-color: #fff;
margin-left: -6.25rem;
margin-top: -6rem;
}
.mini-app-dialog .mini-app-header {
height: 2rem;
line-height: 2rem;
}
.mini-app-dialog .mini-app-content {
padding: 0.625rem;
}
.mini-app-dialog .mini-app-content img {
width: 6.45rem;
height: 6.45rem;
}
.mini-app-dialog .mini-app-footer {
height: 3.65rem;
line-height: 3.65rem;
font-size: 0.7rem;
}
.mini-app-dialog .mini-app-close {
width: 0.75rem;
height: 0.75rem;
position: absolute;
right: 0.25rem;
top: 0.25rem;
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAmFJREFUeNrMl99OE0EUxrdL9bYYbWoEJajUP5ckXsM2IZJe0IQQqY9AGq0+QY0vUExs+gqQkCblAi0ktPckvUQoQoyihDbE6qWELN9pzjbr6O7MlK7xJB/Tdg/nN+fszOzZkG3bhszK5fIlDI+hKegRdAe6wpe/Q/vQFrQBradSqV+ymCE/MICDGF5AGeiaoWYnUAHKYwJtbTCgaQyLUMzozZpQFvAlJTCAAxjecJb9sCL0DBM48wQzlGY4Z/TXStATN9wUHBYDgJLNchX/zBjZznO2QdpT5553wLx6dy6wkFStBcVptTulzvpAJ3jfNhQCb0Mj0LTH9Sj0snOPke1lyQr+ihkeYExAexKoBd/P9D8+fhlimnwaRX0c38FxCAEpmOUBJ2gCPk34UsarPvGu0ilo8lHoZ2PQpgsuZv6BocfwuYXPVWhUErMDHle4d3GG3wDgkOEfGWq5oDUFKNm4yRkZPcCtHjLtVjGMPxGN7XCP4RbDaSveZOhtjTgRytjW3Iu24m++RuCfGv67XN4jZDoMXcfnL1z2A404P0zJ3hShlgPl8lZd8EkN+B6B67qZMvQudJ/vuS68TuCKxKnB0G8C1LEHDI9plL1icp/U8nFKuqCbAtQNrzKcjswZSWtUcZ5OOXx55eFI5aNM3ivseTo6k9BDaM3D5zUmlwvzF3pIL3g8oWoaq5WAnySPxXy3A+FuMGsEb8+dzrPb+uCHZQxvA4QW3B2n2HNRD70SALQkVvQ3MHeBaW7I+2VFscP8vxr6v7zCZLk1iv6TVxiFl7ZBvtwWXtoqAJ7KYp4LMACryxGMnWAbNgAAAABJRU5ErkJggg==");
background-size: cover;
}
... ...
.mini-app-dialog-bg,
.mini-app-dialog {
display: none;
}
.mini-app-dialog-bg {
background-color: #000;
opacity: .3;
position: fixed;
width: 100%;
z-index: 30;
height: 100%;
}
.mini-app-dialog {
text-align: center;
position: fixed;
z-index: 31;
left: 50%;
top: 50%;
width: 12.5rem;
border-radius: 0.2rem;
background-color: #fff;
margin-left: -6.25rem;
margin-top: -6rem;
}
.mini-app-dialog .mini-app-header {
height: 2rem;
line-height: 2rem;
}
.mini-app-dialog .mini-app-content {
padding: 0.625rem;
}
.mini-app-dialog .mini-app-content img {
width: 6.45rem;
height: 6.45rem;
}
.mini-app-dialog .mini-app-footer {
height: 3.65rem;
line-height: 3.65rem;
font-size: 0.7rem;
}
.mini-app-dialog .mini-app-close {
width: 0.75rem;
height: 0.75rem;
position: absolute;
right: 0.25rem;
top: 0.25rem;
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAmFJREFUeNrMl99OE0EUxrdL9bYYbWoEJajUP5ckXsM2IZJe0IQQqY9AGq0+QY0vUExs+gqQkCblAi0ktPckvUQoQoyihDbE6qWELN9pzjbr6O7MlK7xJB/Tdg/nN+fszOzZkG3bhszK5fIlDI+hKegRdAe6wpe/Q/vQFrQBradSqV+ymCE/MICDGF5AGeiaoWYnUAHKYwJtbTCgaQyLUMzozZpQFvAlJTCAAxjecJb9sCL0DBM48wQzlGY4Z/TXStATN9wUHBYDgJLNchX/zBjZznO2QdpT5553wLx6dy6wkFStBcVptTulzvpAJ3jfNhQCb0Mj0LTH9Sj0snOPke1lyQr+ihkeYExAexKoBd/P9D8+fhlimnwaRX0c38FxCAEpmOUBJ2gCPk34UsarPvGu0ilo8lHoZ2PQpgsuZv6BocfwuYXPVWhUErMDHle4d3GG3wDgkOEfGWq5oDUFKNm4yRkZPcCtHjLtVjGMPxGN7XCP4RbDaSveZOhtjTgRytjW3Iu24m++RuCfGv67XN4jZDoMXcfnL1z2A404P0zJ3hShlgPl8lZd8EkN+B6B67qZMvQudJ/vuS68TuCKxKnB0G8C1LEHDI9plL1icp/U8nFKuqCbAtQNrzKcjswZSWtUcZ5OOXx55eFI5aNM3ivseTo6k9BDaM3D5zUmlwvzF3pIL3g8oWoaq5WAnySPxXy3A+FuMGsEb8+dzrPb+uCHZQxvA4QW3B2n2HNRD70SALQkVvQ3MHeBaW7I+2VFscP8vxr6v7zCZLk1iv6TVxiFl7ZBvtwWXtoqAJ7KYp4LMACryxGMnWAbNgAAAABJRU5ErkJggg==");
background-size: cover;
}
... ...
... ... @@ -48,8 +48,7 @@ var appInfo = {
var isApp = /yoho/i.test(navigator.userAgent) || /app_version=/i.test(window.location.search) || !!window.yohoInterface;
var isMobile = /(iPhone|Android|iPad|iPod|iOS)/i.test(navigator.userAgent);
// var isWechat = /micromessenger/i.test(navigator.userAgent);
var isWechat = true;
var isWechat = /micromessenger/i.test(navigator.userAgent);
var ismyhbuy = /m\.yohobuy\.com/i.test(document.domain);
var isfeature = /feature\.yoho\.cn/i.test(document.domain) || /activity\.yoho\.cn/i.test(document.domain);
var downloadBlackLst = ['m.yohobuy.com/brands', 'm.yohobuy.com/passport'];
... ... @@ -448,7 +447,7 @@ function setMiniAppDialog() {
// 设定fontsize
util.setFontSize();
var css = require('../css/download.css')
var css = require('../css/wechat-mini-app.css');
var miniDom = document.createElement('div');
miniDom.innerHTML = util.getMiniAppDialog();
... ... @@ -493,6 +492,11 @@ function setDownloadBar() {
return;
}
// 设定fontsize
util.setFontSize();
var css = require('../css/download.css');
var downloadDom = document.createElement('div');
downloadDom.innerHTML = util.getDownloadStr(isWechat);
yasDombar.appendChild(downloadDom);
... ...