Authored by 周少峰

Merge branch 'release/5.4.1' into gray

... ... @@ -17,8 +17,11 @@
{{#if devEnv}}
<link rel="stylesheet" href="//{{devHost}}:5002/css/index.css">
<link rel="stylesheet" href="//{{devHost}}:5002/css/cart.index.css">
{{^}}
<link rel="stylesheet" href="//{{#isEqual cdn 'qcloud'}}qcdn.yoho.cn{{^}}cdn.yoho.cn{{/isEqual}}/yohobuy-node/{{version}}/index.css">
<link rel="stylesheet" href="//{{#isEqual cdn 'qcloud'}}qcdn.yoho.cn{{^}}cdn.yoho.cn{{/isEqual}}/yohobuy-node/{{version}}/cart.index.css">
{{/if}}
</head>
<body>
... ...
... ... @@ -125,7 +125,7 @@ gulp.task('dist', ['ge'], () => {
// postcss compile in dev
gulp.task('postcss-dev', () => {
return gulp.src('scss/index.css')
return gulp.src(['scss/index.css', 'scss/cart.index.css'])
.pipe(sourcemaps.init())
.pipe(postcss(postcssPlugin(env.dev)))
.pipe(sourcemaps.write('.'))
... ... @@ -154,7 +154,7 @@ gulp.task('font', () => {
// postcss compile in pro
gulp.task('postcss', ['assets'], () => {
return gulp.src('scss/index.css')
return gulp.src(['scss/index.css', 'scss/cart.index.css'])
.pipe(postcss(postcssPlugin(env.pro)))
.pipe(cssnano())
.pipe(gulp.dest(dist.css));
... ...

42.5 KB | W: | H:

608 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
... ... @@ -5,8 +5,10 @@
*/
var $ = require('yoho-jquery');
var areaSelect = {
isIE8: window.navigator.appName === 'Microsoft Internet Explorer' && window.navigator.appVersion.match(/8./i) === '8.', // eslint-disable-line
require('../../common'); // eslint-disable-line
var areaSelect = { // eslint-disable-line
isIE8: window.isIE8,
init: function($el, areaCode) {
var city, province, area;
... ...
... ... @@ -215,6 +215,28 @@ function isLogin() {
}
}
function isIE() {
return /msie|trident/i.test(navigator.userAgent);
}
function isIEVer(version) {
var ver = '';
var getVersion = function(regex) {
var ua = navigator.userAgent;
var match = ua && ua.match(regex);
return (match && match.length > 1 && match[1]) || '';
};
if (isIE()) {
ver = getVersion(/(?:msie |rv:)(\d+(\.\d+)?)/i);
return ver === version;
}
return false;
}
// 品友
function addPyEvent(eventName, val) {
if (typeof window.py === 'function') {
... ... @@ -247,6 +269,10 @@ window.registerUrl = registerUrl;
window.jumpUrl = jumpUrl;
window.isIE = isIE;
window.isIE8 = isIEVer('8.0');
window.once = once;
window.addPyEvent = addPyEvent;
... ...
@charset "utf-8";
/* 模块 */
@import 'cart/index';
... ...
... ... @@ -15,6 +15,6 @@
@import "share";
@import 'home/index';
@import 'guang/index';
@import 'cart/index';
/*@import 'cart/index';*/
@import 'service/index';
@import '3party/index';
... ...