bfaabe0.js 6.6 KB

12
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([[37,58],{540:function(e,t,r){"use strict";var o=r(4),n=r(29),c=r(14),l=/"/g,f=o("".replace);e.exports=function(e,t,r,o){var m=c(n(e)),h="<"+t;return""!==r&&(h+=" "+r+'="'+f(c(o),l,"&quot;")+'"'),h+">"+m+"</"+t+">"}},541:function(e,t,r){"use strict";var o=r(3);e.exports=function(e){return o((function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}))}},555:function(e,t,r){e.exports={}},571:function(e,t,r){"use strict";r.r(t);var o={name:"Zoom",props:{imgUrl:String},data:function(){return{}},methods:{handler:function(e){var mask=this.$refs.mask,t=e.offsetX-mask.offsetWidth/2,r=e.offsetY-mask.offsetHeight/2;t<=0&&(t=0),t>=mask.offsetWidth&&(t=mask.offsetWidth),r<=0&&(r=0),r>=mask.offsetHeight&&(r=mask.offsetHeight),mask.style.left=t+"px",mask.style.top=r+"px";var o={};o.left=t,o.top=r,o.bigShow=!0,this.$emit("sendStyle",o)},leave:function(){var e={left:0,top:0,bigShow:!1};this.$emit("sendStyle",e)}}},n=(r(592),r(21)),component=Object(n.a)(o,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"spec-preview"},[t("el-image",{staticStyle:{width:"100%",height:"100%"},attrs:{src:e.imgUrl,alt:"",fit:"cover"}}),e._v(" "),t("div",{staticClass:"event",on:{mousemove:e.handler,mouseleave:e.leave,click:function(t){return e.$emit("handleViwer")}}}),e._v(" "),t("div",{ref:"mask",staticClass:"mask"})],1)}),[],!1,null,"5b247e95",null);t.default=component.exports},592:function(e,t,r){"use strict";r(555)},593:function(e,t,r){e.exports={}},623:function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAYCAYAAAAPtVbGAAAAAXNSR0IArs4c6QAAAepJREFUSEu9lk2IT2EUxn9Pk2SaBWWhbAYlalKk5GMhZKNYMWYnC6TMzhZjMRs7OxbKQr5WpmYjHwthMyspUj5SJDOYhZSFHp1/5+rOnTtzh9z/u7of7z2/8/Gc817RsGyvA4aAXcAAsDQ/mQaeAw+A65JezmVKc72wvRa4AOzPPb+AMPQp71cA4UBP3o8BpyW9qtqshdg+BlwEFgNP8npc0veyAdt9wD5gGNgG/IxrSZfL+2ZBbJ8DzgLfgOOSbjelNN7bPghcApYBI5LCTmfNgGQEsfE1sFfSm4UAij22VwN3gTXpYCeiP5CswTPgB7D5bwEV0ATQC2yIGpUhd7LIh+pSZHsj8F7Sl6boMnW3gDFJBzqQlOmLKLKk7VUjtpcDn4EAnJJ0YwGgxymG9QVkBDgDHJZ0swbSD7wtPY+oT0gq5DyLaXsQCGfOF5BHwNZotKpMM9IC8hBYBOwAvqZcr9VFlfKOhn1aQEKuHyRFR9d5VUCuAkezL0aBJUBEdVLSx5oMxERYWUAM3Je0pwki6UhGtwq4AuwEwuMt1W63fQ/Y3VVIV9LVlcJ3RcIxspuacRKY+udmTLU0jZVNwDtJ0R/zrtqxkpA4pNodkAmKw6q9UV8a1e0eWiVQu8dvCdTuj0RZOv/jl+g3/RhEvhTk7TEAAAAASUVORK5CYII="},624:function(e,t,r){"use strict";var o=r(2),n=r(540);o({target:"String",proto:!0,forced:r(541)("big")},{big:function(){return n(this,"big","","")}})},625:function(e,t,r){"use strict";r(593)},698:function(e,t,r){"use strict";r.r(t);var o=[function(){var e=this._self._c;return e("div",{staticClass:"playMask"},[e("img",{attrs:{src:r(623),alt:""}})])}],n=r(24),c=(r(43),r(44),r(60),r(63),r(64),r(48),r(11),r(36),r(535),r(624),r(45)),l=r(567);function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function m(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?f(Object(r),!0).forEach((function(t){Object(n.a)(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):f(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var h={components:{Zoom:r(571).default,ElImageViewer:l.a},props:{pageData:{type:Object,default:function(){return{}}},id:{type:Number,default:0}},data:function(){return{indexBanner:[],btnObj:["View larger","3D Preview"],current3D:0,btnShow:!0,bigShow:!1,showViewer:!1}},computed:{currentPre:function(){return this.$store.state.product.smImgUlIdx},comInfo:function(){var main=this.pageData.main,e=main.image_color.map((function(i){return i.image}));return main.image&&e.unshift(main.image),main.mergeImages=e,main},comS3Img:function(){var e=this;return this.comInfo.mergeImages.map((function(t){return e.$utils.repaceDomain(t)}))}},watch:{currentPre:function(e){this.$refs.carousel.setActiveItem(e)}},mounted:function(){this.comInfo.video&&(this.$refs.video.volume=.5)},methods:m(m({},Object(c.c)({setSmImgUlIdx:"product/setSmImgUlIdx"})),{},{changeCarousel:function(e){var t;this.setSmImgUlIdx(e),e===(null===(t=this.comInfo.mergeImages)||void 0===t?void 0:t.length)?(this.btnShow=!1,this.comInfo.video&&this.$refs.video.play()):(this.btnShow=!0,this.comInfo.video&&this.$refs.video.pause())},selectCurrent3D:function(e){this.current3D=e},getStyle:function(e){var t=this.$refs.big;t.style.left=-2*e.left+"px",t.style.top=-2*e.top+"px",this.bigShow=e.bigShow},closeViewer:function(){this.showViewer=!1},handleViwer:function(){this.showViewer=!0}})},d=(r(625),r(21)),component=Object(d.a)(h,(function(){var e,t=this,r=t._self._c;return r("div",{staticClass:"product-left"},[r("div",{staticClass:"media"},[r("div",{directives:[{name:"show",rawName:"v-show",value:t.bigShow,expression:"bigShow"}],staticClass:"big"},[r("img",{ref:"big",attrs:{src:t.$utils.generateResizedImageUrl(t.comInfo.mergeImages[t.currentPre],1800),alt:""}})]),t._v(" "),r("el-carousel",{ref:"carousel",attrs:{interval:5e3,arrow:"always",height:"578px","indicator-position":"none",autoplay:!1},on:{change:t.changeCarousel}},[t._l(t.comInfo.mergeImages,(function(e){return r("el-carousel-item",{key:e},[r("zoom",{attrs:{imgUrl:t.$utils.generateResizedImageUrl(t.comInfo.mergeImages[t.currentPre],1800)},on:{sendStyle:t.getStyle,handleViwer:t.handleViwer}})],1)})),t._v(" "),t.comInfo.video?r("el-carousel-item",[r("video",{ref:"video",attrs:{controls:"",width:"100%",height:"100%"}},[r("source",{attrs:{src:t.comInfo.video}}),t._v("\n Your browser does not support the video tag.\n ")])]):t._e()],2)],1),t._v(" "),r("div",{staticClass:"smImgUl"},[r("ul",[t._l(t.comInfo.mergeImages,(function(e,o){return r("li",{key:o,staticClass:"banner",class:t.currentPre==o?"slip":"",on:{click:function(e){t.changeCarousel(o)}}},[r("el-image",{staticClass:"card-img-1",staticStyle:{width:"100%",height:"100%"},attrs:{src:t.$utils.generateResizedImageUrl(e,100),fit:"cover"}})],1)})),t._v(" "),t.comInfo.video?r("li",{class:t.currentPre==(null===(e=t.comInfo.mergeImages)||void 0===e?void 0:e.length)?"slip":"",on:{click:function(e){var r;t.changeCarousel(null===(r=t.comInfo.mergeImages)||void 0===r?void 0:r.length)}}},[r("video",{attrs:{width:"100%",height:"100%",src:t.comInfo.video}}),t._v(" "),t._m(0)]):t._e()],2)]),t._v(" "),t.showViewer?r("ElImageViewer",{attrs:{"initial-index":t.currentPre,"on-close":t.closeViewer,"url-list":t.comS3Img}}):t._e()],1)}),o,!1,null,"200035a3",null);t.default=component.exports;installComponents(component,{Zoom:r(571).default})}}]);
  2. //# sourceMappingURL=bfaabe0.js.map