@everymatrix/casino-engagement-suite-modal 1.56.0 → 1.56.3
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/casino-engagement-suite-modal/casino-engagement-suite-modal.esm.js +1 -1
- package/dist/casino-engagement-suite-modal/p-85dea1f3.entry.js +1 -0
- package/dist/casino-engagement-suite-modal/p-b82db066.js +2 -0
- package/dist/cjs/casino-engagement-suite-modal.cjs.entry.js +11 -15
- package/dist/cjs/casino-engagement-suite-modal.cjs.js +2 -2
- package/dist/cjs/{index-f0bdc19e.js → index-0d730cd7.js} +65 -200
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/casino-engagement-suite-modal/casino-engagement-suite-modal.js +10 -32
- package/dist/esm/casino-engagement-suite-modal.entry.js +11 -15
- package/dist/esm/casino-engagement-suite-modal.js +3 -3
- package/dist/esm/{index-118cee90.js → index-2faffb64.js} +65 -200
- package/dist/esm/loader.js +2 -2
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/packages/stencil/casino-engagement-suite-modal/stencil.config.d.ts +2 -0
- package/dist/types/Users/maria.bumbar/Desktop/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/packages/stencil/casino-engagement-suite-modal/stencil.config.dev.d.ts +2 -0
- package/dist/types/stencil-public-runtime.d.ts +0 -6
- package/package.json +1 -1
- package/dist/casino-engagement-suite-modal/p-6b988108.js +0 -2
- package/dist/casino-engagement-suite-modal/p-c66da26c.entry.js +0 -1
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/packages/stencil/casino-engagement-suite-modal/stencil.config.d.ts +0 -2
- package/dist/types/Users/adrian.pripon/Documents/Work/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/packages/stencil/casino-engagement-suite-modal/stencil.config.dev.d.ts +0 -2
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/tools/plugins/index.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/tools/plugins/stencil-clean-deps-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/tools/plugins/vite-chunk-plugin.d.ts +0 -0
- /package/dist/types/Users/{adrian.pripon/Documents/Work → maria.bumbar/Desktop}/widgets-monorepo/packages/stencil/casino-engagement-suite-modal/.stencil/tools/plugins/vite-clean-deps-plugin.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as n,b as i}from"./p-
|
|
1
|
+
import{p as n,b as i}from"./p-b82db066.js";export{s as setNonce}from"./p-b82db066.js";import{g as t}from"./p-e1255160.js";(()=>{const i=import.meta.url,t={};return""!==i&&(t.resourcesUrl=new URL(".",i).href),n(t)})().then((async n=>(await t(),i([["p-85dea1f3",[[1,"casino-engagement-suite-modal",{clientStyling:[513,"client-styling"],clientStylingUrl:[513,"client-styling-url"],isOpen:[4,"is-open"],isLoading:[1028,"is-loading"],header:[1],contentIcon:[1,"content-icon"],modalType:[1,"modal-type"],device:[1],showAnimation:[4,"show-animation"],limitStylingAppends:[32]}]]]],n))));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as o,h as t,g as a}from"./p-b82db066.js";const i=class{constructor(t){e(this,t),this.closeModal=o(this,"closeModal",7),this.handleCloseClick=()=>{this.isLoading||this.closeModal.emit(this.modalType)},this.setClientStyling=()=>{let e=document.createElement("style");e.innerHTML=this.clientStyling,this.host.prepend(e)},this.setClientStylingURL=()=>{let e=new URL(this.clientStylingUrl),o=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{o.innerHTML=e,setTimeout((()=>{this.host.prepend(o)}),1)})).catch((e=>{console.log("Error ",e)}))},this.clientStyling="",this.clientStylingUrl="",this.isOpen=void 0,this.isLoading=void 0,this.header=void 0,this.contentIcon=void 0,this.modalType=void 0,this.device="Mobile",this.showAnimation=!1,this.limitStylingAppends=!1}componentDidRender(){!this.limitStylingAppends&&this.host&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrl&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){return t("div",{key:"570a2289e990efeae5cceac8bc2152cbb9bb5221",class:`ModalOverlay ${this.isOpen&&"Open"} ${this.device} ${this.showAnimation&&"ShowAnimation"}`},t("div",{key:"9d40898f29b5a539907a7e50f3fdee02636aced6",class:"ModalWinAnimation"}),t("div",{key:"724ffe5cd946b40aa12f99ac926a6c832c1633da",class:"ModalContent GradientBorder"},t("div",{key:"14bb1463ba0b5e9cdb545a81c13873a3e124f4c3",class:"IconCloseContainer"},t("button",{key:"1640c3c0881c65199a26f3f2217610189d626f91",class:"EngagementSuiteIconButton Close",onClick:this.handleCloseClick})),this.contentIcon?t("div",{class:"ModalIcon",style:{background:`url(${this.contentIcon}) no-repeat center, linear-gradient(98.25deg, #FF9400 22.48%, #FEF746 131.02%, #FFE24A 131.9%)`}}):null,t("div",{key:"c49ddc1152bb9c8af76ff11874816da8477ba821",class:"ModalHeader"},t("h1",{key:"08352f25028b0b08c2c1a77b91ea80cc968aa4e1"},this.header)),t("div",{key:"3420427d531aceb3861c1876394443ad664ff68b",class:"ModalBodyWrapper"},t("div",{key:"3e453586b727029f5fca9688b376d4b3e8298dbf",class:"ModalBody"},t("slot",{key:"0d82c3fa9b0faa9012005ccca85350313a684326",name:"body"})),t("div",{key:"9e7a078e4c912869f2e3573a533bb3cf82454a4c",class:"ModalFooter"},t("slot",{key:"df8e0568aeca79889cf8eb8f7fb33caf685b092e",name:"footer"})))))}get host(){return a(this)}};i.style=':host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer;touch-action:manipulation}button:focus{outline:none}.EngagementSuiteIconButton{width:24px;height:24px}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.ModalOverlay{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0, 0, 0, 0.5);justify-content:center;align-items:center;z-index:1}.ModalOverlay.Open{display:flex}.IconCloseContainer{width:100%;display:flex;justify-content:end}.ModalBodyWrapper{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden}.ModalBodyWrapper::-webkit-scrollbar{width:3px;background:none}.ModalBodyWrapper::-webkit-scrollbar-thumb{border-radius:var(--emw--border-radius-small, 4px);background-color:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.ModalContent{display:flex;flex-direction:column;align-items:center;font-family:var(--emw--font-family-secondary, "Montserrat", sans-serif);position:relative;color:var(--emw--color-typography, #FFFFFF);background-color:var(--emw--color-background, #1E1638);padding:24px;border-radius:var(--emw--border-radius-large, 8px);width:450px;max-width:100%;text-align:center;max-height:90dvh}.GradientBorder::before{content:"";position:absolute;top:-1px;left:-1px;right:-1px;bottom:-1px;border-radius:var(--emw--border-radius-large, 9px);background:linear-gradient(143.2deg, #FF9401 -0.41%, #FFD32D 45.61%, #FF9401 82.77%);z-index:-1}.ModalHeader h1{font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large-plus, 24px);padding:0 16px;margin-bottom:16px}.ModalIcon{width:44px;height:44px;border-radius:50%;background-size:cover;margin:12px 0}.ModalBody{font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);color:var(--emw--color-secondary, #BBB9C3);padding:0 16px}.ModalFooter{margin-top:40px;margin-bottom:28px;padding:0 16px;width:100%}@keyframes rotate{100%{transform:rotate(1turn)}}.ModalOverlay .ModalWinAnimation{display:none}.ModalOverlay.ShowAnimation .ModalWinAnimation{display:block;position:absolute;width:100%;height:100%;inset:0;background:center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/light.svg) no-repeat, center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/win.svg) no-repeat;animation:6s rotate linear infinite}.ModalOverlay.Mobile .EngagementSuiteIconButton{width:16px;height:16px}.ModalOverlay.Mobile .ModalBody{font-size:var(--emw--font-size-small, 14px)}.ModalOverlay.Mobile .ModalContent{width:318px;padding:12px}.ModalOverlay.Mobile .ModalHeader h1{font-size:var(--emw--font-size-large, 20px);padding:0 60px}.ModalOverlay.Mobile.ShowAnimation .ModalWinAnimation{background-size:400px}';export{i as casino_engagement_suite_modal}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var e=Object.defineProperty,t=new WeakMap,n=e=>t.get(e),l=(e,n)=>t.set(n.t=e,n),o=(e,t)=>t in e,s=(e,t)=>(0,console.error)(e,t),r=new Map,i=new Map,c="slot-fb{display:contents}slot-fb[hidden]{display:none}",u="undefined"!=typeof window?window:{},a=u.document||{head:{}},f={l:0,o:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,l)=>e.addEventListener(t,n,l),rel:(e,t,n,l)=>e.removeEventListener(t,n,l),ce:(e,t)=>new CustomEvent(e,t)},h=e=>Promise.resolve(e),m=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(e){}return!1})(),d=!1,p=[],y=[],$=(e,t)=>n=>{e.push(n),d||(d=!0,t&&4&f.l?v(w):f.raf(w))},b=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){s(e)}e.length=0},w=()=>{b(p),b(y),(d=p.length>0)&&f.raf(w)},v=e=>h().then(e),g=$(y,!0),S={},j=e=>"object"==(e=typeof e)||"function"===e;function k(e){var t,n,l;return null!=(l=null==(n=null==(t=e.head)?void 0:t.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?l:void 0}((t,n)=>{for(var l in n)e(t,l,{get:n[l],enumerable:!0})})({},{err:()=>E,map:()=>C,ok:()=>O,unwrap:()=>P,unwrapErr:()=>R});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,P=e=>{if(e.isOk)return e.value;throw e.value},R=e=>{if(e.isErr)return e.value;throw e.value},T=(e,t,...n)=>{let l=null,o=null,s=!1,r=!1;const i=[],c=t=>{for(let n=0;n<t.length;n++)l=t[n],Array.isArray(l)?c(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof e&&!j(l))&&(l+=""),s&&r?i[i.length-1].i+=l:i.push(s?A(null,l):l),r=s)};if(c(n),t){t.key&&(o=t.key);{const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}}const u=A(e,null);return u.u=t,i.length>0&&(u.h=i),u.m=o,u},A=(e,t)=>({l:0,p:e,i:t,$:null,h:null,u:null,m:null}),N={},U=e=>n(e).$hostElement$,D=(e,t,n)=>{const l=U(e);return{emit:e=>F(l,t,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:e})}},F=(e,t,n)=>{const l=f.ce(t,n);return e.dispatchEvent(l),l},H=new WeakMap,L=e=>"sc-"+e.v,W=(e,t,n,l,s,r)=>{if(n!==l){let i=o(e,t),c=t.toLowerCase();if("class"===t){const t=e.classList,o=G(n),s=G(l);t.remove(...o.filter((e=>e&&!s.includes(e)))),t.add(...s.filter((e=>e&&!o.includes(e))))}else if("style"===t){for(const t in n)l&&null!=l[t]||(t.includes("-")?e.style.removeProperty(t):e.style[t]="");for(const t in l)n&&l[t]===n[t]||(t.includes("-")?e.style.setProperty(t,l[t]):e.style[t]=l[t])}else if("key"===t);else if(i||"o"!==t[0]||"n"!==t[1]){const o=j(l);if((i||o&&null!==l)&&!s)try{if(e.tagName.includes("-"))e[t]=l;else{const o=null==l?"":l;"list"===t?i=!1:null!=n&&e[t]==o||(e[t]=o)}}catch(e){}null==l||!1===l?!1===l&&""!==e.getAttribute(t)||e.removeAttribute(t):(!i||4&r||s)&&!o&&e.setAttribute(t,l=!0===l?"":l)}else if(t="-"===t[2]?t.slice(3):o(u,c)?c.slice(2):c[2]+t.slice(3),n||l){const o=t.endsWith(V);t=t.replace(_,""),n&&f.rel(e,t,n,o),l&&f.ael(e,t,l,o)}}},q=/\s/,G=e=>e?e.split(q):[],V="Capture",_=RegExp(V+"$"),z=(e,t,n)=>{const l=11===t.$.nodeType&&t.$.host?t.$.host:t.$,o=e&&e.u||S,s=t.u||S;for(const e of B(Object.keys(o)))e in s||W(l,e,o[e],void 0,n,t.l);for(const e of B(Object.keys(s)))W(l,e,o[e],s[e],n,t.l)};function B(e){return e.includes("ref")?[...e.filter((e=>"ref"!==e)),"ref"]:e}var I=!1,J=!1,K=(e,t,n)=>{const l=t.h[n];let o,s,r=0;if(null!==l.i)o=l.$=a.createTextNode(l.i);else if(o=l.$=a.createElement(l.p),z(null,l,J),null!=M&&o["s-si"]!==M&&o.classList.add(o["s-si"]=M),l.h)for(r=0;r<l.h.length;++r)s=K(e,l,r),s&&o.appendChild(s);return o["s-hn"]=x,o},Q=(e,t,n,l,o,s)=>{let r,i=e;for(i.shadowRoot&&i.tagName===x&&(i=i.shadowRoot);o<=s;++o)l[o]&&(r=K(null,n,o),r&&(l[o].$=r,ee(i,r,t)))},X=(e,t,n)=>{for(let l=t;l<=n;++l){const t=e[l];if(t){const e=t.$;e&&e.remove()}}},Y=(e,t,n=!1)=>e.p===t.p&&(!!n||e.m===t.m),Z=(e,t,n=!1)=>{const l=t.$=e.$,o=e.h,s=t.h,r=t.i;null===r?(("slot"!==t.p||I)&&z(e,t,J),null!==o&&null!==s?((e,t,n,l,o=!1)=>{let s,r,i=0,c=0,u=0,a=0,f=t.length-1,h=t[0],m=t[f],d=l.length-1,p=l[0],y=l[d];for(;i<=f&&c<=d;)if(null==h)h=t[++i];else if(null==m)m=t[--f];else if(null==p)p=l[++c];else if(null==y)y=l[--d];else if(Y(h,p,o))Z(h,p,o),h=t[++i],p=l[++c];else if(Y(m,y,o))Z(m,y,o),m=t[--f],y=l[--d];else if(Y(h,y,o))Z(h,y,o),ee(e,h.$,m.$.nextSibling),h=t[++i],y=l[--d];else if(Y(m,p,o))Z(m,p,o),ee(e,m.$,h.$),m=t[--f],p=l[++c];else{for(u=-1,a=i;a<=f;++a)if(t[a]&&null!==t[a].m&&t[a].m===p.m){u=a;break}u>=0?(r=t[u],r.p!==p.p?s=K(t&&t[c],n,u):(Z(r,p,o),t[u]=void 0,s=r.$),p=l[++c]):(s=K(t&&t[c],n,c),p=l[++c]),s&&ee(h.$.parentNode,s,h.$)}i>f?Q(e,null==l[d+1]?null:l[d+1].$,n,l,c,d):c>d&&X(t,i,f)})(l,o,t,s,n):null!==s?(null!==e.i&&(l.textContent=""),Q(l,null,t,s,0,s.length-1)):null!==o&&X(o,0,o.length-1)):e.i!==r&&(l.data=r)},ee=(e,t,n)=>null==e?void 0:e.insertBefore(t,n),te=(e,t)=>{t&&!e.S&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.S=t)))},ne=(e,t)=>{if(e.l|=16,!(4&e.l))return te(e,e.j),g((()=>le(e,t)));e.l|=512},le=(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`);return oe(void 0,(()=>re(e,n,t)))},oe=(e,t)=>se(e)?e.then(t).catch((e=>{console.error(e),t()})):t(),se=e=>e instanceof Promise||e&&e.then&&"function"==typeof e.then,re=async(e,t,n)=>{var l;const o=e.$hostElement$,s=o["s-rc"];n&&(e=>{const t=e.k,n=e.$hostElement$,l=t.l,o=((e,t)=>{var n;const l=L(t),o=i.get(l);if(e=11===e.nodeType?e:a,o)if("string"==typeof o){let s,r=H.get(e=e.head||e);if(r||H.set(e,r=new Set),!r.has(l)){{s=a.createElement("style"),s.innerHTML=o;const t=null!=(n=f.O)?n:k(a);null!=t&&s.setAttribute("nonce",t),e.insertBefore(s,e.querySelector("link"))}4&t.l&&(s.innerHTML+=c),r&&r.add(l)}}else e.adoptedStyleSheets.includes(o)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,o]);return l})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&l&&(n["s-sc"]=o,n.classList.add(o+"-h"))})(e);ie(e,t,o,n),s&&(s.map((e=>e())),o["s-rc"]=void 0);{const t=null!=(l=o["s-p"])?l:[],n=()=>ce(e);0===t.length?n():(Promise.all(t).then(n),e.l|=4,t.length=0)}},ie=(e,t,n,l)=>{try{t=t.render(),e.l&=-17,e.l|=2,((e,t,n=!1)=>{const l=e.$hostElement$,o=e.k,s=e.C||A(null,null),r=(e=>e&&e.p===N)(t)?t:T(null,null,t);if(x=l.tagName,o.M&&(r.u=r.u||{},o.M.map((([e,t])=>r.u[t]=l[e]))),n&&r.u)for(const e of Object.keys(r.u))l.hasAttribute(e)&&!["key","ref","style","class"].includes(e)&&(r.u[e]=l[e]);r.p=null,r.l|=4,e.C=r,r.$=s.$=l.shadowRoot||l,M=l["s-sc"],I=!!(1&o.l),Z(s,r,n)})(e,t,l)}catch(t){s(t,e.$hostElement$)}return null},ce=e=>{const t=e.$hostElement$,n=e.j;ae(e.t,"componentDidRender"),64&e.l||(e.l|=64,fe(t),e.P(t),n||ue()),e.S&&(e.S(),e.S=void 0),512&e.l&&v((()=>ne(e,!1))),e.l&=-517},ue=()=>{fe(a.documentElement),v((()=>F(u,"appload",{detail:{namespace:"casino-engagement-suite-modal"}})))},ae=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){s(e)}},fe=e=>e.classList.add("hydrated"),he=(e,t,l)=>{var o,s;const r=e.prototype;if(t.R){const i=Object.entries(null!=(o=t.R)?o:{});if(i.map((([e,[o]])=>{(31&o||2&l&&32&o)&&Object.defineProperty(r,e,{get(){return((e,t)=>n(this).T.get(t))(0,e)},set(l){((e,t,l,o)=>{const s=n(e);if(!s)throw Error(`Couldn't find host element for "${o.v}" 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 r=s.T.get(t),i=s.l,c=s.t;l=((e,t)=>null==e||j(e)?e:4&t?"false"!==e&&(""===e||!!e):1&t?e+"":e)(l,o.R[t][0]),8&i&&void 0!==r||l===r||Number.isNaN(r)&&Number.isNaN(l)||(s.T.set(t,l),c&&2==(18&i)&&ne(s,!1))})(this,e,l,t)},configurable:!0,enumerable:!0})})),1&l){const l=new Map;r.attributeChangedCallback=function(e,o,s){f.jmp((()=>{var i;const c=l.get(e);if(this.hasOwnProperty(c))s=this[c],delete this[c];else{if(r.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==s)return;if(null==c){const l=n(this),r=null==l?void 0:l.l;if(r&&!(8&r)&&128&r&&s!==o){const n=l.t,r=null==(i=t.A)?void 0:i[e];null==r||r.forEach((t=>{null!=n[t]&&n[t].call(n,s,o,e)}))}return}}this[c]=(null!==s||"boolean"!=typeof this[c])&&s}))},e.observedAttributes=Array.from(new Set([...Object.keys(null!=(s=t.A)?s:{}),...i.filter((([e,t])=>15&t[0])).map((([e,n])=>{var o;const s=n[1]||e;return l.set(s,e),512&n[0]&&(null==(o=t.M)||o.push([e,s])),s}))]))}}return e},me=(e,l={})=>{var o;const h=[],d=l.exclude||[],p=u.customElements,y=a.head,$=y.querySelector("meta[charset]"),b=a.createElement("style"),w=[];let v,g=!0;Object.assign(f,l),f.o=new URL(l.resourcesUrl||"./",a.baseURI).href;let S=!1;if(e.map((e=>{e[1].map((l=>{const o={l:l[0],v:l[1],R:l[2],N:l[3]};4&o.l&&(S=!0),o.R=l[2],o.M=[];const c=o.v,u=class extends HTMLElement{constructor(e){if(super(e),this.hasRegisteredEventListeners=!1,((e,n)=>{const l={l:0,$hostElement$:e,k:n,T:new Map};l.U=new Promise((e=>l.P=e)),e["s-p"]=[],e["s-rc"]=[],t.set(e,l)})(e=this,o),1&o.l)if(e.shadowRoot){if("open"!==e.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${o.v}! 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),v&&(clearTimeout(v),v=null),g?w.push(this):f.jmp((()=>(e=>{if(!(1&f.l)){const t=n(e),l=t.k,o=()=>{};if(1&t.l)(null==t?void 0:t.t)||(null==t?void 0:t.U)&&t.U.then((()=>{}));else{t.l|=1;{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){te(t,t.j=n);break}}l.R&&Object.entries(l.R).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n)=>{let l;if(!(32&t.l)){if(t.l|=32,n.D){const e=(e=>{const t=e.v.replace(/-/g,"_"),n=e.D;if(!n)return;const l=r.get(n);return l?l[t]:import(`./${n}.entry.js`).then((e=>(r.set(n,e),e[t])),s)
|
|
2
|
+
/*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n);if(e&&"then"in e){const t=()=>{};l=await e,t()}else l=e;if(!l)throw Error(`Constructor for "${n.v}#${t.F}" was not found`);l.isProxied||(he(l,n,2),l.isProxied=!0);const o=()=>{};t.l|=8;try{new l(t)}catch(e){s(e)}t.l&=-9,o()}else l=e.constructor,customElements.whenDefined(e.localName).then((()=>t.l|=128));if(l&&l.style){let e;"string"==typeof l.style&&(e=l.style);const t=L(n);if(!i.has(t)){const l=()=>{};((e,t,n)=>{let l=i.get(e);m&&n?(l=l||new CSSStyleSheet,"string"==typeof l?l=t:l.replaceSync(t)):l=t,i.set(e,l)})(t,e,!!(1&n.l)),l()}}}const o=t.j,c=()=>ne(t,!0);o&&o["s-rc"]?o["s-rc"].push(c):c()})(e,t,l)}o()}})(this)))}disconnectedCallback(){f.jmp((()=>(async()=>{if(!(1&f.l)){const e=n(this);(null==e?void 0:e.t)||(null==e?void 0:e.U)&&e.U.then((()=>{}))}})()))}componentOnReady(){return n(this).U}};o.D=e[0],d.includes(c)||p.get(c)||(h.push(c),p.define(c,he(u,o,1)))}))})),h.length>0&&(S&&(b.textContent+=c),b.textContent+=h.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",b.innerHTML.length)){b.setAttribute("data-styles","");const e=null!=(o=f.O)?o:k(a);null!=e&&b.setAttribute("nonce",e),y.insertBefore(b,$?$.nextSibling:y.firstChild)}g=!1,w.length?w.map((e=>e.connectedCallback())):f.jmp((()=>v=setTimeout(ue,30)))},de=e=>f.O=e;export{me as b,D as c,U as g,T as h,h as p,l as r,de as s}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-0d730cd7.js');
|
|
6
6
|
|
|
7
7
|
const casinoEngagementSuiteModalCss = ":host{display:block;font-family:inherit}*{box-sizing:border-box;margin:0;padding:0}button{border:none;background:none;cursor:pointer;touch-action:manipulation}button:focus{outline:none}.EngagementSuiteIconButton{width:24px;height:24px}.EngagementSuiteIconButton.Close{background:center/100% url(https://static.everymatrix.com/gic/img/engagement-suite/close.svg) no-repeat}.ModalOverlay{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0, 0, 0, 0.5);justify-content:center;align-items:center;z-index:1}.ModalOverlay.Open{display:flex}.IconCloseContainer{width:100%;display:flex;justify-content:end}.ModalBodyWrapper{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden}.ModalBodyWrapper::-webkit-scrollbar{width:3px;background:none}.ModalBodyWrapper::-webkit-scrollbar-thumb{border-radius:var(--emw--border-radius-small, 4px);background-color:var(--emw--color-gray-transparency-30, rgba(255, 255, 255, 0.3))}.ModalContent{display:flex;flex-direction:column;align-items:center;font-family:var(--emw--font-family-secondary, \"Montserrat\", sans-serif);position:relative;color:var(--emw--color-typography, #FFFFFF);background-color:var(--emw--color-background, #1E1638);padding:24px;border-radius:var(--emw--border-radius-large, 8px);width:450px;max-width:100%;text-align:center;max-height:90dvh}.GradientBorder::before{content:\"\";position:absolute;top:-1px;left:-1px;right:-1px;bottom:-1px;border-radius:var(--emw--border-radius-large, 9px);background:linear-gradient(143.2deg, #FF9401 -0.41%, #FFD32D 45.61%, #FF9401 82.77%);z-index:-1}.ModalHeader h1{font-weight:var(--emw--font-weight-semibold, 600);font-size:var(--emw--font-size-large-plus, 24px);padding:0 16px;margin-bottom:16px}.ModalIcon{width:44px;height:44px;border-radius:50%;background-size:cover;margin:12px 0}.ModalBody{font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);color:var(--emw--color-secondary, #BBB9C3);padding:0 16px}.ModalFooter{margin-top:40px;margin-bottom:28px;padding:0 16px;width:100%}@keyframes rotate{100%{transform:rotate(1turn)}}.ModalOverlay .ModalWinAnimation{display:none}.ModalOverlay.ShowAnimation .ModalWinAnimation{display:block;position:absolute;width:100%;height:100%;inset:0;background:center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/light.svg) no-repeat, center/550px url(https://static.everymatrix.com/gic/img/engagement-suite/win.svg) no-repeat;animation:6s rotate linear infinite}.ModalOverlay.Mobile .EngagementSuiteIconButton{width:16px;height:16px}.ModalOverlay.Mobile .ModalBody{font-size:var(--emw--font-size-small, 14px)}.ModalOverlay.Mobile .ModalContent{width:318px;padding:12px}.ModalOverlay.Mobile .ModalHeader h1{font-size:var(--emw--font-size-large, 20px);padding:0 60px}.ModalOverlay.Mobile.ShowAnimation .ModalWinAnimation{background-size:400px}";
|
|
8
8
|
const CasinoEngagementSuiteModalStyle0 = casinoEngagementSuiteModalCss;
|
|
@@ -11,20 +11,6 @@ const CasinoEngagementSuiteModal = class {
|
|
|
11
11
|
constructor(hostRef) {
|
|
12
12
|
index.registerInstance(this, hostRef);
|
|
13
13
|
this.closeModal = index.createEvent(this, "closeModal", 7);
|
|
14
|
-
/**
|
|
15
|
-
* Client custom styling via string
|
|
16
|
-
*/
|
|
17
|
-
this.clientStyling = '';
|
|
18
|
-
/**
|
|
19
|
-
* Client custom styling via url
|
|
20
|
-
*/
|
|
21
|
-
this.clientStylingUrl = '';
|
|
22
|
-
this.device = 'Mobile';
|
|
23
|
-
/**
|
|
24
|
-
* Show win animation
|
|
25
|
-
*/
|
|
26
|
-
this.showAnimation = false;
|
|
27
|
-
this.limitStylingAppends = false;
|
|
28
14
|
this.handleCloseClick = () => {
|
|
29
15
|
if (this.isLoading)
|
|
30
16
|
return;
|
|
@@ -48,6 +34,16 @@ const CasinoEngagementSuiteModal = class {
|
|
|
48
34
|
console.log('Error ', err);
|
|
49
35
|
});
|
|
50
36
|
};
|
|
37
|
+
this.clientStyling = '';
|
|
38
|
+
this.clientStylingUrl = '';
|
|
39
|
+
this.isOpen = undefined;
|
|
40
|
+
this.isLoading = undefined;
|
|
41
|
+
this.header = undefined;
|
|
42
|
+
this.contentIcon = undefined;
|
|
43
|
+
this.modalType = undefined;
|
|
44
|
+
this.device = 'Mobile';
|
|
45
|
+
this.showAnimation = false;
|
|
46
|
+
this.limitStylingAppends = false;
|
|
51
47
|
}
|
|
52
48
|
componentDidRender() {
|
|
53
49
|
if (!this.limitStylingAppends && this.host) {
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-0d730cd7.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
|
-
Stencil Client Patch Browser v4.
|
|
9
|
+
Stencil Client Patch Browser v4.19.2 | MIT Licensed | https://stenciljs.com
|
|
10
10
|
*/
|
|
11
11
|
var patchBrowser = () => {
|
|
12
12
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('casino-engagement-suite-modal.cjs.js', document.baseURI).href));
|
|
@@ -21,23 +21,19 @@ function _interopNamespace(e) {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
const NAMESPACE = 'casino-engagement-suite-modal';
|
|
24
|
-
const BUILD = /* casino-engagement-suite-modal */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false,
|
|
24
|
+
const BUILD = /* casino-engagement-suite-modal */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: false, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: false, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: false };
|
|
25
25
|
|
|
26
26
|
/*
|
|
27
|
-
Stencil Client Platform v4.
|
|
27
|
+
Stencil Client Platform v4.19.2 | MIT Licensed | https://stenciljs.com
|
|
28
28
|
*/
|
|
29
29
|
var __defProp = Object.defineProperty;
|
|
30
30
|
var __export = (target, all) => {
|
|
31
31
|
for (var name in all)
|
|
32
32
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
33
33
|
};
|
|
34
|
-
|
|
35
|
-
// src/client/client-host-ref.ts
|
|
36
34
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
|
37
35
|
var getHostRef = (ref) => hostRefs.get(ref);
|
|
38
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
|
39
|
-
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
40
|
-
};
|
|
36
|
+
var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
41
37
|
var registerHost = (hostElement, cmpMeta) => {
|
|
42
38
|
const hostRef = {
|
|
43
39
|
$flags$: 0,
|
|
@@ -50,8 +46,7 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
50
46
|
hostElement["s-p"] = [];
|
|
51
47
|
hostElement["s-rc"] = [];
|
|
52
48
|
}
|
|
53
|
-
|
|
54
|
-
return ref;
|
|
49
|
+
return hostRefs.set(hostElement, hostRef);
|
|
55
50
|
};
|
|
56
51
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
57
52
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -88,22 +83,16 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
88
83
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
89
84
|
/* webpackMode: "lazy" */
|
|
90
85
|
`./${bundleId}.entry.js${""}`
|
|
91
|
-
)); }).then(
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
cmpModules.set(bundleId, importedModule);
|
|
95
|
-
}
|
|
96
|
-
return importedModule[exportName];
|
|
97
|
-
},
|
|
98
|
-
(e) => {
|
|
99
|
-
consoleError(e, hostRef.$hostElement$);
|
|
86
|
+
)); }).then((importedModule) => {
|
|
87
|
+
{
|
|
88
|
+
cmpModules.set(bundleId, importedModule);
|
|
100
89
|
}
|
|
101
|
-
|
|
90
|
+
return importedModule[exportName];
|
|
91
|
+
}, consoleError);
|
|
102
92
|
};
|
|
103
93
|
|
|
104
94
|
// src/client/client-style.ts
|
|
105
95
|
var styles = /* @__PURE__ */ new Map();
|
|
106
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
|
107
96
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
108
97
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
109
98
|
var win = typeof window !== "undefined" ? window : {};
|
|
@@ -161,6 +150,12 @@ var flush = () => {
|
|
|
161
150
|
};
|
|
162
151
|
var nextTick = (cb) => promiseResolve().then(cb);
|
|
163
152
|
var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
|
|
153
|
+
|
|
154
|
+
// src/utils/constants.ts
|
|
155
|
+
var EMPTY_OBJ = {};
|
|
156
|
+
|
|
157
|
+
// src/utils/helpers.ts
|
|
158
|
+
var isDef = (v) => v != null;
|
|
164
159
|
var isComplexType = (o) => {
|
|
165
160
|
o = typeof o;
|
|
166
161
|
return o === "object" || o === "function";
|
|
@@ -361,40 +356,13 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
361
356
|
}
|
|
362
357
|
if (!appliedStyles.has(scopeId2)) {
|
|
363
358
|
{
|
|
364
|
-
styleElm =
|
|
359
|
+
styleElm = doc.createElement("style");
|
|
365
360
|
styleElm.innerHTML = style;
|
|
366
361
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
367
362
|
if (nonce != null) {
|
|
368
363
|
styleElm.setAttribute("nonce", nonce);
|
|
369
364
|
}
|
|
370
|
-
|
|
371
|
-
if (styleContainerNode.nodeName === "HEAD") {
|
|
372
|
-
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
373
|
-
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
374
|
-
styleContainerNode.insertBefore(
|
|
375
|
-
styleElm,
|
|
376
|
-
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
377
|
-
);
|
|
378
|
-
} else if ("host" in styleContainerNode) {
|
|
379
|
-
if (supportsConstructableStylesheets) {
|
|
380
|
-
const stylesheet = new CSSStyleSheet();
|
|
381
|
-
stylesheet.replaceSync(style);
|
|
382
|
-
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
|
383
|
-
} else {
|
|
384
|
-
const existingStyleContainer = styleContainerNode.querySelector("style");
|
|
385
|
-
if (existingStyleContainer) {
|
|
386
|
-
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
|
387
|
-
} else {
|
|
388
|
-
styleContainerNode.prepend(styleElm);
|
|
389
|
-
}
|
|
390
|
-
}
|
|
391
|
-
} else {
|
|
392
|
-
styleContainerNode.append(styleElm);
|
|
393
|
-
}
|
|
394
|
-
}
|
|
395
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
396
|
-
styleContainerNode.insertBefore(styleElm, null);
|
|
397
|
-
}
|
|
365
|
+
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector("link"));
|
|
398
366
|
}
|
|
399
367
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
|
400
368
|
styleElm.innerHTML += SLOT_FB_CSS;
|
|
@@ -417,25 +385,23 @@ var attachStyles = (hostRef) => {
|
|
|
417
385
|
const scopeId2 = addStyle(
|
|
418
386
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
|
419
387
|
cmpMeta);
|
|
420
|
-
if (
|
|
388
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
|
421
389
|
elm["s-sc"] = scopeId2;
|
|
422
390
|
elm.classList.add(scopeId2 + "-h");
|
|
423
391
|
}
|
|
424
392
|
endAttachStyles();
|
|
425
393
|
};
|
|
426
394
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
427
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags
|
|
395
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
428
396
|
if (oldValue !== newValue) {
|
|
429
397
|
let isProp = isMemberInElement(elm, memberName);
|
|
430
398
|
let ln = memberName.toLowerCase();
|
|
431
399
|
if (memberName === "class") {
|
|
432
400
|
const classList = elm.classList;
|
|
433
401
|
const oldClasses = parseClassList(oldValue);
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
438
|
-
}
|
|
402
|
+
const newClasses = parseClassList(newValue);
|
|
403
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
404
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
439
405
|
} else if (memberName === "style") {
|
|
440
406
|
{
|
|
441
407
|
for (const prop in oldValue) {
|
|
@@ -484,13 +450,9 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
484
450
|
if (memberName === "list") {
|
|
485
451
|
isProp = false;
|
|
486
452
|
} else if (oldValue == null || elm[memberName] != n) {
|
|
487
|
-
|
|
488
|
-
elm[memberName] = n;
|
|
489
|
-
} else {
|
|
490
|
-
elm.setAttribute(memberName, n);
|
|
491
|
-
}
|
|
453
|
+
elm[memberName] = n;
|
|
492
454
|
}
|
|
493
|
-
} else
|
|
455
|
+
} else {
|
|
494
456
|
elm[memberName] = newValue;
|
|
495
457
|
}
|
|
496
458
|
} catch (e) {
|
|
@@ -512,44 +474,24 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
512
474
|
}
|
|
513
475
|
};
|
|
514
476
|
var parseClassListRegex = /\s/;
|
|
515
|
-
var parseClassList = (value) =>
|
|
516
|
-
if (typeof value === "object" && value && "baseVal" in value) {
|
|
517
|
-
value = value.baseVal;
|
|
518
|
-
}
|
|
519
|
-
if (!value || typeof value !== "string") {
|
|
520
|
-
return [];
|
|
521
|
-
}
|
|
522
|
-
return value.split(parseClassListRegex);
|
|
523
|
-
};
|
|
477
|
+
var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
|
|
524
478
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
525
479
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
526
480
|
|
|
527
481
|
// src/runtime/vdom/update-element.ts
|
|
528
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2
|
|
482
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
529
483
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
530
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
531
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
484
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
|
|
485
|
+
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
532
486
|
{
|
|
533
487
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
534
488
|
if (!(memberName in newVnodeAttrs)) {
|
|
535
|
-
setAccessor(
|
|
536
|
-
elm,
|
|
537
|
-
memberName,
|
|
538
|
-
oldVnodeAttrs[memberName],
|
|
539
|
-
void 0,
|
|
540
|
-
isSvgMode2,
|
|
541
|
-
newVnode.$flags$);
|
|
489
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
|
|
542
490
|
}
|
|
543
491
|
}
|
|
544
492
|
}
|
|
545
493
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
546
|
-
setAccessor(
|
|
547
|
-
elm,
|
|
548
|
-
memberName,
|
|
549
|
-
oldVnodeAttrs[memberName],
|
|
550
|
-
newVnodeAttrs[memberName],
|
|
551
|
-
isSvgMode2,
|
|
552
|
-
newVnode.$flags$);
|
|
494
|
+
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
|
|
553
495
|
}
|
|
554
496
|
};
|
|
555
497
|
function sortedAttrNames(attrNames) {
|
|
@@ -561,10 +503,13 @@ function sortedAttrNames(attrNames) {
|
|
|
561
503
|
attrNames
|
|
562
504
|
);
|
|
563
505
|
}
|
|
506
|
+
|
|
507
|
+
// src/runtime/vdom/vdom-render.ts
|
|
508
|
+
var scopeId;
|
|
564
509
|
var hostTagName;
|
|
565
510
|
var useNativeShadowDom = false;
|
|
566
511
|
var isSvgMode = false;
|
|
567
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
512
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
568
513
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
569
514
|
let i2 = 0;
|
|
570
515
|
let elm;
|
|
@@ -578,6 +523,9 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
|
578
523
|
{
|
|
579
524
|
updateElement(null, newVNode2, isSvgMode);
|
|
580
525
|
}
|
|
526
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
527
|
+
elm.classList.add(elm["s-si"] = scopeId);
|
|
528
|
+
}
|
|
581
529
|
if (newVNode2.$children$) {
|
|
582
530
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
583
531
|
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
@@ -706,9 +654,6 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
706
654
|
if (!isInitialRender) {
|
|
707
655
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
708
656
|
}
|
|
709
|
-
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
710
|
-
leftVNode.$key$ = rightVNode.$key$;
|
|
711
|
-
}
|
|
712
657
|
return true;
|
|
713
658
|
}
|
|
714
659
|
return false;
|
|
@@ -732,10 +677,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
732
677
|
elm.textContent = "";
|
|
733
678
|
}
|
|
734
679
|
addVnodes(elm, null, newVNode2, newChildren, 0, newChildren.length - 1);
|
|
735
|
-
} else if (
|
|
736
|
-
// don't do this on initial render as it can cause non-hydrated content to be removed
|
|
737
|
-
!isInitialRender && BUILD.updatable && oldChildren !== null
|
|
738
|
-
) {
|
|
680
|
+
} else if (oldChildren !== null) {
|
|
739
681
|
removeVnodes(oldChildren, 0, oldChildren.length - 1);
|
|
740
682
|
}
|
|
741
683
|
} else if (oldVNode.$text$ !== text) {
|
|
@@ -743,9 +685,8 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
743
685
|
}
|
|
744
686
|
};
|
|
745
687
|
var insertBefore = (parent, newNode, reference) => {
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
}
|
|
688
|
+
const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
689
|
+
return inserted;
|
|
749
690
|
};
|
|
750
691
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
751
692
|
const hostElm = hostRef.$hostElement$;
|
|
@@ -770,21 +711,17 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
770
711
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
771
712
|
hostRef.$vnode$ = rootVnode;
|
|
772
713
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
773
|
-
|
|
714
|
+
{
|
|
715
|
+
scopeId = hostElm["s-sc"];
|
|
716
|
+
}
|
|
717
|
+
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
774
718
|
patch(oldVNode, rootVnode, isInitialLoad);
|
|
775
719
|
};
|
|
776
720
|
|
|
777
721
|
// src/runtime/update-component.ts
|
|
778
722
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
779
723
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
780
|
-
|
|
781
|
-
new Promise(
|
|
782
|
-
(r) => hostRef.$onRenderResolve$ = () => {
|
|
783
|
-
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
784
|
-
r();
|
|
785
|
-
}
|
|
786
|
-
)
|
|
787
|
-
);
|
|
724
|
+
ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
|
|
788
725
|
}
|
|
789
726
|
};
|
|
790
727
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -875,7 +812,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
875
812
|
const instance = hostRef.$lazyInstance$ ;
|
|
876
813
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
877
814
|
{
|
|
878
|
-
safeCall(instance, "componentDidRender"
|
|
815
|
+
safeCall(instance, "componentDidRender");
|
|
879
816
|
}
|
|
880
817
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
881
818
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
@@ -904,14 +841,17 @@ var postUpdateComponent = (hostRef) => {
|
|
|
904
841
|
}
|
|
905
842
|
};
|
|
906
843
|
var appDidLoad = (who) => {
|
|
844
|
+
{
|
|
845
|
+
addHydratedFlag(doc.documentElement);
|
|
846
|
+
}
|
|
907
847
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
908
848
|
};
|
|
909
|
-
var safeCall = (instance, method, arg
|
|
849
|
+
var safeCall = (instance, method, arg) => {
|
|
910
850
|
if (instance && instance[method]) {
|
|
911
851
|
try {
|
|
912
852
|
return instance[method](arg);
|
|
913
853
|
} catch (e) {
|
|
914
|
-
consoleError(e
|
|
854
|
+
consoleError(e);
|
|
915
855
|
}
|
|
916
856
|
}
|
|
917
857
|
return void 0;
|
|
@@ -954,68 +894,15 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
954
894
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
955
895
|
members.map(([memberName, [memberFlags]]) => {
|
|
956
896
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
957
|
-
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
958
|
-
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
959
|
-
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
960
|
-
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
961
|
-
Object.defineProperty(prototype, memberName, {
|
|
962
|
-
get() {
|
|
963
|
-
{
|
|
964
|
-
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
965
|
-
return getValue(this, memberName);
|
|
966
|
-
}
|
|
967
|
-
const ref = getHostRef(this);
|
|
968
|
-
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
969
|
-
if (!instance) return;
|
|
970
|
-
return instance[memberName];
|
|
971
|
-
}
|
|
972
|
-
},
|
|
973
|
-
configurable: true,
|
|
974
|
-
enumerable: true
|
|
975
|
-
});
|
|
976
|
-
}
|
|
977
897
|
Object.defineProperty(prototype, memberName, {
|
|
898
|
+
get() {
|
|
899
|
+
return getValue(this, memberName);
|
|
900
|
+
},
|
|
978
901
|
set(newValue) {
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
newValue = ref.$instanceValues$.get(memberName);
|
|
984
|
-
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
985
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
986
|
-
}
|
|
987
|
-
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
988
|
-
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
989
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
990
|
-
return;
|
|
991
|
-
}
|
|
992
|
-
{
|
|
993
|
-
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
994
|
-
setValue(this, memberName, newValue, cmpMeta);
|
|
995
|
-
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
996
|
-
ref.$onReadyPromise$.then(() => {
|
|
997
|
-
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
998
|
-
ref.$lazyInstance$[memberName] = newValue;
|
|
999
|
-
}
|
|
1000
|
-
});
|
|
1001
|
-
}
|
|
1002
|
-
return;
|
|
1003
|
-
}
|
|
1004
|
-
const setterSetVal = () => {
|
|
1005
|
-
const currentValue = ref.$lazyInstance$[memberName];
|
|
1006
|
-
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1007
|
-
ref.$instanceValues$.set(memberName, currentValue);
|
|
1008
|
-
}
|
|
1009
|
-
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1010
|
-
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1011
|
-
};
|
|
1012
|
-
if (ref.$lazyInstance$) {
|
|
1013
|
-
setterSetVal();
|
|
1014
|
-
} else {
|
|
1015
|
-
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1016
|
-
}
|
|
1017
|
-
}
|
|
1018
|
-
}
|
|
902
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
903
|
+
},
|
|
904
|
+
configurable: true,
|
|
905
|
+
enumerable: true
|
|
1019
906
|
});
|
|
1020
907
|
}
|
|
1021
908
|
});
|
|
@@ -1025,11 +912,10 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1025
912
|
plt.jmp(() => {
|
|
1026
913
|
var _a2;
|
|
1027
914
|
const propName = attrNameToPropName.get(attrName);
|
|
1028
|
-
if (this.hasOwnProperty(propName)
|
|
915
|
+
if (this.hasOwnProperty(propName)) {
|
|
1029
916
|
newValue = this[propName];
|
|
1030
917
|
delete this[propName];
|
|
1031
|
-
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" &&
|
|
1032
|
-
this[propName] == newValue) {
|
|
918
|
+
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && this[propName] == newValue) {
|
|
1033
919
|
return;
|
|
1034
920
|
} else if (propName == null) {
|
|
1035
921
|
const hostRef = getHostRef(this);
|
|
@@ -1045,11 +931,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1045
931
|
}
|
|
1046
932
|
return;
|
|
1047
933
|
}
|
|
1048
|
-
|
|
1049
|
-
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1050
|
-
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1051
|
-
this[propName] = newValue;
|
|
1052
|
-
}
|
|
934
|
+
this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1053
935
|
});
|
|
1054
936
|
};
|
|
1055
937
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1078,7 +960,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1078
960
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1079
961
|
const bundleId = cmpMeta.$lazyBundleId$;
|
|
1080
962
|
if (bundleId) {
|
|
1081
|
-
const CstrImport = loadModule(cmpMeta
|
|
963
|
+
const CstrImport = loadModule(cmpMeta);
|
|
1082
964
|
if (CstrImport && "then" in CstrImport) {
|
|
1083
965
|
const endLoad = uniqueTime();
|
|
1084
966
|
Cstr = await CstrImport;
|
|
@@ -1100,7 +982,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1100
982
|
try {
|
|
1101
983
|
new Cstr(hostRef);
|
|
1102
984
|
} catch (e) {
|
|
1103
|
-
consoleError(e
|
|
985
|
+
consoleError(e);
|
|
1104
986
|
}
|
|
1105
987
|
{
|
|
1106
988
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1132,7 +1014,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1132
1014
|
schedule();
|
|
1133
1015
|
}
|
|
1134
1016
|
};
|
|
1135
|
-
var fireConnectedCallback = (instance
|
|
1017
|
+
var fireConnectedCallback = (instance) => {
|
|
1136
1018
|
};
|
|
1137
1019
|
|
|
1138
1020
|
// src/runtime/connected-callback.ts
|
|
@@ -1172,7 +1054,7 @@ var connectedCallback = (elm) => {
|
|
|
1172
1054
|
endConnected();
|
|
1173
1055
|
}
|
|
1174
1056
|
};
|
|
1175
|
-
var disconnectInstance = (instance
|
|
1057
|
+
var disconnectInstance = (instance) => {
|
|
1176
1058
|
};
|
|
1177
1059
|
var disconnectedCallback = async (elm) => {
|
|
1178
1060
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
@@ -1181,12 +1063,6 @@ var disconnectedCallback = async (elm) => {
|
|
|
1181
1063
|
hostRef.$onReadyPromise$.then(() => disconnectInstance());
|
|
1182
1064
|
}
|
|
1183
1065
|
}
|
|
1184
|
-
if (rootAppliedStyles.has(elm)) {
|
|
1185
|
-
rootAppliedStyles.delete(elm);
|
|
1186
|
-
}
|
|
1187
|
-
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1188
|
-
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1189
|
-
}
|
|
1190
1066
|
};
|
|
1191
1067
|
|
|
1192
1068
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1263,17 +1139,6 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1263
1139
|
}
|
|
1264
1140
|
disconnectedCallback() {
|
|
1265
1141
|
plt.jmp(() => disconnectedCallback(this));
|
|
1266
|
-
plt.raf(() => {
|
|
1267
|
-
var _a3;
|
|
1268
|
-
const hostRef = getHostRef(this);
|
|
1269
|
-
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
1270
|
-
if (i2 > -1) {
|
|
1271
|
-
deferredConnectedCallbacks.splice(i2, 1);
|
|
1272
|
-
}
|
|
1273
|
-
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1274
|
-
delete hostRef.$vnode$.$elm$;
|
|
1275
|
-
}
|
|
1276
|
-
});
|
|
1277
1142
|
}
|
|
1278
1143
|
componentOnReady() {
|
|
1279
1144
|
return getHostRef(this).$onReadyPromise$;
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-0d730cd7.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|