...
|
...
|
@@ -4,14 +4,21 @@ |
|
|
* Date: 2016/7/19
|
|
|
* Time: 16:05
|
|
|
*/
|
|
|
const $ = require('yoho-jquery');
|
|
|
const Vue = require('yoho-vue');
|
|
|
const lazyload = require('yoho-vue-lazyload');
|
|
|
const contentCode = require('content-code');
|
|
|
const qs = require('yoho-qs');
|
|
|
|
|
|
const brandBox = require('channel/brand-box.vue');
|
|
|
|
|
|
new Vue({
|
|
|
el: '#brand',
|
|
|
data() {
|
|
|
return {
|
|
|
page: 'brand',
|
|
|
contentCode: contentCode.brand[qs.brand || 'men']
|
|
|
}
|
|
|
},
|
|
|
components: {
|
|
|
brandBox
|
|
|
}
|
...
|
...
|
@@ -19,20 +26,3 @@ new Vue({ |
|
|
|
|
|
Vue.use(lazyload);
|
|
|
|
|
|
const $expand = $('.expand'),
|
|
|
$collapse = $('.collapse'),
|
|
|
$brandIntro = $('.brand-intro'),
|
|
|
exCoTm = 4; // 展开隐藏的倍数
|
|
|
|
|
|
$expand.on('click', function() {
|
|
|
$brandIntro.removeClass('line-clamp').animate({height: $brandIntro.height() * exCoTm});
|
|
|
$expand.hide();
|
|
|
$collapse.show();
|
|
|
});
|
|
|
|
|
|
$collapse.on('click', function() {
|
|
|
$brandIntro.addClass('line-clamp').animate({height: $brandIntro.height() / exCoTm});
|
|
|
$collapse.hide();
|
|
|
$expand.show();
|
|
|
});
|
|
|
|
...
|
...
|
|