@everymatrix/player-account-gaming-limits-popup-2 0.0.401 → 0.0.403
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,4 +1,4 @@
|
|
|
1
|
-
!function(e
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).app=e()}(this,(function(){"use strict";function t(){}function e(t){return t()}function n(){return Object.create(null)}function r(t){t.forEach(e)}function i(t){return"function"==typeof t}function o(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function s(e,...n){if(null==e)return t;const r=e.subscribe(...n);return r.unsubscribe?()=>r.unsubscribe():r}function a(t,e){t.appendChild(e)}function u(t,e,n){t.insertBefore(e,n||null)}function l(t){t.parentNode.removeChild(t)}function c(t){return document.createElement(t)}function h(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function p(t){return document.createTextNode(t)}function f(){return p(" ")}function m(t,e,n,r){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)}function g(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function d(t){return""===t?null:+t}function y(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function b(t,e){t.value=null==e?"":e}function E(t,e,n,r){null===n?t.style.removeProperty(e):t.style.setProperty(e,n,r?"important":"")}function v(t,e,n){t.classList[n?"add":"remove"](e)}function T(t){const e={};for(const n of t)e[n.name]=n.value;return e}let P;function B(t){P=t}const H=[],A=[],_=[],L=[],w=Promise.resolve();let S=!1;function I(t){_.push(t)}
|
|
2
2
|
// flush() calls callbacks in this order:
|
|
3
3
|
// 1. All beforeUpdate callbacks, in order: parents before children
|
|
4
4
|
// 2. All bind:this callbacks, in reverse order: children before parents.
|
|
@@ -18,42 +18,42 @@
|
|
|
18
18
|
// callback called a second time; the seen_callbacks set, outside the flush()
|
|
19
19
|
// function, guarantees this behavior.
|
|
20
20
|
const C=new Set;let N=0;// Do *not* move this inside the flush() function
|
|
21
|
-
function M(){const
|
|
21
|
+
function M(){const t=P;do{
|
|
22
22
|
// first, call beforeUpdate functions
|
|
23
23
|
// and update components
|
|
24
|
-
for(;N<H.length;){const
|
|
24
|
+
for(;N<H.length;){const t=H[N];N++,B(t),O(t.$$)}for(B(null),H.length=0,N=0;A.length;)A.pop()();
|
|
25
25
|
// then, once components are updated, call
|
|
26
26
|
// afterUpdate functions. This may cause
|
|
27
27
|
// subsequent updates...
|
|
28
|
-
for(let
|
|
28
|
+
for(let t=0;t<_.length;t+=1){const e=_[t];C.has(e)||(
|
|
29
29
|
// ...so guard against infinite loops
|
|
30
|
-
C.add(
|
|
30
|
+
C.add(e),e())}_.length=0}while(H.length);for(;L.length;)L.pop()();S=!1,C.clear(),B(t)}function O(t){if(null!==t.fragment){t.update(),r(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(I)}}const R=new Set;const D="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function k(t,e){-1===t.$$.dirty[0]&&(H.push(t),S||(S=!0,w.then(M)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function x(o,s,a,u,c,h,p,f=[-1]){const m=P;B(o);const g=o.$$={fragment:null,ctx:null,
|
|
31
31
|
// state
|
|
32
|
-
props:h,update:
|
|
32
|
+
props:h,update:t,not_equal:c,bound:n(),
|
|
33
33
|
// lifecycle
|
|
34
34
|
on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(s.context||(m?m.$$.context:[])),
|
|
35
35
|
// everything else
|
|
36
|
-
callbacks:n(),dirty:f,skip_bound:!1,root:s.target||m.$$.root};p&&p(g.root);let d=!1;if(g.ctx=a?a(o,s.props||{},((e
|
|
36
|
+
callbacks:n(),dirty:f,skip_bound:!1,root:s.target||m.$$.root};p&&p(g.root);let d=!1;if(g.ctx=a?a(o,s.props||{},((t,e,...n)=>{const r=n.length?n[0]:e;return g.ctx&&c(g.ctx[t],g.ctx[t]=r)&&(!g.skip_bound&&g.bound[t]&&g.bound[t](r),d&&k(o,t)),e})):[],g.update(),d=!0,r(g.before_update),
|
|
37
37
|
// `false` as a special case of no DOM component
|
|
38
|
-
g.fragment=!!u&&u(g.ctx),s.target){if(s.hydrate){const
|
|
38
|
+
g.fragment=!!u&&u(g.ctx),s.target){if(s.hydrate){const t=function(t){return Array.from(t.childNodes)}(s.target);
|
|
39
39
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
40
|
-
g.fragment&&g.fragment.l(
|
|
40
|
+
g.fragment&&g.fragment.l(t),t.forEach(l)}else
|
|
41
41
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
42
|
-
g.fragment&&g.fragment.c();s.intro&&((y=o.$$.fragment)&&y.i&&(R.delete(y),y.i(b))),function(
|
|
42
|
+
g.fragment&&g.fragment.c();s.intro&&((y=o.$$.fragment)&&y.i&&(R.delete(y),y.i(b))),function(t,n,o,s){const{fragment:a,on_mount:u,on_destroy:l,after_update:c}=t.$$;a&&a.m(n,o),s||
|
|
43
43
|
// onMount happens before the initial afterUpdate
|
|
44
|
-
I((()=>{const n=u.map(
|
|
44
|
+
I((()=>{const n=u.map(e).filter(i);l?l.push(...n):
|
|
45
45
|
// Edge case - component was destroyed immediately,
|
|
46
46
|
// most likely as a result of a binding initialising
|
|
47
|
-
r(n),
|
|
47
|
+
r(n),t.$$.on_mount=[]})),c.forEach(I)}(o,s.target,s.anchor,s.customElement),M()}var y,b;B(m)}let U;"function"==typeof HTMLElement&&(U=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"})}connectedCallback(){const{on_mount:t}=this.$$;this.$$.on_disconnect=t.map(e).filter(i);
|
|
48
48
|
// @ts-ignore todo: improve typings
|
|
49
|
-
for(const
|
|
49
|
+
for(const t in this.$$.slotted)
|
|
50
50
|
// @ts-ignore todo: improve typings
|
|
51
|
-
this.appendChild(this.$$.slotted[
|
|
51
|
+
this.appendChild(this.$$.slotted[t])}attributeChangedCallback(t,e,n){this[t]=n}disconnectedCallback(){r(this.$$.on_disconnect)}$destroy(){!function(t,e){const n=t.$$;null!==n.fragment&&(r(n.on_destroy),n.fragment&&n.fragment.d(e),
|
|
52
52
|
// TODO null out other refs, including component.$$ (but need to
|
|
53
53
|
// preserve final state?)
|
|
54
|
-
n.on_destroy=n.fragment=null,n.ctx=[])}(this,1),this.$destroy=
|
|
54
|
+
n.on_destroy=n.fragment=null,n.ctx=[])}(this,1),this.$destroy=t}$on(t,e){
|
|
55
55
|
// TODO should this delegate to addEventListener?
|
|
56
|
-
const n=this.$$.callbacks[
|
|
56
|
+
const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){var e;this.$$set&&(e=t,0!==Object.keys(e).length)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}});const G=[];
|
|
57
57
|
/**
|
|
58
58
|
* Creates a `Readable` store that allows reading by subscription.
|
|
59
59
|
* @param value initial value
|
|
@@ -64,119 +64,119 @@ const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{co
|
|
|
64
64
|
* @param {*=}value initial value
|
|
65
65
|
* @param {StartStopNotifier=}start start and stop notifications for subscriptions
|
|
66
66
|
*/
|
|
67
|
-
function
|
|
68
|
-
const
|
|
67
|
+
function $(e,n=t){let r;const i=new Set;function s(t){if(o(e,t)&&(e=t,r)){// store is ready
|
|
68
|
+
const t=!G.length;for(const t of i)t[1](),G.push(t,e);if(t){for(let t=0;t<G.length;t+=2)G[t][0](G[t+1]);G.length=0}}}return{set:s,update:function(t){s(t(e))},subscribe:function(o,a=t){const u=[o,a];return i.add(u),1===i.size&&(r=n(s)||t),o(e),()=>{i.delete(u),0===i.size&&(r(),r=null)}}}}function F(e,n,o){const a=!Array.isArray(e),u=a?[e]:e,l=n.length<2;return c=e=>{let o=!1;const c=[];let h=0,p=t;const f=()=>{if(h)return;p();const r=n(a?c[0]:c,e);l?e(r):p=i(r)?r:t},m=u.map(((t,e)=>s(t,(t=>{c[e]=t,h&=~(1<<e),o&&f()}),(()=>{h|=1<<e}))));return o=!0,f(),function(){r(m),p()}},{subscribe:$(o,c).subscribe};var c}var j=function(t){return function(t){return!!t&&"object"==typeof t}(t)&&!function(t){var e=Object.prototype.toString.call(t);return"[object RegExp]"===e||"[object Date]"===e||function(t){return t.$$typeof===V}(t)}
|
|
69
69
|
// see https://github.com/facebook/react/blob/b5ac963fb791d1298e7f396236383bc955f916c1/src/isomorphic/classic/element/ReactElement.js#L21-L25
|
|
70
|
-
(
|
|
70
|
+
(t)};var V="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function K(t,e){return!1!==e.clone&&e.isMergeableObject(t)?Z((n=t,Array.isArray(n)?[]:{}),t,e):t;var n}function X(t,e,n){return t.concat(e).map((function(t){return K(t,n)}))}function z(t){return Object.keys(t).concat(function(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter((function(e){return t.propertyIsEnumerable(e)})):[]}(t))}function W(t,e){try{return e in t}catch(t){return!1}}
|
|
71
71
|
// Protects from prototype poisoning and unexpected merging up the prototype chain.
|
|
72
|
-
function
|
|
73
|
-
})(
|
|
72
|
+
function Y(t,e,n){var r={};return n.isMergeableObject(t)&&z(t).forEach((function(e){r[e]=K(t[e],n)})),z(e).forEach((function(i){(function(t,e){return W(t,e)&&!(Object.hasOwnProperty.call(t,e)&&Object.propertyIsEnumerable.call(t,e));// and also unsafe if they're nonenumerable.
|
|
73
|
+
})(t,i)||(W(t,i)&&n.isMergeableObject(e[i])?r[i]=function(t,e){if(!e.customMerge)return Z;var n=e.customMerge(t);return"function"==typeof n?n:Z}(i,n)(t[i],e[i],n):r[i]=K(e[i],n))})),r}function Z(t,e,n){(n=n||{}).arrayMerge=n.arrayMerge||X,n.isMergeableObject=n.isMergeableObject||j,
|
|
74
74
|
// cloneUnlessOtherwiseSpecified is added to `options` so that custom arrayMerge()
|
|
75
75
|
// implementations can use it. The caller may not replace it.
|
|
76
|
-
n.cloneUnlessOtherwiseSpecified=
|
|
76
|
+
n.cloneUnlessOtherwiseSpecified=K;var r=Array.isArray(e);return r===Array.isArray(t)?r?n.arrayMerge(t,e,n):Y(t,e,n):K(e,n)}Z.all=function(t,e){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce((function(t,n){return Z(t,n,e)}),{})};var q=Z,Q=function(t,e){return Q=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},Q(t,e)};function J(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}Q(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var tt,et,nt,rt=function(){return rt=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t},rt.apply(this,arguments)};function it(t,e,n){if(n||2===arguments.length)for(var r,i=0,o=e.length;i<o;i++)!r&&i in e||(r||(r=Array.prototype.slice.call(e,0,i)),r[i]=e[i]);return t.concat(r||Array.prototype.slice.call(e))}
|
|
77
77
|
/**
|
|
78
78
|
* Type Guards
|
|
79
79
|
*/
|
|
80
|
-
function
|
|
80
|
+
function ot(t){return t.type===et.literal}function st(t){return t.type===et.argument}function at(t){return t.type===et.number}function ut(t){return t.type===et.date}function lt(t){return t.type===et.time}function ct(t){return t.type===et.select}function ht(t){return t.type===et.plural}function pt(t){return t.type===et.pound}function ft(t){return t.type===et.tag}function mt(t){return!(!t||"object"!=typeof t||t.type!==nt.number)}function gt(t){return!(!t||"object"!=typeof t||t.type!==nt.dateTime)}
|
|
81
81
|
// @generated from regex-gen.ts
|
|
82
|
-
!function(
|
|
82
|
+
!function(t){
|
|
83
83
|
/** Argument is unclosed (e.g. `{0`) */
|
|
84
|
-
|
|
84
|
+
t[t.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",
|
|
85
85
|
/** Argument is empty (e.g. `{}`). */
|
|
86
|
-
|
|
86
|
+
t[t.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",
|
|
87
87
|
/** Argument is malformed (e.g. `{foo!}``) */
|
|
88
|
-
|
|
88
|
+
t[t.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",
|
|
89
89
|
/** Expect an argument type (e.g. `{foo,}`) */
|
|
90
|
-
|
|
90
|
+
t[t.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",
|
|
91
91
|
/** Unsupported argument type (e.g. `{foo,foo}`) */
|
|
92
|
-
|
|
92
|
+
t[t.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",
|
|
93
93
|
/** Expect an argument style (e.g. `{foo, number, }`) */
|
|
94
|
-
|
|
94
|
+
t[t.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",
|
|
95
95
|
/** The number skeleton is invalid. */
|
|
96
|
-
|
|
96
|
+
t[t.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",
|
|
97
97
|
/** The date time skeleton is invalid. */
|
|
98
|
-
|
|
98
|
+
t[t.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",
|
|
99
99
|
/** Exepct a number skeleton following the `::` (e.g. `{foo, number, ::}`) */
|
|
100
|
-
|
|
100
|
+
t[t.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",
|
|
101
101
|
/** Exepct a date time skeleton following the `::` (e.g. `{foo, date, ::}`) */
|
|
102
|
-
|
|
102
|
+
t[t.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",
|
|
103
103
|
/** Unmatched apostrophes in the argument style (e.g. `{foo, number, 'test`) */
|
|
104
|
-
|
|
104
|
+
t[t.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",
|
|
105
105
|
/** Missing select argument options (e.g. `{foo, select}`) */
|
|
106
|
-
|
|
106
|
+
t[t.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",
|
|
107
107
|
/** Expecting an offset value in `plural` or `selectordinal` argument (e.g `{foo, plural, offset}`) */
|
|
108
|
-
|
|
108
|
+
t[t.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",
|
|
109
109
|
/** Offset value in `plural` or `selectordinal` is invalid (e.g. `{foo, plural, offset: x}`) */
|
|
110
|
-
|
|
110
|
+
t[t.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",
|
|
111
111
|
/** Expecting a selector in `select` argument (e.g `{foo, select}`) */
|
|
112
|
-
|
|
112
|
+
t[t.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",
|
|
113
113
|
/** Expecting a selector in `plural` or `selectordinal` argument (e.g `{foo, plural}`) */
|
|
114
|
-
|
|
114
|
+
t[t.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",
|
|
115
115
|
/** Expecting a message fragment after the `select` selector (e.g. `{foo, select, apple}`) */
|
|
116
|
-
|
|
116
|
+
t[t.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",
|
|
117
117
|
/**
|
|
118
118
|
* Expecting a message fragment after the `plural` or `selectordinal` selector
|
|
119
119
|
* (e.g. `{foo, plural, one}`)
|
|
120
120
|
*/
|
|
121
|
-
|
|
121
|
+
t[t.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",
|
|
122
122
|
/** Selector in `plural` or `selectordinal` is malformed (e.g. `{foo, plural, =x {#}}`) */
|
|
123
|
-
|
|
123
|
+
t[t.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",
|
|
124
124
|
/**
|
|
125
125
|
* Duplicate selectors in `plural` or `selectordinal` argument.
|
|
126
126
|
* (e.g. {foo, plural, one {#} one {#}})
|
|
127
127
|
*/
|
|
128
|
-
|
|
128
|
+
t[t.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",
|
|
129
129
|
/** Duplicate selectors in `select` argument.
|
|
130
130
|
* (e.g. {foo, select, apple {apple} apple {apple}})
|
|
131
131
|
*/
|
|
132
|
-
|
|
132
|
+
t[t.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",
|
|
133
133
|
/** Plural or select argument option must have `other` clause. */
|
|
134
|
-
|
|
134
|
+
t[t.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",
|
|
135
135
|
/** The tag is malformed. (e.g. `<bold!>foo</bold!>) */
|
|
136
|
-
|
|
136
|
+
t[t.INVALID_TAG=23]="INVALID_TAG",
|
|
137
137
|
/** The tag name is invalid. (e.g. `<123>foo</123>`) */
|
|
138
|
-
|
|
138
|
+
t[t.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",
|
|
139
139
|
/** The closing tag does not match the opening tag. (e.g. `<bold>foo</italic>`) */
|
|
140
|
-
|
|
140
|
+
t[t.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",
|
|
141
141
|
/** The opening tag has unmatched closing tag. (e.g. `<bold>foo`) */
|
|
142
|
-
|
|
142
|
+
t[t.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(tt||(tt={})),function(t){
|
|
143
143
|
/**
|
|
144
144
|
* Raw text
|
|
145
145
|
*/
|
|
146
|
-
|
|
146
|
+
t[t.literal=0]="literal",
|
|
147
147
|
/**
|
|
148
148
|
* Variable w/o any format, e.g `var` in `this is a {var}`
|
|
149
149
|
*/
|
|
150
|
-
|
|
150
|
+
t[t.argument=1]="argument",
|
|
151
151
|
/**
|
|
152
152
|
* Variable w/ number format
|
|
153
153
|
*/
|
|
154
|
-
|
|
154
|
+
t[t.number=2]="number",
|
|
155
155
|
/**
|
|
156
156
|
* Variable w/ date format
|
|
157
157
|
*/
|
|
158
|
-
|
|
158
|
+
t[t.date=3]="date",
|
|
159
159
|
/**
|
|
160
160
|
* Variable w/ time format
|
|
161
161
|
*/
|
|
162
|
-
|
|
162
|
+
t[t.time=4]="time",
|
|
163
163
|
/**
|
|
164
164
|
* Variable w/ select format
|
|
165
165
|
*/
|
|
166
|
-
|
|
166
|
+
t[t.select=5]="select",
|
|
167
167
|
/**
|
|
168
168
|
* Variable w/ plural format
|
|
169
169
|
*/
|
|
170
|
-
|
|
170
|
+
t[t.plural=6]="plural",
|
|
171
171
|
/**
|
|
172
172
|
* Only possible within plural argument.
|
|
173
173
|
* This is the `#` symbol that will be substituted with the count.
|
|
174
174
|
*/
|
|
175
|
-
|
|
175
|
+
t[t.pound=7]="pound",
|
|
176
176
|
/**
|
|
177
177
|
* XML-like tag
|
|
178
178
|
*/
|
|
179
|
-
|
|
179
|
+
t[t.tag=8]="tag"}(et||(et={})),function(t){t[t.number=0]="number",t[t.dateTime=1]="dateTime"}(nt||(nt={}));var dt=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,yt=/(?:[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;
|
|
180
180
|
/**
|
|
181
181
|
* https://unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
182
182
|
* Credit: https://github.com/caridy/intl-datetimeformat-pattern/blob/master/index.js
|
|
@@ -188,67 +188,67 @@ e[e.tag=8]="tag"}(ee||(ee={})),function(e){e[e.number=0]="number",e[e.dateTime=1
|
|
|
188
188
|
* @public
|
|
189
189
|
* @param skeleton skeleton string
|
|
190
190
|
*/
|
|
191
|
-
function
|
|
191
|
+
function bt(t){var e={};return t.replace(yt,(function(t){var n=t.length;switch(t[0]){
|
|
192
192
|
// Era
|
|
193
|
-
case"G":
|
|
193
|
+
case"G":e.era=4===n?"long":5===n?"narrow":"short";break;
|
|
194
194
|
// Year
|
|
195
|
-
case"y":
|
|
195
|
+
case"y":e.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");
|
|
196
196
|
// Quarter
|
|
197
197
|
case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");
|
|
198
198
|
// Month
|
|
199
|
-
case"M":case"L":
|
|
199
|
+
case"M":case"L":e.month=["numeric","2-digit","short","long","narrow"][n-1];break;
|
|
200
200
|
// Week
|
|
201
|
-
case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":
|
|
201
|
+
case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":e.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");
|
|
202
202
|
// Weekday
|
|
203
|
-
case"E":
|
|
203
|
+
case"E":e.weekday=4===n?"short":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][n-4];break;
|
|
204
204
|
// Period
|
|
205
205
|
case"a":// AM, PM
|
|
206
|
-
|
|
206
|
+
e.hour12=!0;break;case"b":// am, pm, noon, midnight
|
|
207
207
|
case"B":// flexible day periods
|
|
208
208
|
throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");
|
|
209
209
|
// Hour
|
|
210
|
-
case"h":
|
|
210
|
+
case"h":e.hourCycle="h12",e.hour=["numeric","2-digit"][n-1];break;case"H":e.hourCycle="h23",e.hour=["numeric","2-digit"][n-1];break;case"K":e.hourCycle="h11",e.hour=["numeric","2-digit"][n-1];break;case"k":e.hourCycle="h24",e.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");
|
|
211
211
|
// Minute
|
|
212
|
-
case"m":
|
|
212
|
+
case"m":e.minute=["numeric","2-digit"][n-1];break;
|
|
213
213
|
// Second
|
|
214
|
-
case"s":
|
|
214
|
+
case"s":e.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");
|
|
215
215
|
// Zone
|
|
216
216
|
case"z":// 1..3, 4: specific non-location format
|
|
217
|
-
|
|
217
|
+
e.timeZoneName=n<4?"short":"long";break;case"Z":// 1..3, 4, 5: The ISO8601 varios formats
|
|
218
218
|
case"O":// 1, 4: miliseconds in day short, long
|
|
219
219
|
case"v":// 1, 4: generic non-location format
|
|
220
220
|
case"V":// 1, 2, 3, 4: time zone ID or city
|
|
221
221
|
case"X":// 1, 2, 3, 4: The ISO8601 varios formats
|
|
222
222
|
case"x":// 1, 2, 3, 4: The ISO8601 varios formats
|
|
223
|
-
throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),
|
|
223
|
+
throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),e}
|
|
224
224
|
// @generated from regex-gen.ts
|
|
225
|
-
var
|
|
225
|
+
var Et=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;var vt=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,Tt=/^(@+)?(\+|#+)?[rs]?$/g,Pt=/(\*)(0+)|(#+)(0+)|(0+)/g,Bt=/^(0+)$/;function Ht(t){var e={};return"r"===t[t.length-1]?e.roundingPriority="morePrecision":"s"===t[t.length-1]&&(e.roundingPriority="lessPrecision"),t.replace(Tt,(function(t,n,r){
|
|
226
226
|
// @@@ case
|
|
227
|
-
return"string"!=typeof r?(
|
|
227
|
+
return"string"!=typeof r?(e.minimumSignificantDigits=n.length,e.maximumSignificantDigits=n.length):"+"===r?e.minimumSignificantDigits=n.length:"#"===n[0]?e.maximumSignificantDigits=n.length:(e.minimumSignificantDigits=n.length,e.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""})),e}function At(t){switch(t){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 _t(t){
|
|
228
228
|
// Engineering
|
|
229
|
-
var
|
|
229
|
+
var e;if("E"===t[0]&&"E"===t[1]?(e={notation:"engineering"},t=t.slice(2)):"E"===t[0]&&(e={notation:"scientific"},t=t.slice(1)),e){var n=t.slice(0,2);if("+!"===n?(e.signDisplay="always",t=t.slice(2)):"+?"===n&&(e.signDisplay="exceptZero",t=t.slice(2)),!Bt.test(t))throw new Error("Malformed concise eng/scientific notation");e.minimumIntegerDigits=t.length}return e}function Lt(t){var e=At(t);return e||{}}
|
|
230
230
|
/**
|
|
231
231
|
* https://github.com/unicode-org/icu/blob/master/docs/userguide/format_parse/numbers/skeletons.md#skeleton-stems-and-options
|
|
232
|
-
*/function
|
|
232
|
+
*/function wt(t){for(var e={},n=0,r=t;n<r.length;n++){var i=r[n];switch(i.stem){case"percent":case"%":e.style="percent";continue;case"%x100":e.style="percent",e.scale=100;continue;case"currency":e.style="currency",e.currency=i.options[0];continue;case"group-off":case",_":e.useGrouping=!1;continue;case"precision-integer":case".":e.maximumFractionDigits=0;continue;case"measure-unit":case"unit":e.style="unit",e.unit=i.options[0].replace(/^(.*?)-/,"");continue;case"compact-short":case"K":e.notation="compact",e.compactDisplay="short";continue;case"compact-long":case"KK":e.notation="compact",e.compactDisplay="long";continue;case"scientific":e=rt(rt(rt({},e),{notation:"scientific"}),i.options.reduce((function(t,e){return rt(rt({},t),Lt(e))}),{}));continue;case"engineering":e=rt(rt(rt({},e),{notation:"engineering"}),i.options.reduce((function(t,e){return rt(rt({},t),Lt(e))}),{}));continue;case"notation-simple":e.notation="standard";continue;
|
|
233
233
|
// https://github.com/unicode-org/icu/blob/master/icu4c/source/i18n/unicode/unumberformatter.h
|
|
234
|
-
case"unit-width-narrow":
|
|
234
|
+
case"unit-width-narrow":e.currencyDisplay="narrowSymbol",e.unitDisplay="narrow";continue;case"unit-width-short":e.currencyDisplay="code",e.unitDisplay="short";continue;case"unit-width-full-name":e.currencyDisplay="name",e.unitDisplay="long";continue;case"unit-width-iso-code":e.currencyDisplay="symbol";continue;case"scale":e.scale=parseFloat(i.options[0]);continue;
|
|
235
235
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#integer-width
|
|
236
|
-
case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(
|
|
236
|
+
case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(Pt,(function(t,n,r,i,o,s){if(n)e.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}
|
|
237
237
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#integer-width
|
|
238
|
-
if(
|
|
238
|
+
if(Bt.test(i.stem))e.minimumIntegerDigits=i.stem.length;else if(vt.test(i.stem)){
|
|
239
239
|
// Precision
|
|
240
240
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#fraction-precision
|
|
241
241
|
// precision-integer case
|
|
242
|
-
if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(
|
|
242
|
+
if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(vt,(function(t,n,r,i,o,s){
|
|
243
243
|
// .000* case (before ICU67 it was .000+)
|
|
244
|
-
return"*"===r?
|
|
244
|
+
return"*"===r?e.minimumFractionDigits=n.length:i&&"#"===i[0]?e.maximumFractionDigits=i.length:o&&s?(e.minimumFractionDigits=o.length,e.maximumFractionDigits=o.length+s.length):(e.minimumFractionDigits=n.length,e.maximumFractionDigits=n.length),""}));var o=i.options[0];
|
|
245
245
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#trailing-zero-display
|
|
246
|
-
"w"===o?
|
|
246
|
+
"w"===o?e=rt(rt({},e),{trailingZeroDisplay:"stripIfInteger"}):o&&(e=rt(rt({},e),Ht(o)))}
|
|
247
247
|
// https://unicode-org.github.io/icu/userguide/format_parse/numbers/skeletons.html#significant-digits-precision
|
|
248
|
-
else if(
|
|
248
|
+
else if(Tt.test(i.stem))e=rt(rt({},e),Ht(i.stem));else{var s=At(i.stem);s&&(e=rt(rt({},e),s));var a=_t(i.stem);a&&(e=rt(rt({},e),a))}}return e}
|
|
249
249
|
// @generated from time-data-gen.ts
|
|
250
250
|
// prettier-ignore
|
|
251
|
-
var
|
|
251
|
+
var St,It={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"]};
|
|
252
252
|
/**
|
|
253
253
|
* Returns the best matching date time pattern if a date time skeleton
|
|
254
254
|
* pattern is provided with a locale. Follows the Unicode specification:
|
|
@@ -261,45 +261,45 @@ var we,Se={AX:["H"],BQ:["H"],CP:["H"],CZ:["H"],DK:["H"],FI:["H"],ID:["H"],IS:["H
|
|
|
261
261
|
* of the given `locale` to the corresponding time pattern.
|
|
262
262
|
* @param locale
|
|
263
263
|
*/
|
|
264
|
-
function
|
|
264
|
+
function Ct(t){var e=t.hourCycle;if(void 0===e&&
|
|
265
265
|
// @ts-ignore hourCycle(s) is not identified yet
|
|
266
|
-
|
|
266
|
+
t.hourCycles&&
|
|
267
267
|
// @ts-ignore
|
|
268
|
-
|
|
268
|
+
t.hourCycles.length&&(
|
|
269
269
|
// @ts-ignore
|
|
270
|
-
t
|
|
270
|
+
e=t.hourCycles[0]),e)switch(e){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}
|
|
271
271
|
// TODO: Once hourCycle is fully supported remove the following with data generation
|
|
272
|
-
var n,r=
|
|
272
|
+
var n,r=t.language;return"root"!==r&&(n=t.maximize().region),(It[n||""]||It[r||""]||It["".concat(r,"-001")]||It["001"])[0]}var Nt=new RegExp("^".concat(dt.source,"*")),Mt=new RegExp("".concat(dt.source,"*$"));function Ot(t,e){return{start:t,end:e}}
|
|
273
273
|
// #region Ponyfills
|
|
274
274
|
// Consolidate these variables up top for easier toggling during debugging
|
|
275
|
-
var
|
|
275
|
+
var Rt=!!String.prototype.startsWith,Dt=!!String.fromCodePoint,kt=!!Object.fromEntries,xt=!!String.prototype.codePointAt,Ut=!!String.prototype.trimStart,Gt=!!String.prototype.trimEnd,$t=!!Number.isSafeInteger?Number.isSafeInteger:function(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t&&Math.abs(t)<=9007199254740991},Ft=!0;try{
|
|
276
276
|
/**
|
|
277
277
|
* legacy Edge or Xbox One browser
|
|
278
278
|
* Unicode flag support: supported
|
|
279
279
|
* Pattern_Syntax support: not supported
|
|
280
280
|
* See https://github.com/formatjs/formatjs/issues/2822
|
|
281
281
|
*/
|
|
282
|
-
|
|
283
|
-
function(e,
|
|
284
|
-
function(e,
|
|
285
|
-
function(){for(var
|
|
282
|
+
Ft="a"===(null===(St=Zt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===St?void 0:St[0])}catch(t){Ft=!1}var jt,Vt=Rt?// Native
|
|
283
|
+
function(t,e,n){return t.startsWith(e,n)}:// For IE11
|
|
284
|
+
function(t,e,n){return t.slice(n,n+e.length)===e},Kt=Dt?String.fromCodePoint:// IE11
|
|
285
|
+
function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var n,r="",i=t.length,o=0;i>o;){if((n=t[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},Xt=
|
|
286
286
|
// native
|
|
287
|
-
|
|
288
|
-
function(
|
|
289
|
-
function(e
|
|
290
|
-
function(e
|
|
291
|
-
function(
|
|
292
|
-
function(
|
|
293
|
-
function(
|
|
294
|
-
function(
|
|
287
|
+
kt?Object.fromEntries:// Ponyfill
|
|
288
|
+
function(t){for(var e={},n=0,r=t;n<r.length;n++){var i=r[n],o=i[0],s=i[1];e[o]=s}return e},zt=xt?// Native
|
|
289
|
+
function(t,e){return t.codePointAt(e)}:// IE 11
|
|
290
|
+
function(t,e){var n=t.length;if(!(e<0||e>=n)){var r,i=t.charCodeAt(e);return i<55296||i>56319||e+1===n||(r=t.charCodeAt(e+1))<56320||r>57343?i:r-56320+(i-55296<<10)+65536}},Wt=Ut?// Native
|
|
291
|
+
function(t){return t.trimStart()}:// Ponyfill
|
|
292
|
+
function(t){return t.replace(Nt,"")},Yt=Gt?// Native
|
|
293
|
+
function(t){return t.trimEnd()}:// Ponyfill
|
|
294
|
+
function(t){return t.replace(Mt,"")};
|
|
295
295
|
// Prevent minifier to translate new RegExp to literal form that might cause syntax error on IE11.
|
|
296
|
-
function
|
|
296
|
+
function Zt(t,e){return new RegExp(t,e)}
|
|
297
297
|
// #endregion
|
|
298
|
-
if(
|
|
298
|
+
if(Ft){
|
|
299
299
|
// Native
|
|
300
|
-
var
|
|
300
|
+
var qt=Zt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");jt=function(t,e){var n;return qt.lastIndex=e,null!==(n=qt.exec(t)[1])&&void 0!==n?n:""}}else
|
|
301
301
|
// IE11
|
|
302
|
-
|
|
302
|
+
jt=function(t,e){for(var n=[];;){var r=zt(t,e);if(void 0===r||ee(r)||ne(r))break;n.push(r),e+=r>=65536?2:1}return Kt.apply(void 0,n)};var Qt=/** @class */function(){function t(t,e){void 0===e&&(e={}),this.message=t,this.position={offset:0,line:1,column:1},this.ignoreTag=!!e.ignoreTag,this.locale=e.locale,this.requiresOtherClause=!!e.requiresOtherClause,this.shouldParseSkeletons=!!e.shouldParseSkeletons}return t.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},t.prototype.parseMessage=function(t,e,n){for(var r=[];!this.isEOF();){var i=this.char();if(123/* `{` */===i){if((o=this.parseArgument(t,n)).err)return o;r.push(o.val)}else{if(125/* `}` */===i&&t>0)break;if(35/* `#` */!==i||"plural"!==e&&"selectordinal"!==e){if(60/* `<` */===i&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(tt.UNMATCHED_CLOSING_TAG,Ot(this.clonePosition(),this.clonePosition()))}if(60/* `<` */===i&&!this.ignoreTag&&Jt(this.peek()||0)){if((o=this.parseTag(t,e)).err)return o;r.push(o.val)}else{var o;if((o=this.parseLiteral(t,e)).err)return o;r.push(o.val)}}else{var s=this.clonePosition();this.bump(),r.push({type:et.pound,location:Ot(s,this.clonePosition())})}}}return{val:r,err:null}},
|
|
303
303
|
/**
|
|
304
304
|
* A tag name must start with an ASCII lower/upper case letter. The grammar is based on the
|
|
305
305
|
* [custom element name][] except that a dash is NOT always mandatory and uppercase letters
|
|
@@ -318,24 +318,24 @@ $e=function(e,t){for(var n=[];;){var r=Xe(e,t);if(void 0===r||et(r)||tt(r))break
|
|
|
318
318
|
* NOTE: We're a bit more lax here since HTML technically does not allow uppercase HTML element but we do
|
|
319
319
|
* since other tag-based engines like React allow it
|
|
320
320
|
*/
|
|
321
|
-
|
|
321
|
+
t.prototype.parseTag=function(t,e){var n=this.clonePosition();this.bump();// `<`
|
|
322
322
|
var r=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))
|
|
323
323
|
// Self closing tag
|
|
324
|
-
return{val:{type:
|
|
324
|
+
return{val:{type:et.literal,value:"<".concat(r,"/>"),location:Ot(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var i=this.parseMessage(t+1,e,!0);if(i.err)return i;var o=i.val,s=this.clonePosition();
|
|
325
325
|
// Expecting a close tag
|
|
326
|
-
if(this.bumpIf("</")){if(this.isEOF()||!
|
|
326
|
+
if(this.bumpIf("</")){if(this.isEOF()||!Jt(this.char()))return this.error(tt.INVALID_TAG,Ot(s,this.clonePosition()));var a=this.clonePosition();return r!==this.parseTagName()?this.error(tt.UNMATCHED_CLOSING_TAG,Ot(a,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:et.tag,value:r,children:o,location:Ot(n,this.clonePosition())},err:null}:this.error(tt.INVALID_TAG,Ot(s,this.clonePosition())))}return this.error(tt.UNCLOSED_TAG,Ot(n,this.clonePosition()))}return this.error(tt.INVALID_TAG,Ot(n,this.clonePosition()))},
|
|
327
327
|
/**
|
|
328
328
|
* This method assumes that the caller has peeked ahead for the first tag character.
|
|
329
329
|
*/
|
|
330
|
-
|
|
331
|
-
for(this.bump();!this.isEOF()&&
|
|
330
|
+
t.prototype.parseTagName=function(){var t=this.offset();// the first tag name character
|
|
331
|
+
for(this.bump();!this.isEOF()&&te(this.char());)this.bump();return this.message.slice(t,this.offset())},t.prototype.parseLiteral=function(t,e){for(var n=this.clonePosition(),r="";;){var i=this.tryParseQuote(e);if(i)r+=i;else{var o=this.tryParseUnquoted(t,e);if(o)r+=o;else{var s=this.tryParseLeftAngleBracket();if(!s)break;r+=s}}}var a=Ot(n,this.clonePosition());return{val:{type:et.literal,value:r,location:a},err:null}},t.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60/* `<` */!==this.char()||!this.ignoreTag&&(Jt(t=this.peek()||0)||47===t)?null:(this.bump(),"<");var t;
|
|
332
332
|
/** See `parseTag` function docs. */},
|
|
333
333
|
/**
|
|
334
334
|
* Starting with ICU 4.8, an ASCII apostrophe only starts quoted text if it immediately precedes
|
|
335
335
|
* a character that requires quoting (that is, "only where needed"), and works the same in
|
|
336
336
|
* nested messages as on the top level of the pattern. The new behavior is otherwise compatible.
|
|
337
337
|
*/
|
|
338
|
-
|
|
338
|
+
t.prototype.tryParseQuote=function(t){if(this.isEOF()||39/* `'` */!==this.char())return null;
|
|
339
339
|
// Parse escaped char following the apostrophe, or early return if there is no escaped char.
|
|
340
340
|
// Check if is valid escaped character
|
|
341
341
|
switch(this.peek()){case 39/* `'` */:
|
|
@@ -343,74 +343,74 @@ switch(this.peek()){case 39/* `'` */:
|
|
|
343
343
|
return this.bump(),this.bump(),"'";
|
|
344
344
|
// '{', '<', '>', '}'
|
|
345
345
|
case 123:case 60:case 62:case 125:break;case 35:// '#'
|
|
346
|
-
if("plural"===
|
|
347
|
-
var
|
|
346
|
+
if("plural"===t||"selectordinal"===t)break;return null;default:return null}this.bump();// apostrophe
|
|
347
|
+
var e=[this.char()];// escaped char
|
|
348
348
|
// read chars until the optional closing apostrophe is found
|
|
349
349
|
for(this.bump();!this.isEOF();){var n=this.char();if(39/* `'` */===n){if(39/* `'` */!==this.peek()){
|
|
350
350
|
// Optional closing apostrophe.
|
|
351
|
-
this.bump();break}
|
|
351
|
+
this.bump();break}e.push(39),
|
|
352
352
|
// Bump one more time because we need to skip 2 characters.
|
|
353
|
-
this.bump()}else
|
|
354
|
-
this.bumpSpace(),this.isEOF())return this.error(
|
|
353
|
+
this.bump()}else e.push(n);this.bump()}return Kt.apply(void 0,e)},t.prototype.tryParseUnquoted=function(t,e){if(this.isEOF())return null;var n=this.char();return 60/* `<` */===n||123/* `{` */===n||35/* `#` */===n&&("plural"===e||"selectordinal"===e)||125/* `}` */===n&&t>0?null:(this.bump(),Kt(n))},t.prototype.parseArgument=function(t,e){var n=this.clonePosition();if(this.bump(),// `{`
|
|
354
|
+
this.bumpSpace(),this.isEOF())return this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Ot(n,this.clonePosition()));if(125/* `}` */===this.char())return this.bump(),this.error(tt.EMPTY_ARGUMENT,Ot(n,this.clonePosition()));
|
|
355
355
|
// argument name
|
|
356
|
-
var r=this.parseIdentifierIfPossible().value;if(!r)return this.error(
|
|
356
|
+
var r=this.parseIdentifierIfPossible().value;if(!r)return this.error(tt.MALFORMED_ARGUMENT,Ot(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Ot(n,this.clonePosition()));switch(this.char()){
|
|
357
357
|
// Simple argument: `{name}`
|
|
358
358
|
case 125/* `}` */:// `}`
|
|
359
|
-
return this.bump(),{val:{type:
|
|
359
|
+
return this.bump(),{val:{type:et.argument,
|
|
360
360
|
// value does not include the opening and closing braces.
|
|
361
|
-
value:r,location:
|
|
361
|
+
value:r,location:Ot(n,this.clonePosition())},err:null};
|
|
362
362
|
// Argument with options: `{name, format, ...}`
|
|
363
363
|
case 44/* `,` */:return this.bump(),// `,`
|
|
364
|
-
this.bumpSpace(),this.isEOF()?this.error(
|
|
364
|
+
this.bumpSpace(),this.isEOF()?this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Ot(n,this.clonePosition())):this.parseArgumentOptions(t,e,r,n);default:return this.error(tt.MALFORMED_ARGUMENT,Ot(n,this.clonePosition()))}},
|
|
365
365
|
/**
|
|
366
366
|
* Advance the parser until the end of the identifier, if it is currently on
|
|
367
367
|
* an identifier character. Return an empty string otherwise.
|
|
368
368
|
*/
|
|
369
|
-
|
|
369
|
+
t.prototype.parseIdentifierIfPossible=function(){var t=this.clonePosition(),e=this.offset(),n=jt(this.message,e),r=e+n.length;return this.bumpTo(r),{value:n,location:Ot(t,this.clonePosition())}},t.prototype.parseArgumentOptions=function(t,e,n,r){var i,o=this.clonePosition(),s=this.parseIdentifierIfPossible().value,a=this.clonePosition();
|
|
370
370
|
// Parse this range:
|
|
371
371
|
// {name, type, style}
|
|
372
372
|
// ^---^
|
|
373
373
|
switch(s){case"":
|
|
374
374
|
// Expecting a style string number, date, time, plural, selectordinal, or select.
|
|
375
|
-
return this.error(
|
|
375
|
+
return this.error(tt.EXPECT_ARGUMENT_TYPE,Ot(o,a));case"number":case"date":case"time":
|
|
376
376
|
// Parse this range:
|
|
377
377
|
// {name, number, style}
|
|
378
378
|
// ^-------^
|
|
379
|
-
this.bumpSpace();var u=null;if(this.bumpIf(",")){this.bumpSpace();var l=this.clonePosition();if((y=this.parseSimpleArgStyleIfPossible()).err)return y;if(0===(f=
|
|
379
|
+
this.bumpSpace();var u=null;if(this.bumpIf(",")){this.bumpSpace();var l=this.clonePosition();if((y=this.parseSimpleArgStyleIfPossible()).err)return y;if(0===(f=Yt(y.val)).length)return this.error(tt.EXPECT_ARGUMENT_STYLE,Ot(this.clonePosition(),this.clonePosition()));u={style:f,styleLocation:Ot(l,this.clonePosition())}}if((b=this.tryParseArgumentClose(r)).err)return b;var c=Ot(r,this.clonePosition());
|
|
380
380
|
// Extract style or skeleton
|
|
381
|
-
if(u&&
|
|
381
|
+
if(u&&Vt(null==u?void 0:u.style,"::",0)){
|
|
382
382
|
// Skeleton starts with `::`.
|
|
383
|
-
var h=
|
|
383
|
+
var h=Wt(u.style.slice(2));if("number"===s)return(y=this.parseNumberSkeletonFromString(h,u.styleLocation)).err?y:{val:{type:et.number,value:n,location:c,style:y.val},err:null};if(0===h.length)return this.error(tt.EXPECT_DATE_TIME_SKELETON,c);var p=h;
|
|
384
384
|
// Get "best match" pattern only if locale is passed, if not, let it
|
|
385
385
|
// pass as-is where `parseDateTimeSkeleton()` will throw an error
|
|
386
386
|
// for unsupported patterns.
|
|
387
|
-
this.locale&&(p=function(e
|
|
387
|
+
this.locale&&(p=function(t,e){for(var n="",r=0;r<t.length;r++){var i=t.charAt(r);if("j"===i){for(var o=0;r+1<t.length&&t.charAt(r+1)===i;)o++,r++;var s=1+(1&o),a=o<2?1:3+(o>>1),u=Ct(e);for("H"!=u&&"k"!=u||(a=0);a-- >0;)n+="a";for(;s-- >0;)n=u+n}else n+="J"===i?"H":i}return n}(h,this.locale));var f={type:nt.dateTime,pattern:p,location:u.styleLocation,parsedOptions:this.shouldParseSkeletons?bt(p):{}};return{val:{type:"date"===s?et.date:et.time,value:n,location:c,style:f},err:null}}
|
|
388
388
|
// Regular style or no style.
|
|
389
|
-
return{val:{type:"number"===s?
|
|
389
|
+
return{val:{type:"number"===s?et.number:"date"===s?et.date:et.time,value:n,location:c,style:null!==(i=null==u?void 0:u.style)&&void 0!==i?i:null},err:null};case"plural":case"selectordinal":case"select":
|
|
390
390
|
// Parse this range:
|
|
391
391
|
// {name, plural, options}
|
|
392
392
|
// ^---------^
|
|
393
|
-
var m=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(
|
|
393
|
+
var m=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(tt.EXPECT_SELECT_ARGUMENT_OPTIONS,Ot(m,rt({},m)));this.bumpSpace();
|
|
394
394
|
// Parse offset:
|
|
395
395
|
// {name, plural, offset:1, options}
|
|
396
396
|
// ^-----^
|
|
397
397
|
// or the first option:
|
|
398
398
|
// {name, plural, one {...} other {...}}
|
|
399
399
|
// ^--^
|
|
400
|
-
var g=this.parseIdentifierIfPossible(),d=0;if("select"!==s&&"offset"===g.value){if(!this.bumpIf(":"))return this.error(
|
|
400
|
+
var g=this.parseIdentifierIfPossible(),d=0;if("select"!==s&&"offset"===g.value){if(!this.bumpIf(":"))return this.error(tt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,Ot(this.clonePosition(),this.clonePosition()));var y;if(this.bumpSpace(),(y=this.tryParseDecimalInteger(tt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,tt.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return y;
|
|
401
401
|
// Parse another identifier for option parsing
|
|
402
|
-
this.bumpSpace(),g=this.parseIdentifierIfPossible(),d=y.val}var b,E=this.tryParsePluralOrSelectOptions(
|
|
402
|
+
this.bumpSpace(),g=this.parseIdentifierIfPossible(),d=y.val}var b,E=this.tryParsePluralOrSelectOptions(t,s,e,g);if(E.err)return E;if((b=this.tryParseArgumentClose(r)).err)return b;var v=Ot(r,this.clonePosition());return"select"===s?{val:{type:et.select,value:n,options:Xt(E.val),location:v},err:null}:{val:{type:et.plural,value:n,options:Xt(E.val),offset:d,pluralType:"plural"===s?"cardinal":"ordinal",location:v},err:null};default:return this.error(tt.INVALID_ARGUMENT_TYPE,Ot(o,a))}},t.prototype.tryParseArgumentClose=function(t){
|
|
403
403
|
// Parse: {value, number, ::currency/GBP }
|
|
404
|
-
return this.isEOF()||125/* `}` */!==this.char()?this.error(
|
|
404
|
+
return this.isEOF()||125/* `}` */!==this.char()?this.error(tt.EXPECT_ARGUMENT_CLOSING_BRACE,Ot(t,this.clonePosition())):(this.bump(),{val:!0,err:null})},
|
|
405
405
|
/**
|
|
406
406
|
* See: https://github.com/unicode-org/icu/blob/af7ed1f6d2298013dc303628438ec4abe1f16479/icu4c/source/common/messagepattern.cpp#L659
|
|
407
407
|
*/
|
|
408
|
-
|
|
408
|
+
t.prototype.parseSimpleArgStyleIfPossible=function(){for(var t=0,e=this.clonePosition();!this.isEOF();){switch(this.char()){case 39/* `'` */:
|
|
409
409
|
// Treat apostrophe as quoting but include it in the style part.
|
|
410
410
|
// Find the end of the quoted literal text.
|
|
411
|
-
this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(
|
|
411
|
+
this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(tt.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,Ot(n,this.clonePosition()));this.bump();break;case 123/* `{` */:t+=1,this.bump();break;case 125/* `}` */:if(!(t>0))return{val:this.message.slice(e.offset,this.offset()),err:null};t-=1;break;default:this.bump()}}return{val:this.message.slice(e.offset,this.offset()),err:null}},t.prototype.parseNumberSkeletonFromString=function(t,e){var n=[];try{n=function(t){if(0===t.length)throw new Error("Number skeleton cannot be empty");
|
|
412
412
|
// Parse the skeleton
|
|
413
|
-
for(var t
|
|
413
|
+
for(var e=t.split(Et).filter((function(t){return t.length>0})),n=[],r=0,i=e;r<i.length;r++){var o=i[r].split("/");if(0===o.length)throw new Error("Invalid number skeleton");for(var s=o[0],a=o.slice(1),u=0,l=a;u<l.length;u++)if(0===l[u].length)throw new Error("Invalid number skeleton");n.push({stem:s,options:a})}return n}(t)}catch(t){return this.error(tt.INVALID_NUMBER_SKELETON,e)}return{val:{type:nt.number,tokens:n,location:e,parsedOptions:this.shouldParseSkeletons?wt(n):{}},err:null}},
|
|
414
414
|
/**
|
|
415
415
|
* @param nesting_level The current nesting level of messages.
|
|
416
416
|
* This can be positive when parsing message fragment in select or plural argument options.
|
|
@@ -421,139 +421,139 @@ for(var t=e.split(be).filter((function(e){return e.length>0})),n=[],r=0,i=t;r<i.
|
|
|
421
421
|
* between a pair of opening and closing tags. The nested message will not parse beyond
|
|
422
422
|
* the closing tag boundary.
|
|
423
423
|
*/
|
|
424
|
-
|
|
424
|
+
t.prototype.tryParsePluralOrSelectOptions=function(t,e,n,r){
|
|
425
425
|
// Parse:
|
|
426
426
|
// one {one apple}
|
|
427
427
|
// ^--^
|
|
428
|
-
for(var i,o=!1,s=[],a=new Set,u=r.value,l=r.location;;){if(0===u.length){var c=this.clonePosition();if("select"===
|
|
428
|
+
for(var i,o=!1,s=[],a=new Set,u=r.value,l=r.location;;){if(0===u.length){var c=this.clonePosition();if("select"===e||!this.bumpIf("="))break;
|
|
429
429
|
// Try parse `={number}` selector
|
|
430
|
-
var h=this.tryParseDecimalInteger(
|
|
430
|
+
var h=this.tryParseDecimalInteger(tt.EXPECT_PLURAL_ARGUMENT_SELECTOR,tt.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;l=Ot(c,this.clonePosition()),u=this.message.slice(c.offset,this.offset())}
|
|
431
431
|
// Duplicate selector clauses
|
|
432
|
-
if(a.has(u))return this.error("select"===
|
|
432
|
+
if(a.has(u))return this.error("select"===e?tt.DUPLICATE_SELECT_ARGUMENT_SELECTOR:tt.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,l);"other"===u&&(o=!0),
|
|
433
433
|
// Parse:
|
|
434
434
|
// one {one apple}
|
|
435
435
|
// ^----------^
|
|
436
|
-
this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===
|
|
436
|
+
this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===e?tt.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:tt.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,Ot(this.clonePosition(),this.clonePosition()));var f=this.parseMessage(t+1,e,n);if(f.err)return f;var m=this.tryParseArgumentClose(p);if(m.err)return m;s.push([u,{value:f.val,location:Ot(p,this.clonePosition())}]),
|
|
437
437
|
// Keep track of the existing selectors
|
|
438
438
|
a.add(u),
|
|
439
439
|
// Prep next selector clause.
|
|
440
|
-
this.bumpSpace(),u=(i=this.parseIdentifierIfPossible()).value,l=i.location}return 0===s.length?this.error("select"===
|
|
440
|
+
this.bumpSpace(),u=(i=this.parseIdentifierIfPossible()).value,l=i.location}return 0===s.length?this.error("select"===e?tt.EXPECT_SELECT_ARGUMENT_SELECTOR:tt.EXPECT_PLURAL_ARGUMENT_SELECTOR,Ot(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(tt.MISSING_OTHER_CLAUSE,Ot(this.clonePosition(),this.clonePosition())):{val:s,err:null}},t.prototype.tryParseDecimalInteger=function(t,e){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=Ot(r,this.clonePosition());return i?$t(o*=n)?{val:o,err:null}:this.error(e,a):this.error(t,a)},t.prototype.offset=function(){return this.position.offset},t.prototype.isEOF=function(){return this.offset()===this.message.length},t.prototype.clonePosition=function(){
|
|
441
441
|
// This is much faster than `Object.assign` or spread.
|
|
442
442
|
return{offset:this.position.offset,line:this.position.line,column:this.position.column}},
|
|
443
443
|
/**
|
|
444
444
|
* Return the code point at the current position of the parser.
|
|
445
445
|
* Throws if the index is out of bound.
|
|
446
446
|
*/
|
|
447
|
-
|
|
447
|
+
t.prototype.char=function(){var t=this.position.offset;if(t>=this.message.length)throw Error("out of bound");var e=zt(this.message,t);if(void 0===e)throw Error("Offset ".concat(t," is at invalid UTF-16 code unit boundary"));return e},t.prototype.error=function(t,e){return{val:null,err:{kind:t,message:this.message,location:e}}},
|
|
448
448
|
/** Bump the parser to the next UTF-16 code unit. */
|
|
449
|
-
|
|
449
|
+
t.prototype.bump=function(){if(!this.isEOF()){var t=this.char();10/* '\n' */===t?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,
|
|
450
450
|
// 0 ~ 0x10000 -> unicode BMP, otherwise skip the surrogate pair.
|
|
451
|
-
this.position.offset+=
|
|
451
|
+
this.position.offset+=t<65536?1:2)}},
|
|
452
452
|
/**
|
|
453
453
|
* If the substring starting at the current position of the parser has
|
|
454
454
|
* the given prefix, then bump the parser to the character immediately
|
|
455
455
|
* following the prefix and return true. Otherwise, don't bump the parser
|
|
456
456
|
* and return false.
|
|
457
457
|
*/
|
|
458
|
-
|
|
458
|
+
t.prototype.bumpIf=function(t){if(Vt(this.message,t,this.offset())){for(var e=0;e<t.length;e++)this.bump();return!0}return!1},
|
|
459
459
|
/**
|
|
460
460
|
* Bump the parser until the pattern character is found and return `true`.
|
|
461
461
|
* Otherwise bump to the end of the file and return `false`.
|
|
462
462
|
*/
|
|
463
|
-
|
|
463
|
+
t.prototype.bumpUntil=function(t){var e=this.offset(),n=this.message.indexOf(t,e);return n>=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},
|
|
464
464
|
/**
|
|
465
465
|
* Bump the parser to the target offset.
|
|
466
466
|
* If target offset is beyond the end of the input, bump the parser to the end of the input.
|
|
467
467
|
*/
|
|
468
|
-
|
|
468
|
+
t.prototype.bumpTo=function(t){if(this.offset()>t)throw Error("targetOffset ".concat(t," must be greater than or equal to the current offset ").concat(this.offset()));for(t=Math.min(t,this.message.length);;){var e=this.offset();if(e===t)break;if(e>t)throw Error("targetOffset ".concat(t," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},
|
|
469
469
|
/** advance the parser through all whitespace to the next non-whitespace code unit. */
|
|
470
|
-
|
|
470
|
+
t.prototype.bumpSpace=function(){for(;!this.isEOF()&&ee(this.char());)this.bump()},
|
|
471
471
|
/**
|
|
472
472
|
* Peek at the *next* Unicode codepoint in the input without advancing the parser.
|
|
473
473
|
* If the input has been exhausted, then this returns null.
|
|
474
474
|
*/
|
|
475
|
-
|
|
475
|
+
t.prototype.peek=function(){if(this.isEOF())return null;var t=this.char(),e=this.offset(),n=this.message.charCodeAt(e+(t>=65536?2:1));return null!=n?n:null},t}();
|
|
476
476
|
/**
|
|
477
477
|
* This check if codepoint is alphabet (lower & uppercase)
|
|
478
478
|
* @param codepoint
|
|
479
479
|
* @returns
|
|
480
|
-
*/function
|
|
480
|
+
*/function Jt(t){return t>=97&&t<=122||t>=65&&t<=90}function te(t){return 45/* '-' */===t||46/* '.' */===t||t>=48&&t<=57/* 0..9 */||95/* '_' */===t||t>=97&&t<=122/** a..z */||t>=65&&t<=90/* A..Z */||183==t||t>=192&&t<=214||t>=216&&t<=246||t>=248&&t<=893||t>=895&&t<=8191||t>=8204&&t<=8205||t>=8255&&t<=8256||t>=8304&&t<=8591||t>=11264&&t<=12271||t>=12289&&t<=55295||t>=63744&&t<=64975||t>=65008&&t<=65533||t>=65536&&t<=983039}
|
|
481
481
|
/**
|
|
482
482
|
* Code point equivalent of regex `\p{White_Space}`.
|
|
483
483
|
* From: https://www.unicode.org/Public/UCD/latest/ucd/PropList.txt
|
|
484
|
-
*/function
|
|
484
|
+
*/function ee(t){return t>=9&&t<=13||32===t||133===t||t>=8206&&t<=8207||8232===t||8233===t}
|
|
485
485
|
/**
|
|
486
486
|
* Code point equivalent of regex `\p{Pattern_Syntax}`.
|
|
487
487
|
* See https://www.unicode.org/Public/UCD/latest/ucd/PropList.txt
|
|
488
|
-
*/function
|
|
488
|
+
*/function ne(t){return t>=33&&t<=35||36===t||t>=37&&t<=39||40===t||41===t||42===t||43===t||44===t||45===t||t>=46&&t<=47||t>=58&&t<=59||t>=60&&t<=62||t>=63&&t<=64||91===t||92===t||93===t||94===t||96===t||123===t||124===t||125===t||126===t||161===t||t>=162&&t<=165||166===t||167===t||169===t||171===t||172===t||174===t||176===t||177===t||182===t||187===t||191===t||215===t||247===t||t>=8208&&t<=8213||t>=8214&&t<=8215||8216===t||8217===t||8218===t||t>=8219&&t<=8220||8221===t||8222===t||8223===t||t>=8224&&t<=8231||t>=8240&&t<=8248||8249===t||8250===t||t>=8251&&t<=8254||t>=8257&&t<=8259||8260===t||8261===t||8262===t||t>=8263&&t<=8273||8274===t||8275===t||t>=8277&&t<=8286||t>=8592&&t<=8596||t>=8597&&t<=8601||t>=8602&&t<=8603||t>=8604&&t<=8607||8608===t||t>=8609&&t<=8610||8611===t||t>=8612&&t<=8613||8614===t||t>=8615&&t<=8621||8622===t||t>=8623&&t<=8653||t>=8654&&t<=8655||t>=8656&&t<=8657||8658===t||8659===t||8660===t||t>=8661&&t<=8691||t>=8692&&t<=8959||t>=8960&&t<=8967||8968===t||8969===t||8970===t||8971===t||t>=8972&&t<=8991||t>=8992&&t<=8993||t>=8994&&t<=9e3||9001===t||9002===t||t>=9003&&t<=9083||9084===t||t>=9085&&t<=9114||t>=9115&&t<=9139||t>=9140&&t<=9179||t>=9180&&t<=9185||t>=9186&&t<=9254||t>=9255&&t<=9279||t>=9280&&t<=9290||t>=9291&&t<=9311||t>=9472&&t<=9654||9655===t||t>=9656&&t<=9664||9665===t||t>=9666&&t<=9719||t>=9720&&t<=9727||t>=9728&&t<=9838||9839===t||t>=9840&&t<=10087||10088===t||10089===t||10090===t||10091===t||10092===t||10093===t||10094===t||10095===t||10096===t||10097===t||10098===t||10099===t||10100===t||10101===t||t>=10132&&t<=10175||t>=10176&&t<=10180||10181===t||10182===t||t>=10183&&t<=10213||10214===t||10215===t||10216===t||10217===t||10218===t||10219===t||10220===t||10221===t||10222===t||10223===t||t>=10224&&t<=10239||t>=10240&&t<=10495||t>=10496&&t<=10626||10627===t||10628===t||10629===t||10630===t||10631===t||10632===t||10633===t||10634===t||10635===t||10636===t||10637===t||10638===t||10639===t||10640===t||10641===t||10642===t||10643===t||10644===t||10645===t||10646===t||10647===t||10648===t||t>=10649&&t<=10711||10712===t||10713===t||10714===t||10715===t||t>=10716&&t<=10747||10748===t||10749===t||t>=10750&&t<=11007||t>=11008&&t<=11055||t>=11056&&t<=11076||t>=11077&&t<=11078||t>=11079&&t<=11084||t>=11085&&t<=11123||t>=11124&&t<=11125||t>=11126&&t<=11157||11158===t||t>=11159&&t<=11263||t>=11776&&t<=11777||11778===t||11779===t||11780===t||11781===t||t>=11782&&t<=11784||11785===t||11786===t||11787===t||11788===t||11789===t||t>=11790&&t<=11798||11799===t||t>=11800&&t<=11801||11802===t||11803===t||11804===t||11805===t||t>=11806&&t<=11807||11808===t||11809===t||11810===t||11811===t||11812===t||11813===t||11814===t||11815===t||11816===t||11817===t||t>=11818&&t<=11822||11823===t||t>=11824&&t<=11833||t>=11834&&t<=11835||t>=11836&&t<=11839||11840===t||11841===t||11842===t||t>=11843&&t<=11855||t>=11856&&t<=11857||11858===t||t>=11859&&t<=11903||t>=12289&&t<=12291||12296===t||12297===t||12298===t||12299===t||12300===t||12301===t||12302===t||12303===t||12304===t||12305===t||t>=12306&&t<=12307||12308===t||12309===t||12310===t||12311===t||12312===t||12313===t||12314===t||12315===t||12316===t||12317===t||t>=12318&&t<=12319||12320===t||12336===t||64830===t||64831===t||t>=65093&&t<=65094}function re(t){t.forEach((function(t){if(delete t.location,ct(t)||ht(t))for(var e in t.options)delete t.options[e].location,re(t.options[e].value);else at(t)&&mt(t.style)||(ut(t)||lt(t))&>(t.style)?delete t.style.location:ft(t)&&re(t.children)}))}function ie(t,e){void 0===e&&(e={}),e=rt({shouldParseSkeletons:!0,requiresOtherClause:!0},e);var n=new Qt(t,e).parse();if(n.err){var r=SyntaxError(tt[n.err.kind]);
|
|
489
489
|
// @ts-expect-error Assign to error object
|
|
490
490
|
throw r.location=n.err.location,
|
|
491
491
|
// @ts-expect-error Assign to error object
|
|
492
|
-
r.originalMessage=n.err.message,r}return(null==
|
|
492
|
+
r.originalMessage=n.err.message,r}return(null==e?void 0:e.captureLocation)||re(n.val),n.val}
|
|
493
493
|
|
|
494
494
|
// Main
|
|
495
495
|
|
|
496
|
-
function
|
|
496
|
+
function oe(t,e){var n=e&&e.cache?e.cache:fe,r=e&&e.serializer?e.serializer:ce;return(e&&e.strategy?e.strategy:le)(t,{cache:n,serializer:r})}
|
|
497
497
|
|
|
498
498
|
// Strategy
|
|
499
499
|
|
|
500
|
-
function
|
|
500
|
+
function se(t,e,n,r){var i,o=null==(i=r)||"number"==typeof i||"boolean"==typeof i?r:n(r),s=e.get(o);return void 0===s&&(s=t.call(this,r),e.set(o,s)),s}function ae(t,e,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),o=e.get(i);return void 0===o&&(o=t.apply(this,r),e.set(i,o)),o}function ue(t,e,n,r,i){return n.bind(e,t,r,i)}function le(t,e){return ue(t,this,1===t.length?se:ae,e.cache.create(),e.serializer)}
|
|
501
501
|
// Serializer
|
|
502
|
-
var
|
|
502
|
+
var ce=function(){return JSON.stringify(arguments)};
|
|
503
503
|
|
|
504
504
|
// Cache
|
|
505
505
|
|
|
506
|
-
function
|
|
506
|
+
function he(){this.cache=Object.create(null)}he.prototype.get=function(t){return this.cache[t]},he.prototype.set=function(t,e){this.cache[t]=e};var pe,fe={create:function(){
|
|
507
507
|
// @ts-ignore
|
|
508
|
-
return new
|
|
508
|
+
return new he}},me={variadic:function(t,e){return ue(t,this,ae,e.cache.create(),e.serializer)},monadic:function(t,e){return ue(t,this,se,e.cache.create(),e.serializer)}};!function(t){
|
|
509
509
|
// When we have a placeholder but no value to format
|
|
510
|
-
|
|
510
|
+
t.MISSING_VALUE="MISSING_VALUE",
|
|
511
511
|
// When value supplied is invalid
|
|
512
|
-
|
|
512
|
+
t.INVALID_VALUE="INVALID_VALUE",
|
|
513
513
|
// When we need specific Intl API but it's not available
|
|
514
|
-
|
|
514
|
+
t.MISSING_INTL_API="MISSING_INTL_API"}(pe||(pe={}));var ge,de=/** @class */function(t){function e(e,n,r){var i=t.call(this,e)||this;return i.code=n,i.originalMessage=r,i}return J(e,t),e.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},e}(Error),ye=/** @class */function(t){function e(e,n,r,i){return t.call(this,'Invalid values for "'.concat(e,'": "').concat(n,'". Options are "').concat(Object.keys(r).join('", "'),'"'),pe.INVALID_VALUE,i)||this}return J(e,t),e}(de),be=/** @class */function(t){function e(e,n,r){return t.call(this,'Value for "'.concat(e,'" must be of type ').concat(n),pe.INVALID_VALUE,r)||this}return J(e,t),e}(de),Ee=/** @class */function(t){function e(e,n){return t.call(this,'The intl string context variable "'.concat(e,'" was not provided to the string "').concat(n,'"'),pe.MISSING_VALUE,n)||this}return J(e,t),e}(de);function ve(t){return"function"==typeof t}
|
|
515
515
|
// TODO(skeleton): add skeleton support
|
|
516
|
-
function
|
|
516
|
+
function Te(t,e,n,r,i,o,
|
|
517
517
|
// For debugging
|
|
518
518
|
s){
|
|
519
519
|
// Hot path for straight simple msg translations
|
|
520
|
-
if(1===
|
|
520
|
+
if(1===t.length&&ot(t[0]))return[{type:ge.literal,value:t[0].value}];for(var a=[],u=0,l=t;u<l.length;u++){var c=l[u];
|
|
521
521
|
// Exit early for string parts.
|
|
522
|
-
if(
|
|
522
|
+
if(ot(c))a.push({type:ge.literal,value:c.value});else
|
|
523
523
|
// TODO: should this part be literal type?
|
|
524
524
|
// Replace `#` in plural rules with the actual numeric value.
|
|
525
|
-
if(
|
|
525
|
+
if(pt(c))"number"==typeof o&&a.push({type:ge.literal,value:n.getNumberFormat(e).format(o)});else{var h=c.value;
|
|
526
526
|
// Enforce that all required values are provided by the caller.
|
|
527
|
-
if(!i||!(h in i))throw new
|
|
527
|
+
if(!i||!(h in i))throw new Ee(h,s);var p=i[h];if(st(c))p&&"string"!=typeof p&&"number"!=typeof p||(p="string"==typeof p||"number"==typeof p?String(p):""),a.push({type:"string"==typeof p?ge.literal:ge.object,value:p});else
|
|
528
528
|
// Recursively format plural and select parts' option — which can be a
|
|
529
529
|
// nested pattern structure. The choosing of the option to use is
|
|
530
530
|
// abstracted-by and delegated-to the part helper object.
|
|
531
|
-
if(
|
|
531
|
+
if(ut(c)){var f="string"==typeof c.style?r.date[c.style]:gt(c.style)?c.style.parsedOptions:void 0;a.push({type:ge.literal,value:n.getDateTimeFormat(e,f).format(p)})}else if(lt(c)){f="string"==typeof c.style?r.time[c.style]:gt(c.style)?c.style.parsedOptions:r.time.medium;a.push({type:ge.literal,value:n.getDateTimeFormat(e,f).format(p)})}else if(at(c)){(f="string"==typeof c.style?r.number[c.style]:mt(c.style)?c.style.parsedOptions:void 0)&&f.scale&&(p*=f.scale||1),a.push({type:ge.literal,value:n.getNumberFormat(e,f).format(p)})}else{if(ft(c)){var m=c.children,g=c.value,d=i[g];if(!ve(d))throw new be(g,"function",s);var y=d(Te(m,e,n,r,i,o).map((function(t){return t.value})));Array.isArray(y)||(y=[y]),a.push.apply(a,y.map((function(t){return{type:"string"==typeof t?ge.literal:ge.object,value:t}})))}if(ct(c)){if(!(b=c.options[p]||c.options.other))throw new ye(c.value,p,Object.keys(c.options),s);a.push.apply(a,Te(b.value,e,n,r,i))}else if(ht(c)){var b;if(!(b=c.options["=".concat(p)])){if(!Intl.PluralRules)throw new de('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',pe.MISSING_INTL_API,s);var E=n.getPluralRules(e,{type:c.pluralType}).select(p-(c.offset||0));b=c.options[E]||c.options.other}if(!b)throw new ye(c.value,p,Object.keys(c.options),s);a.push.apply(a,Te(b.value,e,n,r,i,p-(c.offset||0)))}else;}}}return function(t){return t.length<2?t:t.reduce((function(t,e){var n=t[t.length-1];return n&&n.type===ge.literal&&e.type===ge.literal?n.value+=e.value:t.push(e),t}),[])}(a)}
|
|
532
532
|
/*
|
|
533
533
|
Copyright (c) 2014, Yahoo! Inc. All rights reserved.
|
|
534
534
|
Copyrights licensed under the New BSD License.
|
|
535
535
|
See the accompanying LICENSE file for terms.
|
|
536
536
|
*/
|
|
537
537
|
// -- MessageFormat --------------------------------------------------------
|
|
538
|
-
function
|
|
538
|
+
function Pe(t,e){return e?Object.keys(t).reduce((function(n,r){var i,o;return n[r]=(i=t[r],(o=e[r])?rt(rt(rt({},i||{}),o||{}),Object.keys(i).reduce((function(t,e){return t[e]=rt(rt({},i[e]),o[e]||{}),t}),{})):i),n}),rt({},t)):t}function Be(t){return{create:function(){return{get:function(e){return t[e]},set:function(e,n){t[e]=n}}}}}!function(t){t[t.literal=0]="literal",t[t.object=1]="object"}(ge||(ge={}));var He=/** @class */function(){function t(e,n,r,i){var o,s=this;if(void 0===n&&(n=t.defaultLocale),this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(t){var e=s.formatToParts(t);
|
|
539
539
|
// Hot path for straight simple msg translations
|
|
540
|
-
if(1===
|
|
540
|
+
if(1===e.length)return e[0].value;var n=e.reduce((function(t,e){return t.length&&e.type===ge.literal&&"string"==typeof t[t.length-1]?t[t.length-1]+=e.value:t.push(e.value),t}),[]);return n.length<=1?n[0]||"":n},this.formatToParts=function(t){return Te(s.ast,s.locales,s.formatters,s.formats,t,void 0,s.message)},this.resolvedOptions=function(){return{locale:s.resolvedLocale.toString()}},this.getAst=function(){return s.ast},
|
|
541
541
|
// Defined first because it's used to build the format pattern.
|
|
542
|
-
this.locales=n,this.resolvedLocale=
|
|
542
|
+
this.locales=n,this.resolvedLocale=t.resolveLocale(n),"string"==typeof e){if(this.message=e,!t.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");
|
|
543
543
|
// Parse string messages into an AST.
|
|
544
|
-
this.ast=
|
|
544
|
+
this.ast=t.__parse(e,{ignoreTag:null==i?void 0:i.ignoreTag,locale:this.resolvedLocale})}else this.ast=e;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");
|
|
545
545
|
// Creates a new object with the specified `formats` merged with the default
|
|
546
546
|
// formats.
|
|
547
|
-
this.formats=
|
|
547
|
+
this.formats=Pe(t.formats,r),this.formatters=i&&i.formatters||(void 0===(o=this.formatterCache)&&(o={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:oe((function(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new((t=Intl.NumberFormat).bind.apply(t,it([void 0],e,!1)))}),{cache:Be(o.number),strategy:me.variadic}),getDateTimeFormat:oe((function(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new((t=Intl.DateTimeFormat).bind.apply(t,it([void 0],e,!1)))}),{cache:Be(o.dateTime),strategy:me.variadic}),getPluralRules:oe((function(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new((t=Intl.PluralRules).bind.apply(t,it([void 0],e,!1)))}),{cache:Be(o.pluralRules),strategy:me.variadic})})}return Object.defineProperty(t,"defaultLocale",{get:function(){return t.memoizedDefaultLocale||(t.memoizedDefaultLocale=(new Intl.NumberFormat).resolvedOptions().locale),t.memoizedDefaultLocale},enumerable:!1,configurable:!0}),t.memoizedDefaultLocale=null,t.resolveLocale=function(t){var e=Intl.NumberFormat.supportedLocalesOf(t);return e.length>0?new Intl.Locale(e[0]):new Intl.Locale("string"==typeof t?t:t[0])},t.__parse=ie,
|
|
548
548
|
// Default format options used as the prototype of the `formats` provided to the
|
|
549
549
|
// constructor. These are used when constructing the internal Intl.NumberFormat
|
|
550
550
|
// and Intl.DateTimeFormat instances.
|
|
551
|
-
|
|
551
|
+
t.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"}}},t}(),Ae=He;
|
|
552
552
|
/*
|
|
553
553
|
Copyright (c) 2014, Yahoo! Inc. All rights reserved.
|
|
554
554
|
Copyrights licensed under the New BSD License.
|
|
555
555
|
See the accompanying LICENSE file for terms.
|
|
556
|
-
*/const
|
|
556
|
+
*/const _e={},Le=(t,e,n)=>n?(e in _e||(_e[e]={}),t in _e[e]||(_e[e][t]=n),n):n,we=(t,e)=>{if(null==e)return;if(e in _e&&t in _e[e])return _e[e][t];const n=Xe(e);for(let r=0;r<n.length;r++){const i=Ne(n[r],t);if(i)return Le(t,e,i)}};let Se;const Ie=$({});function Ce(t){return t in Se}function Ne(t,e){if(!Ce(t))return null;const n=function(t){return Se[t]||null}(t);return function(t,e){if(null==e)return;if(e in t)return t[e];const n=e.split(".");let r=t;for(let t=0;t<n.length;t++)if("object"==typeof r){if(t>0){const e=n.slice(t,n.length).join(".");if(e in r){r=r[e];break}}r=r[n[t]]}else r=void 0;return r}(n,e)}function Me(t,...e){delete _e[t],Ie.update((n=>(n[t]=q.all([n[t]||{},...e]),n)))}F([Ie],(([t])=>Object.keys(t))),Ie.subscribe((t=>Se=t));const Oe={};function Re(t){return Oe[t]}function De(t){return null!=t&&Xe(t).some((t=>{var e;return null===(e=Re(t))||void 0===e?void 0:e.size}))}const ke={};function xe(t){if(!De(t))return t in ke?ke[t]:Promise.resolve();const e=function(t){return Xe(t).map((t=>{const e=Re(t);return[t,e?[...e]:[]]})).filter((([,t])=>t.length>0))}(t);return ke[t]=Promise.all(e.map((([t,e])=>function(t,e){const n=Promise.all(e.map((e=>(function(t,e){Oe[t].delete(e),0===Oe[t].size&&delete Oe[t]}(t,e),e().then((t=>t.default||t))))));return n.then((e=>Me(t,...e)))}(t,e)))).then((()=>{if(De(t))return xe(t);delete ke[t]})),ke[t]}
|
|
557
557
|
/*! *****************************************************************************
|
|
558
558
|
Copyright (c) Microsoft Corporation.
|
|
559
559
|
|
|
@@ -567,26 +567,28 @@ e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"}
|
|
|
567
567
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
568
568
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
569
569
|
PERFORMANCE OF THIS SOFTWARE.
|
|
570
|
-
***************************************************************************** */function
|
|
571
|
-
/* src/PlayerAccountGamingLimitsPopup_2.svelte generated by Svelte v3.48.0 */function
|
|
572
|
-
return"initial"===
|
|
573
|
-
// (
|
|
574
|
-
function
|
|
575
|
-
// (
|
|
576
|
-
function
|
|
577
|
-
// (
|
|
578
|
-
function
|
|
579
|
-
// (
|
|
580
|
-
function
|
|
581
|
-
// (
|
|
582
|
-
function
|
|
583
|
-
// (
|
|
584
|
-
function
|
|
585
|
-
/*svg_binding*/
|
|
586
|
-
/*button2_binding*/
|
|
587
|
-
/*svg_binding*/,
|
|
588
|
-
/*button2_binding*/,
|
|
589
|
-
return
|
|
590
|
-
/*div2_binding*/,
|
|
591
|
-
/*
|
|
570
|
+
***************************************************************************** */function Ue(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]])}return n}const Ge={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 $e(){return Ge}const Fe=$(!1);let je;const Ve=$(null);function Ke(t){return t.split("-").map(((t,e,n)=>n.slice(0,e+1).join("-"))).reverse()}function Xe(t,e=$e().fallbackLocale){const n=Ke(t);return e?[...new Set([...n,...Ke(e)])]:n}function ze(){return null!=je?je:void 0}Ve.subscribe((t=>{je=null!=t?t:void 0,"undefined"!=typeof window&&null!=t&&document.documentElement.setAttribute("lang",t)}));const We=Object.assign(Object.assign({},Ve),{set:t=>{if(t&&function(t){if(null==t)return;const e=Xe(t);for(let t=0;t<e.length;t++){const n=e[t];if(Ce(n))return n}}(t)&&De(t)){const{loadingDelay:e}=$e();let n;return"undefined"!=typeof window&&null!=ze()&&e?n=window.setTimeout((()=>Fe.set(!0)),e):Fe.set(!0),xe(t).then((()=>{Ve.set(t)})).finally((()=>{clearTimeout(n),Fe.set(!1)}))}return Ve.set(t)}}),Ye=t=>{const e=Object.create(null);return n=>{const r=JSON.stringify(n);return r in e?e[r]:e[r]=t(n)}},Ze=(t,e)=>{const{formats:n}=$e();if(t in n&&e in n[t])return n[t][e];throw new Error(`[svelte-i18n] Unknown "${e}" ${t} format.`)},qe=Ye((t=>{var{locale:e,format:n}=t,r=Ue(t,["locale","format"]);if(null==e)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return n&&(r=Ze("number",n)),new Intl.NumberFormat(e,r)})),Qe=Ye((t=>{var{locale:e,format:n}=t,r=Ue(t,["locale","format"]);if(null==e)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return n?r=Ze("date",n):0===Object.keys(r).length&&(r=Ze("date","short")),new Intl.DateTimeFormat(e,r)})),Je=Ye((t=>{var{locale:e,format:n}=t,r=Ue(t,["locale","format"]);if(null==e)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return n?r=Ze("time",n):0===Object.keys(r).length&&(r=Ze("time","short")),new Intl.DateTimeFormat(e,r)})),tn=Ye(((t,e=ze())=>new Ae(t,e,$e().formats,{ignoreTag:$e().ignoreTag}))),en=(t,e={})=>{var n,r,i,o;let s=e;"object"==typeof t&&(s=t,t=s.id);const{values:a,locale:u=ze(),default:l}=s;if(null==u)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let c=we(t,u);if(c){if("string"!=typeof c)return console.warn(`[svelte-i18n] Message with id "${t}" must be of type "string", found: "${typeof c}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),c}else c=null!==(o=null!==(i=null===(r=(n=$e()).handleMissingMessage)||void 0===r?void 0:r.call(n,{locale:u,id:t,defaultValue:l}))&&void 0!==i?i:l)&&void 0!==o?o:t;if(!a)return c;let h=c;try{h=tn(c,u).format(a)}catch(e){console.warn(`[svelte-i18n] Message "${t}" has syntax error:`,e.message)}return h},nn=(t,e)=>((t={})=>{var{locale:e=ze()}=t,n=Ue(t,["locale"]);return Je(Object.assign({locale:e},n))})(e).format(t),rn=(t,e)=>((t={})=>{var{locale:e=ze()}=t,n=Ue(t,["locale"]);return Qe(Object.assign({locale:e},n))})(e).format(t),on=(t,e)=>((t={})=>{var{locale:e=ze()}=t,n=Ue(t,["locale"]);return qe(Object.assign({locale:e},n))})(e).format(t),sn=(t,e=ze())=>we(t,e),an=F([We,Ie],(()=>en));F([We],(()=>nn)),F([We],(()=>rn)),F([We],(()=>on)),F([We,Ie],(()=>sn));const un={en:{lugasPopup:{loading:"Loading, please wait...",setLimit:"Set a limit",setLimitDescription:"In Germany, you are legally required to set a monthly deposit limit. Therefore, we ask you to confirm your existing limit or set a new one in order to enjoy playing without restrictions.",lugasInfo1:"Any questions? Information about",lugasInfo2:"LUGAS",keepCurrentLimit:"KEEP THE CURRENT LIMIT",keepCurrentLimitButton:"NEW LIMIT",applyButton:"APPLY",depositPeriod:"Monthly deposit limit",TCpart1:'By clicking "Keep the current limit" or "Apply" I confirm that I have read and accept the ',TClink:"General Terms and Conditions",TCpart2:". Also note our ",PPlink:"Privacy Policy",depositLimit:"Deposit Limit set",successful:"Succesful!",successDescription:"The deposit limit has been set successfully. You can manage your limits at any time in the account settings.",kyc1Part1:"We were able to set your monthly deposit limit to ",kyc1Part2:". In order to increase the limit to the desired amount, we ask you to provide us with the relevant information. This information can be submitted in the document upload.",kycButton:"UPLOAD DOCUMENTS",closeButton:"CLOSE",depositError:"Deposit Limit update error",errorDescription:"We were unable to set your limit at this time, due to a server error. Please try again later.",docsRequired:"Documents required!",kyc2:"For the selected limit, we require documents that show your economic capacity. Please upload your last payslip as well as a current bank statement, including the balance, that confirms that you received the payment."}},de:{lugasPopup:{loading:"Loading, please wait...",setLimit:"Set a limit",setLimitDescription:"In Germany, you are legally required to set a monthly deposit limit. Therefore, we ask you to confirm your existing limit or set a new one in order to enjoy playing without restrictions.",lugasInfo1:"Any questions? Information about",lugasInfo2:"LUGAS",keepCurrentLimit:"KEEP THE CURRENT LIMIT",keepCurrentLimitButton:"NEW LIMIT",applyButton:"APPLY",depositPeriod:"Monthly deposit limit",TCpart1:'By clicking "Keep the current limit" or "Apply" I confirm that I have read and accept the ',TClink:"General Terms and Conditions",TCpart2:". Also note our ",PPlink:"Privacy Policy",depositLimit:"Deposit Limit set",successful:"Succesful!",successDescription:"The deposit limit has been set successfully. You can manage your limits at any time in the account settings.",kyc1Part1:"We were able to set your monthly deposit limit to ",kyc1Part2:". In order to increase the limit to the desired amount, we ask you to provide us with the relevant information. This information can be submitted in the document upload.",kycButton:"UPLOAD DOCUMENTS",closeButton:"CLOSE",depositError:"Deposit Limit update error",errorDescription:"We were unable to set your limit at this time, due to a server error. Please try again later.",docsRequired:"Documents required!",kyc2:"For the selected limit, we require documents that show your economic capacity. Please upload your last payslip as well as a current bank statement, including the balance, that confirms that you received the payment."}}},{document:ln}=D;
|
|
571
|
+
/* src/PlayerAccountGamingLimitsPopup_2.svelte generated by Svelte v3.48.0 */function cn(t){let e;function n(t,e){/*popupState*/
|
|
572
|
+
return"initial"===t[10]?dn:/*popupState*/"successful"===t[10]?gn:/*popupState*/"KYC"===t[10]?mn:/*popupState*/"KYC2"===t[10]?fn:/*popupState*/"error"===t[10]?pn:void 0}let r=n(t),i=r&&r(t);return{c(){e=c("div"),i&&i.c(),g(e,"class","InitialWrapper")},m(t,n){u(t,e,n),i&&i.m(e,null)},p(t,o){r===(r=n(t))&&i?i.p(t,o):(i&&i.d(1),i=r&&r(t),i&&(i.c(),i.m(e,null)))},d(t){t&&l(e),i&&i.d()}}}
|
|
573
|
+
// (135:8) {#if isLoading}
|
|
574
|
+
function hn(t){let e,n,r=/*$_*/t[12]("lugasPopup.loading")+"";return{c(){e=c("p"),n=p(r)},m(t,r){u(t,e,r),a(e,n)},p(t,e){/*$_*/4096&e[0]&&r!==(r=/*$_*/t[12]("lugasPopup.loading")+"")&&y(n,r)},d(t){t&&l(e)}}}
|
|
575
|
+
// (231:43)
|
|
576
|
+
function pn(t){let e,n,r,i,o,s,h,d,b,E,v,T,P=/*$_*/t[12]("lugasPopup.depositError")+"",B=/*$_*/t[12]("lugasPopup.errorDescription")+"",H=/*$_*/t[12]("lugasPopup.closeButton")+"";return{c(){e=c("p"),n=p(P),r=f(),i=c("div"),i.innerHTML='<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 1000 1000" enable-background="new 0 0 1000 1000" xml:space="preserve"><metadata>Svg Vector Icons : http://www.onlinewebfonts.com/icon </metadata><g><path d="M500,100.9c220,0,399.1,179,399.1,399.1S720.1,899.1,500,899.1c-220.1,0-399.1-179-399.1-399.1C100.9,279.9,279.9,100.9,500,100.9 M500,10C229.4,10,10,229.4,10,500c0,270.6,219.4,490,490,490c270.6,0,490-219.4,490-490C990,229.4,770.6,10,500,10L500,10z"></path><path d="M658.7,734.5L272.2,348l75-75l386.4,386.4L658.7,734.5z"></path><path d="M347.2,734.5l-75-75L658.7,273l75,75L347.2,734.5z"></path></g></svg>',o=f(),s=c("p"),h=p(B),d=f(),b=c("button"),E=p(H),g(e,"class","Title"),g(i,"class","ResultIconWrapper"),g(s,"class","Description CenterAlign"),g(b,"class","ConfirmButton SecondaryButtonStyle")},m(l,c){u(l,e,c),a(e,n),u(l,r,c),u(l,i,c),u(l,o,c),u(l,s,c),a(s,h),u(l,d,c),u(l,b,c),a(b,E),v||(T=m(b,"click",/*click_handler_10*/t[35]),v=!0)},p(t,e){/*$_*/4096&e[0]&&P!==(P=/*$_*/t[12]("lugasPopup.depositError")+"")&&y(n,P),/*$_*/4096&e[0]&&B!==(B=/*$_*/t[12]("lugasPopup.errorDescription")+"")&&y(h,B),/*$_*/4096&e[0]&&H!==(H=/*$_*/t[12]("lugasPopup.closeButton")+"")&&y(E,H)},d(t){t&&l(e),t&&l(r),t&&l(i),t&&l(o),t&&l(s),t&&l(d),t&&l(b),v=!1,T()}}}
|
|
577
|
+
// (208:42)
|
|
578
|
+
function fn(t){let e,n,i,o,s,d,b,v,T,P,B,H,A,_,L,w,S,I,C,N,M,O,R=/*$_*/t[12]("lugasPopup.docsRequired")+"",D=/*$_*/t[12]("lugasPopup.docsRequired")+"",k=/*$_*/t[12]("lugasPopup.kyc2")+"",x=/*$_*/t[12]("lugasPopup.kycButton")+"",U=/*$_*/t[12]("lugasPopup.closeButton")+"";return{c(){e=c("p"),n=p(R),i=f(),o=c("div"),s=c("div"),d=h("svg"),b=h("g"),v=h("path"),T=f(),P=c("p"),B=p(D),H=f(),A=c("p"),_=p(k),L=f(),w=c("button"),S=p(x),I=f(),C=c("button"),N=p(U),g(e,"class","Title"),g(v,"id","XMLID_6_"),g(v,"d","M426.2,55h-99.8C318,23.3,290,0,255.5,0S193,23.3,184.7,55H84.9c-27,0-48.5,22.4-48.5,48.5v360\n c0,27,22.4,48.5,48.5,48.5h342.3c27,0,48.5-22.4,48.5-48.5v-360C475.6,76.5,453.2,55,426.2,55z M255.5,55\n c13.1,0,24.2,11.2,24.2,24.2s-11.2,24.2-24.2,24.2s-24.2-11.2-24.2-24.2S242.5,55,255.5,55z M429.9,467.2H81.1V100.7h45.7v82.1\n h256.5v-82.1H429v366.5H429.9z"),g(b,"id","XMLID_1_"),g(d,"version","1.1"),g(d,"id","Layer_1"),g(d,"xmlns","http://www.w3.org/2000/svg"),g(d,"xmlns:xlink","http://www.w3.org/1999/xlink"),g(d,"x","0px"),g(d,"y","0px"),g(d,"viewBox","0 0 512 512"),E(d,"enable-background","new 0 0 512 512"),g(d,"xml:space","preserve"),g(s,"class","ResultIconWrapper"),g(A,"class","Description CenterAlign"),g(o,"class","DescriptionWrapper"),g(w,"class","KycButton PrimaryButtonStyle"),g(C,"class","ConfirmButton SecondaryButtonStyle")},m(r,l){u(r,e,l),a(e,n),u(r,i,l),u(r,o,l),a(o,s),a(s,d),a(d,b),a(b,v),a(s,T),a(s,P),a(P,B),a(o,H),a(o,A),a(A,_),u(r,L,l),u(r,w,l),a(w,S),u(r,I,l),u(r,C,l),a(C,N),M||(O=[m(w,"click",/*click_handler_8*/t[33]),m(C,"click",/*click_handler_9*/t[34])],M=!0)},p(t,e){/*$_*/4096&e[0]&&R!==(R=/*$_*/t[12]("lugasPopup.docsRequired")+"")&&y(n,R),/*$_*/4096&e[0]&&D!==(D=/*$_*/t[12]("lugasPopup.docsRequired")+"")&&y(B,D),/*$_*/4096&e[0]&&k!==(k=/*$_*/t[12]("lugasPopup.kyc2")+"")&&y(_,k),/*$_*/4096&e[0]&&x!==(x=/*$_*/t[12]("lugasPopup.kycButton")+"")&&y(S,x),/*$_*/4096&e[0]&&U!==(U=/*$_*/t[12]("lugasPopup.closeButton")+"")&&y(N,U)},d(t){t&&l(e),t&&l(i),t&&l(o),t&&l(L),t&&l(w),t&&l(I),t&&l(C),M=!1,r(O)}}}
|
|
579
|
+
// (185:41)
|
|
580
|
+
function mn(t){let e,n,i,o,s,d,b,v,T,P,B,H,A,_,L,w,S,I,C,N,M,O,R,D,k,x,U=/*$_*/t[12]("lugasPopup.depositLimit")+"",G=/*$_*/t[12]("lugasPopup.successful")+"",$=/*$_*/t[12]("lugasPopup.kyc1Part1")+"",F=/*$_*/t[12]("lugasPopup.kyc1Part2")+"",j=/*$_*/t[12]("lugasPopup.kycButton")+"",V=/*$_*/t[12]("lugasPopup.closeButton")+"";return{c(){e=c("p"),n=p(U),i=f(),o=c("div"),s=c("div"),d=h("svg"),b=h("g"),v=h("path"),T=f(),P=c("p"),B=p(G),H=f(),A=c("p"),_=p($),L=p(/*legislatorLimitValue*/t[11]),w=f(),S=p(/*currency*/t[0]),I=p(F),C=f(),N=c("button"),M=p(j),O=f(),R=c("button"),D=p(V),g(e,"class","Title"),g(v,"id","XMLID_6_"),g(v,"d","M426.2,55h-99.8C318,23.3,290,0,255.5,0S193,23.3,184.7,55H84.9c-27,0-48.5,22.4-48.5,48.5v360\n c0,27,22.4,48.5,48.5,48.5h342.3c27,0,48.5-22.4,48.5-48.5v-360C475.6,76.5,453.2,55,426.2,55z M255.5,55\n c13.1,0,24.2,11.2,24.2,24.2s-11.2,24.2-24.2,24.2s-24.2-11.2-24.2-24.2S242.5,55,255.5,55z M429.9,467.2H81.1V100.7h45.7v82.1\n h256.5v-82.1H429v366.5H429.9z"),g(b,"id","XMLID_1_"),g(d,"version","1.1"),g(d,"id","Layer_1"),g(d,"xmlns","http://www.w3.org/2000/svg"),g(d,"xmlns:xlink","http://www.w3.org/1999/xlink"),g(d,"x","0px"),g(d,"y","0px"),g(d,"viewBox","0 0 512 512"),E(d,"enable-background","new 0 0 512 512"),g(d,"xml:space","preserve"),g(s,"class","ResultIconWrapper"),g(A,"class","Description CenterAlign"),g(o,"class","DescriptionWrapper"),g(N,"class","KycButton PrimaryButtonStyle"),g(R,"class","ConfirmButton SecondaryButtonStyle")},m(r,l){u(r,e,l),a(e,n),u(r,i,l),u(r,o,l),a(o,s),a(s,d),a(d,b),a(b,v),a(s,T),a(s,P),a(P,B),a(o,H),a(o,A),a(A,_),a(A,L),a(A,w),a(A,S),a(A,I),u(r,C,l),u(r,N,l),a(N,M),u(r,O,l),u(r,R,l),a(R,D),k||(x=[m(N,"click",/*click_handler_6*/t[31]),m(R,"click",/*click_handler_7*/t[32])],k=!0)},p(t,e){/*$_*/4096&e[0]&&U!==(U=/*$_*/t[12]("lugasPopup.depositLimit")+"")&&y(n,U),/*$_*/4096&e[0]&&G!==(G=/*$_*/t[12]("lugasPopup.successful")+"")&&y(B,G),/*$_*/4096&e[0]&&$!==($=/*$_*/t[12]("lugasPopup.kyc1Part1")+"")&&y(_,$),/*legislatorLimitValue*/2048&e[0]&&y(L,/*legislatorLimitValue*/t[11]),/*currency*/1&e[0]&&y(S,/*currency*/t[0]),/*$_*/4096&e[0]&&F!==(F=/*$_*/t[12]("lugasPopup.kyc1Part2")+"")&&y(I,F),/*$_*/4096&e[0]&&j!==(j=/*$_*/t[12]("lugasPopup.kycButton")+"")&&y(M,j),/*$_*/4096&e[0]&&V!==(V=/*$_*/t[12]("lugasPopup.closeButton")+"")&&y(D,V)},d(t){t&&l(e),t&&l(i),t&&l(o),t&&l(C),t&&l(N),t&&l(O),t&&l(R),k=!1,r(x)}}}
|
|
581
|
+
// (168:48)
|
|
582
|
+
function gn(t){let e,n,r,i,o,s,d,b,v,T,P,B,H,A,_,L,w,S,I,C,N,M=/*$_*/t[12]("lugasPopup.depositLimit")+"",O=/*$_*/t[12]("lugasPopup.successful")+"",R=/*$_*/t[12]("lugasPopup.successDescription")+"";return{c(){e=c("p"),n=p(M),r=f(),i=c("div"),o=c("div"),s=h("svg"),d=h("defs"),b=h("style"),v=p(".fil0 {fill:black;fill-rule:nonzero}\n "),T=h("g"),P=h("polygon"),B=f(),H=c("p"),A=p(O),_=f(),L=c("p"),w=p(R),S=f(),I=c("button"),I.textContent="OK",g(e,"class","Title"),g(b,"type","text/css"),g(P,"class","fil0"),g(P,"points","0,38 10,25 36,47 78,0 90,11 37,69 "),g(s,"xmlns","http://www.w3.org/2000/svg"),g(s,"xmlns:xlink","http://www.w3.org/1999/xlink"),g(s,"xml:space","preserve"),g(s,"version","1.1"),E(s,"shape-rendering","geometricPrecision"),E(s,"text-rendering","geometricPrecision"),E(s,"image-rendering","optimizeQuality"),g(s,"viewBox","0 0 90 69"),g(s,"x","0px"),g(s,"y","0px"),g(s,"fill-rule","evenodd"),g(s,"clip-rule","evenodd"),g(o,"class","ResultIconWrapper"),g(L,"class","Description CenterAlign"),g(i,"class","DescriptionWrapper"),g(I,"class","ConfirmButton PrimaryButtonStyle")},m(l,c){u(l,e,c),a(e,n),u(l,r,c),u(l,i,c),a(i,o),a(o,s),a(s,d),a(d,b),a(b,v),a(s,T),a(T,P),a(o,B),a(o,H),a(H,A),a(i,_),a(i,L),a(L,w),u(l,S,c),u(l,I,c),C||(N=m(I,"click",/*click_handler_5*/t[30]),C=!0)},p(t,e){/*$_*/4096&e[0]&&M!==(M=/*$_*/t[12]("lugasPopup.depositLimit")+"")&&y(n,M),/*$_*/4096&e[0]&&O!==(O=/*$_*/t[12]("lugasPopup.successful")+"")&&y(A,O),/*$_*/4096&e[0]&&R!==(R=/*$_*/t[12]("lugasPopup.successDescription")+"")&&y(w,R)},d(t){t&&l(e),t&&l(r),t&&l(i),t&&l(S),t&&l(I),C=!1,N()}}}
|
|
583
|
+
// (139:10) {#if popupState === "initial"}
|
|
584
|
+
function dn(t){let e,n,i,o,s,E,T,P,B,H,A,_,L,w,S,I,C,N,M,O,R,D,k,x,U,G,$,F,j,V,K,X,z,W,Y,Z,q,Q,J,tt,et,nt,rt=/*$_*/t[12]("lugasPopup.setLimit")+"",it=/*$_*/t[12]("lugasPopup.setLimitDescription")+"",ot=/*$_*/t[12]("lugasPopup.lugasInfo1")+"",st=/*$_*/t[12]("lugasPopup.lugasInfo2")+"",at=/*$_*/t[12]("lugasPopup.keepCurrentLimit")+"",ut=/*$_*/t[12]("lugasPopup.keepCurrentLimitButton")+"",lt=/*$_*/t[12]("lugasPopup.depositPeriod")+"",ct=/*$_*/t[12]("lugasPopup.applyButton")+"",ht=/*$_*/t[12]("lugasPopup.TCpart1")+"",pt=/*$_*/t[12]("lugasPopup.TClink")+"",ft=/*$_*/t[12]("lugasPopup.TCpart2")+"",mt=/*$_*/t[12]("lugasPopup.PPlink")+"";return{c(){e=c("p"),n=p(rt),i=f(),o=c("p"),s=p(it),E=f(),T=c("p"),P=p(ot),B=f(),H=c("a"),A=p(st),_=f(),L=c("button"),w=p(at),S=f(),I=c("button"),C=p(ut),N=h("svg"),M=h("path"),O=h("path"),R=f(),D=c("div"),k=c("div"),x=c("span"),U=p(lt),G=f(),$=c("div"),F=c("input"),j=f(),V=c("button"),K=p(ct),X=f(),z=c("p"),W=p(ht),Y=c("a"),Z=p(pt),q=p(ft),Q=c("a"),J=p(mt),tt=p("."),g(e,"class","Title"),g(o,"class","Description LeftAlign"),g(H,"href","#"),g(T,"class","AdditionalInformation"),g(L,"class","KeepCurrentButton PrimaryButtonStyle"),g(M,"d","M10.5 15l7.5 7.5 7.5-7.5z"),g(O,"d","M0 0h36v36h-36z"),g(O,"fill","none"),g(N,"class","ExpandArrow"),g(N,"xmlns","http://www.w3.org/2000/svg"),g(N,"width","36"),g(N,"height","36"),g(N,"viewBox","0 0 36 36"),g(N,"fill","#999"),v(N,"Extended",/*extended*/t[5]),g(I,"class","ExpandButton"),g(x,"class","DepositPeriodText"),g(k,"class","DepositTextSection"),g(F,"type","number"),g(F,"class","DepositInput"),g(V,"type","submit"),g(V,"class","SubmitDepositButton PrimaryButtonStyle"),V.disabled=!0,g($,"class","DepositInputSection"),g(D,"class","SetLimitSection"),v(D,"Hidden",/*hidden*/t[4]),g(Y,"href","#"),g(Q,"href","#"),g(z,"class","TermsConditions")},m(r,l){u(r,e,l),a(e,n),u(r,i,l),u(r,o,l),a(o,s),u(r,E,l),u(r,T,l),a(T,P),a(T,B),a(T,H),a(H,A),u(r,_,l),u(r,L,l),a(L,w),u(r,S,l),u(r,I,l),a(I,C),a(I,N),a(N,M),a(N,O),
|
|
585
|
+
/*svg_binding*/t[24](N),u(r,R,l),u(r,D,l),a(D,k),a(k,x),a(x,U),a(D,G),a(D,$),a($,F),b(F,/*inputAmount*/t[6]),a($,j),a($,V),a(V,K),
|
|
586
|
+
/*button2_binding*/t[26](V),u(r,X,l),u(r,z,l),a(z,W),a(z,Y),a(Y,Z),a(z,q),a(z,Q),a(Q,J),a(z,tt),et||(nt=[m(H,"click",/*click_handler*/t[22]),m(L,"click",/*click_handler_1*/t[23]),m(I,"click",/*toggleNewLimitArea*/t[13]),m(F,"input",/*input_input_handler*/t[25]),m(F,"keyup",/*updateInputValue*/t[14]),m(V,"click",/*click_handler_2*/t[27]),m(Y,"click",/*click_handler_3*/t[28]),m(Q,"click",/*click_handler_4*/t[29])],et=!0)},p(t,e){/*$_*/4096&e[0]&&rt!==(rt=/*$_*/t[12]("lugasPopup.setLimit")+"")&&y(n,rt),/*$_*/4096&e[0]&&it!==(it=/*$_*/t[12]("lugasPopup.setLimitDescription")+"")&&y(s,it),/*$_*/4096&e[0]&&ot!==(ot=/*$_*/t[12]("lugasPopup.lugasInfo1")+"")&&y(P,ot),/*$_*/4096&e[0]&&st!==(st=/*$_*/t[12]("lugasPopup.lugasInfo2")+"")&&y(A,st),/*$_*/4096&e[0]&&at!==(at=/*$_*/t[12]("lugasPopup.keepCurrentLimit")+"")&&y(w,at),/*$_*/4096&e[0]&&ut!==(ut=/*$_*/t[12]("lugasPopup.keepCurrentLimitButton")+"")&&y(C,ut),/*extended*/32&e[0]&&v(N,"Extended",/*extended*/t[5]),/*$_*/4096&e[0]&<!==(lt=/*$_*/t[12]("lugasPopup.depositPeriod")+"")&&y(U,lt),/*inputAmount*/64&e[0]&&d(F.value)!==/*inputAmount*/t[6]&&b(F,/*inputAmount*/t[6]),/*$_*/4096&e[0]&&ct!==(ct=/*$_*/t[12]("lugasPopup.applyButton")+"")&&y(K,ct),/*hidden*/16&e[0]&&v(D,"Hidden",/*hidden*/t[4]),/*$_*/4096&e[0]&&ht!==(ht=/*$_*/t[12]("lugasPopup.TCpart1")+"")&&y(W,ht),/*$_*/4096&e[0]&&pt!==(pt=/*$_*/t[12]("lugasPopup.TClink")+"")&&y(Z,pt),/*$_*/4096&e[0]&&ft!==(ft=/*$_*/t[12]("lugasPopup.TCpart2")+"")&&y(q,ft),/*$_*/4096&e[0]&&mt!==(mt=/*$_*/t[12]("lugasPopup.PPlink")+"")&&y(J,mt)},d(n){n&&l(e),n&&l(i),n&&l(o),n&&l(E),n&&l(T),n&&l(_),n&&l(L),n&&l(S),n&&l(I)
|
|
587
|
+
/*svg_binding*/,t[24](null),n&&l(R),n&&l(D)
|
|
588
|
+
/*button2_binding*/,t[26](null),n&&l(X),n&&l(z),et=!1,r(nt)}}}function yn(e){let n,r,i,o,s,h;function p(t,e){/*isLoading*/
|
|
589
|
+
return t[7]?hn:/*lang*/t[1]?cn:void 0}let m=p(e),d=m&&m(e);return{c(){n=c("meta"),r=f(),i=c("div"),o=c("div"),s=c("div"),h=c("div"),d&&d.c(),this.c=t,g(n,"name","viewport"),g(n,"content","width=device-width, initial-scale=1"),g(h,"class","ModalContainer"),g(s,"class","Overlay"),g(o,"class","player-account-gaming-limits-popup-2")},m(t,l){a(ln.head,n),u(t,r,l),u(t,i,l),a(i,o),a(o,s),a(s,h),d&&d.m(h,null)
|
|
590
|
+
/*div2_binding*/,e[36](o),
|
|
591
|
+
/*div3_binding*/e[37](i)},p(t,e){m===(m=p(t))&&d?d.p(t,e):(d&&d.d(1),d=m&&m(t),d&&(d.c(),d.m(h,null)))},i:t,o:t,d(t){l(n),t&&l(r),t&&l(i),d&&d.d()
|
|
592
|
+
/*div2_binding*/,e[36](null),
|
|
593
|
+
/*div3_binding*/e[37](null)}}}function bn(t,e,n){let r;var i,o;i=an,o=t=>n(12,r=t),t.$$.on_destroy.push(s(i,o));let a,u,l,c,h,p,{userid:f=""}=e,{session:m=""}=e,{endpoint:g=""}=e,{currency:y=""}=e,{lang:b=""}=e,{clientstyling:E=""}=e,{clientstylingurl:v=""}=e,T=!0,P=!1,B=!1,H="initial";Object.keys(un).forEach((t=>{!function(t,e){Me(t,e)}(t,un[t])}));const _=t=>{switch(window.postMessage({type:t}),t){case"closePopup":case"uploadDocuments":h.parentNode.removeChild(h)}},L=t=>{const e=new URL(`/v1/player/${f}/limit/lugas`,g);let r={};n(7,B=!0),r="custom"===t?{amount:l}:{};let i={method:"POST",headers:{"X-SessionID":m,"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(r)};fetch(e.href,i).then((t=>t.json())).then((t=>{w(t)})).catch((t=>{console.log(t)})).finally((()=>{n(7,B=!1)}))},w=t=>{if(t.hasOwnProperty("kycNeeded"))switch(t.popup){case 1:n(10,H="KYC"),n(11,p=Intl.NumberFormat("en-US",{maximumFractionDigits:0}).format(t.operatorDepositLimitAmount));break;case 2:n(10,H="successful");break;case 3:n(10,H="KYC2")}else n(10,H="error")},S=()=>{var t;t=b,We.set(t)};return t.$$set=t=>{"userid"in t&&n(17,f=t.userid),"session"in t&&n(18,m=t.session),"endpoint"in t&&n(19,g=t.endpoint),"currency"in t&&n(0,y=t.currency),"lang"in t&&n(1,b=t.lang),"clientstyling"in t&&n(20,E=t.clientstyling),"clientstylingurl"in t&&n(21,v=t.clientstylingurl)},t.$$.update=()=>{/*lang*/2&t.$$.dirty[0]&&b&&S(),/*clientstylingurl*/2097152&t.$$.dirty[0]&&v&&(()=>{let t=new URL(v),e=document.createElement("style");fetch(t.href).then((t=>t.text())).then((t=>{e.innerHTML=t,a&&setTimeout((()=>{a.appendChild(e)}),1)}))})(),/*clientstyling*/1048576&t.$$.dirty[0]&&E&&(()=>{let t=document.createElement("style");t.innerHTML=E,a.appendChild(t)})()},[y,b,a,u,T,P,l,B,c,h,H,p,r,()=>{n(5,P=!P),n(4,T=!T)},()=>{const t=999999999999999;l>t&&n(6,l=t);const e=l-Math.floor(l)==0;l>0&&e?c.removeAttribute("disabled"):c.setAttribute("disabled","true")},_,L,f,m,g,E,v,()=>_("lugasInformation"),()=>L("default"),function(t){A[t?"unshift":"push"]((()=>{u=t,n(3,u)}))},function(){l=d(this.value),n(6,l)},function(t){A[t?"unshift":"push"]((()=>{c=t,n(8,c)}))},()=>L("custom"),()=>_("termsConditions"),()=>_("privacyPolicy"),()=>_("closePopup"),()=>_("uploadDocuments"),()=>_("closePopup"),()=>_("uploadDocuments"),()=>_("closePopup"),()=>_("closePopup"),function(t){A[t?"unshift":"push"]((()=>{h=t,n(9,h)}))},function(t){A[t?"unshift":"push"]((()=>{a=t,n(2,a)}))}]}class En extends U{constructor(t){super(),this.shadowRoot.innerHTML="<style>:host{font-family:'Roboto', system-ui, -apple-system, 'Segoe UI', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji';font-size:0.8rem}*,*::before,*::after{margin:0;padding:0;list-style:none;outline:none;box-sizing:border-box}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}.player-account-gaming-limits-popup-2{background:var(--emfe-w-color-black, #000000);color:var(--emfe-w-color-white, #000)}.Title{font-weight:800;font-size:18px}button{display:block;font-size:0.75rem;padding:12px 0;border:0;border-radius:2px;cursor:pointer}button.PrimaryButtonStyle{font-size:14px;color:#fff;background:#7ac317}button.SecondaryButtonStyle{border:1px solid #999;color:#666;background:#fff}.ResultIconWrapper{display:flex;flex-direction:column;align-items:center;margin:12px 0}.ResultIconWrapper svg{height:auto;width:60px;margin:12px}.ResultIconWrapper p{color:#666}.Overlay{position:absolute;top:0;left:0;width:100vw;height:100vh;display:flex;justify-content:center;align-items:center}.ModalContainer{position:fixed;top:30vh;width:20vw;height:auto;padding:18px 14px;background:#fff;border-radius:4px}.InitialWrapper{display:flex;flex-direction:column;gap:12px}.AdditionalInformation{margin:10px 0;font-size:14px}.TermsConditions{font-size:12px}.ExpandButton{font-size:14px;background-color:#fff;border:0;padding:0;margin-top:-10px;color:#999;display:flex;justify-content:center;align-items:center;cursor:pointer}.ExpandButton svg{width:28px;height:auto;margin-left:-4px}.LeftAlign{text-align:left;font-size:16px}.CenterAlign{text-align:center}.SetLimitSection{display:flex;flex-direction:column;gap:6px}.DepositTextSection{display:flex;justify-content:space-between}.DepositInputSection{height:32px;display:flex;gap:4px}.DepositInput{flex-grow:1;padding:0 6px}.SubmitDepositButton{flex-grow:1;font-size:0.75rem;padding:0}.SubmitDepositButton[disabled]{align-items:center;color:#ccc;cursor:not-allowed;background:#fff;border:#ccc 1px solid}.Hidden{display:none}.Extended{transform:rotate(180deg)}</style>",x(this,{target:this.shadowRoot,props:T(this.attributes),customElement:!0},bn,yn,o,{userid:17,session:18,endpoint:19,currency:0,lang:1,clientstyling:20,clientstylingurl:21},null,[-1,-1]),t&&(t.target&&u(t.target,this,t.anchor),t.props&&(this.$set(t.props),M()))}static get observedAttributes(){return["userid","session","endpoint","currency","lang","clientstyling","clientstylingurl"]}get userid(){return this.$$.ctx[17]}set userid(t){this.$$set({userid:t}),M()}get session(){return this.$$.ctx[18]}set session(t){this.$$set({session:t}),M()}get endpoint(){return this.$$.ctx[19]}set endpoint(t){this.$$set({endpoint:t}),M()}get currency(){return this.$$.ctx[0]}set currency(t){this.$$set({currency:t}),M()}get lang(){return this.$$.ctx[1]}set lang(t){this.$$set({lang:t}),M()}get clientstyling(){return this.$$.ctx[20]}set clientstyling(t){this.$$set({clientstyling:t}),M()}get clientstylingurl(){return this.$$.ctx[21]}set clientstylingurl(t){this.$$set({clientstylingurl:t}),M()}}return!customElements.get("player-account-gaming-limits-popup-2")&&customElements.define("player-account-gaming-limits-popup-2",En),En}));
|
|
592
594
|
//# sourceMappingURL=player-account-gaming-limits-popup-2.js.map
|