@everymatrix/bonus-elevate-shop-item 1.55.0 → 1.56.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bonus-elevate-shop-item/bonus-elevate-shop-item.esm.js +1 -1
- package/dist/bonus-elevate-shop-item/p-649baad8.entry.js +1 -0
- package/dist/bonus-elevate-shop-item/p-7e614c16.js +2 -0
- package/dist/cjs/bonus-elevate-shop-assets-slider_3.cjs.entry.js +47 -16
- package/dist/cjs/bonus-elevate-shop-item.cjs.js +2 -2
- package/dist/cjs/{index-791389e8.js → index-5ee6395c.js} +257 -147
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/bonus-elevate-shop-item/bonus-elevate-shop-assets-slider.js +22 -5
- package/dist/collection/components/bonus-elevate-shop-item/bonus-elevate-shop-item.js +41 -7
- package/dist/esm/bonus-elevate-shop-assets-slider_3.entry.js +47 -16
- package/dist/esm/bonus-elevate-shop-item.js +3 -3
- package/dist/esm/{index-3fe56209.js → index-d65aef7f.js} +257 -147
- package/dist/esm/loader.js +2 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/packages/stencil/bonus-elevate-shop-item/stencil.config.d.ts +2 -0
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/packages/stencil/bonus-elevate-shop-item/stencil.config.dev.d.ts +2 -0
- package/package.json +1 -1
- package/dist/bonus-elevate-shop-item/p-11ccf3d4.entry.js +0 -1
- package/dist/bonus-elevate-shop-item/p-8ebd9aab.js +0 -2
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/packages/stencil/bonus-elevate-shop-item/stencil.config.d.ts +0 -2
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/packages/stencil/bonus-elevate-shop-item/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/tools/plugins/vite-chunk-plugin.d.ts +0 -0
- /package/dist/types/Users/{maria.bumbar/Desktop → adrian.pripon/Documents/Work}/widgets-monorepo/packages/stencil/bonus-elevate-shop-item/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
package/dist/esm/loader.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { b as bootstrapLazy } from './index-
|
|
2
|
-
export { s as setNonce } from './index-
|
|
1
|
+
import { b as bootstrapLazy } from './index-d65aef7f.js';
|
|
2
|
+
export { s as setNonce } from './index-d65aef7f.js';
|
|
3
3
|
import { g as globalScripts } from './app-globals-0f993ce5.js';
|
|
4
4
|
|
|
5
5
|
const defineCustomElements = async (win, options) => {
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as e,h as t,g as i,c as a,F as s,H as o}from"./p-8ebd9aab.js";const r=class{constructor(t){e(this,t),this.xDown=null,this.yDown=null,this.orientationChangeHandler=()=>{setTimeout((()=>{this.recalculateItemsPerPage()}),10)},this.resizeHandler=()=>{this.recalculateItemsPerPage()},this.showSliderDots=!1,this.showSliderArrows=!0,this.itemsPerPage=1,this.sliderItems=[],this.activeIndex=0}setActive(e){var t;const i=null===(t=this.sliderItems)||void 0===t?void 0:t.length;this.activeIndex=e>=0?e>=i-1?i-1:e:0}move(e){this.setActive(this.activeIndex+e)}goTo(e){let t=this.activeIndex-e;if(t>0)for(let e=0;e<t;e++)this.move(-1);else for(let e=0;e>t;e--)this.move(1)}handleTouchStart(e){const t=this.getTouches(e)[0];this.xDown=t.clientX,this.yDown=t.clientY}getTouches(e){return e.touches||e.originalEvent.touches}handleTouchMove(e){if(!this.xDown||!this.yDown)return;let t=this.xDown-e.touches[0].clientX,i=this.yDown-e.touches[0].clientY;Math.abs(t)>Math.abs(i)&&this.move(t>0?1:-1),this.xDown=null,this.yDown=null}recalculateItemsPerPage(){this.sliderItemsElement&&(this.itemElementWidth=this.sliderItemsElement.clientWidth,this.sliderItemsElementWidth=(this.sliderItems.length-1)*this.itemElementWidth)}renderDots(){var e;const i=[];for(let a=0;a<(null===(e=this.sliderItems)||void 0===e?void 0:e.length)/this.itemsPerPage;a++)i.push(t("li",{class:a==this.activeIndex?"active":"default",onClick:()=>{this.goTo(a),this.setActive(a)}}));return i}componentDidRender(){this.el.addEventListener("touchstart",this.handleTouchStart.bind(this),{passive:!0}),this.el.addEventListener("touchmove",this.handleTouchMove.bind(this),{passive:!0}),this.recalculateItemsPerPage()}componentDidUpdate(){this.recalculateItemsPerPage()}connectedCallback(){window.screen.orientation.addEventListener("change",this.orientationChangeHandler)}disconnectedCallback(){this.el.removeEventListener("touchstart",this.handleTouchStart),this.el.removeEventListener("touchmove",this.handleTouchMove),window.screen.orientation.removeEventListener("change",this.orientationChangeHandler),window.removeEventListener("resize",this.resizeHandler)}render(){var e;const i={transform:`translate(${this.sliderItemsElementWidth/((null===(e=this.sliderItems)||void 0===e?void 0:e.length)-1)*this.activeIndex*-1}px, 0px)`},a={width:this.itemElementWidth/this.itemsPerPage+"px"};return t("div",{key:"3740bd5b367f4e24f0b4391dc7f25c63ccb12958",class:"SliderWrapper"},t("div",{key:"6aac842f54de59cea8b2f2655e8408a8778702d4",class:"MainContent "},this.showSliderArrows&&t("div",{key:"94de38b6a631824bbe15964d70377639af769917",class:`SliderNavButton LeftArrow ${0===this.activeIndex?"DisabledArrow ":""} ${1===this.sliderItems.length?"HiddenArrow ":""}`,onClick:()=>this.move(-1)},t("svg",{key:"382d3d0c54932b359b2be4b9ed8c3db3c6da49ec",fill:"none",stroke:"var(--emw--color-secondary, #FD2839)",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},t("path",{key:"9b4d592aa650ddff2fbd8625a8b0a5d1b604c723","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 19l-7-7 7-7"}))),t("div",{key:"b3ec493624a11931eb48e44eb620373b2613d0a8",class:"ItemsWrapper",ref:e=>this.sliderItemsElement=e},t("div",{key:"724e11f1b3899c0f4bb179fff9b60f40c363e7f1",class:"Items AssetsItems",style:i},this.sliderItems.map((e=>t("img",{class:`img${this.itemsPerPage}`,alt:"Gift Thumbnails",style:a,src:e}))))),this.showSliderArrows&&t("div",{key:"2791a14781f73619c122401a97a9833e33787282",class:`SliderNavButton RightArrow ${1===this.sliderItems.length?"HiddenArrow ":""}\n ${this.activeIndex===this.sliderItems.length-1||this.itemsPerPage==this.sliderItems.length?"DisabledArrow":""}`,onClick:()=>this.move(1)},t("svg",{key:"3810b14f2a0fc436601186335a01b7af90aabab5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},t("path",{key:"18178c52a74cf77c856f65b6f377a350fc672db8","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5l7 7-7 7"})))),this.showSliderDots&&this.sliderItems.length>1&&t("div",{key:"83964fb11e6728adb065958ebfbf17902e301b2e",class:"DotsWrapper"},t("ul",{key:"cafab68d463e25a0847306314c64041bc3f107f7",class:"Dots"},this.renderDots())))}get el(){return i(this)}},d=["ro","en","fr","ar","hu"],n={en:{coins:"Coins",noGiftPresentation:"No description",redeemGift:"Redeem Gift",noDataFound:"No data found",error4003:"Invalid Session",redeemFailed:"Failed to redeem",back:"Back"},ro:{coins:"Coins",noGiftPresentation:"No description",redeemGift:"Redeem Gift",noDataFound:"No data found",error4003:"Invalid Session",redeemFailed:"Failed to redeem",back:"Back"},fr:{coins:"Coins",noGiftPresentation:"No description",redeemGift:"Redeem Gift",noDataFound:"No data found",error4003:"Invalid Session",redeemFailed:"Failed to redeem",back:"Back"},ar:{coins:"Coins",noGiftPresentation:"No description",redeemGift:"Redeem Gift",noDataFound:"No data found",error4003:"Invalid Session",redeemFailed:"Failed to redeem",back:"Back"},hu:{coins:"Coins",noGiftPresentation:"No description",redeemGift:"Redeem Gift",noDataFound:"No data found",error4003:"Invalid Session",redeemFailed:"Failed to redeem",back:"Back"}},l=(e,t)=>{const i=t;return n[void 0!==i&&d.includes(i)?i:"en"][e]},c=class{constructor(t){e(this,t),this.redeemGiftButton=a(this,"redeemGiftButton",7),this.bindedHandler=this.handleMessage.bind(this),this.deviceType=(()=>{const e=(()=>{let e=window.navigator.userAgent;return e.toLowerCase().match(/android/i)?"Android":e.toLowerCase().match(/iphone/i)?"iPhone":e.toLowerCase().match(/ipad|ipod/i)?"iPad":"PC"})();if(e)return"PC"===e?"dk":"iPad"===e||"iPhone"===e?"ios":"mtWeb"})(),this.endpoint=void 0,this.language="en",this.itemId=void 0,this.elevateGift=void 0,this.session=void 0,this.clientStyling="",this.clientStylingUrl="",this.translationUrl="",this.showSliderDots=!1,this.showSliderArrows=!0,this.isGiftNotFound=!1,this.redeemErrorMsg="",this.isRedeeming=!1}redeemGiftConfirm(){this.isRedeeming||"true"!=this.elevateGift.available||window.postMessage({type:"BEERedeemConfirm",shopItem:this.elevateGift},window.location.href)}handleMessage(e){e.data&&"bee-redeem-confirmed"===e.data.type&&e.data.id==this.elevateGift.id&&this.redeemGift()}onBackClicked(){window.postMessage({type:"OnGiftDetailsBackButtonClicked"},window.location.href)}redeemGift(){if("false"===this.elevateGift.available.toLowerCase()||this.isRedeeming)return;let e=new URL(`${this.endpoint}/v1/elevate/redeem`),t={method:"PUT",headers:{"x-SessionId":this.session,"Content-Type":"application/json-patch+json"},body:JSON.stringify({giftId:this.elevateGift.id})};this.redeemErrorMsg="",this.isRedeeming=!0,fetch(e.toString(),t).then((e=>e.json())).then((e=>{if(e.success)this.redeemGiftButton.emit(),window.postMessage({type:"BEEGiftRedeem",itemId:this.elevateGift.id},window.location.href);else{let t=l(`error${e.errorCode}`,this.language);this.redeemErrorMsg=t||l("redeemFailed",this.language),window.postMessage({type:"BEEGiftRedeemFailed",itemId:this.elevateGift.id,res:e},window.location.href)}})).catch((e=>{window.postMessage({type:"BEEGiftClaimFailed",itemId:this.elevateGift.id,err:e},window.location.href)})).finally((()=>{this.isRedeeming=!1}))}async loadElevateGift(){let e=new URL(`${this.endpoint}/v1/elevate/shop?language=${this.language}&filter=id=${this.itemId}`),t={headers:{"Content-Type":"application/json","x-SessionId":this.session},method:"GET"};await new Promise((i=>{fetch(e.href,t).then((e=>e.json())).then((e=>{let t=e.data;t&&1==t.length?(this.elevateGift=t[0],this.isGiftNotFound=!1):this.isGiftNotFound=!0,i(!0)}))}))}disconnectedCallback(){window.removeEventListener("message",this.bindedHandler,!1)}componentDidLoad(){window.addEventListener("message",this.bindedHandler,!1)}async componentWillLoad(){var e;this.translationUrl.length>2&&await(e=this.translationUrl,new Promise((t=>{fetch(e).then((e=>e.json())).then((e=>{Object.keys(e).forEach((t=>{for(let i in e[t])n[t][i]=e[t][i]})),t(!0)}))}))),this.elevateGift?this.isGiftNotFound=!1:await this.loadElevateGift()}render(){return t(o,{key:"a2a758ab006921f8ec338fda72ab48518f964f3a"},t("general-styling-wrapper",{key:"e1c4d819b7d41706380cd2353eb6da4c82dae256",clientStylingUrl:this.clientStylingUrl,clientStyling:this.clientStyling}),t("div",{key:"5bb49371ddf5c55969132b0d33fe30095779fecb",class:"ElevateDetails"},this.isGiftNotFound&&t(s,{key:"dd7e3a21bedfa2d4ead0553d168a3c087268004d"},t("div",{key:"065b3c57d55abe302ec6a38d6522b3ebe98404b9",class:"Row ThumbnailRow"},t("div",{key:"81f4b48c4ec79824d23a98127a232fa3ed8933fd",class:"BackButton",onClick:()=>{this.onBackClicked()}},t("span",{key:"255d69ec2b508e36d0eac44d97bf75a3f9715eb6",class:"BackArrow",innerHTML:"<"}),t("span",{key:"76867b36d03809eaa6a334c09817640d19ca6273",class:"BackTxt"}," ",l("back",this.language)," "))),t("div",{key:"c43cdf9911df9895f6e947bb1b160ba05f495027",class:"Thumnails GiftNotFound"},l("noDataFound",this.language),".")),this.elevateGift&&t(s,{key:"0c53a7450d3e6c86933c7612346471dfb9bd1b76"},t("div",{key:"9c2d934e82e4147b9f77e91a45548abb568b24ff",class:"ThumbnailRow"},t("div",{key:"0ba463a1262c0b9aad66407d201060240f90e695",class:"Row"},t("div",{key:"b16e46f40ec7a2d48d88adf2123929d2d107f42a",class:"BackButton",onClick:()=>{this.onBackClicked()}},t("span",{key:"dec9e77e0cc5e5df846cbce61c79fa5c2a7af194",class:"BackArrow",innerHTML:"<"}),t("span",{key:"013fcd5ae4702bcf2b1a2f4fadea810896501a7e",class:"BackTxt"}," ",l("back",this.language)," ")),t("bonus-elevate-shop-assets-slider",{key:"e72ed5a7a62411a840190da1d88eafc35e060086",class:"Thumbnails",itemsPerPage:1,sliderItems:this.elevateGift.presentation.assets,showSliderDots:this.showSliderDots})),t("div",{key:"da8e89af090202073a213f708b5d991dcd0bf46f",class:"Col Details"},t("h3",{key:"f057ad4ea2d08c7ece777cf97c4363f36fae74a8",class:"GiftName"},this.elevateGift.presentation.displayName||this.elevateGift.displayName),t("div",{key:"48349d04e8057979453b4497f65d576cd68786bd",class:"GiftPoints"},t("span",{key:"f89912c2447b3d800673a12076aea4344bc8d110",class:"Points"},this.elevateGift.points," "),t("span",{key:"695faa9923ba7d83601ed84d52ae23a8628a4b6f",class:" PointsLabel"},l("coins",this.language))))),t("div",{key:"55f40001d80c1358c458e4a44e464850e683f8ff",class:"ShopItemDetail Details"},t("div",{key:"ce5da55a6b0913a38cb6a2896da9d0a8007434bc",class:"GiftPresentation"},t("p",{key:"83cc1faf299250619be468a2209b1f89e210173d"},this.elevateGift.presentation.description?this.elevateGift.presentation.description:l("noGiftPresentation",this.language))),t("div",{key:"5c5cfb64bc73e6161a64e91e048be70f5783fb8b",class:`RedeemButton ${"false"===this.elevateGift.available||this.isRedeeming?"Disabled deactive":" active "}\n ${"dk"==this.deviceType?"DkButton":""}`,onClick:this.redeemGiftConfirm.bind(this)},l("redeemGift",this.language)),t("span",{key:"ef2e12788cc82b7f199637fbbea9480d679abc4c",class:"RedeemError Error"}," ",this.redeemErrorMsg," ")))))}};c.style=":host{display:block}.ElevateDetails{display:flex;flex-direction:row;flex-wrap:wrap;padding:10px;width:calc(100% - 20px);}.ElevateDetails .RedeemError{display:none}.ElevateDetails .Error{color:var(--emw--color-error, #FD2839)}.ElevateDetails .Row{flex-direction:row;display:flex}.ElevateDetails .Col{flex-direction:column;display:flex}.ElevateDetails .Details{padding:20px}.ElevateDetails .ThumbnailRow{display:flex;flex-direction:column;justify-content:space-between;min-width:268px;max-width:398px}.ElevateDetails .ThumbnailRow .BackButton{width:100px;height:20px;padding:5px;background:white;box-shadow:0px 4px 40px 0px rgba(138, 149, 158, 0.2);margin:10px 0 10px;cursor:pointer;animation-timing-function:ease-out;animation-duration:300ms;transition-property:all;border:1px solid #e4e6e8;border-radius:5px;text-align:center}.ElevateDetails .ThumbnailRow .BackButton:hover{background:rgb(227, 222, 222)}.ElevateDetails .ThumbnailRow .Thumbnails{display:flex;flex-direction:column;position:relative;width:calc(100% - 40px)}.ElevateDetails .ShopItemDetail{flex-grow:1;min-width:300px}.ElevateDetails .GiftPoints .Points{font-size:21px}.ElevateDetails .GiftPoints .PointsLabel{font-size:12px;color:var(--emw--color-gray-300, rgb(78, 90, 55));font-weight:400;line-height:29px;letter-spacing:0.04em;text-align:left}.ElevateDetails .RedeemButton{width:150px;padding:5px 0px;border:2px solid var(--emw--button-border-color, rgba(8, 59, 23, 0.1098039216));text-align:center;color:var(--emw--button-typography, var(--emw--color-white, #FFFFFF));font-size:var(--emw--font-size-small, 12px);font-weight:var(--emw--font-weight-bold, 700);line-height:var(--emw--font-size-medium, 14px);text-transform:uppercase;border-radius:var(--emw--border-radius-medium, 20px)}.ElevateDetails .RedeemButton.active{background:var(--emw--color-primary, #18CE51)}.ElevateDetails .RedeemButton.active:hover{background:var(--mmw--color-main-button-hover, #24B24E)}.ElevateDetails .RedeemButton.deactive,.ElevateDetails .RedeemButton.disabled{background:var(--mmw--color-disabled, rgba(153, 153, 153, 0.5019607843))}.ElevateDetails .SliderWrapper{display:flex;flex-direction:column;position:relative;width:calc(100% - 40px)}.ElevateDetails .SliderWrapper .MainContent{display:flex;flex-direction:row;justify-content:space-around}.ElevateDetails .SliderWrapper .MainContent .LeftArrow,.ElevateDetails .SliderWrapper .MainContent .RightArrow{width:20px}.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper{overflow:hidden;display:inline-flex;width:calc(100% - 40px);flex-direction:column}.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper .Items{display:inline-flex;transition:transform 0.4s ease-in-out;transform:translateX(0px);margin:auto}.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper img.img2{width:50%}.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper img.img3{width:30%}.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper img,.ElevateDetails .SliderWrapper .MainContent .ItemsWrapper img.img1{max-width:100%;background:rgb(239, 239, 239);border:1px solid rgb(239, 239, 239);border-radius:18px;border:1px;margin:10px 0 10px}.ElevateDetails .SliderWrapper .DotsWrapper{width:100%;margin:0 auto;height:30px}.ElevateDetails .SliderWrapper .DotsWrapper ul.Dots{display:flex;justify-content:center;padding:0}.ElevateDetails .SliderWrapper .DotsWrapper ul.Dots li{height:10px;width:10px;background:#ccc;border-radius:50%;margin-left:3px;margin-right:3px;list-style:none;cursor:pointer}.ElevateDetails .SliderWrapper .DotsWrapper ul.Dots li:hover{background:#bbb}.ElevateDetails .SliderWrapper .DotsWrapper ul.Dots li.active{border:solid 1px var(--emw--color-secondary, #FD2839);background:var(--emw--color-secondary, #FD2839)}.ElevateDetails .SliderWrapper .DotsWrapper ul.Dots li.default{border:solid 1px var(--emw--color-secondary, #FD2839);background-color:#FFF}.ElevateDetails .SliderNavButton{border:0px;width:25px;display:flex;align-items:center;justify-content:center;cursor:pointer}.ElevateDetails .SliderNavButton.HiddenArrow{visibility:hidden}.ElevateDetails .SliderNavButton svg{width:20px;stroke:var(--emw--color-secondary, #FD2839)}.ElevateDetails .DisabledArrow svg{opacity:0.2;stroke:var(--emw--color-secondary, #FD2839);pointer-events:none}";const h=class{constructor(t){e(this,t),this.stylingAppends=!1,this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.el.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{this.el.prepend(t)}),1)})).catch((e=>{console.log("error ",e)}))},this.clientStyling="",this.clientStylingUrl="",this.translationUrl="",this.targetTranslations=void 0}componentDidRender(){this.stylingAppends||(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.stylingAppends=!0)}async componentWillLoad(){const e=[];if(this.translationUrl){const a=(t=this.translationUrl,i=this.targetTranslations,new Promise((e=>{fetch(t).then((e=>e.json())).then((t=>{Object.keys(t).forEach((e=>{i[e]=i[e]?i[e]:{};for(let a in t[e])i[e][a]=t[e][a]})),e(!0)}))})));e.push(a)}var t,i;return await Promise.all(e)}render(){return t("div",{key:"4d3414408c7662f88331dbe655966237f74d6958",class:"StyleShell"},t("slot",{key:"1d004644d84602c4314bdf5dfc26b55b160f57df",name:"mainContent"}))}get el(){return i(this)}};h.style=":host{display:block}";export{r as bonus_elevate_shop_assets_slider,c as bonus_elevate_shop_item,h as general_styling_wrapper}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
var e=Object.defineProperty,t=new WeakMap,n=e=>t.get(e),o=(e,n)=>t.set(n.t=e,n),l=(e,t)=>t in e,s=(e,t)=>(0,console.error)(e,t),i=new Map,r=new Map,c="slot-fb{display:contents}slot-fb[hidden]{display:none}",f="undefined"!=typeof window?window:{},u=f.document||{head:{}},a={o:0,l:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,o)=>e.addEventListener(t,n,o),rel:(e,t,n,o)=>e.removeEventListener(t,n,o),ce:(e,t)=>new CustomEvent(e,t)},d=e=>Promise.resolve(e),h=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(e){}return!1})(),p=!1,m=[],v=[],y=(e,t)=>n=>{e.push(n),p||(p=!0,t&&4&a.o?w(b):a.raf(b))},$=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){s(e)}e.length=0},b=()=>{$(m),$(v),(p=m.length>0)&&a.raf(b)},w=e=>d().then(e),g=y(v,!0),S={},k=e=>"object"==(e=typeof e)||"function"===e;function j(e){var t,n,o;return null!=(o=null==(n=null==(t=e.head)?void 0:t.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?o:void 0}((t,n)=>{for(var o in n)e(t,o,{get:n[o],enumerable:!0})})({},{err:()=>E,map:()=>C,ok:()=>O,unwrap:()=>P,unwrapErr:()=>A});var O=e=>({isOk:!0,isErr:!1,value:e}),E=e=>({isOk:!1,isErr:!0,value:e});function C(e,t){if(e.isOk){const n=t(e.value);return n instanceof Promise?n.then((e=>O(e))):O(n)}if(e.isErr)return E(e.value);throw"should never get here"}var M,x,R,P=e=>{if(e.isOk)return e.value;throw e.value},A=e=>{if(e.isErr)return e.value;throw e.value},D=(e,t,...n)=>{let o=null,l=null,s=null,i=!1,r=!1;const c=[],f=t=>{for(let n=0;n<t.length;n++)o=t[n],Array.isArray(o)?f(o):null!=o&&"boolean"!=typeof o&&((i="function"!=typeof e&&!k(o))&&(o+=""),i&&r?c[c.length-1].i+=o:c.push(i?T(null,o):o),r=i)};if(f(n),t){t.key&&(l=t.key),t.name&&(s=t.name);{const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}}if("function"==typeof e)return e(null===t?{}:t,c,F);const u=T(e,null);return u.u=t,c.length>0&&(u.h=c),u.p=l,u.m=s,u},T=(e,t)=>({o:0,v:e,i:t,$:null,h:null,u:null,p:null,m:null}),H={},F={forEach:(e,t)=>e.map(L).forEach(t),map:(e,t)=>e.map(L).map(t).map(N)},L=e=>({vattrs:e.u,vchildren:e.h,vkey:e.p,vname:e.m,vtag:e.v,vtext:e.i}),N=e=>{if("function"==typeof e.vtag){const t={...e.vattrs};return e.vkey&&(t.key=e.vkey),e.vname&&(t.name=e.vname),D(e.vtag,t,...e.vchildren||[])}const t=T(e.vtag,e.vtext);return t.u=e.vattrs,t.h=e.vchildren,t.p=e.vkey,t.m=e.vname,t},U=e=>n(e).$hostElement$,W=(e,t,n)=>{const o=U(e);return{emit:e=>q(o,t,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:e})}},q=(e,t,n)=>{const o=a.ce(t,n);return e.dispatchEvent(o),o},G=new WeakMap,I=e=>"sc-"+e.S,V=(e,t,n,o,s,i)=>{if(n!==o){let r=l(e,t),c=t.toLowerCase();if("class"===t){const t=e.classList,l=z(n),s=z(o);t.remove(...l.filter((e=>e&&!s.includes(e)))),t.add(...s.filter((e=>e&&!l.includes(e))))}else if("style"===t){for(const t in n)o&&null!=o[t]||(t.includes("-")?e.style.removeProperty(t):e.style[t]="");for(const t in o)n&&o[t]===n[t]||(t.includes("-")?e.style.setProperty(t,o[t]):e.style[t]=o[t])}else if("key"===t);else if("ref"===t)o&&o(e);else if(r||"o"!==t[0]||"n"!==t[1]){const l=k(o);if((r||l&&null!==o)&&!s)try{if(e.tagName.includes("-"))e[t]=o;else{const l=null==o?"":o;"list"===t?r=!1:null!=n&&e[t]==l||("function"==typeof e.__lookupSetter__(t)?e[t]=l:e.setAttribute(t,l))}}catch(e){}null==o||!1===o?!1===o&&""!==e.getAttribute(t)||e.removeAttribute(t):(!r||4&i||s)&&!l&&e.setAttribute(t,o=!0===o?"":o)}else if(t="-"===t[2]?t.slice(3):l(f,c)?c.slice(2):c[2]+t.slice(3),n||o){const l=t.endsWith(B);t=t.replace(J,""),n&&a.rel(e,t,n,l),o&&a.ael(e,t,o,l)}}},_=/\s/,z=e=>e?e.split(_):[],B="Capture",J=RegExp(B+"$"),K=(e,t,n)=>{const o=11===t.$.nodeType&&t.$.host?t.$.host:t.$,l=e&&e.u||S,s=t.u||S;for(const e of Q(Object.keys(l)))e in s||V(o,e,l[e],void 0,n,t.o);for(const e of Q(Object.keys(s)))V(o,e,l[e],s[e],n,t.o)};function Q(e){return e.includes("ref")?[...e.filter((e=>"ref"!==e)),"ref"]:e}var X=!1,Y=!1,Z=!1,ee=!1,te=(e,t,n,o)=>{var l;const s=t.h[n];let i,r,c,f=0;if(X||(Z=!0,"slot"===s.v&&(M&&o.classList.add(M+"-s"),s.o|=s.h?2:1)),null!==s.i)i=s.$=u.createTextNode(s.i);else if(1&s.o)i=s.$=u.createTextNode("");else{if(ee||(ee="svg"===s.v),i=s.$=u.createElementNS(ee?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",!X&&2&s.o?"slot-fb":s.v),ee&&"foreignObject"===s.v&&(ee=!1),K(null,s,ee),i.getRootNode().querySelector("body"),s.h)for(f=0;f<s.h.length;++f)r=te(e,s,f,i),r&&i.appendChild(r);"svg"===s.v?ee=!1:"foreignObject"===i.tagName&&(ee=!0)}return i["s-hn"]=R,3&s.o&&(i["s-sr"]=!0,i["s-cr"]=x,i["s-sn"]=s.m||"",i["s-rf"]=null==(l=s.u)?void 0:l.ref,c=e&&e.h&&e.h[n],c&&c.v===s.v&&e.$&&ne(e.$,!1)),i},ne=(e,t)=>{a.o|=1;const n=Array.from(e.childNodes);for(let e=n.length-1;e>=0;e--){const o=n[e];o["s-hn"]!==R&&o["s-ol"]&&(pe(re(o),o,ie(o)),o["s-ol"].remove(),o["s-ol"]=void 0,o["s-sh"]=void 0,Z=!0),t&&ne(o,t)}a.o&=-2},oe=(e,t,n,o,l,s)=>{let i,r=e["s-cr"]&&e["s-cr"].parentNode||e;for(r.shadowRoot&&r.tagName===R&&(r=r.shadowRoot);l<=s;++l)o[l]&&(i=te(null,n,l,e),i&&(o[l].$=i,pe(r,i,ie(t))))},le=(e,t,n)=>{for(let o=t;o<=n;++o){const t=e[o];if(t){const e=t.$;he(t),e&&(Y=!0,e["s-ol"]?e["s-ol"].remove():ne(e,!0),e.remove())}}},se=(e,t,n=!1)=>!(e.v!==t.v||("slot"===e.v?"k"in e&&n&&8!==e.$.nodeType||e.m!==t.m:!n&&e.p!==t.p)),ie=e=>e&&e["s-ol"]||e,re=e=>(e["s-ol"]?e["s-ol"]:e).parentNode,ce=(e,t,n=!1)=>{const o=t.$=e.$,l=e.h,s=t.h,i=t.v,r=t.i;let c;null===r?(ee="svg"===i||"foreignObject"!==i&&ee,("slot"!==i||X)&&K(e,t,ee),null!==l&&null!==s?((e,t,n,o,l=!1)=>{let s,i,r=0,c=0,f=0,u=0,a=t.length-1,d=t[0],h=t[a],p=o.length-1,m=o[0],v=o[p];for(;r<=a&&c<=p;)if(null==d)d=t[++r];else if(null==h)h=t[--a];else if(null==m)m=o[++c];else if(null==v)v=o[--p];else if(se(d,m,l))ce(d,m,l),d=t[++r],m=o[++c];else if(se(h,v,l))ce(h,v,l),h=t[--a],v=o[--p];else if(se(d,v,l))"slot"!==d.v&&"slot"!==v.v||ne(d.$.parentNode,!1),ce(d,v,l),pe(e,d.$,h.$.nextSibling),d=t[++r],v=o[--p];else if(se(h,m,l))"slot"!==d.v&&"slot"!==v.v||ne(h.$.parentNode,!1),ce(h,m,l),pe(e,h.$,d.$),h=t[--a],m=o[++c];else{for(f=-1,u=r;u<=a;++u)if(t[u]&&null!==t[u].p&&t[u].p===m.p){f=u;break}f>=0?(i=t[f],i.v!==m.v?s=te(t&&t[c],n,f,e):(ce(i,m,l),t[f]=void 0,s=i.$),m=o[++c]):(s=te(t&&t[c],n,c,e),m=o[++c]),s&&pe(re(d.$),s,ie(d.$))}r>a?oe(e,null==o[p+1]?null:o[p+1].$,n,o,c,p):c>p&&le(t,r,a)})(o,l,t,s,n):null!==s?(null!==e.i&&(o.textContent=""),oe(o,null,t,s,0,s.length-1)):!n&&null!==l&&le(l,0,l.length-1),ee&&"svg"===i&&(ee=!1)):(c=o["s-cr"])?c.parentNode.textContent=r:e.i!==r&&(o.data=r)},fe=e=>{const t=e.childNodes;for(const e of t)if(1===e.nodeType){if(e["s-sr"]){const n=e["s-sn"];e.hidden=!1;for(const o of t)if(o!==e)if(o["s-hn"]!==e["s-hn"]||""!==n){if(1===o.nodeType&&(n===o.getAttribute("slot")||n===o["s-sn"])||3===o.nodeType&&n===o["s-sn"]){e.hidden=!0;break}}else if(1===o.nodeType||3===o.nodeType&&""!==o.textContent.trim()){e.hidden=!0;break}}fe(e)}},ue=[],ae=e=>{let t,n,o;for(const l of e.childNodes){if(l["s-sr"]&&(t=l["s-cr"])&&t.parentNode){n=t.parentNode.childNodes;const e=l["s-sn"];for(o=n.length-1;o>=0;o--)if(t=n[o],!t["s-cn"]&&!t["s-nr"]&&t["s-hn"]!==l["s-hn"])if(de(t,e)){let n=ue.find((e=>e.j===t));Y=!0,t["s-sn"]=t["s-sn"]||e,n?(n.j["s-sh"]=l["s-hn"],n.O=l):(t["s-sh"]=l["s-hn"],ue.push({O:l,j:t})),t["s-sr"]&&ue.map((e=>{de(e.j,t["s-sn"])&&(n=ue.find((e=>e.j===t)),n&&!e.O&&(e.O=n.O))}))}else ue.some((e=>e.j===t))||ue.push({j:t})}1===l.nodeType&&ae(l)}},de=(e,t)=>1===e.nodeType?null===e.getAttribute("slot")&&""===t||e.getAttribute("slot")===t:e["s-sn"]===t||""===t,he=e=>{e.u&&e.u.ref&&e.u.ref(null),e.h&&e.h.map(he)},pe=(e,t,n)=>null==e?void 0:e.insertBefore(t,n),me=(e,t)=>{t&&!e.C&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.C=t)))},ve=(e,t)=>{if(e.o|=16,!(4&e.o))return me(e,e.M),g((()=>ye(e,t)));e.o|=512},ye=(e,t)=>{const n=e.t;if(!n)throw Error(`Can't render component <${e.$hostElement$.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let o;return t&&(o=je(n,"componentWillLoad")),$e(o,(()=>we(e,n,t)))},$e=(e,t)=>be(e)?e.then(t).catch((e=>{console.error(e),t()})):t(),be=e=>e instanceof Promise||e&&e.then&&"function"==typeof e.then,we=async(e,t,n)=>{var o;const l=e.$hostElement$,s=l["s-rc"];n&&(e=>{const t=e.R,n=e.$hostElement$,o=t.o,l=((e,t)=>{var n;const o=I(t),l=r.get(o);if(e=11===e.nodeType?e:u,l)if("string"==typeof l){let s,i=G.get(e=e.head||e);if(i||G.set(e,i=new Set),!i.has(o)){{s=u.createElement("style"),s.innerHTML=l;const o=null!=(n=a.P)?n:j(u);if(null!=o&&s.setAttribute("nonce",o),!(1&t.o))if("HEAD"===e.nodeName){const t=e.querySelectorAll("link[rel=preconnect]"),n=t.length>0?t[t.length-1].nextSibling:e.querySelector("style");e.insertBefore(s,n)}else if("host"in e)if(h){const t=new CSSStyleSheet;t.replaceSync(l),e.adoptedStyleSheets=[t,...e.adoptedStyleSheets]}else{const t=e.querySelector("style");t?t.innerHTML=l+t.innerHTML:e.prepend(s)}else e.append(s);1&t.o&&"HEAD"!==e.nodeName&&e.insertBefore(s,null)}4&t.o&&(s.innerHTML+=c),i&&i.add(o)}}else e.adoptedStyleSheets.includes(l)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,l]);return o})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&o&&2&o&&(n["s-sc"]=l,n.classList.add(l+"-h"))})(e);ge(e,t,l,n),s&&(s.map((e=>e())),l["s-rc"]=void 0);{const t=null!=(o=l["s-p"])?o:[],n=()=>Se(e);0===t.length?n():(Promise.all(t).then(n),e.o|=4,t.length=0)}},ge=(e,t,n,o)=>{try{t=t.render(),e.o&=-17,e.o|=2,((e,t,n=!1)=>{var o,l,s,i;const r=e.$hostElement$,c=e.R,f=e.A||T(null,null),d=(e=>e&&e.v===H)(t)?t:D(null,null,t);if(R=r.tagName,c.D&&(d.u=d.u||{},c.D.map((([e,t])=>d.u[t]=r[e]))),n&&d.u)for(const e of Object.keys(d.u))r.hasAttribute(e)&&!["key","ref","style","class"].includes(e)&&(d.u[e]=r[e]);if(d.v=null,d.o|=4,e.A=d,d.$=f.$=r.shadowRoot||r,M=r["s-sc"],X=!!(1&c.o),x=r["s-cr"],Y=!1,ce(f,d,n),a.o|=1,Z){ae(d.$);for(const e of ue){const t=e.j;if(!t["s-ol"]){const e=u.createTextNode("");e["s-nr"]=t,pe(t.parentNode,t["s-ol"]=e,t)}}for(const e of ue){const t=e.j,r=e.O;if(r){const e=r.parentNode;let n=r.nextSibling;{let s=null==(o=t["s-ol"])?void 0:o.previousSibling;for(;s;){let o=null!=(l=s["s-nr"])?l:null;if(o&&o["s-sn"]===t["s-sn"]&&e===o.parentNode){for(o=o.nextSibling;o===t||(null==o?void 0:o["s-sr"]);)o=null==o?void 0:o.nextSibling;if(!o||!o["s-nr"]){n=o;break}}s=s.previousSibling}}(!n&&e!==t.parentNode||t.nextSibling!==n)&&t!==n&&(!t["s-hn"]&&t["s-ol"]&&(t["s-hn"]=t["s-ol"].parentNode.nodeName),pe(e,t,n),1===t.nodeType&&(t.hidden=null!=(s=t["s-ih"])&&s)),t&&"function"==typeof r["s-rf"]&&r["s-rf"](t)}else 1===t.nodeType&&(n&&(t["s-ih"]=null!=(i=t.hidden)&&i),t.hidden=!0)}}Y&&fe(d.$),a.o&=-2,ue.length=0,x=void 0})(e,t,o)}catch(t){s(t,e.$hostElement$)}return null},Se=e=>{const t=e.$hostElement$,n=e.t,o=e.M;je(n,"componentDidRender"),64&e.o?je(n,"componentDidUpdate"):(e.o|=64,Oe(t),je(n,"componentDidLoad"),e.T(t),o||ke()),e.C&&(e.C(),e.C=void 0),512&e.o&&w((()=>ve(e,!1))),e.o&=-517},ke=()=>{Oe(u.documentElement),w((()=>q(f,"appload",{detail:{namespace:"bonus-elevate-shop-item"}})))},je=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){s(e)}},Oe=e=>e.classList.add("hydrated"),Ee=(e,t,o)=>{var l,s;const i=e.prototype;if(t.H){const r=Object.entries(null!=(l=t.H)?l:{});if(r.map((([e,[l]])=>{(31&l||2&o&&32&l)&&Object.defineProperty(i,e,{get(){return((e,t)=>n(this).F.get(t))(0,e)},set(o){((e,t,o,l)=>{const s=n(e);if(!s)throw Error(`Couldn't find host element for "${l.S}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/ionic-team/stencil/issues/5457).`);const i=s.F.get(t),r=s.o,c=s.t;o=((e,t)=>null==e||k(e)?e:4&t?"false"!==e&&(""===e||!!e):2&t?parseFloat(e):1&t?e+"":e)(o,l.H[t][0]),8&r&&void 0!==i||o===i||Number.isNaN(i)&&Number.isNaN(o)||(s.F.set(t,o),c&&2==(18&r)&&ve(s,!1))})(this,e,o,t)},configurable:!0,enumerable:!0})})),1&o){const o=new Map;i.attributeChangedCallback=function(e,l,s){a.jmp((()=>{var r;const c=o.get(e);if(this.hasOwnProperty(c))s=this[c],delete this[c];else{if(i.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==s)return;if(null==c){const o=n(this),i=null==o?void 0:o.o;if(i&&!(8&i)&&128&i&&s!==l){const n=o.t,i=null==(r=t.L)?void 0:r[e];null==i||i.forEach((t=>{null!=n[t]&&n[t].call(n,s,l,e)}))}return}}this[c]=(null!==s||"boolean"!=typeof this[c])&&s}))},e.observedAttributes=Array.from(new Set([...Object.keys(null!=(s=t.L)?s:{}),...r.filter((([e,t])=>15&t[0])).map((([e,n])=>{var l;const s=n[1]||e;return o.set(s,e),512&n[0]&&(null==(l=t.D)||l.push([e,s])),s}))]))}}return e},Ce=e=>{je(e,"connectedCallback")},Me=e=>{je(e,"disconnectedCallback")},xe=(e,o={})=>{var l;const d=[],p=o.exclude||[],m=f.customElements,v=u.head,y=v.querySelector("meta[charset]"),$=u.createElement("style"),b=[];let w,g=!0;Object.assign(a,o),a.l=new URL(o.resourcesUrl||"./",u.baseURI).href;let S=!1;if(e.map((e=>{e[1].map((o=>{const l={o:o[0],S:o[1],H:o[2],N:o[3]};4&l.o&&(S=!0),l.H=o[2],l.D=[];const c=l.S,f=class extends HTMLElement{constructor(e){if(super(e),this.hasRegisteredEventListeners=!1,((e,n)=>{const o={o:0,$hostElement$:e,R:n,F:new Map};o.U=new Promise((e=>o.T=e)),e["s-p"]=[],e["s-rc"]=[],t.set(e,o)})(e=this,l),1&l.o)if(e.shadowRoot){if("open"!==e.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${l.S}! Mode is set to ${e.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else e.attachShadow({mode:"open"})}connectedCallback(){this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0),w&&(clearTimeout(w),w=null),g?b.push(this):a.jmp((()=>(e=>{if(!(1&a.o)){const t=n(e),o=t.R,l=()=>{};if(1&t.o)(null==t?void 0:t.t)?Ce(t.t):(null==t?void 0:t.U)&&t.U.then((()=>Ce(t.t)));else{t.o|=1,12&o.o&&(e=>{const t=e["s-cr"]=u.createComment("");t["s-cn"]=!0,pe(e,t,e.firstChild)})(e);{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){me(t,t.M=n);break}}o.H&&Object.entries(o.H).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n)=>{let o;if(!(32&t.o)){if(t.o|=32,n.W){const e=(e=>{const t=e.S.replace(/-/g,"_"),n=e.W;if(!n)return;const o=i.get(n);return o?o[t]:import(`./${n}.entry.js`).then((e=>(i.set(n,e),e[t])),s)
|
|
2
|
-
/*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n);if(e&&"then"in e){const t=()=>{};o=await e,t()}else o=e;if(!o)throw Error(`Constructor for "${n.S}#${t.q}" was not found`);o.isProxied||(Ee(o,n,2),o.isProxied=!0);const l=()=>{};t.o|=8;try{new o(t)}catch(e){s(e)}t.o&=-9,l(),Ce(t.t)}else o=e.constructor,customElements.whenDefined(e.localName).then((()=>t.o|=128));if(o&&o.style){let e;"string"==typeof o.style&&(e=o.style);const t=I(n);if(!r.has(t)){const o=()=>{};((e,t,n)=>{let o=r.get(e);h&&n?(o=o||new CSSStyleSheet,"string"==typeof o?o=t:o.replaceSync(t)):o=t,r.set(e,o)})(t,e,!!(1&n.o)),o()}}}const l=t.M,c=()=>ve(t,!0);l&&l["s-rc"]?l["s-rc"].push(c):c()})(e,t,o)}l()}})(this)))}disconnectedCallback(){a.jmp((()=>(async()=>{if(!(1&a.o)){const e=n(this);(null==e?void 0:e.t)?Me(e.t):(null==e?void 0:e.U)&&e.U.then((()=>Me(e.t)))}})()))}componentOnReady(){return n(this).U}};l.W=e[0],p.includes(c)||m.get(c)||(d.push(c),m.define(c,Ee(f,l,1)))}))})),d.length>0&&(S&&($.textContent+=c),$.textContent+=d.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",$.innerHTML.length)){$.setAttribute("data-styles","");const e=null!=(l=a.P)?l:j(u);null!=e&&$.setAttribute("nonce",e),v.insertBefore($,y?y.nextSibling:v.firstChild)}g=!1,b.length?b.map((e=>e.connectedCallback())):a.jmp((()=>w=setTimeout(ke,30)))},Re=(e,t)=>t,Pe=e=>a.P=e;export{Re as F,H,xe as b,W as c,U as g,D as h,d as p,o as r,Pe as s}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|