@everymatrix/cashier-session-expiration-modal 1.41.0 → 1.42.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.
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).app=t()}(this,(function(){"use strict";function e(){}const t=e=>e;function n(e){return e()}function r(){return Object.create(null)}function i(e){e.forEach(n)}function o(e){return"function"==typeof e}function
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).app=t()}(this,(function(){"use strict";function e(){}const t=e=>e;function n(e){return e()}function r(){return Object.create(null)}function i(e){e.forEach(n)}function o(e){return"function"==typeof e}function s(e,t){return e!=e?t==t:e!==t||e&&"object"==typeof e||"function"==typeof e}let a;function c(e,t){return a||(a=document.createElement("a")),a.href=t,e===a.href}function l(t,...n){if(null==t)return e;const r=t.subscribe(...n);return r.unsubscribe?()=>r.unsubscribe():r}const u="undefined"!=typeof window;let h=u?()=>window.performance.now():()=>Date.now(),p=u?e=>requestAnimationFrame(e):e;const f=new Set;function m(e){f.forEach((t=>{t.c(e)||(f.delete(t),t.f())})),0!==f.size&&p(m)}
|
|
2
2
|
/**
|
|
3
3
|
* Creates a new task that runs on each raf frame
|
|
4
4
|
* until it returns a falsy value or is aborted
|
|
5
|
-
*/function d(e,t){e.appendChild(t)}function g(e){if(!e)return document;const t=e.getRootNode?e.getRootNode():e.ownerDocument;return t&&t.host?t:e.ownerDocument}function E(e){const t=T("style");return function(e,t){d(e.head||e,t),t.sheet}(g(e),t),t.sheet}function y(e,t,n){e.insertBefore(t,n||null)}function b(e){e.parentNode&&e.parentNode.removeChild(e)}function T(e){return document.createElement(e)}function v(e){return document.createTextNode(e)}function
|
|
5
|
+
*/function d(e,t){e.appendChild(t)}function g(e){if(!e)return document;const t=e.getRootNode?e.getRootNode():e.ownerDocument;return t&&t.host?t:e.ownerDocument}function E(e){const t=T("style");return function(e,t){d(e.head||e,t),t.sheet}(g(e),t),t.sheet}function y(e,t,n){e.insertBefore(t,n||null)}function b(e){e.parentNode&&e.parentNode.removeChild(e)}function T(e){return document.createElement(e)}function v(e){return document.createTextNode(e)}function w(){return v(" ")}function S(e,t,n,r){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}function A(e,t,n){null==n?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function H(e,t){t=""+t,e.data!==t&&(e.data=t)}
|
|
6
6
|
// unfortunately this can't be a constant as that wouldn't be tree-shakeable
|
|
7
7
|
// so we cache the result instead
|
|
8
|
-
let N;function
|
|
8
|
+
let N;function O(){if(void 0===N){N=!1;try{"undefined"!=typeof window&&window.parent&&window.parent.document}catch(e){N=!0}}return N}function C(e){const t={};for(const n of e)t[n.name]=n.value;return t}
|
|
9
9
|
// we need to store the information for multiple documents because a Svelte application could also contain iframes
|
|
10
10
|
// https://github.com/sveltejs/svelte/issues/3624
|
|
11
|
-
const
|
|
11
|
+
const B=new Map;let P,R=0;
|
|
12
12
|
// https://github.com/darkskyapp/string-hash/blob/master/index.js
|
|
13
|
-
function
|
|
13
|
+
function L(e,t,n,r,i,o,s,a=0){const c=16.666/r;let l="{\n";for(let e=0;e<=1;e+=c){const r=t+(n-t)*o(e);l+=100*e+`%{${s(r,1-r)}}\n`}const u=l+`100% {${s(n,1-n)}}\n}`,h=`__svelte_${function(e){let t=5381,n=e.length;for(;n--;)t=(t<<5)-t^e.charCodeAt(n);return t>>>0}(u)}_${a}`,p=g(e),{stylesheet:f,rules:m}=B.get(p)||function(e,t){const n={stylesheet:E(t),rules:{}};return B.set(e,n),n}(p,e);m[h]||(m[h]=!0,f.insertRule(`@keyframes ${h} ${u}`,f.cssRules.length));const d=e.style.animation||"";return e.style.animation=`${d?`${d}, `:""}${h} ${r}ms linear ${i}ms 1 both`,R+=1,h}function M(e,t){const n=(e.style.animation||"").split(", "),r=n.filter(t?e=>e.indexOf(t)<0:e=>-1===e.indexOf("__svelte")),i=n.length-r.length;i&&(e.style.animation=r.join(", "),R-=i,R||p((()=>{R||(B.forEach((e=>{const{ownerNode:t}=e.stylesheet;
|
|
14
14
|
// there is no ownerNode if it runs on jsdom.
|
|
15
|
-
t&&b(t)})),
|
|
15
|
+
t&&b(t)})),B.clear())})))}function x(e){P=e}function I(){if(!P)throw new Error("Function called outside component initialization");return P}
|
|
16
16
|
/**
|
|
17
17
|
* The `onMount` function schedules a callback to run as soon as the component has been mounted to the DOM.
|
|
18
18
|
* It must be called during the component's initialisation (but doesn't need to live *inside* the component;
|
|
@@ -21,7 +21,7 @@ t&&b(t)})),C.clear())})))}function P(e){B=e}function I(){if(!B)throw new Error("
|
|
|
21
21
|
* `onMount` does not run inside a [server-side component](/docs#run-time-server-side-component-api).
|
|
22
22
|
*
|
|
23
23
|
* https://svelte.dev/docs#run-time-svelte-onmount
|
|
24
|
-
*/const
|
|
24
|
+
*/const D=[],k=[];let U=[];const G=[],F=Promise.resolve();let z=!1;function Z(e){U.push(e)}
|
|
25
25
|
// flush() calls callbacks in this order:
|
|
26
26
|
// 1. All beforeUpdate callbacks, in order: parents before children
|
|
27
27
|
// 2. All bind:this callbacks, in reverse order: children before parents.
|
|
@@ -40,69 +40,69 @@ t&&b(t)})),C.clear())})))}function P(e){B=e}function I(){if(!B)throw new Error("
|
|
|
40
40
|
// 3. During afterUpdate, any updated components will NOT have their afterUpdate
|
|
41
41
|
// callback called a second time; the seen_callbacks set, outside the flush()
|
|
42
42
|
// function, guarantees this behavior.
|
|
43
|
-
const j=new Set;let
|
|
44
|
-
function
|
|
43
|
+
const j=new Set;let V,W=0;// Do *not* move this inside the flush() function
|
|
44
|
+
function _(){
|
|
45
45
|
// Do not reenter flush while dirty components are updated, as this can
|
|
46
46
|
// result in an infinite loop. Instead, let the inner flush handle it.
|
|
47
47
|
// Reentrancy is ok afterwards for bindings etc.
|
|
48
|
-
if(0!==W)return;const e=
|
|
48
|
+
if(0!==W)return;const e=P;do{
|
|
49
49
|
// first, call beforeUpdate functions
|
|
50
50
|
// and update components
|
|
51
|
-
try{for(;W<
|
|
51
|
+
try{for(;W<D.length;){const e=D[W];W++,x(e),J(e.$$)}}catch(e){
|
|
52
52
|
// reset dirty state to not end up in a deadlocked state and then rethrow
|
|
53
|
-
throw
|
|
53
|
+
throw D.length=0,W=0,e}for(x(null),D.length=0,W=0;k.length;)k.pop()();
|
|
54
54
|
// then, once components are updated, call
|
|
55
55
|
// afterUpdate functions. This may cause
|
|
56
56
|
// subsequent updates...
|
|
57
57
|
for(let e=0;e<U.length;e+=1){const t=U[e];j.has(t)||(
|
|
58
58
|
// ...so guard against infinite loops
|
|
59
|
-
j.add(t),t())}U.length=0}while(
|
|
59
|
+
j.add(t),t())}U.length=0}while(D.length);for(;G.length;)G.pop()();z=!1,j.clear(),x(e)}function J(e){if(null!==e.fragment){e.update(),i(e.before_update);const t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(Z)}}
|
|
60
60
|
/**
|
|
61
61
|
* Useful for example to execute remaining `afterUpdate` callbacks before executing `destroy`.
|
|
62
|
-
*/function
|
|
62
|
+
*/function X(e,t,n){e.dispatchEvent(function(e,t,{bubbles:n=!1,cancelable:r=!1}={}){const i=document.createEvent("CustomEvent");return i.initCustomEvent(e,n,r,t),i}(`${t?"intro":"outro"}${n}`))}const q=new Set;let Y;function K(e,t){e&&e.i&&(q.delete(e),e.i(t))}function Q(e,t,n,r){if(e&&e.o){if(q.has(e))return;q.add(e),Y.c.push((()=>{q.delete(e),r&&(n&&e.d(1),r())})),e.o(t)}else r&&r()}const $={duration:0};function ee(n,r,s,a){const c={direction:"both"};let l=r(n,s,c),u=a?0:1,d=null,g=null,E=null;function y(){E&&M(n,E)}function b(e,t){const n=e.b-u;return t*=Math.abs(n),{a:u,b:e.b,d:n,duration:t,start:e.start,end:e.start+t,group:e.group}}function T(r){const{delay:o=0,duration:s=300,easing:a=t,tick:c=e,css:T}=l||$,v={start:h()+o,b:r};r||(
|
|
63
63
|
// @ts-ignore todo: improve typings
|
|
64
|
-
v.group=
|
|
64
|
+
v.group=Y,Y.r+=1),d||g?g=v:(
|
|
65
65
|
// if this is an intro, and there's a delay, we need to do
|
|
66
66
|
// an initial tick and/or apply CSS animation immediately
|
|
67
|
-
T&&(y(),E=
|
|
67
|
+
T&&(y(),E=L(n,u,r,s,o,a,T)),r&&c(0,1),d=b(v,s),Z((()=>X(n,r,"start"))),function(e){let t;0===f.size&&p(m),new Promise((n=>{f.add(t={c:e,f:n})}))}((e=>{if(g&&e>g.start&&(d=b(g,s),g=null,X(n,d.b,"start"),T&&(y(),E=L(n,u,d.b,d.duration,0,a,l.css))),d)if(e>=d.end)c(u=d.b,1-u),X(n,d.b,"end"),g||(
|
|
68
68
|
// we're done
|
|
69
69
|
d.b?
|
|
70
70
|
// intro — we can tidy up immediately
|
|
71
71
|
y():
|
|
72
72
|
// outro — needs to be coordinated
|
|
73
|
-
--d.group.r||i(d.group.c)),d=null;else if(e>=d.start){const t=e-d.start;u=d.a+d.d*
|
|
73
|
+
--d.group.r||i(d.group.c)),d=null;else if(e>=d.start){const t=e-d.start;u=d.a+d.d*a(t/d.duration),c(u,1-u)}return!(!d&&!g)})))}return{run(e){o(l)?(V||(V=Promise.resolve(),V.then((()=>{V=null}))),V).then((()=>{
|
|
74
74
|
// @ts-ignore
|
|
75
|
-
|
|
75
|
+
l=l(c),T(e)})):T(e)},end(){y(),d=g=null}}}function te(e,t){const n=e.$$;null!==n.fragment&&(!function(e){const t=[],n=[];U.forEach((r=>-1===e.indexOf(r)?t.push(r):n.push(r))),n.forEach((e=>e())),U=t}(n.after_update),i(n.on_destroy),n.fragment&&n.fragment.d(t),
|
|
76
76
|
// TODO null out other refs, including component.$$ (but need to
|
|
77
77
|
// preserve final state?)
|
|
78
|
-
n.on_destroy=n.fragment=null,n.ctx=[])}function ne(e,t){-1===e.$$.dirty[0]&&(
|
|
78
|
+
n.on_destroy=n.fragment=null,n.ctx=[])}function ne(e,t){-1===e.$$.dirty[0]&&(D.push(e),z||(z=!0,F.then(_)),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}function re(t,s,a,c,l,u,h,p=[-1]){const f=P;x(t);const m=t.$$={fragment:null,ctx:[],
|
|
79
79
|
// state
|
|
80
|
-
props:u,update:e,not_equal:
|
|
80
|
+
props:u,update:e,not_equal:l,bound:r(),
|
|
81
81
|
// lifecycle
|
|
82
|
-
on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(
|
|
82
|
+
on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(s.context||(f?f.$$.context:[])),
|
|
83
83
|
// everything else
|
|
84
|
-
callbacks:r(),dirty:
|
|
84
|
+
callbacks:r(),dirty:p,skip_bound:!1,root:s.target||f.$$.root};h&&h(m.root);let d=!1;if(m.ctx=a?a(t,s.props||{},((e,n,...r)=>{const i=r.length?r[0]:n;return m.ctx&&l(m.ctx[e],m.ctx[e]=i)&&(!m.skip_bound&&m.bound[e]&&m.bound[e](i),d&&ne(t,e)),n})):[],m.update(),d=!0,i(m.before_update),
|
|
85
85
|
// `false` as a special case of no DOM component
|
|
86
|
-
m.fragment=!!
|
|
86
|
+
m.fragment=!!c&&c(m.ctx),s.target){if(s.hydrate){const e=function(e){return Array.from(e.childNodes)}(s.target);
|
|
87
87
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
88
88
|
m.fragment&&m.fragment.l(e),e.forEach(b)}else
|
|
89
89
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
90
|
-
m.fragment&&m.fragment.c();
|
|
90
|
+
m.fragment&&m.fragment.c();s.intro&&K(t.$$.fragment),function(e,t,r,s){const{fragment:a,after_update:c}=e.$$;a&&a.m(t,r),s||
|
|
91
91
|
// onMount happens before the initial afterUpdate
|
|
92
|
-
|
|
92
|
+
Z((()=>{const t=e.$$.on_mount.map(n).filter(o);
|
|
93
93
|
// if the component was destroyed immediately
|
|
94
94
|
// it will update the `$$.on_destroy` reference to `null`.
|
|
95
95
|
// the destructured on_destroy may still reference to the old array
|
|
96
96
|
e.$$.on_destroy?e.$$.on_destroy.push(...t):
|
|
97
97
|
// Edge case - component was destroyed immediately,
|
|
98
98
|
// most likely as a result of a binding initialising
|
|
99
|
-
i(t),e.$$.on_mount=[]})),
|
|
99
|
+
i(t),e.$$.on_mount=[]})),c.forEach(Z)}(t,s.target,s.anchor,s.customElement),_()}x(f)}let ie;function oe(e,{delay:n=0,duration:r=400,easing:i=t}={}){const o=+getComputedStyle(e).opacity;return{delay:n,duration:r,easing:i,css:e=>"opacity: "+e*o}}"function"==typeof HTMLElement&&(ie=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){const{on_mount:e}=this.$$;this.$$.on_disconnect=e.map(n).filter(o);
|
|
100
100
|
// @ts-ignore todo: improve typings
|
|
101
101
|
for(const e in this.$$.slotted)
|
|
102
102
|
// @ts-ignore todo: improve typings
|
|
103
103
|
this.appendChild(this.$$.slotted[e])}attributeChangedCallback(e,t,n){this[e]=n}disconnectedCallback(){i(this.$$.on_disconnect)}$destroy(){te(this,1),this.$destroy=e}$on(t,n){
|
|
104
104
|
// TODO should this delegate to addEventListener?
|
|
105
|
-
if(!o(n))return e;const r=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return r.push(n),()=>{const e=r.indexOf(n);-1!==e&&r.splice(e,1)}}$set(e){var t;this.$$set&&(t=e,0!==Object.keys(t).length)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}});const
|
|
105
|
+
if(!o(n))return e;const r=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return r.push(n),()=>{const e=r.indexOf(n);-1!==e&&r.splice(e,1)}}$set(e){var t;this.$$set&&(t=e,0!==Object.keys(t).length)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}});const se=[];
|
|
106
106
|
/**
|
|
107
107
|
* Creates a `Readable` store that allows reading by subscription.
|
|
108
108
|
* @param value initial value
|
|
@@ -113,24 +113,24 @@ if(!o(n))return e;const r=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return
|
|
|
113
113
|
* @param {*=}value initial value
|
|
114
114
|
* @param {StartStopNotifier=} start
|
|
115
115
|
*/
|
|
116
|
-
function
|
|
117
|
-
const e=!
|
|
116
|
+
function ae(t,n=e){let r;const i=new Set;function o(e){if(s(t,e)&&(t=e,r)){// store is ready
|
|
117
|
+
const e=!se.length;for(const e of i)e[1](),se.push(e,t);if(e){for(let e=0;e<se.length;e+=2)se[e][0](se[e+1]);se.length=0}}}return{set:o,update:function(e){o(e(t))},subscribe:function(s,a=e){const c=[s,a];return i.add(c),1===i.size&&(r=n(o)||e),s(t),()=>{i.delete(c),0===i.size&&r&&(r(),r=null)}}}}function ce(t,n,r){const s=!Array.isArray(t),a=s?[t]:t,c=n.length<2;return u=t=>{let r=!1;const u=[];let h=0,p=e;const f=()=>{if(h)return;p();const r=n(s?u[0]:u,t);c?t(r):p=o(r)?r:e},m=a.map(((e,t)=>l(e,(e=>{u[t]=e,h&=~(1<<t),r&&f()}),(()=>{h|=1<<t}))));return r=!0,f(),function(){i(m),p(),
|
|
118
118
|
// We need to set this to false because callbacks can still happen despite having unsubscribed:
|
|
119
119
|
// Callbacks might already be placed in the queue which doesn't know it should no longer
|
|
120
120
|
// invoke this derived store.
|
|
121
|
-
r=!1}},{subscribe:
|
|
121
|
+
r=!1}},{subscribe:ae(r,u).subscribe};var u}var le=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===ue}(e)}
|
|
122
122
|
// see https://github.com/facebook/react/blob/b5ac963fb791d1298e7f396236383bc955f916c1/src/isomorphic/classic/element/ReactElement.js#L21-L25
|
|
123
|
-
(e)};var ue="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function he(e,t){return!1!==t.clone&&t.isMergeableObject(e)?ge((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function
|
|
123
|
+
(e)};var ue="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function he(e,t){return!1!==t.clone&&t.isMergeableObject(e)?ge((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function pe(e,t,n){return e.concat(t).map((function(e){return he(e,n)}))}function fe(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter((function(t){return Object.propertyIsEnumerable.call(e,t)})):[]}(e))}function me(e,t){try{return t in e}catch(e){return!1}}
|
|
124
124
|
// Protects from prototype poisoning and unexpected merging up the prototype chain.
|
|
125
|
-
function de(e,t,n){var r={};return n.isMergeableObject(e)&&
|
|
126
|
-
})(e,i)||(me(e,i)&&n.isMergeableObject(t[i])?r[i]=function(e,t){if(!t.customMerge)return ge;var n=t.customMerge(e);return"function"==typeof n?n:ge}(i,n)(e[i],t[i],n):r[i]=he(t[i],n))})),r}function ge(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||
|
|
125
|
+
function de(e,t,n){var r={};return n.isMergeableObject(e)&&fe(e).forEach((function(t){r[t]=he(e[t],n)})),fe(t).forEach((function(i){(function(e,t){return me(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t));// and also unsafe if they're nonenumerable.
|
|
126
|
+
})(e,i)||(me(e,i)&&n.isMergeableObject(t[i])?r[i]=function(e,t){if(!t.customMerge)return ge;var n=t.customMerge(e);return"function"==typeof n?n:ge}(i,n)(e[i],t[i],n):r[i]=he(t[i],n))})),r}function ge(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||pe,n.isMergeableObject=n.isMergeableObject||le,
|
|
127
127
|
// cloneUnlessOtherwiseSpecified is added to `options` so that custom arrayMerge()
|
|
128
128
|
// implementations can use it. The caller may not replace it.
|
|
129
|
-
n.cloneUnlessOtherwiseSpecified=he;var r=Array.isArray(t);return r===Array.isArray(e)?r?n.arrayMerge(e,t,n):de(e,t,n):he(t,n)}ge.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce((function(e,n){return ge(e,n,t)}),{})};var Ee=ge,ye=function(e,t){return ye=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])},ye(e,t)};function be(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}ye(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Te,ve,
|
|
129
|
+
n.cloneUnlessOtherwiseSpecified=he;var r=Array.isArray(t);return r===Array.isArray(e)?r?n.arrayMerge(e,t,n):de(e,t,n):he(t,n)}ge.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce((function(e,n){return ge(e,n,t)}),{})};var Ee=ge,ye=function(e,t){return ye=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])},ye(e,t)};function be(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}ye(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Te,ve,we,Se=function(){return Se=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Se.apply(this,arguments)};function Ae(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}
|
|
130
130
|
/**
|
|
131
131
|
* Type Guards
|
|
132
132
|
*/
|
|
133
|
-
function
|
|
133
|
+
function He(e){return e.type===ve.literal}function Ne(e){return e.type===ve.argument}function Oe(e){return e.type===ve.number}function Ce(e){return e.type===ve.date}function Be(e){return e.type===ve.time}function Pe(e){return e.type===ve.select}function Re(e){return e.type===ve.plural}function Le(e){return e.type===ve.pound}function Me(e){return e.type===ve.tag}function xe(e){return!(!e||"object"!=typeof e||e.type!==we.number)}function Ie(e){return!(!e||"object"!=typeof e||e.type!==we.dateTime)}
|
|
134
134
|
// @generated from regex-gen.ts
|
|
135
135
|
"function"==typeof SuppressedError&&SuppressedError,function(e){
|
|
136
136
|
/** Argument is unclosed (e.g. `{0`) */
|
|
@@ -229,7 +229,7 @@ e[e.pound=7]="pound",
|
|
|
229
229
|
/**
|
|
230
230
|
* XML-like tag
|
|
231
231
|
*/
|
|
232
|
-
e[e.tag=8]="tag"}(ve||(ve={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(
|
|
232
|
+
e[e.tag=8]="tag"}(ve||(ve={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(we||(we={}));var De=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,ke=/(?:[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;
|
|
233
233
|
/**
|
|
234
234
|
* https://unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
235
235
|
* Credit: https://github.com/caridy/intl-datetimeformat-pattern/blob/master/index.js
|
|
@@ -241,7 +241,7 @@ e[e.tag=8]="tag"}(ve||(ve={})),function(e){e[e.number=0]="number",e[e.dateTime=1
|
|
|
241
241
|
* @public
|
|
242
242
|
* @param skeleton skeleton string
|
|
243
243
|
*/
|
|
244
|
-
function Ue(e){var t={};return e.replace(
|
|
244
|
+
function Ue(e){var t={};return e.replace(ke,(function(e){var n=e.length;switch(e[0]){
|
|
245
245
|
// Era
|
|
246
246
|
case"G":t.era=4===n?"long":5===n?"narrow":"short";break;
|
|
247
247
|
// Year
|
|
@@ -275,33 +275,33 @@ case"X":// 1, 2, 3, 4: The ISO8601 varios formats
|
|
|
275
275
|
case"x":// 1, 2, 3, 4: The ISO8601 varios formats
|
|
276
276
|
throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),t}
|
|
277
277
|
// @generated from regex-gen.ts
|
|
278
|
-
var
|
|
278
|
+
var Ge=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;var Fe=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,ze=/^(@+)?(\+|#+)?[rs]?$/g,Ze=/(\*)(0+)|(#+)(0+)|(0+)/g,je=/^(0+)$/;function Ve(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(ze,(function(e,n,r){
|
|
279
279
|
// @@@ case
|
|
280
|
-
return"string"!=typeof r?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===r?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""})),t}function We(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
|
|
280
|
+
return"string"!=typeof r?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===r?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""})),t}function We(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 _e(e){
|
|
281
281
|
// Engineering
|
|
282
|
-
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)),!je.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function
|
|
282
|
+
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)),!je.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function Je(e){var t=We(e);return t||{}}
|
|
283
283
|
/**
|
|
284
284
|
* https://github.com/unicode-org/icu/blob/master/docs/userguide/format_parse/numbers/skeletons.md#skeleton-stems-and-options
|
|
285
|
-
*/function
|
|
285
|
+
*/function Xe(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n];switch(i.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=i.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=i.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=Se(Se(Se({},t),{notation:"scientific"}),i.options.reduce((function(e,t){return Se(Se({},e),Je(t))}),{}));continue;case"engineering":t=Se(Se(Se({},t),{notation:"engineering"}),i.options.reduce((function(e,t){return Se(Se({},e),Je(t))}),{}));continue;case"notation-simple":t.notation="standard";continue;
|
|
286
286
|
// https://github.com/unicode-org/icu/blob/master/icu4c/source/i18n/unicode/unumberformatter.h
|
|
287
287
|
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(i.options[0]);continue;
|
|
288
288
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#integer-width
|
|
289
|
-
case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(
|
|
289
|
+
case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(Ze,(function(e,n,r,i,o,s){if(n)t.minimumIntegerDigits=r.length;else{if(i&&o)throw new Error("We currently do not support maximum integer digits");if(s)throw new Error("We currently do not support exact integer digits")}return""}));continue}
|
|
290
290
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#integer-width
|
|
291
|
-
if(je.test(i.stem))t.minimumIntegerDigits=i.stem.length;else if(
|
|
291
|
+
if(je.test(i.stem))t.minimumIntegerDigits=i.stem.length;else if(Fe.test(i.stem)){
|
|
292
292
|
// Precision
|
|
293
293
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#fraction-precision
|
|
294
294
|
// precision-integer case
|
|
295
|
-
if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(
|
|
295
|
+
if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(Fe,(function(e,n,r,i,o,s){
|
|
296
296
|
// .000* case (before ICU67 it was .000+)
|
|
297
|
-
return"*"===r?t.minimumFractionDigits=n.length:i&&"#"===i[0]?t.maximumFractionDigits=i.length:o&&
|
|
297
|
+
return"*"===r?t.minimumFractionDigits=n.length:i&&"#"===i[0]?t.maximumFractionDigits=i.length:o&&s?(t.minimumFractionDigits=o.length,t.maximumFractionDigits=o.length+s.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""}));var o=i.options[0];
|
|
298
298
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#trailing-zero-display
|
|
299
|
-
"w"===o?t=
|
|
299
|
+
"w"===o?t=Se(Se({},t),{trailingZeroDisplay:"stripIfInteger"}):o&&(t=Se(Se({},t),Ve(o)))}
|
|
300
300
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#significant-digits-precision
|
|
301
|
-
else if(
|
|
301
|
+
else if(ze.test(i.stem))t=Se(Se({},t),Ve(i.stem));else{var s=We(i.stem);s&&(t=Se(Se({},t),s));var a=_e(i.stem);a&&(t=Se(Se({},t),a))}}return t}
|
|
302
302
|
// @generated from time-data-gen.ts
|
|
303
303
|
// prettier-ignore
|
|
304
|
-
var
|
|
304
|
+
var qe,Ye={AX:["H"],BQ:["H"],CP:["H"],CZ:["H"],DK:["H"],FI:["H"],ID:["H"],IS:["H"],ML:["H"],NE:["H"],RU:["H"],SE:["H"],SJ:["H"],SK:["H"],AS:["h","H"],BT:["h","H"],DJ:["h","H"],ER:["h","H"],GH:["h","H"],IN:["h","H"],LS:["h","H"],PG:["h","H"],PW:["h","H"],SO:["h","H"],TO:["h","H"],VU:["h","H"],WS:["h","H"],"001":["H","h"],AL:["h","H","hB"],TD:["h","H","hB"],"ca-ES":["H","h","hB"],CF:["H","h","hB"],CM:["H","h","hB"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],LU:["H","h","hB"],NP:["H","h","hB"],PF:["H","h","hB"],SC:["H","h","hB"],SM:["H","h","hB"],SN:["H","h","hB"],TF:["H","h","hB"],VA:["H","h","hB"],CY:["h","H","hb","hB"],GR:["h","H","hb","hB"],CO:["h","H","hB","hb"],DO:["h","H","hB","hb"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],NA:["h","H","hB","hb"],PA:["h","H","hB","hb"],PR:["h","H","hB","hb"],VE:["h","H","hB","hb"],AC:["H","h","hb","hB"],AI:["H","h","hb","hB"],BW:["H","h","hb","hB"],BZ:["H","h","hb","hB"],CC:["H","h","hb","hB"],CK:["H","h","hb","hB"],CX:["H","h","hb","hB"],DG:["H","h","hb","hB"],FK:["H","h","hb","hB"],GB:["H","h","hb","hB"],GG:["H","h","hb","hB"],GI:["H","h","hb","hB"],IE:["H","h","hb","hB"],IM:["H","h","hb","hB"],IO:["H","h","hb","hB"],JE:["H","h","hb","hB"],LT:["H","h","hb","hB"],MK:["H","h","hb","hB"],MN:["H","h","hb","hB"],MS:["H","h","hb","hB"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],PN:["H","h","hb","hB"],SH:["H","h","hb","hB"],SX:["H","h","hb","hB"],TA:["H","h","hb","hB"],ZA:["H","h","hb","hB"],"af-ZA":["H","h","hB","hb"],AR:["H","h","hB","hb"],CL:["H","h","hB","hb"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],EA:["H","h","hB","hb"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],GT:["H","h","hB","hb"],HN:["H","h","hB","hb"],IC:["H","h","hB","hb"],KG:["H","h","hB","hb"],KM:["H","h","hB","hb"],LK:["H","h","hB","hb"],MA:["H","h","hB","hb"],MX:["H","h","hB","hb"],NI:["H","h","hB","hb"],PY:["H","h","hB","hb"],SV:["H","h","hB","hb"],UY:["H","h","hB","hb"],JP:["H","h","K"],AD:["H","hB"],AM:["H","hB"],AO:["H","hB"],AT:["H","hB"],AW:["H","hB"],BE:["H","hB"],BF:["H","hB"],BJ:["H","hB"],BL:["H","hB"],BR:["H","hB"],CG:["H","hB"],CI:["H","hB"],CV:["H","hB"],DE:["H","hB"],EE:["H","hB"],FR:["H","hB"],GA:["H","hB"],GF:["H","hB"],GN:["H","hB"],GP:["H","hB"],GW:["H","hB"],HR:["H","hB"],IL:["H","hB"],IT:["H","hB"],KZ:["H","hB"],MC:["H","hB"],MD:["H","hB"],MF:["H","hB"],MQ:["H","hB"],MZ:["H","hB"],NC:["H","hB"],NL:["H","hB"],PM:["H","hB"],PT:["H","hB"],RE:["H","hB"],RO:["H","hB"],SI:["H","hB"],SR:["H","hB"],ST:["H","hB"],TG:["H","hB"],TR:["H","hB"],WF:["H","hB"],YT:["H","hB"],BD:["h","hB","H"],PK:["h","hB","H"],AZ:["H","hB","h"],BA:["H","hB","h"],BG:["H","hB","h"],CH:["H","hB","h"],GE:["H","hB","h"],LI:["H","hB","h"],ME:["H","hB","h"],RS:["H","hB","h"],UA:["H","hB","h"],UZ:["H","hB","h"],XK:["H","hB","h"],AG:["h","hb","H","hB"],AU:["h","hb","H","hB"],BB:["h","hb","H","hB"],BM:["h","hb","H","hB"],BS:["h","hb","H","hB"],CA:["h","hb","H","hB"],DM:["h","hb","H","hB"],"en-001":["h","hb","H","hB"],FJ:["h","hb","H","hB"],FM:["h","hb","H","hB"],GD:["h","hb","H","hB"],GM:["h","hb","H","hB"],GU:["h","hb","H","hB"],GY:["h","hb","H","hB"],JM:["h","hb","H","hB"],KI:["h","hb","H","hB"],KN:["h","hb","H","hB"],KY:["h","hb","H","hB"],LC:["h","hb","H","hB"],LR:["h","hb","H","hB"],MH:["h","hb","H","hB"],MP:["h","hb","H","hB"],MW:["h","hb","H","hB"],NZ:["h","hb","H","hB"],SB:["h","hb","H","hB"],SG:["h","hb","H","hB"],SL:["h","hb","H","hB"],SS:["h","hb","H","hB"],SZ:["h","hb","H","hB"],TC:["h","hb","H","hB"],TT:["h","hb","H","hB"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],VC:["h","hb","H","hB"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],ZM:["h","hb","H","hB"],BO:["H","hB","h","hb"],EC:["H","hB","h","hb"],ES:["H","hB","h","hb"],GQ:["H","hB","h","hb"],PE:["H","hB","h","hb"],AE:["h","hB","hb","H"],"ar-001":["h","hB","hb","H"],BH:["h","hB","hb","H"],DZ:["h","hB","hb","H"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],HK:["h","hB","hb","H"],IQ:["h","hB","hb","H"],JO:["h","hB","hb","H"],KW:["h","hB","hb","H"],LB:["h","hB","hb","H"],LY:["h","hB","hb","H"],MO:["h","hB","hb","H"],MR:["h","hB","hb","H"],OM:["h","hB","hb","H"],PH:["h","hB","hb","H"],PS:["h","hB","hb","H"],QA:["h","hB","hb","H"],SA:["h","hB","hb","H"],SD:["h","hB","hb","H"],SY:["h","hB","hb","H"],TN:["h","hB","hb","H"],YE:["h","hB","hb","H"],AF:["H","hb","hB","h"],LA:["H","hb","hB","h"],CN:["H","hB","hb","h"],LV:["H","hB","hb","h"],TL:["H","hB","hb","h"],"zu-ZA":["H","hB","hb","h"],CD:["hB","H"],IR:["hB","H"],"hi-IN":["hB","h","H"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"te-IN":["hB","h","H"],KH:["hB","h","H","hb"],"ta-IN":["hB","h","hb","H"],BN:["hb","hB","h","H"],MY:["hb","hB","h","H"],ET:["hB","hb","h","H"],"gu-IN":["hB","hb","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],TW:["hB","hb","h","H"],KE:["hB","hb","H","h"],MM:["hB","hb","H","h"],TZ:["hB","hb","H","h"],UG:["hB","hb","H","h"]};
|
|
305
305
|
/**
|
|
306
306
|
* Returns the best matching date time pattern if a date time skeleton
|
|
307
307
|
* pattern is provided with a locale. Follows the Unicode specification:
|
|
@@ -314,7 +314,7 @@ var Ke,Ze={AX:["H"],BQ:["H"],CP:["H"],CZ:["H"],DK:["H"],FI:["H"],ID:["H"],IS:["H
|
|
|
314
314
|
* of the given `locale` to the corresponding time pattern.
|
|
315
315
|
* @param locale
|
|
316
316
|
*/
|
|
317
|
-
function
|
|
317
|
+
function Ke(e){var t=e.hourCycle;if(void 0===t&&
|
|
318
318
|
// @ts-ignore hourCycle(s) is not identified yet
|
|
319
319
|
e.hourCycles&&
|
|
320
320
|
// @ts-ignore
|
|
@@ -322,37 +322,37 @@ e.hourCycles.length&&(
|
|
|
322
322
|
// @ts-ignore
|
|
323
323
|
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")}
|
|
324
324
|
// TODO: Once hourCycle is fully supported remove the following with data generation
|
|
325
|
-
var n,r=e.language;return"root"!==r&&(n=e.maximize().region),(
|
|
325
|
+
var n,r=e.language;return"root"!==r&&(n=e.maximize().region),(Ye[n||""]||Ye[r||""]||Ye["".concat(r,"-001")]||Ye["001"])[0]}var Qe=new RegExp("^".concat(De.source,"*")),$e=new RegExp("".concat(De.source,"*$"));function et(e,t){return{start:e,end:t}}
|
|
326
326
|
// #region Ponyfills
|
|
327
327
|
// Consolidate these variables up top for easier toggling during debugging
|
|
328
|
-
var tt=!!String.prototype.startsWith,nt=!!String.fromCodePoint,rt=!!Object.fromEntries,it=!!String.prototype.codePointAt,ot=!!String.prototype.trimStart,
|
|
328
|
+
var tt=!!String.prototype.startsWith,nt=!!String.fromCodePoint,rt=!!Object.fromEntries,it=!!String.prototype.codePointAt,ot=!!String.prototype.trimStart,st=!!String.prototype.trimEnd,at=!!Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},ct=!0;try{
|
|
329
329
|
/**
|
|
330
330
|
* legacy Edge or Xbox One browser
|
|
331
331
|
* Unicode flag support: supported
|
|
332
332
|
* Pattern_Syntax support: not supported
|
|
333
333
|
* See https://github.com/formatjs/formatjs/issues/2822
|
|
334
334
|
*/
|
|
335
|
-
|
|
335
|
+
ct="a"===(null===(qe=gt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===qe?void 0:qe[0])}catch(e){ct=!1}var lt,ut=tt?// Native
|
|
336
336
|
function(e,t,n){return e.startsWith(t,n)}:// For IE11
|
|
337
337
|
function(e,t,n){return e.slice(n,n+t.length)===t},ht=nt?String.fromCodePoint:// IE11
|
|
338
|
-
function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n,r="",i=e.length,o=0;i>o;){if((n=e[o++])>1114111)throw RangeError(n+" is not a valid code point");r+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return r},
|
|
338
|
+
function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n,r="",i=e.length,o=0;i>o;){if((n=e[o++])>1114111)throw RangeError(n+" is not a valid code point");r+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return r},pt=
|
|
339
339
|
// native
|
|
340
340
|
rt?Object.fromEntries:// Ponyfill
|
|
341
|
-
function(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n],o=i[0],
|
|
341
|
+
function(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n],o=i[0],s=i[1];t[o]=s}return t},ft=it?// Native
|
|
342
342
|
function(e,t){return e.codePointAt(t)}:// IE 11
|
|
343
343
|
function(e,t){var n=e.length;if(!(t<0||t>=n)){var r,i=e.charCodeAt(t);return i<55296||i>56319||t+1===n||(r=e.charCodeAt(t+1))<56320||r>57343?i:r-56320+(i-55296<<10)+65536}},mt=ot?// Native
|
|
344
344
|
function(e){return e.trimStart()}:// Ponyfill
|
|
345
|
-
function(e){return e.replace(
|
|
345
|
+
function(e){return e.replace(Qe,"")},dt=st?// Native
|
|
346
346
|
function(e){return e.trimEnd()}:// Ponyfill
|
|
347
|
-
function(e){return e.replace(
|
|
347
|
+
function(e){return e.replace($e,"")};
|
|
348
348
|
// Prevent minifier to translate new RegExp to literal form that might cause syntax error on IE11.
|
|
349
349
|
function gt(e,t){return new RegExp(e,t)}
|
|
350
350
|
// #endregion
|
|
351
|
-
if(
|
|
351
|
+
if(ct){
|
|
352
352
|
// Native
|
|
353
|
-
var Et=gt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");
|
|
353
|
+
var Et=gt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");lt=function(e,t){var n;return Et.lastIndex=t,null!==(n=Et.exec(e)[1])&&void 0!==n?n:""}}else
|
|
354
354
|
// IE11
|
|
355
|
-
|
|
355
|
+
lt=function(e,t){for(var n=[];;){var r=ft(e,t);if(void 0===r||Tt(r)||vt(r))break;n.push(r),t+=r>=65536?2:1}return ht.apply(void 0,n)};var yt=/** @class */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 r=[];!this.isEOF();){var i=this.char();if(123/* `{` */===i){if((o=this.parseArgument(e,n)).err)return o;r.push(o.val)}else{if(125/* `}` */===i&&e>0)break;if(35/* `#` */!==i||"plural"!==t&&"selectordinal"!==t){if(60/* `<` */===i&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(Te.UNMATCHED_CLOSING_TAG,et(this.clonePosition(),this.clonePosition()))}if(60/* `<` */===i&&!this.ignoreTag&&bt(this.peek()||0)){if((o=this.parseTag(e,t)).err)return o;r.push(o.val)}else{var o;if((o=this.parseLiteral(e,t)).err)return o;r.push(o.val)}}else{var s=this.clonePosition();this.bump(),r.push({type:ve.pound,location:et(s,this.clonePosition())})}}}return{val:r,err:null}},
|
|
356
356
|
/**
|
|
357
357
|
* A tag name must start with an ASCII lower/upper case letter. The grammar is based on the
|
|
358
358
|
* [custom element name][] except that a dash is NOT always mandatory and uppercase letters
|
|
@@ -374,14 +374,14 @@ ct=function(e,t){for(var n=[];;){var r=pt(e,t);if(void 0===r||Tt(r)||vt(r))break
|
|
|
374
374
|
e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();// `<`
|
|
375
375
|
var r=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))
|
|
376
376
|
// Self closing tag
|
|
377
|
-
return{val:{type:ve.literal,value:"<".concat(r,"/>"),location:et(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var i=this.parseMessage(e+1,t,!0);if(i.err)return i;var o=i.val,
|
|
377
|
+
return{val:{type:ve.literal,value:"<".concat(r,"/>"),location:et(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var i=this.parseMessage(e+1,t,!0);if(i.err)return i;var o=i.val,s=this.clonePosition();
|
|
378
378
|
// Expecting a close tag
|
|
379
|
-
if(this.bumpIf("</")){if(this.isEOF()||!bt(this.char()))return this.error(Te.INVALID_TAG,et(
|
|
379
|
+
if(this.bumpIf("</")){if(this.isEOF()||!bt(this.char()))return this.error(Te.INVALID_TAG,et(s,this.clonePosition()));var a=this.clonePosition();return r!==this.parseTagName()?this.error(Te.UNMATCHED_CLOSING_TAG,et(a,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:ve.tag,value:r,children:o,location:et(n,this.clonePosition())},err:null}:this.error(Te.INVALID_TAG,et(s,this.clonePosition())))}return this.error(Te.UNCLOSED_TAG,et(n,this.clonePosition()))}return this.error(Te.INVALID_TAG,et(n,this.clonePosition()))},
|
|
380
380
|
/**
|
|
381
381
|
* This method assumes that the caller has peeked ahead for the first tag character.
|
|
382
382
|
*/
|
|
383
383
|
e.prototype.parseTagName=function(){var e,t=this.offset();// the first tag name character
|
|
384
|
-
for(this.bump();!this.isEOF()&&(45/* '-' */===(e=this.char())||46/* '.' */===e||e>=48&&e<=57/* 0..9 */||95/* '_' */===e||e>=97&&e<=122/** a..z */||e>=65&&e<=90/* A..Z */||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(),r="";;){var i=this.tryParseQuote(t);if(i)r+=i;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var
|
|
384
|
+
for(this.bump();!this.isEOF()&&(45/* '-' */===(e=this.char())||46/* '.' */===e||e>=48&&e<=57/* 0..9 */||95/* '_' */===e||e>=97&&e<=122/** a..z */||e>=65&&e<=90/* A..Z */||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(),r="";;){var i=this.tryParseQuote(t);if(i)r+=i;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var s=this.tryParseLeftAngleBracket();if(!s)break;r+=s}}}var a=et(n,this.clonePosition());return{val:{type:ve.literal,value:r,location:a},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60/* `<` */!==this.char()||!this.ignoreTag&&(bt(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e;
|
|
385
385
|
/** See `parseTag` function docs. */},
|
|
386
386
|
/**
|
|
387
387
|
* Starting with ICU 4.8, an ASCII apostrophe only starts quoted text if it immediately precedes
|
|
@@ -419,40 +419,40 @@ this.bumpSpace(),this.isEOF()?this.error(Te.EXPECT_ARGUMENT_CLOSING_BRACE,et(n,t
|
|
|
419
419
|
* Advance the parser until the end of the identifier, if it is currently on
|
|
420
420
|
* an identifier character. Return an empty string otherwise.
|
|
421
421
|
*/
|
|
422
|
-
e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=
|
|
422
|
+
e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=lt(this.message,t),r=t+n.length;return this.bumpTo(r),{value:n,location:et(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,r){var i,o=this.clonePosition(),s=this.parseIdentifierIfPossible().value,a=this.clonePosition();
|
|
423
423
|
// Parse this range:
|
|
424
424
|
// {name, type, style}
|
|
425
425
|
// ^---^
|
|
426
|
-
switch(
|
|
426
|
+
switch(s){case"":
|
|
427
427
|
// Expecting a style string number, date, time, plural, selectordinal, or select.
|
|
428
|
-
return this.error(Te.EXPECT_ARGUMENT_TYPE,et(o,
|
|
428
|
+
return this.error(Te.EXPECT_ARGUMENT_TYPE,et(o,a));case"number":case"date":case"time":
|
|
429
429
|
// Parse this range:
|
|
430
430
|
// {name, number, style}
|
|
431
431
|
// ^-------^
|
|
432
|
-
this.bumpSpace();var
|
|
432
|
+
this.bumpSpace();var c=null;if(this.bumpIf(",")){this.bumpSpace();var l=this.clonePosition();if((E=this.parseSimpleArgStyleIfPossible()).err)return E;if(0===(f=dt(E.val)).length)return this.error(Te.EXPECT_ARGUMENT_STYLE,et(this.clonePosition(),this.clonePosition()));c={style:f,styleLocation:et(l,this.clonePosition())}}if((y=this.tryParseArgumentClose(r)).err)return y;var u=et(r,this.clonePosition());
|
|
433
433
|
// Extract style or skeleton
|
|
434
|
-
if(
|
|
434
|
+
if(c&&ut(null==c?void 0:c.style,"::",0)){
|
|
435
435
|
// Skeleton starts with `::`.
|
|
436
|
-
var h=mt(
|
|
436
|
+
var h=mt(c.style.slice(2));if("number"===s)return(E=this.parseNumberSkeletonFromString(h,c.styleLocation)).err?E:{val:{type:ve.number,value:n,location:u,style:E.val},err:null};if(0===h.length)return this.error(Te.EXPECT_DATE_TIME_SKELETON,u);var p=h;
|
|
437
437
|
// Get "best match" pattern only if locale is passed, if not, let it
|
|
438
438
|
// pass as-is where `parseDateTimeSkeleton()` will throw an error
|
|
439
439
|
// for unsupported patterns.
|
|
440
|
-
this.locale&&(
|
|
440
|
+
this.locale&&(p=function(e,t){for(var n="",r=0;r<e.length;r++){var i=e.charAt(r);if("j"===i){for(var o=0;r+1<e.length&&e.charAt(r+1)===i;)o++,r++;var s=1+(1&o),a=o<2?1:3+(o>>1),c=Ke(t);for("H"!=c&&"k"!=c||(a=0);a-- >0;)n+="a";for(;s-- >0;)n=c+n}else n+="J"===i?"H":i}return n}(h,this.locale));var f={type:we.dateTime,pattern:p,location:c.styleLocation,parsedOptions:this.shouldParseSkeletons?Ue(p):{}};return{val:{type:"date"===s?ve.date:ve.time,value:n,location:u,style:f},err:null}}
|
|
441
441
|
// Regular style or no style.
|
|
442
|
-
return{val:{type:"number"===
|
|
442
|
+
return{val:{type:"number"===s?ve.number:"date"===s?ve.date:ve.time,value:n,location:u,style:null!==(i=null==c?void 0:c.style)&&void 0!==i?i:null},err:null};case"plural":case"selectordinal":case"select":
|
|
443
443
|
// Parse this range:
|
|
444
444
|
// {name, plural, options}
|
|
445
445
|
// ^---------^
|
|
446
|
-
var m=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(Te.EXPECT_SELECT_ARGUMENT_OPTIONS,et(m,
|
|
446
|
+
var m=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(Te.EXPECT_SELECT_ARGUMENT_OPTIONS,et(m,Se({},m)));this.bumpSpace();
|
|
447
447
|
// Parse offset:
|
|
448
448
|
// {name, plural, offset:1, options}
|
|
449
449
|
// ^-----^
|
|
450
450
|
// or the first option:
|
|
451
451
|
// {name, plural, one {...} other {...}}
|
|
452
452
|
// ^--^
|
|
453
|
-
var d=this.parseIdentifierIfPossible(),g=0;if("select"!==
|
|
453
|
+
var d=this.parseIdentifierIfPossible(),g=0;if("select"!==s&&"offset"===d.value){if(!this.bumpIf(":"))return this.error(Te.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,et(this.clonePosition(),this.clonePosition()));var E;if(this.bumpSpace(),(E=this.tryParseDecimalInteger(Te.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,Te.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return E;
|
|
454
454
|
// Parse another identifier for option parsing
|
|
455
|
-
this.bumpSpace(),d=this.parseIdentifierIfPossible(),g=E.val}var y,b=this.tryParsePluralOrSelectOptions(e,
|
|
455
|
+
this.bumpSpace(),d=this.parseIdentifierIfPossible(),g=E.val}var y,b=this.tryParsePluralOrSelectOptions(e,s,t,d);if(b.err)return b;if((y=this.tryParseArgumentClose(r)).err)return y;var T=et(r,this.clonePosition());return"select"===s?{val:{type:ve.select,value:n,options:pt(b.val),location:T},err:null}:{val:{type:ve.plural,value:n,options:pt(b.val),offset:g,pluralType:"plural"===s?"cardinal":"ordinal",location:T},err:null};default:return this.error(Te.INVALID_ARGUMENT_TYPE,et(o,a))}},e.prototype.tryParseArgumentClose=function(e){
|
|
456
456
|
// Parse: {value, number, ::currency/GBP }
|
|
457
457
|
return this.isEOF()||125/* `}` */!==this.char()?this.error(Te.EXPECT_ARGUMENT_CLOSING_BRACE,et(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},
|
|
458
458
|
/**
|
|
@@ -463,7 +463,7 @@ e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePos
|
|
|
463
463
|
// Find the end of the quoted literal text.
|
|
464
464
|
this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(Te.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,et(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");
|
|
465
465
|
// Parse the skeleton
|
|
466
|
-
for(var t=[],n=0,r=e.split(
|
|
466
|
+
for(var t=[],n=0,r=e.split(Ge).filter((function(e){return e.length>0}));n<r.length;n++){var i=r[n].split("/");if(0===i.length)throw new Error("Invalid number skeleton");for(var o=i[0],s=i.slice(1),a=0,c=s;a<c.length;a++)if(0===c[a].length)throw new Error("Invalid number skeleton");t.push({stem:o,options:s})}return t}(e)}catch(e){return this.error(Te.INVALID_NUMBER_SKELETON,t)}return{val:{type:we.number,tokens:n,location:t,parsedOptions:this.shouldParseSkeletons?Xe(n):{}},err:null}},
|
|
467
467
|
/**
|
|
468
468
|
* @param nesting_level The current nesting level of messages.
|
|
469
469
|
* This can be positive when parsing message fragment in select or plural argument options.
|
|
@@ -478,26 +478,26 @@ e.prototype.tryParsePluralOrSelectOptions=function(e,t,n,r){
|
|
|
478
478
|
// Parse:
|
|
479
479
|
// one {one apple}
|
|
480
480
|
// ^--^
|
|
481
|
-
for(var i,o=!1,
|
|
481
|
+
for(var i,o=!1,s=[],a=new Set,c=r.value,l=r.location;;){if(0===c.length){var u=this.clonePosition();if("select"===t||!this.bumpIf("="))break;
|
|
482
482
|
// Try parse `={number}` selector
|
|
483
|
-
var h=this.tryParseDecimalInteger(Te.EXPECT_PLURAL_ARGUMENT_SELECTOR,Te.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;
|
|
483
|
+
var h=this.tryParseDecimalInteger(Te.EXPECT_PLURAL_ARGUMENT_SELECTOR,Te.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;l=et(u,this.clonePosition()),c=this.message.slice(u.offset,this.offset())}
|
|
484
484
|
// Duplicate selector clauses
|
|
485
|
-
if(
|
|
485
|
+
if(a.has(c))return this.error("select"===t?Te.DUPLICATE_SELECT_ARGUMENT_SELECTOR:Te.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,l);"other"===c&&(o=!0),
|
|
486
486
|
// Parse:
|
|
487
487
|
// one {one apple}
|
|
488
488
|
// ^----------^
|
|
489
|
-
this.bumpSpace();var
|
|
489
|
+
this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?Te.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:Te.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,et(this.clonePosition(),this.clonePosition()));var f=this.parseMessage(e+1,t,n);if(f.err)return f;var m=this.tryParseArgumentClose(p);if(m.err)return m;s.push([c,{value:f.val,location:et(p,this.clonePosition())}]),
|
|
490
490
|
// Keep track of the existing selectors
|
|
491
|
-
|
|
491
|
+
a.add(c),
|
|
492
492
|
// Prep next selector clause.
|
|
493
|
-
this.bumpSpace(),
|
|
493
|
+
this.bumpSpace(),c=(i=this.parseIdentifierIfPossible()).value,l=i.location}return 0===s.length?this.error("select"===t?Te.EXPECT_SELECT_ARGUMENT_SELECTOR:Te.EXPECT_PLURAL_ARGUMENT_SELECTOR,et(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(Te.MISSING_OTHER_CLAUSE,et(this.clonePosition(),this.clonePosition())):{val:s,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var n=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var i=!1,o=0;!this.isEOF();){var s=this.char();if(!(s>=48/* `0` */&&s<=57/* `9` */))break;i=!0,o=10*o+(s-48),this.bump()}var a=et(r,this.clonePosition());return i?at(o*=n)?{val:o,err:null}:this.error(t,a):this.error(e,a)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){
|
|
494
494
|
// This is much faster than `Object.assign` or spread.
|
|
495
495
|
return{offset:this.position.offset,line:this.position.line,column:this.position.column}},
|
|
496
496
|
/**
|
|
497
497
|
* Return the code point at the current position of the parser.
|
|
498
498
|
* Throws if the index is out of bound.
|
|
499
499
|
*/
|
|
500
|
-
e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=
|
|
500
|
+
e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=ft(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}}},
|
|
501
501
|
/** Bump the parser to the next UTF-16 code unit. */
|
|
502
502
|
e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10/* '\n' */===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,
|
|
503
503
|
// 0 ~ 0x10000 -> unicode BMP, otherwise skip the surrogate pair.
|
|
@@ -539,88 +539,88 @@ function Tt(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||
|
|
|
539
539
|
/**
|
|
540
540
|
* Code point equivalent of regex `\p{Pattern_Syntax}`.
|
|
541
541
|
* See https://www.unicode.org/Public/UCD/latest/ucd/PropList.txt
|
|
542
|
-
*/function vt(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
|
|
542
|
+
*/function vt(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 wt(e){e.forEach((function(e){if(delete e.location,Pe(e)||Re(e))for(var t in e.options)delete e.options[t].location,wt(e.options[t].value);else Oe(e)&&xe(e.style)||(Ce(e)||Be(e))&&Ie(e.style)?delete e.style.location:Me(e)&&wt(e.children)}))}function St(e,t){void 0===t&&(t={}),t=Se({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new yt(e,t).parse();if(n.err){var r=SyntaxError(Te[n.err.kind]);
|
|
543
543
|
// @ts-expect-error Assign to error object
|
|
544
544
|
throw r.location=n.err.location,
|
|
545
545
|
// @ts-expect-error Assign to error object
|
|
546
|
-
r.originalMessage=n.err.message,r}return(null==t?void 0:t.captureLocation)||
|
|
546
|
+
r.originalMessage=n.err.message,r}return(null==t?void 0:t.captureLocation)||wt(n.val),n.val}
|
|
547
547
|
|
|
548
548
|
// Main
|
|
549
549
|
|
|
550
|
-
function
|
|
550
|
+
function At(e,t){var n=t&&t.cache?t.cache:Lt,r=t&&t.serializer?t.serializer:Bt;return(t&&t.strategy?t.strategy:Ct)(e,{cache:n,serializer:r})}
|
|
551
551
|
|
|
552
552
|
// Strategy
|
|
553
553
|
|
|
554
|
-
function
|
|
554
|
+
function Ht(e,t,n,r){var i,o=null==(i=r)||"number"==typeof i||"boolean"==typeof i?r:n(r),s=t.get(o);return void 0===s&&(s=e.call(this,r),t.set(o,s)),s}function Nt(e,t,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),o=t.get(i);return void 0===o&&(o=e.apply(this,r),t.set(i,o)),o}function Ot(e,t,n,r,i){return n.bind(t,e,r,i)}function Ct(e,t){return Ot(e,this,1===e.length?Ht:Nt,t.cache.create(),t.serializer)}
|
|
555
555
|
// Serializer
|
|
556
|
-
var
|
|
556
|
+
var Bt=function(){return JSON.stringify(arguments)};
|
|
557
557
|
|
|
558
558
|
// Cache
|
|
559
559
|
|
|
560
|
-
function
|
|
560
|
+
function Pt(){this.cache=Object.create(null)}Pt.prototype.get=function(e){return this.cache[e]},Pt.prototype.set=function(e,t){this.cache[e]=t};var Rt,Lt={create:function(){
|
|
561
561
|
// @ts-ignore
|
|
562
|
-
return new
|
|
562
|
+
return new Pt}},Mt={variadic:function(e,t){return Ot(e,this,Nt,t.cache.create(),t.serializer)},monadic:function(e,t){return Ot(e,this,Ht,t.cache.create(),t.serializer)}};!function(e){
|
|
563
563
|
// When we have a placeholder but no value to format
|
|
564
564
|
e.MISSING_VALUE="MISSING_VALUE",
|
|
565
565
|
// When value supplied is invalid
|
|
566
566
|
e.INVALID_VALUE="INVALID_VALUE",
|
|
567
567
|
// When we need specific Intl API but it's not available
|
|
568
|
-
e.MISSING_INTL_API="MISSING_INTL_API"}(
|
|
568
|
+
e.MISSING_INTL_API="MISSING_INTL_API"}(Rt||(Rt={}));var xt,It=/** @class */function(e){function t(t,n,r){var i=e.call(this,t)||this;return i.code=n,i.originalMessage=r,i}return be(t,e),t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),Dt=/** @class */function(e){function t(t,n,r,i){return e.call(this,'Invalid values for "'.concat(t,'": "').concat(n,'". Options are "').concat(Object.keys(r).join('", "'),'"'),Rt.INVALID_VALUE,i)||this}return be(t,e),t}(It),kt=/** @class */function(e){function t(t,n,r){return e.call(this,'Value for "'.concat(t,'" must be of type ').concat(n),Rt.INVALID_VALUE,r)||this}return be(t,e),t}(It),Ut=/** @class */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,'"'),Rt.MISSING_VALUE,n)||this}return be(t,e),t}(It);function Gt(e){return"function"==typeof e}
|
|
569
569
|
// TODO(skeleton): add skeleton support
|
|
570
|
-
function
|
|
570
|
+
function Ft(e,t,n,r,i,o,
|
|
571
571
|
// For debugging
|
|
572
|
-
|
|
572
|
+
s){
|
|
573
573
|
// Hot path for straight simple msg translations
|
|
574
|
-
if(1===e.length&&
|
|
574
|
+
if(1===e.length&&He(e[0]))return[{type:xt.literal,value:e[0].value}];for(var a=[],c=0,l=e;c<l.length;c++){var u=l[c];
|
|
575
575
|
// Exit early for string parts.
|
|
576
|
-
if(
|
|
576
|
+
if(He(u))a.push({type:xt.literal,value:u.value});else
|
|
577
577
|
// TODO: should this part be literal type?
|
|
578
578
|
// Replace `#` in plural rules with the actual numeric value.
|
|
579
|
-
if(
|
|
579
|
+
if(Le(u))"number"==typeof o&&a.push({type:xt.literal,value:n.getNumberFormat(t).format(o)});else{var h=u.value;
|
|
580
580
|
// Enforce that all required values are provided by the caller.
|
|
581
|
-
if(!i||!(h in i))throw new Ut(h,
|
|
581
|
+
if(!i||!(h in i))throw new Ut(h,s);var p=i[h];if(Ne(u))p&&"string"!=typeof p&&"number"!=typeof p||(p="string"==typeof p||"number"==typeof p?String(p):""),a.push({type:"string"==typeof p?xt.literal:xt.object,value:p});else
|
|
582
582
|
// Recursively format plural and select parts' option — which can be a
|
|
583
583
|
// nested pattern structure. The choosing of the option to use is
|
|
584
584
|
// abstracted-by and delegated-to the part helper object.
|
|
585
|
-
if(
|
|
585
|
+
if(Ce(u)){var f="string"==typeof u.style?r.date[u.style]:Ie(u.style)?u.style.parsedOptions:void 0;a.push({type:xt.literal,value:n.getDateTimeFormat(t,f).format(p)})}else if(Be(u)){f="string"==typeof u.style?r.time[u.style]:Ie(u.style)?u.style.parsedOptions:r.time.medium;a.push({type:xt.literal,value:n.getDateTimeFormat(t,f).format(p)})}else if(Oe(u)){(f="string"==typeof u.style?r.number[u.style]:xe(u.style)?u.style.parsedOptions:void 0)&&f.scale&&(p*=f.scale||1),a.push({type:xt.literal,value:n.getNumberFormat(t,f).format(p)})}else{if(Me(u)){var m=u.children,d=u.value,g=i[d];if(!Gt(g))throw new kt(d,"function",s);var E=g(Ft(m,t,n,r,i,o).map((function(e){return e.value})));Array.isArray(E)||(E=[E]),a.push.apply(a,E.map((function(e){return{type:"string"==typeof e?xt.literal:xt.object,value:e}})))}if(Pe(u)){if(!(y=u.options[p]||u.options.other))throw new Dt(u.value,p,Object.keys(u.options),s);a.push.apply(a,Ft(y.value,t,n,r,i))}else if(Re(u)){var y;if(!(y=u.options["=".concat(p)])){if(!Intl.PluralRules)throw new It('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',Rt.MISSING_INTL_API,s);var b=n.getPluralRules(t,{type:u.pluralType}).select(p-(u.offset||0));y=u.options[b]||u.options.other}if(!y)throw new Dt(u.value,p,Object.keys(u.options),s);a.push.apply(a,Ft(y.value,t,n,r,i,p-(u.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===xt.literal&&t.type===xt.literal?n.value+=t.value:e.push(t),e}),[])}(a)}
|
|
586
586
|
/*
|
|
587
587
|
Copyright (c) 2014, Yahoo! Inc. All rights reserved.
|
|
588
588
|
Copyrights licensed under the New BSD License.
|
|
589
589
|
See the accompanying LICENSE file for terms.
|
|
590
590
|
*/
|
|
591
591
|
// -- MessageFormat --------------------------------------------------------
|
|
592
|
-
function
|
|
592
|
+
function zt(e,t){return t?Object.keys(e).reduce((function(n,r){var i,o;return n[r]=(i=e[r],(o=t[r])?Se(Se(Se({},i||{}),o||{}),Object.keys(i).reduce((function(e,t){return e[t]=Se(Se({},i[t]),o[t]||{}),e}),{})):i),n}),Se({},e)):e}function Zt(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"}(xt||(xt={}));var jt=/** @class */function(){function e(t,n,r,i){var o,s=this;if(void 0===n&&(n=e.defaultLocale),this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(e){var t=s.formatToParts(e);
|
|
593
593
|
// Hot path for straight simple msg translations
|
|
594
|
-
if(1===t.length)return t[0].value;var n=t.reduce((function(e,t){return e.length&&t.type===
|
|
594
|
+
if(1===t.length)return t[0].value;var n=t.reduce((function(e,t){return e.length&&t.type===xt.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 Ft(s.ast,s.locales,s.formatters,s.formats,e,void 0,s.message)},this.resolvedOptions=function(){return{locale:s.resolvedLocale.toString()}},this.getAst=function(){return s.ast},
|
|
595
595
|
// Defined first because it's used to build the format pattern.
|
|
596
596
|
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`");
|
|
597
597
|
// Parse string messages into an AST.
|
|
598
598
|
this.ast=e.__parse(t,{ignoreTag:null==i?void 0:i.ignoreTag,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.");
|
|
599
599
|
// Creates a new object with the specified `formats` merged with the default
|
|
600
600
|
// formats.
|
|
601
|
-
this.formats
|
|
601
|
+
this.formats=zt(e.formats,r),this.formatters=i&&i.formatters||(void 0===(o=this.formatterCache)&&(o={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:At((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,Ae([void 0],t,!1)))}),{cache:Zt(o.number),strategy:Mt.variadic}),getDateTimeFormat:At((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,Ae([void 0],t,!1)))}),{cache:Zt(o.dateTime),strategy:Mt.variadic}),getPluralRules:At((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,Ae([void 0],t,!1)))}),{cache:Zt(o.pluralRules),strategy:Mt.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){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=St,
|
|
602
602
|
// Default format options used as the prototype of the `formats` provided to the
|
|
603
603
|
// constructor. These are used when constructing the internal Intl.NumberFormat
|
|
604
604
|
// and Intl.DateTimeFormat instances.
|
|
605
|
-
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}();const
|
|
605
|
+
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}();const Vt={},Wt=(e,t,n)=>n?(t in Vt||(Vt[t]={}),e in Vt[t]||(Vt[t][e]=n),n):n,_t=(e,t)=>{if(null==t)return;if(t in Vt&&e in Vt[t])return Vt[t][e];const n=wn(t);for(let r=0;r<n.length;r++){const i=Yt(n[r],e);if(i)return Wt(e,t,i)}};let Jt;const Xt=ae({});function qt(e){return e in Jt}function Yt(e,t){if(!qt(e))return null;const n=function(e){return Jt[e]||null}(e);return function(e,t){if(null==t)return;if(t in e)return e[t];const n=t.split(".");let r=e;for(let e=0;e<n.length;e++)if("object"==typeof r){if(e>0){const t=n.slice(e,n.length).join(".");if(t in r){r=r[t];break}}r=r[n[e]]}else r=void 0;return r}(n,t)}function Kt(e,...t){delete Vt[e],Xt.update((n=>(n[e]=Ee.all([n[e]||{},...t]),n)))}ce([Xt],(([e])=>Object.keys(e))),Xt.subscribe((e=>Jt=e));const Qt={};function $t(e){return Qt[e]}function en(e){return null!=e&&wn(e).some((e=>{var t;return null==(t=$t(e))?void 0:t.size}))}function tn(e,t){const n=Promise.all(t.map((t=>(function(e,t){Qt[e].delete(t),0===Qt[e].size&&delete Qt[e]}(e,t),t().then((e=>e.default||e))))));return n.then((t=>Kt(e,...t)))}const nn={};function rn(e){if(!en(e))return e in nn?nn[e]:Promise.resolve();const t=function(e){return wn(e).map((e=>{const t=$t(e);return[e,t?[...t]:[]]})).filter((([,e])=>e.length>0))}(e);return nn[e]=Promise.all(t.map((([e,t])=>tn(e,t)))).then((()=>{if(en(e))return rn(e);delete nn[e]})),nn[e]}var on=Object.getOwnPropertySymbols,sn=Object.prototype.hasOwnProperty,an=Object.prototype.propertyIsEnumerable;function cn({locale:e,id:t}){console.warn(`[svelte-i18n] The message "${t}" was not found in "${wn(e).join('", "')}".${en(Sn())?"\n\nNote: there are at least one loader still registered to this locale that wasn't executed.":""}`)}const ln={fallbackLocale:null,loadingDelay:200,formats:{number:{scientific:{notation:"scientific"},engineering:{notation:"engineering"},compactLong:{notation:"compact",compactDisplay:"long"},compactShort:{notation:"compact",compactDisplay:"short"}},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"}}},warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0};function un(){return ln}const hn=ae(!1);var pn=Object.defineProperty,fn=Object.defineProperties,mn=Object.getOwnPropertyDescriptors,dn=Object.getOwnPropertySymbols,gn=Object.prototype.hasOwnProperty,En=Object.prototype.propertyIsEnumerable,yn=(e,t,n)=>t in e?pn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;let bn;const Tn=ae(null);function vn(e){return e.split("-").map(((e,t,n)=>n.slice(0,t+1).join("-"))).reverse()}function wn(e,t=un().fallbackLocale){const n=vn(e);return t?[...new Set([...n,...vn(t)])]:n}function Sn(){return null!=bn?bn:void 0}Tn.subscribe((e=>{bn=null!=e?e:void 0,"undefined"!=typeof window&&null!=e&&document.documentElement.setAttribute("lang",e)}));const An=(Hn=((e,t)=>{for(var n in t||(t={}))gn.call(t,n)&&yn(e,n,t[n]);if(dn)for(var n of dn(t))En.call(t,n)&&yn(e,n,t[n]);return e})({},Tn),fn(Hn,mn({set:e=>{if(e&&function(e){if(null==e)return;const t=wn(e);for(let e=0;e<t.length;e++){const n=t[e];if(qt(n))return n}}(e)&&en(e)){const{loadingDelay:t}=un();let n;return"undefined"!=typeof window&&null!=Sn()&&t?n=window.setTimeout((()=>hn.set(!0)),t):hn.set(!0),rn(e).then((()=>{Tn.set(e)})).finally((()=>{clearTimeout(n),hn.set(!1)}))}return Tn.set(e)}})));var Hn;const Nn=e=>{const t=Object.create(null);return n=>{const r=JSON.stringify(n);return r in t?t[r]:t[r]=e(n)}};var On=Object.defineProperty,Cn=Object.getOwnPropertySymbols,Bn=Object.prototype.hasOwnProperty,Pn=Object.prototype.propertyIsEnumerable,Rn=(e,t,n)=>t in e?On(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ln=(e,t)=>{for(var n in t||(t={}))Bn.call(t,n)&&Rn(e,n,t[n]);if(Cn)for(var n of Cn(t))Pn.call(t,n)&&Rn(e,n,t[n]);return e},Mn=(e,t)=>{var n={};for(var r in e)Bn.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&Cn)for(var r of Cn(e))t.indexOf(r)<0&&Pn.call(e,r)&&(n[r]=e[r]);return n};const xn=(e,t)=>{const{formats:n}=un();if(e in n&&t in n[e])return n[e][t];throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`)},In=Nn((e=>{var t=e,{locale:n,format:r}=t,i=Mn(t,["locale","format"]);if(null==n)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return r&&(i=xn("number",r)),new Intl.NumberFormat(n,i)})),Dn=Nn((e=>{var t=e,{locale:n,format:r}=t,i=Mn(t,["locale","format"]);if(null==n)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return r?i=xn("date",r):0===Object.keys(i).length&&(i=xn("date","short")),new Intl.DateTimeFormat(n,i)})),kn=Nn((e=>{var t=e,{locale:n,format:r}=t,i=Mn(t,["locale","format"]);if(null==n)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return r?i=xn("time",r):0===Object.keys(i).length&&(i=xn("time","short")),new Intl.DateTimeFormat(n,i)})),Un=Nn((
|
|
606
606
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
607
|
-
(e,t=
|
|
607
|
+
(e,t=Sn())=>new jt(e,t,un().formats,{ignoreTag:un().ignoreTag}))),Gn=(e,t={})=>{var n,r,i,o;let s=t;"object"==typeof e&&(s=e,e=s.id);const{values:a,locale:c=Sn(),default:l}=s;if(null==c)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let u=_t(e,c);if(u){if("string"!=typeof u)return console.warn(`[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof u}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),u}else u=null!=(o=null!=(i=null==(r=(n=un()).handleMissingMessage)?void 0:r.call(n,{locale:c,id:e,defaultValue:l}))?i:l)?o:e;if(!a)return u;let h=u;try{h=Un(u,c).format(a)}catch(t){t instanceof Error&&console.warn(`[svelte-i18n] Message "${e}" has syntax error:`,t.message)}return h},Fn=(e,t)=>((e={})=>{var t=e,{locale:n=Sn()}=t,r=Mn(t,["locale"]);return kn(Ln({locale:n},r))})(t).format(e),zn=(e,t)=>((e={})=>{var t=e,{locale:n=Sn()}=t,r=Mn(t,["locale"]);return Dn(Ln({locale:n},r))})(t).format(e),Zn=(e,t)=>((e={})=>{var t=e,{locale:n=Sn()}=t,r=Mn(t,["locale"]);return In(Ln({locale:n},r))})(t).format(e),jn=(e,t=Sn())=>_t(e,t),Vn=ce([An,Xt],(()=>Gn));function Wn(e,t){Kt(e,t)}ce([An],(()=>Fn)),ce([An],(()=>zn)),ce([An],(()=>Zn)),ce([An,Xt],(()=>jn)),function(e){const t=e,{formats:n}=t,r=((e,t)=>{var n={};for(var r in e)sn.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&on)for(var r of on(e))t.indexOf(r)<0&&an.call(e,r)&&(n[r]=e[r]);return n})(t,["formats"]);let i=e.fallbackLocale;if(e.initialLocale)try{jt.resolveLocale(e.initialLocale)&&(i=e.initialLocale)}catch(t){console.warn(`[svelte-i18n] The initial locale "${e.initialLocale}" is not a valid locale.`)}r.warnOnMissingMessages&&(delete r.warnOnMissingMessages,null==r.handleMissingMessage?r.handleMissingMessage=cn:console.warn('[svelte-i18n] The "warnOnMissingMessages" option is deprecated. Please use the "handleMissingMessage" option instead.')),Object.assign(ln,r,{initialLocale:i}),n&&("number"in n&&Object.assign(ln.formats.number,n.number),"date"in n&&Object.assign(ln.formats.date,n.date),"time"in n&&Object.assign(ln.formats.time,n.time)),An.set(i)}({fallbackLocale:"en"});const _n={en:{sessionExpirationHeader:"Session Warning",sessionExpirationTitle:"Your session is about to expire!",sessionExpirationGeneralText:"Your session will automatically terminate in <b>{second} seconds</b>.",sessionExpirationGeneralButton:"CONTINUE"},tr:{sessionExpirationHeader:"Session Warning",sessionExpirationTitle:"You session is about to expire!",sessionExpirationGeneralText:"Oyun seansınız <b>{second} saniye</b> içinde otomatik olarak sonuçlandırılacaktır",sessionExpirationGeneralButton:"Devam et"}};"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var Jn=function(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&n.path)}},n.exports),n.exports}((function(e,t){
|
|
608
608
|
/*! @license DOMPurify 3.1.6 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.1.6/LICENSE */
|
|
609
|
-
e.exports=function(){const{entries:e,setPrototypeOf:t,isFrozen:n,getPrototypeOf:r,getOwnPropertyDescriptor:i}=Object;let{freeze:o,seal:
|
|
610
|
-
o||(o=function(e){return e}),
|
|
609
|
+
e.exports=function(){const{entries:e,setPrototypeOf:t,isFrozen:n,getPrototypeOf:r,getOwnPropertyDescriptor:i}=Object;let{freeze:o,seal:s,create:a}=Object,{apply:c,construct:l}="undefined"!=typeof Reflect&&Reflect;// eslint-disable-line import/no-mutable-exports
|
|
610
|
+
o||(o=function(e){return e}),s||(s=function(e){return e}),c||(c=function(e,t,n){return e.apply(t,n)}),l||(l=function(e,t){return new e(...t)});const u=w(Array.prototype.forEach),h=w(Array.prototype.pop),p=w(Array.prototype.push),f=w(String.prototype.toLowerCase),m=w(String.prototype.toString),d=w(String.prototype.match),g=w(String.prototype.replace),E=w(String.prototype.indexOf),y=w(String.prototype.trim),b=w(Object.prototype.hasOwnProperty),T=w(RegExp.prototype.test),v=S(TypeError);
|
|
611
611
|
/**
|
|
612
612
|
* Creates a new function that calls the given function with a specified thisArg and arguments.
|
|
613
613
|
*
|
|
614
614
|
* @param {Function} func - The function to be wrapped and called.
|
|
615
615
|
* @returns {Function} A new function that calls the given function with a specified thisArg and arguments.
|
|
616
616
|
*/
|
|
617
|
-
function
|
|
617
|
+
function w(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return c(e,t,r)}}
|
|
618
618
|
/**
|
|
619
619
|
* Creates a new function that constructs an instance of the given constructor function with the provided arguments.
|
|
620
620
|
*
|
|
621
621
|
* @param {Function} func - The constructor function to be wrapped and called.
|
|
622
622
|
* @returns {Function} A new function that constructs an instance of the given constructor function with the provided arguments.
|
|
623
|
-
*/function
|
|
623
|
+
*/function S(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return l(e,n)}}
|
|
624
624
|
/**
|
|
625
625
|
* Add properties to a lookup table
|
|
626
626
|
*
|
|
@@ -628,7 +628,7 @@ function _(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:
|
|
|
628
628
|
* @param {Array} array - The array containing elements to be added to the set.
|
|
629
629
|
* @param {Function} transformCaseFunc - An optional function to transform the case of each element before adding to the set.
|
|
630
630
|
* @returns {Object} The modified set with added elements.
|
|
631
|
-
*/function
|
|
631
|
+
*/function A(e,r){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:f;t&&
|
|
632
632
|
// Make 'in' and truthy checks like Boolean(set.constructor)
|
|
633
633
|
// independent of any properties defined on Object.prototype.
|
|
634
634
|
// Prevent prototype setters from intercepting set as a this value.
|
|
@@ -640,28 +640,28 @@ n(r)||(r[o]=e),t=e)}e[t]=!0}return e}
|
|
|
640
640
|
*
|
|
641
641
|
* @param {Array} array - The array to be cleaned.
|
|
642
642
|
* @returns {Array} The cleaned version of the array
|
|
643
|
-
*/function
|
|
643
|
+
*/function H(e){for(let t=0;t<e.length;t++)b(e,t)||(e[t]=null);return e}
|
|
644
644
|
/**
|
|
645
645
|
* Shallow clone an object
|
|
646
646
|
*
|
|
647
647
|
* @param {Object} object - The object to be cloned.
|
|
648
648
|
* @returns {Object} A new object that copies the original.
|
|
649
|
-
*/function N(t){const n=
|
|
649
|
+
*/function N(t){const n=a(null);for(const[r,i]of e(t))b(t,r)&&(Array.isArray(i)?n[r]=H(i):i&&"object"==typeof i&&i.constructor===Object?n[r]=N(i):n[r]=i);return n}
|
|
650
650
|
/**
|
|
651
651
|
* This method automatically checks if the prop is function or getter and behaves accordingly.
|
|
652
652
|
*
|
|
653
653
|
* @param {Object} object - The object to look up the getter function in its prototype chain.
|
|
654
654
|
* @param {String} prop - The property name for which to find the getter function.
|
|
655
655
|
* @returns {Function} The getter function found in the prototype chain or a fallback function.
|
|
656
|
-
*/function
|
|
656
|
+
*/function O(e,t){for(;null!==e;){const n=i(e,t);if(n){if(n.get)return w(n.get);if("function"==typeof n.value)return w(n.value)}e=r(e)}function n(){return null}return n}const C=o(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),B=o(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),P=o(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),R=o(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),L=o(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),M=o(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),x=o(["#text"]),I=o(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),D=o(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),k=o(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),U=o(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),G=s(/\{\{[\w\W]*|[\w\W]*\}\}/gm),F=s(/<%[\w\W]*|[\w\W]*%>/gm),z=s(/\${[\w\W]*}/gm),Z=s(/^data-[\-\w.\u00B7-\uFFFF]/),j=s(/^aria-[\-\w]+$/),V=s(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),W=s(/^(?:\w+script|data):/i),_=s(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),J=s(/^html$/i),X=s(/^[a-z][.\w]*(-[.\w]+)+$/i);
|
|
657
657
|
// SVG
|
|
658
|
-
var
|
|
658
|
+
var q=Object.freeze({__proto__:null,MUSTACHE_EXPR:G,ERB_EXPR:F,TMPLIT_EXPR:z,DATA_ATTR:Z,ARIA_ATTR:j,IS_ALLOWED_URI:V,IS_SCRIPT_OR_DATA:W,ATTR_WHITESPACE:_,DOCTYPE_NAME:J,CUSTOM_ELEMENT:X});
|
|
659
659
|
// https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeType
|
|
660
|
-
const
|
|
660
|
+
const Y={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,
|
|
661
661
|
// Deprecated
|
|
662
662
|
entityNode:6,
|
|
663
663
|
// Deprecated
|
|
664
|
-
progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},
|
|
664
|
+
progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},K=function(){return"undefined"==typeof window?null:window},Q=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;
|
|
665
665
|
// Allow the callers to control the unique policy name
|
|
666
666
|
// by adding a data-tt-policy-suffix to the script element with the DOMPurify.
|
|
667
667
|
// Policy creation with duplicate names throws in Trusted Types.
|
|
@@ -669,7 +669,7 @@ let n=null;const r="data-tt-policy-suffix";t&&t.hasAttribute(r)&&(n=t.getAttribu
|
|
|
669
669
|
// Policy creation failed (most likely another DOMPurify script has
|
|
670
670
|
// already run). Skip creating the policy, as this will only cause errors
|
|
671
671
|
// if TT are enforced.
|
|
672
|
-
return console.warn("TrustedTypes policy "+i+" could not be created."),null}};function
|
|
672
|
+
return console.warn("TrustedTypes policy "+i+" could not be created."),null}};function $(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:K();const n=e=>$(e)
|
|
673
673
|
/**
|
|
674
674
|
* Version label, exposed for easier checks
|
|
675
675
|
* if DOMPurify is up to date or not
|
|
@@ -678,209 +678,209 @@ return console.warn("TrustedTypes policy "+i+" could not be created."),null}};fu
|
|
|
678
678
|
* Array of elements that DOMPurify removed during sanitation.
|
|
679
679
|
* Empty if nothing was removed.
|
|
680
680
|
*/
|
|
681
|
-
n.removed=[],!t||!t.document||t.document.nodeType!==
|
|
681
|
+
n.removed=[],!t||!t.document||t.document.nodeType!==Y.document)
|
|
682
682
|
// Not running in a browser, provide a factory function
|
|
683
683
|
// so that you can pass your own Window
|
|
684
|
-
return n.isSupported=!1,n;let{document:r}=t;const i=r,
|
|
684
|
+
return n.isSupported=!1,n;let{document:r}=t;const i=r,s=i.currentScript,{DocumentFragment:c,HTMLTemplateElement:l,Node:w,Element:S,NodeFilter:H,NamedNodeMap:G=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:F,DOMParser:z,trustedTypes:Z}=t,j=S.prototype,W=O(j,"cloneNode"),_=O(j,"remove"),X=O(j,"nextSibling"),ee=O(j,"childNodes"),te=O(j,"parentNode");
|
|
685
685
|
// As per issue #47, the web-components registry is inherited by a
|
|
686
686
|
// new document created via createHTMLDocument. As per the spec
|
|
687
687
|
// (http://w3c.github.io/webcomponents/spec/custom/#creating-and-passing-registries)
|
|
688
688
|
// a new empty registry is used when creating a template contents owner
|
|
689
689
|
// document, so we use that as our parent document to ensure nothing
|
|
690
690
|
// is inherited.
|
|
691
|
-
if("function"==typeof
|
|
691
|
+
if("function"==typeof l){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let ne,re="";const{implementation:ie,createNodeIterator:oe,createDocumentFragment:se,getElementsByTagName:ae}=r,{importNode:ce}=i;let le={};
|
|
692
692
|
/**
|
|
693
693
|
* Expose whether this browser supports running the full DOMPurify.
|
|
694
|
-
*/n.isSupported="function"==typeof e&&"function"==typeof te&&ie&&void 0!==ie.createHTMLDocument;const{MUSTACHE_EXPR:ue,ERB_EXPR:he,TMPLIT_EXPR:
|
|
694
|
+
*/n.isSupported="function"==typeof e&&"function"==typeof te&&ie&&void 0!==ie.createHTMLDocument;const{MUSTACHE_EXPR:ue,ERB_EXPR:he,TMPLIT_EXPR:pe,DATA_ATTR:fe,ARIA_ATTR:me,IS_SCRIPT_OR_DATA:de,ATTR_WHITESPACE:ge,CUSTOM_ELEMENT:Ee}=q;let{IS_ALLOWED_URI:ye}=q,be=null;
|
|
695
695
|
/**
|
|
696
696
|
* We consider the elements and attributes below to be safe. Ideally
|
|
697
697
|
* don't add any new ones but feel free to remove unwanted ones.
|
|
698
698
|
*/
|
|
699
|
-
/* allowed element names */const Te=
|
|
700
|
-
/* Allowed attribute names */let ve=null;const
|
|
699
|
+
/* allowed element names */const Te=A({},[...C,...B,...P,...L,...x]);
|
|
700
|
+
/* Allowed attribute names */let ve=null;const we=A({},[...I,...D,...k,...U]);
|
|
701
701
|
/*
|
|
702
702
|
* Configure how DOMPUrify should handle custom elements and their attributes as well as customized built-in elements.
|
|
703
703
|
* @property {RegExp|Function|null} tagNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any custom elements)
|
|
704
704
|
* @property {RegExp|Function|null} attributeNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any attributes not on the allow list)
|
|
705
705
|
* @property {boolean} allowCustomizedBuiltInElements allow custom elements derived from built-ins if they pass CUSTOM_ELEMENT_HANDLING.tagNameCheck. Default: `false`.
|
|
706
|
-
*/let
|
|
707
|
-
/* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */const
|
|
708
|
-
/* Keep element content when removing element? */let
|
|
706
|
+
*/let Se=Object.seal(a(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ae=null,He=null,Ne=!0,Oe=!0,Ce=!1,Be=!0,Pe=!1,Re=!0,Le=!1,Me=!1,xe=!1,Ie=!1,De=!1,ke=!1,Ue=!0,Ge=!1;
|
|
707
|
+
/* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */const Fe="user-content-";
|
|
708
|
+
/* Keep element content when removing element? */let ze=!0,Ze=!1,je={},Ve=null;
|
|
709
709
|
/* If a `Node` is passed to sanitize(), then performs sanitization in-place instead
|
|
710
|
-
* of importing it into a new Document and returning a sanitized copy */const We=
|
|
711
|
-
/* Tags that are safe for data: URIs */let
|
|
712
|
-
/* Attributes safe for values like "javascript:" */let
|
|
710
|
+
* of importing it into a new Document and returning a sanitized copy */const We=A({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);
|
|
711
|
+
/* Tags that are safe for data: URIs */let _e=null;const Je=A({},["audio","video","img","source","image","track"]);
|
|
712
|
+
/* Attributes safe for values like "javascript:" */let Xe=null;const qe=A({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Ye="http://www.w3.org/1998/Math/MathML",Ke="http://www.w3.org/2000/svg",Qe="http://www.w3.org/1999/xhtml";
|
|
713
713
|
/* Document namespace */
|
|
714
|
-
let Qe
|
|
715
|
-
/* Parsing of strict XHTML documents */let rt=null;const it=["application/xhtml+xml","text/html"],ot="text/html";let
|
|
714
|
+
let $e=Qe,et=!1,tt=null;const nt=A({},[Ye,Ke,Qe],m);
|
|
715
|
+
/* Parsing of strict XHTML documents */let rt=null;const it=["application/xhtml+xml","text/html"],ot="text/html";let st=null,at=null;
|
|
716
716
|
/* Keep a reference to config to pass to hooks */
|
|
717
717
|
/* Ideally, do not touch anything below this line */
|
|
718
718
|
/* ______________________________________________ */
|
|
719
|
-
const
|
|
719
|
+
const ct=r.createElement("form"),lt=function(e){return e instanceof RegExp||e instanceof Function},ut=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!at||at!==e){if(
|
|
720
720
|
/* Shield configuration object from tampering */
|
|
721
721
|
e&&"object"==typeof e||(e={})
|
|
722
722
|
/* Shield configuration object from prototype pollution */,e=N(e),rt=
|
|
723
723
|
// eslint-disable-next-line unicorn/prefer-includes
|
|
724
724
|
-1===it.indexOf(e.PARSER_MEDIA_TYPE)?ot:e.PARSER_MEDIA_TYPE,
|
|
725
725
|
// HTML tags and attributes are not case-sensitive, converting to lowercase. Keeping XHTML as is.
|
|
726
|
-
|
|
726
|
+
st="application/xhtml+xml"===rt?m:f,
|
|
727
727
|
/* Set configuration parameters */
|
|
728
|
-
be=b(e,"ALLOWED_TAGS")?
|
|
728
|
+
be=b(e,"ALLOWED_TAGS")?A({},e.ALLOWED_TAGS,st):Te,ve=b(e,"ALLOWED_ATTR")?A({},e.ALLOWED_ATTR,st):we,tt=b(e,"ALLOWED_NAMESPACES")?A({},e.ALLOWED_NAMESPACES,m):nt,Xe=b(e,"ADD_URI_SAFE_ATTR")?A(N(qe),
|
|
729
729
|
// eslint-disable-line indent
|
|
730
730
|
e.ADD_URI_SAFE_ATTR,
|
|
731
731
|
// eslint-disable-line indent
|
|
732
|
-
|
|
732
|
+
st):qe,_e=b(e,"ADD_DATA_URI_TAGS")?A(N(Je),
|
|
733
733
|
// eslint-disable-line indent
|
|
734
734
|
e.ADD_DATA_URI_TAGS,
|
|
735
735
|
// eslint-disable-line indent
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
736
|
+
st):Je,Ve=b(e,"FORBID_CONTENTS")?A({},e.FORBID_CONTENTS,st):We,Ae=b(e,"FORBID_TAGS")?A({},e.FORBID_TAGS,st):{},He=b(e,"FORBID_ATTR")?A({},e.FORBID_ATTR,st):{},je=!!b(e,"USE_PROFILES")&&e.USE_PROFILES,Ne=!1!==e.ALLOW_ARIA_ATTR,// Default true
|
|
737
|
+
Oe=!1!==e.ALLOW_DATA_ATTR,// Default true
|
|
738
|
+
Ce=e.ALLOW_UNKNOWN_PROTOCOLS||!1,// Default false
|
|
739
|
+
Be=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,// Default true
|
|
740
|
+
Pe=e.SAFE_FOR_TEMPLATES||!1,// Default false
|
|
741
|
+
Re=!1!==e.SAFE_FOR_XML,// Default true
|
|
742
|
+
Le=e.WHOLE_DOCUMENT||!1,// Default false
|
|
743
743
|
Ie=e.RETURN_DOM||!1,// Default false
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
744
|
+
De=e.RETURN_DOM_FRAGMENT||!1,// Default false
|
|
745
|
+
ke=e.RETURN_TRUSTED_TYPE||!1,// Default false
|
|
746
|
+
xe=e.FORCE_BODY||!1,// Default false
|
|
747
747
|
Ue=!1!==e.SANITIZE_DOM,// Default true
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
ye=e.ALLOWED_URI_REGEXP||
|
|
752
|
-
/* Parse profile info */,je&&(be=
|
|
753
|
-
/* Merge configuration parameters */,e.ADD_TAGS&&(be===Te&&(be=N(be)),
|
|
754
|
-
/* Add #text in case KEEP_CONTENT is set to true
|
|
755
|
-
/* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */,
|
|
756
|
-
/* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */,be.table&&(
|
|
748
|
+
Ge=e.SANITIZE_NAMED_PROPS||!1,// Default false
|
|
749
|
+
ze=!1!==e.KEEP_CONTENT,// Default true
|
|
750
|
+
Ze=e.IN_PLACE||!1,// Default false
|
|
751
|
+
ye=e.ALLOWED_URI_REGEXP||V,$e=e.NAMESPACE||Qe,Se=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&<(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Se.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&<(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Se.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(Se.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Pe&&(Oe=!1),De&&(Ie=!0)
|
|
752
|
+
/* Parse profile info */,je&&(be=A({},x),ve=[],!0===je.html&&(A(be,C),A(ve,I)),!0===je.svg&&(A(be,B),A(ve,D),A(ve,U)),!0===je.svgFilters&&(A(be,P),A(ve,D),A(ve,U)),!0===je.mathMl&&(A(be,L),A(ve,k),A(ve,U)))
|
|
753
|
+
/* Merge configuration parameters */,e.ADD_TAGS&&(be===Te&&(be=N(be)),A(be,e.ADD_TAGS,st)),e.ADD_ATTR&&(ve===we&&(ve=N(ve)),A(ve,e.ADD_ATTR,st)),e.ADD_URI_SAFE_ATTR&&A(Xe,e.ADD_URI_SAFE_ATTR,st),e.FORBID_CONTENTS&&(Ve===We&&(Ve=N(Ve)),A(Ve,e.FORBID_CONTENTS,st))
|
|
754
|
+
/* Add #text in case KEEP_CONTENT is set to true */,ze&&(be["#text"]=!0)
|
|
755
|
+
/* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */,Le&&A(be,["html","head","body"])
|
|
756
|
+
/* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */,be.table&&(A(be,["tbody"]),delete Ae.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw v('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw v('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
|
|
757
757
|
// Overwrite existing TrustedTypes policy.
|
|
758
758
|
ne=e.TRUSTED_TYPES_POLICY,
|
|
759
759
|
// Sign local variables required by `sanitize`.
|
|
760
760
|
re=ne.createHTML("")}else
|
|
761
761
|
// Uninitialized policy, attempt to initialize the internal dompurify policy.
|
|
762
|
-
void 0===ne&&(ne=
|
|
762
|
+
void 0===ne&&(ne=Q(Z,s)),
|
|
763
763
|
// If creating the internal policy succeeded sign internal variables.
|
|
764
764
|
null!==ne&&"string"==typeof re&&(re=ne.createHTML(""));
|
|
765
765
|
// Prevent further manipulation of configuration.
|
|
766
766
|
// Not available in IE8, Safari 5, etc.
|
|
767
|
-
o&&o(e),
|
|
767
|
+
o&&o(e),at=e}},ht=A({},["mi","mo","mn","ms","mtext"]),pt=A({},["foreignobject","annotation-xml"]),ft=A({},["title","style","font","a","script"]),mt=A({},[...B,...P,...R]),dt=A({},[...L,...M]),gt=function(e){let t=te(e);
|
|
768
768
|
// In JSDOM, if we're inside shadow DOM, then parentNode
|
|
769
769
|
// can be null. We just simulate parent in this case.
|
|
770
|
-
t&&t.tagName||(t={namespaceURI
|
|
770
|
+
t&&t.tagName||(t={namespaceURI:$e,tagName:"template"});const n=f(e.tagName),r=f(t.tagName);return!!tt[e.namespaceURI]&&(e.namespaceURI===Ke?
|
|
771
771
|
// The only way to switch from HTML namespace to SVG
|
|
772
772
|
// is via <svg>. If it happens via any other tag, then
|
|
773
773
|
// it should be killed.
|
|
774
|
-
t.namespaceURI===
|
|
774
|
+
t.namespaceURI===Qe?"svg"===n:
|
|
775
775
|
// The only way to switch from MathML to SVG is via`
|
|
776
776
|
// svg if parent is either <annotation-xml> or MathML
|
|
777
777
|
// text integration points.
|
|
778
|
-
t.namespaceURI===
|
|
778
|
+
t.namespaceURI===Ye?"svg"===n&&("annotation-xml"===r||ht[r]):Boolean(mt[n]):e.namespaceURI===Ye?
|
|
779
779
|
// The only way to switch from HTML namespace to MathML
|
|
780
780
|
// is via <math>. If it happens via any other tag, then
|
|
781
781
|
// it should be killed.
|
|
782
|
-
t.namespaceURI===
|
|
782
|
+
t.namespaceURI===Qe?"math"===n:
|
|
783
783
|
// The only way to switch from SVG to MathML is via
|
|
784
784
|
// <math> and HTML integration points
|
|
785
|
-
t.namespaceURI===
|
|
785
|
+
t.namespaceURI===Ke?"math"===n&&pt[r]:Boolean(dt[n]):e.namespaceURI===Qe?
|
|
786
786
|
// The only way to switch from SVG to HTML is via
|
|
787
787
|
// HTML integration points, and from MathML to HTML
|
|
788
788
|
// is via MathML text integration points
|
|
789
|
-
!(t.namespaceURI===
|
|
789
|
+
!(t.namespaceURI===Ke&&!pt[r])&&!(t.namespaceURI===Ye&&!ht[r])&&!dt[n]&&(ft[n]||!mt[n]):!("application/xhtml+xml"!==rt||!tt[e.namespaceURI]))},Et=function(e){p(n.removed,{element:e});try{
|
|
790
790
|
// eslint-disable-next-line unicorn/prefer-dom-node-remove
|
|
791
|
-
te(e).removeChild(e)}catch(t){
|
|
791
|
+
te(e).removeChild(e)}catch(t){_(e)}},yt=function(e,t){try{p(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){p(n.removed,{attribute:null,from:t})}
|
|
792
792
|
// We void attribute values for unremovable "is"" attributes
|
|
793
|
-
if(t.removeAttribute(e),"is"===e&&!ve[e])if(Ie||
|
|
793
|
+
if(t.removeAttribute(e),"is"===e&&!ve[e])if(Ie||De)try{Et(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},bt=function(e){
|
|
794
794
|
/* Create a HTML document */
|
|
795
|
-
let t=null,n=null;if(
|
|
795
|
+
let t=null,n=null;if(xe)e="<remove></remove>"+e;else{
|
|
796
796
|
/* If FORCE_BODY isn't used, leading whitespace needs to be preserved manually */
|
|
797
|
-
const t=d(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===rt
|
|
797
|
+
const t=d(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===rt&&$e===Qe&&(
|
|
798
798
|
// Root of XHTML doc must contain xmlns declaration (see https://www.w3.org/TR/xhtml1/normative.html#strict)
|
|
799
799
|
e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const i=ne?ne.createHTML(e):e;
|
|
800
800
|
/*
|
|
801
801
|
* Use the DOMParser API by default, fallback later if needs be
|
|
802
802
|
* DOMParser not work for svg when has multiple root element.
|
|
803
|
-
*/if(Qe
|
|
804
|
-
/* Use createHTMLDocument in case DOMParser is not available */if(!t||!t.documentElement){t=ie.createDocument(
|
|
803
|
+
*/if($e===Qe)try{t=(new z).parseFromString(i,rt)}catch(e){}
|
|
804
|
+
/* Use createHTMLDocument in case DOMParser is not available */if(!t||!t.documentElement){t=ie.createDocument($e,"template",null);try{t.documentElement.innerHTML=et?re:i}catch(e){
|
|
805
805
|
// Syntax error if dirtyPayload is invalid xml
|
|
806
806
|
}}const o=t.body||t.documentElement;
|
|
807
807
|
/* Work on whole document or just its body */
|
|
808
|
-
return e&&n&&o.insertBefore(r.createTextNode(n),o.childNodes[0]||null)
|
|
808
|
+
return e&&n&&o.insertBefore(r.createTextNode(n),o.childNodes[0]||null),$e===Qe?ae.call(t,Le?"html":"body")[0]:Le?t.documentElement:o},Tt=function(e){return oe.call(e.ownerDocument||e,e,
|
|
809
809
|
// eslint-disable-next-line no-bitwise
|
|
810
|
-
|
|
810
|
+
H.SHOW_ELEMENT|H.SHOW_COMMENT|H.SHOW_TEXT|H.SHOW_PROCESSING_INSTRUCTION|H.SHOW_CDATA_SECTION,null)},vt=function(e){return e instanceof F&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof G)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes)},wt=function(e){return"function"==typeof w&&e instanceof w},St=function(e,t,r){le[e]&&u(le[e],(e=>{e.call(n,t,r,at)}))},At=function(e){let t=null;
|
|
811
811
|
/* Execute a hook if present */
|
|
812
812
|
/* Check if element is clobbered or can clobber */
|
|
813
|
-
if(
|
|
814
|
-
/* Now let's check the element's type and name */const r=
|
|
813
|
+
if(St("beforeSanitizeElements",e,null),vt(e))return Et(e),!0;
|
|
814
|
+
/* Now let's check the element's type and name */const r=st(e.nodeName);
|
|
815
815
|
/* Execute a hook if present */
|
|
816
816
|
/* Detect mXSS attempts abusing namespace confusion */
|
|
817
|
-
if(
|
|
818
|
-
/* Remove any occurrence of processing instructions */if(e.nodeType===
|
|
819
|
-
/* Remove any kind of possibly harmful comments */if(
|
|
820
|
-
/* Remove element if anything forbids its presence */if(!be[r]||
|
|
817
|
+
if(St("uponSanitizeElement",e,{tagName:r,allowedTags:be}),e.hasChildNodes()&&!wt(e.firstElementChild)&&T(/<[/\w]/g,e.innerHTML)&&T(/<[/\w]/g,e.textContent))return Et(e),!0;
|
|
818
|
+
/* Remove any occurrence of processing instructions */if(e.nodeType===Y.progressingInstruction)return Et(e),!0;
|
|
819
|
+
/* Remove any kind of possibly harmful comments */if(Re&&e.nodeType===Y.comment&&T(/<[/\w]/g,e.data))return Et(e),!0;
|
|
820
|
+
/* Remove element if anything forbids its presence */if(!be[r]||Ae[r]){
|
|
821
821
|
/* Check if we have a custom element to handle */
|
|
822
|
-
if(!
|
|
823
|
-
/* Keep content except for bad-listed elements */if(
|
|
824
|
-
/* Check whether element has a valid namespace */return e instanceof
|
|
822
|
+
if(!Ae[r]&&Nt(r)){if(Se.tagNameCheck instanceof RegExp&&T(Se.tagNameCheck,r))return!1;if(Se.tagNameCheck instanceof Function&&Se.tagNameCheck(r))return!1}
|
|
823
|
+
/* Keep content except for bad-listed elements */if(ze&&!Ve[r]){const t=te(e)||e.parentNode,n=ee(e)||e.childNodes;if(n&&t)for(let r=n.length-1;r>=0;--r){const i=W(n[r],!0);i.__removalCount=(e.__removalCount||0)+1,t.insertBefore(i,X(e))}}return Et(e),!0}
|
|
824
|
+
/* Check whether element has a valid namespace */return e instanceof S&&!gt(e)?(Et(e),!0):
|
|
825
825
|
/* Make sure that older browsers don't get fallback-tag mXSS */
|
|
826
826
|
"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!T(/<\/no(script|embed|frames)/i,e.innerHTML)?(
|
|
827
827
|
/* Sanitize element content to be template-safe */
|
|
828
|
-
|
|
828
|
+
Pe&&e.nodeType===Y.text&&(
|
|
829
829
|
/* Get the element's text content */
|
|
830
|
-
t=e.textContent,u([ue,he,
|
|
831
|
-
/* Execute a hook if present */,
|
|
830
|
+
t=e.textContent,u([ue,he,pe],(e=>{t=g(t,e," ")})),e.textContent!==t&&(p(n.removed,{element:e.cloneNode()}),e.textContent=t))
|
|
831
|
+
/* Execute a hook if present */,St("afterSanitizeElements",e,null),!1):(Et(e),!0)},Ht=function(e,t,n){
|
|
832
832
|
/* Make sure attribute cannot clobber */
|
|
833
|
-
if(Ue&&("id"===t||"name"===t)&&(n in r||n in
|
|
833
|
+
if(Ue&&("id"===t||"name"===t)&&(n in r||n in ct))return!1;
|
|
834
834
|
/* Allow valid data-* attributes: At least one character after "-"
|
|
835
835
|
(https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)
|
|
836
836
|
XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)
|
|
837
|
-
We don't need to check the value; it's always URI safe. */if(He
|
|
837
|
+
We don't need to check the value; it's always URI safe. */if(Oe&&!He[t]&&T(fe,t));else if(Ne&&T(me,t));else if(!ve[t]||He[t]){if(
|
|
838
838
|
// First condition does a very basic check if a) it's basically a valid custom element tagname AND
|
|
839
839
|
// b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
840
840
|
// and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
|
|
841
|
-
!(Nt(e)&&(
|
|
841
|
+
!(Nt(e)&&(Se.tagNameCheck instanceof RegExp&&T(Se.tagNameCheck,e)||Se.tagNameCheck instanceof Function&&Se.tagNameCheck(e))&&(Se.attributeNameCheck instanceof RegExp&&T(Se.attributeNameCheck,t)||Se.attributeNameCheck instanceof Function&&Se.attributeNameCheck(t))||
|
|
842
842
|
// Alternative, second condition checks if it's an `is`-attribute, AND
|
|
843
843
|
// the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
844
|
-
"is"===t&&
|
|
845
|
-
/* Check value is safe. First, is attr inert? If so, is safe */}else if(
|
|
844
|
+
"is"===t&&Se.allowCustomizedBuiltInElements&&(Se.tagNameCheck instanceof RegExp&&T(Se.tagNameCheck,n)||Se.tagNameCheck instanceof Function&&Se.tagNameCheck(n))))return!1;
|
|
845
|
+
/* Check value is safe. First, is attr inert? If so, is safe */}else if(Xe[t]);else if(T(ye,g(n,ge,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==E(n,"data:")||!_e[e])if(Ce&&!T(de,g(n,ge,"")));else if(n)return!1;return!0},Nt=function(e){return"annotation-xml"!==e&&d(e,Ee)},Ot=function(e){
|
|
846
846
|
/* Execute a hook if present */
|
|
847
|
-
|
|
847
|
+
St("beforeSanitizeAttributes",e,null);const{attributes:t}=e;
|
|
848
848
|
/* Check if we have attributes; if not we might have a text node */if(!t)return;const r={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:ve};let i=t.length;
|
|
849
|
-
/* Go backwards over all attributes; safely remove bad ones */for(;i--;){const o=t[i],{name:
|
|
849
|
+
/* Go backwards over all attributes; safely remove bad ones */for(;i--;){const o=t[i],{name:s,namespaceURI:a,value:c}=o,l=st(s);let p="value"===s?c:y(c);
|
|
850
850
|
/* Execute a hook if present */
|
|
851
851
|
/* Work around a security issue with comments inside attributes */
|
|
852
|
-
if(r.attrName=
|
|
853
|
-
|
|
852
|
+
if(r.attrName=l,r.attrValue=p,r.keepAttr=!0,r.forceKeepAttr=void 0,// Allows developers to see this is a property they can set
|
|
853
|
+
St("uponSanitizeAttribute",e,r),p=r.attrValue,Re&&T(/((--!?|])>)|<\/(style|title)/i,p)){yt(s,e);continue}
|
|
854
854
|
/* Did the hooks approve of the attribute? */if(r.forceKeepAttr)continue;
|
|
855
855
|
/* Remove attribute */
|
|
856
856
|
/* Did the hooks approve of the attribute? */
|
|
857
|
-
if(yt(
|
|
858
|
-
/* Work around a security issue in jQuery 3.0 */if(!
|
|
859
|
-
/* Sanitize attribute content to be template-safe */
|
|
860
|
-
/* Is `value` valid for this attribute? */;const
|
|
857
|
+
if(yt(s,e),!r.keepAttr)continue;
|
|
858
|
+
/* Work around a security issue in jQuery 3.0 */if(!Be&&T(/\/>/i,p)){yt(s,e);continue}
|
|
859
|
+
/* Sanitize attribute content to be template-safe */Pe&&u([ue,he,pe],(e=>{p=g(p,e," ")}))
|
|
860
|
+
/* Is `value` valid for this attribute? */;const f=st(e.nodeName);if(Ht(f,l,p)){
|
|
861
861
|
/* Handle attributes that require Trusted Types */
|
|
862
862
|
if(
|
|
863
863
|
/* Full DOM Clobbering protection via namespace isolation,
|
|
864
864
|
* Prefix id and name attributes with `user-content-`
|
|
865
865
|
*/
|
|
866
|
-
!
|
|
866
|
+
!Ge||"id"!==l&&"name"!==l||(
|
|
867
867
|
// Remove the attribute with this value
|
|
868
|
-
yt(
|
|
868
|
+
yt(s,e),
|
|
869
869
|
// Prefix the value and later re-create the attribute with the sanitized value
|
|
870
|
-
|
|
871
|
-
/* Handle invalid data-* attribute set by try-catching it */try{
|
|
870
|
+
p=Fe+p),ne&&"object"==typeof Z&&"function"==typeof Z.getAttributeType)if(a);else switch(Z.getAttributeType(f,l)){case"TrustedHTML":p=ne.createHTML(p);break;case"TrustedScriptURL":p=ne.createScriptURL(p)}
|
|
871
|
+
/* Handle invalid data-* attribute set by try-catching it */try{a?e.setAttributeNS(a,s,p):
|
|
872
872
|
/* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
|
|
873
|
-
e.setAttribute(
|
|
874
|
-
/* Execute a hook if present */
|
|
875
|
-
/* Execute a hook if present */for(
|
|
873
|
+
e.setAttribute(s,p),vt(e)?Et(e):h(n.removed)}catch(e){}}}
|
|
874
|
+
/* Execute a hook if present */St("afterSanitizeAttributes",e,null)},Ct=function e(t){let n=null;const r=Tt(t);
|
|
875
|
+
/* Execute a hook if present */for(St("beforeSanitizeShadowDOM",t,null);n=r.nextNode();)
|
|
876
876
|
/* Execute a hook if present */
|
|
877
|
-
|
|
877
|
+
St("uponSanitizeShadowNode",n,null),
|
|
878
878
|
/* Sanitize tags and elements */
|
|
879
|
-
|
|
879
|
+
At(n)||(
|
|
880
880
|
/* Deep shadow DOM detected */
|
|
881
|
-
n.content instanceof
|
|
882
|
-
/* Check attributes, sanitize if necessary */,
|
|
883
|
-
/* Execute a hook if present */
|
|
881
|
+
n.content instanceof c&&e(n.content)
|
|
882
|
+
/* Check attributes, sanitize if necessary */,Ot(n));
|
|
883
|
+
/* Execute a hook if present */St("afterSanitizeShadowDOM",t,null)};
|
|
884
884
|
/**
|
|
885
885
|
* Sanitize
|
|
886
886
|
* Public method providing core sanitation functionality
|
|
@@ -889,46 +889,46 @@ n.content instanceof l&&e(n.content)
|
|
|
889
889
|
* @param {Object} cfg object
|
|
890
890
|
*/
|
|
891
891
|
// eslint-disable-next-line complexity
|
|
892
|
-
return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,o=null,
|
|
892
|
+
return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,o=null,s=null,a=null;
|
|
893
893
|
/* Stringify, in case dirty is an object */
|
|
894
894
|
if(
|
|
895
895
|
/* Make sure we have a string to sanitize.
|
|
896
896
|
DO NOT return early, as this will return the wrong type if
|
|
897
897
|
the user has requested a DOM object rather than a string */
|
|
898
|
-
et=!e,et&&(e="\x3c!--\x3e"),"string"!=typeof e&&!
|
|
898
|
+
et=!e,et&&(e="\x3c!--\x3e"),"string"!=typeof e&&!wt(e)){if("function"!=typeof e.toString)throw v("toString is not a function");if("string"!=typeof(e=e.toString()))throw v("dirty is not a string, aborting")}
|
|
899
899
|
/* Return dirty HTML if DOMPurify cannot run */if(!n.isSupported)return e;
|
|
900
|
-
/* Assign config vars */if(
|
|
900
|
+
/* Assign config vars */if(Me||ut(t)
|
|
901
901
|
/* Clean up removed elements */,n.removed=[],
|
|
902
902
|
/* Check if dirty is correctly typed for IN_PLACE */
|
|
903
|
-
"string"==typeof e&&(
|
|
903
|
+
"string"==typeof e&&(Ze=!1),Ze){
|
|
904
904
|
/* Do some early pre-sanitization to avoid unsafe root nodes */
|
|
905
|
-
if(e.nodeName){const t=
|
|
905
|
+
if(e.nodeName){const t=st(e.nodeName);if(!be[t]||Ae[t])throw v("root node is forbidden and cannot be sanitized in-place")}}else if(e instanceof w)
|
|
906
906
|
/* If dirty is a DOM element, append to an empty document to avoid
|
|
907
907
|
elements being stripped by the parser */
|
|
908
|
-
r=bt("\x3c!----\x3e"),o=r.ownerDocument.importNode(e,!0),o.nodeType===
|
|
908
|
+
r=bt("\x3c!----\x3e"),o=r.ownerDocument.importNode(e,!0),o.nodeType===Y.element&&"BODY"===o.nodeName||"HTML"===o.nodeName?
|
|
909
909
|
/* Node is already a body, use as is */
|
|
910
910
|
r=o:
|
|
911
911
|
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
912
912
|
r.appendChild(o);else{
|
|
913
913
|
/* Exit directly if we have nothing to do */
|
|
914
|
-
if(!Ie&&!
|
|
914
|
+
if(!Ie&&!Pe&&!Le&&
|
|
915
915
|
// eslint-disable-next-line unicorn/prefer-includes
|
|
916
|
-
-1===e.indexOf("<"))return ne&&
|
|
916
|
+
-1===e.indexOf("<"))return ne&&ke?ne.createHTML(e):e;
|
|
917
917
|
/* Initialize the document to work on */
|
|
918
918
|
/* Check we have a DOM node from the data */
|
|
919
|
-
if(r=bt(e),!r)return Ie?null:
|
|
920
|
-
/* Remove first element node (ours) if FORCE_BODY is set */r&&
|
|
921
|
-
/* Get node iterator */;const
|
|
922
|
-
/* Now start iterating over the created document */for(;
|
|
919
|
+
if(r=bt(e),!r)return Ie?null:ke?re:""}
|
|
920
|
+
/* Remove first element node (ours) if FORCE_BODY is set */r&&xe&&Et(r.firstChild)
|
|
921
|
+
/* Get node iterator */;const l=Tt(Ze?e:r);
|
|
922
|
+
/* Now start iterating over the created document */for(;s=l.nextNode();)
|
|
923
923
|
/* Sanitize tags and elements */
|
|
924
|
-
|
|
924
|
+
At(s)||(
|
|
925
925
|
/* Shadow DOM detected, sanitize it */
|
|
926
|
-
|
|
927
|
-
/* Check attributes, sanitize if necessary */,
|
|
928
|
-
/* If we sanitized `dirty` in-place, return it. */if(
|
|
929
|
-
/* Return sanitized string or DOM */if(Ie){if(
|
|
926
|
+
s.content instanceof c&&Ct(s.content)
|
|
927
|
+
/* Check attributes, sanitize if necessary */,Ot(s));
|
|
928
|
+
/* If we sanitized `dirty` in-place, return it. */if(Ze)return e;
|
|
929
|
+
/* Return sanitized string or DOM */if(Ie){if(De)for(a=se.call(r.ownerDocument);r.firstChild;)
|
|
930
930
|
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
|
931
|
-
|
|
931
|
+
a.appendChild(r.firstChild);else a=r;return(ve.shadowroot||ve.shadowrootmode)&&(
|
|
932
932
|
/*
|
|
933
933
|
AdoptNode() is not used because internal state is not reset
|
|
934
934
|
(e.g. the past names map of a HTMLFormElement), this is safe
|
|
@@ -936,22 +936,22 @@ s.appendChild(r.firstChild);else s=r;return(ve.shadowroot||ve.shadowrootmode)&&(
|
|
|
936
936
|
The state that is cloned by importNode() is explicitly defined
|
|
937
937
|
by the specs.
|
|
938
938
|
*/
|
|
939
|
-
|
|
940
|
-
/* Serialize doctype if allowed */return
|
|
941
|
-
/* Sanitize final string template-safe */,
|
|
939
|
+
a=ce.call(i,a,!0)),a}let h=Le?r.outerHTML:r.innerHTML;
|
|
940
|
+
/* Serialize doctype if allowed */return Le&&be["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&T(J,r.ownerDocument.doctype.name)&&(h="<!DOCTYPE "+r.ownerDocument.doctype.name+">\n"+h)
|
|
941
|
+
/* Sanitize final string template-safe */,Pe&&u([ue,he,pe],(e=>{h=g(h,e," ")})),ne&&ke?ne.createHTML(h):h},
|
|
942
942
|
/**
|
|
943
943
|
* Public method to set the configuration once
|
|
944
944
|
* setConfig
|
|
945
945
|
*
|
|
946
946
|
* @param {Object} cfg configuration object
|
|
947
947
|
*/
|
|
948
|
-
n.setConfig=function(){ut(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),
|
|
948
|
+
n.setConfig=function(){ut(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),Me=!0},
|
|
949
949
|
/**
|
|
950
950
|
* Public method to remove the configuration
|
|
951
951
|
* clearConfig
|
|
952
952
|
*
|
|
953
953
|
*/
|
|
954
|
-
n.clearConfig=function(){
|
|
954
|
+
n.clearConfig=function(){at=null,Me=!1},
|
|
955
955
|
/**
|
|
956
956
|
* Public method to check if an attribute value is valid.
|
|
957
957
|
* Uses last set config, if any. Otherwise, uses config defaults.
|
|
@@ -964,7 +964,7 @@ n.clearConfig=function(){st=null,Re=!1},
|
|
|
964
964
|
*/
|
|
965
965
|
n.isValidAttribute=function(e,t,n){
|
|
966
966
|
/* Initialize shared config vars if necessary. */
|
|
967
|
-
|
|
967
|
+
at||ut({});const r=st(e),i=st(t);return Ht(r,i,n)},
|
|
968
968
|
/**
|
|
969
969
|
* AddHook
|
|
970
970
|
* Public method to add DOMPurify hooks
|
|
@@ -972,7 +972,7 @@ st||ut({});const r=at(e),i=at(t);return St(r,i,n)},
|
|
|
972
972
|
* @param {String} entryPoint entry point for the hook to add
|
|
973
973
|
* @param {Function} hookFunction function to execute
|
|
974
974
|
*/
|
|
975
|
-
n.addHook=function(e,t){"function"==typeof t&&(
|
|
975
|
+
n.addHook=function(e,t){"function"==typeof t&&(le[e]=le[e]||[],p(le[e],t))},
|
|
976
976
|
/**
|
|
977
977
|
* RemoveHook
|
|
978
978
|
* Public method to remove a DOMPurify hook at a given entryPoint
|
|
@@ -981,29 +981,33 @@ n.addHook=function(e,t){"function"==typeof t&&(ce[e]=ce[e]||[],f(ce[e],t))},
|
|
|
981
981
|
* @param {String} entryPoint entry point for the hook to remove
|
|
982
982
|
* @return {Function} removed(popped) hook
|
|
983
983
|
*/
|
|
984
|
-
n.removeHook=function(e){if(
|
|
984
|
+
n.removeHook=function(e){if(le[e])return h(le[e])},
|
|
985
985
|
/**
|
|
986
986
|
* RemoveHooks
|
|
987
987
|
* Public method to remove all DOMPurify hooks at a given entryPoint
|
|
988
988
|
*
|
|
989
989
|
* @param {String} entryPoint entry point for the hooks to remove
|
|
990
990
|
*/
|
|
991
|
-
n.removeHooks=function(e){
|
|
991
|
+
n.removeHooks=function(e){le[e]&&(le[e]=[])},
|
|
992
992
|
/**
|
|
993
993
|
* RemoveAllHooks
|
|
994
994
|
* Public method to remove all DOMPurify hooks
|
|
995
995
|
*/
|
|
996
|
-
n.removeAllHooks=function(){ce={}},n}var ee=Q();return ee}()}));
|
|
997
|
-
/* src/CashierSessionExpirationModal.svelte generated by Svelte v3.59.2 */
|
|
998
|
-
|
|
996
|
+
n.removeAllHooks=function(){le={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ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg4ODg8Ppwr8GI64WNQpoBzwAAAAASUVORK5CYII=";
|
|
997
|
+
/* src/CashierSessionExpirationModal.svelte generated by Svelte v3.59.2 */
|
|
998
|
+
function qn(e){let t,n,r,o,s,a,c,l,u,h,p,f,m,g,E,N,C,B,P,R,L,M,x,I,D,k,U,G=/*$_*/e[7]("sessionExpirationHeader")+"",F=/*$_*/e[7]("sessionExpirationTitle")+"",z=Jn.sanitize(/*$_*/e[7]("sessionExpirationGeneralText",{values:{second:/*timeLeft*/e[6]}}))+"",j=/*$_*/e[7]("sessionExpirationGeneralButton")+"";function V(e,t){/*assetsurl*/
|
|
999
|
+
return e[3]?Kn:Yn}let W=V(e),_=W(e);return{c(){t=T("div"),n=T("div"),r=T("div"),o=T("div"),s=T("div"),a=v(G),c=w(),l=T("div"),u=T("div"),h=T("slot"),_.c(),p=w(),f=T("slot"),m=T("span"),g=v(F),E=w(),N=T("slot"),C=T("span"),B=w(),P=T("div"),R=T("slot"),L=T("span"),M=v(j),A(s,"class","CashierSessionExpirationModalHeaderTitle"),A(o,"class","CashierSessionExpirationModalHeader"),A(h,"name","icon"),A(h,"class","CashierSessionExpirationIcon"),A(f,"name","title"),A(f,"class","CashierSessionExpirationTitle"),A(N,"name","text"),A(N,"class","CashierSessionExpirationText"),A(R,"name","button"),A(P,"class","CashierSessionExpirationButton"),A(u,"class","CashierSessionExpiration"),A(l,"class","CashierSessionExpirationModalContainer"),A(l,"part","CashierSessionExpirationModalContainer"),A(r,"class","CashierSessionExpirationModalWrapper"),A(r,"part","CashierSessionExpirationModalWrapper"),A(n,"class","CashierSessionExpirationModalWindow"),A(n,"part","CashierSessionExpirationModalWindow"),A(n,"id","CashierSessionExpirationModal"),Z((()=>/*div6_elementresize_handler*/e[19].call(n))),A(t,"part","CustomStylingContainer")},m(i,v){y(i,t,v),d(t,n),d(n,r),d(r,o),d(o,s),d(s,a),d(r,c),d(r,l),d(l,u),d(u,h),_.m(h,null),d(u,p),d(u,f),d(f,m),d(m,g),d(u,E),d(u,N),d(N,C),C.innerHTML=z,d(u,B),d(u,P),d(P,R),d(R,L),d(L,M),
|
|
1000
|
+
/*div3_binding*/e[18](u),x=function(e,t){"static"===getComputedStyle(e).position&&(e.style.position="relative");const n=T("iframe");n.setAttribute("style","display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; border: 0; opacity: 0; pointer-events: none; z-index: -1;"),n.setAttribute("aria-hidden","true"),n.tabIndex=-1;const r=O();let i;return r?(n.src="data:text/html,<script>onresize=function(){parent.postMessage(0,'*')}<\/script>",i=S(window,"message",(e=>{e.source===n.contentWindow&&t()}))):(n.src="about:blank",n.onload=()=>{i=S(n.contentWindow,"resize",t),
|
|
999
1001
|
// make sure an initial resize event is fired _after_ the iframe is loaded (which is asynchronous)
|
|
1000
1002
|
// see https://github.com/sveltejs/svelte/issues/4233
|
|
1001
1003
|
t()}),d(e,n),()=>{(r||i&&n.contentWindow)&&i(),b(n)}}(n,/*div6_elementresize_handler*/e[19].bind(n)),
|
|
1002
|
-
/*div7_binding*/e[20](t),
|
|
1003
|
-
/*div3_binding
|
|
1004
|
-
/*div7_binding*/,e[20](null),
|
|
1005
|
-
// (
|
|
1006
|
-
function
|
|
1004
|
+
/*div7_binding*/e[20](t),D=!0,k||(U=[S(P,"click",/*renewSession*/e[8]),S(n,"click",/*outOfModalClick*/e[9])],k=!0)},p(t,n){e=t,(!D||/*$_*/128&n[0])&&G!==(G=/*$_*/e[7]("sessionExpirationHeader")+"")&&H(a,G),W===(W=V(e))&&_?_.p(e,n):(_.d(1),_=W(e),_&&(_.c(),_.m(h,null))),(!D||/*$_*/128&n[0])&&F!==(F=/*$_*/e[7]("sessionExpirationTitle")+"")&&H(g,F),(!D||/*$_, timeLeft*/192&n[0])&&z!==(z=Jn.sanitize(/*$_*/e[7]("sessionExpirationGeneralText",{values:{second:/*timeLeft*/e[6]}}))+"")&&(C.innerHTML=z),(!D||/*$_*/128&n[0])&&j!==(j=/*$_*/e[7]("sessionExpirationGeneralButton")+"")&&H(M,j)},i(t){D||(Z((()=>{D&&(I||(I=ee(n,oe,{duration:/*duration*/e[2]},!0)),I.run(1))})),D=!0)},o(t){I||(I=ee(n,oe,{duration:/*duration*/e[2]},!1)),I.run(0),D=!1},d(n){n&&b(t),_.d(),
|
|
1005
|
+
/*div3_binding*/e[18](null),x(),n&&I&&I.end()
|
|
1006
|
+
/*div7_binding*/,e[20](null),k=!1,i(U)}}}
|
|
1007
|
+
// (160:18) {:else}
|
|
1008
|
+
function Yn(t){let n,r;return{c(){n=T("img"),c(n.src,r=Xn)||A(n,"src",r),A(n,"width","300px"),A(n,"alt","error")},m(e,t){y(e,n,t)},p:e,d(e){e&&b(n)}}}
|
|
1009
|
+
// (158:16) {#if assetsurl}
|
|
1010
|
+
function Kn(e){let t,n;return{c(){t=T("img"),c(t.src,n=`${/*assetsurl*/e[3]}/set-timeout-icon.png`)||A(t,"src",n),A(t,"width","300px"),A(t,"alt","error")},m(e,n){y(e,t,n)},p(e,r){/*assetsurl*/8&r[0]&&!c(t.src,n=`${/*assetsurl*/e[3]}/set-timeout-icon.png`)&&A(t,"src",n)},d(e){e&&b(t)}}}function Qn(t){let n,r,o=/*show*/t[5]&&qn(t);return{c(){o&&o.c(),n=v(""),this.c=e},m(e,t){o&&o.m(e,t),y(e,n,t),r=!0},p(e,t){/*show*/e[5]?o?(o.p(e,t),/*show*/32&t[0]&&K(o,1)):(o=qn(e),o.c(),K(o,1),o.m(n.parentNode,n)):o&&(Y={r:0,c:[],p:Y},Q(o,1,1,(()=>{o=null})),Y.r||i(Y.c),Y=Y.p)},i(e){r||(K(o),r=!0)},o(e){Q(o),r=!1},d(e){o&&o.d(e),e&&b(n)}}}function $n(e,t,n){let r;var i,o;i=Vn,o=e=>n(7,r=e),e.$$.on_destroy.push(l(i,o));let s,a,c,u,h,p,{clientstyling:f=""}=t,{clientstylingurl:m=""}=t,{width:d}=t,{height:g}=t,{duration:E=200}=t,{assetsurl:y=""}=t,{lang:b="en"}=t,{translationurl:T=""}=t,{endpoint:v}=t,{currency:w}=t,{customerid:S}=t,{selectedpaymentmethodname:A}=t,H=!1;const N=e=>{"StartSessionCountdown"===e.data.type&&(p=e.data.xPaymentSessionToken,h=e.data.paymentMethodName,O())},O=()=>{n(5,H=!1);const e=(e=>{try{return JSON.parse(atob(e.split(".")[1]))}catch(e){return null}})(p);e&&(c=null==e?void 0:e.exp,n(6,a=c),u&&clearInterval(u),u=setInterval((()=>{const e=Math.floor((new Date).getTime()/1e3);n(6,a=c-e),a<=90&&n(5,H=!0),e>=c&&(n(6,a=0),n(5,H=!1),clearInterval(u),window.postMessage({type:"SessionExpired"},window.location.href))}),1e3))},C=()=>{const e=new URL(`${v}/v1/player/${S}/payment/GetPaymentMethod`),t=new Headers;t.append("accept","application/json"),t.append("Content-Type","application/json");const n={method:"POST",mode:"cors",headers:t,body:JSON.stringify({PaymentMethodName:h||A,Currency:w,XPaymentSessionToken:p})};fetch(e,n).then((e=>e.json())).then((e=>{p=e.XPaymentSessionToken,O()}))};Object.keys(_n).forEach((e=>{Wn(e,_n[e])}));const B=()=>{var e;e=b,An.set(e)};var P;
|
|
1007
1011
|
/**
|
|
1008
1012
|
* Schedules a callback to run immediately before the component is unmounted.
|
|
1009
1013
|
*
|
|
@@ -1011,5 +1015,5 @@ function Kn(e){let t,n;return{c(){t=T("img"),l(t.src,n=`${/*assetsurl*/e[3]}/set
|
|
|
1011
1015
|
* only one that runs inside a server-side component.
|
|
1012
1016
|
*
|
|
1013
1017
|
* https://svelte.dev/docs#run-time-svelte-ondestroy
|
|
1014
|
-
*/return
|
|
1018
|
+
*/return P=()=>(window.addEventListener("message",N,!1),()=>{window.removeEventListener("message",N)}),I().$$.on_mount.push(P),function(e){I().$$.on_destroy.push(e)}((()=>{clearInterval(u)})),e.$$set=e=>{"clientstyling"in e&&n(10,f=e.clientstyling),"clientstylingurl"in e&&n(11,m=e.clientstylingurl),"width"in e&&n(0,d=e.width),"height"in e&&n(1,g=e.height),"duration"in e&&n(2,E=e.duration),"assetsurl"in e&&n(3,y=e.assetsurl),"lang"in e&&n(12,b=e.lang),"translationurl"in e&&n(13,T=e.translationurl),"endpoint"in e&&n(14,v=e.endpoint),"currency"in e&&n(15,w=e.currency),"customerid"in e&&n(16,S=e.customerid),"selectedpaymentmethodname"in e&&n(17,A=e.selectedpaymentmethodname)},e.$$.update=()=>{/*lang*/4096&e.$$.dirty[0]&&b&&B(),/*clientstyling, customStylingContainer*/1040&e.$$.dirty[0]&&f&&s&&(()=>{let e=document.createElement("style");e.innerHTML=f,s.appendChild(e)})(),/*clientstylingurl, customStylingContainer*/2064&e.$$.dirty[0]&&m&&s&&(()=>{let e=new URL(m),t=document.createElement("style");fetch(e.href).then((e=>e.text())).then((e=>{t.innerHTML=e,setTimeout((()=>{s.appendChild(t)}),1)}))})(),/*translationurl*/8192&e.$$.dirty[0]&&T&&fetch(T).then((e=>e.json())).then((e=>{Object.keys(e).forEach((t=>{Wn(t,e[t])}))})).catch((e=>{console.log(e)}))},[d,g,E,y,s,H,a,r,C,e=>{const t=e.currentTarget;e.target===t&&C()},f,m,b,T,v,w,S,A,function(e){k[e?"unshift":"push"]((()=>{s=e,n(4,s)}))},function(){d=this.clientWidth,g=this.clientHeight,n(0,d),n(1,g)},function(e){k[e?"unshift":"push"]((()=>{s=e,n(4,s)}))}]}class er extends ie{constructor(e){super();const t=document.createElement("style");t.textContent="*,*::before,*::after{margin:0;padding:0;box-sizing:border-box}.CashierSessionExpirationModalWindow{display:flex;position:fixed;align-items:center;justify-content:center;width:100%;height:100%;z-index:101;top:0;left:0;background-color:var(--mmw--color-black-transparency-4, rgba(0, 0, 0, 0.04));container-type:inline-size;container-name:session-expiration-modal-window}.CashierSessionExpirationModalWrapper{background:var(--emw--color-white, #fff);border-radius:var(--emw--border-radius-medium, 4px);width:400px}.CashierSessionExpirationModalHeader{display:flex;align-items:center;position:relative;height:var(--mmw--header-height, 32px);background-color:var(--mmw--color-grey-105, #E8E9EB);width:100%;border-radius:var(--emw--border-radius-medium, 4px) var(--emw--border-radius-medium, 4px) 0 0}.CashierSessionExpirationModalHeaderTitle{display:flex;text-align:center;color:var(--mmw--color-grey-10, #111);font-size:var(--emw--font-size-small, 14px);font-weight:var(--emw--font-weight-semibold, 500);margin:auto;max-width:calc(100% - 150px);overflow:hidden;text-overflow:ellipsis;line-height:calc(var(--emw--font-size-small, 14px) + 2px)}.CashierSessionExpirationModalContainer{padding:var(--emw--spacing-large, 20px)}.CashierSessionExpiration{width:100%;display:flex;flex-direction:column;align-items:center;gap:var(--emw--spacing-large, 20px)}.CashierSessionExpirationTitle{color:var(--emw--color-black, #000);font-weight:var(--emw--font-weight-semibold, 500);font-size:var(--emw--font-size-x-small, 12px);line-height:120%;text-align:center}.CashierSessionExpirationText{color:var(--mmw--color-grey-290, #666);font-weight:var(--emw--font-weight-normal, 400);font-size:var(--emw--font-size-x-small, 12px);line-height:120%;text-align:center}.CashierSessionExpirationButton{display:flex;width:100%;height:36px;flex-direction:column;justify-content:center;flex-shrink:0;color:var(--emw--color-white, #FFF);cursor:pointer;text-align:center;font-size:var(--emw--font-size-x-small, 12px);font-style:normal;font-weight:var(--emw--font-weight-semibold, 500);font-family:inherit;line-height:36px;border-radius:var(--emw--border-radius-medium, 4px);background:var(--emw--color-primary, #7EC51E)}.CashierSessionExpirationButton:hover{background:var(--mmw--color-main-button-hover, #71B11B)}.CashierSessionExpirationButton:active{background:var(--mmw--color-main-button-active, #5C950F)}@container session-expiration-modal-window (max-width:750px){.CashierSessionExpirationModalWindow .CashierSessionExpirationModalWrapper{width:90%;max-width:400px}}",this.shadowRoot.appendChild(t),re(this,{target:this.shadowRoot,props:C(this.attributes),customElement:!0},$n,Qn,s,{clientstyling:10,clientstylingurl:11,width:0,height:1,duration:2,assetsurl:3,lang:12,translationurl:13,endpoint:14,currency:15,customerid:16,selectedpaymentmethodname:17},null,[-1,-1]),e&&(e.target&&y(e.target,this,e.anchor),e.props&&(this.$set(e.props),_()))}static get observedAttributes(){return["clientstyling","clientstylingurl","width","height","duration","assetsurl","lang","translationurl","endpoint","currency","customerid","selectedpaymentmethodname"]}get clientstyling(){return this.$$.ctx[10]}set clientstyling(e){this.$$set({clientstyling:e}),_()}get clientstylingurl(){return this.$$.ctx[11]}set clientstylingurl(e){this.$$set({clientstylingurl:e}),_()}get width(){return this.$$.ctx[0]}set width(e){this.$$set({width:e}),_()}get height(){return this.$$.ctx[1]}set height(e){this.$$set({height:e}),_()}get duration(){return this.$$.ctx[2]}set duration(e){this.$$set({duration:e}),_()}get assetsurl(){return this.$$.ctx[3]}set assetsurl(e){this.$$set({assetsurl:e}),_()}get lang(){return this.$$.ctx[12]}set lang(e){this.$$set({lang:e}),_()}get translationurl(){return this.$$.ctx[13]}set translationurl(e){this.$$set({translationurl:e}),_()}get endpoint(){return this.$$.ctx[14]}set endpoint(e){this.$$set({endpoint:e}),_()}get currency(){return this.$$.ctx[15]}set currency(e){this.$$set({currency:e}),_()}get customerid(){return this.$$.ctx[16]}set customerid(e){this.$$set({customerid:e}),_()}get selectedpaymentmethodname(){return this.$$.ctx[17]}set selectedpaymentmethodname(e){this.$$set({selectedpaymentmethodname:e}),_()}}return!customElements.get("cashier-session-expiration-modal")&&customElements.define("cashier-session-expiration-modal",er),er}));
|
|
1015
1019
|
//# sourceMappingURL=cashier-session-expiration-modal.js.map
|