{"version":3,"sources":["components/product/detail/banner/_std/product-detail-banner.js"],"names":["ProductDetailBanner","Component","constructor","el","banners","$findAll","EventBus","getInstance","addEventListener","e","onVariantChange","detail","variant","forEach","classList","remove","dataset","variantId","id","add"],"mappings":"aAAA,KAAMA,CAAAA,mBAAN,QAAkCC,CAAAA,SAAU,CAC3CC,WAAW,CAACC,EAAD,CAAK,CACf,MAAMA,EAAN,EACA,KAAKC,OAAL,CAAe,KAAKC,QAAL,CAAc,8BAAd,CAAf,CACAC,QAAQ,CAACC,WAAT,GAAuBC,gBAAvB,CAAwC,uBAAxC,CAAiEC,CAAC,EAAI,KAAKC,eAAL,CAAqBD,CAAC,CAACE,MAAvB,CAAtE,CACA,CAEDD,eAAe,CAACE,OAAD,CAAU,CACxB,KAAKR,OAAL,CAAaS,OAAb,CAAqB,SAAUV,EAAV,CAAc,CAClCA,EAAE,CAACW,SAAH,CAAaC,MAAb,CAAoB,WAApB,EACA,GAAIZ,EAAE,CAACa,OAAH,CAAWC,SAAX,EAAwBL,OAAO,CAACM,EAApC,CAAwC,CACvCf,EAAE,CAACW,SAAH,CAAaK,GAAb,CAAiB,WAAjB,CACA,CACD,CALD,CAMA,CAd0C","sourcesContent":["class ProductDetailBanner extends Component {\n\tconstructor(el) {\n\t\tsuper(el);\n\t\tthis.banners = this.$findAll('.ProductDetailBanner-variant');\n\t\tEventBus.getInstance().addEventListener('productVariantChanged', e => this.onVariantChange(e.detail));\n\t}\n\n\tonVariantChange(variant) {\n\t\tthis.banners.forEach(function (el) {\n\t\t\tel.classList.remove(\"is-active\");\n\t\t\tif (el.dataset.variantId == variant.id) {\n\t\t\t\tel.classList.add(\"is-active\");\n\t\t\t}\n\t\t});\n\t}\n}\n"],"file":"product-detail-banner.min.js"}