notificare-react-preview-components 1.0.0 → 1.1.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/esm/index.js CHANGED
@@ -1,2 +1,10 @@
1
- import{jsxs as e,jsx as t,Fragment as n}from"react/jsx-runtime";import i,{useState as a,useRef as o,useEffect as r,Fragment as s,createContext as c,useContext as _,forwardRef as l,useMemo as d,useImperativeHandle as p,Children as u,useReducer as h,useCallback as f,useLayoutEffect as m}from"react";import{createPortal as g}from"react-dom";function b(e,t,n,i){return new(n||(n=Promise))((function(a,o){function r(e){try{c(i.next(e))}catch(e){o(e)}}function s(e){try{c(i.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}c((i=i.apply(e,t||[])).next())}))}function v(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&i.firstChild?i.insertBefore(a,i.firstChild):i.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}"function"==typeof SuppressedError&&SuppressedError;v("@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');\n\n.notificare {\n font-family: proxima-nova, Helvetica, Arial, sans-serif;\n color: #232c2a;\n}\n\n.notificare * {\n border: 0;\n margin: 0;\n box-sizing: border-box;\n}");v(".notificare .notificare__push__preview {\n margin-top: 20px;\n}\n\n.notificare .notificare__push__preview-wrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: max-content;\n}");v(".notificare .notificare__push__preview-controls {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 350px;\n row-gap: 14px;\n}\n\n.notificare .notificare__push__preview-controls-preview {\n margin-top: 14px;\n}\n\n.notificare .notificare__push__preview-controls-toggle-groups {\n display: flex;\n align-items: center;\n column-gap: 30px;\n align-self: start;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-divider {\n width: 20px;\n height: 20px;\n animation: fadeIn 0.3s ease-out;\n}\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}");function y({options:n,selected:i,setSelected:s}){var c;const[_,l]=a(!1),d=o(null);if(r((()=>{l(!1),n.find((e=>e.key===i))&&i||s(n[0].key)}),[]),r((()=>{function e(e){d.current&&!d.current.contains(e.target)&&l(!1)}return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}}),[]),n.length>0)return e("div",{className:"notificare__push__preview-controls-selector",children:[t("p",{className:"notificare__push__preview-controls-selector-label",children:"Variant"}),e("button",{className:"notificare__push__preview-controls-selector-button",onClick:()=>l(!_),children:[null===(c=n.find((e=>e.key===i)))||void 0===c?void 0:c.label,t("svg",{className:"notificare__push__preview-controls-selector-button-expand-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"})})]}),_&&t("div",{className:"notificare__push__preview-controls-selector-options",ref:d,children:n.map((e=>t("button",{className:"notificare__push__preview-controls-selector-option-button "+(i===e.key?"notificare__push__preview-controls-selector-option-button--selected":""),onClick:()=>{s(e.key),l(!1)},"data-testid":`selector-option-${e.key}`,children:e.label},e.key)))})]})}v(".notificare .notificare__push__preview-controls-selector {\n position: relative;\n}\n\n.notificare .notificare__push__preview-controls-selector-label {\n font-size: 14px;\n color: #6e6e6e;\n margin-bottom: 7px;\n}\n\n.notificare .notificare__push__preview-controls-selector-button {\n width: 350px;\n height: 42px;\n background-color: #F6F6F6;\n color: #1c1c1c;\n border: 1px solid #E8E8E8;\n text-align: left;\n padding-left: 14px;\n font-size: 16px;\n display: flex;\n align-items: center;\n}\n\n.notificare .notificare__push__preview-controls-selector-button:hover {\n cursor: pointer;\n}\n\n.notificare .notificare__push__preview-controls-selector-button-expand-icon {\n width: 16px;\n height: 16px;\n margin-left: auto;\n margin-right: 14px;\n}\n\n.notificare .notificare__push__preview-controls-selector-options {\n display: flex;\n flex-direction: column;\n position: absolute;\n top: 63px;\n z-index: 1;\n box-shadow: 0 14px 10px -10px rgba(0, 0, 0, 0.2);\n}\n\n.notificare .notificare__push__preview-controls-selector-option-button {\n width: 350px;\n height: 42px;\n background-color: #ececec;\n color: #151515;\n border: 0;\n font-size: 15px;\n text-align: left;\n padding-left: 14px;\n}\n\n.notificare .notificare__push__preview-controls-selector-option-button--selected {\n background-color: #c8c8c8;\n}\n\n.notificare .notificare__push__preview-controls-selector-option-button:hover {\n background-color: #5E5E5E;\n color: white;\n cursor: pointer;\n}");function w({label:n,options:i,selected:a,setSelected:o}){return r((()=>{a||o(i[0].key)}),[]),e("div",{className:"notificare__push__preview-controls-toggle-group",children:[e("p",{className:"notificare__push__preview-controls-toggle-group-label",children:[" ",n," "]}),t("div",{className:"notificare__push__preview-controls-toggle-group-options",children:i.map(((n,r)=>e(s,{children:[t("button",{className:"notificare__push__preview-controls-toggle-group-option "+(a===n.key?"notificare__push__preview-controls-toggle-group-option--selected":""),onClick:()=>o(n.key),"aria-label":`Button with option '${n.key}'`,"data-testid":`toggle-option-${n.key}`,children:t("div",{className:"notificare__push__preview-controls-toggle-group-option-icon "+(a===n.key?"notificare__push__preview-controls-toggle-group-option-icon--selected":""),children:n.icon})}),r!==i.length-1&&t("div",{className:"notificare__push__preview-controls-toggle-group-divisor"})]},n.key)))})]})}function x({platform:i,mobileVariant:a,webDevice:o,webMobileType:r,webDesktopOS:s,setPlatform:c,setMobileVariant:_,setWebDevice:l,setWebMobileType:d,setWebDesktopOS:p}){const u=[{key:"android",icon:t("svg",{width:"22px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{d:"M420.6 301.9a24 24 0 1 1 24-24 24 24 0 0 1 -24 24m-265.1 0a24 24 0 1 1 24-24 24 24 0 0 1 -24 24m273.7-144.5 47.9-83a10 10 0 1 0 -17.3-10h0l-48.5 84.1a301.3 301.3 0 0 0 -246.6 0L116.2 64.5a10 10 0 1 0 -17.3 10h0l47.9 83C64.5 202.2 8.2 285.6 0 384H576c-8.2-98.5-64.5-181.8-146.9-226.6"})},"Android Icon")},{key:"ios",icon:t("svg",{width:"20px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",children:t("path",{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"})},"iOS Icon")},{key:"web",icon:t("svg",{width:"22px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",children:t("path",{d:"M0 32l34.9 395.8L191.5 480l157.6-52.2L384 32H0zm308.2 127.9H124.4l4.1 49.4h175.6l-13.6 148.4-97.9 27v.3h-1.1l-98.7-27.3-6-75.8h47.7L138 320l53.5 14.5 53.7-14.5 6-62.2H84.3L71.5 112.2h241.1l-4.4 47.7z"})},"Web Icon")}],h=[{key:"desktop",icon:t("svg",{width:"22px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{d:"M64 0C28.7 0 0 28.7 0 64L0 352c0 35.3 28.7 64 64 64l176 0-10.7 32L160 448c-17.7 0-32 14.3-32 32s14.3 32 32 32l256 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-69.3 0L336 416l176 0c35.3 0 64-28.7 64-64l0-288c0-35.3-28.7-64-64-64L64 0zM512 64l0 288L64 352 64 64l448 0z"})},"Desktop Icon")},{key:"phone",icon:t("svg",{width:"19px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",children:t("path",{d:"M16 64C16 28.7 44.7 0 80 0L304 0c35.3 0 64 28.7 64 64l0 384c0 35.3-28.7 64-64 64L80 512c-35.3 0-64-28.7-64-64L16 64zM224 448a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zM304 64L80 64l0 320 224 0 0-320z"})},"Phone Icon")}],f=[{key:"android",icon:t("svg",{width:"22px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{d:"M420.6 301.9a24 24 0 1 1 24-24 24 24 0 0 1 -24 24m-265.1 0a24 24 0 1 1 24-24 24 24 0 0 1 -24 24m273.7-144.5 47.9-83a10 10 0 1 0 -17.3-10h0l-48.5 84.1a301.3 301.3 0 0 0 -246.6 0L116.2 64.5a10 10 0 1 0 -17.3 10h0l47.9 83C64.5 202.2 8.2 285.6 0 384H576c-8.2-98.5-64.5-181.8-146.9-226.6"})},"iOS Icon")},{key:"iphone",icon:t("svg",{width:"20px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",children:t("path",{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"})},"iOS Icon")}];return e("div",{className:"notificare__push__preview-controls","data-testid":"controls",children:[e("div",{className:"notificare__push__preview-controls-toggle-groups",children:[t(w,{label:"Platform",options:u.map((e=>e)),selected:i,setSelected:c}),"web"===i&&e(n,{children:[t(w,{label:"Form Factor",options:h.map((e=>e)),selected:o,setSelected:l}),"phone"===o&&t(w,{label:"Phone Model",options:f.map((e=>e)),selected:r,setSelected:d})]})]}),("ios"===i||"android"===i)&&t(y,{options:[{key:"lockscreen",label:"Lock Screen"},{key:"lockscreen-expanded",label:"Lock Screen Expanded"},{key:"app-ui",label:"App UI"}],selected:a,setSelected:_}),"web"===i&&e(n,{children:["phone"===o&&t(y,{options:[{key:"app-ui",label:"App UI"}],selected:a,setSelected:_}),"desktop"===o&&t(y,{options:[{key:"macOS",label:"macOS"}],selected:s,setSelected:p})]})]})}function k({options:e,children:n}){return t(C.Provider,{value:{options:e},children:n})}v(".notificare .notificare__push__preview-controls-toggle-group {\n display: flex;\n flex-direction: column;\n row-gap: 7px;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-label {\n font-size: 14px;\n color: #6e6e6e;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-options {\n display: flex;\n border-radius: 8px;\n border: 1px solid #DADADA;\n width: max-content;\n overflow: hidden;\n background-color: #F6F6F6;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-option {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 40px;\n height: 40px;\n transition: all 0.3s;\n background: #f6f6f6;\n color: #374151;\n border: 0;\n cursor: pointer;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-option--selected {\n background: #5E5E5E;\n color: #ffffff;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-option-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n fill: #C0C0C0;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-option-icon--selected {\n fill: #FFF\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-divisor {\n width: 1px;\n height: 40px;\n background: #DADADA;\n}");const N=()=>{const e=_(C);if(!e)throw new Error("useOptions should be used inside an OptionsProvider");return e},C=c(void 0);function S(e){return e.startsWith("https://")||e.startsWith("http://")?e:`https://push.notifica.re/upload${e}`}v(".notificare .notificare__push__android__preview {\n font-family: 'Roboto', sans-serif;\n height: 100%;\n}");function T({children:n,theme:i}){return e("div",{className:"notificare__push__android__phone-background "+("dark"===i?"notificare__push__android__phone-background--dark":""),"data-testid":"android-phone-background",children:[t("div",{className:"notificare__push__android__phone-background-camera"}),t("div",{className:"notificare__push__android__phone-background-content",children:n})]})}v(".notificare .notificare__push__android__phone-background {\n width: 350px;\n border-radius: 40px;\n border: 6px solid #c6c6c6;\n background-color: #fff;\n overflow: hidden;\n}\n\n.notificare .notificare__push__android__phone-background--dark {\n background-color: #9ea2a1;\n border-color: #eaeaea;\n}\n\n.notificare .notificare__push__android__phone-background-camera {\n width: 20px;\n height: 20px;\n background: #c6c6c6;\n border-radius: 50%;\n margin: 20px auto 10px;\n}\n\n.notificare .notificare__push__android__phone-background-content {\n width: 100%;\n height: 615px;\n overflow: hidden;\n position: relative;\n}");function A({message:n,showConsoleWarning:i}){return e("div",{"data-testid":"notificare-push-unavailable-preview",children:[e("div",{className:"notificare__push__unavailable-preview-warning",children:[t("svg",{className:"notificare__push__unavailable-preview-alert-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480L40 480c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24l0 112c0 13.3 10.7 24 24 24s24-10.7 24-24l0-112c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"})}),e("div",{className:"notificare__push__unavailable-preview-text-container",children:[t("div",{className:"notificare__push__unavailable-preview-title",children:"Preview could not be loaded"}),t("div",{className:"notificare__push__unavailable-preview-reason-text","data-testid":"notificare-push-unavailable-preview-reason-text",children:n})]})]}),i&&t("div",{className:"notificare__push__unavailable-preview-check-console-text",children:"Check console for more information"})]})}v(".notificare .notificare__push__unavailable-preview-warning {\n width: 350px;\n background-color: #fff1cc;\n border: 1px solid #d5d5d5;\n display: flex;\n align-items: center;\n padding: 14px;\n border-radius: 10px;\n column-gap: 14px;\n}\n\n.notificare .notificare__push__unavailable-preview-text-container {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n width: 100%;\n}\n\n.notificare .notificare__push__unavailable-preview-title {\n font-size: 15px;\n color: #232323;\n font-weight: bold;\n}\n\n.notificare .notificare__push__unavailable-preview-reason-text {\n font-size: 13px;\n color: #bd6868;\n}\n\n.notificare .notificare__push__unavailable-preview-alert-icon {\n width: 40px;\n}\n\n.notificare .notificare__push__unavailable-preview-check-console-text {\n font-size: 12px;\n color: #989898;\n text-align: right;\n margin-top: 6px;\n margin-right: 3px;\n font-style: italic;\n}");v("");v(".notificare .notificare__push__webshot-background {\n background-color: #fff;\n}");function O(){return t("div",{className:"notificare__push__webshot-loading-icon","data-testid":"loading-icon",children:t("svg",{className:"notificare__push__webshot-loading-icon-svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M222.7 32.1c5 16.9-4.6 34.8-21.5 39.8C121.8 95.6 64 169.1 64 256c0 106 86 192 192 192s192-86 192-192c0-86.9-57.8-160.4-137.1-184.1c-16.9-5-26.6-22.9-21.5-39.8s22.9-26.6 39.8-21.5C434.9 42.1 512 140 512 256c0 141.4-114.6 256-256 256S0 397.4 0 256C0 140 77.1 42.1 182.9 10.6c16.9-5 34.8 4.6 39.8 21.5z",fill:"#64706e"})})})}v("@keyframes notificare-push-webshot-loading-icon-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}\n\n.notificare .notificare__push__webshot-loading-icon {\n width: 100%;\n display: flex;\n justify-content: center;\n padding-top: 50px;\n}\n\n.notificare .notificare__push__webshot-loading-icon-svg {\n width: 60px;\n height: 60px;\n animation: notificare-push-webshot-loading-icon-spin 2s linear infinite;\n}");function j({message:i}){return e("div",{className:"notificare__push__preview-error","data-testid":"preview-error",children:[t("svg",{className:"notificare__push__preview-error-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480L40 480c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24l0 112c0 13.3 10.7 24 24 24s24-10.7 24-24l0-112c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"})}),e("p",{className:"notificare__push__preview-error-text",children:["Preview could not be generated",i&&e(n,{children:[t("br",{})," ",t("br",{})," ",i]})]})]})}function P({url:e,platform:n,width:i,height:o,onLoadingChange:s,canShow:c=!0}){const{serviceKey:_}=N().options,[l,d]=a(""),[p,u]=a(!1),[h,f]=a(!0);return r((()=>{if(!_)return u(!0),void console.error("The service key is missing");if(!function(e){try{return new URL(e),!0}catch(e){return!1}}(e))return u(!0),void console.error("The URL is invalid");let t;f(!0),null==s||s(!0),u(!1);const a=setTimeout((()=>b(this,void 0,void 0,(function*(){try{const a=yield function(e,t,n,i,a){return b(this,void 0,void 0,(function*(){const o=yield fetch(`https://push.notifica.re/webshot?apiKey=${a}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:e,delay:3e3,platform:i,type:"png",params:{width:t,height:n}})});return(yield o.json()).webshot.id}))}(e,i,o,n,_);t=setInterval((()=>b(this,void 0,void 0,(function*(){const e=yield function(e,t){return b(this,void 0,void 0,(function*(){const n=yield fetch(`https://push.notifica.re/webshot/${e}?apiKey=${t}`);return(yield n.json()).webshot.status}))}(a,_);if("error"===e)u(!0),f(!1),null==s||s(!1),clearInterval(t);else if("finished"===e){const e=yield function(e,t){return b(this,void 0,void 0,(function*(){const n=yield fetch(`https://push.notifica.re/webshot/${e}/result?apiKey=${t}`),i=yield n.blob();return URL.createObjectURL(i)}))}(a,_);d(e),f(!1),null==s||s(!1),clearInterval(t)}}))),3e3)}catch(e){console.error(e),u(!0),f(!1),null==s||s(!1)}}))),3e3);return()=>{clearTimeout(a),clearInterval(t)}}),[e]),t("div",{className:"notificare__push__webshot-background",style:{width:i,height:o},children:p?t(j,{}):h||!c?t(O,{}):t("img",{src:l,alt:"Webshot","data-testid":"webshot"})})}v(".notificare .notificare__push__preview-error {\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n width: 100%;\n height: 440px;\n text-align: center;\n padding: 0 20px;\n}\n\n.notificare .notificare__push__preview-error-icon {\n width: 72px;\n margin-bottom: 20px;\n}\n\n.notificare .notificare__push__preview-error-text {\n font-weight: 700;\n font-size: 16px;\n color: #232c2a;\n}");function I({appName:n,title:i,showOptions:a}){return e("div",{className:"notificare__push__android__app-ui__navigation-bar",children:[t("svg",{className:"notificare__push__android__app-ui__navigation-bar-arrow-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",children:t("path",{d:"M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288 416 288c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0L214.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"})}),t("div",{className:"notificare__push__android__app-ui__navigation-bar-title",children:i||n}),a&&t("svg",{className:"notificare__push__android__app-ui__navigation-bar-options-button",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 128 512","data-testid":"android-app-ui-navigation-bar-options-button",children:t("path",{d:"M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112zm0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112zM120 96A56 56 0 1 0 8 96a56 56 0 1 0 112 0z"})})]})}function L({notification:n,appName:i}){return e("div",{"data-testid":"android-app-ui-app-recommendation-notification",children:[t(I,{appName:i,title:n.title,showOptions:!1}),t(P,{url:M(n.content[0]),platform:"Android",width:338,height:570})]})}function M(e){switch(e.type){case"re.notifica.content.GooglePlayDetails":return`https://play.google.com/store/apps/details?id=${e.data}`;case"re.notifica.content.GooglePlayDeveloper":return`https://play.google.com/store/apps/dev?id=${e.data}`;case"re.notifica.content.GooglePlayCollection":return`https://play.google.com/store/apps/collection/${e.data}`;case"re.notifica.content.GooglePlaySearch":return`https://play.google.com/store/search?q=${e.data}&c=apps`;default:return""}}v(".notificare .notificare__push__android__app-ui__navigation-bar {\n display: flex;\n width: 338px;\n height: 45px;\n padding: 0 15px;\n align-items: center;\n justify-content: flex-start;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-arrow-icon {\n margin-right: 20px;\n height: 24px;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-title {\n width: 100%;\n font-size: 18px;\n font-weight: 700;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-options-button {\n margin-left: auto;\n height: 24px;\n}");function E(e){return!!(e.actions&&e.actions.length>0)}function Z(e){return!(!e.actions||1!==e.actions.length)}function z(e){return!!(e.actions&&e.actions.length>1)}function R(e){var t;return!!(null===(t=e.attachments)||void 0===t?void 0:t[0])}function D({notification:n,appName:i}){return e("div",{"data-testid":"android-app-ui-passbook-notification",children:[t(I,{appName:i,title:n.title,showOptions:E(n)}),t(P,{url:`https://push.notifica.re/pass/web/${n.content[0].data.split("/")[5]}`,platform:"Android",width:338,height:570}),")"]})}v("");function $({notification:n,appName:i}){return e("div",{"data-testid":"android-app-ui-images-notification",children:[t(I,{appName:i,title:n.title,showOptions:E(n)}),t("div",{className:"notificare__push__android__image__app-ui__rich-content",children:t("div",{className:"notificare__push__android__image__app-ui__image-slider",children:n.content.map(((e,n)=>t("img",{className:"notificare__push__android__image__app-ui__image-slider-item",src:e.data,alt:"Slider image"},n)))})})]})}v(".notificare .notificare__push__android__image__app-ui__rich-content {\n display: flex;\n align-items: center;\n width: 100%;\n height: 570px;\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scrollbar-width: none; /* Hide in Firefox */\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider::-webkit-scrollbar {\n display: none; /* Hide in Chrome and Safari */\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}");v("");function F(e){try{const t=new URL(e).hostname,n=t.split(".");return n.length>2?n.slice(-2).join("."):t}catch(e){return console.error("Invalid URL:",e),""}}function V(e){try{return"https:"===new URL(e).protocol}catch(e){return!1}}function B({url:n,onLoadingChange:i,canShow:o}){const[s,c]=a(""),[_,l]=a(!1),{serviceKey:d}=N().options;return r((()=>{(()=>{b(this,void 0,void 0,(function*(){l(!0);const e=yield function(e,t){return b(this,void 0,void 0,(function*(){var n,i;try{const a=new URLSearchParams({apiKey:e,url:t}),o=yield fetch(`https://push.notifica.re/proxy/?${a.toString()}`),r=yield o.text(),s=new DOMParser;return null!==(i=null===(n=s.parseFromString(r,"text/html").querySelector("title"))||void 0===n?void 0:n.textContent)&&void 0!==i?i:""}catch(e){return console.error("Error getting page title: ",e),""}}))}(d,n);c(e),l(!1),null==i||i(!1)}))})()}),[n]),e("div",{className:"notificare__push__android__in-app-browser__app-ui__bar",children:[t("svg",{className:"notificare__push__android__in-app-browser__app-ui__x-mark-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",children:t("path",{d:"M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"})}),V(n)?t("svg",{className:"notificare__push__android__in-app-browser__app-ui__bar-lock-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",children:t("path",{d:"M144 144l0 48 160 0 0-48c0-44.2-35.8-80-80-80s-80 35.8-80 80zM80 192l0-48C80 64.5 144.5 0 224 0s144 64.5 144 144l0 48 16 0c35.3 0 64 28.7 64 64l0 192c0 35.3-28.7 64-64 64L64 512c-35.3 0-64-28.7-64-64L0 256c0-35.3 28.7-64 64-64l16 0z"})}):t("svg",{className:"notificare__push__android__in-app-browser__app-ui__loading-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480L40 480c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24l0 112c0 13.3 10.7 24 24 24s24-10.7 24-24l0-112c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"})}),e("div",{className:"notificare__push__android__in-app-browser__app-ui__bar-domain",children:[t("p",{className:"notificare__push__android__in-app-browser__app-ui__bar-text notificare__push__android__in-app-browser__app-ui__bar-text--title",children:!_&&o?s:"Loading..."}),t("p",{className:"notificare__push__android__in-app-browser__app-ui__bar-text notificare__push__android__in-app-browser__app-ui__bar-text--url",children:F(n)})]})]})}function U({notification:n}){const[i,o]=a(!0),[r,s]=a(!0),c=n.content[0].data;return e("div",{"data-testid":"android-app-ui-in-app-browser-notification",children:[t(B,{url:c,onLoadingChange:o,canShow:!r}),t(P,{url:c,platform:"Android",width:338,height:570,onLoadingChange:s,canShow:!i})]})}v(".notificare .notificare__push__android__in-app-browser__app-ui__bar {\n display: flex;\n width: 334px;\n height: 45px;\n padding: 0 15px;\n align-items: center;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__x-mark-icon {\n margin-right: 20px;\n height: 24px;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-lock-icon {\n margin-right: 7px;\n height: 14px;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__loading-icon {\n margin-right: 7px;\n height: 14px;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-domain {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-width: 0;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text--title {\n font-size: 14px;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text--url {\n font-size: 12px;\n}");function K({notification:n,appName:i,appIcon:a,expanded:o}){var r,s;return e("div",{className:"notificare__push__android__lock-screen","data-testid":"android-lock-screen-notification",children:[t("div",{className:"notificare__push__android__lock-screen__app-icon",children:t("img",{className:"notificare__push__android__lock-screen__app-icon-image",alt:"App icon",src:a})}),e("div",{className:"notificare__push__android__lock-screen__text-content",children:[e("div",{className:"notificare__push__android__lock-screen__text-content-top",children:[e("div",{className:"notificare__push__android__lock-screen__title-and-subtitle "+(R(n)&&!o?"notificare__push__android__lock-screen__title-and-subtitle--has-media":""),children:[t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--title",children:o?i:n.title||i}),n.subtitle&&!R(n)&&t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--subtitle",children:n.subtitle})]}),t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--time",children:"now"})]}),o&&t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--expanded-title",children:n.title}),t("p",{className:`notificare__push__android__lock-screen__text ${o?"notificare__push__android__lock-screen__text--expanded-message":""} ${R(n)&&!o?"notificare__push__android__lock-screen__text--message-with-media":"notificare__push__android__lock-screen__text--message-without-media"}`,children:n.message}),R(n)&&o&&t("div",{className:"notificare__push__android__lock-screen__expanded-media","data-testid":"android-lock-screen-notification-expanded-media",children:t("img",{className:"notificare__push__android__lock-screen__expanded-media-image",src:null===(r=n.attachments)||void 0===r?void 0:r[0].uri,alt:"Expanded media"})})]}),R(n)&&!o&&t("div",{className:"notificare__push__android__lock-screen__media","data-testid":"android-lock-screen-notification-media",children:t("img",{className:"notificare__push__android__lock-screen__media-image",src:null===(s=n.attachments)||void 0===s?void 0:s[0].uri,alt:"Media icon"})})]})}v(".notificare .notificare__push__android__lock-screen {\n position: absolute;\n font-family: 'Roboto', sans-serif;\n background-color: #f2f4f6;\n width: 315px;\n border-radius: 20px;\n padding: 10px;\n display: flex;\n flex-direction: row;\n column-gap: 11px;\n left: 50%;\n transform: translateX(-50%);\n top: 40px;\n}\n\n.notificare .notificare__push__android__lock-screen__wrapper {\n position: relative;\n}\n\n/* App Icon */\n\n.notificare .notificare__push__android__lock-screen__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n width: 32px;\n height: 32px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__android__lock-screen__app-icon-image {\n width: 100%;\n}\n\n/* Text Content */\n\n.notificare .notificare__push__android__lock-screen__text-content {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n}\n\n.notificare .notificare__push__android__lock-screen__text-content-top {\n display: flex;\n column-gap: 5px;\n margin-top: 0;\n margin-bottom: 0;\n}\n\n.notificare .notificare__push__android__lock-screen__title-and-subtitle {\n display: flex;\n overflow: hidden;\n column-gap: 6px;\n max-width: 223px;\n}\n\n.notificare .notificare__push__android__lock-screen__title-and-subtitle--has-media {\n max-width: 160px;\n}\n\n.notificare .notificare__push__android__lock-screen__text {\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.notificare .notificare__push__android__lock-screen__text--title {\n font-weight: 700;\n font-size: 14px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--expanded-title {\n font-weight: 700;\n font-size: 14px;\n margin-top: 5px;\n width: 223px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--subtitle {\n color: #64706e;\n font-size: 12px;\n font-weight: 400;\n}\n\n.notificare .notificare__push__android__lock-screen__text--time {\n color: #64706e;\n font-size: 12px;\n font-weight: 400;\n}\n\n.notificare .notificare__push__android__lock-screen__text--message-without-media {\n font-size: 14px;\n width: 252px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--message-with-media {\n font-size: 14px;\n width: 191px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--expanded-message {\n font-size: 14px;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 3;\n word-break: break-word;\n width: 252px;\n white-space: wrap;\n}\n\n/* Media */\n\n.notificare .notificare__push__android__lock-screen__media {\n display: flex;\n width: 50px;\n}\n\n.notificare .notificare__push__android__lock-screen__media-image {\n width: 50px;\n border-radius: 5px;\n object-fit: cover;\n}\n\n.notificare .notificare__push__android__lock-screen__expanded-media {\n margin-top: 5px;\n width: 252px;\n}\n\n.notificare .notificare__push__android__lock-screen__expanded-media-image {\n width: 100%;\n max-height: 168px;\n border-radius: 15px;\n}\n");v("");var W,G;function H(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}v("");var q=H(G?W:(G=1,W=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var i,a,o;if(Array.isArray(t)){if((i=t.length)!=n.length)return!1;for(a=i;0!=a--;)if(!e(t[a],n[a]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((i=(o=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(a=i;0!=a--;)if(!Object.prototype.hasOwnProperty.call(n,o[a]))return!1;for(a=i;0!=a--;){var r=o[a];if(!e(t[r],n[r]))return!1}return!0}return t!=t&&n!=n}));function J(){return J=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},J.apply(null,arguments)}function Y(e,t){if(null==e)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(-1!==t.indexOf(i))continue;n[i]=e[i]}return n}function X(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t);if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}const Q="NOT_LOADED",ee="LOADING",te="LOADED",ne="FAILED",ie="AUTH_FAILURE";class ae{static async load(e,t){var n;const i=e.libraries?e.libraries.split(","):[],a=this.serializeParams(e);this.listeners.push(t),null!=(n=window.google)&&null!=(n=n.maps)&&n.importLibrary?(this.serializedApiParams||(this.loadingStatus=te),this.notifyLoadingStatusListeners()):(this.serializedApiParams=a,this.initImportLibrary(e)),this.serializedApiParams&&this.serializedApiParams!==a&&console.warn("[google-maps-api-loader] The maps API has already been loaded with different parameters and will not be loaded again. Refresh the page for new values to have effect.");const o=["maps",...i];await Promise.all(o.map((e=>google.maps.importLibrary(e))))}static serializeParams(e){return[e.v,e.key,e.language,e.region,e.authReferrerPolicy,e.solutionChannel].join("/")}static initImportLibrary(e){if(window.google||(window.google={}),window.google.maps||(window.google.maps={}),window.google.maps.importLibrary)return void console.error("[google-maps-api-loader-internal]: initImportLibrary must only be called once");let t=null;const n=()=>t||(t=new Promise(((t,n)=>{var i;const a=document.createElement("script"),o=new URLSearchParams;for(const[t,n]of Object.entries(e)){const e=t.replace(/[A-Z]/g,(e=>"_"+e[0].toLowerCase()));o.set(e,String(n))}o.set("loading","async"),o.set("callback","__googleMapsCallback__"),a.async=!0,a.src="https://maps.googleapis.com/maps/api/js?"+o.toString(),a.nonce=(null==(i=document.querySelector("script[nonce]"))?void 0:i.nonce)||"",a.onerror=()=>{this.loadingStatus=ne,this.notifyLoadingStatusListeners(),n(new Error("The Google Maps JavaScript API could not load."))},window.__googleMapsCallback__=()=>{this.loadingStatus=te,this.notifyLoadingStatusListeners(),t()},window.gm_authFailure=()=>{this.loadingStatus=ie,this.notifyLoadingStatusListeners()},this.loadingStatus=ee,this.notifyLoadingStatusListeners(),document.head.append(a)})),t);google.maps.importLibrary=e=>n().then((()=>google.maps.importLibrary(e)))}static notifyLoadingStatusListeners(){for(const e of this.listeners)e(this.loadingStatus)}}ae.loadingStatus=Q,ae.serializedApiParams=void 0,ae.listeners=[];const oe=["onLoad","onError","apiKey","version","libraries"],re=["children"],se=i.createContext(null);const ce=e=>{const{children:t}=e,n=Y(e,re),{mapInstances:o,addMapInstance:s,removeMapInstance:c,clearMapInstances:_}=function(){const[e,t]=a({});return{mapInstances:e,addMapInstance:(e,n="default")=>{t((t=>J({},t,{[n]:e})))},removeMapInstance:(e="default")=>{t((t=>Y(t,[e].map(X))))},clearMapInstances:()=>{t({})}}}(),{status:l,loadedLibraries:p,importLibrary:u}=function(e){const{onLoad:t,onError:n,apiKey:i,version:o,libraries:s=[]}=e,c=Y(e,oe),[_,l]=a(ae.loadingStatus),[p,u]=h(((e,t)=>e[t.name]?e:J({},e,{[t.name]:t.value})),{}),m=d((()=>null==s?void 0:s.join(",")),[s]),g=d((()=>JSON.stringify(J({apiKey:i,version:o},c))),[i,o,c]),b=f((async e=>{var t;if(p[e])return p[e];if(null==(t=google)||null==(t=t.maps)||!t.importLibrary)throw new Error("[api-provider-internal] importLibrary was called before google.maps.importLibrary was defined.");const n=await window.google.maps.importLibrary(e);return u({name:e,value:n}),n}),[p]);return r((()=>{(async()=>{try{const e=J({key:i},c);o&&(e.v=o),(null==m?void 0:m.length)>0&&(e.libraries=m),(void 0===e.channel||e.channel<0||e.channel>999)&&delete e.channel,void 0===e.solutionChannel?e.solutionChannel="GMP_visgl_rgmlibrary_v1_default":""===e.solutionChannel&&delete e.solutionChannel,await ae.load(e,(e=>l(e)));for(const e of["core","maps",...s])await b(e);t&&t()}catch(e){n?n(e):console.error("<ApiProvider> failed to load the Google Maps JavaScript API",e)}})()}),[i,m,g]),{status:_,loadedLibraries:p,importLibrary:b}}(n),m=d((()=>({mapInstances:o,addMapInstance:s,removeMapInstance:c,clearMapInstances:_,status:l,loadedLibraries:p,importLibrary:u})),[o,s,c,_,l,p,u]);return i.createElement(se.Provider,{value:m},t)};function _e(e,t,n){const i={type:e,map:t,detail:{},stoppable:!1,stop:()=>{}};if(de.includes(e)){const e=i,n=t.getCenter(),a=t.getZoom(),o=t.getHeading()||0,r=t.getTilt()||0,s=t.getBounds();return n&&s&&Number.isFinite(a)||console.warn("[createEvent] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),e.detail={center:(null==n?void 0:n.toJSON())||{lat:0,lng:0},zoom:a||0,heading:o,tilt:r,bounds:(null==s?void 0:s.toJSON())||{north:90,east:180,south:-90,west:-180}},e}if(pe.includes(e)){var a;if(!n)throw new Error("[createEvent] mouse events must provide a srcEvent");const e=i;return e.domEvent=n.domEvent,e.stoppable=!0,e.stop=()=>n.stop(),e.detail={latLng:(null==(a=n.latLng)?void 0:a.toJSON())||null,placeId:n.placeId},e}return i}const le={onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onContextmenu:"contextmenu",onDblclick:"dblclick",onDrag:"drag",onDragend:"dragend",onDragstart:"dragstart",onHeadingChanged:"heading_changed",onIdle:"idle",onIsFractionalZoomEnabledChanged:"isfractionalzoomenabled_changed",onMapCapabilitiesChanged:"mapcapabilities_changed",onMapTypeIdChanged:"maptypeid_changed",onMousemove:"mousemove",onMouseout:"mouseout",onMouseover:"mouseover",onProjectionChanged:"projection_changed",onRenderingTypeChanged:"renderingtype_changed",onTilesLoaded:"tilesloaded",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed",onCameraChanged:"bounds_changed"},de=["bounds_changed","center_changed","heading_changed","tilt_changed","zoom_changed"],pe=["click","contextmenu","dblclick","mousemove","mouseout","mouseover"],ue=Object.keys(le);const he=new Set(["backgroundColor","clickableIcons","controlSize","disableDefaultUI","disableDoubleClickZoom","draggable","draggableCursor","draggingCursor","fullscreenControl","fullscreenControlOptions","gestureHandling","headingInteractionEnabled","isFractionalZoomEnabled","keyboardShortcuts","mapTypeControl","mapTypeControlOptions","mapTypeId","maxZoom","minZoom","noClear","panControl","panControlOptions","restriction","rotateControl","rotateControlOptions","scaleControl","scaleControlOptions","scrollwheel","streetView","streetViewControl","streetViewControlOptions","styles","tiltInteractionEnabled","zoomControl","zoomControlOptions"]);function fe(e,t){const n={},i=Object.keys(t);for(const e of i)he.has(e)&&(n[e]=t[e]);!function(e,t){const n=o(void 0);n.current&&q(t,n.current)||(n.current=t),r(e,n.current)}((()=>{e&&e.setOptions(n)}),[n])}function me(){var e;return(null==(e=_(se))?void 0:e.status)||Q}function ge(e){return function(e){return!(!e||"object"!=typeof e)&&"lat"in e&&"lng"in e&&Number.isFinite(e.lat)&&Number.isFinite(e.lng)}(e)?e:e.toJSON()}const be=()=>i.createElement("div",{style:{position:"absolute",top:0,left:0,bottom:0,right:0,zIndex:999,display:"flex",flexFlow:"column nowrap",textAlign:"center",justifyContent:"center",fontSize:".8rem",color:"rgba(0,0,0,0.6)",background:"#dddddd",padding:"1rem 1.5rem"}},i.createElement("h2",null,"Error: AuthFailure"),i.createElement("p",null,"A problem with your API key prevents the map from rendering correctly. Please make sure the value of the ",i.createElement("code",null,"APIProvider.apiKey")," prop is correct. Check the error-message in the console for further details."));function ve(){return me()===te}function ye(e){const t=function(){const[,e]=h((e=>e+1),0);return e}(),n=o({center:{lat:0,lng:0},heading:0,tilt:0,zoom:0});return r((()=>{if(!e)return;const i=google.maps.event.addListener(e,"bounds_changed",(()=>{!function(e,t){const n=e.getCenter(),i=e.getZoom(),a=e.getHeading()||0,o=e.getTilt()||0,r=e.getBounds();n&&r&&Number.isFinite(i)||console.warn("[useTrackedCameraState] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),Object.assign(t.current,{center:(null==n?void 0:n.toJSON())||{lat:0,lng:0},zoom:i||0,heading:a,tilt:o})}(e,n),t()}));return()=>i.remove()}),[e,t]),n}const we=["id","defaultBounds","defaultCenter","defaultZoom","defaultHeading","defaultTilt","reuseMaps","renderingType","colorScheme"],xe=["padding"];class ke{static has(e){return this.entries[e]&&this.entries[e].length>0}static pop(e){return this.entries[e]&&this.entries[e].pop()||null}static push(e,t){this.entries[e]||(this.entries[e]=[]),this.entries[e].push(t)}}function Ne(e,t){const n=ve(),[i,s]=a(null),[c,_]=function(){const[e,t]=a(null);return[e,f((e=>t(e)),[t])]}(),l=ye(i),{id:d,defaultBounds:p,defaultCenter:u,defaultZoom:h,defaultHeading:m,defaultTilt:g,reuseMaps:b,renderingType:v,colorScheme:y}=e,w=Y(e,we),x=void 0!==e.zoom||void 0!==e.defaultZoom,k=void 0!==e.center||void 0!==e.defaultCenter;p||x&&k||console.warn("<Map> component is missing configuration. You have to provide zoom and center (via the `zoom`/`defaultZoom` and `center`/`defaultCenter` props) or specify the region to show using `defaultBounds`. See https://visgl.github.io/react-google-maps/docs/api-reference/components/map#required"),!w.center&&u&&(w.center=u),!w.zoom&&Number.isFinite(h)&&(w.zoom=h),!w.heading&&Number.isFinite(m)&&(w.heading=m),!w.tilt&&Number.isFinite(g)&&(w.tilt=g);for(const e of Object.keys(w))void 0===w[e]&&delete w[e];const N=o(void 0);return r((()=>{if(!c||!n)return;const{addMapInstance:i,removeMapInstance:a}=t,{mapId:o}=e,r=`${o||"default"}:${v||"default"}:${y||"LIGHT"}`;let _,u;if(b&&ke.has(r)?(u=ke.pop(r),_=u.getDiv(),c.appendChild(_),u.setOptions(w),setTimeout((()=>u.setCenter(u.getCenter())),0)):(_=document.createElement("div"),_.style.height="100%",c.appendChild(_),u=new google.maps.Map(_,J({},w,v?{renderingType:v}:{},y?{colorScheme:y}:{}))),s(u),i(u,d),p){const{padding:e}=p,t=Y(p,xe);u.fitBounds(t,e)}else x&&k||u.fitBounds({east:180,west:-180,south:-90,north:90});if(N.current){const{mapId:e,cameraState:t}=N.current;e!==o&&u.setOptions(t)}return()=>{N.current={mapId:o,cameraState:l.current},_.remove(),b?ke.push(r,u):google.maps.event.clearInstanceListeners(u),s(null),a(d)}}),[c,n,d,e.mapId,e.renderingType,e.colorScheme]),[i,_,l]}ke.entries={};const Ce=i.createContext(null),Se=e=>{const{children:t,id:n,className:a,style:o}=e,s=_(se),c=me();if(!s)throw new Error("<Map> can only be used inside an <ApiProvider> component.");const[l,p,u]=Ne(e,s);!function(e,t,n){const i=n.center?ge(n.center):null;let a=null,o=null;i&&Number.isFinite(i.lat)&&Number.isFinite(i.lng)&&(a=i.lat,o=i.lng);const r=Number.isFinite(n.zoom)?n.zoom:null,s=Number.isFinite(n.heading)?n.heading:null,c=Number.isFinite(n.tilt)?n.tilt:null;m((()=>{if(!e)return;const n={};let i=!1;null===a||null===o||t.current.center.lat===a&&t.current.center.lng===o||(n.center={lat:a,lng:o},i=!0),null!==r&&t.current.zoom!==r&&(n.zoom=r,i=!0),null!==s&&t.current.heading!==s&&(n.heading=s,i=!0),null!==c&&t.current.tilt!==c&&(n.tilt=c,i=!0),i&&e.moveCamera(n)}))}(l,u,e),function(e,t){for(const n of ue){const i=t[n],a=le[n];r((()=>{if(!e)return;if(!i)return;const t=google.maps.event.addListener(e,a,(t=>{i(_e(a,e,t))}));return()=>t.remove()}),[e,a,i])}}(l,e),fe(l,e);const h=function(e,t){const{viewport:n,viewState:i}=t,a=!!n;return m((()=>{if(!e||!i)return;const{latitude:t,longitude:n,bearing:a,pitch:o,zoom:r}=i;e.moveCamera({center:{lat:t,lng:n},heading:a,tilt:o,zoom:r+1})}),[e,i]),a}(l,e),f=!!e.controlled;r((()=>{if(l)return h&&l.setOptions({disableDefaultUI:!0}),(h||f)&&l.setOptions({gestureHandling:"none",keyboardShortcuts:!1}),()=>{l.setOptions({gestureHandling:e.gestureHandling,keyboardShortcuts:e.keyboardShortcuts})}}),[l,h,f,e.gestureHandling,e.keyboardShortcuts]);const g=e.center?ge(e.center):null;let b=null,v=null;g&&Number.isFinite(g.lat)&&Number.isFinite(g.lng)&&(b=g.lat,v=g.lng);const y=d((()=>{var t,n,i,a,o;return{center:{lat:null!=(t=b)?t:0,lng:null!=(n=v)?n:0},zoom:null!=(i=e.zoom)?i:0,heading:null!=(a=e.heading)?a:0,tilt:null!=(o=e.tilt)?o:0}}),[b,v,e.zoom,e.heading,e.tilt]);m((()=>{if(!l||!f)return;l.moveCamera(y);const e=l.addListener("bounds_changed",(()=>{l.moveCamera(y)}));return()=>e.remove()}),[l,f,y]);const w=d((()=>J({width:"100%",height:"100%",position:"relative",zIndex:h?-1:0},o)),[o,h]),x=d((()=>({map:l})),[l]);return c===ie?i.createElement("div",{style:J({position:"relative"},a?{}:w),className:a},i.createElement(be,null)):i.createElement("div",J({ref:p,"data-testid":"map",style:a?void 0:w,className:a},n?{id:n}:{}),l?i.createElement(Ce.Provider,{value:x},t):null)};Se.deckGLViewProps=!0;const Te=new Set;const Ae=(e=null)=>{const t=_(se),{map:n}=_(Ce)||{};if(null===t)return function(...e){const t=JSON.stringify(e);Te.has(t)||(Te.add(t),console.error(...e))}("useMap(): failed to retrieve APIProviderContext. Make sure that the <APIProvider> component exists and that the component you are calling `useMap()` from is a sibling of the <APIProvider>."),null;const{mapInstances:i}=t;return null!==e?i[e]||null:n||(i.default||null)};function Oe(e,t,n){r((()=>{if(!e||!t||!n)return;const i=google.maps.event.addListener(e,t,n);return()=>i.remove()}),[e,t,n])}function je(e,t,n){r((()=>{e&&(e[t]=n)}),[e,t,n])}function Pe(e,t,n){r((()=>{if(e&&t&&n)return e.addEventListener(t,n),()=>e.removeEventListener(t,n)}),[e,t,n])}const Ie=i.createContext(null),Le={BOTTOM:["50%","100%"]},Me=({children:e,styles:t,className:n,anchorPoint:a})=>{const[o,r]=null!=a?a:Le.BOTTOM;let s=`-${o}`,c=`-${r}`;o.trimStart().startsWith("-")&&(s=o.substring(1)),r.trimStart().startsWith("-")&&(c=r.substring(1));const _=`translate(50%, 100%) translate(${s}, ${c})`;return i.createElement("div",{style:{transform:_}},i.createElement("div",{className:n,style:t},e))};function Ee(e){const[t,n]=a(null),[i,o]=a(null),s=Ae(),c=function(e){const t=ve(),n=_(se);return r((()=>{t&&n&&n.importLibrary(e)}),[t,n,e]),(null==n?void 0:n.loadedLibraries[e])||null}("marker"),{children:l,onClick:d,className:p,onMouseEnter:h,onMouseLeave:f,onDrag:m,onDragStart:g,onDragEnd:b,collisionBehavior:v,clickable:y,draggable:w,position:x,title:k,zIndex:N}=e,C=u.count(l);return r((()=>{if(!s||!c)return;const e=new c.AdvancedMarkerElement;e.map=s,n(e);let t=null;return C>0&&(t=document.createElement("div"),t.isCustomMarker=!0,e.content=t,o(t)),()=>{var i;e.map=null,null==(i=t)||i.remove(),n(null),o(null)}}),[s,c,C]),r((()=>{!t||!t.content||C>0||(t.content.className=p||"")}),[t,p,C]),je(t,"position",x),je(t,"title",null!=k?k:""),je(t,"zIndex",N),je(t,"collisionBehavior",v),r((()=>{t&&(t.gmpDraggable=void 0!==w?w:!!(m||g||b))}),[t,w,m,b,g]),r((()=>{if(!t)return;const e=void 0!==y||Boolean(d)||Boolean(h)||Boolean(f);t.gmpClickable=e,e&&null!=t&&t.content&&t.content.nodeType===Node.ELEMENT_NODE&&(t.content.style.pointerEvents="none",t.content.firstElementChild&&(t.content.firstElementChild.style.pointerEvents="all"))}),[t,y,d,h,f]),Oe(t,"click",d),Oe(t,"drag",m),Oe(t,"dragstart",g),Oe(t,"dragend",b),Pe(null==t?void 0:t.element,"mouseenter",h),Pe(null==t?void 0:t.element,"mouseleave",f),[t,i]}l(((e,t)=>{const{children:n,style:a,className:o,anchorPoint:r}=e,[s,c]=Ee(e),_=d((()=>s?{marker:s}:null),[s]);return p(t,(()=>s),[s]),c?i.createElement(Ie.Provider,{value:_},g(i.createElement(Me,{anchorPoint:r,styles:a,className:o},n),c)):null}));const Ze=["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut"];const ze=l(((e,t)=>{const n=function(e){const[t,n]=a(null),i=Ae(),{onClick:o,onDrag:s,onDragStart:c,onDragEnd:_,onMouseOver:l,onMouseOut:d}=e,p=Y(e,Ze),{position:u,draggable:h}=p;return r((()=>{if(!i)return void(void 0===i&&console.error("<Marker> has to be inside a Map component."));const e=new google.maps.Marker(p);return e.setMap(i),n(e),()=>{e.setMap(null),n(null)}}),[i]),r((()=>{if(!t)return;const e=t,n=google.maps.event;return o&&n.addListener(e,"click",o),s&&n.addListener(e,"drag",s),c&&n.addListener(e,"dragstart",c),_&&n.addListener(e,"dragend",_),l&&n.addListener(e,"mouseover",l),d&&n.addListener(e,"mouseout",d),t.setDraggable(Boolean(h)),()=>{n.clearInstanceListeners(e)}}),[t,h,o,s,c,_,l,d]),r((()=>{t&&p&&t.setOptions(p)}),[t,p]),r((()=>{!h&&u&&t&&t.setPosition(u)}),[h,u,t]),t}(e);return p(t,(()=>n),[n]),i.createElement(i.Fragment,null)}));function Re({notification:e,width:n,height:i}){const{googleMapsAPIKey:o}=N().options,s=function(e){const t=[];return e.content.forEach((e=>{t.push({title:e.data.title,latitude:e.data.latitude,longitude:e.data.longitude})})),t}(e).map(((e,t)=>({id:t,lat:e.latitude,lng:e.longitude,title:e.title}))),[c,_]=a(!1),l=d((()=>s.length>0?{lat:s[0].lat,lng:s[0].lng}:{lat:0,lng:0}),[s]);return r((()=>{_(!0)}),[]),0!==s.length&&c?t("div",{"data-testid":"map-notification",children:t(ce,{apiKey:o||"",children:t(De,{markers:s,center:l,width:n,height:i})})}):t(O,{})}function De({markers:n,center:i,width:a,height:o}){const r=me();return e("div",{style:{width:a,height:o,backgroundColor:"white",position:"relative",overflow:"hidden"},children:[r===ee&&t(O,{}),r===ie&&t(j,{message:"Authentication failure. Your Google Maps API key might be invalid. Check console for more information."}),r===ne&&t(j,{message:"Google Maps failed to be loaded. Check console for more information."}),r===te&&t(Se,{style:{width:a,height:o},defaultCenter:i,defaultZoom:10,gestureHandling:"greedy",disableDefaultUI:!0,children:n.map((e=>t(ze,{position:{lat:e.lat,lng:e.lng},title:e.title},e.id)))})]})}function $e({notification:n,appName:i}){return e("div",{"data-testid":"android-app-ui-map-notification",children:[t(I,{appName:i,showOptions:E(n)}),t(Re,{notification:n,width:"100%",height:"570px"})]})}function Fe({notification:n,appName:i,appAndroidPackageName:a}){return e("div",{"data-testid":"android-app-ui-rate-notification",children:[t(I,{appName:i,title:n.title,showOptions:!1}),t(P,{url:`https://play.google.com/store/apps/details?id=${a}&hl=en`,platform:"Android",width:338,height:570})]})}v("");function Ve({notification:n,appName:i,appIcon:a}){var o;return t("div",{className:"notificare__push__android__alert__app-ui","data-testid":"android-app-ui-text-alert-notification",children:e("div",{className:"notificare__push__android__alert__app-ui__wrapper",children:[e("div",{className:"notificare__push__android__alert__app-ui__header",children:[t("div",{className:"notificare__push__android__alert__app-ui__app-icon",children:t("img",{className:"notificare__push__android__alert__app-ui__app-icon-image",alt:"App icon",src:a})}),t("p",{className:"notificare__push__android__alert__app-ui__title",children:n.title||i})]}),t("p",{className:"notificare__push__android__alert__app-ui__message",children:n.message}),E(n)&&e("div",{className:"notificare__push__android__alert__app-ui__actions",children:[null===(o=n.actions)||void 0===o?void 0:o.map(((e,n)=>t("p",{className:"notificare__push__android__alert__app-ui__action-label","data-testid":`android-app-ui-text-alert-notification-action-${n}`,children:e.label},n))),t("p",{className:"notificare__push__android__alert__app-ui__cancel-label",children:"Cancel"},"cancel-button-label")]})]})})}v(".notificare .notificare__push__android__alert__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__android__alert__app-ui__wrapper {\n position: relative;\n background-color: #fff;\n width: 290px;\n border-radius: 2px;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n/* Header - App Icon and Title */\n\n.notificare .notificare__push__android__alert__app-ui__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n width: 32px;\n height: 32px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__android__alert__app-ui__app-icon-image {\n width: 100%;\n}\n\n.notificare .notificare__push__android__alert__app-ui__header {\n display: flex;\n align-items: center;\n column-gap: 10px;\n padding: 20px 20px 0;\n}\n\n.notificare .notificare__push__android__alert__app-ui__title {\n font-weight: 700;\n font-size: 18px;\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 208px;\n}\n\n/* Message */\n\n.notificare .notificare__push__android__alert__app-ui__message {\n font-size: 16px;\n margin-top: 20px;\n margin-bottom: 0;\n word-break: break-all;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 8;\n padding: 0 20px 20px;\n}\n\n/* Actions */\n\n.notificare .notificare__push__android__alert__app-ui__actions {\n border-top: 1px solid #f2f4f6;\n}\n\n.notificare .notificare__push__android__alert__app-ui__action-label {\n font-size: 14px;\n font-weight: 600;\n padding: 15px 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__alert__app-ui__cancel-label {\n font-size: 14px;\n font-weight: 600;\n color: #64706e;\n padding: 15px 20px 20px;\n}");function Be(e,t){return b(this,void 0,void 0,(function*(){try{const n=new URLSearchParams({apiKey:e,url:t});return(yield fetch(`https://push.notifica.re/proxy/?${n.toString()}`)).text()}catch(e){return console.error("Error fetching website",e),""}}))}function Ue(e){const t=(new DOMParser).parseFromString(e,"text/html").querySelectorAll("a");let n=!1;return t.forEach((e=>{new URL(e.href,window.location.origin).searchParams.has("notificareOpenAction")&&(n=!0)})),n}function Ke({notification:n,appName:i}){const o=n.content[0].data,[s,c]=a(""),{serviceKey:_}=N().options;return r((()=>{(()=>{b(this,void 0,void 0,(function*(){c(yield Be(_,o))}))})()}),[]),e("div",{"data-testid":"android-app-ui-url-notification",children:[t(I,{appName:i,title:n.title,showOptions:E(n)&&!Ue(s)}),t(P,{url:o,platform:"Android",width:338,height:570})]})}v("");v("");function We({videoData:e,width:n,height:i}){const a=()=>{switch(e.type){case"re.notifica.content.YouTube":return`https://www.youtube.com/embed/${e.data}`;case"re.notifica.content.Vimeo":return`https://player.vimeo.com/video/${e.data}`;case"re.notifica.content.HTML5Video":return e.data;default:return""}};return"re.notifica.content.YouTube"===e.type||"re.notifica.content.Vimeo"===e.type?t("iframe",{className:"notificare__push__video-rich-content",src:a(),sandbox:"allow-scripts allow-same-origin",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",width:n,height:i}):t("video",{className:"notificare__push__video-rich-content",width:n,height:i,autoPlay:!0,controls:!0,children:t("source",{src:a(),type:"video/mp4"})})}function Ge(n){const{notification:i,appName:a}=n;return e("div",{"data-testid":"android-app-ui-video-notification",children:[t(I,{appName:a,title:i.title,showOptions:E(i)}),t(We,{videoData:i.content[0],width:"100%",height:"570px"})]})}v(".notificare .notificare__push__video-rich-content {\n border: 0;\n background-color: #fff;\n}");function He(n){const{notification:i,appName:a}=n,o=i.content[0].data;return e("div",{"data-testid":"android-app-ui-web-view-notification",children:[t(I,{appName:a,title:i.title,showOptions:E(i)&&!Ue(o)}),t("iframe",{className:"notificare__push__android__web-view__app-ui__content",srcDoc:o,sandbox:"allow-same-origin"})]})}function qe({notification:n,application:i,mobileVariant:a}){const{googleMapsAPIKey:o}=N().options;return"re.notifica.notification.Map"!==n.type||o||"app-ui"!==a?t(T,{theme:Je(n.type,a),children:e("div",{className:"notificare__push__android__preview",children:[("lockscreen"===a||"lockscreen-expanded"===a)&&t(K,{notification:n,appName:i.name,appIcon:S(i.websitePushConfig.icon),expanded:"lockscreen-expanded"===a}),"app-ui"===a&&(()=>{switch(n.type){case"re.notifica.notification.Alert":return t(Ve,{notification:n,appName:i.name,appIcon:S(i.websitePushConfig.icon)});case"re.notifica.notification.WebView":return t(He,{notification:n,appName:i.name});case"re.notifica.notification.URL":return t(Ke,{notification:n,appName:i.name});case"re.notifica.notification.InAppBrowser":return t(U,{notification:n,appName:i.name});case"re.notifica.notification.Image":return t($,{notification:n,appName:i.name});case"re.notifica.notification.Map":return t($e,{notification:n,appName:i.name});case"re.notifica.notification.Rate":return t(Fe,{notification:n,appName:i.name,appAndroidPackageName:i.androidPackageName});case"re.notifica.notification.Passbook":return t(D,{notification:n,appName:i.name});case"re.notifica.notification.Video":return t(Ge,{notification:n,appName:i.name});case"re.notifica.notification.Store":return t(L,{notification:n,appName:i.name})}})()]})}):t(A,{message:"→ A Google Maps API key should be provided",showConsoleWarning:!1})}function Je(e,t){if("app-ui"!==t)return"light";return["re.notifica.notification.Alert"].includes(e)?"dark":"light"}v(".notificare .notificare__push__android__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 570px;\n background-color: #fff;\n}");v(".notificare .notificare__push__ios__preview {\n font-family: -apple-system, BlinkMacSystemFont, sans-serif;\n height: 100%;\n}");function Ye({children:n,theme:i}){return e("div",{className:"notificare__push__ios__phone-background "+("dark"===i?"notificare__push__ios__phone-background--dark":""),"data-testid":"ios-phone-background",children:[t("div",{className:"notificare__push__ios__phone-background-camera"}),t("div",{className:"notificare__push__ios__phone-background-content",children:n})]})}v(".notificare .notificare__push__ios__phone-background {\n width: 350px;\n border-radius: 40px;\n border: 6px solid #c6c6c6;\n background-color: #fff;\n overflow: hidden;\n}\n\n.notificare .notificare__push__ios__phone-background--dark {\n background-color: #9ea2a1;\n border-color: #eaeaea;\n}\n\n.notificare .notificare__push__ios__phone-background-camera {\n width: 80px;\n height: 20px;\n background: #c6c6c6;\n margin: 20px auto 10px;\n border-radius: 20px;\n}\n\n.notificare .notificare__push__ios__phone-background-content {\n width: 100%;\n height: 615px;\n overflow: hidden;\n position: relative;\n}");v("/* Top Bar */\n\n.notificare .notificare__push__ios__store__app-ui__bar {\n display: flex;\n width: 100%;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n font-size: 14px;\n font-weight: 700;\n padding: 11px 15px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n background-color: #fff;\n margin-top: 10px;\n}\n\n/* --- App Recommendation Content --- */\n\n.notificare .notificare__push__ios__store__app-ui {\n height: 566px;\n background-color: #fff;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page {\n width: 100%;\n overflow: hidden;\n}\n\n/* Header */\n\n.notificare .notificare__push__ios__store__app-ui__page-header {\n width: 100%;\n padding: 15px;\n display: flex;\n column-gap: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__app-icon {\n width: 90px;\n height: 90px;\n border-radius: 15px;\n overflow: hidden;\n flex-shrink: 0;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-info {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-name {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-category {\n font-size: 12px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-install {\n font-size: 11px;\n font-weight: 700;\n text-transform: uppercase;\n padding: 7px 12px;\n background: #3b82f6;\n color: #fff;\n border-radius: 15px;\n width: max-content;\n}\n\n/* Other info */\n\n.notificare .notificare__push__ios__store__app-ui__page-other-app-info-wrapper {\n padding: 0 15px;\n width: calc(100% - 15px);\n overflow: hidden;\n position: relative;\n margin-bottom: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-other-app-info {\n display: flex;\n width: 1000px;\n border-bottom: 1px solid #f2f4f6;\n border-top: 1px solid #f2f4f6;\n position: relative;\n box-sizing: border-box;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block {\n padding: 5px;\n width: 85px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-title {\n font-size: 10px;\n font-weight: 600;\n text-transform: uppercase;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-value {\n font-size: 30px;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-icon {\n height: 18px;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-bottom-text {\n font-size: 11px;\n text-align: center;\n}\n\n/* History */\n\n.notificare .notificare__push__ios__store__app-ui__page-history {\n margin: 0 15px;\n border-bottom: 1px solid #f2f4f6;\n padding-bottom: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-title {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-version-last-update {\n display: flex;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-version {\n font-size: 12px;\n color: #64706e;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-last-update {\n font-size: 11px;\n color: #64706e;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-notes {\n margin-top: 5px;\n font-size: 12px;\n max-height: 60px;\n overflow: hidden;\n display: -webkit-box;\n -webkit-line-clamp: 3;\n -webkit-box-orient: vertical;\n padding-right: 5px;\n word-break: break-word;\n}\n\n/* Previews */\n\n.notificare .notificare__push__ios__store__app-ui__page-previews {\n margin-top: 15px;\n padding: 0 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-previews-title {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-previews-images {\n display: flex;\n max-height: 400px;\n overflow: hidden;\n column-gap: 8px;\n margin-top: 10px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-preview-image {\n border-radius: 15px;\n width: 150px;\n}");function Xe(e){const{rating:n}=e,i=[];for(let e=1;e<=5;e++)e<=n?i.push(t(Qe,{},e)):e-.5<=n?i.push(t(et,{},e)):i.push(t(tt,{},e));return t("div",{className:"notificare__push__ios__store__app-ui__star-rating",children:i})}v(".notificare .notificare__push__ios__store__app-ui__star-rating {\n display: inline-flex;\n flex-grow: 0;\n position: relative;\n}");const Qe=()=>t("svg",{width:"10px",height:"10px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{d:"M316.9 18C311.6 7 300.4 0 288.1 0s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329 113.2 474.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329 542.7 225.9c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7L381.2 150.3 316.9 18z"})}),et=()=>e("svg",{width:"10px",height:"10px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:[t("defs",{children:e("linearGradient",{id:"halfGrad",children:[t("stop",{offset:"50%",stopColor:"#1e3050"}),t("stop",{offset:"50%",stopColor:"#ccc"})]})}),t("path",{fill:"url(#halfGrad)",d:"M316.9 18C311.6 7 300.4 0 288.1 0s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329 113.2 474.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329 542.7 225.9c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7L381.2 150.3 316.9 18z"})]}),tt=()=>t("svg",{width:"10px",height:"10px",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{fill:"#EAEAEA",d:"M316.9 18C311.6 7 300.4 0 288.1 0s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329 113.2 474.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329 542.7 225.9c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7L381.2 150.3 316.9 18z"})});function nt({notification:n}){const i=n.content[0],[o,s]=a(!1),[c,_]=a(),[l,d]=a(!1);return r((()=>{(()=>{b(this,void 0,void 0,(function*(){if(d(!0),"re.notifica.content.AppStore"===i.type&&"string"!=typeof i.data)try{const e=yield fetch(`https://itunes.apple.com/lookup?country=GB&id=${i.data.identifier}`),t=yield e.json();_(t),0===(null==c?void 0:c.resultCount)&&s(!0)}catch(e){s(!0)}else s(!0);d(!1)}))})()}),[i.data]),e("div",{"data-testid":"ios-app-ui-app-recommendation-notification",children:[t("div",{className:"notificare__push__ios__store__app-ui__bar",children:"Done"}),t("div",{className:"notificare__push__ios__store__app-ui",children:o?t(j,{}):l?t(O,{}):c&&e("div",{className:"notificare__push__ios__store__app-ui__page",children:[e("div",{className:"notificare__push__ios__store__app-ui__page-header",children:[t("img",{src:c.results[0].artworkUrl512,className:"notificare__push__ios__store__app-ui__app-icon",alt:"App icon"}),e("div",{className:"notificare__push__ios__store__app-ui__page-app-info",children:[e("div",{children:[t("p",{className:"notificare__push__ios__store__app-ui__page-app-name",children:c.results[0].trackName}),t("p",{className:"notificare__push__ios__store__app-ui__page-app-category",children:c.results[0].primaryGenreName})]}),t("div",{className:"notificare__push__ios__store__app-ui__page-install",children:"Install"})]})]}),t("div",{className:"notificare__push__ios__store__app-ui__page-other-app-info-wrapper",children:e("div",{className:"notificare__push__ios__store__app-ui__page-other-app-info",children:[e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[e("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:[at(c.results[0].userRatingCount)," RATINGS"]}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-value",children:c.results[0].averageUserRating.toFixed(1)}),t(Xe,{rating:c.results[0].averageUserRating})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:"AGE"}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-value",children:c.results[0].trackContentRating}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:"Years Old"})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:"CATEGORY"}),t("svg",{className:"notificare__push__ios__store__app-ui__page-info-block-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",children:t("path",{d:"M264.5 5.2c14.9-6.9 32.1-6.9 47 0l218.6 101c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 149.8C37.4 145.8 32 137.3 32 128s5.4-17.9 13.9-21.8L264.5 5.2zM476.9 209.6l53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 277.8C37.4 273.8 32 265.3 32 256s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0l152-70.2zm-152 198.2l152-70.2 53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 405.8C37.4 401.8 32 393.3 32 384s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0z"})}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:c.results[0].primaryGenreName})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:"DEVELOPER"}),t("svg",{className:"notificare__push__ios__store__app-ui__page-info-block-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M399 384.2C376.9 345.8 335.4 320 288 320l-64 0c-47.4 0-88.9 25.8-111 64.2c35.2 39.2 86.2 63.8 143 63.8s107.8-24.7 143-63.8zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zm256 16a72 72 0 1 0 0-144 72 72 0 1 0 0 144z"})}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:c.results[0].sellerName})]})]})}),e("div",{className:"notificare__push__ios__store__app-ui__page-history",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-history-title",children:"What's New"}),e("div",{className:"notificare__push__ios__store__app-ui__page-history-version-last-update",children:[e("p",{className:"notificare__push__ios__store__app-ui__page-history-version",children:["Version ",c.results[0].version]}),t("p",{className:"notificare__push__ios__store__app-ui__page-history-last-update",children:it(c.results[0].currentVersionReleaseDate)})]}),t("p",{className:"notificare__push__ios__store__app-ui__page-history-notes",children:c.results[0].releaseNotes})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-previews",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-previews-title",children:"Preview"}),e("div",{className:"notificare__push__ios__store__app-ui__page-previews-images",children:[t("img",{src:c.results[0].screenshotUrls[0],className:"notificare__push__ios__store__app-ui__page-preview-image",alt:"App preview"}),t("img",{src:c.results[0].screenshotUrls[1],className:"notificare__push__ios__store__app-ui__page-preview-image",alt:"App preview"})]})]})]})})]})}function it(e){var t;const n=new Date(e),i=new Date,a=Math.floor((i.getTime()-n.getTime())/1e3),o=[{value:60,label:"second"},{value:3600,label:"minute"},{value:86400,label:"hour"},{value:604800,label:"day"},{value:2592e3,label:"week"},{value:31536e3,label:"month"},{value:1/0,label:"year"}];for(let e=0;e<o.length;e++){const{value:n,label:i}=o[e];if(a<n){const n=Math.floor(a/((null===(t=o[e-1])||void 0===t?void 0:t.value)||1));return n<=1?`a ${i} ago`:`${n} ${i}s ago`}}return"a long time ago"}function at(e){return e>=1e6?(e/1e6).toFixed(1)+"M":e>=1e3?(e/1e3).toFixed(1)+"K":e.toString()}v("");function ot({appName:n,title:i,showOptions:a}){return e("div",{className:"notificare__push__ios__app-ui__title-bar",children:[t("div",{className:"notificare__push__ios__app-ui__title-bar-text",children:i||n}),a&&t("svg",{className:"notificare__push__ios__app-ui__title-bar-options-button",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512","data-testid":"ios-app-ui-title-bar-options-button",children:t("path",{d:"M8 256a56 56 0 1 1 112 0A56 56 0 1 1 8 256zm160 0a56 56 0 1 1 112 0 56 56 0 1 1 -112 0zm216-56a56 56 0 1 1 0 112 56 56 0 1 1 0-112z"})})]})}function rt({notification:n,appName:i}){return e("div",{"data-testid":"ios-app-ui-passbook-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)}),t(P,{url:`https://push.notifica.re/pass/web/${n.content[0].data.split("/")[5]}`,platform:"Web",width:338,height:566})]})}v(".notificare .notificare__push__ios__app-ui__title-bar {\n display: flex;\n align-items: center;\n width: 100%;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n background-color: #fff;\n margin-top: 10px;\n position: relative;\n}\n\n.notificare .notificare__push__ios__app-ui__title-bar-text {\n padding: 11px 25px;\n font-size: 14px;\n font-weight: 700;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n max-width: 255px;\n position: relative;\n left: 50%;\n transform: translateX(-50%);\n}\n\n.notificare .notificare__push__ios__app-ui__title-bar-options-button {\n width: 20px;\n margin-left: auto;\n margin-right: 12px;\n}");function st({notification:n,appName:i}){return e("div",{"data-testid":"ios-app-ui-images-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)}),t("div",{className:"notificare__push__ios__image__app-ui__rich-content",children:t("div",{className:"notificare__push__ios__image__app-ui__slider",children:n.content.map(((e,n)=>t("img",{className:"notificare__push__ios__image__app-ui__slider-item",src:e.data,alt:"Slider image"},n)))})})]})}v(".notificare .notificare__push__ios__image__app-ui__rich-content {\n display: flex;\n align-items: center;\n width: 100%;\n height: 566px;\n background-color: white;\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scrollbar-width: none; /* Hide in Firefox */\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider::-webkit-scrollbar {\n display: none; /* Hide in Chrome and Safari */\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}");v("");function ct(i){const{url:a}=i;return e("div",{className:"notificare__push__ios__in-app-browser__app-ui__bar",children:[t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-done-button",children:" Done "}),e("div",{className:"notificare__push__ios__in-app-browser__app-ui__bar-domain",children:[V(a)?t(n,{children:t("svg",{className:"notificare__push__ios__in-app-browser__app-ui__bar-lock-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",children:t("path",{d:"M144 144l0 48 160 0 0-48c0-44.2-35.8-80-80-80s-80 35.8-80 80zM80 192l0-48C80 64.5 144.5 0 224 0s144 64.5 144 144l0 48 16 0c35.3 0 64 28.7 64 64l0 192c0 35.3-28.7 64-64 64L64 512c-35.3 0-64-28.7-64-64L0 256c0-35.3 28.7-64 64-64l16 0z"})})}):t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-not-secure",children:"Not Secure —"}),t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-url",children:F(a)})]})]})}function _t({notification:n}){const i=n.content[0].data;return e("div",{"data-testid":"ios-app-ui-in-app-browser-notification",children:[t(ct,{url:i}),t(P,{url:i,platform:"iOS",width:338,height:564})]})}v(".notificare .notificare__push__ios__in-app-browser__app-ui__bar {\n display: flex;\n width: 100%;\n padding: 12px 0;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n margin-top: 10px;\n background-color: #fff;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-done-button {\n font-size: 14px;\n font-weight: 700;\n position: absolute;\n left: 0;\n margin-left: 15px;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-lock-icon {\n height: 14px;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-domain {\n display: flex;\n column-gap: 5px;\n font-size: 14px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-not-secure {\n color: #64706e;\n font-weight: 400;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-url {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}");function lt(n){var i,a;const{notification:o,appName:r,appIcon:s,expanded:c}=n;return e("div",{className:"notificare__push__ios__lock-screen","data-testid":"ios-lock-screen-notification",children:[e("div",{className:"notificare__push__ios__lock-screen__main-content",children:[t("div",{className:"notificare__push__ios__lock-screen__app-icon",children:t("img",{className:"notificare__push__ios__lock-screen__app-icon-image",alt:"App icon",src:s})}),e("div",{className:"notificare__push__ios__lock-screen__text-content",children:[e("div",{className:"notificare__push__ios__lock-screen__title-and-time",children:[t("p",{className:"notificare__push__ios__lock-screen__text "+(c?"notificare__push__ios__lock-screen__text--expanded-title-or-subtitle":"notificare__push__ios__lock-screen__text--title-or-subtitle"),children:o.title||r}),t("p",{className:"notificare__push__ios__lock-screen__text notificare__push__ios__lock-screen__text--time",children:"Now"})]}),o.subtitle&&t("p",{className:"notificare__push__ios__lock-screen__text "+(c?"notificare__push__ios__lock-screen__text--expanded-title-or-subtitle":"notificare__push__ios__lock-screen__text--title-or-subtitle"),children:o.subtitle}),e("div",{className:"notificare__push__ios__lock-screen__message-and-media",children:[t("p",{className:"notificare__push__ios__lock-screen__text "+(R(o)&&!c?"notificare__push__ios__lock-screen__text--message-with-media":"notificare__push__ios__lock-screen__text--message-without-media"),children:o.message}),R(o)&&!c&&t("img",{className:"notificare__push__ios__lock-screen__media-image",src:null===(i=o.attachments)||void 0===i?void 0:i[0].uri,alt:"Media icon","data-testid":"ios-lock-screen-notification-media"})]})]})]}),R(o)&&c&&t("img",{className:"notificare__push__ios__lock-screen__expanded-media",src:null===(a=o.attachments)||void 0===a?void 0:a[0].uri,alt:"Media icon","data-testid":"ios-lock-screen-notification-expanded-media"})]})}v(".notificare .notificare__push__ios__lock-screen {\n position: absolute;\n font-family: -apple-system, BlinkMacSystemFont, sans-serif;\n left: 50%;\n transform: translateX(-50%);\n bottom: 80px;\n background-color: #f2f4f6;\n width: 315px;\n border-radius: 20px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__ios__lock-screen__main-content {\n width: 100%;\n display: flex;\n align-items: center;\n column-gap: 11px;\n padding: 10px;\n}\n\n/* App Icon */\n\n.notificare .notificare__push__ios__lock-screen__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 10px;\n width: 35px;\n height: 35px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__ios__lock-screen__app-icon-image {\n width: 100%;\n}\n\n/* Text Content */\n\n.notificare .notificare__push__ios__lock-screen__text-content {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n width: 249px;\n}\n\n.notificare .notificare__push__ios__lock-screen__title-and-time {\n display: flex;\n column-gap: 5px;\n margin-top: 0;\n margin-bottom: 0;\n position: relative;\n width: 100%;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__lock-screen__text {\n font-size: 13px;\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--title-or-subtitle {\n font-weight: 700;\n width: 218px;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--expanded-title-or-subtitle {\n font-weight: 700;\n width: 218px;\n white-space: wrap;\n word-break: break-word;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--time {\n color: #64706e;\n font-size: 12px;\n text-align: right;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--message-without-media {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n -webkit-line-clamp: 4;\n width: 242px;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--message-with-media {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n -webkit-line-clamp: 4;\n width: 210px;\n}\n\n/* Media */\n\n.notificare .notificare__push__ios__lock-screen__message-and-media {\n display: flex;\n column-gap: 7px;\n}\n\n.notificare .notificare__push__ios__lock-screen__media-image {\n border-radius: 5px;\n object-fit: cover;\n width: 32px;\n height: 32px;\n align-self: flex-start;\n justify-self: flex-end;\n}\n\n.notificare .notificare__push__ios__lock-screen__expanded-media {\n object-fit: cover;\n width: 100%;\n max-height: 275px;\n overflow: hidden;\n display: block;\n}\n");function dt({notification:n,appName:i}){return e("div",{"data-testid":"ios-app-ui-map-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)}),t(Re,{notification:n,width:"100%",height:"566px"})]})}v("");function pt({appName:n,title:i}){return t("div",{className:"notificare__push__ios__rate__app-ui","data-testid":"ios-app-ui-rate-notification",children:e("div",{className:"notificare__push__ios__rate__app-ui__wrapper",children:[t("p",{className:"notificare__push__ios__rate__app-ui__header",children:i||n}),t("div",{className:"notificare__push__ios__rate__app-ui__action",children:"Yes, I'll Rate Now"}),t("div",{className:"notificare__push__ios__rate__app-ui__action",children:"No, Thanks"})]})})}v(".notificare .notificare__push__ios__rate__app-ui {\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__ios__rate__app-ui__wrapper {\n width: 300px;\n background: #fff;\n border-radius: 20px;\n overflow: hidden;\n border: 1px solid #f2f4f6;\n}\n\n/* Header */\n\n.notificare .notificare__push__ios__rate__app-ui__header {\n padding: 20px;\n font-size: 16px;\n font-weight: 700;\n text-align: center;\n word-break: break-word;\n}\n\n/* Actions */\n\n.notificare .notificare__push__ios__rate__app-ui__action {\n padding: 10px 20px;\n text-align: center;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n border-top: 1px solid #f2f4f6;\n font-size: 14px;\n font-weight: 700;\n}");function ut({notification:n,appName:i}){var a,o;return t("div",{className:"notificare__push__ios__alert__app-ui","data-testid":"ios-app-ui-text-alert-notification",children:e("div",{className:"notificare__push__ios__alert__app-ui__background",children:[e("div",{className:"notificare__push__ios__alert__app-ui__title-and-message",children:[t("p",{className:"notificare__push__ios__alert__app-ui__title",children:n.title||i}),t("p",{className:"notificare__push__ios__alert__app-ui__message",children:n.message})]}),t("div",{className:"notificare__push__ios__alert__app-ui__actions",children:Z(n)?e("div",{className:"notificare__push__ios__alert__app-ui__actions-single",children:[t("div",{className:"notificare__push__ios__alert__app-ui__single-cancel",children:"Cancel"}),t("div",{className:"notificare__push__ios__alert__app-ui__action notificare__push__ios__alert__app-ui__action--single","data-testid":"ios-app-ui-text-alert-notification-single-action",children:null===(a=n.actions)||void 0===a?void 0:a[0].label})]}):z(n)?e("div",{className:"notificare__push__ios__alert__app-ui__actions-multiple",children:[null===(o=n.actions)||void 0===o?void 0:o.map(((e,n)=>t("div",{className:"notificare__push__ios__alert__app-ui__action notificare__push__ios__alert__app-ui__action--multiple","data-testid":`ios-app-ui-text-alert-notification-action-${n}`,children:e.label},n))),t("div",{className:"notificare__push__ios__alert__app-ui__multiple-cancel",children:"Cancel"})]}):t("div",{className:"notificare__push__ios__alert__app-ui__no-actions",children:"OK"})})]})})}v(".notificare .notificare__push__ios__alert__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__background {\n width: 300px;\n background: #fff;\n border-radius: 20px;\n overflow: hidden;\n border: 1px solid #f2f4f6;\n}\n\n/* Header - Title and Message */\n\n.notificare .notificare__push__ios__alert__app-ui__title-and-message {\n padding: 20px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n word-break: break-word;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__title {\n font-size: 16px;\n font-weight: 700;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__message {\n margin-top: 3px;\n font-size: 12px;\n font-weight: 500;\n text-align: center;\n}\n\n/* --- Actions --- */\n\n.notificare .notificare__push__ios__alert__app-ui__actions {\n font-size: 14px;\n font-weight: 700;\n border-top: 1px solid #f2f4f6;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action {\n padding: 10px 20px;\n text-align: center;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n/* Single Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__actions-single {\n display: flex;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__single-cancel {\n padding: 10px 20px;\n border-right: 1px solid #f2f4f6;\n width: 50%;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action--single {\n width: 50%;\n}\n\n/* Multiple Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__actions-multiple {\n display: flex;\n flex-direction: column;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__multiple-cancel {\n padding: 10px 20px;\n width: 100%;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action--multiple {\n width: 100%;\n border-bottom: 1px solid #f2f4f6;\n}\n\n/* No Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__no-actions {\n width: 100%;\n text-align: center;\n padding: 10px 20px;\n}");function ht({notification:n,appName:i}){const o=n.content[0].data,[s,c]=a(""),{serviceKey:_}=N().options;return r((()=>{(()=>{b(this,void 0,void 0,(function*(){c(yield Be(_,o))}))})()}),[]),e("div",{"data-testid":"ios-app-ui-url-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)&&!Ue(s)}),t(P,{url:o,platform:"iOS",width:338,height:566})]})}v("");function ft({notification:n,appName:i}){const a=n.content[0];return e("div",{"data-testid":"ios-app-ui-video-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)}),t(We,{videoData:a,width:"100%",height:"566px"})]})}v("");function mt({notification:n,appName:i}){const a=n.content[0].data;return e("div",{"data-testid":"ios-app-ui-web-view-notification",children:[t(ot,{appName:i,title:n.title,showOptions:E(n)&&!Ue(a)}),t("iframe",{className:"notificare__push__ios__web-view__app-ui__content",srcDoc:a,sandbox:"allow-same-origin"})]})}function gt({notification:n,application:i,mobileVariant:a}){const{googleMapsAPIKey:o}=N().options;return"re.notifica.notification.Map"!==n.type||o||"app-ui"!==a?t(Ye,{theme:bt(n.type,a),children:e("div",{className:"notificare__push__ios__preview",children:[("lockscreen"===a||"lockscreen-expanded"===a)&&t(lt,{notification:n,appName:i.name,appIcon:S(i.websitePushConfig.icon),expanded:"lockscreen-expanded"===a}),"app-ui"===a&&(()=>{switch(n.type){case"re.notifica.notification.Alert":return t(ut,{notification:n,appName:i.name});case"re.notifica.notification.WebView":return t(mt,{notification:n,appName:i.name});case"re.notifica.notification.URL":return t(ht,{notification:n,appName:i.name});case"re.notifica.notification.InAppBrowser":return t(_t,{notification:n});case"re.notifica.notification.Image":return t(st,{notification:n,appName:i.name});case"re.notifica.notification.Map":return t(dt,{notification:n,appName:i.name});case"re.notifica.notification.Rate":return t(pt,{title:n.title,appName:i.name});case"re.notifica.notification.Passbook":return t(rt,{notification:n,appName:i.name});case"re.notifica.notification.Video":return t(ft,{notification:n,appName:i.name});case"re.notifica.notification.Store":return t(nt,{notification:n})}})()]})}):t(A,{message:"→ A Google Maps API key should be provided",showConsoleWarning:!1})}function bt(e,t){if("app-ui"!==t)return"light";return["re.notifica.notification.Alert","re.notifica.notification.WebView","re.notifica.notification.URL","re.notifica.notification.InAppBrowser","re.notifica.notification.Image","re.notifica.notification.Rate","re.notifica.notification.Passbook","re.notifica.notification.Video","re.notifica.notification.Store","re.notifica.notification.Map"].includes(e)?"dark":"light"}v(".notificare .notificare__push__ios__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 566px;\n background-color: #fff;\n}");v("/* Preview Wrapper */\n\n.notificare .notificare__push__web__desktop__lock-screen {\n position: relative;\n background-color: #f4f4f4;\n width: 340px;\n border-radius: 15px;\n border: 1px solid #e4e4e4;\n box-shadow: 1px 1px 10px rgba(0, 0, 0, 0.1);\n transition: height 0.3s ease-in-out;\n align-self: start;\n}\n\n/* Expand Button */\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button-container {\n position: absolute;\n top: 8px;\n right: 8px;\n animation: fadeIn 0.5s ease-out forwards;\n}\n\n/* --- MAIN CONTENT --- */\n\n.notificare .notificare__push__web__desktop__lock-screen__main-content {\n width: 100%;\n display: flex;\n flex-direction: row;\n column-gap: 10px;\n padding: 14px;\n}\n\n/* Browser Icon */\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon-background {\n background-color: #ffffff;\n border-radius: 10px;\n padding: 4px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon-image {\n width: 30px;\n}\n\n/* Text */\n\n.notificare .notificare__push__web__desktop__lock-screen__text-content {\n width: 219px;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text {\n font-size: 14px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n margin-top: 0;\n margin-bottom: 0;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--title {\n font-weight: 700;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--domain {\n font-weight: 700;\n margin-top: 2px;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--message {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n margin-top: 2px;\n -webkit-line-clamp: 3;\n line-height: 1.2;\n transition: height 0.3s ease-in-out;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--expandable-message {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n margin-top: 2px;\n line-height: 1.2;\n transition: height 0.3s ease-in-out;\n}\n\n/* Small Media */\n\n.notificare .notificare__push__web__desktop__lock-screen__small-media {\n position: absolute;\n display: flex;\n justify-content: flex-end;\n width: 38px;\n height: 38px;\n border-radius: 25%;\n object-fit: cover;\n animation: fadeIn 0.5s ease-out forwards;\n right: 14px;\n bottom: 10px;\n}\n\n/* Expanded Media */\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-media {\n width: 100%;\n display: block;\n}\n\n/* Time */\n\n.notificare .notificare__push__web__desktop__lock-screen__time-container {\n position: absolute;\n top: 8px;\n right: 14px;\n animation: fadeIn 0.5s ease-out forwards;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__time {\n font-size: 12px;\n color: #64706e;\n}\n\n/* SETTINGS */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button-container {\n position: absolute;\n bottom: 10px;\n right: 14px;\n z-index: 10;\n}\n\n/* Settings Button */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button {\n min-width: 70px;\n display: flex;\n background-color: #d6d6d6;\n border-radius: 7px;\n border: 0;\n padding: 5px 10px 5px;\n font-size: 13px;\n justify-content: center;\n box-shadow: -5px -7px 10px 10px rgba(242, 244, 246, 1);\n animation: fadeIn 0.5s ease-out forwards;\n position: relative;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button-expand-icon {\n width: 9px;\n margin-left: 4px;\n color: #000000;\n}\n\n/* Settings Selector */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector {\n background-color: #eaeaea;\n border-radius: 7px;\n box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);\n padding: 4px;\n display: flex;\n flex-direction: column;\n position: absolute;\n top: 32px;\n width: max-content;\n right: 0;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector-option {\n min-width: 70px;\n background-color: transparent;\n border-radius: 7px;\n font-size: 13px;\n border: 0;\n padding: 5px 10px;\n flex: 1;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector-option:hover {\n background-color: #3b82f6;\n color: #fff;\n}\n\n/* Expanded Options - Actions & Settings */\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-content {\n padding: 0 14px 14px;\n width: 100%;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-divisor {\n border: none;\n border-top: 1px solid #d6d6d6;\n width: 102%;\n margin-left: -1%;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-button {\n font-size: 14px;\n border-radius: 7px;\n width: 100%;\n border: 0;\n padding: 8px;\n background-color: transparent;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-button:hover {\n background-color: #efefef;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-buttons-divisor {\n border: none;\n border-top: 1px solid #d6d6d6;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-buttons-divisor--transparent {\n border-top: 1px solid transparent;\n}\n\n\n\n/* keyframes */\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n\n\n\n\n");function vt(e){const{open:n,disabled:i,onToggle:a}=e;return t("button",{disabled:i,className:"notificare__push__web__desktop__lock-screen__expand-button "+(n?"notificare__push__web__desktop__lock-screen__expand-button--rotated":""),onClick:a,"data-testid":"web-desktop-expand-button",children:t("svg",{className:"notificare__push__web__desktop__lock-screen__expand-button-svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512",children:t("path",{d:"M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"})})})}function yt({notification:i,appName:s,appDomain:c}){var _,l,d;const[p,u]=a(!1),[h,f]=a(!1),[m,g]=a(-1),[b,v]=a(!1),[y,w]=a(!1),[x,k]=a(!1),[N,C]=a(!1),[S,T]=a(""),A=o(null),O=o(null);return r((()=>{if(A.current&&O.current){const e=O.current.scrollHeight;v(e>3*16.7);const t=`${A.current.scrollHeight}px`;A.current.style.height=t,T(t)}R(i)&&v(!0)}),[]),e("div",{ref:A,className:"notificare__push__web__desktop__lock-screen",onMouseEnter:()=>f((()=>!0)),onMouseLeave:()=>f((()=>y)),"data-testid":"web-desktop-notification",children:[(b&&h||p||x)&&t("div",{className:"notificare__push__web__desktop__lock-screen__expand-button-container",children:t(vt,{open:p,disabled:x||N,onToggle:()=>{const e=A.current,t=O.current;e&&t&&(p?(e.style.backgroundColor="#f4f4f4",e.style.height=S,k(!0),u(!1),setTimeout((()=>{k(!1),e.style.overflow=""}),300)):(e.style.backgroundColor="#fff",e.style.overflow="hidden",C(!0),u(!0),setTimeout((()=>{e.style.height=`${e.scrollHeight-t.clientHeight+t.scrollHeight}px`}),10),setTimeout((()=>{C(!1)}),300)),w(!1))}})}),!h&&!p&&!x&&t("div",{className:"notificare__push__web__desktop__lock-screen__time-container",children:t("p",{className:"notificare__push__web__desktop__lock-screen__time",children:" now "})}),e("div",{className:"notificare__push__web__desktop__lock-screen__main-content",children:[t("div",{className:"notificare__push__web__desktop__lock-screen__browser-icon",children:t("div",{className:"notificare__push__web__desktop__lock-screen__browser-icon-background",children:t("img",{className:"notificare__push__web__desktop__lock-screen__browser-icon-image",src:"https://upload.wikimedia.org/wikipedia/commons/e/e1/Google_Chrome_icon_%28February_2022%29.svg",alt:"Google Chrome Icon"})})}),e("div",{className:"notificare__push__web__desktop__lock-screen__text-content",children:[t("p",{className:"notificare__push__web__desktop__lock-screen__text notificare__push__web__desktop__lock-screen__text--title",children:i.title||s}),t("p",{className:"notificare__push__web__desktop__lock-screen__text notificare__push__web__desktop__lock-screen__text--domain",children:wt(c)}),t("p",{ref:O,className:"notificare__push__web__desktop__lock-screen__text "+(p||x?"notificare__push__web__desktop__lock-screen__text--expandable-message":"notificare__push__web__desktop__lock-screen__text--message"),children:i.message})]}),R(i)&&!p&&!x&&!h&&t("img",{className:"notificare__push__web__desktop__lock-screen__small-media",src:null===(_=i.attachments)||void 0===_?void 0:_[0].uri,alt:"Small media icon"}),h&&!p&&!x&&t("div",{className:"notificare__push__web__desktop__lock-screen__settings-button-container",children:i.actions&&i.actions.length>0?e(n,{children:[e("button",{className:"notificare__push__web__desktop__lock-screen__settings-button",onClick:()=>w((e=>!e)),"data-testid":"web-desktop-settings-button",children:["Options",t("svg",{className:"notificare__push__web__desktop__lock-screen__settings-button-expand-icon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",children:t("path",{d:"M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"})})]}),y&&e("div",{className:"notificare__push__web__desktop__lock-screen__settings-selector",children:[i.actions.map(((e,n)=>t("button",{className:"notificare__push__web__desktop__lock-screen__settings-selector-option","data-testid":`web-desktop-options-action-${n}`,children:e.label},n))),t("button",{className:"notificare__push__web__desktop__lock-screen__settings-selector-option",children:"Settings"})]})]}):t("button",{className:"notificare__push__web__desktop__lock-screen__settings-button",children:"Settings"})})]}),(p||x)&&e("div",{className:"notificare__push__web__desktop__lock-screen__expanded-content",children:[R(i)&&t("img",{className:"notificare__push__web__desktop__lock-screen__expanded-media",src:null===(l=i.attachments)||void 0===l?void 0:l[0].uri,alt:"Expanded media"}),t("hr",{className:"notificare__push__web__desktop__lock-screen__expanded-divisor"}),null===(d=i.actions)||void 0===d?void 0:d.map(((n,i)=>e("div",{className:"notificare__push__web__desktop__lock-screen__action",children:[t("button",{className:"notificare__push__web__desktop__lock-screen__expanded-button",onMouseEnter:()=>g(i),onMouseLeave:()=>g(-1),"data-testid":`web-desktop-expanded-action-${i}`,children:n.label}),t("hr",{className:`notificare__push__web__desktop__lock-screen__expanded-buttons-divisor ${(m===i||m-1===i)&&"notificare__push__web__desktop__lock-screen__expanded-buttons-divisor--transparent"}`})]},i))),t("button",{className:"notificare__push__web__desktop__lock-screen__expanded-button",onMouseEnter:()=>{var e;return g((null===(e=i.actions)||void 0===e?void 0:e.length)||-1)},onMouseLeave:()=>g(-1),children:"Settings"})]})]})}function wt(e){try{return new URL(e).hostname}catch(e){return""}}v(".notificare .notificare__push__web__desktop__lock-screen__expand-button {\n background: none;\n border: none;\n padding: 0;\n cursor: pointer;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n transition: transform 0.3s ease;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button--rotated {\n transform: rotate(90deg);\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button-svg {\n width: 11px;\n height: 11px;\n fill: #9e9e9e;\n}");var xt,kt;function Nt({notification:n,appName:i,appIcon:a}){var o;if("re.notifica.notification.Alert"===n.type||"re.notifica.notification.Map"===n.type||"re.notifica.notification.WebView"===n.type||"re.notifica.notification.URL"===n.type||"re.notifica.notification.Video"===n.type||"re.notifica.notification.Image"===n.type)return t("div",{className:"notificare__web__phone__app-ui",children:e("div",{className:"notificare__web__phone__app-ui__background",children:[e("div",{className:"notificare__web__phone__app-ui__header",children:[t("img",{className:"notificare__web__phone__app-ui__app-icon",src:a,alt:"App icon"}),t("p",{className:"notificare__web__phone__app-ui__app-name",children:i}),t("button",{className:"notificare__web__phone__app-ui__close-button",children:t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 48 48",className:"notificare__web__phone__app-ui__close-button-icon",children:t("path",{d:"m12.45 37.65-2.1-2.1L21.9 24 10.35 12.45l2.1-2.1L24 21.9l11.55-11.55 2.1 2.1L26.1 24l11.55 11.55-2.1 2.1L24 26.1Z"})})})]}),"re.notifica.notification.Alert"===n.type&&e("div",{"data-testid":"web-mobile-app-ui-text-alert-notification",children:[R(n)&&t("img",{className:"notificare__web__phone__alert__app-ui__media",src:null===(o=n.attachments)||void 0===o?void 0:o[0].uri,alt:"Notification attachment"}),e("div",{children:[t("p",{className:"notificare__web__phone__alert__app-ui__title",children:n.title}),t("p",{className:"notificare__web__phone__alert__app-ui__subtitle",children:n.subtitle}),t("p",{className:"notificare__web__phone__alert__app-ui__message",children:n.message})]})]}),"re.notifica.notification.WebView"===n.type&&t("iframe",{className:"notificare__web__phone__web-view__app-ui__content",srcDoc:n.content[0].data,sandbox:"allow-same-origin","data-testid":"web-mobile-app-ui-web-view-notification"}),"re.notifica.notification.Map"===n.type&&t(Re,{notification:n,width:"100%",height:"400px"}),"re.notifica.notification.URL"==n.type&&t("div",{"data-testid":"web-mobile-app-ui-url-notification",children:t(P,{url:n.content[0].data,platform:"Web",width:268,height:430})}),"re.notifica.notification.Video"===n.type&&t("div",{"data-testid":"web-mobile-app-ui-video-notification",children:t(We,{videoData:n.content[0],width:"100%",height:"430px"})}),"re.notifica.notification.Image"===n.type&&t("div",{className:"notificare__web__phone__image__app-ui__image-slider","data-testid":"web-mobile-app-ui-image-notification",children:n.content.map(((e,n)=>t("img",{className:"notificare__web__phone__image__app-ui__image-slider-item",src:e.data,alt:"Slider image"},n)))}),n.actions&&t("div",{className:""+(n.actions.length>=3?"notificare__web__phone__app-ui__actions-column":"notificare__web__phone__app-ui__actions-row"),children:n.actions.map(((e,n)=>t("button",{className:"notificare__web__phone__app-ui__action "+(0===n?"notificare__web__phone__app-ui__action--primary":"notificare__web__phone__app-ui__action--secondary"),"data-testid":`web-mobile-app-ui-action-${n}`,children:e.label},n)))})]})})}function Ct({notification:e,application:n,mobileVariant:i,webDevice:a,webMobileType:o,webDesktopOS:r}){const{googleMapsAPIKey:s}=N().options;if("desktop"===a&&"macOS"===r)return t(yt,{notification:e,appName:n.name,appDomain:n.websitePushConfig.allowedDomains[0]},e.message);if("phone"===a&&"app-ui"===i){if("re.notifica.notification.Alert"!==e.type&&"re.notifica.notification.Map"!==e.type&&"re.notifica.notification.WebView"!==e.type&&"re.notifica.notification.URL"!==e.type&&"re.notifica.notification.Video"!==e.type&&"re.notifica.notification.Image"!==e.type)return t(A,{message:`→ The preview for the notification type '${e.type}' does not exist in this variant`,showConsoleWarning:!1});if("re.notifica.notification.Map"===e.type&&!s)return t(A,{message:"→ A Google Maps API key should be provided",showConsoleWarning:!1});const i="android"===o?T:"iphone"===o?Ye:null;if(i)return t(i,{theme:St(e.type),children:t(Nt,{notification:e,appName:n.name,appIcon:S(n.websitePushConfig.icon)})})}}function St(e){return["re.notifica.notification.Alert","re.notifica.notification.Map","re.notifica.notification.WebView","re.notifica.notification.URL","re.notifica.notification.Video","re.notifica.notification.Image"].includes(e)?"dark":"light"}v("/* MAIN */\n\n.notificare .notificare__web__phone__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__web__phone__app-ui__background {\n width: 300px;\n background-color: white;\n border-radius: 4px;\n padding: 16px;\n display: flex;\n flex-direction: column;\n row-gap: 16px;\n}\n\n/* Header */\n\n.notificare .notificare__web__phone__app-ui__header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n column-gap: 16px;\n}\n\n.notificare .notificare__web__phone__app-ui__app-icon {\n border-radius: 4px;\n height: 32px;\n width: 32px;\n}\n\n.notificare .notificare__web__phone__app-ui__app-name {\n font-size: 18px;\n flex: 1;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n display: block;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button {\n width: 32px;\n height: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: transparent;\n border: none;\n cursor: pointer;\n border-radius: 4px;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button:hover {\n transition: background-color .3s ease-in-out, border-radius .3s ease-in-out;\n background-color: #f4f5f9;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button-icon {\n width: 24px;\n height: 24px;\n}\n\n/* TEXT ALERT */\n\n.notificare .notificare__web__phone__alert__app-ui__media {\n max-width: 100%;\n max-height: 250px;\n aspect-ratio: 16 / 9;\n margin-bottom: 10px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__title {\n font-size: 16px;\n font-weight: 600;\n margin-bottom: 8px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__subtitle {\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__message {\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n/* Actions */\n\n.notificare .notificare__web__phone__app-ui__actions-row {\n display: flex;\n flex-wrap: wrap;\n column-gap: 8px;\n row-gap: 8px;\n flex-direction: row-reverse;\n}\n\n.notificare .notificare__web__phone__app-ui__actions-column {\n display: flex;\n flex-direction: column;\n row-gap: 8px;\n align-items: stretch;\n}\n\n.notificare .notificare__web__phone__app-ui__action {\n font-size: 14px;\n font-weight: 500;\n line-height: 20px;\n overflow: hidden;\n padding: 8px 16px;\n text-overflow: ellipsis;\n transition: background-color .3s ease-in-out, color .3s ease-in-out;\n white-space: nowrap;\n border-radius: 4px;\n border: 0;\n cursor: pointer;\n}\n\n.notificare .notificare__web__phone__app-ui__action--full-width {\n width: 100%\n}\n\n.notificare .notificare__web__phone__app-ui__action--primary {\n background-color: #2b42f7;\n color: #ffffffde;\n}\n\n.notificare .notificare__web__phone__app-ui__action--primary:hover {\n background-color: #071cc3;\n}\n\n.notificare .notificare__web__phone__app-ui__action--secondary {\n background-color: transparent;\n color: #2b42f7;\n}\n\n.notificare .notificare__web__phone__app-ui__action--secondary:hover {\n background-color: #f4f5f9;\n}\n\n/* WEB VIEW */\n\n.notificare .notificare__web__phone__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 360px;\n background-color: #fff;\n}\n\n/* IMAGE */\n\n.notificare .notificare__web__phone__image__app-ui__image-slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scroll-behavior: smooth;\n scrollbar-width: thin; /* Firefox */\n scrollbar-color: #bbb transparent; /* Firefox */\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}\n\n/* For Chrome, Edge and Safari */\n.notificare .notificare__web__phone__image__app-ui__image-slider::-webkit-scrollbar {\n height: 4px;\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-webkit-scrollbar-thumb {\n background: #999;\n border-radius: 10px;\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-webkit-scrollbar-track {\n background: transparent;\n}\n\n"),function(e){e.assertEqual=e=>e,e.assertIs=function(e){},e.assertNever=function(e){throw new Error},e.arrayToEnum=e=>{const t={};for(const n of e)t[n]=n;return t},e.getValidEnumValues=t=>{const n=e.objectKeys(t).filter((e=>"number"!=typeof t[t[e]])),i={};for(const e of n)i[e]=t[e];return e.objectValues(i)},e.objectValues=t=>e.objectKeys(t).map((function(e){return t[e]})),e.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{const t=[];for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t},e.find=(e,t)=>{for(const n of e)if(t(n))return n},e.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e,e.joinValues=function(e,t=" | "){return e.map((e=>"string"==typeof e?`'${e}'`:e)).join(t)},e.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t}(xt||(xt={})),function(e){e.mergeShapes=(e,t)=>({...e,...t})}(kt||(kt={}));const Tt=xt.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),At=e=>{switch(typeof e){case"undefined":return Tt.undefined;case"string":return Tt.string;case"number":return isNaN(e)?Tt.nan:Tt.number;case"boolean":return Tt.boolean;case"function":return Tt.function;case"bigint":return Tt.bigint;case"symbol":return Tt.symbol;case"object":return Array.isArray(e)?Tt.array:null===e?Tt.null:e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch?Tt.promise:"undefined"!=typeof Map&&e instanceof Map?Tt.map:"undefined"!=typeof Set&&e instanceof Set?Tt.set:"undefined"!=typeof Date&&e instanceof Date?Tt.date:Tt.object;default:return Tt.unknown}},Ot=xt.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class jt extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){const t=e||function(e){return e.message},n={_errors:[]},i=e=>{for(const a of e.issues)if("invalid_union"===a.code)a.unionErrors.map(i);else if("invalid_return_type"===a.code)i(a.returnTypeError);else if("invalid_arguments"===a.code)i(a.argumentsError);else if(0===a.path.length)n._errors.push(t(a));else{let e=n,i=0;for(;i<a.path.length;){const n=a.path[i];i===a.path.length-1?(e[n]=e[n]||{_errors:[]},e[n]._errors.push(t(a))):e[n]=e[n]||{_errors:[]},e=e[n],i++}}};return i(this),n}static assert(e){if(!(e instanceof jt))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,xt.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){const t={},n=[];for(const i of this.issues)i.path.length>0?(t[i.path[0]]=t[i.path[0]]||[],t[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:t}}get formErrors(){return this.flatten()}}jt.create=e=>new jt(e);const Pt=(e,t)=>{let n;switch(e.code){case Ot.invalid_type:n=e.received===Tt.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case Ot.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,xt.jsonStringifyReplacer)}`;break;case Ot.unrecognized_keys:n=`Unrecognized key(s) in object: ${xt.joinValues(e.keys,", ")}`;break;case Ot.invalid_union:n="Invalid input";break;case Ot.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${xt.joinValues(e.options)}`;break;case Ot.invalid_enum_value:n=`Invalid enum value. Expected ${xt.joinValues(e.options)}, received '${e.received}'`;break;case Ot.invalid_arguments:n="Invalid function arguments";break;case Ot.invalid_return_type:n="Invalid function return type";break;case Ot.invalid_date:n="Invalid date";break;case Ot.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:xt.assertNever(e.validation):n="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case Ot.too_small:n="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case Ot.too_big:n="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case Ot.custom:n="Invalid input";break;case Ot.invalid_intersection_types:n="Intersection results could not be merged";break;case Ot.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case Ot.not_finite:n="Number must be finite";break;default:n=t.defaultError,xt.assertNever(e)}return{message:n}};let It=Pt;function Lt(){return It}const Mt=e=>{const{data:t,path:n,errorMaps:i,issueData:a}=e,o=[...n,...a.path||[]],r={...a,path:o};if(void 0!==a.message)return{...a,path:o,message:a.message};let s="";const c=i.filter((e=>!!e)).slice().reverse();for(const e of c)s=e(r,{data:t,defaultError:s}).message;return{...a,path:o,message:s}};function Et(e,t){const n=Lt(),i=Mt({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===Pt?void 0:Pt].filter((e=>!!e))});e.common.issues.push(i)}class Zt{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){const n=[];for(const i of t){if("aborted"===i.status)return zt;"dirty"===i.status&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,t){const n=[];for(const e of t){const t=await e.key,i=await e.value;n.push({key:t,value:i})}return Zt.mergeObjectSync(e,n)}static mergeObjectSync(e,t){const n={};for(const i of t){const{key:t,value:a}=i;if("aborted"===t.status)return zt;if("aborted"===a.status)return zt;"dirty"===t.status&&e.dirty(),"dirty"===a.status&&e.dirty(),"__proto__"===t.value||void 0===a.value&&!i.alwaysSet||(n[t.value]=a.value)}return{status:e.value,value:n}}}const zt=Object.freeze({status:"aborted"}),Rt=e=>({status:"dirty",value:e}),Dt=e=>({status:"valid",value:e}),$t=e=>"aborted"===e.status,Ft=e=>"dirty"===e.status,Vt=e=>"valid"===e.status,Bt=e=>"undefined"!=typeof Promise&&e instanceof Promise;function Ut(e,t,n,i){if("function"==typeof t||!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t.get(e)}function Kt(e,t,n,i,a){if("function"==typeof t||!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t.set(e,n),n}var Wt,Gt,Ht;"function"==typeof SuppressedError&&SuppressedError,function(e){e.errToObj=e=>"string"==typeof e?{message:e}:e||{},e.toString=e=>"string"==typeof e?e:null==e?void 0:e.message}(Wt||(Wt={}));class qt{constructor(e,t,n,i){this._cachedPath=[],this.parent=e,this.data=t,this._path=n,this._key=i}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Jt=(e,t)=>{if(Vt(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new jt(e.common.issues);return this._error=t,this._error}}};function Yt(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:i,description:a}=e;if(t&&(n||i))throw new Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');if(t)return{errorMap:t,description:a};return{errorMap:(t,a)=>{var o,r;const{message:s}=e;return"invalid_enum_value"===t.code?{message:null!=s?s:a.defaultError}:void 0===a.data?{message:null!==(o=null!=s?s:i)&&void 0!==o?o:a.defaultError}:"invalid_type"!==t.code?{message:a.defaultError}:{message:null!==(r=null!=s?s:n)&&void 0!==r?r:a.defaultError}},description:a}}class Xt{get description(){return this._def.description}_getType(e){return At(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:At(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new Zt,ctx:{common:e.parent.common,data:e.data,parsedType:At(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(Bt(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const n=this.safeParse(e,t);if(n.success)return n.data;throw n.error}safeParse(e,t){var n;const i={common:{issues:[],async:null!==(n=null==t?void 0:t.async)&&void 0!==n&&n,contextualErrorMap:null==t?void 0:t.errorMap},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:At(e)},a=this._parseSync({data:e,path:i.path,parent:i});return Jt(i,a)}"~validate"(e){var t,n;const i={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:At(e)};if(!this["~standard"].async)try{const t=this._parseSync({data:e,path:[],parent:i});return Vt(t)?{value:t.value}:{issues:i.common.issues}}catch(e){(null===(n=null===(t=null==e?void 0:e.message)||void 0===t?void 0:t.toLowerCase())||void 0===n?void 0:n.includes("encountered"))&&(this["~standard"].async=!0),i.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:i}).then((e=>Vt(e)?{value:e.value}:{issues:i.common.issues}))}async parseAsync(e,t){const n=await this.safeParseAsync(e,t);if(n.success)return n.data;throw n.error}async safeParseAsync(e,t){const n={common:{issues:[],contextualErrorMap:null==t?void 0:t.errorMap,async:!0},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:At(e)},i=this._parse({data:e,path:n.path,parent:n}),a=await(Bt(i)?i:Promise.resolve(i));return Jt(n,a)}refine(e,t){const n=e=>"string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(e):t;return this._refinement(((t,i)=>{const a=e(t),o=()=>i.addIssue({code:Ot.custom,...n(t)});return"undefined"!=typeof Promise&&a instanceof Promise?a.then((e=>!!e||(o(),!1))):!!a||(o(),!1)}))}refinement(e,t){return this._refinement(((n,i)=>!!e(n)||(i.addIssue("function"==typeof t?t(n,i):t),!1)))}_refinement(e){return new Qn({schema:this,typeName:pi.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:e=>this["~validate"](e)}}optional(){return ei.create(this,this._def)}nullable(){return ti.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Mn.create(this)}promise(){return Xn.create(this,this._def)}or(e){return zn.create([this,e],this._def)}and(e){return Fn.create(this,e,this._def)}transform(e){return new Qn({...Yt(this._def),schema:this,typeName:pi.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t="function"==typeof e?e:()=>e;return new ni({...Yt(this._def),innerType:this,defaultValue:t,typeName:pi.ZodDefault})}brand(){return new ri({typeName:pi.ZodBranded,type:this,...Yt(this._def)})}catch(e){const t="function"==typeof e?e:()=>e;return new ii({...Yt(this._def),innerType:this,catchValue:t,typeName:pi.ZodCatch})}describe(e){return new(0,this.constructor)({...this._def,description:e})}pipe(e){return si.create(this,e)}readonly(){return ci.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const Qt=/^c[^\s-]{8,}$/i,en=/^[0-9a-z]+$/,tn=/^[0-9A-HJKMNP-TV-Z]{26}$/i,nn=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,an=/^[a-z0-9_-]{21}$/i,on=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,rn=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,sn=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;let cn;const _n=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ln=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,dn=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,pn=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,un=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,hn=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,fn="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",mn=new RegExp(`^${fn}$`);function gn(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`);return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${e.precision?"+":"?"}`}function bn(e){let t=`${fn}T${gn(e)}`;const n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function vn(e,t){if(!on.test(e))return!1;try{const[n]=e.split("."),i=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),a=JSON.parse(atob(i));return"object"==typeof a&&null!==a&&(!(!a.typ||!a.alg)&&(!t||a.alg===t))}catch(e){return!1}}function yn(e,t){return!("v4"!==t&&t||!ln.test(e))||!("v6"!==t&&t||!pn.test(e))}class wn extends Xt{_parse(e){this._def.coerce&&(e.data=String(e.data));if(this._getType(e)!==Tt.string){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.string,received:t.parsedType}),zt}const t=new Zt;let n;for(const o of this._def.checks)if("min"===o.kind)e.data.length<o.value&&(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),t.dirty());else if("max"===o.kind)e.data.length>o.value&&(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),t.dirty());else if("length"===o.kind){const i=e.data.length>o.value,a=e.data.length<o.value;(i||a)&&(n=this._getOrReturnCtx(e,n),i?Et(n,{code:Ot.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):a&&Et(n,{code:Ot.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),t.dirty())}else if("email"===o.kind)sn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"email",code:Ot.invalid_string,message:o.message}),t.dirty());else if("emoji"===o.kind)cn||(cn=new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),cn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"emoji",code:Ot.invalid_string,message:o.message}),t.dirty());else if("uuid"===o.kind)nn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"uuid",code:Ot.invalid_string,message:o.message}),t.dirty());else if("nanoid"===o.kind)an.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"nanoid",code:Ot.invalid_string,message:o.message}),t.dirty());else if("cuid"===o.kind)Qt.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"cuid",code:Ot.invalid_string,message:o.message}),t.dirty());else if("cuid2"===o.kind)en.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"cuid2",code:Ot.invalid_string,message:o.message}),t.dirty());else if("ulid"===o.kind)tn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"ulid",code:Ot.invalid_string,message:o.message}),t.dirty());else if("url"===o.kind)try{new URL(e.data)}catch(i){n=this._getOrReturnCtx(e,n),Et(n,{validation:"url",code:Ot.invalid_string,message:o.message}),t.dirty()}else if("regex"===o.kind){o.regex.lastIndex=0;o.regex.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"regex",code:Ot.invalid_string,message:o.message}),t.dirty())}else if("trim"===o.kind)e.data=e.data.trim();else if("includes"===o.kind)e.data.includes(o.value,o.position)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),t.dirty());else if("toLowerCase"===o.kind)e.data=e.data.toLowerCase();else if("toUpperCase"===o.kind)e.data=e.data.toUpperCase();else if("startsWith"===o.kind)e.data.startsWith(o.value)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:{startsWith:o.value},message:o.message}),t.dirty());else if("endsWith"===o.kind)e.data.endsWith(o.value)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:{endsWith:o.value},message:o.message}),t.dirty());else if("datetime"===o.kind){bn(o).test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:"datetime",message:o.message}),t.dirty())}else if("date"===o.kind){mn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:"date",message:o.message}),t.dirty())}else if("time"===o.kind){new RegExp(`^${gn(o)}$`).test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.invalid_string,validation:"time",message:o.message}),t.dirty())}else"duration"===o.kind?rn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"duration",code:Ot.invalid_string,message:o.message}),t.dirty()):"ip"===o.kind?(i=e.data,("v4"!==(a=o.version)&&a||!_n.test(i))&&("v6"!==a&&a||!dn.test(i))&&(n=this._getOrReturnCtx(e,n),Et(n,{validation:"ip",code:Ot.invalid_string,message:o.message}),t.dirty())):"jwt"===o.kind?vn(e.data,o.alg)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"jwt",code:Ot.invalid_string,message:o.message}),t.dirty()):"cidr"===o.kind?yn(e.data,o.version)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"cidr",code:Ot.invalid_string,message:o.message}),t.dirty()):"base64"===o.kind?un.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"base64",code:Ot.invalid_string,message:o.message}),t.dirty()):"base64url"===o.kind?hn.test(e.data)||(n=this._getOrReturnCtx(e,n),Et(n,{validation:"base64url",code:Ot.invalid_string,message:o.message}),t.dirty()):xt.assertNever(o);var i,a;return{status:t.value,value:e.data}}_regex(e,t,n){return this.refinement((t=>e.test(t)),{validation:t,code:Ot.invalid_string,...Wt.errToObj(n)})}_addCheck(e){return new wn({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...Wt.errToObj(e)})}url(e){return this._addCheck({kind:"url",...Wt.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...Wt.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...Wt.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...Wt.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...Wt.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...Wt.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...Wt.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...Wt.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...Wt.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...Wt.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...Wt.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...Wt.errToObj(e)})}datetime(e){var t,n;return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,offset:null!==(t=null==e?void 0:e.offset)&&void 0!==t&&t,local:null!==(n=null==e?void 0:e.local)&&void 0!==n&&n,...Wt.errToObj(null==e?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,...Wt.errToObj(null==e?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...Wt.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...Wt.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:null==t?void 0:t.position,...Wt.errToObj(null==t?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...Wt.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...Wt.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...Wt.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...Wt.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...Wt.errToObj(t)})}nonempty(e){return this.min(1,Wt.errToObj(e))}trim(){return new wn({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new wn({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new wn({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e=>"datetime"===e.kind))}get isDate(){return!!this._def.checks.find((e=>"date"===e.kind))}get isTime(){return!!this._def.checks.find((e=>"time"===e.kind))}get isDuration(){return!!this._def.checks.find((e=>"duration"===e.kind))}get isEmail(){return!!this._def.checks.find((e=>"email"===e.kind))}get isURL(){return!!this._def.checks.find((e=>"url"===e.kind))}get isEmoji(){return!!this._def.checks.find((e=>"emoji"===e.kind))}get isUUID(){return!!this._def.checks.find((e=>"uuid"===e.kind))}get isNANOID(){return!!this._def.checks.find((e=>"nanoid"===e.kind))}get isCUID(){return!!this._def.checks.find((e=>"cuid"===e.kind))}get isCUID2(){return!!this._def.checks.find((e=>"cuid2"===e.kind))}get isULID(){return!!this._def.checks.find((e=>"ulid"===e.kind))}get isIP(){return!!this._def.checks.find((e=>"ip"===e.kind))}get isCIDR(){return!!this._def.checks.find((e=>"cidr"===e.kind))}get isBase64(){return!!this._def.checks.find((e=>"base64"===e.kind))}get isBase64url(){return!!this._def.checks.find((e=>"base64url"===e.kind))}get minLength(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}function xn(e,t){const n=(e.toString().split(".")[1]||"").length,i=(t.toString().split(".")[1]||"").length,a=n>i?n:i;return parseInt(e.toFixed(a).replace(".",""))%parseInt(t.toFixed(a).replace(".",""))/Math.pow(10,a)}wn.create=e=>{var t;return new wn({checks:[],typeName:pi.ZodString,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Yt(e)})};class kn extends Xt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){this._def.coerce&&(e.data=Number(e.data));if(this._getType(e)!==Tt.number){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.number,received:t.parsedType}),zt}let t;const n=new Zt;for(const i of this._def.checks)if("int"===i.kind)xt.isInteger(e.data)||(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.invalid_type,expected:"integer",received:"float",message:i.message}),n.dirty());else if("min"===i.kind){(i.inclusive?e.data<i.value:e.data<=i.value)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty())}else if("max"===i.kind){(i.inclusive?e.data>i.value:e.data>=i.value)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty())}else"multipleOf"===i.kind?0!==xn(e.data,i.value)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):"finite"===i.kind?Number.isFinite(e.data)||(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.not_finite,message:i.message}),n.dirty()):xt.assertNever(i);return{status:n.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,Wt.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Wt.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Wt.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Wt.toString(t))}setLimit(e,t,n,i){return new kn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:Wt.toString(i)}]})}_addCheck(e){return new kn({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:Wt.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Wt.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Wt.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Wt.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Wt.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Wt.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:Wt.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Wt.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Wt.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find((e=>"int"===e.kind||"multipleOf"===e.kind&&xt.isInteger(e.value)))}get isFinite(){let e=null,t=null;for(const n of this._def.checks){if("finite"===n.kind||"int"===n.kind||"multipleOf"===n.kind)return!0;"min"===n.kind?(null===t||n.value>t)&&(t=n.value):"max"===n.kind&&(null===e||n.value<e)&&(e=n.value)}return Number.isFinite(t)&&Number.isFinite(e)}}kn.create=e=>new kn({checks:[],typeName:pi.ZodNumber,coerce:(null==e?void 0:e.coerce)||!1,...Yt(e)});class Nn extends Xt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch(t){return this._getInvalidInput(e)}if(this._getType(e)!==Tt.bigint)return this._getInvalidInput(e);let t;const n=new Zt;for(const i of this._def.checks)if("min"===i.kind){(i.inclusive?e.data<i.value:e.data<=i.value)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty())}else if("max"===i.kind){(i.inclusive?e.data>i.value:e.data>=i.value)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty())}else"multipleOf"===i.kind?e.data%i.value!==BigInt(0)&&(t=this._getOrReturnCtx(e,t),Et(t,{code:Ot.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):xt.assertNever(i);return{status:n.value,value:e.data}}_getInvalidInput(e){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.bigint,received:t.parsedType}),zt}gte(e,t){return this.setLimit("min",e,!0,Wt.toString(t))}gt(e,t){return this.setLimit("min",e,!1,Wt.toString(t))}lte(e,t){return this.setLimit("max",e,!0,Wt.toString(t))}lt(e,t){return this.setLimit("max",e,!1,Wt.toString(t))}setLimit(e,t,n,i){return new Nn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:Wt.toString(i)}]})}_addCheck(e){return new Nn({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Wt.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Wt.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Wt.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Wt.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:Wt.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}Nn.create=e=>{var t;return new Nn({checks:[],typeName:pi.ZodBigInt,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...Yt(e)})};class Cn extends Xt{_parse(e){this._def.coerce&&(e.data=Boolean(e.data));if(this._getType(e)!==Tt.boolean){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.boolean,received:t.parsedType}),zt}return Dt(e.data)}}Cn.create=e=>new Cn({typeName:pi.ZodBoolean,coerce:(null==e?void 0:e.coerce)||!1,...Yt(e)});class Sn extends Xt{_parse(e){this._def.coerce&&(e.data=new Date(e.data));if(this._getType(e)!==Tt.date){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.date,received:t.parsedType}),zt}if(isNaN(e.data.getTime())){return Et(this._getOrReturnCtx(e),{code:Ot.invalid_date}),zt}const t=new Zt;let n;for(const i of this._def.checks)"min"===i.kind?e.data.getTime()<i.value&&(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),t.dirty()):"max"===i.kind?e.data.getTime()>i.value&&(n=this._getOrReturnCtx(e,n),Et(n,{code:Ot.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),t.dirty()):xt.assertNever(i);return{status:t.value,value:new Date(e.data.getTime())}}_addCheck(e){return new Sn({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:Wt.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:Wt.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}Sn.create=e=>new Sn({checks:[],coerce:(null==e?void 0:e.coerce)||!1,typeName:pi.ZodDate,...Yt(e)});class Tn extends Xt{_parse(e){if(this._getType(e)!==Tt.symbol){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.symbol,received:t.parsedType}),zt}return Dt(e.data)}}Tn.create=e=>new Tn({typeName:pi.ZodSymbol,...Yt(e)});class An extends Xt{_parse(e){if(this._getType(e)!==Tt.undefined){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.undefined,received:t.parsedType}),zt}return Dt(e.data)}}An.create=e=>new An({typeName:pi.ZodUndefined,...Yt(e)});class On extends Xt{_parse(e){if(this._getType(e)!==Tt.null){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.null,received:t.parsedType}),zt}return Dt(e.data)}}On.create=e=>new On({typeName:pi.ZodNull,...Yt(e)});class jn extends Xt{constructor(){super(...arguments),this._any=!0}_parse(e){return Dt(e.data)}}jn.create=e=>new jn({typeName:pi.ZodAny,...Yt(e)});class Pn extends Xt{constructor(){super(...arguments),this._unknown=!0}_parse(e){return Dt(e.data)}}Pn.create=e=>new Pn({typeName:pi.ZodUnknown,...Yt(e)});class In extends Xt{_parse(e){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.never,received:t.parsedType}),zt}}In.create=e=>new In({typeName:pi.ZodNever,...Yt(e)});class Ln extends Xt{_parse(e){if(this._getType(e)!==Tt.undefined){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.void,received:t.parsedType}),zt}return Dt(e.data)}}Ln.create=e=>new Ln({typeName:pi.ZodVoid,...Yt(e)});class Mn extends Xt{_parse(e){const{ctx:t,status:n}=this._processInputParams(e),i=this._def;if(t.parsedType!==Tt.array)return Et(t,{code:Ot.invalid_type,expected:Tt.array,received:t.parsedType}),zt;if(null!==i.exactLength){const e=t.data.length>i.exactLength.value,a=t.data.length<i.exactLength.value;(e||a)&&(Et(t,{code:e?Ot.too_big:Ot.too_small,minimum:a?i.exactLength.value:void 0,maximum:e?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),n.dirty())}if(null!==i.minLength&&t.data.length<i.minLength.value&&(Et(t,{code:Ot.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),n.dirty()),null!==i.maxLength&&t.data.length>i.maxLength.value&&(Et(t,{code:Ot.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),n.dirty()),t.common.async)return Promise.all([...t.data].map(((e,n)=>i.type._parseAsync(new qt(t,e,t.path,n))))).then((e=>Zt.mergeArray(n,e)));const a=[...t.data].map(((e,n)=>i.type._parseSync(new qt(t,e,t.path,n))));return Zt.mergeArray(n,a)}get element(){return this._def.type}min(e,t){return new Mn({...this._def,minLength:{value:e,message:Wt.toString(t)}})}max(e,t){return new Mn({...this._def,maxLength:{value:e,message:Wt.toString(t)}})}length(e,t){return new Mn({...this._def,exactLength:{value:e,message:Wt.toString(t)}})}nonempty(e){return this.min(1,e)}}function En(e){if(e instanceof Zn){const t={};for(const n in e.shape){const i=e.shape[n];t[n]=ei.create(En(i))}return new Zn({...e._def,shape:()=>t})}return e instanceof Mn?new Mn({...e._def,type:En(e.element)}):e instanceof ei?ei.create(En(e.unwrap())):e instanceof ti?ti.create(En(e.unwrap())):e instanceof Vn?Vn.create(e.items.map((e=>En(e)))):e}Mn.create=(e,t)=>new Mn({type:e,minLength:null,maxLength:null,exactLength:null,typeName:pi.ZodArray,...Yt(t)});class Zn extends Xt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;const e=this._def.shape(),t=xt.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==Tt.object){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.object,received:t.parsedType}),zt}const{status:t,ctx:n}=this._processInputParams(e),{shape:i,keys:a}=this._getCached(),o=[];if(!(this._def.catchall instanceof In&&"strip"===this._def.unknownKeys))for(const e in n.data)a.includes(e)||o.push(e);const r=[];for(const e of a){const t=i[e],a=n.data[e];r.push({key:{status:"valid",value:e},value:t._parse(new qt(n,a,n.path,e)),alwaysSet:e in n.data})}if(this._def.catchall instanceof In){const e=this._def.unknownKeys;if("passthrough"===e)for(const e of o)r.push({key:{status:"valid",value:e},value:{status:"valid",value:n.data[e]}});else if("strict"===e)o.length>0&&(Et(n,{code:Ot.unrecognized_keys,keys:o}),t.dirty());else if("strip"!==e)throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const e=this._def.catchall;for(const t of o){const i=n.data[t];r.push({key:{status:"valid",value:t},value:e._parse(new qt(n,i,n.path,t)),alwaysSet:t in n.data})}}return n.common.async?Promise.resolve().then((async()=>{const e=[];for(const t of r){const n=await t.key,i=await t.value;e.push({key:n,value:i,alwaysSet:t.alwaysSet})}return e})).then((e=>Zt.mergeObjectSync(t,e))):Zt.mergeObjectSync(t,r)}get shape(){return this._def.shape()}strict(e){return Wt.errToObj,new Zn({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,n)=>{var i,a,o,r;const s=null!==(o=null===(a=(i=this._def).errorMap)||void 0===a?void 0:a.call(i,t,n).message)&&void 0!==o?o:n.defaultError;return"unrecognized_keys"===t.code?{message:null!==(r=Wt.errToObj(e).message)&&void 0!==r?r:s}:{message:s}}}:{}})}strip(){return new Zn({...this._def,unknownKeys:"strip"})}passthrough(){return new Zn({...this._def,unknownKeys:"passthrough"})}extend(e){return new Zn({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Zn({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:pi.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Zn({...this._def,catchall:e})}pick(e){const t={};return xt.objectKeys(e).forEach((n=>{e[n]&&this.shape[n]&&(t[n]=this.shape[n])})),new Zn({...this._def,shape:()=>t})}omit(e){const t={};return xt.objectKeys(this.shape).forEach((n=>{e[n]||(t[n]=this.shape[n])})),new Zn({...this._def,shape:()=>t})}deepPartial(){return En(this)}partial(e){const t={};return xt.objectKeys(this.shape).forEach((n=>{const i=this.shape[n];e&&!e[n]?t[n]=i:t[n]=i.optional()})),new Zn({...this._def,shape:()=>t})}required(e){const t={};return xt.objectKeys(this.shape).forEach((n=>{if(e&&!e[n])t[n]=this.shape[n];else{let e=this.shape[n];for(;e instanceof ei;)e=e._def.innerType;t[n]=e}})),new Zn({...this._def,shape:()=>t})}keyof(){return qn(xt.objectKeys(this.shape))}}Zn.create=(e,t)=>new Zn({shape:()=>e,unknownKeys:"strip",catchall:In.create(),typeName:pi.ZodObject,...Yt(t)}),Zn.strictCreate=(e,t)=>new Zn({shape:()=>e,unknownKeys:"strict",catchall:In.create(),typeName:pi.ZodObject,...Yt(t)}),Zn.lazycreate=(e,t)=>new Zn({shape:e,unknownKeys:"strip",catchall:In.create(),typeName:pi.ZodObject,...Yt(t)});class zn extends Xt{_parse(e){const{ctx:t}=this._processInputParams(e),n=this._def.options;if(t.common.async)return Promise.all(n.map((async e=>{const n={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:n}),ctx:n}}))).then((function(e){for(const t of e)if("valid"===t.result.status)return t.result;for(const n of e)if("dirty"===n.result.status)return t.common.issues.push(...n.ctx.common.issues),n.result;const n=e.map((e=>new jt(e.ctx.common.issues)));return Et(t,{code:Ot.invalid_union,unionErrors:n}),zt}));{let e;const i=[];for(const a of n){const n={...t,common:{...t.common,issues:[]},parent:null},o=a._parseSync({data:t.data,path:t.path,parent:n});if("valid"===o.status)return o;"dirty"!==o.status||e||(e={result:o,ctx:n}),n.common.issues.length&&i.push(n.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;const a=i.map((e=>new jt(e)));return Et(t,{code:Ot.invalid_union,unionErrors:a}),zt}}get options(){return this._def.options}}zn.create=(e,t)=>new zn({options:e,typeName:pi.ZodUnion,...Yt(t)});const Rn=e=>e instanceof Gn?Rn(e.schema):e instanceof Qn?Rn(e.innerType()):e instanceof Hn?[e.value]:e instanceof Jn?e.options:e instanceof Yn?xt.objectValues(e.enum):e instanceof ni?Rn(e._def.innerType):e instanceof An?[void 0]:e instanceof On?[null]:e instanceof ei?[void 0,...Rn(e.unwrap())]:e instanceof ti?[null,...Rn(e.unwrap())]:e instanceof ri||e instanceof ci?Rn(e.unwrap()):e instanceof ii?Rn(e._def.innerType):[];class Dn extends Xt{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Tt.object)return Et(t,{code:Ot.invalid_type,expected:Tt.object,received:t.parsedType}),zt;const n=this.discriminator,i=t.data[n],a=this.optionsMap.get(i);return a?t.common.async?a._parseAsync({data:t.data,path:t.path,parent:t}):a._parseSync({data:t.data,path:t.path,parent:t}):(Et(t,{code:Ot.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),zt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,n){const i=new Map;for(const n of t){const t=Rn(n.shape[e]);if(!t.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const a of t){if(i.has(a))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(a)}`);i.set(a,n)}}return new Dn({typeName:pi.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:i,...Yt(n)})}}function $n(e,t){const n=At(e),i=At(t);if(e===t)return{valid:!0,data:e};if(n===Tt.object&&i===Tt.object){const n=xt.objectKeys(t),i=xt.objectKeys(e).filter((e=>-1!==n.indexOf(e))),a={...e,...t};for(const n of i){const i=$n(e[n],t[n]);if(!i.valid)return{valid:!1};a[n]=i.data}return{valid:!0,data:a}}if(n===Tt.array&&i===Tt.array){if(e.length!==t.length)return{valid:!1};const n=[];for(let i=0;i<e.length;i++){const a=$n(e[i],t[i]);if(!a.valid)return{valid:!1};n.push(a.data)}return{valid:!0,data:n}}return n===Tt.date&&i===Tt.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class Fn extends Xt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=(e,i)=>{if($t(e)||$t(i))return zt;const a=$n(e.value,i.value);return a.valid?((Ft(e)||Ft(i))&&t.dirty(),{status:t.value,value:a.data}):(Et(n,{code:Ot.invalid_intersection_types}),zt)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then((([e,t])=>i(e,t))):i(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}}Fn.create=(e,t,n)=>new Fn({left:e,right:t,typeName:pi.ZodIntersection,...Yt(n)});class Vn extends Xt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Tt.array)return Et(n,{code:Ot.invalid_type,expected:Tt.array,received:n.parsedType}),zt;if(n.data.length<this._def.items.length)return Et(n,{code:Ot.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),zt;!this._def.rest&&n.data.length>this._def.items.length&&(Et(n,{code:Ot.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const i=[...n.data].map(((e,t)=>{const i=this._def.items[t]||this._def.rest;return i?i._parse(new qt(n,e,n.path,t)):null})).filter((e=>!!e));return n.common.async?Promise.all(i).then((e=>Zt.mergeArray(t,e))):Zt.mergeArray(t,i)}get items(){return this._def.items}rest(e){return new Vn({...this._def,rest:e})}}Vn.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Vn({items:e,typeName:pi.ZodTuple,rest:null,...Yt(t)})};class Bn extends Xt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Tt.object)return Et(n,{code:Ot.invalid_type,expected:Tt.object,received:n.parsedType}),zt;const i=[],a=this._def.keyType,o=this._def.valueType;for(const e in n.data)i.push({key:a._parse(new qt(n,e,n.path,e)),value:o._parse(new qt(n,n.data[e],n.path,e)),alwaysSet:e in n.data});return n.common.async?Zt.mergeObjectAsync(t,i):Zt.mergeObjectSync(t,i)}get element(){return this._def.valueType}static create(e,t,n){return new Bn(t instanceof Xt?{keyType:e,valueType:t,typeName:pi.ZodRecord,...Yt(n)}:{keyType:wn.create(),valueType:e,typeName:pi.ZodRecord,...Yt(t)})}}class Un extends Xt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Tt.map)return Et(n,{code:Ot.invalid_type,expected:Tt.map,received:n.parsedType}),zt;const i=this._def.keyType,a=this._def.valueType,o=[...n.data.entries()].map((([e,t],o)=>({key:i._parse(new qt(n,e,n.path,[o,"key"])),value:a._parse(new qt(n,t,n.path,[o,"value"]))})));if(n.common.async){const e=new Map;return Promise.resolve().then((async()=>{for(const n of o){const i=await n.key,a=await n.value;if("aborted"===i.status||"aborted"===a.status)return zt;"dirty"!==i.status&&"dirty"!==a.status||t.dirty(),e.set(i.value,a.value)}return{status:t.value,value:e}}))}{const e=new Map;for(const n of o){const i=n.key,a=n.value;if("aborted"===i.status||"aborted"===a.status)return zt;"dirty"!==i.status&&"dirty"!==a.status||t.dirty(),e.set(i.value,a.value)}return{status:t.value,value:e}}}}Un.create=(e,t,n)=>new Un({valueType:t,keyType:e,typeName:pi.ZodMap,...Yt(n)});class Kn extends Xt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==Tt.set)return Et(n,{code:Ot.invalid_type,expected:Tt.set,received:n.parsedType}),zt;const i=this._def;null!==i.minSize&&n.data.size<i.minSize.value&&(Et(n,{code:Ot.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),t.dirty()),null!==i.maxSize&&n.data.size>i.maxSize.value&&(Et(n,{code:Ot.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),t.dirty());const a=this._def.valueType;function o(e){const n=new Set;for(const i of e){if("aborted"===i.status)return zt;"dirty"===i.status&&t.dirty(),n.add(i.value)}return{status:t.value,value:n}}const r=[...n.data.values()].map(((e,t)=>a._parse(new qt(n,e,n.path,t))));return n.common.async?Promise.all(r).then((e=>o(e))):o(r)}min(e,t){return new Kn({...this._def,minSize:{value:e,message:Wt.toString(t)}})}max(e,t){return new Kn({...this._def,maxSize:{value:e,message:Wt.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}Kn.create=(e,t)=>new Kn({valueType:e,minSize:null,maxSize:null,typeName:pi.ZodSet,...Yt(t)});class Wn extends Xt{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Tt.function)return Et(t,{code:Ot.invalid_type,expected:Tt.function,received:t.parsedType}),zt;function n(e,n){return Mt({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Lt(),Pt].filter((e=>!!e)),issueData:{code:Ot.invalid_arguments,argumentsError:n}})}function i(e,n){return Mt({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Lt(),Pt].filter((e=>!!e)),issueData:{code:Ot.invalid_return_type,returnTypeError:n}})}const a={errorMap:t.common.contextualErrorMap},o=t.data;if(this._def.returns instanceof Xn){const e=this;return Dt((async function(...t){const r=new jt([]),s=await e._def.args.parseAsync(t,a).catch((e=>{throw r.addIssue(n(t,e)),r})),c=await Reflect.apply(o,this,s);return await e._def.returns._def.type.parseAsync(c,a).catch((e=>{throw r.addIssue(i(c,e)),r}))}))}{const e=this;return Dt((function(...t){const r=e._def.args.safeParse(t,a);if(!r.success)throw new jt([n(t,r.error)]);const s=Reflect.apply(o,this,r.data),c=e._def.returns.safeParse(s,a);if(!c.success)throw new jt([i(s,c.error)]);return c.data}))}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new Wn({...this._def,args:Vn.create(e).rest(Pn.create())})}returns(e){return new Wn({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,n){return new Wn({args:e||Vn.create([]).rest(Pn.create()),returns:t||Pn.create(),typeName:pi.ZodFunction,...Yt(n)})}}class Gn extends Xt{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}Gn.create=(e,t)=>new Gn({getter:e,typeName:pi.ZodLazy,...Yt(t)});class Hn extends Xt{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return Et(t,{received:t.data,code:Ot.invalid_literal,expected:this._def.value}),zt}return{status:"valid",value:e.data}}get value(){return this._def.value}}function qn(e,t){return new Jn({values:e,typeName:pi.ZodEnum,...Yt(t)})}Hn.create=(e,t)=>new Hn({value:e,typeName:pi.ZodLiteral,...Yt(t)});class Jn extends Xt{constructor(){super(...arguments),Gt.set(this,void 0)}_parse(e){if("string"!=typeof e.data){const t=this._getOrReturnCtx(e),n=this._def.values;return Et(t,{expected:xt.joinValues(n),received:t.parsedType,code:Ot.invalid_type}),zt}if(Ut(this,Gt)||Kt(this,Gt,new Set(this._def.values)),!Ut(this,Gt).has(e.data)){const t=this._getOrReturnCtx(e),n=this._def.values;return Et(t,{received:t.data,code:Ot.invalid_enum_value,options:n}),zt}return Dt(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return Jn.create(e,{...this._def,...t})}exclude(e,t=this._def){return Jn.create(this.options.filter((t=>!e.includes(t))),{...this._def,...t})}}Gt=new WeakMap,Jn.create=qn;class Yn extends Xt{constructor(){super(...arguments),Ht.set(this,void 0)}_parse(e){const t=xt.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==Tt.string&&n.parsedType!==Tt.number){const e=xt.objectValues(t);return Et(n,{expected:xt.joinValues(e),received:n.parsedType,code:Ot.invalid_type}),zt}if(Ut(this,Ht)||Kt(this,Ht,new Set(xt.getValidEnumValues(this._def.values))),!Ut(this,Ht).has(e.data)){const e=xt.objectValues(t);return Et(n,{received:n.data,code:Ot.invalid_enum_value,options:e}),zt}return Dt(e.data)}get enum(){return this._def.values}}Ht=new WeakMap,Yn.create=(e,t)=>new Yn({values:e,typeName:pi.ZodNativeEnum,...Yt(t)});class Xn extends Xt{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==Tt.promise&&!1===t.common.async)return Et(t,{code:Ot.invalid_type,expected:Tt.promise,received:t.parsedType}),zt;const n=t.parsedType===Tt.promise?t.data:Promise.resolve(t.data);return Dt(n.then((e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap}))))}}Xn.create=(e,t)=>new Xn({type:e,typeName:pi.ZodPromise,...Yt(t)});class Qn extends Xt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===pi.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=this._def.effect||null,a={addIssue:e=>{Et(n,e),e.fatal?t.abort():t.dirty()},get path(){return n.path}};if(a.addIssue=a.addIssue.bind(a),"preprocess"===i.type){const e=i.transform(n.data,a);if(n.common.async)return Promise.resolve(e).then((async e=>{if("aborted"===t.value)return zt;const i=await this._def.schema._parseAsync({data:e,path:n.path,parent:n});return"aborted"===i.status?zt:"dirty"===i.status||"dirty"===t.value?Rt(i.value):i}));{if("aborted"===t.value)return zt;const i=this._def.schema._parseSync({data:e,path:n.path,parent:n});return"aborted"===i.status?zt:"dirty"===i.status||"dirty"===t.value?Rt(i.value):i}}if("refinement"===i.type){const e=e=>{const t=i.refinement(e,a);if(n.common.async)return Promise.resolve(t);if(t instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1===n.common.async){const i=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return"aborted"===i.status?zt:("dirty"===i.status&&t.dirty(),e(i.value),{status:t.value,value:i.value})}return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then((n=>"aborted"===n.status?zt:("dirty"===n.status&&t.dirty(),e(n.value).then((()=>({status:t.value,value:n.value}))))))}if("transform"===i.type){if(!1===n.common.async){const e=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!Vt(e))return e;const o=i.transform(e.value,a);if(o instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:o}}return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then((e=>Vt(e)?Promise.resolve(i.transform(e.value,a)).then((e=>({status:t.value,value:e}))):e))}xt.assertNever(i)}}Qn.create=(e,t,n)=>new Qn({schema:e,typeName:pi.ZodEffects,effect:t,...Yt(n)}),Qn.createWithPreprocess=(e,t,n)=>new Qn({schema:t,effect:{type:"preprocess",transform:e},typeName:pi.ZodEffects,...Yt(n)});class ei extends Xt{_parse(e){return this._getType(e)===Tt.undefined?Dt(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ei.create=(e,t)=>new ei({innerType:e,typeName:pi.ZodOptional,...Yt(t)});class ti extends Xt{_parse(e){return this._getType(e)===Tt.null?Dt(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ti.create=(e,t)=>new ti({innerType:e,typeName:pi.ZodNullable,...Yt(t)});class ni extends Xt{_parse(e){const{ctx:t}=this._processInputParams(e);let n=t.data;return t.parsedType===Tt.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}ni.create=(e,t)=>new ni({innerType:e,typeName:pi.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...Yt(t)});class ii extends Xt{_parse(e){const{ctx:t}=this._processInputParams(e),n={...t,common:{...t.common,issues:[]}},i=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return Bt(i)?i.then((e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new jt(n.common.issues)},input:n.data})}))):{status:"valid",value:"valid"===i.status?i.value:this._def.catchValue({get error(){return new jt(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}}ii.create=(e,t)=>new ii({innerType:e,typeName:pi.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...Yt(t)});class ai extends Xt{_parse(e){if(this._getType(e)!==Tt.nan){const t=this._getOrReturnCtx(e);return Et(t,{code:Ot.invalid_type,expected:Tt.nan,received:t.parsedType}),zt}return{status:"valid",value:e.data}}}ai.create=e=>new ai({typeName:pi.ZodNaN,...Yt(e)});const oi=Symbol("zod_brand");class ri extends Xt{_parse(e){const{ctx:t}=this._processInputParams(e),n=t.data;return this._def.type._parse({data:n,path:t.path,parent:t})}unwrap(){return this._def.type}}class si extends Xt{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.common.async){return(async()=>{const e=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return"aborted"===e.status?zt:"dirty"===e.status?(t.dirty(),Rt(e.value)):this._def.out._parseAsync({data:e.value,path:n.path,parent:n})})()}{const e=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return"aborted"===e.status?zt:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:n.path,parent:n})}}static create(e,t){return new si({in:e,out:t,typeName:pi.ZodPipeline})}}class ci extends Xt{_parse(e){const t=this._def.innerType._parse(e),n=e=>(Vt(e)&&(e.value=Object.freeze(e.value)),e);return Bt(t)?t.then((e=>n(e))):n(t)}unwrap(){return this._def.innerType}}function _i(e,t){const n="function"==typeof e?e(t):"string"==typeof e?{message:e}:e;return"string"==typeof n?{message:n}:n}function li(e,t={},n){return e?jn.create().superRefine(((i,a)=>{var o,r;const s=e(i);if(s instanceof Promise)return s.then((e=>{var o,r;if(!e){const e=_i(t,i),s=null===(r=null!==(o=e.fatal)&&void 0!==o?o:n)||void 0===r||r;a.addIssue({code:"custom",...e,fatal:s})}}));if(!s){const e=_i(t,i),s=null===(r=null!==(o=e.fatal)&&void 0!==o?o:n)||void 0===r||r;a.addIssue({code:"custom",...e,fatal:s})}})):jn.create()}ci.create=(e,t)=>new ci({innerType:e,typeName:pi.ZodReadonly,...Yt(t)});const di={object:Zn.lazycreate};var pi;!function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"}(pi||(pi={}));const ui=wn.create,hi=kn.create,fi=ai.create,mi=Nn.create,gi=Cn.create,bi=Sn.create,vi=Tn.create,yi=An.create,wi=On.create,xi=jn.create,ki=Pn.create,Ni=In.create,Ci=Ln.create,Si=Mn.create,Ti=Zn.create,Ai=Zn.strictCreate,Oi=zn.create,ji=Dn.create,Pi=Fn.create,Ii=Vn.create,Li=Bn.create,Mi=Un.create,Ei=Kn.create,Zi=Wn.create,zi=Gn.create,Ri=Hn.create,Di=Jn.create,$i=Yn.create,Fi=Xn.create,Vi=Qn.create,Bi=ei.create,Ui=ti.create,Ki=Qn.createWithPreprocess,Wi=si.create,Gi={string:e=>wn.create({...e,coerce:!0}),number:e=>kn.create({...e,coerce:!0}),boolean:e=>Cn.create({...e,coerce:!0}),bigint:e=>Nn.create({...e,coerce:!0}),date:e=>Sn.create({...e,coerce:!0})},Hi=zt;var qi=Object.freeze({__proto__:null,defaultErrorMap:Pt,setErrorMap:function(e){It=e},getErrorMap:Lt,makeIssue:Mt,EMPTY_PATH:[],addIssueToContext:Et,ParseStatus:Zt,INVALID:zt,DIRTY:Rt,OK:Dt,isAborted:$t,isDirty:Ft,isValid:Vt,isAsync:Bt,get util(){return xt},get objectUtil(){return kt},ZodParsedType:Tt,getParsedType:At,ZodType:Xt,datetimeRegex:bn,ZodString:wn,ZodNumber:kn,ZodBigInt:Nn,ZodBoolean:Cn,ZodDate:Sn,ZodSymbol:Tn,ZodUndefined:An,ZodNull:On,ZodAny:jn,ZodUnknown:Pn,ZodNever:In,ZodVoid:Ln,ZodArray:Mn,ZodObject:Zn,ZodUnion:zn,ZodDiscriminatedUnion:Dn,ZodIntersection:Fn,ZodTuple:Vn,ZodRecord:Bn,ZodMap:Un,ZodSet:Kn,ZodFunction:Wn,ZodLazy:Gn,ZodLiteral:Hn,ZodEnum:Jn,ZodNativeEnum:Yn,ZodPromise:Xn,ZodEffects:Qn,ZodTransformer:Qn,ZodOptional:ei,ZodNullable:ti,ZodDefault:ni,ZodCatch:ii,ZodNaN:ai,BRAND:oi,ZodBranded:ri,ZodPipeline:si,ZodReadonly:ci,custom:li,Schema:Xt,ZodSchema:Xt,late:di,get ZodFirstPartyTypeKind(){return pi},coerce:Gi,any:xi,array:Si,bigint:mi,boolean:gi,date:bi,discriminatedUnion:ji,effect:Vi,enum:Di,function:Zi,instanceof:(e,t={message:`Input not instance of ${e.name}`})=>li((t=>t instanceof e),t),intersection:Pi,lazy:zi,literal:Ri,map:Mi,nan:fi,nativeEnum:$i,never:Ni,null:wi,nullable:Ui,number:hi,object:Ti,oboolean:()=>gi().optional(),onumber:()=>hi().optional(),optional:Bi,ostring:()=>ui().optional(),pipeline:Wi,preprocess:Ki,promise:Fi,record:Li,set:Ei,strictObject:Ai,string:ui,symbol:vi,transformer:Vi,tuple:Ii,undefined:yi,union:Oi,unknown:ki,void:Ci,NEVER:Hi,ZodIssueCode:Ot,quotelessJson:e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:"),ZodError:jt});const Ji=qi.object({type:qi.string({message:"Action property 'type' should be a string"}),label:qi.string({message:"Action property 'label' should be a string"}),target:qi.string({message:"Action property 'target' should be a string"}).optional(),camera:qi.boolean({message:"Action property 'camera' should be a boolean"}).optional(),keyboard:qi.boolean({message:"Action property 'keyboard' should be a boolean"}).optional()}),Yi=qi.object({mimeType:qi.string({message:"Attachment property 'mimeType' should be a string"}),uri:qi.string({message:"Attachment property 'uri' should be a string"}).url("Attachment 'uri' property should be a valid URL")}),Xi=qi.object({type:qi.literal("re.notifica.notification.Alert"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),Qi=qi.object({type:qi.literal("re.notifica.notification.Image"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.enum(["re.notifica.content.PNG","re.notifica.content.JPEG","re.notifica.content.GIF"],{message:"Content objects should be of type 're.notifica.content.PNG', 're.notifica.content.JPEG' or 're.notifica.content.GIF'"}),data:qi.string({message:"Content objects data should be strings"}).url("Content objects data should be valid URLs")})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),ea=qi.object({type:qi.literal("re.notifica.notification.InAppBrowser"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.literal("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:qi.string({message:"Content object data should be a string"}).url("Content object data should be a valid URL")})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),ta=qi.object({type:qi.literal("re.notifica.notification.Map"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.literal("re.notifica.content.Marker",{message:"Content objects should be of type 're.notifica.content.Marker'"}),data:qi.object({title:qi.string({message:"Content object data property 'title' should be a string"}),description:qi.string({message:"Content object data property 'description' should be a string"}),latitude:qi.number({message:"Content object data property 'latitude' should be a number"}).min(-90,"Content object data property 'latitude' should be a minimum of -90").max(90,"Content object data property 'latitude' should be a maximum of 90"),longitude:qi.number({message:"Content object data property 'longitude' should be a number"}).min(-180,"Content object data property 'longitude' must be at least -180").max(180,"Content object data property 'longitude' must be at most 180")})})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),na=qi.object({type:qi.literal("re.notifica.notification.Passbook"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.literal("re.notifica.content.PKPass",{message:"Content object should be of type 're.notifica.content.PKPass'"}),data:qi.string({message:"Content object data should be a string"}).url("Content object data should be a valid URL")})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),ia=qi.object({type:qi.literal("re.notifica.notification.Rate"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.string({message:"Content object type should be a string"}),data:qi.unknown()})).optional(),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),aa=qi.object({type:qi.literal("re.notifica.notification.Store"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.string({message:"Content object type should be a string"}),data:qi.union([qi.string().nonempty("Content object data is mandatory"),qi.object({identifier:qi.string({message:"Content object data property 'identifier' should be a string"}),campaignToken:qi.string({message:"Content object data property 'campaignToken' should be a string"}).optional(),affiliateToken:qi.string({message:"Content object data property 'affiliateToken' should be a string"}).optional(),providerToken:qi.string({message:"Content object data property 'providerToken' should be a string"}).optional()})])})).superRefine(((e,t)=>{e.forEach(((e,n)=>{["re.notifica.content.GooglePlayDetails","re.notifica.content.GooglePlayDeveloper","re.notifica.content.GooglePlayCollection","re.notifica.content.GooglePlaySearch","re.notifica.content.AppGalleryDetails","re.notifica.content.AppGallerySearch","re.notifica.content.AppStore"].includes(e.type)||t.addIssue({code:qi.ZodIssueCode.custom,message:"Content object type should be one of: 're.notifica.content.GooglePlayDetails', 're.notifica.content.GooglePlayDeveloper', 're.notifica.content.GooglePlayCollection', 're.notifica.content.GooglePlaySearch', 're.notifica.content.AppGalleryDetails', 're.notifica.content.AppGallerySearch', 're.notifica.content.AppStore'",path:["content",n,"type"]}),"re.notifica.content.AppStore"===e.type&&"object"!=typeof e.data&&t.addIssue({code:qi.ZodIssueCode.custom,message:"AppStore content object data must be an object with 'identifier' (mandatory), 'campaignToken', 'affiliateToken', or 'providerToken'",path:["content",n,"data"]}),"re.notifica.content.AppStore"!==e.type&&"string"!=typeof e.data&&t.addIssue({code:qi.ZodIssueCode.custom,message:"GooglePlay and AppGallery content object data must be a string",path:["content",n,"data"]})}))})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),oa=qi.object({type:qi.literal("re.notifica.notification.URL"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.literal("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:qi.string({message:"Content object data should be a string"}).url("Content object data should be a valid URL")})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),ra=qi.object({type:qi.literal("re.notifica.notification.Video"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Property 'message' is mandatory"),content:qi.array(qi.object({type:qi.string({message:"Content object type should be a string"}),data:qi.string().nonempty("Content object data is mandatory")})).superRefine(((e,t)=>{e.forEach(((e,n)=>{if(["re.notifica.content.YouTube","re.notifica.content.Vimeo","re.notifica.content.HTML5Video"].includes(e.type)||t.addIssue({code:qi.ZodIssueCode.custom,message:"Content object should be of type 're.notifica.content.YouTube', 're.notifica.content.Vimeo' or 're.notifica.content.HTML5Video'",path:["content",n,"type"]}),"re.notifica.content.HTML5Video"===e.type)try{new URL(e.data)}catch(e){t.addIssue({code:qi.ZodIssueCode.custom,message:"For a HTML5Video, content object data should be a valid URL",path:["content",n,"data"]})}}))})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),sa=qi.object({type:qi.literal("re.notifica.notification.WebView"),title:qi.string({message:"Property 'title' should be a string"}).optional(),subtitle:qi.string({message:"Property 'subtitle' should be a string"}).optional(),message:qi.string({message:"Property 'message' should be a string"}).nonempty("Message is mandatory"),content:qi.array(qi.object({type:qi.literal("re.notifica.content.HTML",{message:"Content object should be of type 're.notifica.content.HTML'"}),data:qi.string({message:"Content data should be a string containing the HTML markup"})})),actions:qi.array(Ji).optional(),attachments:qi.array(Yi).optional()}),ca=qi.discriminatedUnion("type",[Xi,sa,oa,ea,Qi,ta,ia,na,ra,aa]),_a={name:"My App",androidPackageName:"com.example.app",websitePushConfig:{icon:"https://avatars.githubusercontent.com/u/1728060?s=200&v=4",allowedDomains:["https://my-app.com/"]}};function la({notification:i,applicationId:o,showControls:s=!0,variant:c="android-lockscreen",serviceKey:_,googleMapsAPIKey:l}){var d,p,u,h,f;const[m,g]=a();r((()=>{!function(){b(this,void 0,void 0,(function*(){if(o)try{const e=yield fetch(`https://push.notifica.re/application/${o}/info?apiKey=${_}`);if(e.ok){const{application:t}=yield e.json();g(t)}else{const{error:t}=yield e.json();console.error(`There was an error trying to get the application: ${t}`),g(_a)}}catch(e){console.error("Error fetching the application: ",e),g(_a)}else g(_a)}))}()}),[o,_]);const v=new Map([["android-lockscreen",{platform:"android",mobileVariant:"lockscreen"}],["android-lockscreen-expanded",{platform:"android",mobileVariant:"lockscreen-expanded"}],["android-app-ui",{platform:"android",mobileVariant:"app-ui"}],["ios-lockscreen",{platform:"ios",mobileVariant:"lockscreen"}],["ios-lockscreen-expanded",{platform:"ios",mobileVariant:"lockscreen-expanded"}],["ios-app-ui",{platform:"ios",mobileVariant:"app-ui"}],["web-desktop-macos",{platform:"web",webDevice:"desktop",webDesktopOS:"macOS"}],["web-iphone-app-ui",{platform:"web",webDevice:"phone",webMobileType:"iphone",mobileVariant:"app-ui"}],["web-android-app-ui",{platform:"web",webDevice:"phone",webMobileType:"android",mobileVariant:"app-ui"}]]),[y,w]=a(null===(d=v.get(c))||void 0===d?void 0:d.platform),[N,C]=a(null===(p=v.get(c))||void 0===p?void 0:p.mobileVariant),[S,T]=a(null===(u=v.get(c))||void 0===u?void 0:u.webDevice),[j,P]=a(null===(h=v.get(c))||void 0===h?void 0:h.webMobileType),[I,L]=a(null===(f=v.get(c))||void 0===f?void 0:f.webDesktopOS),M=ca.safeParse(i);return M.success||function(e){if(e.find((e=>"invalid_union_discriminator"===e.code&&e.path.includes("type")))){const e=ca.options.map((e=>e.shape.type.value));console.error(`Notification error: \n\nInvalid notification type. Expected one of: ${e.join(", ")}`)}else{const t=e.map((e=>e.message));console.error("Notification errors:\n\n"+t.join("\n"))}}(M.error.errors),t(k,{options:{serviceKey:_,googleMapsAPIKey:l},children:t("div",{className:"notificare",children:e("div",{className:"notificare__push__preview-wrapper",children:[s&&t(x,{platform:y,mobileVariant:N,webDevice:S,webMobileType:j,webDesktopOS:I,setPlatform:w,setMobileVariant:C,setWebDesktopOS:L,setWebDevice:T,setWebMobileType:P}),m?t("div",{className:"notificare__push__preview",children:M.success?e(n,{children:["android"===y&&t(qe,{notification:M.data,application:m,mobileVariant:N}),"ios"===y&&t(gt,{notification:M.data,application:m,mobileVariant:N}),"web"===y&&t(Ct,{notification:M.data,application:m,mobileVariant:N,webDevice:S,webMobileType:j,webDesktopOS:I})]}):t(A,{message:"→ Invalid Notification",showConsoleWarning:!0})}):t(O,{})]})})})}export{la as NotificareNotificationPreview};
1
+ import{jsxs as e,jsx as t,Fragment as n}from"react/jsx-runtime";import*as i from"react";import r,{useState as a,useEffect as o,useMemo as s,useRef as c,Fragment as l,createContext as p,useContext as d,forwardRef as u,useImperativeHandle as _,Children as h,useReducer as f,useCallback as m,useLayoutEffect as g}from"react";import{createPortal as v}from"react-dom";var b=function(e,t){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},b(e,t)};function w(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}b(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var y=function(){return y=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},y.apply(this,arguments)};function x(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]])}return n}function k(e,t,n,i){return new(n||(n=Promise))((function(r,a){function o(e){try{c(i.next(e))}catch(e){a(e)}}function s(e){try{c(i.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(o,s)}c((i=i.apply(e,t||[])).next())}))}function E(e,t,n){if(n||2===arguments.length)for(var i,r=0,a=t.length;r<a;r++)!i&&r in t||(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}function N(e,t){var n=t&&t.cache?t.cache:I,i=t&&t.serializer?t.serializer:O;return(t&&t.strategy?t.strategy:M)(e,{cache:n,serializer:i})}function S(e,t,n,i){var r,a=null==(r=i)||"number"==typeof r||"boolean"==typeof r?i:n(i),o=t.get(a);return void 0===o&&(o=e.call(this,i),t.set(a,o)),o}function T(e,t,n){var i=Array.prototype.slice.call(arguments,3),r=n(i),a=t.get(r);return void 0===a&&(a=e.apply(this,i),t.set(r,a)),a}function A(e,t,n,i,r){return n.bind(t,e,i,r)}function M(e,t){return A(e,this,1===e.length?S:T,t.cache.create(),t.serializer)}"function"==typeof SuppressedError&&SuppressedError;var C,P,L,O=function(){return JSON.stringify(arguments)},R=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(e){return this.cache[e]},e.prototype.set=function(e,t){this.cache[e]=t},e}(),I={create:function(){return new R}},U={variadic:function(e,t){return A(e,this,T,t.cache.create(),t.serializer)}};function B(e){return e.type===P.literal}function H(e){return e.type===P.argument}function j(e){return e.type===P.number}function F(e){return e.type===P.date}function D(e){return e.type===P.time}function G(e){return e.type===P.select}function z(e){return e.type===P.plural}function V(e){return e.type===P.pound}function Z(e){return e.type===P.tag}function $(e){return!(!e||"object"!=typeof e||e.type!==L.number)}function W(e){return!(!e||"object"!=typeof e||e.type!==L.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(C||(C={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(P||(P={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(L||(L={}));var K=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,q=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function X(e){var t={};return e.replace(q,(function(e){var n=e.length;switch(e[0]){case"G":t.era=4===n?"long":5===n?"narrow":"short";break;case"y":t.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][n-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===n?"long":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][n-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][n-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][n-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][n-1];break;case"s":t.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=n<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),t}var Y=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;var J=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,Q=/^(@+)?(\+|#+)?[rs]?$/g,ee=/(\*)(0+)|(#+)(0+)|(0+)/g,te=/^(0+)$/;function ne(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(Q,(function(e,n,i){return"string"!=typeof i?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===i?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof i?i.length:0)),""})),t}function ie(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function re(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if("+!"===n?(t.signDisplay="always",e=e.slice(2)):"+?"===n&&(t.signDisplay="exceptZero",e=e.slice(2)),!te.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function ae(e){var t=ie(e);return t||{}}function oe(e){for(var t={},n=0,i=e;n<i.length;n++){var r=i[n];switch(r.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=r.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=r.options[0].replace(/^(.*?)-/,"");continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=y(y(y({},t),{notation:"scientific"}),r.options.reduce((function(e,t){return y(y({},e),ae(t))}),{}));continue;case"engineering":t=y(y(y({},t),{notation:"engineering"}),r.options.reduce((function(e,t){return y(y({},e),ae(t))}),{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(r.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(r.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");r.options[0].replace(ee,(function(e,n,i,r,a,o){if(n)t.minimumIntegerDigits=i.length;else{if(r&&a)throw new Error("We currently do not support maximum integer digits");if(o)throw new Error("We currently do not support exact integer digits")}return""}));continue}if(te.test(r.stem))t.minimumIntegerDigits=r.stem.length;else if(J.test(r.stem)){if(r.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");r.stem.replace(J,(function(e,n,i,r,a,o){return"*"===i?t.minimumFractionDigits=n.length:r&&"#"===r[0]?t.maximumFractionDigits=r.length:a&&o?(t.minimumFractionDigits=a.length,t.maximumFractionDigits=a.length+o.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""}));var a=r.options[0];"w"===a?t=y(y({},t),{trailingZeroDisplay:"stripIfInteger"}):a&&(t=y(y({},t),ne(a)))}else if(Q.test(r.stem))t=y(y({},t),ne(r.stem));else{var o=ie(r.stem);o&&(t=y(y({},t),o));var s=re(r.stem);s&&(t=y(y({},t),s))}}return t}var se,ce={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function le(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n,i=e.language;return"root"!==i&&(n=e.maximize().region),(ce[n||""]||ce[i||""]||ce["".concat(i,"-001")]||ce["001"])[0]}var pe=new RegExp("^".concat(K.source,"*")),de=new RegExp("".concat(K.source,"*$"));function ue(e,t){return{start:e,end:t}}var _e=!!String.prototype.startsWith&&"_a".startsWith("a",1),he=!!String.fromCodePoint,fe=!!Object.fromEntries,me=!!String.prototype.codePointAt,ge=!!String.prototype.trimStart,ve=!!String.prototype.trimEnd,be=!!Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},we=!0;try{we="a"===(null===(se=Ae("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===se?void 0:se[0])}catch(e){we=!1}var ye,xe=_e?function(e,t,n){return e.startsWith(t,n)}:function(e,t,n){return e.slice(n,n+t.length)===t},ke=he?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n,i="",r=e.length,a=0;r>a;){if((n=e[a++])>1114111)throw RangeError(n+" is not a valid code point");i+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return i},Ee=fe?Object.fromEntries:function(e){for(var t={},n=0,i=e;n<i.length;n++){var r=i[n],a=r[0],o=r[1];t[a]=o}return t},Ne=me?function(e,t){return e.codePointAt(t)}:function(e,t){var n=e.length;if(!(t<0||t>=n)){var i,r=e.charCodeAt(t);return r<55296||r>56319||t+1===n||(i=e.charCodeAt(t+1))<56320||i>57343?r:i-56320+(r-55296<<10)+65536}},Se=ge?function(e){return e.trimStart()}:function(e){return e.replace(pe,"")},Te=ve?function(e){return e.trimEnd()}:function(e){return e.replace(de,"")};function Ae(e,t){return new RegExp(e,t)}if(we){var Me=Ae("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");ye=function(e,t){var n;return Me.lastIndex=t,null!==(n=Me.exec(e)[1])&&void 0!==n?n:""}}else ye=function(e,t){for(var n=[];;){var i=Ne(e,t);if(void 0===i||Oe(i)||Re(i))break;n.push(i),t+=i>=65536?2:1}return ke.apply(void 0,n)};var Ce,Pe=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,n){for(var i=[];!this.isEOF();){var r=this.char();if(123===r){if((a=this.parseArgument(e,n)).err)return a;i.push(a.val)}else{if(125===r&&e>0)break;if(35!==r||"plural"!==t&&"selectordinal"!==t){if(60===r&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(C.UNMATCHED_CLOSING_TAG,ue(this.clonePosition(),this.clonePosition()))}if(60===r&&!this.ignoreTag&&Le(this.peek()||0)){if((a=this.parseTag(e,t)).err)return a;i.push(a.val)}else{var a;if((a=this.parseLiteral(e,t)).err)return a;i.push(a.val)}}else{var o=this.clonePosition();this.bump(),i.push({type:P.pound,location:ue(o,this.clonePosition())})}}}return{val:i,err:null}},e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();var i=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:P.literal,value:"<".concat(i,"/>"),location:ue(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var r=this.parseMessage(e+1,t,!0);if(r.err)return r;var a=r.val,o=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!Le(this.char()))return this.error(C.INVALID_TAG,ue(o,this.clonePosition()));var s=this.clonePosition();return i!==this.parseTagName()?this.error(C.UNMATCHED_CLOSING_TAG,ue(s,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:P.tag,value:i,children:a,location:ue(n,this.clonePosition())},err:null}:this.error(C.INVALID_TAG,ue(o,this.clonePosition())))}return this.error(C.UNCLOSED_TAG,ue(n,this.clonePosition()))}return this.error(C.INVALID_TAG,ue(n,this.clonePosition()))},e.prototype.parseTagName=function(){var e,t=this.offset();for(this.bump();!this.isEOF()&&(45===(e=this.char())||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039);)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(e,t){for(var n=this.clonePosition(),i="";;){var r=this.tryParseQuote(t);if(r)i+=r;else{var a=this.tryParseUnquoted(e,t);if(a)i+=a;else{var o=this.tryParseLeftAngleBracket();if(!o)break;i+=o}}}var s=ue(n,this.clonePosition());return{val:{type:P.literal,value:i,location:s},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(Le(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(n);this.bump()}return ke.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===t||"selectordinal"===t)||125===n&&e>0?null:(this.bump(),ke(n))},e.prototype.parseArgument=function(e,t){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(C.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(C.EMPTY_ARGUMENT,ue(n,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(C.MALFORMED_ARGUMENT,ue(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(C.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:P.argument,value:i,location:ue(n,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(C.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition())):this.parseArgumentOptions(e,t,i,n);default:return this.error(C.MALFORMED_ARGUMENT,ue(n,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=ye(this.message,t),i=t+n.length;return this.bumpTo(i),{value:n,location:ue(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,i){var r,a=this.clonePosition(),o=this.parseIdentifierIfPossible().value,s=this.clonePosition();switch(o){case"":return this.error(C.EXPECT_ARGUMENT_TYPE,ue(a,s));case"number":case"date":case"time":this.bumpSpace();var c=null;if(this.bumpIf(",")){this.bumpSpace();var l=this.clonePosition();if((g=this.parseSimpleArgStyleIfPossible()).err)return g;if(0===(_=Te(g.val)).length)return this.error(C.EXPECT_ARGUMENT_STYLE,ue(this.clonePosition(),this.clonePosition()));c={style:_,styleLocation:ue(l,this.clonePosition())}}if((v=this.tryParseArgumentClose(i)).err)return v;var p=ue(i,this.clonePosition());if(c&&xe(null==c?void 0:c.style,"::",0)){var d=Se(c.style.slice(2));if("number"===o)return(g=this.parseNumberSkeletonFromString(d,c.styleLocation)).err?g:{val:{type:P.number,value:n,location:p,style:g.val},err:null};if(0===d.length)return this.error(C.EXPECT_DATE_TIME_SKELETON,p);var u=d;this.locale&&(u=function(e,t){for(var n="",i=0;i<e.length;i++){var r=e.charAt(i);if("j"===r){for(var a=0;i+1<e.length&&e.charAt(i+1)===r;)a++,i++;var o=1+(1&a),s=a<2?1:3+(a>>1),c=le(t);for("H"!=c&&"k"!=c||(s=0);s-- >0;)n+="a";for(;o-- >0;)n=c+n}else n+="J"===r?"H":r}return n}(d,this.locale));var _={type:L.dateTime,pattern:u,location:c.styleLocation,parsedOptions:this.shouldParseSkeletons?X(u):{}};return{val:{type:"date"===o?P.date:P.time,value:n,location:p,style:_},err:null}}return{val:{type:"number"===o?P.number:"date"===o?P.date:P.time,value:n,location:p,style:null!==(r=null==c?void 0:c.style)&&void 0!==r?r:null},err:null};case"plural":case"selectordinal":case"select":var h=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(C.EXPECT_SELECT_ARGUMENT_OPTIONS,ue(h,y({},h)));this.bumpSpace();var f=this.parseIdentifierIfPossible(),m=0;if("select"!==o&&"offset"===f.value){if(!this.bumpIf(":"))return this.error(C.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,ue(this.clonePosition(),this.clonePosition()));var g;if(this.bumpSpace(),(g=this.tryParseDecimalInteger(C.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,C.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return g;this.bumpSpace(),f=this.parseIdentifierIfPossible(),m=g.val}var v,b=this.tryParsePluralOrSelectOptions(e,o,t,f);if(b.err)return b;if((v=this.tryParseArgumentClose(i)).err)return v;var w=ue(i,this.clonePosition());return"select"===o?{val:{type:P.select,value:n,options:Ee(b.val),location:w},err:null}:{val:{type:P.plural,value:n,options:Ee(b.val),offset:m,pluralType:"plural"===o?"cardinal":"ordinal",location:w},err:null};default:return this.error(C.INVALID_ARGUMENT_TYPE,ue(a,s))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(C.EXPECT_ARGUMENT_CLOSING_BRACE,ue(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(C.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,ue(n,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var n=[];try{n=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],n=0,i=e.split(Y).filter((function(e){return e.length>0}));n<i.length;n++){var r=i[n].split("/");if(0===r.length)throw new Error("Invalid number skeleton");for(var a=r[0],o=r.slice(1),s=0,c=o;s<c.length;s++)if(0===c[s].length)throw new Error("Invalid number skeleton");t.push({stem:a,options:o})}return t}(e)}catch(e){return this.error(C.INVALID_NUMBER_SKELETON,t)}return{val:{type:L.number,tokens:n,location:t,parsedOptions:this.shouldParseSkeletons?oe(n):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,n,i){for(var r,a=!1,o=[],s=new Set,c=i.value,l=i.location;;){if(0===c.length){var p=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var d=this.tryParseDecimalInteger(C.EXPECT_PLURAL_ARGUMENT_SELECTOR,C.INVALID_PLURAL_ARGUMENT_SELECTOR);if(d.err)return d;l=ue(p,this.clonePosition()),c=this.message.slice(p.offset,this.offset())}if(s.has(c))return this.error("select"===t?C.DUPLICATE_SELECT_ARGUMENT_SELECTOR:C.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,l);"other"===c&&(a=!0),this.bumpSpace();var u=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?C.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:C.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,ue(this.clonePosition(),this.clonePosition()));var _=this.parseMessage(e+1,t,n);if(_.err)return _;var h=this.tryParseArgumentClose(u);if(h.err)return h;o.push([c,{value:_.val,location:ue(u,this.clonePosition())}]),s.add(c),this.bumpSpace(),c=(r=this.parseIdentifierIfPossible()).value,l=r.location}return 0===o.length?this.error("select"===t?C.EXPECT_SELECT_ARGUMENT_SELECTOR:C.EXPECT_PLURAL_ARGUMENT_SELECTOR,ue(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!a?this.error(C.MISSING_OTHER_CLAUSE,ue(this.clonePosition(),this.clonePosition())):{val:o,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var n=1,i=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var r=!1,a=0;!this.isEOF();){var o=this.char();if(!(o>=48&&o<=57))break;r=!0,a=10*a+(o-48),this.bump()}var s=ue(i,this.clonePosition());return r?be(a*=n)?{val:a,err:null}:this.error(t,s):this.error(e,s)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=Ne(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if(xe(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),n=this.message.indexOf(e,t);return n>=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&Oe(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),n=this.message.charCodeAt(t+(e>=65536?2:1));return null!=n?n:null},e}();function Le(e){return e>=97&&e<=122||e>=65&&e<=90}function Oe(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function Re(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function Ie(e){e.forEach((function(e){if(delete e.location,G(e)||z(e))for(var t in e.options)delete e.options[t].location,Ie(e.options[t].value);else j(e)&&$(e.style)||(F(e)||D(e))&&W(e.style)?delete e.style.location:Z(e)&&Ie(e.children)}))}function Ue(e,t){void 0===t&&(t={}),t=y({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new Pe(e,t).parse();if(n.err){var i=SyntaxError(C[n.err.kind]);throw i.location=n.err.location,i.originalMessage=n.err.message,i}return(null==t?void 0:t.captureLocation)||Ie(n.val),n.val}!function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"}(Ce||(Ce={}));var Be,He=function(e){function t(t,n,i){var r=e.call(this,t)||this;return r.code=n,r.originalMessage=i,r}return w(t,e),t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),je=function(e){function t(t,n,i,r){return e.call(this,'Invalid values for "'.concat(t,'": "').concat(n,'". Options are "').concat(Object.keys(i).join('", "'),'"'),Ce.INVALID_VALUE,r)||this}return w(t,e),t}(He),Fe=function(e){function t(t,n,i){return e.call(this,'Value for "'.concat(t,'" must be of type ').concat(n),Ce.INVALID_VALUE,i)||this}return w(t,e),t}(He),De=function(e){function t(t,n){return e.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(n,'"'),Ce.MISSING_VALUE,n)||this}return w(t,e),t}(He);function Ge(e){return"function"==typeof e}function ze(e,t,n,i,r,a,o){if(1===e.length&&B(e[0]))return[{type:Be.literal,value:e[0].value}];for(var s=[],c=0,l=e;c<l.length;c++){var p=l[c];if(B(p))s.push({type:Be.literal,value:p.value});else if(V(p))"number"==typeof a&&s.push({type:Be.literal,value:n.getNumberFormat(t).format(a)});else{var d=p.value;if(!r||!(d in r))throw new De(d,o);var u=r[d];if(H(p))u&&"string"!=typeof u&&"number"!=typeof u||(u="string"==typeof u||"number"==typeof u?String(u):""),s.push({type:"string"==typeof u?Be.literal:Be.object,value:u});else if(F(p)){var _="string"==typeof p.style?i.date[p.style]:W(p.style)?p.style.parsedOptions:void 0;s.push({type:Be.literal,value:n.getDateTimeFormat(t,_).format(u)})}else if(D(p)){_="string"==typeof p.style?i.time[p.style]:W(p.style)?p.style.parsedOptions:i.time.medium;s.push({type:Be.literal,value:n.getDateTimeFormat(t,_).format(u)})}else if(j(p)){(_="string"==typeof p.style?i.number[p.style]:$(p.style)?p.style.parsedOptions:void 0)&&_.scale&&(u*=_.scale||1),s.push({type:Be.literal,value:n.getNumberFormat(t,_).format(u)})}else{if(Z(p)){var h=p.children,f=p.value,m=r[f];if(!Ge(m))throw new Fe(f,"function",o);var g=m(ze(h,t,n,i,r,a).map((function(e){return e.value})));Array.isArray(g)||(g=[g]),s.push.apply(s,g.map((function(e){return{type:"string"==typeof e?Be.literal:Be.object,value:e}})))}if(G(p)){if(!(v=p.options[u]||p.options.other))throw new je(p.value,u,Object.keys(p.options),o);s.push.apply(s,ze(v.value,t,n,i,r))}else if(z(p)){var v;if(!(v=p.options["=".concat(u)])){if(!Intl.PluralRules)throw new He('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',Ce.MISSING_INTL_API,o);var b=n.getPluralRules(t,{type:p.pluralType}).select(u-(p.offset||0));v=p.options[b]||p.options.other}if(!v)throw new je(p.value,u,Object.keys(p.options),o);s.push.apply(s,ze(v.value,t,n,i,r,u-(p.offset||0)))}else;}}}return function(e){return e.length<2?e:e.reduce((function(e,t){var n=e[e.length-1];return n&&n.type===Be.literal&&t.type===Be.literal?n.value+=t.value:e.push(t),e}),[])}(s)}function Ve(e,t){return t?Object.keys(e).reduce((function(n,i){var r,a;return n[i]=(r=e[i],(a=t[i])?y(y(y({},r||{}),a||{}),Object.keys(r).reduce((function(e,t){return e[t]=y(y({},r[t]),a[t]||{}),e}),{})):r),n}),y({},e)):e}function Ze(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}!function(e){e[e.literal=0]="literal",e[e.object=1]="object"}(Be||(Be={}));var $e,We=function(){function e(t,n,i,r){void 0===n&&(n=e.defaultLocale);var a,o=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(e){var t=o.formatToParts(e);if(1===t.length)return t[0].value;var n=t.reduce((function(e,t){return e.length&&t.type===Be.literal&&"string"==typeof e[e.length-1]?e[e.length-1]+=t.value:e.push(t.value),e}),[]);return n.length<=1?n[0]||"":n},this.formatToParts=function(e){return ze(o.ast,o.locales,o.formatters,o.formats,e,void 0,o.message)},this.resolvedOptions=function(){var e;return{locale:(null===(e=o.resolvedLocale)||void 0===e?void 0:e.toString())||Intl.NumberFormat.supportedLocalesOf(o.locales)[0]}},this.getAst=function(){return o.ast},this.locales=n,this.resolvedLocale=e.resolveLocale(n),"string"==typeof t){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var s=r||{};s.formatters;var c=x(s,["formatters"]);this.ast=e.__parse(t,y(y({},c),{locale:this.resolvedLocale}))}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=Ve(e.formats,i),this.formatters=r&&r.formatters||(void 0===(a=this.formatterCache)&&(a={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,E([void 0],t,!1)))}),{cache:Ze(a.number),strategy:U.variadic}),getDateTimeFormat:N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,E([void 0],t,!1)))}),{cache:Ze(a.dateTime),strategy:U.variadic}),getPluralRules:N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,E([void 0],t,!1)))}),{cache:Ze(a.pluralRules),strategy:U.variadic})})}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=(new Intl.NumberFormat).resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.resolveLocale=function(e){if(void 0!==Intl.Locale){var t=Intl.NumberFormat.supportedLocalesOf(e);return t.length>0?new Intl.Locale(t[0]):new Intl.Locale("string"==typeof e?e:e[0])}},e.__parse=Ue,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}();!function(e){e.FORMAT_ERROR="FORMAT_ERROR",e.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",e.INVALID_CONFIG="INVALID_CONFIG",e.MISSING_DATA="MISSING_DATA",e.MISSING_TRANSLATION="MISSING_TRANSLATION"}($e||($e={}));var Ke=function(e){function t(n,i,r){var a=this,o=r?r instanceof Error?r:new Error(String(r)):void 0;return(a=e.call(this,"[@formatjs/intl Error ".concat(n,"] ").concat(i,"\n").concat(o?"\n".concat(o.message,"\n").concat(o.stack):""))||this).code=n,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(a,t),a}return w(t,e),t}(Error),qe=function(e){function t(t,n){return e.call(this,$e.UNSUPPORTED_FORMATTER,t,n)||this}return w(t,e),t}(Ke),Xe=function(e){function t(t,n){return e.call(this,$e.INVALID_CONFIG,t,n)||this}return w(t,e),t}(Ke),Ye=function(e){function t(t,n){return e.call(this,$e.MISSING_DATA,t,n)||this}return w(t,e),t}(Ke),Je=function(e){function t(t,n,i){var r=e.call(this,$e.FORMAT_ERROR,"".concat(t,"\nLocale: ").concat(n,"\n"),i)||this;return r.locale=n,r}return w(t,e),t}(Ke),Qe=function(e){function t(t,n,i,r){var a=e.call(this,"".concat(t,"\nMessageID: ").concat(null==i?void 0:i.id,"\nDefault Message: ").concat(null==i?void 0:i.defaultMessage,"\nDescription: ").concat(null==i?void 0:i.description,"\n"),n,r)||this;return a.descriptor=i,a.locale=n,a}return w(t,e),t}(Je),et=function(e){function t(t,n){var i=e.call(this,$e.MISSING_TRANSLATION,'Missing message: "'.concat(t.id,'" for locale "').concat(n,'", using ').concat(t.defaultMessage?"default message (".concat("string"==typeof t.defaultMessage?t.defaultMessage:t.defaultMessage.map((function(e){var t;return null!==(t=e.value)&&void 0!==t?t:JSON.stringify(e)})).join(),")"):"id"," as fallback."))||this;return i.descriptor=t,i}return w(t,e),t}(Ke);function tt(e,t,n){return void 0===n&&(n={}),t.reduce((function(t,i){return i in e?t[i]=e[i]:i in n&&(t[i]=n[i]),t}),{})}var nt={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:function(e){"production"!==process.env.NODE_ENV&&console.error(e)},onWarn:function(e){"production"!==process.env.NODE_ENV&&console.warn(e)}};function it(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function rt(e,t,n,i){var r,a=e&&e[t];if(a&&(r=a[n]),r)return r;i(new qe("No ".concat(t," format named: ").concat(n)))}function at(e,t){return Object.keys(e).reduce((function(n,i){return n[i]=y({timeZone:t},e[i]),n}),{})}function ot(e,t){return Object.keys(y(y({},e),t)).reduce((function(n,i){return n[i]=y(y({},e[i]||{}),t[i]||{}),n}),{})}function st(e,t){if(!t)return e;var n=We.formats;return y(y(y({},n),e),{date:ot(at(n.date,t),at(e.date||{},t)),time:ot(at(n.time,t),at(e.time||{},t))})}var ct=function(e,t,n,i,r){var a=e.locale,o=e.formats,s=e.messages,c=e.defaultLocale,l=e.defaultFormats,p=e.fallbackOnEmptyString,d=e.onError,u=e.timeZone,_=e.defaultRichTextElements;void 0===n&&(n={id:""});var h=n.id,f=n.defaultMessage;!function(e,t,n){if(void 0===n&&(n=Error),!e)throw new n(t)}(!!h,"[@formatjs/intl] An `id` must be provided to format a message. You can either:\n1. Configure your build toolchain with [babel-plugin-formatjs](https://formatjs.github.io/docs/tooling/babel-plugin)\nor [@formatjs/ts-transformer](https://formatjs.github.io/docs/tooling/ts-transformer) OR\n2. Configure your `eslint` config to include [eslint-plugin-formatjs](https://formatjs.github.io/docs/tooling/linter#enforce-id)\nto autofix this issue");var m=String(h),g=s&&Object.prototype.hasOwnProperty.call(s,m)&&s[m];if(Array.isArray(g)&&1===g.length&&g[0].type===P.literal)return g[0].value;if(!i&&g&&"string"==typeof g&&!_)return g.replace(/'\{(.*?)\}'/gi,"{$1}");if(i=y(y({},_),i||{}),o=st(o,u),l=st(l,u),!g){if(!1===p&&""===g)return g;if((!f||a&&a.toLowerCase()!==c.toLowerCase())&&d(new et(n,a)),f)try{return t.getMessageFormat(f,c,l,r).format(i)}catch(e){return d(new Qe('Error formatting default message for: "'.concat(m,'", rendering default message verbatim'),a,n,e)),"string"==typeof f?f:m}return m}try{return t.getMessageFormat(g,a,o,y({formatters:t},r||{})).format(i)}catch(e){d(new Qe('Error formatting message: "'.concat(m,'", using ').concat(f?"default message":"id"," as fallback."),a,n,e))}if(f)try{return t.getMessageFormat(f,c,l,r).format(i)}catch(e){d(new Qe('Error formatting the default message for: "'.concat(m,'", rendering message verbatim'),a,n,e))}return"string"==typeof g?g:"string"==typeof f?f:m},lt=["formatMatcher","timeZone","hour12","weekday","era","year","month","day","hour","minute","second","timeZoneName","hourCycle","dateStyle","timeStyle","calendar","numberingSystem","fractionalSecondDigits"];function pt(e,t,n,i){var r=e.locale,a=e.formats,o=e.onError,s=e.timeZone;void 0===i&&(i={});var c=i.format,l=y(y({},s&&{timeZone:s}),c&&rt(a,t,c,o)),p=tt(i,lt,l);return"time"!==t||p.hour||p.minute||p.second||p.timeStyle||p.dateStyle||(p=y(y({},p),{hour:"numeric",minute:"numeric"})),n(r,p)}function dt(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];var r=n[0],a=n[1],o=void 0===a?{}:a,s="string"==typeof r?new Date(r||0):r;try{return pt(e,"date",t,o).format(s)}catch(t){e.onError(new Je("Error formatting date.",e.locale,t))}return String(s)}function ut(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];var r=n[0],a=n[1],o=void 0===a?{}:a,s="string"==typeof r?new Date(r||0):r;try{return pt(e,"time",t,o).format(s)}catch(t){e.onError(new Je("Error formatting time.",e.locale,t))}return String(s)}function _t(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];var r=n[0],a=n[1],o=n[2],s=void 0===o?{}:o,c="string"==typeof r?new Date(r||0):r,l="string"==typeof a?new Date(a||0):a;try{return pt(e,"dateTimeRange",t,s).formatRange(c,l)}catch(t){e.onError(new Je("Error formatting date time range.",e.locale,t))}return String(c)}function ht(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];var r=n[0],a=n[1],o=void 0===a?{}:a,s="string"==typeof r?new Date(r||0):r;try{return pt(e,"date",t,o).formatToParts(s)}catch(t){e.onError(new Je("Error formatting date.",e.locale,t))}return[]}function ft(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];var r=n[0],a=n[1],o=void 0===a?{}:a,s="string"==typeof r?new Date(r||0):r;try{return pt(e,"time",t,o).formatToParts(s)}catch(t){e.onError(new Je("Error formatting time.",e.locale,t))}return[]}var mt=["style","type","fallback","languageDisplay"];function gt(e,t,n,i){var r=e.locale,a=e.onError;Intl.DisplayNames||a(new He('Intl.DisplayNames is not available in this environment.\nTry polyfilling it using "@formatjs/intl-displaynames"\n',Ce.MISSING_INTL_API));var o=tt(i,mt);try{return t(r,o).of(n)}catch(e){a(new Je("Error formatting display name.",r,e))}}var vt=["type","style"],bt=Date.now();function wt(e,t,n,i){void 0===i&&(i={});var r=yt(e,t,n,i).reduce((function(e,t){var n=t.value;return"string"!=typeof n?e.push(n):"string"==typeof e[e.length-1]?e[e.length-1]+=n:e.push(n),e}),[]);return 1===r.length?r[0]:0===r.length?"":r}function yt(e,t,n,i){var r=e.locale,a=e.onError;void 0===i&&(i={}),Intl.ListFormat||a(new He('Intl.ListFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-listformat"\n',Ce.MISSING_INTL_API));var o=tt(i,vt);try{var s={},c=n.map((function(e,t){if("object"==typeof e){var n=function(e){return"".concat(bt,"_").concat(e,"_").concat(bt)}(t);return s[n]=e,n}return String(e)}));return t(r,o).formatToParts(c).map((function(e){return"literal"===e.type?e:y(y({},e),{value:s[e.value]||e.value})}))}catch(e){a(new Je("Error formatting list.",r,e))}return n}var xt=["type"];function kt(e,t,n,i){var r=e.locale,a=e.onError;void 0===i&&(i={}),Intl.PluralRules||a(new He('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',Ce.MISSING_INTL_API));var o=tt(i,xt);try{return t(r,o).select(n)}catch(e){a(new Je("Error formatting plural.",r,e))}return"other"}var Et=["numeric","style"];function Nt(e,t,n,i,r){void 0===r&&(r={}),i||(i="second"),Intl.RelativeTimeFormat||e.onError(new He('Intl.RelativeTimeFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-relativetimeformat"\n',Ce.MISSING_INTL_API));try{return function(e,t,n){var i=e.locale,r=e.formats,a=e.onError;void 0===n&&(n={});var o=n.format,s=!!o&&rt(r,"relative",o,a)||{};return t(i,tt(n,Et,s))}(e,t,r).format(n,i)}catch(t){e.onError(new Je("Error formatting relative time.",e.locale,t))}return String(n)}var St=["style","currency","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","currencyDisplay","currencySign","notation","signDisplay","unit","unitDisplay","numberingSystem","trailingZeroDisplay","roundingPriority","roundingIncrement","roundingMode"];function Tt(e,t,n){var i=e.locale,r=e.formats,a=e.onError;void 0===n&&(n={});var o=n.format,s=o&&rt(r,"number",o,a)||{};return t(i,tt(n,St,s))}function At(e,t,n,i){void 0===i&&(i={});try{return Tt(e,t,i).format(n)}catch(t){e.onError(new Je("Error formatting number.",e.locale,t))}return String(n)}function Mt(e,t,n,i){void 0===i&&(i={});try{return Tt(e,t,i).formatToParts(n)}catch(t){e.onError(new Je("Error formatting number.",e.locale,t))}return[]}function Ct(e){var t;e.onWarn&&e.defaultRichTextElements&&"string"==typeof((t=e.messages||{})?t[Object.keys(t)[0]]:void 0)&&e.onWarn('[@formatjs/intl] "defaultRichTextElements" was specified but "message" was not pre-compiled. \nPlease consider using "@formatjs/cli" to pre-compile your messages for performance.\nFor more details see https://formatjs.github.io/docs/getting-started/message-distribution')}function Pt(e,t){var n=function(e){void 0===e&&(e={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}});var t=Intl.RelativeTimeFormat,n=Intl.ListFormat,i=Intl.DisplayNames,r=N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,E([void 0],t,!1)))}),{cache:it(e.dateTime),strategy:U.variadic}),a=N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,E([void 0],t,!1)))}),{cache:it(e.number),strategy:U.variadic}),o=N((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,E([void 0],t,!1)))}),{cache:it(e.pluralRules),strategy:U.variadic});return{getDateTimeFormat:r,getNumberFormat:a,getMessageFormat:N((function(e,t,n,i){return new We(e,t,n,y({formatters:{getNumberFormat:a,getDateTimeFormat:r,getPluralRules:o}},i||{}))}),{cache:it(e.message),strategy:U.variadic}),getRelativeTimeFormat:N((function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new(t.bind.apply(t,E([void 0],e,!1)))}),{cache:it(e.relativeTime),strategy:U.variadic}),getPluralRules:o,getListFormat:N((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(n.bind.apply(n,E([void 0],e,!1)))}),{cache:it(e.list),strategy:U.variadic}),getDisplayNames:N((function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(i.bind.apply(i,E([void 0],e,!1)))}),{cache:it(e.displayNames),strategy:U.variadic})}}(t),i=y(y({},nt),e),r=i.locale,a=i.defaultLocale,o=i.onError;return r?!Intl.NumberFormat.supportedLocalesOf(r).length&&o?o(new Ye('Missing locale data for locale: "'.concat(r,'" in Intl.NumberFormat. Using default locale: "').concat(a,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):!Intl.DateTimeFormat.supportedLocalesOf(r).length&&o&&o(new Ye('Missing locale data for locale: "'.concat(r,'" in Intl.DateTimeFormat. Using default locale: "').concat(a,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):(o&&o(new Xe('"locale" was not configured, using "'.concat(a,'" as fallback. See https://formatjs.github.io/docs/react-intl/api#intlshape for more details'))),i.locale=i.defaultLocale||"en"),Ct(i),y(y({},i),{formatters:n,formatNumber:At.bind(null,i,n.getNumberFormat),formatNumberToParts:Mt.bind(null,i,n.getNumberFormat),formatRelativeTime:Nt.bind(null,i,n.getRelativeTimeFormat),formatDate:dt.bind(null,i,n.getDateTimeFormat),formatDateToParts:ht.bind(null,i,n.getDateTimeFormat),formatTime:ut.bind(null,i,n.getDateTimeFormat),formatDateTimeRange:_t.bind(null,i,n.getDateTimeFormat),formatTimeToParts:ft.bind(null,i,n.getDateTimeFormat),formatPlural:kt.bind(null,i,n.getPluralRules),formatMessage:ct.bind(null,i,n),$t:ct.bind(null,i,n),formatList:wt.bind(null,i,n.getListFormat),formatListToParts:yt.bind(null,i,n.getListFormat),formatDisplayName:gt.bind(null,i,n.getDisplayNames)})}function Lt(e){!function(e,t,n){if(void 0===n&&(n=Error),!e)throw new n(t)}(e,"[React Intl] Could not find required `intl` object. <IntlProvider> needs to exist in the component ancestry.")}var Ot=y(y({},nt),{textComponent:i.Fragment}),Rt={key:42},It=function(e){return i.isValidElement(e)?i.createElement(i.Fragment,Rt,e):e};function Ut(e,t){if(e===t)return!0;if(!e||!t)return!1;var n=Object.keys(e),i=Object.keys(t),r=n.length;if(i.length!==r)return!1;for(var a=0;a<r;a++){var o=n[a];if(e[o]!==t[o]||!Object.prototype.hasOwnProperty.call(t,o))return!1}return!0}function Bt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ht,jt={exports:{}},Ft={};var Dt,Gt,zt,Vt,Zt={};
2
+ /** @license React v16.13.1
3
+ * react-is.development.js
4
+ *
5
+ * Copyright (c) Facebook, Inc. and its affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */function $t(){return Gt||(Gt=1,"production"===process.env.NODE_ENV?jt.exports=function(){if(Ht)return Ft;Ht=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,i=e?Symbol.for("react.fragment"):60107,r=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,p=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,u=e?Symbol.for("react.suspense_list"):60120,_=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,v=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var u=e.$$typeof;switch(u){case t:switch(e=e.type){case c:case l:case i:case a:case r:case d:return e;default:switch(e=e&&e.$$typeof){case s:case p:case h:case _:case o:return e;default:return u}}case n:return u}}}function w(e){return b(e)===l}return Ft.AsyncMode=c,Ft.ConcurrentMode=l,Ft.ContextConsumer=s,Ft.ContextProvider=o,Ft.Element=t,Ft.ForwardRef=p,Ft.Fragment=i,Ft.Lazy=h,Ft.Memo=_,Ft.Portal=n,Ft.Profiler=a,Ft.StrictMode=r,Ft.Suspense=d,Ft.isAsyncMode=function(e){return w(e)||b(e)===c},Ft.isConcurrentMode=w,Ft.isContextConsumer=function(e){return b(e)===s},Ft.isContextProvider=function(e){return b(e)===o},Ft.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Ft.isForwardRef=function(e){return b(e)===p},Ft.isFragment=function(e){return b(e)===i},Ft.isLazy=function(e){return b(e)===h},Ft.isMemo=function(e){return b(e)===_},Ft.isPortal=function(e){return b(e)===n},Ft.isProfiler=function(e){return b(e)===a},Ft.isStrictMode=function(e){return b(e)===r},Ft.isSuspense=function(e){return b(e)===d},Ft.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===l||e===a||e===r||e===d||e===u||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===_||e.$$typeof===o||e.$$typeof===s||e.$$typeof===p||e.$$typeof===m||e.$$typeof===g||e.$$typeof===v||e.$$typeof===f)},Ft.typeOf=b,Ft}():jt.exports=(Dt||(Dt=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,i=e?Symbol.for("react.fragment"):60107,r=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,p=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,u=e?Symbol.for("react.suspense_list"):60120,_=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,v=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var u=e.$$typeof;switch(u){case t:var f=e.type;switch(f){case c:case l:case i:case a:case r:case d:return f;default:var m=f&&f.$$typeof;switch(m){case s:case p:case h:case _:case o:return m;default:return u}}case n:return u}}}var w=c,y=l,x=s,k=o,E=t,N=p,S=i,T=h,A=_,M=n,C=a,P=r,L=d,O=!1;function R(e){return b(e)===l}Zt.AsyncMode=w,Zt.ConcurrentMode=y,Zt.ContextConsumer=x,Zt.ContextProvider=k,Zt.Element=E,Zt.ForwardRef=N,Zt.Fragment=S,Zt.Lazy=T,Zt.Memo=A,Zt.Portal=M,Zt.Profiler=C,Zt.StrictMode=P,Zt.Suspense=L,Zt.isAsyncMode=function(e){return O||(O=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),R(e)||b(e)===c},Zt.isConcurrentMode=R,Zt.isContextConsumer=function(e){return b(e)===s},Zt.isContextProvider=function(e){return b(e)===o},Zt.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Zt.isForwardRef=function(e){return b(e)===p},Zt.isFragment=function(e){return b(e)===i},Zt.isLazy=function(e){return b(e)===h},Zt.isMemo=function(e){return b(e)===_},Zt.isPortal=function(e){return b(e)===n},Zt.isProfiler=function(e){return b(e)===a},Zt.isStrictMode=function(e){return b(e)===r},Zt.isSuspense=function(e){return b(e)===d},Zt.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===l||e===a||e===r||e===d||e===u||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===_||e.$$typeof===o||e.$$typeof===s||e.$$typeof===p||e.$$typeof===m||e.$$typeof===g||e.$$typeof===v||e.$$typeof===f)},Zt.typeOf=b}()),Zt)),jt.exports}!function(){if(Vt)return zt;Vt=1;var e=$t(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},n={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},r={};function a(n){return e.isMemo(n)?i:r[n.$$typeof]||t}r[e.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},r[e.Memo]=i;var o=Object.defineProperty,s=Object.getOwnPropertyNames,c=Object.getOwnPropertySymbols,l=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,d=Object.prototype;zt=function e(t,i,r){if("string"!=typeof i){if(d){var u=p(i);u&&u!==d&&e(t,u,r)}var _=s(i);c&&(_=_.concat(c(i)));for(var h=a(t),f=a(i),m=0;m<_.length;++m){var g=_[m];if(!(n[g]||r&&r[g]||f&&f[g]||h&&h[g])){var v=l(i,g);try{o(t,g,v)}catch(e){}}}}return t}}();var Wt="undefined"==typeof window||window.__REACT_INTL_BYPASS_GLOBAL_CONTEXT__?i.createContext(null):window.__REACT_INTL_CONTEXT__||(window.__REACT_INTL_CONTEXT__=i.createContext(null));Wt.Consumer;var Kt,qt,Xt=Wt.Provider,Yt=Wt;function Jt(){var e=i.useContext(Yt);return Lt(e),e}function Qt(e){var t=function(t){var n=Jt(),i=t.value,r=t.children,a=x(t,["value","children"]),o="string"==typeof i?new Date(i||0):i;return r("formatDate"===e?n.formatDateToParts(o,a):n.formatTimeToParts(o,a))};return t.displayName=qt[e],t}function en(e){var t=function(t){var n=Jt(),r=t.value,a=t.children,o=x(t,["value","children"]),s=n[e](r,o);if("function"==typeof a)return a(s);var c=n.textComponent||i.Fragment;return i.createElement(c,null,s)};return t.displayName=Kt[e],t}function tn(e){return e?Object.keys(e).reduce((function(t,n){var r,a=e[n];return t[n]=Ge(a)?(r=a,function(e){return r(i.Children.toArray(e))}):a,t}),{}):e}!function(e){e.formatDate="FormattedDate",e.formatTime="FormattedTime",e.formatNumber="FormattedNumber",e.formatList="FormattedList",e.formatDisplayName="FormattedDisplayName"}(Kt||(Kt={})),function(e){e.formatDate="FormattedDateParts",e.formatTime="FormattedTimeParts",e.formatNumber="FormattedNumberParts",e.formatList="FormattedListParts"}(qt||(qt={}));var nn=function(e,t,n,r){for(var a=[],o=4;o<arguments.length;o++)a[o-4]=arguments[o];var s=tn(r),c=ct.apply(void 0,E([e,t,n,s],a,!1));return Array.isArray(c)?function(e){var t;return null!==(t=i.Children.map(e,It))&&void 0!==t?t:[]}(c):c},rn=function(e,t){var n=e.defaultRichTextElements,i=x(e,["defaultRichTextElements"]),r=tn(n),a=Pt(y(y(y({},Ot),i),{defaultRichTextElements:r}),t),o={locale:a.locale,timeZone:a.timeZone,fallbackOnEmptyString:a.fallbackOnEmptyString,formats:a.formats,defaultLocale:a.defaultLocale,defaultFormats:a.defaultFormats,messages:a.messages,onError:a.onError,defaultRichTextElements:r};return y(y({},a),{formatMessage:nn.bind(null,o,a.formatters),$t:nn.bind(null,o,a.formatters)})};function an(e){var t=Jt(),n=t.formatMessage,r=t.textComponent,a=void 0===r?i.Fragment:r,o=e.id,s=e.description,c=e.defaultMessage,l=e.values,p=e.children,d=e.tagName,u=void 0===d?a:d,_=n({id:o,description:s,defaultMessage:c},l,{ignoreTag:e.ignoreTag});return"function"==typeof p?p(Array.isArray(_)?_:[_]):u?i.createElement(u,null,_):i.createElement(i.Fragment,null,_)}an.displayName="FormattedMessage";var on=i.memo(an,(function(e,t){var n=e.values,i=x(e,["values"]),r=t.values,a=x(t,["values"]);return Ut(r,n)&&Ut(i,a)}));function sn(e){return{locale:e.locale,timeZone:e.timeZone,fallbackOnEmptyString:e.fallbackOnEmptyString,formats:e.formats,textComponent:e.textComponent,messages:e.messages,defaultLocale:e.defaultLocale,defaultFormats:e.defaultFormats,onError:e.onError,onWarn:e.onWarn,wrapRichTextChunksInFragment:e.wrapRichTextChunksInFragment,defaultRichTextElements:e.defaultRichTextElements}}on.displayName="MemoizedFormattedMessage";var cn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.cache={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}},t.state={cache:t.cache,intl:rn(sn(t.props),t.cache),prevConfig:sn(t.props)},t}return w(t,e),t.getDerivedStateFromProps=function(e,t){var n=t.prevConfig,i=t.cache,r=sn(e);return Ut(n,r)?null:{intl:rn(r,i),prevConfig:r}},t.prototype.render=function(){return Lt(this.state.intl),i.createElement(Xt,{value:this.state.intl},this.props.children)},t.displayName="IntlProvider",t.defaultProps=Ot,t}(i.PureComponent);function ln(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css","top"===n&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}en("formatDate"),en("formatTime"),en("formatNumber"),en("formatList"),en("formatDisplayName"),Qt("formatDate"),Qt("formatTime");function pn({children:n,theme:i}){return e("div",{className:"notificare__android-phone-background__wrapper "+("dark"===i?"notificare__android-phone-background__wrapper--dark":""),"data-testid":"android-phone-background",children:[t("div",{className:"notificare__android-phone-background__camera"}),t("div",{className:"notificare__android-phone-background__content",children:n})]})}ln(".notificare .notificare__android-phone-background__wrapper {\n width: 350px;\n border-radius: 40px;\n border: 6px solid #c6c6c6;\n background-color: #fff;\n overflow: hidden;\n}\n\n.notificare .notificare__android-phone-background__wrapper--dark {\n background-color: #9ea2a1;\n border-color: #eaeaea;\n}\n\n.notificare .notificare__android-phone-background__camera {\n width: 20px;\n height: 20px;\n background: #c6c6c6;\n border-radius: 50%;\n margin: 20px auto 10px;\n}\n\n.notificare .notificare__android-phone-background__content {\n width: 100%;\n height: 615px;\n overflow: hidden;\n position: relative;\n}");var dn;function un({children:n,theme:i}){return e("div",{className:"notificare__ios-phone-background__wrapper "+("dark"===i?"notificare__ios-phone-background__wrapper--dark":""),"data-testid":"ios-phone-background",children:[t("div",{className:"notificare__ios-phone-background__camera"}),t("div",{className:"notificare__ios-phone-background__content",children:n})]})}function _n(){return _n=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},_n.apply(null,arguments)}ln(".notificare .notificare__ios-phone-background__wrapper {\n width: 350px;\n border-radius: 40px;\n border: 6px solid #c6c6c6;\n background-color: #fff;\n overflow: hidden;\n}\n\n.notificare .notificare__ios-phone-background__wrapper--dark {\n background-color: #9ea2a1;\n border-color: #eaeaea;\n}\n\n.notificare .notificare__ios-phone-background__camera {\n width: 80px;\n height: 20px;\n background: #c6c6c6;\n margin: 20px auto 10px;\n border-radius: 20px;\n}\n\n.notificare .notificare__ios-phone-background__content {\n width: 100%;\n height: 615px;\n overflow: hidden;\n position: relative;\n}");var hn,fn=function(e){return i.createElement("svg",_n({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",width:"1em",height:"1em"},e),dn||(dn=i.createElement("path",{fill:"#64706e",d:"M222.7 32.1c5 16.9-4.6 34.8-21.5 39.8C121.8 95.6 64 169.1 64 256c0 106 86 192 192 192s192-86 192-192c0-86.9-57.8-160.4-137.1-184.1-16.9-5-26.6-22.9-21.5-39.8s22.9-26.6 39.8-21.5C434.9 42.1 512 140 512 256c0 141.4-114.6 256-256 256S0 397.4 0 256C0 140 77.1 42.1 182.9 10.6c16.9-5 34.8 4.6 39.8 21.5"})))};function mn(){return t("div",{className:"notificare__loading__wrapper","data-testid":"loading",children:t(fn,{className:"notificare__loading__icon"})})}function gn(){return gn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},gn.apply(null,arguments)}ln(".notificare .notificare__loading__wrapper {\n width: 100%;\n display: flex;\n justify-content: center;\n padding-top: 50px;\n}\n\n.notificare .notificare__loading__icon {\n width: 60px;\n height: 60px;\n animation: notificare-loading-icon-spin 2s linear infinite;\n}\n\n@keyframes notificare-loading-icon-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}");var vn=function(e){return i.createElement("svg",gn({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",width:"1em",height:"1em"},e),hn||(hn=i.createElement("path",{d:"M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7.2 40.1S486.3 480 472 480H40c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8.2-40.1l216-368C228.7 39.5 241.8 32 256 32m0 128c-13.3 0-24 10.7-24 24v112c0 13.3 10.7 24 24 24s24-10.7 24-24V184c0-13.3-10.7-24-24-24m32 224a32 32 0 1 0-64 0 32 32 0 1 0 64 0"})))};const bn={"controls.platform":"Platform","controls.formFactor":"Form Factor","controls.operatingSystem":"OS","controls.operatingSystem.macos":"macOS","controls.variant":"Variant","controls.displayMode.lockScreen":"Lock Screen","controls.displayMode.expandedLockScreen":"Lock Screen - Expanded","controls.displayMode.appUi":"App UI","preview.error.notGeneratedPreview":"Preview could not be generated","preview.error.checkConsole":"Check console for more information","preview.error.invalidNotification":"→ Invalid Notification","preview.error.provideGoogleMapsApiKey":"→ A Google Maps API key should be provided","preview.error.notSupportedPreviewVariant":"→ Not supported variant","preview.error.invalidUrl":"The URL is invalid.","preview.error.iosStoreAppNotFound":"The app was not found. Check the unique identifier and try again","preview.error.webshotFail":"Webshot failed to be loaded. Check console for more details.","preview.error.notSupportedNotificationTypePreviewVariant":"→ Previewing notifications of type ''{notificationType}'' is not possible in this variant","preview.error.notSupportedUrlResolverWithUrlSchemePreview":"→ Previewing notifications of type 're.notifica.notification.URLResolver' with a custom URL Scheme is not possible","preview.error.urlResolverInvalidUrl":"→ The provided URL is invalid","preview.error.urlResolverNoNotificareWebViewQueryParameter":"→ Previewing notifications of type 're.notifica.notification.URLResolver' with an HTTP URL without 'notificareWebView' query parameter is not possible in this variant","preview.error.notSupportedUrlResolverWithDynamicLink":"→ Previewing notifications of type 're.notifica.notification.URLResolver' with a dynamic link is not possible","preview.error.notSupportedUrlResolverWithRelativeUrl":"→ Previewing notifications of type 're.notifica.notification.URLResolver' with a relative URL (starts with '/') is not possible","preview.error.googleMapsAuthFailure":"Authentication failure. Your Google Maps API key might be invalid. Check console for more information.","preview.error.googleMapsLoadFailure":"Google Maps failed to be loaded. Check console for more information.","preview.error.noValidContentObject":"No valid content object was provided","preview.error.iosStoreAppLoadFailure":"The app failed to be loaded. Check console for more details","preview.android.alert.appUi.cancel":"Cancel","preview.android.inAppBrowser.appUi.pageTitleLoading":"Loading...","preview.android.lockscreen.time":"now","preview.ios.alert.appUi.cancel":"Cancel","preview.ios.alert.appUi.ok":"OK","preview.ios.inAppBrowser.appUi.done":"Done","preview.ios.inAppBrowser.appUi.notSecure":"Not Secure —","preview.ios.rate.appUi.rateNow":"Yes, I'll Rate Now","preview.ios.rate.appUi.doNotRate":"No, Thanks","preview.ios.store.appUi.done":"Done","preview.ios.store.appUi.install":"Install","preview.ios.store.appUi.ratings":"{userRatingCount, number, ::compact-short} Ratings","preview.ios.store.appUi.age":"Age","preview.ios.store.appUi.yearsOld":"Years Old","preview.ios.store.appUi.category":"Category","preview.ios.store.appUi.developer":"Developer","preview.ios.store.appUi.whatsNew":"What's New","preview.ios.store.appUi.historyVersion":"Version {version}","preview.ios.store.appUi.screenshots":"Screenshots","preview.ios.lockScreen.time":"Now","preview.web.desktop.macos.lockScreen.time":"now","preview.web.desktop.macos.lockScreen.settings":"Settings","preview.web.desktop.macos.lockScreen.options":"Options"};var wn;function yn({message:i}){const r=Jt();return e("div",{className:"notificare__preview-error__wrapper","data-testid":"preview-error",children:[t(vn,{className:"notificare__preview-error__icon"}),e("p",{className:"notificare__preview-error__text",children:[r.formatMessage({id:"preview.error.notGeneratedPreview",defaultMessage:bn["preview.error.notGeneratedPreview"]}),i&&e(n,{children:[t("br",{})," ",t("br",{})," ",i]})]})]})}function xn(){return xn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},xn.apply(null,arguments)}ln(".notificare .notificare__preview-error__wrapper {\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n width: 100%;\n height: 440px;\n text-align: center;\n padding: 0 20px;\n}\n\n.notificare .notificare__preview-error__icon {\n width: 72px;\n margin-bottom: 20px;\n height: auto;\n}\n\n.notificare .notificare__preview-error__text {\n font-weight: 700;\n font-size: 16px;\n color: #232c2a;\n}");var kn=function(e){return i.createElement("svg",xn({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",width:"1em",height:"1em"},e),wn||(wn=i.createElement("path",{d:"M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"})))};class En extends Error{constructor(e){super(`Failed to fetch a resource with response code '${e.status}'.`),this.response=e,this.name="NetworkRequestError",Error.captureStackTrace&&Error.captureStackTrace(this,En)}}function Nn(e){return e.startsWith("https://")||e.startsWith("http://")?e:`https://push.notifica.re/upload${e}`}const Sn={name:"My app",icon:void 0,androidPackageName:"com.example.app",websitePushConfig:{icon:void 0,allowedDomains:["https://my-app.com/"]}};function Tn({id:e,serviceKey:t}){const[n,i]=a({status:"idle"});return o((()=>{e?function(e,t){return k(this,void 0,void 0,(function*(){const n=new URL(`/application/${encodeURIComponent(e)}/info`,"https://push.notifica.re");n.searchParams.set("apiKey",t);const i=yield fetch(n);if(!i.ok)throw new En(i);const{application:r}=yield i.json();return{name:r.name,icon:r.icon,androidPackageName:r.androidPackageName,websitePushConfig:r.websitePushConfig&&{icon:r.websitePushConfig.icon?Nn(r.websitePushConfig.icon):void 0,allowedDomains:r.websitePushConfig.allowedDomains}}}))}(e,t).then((e=>{i({status:"success",data:e})})).catch((e=>{console.error("Error fetching the application: ",e),i({status:"success",data:Sn})})):i({status:"success",data:Sn})}),[e]),n}function An(e,t){const[n,i]=a(e);return o((()=>{const n=setTimeout((()=>{i(e)}),t);return()=>{clearTimeout(n)}}),[e,t]),n}function Mn(e){try{return Intl.NumberFormat.supportedLocalesOf([e]).length>0}catch(e){return!1}}const Cn={"preview.error.invalidInAppMessage":"→ Invalid in-app message","preview.error.notGeneratedPreview":"Preview could not be generated","preview.error.checkConsole":"Check console for more information"},Pn={"preview.error.invalidInAppMessage":"→ Message intégré invalide","preview.error.notGeneratedPreview":"L'aperçu n’a pas pu être généré","preview.error.checkConsole":"Consultez la console pour plus d’informations"},Ln={"preview.error.invalidInAppMessage":"→ Mensagem in-app inválida","preview.error.notGeneratedPreview":"Não foi possível gerar a pré-visualização","preview.error.checkConsole":"Consulte a consola para mais informações"},On={"controls.platform":"Plateforme","controls.formFactor":"Format","controls.operatingSystem":"SE","controls.operatingSystem.macos":"macOS","controls.variant":"Variante","controls.displayMode.lockScreen":"Écran verrouillé","controls.displayMode.expandedLockScreen":"Écran verrouillé - Étendu","controls.displayMode.appUi":"App UI","preview.error.notGeneratedPreview":"Aperçu non généré","preview.error.checkConsole":"Consultez la console pour plus d’informations","preview.error.invalidNotification":"→ Notification invalide","preview.error.provideGoogleMapsApiKey":"→ Une clé API Google Maps doit être fournie","preview.error.notSupportedPreviewVariant":"→ Variante non prise en charge","preview.error.invalidUrl":"L’URL est invalide.","preview.error.iosStoreAppNotFound":"L'application n’a pas été trouvée. Vérifiez l’identifiant unique et réessayez","preview.error.webshotFail":"La capture Web a échoué. Consultez la console pour plus de détails.","preview.error.notSupportedNotificationTypePreviewVariant":"→ L’aperçu des notifications de type ''{notificationType}'' n’est pas possible dans cette variante","preview.error.notSupportedUrlResolverWithUrlSchemePreview":"→ L’aperçu des notifications de type 're.notifica.notification.URLResolver' avec un schéma d’URL personnalisé (URL Scheme) n’est pas possible","preview.error.urlResolverInvalidUrl":"→ L’URL fournie est invalide","preview.error.urlResolverNoNotificareWebViewQueryParameter":"→ L’aperçu des notifications de type 're.notifica.notification.URLResolver' avec une URL HTTP sans le paramètre de requête 'notificareWebView' n’est pas possible dans cette variante","preview.error.notSupportedUrlResolverWithDynamicLink":"→ L’aperçu des notifications de type 're.notifica.notification.URLResolver' avec un lien dynamique n’est pas possible","preview.error.notSupportedUrlResolverWithRelativeUrl":"→ L’aperçu des notifications de type 're.notifica.notification.URLResolver' avec une URL relative (commençant par '/') n’est pas possible","preview.error.googleMapsAuthFailure":"Échec de l’authentification. Votre clé API Google Maps pourrait être invalide. Consultez la console pour plus d’informations.","preview.error.googleMapsLoadFailure":"Échec du chargement de Google Maps. Consultez la console pour plus d’informations.","preview.error.noValidContentObject":"Aucun objet de contenu valide fourni","preview.error.iosStoreAppLoadFailure":"Échec du chargement de l’application. Consultez la console pour plus de détails","preview.android.alert.appUi.cancel":"Annuler","preview.android.inAppBrowser.appUi.pageTitleLoading":"Chargement...","preview.android.lockscreen.time":"maintenant","preview.ios.alert.appUi.cancel":"Annuler","preview.ios.alert.appUi.ok":"OK","preview.ios.inAppBrowser.appUi.done":"Terminé","preview.ios.inAppBrowser.appUi.notSecure":"Non Sécurisé —","preview.ios.rate.appUi.rateNow":"Oui, je vais noter maintenant","preview.ios.rate.appUi.doNotRate":"Non, Merci","preview.ios.store.appUi.done":"Terminé","preview.ios.store.appUi.install":"Installer","preview.ios.store.appUi.ratings":"{userRatingCount, number, ::compact-short} Évaluations","preview.ios.store.appUi.age":"Âge","preview.ios.store.appUi.yearsOld":"Ans","preview.ios.store.appUi.category":"Catégorie","preview.ios.store.appUi.developer":"Développeur","preview.ios.store.appUi.whatsNew":"Nouveautés","preview.ios.store.appUi.historyVersion":"Version {version}","preview.ios.store.appUi.screenshots":"Captures d’écran","preview.ios.lockScreen.time":"Maintenant","preview.web.desktop.macos.lockScreen.time":"maintenant","preview.web.desktop.macos.lockScreen.settings":"Réglages","preview.web.desktop.macos.lockScreen.options":"Options"},Rn={"controls.platform":"Plataforma","controls.formFactor":"Formato","controls.operatingSystem":"SO","controls.operatingSystem.macos":"macOS","controls.variant":"Variante","controls.displayMode.lockScreen":"Ecrã de Bloqueio","controls.displayMode.expandedLockScreen":"Ecrã de Bloqueio - Expandido","controls.displayMode.appUi":"App UI","preview.error.notGeneratedPreview":"Não foi possível gerar a pré-visualização","preview.error.checkConsole":"Consulte a consola para mais informações","preview.error.invalidNotification":"→ Notificação inválida","preview.error.provideGoogleMapsApiKey":"→ Deve ser fornecida uma chave de API do Google Maps","preview.error.notSupportedPreviewVariant":"→ Variante não suportada","preview.error.invalidUrl":"A URL é inválida.","preview.error.iosStoreAppNotFound":"A aplicação não foi encontrada. Verifique o identificador único e tente novamente","preview.error.webshotFail":"Não foi possível efetuar a captura da página web. Consulte a consola para mais informações.","preview.error.notSupportedNotificationTypePreviewVariant":"→ A pré-visualização de notificações do tipo ''{notificationType}'' não é possível nesta variante","preview.error.notSupportedUrlResolverWithUrlSchemePreview":"→ A pré-visualização de notificações do tipo 're.notifica.notification.URLResolver' com um esquema de URL personalizado (URL Scheme) não é possível","preview.error.urlResolverInvalidUrl":"→ O URL fornecido é inválido","preview.error.urlResolverNoNotificareWebViewQueryParameter":"→ A pré-visualização de notificações do tipo 're.notifica.notification.URLResolver' com um URL HTTP sem o parâmetro de query 'notificareWebView' não é possível nesta variante","preview.error.notSupportedUrlResolverWithDynamicLink":"→ A pré-visualização de notificações do tipo 're.notifica.notification.URLResolver' com um link dinâmico não é possível","preview.error.notSupportedUrlResolverWithRelativeUrl":"→ A pré-visualização de notificações do tipo 're.notifica.notification.URLResolver' com um URL relativo (que começa por '/') não é possível","preview.error.googleMapsAuthFailure":"Falha de autenticação. A chave da API do Google Maps poderá ser inválida. Consulte a consola para mais informações.","preview.error.googleMapsLoadFailure":"Não foi possível carregar o Google Maps. Consulte a consola para mais informações.","preview.error.noValidContentObject":"Nenhum objeto válido foi fornecido","preview.error.iosStoreAppLoadFailure":"Não foi possível carregar a aplicação. Consulte a consola para mais informações","preview.android.alert.appUi.cancel":"Cancelar","preview.android.inAppBrowser.appUi.pageTitleLoading":"A carregar...","preview.android.lockscreen.time":"agora","preview.ios.alert.appUi.cancel":"Cancelar","preview.ios.alert.appUi.ok":"OK","preview.ios.inAppBrowser.appUi.done":"Concluído","preview.ios.inAppBrowser.appUi.notSecure":"Não seguro —","preview.ios.rate.appUi.rateNow":"Sim, avaliar agora","preview.ios.rate.appUi.doNotRate":"Não, obrigado","preview.ios.store.appUi.done":"OK","preview.ios.store.appUi.install":"Obter","preview.ios.store.appUi.ratings":"{userRatingCount, number, ::compact-short} Classificações","preview.ios.store.appUi.age":"Idade","preview.ios.store.appUi.yearsOld":"Anos","preview.ios.store.appUi.category":"Categoria","preview.ios.store.appUi.developer":"Programador","preview.ios.store.appUi.whatsNew":"Novidades","preview.ios.store.appUi.historyVersion":"Versão {version}","preview.ios.store.appUi.screenshots":"Capturas de ecrã","preview.ios.lockScreen.time":"Agora","preview.web.desktop.macos.lockScreen.time":"agora","preview.web.desktop.macos.lockScreen.settings":"Definições","preview.web.desktop.macos.lockScreen.options":"Opções"};function In({locale:e,customTranslations:t,type:n}){const[i,r]=a({status:"idle"}),c=s((()=>{if(!Mn(e))return null;return function(e,t){switch(e){case"en":return"push"===t?bn:Cn;case"pt":return"push"===t?Rn:Ln;case"fr":return"push"===t?On:Pn;default:return null}}(new Intl.Locale(e).language,n)}),[e,n]);return o((function(){Mn(e)?r({status:"success",data:{locale:e,translations:Object.assign(Object.assign({},c),t)}}):r({status:"error",error:new Error("→ The locale you chose is invalid. Choose a different one and try again")})}),[e,t,c]),i}function Un({label:n,options:i,value:r,onValueChanged:s,disabled:l=!1}){const p=Jt(),[d,u]=a(!1),[_,h]=a((function(){const e=i.find((e=>e.value===r));if(!e)throw new Error(`Value "${String(r)}" not found in the Selector options.`);return p.formatMessage({id:e.labelId,defaultMessage:e.defaultLabel})})),f=c(null),m=c(null);return function({refs:e,onClickOutside:t}){o((()=>{function n(n){e.every((e=>!e.current||!e.current.contains(n.target)))&&t()}return document.addEventListener("mousedown",n),()=>{document.removeEventListener("mousedown",n)}}),[e])}({refs:[f,m],onClickOutside:()=>u(!1)}),e("div",{className:"notificare__selector__wrapper",children:[t("p",{className:"notificare__selector__label",children:n}),e("button",{className:"notificare__selector__button",onClick:()=>u(!d),disabled:l,ref:m,children:[_,t(kn,{className:"notificare__selector__button-expand-icon"})]}),d&&t("div",{className:"notificare__selector__options",ref:f,children:i.map((e=>t("button",{className:"notificare__selector__option-button "+(r===e.value?"notificare__selector__option-button--selected":""),onClick:()=>{null==s||s(e.value),u(!1),h(p.formatMessage({id:e.labelId,defaultMessage:e.defaultLabel}))},"data-testid":`selector-option-${e.value}`,children:p.formatMessage({id:e.labelId,defaultMessage:e.defaultLabel})},e.value)))})]})}ln(".notificare .notificare__selector__wrapper {\n position: relative;\n}\n\n.notificare .notificare__selector__label {\n font-size: 14px;\n color: #6e6e6e;\n margin-bottom: 7px;\n}\n\n.notificare .notificare__selector__button {\n width: 350px;\n height: 42px;\n background-color: #F6F6F6;\n color: #1c1c1c;\n border: 1px solid #E8E8E8;\n text-align: left;\n padding-left: 14px;\n font-size: 16px;\n display: flex;\n align-items: center;\n}\n\n.notificare .notificare__selector__button:not(:disabled) {\n cursor: pointer;\n}\n\n.notificare .notificare__selector__button:disabled {\n color: #b3b3b3;\n}\n\n.notificare .notificare__selector__button-expand-icon {\n width: 16px;\n height: 16px;\n margin-left: auto;\n margin-right: 14px;\n}\n\n.notificare .notificare__selector__button:disabled .notificare__selector__button-expand-icon {\n fill: #b3b3b3;\n}\n\n.notificare .notificare__selector__options {\n display: flex;\n flex-direction: column;\n position: absolute;\n top: 63px;\n z-index: 1;\n box-shadow: 0 14px 10px -10px rgba(0, 0, 0, 0.2);\n}\n\n.notificare .notificare__selector__option-button {\n width: 350px;\n height: 42px;\n background-color: #ececec;\n color: #151515;\n border: 0;\n font-size: 15px;\n text-align: left;\n padding-left: 14px;\n}\n\n.notificare .notificare__selector__option-button--selected {\n background-color: #c8c8c8;\n}\n\n.notificare .notificare__selector__option-button:hover {\n background-color: #5E5E5E;\n color: white;\n cursor: pointer;\n}\n");function Bn({label:n,options:i,value:r,onValueChanged:a}){return e("div",{className:"notificare__toggle-group__wrapper",children:[t("p",{className:"notificare__toggle-group__label","data-testid":`toggle-group-${n}`,children:n}),t("div",{className:"notificare__toggle-group__options",children:i.map(((n,o)=>e(l,{children:[t("button",{className:"notificare__toggle-group__option-button "+(r===n.value?"notificare__toggle-group__option-button--selected":""),onClick:()=>a(n.value),"aria-label":`Button with option '${n.value}'`,"data-testid":`toggle-group-option-${n.value}`,children:t("div",{className:"notificare__toggle-group__option-button-icon "+(r===n.value?"notificare__toggle-group__option-button-icon--selected":""),children:n.icon})}),o!==i.length-1&&t("div",{className:"notificare__toggle-group__border"})]},n.value)))})]})}ln(".notificare .notificare__toggle-group__wrapper {\n display: flex;\n flex-direction: column;\n row-gap: 7px;\n}\n\n.notificare .notificare__toggle-group__label {\n font-size: 14px;\n color: #6e6e6e;\n}\n\n.notificare .notificare__toggle-group__options {\n display: flex;\n border-radius: 8px;\n border: 1px solid #DADADA;\n width: max-content;\n overflow: hidden;\n background-color: #F6F6F6;\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);\n}\n\n.notificare .notificare__toggle-group__option-button {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 40px;\n height: 40px;\n transition: all 0.3s;\n background: #f6f6f6;\n color: #374151;\n border: 0;\n cursor: pointer;\n}\n\n.notificare .notificare__toggle-group__option-button--selected {\n background: #5E5E5E;\n color: #ffffff;\n}\n\n.notificare .notificare__toggle-group__option-button-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n fill: #C0C0C0;\n}\n\n.notificare .notificare__toggle-group__option-button-icon--selected {\n fill: #FFF\n}\n\n.notificare .notificare__toggle-group__border {\n width: 1px;\n height: 40px;\n background: #DADADA;\n}");function Hn({message:n,showConsoleWarning:i}){return e("div",{className:"notificare__unavailable-preview__wrapper","data-testid":"unavailable-preview",children:[e("div",{className:"notificare__unavailable-preview__warning",children:[t(vn,{className:"notificare__unavailable-preview__alert-icon"}),e("div",{className:"notificare__unavailable-preview__text-container",children:[t("div",{className:"notificare__unavailable-preview__title",children:t(on,{id:"preview.error.notGeneratedPreview",defaultMessage:bn["preview.error.notGeneratedPreview"]})}),t("div",{className:"notificare__unavailable-preview__reason-text","data-testid":"unavailable-preview-reason-text",children:n})]})]}),i&&t("div",{className:"notificare__unavailable-preview__check-console-text",children:t(on,{id:"preview.error.checkConsole",defaultMessage:bn["preview.error.checkConsole"]})})]})}ln(".notificare .notificare__unavailable-preview__wrapper {\n width: 350px;\n}\n\n.notificare .notificare__unavailable-preview__warning {\n width: 100%;\n background-color: #fff1cc;\n border: 1px solid #d5d5d5;\n display: flex;\n align-items: center;\n padding: 14px;\n border-radius: 10px;\n column-gap: 14px;\n}\n\n.notificare .notificare__unavailable-preview__text-container {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n width: 100%;\n}\n\n.notificare .notificare__unavailable-preview__title {\n font-size: 15px;\n color: #232323;\n font-weight: bold;\n}\n\n.notificare .notificare__unavailable-preview__reason-text {\n font-size: 13px;\n color: #bd6868;\n}\n\n.notificare .notificare__unavailable-preview__alert-icon {\n width: 40px;\n height: auto;\n}\n\n.notificare .notificare__unavailable-preview__check-console-text {\n font-size: 12px;\n color: #989898;\n text-align: right;\n margin-top: 6px;\n margin-right: 3px;\n font-style: italic;\n position: relative;\n}");const jn=p(void 0);function Fn(e){var{children:n}=e,i=x(e,["children"]);return t(jn.Provider,{value:i,children:n})}function Dn(){const e=d(jn);if(!e)throw new Error("useOptions should be used inside an OptionsProvider");return e}function Gn(e){try{return"https:"===new URL(e).protocol}catch(e){return!1}}function zn(e){try{const t=new URL(e).hostname,n=t.split(".");return n.length>2?n.slice(-2).join("."):t}catch(e){return console.error("Invalid URL:",e),""}}function Vn(e){const{serviceKey:t}=Dn(),n=Jt(),{url:i,platform:r,width:s,height:c}=An(e,500),[l,p]=a({status:"idle"}),[d,u]=a();return o((function(){!function(e){try{return new URL(e),!0}catch(e){return!1}}(i)?p({status:"error",error:new Error(n.formatMessage({id:"preview.error.invalidUrl",defaultMessage:bn["preview.error.invalidUrl"]}))}):(p({status:"loading"}),u(void 0),function(e,t,n,i,r){return k(this,void 0,void 0,(function*(){const a=new URL("/webshot","https://push.notifica.re");a.searchParams.set("apiKey",r);const o=yield fetch(a,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({url:e,delay:3e3,platform:i,type:"png",params:{width:t,height:n}})});if(!o.ok)throw new En(o);return(yield o.json()).webshot.id}))}(i,s,c,r,t).then(u).catch((e=>{console.error("Webshot error:\n\n"+e),p({status:"error",error:new Error(n.formatMessage({id:"preview.error.webshotFail",defaultMessage:bn["preview.error.webshotFail"]}))})})))}),[i,s,c,r,t]),o((function(){if(!d)return;let e;return e=setInterval((()=>k(this,void 0,void 0,(function*(){try{const i=yield function(e,t){return k(this,void 0,void 0,(function*(){const n=new URL(`/webshot/${encodeURIComponent(e)}`,"https://push.notifica.re");n.searchParams.set("apiKey",t);const i=yield fetch(n);if(!i.ok)throw new En(i);return(yield i.json()).webshot}))}(d,t);if("finished"===i.status){const n=yield function(e,t){return k(this,void 0,void 0,(function*(){const n=new URL(`/webshot/${encodeURIComponent(e)}/result`,"https://push.notifica.re");n.searchParams.set("apiKey",t);const i=yield fetch(n);if(!i.ok)throw new En(i);const r=yield i.blob();return URL.createObjectURL(r)}))}(d,t);p({status:"success",data:n}),clearInterval(e)}else"error"===i.status&&(console.error("Webshot error:\n\n"+i.result),p({status:"error",error:new Error(n.formatMessage({id:"preview.error.webshotFail",defaultMessage:bn["preview.error.webshotFail"]}))}),clearInterval(e))}catch(t){console.error("Webshot error:\n\n"+t),p({status:"error",error:new Error(n.formatMessage({id:"preview.error.webshotFail",defaultMessage:bn["preview.error.webshotFail"]}))}),clearInterval(e)}}))),3e3),()=>clearInterval(e)}),[d,t]),l}var Zn;function $n({url:n,platform:i,width:r,height:a,onLoadingChanged:s,canShow:c=!0}){const l=Vn({url:n,platform:i,width:r,height:a});return o((function(){switch(l.status){case"idle":case"loading":null==s||s(!0);break;case"success":case"error":null==s||s(!1)}}),[l]),e("div",{className:"notificare__webshot__wrapper",style:{width:r,height:a},children:["loading"===l.status&&t(mn,{}),"success"===l.status&&c&&t("img",{src:l.data,alt:"Webshot","data-testid":"webshot"}),"error"===l.status&&t(yn,{message:l.error.message})]})}function Wn(){return Wn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Wn.apply(null,arguments)}ln(".notificare .notificare__webshot__wrapper {\n background-color: #fff;\n}");var Kn,qn=function(e){return i.createElement("svg",Wn({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",width:"1em",height:"1em"},e),Zn||(Zn=i.createElement("path",{d:"M144 144v48h160v-48c0-44.2-35.8-80-80-80s-80 35.8-80 80m-64 48v-48C80 64.5 144.5 0 224 0s144 64.5 144 144v48h16c35.3 0 64 28.7 64 64v192c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V256c0-35.3 28.7-64 64-64z"})))};function Xn(){return Xn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Xn.apply(null,arguments)}var Yn=function(e){return i.createElement("svg",Xn({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",width:"1em",height:"1em"},e),Kn||(Kn=i.createElement("path",{d:"M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3l105.4 105.3c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256z"})))};function Jn({url:n,onLoadingChanged:i,canShow:r}){const[s,c]=a(""),[l,p]=a({isLoading:!0}),{serviceKey:d}=Dn(),u=Jt();return o((function(){(()=>{k(this,void 0,void 0,(function*(){Qn(!0,p,i);try{const e=yield function(e,t){return k(this,void 0,void 0,(function*(){var n,i;const r=new URL("/proxy","https://push.notifica.re");r.searchParams.set("apiKey",e),r.searchParams.set("url",t);const a=yield fetch(r),o=yield a.text();return null!==(i=null===(n=(new DOMParser).parseFromString(o,"text/html").querySelector("title"))||void 0===n?void 0:n.textContent)&&void 0!==i?i:""}))}(d,n);c(e)}catch(e){console.error("Error while getting page title:\n\n",e)}Qn(!1,p,i)}))})()}),[n]),e("div",{className:"notificare__push__android__in-app-browser__app-ui__bar",children:[t(Yn,{className:"notificare__push__android__in-app-browser__app-ui__x-mark-icon"}),Gn(n)?t(qn,{className:"notificare__push__android__in-app-browser__app-ui__bar-lock-icon"}):t(vn,{className:"notificare__push__android__in-app-browser__app-ui__alert-icon"}),e("div",{className:"notificare__push__android__in-app-browser__app-ui__bar-domain",children:[t("p",{className:"notificare__push__android__in-app-browser__app-ui__bar-text notificare__push__android__in-app-browser__app-ui__bar-text--title",children:!l.isLoading&&r?s:u.formatMessage({id:"preview.android.inAppBrowser.appUi.pageTitleLoading",defaultMessage:bn["preview.android.inAppBrowser.appUi.pageTitleLoading"]})}),t("p",{className:"notificare__push__android__in-app-browser__app-ui__bar-text notificare__push__android__in-app-browser__app-ui__bar-text--url",children:zn(n)})]})]})}function Qn(e,t,n){t({isLoading:e}),null==n||n(e)}ln(".notificare .notificare__push__android__in-app-browser__app-ui__bar {\n display: flex;\n width: 334px;\n height: 45px;\n padding: 0 15px;\n align-items: center;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__x-mark-icon {\n margin-right: 20px;\n height: 24px;\n width: auto;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-lock-icon {\n margin-right: 7px;\n height: 14px;\n width: auto;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__alert-icon {\n margin-right: 7px;\n height: 14px;\n width: auto;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-domain {\n display: flex;\n flex-direction: column;\n flex: 1;\n min-width: 0;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text--title {\n font-size: 14px;\n}\n\n.notificare .notificare__push__android__in-app-browser__app-ui__bar-text--url {\n font-size: 12px;\n}");function ei({notification:n}){const[i,r]=a(!0),[o,s]=a(!0),c=n.content[0].data;return e("div",{"data-testid":"android-app-ui-in-app-browser-notification",children:[t(Jn,{url:c,onLoadingChanged:r,canShow:!o}),t($n,{url:c,platform:"Android",width:338,height:570,onLoadingChanged:s,canShow:!i})]})}ln("");const ti=p(void 0);function ni({application:e,children:n}){return t(ti.Provider,{value:e,children:n})}function ii(){const e=d(ti);if(!e)throw new Error("useApplication should be used inside an ApplicationProvider");return e}function ri(e,t){return k(this,void 0,void 0,(function*(){const n=new URL("/proxy","https://push.notifica.re");n.searchParams.set("apiKey",e),n.searchParams.set("url",t);return(yield fetch(n)).text()}))}function ai(e){return!!(e.actions&&e.actions.length>0)}function oi(e){return!(!e.actions||1!==e.actions.length)}function si(e){return!!(e.actions&&e.actions.length>1)}function ci(e){var t;return!!(null===(t=e.attachments)||void 0===t?void 0:t[0])}function li(e){const t=(new DOMParser).parseFromString(e,"text/html").querySelectorAll("a");let n=!1;return t.forEach((e=>{new URL(e.href,window.location.origin).searchParams.has("notificareOpenAction")&&(n=!0)})),n}var pi;function di(){return di=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},di.apply(null,arguments)}var ui,_i=function(e){return i.createElement("svg",di({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",width:"1em",height:"1em"},e),pi||(pi=i.createElement("path",{d:"M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288H416c17.7 0 32-14.3 32-32s-14.3-32-32-32H109.3l105.3-105.4c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"})))};function hi(){return hi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},hi.apply(null,arguments)}var fi=function(e){return i.createElement("svg",hi({xmlns:"http://www.w3.org/2000/svg","data-testid":"android-app-ui-navigation-bar-options-button",viewBox:"0 0 128 512",width:"1em",height:"1em"},e),ui||(ui=i.createElement("path",{d:"M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112m0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112m56-104A56 56 0 1 0 8 96a56 56 0 1 0 112 0"})))};function mi({title:n,showOptions:i}){return e("div",{className:"notificare__push__android__app-ui__navigation-bar",children:[t(_i,{className:"notificare__push__android__app-ui__navigation-bar-arrow-icon"}),t("div",{className:"notificare__push__android__app-ui__navigation-bar-title",children:n}),i&&t(fi,{"data-testid":"android-app-ui-navigation-bar-options-button",className:"notificare__push__android__app-ui__navigation-bar-options-button"})]})}ln(".notificare .notificare__push__android__app-ui__navigation-bar {\n display: flex;\n width: 338px;\n height: 45px;\n padding: 0 15px;\n align-items: center;\n justify-content: flex-start;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-arrow-icon {\n margin-right: 20px;\n height: 24px;\n width: auto;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-title {\n width: 100%;\n font-size: 18px;\n font-weight: 700;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__app-ui__navigation-bar-options-button {\n margin-left: auto;\n height: 24px;\n}");var gi;function vi({notification:n}){const i=ii(),r=n.content[0].data,[s,c]=a(""),{serviceKey:l}=Dn();return o((function(){(()=>{k(this,void 0,void 0,(function*(){try{const e=yield ri(l,r);c(e)}catch(e){console.error("Error fetching website markup:\n\n",e)}}))})()}),[]),e("div",{"data-testid":"android-app-ui-url-notification",children:[t(mi,{title:n.title||i.name,showOptions:ai(n)&&!li(s)}),t($n,{url:r,platform:"Android",width:338,height:570})]})}function bi(e){if(!(e=e.trim()))return gi.INVALID_URL;if(e.startsWith("/"))return gi.RELATIVE_URL;let t;try{t=new URL(e)}catch(e){return gi.INVALID_URL}const n="http:"===t.protocol||"https:"===t.protocol,i=t.host.endsWith("ntc.re");if(!n)return gi.URL_SCHEME;if(i)return gi.DYNAMIC_LINK;const r=t.searchParams.get("notificareWebView");return"1"===r||"true"===(null==r?void 0:r.toLowerCase())?gi.WEB_VIEW:gi.IN_APP_BROWSER}function wi({notification:e,onError:n}){const i=Jt(),r=e.content[0].data,a=bi(r);switch(o((function(){switch(a){case"invalid-url":n(i.formatMessage({id:"preview.error.urlResolverInvalidUrl",defaultMessage:bn["preview.error.urlResolverInvalidUrl"]}));break;case"url-scheme":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithUrlSchemePreview",defaultMessage:bn["preview.error.notSupportedUrlResolverWithUrlSchemePreview"]}));break;case"dynamic-link":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithDynamicLink",defaultMessage:bn["preview.error.notSupportedUrlResolverWithDynamicLink"]}));break;case"relative-url":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithRelativeUrl",defaultMessage:bn["preview.error.notSupportedUrlResolverWithRelativeUrl"]}))}}),[r]),a){case"invalid-url":case"url-scheme":case"dynamic-link":case"relative-url":return;case"web-view":return t(vi,{notification:e});case"in-app-browser":return t(ei,{notification:e})}}ln(""),function(e){e.INVALID_URL="invalid-url",e.DYNAMIC_LINK="dynamic-link",e.WEB_VIEW="web-view",e.IN_APP_BROWSER="in-app-browser",e.URL_SCHEME="url-scheme",e.RELATIVE_URL="relative-url"}(gi||(gi={}));function yi({notification:n}){const i=ii(),r=Jt(),a=function(e){const t="https://play.google.com";for(const n of e)switch(n.type){case"re.notifica.content.GooglePlayDetails":{const e=new URL("/store/apps/details",t);return e.searchParams.set("id",n.data),e.toString()}case"re.notifica.content.GooglePlayDeveloper":{const e=new URL("/store/apps/dev",t);return e.searchParams.set("id",n.data),e.toString()}case"re.notifica.content.GooglePlayCollection":return new URL(`/store/apps/collection/${encodeURIComponent(n.data)}`,t).toString();case"re.notifica.content.GooglePlaySearch":{const e=new URL("/store/search",t);return e.searchParams.set("q",n.data),e.searchParams.set("c","apps"),e.toString()}}return null}(n.content);return e("div",{"data-testid":"android-app-ui-app-recommendation-notification",children:[t(mi,{title:n.title||i.name,showOptions:!1}),a?t($n,{url:a,platform:"Android",width:338,height:570}):t(yn,{message:r.formatMessage({id:"preview.error.noValidContentObject",defaultMessage:bn["preview.error.noValidContentObject"]})})]})}ln("");function xi({notification:n}){const i=ii();return e("div",{"data-testid":"android-app-ui-passbook-notification",children:[t(mi,{title:n.title||i.name,showOptions:ai(n)}),t($n,{url:`https://push.notifica.re/pass/web/${n.content[0].data.split("/")[5]}`,platform:"Android",width:338,height:570}),")"]})}ln("");var ki,Ei;function Ni({notification:n}){const i=ii();return e("div",{"data-testid":"android-app-ui-images-notification",children:[t(mi,{title:n.title||i.name,showOptions:ai(n)}),t("div",{className:"notificare__push__android__image__app-ui__rich-content",children:t("div",{className:"notificare__push__android__image__app-ui__image-slider",children:n.content.map(((e,n)=>t("img",{className:"notificare__push__android__image__app-ui__image-slider-item",src:e.data,alt:"Slider image"},n)))})})]})}ln(".notificare .notificare__push__android__image__app-ui__rich-content {\n display: flex;\n align-items: center;\n width: 100%;\n height: 570px;\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scrollbar-width: none; /* Hide in Firefox */\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider::-webkit-scrollbar {\n display: none; /* Hide in Chrome and Safari */\n}\n\n.notificare .notificare__push__android__image__app-ui__image-slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}");var Si=Bt(Ei?ki:(Ei=1,ki=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;var i,r,a;if(Array.isArray(t)){if((i=t.length)!=n.length)return!1;for(r=i;0!==r--;)if(!e(t[r],n[r]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((i=(a=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(r=i;0!==r--;)if(!Object.prototype.hasOwnProperty.call(n,a[r]))return!1;for(r=i;0!==r--;){var o=a[r];if(!e(t[o],n[o]))return!1}return!0}return t!=t&&n!=n}));function Ti(){return Ti=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ti.apply(null,arguments)}function Ai(e,t){if(null==e)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(-1!==t.indexOf(i))continue;n[i]=e[i]}return n}function Mi(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t);if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}const Ci="NOT_LOADED",Pi="LOADING",Li="LOADED",Oi="FAILED",Ri="AUTH_FAILURE";class Ii{static async load(e,t){var n;const i=e.libraries?e.libraries.split(","):[],r=this.serializeParams(e);this.listeners.push(t),null!=(n=window.google)&&null!=(n=n.maps)&&n.importLibrary?(this.serializedApiParams||(this.loadingStatus=Li),this.notifyLoadingStatusListeners()):(this.serializedApiParams=r,this.initImportLibrary(e)),this.serializedApiParams&&this.serializedApiParams!==r&&console.warn("[google-maps-api-loader] The maps API has already been loaded with different parameters and will not be loaded again. Refresh the page for new values to have effect.");const a=["maps",...i];await Promise.all(a.map((e=>google.maps.importLibrary(e))))}static serializeParams(e){return[e.v,e.key,e.language,e.region,e.authReferrerPolicy,e.solutionChannel].join("/")}static initImportLibrary(e){if(window.google||(window.google={}),window.google.maps||(window.google.maps={}),window.google.maps.importLibrary)return void console.error("[google-maps-api-loader-internal]: initImportLibrary must only be called once");let t=null;const n=()=>t||(t=new Promise(((t,n)=>{var i;const r=document.createElement("script"),a=new URLSearchParams;for(const[t,n]of Object.entries(e)){const e=t.replace(/[A-Z]/g,(e=>"_"+e[0].toLowerCase()));a.set(e,String(n))}a.set("loading","async"),a.set("callback","__googleMapsCallback__"),r.async=!0,r.src="https://maps.googleapis.com/maps/api/js?"+a.toString(),r.nonce=(null==(i=document.querySelector("script[nonce]"))?void 0:i.nonce)||"",r.onerror=()=>{this.loadingStatus=Oi,this.notifyLoadingStatusListeners(),n(new Error("The Google Maps JavaScript API could not load."))},window.__googleMapsCallback__=()=>{this.loadingStatus=Li,this.notifyLoadingStatusListeners(),t()},window.gm_authFailure=()=>{this.loadingStatus=Ri,this.notifyLoadingStatusListeners()},this.loadingStatus=Pi,this.notifyLoadingStatusListeners(),document.head.append(r)})),t);google.maps.importLibrary=e=>n().then((()=>google.maps.importLibrary(e)))}static notifyLoadingStatusListeners(){for(const e of this.listeners)e(this.loadingStatus)}}Ii.loadingStatus=Ci,Ii.serializedApiParams=void 0,Ii.listeners=[];const Ui=["onLoad","onError","apiKey","version","libraries"],Bi=["children"],Hi=r.createContext(null);const ji=e=>{const{children:t}=e,n=Ai(e,Bi),{mapInstances:i,addMapInstance:c,removeMapInstance:l,clearMapInstances:p}=function(){const[e,t]=a({});return{mapInstances:e,addMapInstance:(e,n="default")=>{t((t=>Ti({},t,{[n]:e})))},removeMapInstance:(e="default")=>{t((t=>Ai(t,[e].map(Mi))))},clearMapInstances:()=>{t({})}}}(),{status:d,loadedLibraries:u,importLibrary:_}=function(e){const{onLoad:t,onError:n,apiKey:i,version:r,libraries:c=[]}=e,l=Ai(e,Ui),[p,d]=a(Ii.loadingStatus),[u,_]=f(((e,t)=>e[t.name]?e:Ti({},e,{[t.name]:t.value})),{}),h=s((()=>null==c?void 0:c.join(",")),[c]),g=s((()=>JSON.stringify(Ti({apiKey:i,version:r},l))),[i,r,l]),v=m((async e=>{var t;if(u[e])return u[e];if(null==(t=google)||null==(t=t.maps)||!t.importLibrary)throw new Error("[api-provider-internal] importLibrary was called before google.maps.importLibrary was defined.");const n=await window.google.maps.importLibrary(e);return _({name:e,value:n}),n}),[u]);return o((()=>{(async()=>{try{const e=Ti({key:i},l);r&&(e.v=r),(null==h?void 0:h.length)>0&&(e.libraries=h),(void 0===e.channel||e.channel<0||e.channel>999)&&delete e.channel,void 0===e.solutionChannel?e.solutionChannel="GMP_visgl_rgmlibrary_v1_default":""===e.solutionChannel&&delete e.solutionChannel,await Ii.load(e,(e=>d(e)));for(const e of["core","maps",...c])await v(e);t&&t()}catch(e){n?n(e):console.error("<ApiProvider> failed to load the Google Maps JavaScript API",e)}})()}),[i,h,g]),{status:p,loadedLibraries:u,importLibrary:v}}(n),h=s((()=>({mapInstances:i,addMapInstance:c,removeMapInstance:l,clearMapInstances:p,status:d,loadedLibraries:u,importLibrary:_})),[i,c,l,p,d,u,_]);return r.createElement(Hi.Provider,{value:h},t)};function Fi(e,t,n){const i={type:e,map:t,detail:{},stoppable:!1,stop:()=>{}};if(Gi.includes(e)){const e=i,n=t.getCenter(),r=t.getZoom(),a=t.getHeading()||0,o=t.getTilt()||0,s=t.getBounds();return n&&s&&Number.isFinite(r)||console.warn("[createEvent] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),e.detail={center:(null==n?void 0:n.toJSON())||{lat:0,lng:0},zoom:r||0,heading:a,tilt:o,bounds:(null==s?void 0:s.toJSON())||{north:90,east:180,south:-90,west:-180}},e}if(zi.includes(e)){var r;if(!n)throw new Error("[createEvent] mouse events must provide a srcEvent");const e=i;return e.domEvent=n.domEvent,e.stoppable=!0,e.stop=()=>n.stop(),e.detail={latLng:(null==(r=n.latLng)?void 0:r.toJSON())||null,placeId:n.placeId},e}return i}const Di={onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onContextmenu:"contextmenu",onDblclick:"dblclick",onDrag:"drag",onDragend:"dragend",onDragstart:"dragstart",onHeadingChanged:"heading_changed",onIdle:"idle",onIsFractionalZoomEnabledChanged:"isfractionalzoomenabled_changed",onMapCapabilitiesChanged:"mapcapabilities_changed",onMapTypeIdChanged:"maptypeid_changed",onMousemove:"mousemove",onMouseout:"mouseout",onMouseover:"mouseover",onProjectionChanged:"projection_changed",onRenderingTypeChanged:"renderingtype_changed",onTilesLoaded:"tilesloaded",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed",onCameraChanged:"bounds_changed"},Gi=["bounds_changed","center_changed","heading_changed","tilt_changed","zoom_changed"],zi=["click","contextmenu","dblclick","mousemove","mouseout","mouseover"],Vi=Object.keys(Di);const Zi=new Set(["backgroundColor","clickableIcons","controlSize","disableDefaultUI","disableDoubleClickZoom","draggable","draggableCursor","draggingCursor","fullscreenControl","fullscreenControlOptions","gestureHandling","headingInteractionEnabled","isFractionalZoomEnabled","keyboardShortcuts","mapTypeControl","mapTypeControlOptions","mapTypeId","maxZoom","minZoom","noClear","panControl","panControlOptions","restriction","rotateControl","rotateControlOptions","scaleControl","scaleControlOptions","scrollwheel","streetView","streetViewControl","streetViewControlOptions","styles","tiltInteractionEnabled","zoomControl","zoomControlOptions"]);function $i(e,t){const n={},i=Object.keys(t);for(const e of i)Zi.has(e)&&(n[e]=t[e]);!function(e,t){const n=c(void 0);n.current&&Si(t,n.current)||(n.current=t),o(e,n.current)}((()=>{e&&e.setOptions(n)}),[n])}function Wi(){var e;return(null==(e=d(Hi))?void 0:e.status)||Ci}function Ki(e){return function(e){return!(!e||"object"!=typeof e)&&"lat"in e&&"lng"in e&&Number.isFinite(e.lat)&&Number.isFinite(e.lng)}(e)?e:e.toJSON()}const qi=()=>r.createElement("div",{style:{position:"absolute",top:0,left:0,bottom:0,right:0,zIndex:999,display:"flex",flexFlow:"column nowrap",textAlign:"center",justifyContent:"center",fontSize:".8rem",color:"rgba(0,0,0,0.6)",background:"#dddddd",padding:"1rem 1.5rem"}},r.createElement("h2",null,"Error: AuthFailure"),r.createElement("p",null,"A problem with your API key prevents the map from rendering correctly. Please make sure the value of the ",r.createElement("code",null,"APIProvider.apiKey")," prop is correct. Check the error-message in the console for further details."));function Xi(){return Wi()===Li}function Yi(e){const t=function(){const[,e]=f((e=>e+1),0);return e}(),n=c({center:{lat:0,lng:0},heading:0,tilt:0,zoom:0});return o((()=>{if(!e)return;const i=google.maps.event.addListener(e,"bounds_changed",(()=>{!function(e,t){const n=e.getCenter(),i=e.getZoom(),r=e.getHeading()||0,a=e.getTilt()||0,o=e.getBounds();n&&o&&Number.isFinite(i)||console.warn("[useTrackedCameraState] at least one of the values from the map returned undefined. This is not expected to happen. Please report an issue at https://github.com/visgl/react-google-maps/issues/new"),Object.assign(t.current,{center:(null==n?void 0:n.toJSON())||{lat:0,lng:0},zoom:i||0,heading:r,tilt:a})}(e,n),t()}));return()=>i.remove()}),[e,t]),n}const Ji=["id","defaultBounds","defaultCenter","defaultZoom","defaultHeading","defaultTilt","reuseMaps","renderingType","colorScheme"],Qi=["padding"];class er{static has(e){return this.entries[e]&&this.entries[e].length>0}static pop(e){return this.entries[e]&&this.entries[e].pop()||null}static push(e,t){this.entries[e]||(this.entries[e]=[]),this.entries[e].push(t)}}function tr(e,t){const n=Xi(),[i,r]=a(null),[s,l]=function(){const[e,t]=a(null);return[e,m((e=>t(e)),[t])]}(),p=Yi(i),{id:d,defaultBounds:u,defaultCenter:_,defaultZoom:h,defaultHeading:f,defaultTilt:g,reuseMaps:v,renderingType:b,colorScheme:w}=e,y=Ai(e,Ji),x=void 0!==e.zoom||void 0!==e.defaultZoom,k=void 0!==e.center||void 0!==e.defaultCenter;u||x&&k||console.warn("<Map> component is missing configuration. You have to provide zoom and center (via the `zoom`/`defaultZoom` and `center`/`defaultCenter` props) or specify the region to show using `defaultBounds`. See https://visgl.github.io/react-google-maps/docs/api-reference/components/map#required"),!y.center&&_&&(y.center=_),!y.zoom&&Number.isFinite(h)&&(y.zoom=h),!y.heading&&Number.isFinite(f)&&(y.heading=f),!y.tilt&&Number.isFinite(g)&&(y.tilt=g);for(const e of Object.keys(y))void 0===y[e]&&delete y[e];const E=c(void 0);return o((()=>{if(!s||!n)return;const{addMapInstance:i,removeMapInstance:a}=t,{mapId:o}=e,c=`${o||"default"}:${b||"default"}:${w||"LIGHT"}`;let l,_;if(v&&er.has(c)?(_=er.pop(c),l=_.getDiv(),s.appendChild(l),_.setOptions(y),setTimeout((()=>_.setCenter(_.getCenter())),0)):(l=document.createElement("div"),l.style.height="100%",s.appendChild(l),_=new google.maps.Map(l,Ti({},y,b?{renderingType:b}:{},w?{colorScheme:w}:{}))),r(_),i(_,d),u){const{padding:e}=u,t=Ai(u,Qi);_.fitBounds(t,e)}else x&&k||_.fitBounds({east:180,west:-180,south:-90,north:90});if(E.current){const{mapId:e,cameraState:t}=E.current;e!==o&&_.setOptions(t)}return()=>{E.current={mapId:o,cameraState:p.current},l.remove(),v?er.push(c,_):google.maps.event.clearInstanceListeners(_),r(null),a(d)}}),[s,n,d,e.mapId,e.renderingType,e.colorScheme]),[i,l,p]}er.entries={};const nr=r.createContext(null),ir=e=>{const{children:t,id:n,className:i,style:a}=e,c=d(Hi),l=Wi();if(!c)throw new Error("<Map> can only be used inside an <ApiProvider> component.");const[p,u,_]=tr(e,c);!function(e,t,n){const i=n.center?Ki(n.center):null;let r=null,a=null;i&&Number.isFinite(i.lat)&&Number.isFinite(i.lng)&&(r=i.lat,a=i.lng);const o=Number.isFinite(n.zoom)?n.zoom:null,s=Number.isFinite(n.heading)?n.heading:null,c=Number.isFinite(n.tilt)?n.tilt:null;g((()=>{if(!e)return;const n={};let i=!1;null===r||null===a||t.current.center.lat===r&&t.current.center.lng===a||(n.center={lat:r,lng:a},i=!0),null!==o&&t.current.zoom!==o&&(n.zoom=o,i=!0),null!==s&&t.current.heading!==s&&(n.heading=s,i=!0),null!==c&&t.current.tilt!==c&&(n.tilt=c,i=!0),i&&e.moveCamera(n)}))}(p,_,e),function(e,t){for(const n of Vi){const i=t[n],r=Di[n];o((()=>{if(!e)return;if(!i)return;const t=google.maps.event.addListener(e,r,(t=>{i(Fi(r,e,t))}));return()=>t.remove()}),[e,r,i])}}(p,e),$i(p,e);const h=function(e,t){const{viewport:n,viewState:i}=t,r=!!n;return g((()=>{if(!e||!i)return;const{latitude:t,longitude:n,bearing:r,pitch:a,zoom:o}=i;e.moveCamera({center:{lat:t,lng:n},heading:r,tilt:a,zoom:o+1})}),[e,i]),r}(p,e),f=!!e.controlled;o((()=>{if(p)return h&&p.setOptions({disableDefaultUI:!0}),(h||f)&&p.setOptions({gestureHandling:"none",keyboardShortcuts:!1}),()=>{p.setOptions({gestureHandling:e.gestureHandling,keyboardShortcuts:e.keyboardShortcuts})}}),[p,h,f,e.gestureHandling,e.keyboardShortcuts]);const m=e.center?Ki(e.center):null;let v=null,b=null;m&&Number.isFinite(m.lat)&&Number.isFinite(m.lng)&&(v=m.lat,b=m.lng);const w=s((()=>{var t,n,i,r,a;return{center:{lat:null!=(t=v)?t:0,lng:null!=(n=b)?n:0},zoom:null!=(i=e.zoom)?i:0,heading:null!=(r=e.heading)?r:0,tilt:null!=(a=e.tilt)?a:0}}),[v,b,e.zoom,e.heading,e.tilt]);g((()=>{if(!p||!f)return;p.moveCamera(w);const e=p.addListener("bounds_changed",(()=>{p.moveCamera(w)}));return()=>e.remove()}),[p,f,w]);const y=s((()=>Ti({width:"100%",height:"100%",position:"relative",zIndex:h?-1:0},a)),[a,h]),x=s((()=>({map:p})),[p]);return l===Ri?r.createElement("div",{style:Ti({position:"relative"},i?{}:y),className:i},r.createElement(qi,null)):r.createElement("div",Ti({ref:u,"data-testid":"map",style:i?void 0:y,className:i},n?{id:n}:{}),p?r.createElement(nr.Provider,{value:x},t):null)};ir.deckGLViewProps=!0;const rr=new Set;const ar=(e=null)=>{const t=d(Hi),{map:n}=d(nr)||{};if(null===t)return function(...e){const t=JSON.stringify(e);rr.has(t)||(rr.add(t),console.error(...e))}("useMap(): failed to retrieve APIProviderContext. Make sure that the <APIProvider> component exists and that the component you are calling `useMap()` from is a sibling of the <APIProvider>."),null;const{mapInstances:i}=t;return null!==e?i[e]||null:n||(i.default||null)};function or(e,t,n){o((()=>{if(!e||!t||!n)return;const i=google.maps.event.addListener(e,t,n);return()=>i.remove()}),[e,t,n])}function sr(e,t,n){o((()=>{e&&(e[t]=n)}),[e,t,n])}function cr(e,t,n){o((()=>{if(e&&t&&n)return e.addEventListener(t,n),()=>e.removeEventListener(t,n)}),[e,t,n])}const lr=r.createContext(null),pr={BOTTOM:["50%","100%"]},dr=({children:e,styles:t,className:n,anchorPoint:i})=>{const[a,o]=null!=i?i:pr.BOTTOM;let s=`-${a}`,c=`-${o}`;a.trimStart().startsWith("-")&&(s=a.substring(1)),o.trimStart().startsWith("-")&&(c=o.substring(1));const l=`translate(50%, 100%) translate(${s}, ${c})`;return r.createElement("div",{style:{transform:l}},r.createElement("div",{className:n,style:t},e))};function ur(e){const[t,n]=a(null),[i,r]=a(null),s=ar(),c=function(e){const t=Xi(),n=d(Hi);return o((()=>{t&&n&&n.importLibrary(e)}),[t,n,e]),(null==n?void 0:n.loadedLibraries[e])||null}("marker"),{children:l,onClick:p,className:u,onMouseEnter:_,onMouseLeave:f,onDrag:m,onDragStart:g,onDragEnd:v,collisionBehavior:b,clickable:w,draggable:y,position:x,title:k,zIndex:E}=e,N=h.count(l);return o((()=>{if(!s||!c)return;const e=new c.AdvancedMarkerElement;e.map=s,n(e);let t=null;return N>0&&(t=document.createElement("div"),t.isCustomMarker=!0,e.content=t,r(t)),()=>{var i;e.map=null,null==(i=t)||i.remove(),n(null),r(null)}}),[s,c,N]),o((()=>{!t||!t.content||N>0||(t.content.className=u||"")}),[t,u,N]),sr(t,"position",x),sr(t,"title",null!=k?k:""),sr(t,"zIndex",E),sr(t,"collisionBehavior",b),o((()=>{t&&(t.gmpDraggable=void 0!==y?y:!!(m||g||v))}),[t,y,m,v,g]),o((()=>{if(!t)return;const e=void 0!==w||Boolean(p)||Boolean(_)||Boolean(f);t.gmpClickable=e,e&&null!=t&&t.content&&t.content.nodeType===Node.ELEMENT_NODE&&(t.content.style.pointerEvents="none",t.content.firstElementChild&&(t.content.firstElementChild.style.pointerEvents="all"))}),[t,w,p,_,f]),or(t,"click",p),or(t,"drag",m),or(t,"dragstart",g),or(t,"dragend",v),cr(null==t?void 0:t.element,"mouseenter",_),cr(null==t?void 0:t.element,"mouseleave",f),[t,i]}u(((e,t)=>{const{children:n,style:i,className:a,anchorPoint:o}=e,[c,l]=ur(e),p=s((()=>c?{marker:c}:null),[c]);return _(t,(()=>c),[c]),l?r.createElement(lr.Provider,{value:p},v(r.createElement(dr,{anchorPoint:o,styles:i,className:a},n),l)):null}));const _r=["onClick","onDrag","onDragStart","onDragEnd","onMouseOver","onMouseOut"];const hr=u(((e,t)=>{const n=function(e){const[t,n]=a(null),i=ar(),{onClick:r,onDrag:s,onDragStart:c,onDragEnd:l,onMouseOver:p,onMouseOut:d}=e,u=Ai(e,_r),{position:_,draggable:h}=u;return o((()=>{if(!i)return void(void 0===i&&console.error("<Marker> has to be inside a Map component."));const e=new google.maps.Marker(u);return e.setMap(i),n(e),()=>{e.setMap(null),n(null)}}),[i]),o((()=>{if(!t)return;const e=t,n=google.maps.event;return r&&n.addListener(e,"click",r),s&&n.addListener(e,"drag",s),c&&n.addListener(e,"dragstart",c),l&&n.addListener(e,"dragend",l),p&&n.addListener(e,"mouseover",p),d&&n.addListener(e,"mouseout",d),t.setDraggable(Boolean(h)),()=>{n.clearInstanceListeners(e)}}),[t,h,r,s,c,l,p,d]),o((()=>{t&&u&&t.setOptions(u)}),[t,u]),o((()=>{!h&&_&&t&&t.setPosition(_)}),[h,_,t]),t}(e);return _(t,(()=>n),[n]),r.createElement(r.Fragment,null)}));function fr({notification:e,width:n,height:i}){const{googleMapsAPIKey:r}=Dn(),[c,l]=a(!1),p=s((()=>function(e){const t=[];return e.content.forEach((e=>{t.push({title:e.data.title,latitude:e.data.latitude,longitude:e.data.longitude})})),t}(e).map(((e,t)=>({id:t,lat:e.latitude,lng:e.longitude,title:e.title})))),[e.content]),d=s((()=>p.length>0?{lat:p[0].lat,lng:p[0].lng}:{lat:0,lng:0}),[p]);return o((()=>{l(!0)}),[]),0!==p.length&&c?t("div",{"data-testid":"map-notification",children:t(ji,{apiKey:r||"",children:t(mr,{markers:p,center:d,width:n,height:i})})}):t(mn,{})}function mr({markers:n,center:i,width:r,height:a}){const o=Wi(),s=Jt();return e("div",{style:{width:r,height:a,backgroundColor:"white",position:"relative",overflow:"hidden"},children:[o===Pi&&t(mn,{}),o===Ri&&t(yn,{message:s.formatMessage({id:"preview.error.googleMapsAuthFailure",defaultMessage:bn["preview.error.googleMapsAuthFailure"]})}),o===Oi&&t(yn,{message:s.formatMessage({id:"preview.error.googleMapsLoadFailure",defaultMessage:bn["preview.error.googleMapsLoadFailure"]})}),o===Li&&t(ir,{style:{width:r,height:a},defaultCenter:i,defaultZoom:10,gestureHandling:"greedy",disableDefaultUI:!0,children:n.map((e=>t(hr,{position:{lat:e.lat,lng:e.lng},title:e.title},e.id)))})]})}ln("");function gr({notification:n,onError:i}){const r=ii(),{googleMapsAPIKey:a}=Dn(),s=Jt();if(o((function(){a||i(s.formatMessage({id:"preview.error.provideGoogleMapsApiKey",defaultMessage:bn["preview.error.provideGoogleMapsApiKey"]}))}),[a]),a)return e("div",{"data-testid":"android-app-ui-map-notification",children:[t(mi,{title:r.name,showOptions:ai(n)}),t(fr,{notification:n,width:"100%",height:"570px"})]})}ln("");var vr;function br({notification:n}){const i=ii(),r=new URL("/store/apps/details","https://play.google.com");return r.searchParams.set("id",i.androidPackageName||""),e("div",{"data-testid":"android-app-ui-rate-notification",children:[t(mi,{title:n.title||i.name,showOptions:!1}),t($n,{url:r.toString(),platform:"Android",width:338,height:570})]})}function wr(){return wr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},wr.apply(null,arguments)}ln("");var yr=function(e){return i.createElement("svg",wr({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid slice",viewBox:"1757.501 1648.178 806.546 806.694"},e),vr||(vr=i.createElement("rect",{width:"100%",height:"100%",fill:"transparent"})),i.createElement("path",{d:"M-33.085-33.085h66.17v66.17h-66.17z",style:{fill:"#232c2a",strokeWidth:1},transform:"translate(2160.42 2051.46)scale(12.2)"}),i.createElement("circle",{r:35,style:{fill:"#232c2a",stroke:"#444",strokeWidth:1},transform:"matrix(7.2 0 0 7.2 2160.42 2051.79)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"rotate(-135 1505.372 579.04)scale(15.19 -.07)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(10.71 -10.71 -.05 -.05 2160.62 2052.92)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(10.69 0 0 -.07 2160.36 2053.16)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(0 -10.69 -.07 0 1896.9 2052.81)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(0 -10.69 -.07 0 2423.68 2053.49)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(-10.69 0 0 .07 2160.38 1790.29)"}),i.createElement("path",{d:"M-17.46-19.415h34.92v38.83h-34.92z",style:{fill:"#444",stroke:"#444",strokeWidth:40},transform:"matrix(-10.68 0 0 .07 2160.42 2313.82)"}))};function xr({notification:n}){var i;const r=ii();return t("div",{className:"notificare__push__android__alert__app-ui","data-testid":"android-app-ui-text-alert-notification",children:e("div",{className:"notificare__push__android__alert__app-ui__wrapper",children:[e("div",{className:"notificare__push__android__alert__app-ui__header",children:[t("div",{className:"notificare__push__android__alert__app-ui__app-icon",children:r.icon?t("img",{className:"notificare__push__android__alert__app-ui__app-icon-image",alt:"App icon",src:r.icon}):t(yr,{className:"notificare__push__android__alert__app-ui__default-app-icon"})}),t("p",{className:"notificare__push__android__alert__app-ui__title",children:n.title||r.name})]}),t("p",{className:"notificare__push__android__alert__app-ui__message",children:n.message}),ai(n)&&e("div",{className:"notificare__push__android__alert__app-ui__actions",children:[null===(i=n.actions)||void 0===i?void 0:i.map(((e,n)=>t("p",{className:"notificare__push__android__alert__app-ui__action-label","data-testid":`android-app-ui-text-alert-notification-action-${n}`,children:e.label},n))),t("p",{className:"notificare__push__android__alert__app-ui__cancel-label",children:t(on,{id:"preview.android.alert.appUi.cancel",defaultMessage:bn["preview.android.alert.appUi.cancel"]})},"cancel-button-label")]})]})})}ln(".notificare .notificare__push__android__alert__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__android__alert__app-ui__wrapper {\n position: relative;\n background-color: #fff;\n width: 290px;\n border-radius: 2px;\n box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;\n}\n\n/* Header - App Icon and Title */\n\n.notificare .notificare__push__android__alert__app-ui__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n width: 32px;\n height: 32px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__android__alert__app-ui__app-icon-image {\n width: 100%;\n}\n\n.notificare .notificare__push__android__alert__app-ui__default-app-icon {\n height: 100%;\n width: 100%;\n}\n\n.notificare .notificare__push__android__alert__app-ui__header {\n display: flex;\n align-items: center;\n column-gap: 10px;\n padding: 20px 20px 0;\n}\n\n.notificare .notificare__push__android__alert__app-ui__title {\n font-weight: 700;\n font-size: 18px;\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 208px;\n}\n\n/* Message */\n\n.notificare .notificare__push__android__alert__app-ui__message {\n font-size: 16px;\n margin-top: 20px;\n margin-bottom: 0;\n word-break: break-all;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 8;\n padding: 0 20px 20px;\n}\n\n/* Actions */\n\n.notificare .notificare__push__android__alert__app-ui__actions {\n border-top: 1px solid #f2f4f6;\n}\n\n.notificare .notificare__push__android__alert__app-ui__action-label {\n font-size: 14px;\n font-weight: 600;\n padding: 15px 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.notificare .notificare__push__android__alert__app-ui__cancel-label {\n font-size: 14px;\n font-weight: 600;\n color: #64706e;\n padding: 15px 20px 20px;\n}");function kr({videoData:e,width:n,height:i}){const r=()=>{switch(e.type){case"re.notifica.content.YouTube":return`https://www.youtube.com/embed/${e.data}`;case"re.notifica.content.Vimeo":return`https://player.vimeo.com/video/${e.data}`;case"re.notifica.content.HTML5Video":return e.data;default:return""}};return"re.notifica.content.YouTube"===e.type||"re.notifica.content.Vimeo"===e.type?t("iframe",{className:"notificare__push__video-rich-content",src:r(),sandbox:"allow-scripts allow-same-origin",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",width:n,height:i}):t("video",{className:"notificare__push__video-rich-content",width:n,height:i,autoPlay:!0,controls:!0,children:t("source",{src:r(),type:"video/mp4"})})}ln(".notificare .notificare__push__video-rich-content {\n border: 0;\n background-color: #fff;\n}");function Er({notification:n}){const i=ii();return e("div",{"data-testid":"android-app-ui-video-notification",children:[t(mi,{title:n.title||i.name,showOptions:ai(n)}),t(kr,{videoData:n.content[0],width:"100%",height:"570px"})]})}ln("");function Nr({notification:n}){const i=ii(),r=n.content[0].data;return e("div",{"data-testid":"android-app-ui-web-view-notification",children:[t(mi,{title:n.title||i.name,showOptions:ai(n)&&!li(r)}),t("iframe",{className:"notificare__push__android__web-view__app-ui__content",srcDoc:r,sandbox:"allow-same-origin"})]})}ln(".notificare .notificare__push__android__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 570px;\n background-color: #fff;\n pointer-events: none;\n}");function Sr({notification:n,expanded:i}){var r,a;const o=ii();return e("div",{className:"notificare__push__android__lock-screen","data-testid":"android-lock-screen-notification",children:[t("div",{className:"notificare__push__android__lock-screen__app-icon",children:o.icon?t("img",{className:"notificare__push__android__lock-screen__app-icon-image",alt:"App icon",src:o.icon}):t(yr,{className:"notificare__push__android__lock-screen__default-app-icon"})}),e("div",{className:"notificare__push__android__lock-screen__text-content",children:[e("div",{className:"notificare__push__android__lock-screen__text-content-top "+(ci(n)&&!i?"notificare__push__android__lock-screen__text-content-top--has-media":""),children:[e("div",{className:"notificare__push__android__lock-screen__title-and-subtitle",children:[t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--title",children:i?o.name:n.title||o.name}),n.subtitle&&!ci(n)&&t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--subtitle",children:n.subtitle})]}),t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--time",children:t(on,{id:"preview.android.lockscreen.time",defaultMessage:bn["preview.android.lockscreen.time"]})})]}),i&&t("p",{className:"notificare__push__android__lock-screen__text notificare__push__android__lock-screen__text--expanded-title",children:n.title}),t("p",{className:`notificare__push__android__lock-screen__text ${i?"notificare__push__android__lock-screen__text--expanded-message":""} ${ci(n)&&!i?"notificare__push__android__lock-screen__text--message-with-media":"notificare__push__android__lock-screen__text--message-without-media"}`,children:n.message}),ci(n)&&i&&t("img",{className:"notificare__push__android__lock-screen__expanded-media",src:null===(r=n.attachments)||void 0===r?void 0:r[0].uri,alt:"Expanded media","data-testid":"android-lock-screen-notification-expanded-media"})]}),ci(n)&&!i&&t("img",{className:"notificare__push__android__lock-screen__media",src:null===(a=n.attachments)||void 0===a?void 0:a[0].uri,alt:"Media icon","data-testid":"android-lock-screen-notification-media"})]})}ln(".notificare .notificare__push__android__lock-screen {\n position: absolute;\n font-family: 'Roboto', sans-serif;\n background-color: #f2f4f6;\n width: 315px;\n border-radius: 20px;\n padding: 10px;\n display: flex;\n flex-direction: row;\n column-gap: 11px;\n left: 50%;\n transform: translateX(-50%);\n top: 40px;\n}\n\n.notificare .notificare__push__android__lock-screen__wrapper {\n position: relative;\n}\n\n/* App Icon */\n\n.notificare .notificare__push__android__lock-screen__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n width: 32px;\n height: 32px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__android__lock-screen__app-icon-image {\n width: 100%;\n}\n\n.notificare .notificare__push__android__lock-screen__default-app-icon {\n height: 100%;\n width: 100%;\n}\n\n/* Text Content */\n\n.notificare .notificare__push__android__lock-screen__text-content {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n}\n\n.notificare .notificare__push__android__lock-screen__text-content-top {\n display: flex;\n column-gap: 5px;\n margin-top: 0;\n margin-bottom: 0;\n max-width: 252px;\n}\n\n.notificare .notificare__push__android__lock-screen__text-content-top--has-media {\n max-width: 191px;\n}\n\n.notificare .notificare__push__android__lock-screen__title-and-subtitle {\n display: flex;\n overflow: hidden;\n column-gap: 6px;\n}\n\n.notificare .notificare__push__android__lock-screen__text {\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.notificare .notificare__push__android__lock-screen__text--title {\n font-weight: 700;\n font-size: 14px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--expanded-title {\n font-weight: 700;\n font-size: 14px;\n margin-top: 5px;\n width: 252px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--subtitle {\n color: #64706e;\n font-size: 12px;\n font-weight: 400;\n}\n\n.notificare .notificare__push__android__lock-screen__text--time {\n color: #64706e;\n font-size: 12px;\n font-weight: 400;\n flex-shrink: 0;\n max-width: 135px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--message-without-media {\n font-size: 14px;\n width: 252px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--message-with-media {\n font-size: 14px;\n width: 191px;\n}\n\n.notificare .notificare__push__android__lock-screen__text--expanded-message {\n font-size: 14px;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 3;\n word-break: break-word;\n width: 252px;\n white-space: wrap;\n}\n\n/* Media */\n\n.notificare .notificare__push__android__lock-screen__media {\n width: 50px;\n border-radius: 5px;\n object-fit: cover;\n}\n\n.notificare .notificare__push__android__lock-screen__expanded-media {\n width: 252px;\n max-height: 168px;\n border-radius: 15px;\n margin-top: 5px;\n}\n");function Tr({notification:e,previewState:n,onError:i}){const r=Jt();if(o((function(){Mr(e.type,n.displayMode)||i(r.formatMessage({id:"preview.error.notSupportedNotificationTypePreviewVariant",defaultMessage:bn["preview.error.notSupportedNotificationTypePreviewVariant"]},{notificationType:e.type}))}),[n,e.type]),Mr(e.type,n.displayMode))return t(pn,{theme:Ar(e.type,n.displayMode),children:t("div",{className:"notificare__push__android__preview",children:(()=>{switch(n.displayMode){case"lockscreen":case"lockscreen-expanded":return t(Sr,{notification:e,expanded:"lockscreen-expanded"===n.displayMode});case"app-ui":switch(e.type){case"re.notifica.notification.Alert":return t(xr,{notification:e});case"re.notifica.notification.WebView":return t(Nr,{notification:e});case"re.notifica.notification.URL":return t(vi,{notification:e});case"re.notifica.notification.InAppBrowser":return t(ei,{notification:e});case"re.notifica.notification.Image":return t(Ni,{notification:e});case"re.notifica.notification.Map":return t(gr,{notification:e,onError:i});case"re.notifica.notification.Rate":return t(br,{notification:e});case"re.notifica.notification.Passbook":return t(xi,{notification:e});case"re.notifica.notification.Video":return t(Er,{notification:e});case"re.notifica.notification.Store":return t(yi,{notification:e});case"re.notifica.notification.URLResolver":return t(wi,{notification:e,onError:i})}}})()})})}function Ar(e,t){return"app-ui"===t&&"re.notifica.notification.Alert"===e?"dark":"light"}function Mr(e,t){if("app-ui"===t)switch(e){case"re.notifica.notification.Alert":case"re.notifica.notification.WebView":case"re.notifica.notification.URL":case"re.notifica.notification.InAppBrowser":case"re.notifica.notification.Image":case"re.notifica.notification.Map":case"re.notifica.notification.Rate":case"re.notifica.notification.Passbook":case"re.notifica.notification.Video":case"re.notifica.notification.Store":case"re.notifica.notification.URLResolver":return!0;default:return!1}return!0}ln(".notificare .notificare__push__android__preview {\n font-family: 'Roboto', sans-serif;\n height: 100%;\n}");function Cr(n){const{url:i}=n;return e("div",{className:"notificare__push__ios__in-app-browser__app-ui__bar",children:[t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-done-button",children:t(on,{id:"preview.ios.inAppBrowser.appUi.done",defaultMessage:bn["preview.ios.inAppBrowser.appUi.done"]})}),e("div",{className:"notificare__push__ios__in-app-browser__app-ui__bar-domain",children:[Gn(i)?t(qn,{className:"notificare__push__ios__in-app-browser__app-ui__bar-lock-icon"}):t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-not-secure",children:t(on,{id:"preview.ios.inAppBrowser.appUi.notSecure",defaultMessage:bn["preview.ios.inAppBrowser.appUi.notSecure"]})}),t("p",{className:"notificare__push__ios__in-app-browser__app-ui__bar-url",children:zn(i)})]})]})}ln(".notificare .notificare__push__ios__in-app-browser__app-ui__bar {\n display: flex;\n width: 100%;\n padding: 12px 0;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n margin-top: 10px;\n background-color: #fff;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-done-button {\n font-size: 14px;\n font-weight: 700;\n position: absolute;\n left: 0;\n margin-left: 15px;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-lock-icon {\n height: 14px;\n width: auto;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-domain {\n display: flex;\n column-gap: 5px;\n font-size: 14px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-not-secure {\n color: #64706e;\n font-weight: 400;\n}\n\n.notificare .notificare__push__ios__in-app-browser__app-ui__bar-url {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}");function Pr({notification:n}){const i=n.content[0].data;return e("div",{"data-testid":"ios-app-ui-in-app-browser-notification",children:[t(Cr,{url:i}),t($n,{url:i,platform:"iOS",width:338,height:564})]})}ln("");function Lr({title:n,showOptions:i}){return e("div",{className:"notificare__push__ios__app-ui__title-bar",children:[t("div",{className:"notificare__push__ios__app-ui__title-bar-text",children:n}),i&&t(fi,{className:"notificare__push__ios__app-ui__title-bar-options-button","data-testid":"ios-app-ui-title-bar-options-button"})]})}ln(".notificare .notificare__push__ios__app-ui__title-bar {\n display: flex;\n align-items: center;\n width: 100%;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n background-color: #fff;\n margin-top: 10px;\n position: relative;\n}\n\n.notificare .notificare__push__ios__app-ui__title-bar-text {\n padding: 11px 25px;\n font-size: 14px;\n font-weight: 700;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n max-width: 255px;\n position: relative;\n left: 50%;\n transform: translateX(-50%);\n}\n\n.notificare .notificare__push__ios__app-ui__title-bar-options-button {\n width: 20px;\n margin-left: auto;\n margin-right: 12px;\n}");var Or;function Rr({notification:n}){const i=n.content[0].data,r=ii(),[s,c]=a(""),{serviceKey:l}=Dn();return o((function(){(()=>{k(this,void 0,void 0,(function*(){try{const e=yield ri(l,i);c(e)}catch(e){console.error("Error fetching website markup:\n\n",e)}}))})()}),[]),e("div",{"data-testid":"ios-app-ui-url-notification",children:[t(Lr,{title:n.title||r.name,showOptions:ai(n)&&!li(s)}),t($n,{url:i,platform:"iOS",width:338,height:566})]})}function Ir({notification:e,onError:n}){const i=Jt(),r=e.content[0].data,a=bi(r);switch(o((function(){switch(a){case"invalid-url":n(i.formatMessage({id:"preview.error.urlResolverInvalidUrl",defaultMessage:bn["preview.error.urlResolverInvalidUrl"]}));break;case"url-scheme":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithUrlSchemePreview",defaultMessage:bn["preview.error.notSupportedUrlResolverWithUrlSchemePreview"]}));break;case"dynamic-link":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithDynamicLink",defaultMessage:bn["preview.error.notSupportedUrlResolverWithDynamicLink"]}));break;case"relative-url":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithRelativeUrl",defaultMessage:bn["preview.error.notSupportedUrlResolverWithRelativeUrl"]}))}}),[r]),a){case"invalid-url":case"url-scheme":case"dynamic-link":case"relative-url":return;case"web-view":return t(Rr,{notification:e});case"in-app-browser":return t(Pr,{notification:e})}}function Ur(){return Ur=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ur.apply(null,arguments)}ln("");var Br,Hr=function(e){return i.createElement("svg",Ur({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",width:"1em",height:"1em"},e),Or||(Or=i.createElement("path",{d:"M264.5 5.2c14.9-6.9 32.1-6.9 47 0l218.6 101c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0l-218.6-101c-8.5-4-13.9-12.5-13.9-21.8s5.4-17.9 13.9-21.8zm212.4 204.4 53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0l-218.6-101c-8.5-4-13.9-12.5-13.9-21.8s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2a88.1 88.1 0 0 0 73.8 0zm-152 198.2 152-70.2 53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0l-218.6-101c-8.5-4-13.9-12.5-13.9-21.8s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2a88.1 88.1 0 0 0 73.8 0"})))};function jr(){return jr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},jr.apply(null,arguments)}var Fr,Dr=function(e){return i.createElement("svg",jr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",width:"1em",height:"1em"},e),Br||(Br=i.createElement("path",{d:"M399 384.2c-22.1-38.4-63.6-64.2-111-64.2h-64c-47.4 0-88.9 25.8-111 64.2 35.2 39.2 86.2 63.8 143 63.8s107.8-24.7 143-63.8M0 256a256 256 0 1 1 512 0 256 256 0 1 1-512 0m256 16a72 72 0 1 0 0-144 72 72 0 1 0 0 144"})))};function Gr(e){const{contentList:t}=An(e,500),n=Jt(),[i,r]=a({status:"idle"});return o((function(){(()=>{k(this,void 0,void 0,(function*(){const e=function(e){for(const t of e)if("re.notifica.content.AppStore"===t.type)return t.data.identifier;return null}(t);e?(r({status:"loading"}),function(e){return k(this,void 0,void 0,(function*(){const t=new URL("/lookup","https://itunes.apple.com");t.searchParams.set("country","NL"),t.searchParams.set("id",e);const n=(Date.now()/1e3).toString();t.searchParams.set("x",n);const i=yield fetch(t);if(!i.ok)throw new En(i);return yield i.json()}))}(e).then((e=>{0!==e.resultCount?r({status:"success",data:e.results[0]}):r({status:"error",error:new Error(n.formatMessage({id:"preview.error.iosStoreAppNotFound",defaultMessage:bn["preview.error.iosStoreAppNotFound"]}))})})).catch((e=>{console.error("Error getting App Store app:\n\n"+e),r({status:"error",error:new Error(n.formatMessage({id:"preview.error.iosStoreAppLoadFailure",defaultMessage:bn["preview.error.iosStoreAppLoadFailure"]}))})}))):r({status:"error",error:new Error(n.formatMessage({id:"preview.error.noValidContentObject",defaultMessage:bn["preview.error.noValidContentObject"]}))})}))})()}),[t]),i}function zr(e,t){var n;const i=new Intl.RelativeTimeFormat(t,{style:"long"}),r=new Date(e),a=new Date,o=Math.floor((a.getTime()-r.getTime())/1e3),s=[{value:60,unit:"second"},{value:3600,unit:"minute"},{value:86400,unit:"hour"},{value:604800,unit:"day"},{value:2592e3,unit:"week"},{value:31536e3,unit:"month"}];for(let e=0;e<s.length;e++){const{value:t,unit:r}=s[e];if(o<t){const t=Math.floor(o/((null===(n=s[e-1])||void 0===n?void 0:n.value)||1));return i.format(-t,r)}}const c=Math.floor(o/s[s.length-1].value);return i.format(-c,"year")}function Vr(){return Vr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Vr.apply(null,arguments)}var Zr,$r,Wr=function(e){return i.createElement("svg",Vr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",width:"1em",height:"1em"},e),Fr||(Fr=i.createElement("path",{d:"M316.9 18c-5.3-11-16.5-18-28.8-18s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329l-24.6 145.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329l104.2-103.1c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7l-143.7-21.2z"})))};function Kr(){return Kr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Kr.apply(null,arguments)}var qr=function(e){return i.createElement("svg",Kr({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",width:"1em",height:"1em"},e),Zr||(Zr=i.createElement("defs",null,i.createElement("linearGradient",{id:"half-star_svg__a"},i.createElement("stop",{offset:"50%"}),i.createElement("stop",{offset:"50%",stopColor:"#ccc"})))),$r||($r=i.createElement("path",{fill:"url(#half-star_svg__a)",d:"M316.9 18c-5.3-11-16.5-18-28.8-18s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329l-24.6 145.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329l104.2-103.1c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7l-143.7-21.2z"})))};function Xr(e){const{rating:n}=e,i=[];for(let e=1;e<=5;e++)e<=n?i.push(t(Wr,{className:"notificare__push__ios__store__app-ui__star-icon"},e)):e-.5<=n?i.push(t(qr,{className:"notificare__push__ios__store__app-ui__star-icon"},e)):i.push(t(Wr,{className:"notificare__push__ios__store__app-ui__star-icon notificare__push__ios__store__app-ui__star-icon--empty"},e));return t("div",{className:"notificare__push__ios__store__app-ui__star-rating",children:i})}ln(".notificare .notificare__push__ios__store__app-ui__star-rating {\n display: inline-flex;\n flex-grow: 0;\n position: relative;\n}\n\n.notificare .notificare__push__ios__store__app-ui__star-icon {\n width: 10px;\n height: 10px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__star-icon--empty {\n fill: #EAEAEA;\n}");function Yr({notification:n}){const i=n.content,r=Jt(),a=Gr({contentList:i});return e("div",{"data-testid":"ios-app-ui-app-recommendation-notification",children:[t("div",{className:"notificare__push__ios__store__app-ui__bar",children:t(on,{id:"preview.ios.store.appUi.done",defaultMessage:bn["preview.ios.store.appUi.done"]})}),e("div",{className:"notificare__push__ios__store__app-ui",children:["loading"===a.status&&t(mn,{}),"error"===a.status&&t(yn,{message:a.error.message}),"success"===a.status&&e("div",{className:"notificare__push__ios__store__app-ui__page",children:[e("div",{className:"notificare__push__ios__store__app-ui__page-header",children:[t("img",{src:a.data.artworkUrl512,className:"notificare__push__ios__store__app-ui__app-icon",alt:"App icon"}),e("div",{className:"notificare__push__ios__store__app-ui__page-app-info",children:[e("div",{children:[t("p",{className:"notificare__push__ios__store__app-ui__page-app-name",children:a.data.trackName}),t("p",{className:"notificare__push__ios__store__app-ui__page-app-category",children:a.data.primaryGenreName})]}),t("div",{className:"notificare__push__ios__store__app-ui__page-install",children:t(on,{id:"preview.ios.store.appUi.install",defaultMessage:bn["preview.ios.store.appUi.install"]})})]})]}),t("div",{className:"notificare__push__ios__store__app-ui__page-other-app-info-wrapper",children:e("div",{className:"notificare__push__ios__store__app-ui__page-other-app-info",children:[e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:t(on,{id:"preview.ios.store.appUi.ratings",defaultMessage:bn["preview.ios.store.appUi.ratings"],values:{userRatingCount:a.data.userRatingCount}})}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-value",children:a.data.averageUserRating.toFixed(1)}),t(Xr,{rating:a.data.averageUserRating})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:t(on,{id:"preview.ios.store.appUi.age",defaultMessage:bn["preview.ios.store.appUi.age"]})}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-value",children:a.data.trackContentRating}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:t(on,{id:"preview.ios.store.appUi.yearsOld",defaultMessage:bn["preview.ios.store.appUi.yearsOld"]})})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:t(on,{id:"preview.ios.store.appUi.category",defaultMessage:bn["preview.ios.store.appUi.category"]})}),t(Hr,{className:"notificare__push__ios__store__app-ui__page-info-block-icon"}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:a.data.primaryGenreName})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-info-block",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-title",children:t(on,{id:"preview.ios.store.appUi.developer",defaultMessage:bn["preview.ios.store.appUi.developer"]})}),t(Dr,{className:"notificare__push__ios__store__app-ui__page-info-block-icon"}),t("p",{className:"notificare__push__ios__store__app-ui__page-info-block-bottom-text",children:a.data.sellerName})]})]})}),e("div",{className:"notificare__push__ios__store__app-ui__page-history",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-history-title",children:t(on,{id:"preview.ios.store.appUi.whatsNew",defaultMessage:bn["preview.ios.store.appUi.whatsNew"]})}),e("div",{className:"notificare__push__ios__store__app-ui__page-history-version-last-update",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-history-version",children:t(on,{id:"preview.ios.store.appUi.historyVersion",defaultMessage:bn["preview.ios.store.appUi.historyVersion"],values:{version:a.data.version}})}),t("p",{className:"notificare__push__ios__store__app-ui__page-history-last-update",children:zr(a.data.currentVersionReleaseDate,r.locale)})]}),t("p",{className:"notificare__push__ios__store__app-ui__page-history-notes",children:a.data.releaseNotes})]}),e("div",{className:"notificare__push__ios__store__app-ui__page-previews",children:[t("p",{className:"notificare__push__ios__store__app-ui__page-previews-title",children:t(on,{id:"preview.ios.store.appUi.screenshots",defaultMessage:bn["preview.ios.store.appUi.screenshots"]})}),e("div",{className:"notificare__push__ios__store__app-ui__page-previews-images",children:[t("img",{src:a.data.screenshotUrls[0],className:"notificare__push__ios__store__app-ui__page-preview-image",alt:"App preview"}),t("img",{src:a.data.screenshotUrls[1],className:"notificare__push__ios__store__app-ui__page-preview-image",alt:"App preview"})]})]})]})]})]})}ln("/* Top Bar */\n\n.notificare .notificare__push__ios__store__app-ui__bar {\n display: flex;\n width: 100%;\n border-radius: 20px 20px 0 0;\n border-bottom: 1px solid #f4f6f7;\n font-size: 14px;\n font-weight: 700;\n padding: 11px 15px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n background-color: #fff;\n margin-top: 10px;\n}\n\n/* --- App Recommendation Content --- */\n\n.notificare .notificare__push__ios__store__app-ui {\n height: 566px;\n background-color: #fff;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page {\n width: 100%;\n overflow: hidden;\n}\n\n/* Header */\n\n.notificare .notificare__push__ios__store__app-ui__page-header {\n width: 100%;\n padding: 15px;\n display: flex;\n column-gap: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__app-icon {\n width: 90px;\n height: 90px;\n border-radius: 15px;\n overflow: hidden;\n flex-shrink: 0;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-info {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-name {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-app-category {\n font-size: 12px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-install {\n font-size: 11px;\n font-weight: 700;\n text-transform: uppercase;\n padding: 7px 12px;\n background: #3b82f6;\n color: #fff;\n border-radius: 15px;\n width: max-content;\n}\n\n/* Other info */\n\n.notificare .notificare__push__ios__store__app-ui__page-other-app-info-wrapper {\n padding: 0 15px;\n width: calc(100% - 15px);\n overflow: hidden;\n position: relative;\n margin-bottom: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-other-app-info {\n display: flex;\n width: 1000px;\n border-bottom: 1px solid #f2f4f6;\n border-top: 1px solid #f2f4f6;\n position: relative;\n box-sizing: border-box;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block {\n padding: 5px;\n width: 85px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-title {\n font-size: 10px;\n font-weight: 600;\n text-transform: uppercase;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-value {\n font-size: 30px;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-icon {\n height: 18px;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-info-block-bottom-text {\n font-size: 11px;\n text-align: center;\n}\n\n/* History */\n\n.notificare .notificare__push__ios__store__app-ui__page-history {\n margin: 0 15px;\n border-bottom: 1px solid #f2f4f6;\n padding-bottom: 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-title {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-version-last-update {\n display: flex;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-version {\n font-size: 12px;\n color: #64706e;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-last-update {\n font-size: 11px;\n color: #64706e;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-history-notes {\n margin-top: 5px;\n font-size: 12px;\n max-height: 60px;\n overflow: hidden;\n display: -webkit-box;\n -webkit-line-clamp: 3;\n -webkit-box-orient: vertical;\n padding-right: 5px;\n word-break: break-word;\n}\n\n/* Previews */\n\n.notificare .notificare__push__ios__store__app-ui__page-previews {\n margin-top: 15px;\n padding: 0 15px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-previews-title {\n font-size: 16px;\n font-weight: 700;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-previews-images {\n display: flex;\n max-height: 400px;\n overflow: hidden;\n column-gap: 8px;\n margin-top: 10px;\n}\n\n.notificare .notificare__push__ios__store__app-ui__page-preview-image {\n border-radius: 15px;\n width: 150px;\n}");function Jr({notification:n}){const i=ii();return e("div",{"data-testid":"ios-app-ui-passbook-notification",children:[t(Lr,{title:n.title||i.name,showOptions:ai(n)}),t($n,{url:`https://push.notifica.re/pass/web/${n.content[0].data.split("/")[5]}`,platform:"Web",width:338,height:566})]})}ln("");function Qr({notification:n}){const i=ii();return e("div",{"data-testid":"ios-app-ui-images-notification",children:[t(Lr,{title:n.title||i.name,showOptions:ai(n)}),t("div",{className:"notificare__push__ios__image__app-ui__rich-content",children:t("div",{className:"notificare__push__ios__image__app-ui__slider",children:n.content.map(((e,n)=>t("img",{className:"notificare__push__ios__image__app-ui__slider-item",src:e.data,alt:"Slider image"},n)))})})]})}ln(".notificare .notificare__push__ios__image__app-ui__rich-content {\n display: flex;\n align-items: center;\n width: 100%;\n height: 566px;\n background-color: white;\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scrollbar-width: none; /* Hide in Firefox */\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider::-webkit-scrollbar {\n display: none; /* Hide in Chrome and Safari */\n}\n\n.notificare .notificare__push__ios__image__app-ui__slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}");function ea({notification:n,onError:i}){const r=ii(),{googleMapsAPIKey:a}=Dn(),s=Jt();if(o((function(){a||i(s.formatMessage({id:"preview.error.provideGoogleMapsApiKey",defaultMessage:bn["preview.error.provideGoogleMapsApiKey"]}))}),[a]),a)return e("div",{"data-testid":"ios-app-ui-map-notification",children:[t(Lr,{title:n.title||r.name,showOptions:ai(n)}),t(fr,{notification:n,width:"100%",height:"566px"})]})}ln("");function ta({title:n}){const i=ii();return t("div",{className:"notificare__push__ios__rate__app-ui","data-testid":"ios-app-ui-rate-notification",children:e("div",{className:"notificare__push__ios__rate__app-ui__wrapper",children:[t("p",{className:"notificare__push__ios__rate__app-ui__header",children:n||i.name}),t("div",{className:"notificare__push__ios__rate__app-ui__action",children:t(on,{id:"preview.ios.rate.appUi.rateNow",defaultMessage:bn["preview.ios.rate.appUi.rateNow"]})}),t("div",{className:"notificare__push__ios__rate__app-ui__action",children:t(on,{id:"preview.ios.rate.appUi.doNotRate",defaultMessage:bn["preview.ios.rate.appUi.doNotRate"]})})]})})}ln(".notificare .notificare__push__ios__rate__app-ui {\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__ios__rate__app-ui__wrapper {\n width: 300px;\n background: #fff;\n border-radius: 20px;\n overflow: hidden;\n border: 1px solid #f2f4f6;\n}\n\n/* Header */\n\n.notificare .notificare__push__ios__rate__app-ui__header {\n padding: 20px;\n font-size: 16px;\n font-weight: 700;\n text-align: center;\n word-break: break-word;\n}\n\n/* Actions */\n\n.notificare .notificare__push__ios__rate__app-ui__action {\n padding: 10px 20px;\n text-align: center;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n border-top: 1px solid #f2f4f6;\n font-size: 14px;\n font-weight: 700;\n}");function na({notification:n}){var i,r;const a=ii();return t("div",{className:"notificare__push__ios__alert__app-ui","data-testid":"ios-app-ui-text-alert-notification",children:e("div",{className:"notificare__push__ios__alert__app-ui__background",children:[e("div",{className:"notificare__push__ios__alert__app-ui__title-and-message",children:[t("p",{className:"notificare__push__ios__alert__app-ui__title",children:n.title||a.name}),t("p",{className:"notificare__push__ios__alert__app-ui__message",children:n.message})]}),t("div",{className:"notificare__push__ios__alert__app-ui__actions",children:oi(n)?e("div",{className:"notificare__push__ios__alert__app-ui__actions-single",children:[t("div",{className:"notificare__push__ios__alert__app-ui__single-cancel",children:t(on,{id:"preview.ios.alert.appUi.cancel",defaultMessage:bn["preview.ios.alert.appUi.cancel"]})}),t("div",{className:"notificare__push__ios__alert__app-ui__action notificare__push__ios__alert__app-ui__action--single","data-testid":"ios-app-ui-text-alert-notification-single-action",children:null===(i=n.actions)||void 0===i?void 0:i[0].label})]}):si(n)?e("div",{className:"notificare__push__ios__alert__app-ui__actions-multiple",children:[null===(r=n.actions)||void 0===r?void 0:r.map(((e,n)=>t("div",{className:"notificare__push__ios__alert__app-ui__action notificare__push__ios__alert__app-ui__action--multiple","data-testid":`ios-app-ui-text-alert-notification-action-${n}`,children:e.label},n))),t("div",{className:"notificare__push__ios__alert__app-ui__multiple-cancel",children:t(on,{id:"preview.ios.alert.appUi.cancel",defaultMessage:bn["preview.ios.alert.appUi.cancel"]})})]}):t("div",{className:"notificare__push__ios__alert__app-ui__no-actions",children:t(on,{id:"preview.ios.alert.appUi.ok",defaultMessage:bn["preview.ios.alert.appUi.ok"]})})})]})})}ln(".notificare .notificare__push__ios__alert__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__background {\n width: 300px;\n background: #fff;\n border-radius: 20px;\n overflow: hidden;\n border: 1px solid #f2f4f6;\n}\n\n/* Header - Title and Message */\n\n.notificare .notificare__push__ios__alert__app-ui__title-and-message {\n padding: 20px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n word-break: break-word;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__title {\n font-size: 16px;\n font-weight: 700;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__message {\n margin-top: 3px;\n font-size: 12px;\n font-weight: 500;\n text-align: center;\n}\n\n/* --- Actions --- */\n\n.notificare .notificare__push__ios__alert__app-ui__actions {\n font-size: 14px;\n font-weight: 700;\n border-top: 1px solid #f2f4f6;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action {\n padding: 10px 20px;\n text-align: center;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n/* Single Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__actions-single {\n display: flex;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__single-cancel {\n padding: 10px 20px;\n border-right: 1px solid #f2f4f6;\n width: 50%;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action--single {\n width: 50%;\n}\n\n/* Multiple Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__actions-multiple {\n display: flex;\n flex-direction: column;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__multiple-cancel {\n padding: 10px 20px;\n width: 100%;\n text-align: center;\n}\n\n.notificare .notificare__push__ios__alert__app-ui__action--multiple {\n width: 100%;\n border-bottom: 1px solid #f2f4f6;\n}\n\n/* No Actions */\n\n.notificare .notificare__push__ios__alert__app-ui__no-actions {\n width: 100%;\n text-align: center;\n padding: 10px 20px;\n}");function ia({notification:n}){const i=n.content[0],r=ii();return e("div",{"data-testid":"ios-app-ui-video-notification",children:[t(Lr,{title:n.title||r.name,showOptions:ai(n)}),t(kr,{videoData:i,width:"100%",height:"566px"})]})}ln("");function ra({notification:n}){const i=n.content[0].data,r=ii();return e("div",{"data-testid":"ios-app-ui-web-view-notification",children:[t(Lr,{title:n.title||r.name,showOptions:ai(n)&&!li(i)}),t("iframe",{className:"notificare__push__ios__web-view__app-ui__content",srcDoc:i,sandbox:"allow-same-origin"})]})}ln(".notificare .notificare__push__ios__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 566px;\n background-color: #fff;\n pointer-events: none;\n}");function aa({notification:n,expanded:i}){var r,a;const o=ii();return e("div",{className:"notificare__push__ios__lock-screen","data-testid":"ios-lock-screen-notification",children:[e("div",{className:"notificare__push__ios__lock-screen__main-content",children:[t("div",{className:"notificare__push__ios__lock-screen__app-icon",children:o.icon?t("img",{className:"notificare__push__ios__lock-screen__app-icon-image",alt:"App icon",src:o.icon}):t(yr,{className:"notificare__push__ios__lock-screen__default-app-icon"})}),e("div",{className:"notificare__push__ios__lock-screen__text-content",children:[e("div",{className:"notificare__push__ios__lock-screen__title-and-time",children:[t("p",{className:"notificare__push__ios__lock-screen__text "+(i?"notificare__push__ios__lock-screen__text--expanded-title-or-subtitle":"notificare__push__ios__lock-screen__text--title-or-subtitle"),children:n.title||o.name}),t("p",{className:"notificare__push__ios__lock-screen__text notificare__push__ios__lock-screen__text--time",children:t(on,{id:"preview.ios.lockScreen.time",defaultMessage:bn["preview.ios.lockScreen.time"]})})]}),n.subtitle&&t("p",{className:"notificare__push__ios__lock-screen__text "+(i?"notificare__push__ios__lock-screen__text--expanded-title-or-subtitle":"notificare__push__ios__lock-screen__text--title-or-subtitle"),children:n.subtitle}),e("div",{className:"notificare__push__ios__lock-screen__message-and-media",children:[t("p",{className:"notificare__push__ios__lock-screen__text "+(ci(n)&&!i?"notificare__push__ios__lock-screen__text--message-with-media":"notificare__push__ios__lock-screen__text--message-without-media"),children:n.message}),ci(n)&&!i&&t("img",{className:"notificare__push__ios__lock-screen__media-image",src:null===(r=n.attachments)||void 0===r?void 0:r[0].uri,alt:"Media icon","data-testid":"ios-lock-screen-notification-media"})]})]})]}),ci(n)&&i&&t("img",{className:"notificare__push__ios__lock-screen__expanded-media",src:null===(a=n.attachments)||void 0===a?void 0:a[0].uri,alt:"Media icon","data-testid":"ios-lock-screen-notification-expanded-media"})]})}ln(".notificare .notificare__push__ios__lock-screen {\n position: absolute;\n font-family: -apple-system, BlinkMacSystemFont, sans-serif;\n left: 50%;\n transform: translateX(-50%);\n bottom: 80px;\n background-color: #f2f4f6;\n width: 315px;\n border-radius: 20px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__ios__lock-screen__main-content {\n width: 100%;\n display: flex;\n align-items: center;\n column-gap: 11px;\n padding: 10px;\n}\n\n/* App Icon */\n\n.notificare .notificare__push__ios__lock-screen__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 10px;\n width: 35px;\n height: 35px;\n overflow: hidden;\n}\n\n.notificare .notificare__push__ios__lock-screen__app-icon-image {\n width: 100%;\n}\n\n.notificare .notificare__push__ios__lock-screen__default-app-icon {\n height: 100%;\n width: 100%;\n}\n\n/* Text Content */\n\n.notificare .notificare__push__ios__lock-screen__text-content {\n display: flex;\n flex-direction: column;\n row-gap: 2px;\n width: 249px;\n}\n\n.notificare .notificare__push__ios__lock-screen__title-and-time {\n display: flex;\n column-gap: 5px;\n margin-top: 0;\n margin-bottom: 0;\n position: relative;\n width: 100%;\n justify-content: space-between;\n}\n\n.notificare .notificare__push__ios__lock-screen__text {\n font-size: 13px;\n margin-top: 0;\n margin-bottom: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--title-or-subtitle {\n font-weight: 700;\n width: 210px;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--expanded-title-or-subtitle {\n font-weight: 700;\n width: 210px;\n white-space: wrap;\n word-break: break-word;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--time {\n color: #64706e;\n font-size: 12px;\n text-align: right;\n flex-shrink: 0;\n max-width: 130px;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--message-without-media {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n -webkit-line-clamp: 4;\n width: 242px;\n}\n\n.notificare .notificare__push__ios__lock-screen__text--message-with-media {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n -webkit-line-clamp: 4;\n width: 210px;\n}\n\n/* Media */\n\n.notificare .notificare__push__ios__lock-screen__message-and-media {\n display: flex;\n column-gap: 7px;\n}\n\n.notificare .notificare__push__ios__lock-screen__media-image {\n border-radius: 5px;\n object-fit: cover;\n width: 32px;\n height: 32px;\n align-self: flex-start;\n justify-self: flex-end;\n}\n\n.notificare .notificare__push__ios__lock-screen__expanded-media {\n object-fit: cover;\n width: 100%;\n max-height: 275px;\n overflow: hidden;\n display: block;\n}\n");var oa;function sa({notification:e,previewState:n,onError:i}){const r=Jt();if(o((function(){la(e.type,n.displayMode)||i(r.formatMessage({id:"preview.error.notSupportedNotificationTypePreviewVariant",defaultMessage:bn["preview.error.notSupportedNotificationTypePreviewVariant"]},{notificationType:e.type}))}),[n,e.type]),la(e.type,n.displayMode))return t(un,{theme:ca(e.type,n.displayMode),children:t("div",{className:"notificare__push__ios__preview",children:(()=>{switch(n.displayMode){case"lockscreen":case"lockscreen-expanded":return t(aa,{notification:e,expanded:"lockscreen-expanded"===n.displayMode});case"app-ui":switch(e.type){case"re.notifica.notification.Alert":return t(na,{notification:e});case"re.notifica.notification.WebView":return t(ra,{notification:e});case"re.notifica.notification.URL":return t(Rr,{notification:e});case"re.notifica.notification.InAppBrowser":return t(Pr,{notification:e});case"re.notifica.notification.Image":return t(Qr,{notification:e});case"re.notifica.notification.Map":return t(ea,{notification:e,onError:i});case"re.notifica.notification.Rate":return t(ta,{title:e.title});case"re.notifica.notification.Passbook":return t(Jr,{notification:e});case"re.notifica.notification.Video":return t(ia,{notification:e});case"re.notifica.notification.Store":return t(Yr,{notification:e});case"re.notifica.notification.URLResolver":return t(Ir,{notification:e,onError:i})}}})()})})}function ca(e,t){if("app-ui"===t)switch(e){case"re.notifica.notification.Alert":case"re.notifica.notification.WebView":case"re.notifica.notification.URL":case"re.notifica.notification.InAppBrowser":case"re.notifica.notification.Image":case"re.notifica.notification.Rate":case"re.notifica.notification.Passbook":case"re.notifica.notification.Video":case"re.notifica.notification.Store":case"re.notifica.notification.Map":case"re.notifica.notification.URLResolver":return"dark";default:return"light"}return"light"}function la(e,t){if("app-ui"===t)switch(e){case"re.notifica.notification.Alert":case"re.notifica.notification.WebView":case"re.notifica.notification.URL":case"re.notifica.notification.InAppBrowser":case"re.notifica.notification.Image":case"re.notifica.notification.Map":case"re.notifica.notification.Rate":case"re.notifica.notification.Passbook":case"re.notifica.notification.Video":case"re.notifica.notification.Store":case"re.notifica.notification.URLResolver":return!0;default:return!1}return!0}function pa(){return pa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},pa.apply(null,arguments)}ln(".notificare .notificare__push__ios__preview {\n font-family: -apple-system, BlinkMacSystemFont, sans-serif;\n height: 100%;\n}");var da=function(e){return i.createElement("svg",pa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 48 48",width:"1em",height:"1em"},e),oa||(oa=i.createElement("path",{d:"m12.45 37.65-2.1-2.1L21.9 24 10.35 12.45l2.1-2.1L24 21.9l11.55-11.55 2.1 2.1L26.1 24l11.55 11.55-2.1 2.1L24 26.1Z"})))};function ua({notification:e}){return t("div",{"data-testid":"web-mobile-app-ui-url-notification",children:t($n,{url:e.content[0].data,platform:"Web",width:268,height:430})})}function _a({notification:e,onError:n}){const i=Jt(),r=bi(e.content[0].data);switch(o((function(){switch(r){case"invalid-url":n(i.formatMessage({id:"preview.error.urlResolverInvalidUrl",defaultMessage:bn["preview.error.urlResolverInvalidUrl"]}));break;case"url-scheme":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithUrlSchemePreview",defaultMessage:bn["preview.error.notSupportedUrlResolverWithUrlSchemePreview"]}));break;case"in-app-browser":n(i.formatMessage({id:"preview.error.urlResolverNoNotificareWebViewQueryParameter",defaultMessage:bn["preview.error.urlResolverNoNotificareWebViewQueryParameter"]}));break;case"dynamic-link":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithDynamicLink",defaultMessage:bn["preview.error.notSupportedUrlResolverWithDynamicLink"]}));break;case"relative-url":n(i.formatMessage({id:"preview.error.notSupportedUrlResolverWithRelativeUrl",defaultMessage:bn["preview.error.notSupportedUrlResolverWithRelativeUrl"]}))}}),[r]),r){case"invalid-url":case"url-scheme":case"in-app-browser":case"dynamic-link":case"relative-url":return;case"web-view":return t(ua,{notification:e})}}function ha({notification:n}){var i;return e("div",{"data-testid":"web-mobile-app-ui-text-alert-notification",children:[ci(n)&&t("img",{className:"notificare__web__phone__alert__app-ui__media",src:null===(i=n.attachments)||void 0===i?void 0:i[0].uri,alt:"Notification attachment"}),e("div",{children:[t("p",{className:"notificare__web__phone__alert__app-ui__title",children:n.title}),t("p",{className:"notificare__web__phone__alert__app-ui__subtitle",children:n.subtitle}),t("p",{className:"notificare__web__phone__alert__app-ui__message",children:n.message})]})]})}ln(".notificare .notificare__web__phone__alert__app-ui__media {\n max-width: 100%;\n max-height: 250px;\n aspect-ratio: 16 / 9;\n margin-bottom: 10px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__title {\n font-size: 16px;\n font-weight: 600;\n margin-bottom: 8px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__subtitle {\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n}\n\n.notificare .notificare__web__phone__alert__app-ui__message {\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n}");function fa({notification:e}){return t("div",{className:"notificare__web__phone__image__app-ui__image-slider","data-testid":"web-mobile-app-ui-image-notification",children:e.content.map(((e,n)=>t("img",{className:"notificare__web__phone__image__app-ui__image-slider-item",src:e.data,alt:"Slider image"},n)))})}ln(".notificare .notificare__web__phone__image__app-ui__image-slider {\n display: flex;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n width: 100%;\n scroll-behavior: smooth;\n scrollbar-width: thin; /* Firefox */\n scrollbar-color: #bbb transparent; /* Firefox */\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-item {\n display: flex;\n min-width: 100%;\n scroll-snap-align: start;\n}\n\n/* For Chrome, Edge and Safari */\n.notificare .notificare__web__phone__image__app-ui__image-slider::-webkit-scrollbar {\n height: 4px;\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-webkit-scrollbar-thumb {\n background: #999;\n border-radius: 10px;\n}\n\n.notificare .notificare__web__phone__image__app-ui__image-slider-webkit-scrollbar-track {\n background: transparent;\n}");function ma({notification:e}){return t("iframe",{className:"notificare__web__phone__web-view__app-ui__content",srcDoc:e.content[0].data,sandbox:"allow-same-origin","data-testid":"web-mobile-app-ui-web-view-notification"})}ln(".notificare .notificare__web__phone__web-view__app-ui__content {\n border: 0;\n width: 100%;\n height: 360px;\n background-color: #fff;\n pointer-events: none;\n}");var ga;function va({notification:n,onError:i}){const r=ii(),{googleMapsAPIKey:a}=Dn(),s=Jt();return o((function(){a||"re.notifica.notification.Map"!==n.type||i(s.formatMessage({id:"preview.error.provideGoogleMapsApiKey",defaultMessage:bn["preview.error.provideGoogleMapsApiKey"]}))}),[n.type,a]),t("div",{className:"notificare__web__phone__app-ui",children:e("div",{className:"notificare__web__phone__app-ui__background",children:[e("div",{className:"notificare__web__phone__app-ui__header",children:[t("div",{className:"notificare__web__phone__app-ui__app-icon",children:r.websitePushConfig.icon?t("img",{className:"notificare__web__phone__app-ui__app-icon-image",src:r.websitePushConfig.icon,alt:"App icon"}):t(yr,{className:"notificare__web__phone__app-ui__default-app-icon"})}),t("p",{className:"notificare__web__phone__app-ui__app-name",children:r.name}),t("button",{className:"notificare__web__phone__app-ui__close-button",children:t(da,{className:"notificare__web__phone__app-ui__close-button-icon"})})]}),(()=>{switch(n.type){case"re.notifica.notification.Alert":return t(ha,{notification:n});case"re.notifica.notification.WebView":return t(ma,{notification:n});case"re.notifica.notification.URL":return t("div",{"data-testid":"web-mobile-app-ui-url-notification",children:t($n,{url:n.content[0].data,platform:"Web",width:268,height:430})});case"re.notifica.notification.Image":return t(fa,{notification:n});case"re.notifica.notification.Map":return t(fr,{notification:n,width:"100%",height:"400px"});case"re.notifica.notification.Video":return t("div",{"data-testid":"web-mobile-app-ui-video-notification",children:t(kr,{videoData:n.content[0],width:"100%",height:"430px"})});case"re.notifica.notification.URLResolver":return t(_a,{notification:n,onError:i})}})(),n.actions&&t("div",{className:""+(n.actions.length>=3?"notificare__web__phone__app-ui__actions-column":"notificare__web__phone__app-ui__actions-row"),children:n.actions.map(((e,n)=>t("button",{className:"notificare__web__phone__app-ui__action "+(0===n?"notificare__web__phone__app-ui__action--primary":"notificare__web__phone__app-ui__action--secondary"),"data-testid":`web-mobile-app-ui-action-${n}`,children:e.label},n)))})]})})}function ba(){return ba=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},ba.apply(null,arguments)}ln("/* MAIN */\n\n.notificare .notificare__web__phone__app-ui {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__web__phone__app-ui__background {\n width: 300px;\n background-color: white;\n border-radius: 4px;\n padding: 16px;\n display: flex;\n flex-direction: column;\n row-gap: 16px;\n}\n\n/* Header */\n\n.notificare .notificare__web__phone__app-ui__header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n column-gap: 16px;\n}\n\n.notificare .notificare__web__phone__app-ui__app-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 4px;\n height: 32px;\n width: 32px;\n overflow: hidden;\n}\n\n.notificare .notificare__web__phone__app-ui__app-icon-image {\n width: 100%;\n}\n\n.notificare .notificare__web__phone__app-ui__default-app-icon {\n height: 100%;\n width: 100%;\n}\n\n.notificare .notificare__web__phone__app-ui__app-name {\n font-size: 18px;\n flex: 1;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n display: block;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button {\n width: 32px;\n height: 32px;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: transparent;\n border: none;\n cursor: pointer;\n border-radius: 4px;\n padding: 0;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button:hover {\n transition: background-color .3s ease-in-out, border-radius .3s ease-in-out;\n background-color: #f4f5f9;\n}\n\n.notificare .notificare__web__phone__app-ui__close-button-icon {\n width: 24px;\n height: 24px;\n}\n\n/* Actions */\n\n.notificare .notificare__web__phone__app-ui__actions-row {\n display: flex;\n flex-wrap: wrap;\n column-gap: 8px;\n row-gap: 8px;\n flex-direction: row-reverse;\n}\n\n.notificare .notificare__web__phone__app-ui__actions-column {\n display: flex;\n flex-direction: column;\n row-gap: 8px;\n align-items: stretch;\n}\n\n.notificare .notificare__web__phone__app-ui__action {\n font-size: 14px;\n font-weight: 500;\n line-height: 20px;\n overflow: hidden;\n padding: 8px 16px;\n text-overflow: ellipsis;\n transition: background-color .3s ease-in-out, color .3s ease-in-out;\n white-space: nowrap;\n border-radius: 4px;\n border: 0;\n cursor: pointer;\n}\n\n.notificare .notificare__web__phone__app-ui__action--full-width {\n width: 100%\n}\n\n.notificare .notificare__web__phone__app-ui__action--primary {\n background-color: #2b42f7;\n color: #ffffffde;\n}\n\n.notificare .notificare__web__phone__app-ui__action--primary:hover {\n background-color: #071cc3;\n}\n\n.notificare .notificare__web__phone__app-ui__action--secondary {\n background-color: transparent;\n color: #2b42f7;\n}\n\n.notificare .notificare__web__phone__app-ui__action--secondary:hover {\n background-color: #f4f5f9;\n}\n");var wa=function(e){return i.createElement("svg",ba({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 48 48"},e),ga||(ga=i.createElement("defs",null,i.createElement("linearGradient",{id:"google-chrome_svg__a",x1:3.217,x2:44.781,y1:15,y2:15,gradientUnits:"userSpaceOnUse"},i.createElement("stop",{offset:0,stopColor:"#d93025"}),i.createElement("stop",{offset:1,stopColor:"#ea4335"})),i.createElement("linearGradient",{id:"google-chrome_svg__b",x1:20.722,x2:41.504,y1:47.679,y2:11.684,gradientUnits:"userSpaceOnUse"},i.createElement("stop",{offset:0,stopColor:"#fcc934"}),i.createElement("stop",{offset:1,stopColor:"#fbbc04"})),i.createElement("linearGradient",{id:"google-chrome_svg__c",x1:26.598,x2:5.816,y1:46.502,y2:10.506,gradientUnits:"userSpaceOnUse"},i.createElement("stop",{offset:0,stopColor:"#1e8e3e"}),i.createElement("stop",{offset:1,stopColor:"#34a853"})))),i.createElement("circle",{cx:24,cy:23.995,r:12,style:{fill:"#fff"}}),i.createElement("path",{d:"M3.215 36A24 24 0 1 0 12 3.215 24 24 0 0 0 3.215 36m31.177-18A12 12 0 1 1 18 13.608 12 12 0 0 1 34.392 18",style:{fill:"none"}}),i.createElement("path",{d:"M24 12h20.781a23.994 23.994 0 0 0-41.564.003L13.607 30l.01-.002A11.985 11.985 0 0 1 24 12",style:{fill:"url(#google-chrome_svg__a)"}}),i.createElement("circle",{cx:24,cy:24,r:9.5,style:{fill:"#1a73e8"}}),i.createElement("path",{d:"M34.391 30.003 24.001 48A23.994 23.994 0 0 0 44.78 12.003H23.999l-.003.01a11.985 11.985 0 0 1 10.395 17.99",style:{fill:"url(#google-chrome_svg__b)"}}),i.createElement("path",{d:"M13.609 30.003 3.218 12.006A23.994 23.994 0 0 0 24.003 48l10.39-17.997-.007-.007a11.985 11.985 0 0 1-20.777.007",style:{fill:"url(#google-chrome_svg__c)"}}))};function ya(e){const{open:n,disabled:i,onToggle:r}=e;return t("button",{disabled:i,className:"notificare__push__web__desktop__lock-screen__expand-button "+(n?"notificare__push__web__desktop__lock-screen__expand-button--rotated":""),onClick:r,"data-testid":"web-desktop-expand-button",children:t(kn,{className:"notificare__push__web__desktop__lock-screen__expand-button-svg"})})}ln(".notificare .notificare__push__web__desktop__lock-screen__expand-button {\n background: none;\n border: none;\n padding: 0;\n cursor: pointer;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n transition: transform 0.3s ease;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button--rotated {\n transform: rotate(90deg);\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button-svg {\n width: 11px;\n height: 11px;\n fill: #9e9e9e;\n}");ln("/* Preview Wrapper */\n\n.notificare .notificare__push__web__desktop__lock-screen {\n position: relative;\n background-color: #f4f4f4;\n width: 340px;\n border-radius: 15px;\n border: 1px solid #e4e4e4;\n box-shadow: 1px 1px 10px rgba(0, 0, 0, 0.1);\n transition: height 0.3s ease-in-out;\n align-self: start;\n}\n\n/* Expand Button */\n\n.notificare .notificare__push__web__desktop__lock-screen__expand-button-container {\n position: absolute;\n top: 8px;\n right: 8px;\n animation: fadeIn 0.5s ease-out forwards;\n}\n\n/* --- MAIN CONTENT --- */\n\n.notificare .notificare__push__web__desktop__lock-screen__main-content {\n width: 100%;\n display: flex;\n flex-direction: row;\n column-gap: 10px;\n padding: 14px;\n}\n\n/* Browser Icon */\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon-background {\n background-color: #ffffff;\n border-radius: 10px;\n padding: 4px;\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__browser-icon-svg {\n width: 30px;\n height: auto;\n}\n\n/* Text */\n\n.notificare .notificare__push__web__desktop__lock-screen__text-content {\n width: 219px;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text {\n font-size: 14px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n margin-top: 0;\n margin-bottom: 0;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--title {\n font-weight: 700;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--domain {\n font-weight: 700;\n margin-top: 2px;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--message {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n margin-top: 2px;\n -webkit-line-clamp: 3;\n line-height: 1.2;\n transition: height 0.3s ease-in-out;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__text--expandable-message {\n display: -webkit-box;\n -webkit-box-orient: vertical;\n word-break: break-word;\n white-space: wrap;\n margin-top: 2px;\n line-height: 1.2;\n transition: height 0.3s ease-in-out;\n}\n\n/* Small Media */\n\n.notificare .notificare__push__web__desktop__lock-screen__small-media {\n position: absolute;\n display: flex;\n justify-content: flex-end;\n width: 38px;\n height: 38px;\n border-radius: 25%;\n object-fit: cover;\n animation: fadeIn 0.5s ease-out forwards;\n right: 14px;\n bottom: 10px;\n}\n\n/* Expanded Media */\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-media {\n width: 100%;\n display: block;\n}\n\n/* Time */\n\n.notificare .notificare__push__web__desktop__lock-screen__time-container {\n position: absolute;\n top: 8px;\n right: 14px;\n animation: fadeIn 0.5s ease-out forwards;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__time {\n font-size: 12px;\n color: #64706e;\n}\n\n/* SETTINGS */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button-container {\n position: absolute;\n bottom: 10px;\n right: 14px;\n z-index: 10;\n}\n\n/* Settings Button */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button {\n min-width: 70px;\n display: flex;\n background-color: #d6d6d6;\n border-radius: 7px;\n border: 0;\n padding: 5px 10px 5px;\n font-size: 13px;\n justify-content: center;\n box-shadow: -5px -7px 10px 10px rgba(242, 244, 246, 1);\n animation: fadeIn 0.5s ease-out forwards;\n position: relative;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-button-expand-icon {\n width: 9px;\n margin-left: 4px;\n color: #000000;\n}\n\n/* Settings Selector */\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector {\n background-color: #eaeaea;\n border-radius: 7px;\n box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);\n padding: 4px;\n display: flex;\n flex-direction: column;\n position: absolute;\n top: 32px;\n width: max-content;\n right: 0;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector-option {\n min-width: 70px;\n background-color: transparent;\n border-radius: 7px;\n font-size: 13px;\n border: 0;\n padding: 5px 10px;\n flex: 1;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__settings-selector-option:hover {\n background-color: #3b82f6;\n color: #fff;\n}\n\n/* Expanded Options - Actions & Settings */\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-content {\n padding: 0 14px 14px;\n width: 100%;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-divisor {\n border: none;\n border-top: 1px solid #d6d6d6;\n width: 102%;\n margin-left: -1%;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-button {\n font-size: 14px;\n border-radius: 7px;\n width: 100%;\n border: 0;\n padding: 8px;\n background-color: transparent;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-button:hover {\n background-color: #efefef;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-buttons-divisor {\n border: none;\n border-top: 1px solid #d6d6d6;\n}\n\n.notificare .notificare__push__web__desktop__lock-screen__expanded-buttons-divisor--transparent {\n border-top: 1px solid transparent;\n}\n\n\n\n/* keyframes */\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n\n\n\n\n");function xa({notification:i}){var r,s,l;const[p,d]=a(!1),[u,_]=a(!1),[h,f]=a(-1),[m,g]=a(!1),[v,b]=a(!1),[w,y]=a(!1),[x,k]=a(!1),[E,N]=a(""),S=c(null),T=c(null),A=ii();return o((function(){if(S.current&&T.current){const e=T.current.scrollHeight;g(e>3*16.7);const t=`${S.current.scrollHeight}px`;S.current.style.height=t,N(t)}}),[]),o((function(){ci(i)&&g(!0)}),[]),e("div",{ref:S,className:"notificare__push__web__desktop__lock-screen",onMouseEnter:()=>_((()=>!0)),onMouseLeave:()=>_((()=>v)),"data-testid":"web-desktop-notification",children:[(m&&u||p||w)&&t("div",{className:"notificare__push__web__desktop__lock-screen__expand-button-container",children:t(ya,{open:p,disabled:w||x,onToggle:function(){const e=S.current,t=T.current;e&&t&&(p?(e.style.backgroundColor="#f4f4f4",e.style.height=E,y(!0),d(!1),setTimeout((()=>{y(!1),e.style.overflow=""}),300)):(e.style.backgroundColor="#fff",e.style.overflow="hidden",k(!0),d(!0),setTimeout((()=>{e.style.height=`${e.scrollHeight}px`}),10),setTimeout((()=>{k(!1)}),300)),b(!1))}})}),!u&&!p&&!w&&t("div",{className:"notificare__push__web__desktop__lock-screen__time-container",children:t("p",{className:"notificare__push__web__desktop__lock-screen__time",children:t(on,{id:"preview.web.desktop.macos.lockScreen.time",defaultMessage:bn["preview.web.desktop.macos.lockScreen.time"]})})}),e("div",{className:"notificare__push__web__desktop__lock-screen__main-content",children:[t("div",{className:"notificare__push__web__desktop__lock-screen__browser-icon",children:t("div",{className:"notificare__push__web__desktop__lock-screen__browser-icon-background",children:t(wa,{className:"notificare__push__web__desktop__lock-screen__browser-icon-svg","aria-label":"Google Chrome icon"})})}),e("div",{className:"notificare__push__web__desktop__lock-screen__text-content",children:[t("p",{className:"notificare__push__web__desktop__lock-screen__text notificare__push__web__desktop__lock-screen__text--title",children:i.title||A.name}),t("p",{className:"notificare__push__web__desktop__lock-screen__text notificare__push__web__desktop__lock-screen__text--domain",children:A.websitePushConfig.allowedDomains.length>0?ka(A.websitePushConfig.allowedDomains[0]):"example.com"}),t("p",{ref:T,className:"notificare__push__web__desktop__lock-screen__text "+(p||w?"notificare__push__web__desktop__lock-screen__text--expandable-message":"notificare__push__web__desktop__lock-screen__text--message"),children:i.message})]}),ci(i)&&!p&&!w&&!u&&t("img",{className:"notificare__push__web__desktop__lock-screen__small-media",src:null===(r=i.attachments)||void 0===r?void 0:r[0].uri,alt:"Small media icon"}),u&&!p&&!w&&t("div",{className:"notificare__push__web__desktop__lock-screen__settings-button-container",children:i.actions&&i.actions.length>0?e(n,{children:[e("button",{className:"notificare__push__web__desktop__lock-screen__settings-button",onClick:()=>b((e=>!e)),"data-testid":"web-desktop-settings-button",children:[t(on,{id:"preview.web.desktop.macos.lockScreen.options",defaultMessage:bn["preview.web.desktop.macos.lockScreen.options"]}),t(kn,{className:"notificare__push__web__desktop__lock-screen__settings-button-expand-icon"})]}),v&&e("div",{className:"notificare__push__web__desktop__lock-screen__settings-selector",children:[i.actions.map(((e,n)=>t("button",{className:"notificare__push__web__desktop__lock-screen__settings-selector-option","data-testid":`web-desktop-options-action-${n}`,children:e.label},n))),t("button",{className:"notificare__push__web__desktop__lock-screen__settings-selector-option",children:t(on,{id:"preview.web.desktop.macos.lockScreen.settings",defaultMessage:bn["preview.web.desktop.macos.lockScreen.settings"]})})]})]}):t("button",{className:"notificare__push__web__desktop__lock-screen__settings-button",children:t(on,{id:"preview.web.desktop.macos.lockScreen.settings",defaultMessage:bn["preview.web.desktop.macos.lockScreen.settings"]})})})]}),(p||w)&&e("div",{className:"notificare__push__web__desktop__lock-screen__expanded-content",children:[ci(i)&&t("img",{className:"notificare__push__web__desktop__lock-screen__expanded-media",src:null===(s=i.attachments)||void 0===s?void 0:s[0].uri,alt:"Expanded media"}),t("hr",{className:"notificare__push__web__desktop__lock-screen__expanded-divisor"}),null===(l=i.actions)||void 0===l?void 0:l.map(((n,i)=>e("div",{className:"notificare__push__web__desktop__lock-screen__action",children:[t("button",{className:"notificare__push__web__desktop__lock-screen__expanded-button",onMouseEnter:()=>f(i),onMouseLeave:()=>f(-1),"data-testid":`web-desktop-expanded-action-${i}`,children:n.label}),t("hr",{className:`notificare__push__web__desktop__lock-screen__expanded-buttons-divisor ${(h===i||h-1===i)&&"notificare__push__web__desktop__lock-screen__expanded-buttons-divisor--transparent"}`})]},i))),t("button",{className:"notificare__push__web__desktop__lock-screen__expanded-button",onMouseEnter:()=>{var e;return f((null===(e=i.actions)||void 0===e?void 0:e.length)||-1)},onMouseLeave:()=>f(-1),children:t(on,{id:"preview.web.desktop.macos.lockScreen.settings",defaultMessage:bn["preview.web.desktop.macos.lockScreen.settings"]})})]})]})}function ka(e){try{return new URL(e).hostname}catch(e){return""}}function Ea({notification:e,previewState:n,onError:i}){const r=Jt();switch(o((function(){if("phone"===n.formFactor)switch(n.displayMode){case"lockscreen":case"lockscreen-expanded":i(r.formatMessage({id:"preview.error.notSupportedPreviewVariant",defaultMessage:bn["preview.error.notSupportedPreviewVariant"]}));break;case"app-ui":switch(e.type){case"re.notifica.notification.InAppBrowser":case"re.notifica.notification.Rate":case"re.notifica.notification.Store":case"re.notifica.notification.Passbook":case"re.notifica.notification.None":case"re.notifica.notification.URLScheme":i(r.formatMessage({id:"preview.error.notSupportedNotificationTypePreviewVariant",defaultMessage:bn["preview.error.notSupportedNotificationTypePreviewVariant"]},{notificationType:e.type}))}}}),[n,e.type]),n.formFactor){case"phone":if("app-ui"===n.displayMode)switch(e.type){case"re.notifica.notification.Alert":case"re.notifica.notification.WebView":case"re.notifica.notification.URL":case"re.notifica.notification.Image":case"re.notifica.notification.Map":case"re.notifica.notification.Video":case"re.notifica.notification.URLResolver":switch(n.os){case"android":return t(pn,{theme:Na(e.type),children:t(va,{notification:e,onError:i})});case"ios":return t(un,{theme:Na(e.type),children:t(va,{notification:e,onError:i})})}}break;case"desktop":if("macos"===n.os)return t(xa,{notification:e},e.message)}}function Na(e){switch(e){case"re.notifica.notification.Alert":case"re.notifica.notification.Map":case"re.notifica.notification.WebView":case"re.notifica.notification.URL":case"re.notifica.notification.Video":case"re.notifica.notification.Image":case"re.notifica.notification.URLResolver":return"dark";default:return"light"}}function Sa({notification:e,previewState:n}){const[i,r]=a(null),[o,s]=a(n);if(o!==n&&(r(null),s(n)),i)return t(Hn,{message:i,showConsoleWarning:!1});switch(n.platform){case"android":return t(Tr,{notification:e,previewState:n,onError:r});case"ios":return t(sa,{notification:e,previewState:n,onError:r});case"web":return t(Ea,{notification:e,previewState:n,onError:r})}}var Ta;function Aa(){return Aa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Aa.apply(null,arguments)}var Ma,Ca=function(e){return i.createElement("svg",Aa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",width:"1em",height:"1em"},e),Ta||(Ta=i.createElement("path",{d:"M420.6 301.9a24 24 0 1 1 24-24 24 24 0 0 1-24 24m-265.1 0a24 24 0 1 1 24-24 24 24 0 0 1-24 24m273.7-144.5 47.9-83a10 10 0 1 0-17.3-10l-48.5 84.1a301.3 301.3 0 0 0-246.6 0l-48.5-84a10 10 0 1 0-17.3 10l47.9 83C64.5 202.2 8.2 285.6 0 384h576c-8.2-98.5-64.5-181.8-146.9-226.6"})))};function Pa(){return Pa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Pa.apply(null,arguments)}var La;function Oa(){return Oa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Oa.apply(null,arguments)}var Ra;function Ia(){return Ia=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ia.apply(null,arguments)}var Ua,Ba=function(e){return i.createElement("svg",Ia({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",width:"1em",height:"1em"},e),Ra||(Ra=i.createElement("path",{d:"M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9m-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3"})))};function Ha(){return Ha=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ha.apply(null,arguments)}function ja({previewState:n,onPreviewStateChanged:i}){const r=Jt();return e("div",{className:"notificare__push__preview-controls","data-testid":"controls",children:[e("div",{className:"notificare__push__preview-controls-toggle-groups",children:[t(Bn,{label:r.formatMessage({id:"controls.platform",defaultMessage:bn["controls.platform"]}),options:Fa,value:n.platform,onValueChanged:function(e){if(n.platform!==e)switch(e){case"android":case"ios":i(Object.assign(Object.assign({},n),{platform:e}));break;case"web":i(Object.assign(Object.assign({},n),{platform:"web",formFactor:"desktop",os:"macos",displayMode:"lockscreen"}))}}}),"web"===n.platform&&t(Bn,{label:r.formatMessage({id:"controls.formFactor",defaultMessage:bn["controls.formFactor"]}),options:Da,value:n.formFactor,onValueChanged:function(e){if("web"===n.platform&&n.formFactor!==e)switch(e){case"desktop":i(Object.assign(Object.assign({},n),{formFactor:e,os:"macos",displayMode:"lockscreen"}));break;case"phone":i(Object.assign(Object.assign({},n),{formFactor:e,os:"android",displayMode:"app-ui"}))}}}),"web"===n.platform&&"phone"===n.formFactor&&t(Bn,{label:r.formatMessage({id:"controls.operatingSystem",defaultMessage:bn["controls.operatingSystem"]}),options:Ga,value:n.os,onValueChanged:function(e){"web"===n.platform&&"phone"===n.formFactor&&n.os!==e&&i(Object.assign(Object.assign({},n),{os:e}))}})]}),("android"===n.platform||"ios"===n.platform)&&t(Un,{label:r.formatMessage({id:"controls.variant",defaultMessage:bn["controls.variant"]}),options:Va,value:n.displayMode,onValueChanged:function(e){n.displayMode!==e&&i(Object.assign(Object.assign({},n),{displayMode:e}))}}),"web"===n.platform&&"desktop"===n.formFactor&&t(Un,{label:r.formatMessage({id:"controls.operatingSystem",defaultMessage:bn["controls.operatingSystem"]}),options:za,value:n.os,disabled:!0}),"web"===n.platform&&"phone"===n.formFactor&&t(Un,{label:r.formatMessage({id:"controls.variant",defaultMessage:bn["controls.variant"]}),options:Va,value:"app-ui",disabled:!0})]})}ln(".notificare .notificare__push__preview-controls {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 350px;\n row-gap: 14px;\n}\n\n.notificare .notificare__push__preview-controls-preview {\n margin-top: 14px;\n}\n\n.notificare .notificare__push__preview-controls-toggle-groups {\n display: flex;\n align-items: center;\n column-gap: 30px;\n align-self: start;\n}\n\n.notificare .notificare__push__preview-controls-toggle-group-divider {\n width: 20px;\n height: 20px;\n animation: fadeIn 0.3s ease-out;\n}\n\n/* Icons */\n\n.notificare .notificare__push__preview-controls-android-icon {\n width: 22px;\n height: auto;\n}\n\n.notificare .notificare__push__preview-controls-ios-icon {\n width: 28px;\n height: auto;\n}\n\n.notificare .notificare__push__preview-controls-html5-icon {\n width: 28px;\n height: auto;\n}\n\n.notificare .notificare__push__preview-controls-desktop-icon {\n width: 22px;\n height: auto;\n}\n\n.notificare .notificare__push__preview-controls-phone-icon {\n width: 24px;\n height: auto;\n}\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}");const Fa=[{value:"android",icon:t(Ca,{className:"notificare__push__preview-controls-android-icon"},"platforms-android-icon")},{value:"ios",icon:t(Ba,{className:"notificare__push__preview-controls-ios-icon"},"platform-ios-icon")},{value:"web",icon:t((function(e){return i.createElement("svg",Oa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",width:"1em",height:"1em"},e),La||(La=i.createElement("path",{d:"m0 32 34.9 395.8L191.5 480l157.6-52.2L384 32zm308.2 127.9H124.4l4.1 49.4h175.6l-13.6 148.4-97.9 27v.3h-1.1l-98.7-27.3-6-75.8h47.7L138 320l53.5 14.5 53.7-14.5 6-62.2H84.3L71.5 112.2h241.1z"})))}),{className:"notificare__push__preview-controls-html5-icon"},"platform-html5-icon")}],Da=[{value:"desktop",icon:t((function(e){return i.createElement("svg",Pa({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",width:"1em",height:"1em"},e),Ma||(Ma=i.createElement("path",{d:"M64 0C28.7 0 0 28.7 0 64v288c0 35.3 28.7 64 64 64h176l-10.7 32H160c-17.7 0-32 14.3-32 32s14.3 32 32 32h256c17.7 0 32-14.3 32-32s-14.3-32-32-32h-69.3L336 416h176c35.3 0 64-28.7 64-64V64c0-35.3-28.7-64-64-64zm448 64v288H64V64z"})))}),{className:"notificare__push__preview-controls-desktop-icon"},"form-factor-desktop-icon")},{value:"phone",icon:t((function(e){return i.createElement("svg",Ha({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",width:"1em",height:"1em"},e),Ua||(Ua=i.createElement("path",{d:"M16 64C16 28.7 44.7 0 80 0h224c35.3 0 64 28.7 64 64v384c0 35.3-28.7 64-64 64H80c-35.3 0-64-28.7-64-64zm208 384a32 32 0 1 0-64 0 32 32 0 1 0 64 0m80-384H80v320h224z"})))}),{className:"notificare__push__preview-controls-phone-icon"},"form-factor-phone-icon")}],Ga=[{value:"android",icon:t(Ca,{className:"notificare__push__preview-controls-android-icon"},"device-android-icon")},{value:"ios",icon:t(Ba,{className:"notificare__push__preview-controls-ios-icon"},"device-iphone-icon")}],za=[{value:"macos",labelId:"controls.operatingSystem.macos",defaultLabel:bn["controls.operatingSystem.macos"]}],Va=[{value:"lockscreen",labelId:"controls.displayMode.lockScreen",defaultLabel:bn["controls.displayMode.lockScreen"]},{value:"lockscreen-expanded",labelId:"controls.displayMode.expandedLockScreen",defaultLabel:bn["controls.displayMode.expandedLockScreen"]},{value:"app-ui",labelId:"controls.displayMode.appUi",defaultLabel:bn["controls.displayMode.appUi"]}];ln("@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');\n\n.notificare {\n font-family: proxima-nova, Helvetica, Arial, sans-serif;\n color: #232c2a;\n}\n\n.notificare * {\n border: 0;\n margin: 0;\n box-sizing: border-box;\n}");ln(".notificare .notificare__push__preview-wrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n width: max-content;\n}\n\n.notificare .notificare__push__preview {\n margin-top: 20px;\n}\n\n/* Disable label selection in every preview */\n.notificare .notificare__push__preview p,\n.notificare .notificare__push__preview span,\n.notificare .notificare__push__preview div,\n.notificare .notificare__push__preview h1,\n.notificare .notificare__push__preview h2,\n.notificare .notificare__push__preview h3,\n.notificare .notificare__push__preview h4,\n.notificare .notificare__push__preview h5,\n.notificare .notificare__push__preview h6 {\n user-select: none;\n}");const Za={"android-lockscreen":{platform:"android",displayMode:"lockscreen"},"android-lockscreen-expanded":{platform:"android",displayMode:"lockscreen-expanded"},"android-app-ui":{platform:"android",displayMode:"app-ui"},"ios-lockscreen":{platform:"ios",displayMode:"lockscreen"},"ios-lockscreen-expanded":{platform:"ios",displayMode:"lockscreen-expanded"},"ios-app-ui":{platform:"ios",displayMode:"app-ui"},"web-desktop-macos":{platform:"web",displayMode:"lockscreen",formFactor:"desktop",os:"macos"},"web-android-app-ui":{platform:"web",displayMode:"app-ui",formFactor:"phone",os:"android"},"web-iphone-app-ui":{platform:"web",displayMode:"app-ui",formFactor:"phone",os:"ios"}};function $a({notification:n,applicationId:i,showControls:r=!0,variant:o="android-lockscreen"}){const[s,c]=a(Za[o]),{serviceKey:l}=Dn(),p=Tn({id:i,serviceKey:l});return e("div",{className:"notificare__push__preview-wrapper",children:[r&&t(ja,{previewState:s,onPreviewStateChanged:c}),(()=>{switch(p.status){case"idle":case"loading":return t(mn,{});case"success":return t(ni,{application:p.data,children:t("div",{className:"notificare__push__preview",children:t(Sa,{notification:n,previewState:s})})})}})()]})}var Wa,Ka;!function(e){e.assertEqual=e=>{},e.assertIs=function(e){},e.assertNever=function(e){throw new Error},e.arrayToEnum=e=>{const t={};for(const n of e)t[n]=n;return t},e.getValidEnumValues=t=>{const n=e.objectKeys(t).filter((e=>"number"!=typeof t[t[e]])),i={};for(const e of n)i[e]=t[e];return e.objectValues(i)},e.objectValues=t=>e.objectKeys(t).map((function(e){return t[e]})),e.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{const t=[];for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t},e.find=(e,t)=>{for(const n of e)if(t(n))return n},e.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&Number.isFinite(e)&&Math.floor(e)===e,e.joinValues=function(e,t=" | "){return e.map((e=>"string"==typeof e?`'${e}'`:e)).join(t)},e.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t}(Wa||(Wa={})),function(e){e.mergeShapes=(e,t)=>({...e,...t})}(Ka||(Ka={}));const qa=Wa.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Xa=e=>{switch(typeof e){case"undefined":return qa.undefined;case"string":return qa.string;case"number":return Number.isNaN(e)?qa.nan:qa.number;case"boolean":return qa.boolean;case"function":return qa.function;case"bigint":return qa.bigint;case"symbol":return qa.symbol;case"object":return Array.isArray(e)?qa.array:null===e?qa.null:e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch?qa.promise:"undefined"!=typeof Map&&e instanceof Map?qa.map:"undefined"!=typeof Set&&e instanceof Set?qa.set:"undefined"!=typeof Date&&e instanceof Date?qa.date:qa.object;default:return qa.unknown}},Ya=Wa.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class Ja extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){const t=e||function(e){return e.message},n={_errors:[]},i=e=>{for(const r of e.issues)if("invalid_union"===r.code)r.unionErrors.map(i);else if("invalid_return_type"===r.code)i(r.returnTypeError);else if("invalid_arguments"===r.code)i(r.argumentsError);else if(0===r.path.length)n._errors.push(t(r));else{let e=n,i=0;for(;i<r.path.length;){const n=r.path[i];i===r.path.length-1?(e[n]=e[n]||{_errors:[]},e[n]._errors.push(t(r))):e[n]=e[n]||{_errors:[]},e=e[n],i++}}};return i(this),n}static assert(e){if(!(e instanceof Ja))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Wa.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){const t={},n=[];for(const i of this.issues)i.path.length>0?(t[i.path[0]]=t[i.path[0]]||[],t[i.path[0]].push(e(i))):n.push(e(i));return{formErrors:n,fieldErrors:t}}get formErrors(){return this.flatten()}}Ja.create=e=>new Ja(e);const Qa=(e,t)=>{let n;switch(e.code){case Ya.invalid_type:n=e.received===qa.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case Ya.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,Wa.jsonStringifyReplacer)}`;break;case Ya.unrecognized_keys:n=`Unrecognized key(s) in object: ${Wa.joinValues(e.keys,", ")}`;break;case Ya.invalid_union:n="Invalid input";break;case Ya.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Wa.joinValues(e.options)}`;break;case Ya.invalid_enum_value:n=`Invalid enum value. Expected ${Wa.joinValues(e.options)}, received '${e.received}'`;break;case Ya.invalid_arguments:n="Invalid function arguments";break;case Ya.invalid_return_type:n="Invalid function return type";break;case Ya.invalid_date:n="Invalid date";break;case Ya.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:Wa.assertNever(e.validation):n="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case Ya.too_small:n="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case Ya.too_big:n="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case Ya.custom:n="Invalid input";break;case Ya.invalid_intersection_types:n="Intersection results could not be merged";break;case Ya.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case Ya.not_finite:n="Number must be finite";break;default:n=t.defaultError,Wa.assertNever(e)}return{message:n}};let eo=Qa;function to(e,t){const n=eo,i=(e=>{const{data:t,path:n,errorMaps:i,issueData:r}=e,a=[...n,...r.path||[]],o={...r,path:a};if(void 0!==r.message)return{...r,path:a,message:r.message};let s="";const c=i.filter((e=>!!e)).slice().reverse();for(const e of c)s=e(o,{data:t,defaultError:s}).message;return{...r,path:a,message:s}})({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===Qa?void 0:Qa].filter((e=>!!e))});e.common.issues.push(i)}class no{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){const n=[];for(const i of t){if("aborted"===i.status)return io;"dirty"===i.status&&e.dirty(),n.push(i.value)}return{status:e.value,value:n}}static async mergeObjectAsync(e,t){const n=[];for(const e of t){const t=await e.key,i=await e.value;n.push({key:t,value:i})}return no.mergeObjectSync(e,n)}static mergeObjectSync(e,t){const n={};for(const i of t){const{key:t,value:r}=i;if("aborted"===t.status)return io;if("aborted"===r.status)return io;"dirty"===t.status&&e.dirty(),"dirty"===r.status&&e.dirty(),"__proto__"===t.value||void 0===r.value&&!i.alwaysSet||(n[t.value]=r.value)}return{status:e.value,value:n}}}const io=Object.freeze({status:"aborted"}),ro=e=>({status:"dirty",value:e}),ao=e=>({status:"valid",value:e}),oo=e=>"aborted"===e.status,so=e=>"dirty"===e.status,co=e=>"valid"===e.status,lo=e=>"undefined"!=typeof Promise&&e instanceof Promise;var po;!function(e){e.errToObj=e=>"string"==typeof e?{message:e}:e||{},e.toString=e=>"string"==typeof e?e:e?.message}(po||(po={}));var uo,_o,ho=function(e,t,n,i){if("a"===n&&!i)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?i:"a"===n?i.call(e):i?i.value:t.get(e)},fo=function(e,t,n,i,r){if("m"===i)throw new TypeError("Private method is not writable");if("a"===i&&!r)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===i?r.call(e,n):r?r.value=n:t.set(e,n),n};class mo{constructor(e,t,n,i){this._cachedPath=[],this.parent=e,this.data=t,this._path=n,this._key=i}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const go=(e,t)=>{if(co(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new Ja(e.common.issues);return this._error=t,this._error}}};function vo(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:i,description:r}=e;if(t&&(n||i))throw new Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');if(t)return{errorMap:t,description:r};return{errorMap:(t,r)=>{const{message:a}=e;return"invalid_enum_value"===t.code?{message:a??r.defaultError}:void 0===r.data?{message:a??i??r.defaultError}:"invalid_type"!==t.code?{message:r.defaultError}:{message:a??n??r.defaultError}},description:r}}class bo{get description(){return this._def.description}_getType(e){return Xa(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:Xa(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new no,ctx:{common:e.parent.common,data:e.data,parsedType:Xa(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(lo(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const n=this.safeParse(e,t);if(n.success)return n.data;throw n.error}safeParse(e,t){const n={common:{issues:[],async:t?.async??!1,contextualErrorMap:t?.errorMap},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Xa(e)},i=this._parseSync({data:e,path:n.path,parent:n});return go(n,i)}"~validate"(e){const t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Xa(e)};if(!this["~standard"].async)try{const n=this._parseSync({data:e,path:[],parent:t});return co(n)?{value:n.value}:{issues:t.common.issues}}catch(e){e?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then((e=>co(e)?{value:e.value}:{issues:t.common.issues}))}async parseAsync(e,t){const n=await this.safeParseAsync(e,t);if(n.success)return n.data;throw n.error}async safeParseAsync(e,t){const n={common:{issues:[],contextualErrorMap:t?.errorMap,async:!0},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Xa(e)},i=this._parse({data:e,path:n.path,parent:n}),r=await(lo(i)?i:Promise.resolve(i));return go(n,r)}refine(e,t){const n=e=>"string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(e):t;return this._refinement(((t,i)=>{const r=e(t),a=()=>i.addIssue({code:Ya.custom,...n(t)});return"undefined"!=typeof Promise&&r instanceof Promise?r.then((e=>!!e||(a(),!1))):!!r||(a(),!1)}))}refinement(e,t){return this._refinement(((n,i)=>!!e(n)||(i.addIssue("function"==typeof t?t(n,i):t),!1)))}_refinement(e){return new gs({schema:this,typeName:Ss.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:e=>this["~validate"](e)}}optional(){return vs.create(this,this._def)}nullable(){return bs.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return es.create(this)}promise(){return ms.create(this,this._def)}or(e){return is.create([this,e],this._def)}and(e){return ss.create(this,e,this._def)}transform(e){return new gs({...vo(this._def),schema:this,typeName:Ss.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t="function"==typeof e?e:()=>e;return new ws({...vo(this._def),innerType:this,defaultValue:t,typeName:Ss.ZodDefault})}brand(){return new ks({typeName:Ss.ZodBranded,type:this,...vo(this._def)})}catch(e){const t="function"==typeof e?e:()=>e;return new ys({...vo(this._def),innerType:this,catchValue:t,typeName:Ss.ZodCatch})}describe(e){return new(0,this.constructor)({...this._def,description:e})}pipe(e){return Es.create(this,e)}readonly(){return Ns.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const wo=/^c[^\s-]{8,}$/i,yo=/^[0-9a-z]+$/,xo=/^[0-9A-HJKMNP-TV-Z]{26}$/i,ko=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,Eo=/^[a-z0-9_-]{21}$/i,No=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,So=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,To=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;let Ao;const Mo=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Co=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,Po=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,Lo=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Oo=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,Ro=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Io="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",Uo=new RegExp(`^${Io}$`);function Bo(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`);return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${e.precision?"+":"?"}`}function Ho(e){let t=`${Io}T${Bo(e)}`;const n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function jo(e,t){if(!No.test(e))return!1;try{const[n]=e.split("."),i=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),r=JSON.parse(atob(i));return"object"==typeof r&&null!==r&&((!("typ"in r)||"JWT"===r?.typ)&&(!!r.alg&&(!t||r.alg===t)))}catch{return!1}}function Fo(e,t){return!("v4"!==t&&t||!Co.test(e))||!("v6"!==t&&t||!Lo.test(e))}class Do extends bo{_parse(e){this._def.coerce&&(e.data=String(e.data));if(this._getType(e)!==qa.string){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.string,received:t.parsedType}),io}const t=new no;let n;for(const a of this._def.checks)if("min"===a.kind)e.data.length<a.value&&(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("max"===a.kind)e.data.length>a.value&&(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!1,message:a.message}),t.dirty());else if("length"===a.kind){const i=e.data.length>a.value,r=e.data.length<a.value;(i||r)&&(n=this._getOrReturnCtx(e,n),i?to(n,{code:Ya.too_big,maximum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}):r&&to(n,{code:Ya.too_small,minimum:a.value,type:"string",inclusive:!0,exact:!0,message:a.message}),t.dirty())}else if("email"===a.kind)To.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"email",code:Ya.invalid_string,message:a.message}),t.dirty());else if("emoji"===a.kind)Ao||(Ao=new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),Ao.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"emoji",code:Ya.invalid_string,message:a.message}),t.dirty());else if("uuid"===a.kind)ko.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"uuid",code:Ya.invalid_string,message:a.message}),t.dirty());else if("nanoid"===a.kind)Eo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"nanoid",code:Ya.invalid_string,message:a.message}),t.dirty());else if("cuid"===a.kind)wo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"cuid",code:Ya.invalid_string,message:a.message}),t.dirty());else if("cuid2"===a.kind)yo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"cuid2",code:Ya.invalid_string,message:a.message}),t.dirty());else if("ulid"===a.kind)xo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"ulid",code:Ya.invalid_string,message:a.message}),t.dirty());else if("url"===a.kind)try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),to(n,{validation:"url",code:Ya.invalid_string,message:a.message}),t.dirty()}else if("regex"===a.kind){a.regex.lastIndex=0;a.regex.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"regex",code:Ya.invalid_string,message:a.message}),t.dirty())}else if("trim"===a.kind)e.data=e.data.trim();else if("includes"===a.kind)e.data.includes(a.value,a.position)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:{includes:a.value,position:a.position},message:a.message}),t.dirty());else if("toLowerCase"===a.kind)e.data=e.data.toLowerCase();else if("toUpperCase"===a.kind)e.data=e.data.toUpperCase();else if("startsWith"===a.kind)e.data.startsWith(a.value)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:{startsWith:a.value},message:a.message}),t.dirty());else if("endsWith"===a.kind)e.data.endsWith(a.value)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:{endsWith:a.value},message:a.message}),t.dirty());else if("datetime"===a.kind){Ho(a).test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:"datetime",message:a.message}),t.dirty())}else if("date"===a.kind){Uo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:"date",message:a.message}),t.dirty())}else if("time"===a.kind){new RegExp(`^${Bo(a)}$`).test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.invalid_string,validation:"time",message:a.message}),t.dirty())}else"duration"===a.kind?So.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"duration",code:Ya.invalid_string,message:a.message}),t.dirty()):"ip"===a.kind?(i=e.data,("v4"!==(r=a.version)&&r||!Mo.test(i))&&("v6"!==r&&r||!Po.test(i))&&(n=this._getOrReturnCtx(e,n),to(n,{validation:"ip",code:Ya.invalid_string,message:a.message}),t.dirty())):"jwt"===a.kind?jo(e.data,a.alg)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"jwt",code:Ya.invalid_string,message:a.message}),t.dirty()):"cidr"===a.kind?Fo(e.data,a.version)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"cidr",code:Ya.invalid_string,message:a.message}),t.dirty()):"base64"===a.kind?Oo.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"base64",code:Ya.invalid_string,message:a.message}),t.dirty()):"base64url"===a.kind?Ro.test(e.data)||(n=this._getOrReturnCtx(e,n),to(n,{validation:"base64url",code:Ya.invalid_string,message:a.message}),t.dirty()):Wa.assertNever(a);var i,r;return{status:t.value,value:e.data}}_regex(e,t,n){return this.refinement((t=>e.test(t)),{validation:t,code:Ya.invalid_string,...po.errToObj(n)})}_addCheck(e){return new Do({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...po.errToObj(e)})}url(e){return this._addCheck({kind:"url",...po.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...po.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...po.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...po.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...po.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...po.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...po.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...po.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...po.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...po.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...po.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...po.errToObj(e)})}datetime(e){return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===e?.precision?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...po.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===e?.precision?null:e?.precision,...po.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...po.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...po.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...po.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...po.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...po.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...po.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...po.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...po.errToObj(t)})}nonempty(e){return this.min(1,po.errToObj(e))}trim(){return new Do({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Do({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Do({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e=>"datetime"===e.kind))}get isDate(){return!!this._def.checks.find((e=>"date"===e.kind))}get isTime(){return!!this._def.checks.find((e=>"time"===e.kind))}get isDuration(){return!!this._def.checks.find((e=>"duration"===e.kind))}get isEmail(){return!!this._def.checks.find((e=>"email"===e.kind))}get isURL(){return!!this._def.checks.find((e=>"url"===e.kind))}get isEmoji(){return!!this._def.checks.find((e=>"emoji"===e.kind))}get isUUID(){return!!this._def.checks.find((e=>"uuid"===e.kind))}get isNANOID(){return!!this._def.checks.find((e=>"nanoid"===e.kind))}get isCUID(){return!!this._def.checks.find((e=>"cuid"===e.kind))}get isCUID2(){return!!this._def.checks.find((e=>"cuid2"===e.kind))}get isULID(){return!!this._def.checks.find((e=>"ulid"===e.kind))}get isIP(){return!!this._def.checks.find((e=>"ip"===e.kind))}get isCIDR(){return!!this._def.checks.find((e=>"cidr"===e.kind))}get isBase64(){return!!this._def.checks.find((e=>"base64"===e.kind))}get isBase64url(){return!!this._def.checks.find((e=>"base64url"===e.kind))}get minLength(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}function Go(e,t){const n=(e.toString().split(".")[1]||"").length,i=(t.toString().split(".")[1]||"").length,r=n>i?n:i;return Number.parseInt(e.toFixed(r).replace(".",""))%Number.parseInt(t.toFixed(r).replace(".",""))/10**r}Do.create=e=>new Do({checks:[],typeName:Ss.ZodString,coerce:e?.coerce??!1,...vo(e)});class zo extends bo{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){this._def.coerce&&(e.data=Number(e.data));if(this._getType(e)!==qa.number){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.number,received:t.parsedType}),io}let t;const n=new no;for(const i of this._def.checks)if("int"===i.kind)Wa.isInteger(e.data)||(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.invalid_type,expected:"integer",received:"float",message:i.message}),n.dirty());else if("min"===i.kind){(i.inclusive?e.data<i.value:e.data<=i.value)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty())}else if("max"===i.kind){(i.inclusive?e.data>i.value:e.data>=i.value)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty())}else"multipleOf"===i.kind?0!==Go(e.data,i.value)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):"finite"===i.kind?Number.isFinite(e.data)||(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.not_finite,message:i.message}),n.dirty()):Wa.assertNever(i);return{status:n.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,po.toString(t))}gt(e,t){return this.setLimit("min",e,!1,po.toString(t))}lte(e,t){return this.setLimit("max",e,!0,po.toString(t))}lt(e,t){return this.setLimit("max",e,!1,po.toString(t))}setLimit(e,t,n,i){return new zo({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:po.toString(i)}]})}_addCheck(e){return new zo({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:po.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:po.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:po.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:po.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:po.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:po.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:po.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:po.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:po.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find((e=>"int"===e.kind||"multipleOf"===e.kind&&Wa.isInteger(e.value)))}get isFinite(){let e=null,t=null;for(const n of this._def.checks){if("finite"===n.kind||"int"===n.kind||"multipleOf"===n.kind)return!0;"min"===n.kind?(null===t||n.value>t)&&(t=n.value):"max"===n.kind&&(null===e||n.value<e)&&(e=n.value)}return Number.isFinite(t)&&Number.isFinite(e)}}zo.create=e=>new zo({checks:[],typeName:Ss.ZodNumber,coerce:e?.coerce||!1,...vo(e)});class Vo extends bo{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==qa.bigint)return this._getInvalidInput(e);let t;const n=new no;for(const i of this._def.checks)if("min"===i.kind){(i.inclusive?e.data<i.value:e.data<=i.value)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty())}else if("max"===i.kind){(i.inclusive?e.data>i.value:e.data>=i.value)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty())}else"multipleOf"===i.kind?e.data%i.value!==BigInt(0)&&(t=this._getOrReturnCtx(e,t),to(t,{code:Ya.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):Wa.assertNever(i);return{status:n.value,value:e.data}}_getInvalidInput(e){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.bigint,received:t.parsedType}),io}gte(e,t){return this.setLimit("min",e,!0,po.toString(t))}gt(e,t){return this.setLimit("min",e,!1,po.toString(t))}lte(e,t){return this.setLimit("max",e,!0,po.toString(t))}lt(e,t){return this.setLimit("max",e,!1,po.toString(t))}setLimit(e,t,n,i){return new Vo({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:n,message:po.toString(i)}]})}_addCheck(e){return new Vo({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:po.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:po.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:po.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:po.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:po.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}Vo.create=e=>new Vo({checks:[],typeName:Ss.ZodBigInt,coerce:e?.coerce??!1,...vo(e)});class Zo extends bo{_parse(e){this._def.coerce&&(e.data=Boolean(e.data));if(this._getType(e)!==qa.boolean){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.boolean,received:t.parsedType}),io}return ao(e.data)}}Zo.create=e=>new Zo({typeName:Ss.ZodBoolean,coerce:e?.coerce||!1,...vo(e)});class $o extends bo{_parse(e){this._def.coerce&&(e.data=new Date(e.data));if(this._getType(e)!==qa.date){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.date,received:t.parsedType}),io}if(Number.isNaN(e.data.getTime())){return to(this._getOrReturnCtx(e),{code:Ya.invalid_date}),io}const t=new no;let n;for(const i of this._def.checks)"min"===i.kind?e.data.getTime()<i.value&&(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),t.dirty()):"max"===i.kind?e.data.getTime()>i.value&&(n=this._getOrReturnCtx(e,n),to(n,{code:Ya.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),t.dirty()):Wa.assertNever(i);return{status:t.value,value:new Date(e.data.getTime())}}_addCheck(e){return new $o({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:po.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:po.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}$o.create=e=>new $o({checks:[],coerce:e?.coerce||!1,typeName:Ss.ZodDate,...vo(e)});class Wo extends bo{_parse(e){if(this._getType(e)!==qa.symbol){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.symbol,received:t.parsedType}),io}return ao(e.data)}}Wo.create=e=>new Wo({typeName:Ss.ZodSymbol,...vo(e)});class Ko extends bo{_parse(e){if(this._getType(e)!==qa.undefined){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.undefined,received:t.parsedType}),io}return ao(e.data)}}Ko.create=e=>new Ko({typeName:Ss.ZodUndefined,...vo(e)});class qo extends bo{_parse(e){if(this._getType(e)!==qa.null){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.null,received:t.parsedType}),io}return ao(e.data)}}qo.create=e=>new qo({typeName:Ss.ZodNull,...vo(e)});class Xo extends bo{constructor(){super(...arguments),this._any=!0}_parse(e){return ao(e.data)}}Xo.create=e=>new Xo({typeName:Ss.ZodAny,...vo(e)});class Yo extends bo{constructor(){super(...arguments),this._unknown=!0}_parse(e){return ao(e.data)}}Yo.create=e=>new Yo({typeName:Ss.ZodUnknown,...vo(e)});class Jo extends bo{_parse(e){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.never,received:t.parsedType}),io}}Jo.create=e=>new Jo({typeName:Ss.ZodNever,...vo(e)});class Qo extends bo{_parse(e){if(this._getType(e)!==qa.undefined){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.void,received:t.parsedType}),io}return ao(e.data)}}Qo.create=e=>new Qo({typeName:Ss.ZodVoid,...vo(e)});class es extends bo{_parse(e){const{ctx:t,status:n}=this._processInputParams(e),i=this._def;if(t.parsedType!==qa.array)return to(t,{code:Ya.invalid_type,expected:qa.array,received:t.parsedType}),io;if(null!==i.exactLength){const e=t.data.length>i.exactLength.value,r=t.data.length<i.exactLength.value;(e||r)&&(to(t,{code:e?Ya.too_big:Ya.too_small,minimum:r?i.exactLength.value:void 0,maximum:e?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),n.dirty())}if(null!==i.minLength&&t.data.length<i.minLength.value&&(to(t,{code:Ya.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),n.dirty()),null!==i.maxLength&&t.data.length>i.maxLength.value&&(to(t,{code:Ya.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),n.dirty()),t.common.async)return Promise.all([...t.data].map(((e,n)=>i.type._parseAsync(new mo(t,e,t.path,n))))).then((e=>no.mergeArray(n,e)));const r=[...t.data].map(((e,n)=>i.type._parseSync(new mo(t,e,t.path,n))));return no.mergeArray(n,r)}get element(){return this._def.type}min(e,t){return new es({...this._def,minLength:{value:e,message:po.toString(t)}})}max(e,t){return new es({...this._def,maxLength:{value:e,message:po.toString(t)}})}length(e,t){return new es({...this._def,exactLength:{value:e,message:po.toString(t)}})}nonempty(e){return this.min(1,e)}}function ts(e){if(e instanceof ns){const t={};for(const n in e.shape){const i=e.shape[n];t[n]=vs.create(ts(i))}return new ns({...e._def,shape:()=>t})}return e instanceof es?new es({...e._def,type:ts(e.element)}):e instanceof vs?vs.create(ts(e.unwrap())):e instanceof bs?bs.create(ts(e.unwrap())):e instanceof cs?cs.create(e.items.map((e=>ts(e)))):e}es.create=(e,t)=>new es({type:e,minLength:null,maxLength:null,exactLength:null,typeName:Ss.ZodArray,...vo(t)});class ns extends bo{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;const e=this._def.shape(),t=Wa.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==qa.object){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.object,received:t.parsedType}),io}const{status:t,ctx:n}=this._processInputParams(e),{shape:i,keys:r}=this._getCached(),a=[];if(!(this._def.catchall instanceof Jo&&"strip"===this._def.unknownKeys))for(const e in n.data)r.includes(e)||a.push(e);const o=[];for(const e of r){const t=i[e],r=n.data[e];o.push({key:{status:"valid",value:e},value:t._parse(new mo(n,r,n.path,e)),alwaysSet:e in n.data})}if(this._def.catchall instanceof Jo){const e=this._def.unknownKeys;if("passthrough"===e)for(const e of a)o.push({key:{status:"valid",value:e},value:{status:"valid",value:n.data[e]}});else if("strict"===e)a.length>0&&(to(n,{code:Ya.unrecognized_keys,keys:a}),t.dirty());else if("strip"!==e)throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const e=this._def.catchall;for(const t of a){const i=n.data[t];o.push({key:{status:"valid",value:t},value:e._parse(new mo(n,i,n.path,t)),alwaysSet:t in n.data})}}return n.common.async?Promise.resolve().then((async()=>{const e=[];for(const t of o){const n=await t.key,i=await t.value;e.push({key:n,value:i,alwaysSet:t.alwaysSet})}return e})).then((e=>no.mergeObjectSync(t,e))):no.mergeObjectSync(t,o)}get shape(){return this._def.shape()}strict(e){return po.errToObj,new ns({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,n)=>{const i=this._def.errorMap?.(t,n).message??n.defaultError;return"unrecognized_keys"===t.code?{message:po.errToObj(e).message??i}:{message:i}}}:{}})}strip(){return new ns({...this._def,unknownKeys:"strip"})}passthrough(){return new ns({...this._def,unknownKeys:"passthrough"})}extend(e){return new ns({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new ns({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:Ss.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new ns({...this._def,catchall:e})}pick(e){const t={};for(const n of Wa.objectKeys(e))e[n]&&this.shape[n]&&(t[n]=this.shape[n]);return new ns({...this._def,shape:()=>t})}omit(e){const t={};for(const n of Wa.objectKeys(this.shape))e[n]||(t[n]=this.shape[n]);return new ns({...this._def,shape:()=>t})}deepPartial(){return ts(this)}partial(e){const t={};for(const n of Wa.objectKeys(this.shape)){const i=this.shape[n];e&&!e[n]?t[n]=i:t[n]=i.optional()}return new ns({...this._def,shape:()=>t})}required(e){const t={};for(const n of Wa.objectKeys(this.shape))if(e&&!e[n])t[n]=this.shape[n];else{let e=this.shape[n];for(;e instanceof vs;)e=e._def.innerType;t[n]=e}return new ns({...this._def,shape:()=>t})}keyof(){return _s(Wa.objectKeys(this.shape))}}ns.create=(e,t)=>new ns({shape:()=>e,unknownKeys:"strip",catchall:Jo.create(),typeName:Ss.ZodObject,...vo(t)}),ns.strictCreate=(e,t)=>new ns({shape:()=>e,unknownKeys:"strict",catchall:Jo.create(),typeName:Ss.ZodObject,...vo(t)}),ns.lazycreate=(e,t)=>new ns({shape:e,unknownKeys:"strip",catchall:Jo.create(),typeName:Ss.ZodObject,...vo(t)});class is extends bo{_parse(e){const{ctx:t}=this._processInputParams(e),n=this._def.options;if(t.common.async)return Promise.all(n.map((async e=>{const n={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:n}),ctx:n}}))).then((function(e){for(const t of e)if("valid"===t.result.status)return t.result;for(const n of e)if("dirty"===n.result.status)return t.common.issues.push(...n.ctx.common.issues),n.result;const n=e.map((e=>new Ja(e.ctx.common.issues)));return to(t,{code:Ya.invalid_union,unionErrors:n}),io}));{let e;const i=[];for(const r of n){const n={...t,common:{...t.common,issues:[]},parent:null},a=r._parseSync({data:t.data,path:t.path,parent:n});if("valid"===a.status)return a;"dirty"!==a.status||e||(e={result:a,ctx:n}),n.common.issues.length&&i.push(n.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;const r=i.map((e=>new Ja(e)));return to(t,{code:Ya.invalid_union,unionErrors:r}),io}}get options(){return this._def.options}}is.create=(e,t)=>new is({options:e,typeName:Ss.ZodUnion,...vo(t)});const rs=e=>e instanceof ds?rs(e.schema):e instanceof gs?rs(e.innerType()):e instanceof us?[e.value]:e instanceof hs?e.options:e instanceof fs?Wa.objectValues(e.enum):e instanceof ws?rs(e._def.innerType):e instanceof Ko?[void 0]:e instanceof qo?[null]:e instanceof vs?[void 0,...rs(e.unwrap())]:e instanceof bs?[null,...rs(e.unwrap())]:e instanceof ks||e instanceof Ns?rs(e.unwrap()):e instanceof ys?rs(e._def.innerType):[];class as extends bo{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==qa.object)return to(t,{code:Ya.invalid_type,expected:qa.object,received:t.parsedType}),io;const n=this.discriminator,i=t.data[n],r=this.optionsMap.get(i);return r?t.common.async?r._parseAsync({data:t.data,path:t.path,parent:t}):r._parseSync({data:t.data,path:t.path,parent:t}):(to(t,{code:Ya.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[n]}),io)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,n){const i=new Map;for(const n of t){const t=rs(n.shape[e]);if(!t.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const r of t){if(i.has(r))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(r)}`);i.set(r,n)}}return new as({typeName:Ss.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:i,...vo(n)})}}function os(e,t){const n=Xa(e),i=Xa(t);if(e===t)return{valid:!0,data:e};if(n===qa.object&&i===qa.object){const n=Wa.objectKeys(t),i=Wa.objectKeys(e).filter((e=>-1!==n.indexOf(e))),r={...e,...t};for(const n of i){const i=os(e[n],t[n]);if(!i.valid)return{valid:!1};r[n]=i.data}return{valid:!0,data:r}}if(n===qa.array&&i===qa.array){if(e.length!==t.length)return{valid:!1};const n=[];for(let i=0;i<e.length;i++){const r=os(e[i],t[i]);if(!r.valid)return{valid:!1};n.push(r.data)}return{valid:!0,data:n}}return n===qa.date&&i===qa.date&&+e===+t?{valid:!0,data:e}:{valid:!1}}class ss extends bo{_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=(e,i)=>{if(oo(e)||oo(i))return io;const r=os(e.value,i.value);return r.valid?((so(e)||so(i))&&t.dirty(),{status:t.value,value:r.data}):(to(n,{code:Ya.invalid_intersection_types}),io)};return n.common.async?Promise.all([this._def.left._parseAsync({data:n.data,path:n.path,parent:n}),this._def.right._parseAsync({data:n.data,path:n.path,parent:n})]).then((([e,t])=>i(e,t))):i(this._def.left._parseSync({data:n.data,path:n.path,parent:n}),this._def.right._parseSync({data:n.data,path:n.path,parent:n}))}}ss.create=(e,t,n)=>new ss({left:e,right:t,typeName:Ss.ZodIntersection,...vo(n)});class cs extends bo{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==qa.array)return to(n,{code:Ya.invalid_type,expected:qa.array,received:n.parsedType}),io;if(n.data.length<this._def.items.length)return to(n,{code:Ya.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),io;!this._def.rest&&n.data.length>this._def.items.length&&(to(n,{code:Ya.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const i=[...n.data].map(((e,t)=>{const i=this._def.items[t]||this._def.rest;return i?i._parse(new mo(n,e,n.path,t)):null})).filter((e=>!!e));return n.common.async?Promise.all(i).then((e=>no.mergeArray(t,e))):no.mergeArray(t,i)}get items(){return this._def.items}rest(e){return new cs({...this._def,rest:e})}}cs.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new cs({items:e,typeName:Ss.ZodTuple,rest:null,...vo(t)})};class ls extends bo{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==qa.map)return to(n,{code:Ya.invalid_type,expected:qa.map,received:n.parsedType}),io;const i=this._def.keyType,r=this._def.valueType,a=[...n.data.entries()].map((([e,t],a)=>({key:i._parse(new mo(n,e,n.path,[a,"key"])),value:r._parse(new mo(n,t,n.path,[a,"value"]))})));if(n.common.async){const e=new Map;return Promise.resolve().then((async()=>{for(const n of a){const i=await n.key,r=await n.value;if("aborted"===i.status||"aborted"===r.status)return io;"dirty"!==i.status&&"dirty"!==r.status||t.dirty(),e.set(i.value,r.value)}return{status:t.value,value:e}}))}{const e=new Map;for(const n of a){const i=n.key,r=n.value;if("aborted"===i.status||"aborted"===r.status)return io;"dirty"!==i.status&&"dirty"!==r.status||t.dirty(),e.set(i.value,r.value)}return{status:t.value,value:e}}}}ls.create=(e,t,n)=>new ls({valueType:t,keyType:e,typeName:Ss.ZodMap,...vo(n)});class ps extends bo{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.parsedType!==qa.set)return to(n,{code:Ya.invalid_type,expected:qa.set,received:n.parsedType}),io;const i=this._def;null!==i.minSize&&n.data.size<i.minSize.value&&(to(n,{code:Ya.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),t.dirty()),null!==i.maxSize&&n.data.size>i.maxSize.value&&(to(n,{code:Ya.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),t.dirty());const r=this._def.valueType;function a(e){const n=new Set;for(const i of e){if("aborted"===i.status)return io;"dirty"===i.status&&t.dirty(),n.add(i.value)}return{status:t.value,value:n}}const o=[...n.data.values()].map(((e,t)=>r._parse(new mo(n,e,n.path,t))));return n.common.async?Promise.all(o).then((e=>a(e))):a(o)}min(e,t){return new ps({...this._def,minSize:{value:e,message:po.toString(t)}})}max(e,t){return new ps({...this._def,maxSize:{value:e,message:po.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}ps.create=(e,t)=>new ps({valueType:e,minSize:null,maxSize:null,typeName:Ss.ZodSet,...vo(t)});class ds extends bo{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}ds.create=(e,t)=>new ds({getter:e,typeName:Ss.ZodLazy,...vo(t)});class us extends bo{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return to(t,{received:t.data,code:Ya.invalid_literal,expected:this._def.value}),io}return{status:"valid",value:e.data}}get value(){return this._def.value}}function _s(e,t){return new hs({values:e,typeName:Ss.ZodEnum,...vo(t)})}us.create=(e,t)=>new us({value:e,typeName:Ss.ZodLiteral,...vo(t)});class hs extends bo{constructor(){super(...arguments),uo.set(this,void 0)}_parse(e){if("string"!=typeof e.data){const t=this._getOrReturnCtx(e),n=this._def.values;return to(t,{expected:Wa.joinValues(n),received:t.parsedType,code:Ya.invalid_type}),io}if(ho(this,uo,"f")||fo(this,uo,new Set(this._def.values),"f"),!ho(this,uo,"f").has(e.data)){const t=this._getOrReturnCtx(e),n=this._def.values;return to(t,{received:t.data,code:Ya.invalid_enum_value,options:n}),io}return ao(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return hs.create(e,{...this._def,...t})}exclude(e,t=this._def){return hs.create(this.options.filter((t=>!e.includes(t))),{...this._def,...t})}}uo=new WeakMap,hs.create=_s;class fs extends bo{constructor(){super(...arguments),_o.set(this,void 0)}_parse(e){const t=Wa.getValidEnumValues(this._def.values),n=this._getOrReturnCtx(e);if(n.parsedType!==qa.string&&n.parsedType!==qa.number){const e=Wa.objectValues(t);return to(n,{expected:Wa.joinValues(e),received:n.parsedType,code:Ya.invalid_type}),io}if(ho(this,_o,"f")||fo(this,_o,new Set(Wa.getValidEnumValues(this._def.values)),"f"),!ho(this,_o,"f").has(e.data)){const e=Wa.objectValues(t);return to(n,{received:n.data,code:Ya.invalid_enum_value,options:e}),io}return ao(e.data)}get enum(){return this._def.values}}_o=new WeakMap,fs.create=(e,t)=>new fs({values:e,typeName:Ss.ZodNativeEnum,...vo(t)});class ms extends bo{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==qa.promise&&!1===t.common.async)return to(t,{code:Ya.invalid_type,expected:qa.promise,received:t.parsedType}),io;const n=t.parsedType===qa.promise?t.data:Promise.resolve(t.data);return ao(n.then((e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap}))))}}ms.create=(e,t)=>new ms({type:e,typeName:Ss.ZodPromise,...vo(t)});class gs extends bo{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===Ss.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:n}=this._processInputParams(e),i=this._def.effect||null,r={addIssue:e=>{to(n,e),e.fatal?t.abort():t.dirty()},get path(){return n.path}};if(r.addIssue=r.addIssue.bind(r),"preprocess"===i.type){const e=i.transform(n.data,r);if(n.common.async)return Promise.resolve(e).then((async e=>{if("aborted"===t.value)return io;const i=await this._def.schema._parseAsync({data:e,path:n.path,parent:n});return"aborted"===i.status?io:"dirty"===i.status||"dirty"===t.value?ro(i.value):i}));{if("aborted"===t.value)return io;const i=this._def.schema._parseSync({data:e,path:n.path,parent:n});return"aborted"===i.status?io:"dirty"===i.status||"dirty"===t.value?ro(i.value):i}}if("refinement"===i.type){const e=e=>{const t=i.refinement(e,r);if(n.common.async)return Promise.resolve(t);if(t instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1===n.common.async){const i=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});return"aborted"===i.status?io:("dirty"===i.status&&t.dirty(),e(i.value),{status:t.value,value:i.value})}return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then((n=>"aborted"===n.status?io:("dirty"===n.status&&t.dirty(),e(n.value).then((()=>({status:t.value,value:n.value}))))))}if("transform"===i.type){if(!1===n.common.async){const e=this._def.schema._parseSync({data:n.data,path:n.path,parent:n});if(!co(e))return e;const a=i.transform(e.value,r);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:a}}return this._def.schema._parseAsync({data:n.data,path:n.path,parent:n}).then((e=>co(e)?Promise.resolve(i.transform(e.value,r)).then((e=>({status:t.value,value:e}))):e))}Wa.assertNever(i)}}gs.create=(e,t,n)=>new gs({schema:e,typeName:Ss.ZodEffects,effect:t,...vo(n)}),gs.createWithPreprocess=(e,t,n)=>new gs({schema:t,effect:{type:"preprocess",transform:e},typeName:Ss.ZodEffects,...vo(n)});class vs extends bo{_parse(e){return this._getType(e)===qa.undefined?ao(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}vs.create=(e,t)=>new vs({innerType:e,typeName:Ss.ZodOptional,...vo(t)});class bs extends bo{_parse(e){return this._getType(e)===qa.null?ao(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}bs.create=(e,t)=>new bs({innerType:e,typeName:Ss.ZodNullable,...vo(t)});class ws extends bo{_parse(e){const{ctx:t}=this._processInputParams(e);let n=t.data;return t.parsedType===qa.undefined&&(n=this._def.defaultValue()),this._def.innerType._parse({data:n,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}ws.create=(e,t)=>new ws({innerType:e,typeName:Ss.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...vo(t)});class ys extends bo{_parse(e){const{ctx:t}=this._processInputParams(e),n={...t,common:{...t.common,issues:[]}},i=this._def.innerType._parse({data:n.data,path:n.path,parent:{...n}});return lo(i)?i.then((e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new Ja(n.common.issues)},input:n.data})}))):{status:"valid",value:"valid"===i.status?i.value:this._def.catchValue({get error(){return new Ja(n.common.issues)},input:n.data})}}removeCatch(){return this._def.innerType}}ys.create=(e,t)=>new ys({innerType:e,typeName:Ss.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...vo(t)});class xs extends bo{_parse(e){if(this._getType(e)!==qa.nan){const t=this._getOrReturnCtx(e);return to(t,{code:Ya.invalid_type,expected:qa.nan,received:t.parsedType}),io}return{status:"valid",value:e.data}}}xs.create=e=>new xs({typeName:Ss.ZodNaN,...vo(e)});class ks extends bo{_parse(e){const{ctx:t}=this._processInputParams(e),n=t.data;return this._def.type._parse({data:n,path:t.path,parent:t})}unwrap(){return this._def.type}}class Es extends bo{_parse(e){const{status:t,ctx:n}=this._processInputParams(e);if(n.common.async){return(async()=>{const e=await this._def.in._parseAsync({data:n.data,path:n.path,parent:n});return"aborted"===e.status?io:"dirty"===e.status?(t.dirty(),ro(e.value)):this._def.out._parseAsync({data:e.value,path:n.path,parent:n})})()}{const e=this._def.in._parseSync({data:n.data,path:n.path,parent:n});return"aborted"===e.status?io:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:n.path,parent:n})}}static create(e,t){return new Es({in:e,out:t,typeName:Ss.ZodPipeline})}}class Ns extends bo{_parse(e){const t=this._def.innerType._parse(e),n=e=>(co(e)&&(e.value=Object.freeze(e.value)),e);return lo(t)?t.then((e=>n(e))):n(t)}unwrap(){return this._def.innerType}}var Ss;Ns.create=(e,t)=>new Ns({innerType:e,typeName:Ss.ZodReadonly,...vo(t)}),function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"}(Ss||(Ss={}));const Ts=Do.create,As=zo.create,Ms=Zo.create;Jo.create;const Cs=es.create,Ps=ns.create;is.create;const Ls=as.create;ss.create,cs.create;const Os=us.create,Rs=hs.create;ms.create,vs.create,bs.create;const Is=Ps({title:Ts({message:"Property 'title' should be a string"}).optional(),subtitle:Ts({message:"Property 'subtitle' should be a string"}).optional(),message:Ts({message:"Property 'message' is required and should be a string"}).nonempty("Property 'message' cannot be empty"),actions:Cs(Ps({type:Ts({message:"Action property 'type' is required and should be a string"}),label:Ts({message:"Action property 'label' is required and should be a string"}),target:Ts({message:"Action property 'target' should be a string"}).optional(),camera:Ms({message:"Action property 'camera' should be a boolean"}).optional(),keyboard:Ms({message:"Action property 'keyboard' should be a boolean"}).optional()})).optional(),attachments:Cs(Ps({mimeType:Ts({message:"Attachment property 'mimeType' is required and should be a string"}),uri:Ts({message:"Attachment property 'uri' is required and should be a string"}).url("Attachment property 'uri' should be a valid URL")})).optional()}),Us=Ps({type:Os("re.notifica.notification.None")}).merge(Is),Bs=Ps({type:Os("re.notifica.notification.URLResolver"),content:Cs(Ps({type:Os("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:Ts({message:"Content object data is required and should be a string"})}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Hs=Ps({type:Os("re.notifica.notification.Alert")}).merge(Is),js=Ps({type:Os("re.notifica.notification.Image"),content:Cs(Ps({type:Rs(["re.notifica.content.PNG","re.notifica.content.JPEG","re.notifica.content.GIF"],{message:"Content objects should be of type 're.notifica.content.PNG', 're.notifica.content.JPEG' or 're.notifica.content.GIF'"}),data:Ts({message:"Content objects data should be strings"}).url("Content objects data should be valid URLs")}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Fs=Ps({type:Os("re.notifica.notification.InAppBrowser"),content:Cs(Ps({type:Os("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:Ts({message:"Content object data is required and should be a string"}).url("Content object data should be a valid URL")}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Ds=Ps({type:Os("re.notifica.notification.Map"),content:Cs(Ps({type:Os("re.notifica.content.Marker",{message:"Content objects should be of type 're.notifica.content.Marker'"}),data:Ps({title:Ts({message:"Content object data property 'title' is required and should be a string"}),description:Ts({message:"Content object data property 'description' is required should be a string"}),latitude:As({message:"Content object data property 'latitude' is required and should be a number"}).min(-90,"Content object data property 'latitude' should be a minimum of -90").max(90,"Content object data property 'latitude' should be a maximum of 90"),longitude:As({message:"Content object data property 'longitude' is required and should be a number"}).min(-180,"Content object data property 'longitude' must be at least -180").max(180,"Content object data property 'longitude' must be at most 180")})}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Gs=Ps({type:Os("re.notifica.notification.Passbook"),content:Cs(Ps({type:Os("re.notifica.content.PKPass",{message:"Content object should be of type 're.notifica.content.PKPass'"}),data:Ts({message:"Content object data is required and should be a string"}).url("Content object data should be a valid URL")}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),zs=Ps({type:Os("re.notifica.notification.Rate")}).merge(Is),Vs=Ps({type:Os("re.notifica.notification.Store"),content:Cs(Ls("type",[Ps({type:Os("re.notifica.content.AppStore"),data:Ps({identifier:Ts({message:"Content object data property 'identifier' is mandatory and should be a string"}),campaignToken:Ts({message:"Content object data property 'campaignToken' should be a string"}).optional(),affiliateToken:Ts({message:"Content object data property 'affiliateToken' should be a string"}).optional(),providerToken:Ts({message:"Content object data property 'providerToken' should be a string"}).optional()},{message:"AppStore content object data is required and must be an object with 'identifier' (mandatory), 'campaignToken', 'affiliateToken', or 'providerToken'"})}),Ps({type:Rs(["re.notifica.content.GooglePlayDetails","re.notifica.content.GooglePlayDeveloper","re.notifica.content.GooglePlayCollection","re.notifica.content.GooglePlaySearch","re.notifica.content.AppGalleryDetails","re.notifica.content.AppGallerySearch"]),data:Ts({message:"GooglePlay and AppGallery content object data is required and must be a string"}).nonempty("GooglePlay and AppGallery content object data cannot be empty")})]),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Zs=Ls("type",[Hs,js,Fs,Ds,Us,Gs,zs,Vs,Bs,Ps({type:Os("re.notifica.notification.URL"),content:Cs(Ps({type:Os("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:Ts({message:"Content object data is required and should be a string"}).url("Content object data should be a valid URL")}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Ps({type:Os("re.notifica.notification.URLScheme"),content:Cs(Ps({type:Os("re.notifica.content.URL",{message:"Content object should be of type 're.notifica.content.URL'"}),data:Ts({message:"Content object data is required and should be a string"})}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is),Ps({type:Os("re.notifica.notification.Video"),content:Cs(Ps({type:Ts({message:"Content object type is required and should be a string"}),data:Ts({message:"Content object data is required and should be a string"}).nonempty("Content object data cannot be empty")}),{message:"The notification must be content-rich. Property 'content' is required"}).superRefine(((e,t)=>{e.forEach(((e,n)=>{if(["re.notifica.content.YouTube","re.notifica.content.Vimeo","re.notifica.content.HTML5Video"].includes(e.type)||t.addIssue({code:Ya.custom,message:"Content object should be of type 're.notifica.content.YouTube', 're.notifica.content.Vimeo' or 're.notifica.content.HTML5Video'",path:["content",n,"type"]}),"re.notifica.content.HTML5Video"===e.type)try{new URL(e.data)}catch(e){t.addIssue({code:Ya.custom,message:"For a HTML5Video, content object data should be a valid URL",path:["content",n,"data"]})}}))}))}).merge(Is),Ps({type:Os("re.notifica.notification.WebView"),content:Cs(Ps({type:Os("re.notifica.content.HTML",{message:"Content object should be of type 're.notifica.content.HTML'"}),data:Ts({message:"Content data is required and should be a string containing the HTML markup"})}),{message:"The notification must be content-rich. Property 'content' is required"})}).merge(Is)]);function $s({errors:e}){const n=Jt();return o((function(){!function(e){const t=e.find((e=>"invalid_union_discriminator"===e.code&&e.path.includes("type")&&!e.path.includes("content")));if(t){const e=Zs.options.map((e=>e.shape.type.value));console.error(`Notification error:\n\nInvalid notification type. Expected one of: ${e.join(", ")}\n`)}else{const t=e.map((e=>"invalid_union_discriminator"===e.code&&e.path.includes("type")&&e.path.includes("content")?`Invalid content type. Expected one of: ${e.options.join(", ")}\n`:e.message));console.error("Notification errors:\n\n"+t.join("\n"))}}(e)}),[e]),t(Hn,{message:n.formatMessage({id:"preview.error.invalidNotification",defaultMessage:bn["preview.error.invalidNotification"]}),showConsoleWarning:!0})}function Ws({notification:n,applicationId:i,showControls:r=!0,variant:a="android-lockscreen",serviceKey:o,googleMapsAPIKey:c,locale:l="en-US",translations:p}){const d=In({locale:l,customTranslations:p,type:"push"}),u=s((()=>Zs.safeParse(n)),[n]);return e("div",{className:"notificare",children:["success"===d.status&&t(cn,{locale:d.data.locale,defaultLocale:"en-US",messages:d.data.translations,children:t(Fn,{serviceKey:o,googleMapsAPIKey:c,children:u.success?t($a,{notification:u.data,applicationId:i,showControls:r,variant:a}):t($s,{errors:u.error.errors})})}),"error"===d.status&&t(cn,{locale:"en-US",messages:bn,children:t(Hn,{message:d.error.message})})]})}ln("");function Ks({inAppMessage:n}){return t("div",{className:"notificare__in-app-messaging__banner__wrapper","data-testid":"in-app-messaging-banner-preview-wrapper",children:e("div",{className:"notificare__in-app-messaging__banner__window",children:[n.image&&t("img",{alt:"App icon",className:"notificare__in-app-messaging__banner__image",src:n.image,"data-testid":"in-app-messaging-banner-preview-image"}),e("div",{className:"notificare__in-app-messaging__banner__text-content",children:[t("p",{className:"notificare__in-app-messaging__banner__title","data-testid":"in-app-messaging-banner-preview-title",children:n.title}),t("p",{className:"notificare__in-app-messaging__banner__message","data-testid":"in-app-messaging-banner-preview-message",children:n.message})]})]})})}ln(".notificare .notificare__in-app-messaging__banner__wrapper {\n width: 100%;\n justify-content: center;\n margin-top: 20px;\n display: flex;\n}\n\n.notificare .notificare__in-app-messaging__banner__window {\n width: 320px;\n border-radius: 5px;\n display: flex;\n background-color: #fff;\n padding: 16px;\n column-gap: 12px;\n}\n\n.notificare .notificare__in-app-messaging__banner__image {\n width: 58px;\n height: 58px;\n object-fit: cover;\n}\n\n.notificare .notificare__in-app-messaging__banner__text-content {\n width: 100%;\n overflow: hidden;\n}\n\n.notificare .notificare__in-app-messaging__banner__title {\n font-size: 15px;\n font-weight: 600;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n margin-bottom: 4px;\n line-height: 18px;\n}\n\n.notificare .notificare__in-app-messaging__banner__message {\n font-size: 13px;\n width: 100%;\n word-break: break-word;\n line-height: 18px;\n}");function qs({inAppMessage:n}){return t("div",{className:"notificare__in-app-messaging__card__wrapper","data-testid":"in-app-messaging-card-preview-wrapper",children:e("div",{className:"notificare__in-app-messaging__card__window",children:[e("div",{className:"notificare__in-app-messaging__card__header",children:[t("button",{className:"notificare__in-app-messaging__card__close-button",children:t(da,{className:"notificare__in-app-messaging__card__close-button-icon"})}),t("img",{alt:"App icon",className:"notificare__in-app-messaging__card__image",src:n.image,"data-testid":"in-app-messaging-card-preview-image"})]}),e("div",{className:"notificare__in-app-messaging__card__text-content",children:[t("p",{className:"notificare__in-app-messaging__card__title","data-testid":"in-app-messaging-card-preview-title",children:n.title}),t("p",{className:"notificare__in-app-messaging__card__message","data-testid":"in-app-messaging-card-preview-message",children:n.message})]}),e("div",{className:"notificare__in-app-messaging__card__actions",children:[t("button",{className:"notificare__in-app-messaging__card__action-button notificare__in-app-messaging__card__action-button--primary "+(n.primaryAction.destructive?"notificare__in-app-messaging__card__action-button--destructive":""),"data-testid":"in-app-messaging-card-preview-primary-action-label",children:n.primaryAction.label}),n.secondaryAction&&t("button",{className:"notificare__in-app-messaging__card__action-button notificare__in-app-messaging__card__action-button--secondary "+(n.secondaryAction.destructive?"notificare__in-app-messaging__card__action-button--destructive":""),"data-testid":"in-app-messaging-card-preview-secondary-action-label",children:n.secondaryAction.label})]})]})})}ln(".notificare .notificare__in-app-messaging__card__wrapper {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__in-app-messaging__card__window {\n width: 320px;\n background-color: white;\n border-radius: 5px;\n padding: 16px;\n overflow: hidden;\n row-gap: 16px;\n display: flex;\n flex-direction: column;\n position: relative;\n}\n\n.notificare .notificare__in-app-messaging__card__header {\n position: relative;\n}\n\n.notificare .notificare__in-app-messaging__card__close-button {\n position: absolute;\n right: 8px;\n top: 8px;\n align-items: center;\n cursor: pointer;\n display: flex;\n flex-shrink: 0;\n width: 30px;\n height: 30px;\n justify-content: center;\n border-radius: 16px;\n padding: 0;\n}\n\n.notificare .notificare__in-app-messaging__card__close-button-icon {\n fill: #000000de;\n height: 22px;\n width: 22px;\n}\n\n\n\n.notificare .notificare__in-app-messaging__card__image {\n aspect-ratio: 2 / 1;\n width: 100%;\n object-fit: cover;\n}\n\n\n.notificare .notificare__in-app-messaging__card__title {\n font-weight: 600;\n font-size: 15px;\n width: 100%;\n margin-bottom: 4px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n line-height: 18px;\n}\n\n.notificare .notificare__in-app-messaging__card__message {\n font-size: 13px;\n width: 100%;\n word-break: break-word;\n line-height: 18px;\n}\n\n.notificare .notificare__in-app-messaging__card__actions {\n display: flex;\n flex-direction: row-reverse;\n column-gap: 16px;\n}\n\n.notificare .notificare__in-app-messaging__card__action-button {\n padding: 8px 16px;\n font-weight: 500;\n font-size: 13px;\n border-radius: 4px;\n cursor: pointer;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n line-height: 18px;\n}\n\n.notificare .notificare__in-app-messaging__card__action-button--primary {\n background-color: #2b42f7;\n color: #fff;\n}\n\n.notificare .notificare__in-app-messaging__card__action-button--secondary {\n color: #2a41f3;\n}\n\n.notificare .notificare__in-app-messaging__card__action-button--destructive {\n background-color: #fff;\n color: #e54142;\n}");function Xs({inAppMessage:n}){return t("div",{className:"notificare__in-app-messaging__fullscreen__wrapper","data-testid":"in-app-messaging-fullscreen-preview-wrapper",children:e("div",{className:"notificare__in-app-messaging__fullscreen__window",children:[t("img",{alt:"App icon",className:"notificare__in-app-messaging__fullscreen__background-image",src:n.image,"data-testid":"in-app-messaging-fullscreen-preview-image"}),t("button",{className:"notificare__in-app-messaging__fullscreen__close-button",children:t(da,{className:"notificare__in-app-messaging__fullscreen__close-button-icon"})}),e("div",{className:"notificare__in-app-messaging__fullscreen__text-content",children:[t("div",{className:"notificare__in-app-messaging__fullscreen__title","data-testid":"in-app-messaging-fullscreen-preview-title",children:n.title}),t("div",{className:"notificare__in-app-messaging__fullscreen__message","data-testid":"in-app-messaging-fullscreen-preview-message",children:n.message})]})]})})}ln(".notificare .notificare__in-app-messaging__fullscreen__wrapper {\n width: 100%;\n height: 100%;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__window {\n width: 310px;\n height: 95%;\n border-radius: 5px;\n display: flex;\n justify-content: center;\n align-items: center;\n overflow: hidden;\n position: relative;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__background-image {\n height: 100%;\n object-fit: cover;\n width: 100%;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__close-button {\n position: absolute;\n right: 8px;\n top: 8px;\n align-items: center;\n cursor: pointer;\n display: flex;\n flex-shrink: 0;\n width: 30px;\n height: 30px;\n justify-content: center;\n border-radius: 16px;\n padding: 0;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__close-button-icon {\n fill: #000000de;\n width: 22px;\n height: 22px;\n flex-shrink: 0;\n flex-grow: 0;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__text-content {\n position: absolute;\n bottom: 0;\n padding: 32px 16px 16px;\n width: 100%;\n background: linear-gradient(rgba(255, 255, 255, 0), #fff);\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__title {\n font-weight: 600;\n font-size: 15px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n margin-bottom: 4px;\n line-height: 18px;\n}\n\n.notificare .notificare__in-app-messaging__fullscreen__message {\n font-size: 13px;\n line-height: 18px;\n}");function Ys({inAppMessage:e}){return t("div",{className:"notificare__in-app-messaging__preview",children:t(pn,{theme:"dark",children:(()=>{switch(e.type){case"re.notifica.inappmessage.Banner":return t(Ks,{inAppMessage:e});case"re.notifica.inappmessage.Card":return t(qs,{inAppMessage:e});case"re.notifica.inappmessage.Fullscreen":return t(Xs,{inAppMessage:e})}})()})})}ln(".notificare .notificare__in-app-messaging__preview {\n user-select: none;\n pointer-events: none;\n}");const Js=Ls("type",[Ps({type:Os("re.notifica.inappmessage.Banner"),title:Ts({message:"Property 'title' is required and should be a string"}).max(256,"Property 'title' cannot contain more than 256 characters").nonempty("Property 'title' cannot be empty"),message:Ts({message:"Property 'message' is required and should be a string"}).max(256,"Property 'message' cannot contain more than 256 characters").nonempty("Property 'message' cannot be empty"),image:Ts({message:"Property 'image' should be a string"}).url("Property 'image' should be a valid URL").optional()}),Ps({type:Os("re.notifica.inappmessage.Card"),title:Ts({message:"Property 'title' is required and should be a string"}).max(256,"Property 'title' cannot contain more than 256 characters").nonempty("Property 'title' cannot be empty"),message:Ts({message:"Property 'message' is required and should be a string"}).max(256,"Property 'message' cannot contain more than 256 characters").nonempty("Property 'message' cannot be empty"),image:Ts({message:"Property 'image' should be a string"}).url("Property 'image' should be a valid URL").optional(),primaryAction:Ps({label:Ts({message:"Primary action property 'label' is required and should be a string"}).max(32,"Primary action property 'label' cannot contain more than 32 characters").nonempty("Primary action property 'label' cannot be empty"),destructive:Ms({message:"Primary action property 'destructive' should be a boolean"}).optional()},{message:"A Card must contain a primary action. Property 'primaryAction' is required"}),secondaryAction:Ps({label:Ts({message:"Secondary action property 'label' is required and should be a string"}).max(32,"Secondary action property 'label' cannot contain more than 32 characters").nonempty("Secondary action property 'label' cannot be empty"),destructive:Ms({message:"Secondary action property 'destructive' should be a boolean"}).optional()}).optional()}),Ps({type:Os("re.notifica.inappmessage.Fullscreen"),title:Ts({message:"Property 'title' should be a string"}).max(256,"Property 'title' cannot contain more than 256 characters").optional(),message:Ts({message:"Property 'message' should be a string"}).max(256,"Property 'message' cannot contain more than 256 characters").optional(),image:Ts({message:"Property 'image' is required and should be a string"}).url("Property 'image' should be a valid URL")})]);function Qs({errors:e}){const n=Jt();return o((function(){!function(e){const t=e.find((e=>"invalid_union_discriminator"===e.code&&e.path.includes("type")));if(t){const e=Js.options.map((e=>e.shape.type.value));console.error(`In-app message error:\n\nInvalid type. Expected one of: ${e.join(", ")}`)}else{const t=e.map((({message:e})=>e));console.error(`In-app message errors:\n\n' + ${t.join("\n")}`)}}(e)}),[e]),t(Hn,{message:n.formatMessage({id:"preview.error.invalidInAppMessage",defaultMessage:Cn["preview.error.invalidInAppMessage"]}),showConsoleWarning:!0})}function ec({inAppMessage:n,locale:i="en-US",translations:r}){const a=In({locale:i,customTranslations:r,type:"in-app"}),o=s((()=>Js.safeParse(n)),[n]);return e("div",{className:"notificare",children:["success"===a.status&&t(cn,{locale:a.data.locale,defaultLocale:"en-US",messages:a.data.translations,children:o.success?t(Ys,{inAppMessage:o.data}):t(Qs,{errors:o.error.errors})}),"error"===a.status&&t(cn,{locale:"en-US",messages:Cn,children:t(Hn,{message:a.error.message})})]})}export{ec as NotificareInAppMessagePreview,Ws as NotificareNotificationPreview};
2
10
  //# sourceMappingURL=index.js.map