@everymatrix/player-bonus-history 1.94.20 → 1.94.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/PlayerBonusCard-CxACrSzY.cjs +1 -0
- package/components/{PlayerBonusCard-B3I9Xb9B.js → PlayerBonusCard-DAHK0Hu_.js} +236 -222
- package/components/{PlayerBonusCard-DHTblOIy.js → PlayerBonusCard-DAq5sC5K.js} +236 -222
- package/components/{PlayerBonusHistory-DtaxrYhh.js → PlayerBonusHistory-BEJCSoQ6.js} +2275 -2244
- package/components/{PlayerBonusHistory-DYDPAsky.cjs → PlayerBonusHistory-BUDWlZXF.cjs} +264 -264
- package/components/{PlayerBonusHistory-DHVfmVdW.js → PlayerBonusHistory-DdyXfGAs.js} +2293 -2262
- package/es2015/player-bonus-history.cjs +1 -1
- package/es2015/player-bonus-history.js +1 -1
- package/esnext/player-bonus-history.js +1 -1
- package/package.json +1 -1
- package/components/PlayerBonusCard-CKgXB5tw.cjs +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var dc=Object.defineProperty,uc=Object.defineProperties;var cc=Object.getOwnPropertyDescriptors;var xa=Object.getOwnPropertySymbols;var hc=Object.prototype.hasOwnProperty,pc=Object.prototype.propertyIsEnumerable;var so=(r,e,t)=>e in r?dc(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ct=(r,e)=>{for(var t in e||(e={}))hc.call(e,t)&&so(r,t,e[t]);if(xa)for(var t of xa(e))pc.call(e,t)&&so(r,t,e[t]);return r},hr=(r,e)=>uc(r,cc(e));var Le=(r,e,t)=>(so(r,typeof e!="symbol"?e+"":e,t),t);var pr=(r,e,t)=>new Promise((i,o)=>{var n=l=>{try{s(t.next(l))}catch(d){o(d)}},a=l=>{try{s(t.throw(l))}catch(d){o(d)}},s=l=>l.done?i(l.value):Promise.resolve(l.value).then(n,a);s((t=t.apply(r,e)).next())});function De(){}function ol(r){return r()}function Ca(){return Object.create(null)}function Zt(r){r.forEach(ol)}function En(r){return typeof r=="function"}function Tn(r,e){return r!=r?e==e:r!==e||r&&typeof r=="object"||typeof r=="function"}let ii;function mc(r,e){return r===e?!0:(ii||(ii=document.createElement("a")),ii.href=e,r===ii.href)}function fc(r){return Object.keys(r).length===0}function nl(r,...e){if(r==null){for(const i of e)i(void 0);return De}const t=r.subscribe(...e);return t.unsubscribe?()=>t.unsubscribe():t}function al(r,e,t){r.$$.on_destroy.push(nl(e,t))}function P(r,e){r.appendChild(e)}function sl(r,e,t){const i=_c(r);if(!i.getElementById(e)){const o=Q("style");o.id=e,o.textContent=t,vc(i,o)}}function _c(r){if(!r)return document;const e=r.getRootNode?r.getRootNode():r.ownerDocument;return e&&e.host?e:r.ownerDocument}function vc(r,e){return P(r.head||r,e),e.sheet}function Ee(r,e,t){r.insertBefore(e,t||null)}function ge(r){r.parentNode&&r.parentNode.removeChild(r)}function ll(r,e){for(let t=0;t<r.length;t+=1)r[t]&&r[t].d(e)}function Q(r){return document.createElement(r)}function It(r){return document.createElementNS("http://www.w3.org/2000/svg",r)}function Ce(r){return document.createTextNode(r)}function Ae(){return Ce(" ")}function Pn(){return Ce("")}function it(r,e,t,i){return r.addEventListener(e,t,i),()=>r.removeEventListener(e,t,i)}function D(r,e,t){t==null?r.removeAttribute(e):r.getAttribute(e)!==t&&r.setAttribute(e,t)}function _(r,e,t){const i=e.toLowerCase();i in r?r[i]=typeof r[i]=="boolean"&&t===""?!0:t:e in r?r[e]=typeof r[e]=="boolean"&&t===""?!0:t:D(r,e,t)}function gc(r){return Array.from(r.childNodes)}function mt(r,e){e=""+e,r.data!==e&&(r.data=e)}function bc(r){const e={};return r.childNodes.forEach(t=>{e[t.slot||"default"]=!0}),e}let kr;function Tr(r){kr=r}function yc(){if(!kr)throw new Error("Function called outside component initialization");return kr}function dl(r){yc().$$.on_mount.push(r)}const Mt=[],zt=[];let Ht=[];const Ea=[],wc=Promise.resolve();let No=!1;function xc(){No||(No=!0,wc.then(he))}function Mo(r){Ht.push(r)}const lo=new Set;let St=0;function he(){if(St!==0)return;const r=kr;do{try{for(;St<Mt.length;){const e=Mt[St];St++,Tr(e),Cc(e.$$)}}catch(e){throw Mt.length=0,St=0,e}for(Tr(null),Mt.length=0,St=0;zt.length;)zt.pop()();for(let e=0;e<Ht.length;e+=1){const t=Ht[e];lo.has(t)||(lo.add(t),t())}Ht.length=0}while(Mt.length);for(;Ea.length;)Ea.pop()();No=!1,lo.clear(),Tr(r)}function Cc(r){if(r.fragment!==null){r.update(),Zt(r.before_update);const e=r.dirty;r.dirty=[-1],r.fragment&&r.fragment.p(r.ctx,e),r.after_update.forEach(Mo)}}function Ec(r){const e=[],t=[];Ht.forEach(i=>r.indexOf(i)===-1?e.push(i):t.push(i)),t.forEach(i=>i()),Ht=e}const Tc=new Set;function Pc(r,e){r&&r.i&&(Tc.delete(r),r.i(e))}function wi(r){return(r==null?void 0:r.length)!==void 0?r:Array.from(r)}function Ac(r,e,t){const{fragment:i,after_update:o}=r.$$;i&&i.m(e,t),Mo(()=>{const n=r.$$.on_mount.map(ol).filter(En);r.$$.on_destroy?r.$$.on_destroy.push(...n):Zt(n),r.$$.on_mount=[]}),o.forEach(Mo)}function kc(r,e){const t=r.$$;t.fragment!==null&&(Ec(t.after_update),Zt(t.on_destroy),t.fragment&&t.fragment.d(e),t.on_destroy=t.fragment=null,t.ctx=[])}function Ic(r,e){r.$$.dirty[0]===-1&&(Mt.push(r),xc(),r.$$.dirty.fill(0)),r.$$.dirty[e/31|0]|=1<<e%31}function ul(r,e,t,i,o,n,a=null,s=[-1]){const l=kr;Tr(r);const d=r.$$={fragment:null,ctx:[],props:n,update:De,not_equal:o,bound:Ca(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(l?l.$$.context:[])),callbacks:Ca(),dirty:s,skip_bound:!1,root:e.target||l.$$.root};a&&a(d.root);let u=!1;if(d.ctx=t?t(r,e.props||{},(c,h,...p)=>{const m=p.length?p[0]:h;return d.ctx&&o(d.ctx[c],d.ctx[c]=m)&&(!d.skip_bound&&d.bound[c]&&d.bound[c](m),u&&Ic(r,c)),h}):[],d.update(),u=!0,Zt(d.before_update),d.fragment=i?i(d.ctx):!1,e.target){if(e.hydrate){const c=gc(e.target);d.fragment&&d.fragment.l(c),c.forEach(ge)}else d.fragment&&d.fragment.c();e.intro&&Pc(r.$$.fragment),Ac(r,e.target,e.anchor),he()}Tr(l)}let cl;typeof HTMLElement=="function"&&(cl=class extends HTMLElement{constructor(e,t,i){super();Le(this,"$$ctor");Le(this,"$$s");Le(this,"$$c");Le(this,"$$cn",!1);Le(this,"$$d",{});Le(this,"$$r",!1);Le(this,"$$p_d",{});Le(this,"$$l",{});Le(this,"$$l_u",new Map);this.$$ctor=e,this.$$s=t,i&&this.attachShadow({mode:"open"})}addEventListener(e,t,i){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const o=this.$$c.$on(e,t);this.$$l_u.set(t,o)}super.addEventListener(e,t,i)}removeEventListener(e,t,i){if(super.removeEventListener(e,t,i),this.$$c){const o=this.$$l_u.get(t);o&&(o(),this.$$l_u.delete(t))}}connectedCallback(){return pr(this,null,function*(){if(this.$$cn=!0,!this.$$c){let e=function(n){return()=>{let a;return{c:function(){a=Q("slot"),n!=="default"&&D(a,"name",n)},m:function(d,u){Ee(d,a,u)},d:function(d){d&&ge(a)}}}};if(yield Promise.resolve(),!this.$$cn||this.$$c)return;const t={},i=bc(this);for(const n of this.$$s)n in i&&(t[n]=[e(n)]);for(const n of this.attributes){const a=this.$$g_p(n.name);a in this.$$d||(this.$$d[a]=mi(a,n.value,this.$$p_d,"toProp"))}for(const n in this.$$p_d)!(n in this.$$d)&&this[n]!==void 0&&(this.$$d[n]=this[n],delete this[n]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:hr(ct({},this.$$d),{$$slots:t,$$scope:{ctx:[]}})});const o=()=>{this.$$r=!0;for(const n in this.$$p_d)if(this.$$d[n]=this.$$c.$$.ctx[this.$$c.$$.props[n]],this.$$p_d[n].reflect){const a=mi(n,this.$$d[n],this.$$p_d,"toAttribute");a==null?this.removeAttribute(this.$$p_d[n].attribute||n):this.setAttribute(this.$$p_d[n].attribute||n,a)}this.$$r=!1};this.$$c.$$.after_update.push(o),o();for(const n in this.$$l)for(const a of this.$$l[n]){const s=this.$$c.$on(n,a);this.$$l_u.set(a,s)}this.$$l={}}})}attributeChangedCallback(e,t,i){var o;this.$$r||(e=this.$$g_p(e),this.$$d[e]=mi(e,i,this.$$p_d,"toProp"),(o=this.$$c)==null||o.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)})}$$g_p(e){return Object.keys(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function mi(r,e,t,i){var n;const o=(n=t[r])==null?void 0:n.type;if(e=o==="Boolean"&&typeof e!="boolean"?e!=null:e,!i||!t[r])return e;if(i==="toAttribute")switch(o){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e==null?null:e;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}function hl(r,e,t,i,o,n){let a=class extends cl{constructor(){super(r,t,o),this.$$p_d=e}static get observedAttributes(){return Object.keys(e).map(s=>(e[s].attribute||s).toLowerCase())}};return Object.keys(e).forEach(s=>{Object.defineProperty(a.prototype,s,{get(){return this.$$c&&s in this.$$c?this.$$c[s]:this.$$d[s]},set(l){var d;l=mi(s,l,e),this.$$d[s]=l,(d=this.$$c)==null||d.$set({[s]:l})}})}),i.forEach(s=>{Object.defineProperty(a.prototype,s,{get(){var l;return(l=this.$$c)==null?void 0:l[s]}})}),r.element=a,a}class pl{constructor(){Le(this,"$$");Le(this,"$$set")}$destroy(){kc(this,1),this.$destroy=De}$on(e,t){if(!En(t))return De;const i=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return i.push(t),()=>{const o=i.indexOf(t);o!==-1&&i.splice(o,1)}}$set(e){this.$$set&&!fc(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const Sc="4";typeof window!="undefined"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(Sc);const Bt="__WIDGET_GLOBAL_STYLE_CACHE__";function ml(r,e){if(r){const t=document.createElement("style");t.innerHTML=e,r.appendChild(t)}}function fl(r,e){if(!r||!e)return;const t=new URL(e);fetch(t.href).then(i=>i.text()).then(i=>{const o=document.createElement("style");o.innerHTML=i,r&&r.appendChild(o)}).catch(i=>{console.error("There was an error while trying to load client styling from URL",i)})}function _l(r,e,t,i=!1){if(!window.emMessageBus)return;if(!("adoptedStyleSheets"in Document.prototype)||!i)return t=Dc(r,e),t;window[Bt]||(window[Bt]={}),t=Oc(r,e);const n=t.unsubscribe.bind(t),a=()=>{if(window[Bt][e]){const s=window[Bt][e];s.refCount>1?s.refCount=s.refCount-1:delete window[Bt][e]}n()};return t.unsubscribe=a,t}function Dc(r,e){const t=document.createElement("style");return window.emMessageBus.subscribe(e,i=>{r&&(t.innerHTML=i,r.appendChild(t))})}function Oc(r,e){return window.emMessageBus.subscribe(e,t=>{if(!r)return;const i=r.getRootNode(),o=window[Bt];let n=o[e]&&o[e].sheet;n?o[e].refCount=o[e].refCount+1:(n=new CSSStyleSheet,n.replaceSync(t),o[e]={sheet:n,refCount:1});const a=i.adoptedStyleSheets||[];a.includes(n)||(i.adoptedStyleSheets=[...a,n])})}/*! *****************************************************************************
|
|
2
2
|
Copyright (c) Microsoft Corporation.
|
|
3
3
|
|
|
4
4
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -11,38 +11,38 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
11
11
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
12
12
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
13
13
|
PERFORMANCE OF THIS SOFTWARE.
|
|
14
|
-
***************************************************************************** */var Bo=function(r,e){return Bo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(t[o]=i[o])},Bo(r,e)};function
|
|
14
|
+
***************************************************************************** */var Bo=function(r,e){return Bo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(t[o]=i[o])},Bo(r,e)};function Ur(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");Bo(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}function Lo(r){var e=typeof Symbol=="function"&&Symbol.iterator,t=e&&r[e],i=0;if(t)return t.call(r);if(r&&typeof r.length=="number")return{next:function(){return r&&i>=r.length&&(r=void 0),{value:r&&r[i++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function zo(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var i=t.call(r),o,n=[],a;try{for(;(e===void 0||e-- >0)&&!(o=i.next()).done;)n.push(o.value)}catch(s){a={error:s}}finally{try{o&&!o.done&&(t=i.return)&&t.call(i)}finally{if(a)throw a.error}}return n}function Ho(r,e,t){if(arguments.length===2)for(var i=0,o=e.length,n;i<o;i++)(n||!(i in e))&&(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return r.concat(n||e)}function Ge(r){return typeof r=="function"}function vl(r){var e=function(i){Error.call(i),i.stack=new Error().stack},t=r(e);return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var uo=vl(function(r){return function(t){r(this),this.message=t?t.length+` errors occurred during unsubscription:
|
|
15
15
|
`+t.map(function(i,o){return o+1+") "+i.toString()}).join(`
|
|
16
|
-
`):"",this.name="UnsubscriptionError",this.errors=t}});function Ro(r,e){if(r){var t=r.indexOf(e);0<=t&&r.splice(t,1)}}var $i=function(){function r(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return r.prototype.unsubscribe=function(){var e,t,i,o,n;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var s=Lo(a),l=s.next();!l.done;l=s.next()){var d=l.value;d.remove(this)}}catch(f){e={error:f}}finally{try{l&&!l.done&&(t=s.return)&&t.call(s)}finally{if(e)throw e.error}}else a.remove(this);var u=this.initialTeardown;if(Xe(u))try{u()}catch(f){n=f instanceof uo?f.errors:[f]}var c=this._finalizers;if(c){this._finalizers=null;try{for(var h=Lo(c),p=h.next();!p.done;p=h.next()){var m=p.value;try{Ta(m)}catch(f){n=n!=null?n:[],f instanceof uo?n=Ho(Ho([],zo(n)),zo(f.errors)):n.push(f)}}}catch(f){i={error:f}}finally{try{p&&!p.done&&(o=h.return)&&o.call(h)}finally{if(i)throw i.error}}}if(n)throw new uo(n)}},r.prototype.add=function(e){var t;if(e&&e!==this)if(this.closed)Ta(e);else{if(e instanceof r){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(e)}},r.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},r.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},r.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&Ro(t,e)},r.prototype.remove=function(e){var t=this._finalizers;t&&Ro(t,e),e instanceof r&&e._removeParent(this)},r.EMPTY=function(){var e=new r;return e.closed=!0,e}(),r}(),gl=$i.EMPTY;function bl(r){return r instanceof $i||r&&"closed"in r&&Xe(r.remove)&&Xe(r.add)&&Xe(r.unsubscribe)}function Ta(r){Xe(r)?r():r.unsubscribe()}var Oc={Promise:void 0},Nc={setTimeout:function(r,e){for(var t=[],i=2;i<arguments.length;i++)t[i-2]=arguments[i];return setTimeout.apply(void 0,Ho([r,e],zo(t)))},clearTimeout:function(r){return clearTimeout(r)},delegate:void 0};function Mc(r){Nc.setTimeout(function(){throw r})}function Pa(){}function fi(r){r()}var yl=function(r){Wr(e,r);function e(t){var i=r.call(this)||this;return i.isStopped=!1,t?(i.destination=t,bl(t)&&t.add(i)):i.destination=zc,i}return e.create=function(t,i,o){return new Fo(t,i,o)},e.prototype.next=function(t){this.isStopped||this._next(t)},e.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,r.prototype.unsubscribe.call(this),this.destination=null)},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},e.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},e}($i),Bc=function(){function r(e){this.partialObserver=e}return r.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(i){oi(i)}},r.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(i){oi(i)}else oi(e)},r.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(t){oi(t)}},r}(),Fo=function(r){Wr(e,r);function e(t,i,o){var n=r.call(this)||this,a;return Xe(t)||!t?a={next:t!=null?t:void 0,error:i!=null?i:void 0,complete:o!=null?o:void 0}:a=t,n.destination=new Bc(a),n}return e}(yl);function oi(r){Mc(r)}function Lc(r){throw r}var zc={closed:!0,next:Pa,error:Lc,complete:Pa},Hc=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Rc(r){return r}function Fc(r){return r.length===0?Rc:r.length===1?r[0]:function(t){return r.reduce(function(i,o){return o(i)},t)}}var Aa=function(){function r(e){e&&(this._subscribe=e)}return r.prototype.lift=function(e){var t=new r;return t.source=this,t.operator=e,t},r.prototype.subscribe=function(e,t,i){var o=this,n=Vc(e)?e:new Fo(e,t,i);return fi(function(){var a=o,s=a.operator,l=a.source;n.add(s?s.call(n,l):l?o._subscribe(n):o._trySubscribe(n))}),n},r.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},r.prototype.forEach=function(e,t){var i=this;return t=ka(t),new t(function(o,n){var a=new Fo({next:function(s){try{e(s)}catch(l){n(l),a.unsubscribe()}},error:n,complete:o});i.subscribe(a)})},r.prototype._subscribe=function(e){var t;return(t=this.source)===null||t===void 0?void 0:t.subscribe(e)},r.prototype[Hc]=function(){return this},r.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Fc(e)(this)},r.prototype.toPromise=function(e){var t=this;return e=ka(e),new e(function(i,o){var n;t.subscribe(function(a){return n=a},function(a){return o(a)},function(){return i(n)})})},r.create=function(e){return new r(e)},r}();function ka(r){var e;return(e=r!=null?r:Oc.Promise)!==null&&e!==void 0?e:Promise}function $c(r){return r&&Xe(r.next)&&Xe(r.error)&&Xe(r.complete)}function Vc(r){return r&&r instanceof yl||$c(r)&&bl(r)}var Uc=vl(function(r){return function(){r(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),wl=function(r){Wr(e,r);function e(){var t=r.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return e.prototype.lift=function(t){var i=new Ia(this,this);return i.operator=t,i},e.prototype._throwIfClosed=function(){if(this.closed)throw new Uc},e.prototype.next=function(t){var i=this;fi(function(){var o,n;if(i._throwIfClosed(),!i.isStopped){i.currentObservers||(i.currentObservers=Array.from(i.observers));try{for(var a=Lo(i.currentObservers),s=a.next();!s.done;s=a.next()){var l=s.value;l.next(t)}}catch(d){o={error:d}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(o)throw o.error}}}})},e.prototype.error=function(t){var i=this;fi(function(){if(i._throwIfClosed(),!i.isStopped){i.hasError=i.isStopped=!0,i.thrownError=t;for(var o=i.observers;o.length;)o.shift().error(t)}})},e.prototype.complete=function(){var t=this;fi(function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var i=t.observers;i.length;)i.shift().complete()}})},e.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(e.prototype,"observed",{get:function(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0},enumerable:!1,configurable:!0}),e.prototype._trySubscribe=function(t){return this._throwIfClosed(),r.prototype._trySubscribe.call(this,t)},e.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},e.prototype._innerSubscribe=function(t){var i=this,o=this,n=o.hasError,a=o.isStopped,s=o.observers;return n||a?gl:(this.currentObservers=null,s.push(t),new $i(function(){i.currentObservers=null,Ro(s,t)}))},e.prototype._checkFinalizedStatuses=function(t){var i=this,o=i.hasError,n=i.thrownError,a=i.isStopped;o?t.error(n):a&&t.complete()},e.prototype.asObservable=function(){var t=new Aa;return t.source=this,t},e.create=function(t,i){return new Ia(t,i)},e}(Aa),Ia=function(r){Wr(e,r);function e(t,i){var o=r.call(this)||this;return o.destination=t,o.source=i,o}return e.prototype.next=function(t){var i,o;(o=(i=this.destination)===null||i===void 0?void 0:i.next)===null||o===void 0||o.call(i,t)},e.prototype.error=function(t){var i,o;(o=(i=this.destination)===null||i===void 0?void 0:i.error)===null||o===void 0||o.call(i,t)},e.prototype.complete=function(){var t,i;(i=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||i===void 0||i.call(t)},e.prototype._subscribe=function(t){var i,o;return(o=(i=this.source)===null||i===void 0?void 0:i.subscribe(t))!==null&&o!==void 0?o:gl},e}(wl),xl={now:function(){return(xl.delegate||Date).now()},delegate:void 0},Wc=function(r){Wr(e,r);function e(t,i,o){t===void 0&&(t=1/0),i===void 0&&(i=1/0),o===void 0&&(o=xl);var n=r.call(this)||this;return n._bufferSize=t,n._windowTime=i,n._timestampProvider=o,n._buffer=[],n._infiniteTimeWindow=!0,n._infiniteTimeWindow=i===1/0,n._bufferSize=Math.max(1,t),n._windowTime=Math.max(1,i),n}return e.prototype.next=function(t){var i=this,o=i.isStopped,n=i._buffer,a=i._infiniteTimeWindow,s=i._timestampProvider,l=i._windowTime;o||(n.push(t),!a&&n.push(s.now()+l)),this._trimBuffer(),r.prototype.next.call(this,t)},e.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var i=this._innerSubscribe(t),o=this,n=o._infiniteTimeWindow,a=o._buffer,s=a.slice(),l=0;l<s.length&&!t.closed;l+=n?1:2)t.next(s[l]);return this._checkFinalizedStatuses(t),i},e.prototype._trimBuffer=function(){var t=this,i=t._bufferSize,o=t._timestampProvider,n=t._buffer,a=t._infiniteTimeWindow,s=(a?1:2)*i;if(i<1/0&&s<n.length&&n.splice(0,n.length-s),!a){for(var l=o.now(),d=0,u=1;u<n.length&&n[u]<=l;u+=2)d=u;d&&n.splice(0,d+1)}},e}(wl);const Sa=[],Da={},jc=(r,e=0)=>{if(Sa.indexOf(r)==-1){const t=new Wc(e);Da[r]=t,Sa.push(r)}return Da[r]},Dt=[];function qc(r,e){return{subscribe:Vi(r,e).subscribe}}function Vi(r,e=Oe){let t;const i=new Set;function o(s){if(Tn(r,s)&&(r=s,t)){const l=!Dt.length;for(const d of i)d[1](),Dt.push(d,r);if(l){for(let d=0;d<Dt.length;d+=2)Dt[d][0](Dt[d+1]);Dt.length=0}}}function n(s){o(s(r))}function a(s,l=Oe){const d=[s,l];return i.add(d),i.size===1&&(t=e(o,n)||Oe),s(r),()=>{i.delete(d),i.size===0&&t&&(t(),t=null)}}return{set:o,update:n,subscribe:a}}function er(r,e,t){const i=!Array.isArray(r),o=i?[r]:r;if(!o.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");const n=e.length<2;return qc(t,(a,s)=>{let l=!1;const d=[];let u=0,c=Oe;const h=()=>{if(u)return;c();const m=e(i?d[0]:d,a,s);n?a(m):c=En(m)?m:Oe},p=o.map((m,f)=>nl(m,y=>{d[f]=y,u&=~(1<<f),l&&h()},()=>{u|=1<<f}));return l=!0,h(),function(){Zt(p),c(),l=!1}})}function Yc(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var Gc=function(e){return Xc(e)&&!Kc(e)};function Xc(r){return!!r&&typeof r=="object"}function Kc(r){var e=Object.prototype.toString.call(r);return e==="[object RegExp]"||e==="[object Date]"||Zc(r)}var Qc=typeof Symbol=="function"&&Symbol.for,Jc=Qc?Symbol.for("react.element"):60103;function Zc(r){return r.$$typeof===Jc}function eh(r){return Array.isArray(r)?[]:{}}function Sr(r,e){return e.clone!==!1&&e.isMergeableObject(r)?Wt(eh(r),r,e):r}function th(r,e,t){return r.concat(e).map(function(i){return Sr(i,t)})}function rh(r,e){if(!e.customMerge)return Wt;var t=e.customMerge(r);return typeof t=="function"?t:Wt}function ih(r){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(r).filter(function(e){return Object.propertyIsEnumerable.call(r,e)}):[]}function Oa(r){return Object.keys(r).concat(ih(r))}function Cl(r,e){try{return e in r}catch(t){return!1}}function oh(r,e){return Cl(r,e)&&!(Object.hasOwnProperty.call(r,e)&&Object.propertyIsEnumerable.call(r,e))}function nh(r,e,t){var i={};return t.isMergeableObject(r)&&Oa(r).forEach(function(o){i[o]=Sr(r[o],t)}),Oa(e).forEach(function(o){oh(r,o)||(Cl(r,o)&&t.isMergeableObject(e[o])?i[o]=rh(o,t)(r[o],e[o],t):i[o]=Sr(e[o],t))}),i}function Wt(r,e,t){t=t||{},t.arrayMerge=t.arrayMerge||th,t.isMergeableObject=t.isMergeableObject||Gc,t.cloneUnlessOtherwiseSpecified=Sr;var i=Array.isArray(e),o=Array.isArray(r),n=i===o;return n?i?t.arrayMerge(r,e,t):nh(r,e,t):Sr(e,t)}Wt.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(i,o){return Wt(i,o,t)},{})};var ah=Wt,sh=ah;const lh=Yc(sh);var $o=function(r,e){return $o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(t[o]=i[o])},$o(r,e)};function Ui(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");$o(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var $e=function(){return $e=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},$e.apply(this,arguments)};function dh(r,e){var t={};for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,i=Object.getOwnPropertySymbols(r);o<i.length;o++)e.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(r,i[o])&&(t[i[o]]=r[i[o]]);return t}function co(r,e,t){if(t||arguments.length===2)for(var i=0,o=e.length,n;i<o;i++)(n||!(i in e))&&(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return r.concat(n||Array.prototype.slice.call(e))}function ho(r,e){var t=e&&e.cache?e.cache:_h,i=e&&e.serializer?e.serializer:mh,o=e&&e.strategy?e.strategy:hh;return o(r,{cache:t,serializer:i})}function uh(r){return r==null||typeof r=="number"||typeof r=="boolean"}function ch(r,e,t,i){var o=uh(i)?i:t(i),n=e.get(o);return typeof n=="undefined"&&(n=r.call(this,i),e.set(o,n)),n}function El(r,e,t){var i=Array.prototype.slice.call(arguments,3),o=t(i),n=e.get(o);return typeof n=="undefined"&&(n=r.apply(this,i),e.set(o,n)),n}function Tl(r,e,t,i,o){return t.bind(e,r,i,o)}function hh(r,e){var t=r.length===1?ch:El;return Tl(r,this,t,e.cache.create(),e.serializer)}function ph(r,e){return Tl(r,this,El,e.cache.create(),e.serializer)}var mh=function(){return JSON.stringify(arguments)},fh=function(){function r(){this.cache=Object.create(null)}return r.prototype.get=function(e){return this.cache[e]},r.prototype.set=function(e,t){this.cache[e]=t},r}(),_h={create:function(){return new fh}},po={variadic:ph},xi=function(){return xi=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},xi.apply(this,arguments)};var N;(function(r){r[r.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",r[r.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",r[r.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",r[r.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",r[r.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",r[r.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",r[r.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",r[r.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",r[r.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",r[r.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",r[r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",r[r.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",r[r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",r[r.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",r[r.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",r[r.INVALID_TAG=23]="INVALID_TAG",r[r.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",r[r.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",r[r.UNCLOSED_TAG=27]="UNCLOSED_TAG"})(N||(N={}));var Z;(function(r){r[r.literal=0]="literal",r[r.argument=1]="argument",r[r.number=2]="number",r[r.date=3]="date",r[r.time=4]="time",r[r.select=5]="select",r[r.plural=6]="plural",r[r.pound=7]="pound",r[r.tag=8]="tag"})(Z||(Z={}));var jt;(function(r){r[r.number=0]="number",r[r.dateTime=1]="dateTime"})(jt||(jt={}));function Na(r){return r.type===Z.literal}function vh(r){return r.type===Z.argument}function Pl(r){return r.type===Z.number}function Al(r){return r.type===Z.date}function kl(r){return r.type===Z.time}function Il(r){return r.type===Z.select}function Sl(r){return r.type===Z.plural}function gh(r){return r.type===Z.pound}function Dl(r){return r.type===Z.tag}function Ol(r){return!!(r&&typeof r=="object"&&r.type===jt.number)}function Vo(r){return!!(r&&typeof r=="object"&&r.type===jt.dateTime)}var Nl=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,bh=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function yh(r){var e={};return r.replace(bh,function(t){var i=t.length;switch(t[0]){case"G":e.era=i===4?"long":i===5?"narrow":"short";break;case"y":e.year=i===2?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":e.month=["numeric","2-digit","short","long","narrow"][i-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":e.day=["numeric","2-digit"][i-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":e.weekday=i===4?"long":i===5?"narrow":"short";break;case"e":if(i<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][i-4];break;case"c":if(i<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][i-4];break;case"a":e.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":e.hourCycle="h12",e.hour=["numeric","2-digit"][i-1];break;case"H":e.hourCycle="h23",e.hour=["numeric","2-digit"][i-1];break;case"K":e.hourCycle="h11",e.hour=["numeric","2-digit"][i-1];break;case"k":e.hourCycle="h24",e.hour=["numeric","2-digit"][i-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":e.minute=["numeric","2-digit"][i-1];break;case"s":e.second=["numeric","2-digit"][i-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":e.timeZoneName=i<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),e}var ne=function(){return ne=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},ne.apply(this,arguments)};var wh=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function xh(r){if(r.length===0)throw new Error("Number skeleton cannot be empty");for(var e=r.split(wh).filter(function(h){return h.length>0}),t=[],i=0,o=e;i<o.length;i++){var n=o[i],a=n.split("/");if(a.length===0)throw new Error("Invalid number skeleton");for(var s=a[0],l=a.slice(1),d=0,u=l;d<u.length;d++){var c=u[d];if(c.length===0)throw new Error("Invalid number skeleton")}t.push({stem:s,options:l})}return t}function Ch(r){return r.replace(/^(.*?)-/,"")}var Ma=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,Ml=/^(@+)?(\+|#+)?[rs]?$/g,Eh=/(\*)(0+)|(#+)(0+)|(0+)/g,Bl=/^(0+)$/;function Ba(r){var e={};return r[r.length-1]==="r"?e.roundingPriority="morePrecision":r[r.length-1]==="s"&&(e.roundingPriority="lessPrecision"),r.replace(Ml,function(t,i,o){return typeof o!="string"?(e.minimumSignificantDigits=i.length,e.maximumSignificantDigits=i.length):o==="+"?e.minimumSignificantDigits=i.length:i[0]==="#"?e.maximumSignificantDigits=i.length:(e.minimumSignificantDigits=i.length,e.maximumSignificantDigits=i.length+(typeof o=="string"?o.length:0)),""}),e}function Ll(r){switch(r){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 Th(r){var e;if(r[0]==="E"&&r[1]==="E"?(e={notation:"engineering"},r=r.slice(2)):r[0]==="E"&&(e={notation:"scientific"},r=r.slice(1)),e){var t=r.slice(0,2);if(t==="+!"?(e.signDisplay="always",r=r.slice(2)):t==="+?"&&(e.signDisplay="exceptZero",r=r.slice(2)),!Bl.test(r))throw new Error("Malformed concise eng/scientific notation");e.minimumIntegerDigits=r.length}return e}function La(r){var e={},t=Ll(r);return t||e}function Ph(r){for(var e={},t=0,i=r;t<i.length;t++){var o=i[t];switch(o.stem){case"percent":case"%":e.style="percent";continue;case"%x100":e.style="percent",e.scale=100;continue;case"currency":e.style="currency",e.currency=o.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=Ch(o.options[0]);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=ne(ne(ne({},e),{notation:"scientific"}),o.options.reduce(function(l,d){return ne(ne({},l),La(d))},{}));continue;case"engineering":e=ne(ne(ne({},e),{notation:"engineering"}),o.options.reduce(function(l,d){return ne(ne({},l),La(d))},{}));continue;case"notation-simple":e.notation="standard";continue;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(o.options[0]);continue;case"rounding-mode-floor":e.roundingMode="floor";continue;case"rounding-mode-ceiling":e.roundingMode="ceil";continue;case"rounding-mode-down":e.roundingMode="trunc";continue;case"rounding-mode-up":e.roundingMode="expand";continue;case"rounding-mode-half-even":e.roundingMode="halfEven";continue;case"rounding-mode-half-down":e.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":e.roundingMode="halfExpand";continue;case"integer-width":if(o.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");o.options[0].replace(Eh,function(l,d,u,c,h,p){if(d)e.minimumIntegerDigits=u.length;else{if(c&&h)throw new Error("We currently do not support maximum integer digits");if(p)throw new Error("We currently do not support exact integer digits")}return""});continue}if(Bl.test(o.stem)){e.minimumIntegerDigits=o.stem.length;continue}if(Ma.test(o.stem)){if(o.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");o.stem.replace(Ma,function(l,d,u,c,h,p){return u==="*"?e.minimumFractionDigits=d.length:c&&c[0]==="#"?e.maximumFractionDigits=c.length:h&&p?(e.minimumFractionDigits=h.length,e.maximumFractionDigits=h.length+p.length):(e.minimumFractionDigits=d.length,e.maximumFractionDigits=d.length),""});var n=o.options[0];n==="w"?e=ne(ne({},e),{trailingZeroDisplay:"stripIfInteger"}):n&&(e=ne(ne({},e),Ba(n)));continue}if(Ml.test(o.stem)){e=ne(ne({},e),Ba(o.stem));continue}var a=Ll(o.stem);a&&(e=ne(ne({},e),a));var s=Th(o.stem);s&&(e=ne(ne({},e),s))}return e}var ni={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function Ah(r,e){for(var t="",i=0;i<r.length;i++){var o=r.charAt(i);if(o==="j"){for(var n=0;i+1<r.length&&r.charAt(i+1)===o;)n++,i++;var a=1+(n&1),s=n<2?1:3+(n>>1),l="a",d=kh(e);for((d=="H"||d=="k")&&(s=0);s-- >0;)t+=l;for(;a-- >0;)t=d+t}else o==="J"?t+="H":t+=o}return t}function kh(r){var e=r.hourCycle;if(e===void 0&&r.hourCycles&&r.hourCycles.length&&(e=r.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")}var t=r.language,i;t!=="root"&&(i=r.maximize().region);var o=ni[i||""]||ni[t||""]||ni["".concat(t,"-001")]||ni["001"];return o[0]}var mo,Ih=new RegExp("^".concat(Nl.source,"*")),Sh=new RegExp("".concat(Nl.source,"*$"));function H(r,e){return{start:r,end:e}}var Dh=!!String.prototype.startsWith&&"_a".startsWith("a",1),Oh=!!String.fromCodePoint,Nh=!!Object.fromEntries,Mh=!!String.prototype.codePointAt,Bh=!!String.prototype.trimStart,Lh=!!String.prototype.trimEnd,zh=!!Number.isSafeInteger,Hh=zh?Number.isSafeInteger:function(r){return typeof r=="number"&&isFinite(r)&&Math.floor(r)===r&&Math.abs(r)<=9007199254740991},Uo=!0;try{var Rh=Hl("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");Uo=((mo=Rh.exec("a"))===null||mo===void 0?void 0:mo[0])==="a"}catch(r){Uo=!1}var za=Dh?function(e,t,i){return e.startsWith(t,i)}:function(e,t,i){return e.slice(i,i+t.length)===t},Wo=Oh?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var i="",o=e.length,n=0,a;o>n;){if(a=e[n++],a>1114111)throw RangeError(a+" is not a valid code point");i+=a<65536?String.fromCharCode(a):String.fromCharCode(((a-=65536)>>10)+55296,a%1024+56320)}return i},Ha=Nh?Object.fromEntries:function(e){for(var t={},i=0,o=e;i<o.length;i++){var n=o[i],a=n[0],s=n[1];t[a]=s}return t},zl=Mh?function(e,t){return e.codePointAt(t)}:function(e,t){var i=e.length;if(!(t<0||t>=i)){var o=e.charCodeAt(t),n;return o<55296||o>56319||t+1===i||(n=e.charCodeAt(t+1))<56320||n>57343?o:(o-55296<<10)+(n-56320)+65536}},Fh=Bh?function(e){return e.trimStart()}:function(e){return e.replace(Ih,"")},$h=Lh?function(e){return e.trimEnd()}:function(e){return e.replace(Sh,"")};function Hl(r,e){return new RegExp(r,e)}var jo;if(Uo){var Ra=Hl("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");jo=function(e,t){var i;Ra.lastIndex=t;var o=Ra.exec(e);return(i=o[1])!==null&&i!==void 0?i:""}}else jo=function(e,t){for(var i=[];;){var o=zl(e,t);if(o===void 0||Rl(o)||jh(o))break;i.push(o),t+=o>=65536?2:1}return Wo.apply(void 0,i)};var Vh=function(){function r(e,t){t===void 0&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return r.prototype.parse=function(){if(this.offset()!==0)throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},r.prototype.parseMessage=function(e,t,i){for(var o=[];!this.isEOF();){var n=this.char();if(n===123){var a=this.parseArgument(e,i);if(a.err)return a;o.push(a.val)}else{if(n===125&&e>0)break;if(n===35&&(t==="plural"||t==="selectordinal")){var s=this.clonePosition();this.bump(),o.push({type:Z.pound,location:H(s,this.clonePosition())})}else if(n===60&&!this.ignoreTag&&this.peek()===47){if(i)break;return this.error(N.UNMATCHED_CLOSING_TAG,H(this.clonePosition(),this.clonePosition()))}else if(n===60&&!this.ignoreTag&&qo(this.peek()||0)){var a=this.parseTag(e,t);if(a.err)return a;o.push(a.val)}else{var a=this.parseLiteral(e,t);if(a.err)return a;o.push(a.val)}}}return{val:o,err:null}},r.prototype.parseTag=function(e,t){var i=this.clonePosition();this.bump();var o=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:Z.literal,value:"<".concat(o,"/>"),location:H(i,this.clonePosition())},err:null};if(this.bumpIf(">")){var n=this.parseMessage(e+1,t,!0);if(n.err)return n;var a=n.val,s=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!qo(this.char()))return this.error(N.INVALID_TAG,H(s,this.clonePosition()));var l=this.clonePosition(),d=this.parseTagName();return o!==d?this.error(N.UNMATCHED_CLOSING_TAG,H(l,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:Z.tag,value:o,children:a,location:H(i,this.clonePosition())},err:null}:this.error(N.INVALID_TAG,H(s,this.clonePosition())))}else return this.error(N.UNCLOSED_TAG,H(i,this.clonePosition()))}else return this.error(N.INVALID_TAG,H(i,this.clonePosition()))},r.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&Wh(this.char());)this.bump();return this.message.slice(e,this.offset())},r.prototype.parseLiteral=function(e,t){for(var i=this.clonePosition(),o="";;){var n=this.tryParseQuote(t);if(n){o+=n;continue}var a=this.tryParseUnquoted(e,t);if(a){o+=a;continue}var s=this.tryParseLeftAngleBracket();if(s){o+=s;continue}break}var l=H(i,this.clonePosition());return{val:{type:Z.literal,value:o,location:l},err:null}},r.prototype.tryParseLeftAngleBracket=function(){return!this.isEOF()&&this.char()===60&&(this.ignoreTag||!Uh(this.peek()||0))?(this.bump(),"<"):null},r.prototype.tryParseQuote=function(e){if(this.isEOF()||this.char()!==39)return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if(e==="plural"||e==="selectordinal")break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var i=this.char();if(i===39)if(this.peek()===39)t.push(39),this.bump();else{this.bump();break}else t.push(i);this.bump()}return Wo.apply(void 0,t)},r.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var i=this.char();return i===60||i===123||i===35&&(t==="plural"||t==="selectordinal")||i===125&&e>0?null:(this.bump(),Wo(i))},r.prototype.parseArgument=function(e,t){var i=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(N.EXPECT_ARGUMENT_CLOSING_BRACE,H(i,this.clonePosition()));if(this.char()===125)return this.bump(),this.error(N.EMPTY_ARGUMENT,H(i,this.clonePosition()));var o=this.parseIdentifierIfPossible().value;if(!o)return this.error(N.MALFORMED_ARGUMENT,H(i,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(N.EXPECT_ARGUMENT_CLOSING_BRACE,H(i,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:Z.argument,value:o,location:H(i,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(N.EXPECT_ARGUMENT_CLOSING_BRACE,H(i,this.clonePosition())):this.parseArgumentOptions(e,t,o,i);default:return this.error(N.MALFORMED_ARGUMENT,H(i,this.clonePosition()))}},r.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),i=jo(this.message,t),o=t+i.length;this.bumpTo(o);var n=this.clonePosition(),a=H(e,n);return{value:i,location:a}},r.prototype.parseArgumentOptions=function(e,t,i,o){var n,a=this.clonePosition(),s=this.parseIdentifierIfPossible().value,l=this.clonePosition();switch(s){case"":return this.error(N.EXPECT_ARGUMENT_TYPE,H(a,l));case"number":case"date":case"time":{this.bumpSpace();var d=null;if(this.bumpIf(",")){this.bumpSpace();var u=this.clonePosition(),c=this.parseSimpleArgStyleIfPossible();if(c.err)return c;var h=$h(c.val);if(h.length===0)return this.error(N.EXPECT_ARGUMENT_STYLE,H(this.clonePosition(),this.clonePosition()));var p=H(u,this.clonePosition());d={style:h,styleLocation:p}}var m=this.tryParseArgumentClose(o);if(m.err)return m;var f=H(o,this.clonePosition());if(d&&za(d==null?void 0:d.style,"::",0)){var y=Fh(d.style.slice(2));if(s==="number"){var c=this.parseNumberSkeletonFromString(y,d.styleLocation);return c.err?c:{val:{type:Z.number,value:i,location:f,style:c.val},err:null}}else{if(y.length===0)return this.error(N.EXPECT_DATE_TIME_SKELETON,f);var E=y;this.locale&&(E=Ah(y,this.locale));var h={type:jt.dateTime,pattern:E,location:d.styleLocation,parsedOptions:this.shouldParseSkeletons?yh(E):{}},x=s==="date"?Z.date:Z.time;return{val:{type:x,value:i,location:f,style:h},err:null}}}return{val:{type:s==="number"?Z.number:s==="date"?Z.date:Z.time,value:i,location:f,style:(n=d==null?void 0:d.style)!==null&&n!==void 0?n:null},err:null}}case"plural":case"selectordinal":case"select":{var A=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(N.EXPECT_SELECT_ARGUMENT_OPTIONS,H(A,xi({},A)));this.bumpSpace();var D=this.parseIdentifierIfPossible(),j=0;if(s!=="select"&&D.value==="offset"){if(!this.bumpIf(":"))return this.error(N.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,H(this.clonePosition(),this.clonePosition()));this.bumpSpace();var c=this.tryParseDecimalInteger(N.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,N.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(c.err)return c;this.bumpSpace(),D=this.parseIdentifierIfPossible(),j=c.val}var $=this.tryParsePluralOrSelectOptions(e,s,t,D);if($.err)return $;var m=this.tryParseArgumentClose(o);if(m.err)return m;var J=H(o,this.clonePosition());return s==="select"?{val:{type:Z.select,value:i,options:Ha($.val),location:J},err:null}:{val:{type:Z.plural,value:i,options:Ha($.val),offset:j,pluralType:s==="plural"?"cardinal":"ordinal",location:J},err:null}}default:return this.error(N.INVALID_ARGUMENT_TYPE,H(a,l))}},r.prototype.tryParseArgumentClose=function(e){return this.isEOF()||this.char()!==125?this.error(N.EXPECT_ARGUMENT_CLOSING_BRACE,H(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},r.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){var i=this.char();switch(i){case 39:{this.bump();var o=this.clonePosition();if(!this.bumpUntil("'"))return this.error(N.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,H(o,this.clonePosition()));this.bump();break}case 123:{e+=1,this.bump();break}case 125:{if(e>0)e-=1;else return{val:this.message.slice(t.offset,this.offset()),err:null};break}default:this.bump();break}}return{val:this.message.slice(t.offset,this.offset()),err:null}},r.prototype.parseNumberSkeletonFromString=function(e,t){var i=[];try{i=xh(e)}catch(o){return this.error(N.INVALID_NUMBER_SKELETON,t)}return{val:{type:jt.number,tokens:i,location:t,parsedOptions:this.shouldParseSkeletons?Ph(i):{}},err:null}},r.prototype.tryParsePluralOrSelectOptions=function(e,t,i,o){for(var n,a=!1,s=[],l=new Set,d=o.value,u=o.location;;){if(d.length===0){var c=this.clonePosition();if(t!=="select"&&this.bumpIf("=")){var h=this.tryParseDecimalInteger(N.EXPECT_PLURAL_ARGUMENT_SELECTOR,N.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;u=H(c,this.clonePosition()),d=this.message.slice(c.offset,this.offset())}else break}if(l.has(d))return this.error(t==="select"?N.DUPLICATE_SELECT_ARGUMENT_SELECTOR:N.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,u);d==="other"&&(a=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error(t==="select"?N.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:N.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,H(this.clonePosition(),this.clonePosition()));var m=this.parseMessage(e+1,t,i);if(m.err)return m;var f=this.tryParseArgumentClose(p);if(f.err)return f;s.push([d,{value:m.val,location:H(p,this.clonePosition())}]),l.add(d),this.bumpSpace(),n=this.parseIdentifierIfPossible(),d=n.value,u=n.location}return s.length===0?this.error(t==="select"?N.EXPECT_SELECT_ARGUMENT_SELECTOR:N.EXPECT_PLURAL_ARGUMENT_SELECTOR,H(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!a?this.error(N.MISSING_OTHER_CLAUSE,H(this.clonePosition(),this.clonePosition())):{val:s,err:null}},r.prototype.tryParseDecimalInteger=function(e,t){var i=1,o=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(i=-1);for(var n=!1,a=0;!this.isEOF();){var s=this.char();if(s>=48&&s<=57)n=!0,a=a*10+(s-48),this.bump();else break}var l=H(o,this.clonePosition());return n?(a*=i,Hh(a)?{val:a,err:null}:this.error(t,l)):this.error(e,l)},r.prototype.offset=function(){return this.position.offset},r.prototype.isEOF=function(){return this.offset()===this.message.length},r.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},r.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=zl(this.message,e);if(t===void 0)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},r.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},r.prototype.bump=function(){if(!this.isEOF()){var e=this.char();e===10?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},r.prototype.bumpIf=function(e){if(za(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},r.prototype.bumpUntil=function(e){var t=this.offset(),i=this.message.indexOf(e,t);return i>=0?(this.bumpTo(i),!0):(this.bumpTo(this.message.length),!1)},r.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},r.prototype.bumpSpace=function(){for(;!this.isEOF()&&Rl(this.char());)this.bump()},r.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),i=this.message.charCodeAt(t+(e>=65536?2:1));return i!=null?i:null},r}();function qo(r){return r>=97&&r<=122||r>=65&&r<=90}function Uh(r){return qo(r)||r===47}function Wh(r){return r===45||r===46||r>=48&&r<=57||r===95||r>=97&&r<=122||r>=65&&r<=90||r==183||r>=192&&r<=214||r>=216&&r<=246||r>=248&&r<=893||r>=895&&r<=8191||r>=8204&&r<=8205||r>=8255&&r<=8256||r>=8304&&r<=8591||r>=11264&&r<=12271||r>=12289&&r<=55295||r>=63744&&r<=64975||r>=65008&&r<=65533||r>=65536&&r<=983039}function Rl(r){return r>=9&&r<=13||r===32||r===133||r>=8206&&r<=8207||r===8232||r===8233}function jh(r){return r>=33&&r<=35||r===36||r>=37&&r<=39||r===40||r===41||r===42||r===43||r===44||r===45||r>=46&&r<=47||r>=58&&r<=59||r>=60&&r<=62||r>=63&&r<=64||r===91||r===92||r===93||r===94||r===96||r===123||r===124||r===125||r===126||r===161||r>=162&&r<=165||r===166||r===167||r===169||r===171||r===172||r===174||r===176||r===177||r===182||r===187||r===191||r===215||r===247||r>=8208&&r<=8213||r>=8214&&r<=8215||r===8216||r===8217||r===8218||r>=8219&&r<=8220||r===8221||r===8222||r===8223||r>=8224&&r<=8231||r>=8240&&r<=8248||r===8249||r===8250||r>=8251&&r<=8254||r>=8257&&r<=8259||r===8260||r===8261||r===8262||r>=8263&&r<=8273||r===8274||r===8275||r>=8277&&r<=8286||r>=8592&&r<=8596||r>=8597&&r<=8601||r>=8602&&r<=8603||r>=8604&&r<=8607||r===8608||r>=8609&&r<=8610||r===8611||r>=8612&&r<=8613||r===8614||r>=8615&&r<=8621||r===8622||r>=8623&&r<=8653||r>=8654&&r<=8655||r>=8656&&r<=8657||r===8658||r===8659||r===8660||r>=8661&&r<=8691||r>=8692&&r<=8959||r>=8960&&r<=8967||r===8968||r===8969||r===8970||r===8971||r>=8972&&r<=8991||r>=8992&&r<=8993||r>=8994&&r<=9e3||r===9001||r===9002||r>=9003&&r<=9083||r===9084||r>=9085&&r<=9114||r>=9115&&r<=9139||r>=9140&&r<=9179||r>=9180&&r<=9185||r>=9186&&r<=9254||r>=9255&&r<=9279||r>=9280&&r<=9290||r>=9291&&r<=9311||r>=9472&&r<=9654||r===9655||r>=9656&&r<=9664||r===9665||r>=9666&&r<=9719||r>=9720&&r<=9727||r>=9728&&r<=9838||r===9839||r>=9840&&r<=10087||r===10088||r===10089||r===10090||r===10091||r===10092||r===10093||r===10094||r===10095||r===10096||r===10097||r===10098||r===10099||r===10100||r===10101||r>=10132&&r<=10175||r>=10176&&r<=10180||r===10181||r===10182||r>=10183&&r<=10213||r===10214||r===10215||r===10216||r===10217||r===10218||r===10219||r===10220||r===10221||r===10222||r===10223||r>=10224&&r<=10239||r>=10240&&r<=10495||r>=10496&&r<=10626||r===10627||r===10628||r===10629||r===10630||r===10631||r===10632||r===10633||r===10634||r===10635||r===10636||r===10637||r===10638||r===10639||r===10640||r===10641||r===10642||r===10643||r===10644||r===10645||r===10646||r===10647||r===10648||r>=10649&&r<=10711||r===10712||r===10713||r===10714||r===10715||r>=10716&&r<=10747||r===10748||r===10749||r>=10750&&r<=11007||r>=11008&&r<=11055||r>=11056&&r<=11076||r>=11077&&r<=11078||r>=11079&&r<=11084||r>=11085&&r<=11123||r>=11124&&r<=11125||r>=11126&&r<=11157||r===11158||r>=11159&&r<=11263||r>=11776&&r<=11777||r===11778||r===11779||r===11780||r===11781||r>=11782&&r<=11784||r===11785||r===11786||r===11787||r===11788||r===11789||r>=11790&&r<=11798||r===11799||r>=11800&&r<=11801||r===11802||r===11803||r===11804||r===11805||r>=11806&&r<=11807||r===11808||r===11809||r===11810||r===11811||r===11812||r===11813||r===11814||r===11815||r===11816||r===11817||r>=11818&&r<=11822||r===11823||r>=11824&&r<=11833||r>=11834&&r<=11835||r>=11836&&r<=11839||r===11840||r===11841||r===11842||r>=11843&&r<=11855||r>=11856&&r<=11857||r===11858||r>=11859&&r<=11903||r>=12289&&r<=12291||r===12296||r===12297||r===12298||r===12299||r===12300||r===12301||r===12302||r===12303||r===12304||r===12305||r>=12306&&r<=12307||r===12308||r===12309||r===12310||r===12311||r===12312||r===12313||r===12314||r===12315||r===12316||r===12317||r>=12318&&r<=12319||r===12320||r===12336||r===64830||r===64831||r>=65093&&r<=65094}function Yo(r){r.forEach(function(e){if(delete e.location,Il(e)||Sl(e))for(var t in e.options)delete e.options[t].location,Yo(e.options[t].value);else Pl(e)&&Ol(e.style)||(Al(e)||kl(e))&&Vo(e.style)?delete e.style.location:Dl(e)&&Yo(e.children)})}function qh(r,e){e===void 0&&(e={}),e=xi({shouldParseSkeletons:!0,requiresOtherClause:!0},e);var t=new Vh(r,e).parse();if(t.err){var i=SyntaxError(N[t.err.kind]);throw i.location=t.err.location,i.originalMessage=t.err.message,i}return e!=null&&e.captureLocation||Yo(t.val),t.val}var qt;(function(r){r.MISSING_VALUE="MISSING_VALUE",r.INVALID_VALUE="INVALID_VALUE",r.MISSING_INTL_API="MISSING_INTL_API"})(qt||(qt={}));var Wi=function(r){Ui(e,r);function e(t,i,o){var n=r.call(this,t)||this;return n.code=i,n.originalMessage=o,n}return e.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},e}(Error),Fa=function(r){Ui(e,r);function e(t,i,o,n){return r.call(this,'Invalid values for "'.concat(t,'": "').concat(i,'". Options are "').concat(Object.keys(o).join('", "'),'"'),qt.INVALID_VALUE,n)||this}return e}(Wi),Yh=function(r){Ui(e,r);function e(t,i,o){return r.call(this,'Value for "'.concat(t,'" must be of type ').concat(i),qt.INVALID_VALUE,o)||this}return e}(Wi),Gh=function(r){Ui(e,r);function e(t,i){return r.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(i,'"'),qt.MISSING_VALUE,i)||this}return e}(Wi),we;(function(r){r[r.literal=0]="literal",r[r.object=1]="object"})(we||(we={}));function Xh(r){return r.length<2?r:r.reduce(function(e,t){var i=e[e.length-1];return!i||i.type!==we.literal||t.type!==we.literal?e.push(t):i.value+=t.value,e},[])}function Kh(r){return typeof r=="function"}function _i(r,e,t,i,o,n,a){if(r.length===1&&Na(r[0]))return[{type:we.literal,value:r[0].value}];for(var s=[],l=0,d=r;l<d.length;l++){var u=d[l];if(Na(u)){s.push({type:we.literal,value:u.value});continue}if(gh(u)){typeof n=="number"&&s.push({type:we.literal,value:t.getNumberFormat(e).format(n)});continue}var c=u.value;if(!(o&&c in o))throw new Gh(c,a);var h=o[c];if(vh(u)){(!h||typeof h=="string"||typeof h=="number")&&(h=typeof h=="string"||typeof h=="number"?String(h):""),s.push({type:typeof h=="string"?we.literal:we.object,value:h});continue}if(Al(u)){var p=typeof u.style=="string"?i.date[u.style]:Vo(u.style)?u.style.parsedOptions:void 0;s.push({type:we.literal,value:t.getDateTimeFormat(e,p).format(h)});continue}if(kl(u)){var p=typeof u.style=="string"?i.time[u.style]:Vo(u.style)?u.style.parsedOptions:i.time.medium;s.push({type:we.literal,value:t.getDateTimeFormat(e,p).format(h)});continue}if(Pl(u)){var p=typeof u.style=="string"?i.number[u.style]:Ol(u.style)?u.style.parsedOptions:void 0;p&&p.scale&&(h=h*(p.scale||1)),s.push({type:we.literal,value:t.getNumberFormat(e,p).format(h)});continue}if(Dl(u)){var m=u.children,f=u.value,y=o[f];if(!Kh(y))throw new Yh(f,"function",a);var E=_i(m,e,t,i,o,n),x=y(E.map(function(j){return j.value}));Array.isArray(x)||(x=[x]),s.push.apply(s,x.map(function(j){return{type:typeof j=="string"?we.literal:we.object,value:j}}))}if(Il(u)){var A=u.options[h]||u.options.other;if(!A)throw new Fa(u.value,h,Object.keys(u.options),a);s.push.apply(s,_i(A.value,e,t,i,o));continue}if(Sl(u)){var A=u.options["=".concat(h)];if(!A){if(!Intl.PluralRules)throw new Wi(`Intl.PluralRules is not available in this environment.
|
|
16
|
+
`):"",this.name="UnsubscriptionError",this.errors=t}});function Ro(r,e){if(r){var t=r.indexOf(e);0<=t&&r.splice(t,1)}}var $i=function(){function r(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return r.prototype.unsubscribe=function(){var e,t,i,o,n;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var s=Lo(a),l=s.next();!l.done;l=s.next()){var d=l.value;d.remove(this)}}catch(f){e={error:f}}finally{try{l&&!l.done&&(t=s.return)&&t.call(s)}finally{if(e)throw e.error}}else a.remove(this);var u=this.initialTeardown;if(Ge(u))try{u()}catch(f){n=f instanceof uo?f.errors:[f]}var c=this._finalizers;if(c){this._finalizers=null;try{for(var h=Lo(c),p=h.next();!p.done;p=h.next()){var m=p.value;try{Ta(m)}catch(f){n=n!=null?n:[],f instanceof uo?n=Ho(Ho([],zo(n)),zo(f.errors)):n.push(f)}}}catch(f){i={error:f}}finally{try{p&&!p.done&&(o=h.return)&&o.call(h)}finally{if(i)throw i.error}}}if(n)throw new uo(n)}},r.prototype.add=function(e){var t;if(e&&e!==this)if(this.closed)Ta(e);else{if(e instanceof r){if(e.closed||e._hasParent(this))return;e._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(e)}},r.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},r.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},r.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&Ro(t,e)},r.prototype.remove=function(e){var t=this._finalizers;t&&Ro(t,e),e instanceof r&&e._removeParent(this)},r.EMPTY=function(){var e=new r;return e.closed=!0,e}(),r}(),gl=$i.EMPTY;function bl(r){return r instanceof $i||r&&"closed"in r&&Ge(r.remove)&&Ge(r.add)&&Ge(r.unsubscribe)}function Ta(r){Ge(r)?r():r.unsubscribe()}var Nc={Promise:void 0},Mc={setTimeout:function(r,e){for(var t=[],i=2;i<arguments.length;i++)t[i-2]=arguments[i];return setTimeout.apply(void 0,Ho([r,e],zo(t)))},clearTimeout:function(r){return clearTimeout(r)},delegate:void 0};function Bc(r){Mc.setTimeout(function(){throw r})}function Pa(){}function fi(r){r()}var yl=function(r){Ur(e,r);function e(t){var i=r.call(this)||this;return i.isStopped=!1,t?(i.destination=t,bl(t)&&t.add(i)):i.destination=Hc,i}return e.create=function(t,i,o){return new Fo(t,i,o)},e.prototype.next=function(t){this.isStopped||this._next(t)},e.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,r.prototype.unsubscribe.call(this),this.destination=null)},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},e.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},e}($i),Lc=function(){function r(e){this.partialObserver=e}return r.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(i){oi(i)}},r.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(i){oi(i)}else oi(e)},r.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(t){oi(t)}},r}(),Fo=function(r){Ur(e,r);function e(t,i,o){var n=r.call(this)||this,a;return Ge(t)||!t?a={next:t!=null?t:void 0,error:i!=null?i:void 0,complete:o!=null?o:void 0}:a=t,n.destination=new Lc(a),n}return e}(yl);function oi(r){Bc(r)}function zc(r){throw r}var Hc={closed:!0,next:Pa,error:zc,complete:Pa},Rc=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Fc(r){return r}function $c(r){return r.length===0?Fc:r.length===1?r[0]:function(t){return r.reduce(function(i,o){return o(i)},t)}}var Aa=function(){function r(e){e&&(this._subscribe=e)}return r.prototype.lift=function(e){var t=new r;return t.source=this,t.operator=e,t},r.prototype.subscribe=function(e,t,i){var o=this,n=Uc(e)?e:new Fo(e,t,i);return fi(function(){var a=o,s=a.operator,l=a.source;n.add(s?s.call(n,l):l?o._subscribe(n):o._trySubscribe(n))}),n},r.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},r.prototype.forEach=function(e,t){var i=this;return t=ka(t),new t(function(o,n){var a=new Fo({next:function(s){try{e(s)}catch(l){n(l),a.unsubscribe()}},error:n,complete:o});i.subscribe(a)})},r.prototype._subscribe=function(e){var t;return(t=this.source)===null||t===void 0?void 0:t.subscribe(e)},r.prototype[Rc]=function(){return this},r.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $c(e)(this)},r.prototype.toPromise=function(e){var t=this;return e=ka(e),new e(function(i,o){var n;t.subscribe(function(a){return n=a},function(a){return o(a)},function(){return i(n)})})},r.create=function(e){return new r(e)},r}();function ka(r){var e;return(e=r!=null?r:Nc.Promise)!==null&&e!==void 0?e:Promise}function Vc(r){return r&&Ge(r.next)&&Ge(r.error)&&Ge(r.complete)}function Uc(r){return r&&r instanceof yl||Vc(r)&&bl(r)}var Wc=vl(function(r){return function(){r(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),wl=function(r){Ur(e,r);function e(){var t=r.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return e.prototype.lift=function(t){var i=new Ia(this,this);return i.operator=t,i},e.prototype._throwIfClosed=function(){if(this.closed)throw new Wc},e.prototype.next=function(t){var i=this;fi(function(){var o,n;if(i._throwIfClosed(),!i.isStopped){i.currentObservers||(i.currentObservers=Array.from(i.observers));try{for(var a=Lo(i.currentObservers),s=a.next();!s.done;s=a.next()){var l=s.value;l.next(t)}}catch(d){o={error:d}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(o)throw o.error}}}})},e.prototype.error=function(t){var i=this;fi(function(){if(i._throwIfClosed(),!i.isStopped){i.hasError=i.isStopped=!0,i.thrownError=t;for(var o=i.observers;o.length;)o.shift().error(t)}})},e.prototype.complete=function(){var t=this;fi(function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var i=t.observers;i.length;)i.shift().complete()}})},e.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(e.prototype,"observed",{get:function(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0},enumerable:!1,configurable:!0}),e.prototype._trySubscribe=function(t){return this._throwIfClosed(),r.prototype._trySubscribe.call(this,t)},e.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},e.prototype._innerSubscribe=function(t){var i=this,o=this,n=o.hasError,a=o.isStopped,s=o.observers;return n||a?gl:(this.currentObservers=null,s.push(t),new $i(function(){i.currentObservers=null,Ro(s,t)}))},e.prototype._checkFinalizedStatuses=function(t){var i=this,o=i.hasError,n=i.thrownError,a=i.isStopped;o?t.error(n):a&&t.complete()},e.prototype.asObservable=function(){var t=new Aa;return t.source=this,t},e.create=function(t,i){return new Ia(t,i)},e}(Aa),Ia=function(r){Ur(e,r);function e(t,i){var o=r.call(this)||this;return o.destination=t,o.source=i,o}return e.prototype.next=function(t){var i,o;(o=(i=this.destination)===null||i===void 0?void 0:i.next)===null||o===void 0||o.call(i,t)},e.prototype.error=function(t){var i,o;(o=(i=this.destination)===null||i===void 0?void 0:i.error)===null||o===void 0||o.call(i,t)},e.prototype.complete=function(){var t,i;(i=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||i===void 0||i.call(t)},e.prototype._subscribe=function(t){var i,o;return(o=(i=this.source)===null||i===void 0?void 0:i.subscribe(t))!==null&&o!==void 0?o:gl},e}(wl),xl={now:function(){return(xl.delegate||Date).now()},delegate:void 0},jc=function(r){Ur(e,r);function e(t,i,o){t===void 0&&(t=1/0),i===void 0&&(i=1/0),o===void 0&&(o=xl);var n=r.call(this)||this;return n._bufferSize=t,n._windowTime=i,n._timestampProvider=o,n._buffer=[],n._infiniteTimeWindow=!0,n._infiniteTimeWindow=i===1/0,n._bufferSize=Math.max(1,t),n._windowTime=Math.max(1,i),n}return e.prototype.next=function(t){var i=this,o=i.isStopped,n=i._buffer,a=i._infiniteTimeWindow,s=i._timestampProvider,l=i._windowTime;o||(n.push(t),!a&&n.push(s.now()+l)),this._trimBuffer(),r.prototype.next.call(this,t)},e.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var i=this._innerSubscribe(t),o=this,n=o._infiniteTimeWindow,a=o._buffer,s=a.slice(),l=0;l<s.length&&!t.closed;l+=n?1:2)t.next(s[l]);return this._checkFinalizedStatuses(t),i},e.prototype._trimBuffer=function(){var t=this,i=t._bufferSize,o=t._timestampProvider,n=t._buffer,a=t._infiniteTimeWindow,s=(a?1:2)*i;if(i<1/0&&s<n.length&&n.splice(0,n.length-s),!a){for(var l=o.now(),d=0,u=1;u<n.length&&n[u]<=l;u+=2)d=u;d&&n.splice(0,d+1)}},e}(wl);const Sa=[],Da={},qc=(r,e=0)=>{if(Sa.indexOf(r)==-1){const t=new jc(e);Da[r]=t,Sa.push(r)}return Da[r]},Dt=[];function Yc(r,e){return{subscribe:Vi(r,e).subscribe}}function Vi(r,e=De){let t;const i=new Set;function o(s){if(Tn(r,s)&&(r=s,t)){const l=!Dt.length;for(const d of i)d[1](),Dt.push(d,r);if(l){for(let d=0;d<Dt.length;d+=2)Dt[d][0](Dt[d+1]);Dt.length=0}}}function n(s){o(s(r))}function a(s,l=De){const d=[s,l];return i.add(d),i.size===1&&(t=e(o,n)||De),s(r),()=>{i.delete(d),i.size===0&&t&&(t(),t=null)}}return{set:o,update:n,subscribe:a}}function er(r,e,t){const i=!Array.isArray(r),o=i?[r]:r;if(!o.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");const n=e.length<2;return Yc(t,(a,s)=>{let l=!1;const d=[];let u=0,c=De;const h=()=>{if(u)return;c();const m=e(i?d[0]:d,a,s);n?a(m):c=En(m)?m:De},p=o.map((m,f)=>nl(m,y=>{d[f]=y,u&=~(1<<f),l&&h()},()=>{u|=1<<f}));return l=!0,h(),function(){Zt(p),c(),l=!1}})}function Gc(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var Xc=function(e){return Kc(e)&&!Qc(e)};function Kc(r){return!!r&&typeof r=="object"}function Qc(r){var e=Object.prototype.toString.call(r);return e==="[object RegExp]"||e==="[object Date]"||eh(r)}var Jc=typeof Symbol=="function"&&Symbol.for,Zc=Jc?Symbol.for("react.element"):60103;function eh(r){return r.$$typeof===Zc}function th(r){return Array.isArray(r)?[]:{}}function Ir(r,e){return e.clone!==!1&&e.isMergeableObject(r)?Wt(th(r),r,e):r}function rh(r,e,t){return r.concat(e).map(function(i){return Ir(i,t)})}function ih(r,e){if(!e.customMerge)return Wt;var t=e.customMerge(r);return typeof t=="function"?t:Wt}function oh(r){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(r).filter(function(e){return Object.propertyIsEnumerable.call(r,e)}):[]}function Oa(r){return Object.keys(r).concat(oh(r))}function Cl(r,e){try{return e in r}catch(t){return!1}}function nh(r,e){return Cl(r,e)&&!(Object.hasOwnProperty.call(r,e)&&Object.propertyIsEnumerable.call(r,e))}function ah(r,e,t){var i={};return t.isMergeableObject(r)&&Oa(r).forEach(function(o){i[o]=Ir(r[o],t)}),Oa(e).forEach(function(o){nh(r,o)||(Cl(r,o)&&t.isMergeableObject(e[o])?i[o]=ih(o,t)(r[o],e[o],t):i[o]=Ir(e[o],t))}),i}function Wt(r,e,t){t=t||{},t.arrayMerge=t.arrayMerge||rh,t.isMergeableObject=t.isMergeableObject||Xc,t.cloneUnlessOtherwiseSpecified=Ir;var i=Array.isArray(e),o=Array.isArray(r),n=i===o;return n?i?t.arrayMerge(r,e,t):ah(r,e,t):Ir(e,t)}Wt.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(i,o){return Wt(i,o,t)},{})};var sh=Wt,lh=sh;const dh=Gc(lh);var $o=function(r,e){return $o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(t[o]=i[o])},$o(r,e)};function Ui(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");$o(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var Fe=function(){return Fe=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},Fe.apply(this,arguments)};function uh(r,e){var t={};for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,i=Object.getOwnPropertySymbols(r);o<i.length;o++)e.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(r,i[o])&&(t[i[o]]=r[i[o]]);return t}function co(r,e,t){if(t||arguments.length===2)for(var i=0,o=e.length,n;i<o;i++)(n||!(i in e))&&(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return r.concat(n||Array.prototype.slice.call(e))}function ho(r,e){var t=e&&e.cache?e.cache:vh,i=e&&e.serializer?e.serializer:fh,o=e&&e.strategy?e.strategy:ph;return o(r,{cache:t,serializer:i})}function ch(r){return r==null||typeof r=="number"||typeof r=="boolean"}function hh(r,e,t,i){var o=ch(i)?i:t(i),n=e.get(o);return typeof n=="undefined"&&(n=r.call(this,i),e.set(o,n)),n}function El(r,e,t){var i=Array.prototype.slice.call(arguments,3),o=t(i),n=e.get(o);return typeof n=="undefined"&&(n=r.apply(this,i),e.set(o,n)),n}function Tl(r,e,t,i,o){return t.bind(e,r,i,o)}function ph(r,e){var t=r.length===1?hh:El;return Tl(r,this,t,e.cache.create(),e.serializer)}function mh(r,e){return Tl(r,this,El,e.cache.create(),e.serializer)}var fh=function(){return JSON.stringify(arguments)},_h=function(){function r(){this.cache=Object.create(null)}return r.prototype.get=function(e){return this.cache[e]},r.prototype.set=function(e,t){this.cache[e]=t},r}(),vh={create:function(){return new _h}},po={variadic:mh},xi=function(){return xi=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},xi.apply(this,arguments)};var M;(function(r){r[r.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",r[r.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",r[r.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",r[r.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",r[r.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",r[r.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",r[r.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",r[r.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",r[r.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",r[r.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",r[r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",r[r.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",r[r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",r[r.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",r[r.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",r[r.INVALID_TAG=23]="INVALID_TAG",r[r.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",r[r.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",r[r.UNCLOSED_TAG=27]="UNCLOSED_TAG"})(M||(M={}));var Z;(function(r){r[r.literal=0]="literal",r[r.argument=1]="argument",r[r.number=2]="number",r[r.date=3]="date",r[r.time=4]="time",r[r.select=5]="select",r[r.plural=6]="plural",r[r.pound=7]="pound",r[r.tag=8]="tag"})(Z||(Z={}));var jt;(function(r){r[r.number=0]="number",r[r.dateTime=1]="dateTime"})(jt||(jt={}));function Na(r){return r.type===Z.literal}function gh(r){return r.type===Z.argument}function Pl(r){return r.type===Z.number}function Al(r){return r.type===Z.date}function kl(r){return r.type===Z.time}function Il(r){return r.type===Z.select}function Sl(r){return r.type===Z.plural}function bh(r){return r.type===Z.pound}function Dl(r){return r.type===Z.tag}function Ol(r){return!!(r&&typeof r=="object"&&r.type===jt.number)}function Vo(r){return!!(r&&typeof r=="object"&&r.type===jt.dateTime)}var Nl=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,yh=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function wh(r){var e={};return r.replace(yh,function(t){var i=t.length;switch(t[0]){case"G":e.era=i===4?"long":i===5?"narrow":"short";break;case"y":e.year=i===2?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":e.month=["numeric","2-digit","short","long","narrow"][i-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":e.day=["numeric","2-digit"][i-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":e.weekday=i===4?"long":i===5?"narrow":"short";break;case"e":if(i<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][i-4];break;case"c":if(i<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");e.weekday=["short","long","narrow","short"][i-4];break;case"a":e.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":e.hourCycle="h12",e.hour=["numeric","2-digit"][i-1];break;case"H":e.hourCycle="h23",e.hour=["numeric","2-digit"][i-1];break;case"K":e.hourCycle="h11",e.hour=["numeric","2-digit"][i-1];break;case"k":e.hourCycle="h24",e.hour=["numeric","2-digit"][i-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":e.minute=["numeric","2-digit"][i-1];break;case"s":e.second=["numeric","2-digit"][i-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":e.timeZoneName=i<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),e}var oe=function(){return oe=Object.assign||function(e){for(var t,i=1,o=arguments.length;i<o;i++){t=arguments[i];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},oe.apply(this,arguments)};var xh=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function Ch(r){if(r.length===0)throw new Error("Number skeleton cannot be empty");for(var e=r.split(xh).filter(function(h){return h.length>0}),t=[],i=0,o=e;i<o.length;i++){var n=o[i],a=n.split("/");if(a.length===0)throw new Error("Invalid number skeleton");for(var s=a[0],l=a.slice(1),d=0,u=l;d<u.length;d++){var c=u[d];if(c.length===0)throw new Error("Invalid number skeleton")}t.push({stem:s,options:l})}return t}function Eh(r){return r.replace(/^(.*?)-/,"")}var Ma=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,Ml=/^(@+)?(\+|#+)?[rs]?$/g,Th=/(\*)(0+)|(#+)(0+)|(0+)/g,Bl=/^(0+)$/;function Ba(r){var e={};return r[r.length-1]==="r"?e.roundingPriority="morePrecision":r[r.length-1]==="s"&&(e.roundingPriority="lessPrecision"),r.replace(Ml,function(t,i,o){return typeof o!="string"?(e.minimumSignificantDigits=i.length,e.maximumSignificantDigits=i.length):o==="+"?e.minimumSignificantDigits=i.length:i[0]==="#"?e.maximumSignificantDigits=i.length:(e.minimumSignificantDigits=i.length,e.maximumSignificantDigits=i.length+(typeof o=="string"?o.length:0)),""}),e}function Ll(r){switch(r){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 Ph(r){var e;if(r[0]==="E"&&r[1]==="E"?(e={notation:"engineering"},r=r.slice(2)):r[0]==="E"&&(e={notation:"scientific"},r=r.slice(1)),e){var t=r.slice(0,2);if(t==="+!"?(e.signDisplay="always",r=r.slice(2)):t==="+?"&&(e.signDisplay="exceptZero",r=r.slice(2)),!Bl.test(r))throw new Error("Malformed concise eng/scientific notation");e.minimumIntegerDigits=r.length}return e}function La(r){var e={},t=Ll(r);return t||e}function Ah(r){for(var e={},t=0,i=r;t<i.length;t++){var o=i[t];switch(o.stem){case"percent":case"%":e.style="percent";continue;case"%x100":e.style="percent",e.scale=100;continue;case"currency":e.style="currency",e.currency=o.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=Eh(o.options[0]);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=oe(oe(oe({},e),{notation:"scientific"}),o.options.reduce(function(l,d){return oe(oe({},l),La(d))},{}));continue;case"engineering":e=oe(oe(oe({},e),{notation:"engineering"}),o.options.reduce(function(l,d){return oe(oe({},l),La(d))},{}));continue;case"notation-simple":e.notation="standard";continue;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(o.options[0]);continue;case"rounding-mode-floor":e.roundingMode="floor";continue;case"rounding-mode-ceiling":e.roundingMode="ceil";continue;case"rounding-mode-down":e.roundingMode="trunc";continue;case"rounding-mode-up":e.roundingMode="expand";continue;case"rounding-mode-half-even":e.roundingMode="halfEven";continue;case"rounding-mode-half-down":e.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":e.roundingMode="halfExpand";continue;case"integer-width":if(o.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");o.options[0].replace(Th,function(l,d,u,c,h,p){if(d)e.minimumIntegerDigits=u.length;else{if(c&&h)throw new Error("We currently do not support maximum integer digits");if(p)throw new Error("We currently do not support exact integer digits")}return""});continue}if(Bl.test(o.stem)){e.minimumIntegerDigits=o.stem.length;continue}if(Ma.test(o.stem)){if(o.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");o.stem.replace(Ma,function(l,d,u,c,h,p){return u==="*"?e.minimumFractionDigits=d.length:c&&c[0]==="#"?e.maximumFractionDigits=c.length:h&&p?(e.minimumFractionDigits=h.length,e.maximumFractionDigits=h.length+p.length):(e.minimumFractionDigits=d.length,e.maximumFractionDigits=d.length),""});var n=o.options[0];n==="w"?e=oe(oe({},e),{trailingZeroDisplay:"stripIfInteger"}):n&&(e=oe(oe({},e),Ba(n)));continue}if(Ml.test(o.stem)){e=oe(oe({},e),Ba(o.stem));continue}var a=Ll(o.stem);a&&(e=oe(oe({},e),a));var s=Ph(o.stem);s&&(e=oe(oe({},e),s))}return e}var ni={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function kh(r,e){for(var t="",i=0;i<r.length;i++){var o=r.charAt(i);if(o==="j"){for(var n=0;i+1<r.length&&r.charAt(i+1)===o;)n++,i++;var a=1+(n&1),s=n<2?1:3+(n>>1),l="a",d=Ih(e);for((d=="H"||d=="k")&&(s=0);s-- >0;)t+=l;for(;a-- >0;)t=d+t}else o==="J"?t+="H":t+=o}return t}function Ih(r){var e=r.hourCycle;if(e===void 0&&r.hourCycles&&r.hourCycles.length&&(e=r.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")}var t=r.language,i;t!=="root"&&(i=r.maximize().region);var o=ni[i||""]||ni[t||""]||ni["".concat(t,"-001")]||ni["001"];return o[0]}var mo,Sh=new RegExp("^".concat(Nl.source,"*")),Dh=new RegExp("".concat(Nl.source,"*$"));function R(r,e){return{start:r,end:e}}var Oh=!!String.prototype.startsWith&&"_a".startsWith("a",1),Nh=!!String.fromCodePoint,Mh=!!Object.fromEntries,Bh=!!String.prototype.codePointAt,Lh=!!String.prototype.trimStart,zh=!!String.prototype.trimEnd,Hh=!!Number.isSafeInteger,Rh=Hh?Number.isSafeInteger:function(r){return typeof r=="number"&&isFinite(r)&&Math.floor(r)===r&&Math.abs(r)<=9007199254740991},Uo=!0;try{var Fh=Hl("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");Uo=((mo=Fh.exec("a"))===null||mo===void 0?void 0:mo[0])==="a"}catch(r){Uo=!1}var za=Oh?function(e,t,i){return e.startsWith(t,i)}:function(e,t,i){return e.slice(i,i+t.length)===t},Wo=Nh?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var i="",o=e.length,n=0,a;o>n;){if(a=e[n++],a>1114111)throw RangeError(a+" is not a valid code point");i+=a<65536?String.fromCharCode(a):String.fromCharCode(((a-=65536)>>10)+55296,a%1024+56320)}return i},Ha=Mh?Object.fromEntries:function(e){for(var t={},i=0,o=e;i<o.length;i++){var n=o[i],a=n[0],s=n[1];t[a]=s}return t},zl=Bh?function(e,t){return e.codePointAt(t)}:function(e,t){var i=e.length;if(!(t<0||t>=i)){var o=e.charCodeAt(t),n;return o<55296||o>56319||t+1===i||(n=e.charCodeAt(t+1))<56320||n>57343?o:(o-55296<<10)+(n-56320)+65536}},$h=Lh?function(e){return e.trimStart()}:function(e){return e.replace(Sh,"")},Vh=zh?function(e){return e.trimEnd()}:function(e){return e.replace(Dh,"")};function Hl(r,e){return new RegExp(r,e)}var jo;if(Uo){var Ra=Hl("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");jo=function(e,t){var i;Ra.lastIndex=t;var o=Ra.exec(e);return(i=o[1])!==null&&i!==void 0?i:""}}else jo=function(e,t){for(var i=[];;){var o=zl(e,t);if(o===void 0||Rl(o)||qh(o))break;i.push(o),t+=o>=65536?2:1}return Wo.apply(void 0,i)};var Uh=function(){function r(e,t){t===void 0&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return r.prototype.parse=function(){if(this.offset()!==0)throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},r.prototype.parseMessage=function(e,t,i){for(var o=[];!this.isEOF();){var n=this.char();if(n===123){var a=this.parseArgument(e,i);if(a.err)return a;o.push(a.val)}else{if(n===125&&e>0)break;if(n===35&&(t==="plural"||t==="selectordinal")){var s=this.clonePosition();this.bump(),o.push({type:Z.pound,location:R(s,this.clonePosition())})}else if(n===60&&!this.ignoreTag&&this.peek()===47){if(i)break;return this.error(M.UNMATCHED_CLOSING_TAG,R(this.clonePosition(),this.clonePosition()))}else if(n===60&&!this.ignoreTag&&qo(this.peek()||0)){var a=this.parseTag(e,t);if(a.err)return a;o.push(a.val)}else{var a=this.parseLiteral(e,t);if(a.err)return a;o.push(a.val)}}}return{val:o,err:null}},r.prototype.parseTag=function(e,t){var i=this.clonePosition();this.bump();var o=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:Z.literal,value:"<".concat(o,"/>"),location:R(i,this.clonePosition())},err:null};if(this.bumpIf(">")){var n=this.parseMessage(e+1,t,!0);if(n.err)return n;var a=n.val,s=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!qo(this.char()))return this.error(M.INVALID_TAG,R(s,this.clonePosition()));var l=this.clonePosition(),d=this.parseTagName();return o!==d?this.error(M.UNMATCHED_CLOSING_TAG,R(l,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:Z.tag,value:o,children:a,location:R(i,this.clonePosition())},err:null}:this.error(M.INVALID_TAG,R(s,this.clonePosition())))}else return this.error(M.UNCLOSED_TAG,R(i,this.clonePosition()))}else return this.error(M.INVALID_TAG,R(i,this.clonePosition()))},r.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&jh(this.char());)this.bump();return this.message.slice(e,this.offset())},r.prototype.parseLiteral=function(e,t){for(var i=this.clonePosition(),o="";;){var n=this.tryParseQuote(t);if(n){o+=n;continue}var a=this.tryParseUnquoted(e,t);if(a){o+=a;continue}var s=this.tryParseLeftAngleBracket();if(s){o+=s;continue}break}var l=R(i,this.clonePosition());return{val:{type:Z.literal,value:o,location:l},err:null}},r.prototype.tryParseLeftAngleBracket=function(){return!this.isEOF()&&this.char()===60&&(this.ignoreTag||!Wh(this.peek()||0))?(this.bump(),"<"):null},r.prototype.tryParseQuote=function(e){if(this.isEOF()||this.char()!==39)return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if(e==="plural"||e==="selectordinal")break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var i=this.char();if(i===39)if(this.peek()===39)t.push(39),this.bump();else{this.bump();break}else t.push(i);this.bump()}return Wo.apply(void 0,t)},r.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var i=this.char();return i===60||i===123||i===35&&(t==="plural"||t==="selectordinal")||i===125&&e>0?null:(this.bump(),Wo(i))},r.prototype.parseArgument=function(e,t){var i=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(M.EXPECT_ARGUMENT_CLOSING_BRACE,R(i,this.clonePosition()));if(this.char()===125)return this.bump(),this.error(M.EMPTY_ARGUMENT,R(i,this.clonePosition()));var o=this.parseIdentifierIfPossible().value;if(!o)return this.error(M.MALFORMED_ARGUMENT,R(i,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(M.EXPECT_ARGUMENT_CLOSING_BRACE,R(i,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:Z.argument,value:o,location:R(i,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(M.EXPECT_ARGUMENT_CLOSING_BRACE,R(i,this.clonePosition())):this.parseArgumentOptions(e,t,o,i);default:return this.error(M.MALFORMED_ARGUMENT,R(i,this.clonePosition()))}},r.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),i=jo(this.message,t),o=t+i.length;this.bumpTo(o);var n=this.clonePosition(),a=R(e,n);return{value:i,location:a}},r.prototype.parseArgumentOptions=function(e,t,i,o){var n,a=this.clonePosition(),s=this.parseIdentifierIfPossible().value,l=this.clonePosition();switch(s){case"":return this.error(M.EXPECT_ARGUMENT_TYPE,R(a,l));case"number":case"date":case"time":{this.bumpSpace();var d=null;if(this.bumpIf(",")){this.bumpSpace();var u=this.clonePosition(),c=this.parseSimpleArgStyleIfPossible();if(c.err)return c;var h=Vh(c.val);if(h.length===0)return this.error(M.EXPECT_ARGUMENT_STYLE,R(this.clonePosition(),this.clonePosition()));var p=R(u,this.clonePosition());d={style:h,styleLocation:p}}var m=this.tryParseArgumentClose(o);if(m.err)return m;var f=R(o,this.clonePosition());if(d&&za(d==null?void 0:d.style,"::",0)){var y=$h(d.style.slice(2));if(s==="number"){var c=this.parseNumberSkeletonFromString(y,d.styleLocation);return c.err?c:{val:{type:Z.number,value:i,location:f,style:c.val},err:null}}else{if(y.length===0)return this.error(M.EXPECT_DATE_TIME_SKELETON,f);var E=y;this.locale&&(E=kh(y,this.locale));var h={type:jt.dateTime,pattern:E,location:d.styleLocation,parsedOptions:this.shouldParseSkeletons?wh(E):{}},C=s==="date"?Z.date:Z.time;return{val:{type:C,value:i,location:f,style:h},err:null}}}return{val:{type:s==="number"?Z.number:s==="date"?Z.date:Z.time,value:i,location:f,style:(n=d==null?void 0:d.style)!==null&&n!==void 0?n:null},err:null}}case"plural":case"selectordinal":case"select":{var T=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(M.EXPECT_SELECT_ARGUMENT_OPTIONS,R(T,xi({},T)));this.bumpSpace();var N=this.parseIdentifierIfPossible(),U=0;if(s!=="select"&&N.value==="offset"){if(!this.bumpIf(":"))return this.error(M.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,R(this.clonePosition(),this.clonePosition()));this.bumpSpace();var c=this.tryParseDecimalInteger(M.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,M.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(c.err)return c;this.bumpSpace(),N=this.parseIdentifierIfPossible(),U=c.val}var W=this.tryParsePluralOrSelectOptions(e,s,t,N);if(W.err)return W;var m=this.tryParseArgumentClose(o);if(m.err)return m;var me=R(o,this.clonePosition());return s==="select"?{val:{type:Z.select,value:i,options:Ha(W.val),location:me},err:null}:{val:{type:Z.plural,value:i,options:Ha(W.val),offset:U,pluralType:s==="plural"?"cardinal":"ordinal",location:me},err:null}}default:return this.error(M.INVALID_ARGUMENT_TYPE,R(a,l))}},r.prototype.tryParseArgumentClose=function(e){return this.isEOF()||this.char()!==125?this.error(M.EXPECT_ARGUMENT_CLOSING_BRACE,R(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},r.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){var i=this.char();switch(i){case 39:{this.bump();var o=this.clonePosition();if(!this.bumpUntil("'"))return this.error(M.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,R(o,this.clonePosition()));this.bump();break}case 123:{e+=1,this.bump();break}case 125:{if(e>0)e-=1;else return{val:this.message.slice(t.offset,this.offset()),err:null};break}default:this.bump();break}}return{val:this.message.slice(t.offset,this.offset()),err:null}},r.prototype.parseNumberSkeletonFromString=function(e,t){var i=[];try{i=Ch(e)}catch(o){return this.error(M.INVALID_NUMBER_SKELETON,t)}return{val:{type:jt.number,tokens:i,location:t,parsedOptions:this.shouldParseSkeletons?Ah(i):{}},err:null}},r.prototype.tryParsePluralOrSelectOptions=function(e,t,i,o){for(var n,a=!1,s=[],l=new Set,d=o.value,u=o.location;;){if(d.length===0){var c=this.clonePosition();if(t!=="select"&&this.bumpIf("=")){var h=this.tryParseDecimalInteger(M.EXPECT_PLURAL_ARGUMENT_SELECTOR,M.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;u=R(c,this.clonePosition()),d=this.message.slice(c.offset,this.offset())}else break}if(l.has(d))return this.error(t==="select"?M.DUPLICATE_SELECT_ARGUMENT_SELECTOR:M.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,u);d==="other"&&(a=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error(t==="select"?M.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:M.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,R(this.clonePosition(),this.clonePosition()));var m=this.parseMessage(e+1,t,i);if(m.err)return m;var f=this.tryParseArgumentClose(p);if(f.err)return f;s.push([d,{value:m.val,location:R(p,this.clonePosition())}]),l.add(d),this.bumpSpace(),n=this.parseIdentifierIfPossible(),d=n.value,u=n.location}return s.length===0?this.error(t==="select"?M.EXPECT_SELECT_ARGUMENT_SELECTOR:M.EXPECT_PLURAL_ARGUMENT_SELECTOR,R(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!a?this.error(M.MISSING_OTHER_CLAUSE,R(this.clonePosition(),this.clonePosition())):{val:s,err:null}},r.prototype.tryParseDecimalInteger=function(e,t){var i=1,o=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(i=-1);for(var n=!1,a=0;!this.isEOF();){var s=this.char();if(s>=48&&s<=57)n=!0,a=a*10+(s-48),this.bump();else break}var l=R(o,this.clonePosition());return n?(a*=i,Rh(a)?{val:a,err:null}:this.error(t,l)):this.error(e,l)},r.prototype.offset=function(){return this.position.offset},r.prototype.isEOF=function(){return this.offset()===this.message.length},r.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},r.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=zl(this.message,e);if(t===void 0)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},r.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},r.prototype.bump=function(){if(!this.isEOF()){var e=this.char();e===10?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},r.prototype.bumpIf=function(e){if(za(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},r.prototype.bumpUntil=function(e){var t=this.offset(),i=this.message.indexOf(e,t);return i>=0?(this.bumpTo(i),!0):(this.bumpTo(this.message.length),!1)},r.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},r.prototype.bumpSpace=function(){for(;!this.isEOF()&&Rl(this.char());)this.bump()},r.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),i=this.message.charCodeAt(t+(e>=65536?2:1));return i!=null?i:null},r}();function qo(r){return r>=97&&r<=122||r>=65&&r<=90}function Wh(r){return qo(r)||r===47}function jh(r){return r===45||r===46||r>=48&&r<=57||r===95||r>=97&&r<=122||r>=65&&r<=90||r==183||r>=192&&r<=214||r>=216&&r<=246||r>=248&&r<=893||r>=895&&r<=8191||r>=8204&&r<=8205||r>=8255&&r<=8256||r>=8304&&r<=8591||r>=11264&&r<=12271||r>=12289&&r<=55295||r>=63744&&r<=64975||r>=65008&&r<=65533||r>=65536&&r<=983039}function Rl(r){return r>=9&&r<=13||r===32||r===133||r>=8206&&r<=8207||r===8232||r===8233}function qh(r){return r>=33&&r<=35||r===36||r>=37&&r<=39||r===40||r===41||r===42||r===43||r===44||r===45||r>=46&&r<=47||r>=58&&r<=59||r>=60&&r<=62||r>=63&&r<=64||r===91||r===92||r===93||r===94||r===96||r===123||r===124||r===125||r===126||r===161||r>=162&&r<=165||r===166||r===167||r===169||r===171||r===172||r===174||r===176||r===177||r===182||r===187||r===191||r===215||r===247||r>=8208&&r<=8213||r>=8214&&r<=8215||r===8216||r===8217||r===8218||r>=8219&&r<=8220||r===8221||r===8222||r===8223||r>=8224&&r<=8231||r>=8240&&r<=8248||r===8249||r===8250||r>=8251&&r<=8254||r>=8257&&r<=8259||r===8260||r===8261||r===8262||r>=8263&&r<=8273||r===8274||r===8275||r>=8277&&r<=8286||r>=8592&&r<=8596||r>=8597&&r<=8601||r>=8602&&r<=8603||r>=8604&&r<=8607||r===8608||r>=8609&&r<=8610||r===8611||r>=8612&&r<=8613||r===8614||r>=8615&&r<=8621||r===8622||r>=8623&&r<=8653||r>=8654&&r<=8655||r>=8656&&r<=8657||r===8658||r===8659||r===8660||r>=8661&&r<=8691||r>=8692&&r<=8959||r>=8960&&r<=8967||r===8968||r===8969||r===8970||r===8971||r>=8972&&r<=8991||r>=8992&&r<=8993||r>=8994&&r<=9e3||r===9001||r===9002||r>=9003&&r<=9083||r===9084||r>=9085&&r<=9114||r>=9115&&r<=9139||r>=9140&&r<=9179||r>=9180&&r<=9185||r>=9186&&r<=9254||r>=9255&&r<=9279||r>=9280&&r<=9290||r>=9291&&r<=9311||r>=9472&&r<=9654||r===9655||r>=9656&&r<=9664||r===9665||r>=9666&&r<=9719||r>=9720&&r<=9727||r>=9728&&r<=9838||r===9839||r>=9840&&r<=10087||r===10088||r===10089||r===10090||r===10091||r===10092||r===10093||r===10094||r===10095||r===10096||r===10097||r===10098||r===10099||r===10100||r===10101||r>=10132&&r<=10175||r>=10176&&r<=10180||r===10181||r===10182||r>=10183&&r<=10213||r===10214||r===10215||r===10216||r===10217||r===10218||r===10219||r===10220||r===10221||r===10222||r===10223||r>=10224&&r<=10239||r>=10240&&r<=10495||r>=10496&&r<=10626||r===10627||r===10628||r===10629||r===10630||r===10631||r===10632||r===10633||r===10634||r===10635||r===10636||r===10637||r===10638||r===10639||r===10640||r===10641||r===10642||r===10643||r===10644||r===10645||r===10646||r===10647||r===10648||r>=10649&&r<=10711||r===10712||r===10713||r===10714||r===10715||r>=10716&&r<=10747||r===10748||r===10749||r>=10750&&r<=11007||r>=11008&&r<=11055||r>=11056&&r<=11076||r>=11077&&r<=11078||r>=11079&&r<=11084||r>=11085&&r<=11123||r>=11124&&r<=11125||r>=11126&&r<=11157||r===11158||r>=11159&&r<=11263||r>=11776&&r<=11777||r===11778||r===11779||r===11780||r===11781||r>=11782&&r<=11784||r===11785||r===11786||r===11787||r===11788||r===11789||r>=11790&&r<=11798||r===11799||r>=11800&&r<=11801||r===11802||r===11803||r===11804||r===11805||r>=11806&&r<=11807||r===11808||r===11809||r===11810||r===11811||r===11812||r===11813||r===11814||r===11815||r===11816||r===11817||r>=11818&&r<=11822||r===11823||r>=11824&&r<=11833||r>=11834&&r<=11835||r>=11836&&r<=11839||r===11840||r===11841||r===11842||r>=11843&&r<=11855||r>=11856&&r<=11857||r===11858||r>=11859&&r<=11903||r>=12289&&r<=12291||r===12296||r===12297||r===12298||r===12299||r===12300||r===12301||r===12302||r===12303||r===12304||r===12305||r>=12306&&r<=12307||r===12308||r===12309||r===12310||r===12311||r===12312||r===12313||r===12314||r===12315||r===12316||r===12317||r>=12318&&r<=12319||r===12320||r===12336||r===64830||r===64831||r>=65093&&r<=65094}function Yo(r){r.forEach(function(e){if(delete e.location,Il(e)||Sl(e))for(var t in e.options)delete e.options[t].location,Yo(e.options[t].value);else Pl(e)&&Ol(e.style)||(Al(e)||kl(e))&&Vo(e.style)?delete e.style.location:Dl(e)&&Yo(e.children)})}function Yh(r,e){e===void 0&&(e={}),e=xi({shouldParseSkeletons:!0,requiresOtherClause:!0},e);var t=new Uh(r,e).parse();if(t.err){var i=SyntaxError(M[t.err.kind]);throw i.location=t.err.location,i.originalMessage=t.err.message,i}return e!=null&&e.captureLocation||Yo(t.val),t.val}var qt;(function(r){r.MISSING_VALUE="MISSING_VALUE",r.INVALID_VALUE="INVALID_VALUE",r.MISSING_INTL_API="MISSING_INTL_API"})(qt||(qt={}));var Wi=function(r){Ui(e,r);function e(t,i,o){var n=r.call(this,t)||this;return n.code=i,n.originalMessage=o,n}return e.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},e}(Error),Fa=function(r){Ui(e,r);function e(t,i,o,n){return r.call(this,'Invalid values for "'.concat(t,'": "').concat(i,'". Options are "').concat(Object.keys(o).join('", "'),'"'),qt.INVALID_VALUE,n)||this}return e}(Wi),Gh=function(r){Ui(e,r);function e(t,i,o){return r.call(this,'Value for "'.concat(t,'" must be of type ').concat(i),qt.INVALID_VALUE,o)||this}return e}(Wi),Xh=function(r){Ui(e,r);function e(t,i){return r.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(i,'"'),qt.MISSING_VALUE,i)||this}return e}(Wi),we;(function(r){r[r.literal=0]="literal",r[r.object=1]="object"})(we||(we={}));function Kh(r){return r.length<2?r:r.reduce(function(e,t){var i=e[e.length-1];return!i||i.type!==we.literal||t.type!==we.literal?e.push(t):i.value+=t.value,e},[])}function Qh(r){return typeof r=="function"}function _i(r,e,t,i,o,n,a){if(r.length===1&&Na(r[0]))return[{type:we.literal,value:r[0].value}];for(var s=[],l=0,d=r;l<d.length;l++){var u=d[l];if(Na(u)){s.push({type:we.literal,value:u.value});continue}if(bh(u)){typeof n=="number"&&s.push({type:we.literal,value:t.getNumberFormat(e).format(n)});continue}var c=u.value;if(!(o&&c in o))throw new Xh(c,a);var h=o[c];if(gh(u)){(!h||typeof h=="string"||typeof h=="number")&&(h=typeof h=="string"||typeof h=="number"?String(h):""),s.push({type:typeof h=="string"?we.literal:we.object,value:h});continue}if(Al(u)){var p=typeof u.style=="string"?i.date[u.style]:Vo(u.style)?u.style.parsedOptions:void 0;s.push({type:we.literal,value:t.getDateTimeFormat(e,p).format(h)});continue}if(kl(u)){var p=typeof u.style=="string"?i.time[u.style]:Vo(u.style)?u.style.parsedOptions:i.time.medium;s.push({type:we.literal,value:t.getDateTimeFormat(e,p).format(h)});continue}if(Pl(u)){var p=typeof u.style=="string"?i.number[u.style]:Ol(u.style)?u.style.parsedOptions:void 0;p&&p.scale&&(h=h*(p.scale||1)),s.push({type:we.literal,value:t.getNumberFormat(e,p).format(h)});continue}if(Dl(u)){var m=u.children,f=u.value,y=o[f];if(!Qh(y))throw new Gh(f,"function",a);var E=_i(m,e,t,i,o,n),C=y(E.map(function(U){return U.value}));Array.isArray(C)||(C=[C]),s.push.apply(s,C.map(function(U){return{type:typeof U=="string"?we.literal:we.object,value:U}}))}if(Il(u)){var T=u.options[h]||u.options.other;if(!T)throw new Fa(u.value,h,Object.keys(u.options),a);s.push.apply(s,_i(T.value,e,t,i,o));continue}if(Sl(u)){var T=u.options["=".concat(h)];if(!T){if(!Intl.PluralRules)throw new Wi(`Intl.PluralRules is not available in this environment.
|
|
17
17
|
Try polyfilling it using "@formatjs/intl-pluralrules"
|
|
18
|
-
`,qt.MISSING_INTL_API,a);var D=t.getPluralRules(e,{type:u.pluralType}).select(h-(u.offset||0));A=u.options[D]||u.options.other}if(!A)throw new Fa(u.value,h,Object.keys(u.options),a);s.push.apply(s,_i(A.value,e,t,i,o,h-(u.offset||0)));continue}}return Xh(s)}function Qh(r,e){return e?$e($e($e({},r||{}),e||{}),Object.keys(r).reduce(function(t,i){return t[i]=$e($e({},r[i]),e[i]||{}),t},{})):r}function Jh(r,e){return e?Object.keys(r).reduce(function(t,i){return t[i]=Qh(r[i],e[i]),t},$e({},r)):r}function fo(r){return{create:function(){return{get:function(e){return r[e]},set:function(e,t){r[e]=t}}}}}function Zh(r){return r===void 0&&(r={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.NumberFormat).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.number),strategy:po.variadic}),getDateTimeFormat:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.DateTimeFormat).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.dateTime),strategy:po.variadic}),getPluralRules:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.PluralRules).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.pluralRules),strategy:po.variadic})}}var ep=function(){function r(e,t,i,o){t===void 0&&(t=r.defaultLocale);var n=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(l){var d=n.formatToParts(l);if(d.length===1)return d[0].value;var u=d.reduce(function(c,h){return!c.length||h.type!==we.literal||typeof c[c.length-1]!="string"?c.push(h.value):c[c.length-1]+=h.value,c},[]);return u.length<=1?u[0]||"":u},this.formatToParts=function(l){return _i(n.ast,n.locales,n.formatters,n.formats,l,void 0,n.message)},this.resolvedOptions=function(){var l;return{locale:((l=n.resolvedLocale)===null||l===void 0?void 0:l.toString())||Intl.NumberFormat.supportedLocalesOf(n.locales)[0]}},this.getAst=function(){return n.ast},this.locales=t,this.resolvedLocale=r.resolveLocale(t),typeof e=="string"){if(this.message=e,!r.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var a=o||{};a.formatters;var s=dh(a,["formatters"]);this.ast=r.__parse(e,$e($e({},s),{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.");this.formats=Jh(r.formats,i),this.formatters=o&&o.formatters||Zh(this.formatterCache)}return Object.defineProperty(r,"defaultLocale",{get:function(){return r.memoizedDefaultLocale||(r.memoizedDefaultLocale=new Intl.NumberFormat().resolvedOptions().locale),r.memoizedDefaultLocale},enumerable:!1,configurable:!0}),r.memoizedDefaultLocale=null,r.resolveLocale=function(e){if(typeof Intl.Locale!="undefined"){var t=Intl.NumberFormat.supportedLocalesOf(e);return t.length>0?new Intl.Locale(t[0]):new Intl.Locale(typeof e=="string"?e:e[0])}},r.__parse=qh,r.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"}}},r}();function tp(r,e){if(e==null)return;if(e in r)return r[e];const t=e.split(".");let i=r;for(let o=0;o<t.length;o++)if(typeof i=="object"){if(o>0){const n=t.slice(o,t.length).join(".");if(n in i){i=i[n];break}}i=i[t[o]]}else i=void 0;return i}const nt={},rp=(r,e,t)=>t&&(e in nt||(nt[e]={}),r in nt[e]||(nt[e][r]=t),t),Fl=(r,e)=>{if(e==null)return;if(e in nt&&r in nt[e])return nt[e][r];const t=ji(e);for(let i=0;i<t.length;i++){const o=t[i],n=op(o,r);if(n)return rp(r,e,n)}};let An;const jr=Vi({});function ip(r){return An[r]||null}function $l(r){return r in An}function op(r,e){if(!$l(r))return null;const t=ip(r);return tp(t,e)}function np(r){if(r==null)return;const e=ji(r);for(let t=0;t<e.length;t++){const i=e[t];if($l(i))return i}}function kn(r,...e){delete nt[r],jr.update(t=>(t[r]=lh.all([t[r]||{},...e]),t))}er([jr],([r])=>Object.keys(r));jr.subscribe(r=>An=r);const vi={};function ap(r,e){vi[r].delete(e),vi[r].size===0&&delete vi[r]}function Vl(r){return vi[r]}function sp(r){return ji(r).map(e=>{const t=Vl(e);return[e,t?[...t]:[]]}).filter(([,e])=>e.length>0)}function Go(r){return r==null?!1:ji(r).some(e=>{var t;return(t=Vl(e))==null?void 0:t.size})}function lp(r,e){return Promise.all(e.map(i=>(ap(r,i),i().then(o=>o.default||o)))).then(i=>kn(r,...i))}const fr={};function Ul(r){if(!Go(r))return r in fr?fr[r]:Promise.resolve();const e=sp(r);return fr[r]=Promise.all(e.map(([t,i])=>lp(t,i))).then(()=>{if(Go(r))return Ul(r);delete fr[r]}),fr[r]}const dp={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"}}},up={fallbackLocale:null,loadingDelay:200,formats:dp,warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0},cp=up;function Yt(){return cp}const _o=Vi(!1);var hp=Object.defineProperty,pp=Object.defineProperties,mp=Object.getOwnPropertyDescriptors,$a=Object.getOwnPropertySymbols,fp=Object.prototype.hasOwnProperty,_p=Object.prototype.propertyIsEnumerable,Va=(r,e,t)=>e in r?hp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,vp=(r,e)=>{for(var t in e||(e={}))fp.call(e,t)&&Va(r,t,e[t]);if($a)for(var t of $a(e))_p.call(e,t)&&Va(r,t,e[t]);return r},gp=(r,e)=>pp(r,mp(e));let Xo;const Ci=Vi(null);function Ua(r){return r.split("-").map((e,t,i)=>i.slice(0,t+1).join("-")).reverse()}function ji(r,e=Yt().fallbackLocale){const t=Ua(r);return e?[...new Set([...t,...Ua(e)])]:t}function bt(){return Xo!=null?Xo:void 0}Ci.subscribe(r=>{Xo=r!=null?r:void 0,typeof window!="undefined"&&r!=null&&document.documentElement.setAttribute("lang",r)});const bp=r=>{if(r&&np(r)&&Go(r)){const{loadingDelay:e}=Yt();let t;return typeof window!="undefined"&&bt()!=null&&e?t=window.setTimeout(()=>_o.set(!0),e):_o.set(!0),Ul(r).then(()=>{Ci.set(r)}).finally(()=>{clearTimeout(t),_o.set(!1)})}return Ci.set(r)},yt=gp(vp({},Ci),{set:bp}),qi=r=>{const e=Object.create(null);return i=>{const o=JSON.stringify(i);return o in e?e[o]:e[o]=r(i)}};var yp=Object.defineProperty,Ei=Object.getOwnPropertySymbols,Wl=Object.prototype.hasOwnProperty,jl=Object.prototype.propertyIsEnumerable,Wa=(r,e,t)=>e in r?yp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,In=(r,e)=>{for(var t in e||(e={}))Wl.call(e,t)&&Wa(r,t,e[t]);if(Ei)for(var t of Ei(e))jl.call(e,t)&&Wa(r,t,e[t]);return r},tr=(r,e)=>{var t={};for(var i in r)Wl.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&Ei)for(var i of Ei(r))e.indexOf(i)<0&&jl.call(r,i)&&(t[i]=r[i]);return t};const Dr=(r,e)=>{const{formats:t}=Yt();if(r in t&&e in t[r])return t[r][e];throw new Error(`[svelte-i18n] Unknown "${e}" ${r} format.`)},wp=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return i&&(o=Dr("number",i)),new Intl.NumberFormat(t,o)}),xp=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return i?o=Dr("date",i):Object.keys(o).length===0&&(o=Dr("date","short")),new Intl.DateTimeFormat(t,o)}),Cp=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return i?o=Dr("time",i):Object.keys(o).length===0&&(o=Dr("time","short")),new Intl.DateTimeFormat(t,o)}),Ep=(r={})=>{var e=r,{locale:t=bt()}=e,i=tr(e,["locale"]);return wp(In({locale:t},i))},Tp=(r={})=>{var e=r,{locale:t=bt()}=e,i=tr(e,["locale"]);return xp(In({locale:t},i))},Pp=(r={})=>{var e=r,{locale:t=bt()}=e,i=tr(e,["locale"]);return Cp(In({locale:t},i))},Ap=qi((r,e=bt())=>new ep(r,e,Yt().formats,{ignoreTag:Yt().ignoreTag})),kp=(r,e={})=>{var t,i,o,n;let a=e;typeof r=="object"&&(a=r,r=a.id);const{values:s,locale:l=bt(),default:d}=a;if(l==null)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let u=Fl(r,l);if(!u)u=(n=(o=(i=(t=Yt()).handleMissingMessage)==null?void 0:i.call(t,{locale:l,id:r,defaultValue:d}))!=null?o:d)!=null?n:r;else if(typeof u!="string")return console.warn(`[svelte-i18n] Message with id "${r}" must be of type "string", found: "${typeof u}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),u;if(!s)return u;let c=u;try{c=Ap(u,l).format(s)}catch(h){h instanceof Error&&console.warn(`[svelte-i18n] Message "${r}" has syntax error:`,h.message)}return c},Ip=(r,e)=>Pp(e).format(r),Sp=(r,e)=>Tp(e).format(r),Dp=(r,e)=>Ep(e).format(r),Op=(r,e=bt())=>Fl(r,e),ql=er([yt,jr],()=>kp);er([yt],()=>Ip);er([yt],()=>Sp);er([yt],()=>Dp);er([yt,jr],()=>Op);window.emWidgets={topic:jc};const Yl=r=>r.toLowerCase().match(/android/i)?"Android":r.toLowerCase().match(/iphone/i)?"iPhone":r.toLowerCase().match(/ipad|ipod/i)?"iPad":"PC";String(Number.MAX_SAFE_INTEGER).length;function Qe(r){"@babel/helpers - typeof";return Qe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Qe(r)}function be(r){if(r===null||r===!0||r===!1)return NaN;var e=Number(r);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function ee(r,e){if(e.length<r)throw new TypeError(r+" argument"+(r>1?"s":"")+" required, but only "+e.length+" present")}function ce(r){ee(1,arguments);var e=Object.prototype.toString.call(r);return r instanceof Date||Qe(r)==="object"&&e==="[object Date]"?new Date(r.getTime()):typeof r=="number"||e==="[object Number]"?new Date(r):((typeof r=="string"||e==="[object String]")&&typeof console!="undefined"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Np(r,e){ee(2,arguments);var t=ce(r),i=be(e);if(isNaN(i))return new Date(NaN);if(!i)return t;var o=t.getDate(),n=new Date(t.getTime());n.setMonth(t.getMonth()+i+1,0);var a=n.getDate();return o>=a?n:(t.setFullYear(n.getFullYear(),n.getMonth(),o),t)}function Mp(r,e){ee(2,arguments);var t=ce(r).getTime(),i=be(e);return new Date(t+i)}var Bp={};function rr(){return Bp}function Gl(r){var e=new Date(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate(),r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()));return e.setUTCFullYear(r.getFullYear()),r.getTime()-e.getTime()}function Lp(r){ee(1,arguments);var e=ce(r);return e.setHours(0,0,0,0),e}var zp=6e4,Hp=36e5,Rp=1e3;function Fp(r){return ee(1,arguments),r instanceof Date||Qe(r)==="object"&&Object.prototype.toString.call(r)==="[object Date]"}function $p(r){if(ee(1,arguments),!Fp(r)&&typeof r!="number")return!1;var e=ce(r);return!isNaN(Number(e))}function Vp(r){ee(1,arguments);var e=ce(r);return e.setHours(23,59,59,999),e}function Xl(r,e){ee(2,arguments);var t=be(e);return Mp(r,-t)}var Up=864e5;function Wp(r){ee(1,arguments);var e=ce(r),t=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var i=e.getTime(),o=t-i;return Math.floor(o/Up)+1}function Gt(r){ee(1,arguments);var e=1,t=ce(r),i=t.getUTCDay(),o=(i<e?7:0)+i-e;return t.setUTCDate(t.getUTCDate()-o),t.setUTCHours(0,0,0,0),t}function Kl(r){ee(1,arguments);var e=ce(r),t=e.getUTCFullYear(),i=new Date(0);i.setUTCFullYear(t+1,0,4),i.setUTCHours(0,0,0,0);var o=Gt(i),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var a=Gt(n);return e.getTime()>=o.getTime()?t+1:e.getTime()>=a.getTime()?t:t-1}function jp(r){ee(1,arguments);var e=Kl(r),t=new Date(0);t.setUTCFullYear(e,0,4),t.setUTCHours(0,0,0,0);var i=Gt(t);return i}var qp=6048e5;function Ql(r){ee(1,arguments);var e=ce(r),t=Gt(e).getTime()-jp(e).getTime();return Math.round(t/qp)+1}function vt(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=rr(),c=be((t=(i=(o=(n=e==null?void 0:e.weekStartsOn)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&o!==void 0?o:u.weekStartsOn)!==null&&i!==void 0?i:(l=u.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&t!==void 0?t:0);if(!(c>=0&&c<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=ce(r),p=h.getUTCDay(),m=(p<c?7:0)+p-c;return h.setUTCDate(h.getUTCDate()-m),h.setUTCHours(0,0,0,0),h}function Sn(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=ce(r),c=u.getUTCFullYear(),h=rr(),p=be((t=(i=(o=(n=e==null?void 0:e.firstWeekContainsDate)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&o!==void 0?o:h.firstWeekContainsDate)!==null&&i!==void 0?i:(l=h.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&t!==void 0?t:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var m=new Date(0);m.setUTCFullYear(c+1,0,p),m.setUTCHours(0,0,0,0);var f=vt(m,e),y=new Date(0);y.setUTCFullYear(c,0,p),y.setUTCHours(0,0,0,0);var E=vt(y,e);return u.getTime()>=f.getTime()?c+1:u.getTime()>=E.getTime()?c:c-1}function Yp(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=rr(),c=be((t=(i=(o=(n=e==null?void 0:e.firstWeekContainsDate)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&o!==void 0?o:u.firstWeekContainsDate)!==null&&i!==void 0?i:(l=u.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&t!==void 0?t:1),h=Sn(r,e),p=new Date(0);p.setUTCFullYear(h,0,c),p.setUTCHours(0,0,0,0);var m=vt(p,e);return m}var Gp=6048e5;function Jl(r,e){ee(1,arguments);var t=ce(r),i=vt(t,e).getTime()-Yp(t,e).getTime();return Math.round(i/Gp)+1}function Y(r,e){for(var t=r<0?"-":"",i=Math.abs(r).toString();i.length<e;)i="0"+i;return t+i}var rt={y:function(e,t){var i=e.getUTCFullYear(),o=i>0?i:1-i;return Y(t==="yy"?o%100:o,t.length)},M:function(e,t){var i=e.getUTCMonth();return t==="M"?String(i+1):Y(i+1,2)},d:function(e,t){return Y(e.getUTCDate(),t.length)},a:function(e,t){var i=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.toUpperCase();case"aaa":return i;case"aaaaa":return i[0];case"aaaa":default:return i==="am"?"a.m.":"p.m."}},h:function(e,t){return Y(e.getUTCHours()%12||12,t.length)},H:function(e,t){return Y(e.getUTCHours(),t.length)},m:function(e,t){return Y(e.getUTCMinutes(),t.length)},s:function(e,t){return Y(e.getUTCSeconds(),t.length)},S:function(e,t){var i=t.length,o=e.getUTCMilliseconds(),n=Math.floor(o*Math.pow(10,i-3));return Y(n,t.length)}},Ot={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Xp={G:function(e,t,i){var o=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return i.era(o,{width:"abbreviated"});case"GGGGG":return i.era(o,{width:"narrow"});case"GGGG":default:return i.era(o,{width:"wide"})}},y:function(e,t,i){if(t==="yo"){var o=e.getUTCFullYear(),n=o>0?o:1-o;return i.ordinalNumber(n,{unit:"year"})}return rt.y(e,t)},Y:function(e,t,i,o){var n=Sn(e,o),a=n>0?n:1-n;if(t==="YY"){var s=a%100;return Y(s,2)}return t==="Yo"?i.ordinalNumber(a,{unit:"year"}):Y(a,t.length)},R:function(e,t){var i=Kl(e);return Y(i,t.length)},u:function(e,t){var i=e.getUTCFullYear();return Y(i,t.length)},Q:function(e,t,i){var o=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(o);case"QQ":return Y(o,2);case"Qo":return i.ordinalNumber(o,{unit:"quarter"});case"QQQ":return i.quarter(o,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return i.quarter(o,{width:"wide",context:"formatting"})}},q:function(e,t,i){var o=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(o);case"qq":return Y(o,2);case"qo":return i.ordinalNumber(o,{unit:"quarter"});case"qqq":return i.quarter(o,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return i.quarter(o,{width:"wide",context:"standalone"})}},M:function(e,t,i){var o=e.getUTCMonth();switch(t){case"M":case"MM":return rt.M(e,t);case"Mo":return i.ordinalNumber(o+1,{unit:"month"});case"MMM":return i.month(o,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return i.month(o,{width:"wide",context:"formatting"})}},L:function(e,t,i){var o=e.getUTCMonth();switch(t){case"L":return String(o+1);case"LL":return Y(o+1,2);case"Lo":return i.ordinalNumber(o+1,{unit:"month"});case"LLL":return i.month(o,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return i.month(o,{width:"wide",context:"standalone"})}},w:function(e,t,i,o){var n=Jl(e,o);return t==="wo"?i.ordinalNumber(n,{unit:"week"}):Y(n,t.length)},I:function(e,t,i){var o=Ql(e);return t==="Io"?i.ordinalNumber(o,{unit:"week"}):Y(o,t.length)},d:function(e,t,i){return t==="do"?i.ordinalNumber(e.getUTCDate(),{unit:"date"}):rt.d(e,t)},D:function(e,t,i){var o=Wp(e);return t==="Do"?i.ordinalNumber(o,{unit:"dayOfYear"}):Y(o,t.length)},E:function(e,t,i){var o=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return i.day(o,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(o,{width:"short",context:"formatting"});case"EEEE":default:return i.day(o,{width:"wide",context:"formatting"})}},e:function(e,t,i,o){var n=e.getUTCDay(),a=(n-o.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return Y(a,2);case"eo":return i.ordinalNumber(a,{unit:"day"});case"eee":return i.day(n,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(n,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(n,{width:"short",context:"formatting"});case"eeee":default:return i.day(n,{width:"wide",context:"formatting"})}},c:function(e,t,i,o){var n=e.getUTCDay(),a=(n-o.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return Y(a,t.length);case"co":return i.ordinalNumber(a,{unit:"day"});case"ccc":return i.day(n,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(n,{width:"narrow",context:"standalone"});case"cccccc":return i.day(n,{width:"short",context:"standalone"});case"cccc":default:return i.day(n,{width:"wide",context:"standalone"})}},i:function(e,t,i){var o=e.getUTCDay(),n=o===0?7:o;switch(t){case"i":return String(n);case"ii":return Y(n,t.length);case"io":return i.ordinalNumber(n,{unit:"day"});case"iii":return i.day(o,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(o,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(o,{width:"short",context:"formatting"});case"iiii":default:return i.day(o,{width:"wide",context:"formatting"})}},a:function(e,t,i){var o=e.getUTCHours(),n=o/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"aaaa":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},b:function(e,t,i){var o=e.getUTCHours(),n;switch(o===12?n=Ot.noon:o===0?n=Ot.midnight:n=o/12>=1?"pm":"am",t){case"b":case"bb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"bbbb":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},B:function(e,t,i){var o=e.getUTCHours(),n;switch(o>=17?n=Ot.evening:o>=12?n=Ot.afternoon:o>=4?n=Ot.morning:n=Ot.night,t){case"B":case"BB":case"BBB":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"BBBB":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},h:function(e,t,i){if(t==="ho"){var o=e.getUTCHours()%12;return o===0&&(o=12),i.ordinalNumber(o,{unit:"hour"})}return rt.h(e,t)},H:function(e,t,i){return t==="Ho"?i.ordinalNumber(e.getUTCHours(),{unit:"hour"}):rt.H(e,t)},K:function(e,t,i){var o=e.getUTCHours()%12;return t==="Ko"?i.ordinalNumber(o,{unit:"hour"}):Y(o,t.length)},k:function(e,t,i){var o=e.getUTCHours();return o===0&&(o=24),t==="ko"?i.ordinalNumber(o,{unit:"hour"}):Y(o,t.length)},m:function(e,t,i){return t==="mo"?i.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):rt.m(e,t)},s:function(e,t,i){return t==="so"?i.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):rt.s(e,t)},S:function(e,t){return rt.S(e,t)},X:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();if(a===0)return"Z";switch(t){case"X":return qa(a);case"XXXX":case"XX":return ht(a);case"XXXXX":case"XXX":default:return ht(a,":")}},x:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"x":return qa(a);case"xxxx":case"xx":return ht(a);case"xxxxx":case"xxx":default:return ht(a,":")}},O:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+ja(a,":");case"OOOO":default:return"GMT"+ht(a,":")}},z:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+ja(a,":");case"zzzz":default:return"GMT"+ht(a,":")}},t:function(e,t,i,o){var n=o._originalDate||e,a=Math.floor(n.getTime()/1e3);return Y(a,t.length)},T:function(e,t,i,o){var n=o._originalDate||e,a=n.getTime();return Y(a,t.length)}};function ja(r,e){var t=r>0?"-":"+",i=Math.abs(r),o=Math.floor(i/60),n=i%60;if(n===0)return t+String(o);var a=e;return t+String(o)+a+Y(n,2)}function qa(r,e){if(r%60===0){var t=r>0?"-":"+";return t+Y(Math.abs(r)/60,2)}return ht(r,e)}function ht(r,e){var t=e||"",i=r>0?"-":"+",o=Math.abs(r),n=Y(Math.floor(o/60),2),a=Y(o%60,2);return i+n+t+a}var Ya=function(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},Zl=function(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},Kp=function(e,t){var i=e.match(/(P+)(p+)?/)||[],o=i[1],n=i[2];if(!n)return Ya(e,t);var a;switch(o){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",Ya(o,t)).replace("{{time}}",Zl(n,t))},Ko={p:Zl,P:Kp},Qp=["D","DD"],Jp=["YY","YYYY"];function ed(r){return Qp.indexOf(r)!==-1}function td(r){return Jp.indexOf(r)!==-1}function Ti(r,e,t){if(r==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Zp={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},em=function(e,t,i){var o,n=Zp[e];return typeof n=="string"?o=n:t===1?o=n.one:o=n.other.replace("{{count}}",t.toString()),i!=null&&i.addSuffix?i.comparison&&i.comparison>0?"in "+o:o+" ago":o};function vo(r){return function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.width?String(e.width):r.defaultWidth,i=r.formats[t]||r.formats[r.defaultWidth];return i}}var tm={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},rm={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},im={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},om={date:vo({formats:tm,defaultWidth:"full"}),time:vo({formats:rm,defaultWidth:"full"}),dateTime:vo({formats:im,defaultWidth:"full"})},nm={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},am=function(e,t,i,o){return nm[e]};function _r(r){return function(e,t){var i=t!=null&&t.context?String(t.context):"standalone",o;if(i==="formatting"&&r.formattingValues){var n=r.defaultFormattingWidth||r.defaultWidth,a=t!=null&&t.width?String(t.width):n;o=r.formattingValues[a]||r.formattingValues[n]}else{var s=r.defaultWidth,l=t!=null&&t.width?String(t.width):r.defaultWidth;o=r.values[l]||r.values[s]}var d=r.argumentCallback?r.argumentCallback(e):e;return o[d]}}var sm={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},lm={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},dm={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},um={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},cm={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},hm={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},pm=function(e,t){var i=Number(e),o=i%100;if(o>20||o<10)switch(o%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},mm={ordinalNumber:pm,era:_r({values:sm,defaultWidth:"wide"}),quarter:_r({values:lm,defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:_r({values:dm,defaultWidth:"wide"}),day:_r({values:um,defaultWidth:"wide"}),dayPeriod:_r({values:cm,defaultWidth:"wide",formattingValues:hm,defaultFormattingWidth:"wide"})};function vr(r){return function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=t.width,o=i&&r.matchPatterns[i]||r.matchPatterns[r.defaultMatchWidth],n=e.match(o);if(!n)return null;var a=n[0],s=i&&r.parsePatterns[i]||r.parsePatterns[r.defaultParseWidth],l=Array.isArray(s)?_m(s,function(c){return c.test(a)}):fm(s,function(c){return c.test(a)}),d;d=r.valueCallback?r.valueCallback(l):l,d=t.valueCallback?t.valueCallback(d):d;var u=e.slice(a.length);return{value:d,rest:u}}}function fm(r,e){for(var t in r)if(r.hasOwnProperty(t)&&e(r[t]))return t}function _m(r,e){for(var t=0;t<r.length;t++)if(e(r[t]))return t}function vm(r){return function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=e.match(r.matchPattern);if(!i)return null;var o=i[0],n=e.match(r.parsePattern);if(!n)return null;var a=r.valueCallback?r.valueCallback(n[0]):n[0];a=t.valueCallback?t.valueCallback(a):a;var s=e.slice(o.length);return{value:a,rest:s}}}var gm=/^(\d+)(th|st|nd|rd)?/i,bm=/\d+/i,ym={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},wm={any:[/^b/i,/^(a|c)/i]},xm={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Cm={any:[/1/i,/2/i,/3/i,/4/i]},Em={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Tm={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Pm={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Am={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},km={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Im={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Sm={ordinalNumber:vm({matchPattern:gm,parsePattern:bm,valueCallback:function(e){return parseInt(e,10)}}),era:vr({matchPatterns:ym,defaultMatchWidth:"wide",parsePatterns:wm,defaultParseWidth:"any"}),quarter:vr({matchPatterns:xm,defaultMatchWidth:"wide",parsePatterns:Cm,defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:vr({matchPatterns:Em,defaultMatchWidth:"wide",parsePatterns:Tm,defaultParseWidth:"any"}),day:vr({matchPatterns:Pm,defaultMatchWidth:"wide",parsePatterns:Am,defaultParseWidth:"any"}),dayPeriod:vr({matchPatterns:km,defaultMatchWidth:"any",parsePatterns:Im,defaultParseWidth:"any"})},rd={code:"en-US",formatDistance:em,formatLong:om,formatRelative:am,localize:mm,match:Sm,options:{weekStartsOn:0,firstWeekContainsDate:1}},Dm=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Om=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Nm=/^'([^]*?)'?$/,Mm=/''/g,Bm=/[a-zA-Z]/;function je(r,e,t){var i,o,n,a,s,l,d,u,c,h,p,m,f,y;ee(2,arguments);var E=String(e),x=rr(),A=(i=(o=void 0)!==null&&o!==void 0?o:x.locale)!==null&&i!==void 0?i:rd,D=be((n=(a=(s=(l=void 0)!==null&&l!==void 0?l:void 0)!==null&&s!==void 0?s:x.firstWeekContainsDate)!==null&&a!==void 0?a:(d=x.locale)===null||d===void 0||(u=d.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var j=be((c=(h=(p=(m=void 0)!==null&&m!==void 0?m:void 0)!==null&&p!==void 0?p:x.weekStartsOn)!==null&&h!==void 0?h:(f=x.locale)===null||f===void 0||(y=f.options)===null||y===void 0?void 0:y.weekStartsOn)!==null&&c!==void 0?c:0);if(!(j>=0&&j<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!A.localize)throw new RangeError("locale must contain localize property");if(!A.formatLong)throw new RangeError("locale must contain formatLong property");var $=ce(r);if(!$p($))throw new RangeError("Invalid time value");var J=Gl($),W=Xl($,J),X={firstWeekContainsDate:D,weekStartsOn:j,locale:A,_originalDate:$},I=E.match(Om).map(function(P){var k=P[0];if(k==="p"||k==="P"){var he=Ko[k];return he(P,A.formatLong)}return P}).join("").match(Dm).map(function(P){if(P==="''")return"'";var k=P[0];if(k==="'")return Lm(P);var he=Xp[k];if(he)return td(P)&&Ti(P,e,String(r)),ed(P)&&Ti(P,e,String(r)),he(W,P,A.localize,X);if(k.match(Bm))throw new RangeError("Format string contains an unescaped latin alphabet character `"+k+"`");return P}).join("");return I}function Lm(r){var e=r.match(Nm);return e?e[1].replace(Mm,"'"):r}function zm(r,e){if(r==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=e[t]);return r}function Ga(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,i=Array(e);t<e;t++)i[t]=r[t];return i}function Hm(r,e){if(r){if(typeof r=="string")return Ga(r,e);var t={}.toString.call(r).slice(8,-1);return t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set"?Array.from(r):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?Ga(r,e):void 0}}function Xa(r,e){var t=typeof Symbol!="undefined"&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=Hm(r))||e){t&&(r=t);var i=0,o=function(){};return{s:o,n:function(){return i>=r.length?{done:!0}:{done:!1,value:r[i++]}},e:function(d){throw d},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
19
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var n,a=!0,s=!1;return{s:function(){t=t.call(r)},n:function(){var d=t.next();return a=d.done,d},e:function(d){s=!0,n=d},f:function(){try{a||t.return==null||t.return()}finally{if(s)throw n}}}}function w(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function Qo(r,e){return Qo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t},Qo(r,e)}function R(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&Qo(r,e)}function Pi(r){return Pi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Pi(r)}function id(){try{var r=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(id=function(){return!!r})()}function Rm(r,e){if(e&&(Qe(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return w(r)}function F(r){var e=id();return function(){var t,i=Pi(r);if(e){var o=Pi(this).constructor;t=Reflect.construct(i,arguments,o)}else t=i.apply(this,arguments);return Rm(this,t)}}function M(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function Fm(r,e){if(Qe(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var i=t.call(r,e);if(Qe(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function od(r){var e=Fm(r,"string");return Qe(e)=="symbol"?e:e+""}function $m(r,e){for(var t=0;t<e.length;t++){var i=e[t];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(r,od(i.key),i)}}function B(r,e,t){return e&&$m(r.prototype,e),Object.defineProperty(r,"prototype",{writable:!1}),r}function g(r,e,t){return(e=od(e))in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var Vm=10,nd=function(){function r(){M(this,r),g(this,"priority",void 0),g(this,"subPriority",0)}return B(r,[{key:"validate",value:function(t,i){return!0}}]),r}(),Um=function(r){R(t,r);var e=F(t);function t(i,o,n,a,s){var l;return M(this,t),l=e.call(this),l.value=i,l.validateValue=o,l.setValue=n,l.priority=a,s&&(l.subPriority=s),l}return B(t,[{key:"validate",value:function(o,n){return this.validateValue(o,this.value,n)}},{key:"set",value:function(o,n,a){return this.setValue(o,n,this.value,a)}}]),t}(nd),Wm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",Vm),g(w(i),"subPriority",-1),i}return B(t,[{key:"set",value:function(o,n){if(n.timestampIsSet)return o;var a=new Date(0);return a.setFullYear(o.getUTCFullYear(),o.getUTCMonth(),o.getUTCDate()),a.setHours(o.getUTCHours(),o.getUTCMinutes(),o.getUTCSeconds(),o.getUTCMilliseconds()),a}}]),t}(nd),U=function(){function r(){M(this,r),g(this,"incompatibleTokens",void 0),g(this,"priority",void 0),g(this,"subPriority",void 0)}return B(r,[{key:"run",value:function(t,i,o,n){var a=this.parse(t,i,o,n);return a?{setter:new Um(a.value,this.validate,this.set,this.priority,this.subPriority),rest:a.rest}:null}},{key:"validate",value:function(t,i,o){return!0}}]),r}(),jm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",140),g(w(i),"incompatibleTokens",["R","u","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"G":case"GG":case"GGG":return a.era(o,{width:"abbreviated"})||a.era(o,{width:"narrow"});case"GGGGG":return a.era(o,{width:"narrow"});case"GGGG":default:return a.era(o,{width:"wide"})||a.era(o,{width:"abbreviated"})||a.era(o,{width:"narrow"})}}},{key:"set",value:function(o,n,a){return n.era=a,o.setUTCFullYear(a,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),se={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},Ve={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function le(r,e){return r&&{value:e(r.value),rest:r.rest}}function ie(r,e){var t=e.match(r);return t?{value:parseInt(t[0],10),rest:e.slice(t[0].length)}:null}function Ue(r,e){var t=e.match(r);if(!t)return null;if(t[0]==="Z")return{value:0,rest:e.slice(1)};var i=t[1]==="+"?1:-1,o=t[2]?parseInt(t[2],10):0,n=t[3]?parseInt(t[3],10):0,a=t[5]?parseInt(t[5],10):0;return{value:i*(o*Hp+n*zp+a*Rp),rest:e.slice(t[0].length)}}function ad(r){return ie(se.anyDigitsSigned,r)}function ae(r,e){switch(r){case 1:return ie(se.singleDigit,e);case 2:return ie(se.twoDigits,e);case 3:return ie(se.threeDigits,e);case 4:return ie(se.fourDigits,e);default:return ie(new RegExp("^\\d{1,"+r+"}"),e)}}function Ai(r,e){switch(r){case 1:return ie(se.singleDigitSigned,e);case 2:return ie(se.twoDigitsSigned,e);case 3:return ie(se.threeDigitsSigned,e);case 4:return ie(se.fourDigitsSigned,e);default:return ie(new RegExp("^-?\\d{1,"+r+"}"),e)}}function Dn(r){switch(r){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function sd(r,e){var t=e>0,i=t?e:1-e,o;if(i<=50)o=r||100;else{var n=i+50,a=Math.floor(n/100)*100,s=r>=n%100;o=r+a-(s?100:0)}return t?o:1-o}function ld(r){return r%400===0||r%4===0&&r%100!==0}var qm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){var s=function(d){return{year:d,isTwoDigitYear:n==="yy"}};switch(n){case"y":return le(ae(4,o),s);case"yo":return le(a.ordinalNumber(o,{unit:"year"}),s);default:return le(ae(n.length,o),s)}}},{key:"validate",value:function(o,n){return n.isTwoDigitYear||n.year>0}},{key:"set",value:function(o,n,a){var s=o.getUTCFullYear();if(a.isTwoDigitYear){var l=sd(a.year,s);return o.setUTCFullYear(l,0,1),o.setUTCHours(0,0,0,0),o}var d=!("era"in n)||n.era===1?a.year:1-a.year;return o.setUTCFullYear(d,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),Ym=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){var s=function(d){return{year:d,isTwoDigitYear:n==="YY"}};switch(n){case"Y":return le(ae(4,o),s);case"Yo":return le(a.ordinalNumber(o,{unit:"year"}),s);default:return le(ae(n.length,o),s)}}},{key:"validate",value:function(o,n){return n.isTwoDigitYear||n.year>0}},{key:"set",value:function(o,n,a,s){var l=Sn(o,s);if(a.isTwoDigitYear){var d=sd(a.year,l);return o.setUTCFullYear(d,0,s.firstWeekContainsDate),o.setUTCHours(0,0,0,0),vt(o,s)}var u=!("era"in n)||n.era===1?a.year:1-a.year;return o.setUTCFullYear(u,0,s.firstWeekContainsDate),o.setUTCHours(0,0,0,0),vt(o,s)}}]),t}(U),Gm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n){return Ai(n==="R"?4:n.length,o)}},{key:"set",value:function(o,n,a){var s=new Date(0);return s.setUTCFullYear(a,0,4),s.setUTCHours(0,0,0,0),Gt(s)}}]),t}(U),Xm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n){return Ai(n==="u"?4:n.length,o)}},{key:"set",value:function(o,n,a){return o.setUTCFullYear(a,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),Km=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",120),g(w(i),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"Q":case"QQ":return ae(n.length,o);case"Qo":return a.ordinalNumber(o,{unit:"quarter"});case"QQQ":return a.quarter(o,{width:"abbreviated",context:"formatting"})||a.quarter(o,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(o,{width:"wide",context:"formatting"})||a.quarter(o,{width:"abbreviated",context:"formatting"})||a.quarter(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=1&&n<=4}},{key:"set",value:function(o,n,a){return o.setUTCMonth((a-1)*3,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),Qm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",120),g(w(i),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"q":case"qq":return ae(n.length,o);case"qo":return a.ordinalNumber(o,{unit:"quarter"});case"qqq":return a.quarter(o,{width:"abbreviated",context:"standalone"})||a.quarter(o,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(o,{width:"wide",context:"standalone"})||a.quarter(o,{width:"abbreviated",context:"standalone"})||a.quarter(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=1&&n<=4}},{key:"set",value:function(o,n,a){return o.setUTCMonth((a-1)*3,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),Jm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),g(w(i),"priority",110),i}return B(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d-1};switch(n){case"M":return le(ie(se.month,o),s);case"MM":return le(ae(2,o),s);case"Mo":return le(a.ordinalNumber(o,{unit:"month"}),s);case"MMM":return a.month(o,{width:"abbreviated",context:"formatting"})||a.month(o,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(o,{width:"wide",context:"formatting"})||a.month(o,{width:"abbreviated",context:"formatting"})||a.month(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){return o.setUTCMonth(a,1),o.setUTCHours(0,0,0,0),o}}]),t}(U),Zm=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",110),g(w(i),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d-1};switch(n){case"L":return le(ie(se.month,o),s);case"LL":return le(ae(2,o),s);case"Lo":return le(a.ordinalNumber(o,{unit:"month"}),s);case"LLL":return a.month(o,{width:"abbreviated",context:"standalone"})||a.month(o,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(o,{width:"wide",context:"standalone"})||a.month(o,{width:"abbreviated",context:"standalone"})||a.month(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){return o.setUTCMonth(a,1),o.setUTCHours(0,0,0,0),o}}]),t}(U);function ef(r,e,t){ee(2,arguments);var i=ce(r),o=be(e),n=Jl(i,t)-o;return i.setUTCDate(i.getUTCDate()-n*7),i}var tf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",100),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"w":return ie(se.week,o);case"wo":return a.ordinalNumber(o,{unit:"week"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=53}},{key:"set",value:function(o,n,a,s){return vt(ef(o,a,s),s)}}]),t}(U);function rf(r,e){ee(2,arguments);var t=ce(r),i=be(e),o=Ql(t)-i;return t.setUTCDate(t.getUTCDate()-o*7),t}var of=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",100),g(w(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"I":return ie(se.week,o);case"Io":return a.ordinalNumber(o,{unit:"week"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=53}},{key:"set",value:function(o,n,a){return Gt(rf(o,a))}}]),t}(U),nf=[31,28,31,30,31,30,31,31,30,31,30,31],af=[31,29,31,30,31,30,31,31,30,31,30,31],sf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"subPriority",1),g(w(i),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"d":return ie(se.date,o);case"do":return a.ordinalNumber(o,{unit:"date"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){var a=o.getUTCFullYear(),s=ld(a),l=o.getUTCMonth();return s?n>=1&&n<=af[l]:n>=1&&n<=nf[l]}},{key:"set",value:function(o,n,a){return o.setUTCDate(a),o.setUTCHours(0,0,0,0),o}}]),t}(U),lf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"subpriority",1),g(w(i),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"D":case"DD":return ie(se.dayOfYear,o);case"Do":return a.ordinalNumber(o,{unit:"date"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){var a=o.getUTCFullYear(),s=ld(a);return s?n>=1&&n<=366:n>=1&&n<=365}},{key:"set",value:function(o,n,a){return o.setUTCMonth(0,a),o.setUTCHours(0,0,0,0),o}}]),t}(U);function On(r,e,t){var i,o,n,a,s,l,d,u;ee(2,arguments);var c=rr(),h=be((i=(o=(n=(a=t==null?void 0:t.weekStartsOn)!==null&&a!==void 0?a:t==null||(s=t.locale)===null||s===void 0||(l=s.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:c.weekStartsOn)!==null&&o!==void 0?o:(d=c.locale)===null||d===void 0||(u=d.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&i!==void 0?i:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var p=ce(r),m=be(e),f=p.getUTCDay(),y=m%7,E=(y+7)%7,x=(E<h?7:0)+m-f;return p.setUTCDate(p.getUTCDate()+x),p}var df=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["D","i","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"E":case"EE":case"EEE":return a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"EEEE":default:return a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(U),uf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a,s){var l=function(u){var c=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+c};switch(n){case"e":case"ee":return le(ae(n.length,o),l);case"eo":return le(a.ordinalNumber(o,{unit:"day"}),l);case"eee":return a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"eeeee":return a.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"eeee":default:return a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(U),cf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a,s){var l=function(u){var c=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+c};switch(n){case"c":case"cc":return le(ae(n.length,o),l);case"co":return le(a.ordinalNumber(o,{unit:"day"}),l);case"ccc":return a.day(o,{width:"abbreviated",context:"standalone"})||a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"});case"ccccc":return a.day(o,{width:"narrow",context:"standalone"});case"cccccc":return a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"});case"cccc":default:return a.day(o,{width:"wide",context:"standalone"})||a.day(o,{width:"abbreviated",context:"standalone"})||a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(U);function hf(r,e){ee(2,arguments);var t=be(e);t%7===0&&(t=t-7);var i=1,o=ce(r),n=o.getUTCDay(),a=t%7,s=(a+7)%7,l=(s<i?7:0)+t-n;return o.setUTCDate(o.getUTCDate()+l),o}var pf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d===0?7:d};switch(n){case"i":case"ii":return ae(n.length,o);case"io":return a.ordinalNumber(o,{unit:"day"});case"iii":return le(a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s);case"iiiii":return le(a.day(o,{width:"narrow",context:"formatting"}),s);case"iiiiii":return le(a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s);case"iiii":default:return le(a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(o,n){return n>=1&&n<=7}},{key:"set",value:function(o,n,a){return o=hf(o,a),o.setUTCHours(0,0,0,0),o}}]),t}(U),mf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["b","B","H","k","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"a":case"aa":case"aaa":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(U),ff=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["a","B","H","k","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"b":case"bb":case"bbb":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(U),_f=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["a","b","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"B":case"BB":case"BBB":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(U),vf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["H","K","k","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"h":return ie(se.hour12h,o);case"ho":return a.ordinalNumber(o,{unit:"hour"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=12}},{key:"set",value:function(o,n,a){var s=o.getUTCHours()>=12;return s&&a<12?o.setUTCHours(a+12,0,0,0):!s&&a===12?o.setUTCHours(0,0,0,0):o.setUTCHours(a,0,0,0),o}}]),t}(U),gf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["a","b","h","K","k","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"H":return ie(se.hour23h,o);case"Ho":return a.ordinalNumber(o,{unit:"hour"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=23}},{key:"set",value:function(o,n,a){return o.setUTCHours(a,0,0,0),o}}]),t}(U),bf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["h","H","k","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"K":return ie(se.hour11h,o);case"Ko":return a.ordinalNumber(o,{unit:"hour"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){var s=o.getUTCHours()>=12;return s&&a<12?o.setUTCHours(a+12,0,0,0):o.setUTCHours(a,0,0,0),o}}]),t}(U),yf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["a","b","h","H","K","t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"k":return ie(se.hour24h,o);case"ko":return a.ordinalNumber(o,{unit:"hour"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=24}},{key:"set",value:function(o,n,a){var s=a<=24?a%24:a;return o.setUTCHours(s,0,0,0),o}}]),t}(U),wf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",60),g(w(i),"incompatibleTokens",["t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"m":return ie(se.minute,o);case"mo":return a.ordinalNumber(o,{unit:"minute"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=59}},{key:"set",value:function(o,n,a){return o.setUTCMinutes(a,0,0),o}}]),t}(U),xf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",50),g(w(i),"incompatibleTokens",["t","T"]),i}return B(t,[{key:"parse",value:function(o,n,a){switch(n){case"s":return ie(se.second,o);case"so":return a.ordinalNumber(o,{unit:"second"});default:return ae(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=59}},{key:"set",value:function(o,n,a){return o.setUTCSeconds(a,0),o}}]),t}(U),Cf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",30),g(w(i),"incompatibleTokens",["t","T"]),i}return B(t,[{key:"parse",value:function(o,n){var a=function(l){return Math.floor(l*Math.pow(10,-n.length+3))};return le(ae(n.length,o),a)}},{key:"set",value:function(o,n,a){return o.setUTCMilliseconds(a),o}}]),t}(U),Ef=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",10),g(w(i),"incompatibleTokens",["t","T","x"]),i}return B(t,[{key:"parse",value:function(o,n){switch(n){case"X":return Ue(Ve.basicOptionalMinutes,o);case"XX":return Ue(Ve.basic,o);case"XXXX":return Ue(Ve.basicOptionalSeconds,o);case"XXXXX":return Ue(Ve.extendedOptionalSeconds,o);case"XXX":default:return Ue(Ve.extended,o)}}},{key:"set",value:function(o,n,a){return n.timestampIsSet?o:new Date(o.getTime()-a)}}]),t}(U),Tf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",10),g(w(i),"incompatibleTokens",["t","T","X"]),i}return B(t,[{key:"parse",value:function(o,n){switch(n){case"x":return Ue(Ve.basicOptionalMinutes,o);case"xx":return Ue(Ve.basic,o);case"xxxx":return Ue(Ve.basicOptionalSeconds,o);case"xxxxx":return Ue(Ve.extendedOptionalSeconds,o);case"xxx":default:return Ue(Ve.extended,o)}}},{key:"set",value:function(o,n,a){return n.timestampIsSet?o:new Date(o.getTime()-a)}}]),t}(U),Pf=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",40),g(w(i),"incompatibleTokens","*"),i}return B(t,[{key:"parse",value:function(o){return ad(o)}},{key:"set",value:function(o,n,a){return[new Date(a*1e3),{timestampIsSet:!0}]}}]),t}(U),Af=function(r){R(t,r);var e=F(t);function t(){var i;M(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",20),g(w(i),"incompatibleTokens","*"),i}return B(t,[{key:"parse",value:function(o){return ad(o)}},{key:"set",value:function(o,n,a){return[new Date(a),{timestampIsSet:!0}]}}]),t}(U),kf={G:new jm,y:new qm,Y:new Ym,R:new Gm,u:new Xm,Q:new Km,q:new Qm,M:new Jm,L:new Zm,w:new tf,I:new of,d:new sf,D:new lf,E:new df,e:new uf,c:new cf,i:new pf,a:new mf,b:new ff,B:new _f,h:new vf,H:new gf,K:new bf,k:new yf,m:new wf,s:new xf,S:new Cf,X:new Ef,x:new Tf,t:new Pf,T:new Af},If=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Sf=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Df=/^'([^]*?)'?$/,Of=/''/g,Nf=/\S/,Mf=/[a-zA-Z]/;function Ka(r,e,t,i){var o,n,a,s,l,d,u,c,h,p,m,f,y,E;ee(3,arguments);var x=String(r),A=String(e),D=rr(),j=(o=(n=void 0)!==null&&n!==void 0?n:D.locale)!==null&&o!==void 0?o:rd;if(!j.match)throw new RangeError("locale must contain match property");var $=be((a=(s=(l=(d=void 0)!==null&&d!==void 0?d:void 0)!==null&&l!==void 0?l:D.firstWeekContainsDate)!==null&&s!==void 0?s:(u=D.locale)===null||u===void 0||(c=u.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!($>=1&&$<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var J=be((h=(p=(m=(f=void 0)!==null&&f!==void 0?f:void 0)!==null&&m!==void 0?m:D.weekStartsOn)!==null&&p!==void 0?p:(y=D.locale)===null||y===void 0||(E=y.options)===null||E===void 0?void 0:E.weekStartsOn)!==null&&h!==void 0?h:0);if(!(J>=0&&J<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(A==="")return x===""?ce(t):new Date(NaN);var W={firstWeekContainsDate:$,weekStartsOn:J,locale:j},X=[new Wm],I=A.match(Sf).map(function(te){var q=te[0];if(q in Ko){var ye=Ko[q];return ye(te,j.formatLong)}return te}).join("").match(If),P=[],k=Xa(I),he;try{var Ze=function(){var q=he.value;!(i!=null&&i.useAdditionalWeekYearTokens)&&td(q)&&Ti(q,A,r),!(i!=null&&i.useAdditionalDayOfYearTokens)&&ed(q)&&Ti(q,A,r);var ye=q[0],Tt=kf[ye];if(Tt){var ei=Tt.incompatibleTokens;if(Array.isArray(ei)){var lr=P.find(function(ti){return ei.includes(ti.token)||ti.token===ye});if(lr)throw new RangeError("The format string mustn't contain `".concat(lr.fullToken,"` and `").concat(q,"` at the same time"))}else if(Tt.incompatibleTokens==="*"&&P.length>0)throw new RangeError("The format string mustn't contain `".concat(q,"` and any other token at the same time"));P.push({token:ye,fullToken:q});var Pt=Tt.run(x,q,j.match,W);if(!Pt)return{v:new Date(NaN)};X.push(Pt.setter),x=Pt.rest}else{if(ye.match(Mf))throw new RangeError("Format string contains an unescaped latin alphabet character `"+ye+"`");if(q==="''"?q="'":ye==="'"&&(q=Bf(q)),x.indexOf(q)===0)x=x.slice(q.length);else return{v:new Date(NaN)}}};for(k.s();!(he=k.n()).done;){var Te=Ze();if(Qe(Te)==="object")return Te.v}}catch(te){k.e(te)}finally{k.f()}if(x.length>0&&Nf.test(x))return new Date(NaN);var et=X.map(function(te){return te.priority}).sort(function(te,q){return q-te}).filter(function(te,q,ye){return ye.indexOf(te)===q}).map(function(te){return X.filter(function(q){return q.priority===te}).sort(function(q,ye){return ye.subPriority-q.subPriority})}).map(function(te){return te[0]}),Be=ce(t);if(isNaN(Be.getTime()))return new Date(NaN);var ue=Xl(Be,Gl(Be)),K={},oe=Xa(et),ar;try{for(oe.s();!(ar=oe.n()).done;){var sr=ar.value;if(!sr.validate(ue,W))return new Date(NaN);var ke=sr.set(ue,K,W);Array.isArray(ke)?(ue=ke[0],zm(K,ke[1])):ue=ke}}catch(te){oe.e(te)}finally{oe.f()}return ue}function Bf(r){return r.match(Df)[1].replace(Of,"'")}function Lf(r,e){ee(2,arguments);var t=be(e);return Np(r,-t)}function Qa(r,e){kn(r,e)}function zf(r){yt.set(r)}const Ja={en:{titleBonusesHistory:"Bonus History",dateFrom:"From:",dateTo:"To:",dateFilter:"Filter",noBonusHistory:"You have no bonuses for the selected period."},"zh-hk":{titleBonusesHistory:"獎金歷史",dateFrom:"從:",dateTo:"至:",dateFilter:"篩選",noBonusHistory:"您目前沒有獎金歷史。"},fr:{titleBonusesHistory:"Historique du bonus",dateFrom:"De:",dateTo:"A:",dateFilter:"Filtre",noBonusHistory:"Vous n'avez pas d'historique de bonus pour le moment."},ro:{titleBonusesHistory:"Istoric bonusuri",dateFrom:"De la",dateTo:"La",dateFilter:"Filtru",noBonusHistory:"Nu ai bonusuri pentru perioada selectata."},es:{titleBonusesHistory:"Historial de Bonos",dateFrom:"Desde:",dateTo:"A:",dateFilter:"Filtro",noBonusHistory:"No tiene Bonos para el periodo seleccionado."},pt:{titleBonusesHistory:"Histórico de bônus",dateFrom:"A partir de:",dateTo:"Para:",dateFilter:"Filtro:",noBonusHistory:"Você não tem histórico de bônus no momento."},hr:{titleBonusesHistory:"Povijest bonusa",dateFrom:"Od:",dateTo:"Do:",dateFilter:"Filter",noBonusHistory:"Nemate bonusa u povijesti."},"pt-br":{titleBonusesHistory:"Histórico de bônus",dateFrom:"De:",dateTo:"PARA:",dateFilter:"Filtro",noBonusHistory:"Não há bônus para o período selecionado"},"es-mx":{titleBonusesHistory:"Historial de bonos",dateFrom:"De:",dateTo:"A:",dateFilter:"Filtro",noBonusHistory:"No tiene bonus para el periodo seleccionado"},tr:{titleBonusesHistory:"Bonus Geçmişi",dateFrom:"İtibaren:",dateTo:"İle:",dateFilter:"Filtre",noBonusHistory:"Seçilen dönem için bonusunuz yok."},"en-us":{titleBonusesHistory:"Bonus History",dateFrom:"From:",dateTo:"To:",dateFilter:"Filter",noBonusHistory:"You have no bonuses for the selected period."}},Hf={GRANTED:"/v1/bonus/granted"},Za={TYPES:"standard,freeBet,freeRound,cashBack,stakeBack,oddsBoost,wagering",STATUS_ACTIVE:"active",STATUS_COMPLETED:"completed,released,forfeited,expired,closed"};function Rf(t){return mr(this,arguments,function*(r,e={}){const i=typeof r=="string"?r:r.toString(),o=yield fetch(i,e);let n=null;try{n=yield o.json()}catch(l){n=null}if(o.ok&&n)return n;const a=n&&typeof n=="object"?n:{},s={success:!1,errorMessage:typeof a.errorMessage=="string"&&a.errorMessage||o.statusText||String(o.status),errorCode:typeof a.errorCode=="number"?a.errorCode:void 0};return ut(ut({},a),s)})}function Ff(r,e,t){return mr(this,null,function*(){const i=new URL(`${r}${Hf.GRANTED}`);Object.entries(t).forEach(([n,a])=>{a!=null&&i.searchParams.append(n,String(a))});const o={};return e&&(o["x-SessionId"]=e),Rf(i,{headers:o})})}if(typeof window!="undefined"){let r=function(e){return function(...t){try{return e.apply(this,t)}catch(i){if(i instanceof DOMException&&i.message.includes("has already been used with this registry")||i.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw i}}};customElements.define=r(customElements.define),Promise.resolve().then(()=>require("./PlayerBonusCard-CKgXB5tw.cjs")).then(({default:e})=>{!customElements.get("player-bonus-card")&&customElements.define("player-bonus-card",e.element)})}var $f=Object.defineProperty,Vf=Object.defineProperties,Uf=Object.getOwnPropertyDescriptors,es=Object.getOwnPropertySymbols,Wf=Object.prototype.hasOwnProperty,jf=Object.prototype.propertyIsEnumerable,Jo=(r,e,t)=>e in r?$f(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ki=(r,e)=>{for(var t in e||(e={}))Wf.call(e,t)&&Jo(r,t,e[t]);if(es)for(var t of es(e))jf.call(e,t)&&Jo(r,t,e[t]);return r},dd=(r,e)=>Vf(r,Uf(e)),ve=(r,e,t)=>(Jo(r,typeof e!="symbol"?e+"":e,t),t),Ii=(r,e,t)=>new Promise((i,o)=>{var n=l=>{try{s(t.next(l))}catch(d){o(d)}},a=l=>{try{s(t.throw(l))}catch(d){o(d)}},s=l=>l.done?i(l.value):Promise.resolve(l.value).then(n,a);s((t=t.apply(r,e)).next())});/**
|
|
18
|
+
`,qt.MISSING_INTL_API,a);var N=t.getPluralRules(e,{type:u.pluralType}).select(h-(u.offset||0));T=u.options[N]||u.options.other}if(!T)throw new Fa(u.value,h,Object.keys(u.options),a);s.push.apply(s,_i(T.value,e,t,i,o,h-(u.offset||0)));continue}}return Kh(s)}function Jh(r,e){return e?Fe(Fe(Fe({},r||{}),e||{}),Object.keys(r).reduce(function(t,i){return t[i]=Fe(Fe({},r[i]),e[i]||{}),t},{})):r}function Zh(r,e){return e?Object.keys(r).reduce(function(t,i){return t[i]=Jh(r[i],e[i]),t},Fe({},r)):r}function fo(r){return{create:function(){return{get:function(e){return r[e]},set:function(e,t){r[e]=t}}}}}function ep(r){return r===void 0&&(r={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.NumberFormat).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.number),strategy:po.variadic}),getDateTimeFormat:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.DateTimeFormat).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.dateTime),strategy:po.variadic}),getPluralRules:ho(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.PluralRules).bind.apply(e,co([void 0],t,!1)))},{cache:fo(r.pluralRules),strategy:po.variadic})}}var tp=function(){function r(e,t,i,o){t===void 0&&(t=r.defaultLocale);var n=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(l){var d=n.formatToParts(l);if(d.length===1)return d[0].value;var u=d.reduce(function(c,h){return!c.length||h.type!==we.literal||typeof c[c.length-1]!="string"?c.push(h.value):c[c.length-1]+=h.value,c},[]);return u.length<=1?u[0]||"":u},this.formatToParts=function(l){return _i(n.ast,n.locales,n.formatters,n.formats,l,void 0,n.message)},this.resolvedOptions=function(){var l;return{locale:((l=n.resolvedLocale)===null||l===void 0?void 0:l.toString())||Intl.NumberFormat.supportedLocalesOf(n.locales)[0]}},this.getAst=function(){return n.ast},this.locales=t,this.resolvedLocale=r.resolveLocale(t),typeof e=="string"){if(this.message=e,!r.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var a=o||{};a.formatters;var s=uh(a,["formatters"]);this.ast=r.__parse(e,Fe(Fe({},s),{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.");this.formats=Zh(r.formats,i),this.formatters=o&&o.formatters||ep(this.formatterCache)}return Object.defineProperty(r,"defaultLocale",{get:function(){return r.memoizedDefaultLocale||(r.memoizedDefaultLocale=new Intl.NumberFormat().resolvedOptions().locale),r.memoizedDefaultLocale},enumerable:!1,configurable:!0}),r.memoizedDefaultLocale=null,r.resolveLocale=function(e){if(typeof Intl.Locale!="undefined"){var t=Intl.NumberFormat.supportedLocalesOf(e);return t.length>0?new Intl.Locale(t[0]):new Intl.Locale(typeof e=="string"?e:e[0])}},r.__parse=Yh,r.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"}}},r}();function rp(r,e){if(e==null)return;if(e in r)return r[e];const t=e.split(".");let i=r;for(let o=0;o<t.length;o++)if(typeof i=="object"){if(o>0){const n=t.slice(o,t.length).join(".");if(n in i){i=i[n];break}}i=i[t[o]]}else i=void 0;return i}const ot={},ip=(r,e,t)=>t&&(e in ot||(ot[e]={}),r in ot[e]||(ot[e][r]=t),t),Fl=(r,e)=>{if(e==null)return;if(e in ot&&r in ot[e])return ot[e][r];const t=ji(e);for(let i=0;i<t.length;i++){const o=t[i],n=np(o,r);if(n)return ip(r,e,n)}};let An;const Wr=Vi({});function op(r){return An[r]||null}function $l(r){return r in An}function np(r,e){if(!$l(r))return null;const t=op(r);return rp(t,e)}function ap(r){if(r==null)return;const e=ji(r);for(let t=0;t<e.length;t++){const i=e[t];if($l(i))return i}}function kn(r,...e){delete ot[r],Wr.update(t=>(t[r]=dh.all([t[r]||{},...e]),t))}er([Wr],([r])=>Object.keys(r));Wr.subscribe(r=>An=r);const vi={};function sp(r,e){vi[r].delete(e),vi[r].size===0&&delete vi[r]}function Vl(r){return vi[r]}function lp(r){return ji(r).map(e=>{const t=Vl(e);return[e,t?[...t]:[]]}).filter(([,e])=>e.length>0)}function Go(r){return r==null?!1:ji(r).some(e=>{var t;return(t=Vl(e))==null?void 0:t.size})}function dp(r,e){return Promise.all(e.map(i=>(sp(r,i),i().then(o=>o.default||o)))).then(i=>kn(r,...i))}const mr={};function Ul(r){if(!Go(r))return r in mr?mr[r]:Promise.resolve();const e=lp(r);return mr[r]=Promise.all(e.map(([t,i])=>dp(t,i))).then(()=>{if(Go(r))return Ul(r);delete mr[r]}),mr[r]}const up={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"}}},cp={fallbackLocale:null,loadingDelay:200,formats:up,warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0},hp=cp;function Yt(){return hp}const _o=Vi(!1);var pp=Object.defineProperty,mp=Object.defineProperties,fp=Object.getOwnPropertyDescriptors,$a=Object.getOwnPropertySymbols,_p=Object.prototype.hasOwnProperty,vp=Object.prototype.propertyIsEnumerable,Va=(r,e,t)=>e in r?pp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,gp=(r,e)=>{for(var t in e||(e={}))_p.call(e,t)&&Va(r,t,e[t]);if($a)for(var t of $a(e))vp.call(e,t)&&Va(r,t,e[t]);return r},bp=(r,e)=>mp(r,fp(e));let Xo;const Ci=Vi(null);function Ua(r){return r.split("-").map((e,t,i)=>i.slice(0,t+1).join("-")).reverse()}function ji(r,e=Yt().fallbackLocale){const t=Ua(r);return e?[...new Set([...t,...Ua(e)])]:t}function yt(){return Xo!=null?Xo:void 0}Ci.subscribe(r=>{Xo=r!=null?r:void 0,typeof window!="undefined"&&r!=null&&document.documentElement.setAttribute("lang",r)});const yp=r=>{if(r&&ap(r)&&Go(r)){const{loadingDelay:e}=Yt();let t;return typeof window!="undefined"&&yt()!=null&&e?t=window.setTimeout(()=>_o.set(!0),e):_o.set(!0),Ul(r).then(()=>{Ci.set(r)}).finally(()=>{clearTimeout(t),_o.set(!1)})}return Ci.set(r)},wt=bp(gp({},Ci),{set:yp}),qi=r=>{const e=Object.create(null);return i=>{const o=JSON.stringify(i);return o in e?e[o]:e[o]=r(i)}};var wp=Object.defineProperty,Ei=Object.getOwnPropertySymbols,Wl=Object.prototype.hasOwnProperty,jl=Object.prototype.propertyIsEnumerable,Wa=(r,e,t)=>e in r?wp(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,In=(r,e)=>{for(var t in e||(e={}))Wl.call(e,t)&&Wa(r,t,e[t]);if(Ei)for(var t of Ei(e))jl.call(e,t)&&Wa(r,t,e[t]);return r},tr=(r,e)=>{var t={};for(var i in r)Wl.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&Ei)for(var i of Ei(r))e.indexOf(i)<0&&jl.call(r,i)&&(t[i]=r[i]);return t};const Sr=(r,e)=>{const{formats:t}=Yt();if(r in t&&e in t[r])return t[r][e];throw new Error(`[svelte-i18n] Unknown "${e}" ${r} format.`)},xp=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return i&&(o=Sr("number",i)),new Intl.NumberFormat(t,o)}),Cp=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return i?o=Sr("date",i):Object.keys(o).length===0&&(o=Sr("date","short")),new Intl.DateTimeFormat(t,o)}),Ep=qi(r=>{var e=r,{locale:t,format:i}=e,o=tr(e,["locale","format"]);if(t==null)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return i?o=Sr("time",i):Object.keys(o).length===0&&(o=Sr("time","short")),new Intl.DateTimeFormat(t,o)}),Tp=(r={})=>{var e=r,{locale:t=yt()}=e,i=tr(e,["locale"]);return xp(In({locale:t},i))},Pp=(r={})=>{var e=r,{locale:t=yt()}=e,i=tr(e,["locale"]);return Cp(In({locale:t},i))},Ap=(r={})=>{var e=r,{locale:t=yt()}=e,i=tr(e,["locale"]);return Ep(In({locale:t},i))},kp=qi((r,e=yt())=>new tp(r,e,Yt().formats,{ignoreTag:Yt().ignoreTag})),Ip=(r,e={})=>{var t,i,o,n;let a=e;typeof r=="object"&&(a=r,r=a.id);const{values:s,locale:l=yt(),default:d}=a;if(l==null)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let u=Fl(r,l);if(!u)u=(n=(o=(i=(t=Yt()).handleMissingMessage)==null?void 0:i.call(t,{locale:l,id:r,defaultValue:d}))!=null?o:d)!=null?n:r;else if(typeof u!="string")return console.warn(`[svelte-i18n] Message with id "${r}" must be of type "string", found: "${typeof u}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),u;if(!s)return u;let c=u;try{c=kp(u,l).format(s)}catch(h){h instanceof Error&&console.warn(`[svelte-i18n] Message "${r}" has syntax error:`,h.message)}return c},Sp=(r,e)=>Ap(e).format(r),Dp=(r,e)=>Pp(e).format(r),Op=(r,e)=>Tp(e).format(r),Np=(r,e=yt())=>Fl(r,e),ql=er([wt,Wr],()=>Ip);er([wt],()=>Sp);er([wt],()=>Dp);er([wt],()=>Op);er([wt,Wr],()=>Np);window.emWidgets={topic:qc};const Yl=r=>r.toLowerCase().match(/android/i)?"Android":r.toLowerCase().match(/iphone/i)?"iPhone":r.toLowerCase().match(/ipad|ipod/i)?"iPad":"PC";String(Number.MAX_SAFE_INTEGER).length;function Ke(r){"@babel/helpers - typeof";return Ke=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ke(r)}function be(r){if(r===null||r===!0||r===!1)return NaN;var e=Number(r);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function ee(r,e){if(e.length<r)throw new TypeError(r+" argument"+(r>1?"s":"")+" required, but only "+e.length+" present")}function ce(r){ee(1,arguments);var e=Object.prototype.toString.call(r);return r instanceof Date||Ke(r)==="object"&&e==="[object Date]"?new Date(r.getTime()):typeof r=="number"||e==="[object Number]"?new Date(r):((typeof r=="string"||e==="[object String]")&&typeof console!="undefined"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Mp(r,e){ee(2,arguments);var t=ce(r),i=be(e);if(isNaN(i))return new Date(NaN);if(!i)return t;var o=t.getDate(),n=new Date(t.getTime());n.setMonth(t.getMonth()+i+1,0);var a=n.getDate();return o>=a?n:(t.setFullYear(n.getFullYear(),n.getMonth(),o),t)}function Bp(r,e){ee(2,arguments);var t=ce(r).getTime(),i=be(e);return new Date(t+i)}var Lp={};function rr(){return Lp}function Gl(r){var e=new Date(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate(),r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()));return e.setUTCFullYear(r.getFullYear()),r.getTime()-e.getTime()}function zp(r){ee(1,arguments);var e=ce(r);return e.setHours(0,0,0,0),e}var Hp=6e4,Rp=36e5,Fp=1e3;function $p(r){return ee(1,arguments),r instanceof Date||Ke(r)==="object"&&Object.prototype.toString.call(r)==="[object Date]"}function Vp(r){if(ee(1,arguments),!$p(r)&&typeof r!="number")return!1;var e=ce(r);return!isNaN(Number(e))}function Up(r){ee(1,arguments);var e=ce(r);return e.setHours(23,59,59,999),e}function Xl(r,e){ee(2,arguments);var t=be(e);return Bp(r,-t)}var Wp=864e5;function jp(r){ee(1,arguments);var e=ce(r),t=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var i=e.getTime(),o=t-i;return Math.floor(o/Wp)+1}function Gt(r){ee(1,arguments);var e=1,t=ce(r),i=t.getUTCDay(),o=(i<e?7:0)+i-e;return t.setUTCDate(t.getUTCDate()-o),t.setUTCHours(0,0,0,0),t}function Kl(r){ee(1,arguments);var e=ce(r),t=e.getUTCFullYear(),i=new Date(0);i.setUTCFullYear(t+1,0,4),i.setUTCHours(0,0,0,0);var o=Gt(i),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var a=Gt(n);return e.getTime()>=o.getTime()?t+1:e.getTime()>=a.getTime()?t:t-1}function qp(r){ee(1,arguments);var e=Kl(r),t=new Date(0);t.setUTCFullYear(e,0,4),t.setUTCHours(0,0,0,0);var i=Gt(t);return i}var Yp=6048e5;function Ql(r){ee(1,arguments);var e=ce(r),t=Gt(e).getTime()-qp(e).getTime();return Math.round(t/Yp)+1}function gt(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=rr(),c=be((t=(i=(o=(n=e==null?void 0:e.weekStartsOn)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&o!==void 0?o:u.weekStartsOn)!==null&&i!==void 0?i:(l=u.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&t!==void 0?t:0);if(!(c>=0&&c<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=ce(r),p=h.getUTCDay(),m=(p<c?7:0)+p-c;return h.setUTCDate(h.getUTCDate()-m),h.setUTCHours(0,0,0,0),h}function Sn(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=ce(r),c=u.getUTCFullYear(),h=rr(),p=be((t=(i=(o=(n=e==null?void 0:e.firstWeekContainsDate)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&o!==void 0?o:h.firstWeekContainsDate)!==null&&i!==void 0?i:(l=h.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&t!==void 0?t:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var m=new Date(0);m.setUTCFullYear(c+1,0,p),m.setUTCHours(0,0,0,0);var f=gt(m,e),y=new Date(0);y.setUTCFullYear(c,0,p),y.setUTCHours(0,0,0,0);var E=gt(y,e);return u.getTime()>=f.getTime()?c+1:u.getTime()>=E.getTime()?c:c-1}function Gp(r,e){var t,i,o,n,a,s,l,d;ee(1,arguments);var u=rr(),c=be((t=(i=(o=(n=e==null?void 0:e.firstWeekContainsDate)!==null&&n!==void 0?n:e==null||(a=e.locale)===null||a===void 0||(s=a.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&o!==void 0?o:u.firstWeekContainsDate)!==null&&i!==void 0?i:(l=u.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&t!==void 0?t:1),h=Sn(r,e),p=new Date(0);p.setUTCFullYear(h,0,c),p.setUTCHours(0,0,0,0);var m=gt(p,e);return m}var Xp=6048e5;function Jl(r,e){ee(1,arguments);var t=ce(r),i=gt(t,e).getTime()-Gp(t,e).getTime();return Math.round(i/Xp)+1}function G(r,e){for(var t=r<0?"-":"",i=Math.abs(r).toString();i.length<e;)i="0"+i;return t+i}var tt={y:function(e,t){var i=e.getUTCFullYear(),o=i>0?i:1-i;return G(t==="yy"?o%100:o,t.length)},M:function(e,t){var i=e.getUTCMonth();return t==="M"?String(i+1):G(i+1,2)},d:function(e,t){return G(e.getUTCDate(),t.length)},a:function(e,t){var i=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.toUpperCase();case"aaa":return i;case"aaaaa":return i[0];case"aaaa":default:return i==="am"?"a.m.":"p.m."}},h:function(e,t){return G(e.getUTCHours()%12||12,t.length)},H:function(e,t){return G(e.getUTCHours(),t.length)},m:function(e,t){return G(e.getUTCMinutes(),t.length)},s:function(e,t){return G(e.getUTCSeconds(),t.length)},S:function(e,t){var i=t.length,o=e.getUTCMilliseconds(),n=Math.floor(o*Math.pow(10,i-3));return G(n,t.length)}},Ot={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Kp={G:function(e,t,i){var o=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return i.era(o,{width:"abbreviated"});case"GGGGG":return i.era(o,{width:"narrow"});case"GGGG":default:return i.era(o,{width:"wide"})}},y:function(e,t,i){if(t==="yo"){var o=e.getUTCFullYear(),n=o>0?o:1-o;return i.ordinalNumber(n,{unit:"year"})}return tt.y(e,t)},Y:function(e,t,i,o){var n=Sn(e,o),a=n>0?n:1-n;if(t==="YY"){var s=a%100;return G(s,2)}return t==="Yo"?i.ordinalNumber(a,{unit:"year"}):G(a,t.length)},R:function(e,t){var i=Kl(e);return G(i,t.length)},u:function(e,t){var i=e.getUTCFullYear();return G(i,t.length)},Q:function(e,t,i){var o=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(o);case"QQ":return G(o,2);case"Qo":return i.ordinalNumber(o,{unit:"quarter"});case"QQQ":return i.quarter(o,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return i.quarter(o,{width:"wide",context:"formatting"})}},q:function(e,t,i){var o=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(o);case"qq":return G(o,2);case"qo":return i.ordinalNumber(o,{unit:"quarter"});case"qqq":return i.quarter(o,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return i.quarter(o,{width:"wide",context:"standalone"})}},M:function(e,t,i){var o=e.getUTCMonth();switch(t){case"M":case"MM":return tt.M(e,t);case"Mo":return i.ordinalNumber(o+1,{unit:"month"});case"MMM":return i.month(o,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return i.month(o,{width:"wide",context:"formatting"})}},L:function(e,t,i){var o=e.getUTCMonth();switch(t){case"L":return String(o+1);case"LL":return G(o+1,2);case"Lo":return i.ordinalNumber(o+1,{unit:"month"});case"LLL":return i.month(o,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return i.month(o,{width:"wide",context:"standalone"})}},w:function(e,t,i,o){var n=Jl(e,o);return t==="wo"?i.ordinalNumber(n,{unit:"week"}):G(n,t.length)},I:function(e,t,i){var o=Ql(e);return t==="Io"?i.ordinalNumber(o,{unit:"week"}):G(o,t.length)},d:function(e,t,i){return t==="do"?i.ordinalNumber(e.getUTCDate(),{unit:"date"}):tt.d(e,t)},D:function(e,t,i){var o=jp(e);return t==="Do"?i.ordinalNumber(o,{unit:"dayOfYear"}):G(o,t.length)},E:function(e,t,i){var o=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return i.day(o,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(o,{width:"short",context:"formatting"});case"EEEE":default:return i.day(o,{width:"wide",context:"formatting"})}},e:function(e,t,i,o){var n=e.getUTCDay(),a=(n-o.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return G(a,2);case"eo":return i.ordinalNumber(a,{unit:"day"});case"eee":return i.day(n,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(n,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(n,{width:"short",context:"formatting"});case"eeee":default:return i.day(n,{width:"wide",context:"formatting"})}},c:function(e,t,i,o){var n=e.getUTCDay(),a=(n-o.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return G(a,t.length);case"co":return i.ordinalNumber(a,{unit:"day"});case"ccc":return i.day(n,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(n,{width:"narrow",context:"standalone"});case"cccccc":return i.day(n,{width:"short",context:"standalone"});case"cccc":default:return i.day(n,{width:"wide",context:"standalone"})}},i:function(e,t,i){var o=e.getUTCDay(),n=o===0?7:o;switch(t){case"i":return String(n);case"ii":return G(n,t.length);case"io":return i.ordinalNumber(n,{unit:"day"});case"iii":return i.day(o,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(o,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(o,{width:"short",context:"formatting"});case"iiii":default:return i.day(o,{width:"wide",context:"formatting"})}},a:function(e,t,i){var o=e.getUTCHours(),n=o/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"aaaa":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},b:function(e,t,i){var o=e.getUTCHours(),n;switch(o===12?n=Ot.noon:o===0?n=Ot.midnight:n=o/12>=1?"pm":"am",t){case"b":case"bb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"bbbb":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},B:function(e,t,i){var o=e.getUTCHours(),n;switch(o>=17?n=Ot.evening:o>=12?n=Ot.afternoon:o>=4?n=Ot.morning:n=Ot.night,t){case"B":case"BB":case"BBB":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(n,{width:"narrow",context:"formatting"});case"BBBB":default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},h:function(e,t,i){if(t==="ho"){var o=e.getUTCHours()%12;return o===0&&(o=12),i.ordinalNumber(o,{unit:"hour"})}return tt.h(e,t)},H:function(e,t,i){return t==="Ho"?i.ordinalNumber(e.getUTCHours(),{unit:"hour"}):tt.H(e,t)},K:function(e,t,i){var o=e.getUTCHours()%12;return t==="Ko"?i.ordinalNumber(o,{unit:"hour"}):G(o,t.length)},k:function(e,t,i){var o=e.getUTCHours();return o===0&&(o=24),t==="ko"?i.ordinalNumber(o,{unit:"hour"}):G(o,t.length)},m:function(e,t,i){return t==="mo"?i.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):tt.m(e,t)},s:function(e,t,i){return t==="so"?i.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):tt.s(e,t)},S:function(e,t){return tt.S(e,t)},X:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();if(a===0)return"Z";switch(t){case"X":return qa(a);case"XXXX":case"XX":return pt(a);case"XXXXX":case"XXX":default:return pt(a,":")}},x:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"x":return qa(a);case"xxxx":case"xx":return pt(a);case"xxxxx":case"xxx":default:return pt(a,":")}},O:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+ja(a,":");case"OOOO":default:return"GMT"+pt(a,":")}},z:function(e,t,i,o){var n=o._originalDate||e,a=n.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+ja(a,":");case"zzzz":default:return"GMT"+pt(a,":")}},t:function(e,t,i,o){var n=o._originalDate||e,a=Math.floor(n.getTime()/1e3);return G(a,t.length)},T:function(e,t,i,o){var n=o._originalDate||e,a=n.getTime();return G(a,t.length)}};function ja(r,e){var t=r>0?"-":"+",i=Math.abs(r),o=Math.floor(i/60),n=i%60;if(n===0)return t+String(o);var a=e;return t+String(o)+a+G(n,2)}function qa(r,e){if(r%60===0){var t=r>0?"-":"+";return t+G(Math.abs(r)/60,2)}return pt(r,e)}function pt(r,e){var t=e||"",i=r>0?"-":"+",o=Math.abs(r),n=G(Math.floor(o/60),2),a=G(o%60,2);return i+n+t+a}var Ya=function(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},Zl=function(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},Qp=function(e,t){var i=e.match(/(P+)(p+)?/)||[],o=i[1],n=i[2];if(!n)return Ya(e,t);var a;switch(o){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",Ya(o,t)).replace("{{time}}",Zl(n,t))},Ko={p:Zl,P:Qp},Jp=["D","DD"],Zp=["YY","YYYY"];function ed(r){return Jp.indexOf(r)!==-1}function td(r){return Zp.indexOf(r)!==-1}function Ti(r,e,t){if(r==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(r==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(t,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var em={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},tm=function(e,t,i){var o,n=em[e];return typeof n=="string"?o=n:t===1?o=n.one:o=n.other.replace("{{count}}",t.toString()),i!=null&&i.addSuffix?i.comparison&&i.comparison>0?"in "+o:o+" ago":o};function vo(r){return function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=e.width?String(e.width):r.defaultWidth,i=r.formats[t]||r.formats[r.defaultWidth];return i}}var rm={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},im={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},om={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},nm={date:vo({formats:rm,defaultWidth:"full"}),time:vo({formats:im,defaultWidth:"full"}),dateTime:vo({formats:om,defaultWidth:"full"})},am={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},sm=function(e,t,i,o){return am[e]};function fr(r){return function(e,t){var i=t!=null&&t.context?String(t.context):"standalone",o;if(i==="formatting"&&r.formattingValues){var n=r.defaultFormattingWidth||r.defaultWidth,a=t!=null&&t.width?String(t.width):n;o=r.formattingValues[a]||r.formattingValues[n]}else{var s=r.defaultWidth,l=t!=null&&t.width?String(t.width):r.defaultWidth;o=r.values[l]||r.values[s]}var d=r.argumentCallback?r.argumentCallback(e):e;return o[d]}}var lm={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},dm={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},um={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},cm={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},hm={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},pm={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},mm=function(e,t){var i=Number(e),o=i%100;if(o>20||o<10)switch(o%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},fm={ordinalNumber:mm,era:fr({values:lm,defaultWidth:"wide"}),quarter:fr({values:dm,defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:fr({values:um,defaultWidth:"wide"}),day:fr({values:cm,defaultWidth:"wide"}),dayPeriod:fr({values:hm,defaultWidth:"wide",formattingValues:pm,defaultFormattingWidth:"wide"})};function _r(r){return function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=t.width,o=i&&r.matchPatterns[i]||r.matchPatterns[r.defaultMatchWidth],n=e.match(o);if(!n)return null;var a=n[0],s=i&&r.parsePatterns[i]||r.parsePatterns[r.defaultParseWidth],l=Array.isArray(s)?vm(s,function(c){return c.test(a)}):_m(s,function(c){return c.test(a)}),d;d=r.valueCallback?r.valueCallback(l):l,d=t.valueCallback?t.valueCallback(d):d;var u=e.slice(a.length);return{value:d,rest:u}}}function _m(r,e){for(var t in r)if(r.hasOwnProperty(t)&&e(r[t]))return t}function vm(r,e){for(var t=0;t<r.length;t++)if(e(r[t]))return t}function gm(r){return function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=e.match(r.matchPattern);if(!i)return null;var o=i[0],n=e.match(r.parsePattern);if(!n)return null;var a=r.valueCallback?r.valueCallback(n[0]):n[0];a=t.valueCallback?t.valueCallback(a):a;var s=e.slice(o.length);return{value:a,rest:s}}}var bm=/^(\d+)(th|st|nd|rd)?/i,ym=/\d+/i,wm={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},xm={any:[/^b/i,/^(a|c)/i]},Cm={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Em={any:[/1/i,/2/i,/3/i,/4/i]},Tm={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Pm={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Am={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},km={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Im={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Sm={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Dm={ordinalNumber:gm({matchPattern:bm,parsePattern:ym,valueCallback:function(e){return parseInt(e,10)}}),era:_r({matchPatterns:wm,defaultMatchWidth:"wide",parsePatterns:xm,defaultParseWidth:"any"}),quarter:_r({matchPatterns:Cm,defaultMatchWidth:"wide",parsePatterns:Em,defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:_r({matchPatterns:Tm,defaultMatchWidth:"wide",parsePatterns:Pm,defaultParseWidth:"any"}),day:_r({matchPatterns:Am,defaultMatchWidth:"wide",parsePatterns:km,defaultParseWidth:"any"}),dayPeriod:_r({matchPatterns:Im,defaultMatchWidth:"any",parsePatterns:Sm,defaultParseWidth:"any"})},rd={code:"en-US",formatDistance:tm,formatLong:nm,formatRelative:sm,localize:fm,match:Dm,options:{weekStartsOn:0,firstWeekContainsDate:1}},Om=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Nm=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Mm=/^'([^]*?)'?$/,Bm=/''/g,Lm=/[a-zA-Z]/;function We(r,e,t){var i,o,n,a,s,l,d,u,c,h,p,m,f,y;ee(2,arguments);var E=String(e),C=rr(),T=(i=(o=void 0)!==null&&o!==void 0?o:C.locale)!==null&&i!==void 0?i:rd,N=be((n=(a=(s=(l=void 0)!==null&&l!==void 0?l:void 0)!==null&&s!==void 0?s:C.firstWeekContainsDate)!==null&&a!==void 0?a:(d=C.locale)===null||d===void 0||(u=d.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(N>=1&&N<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var U=be((c=(h=(p=(m=void 0)!==null&&m!==void 0?m:void 0)!==null&&p!==void 0?p:C.weekStartsOn)!==null&&h!==void 0?h:(f=C.locale)===null||f===void 0||(y=f.options)===null||y===void 0?void 0:y.weekStartsOn)!==null&&c!==void 0?c:0);if(!(U>=0&&U<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!T.localize)throw new RangeError("locale must contain localize property");if(!T.formatLong)throw new RangeError("locale must contain formatLong property");var W=ce(r);if(!Vp(W))throw new RangeError("Invalid time value");var me=Gl(W),Y=Xl(W,me),O={firstWeekContainsDate:N,weekStartsOn:U,locale:T,_originalDate:W},I=E.match(Nm).map(function(S){var A=S[0];if(A==="p"||A==="P"){var de=Ko[A];return de(S,T.formatLong)}return S}).join("").match(Om).map(function(S){if(S==="''")return"'";var A=S[0];if(A==="'")return zm(S);var de=Kp[A];if(de)return td(S)&&Ti(S,e,String(r)),ed(S)&&Ti(S,e,String(r)),de(Y,S,T.localize,O);if(A.match(Lm))throw new RangeError("Format string contains an unescaped latin alphabet character `"+A+"`");return S}).join("");return I}function zm(r){var e=r.match(Mm);return e?e[1].replace(Bm,"'"):r}function Hm(r,e){if(r==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=e[t]);return r}function Ga(r,e){(e==null||e>r.length)&&(e=r.length);for(var t=0,i=Array(e);t<e;t++)i[t]=r[t];return i}function Rm(r,e){if(r){if(typeof r=="string")return Ga(r,e);var t={}.toString.call(r).slice(8,-1);return t==="Object"&&r.constructor&&(t=r.constructor.name),t==="Map"||t==="Set"?Array.from(r):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?Ga(r,e):void 0}}function Xa(r,e){var t=typeof Symbol!="undefined"&&r[Symbol.iterator]||r["@@iterator"];if(!t){if(Array.isArray(r)||(t=Rm(r))||e){t&&(r=t);var i=0,o=function(){};return{s:o,n:function(){return i>=r.length?{done:!0}:{done:!1,value:r[i++]}},e:function(d){throw d},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
19
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var n,a=!0,s=!1;return{s:function(){t=t.call(r)},n:function(){var d=t.next();return a=d.done,d},e:function(d){s=!0,n=d},f:function(){try{a||t.return==null||t.return()}finally{if(s)throw n}}}}function w(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}function Qo(r,e){return Qo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t},Qo(r,e)}function F(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");r.prototype=Object.create(e&&e.prototype,{constructor:{value:r,writable:!0,configurable:!0}}),Object.defineProperty(r,"prototype",{writable:!1}),e&&Qo(r,e)}function Pi(r){return Pi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Pi(r)}function id(){try{var r=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(id=function(){return!!r})()}function Fm(r,e){if(e&&(Ke(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return w(r)}function $(r){var e=id();return function(){var t,i=Pi(r);if(e){var o=Pi(this).constructor;t=Reflect.construct(i,arguments,o)}else t=i.apply(this,arguments);return Fm(this,t)}}function B(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function $m(r,e){if(Ke(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var i=t.call(r,e);if(Ke(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function od(r){var e=$m(r,"string");return Ke(e)=="symbol"?e:e+""}function Vm(r,e){for(var t=0;t<e.length;t++){var i=e[t];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(r,od(i.key),i)}}function L(r,e,t){return e&&Vm(r.prototype,e),Object.defineProperty(r,"prototype",{writable:!1}),r}function g(r,e,t){return(e=od(e))in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var Um=10,nd=function(){function r(){B(this,r),g(this,"priority",void 0),g(this,"subPriority",0)}return L(r,[{key:"validate",value:function(t,i){return!0}}]),r}(),Wm=function(r){F(t,r);var e=$(t);function t(i,o,n,a,s){var l;return B(this,t),l=e.call(this),l.value=i,l.validateValue=o,l.setValue=n,l.priority=a,s&&(l.subPriority=s),l}return L(t,[{key:"validate",value:function(o,n){return this.validateValue(o,this.value,n)}},{key:"set",value:function(o,n,a){return this.setValue(o,n,this.value,a)}}]),t}(nd),jm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",Um),g(w(i),"subPriority",-1),i}return L(t,[{key:"set",value:function(o,n){if(n.timestampIsSet)return o;var a=new Date(0);return a.setFullYear(o.getUTCFullYear(),o.getUTCMonth(),o.getUTCDate()),a.setHours(o.getUTCHours(),o.getUTCMinutes(),o.getUTCSeconds(),o.getUTCMilliseconds()),a}}]),t}(nd),q=function(){function r(){B(this,r),g(this,"incompatibleTokens",void 0),g(this,"priority",void 0),g(this,"subPriority",void 0)}return L(r,[{key:"run",value:function(t,i,o,n){var a=this.parse(t,i,o,n);return a?{setter:new Wm(a.value,this.validate,this.set,this.priority,this.subPriority),rest:a.rest}:null}},{key:"validate",value:function(t,i,o){return!0}}]),r}(),qm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",140),g(w(i),"incompatibleTokens",["R","u","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"G":case"GG":case"GGG":return a.era(o,{width:"abbreviated"})||a.era(o,{width:"narrow"});case"GGGGG":return a.era(o,{width:"narrow"});case"GGGG":default:return a.era(o,{width:"wide"})||a.era(o,{width:"abbreviated"})||a.era(o,{width:"narrow"})}}},{key:"set",value:function(o,n,a){return n.era=a,o.setUTCFullYear(a,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),ae={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},$e={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function se(r,e){return r&&{value:e(r.value),rest:r.rest}}function ie(r,e){var t=e.match(r);return t?{value:parseInt(t[0],10),rest:e.slice(t[0].length)}:null}function Ve(r,e){var t=e.match(r);if(!t)return null;if(t[0]==="Z")return{value:0,rest:e.slice(1)};var i=t[1]==="+"?1:-1,o=t[2]?parseInt(t[2],10):0,n=t[3]?parseInt(t[3],10):0,a=t[5]?parseInt(t[5],10):0;return{value:i*(o*Rp+n*Hp+a*Fp),rest:e.slice(t[0].length)}}function ad(r){return ie(ae.anyDigitsSigned,r)}function ne(r,e){switch(r){case 1:return ie(ae.singleDigit,e);case 2:return ie(ae.twoDigits,e);case 3:return ie(ae.threeDigits,e);case 4:return ie(ae.fourDigits,e);default:return ie(new RegExp("^\\d{1,"+r+"}"),e)}}function Ai(r,e){switch(r){case 1:return ie(ae.singleDigitSigned,e);case 2:return ie(ae.twoDigitsSigned,e);case 3:return ie(ae.threeDigitsSigned,e);case 4:return ie(ae.fourDigitsSigned,e);default:return ie(new RegExp("^-?\\d{1,"+r+"}"),e)}}function Dn(r){switch(r){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function sd(r,e){var t=e>0,i=t?e:1-e,o;if(i<=50)o=r||100;else{var n=i+50,a=Math.floor(n/100)*100,s=r>=n%100;o=r+a-(s?100:0)}return t?o:1-o}function ld(r){return r%400===0||r%4===0&&r%100!==0}var Ym=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){var s=function(d){return{year:d,isTwoDigitYear:n==="yy"}};switch(n){case"y":return se(ne(4,o),s);case"yo":return se(a.ordinalNumber(o,{unit:"year"}),s);default:return se(ne(n.length,o),s)}}},{key:"validate",value:function(o,n){return n.isTwoDigitYear||n.year>0}},{key:"set",value:function(o,n,a){var s=o.getUTCFullYear();if(a.isTwoDigitYear){var l=sd(a.year,s);return o.setUTCFullYear(l,0,1),o.setUTCHours(0,0,0,0),o}var d=!("era"in n)||n.era===1?a.year:1-a.year;return o.setUTCFullYear(d,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),Gm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){var s=function(d){return{year:d,isTwoDigitYear:n==="YY"}};switch(n){case"Y":return se(ne(4,o),s);case"Yo":return se(a.ordinalNumber(o,{unit:"year"}),s);default:return se(ne(n.length,o),s)}}},{key:"validate",value:function(o,n){return n.isTwoDigitYear||n.year>0}},{key:"set",value:function(o,n,a,s){var l=Sn(o,s);if(a.isTwoDigitYear){var d=sd(a.year,l);return o.setUTCFullYear(d,0,s.firstWeekContainsDate),o.setUTCHours(0,0,0,0),gt(o,s)}var u=!("era"in n)||n.era===1?a.year:1-a.year;return o.setUTCFullYear(u,0,s.firstWeekContainsDate),o.setUTCHours(0,0,0,0),gt(o,s)}}]),t}(q),Xm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n){return Ai(n==="R"?4:n.length,o)}},{key:"set",value:function(o,n,a){var s=new Date(0);return s.setUTCFullYear(a,0,4),s.setUTCHours(0,0,0,0),Gt(s)}}]),t}(q),Km=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",130),g(w(i),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n){return Ai(n==="u"?4:n.length,o)}},{key:"set",value:function(o,n,a){return o.setUTCFullYear(a,0,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),Qm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",120),g(w(i),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"Q":case"QQ":return ne(n.length,o);case"Qo":return a.ordinalNumber(o,{unit:"quarter"});case"QQQ":return a.quarter(o,{width:"abbreviated",context:"formatting"})||a.quarter(o,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(o,{width:"wide",context:"formatting"})||a.quarter(o,{width:"abbreviated",context:"formatting"})||a.quarter(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=1&&n<=4}},{key:"set",value:function(o,n,a){return o.setUTCMonth((a-1)*3,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),Jm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",120),g(w(i),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"q":case"qq":return ne(n.length,o);case"qo":return a.ordinalNumber(o,{unit:"quarter"});case"qqq":return a.quarter(o,{width:"abbreviated",context:"standalone"})||a.quarter(o,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(o,{width:"wide",context:"standalone"})||a.quarter(o,{width:"abbreviated",context:"standalone"})||a.quarter(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=1&&n<=4}},{key:"set",value:function(o,n,a){return o.setUTCMonth((a-1)*3,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),Zm=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),g(w(i),"priority",110),i}return L(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d-1};switch(n){case"M":return se(ie(ae.month,o),s);case"MM":return se(ne(2,o),s);case"Mo":return se(a.ordinalNumber(o,{unit:"month"}),s);case"MMM":return a.month(o,{width:"abbreviated",context:"formatting"})||a.month(o,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(o,{width:"wide",context:"formatting"})||a.month(o,{width:"abbreviated",context:"formatting"})||a.month(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){return o.setUTCMonth(a,1),o.setUTCHours(0,0,0,0),o}}]),t}(q),ef=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",110),g(w(i),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d-1};switch(n){case"L":return se(ie(ae.month,o),s);case"LL":return se(ne(2,o),s);case"Lo":return se(a.ordinalNumber(o,{unit:"month"}),s);case"LLL":return a.month(o,{width:"abbreviated",context:"standalone"})||a.month(o,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(o,{width:"wide",context:"standalone"})||a.month(o,{width:"abbreviated",context:"standalone"})||a.month(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){return o.setUTCMonth(a,1),o.setUTCHours(0,0,0,0),o}}]),t}(q);function tf(r,e,t){ee(2,arguments);var i=ce(r),o=be(e),n=Jl(i,t)-o;return i.setUTCDate(i.getUTCDate()-n*7),i}var rf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",100),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"w":return ie(ae.week,o);case"wo":return a.ordinalNumber(o,{unit:"week"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=53}},{key:"set",value:function(o,n,a,s){return gt(tf(o,a,s),s)}}]),t}(q);function of(r,e){ee(2,arguments);var t=ce(r),i=be(e),o=Ql(t)-i;return t.setUTCDate(t.getUTCDate()-o*7),t}var nf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",100),g(w(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"I":return ie(ae.week,o);case"Io":return a.ordinalNumber(o,{unit:"week"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=53}},{key:"set",value:function(o,n,a){return Gt(of(o,a))}}]),t}(q),af=[31,28,31,30,31,30,31,31,30,31,30,31],sf=[31,29,31,30,31,30,31,31,30,31,30,31],lf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"subPriority",1),g(w(i),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"d":return ie(ae.date,o);case"do":return a.ordinalNumber(o,{unit:"date"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){var a=o.getUTCFullYear(),s=ld(a),l=o.getUTCMonth();return s?n>=1&&n<=sf[l]:n>=1&&n<=af[l]}},{key:"set",value:function(o,n,a){return o.setUTCDate(a),o.setUTCHours(0,0,0,0),o}}]),t}(q),df=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"subpriority",1),g(w(i),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"D":case"DD":return ie(ae.dayOfYear,o);case"Do":return a.ordinalNumber(o,{unit:"date"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){var a=o.getUTCFullYear(),s=ld(a);return s?n>=1&&n<=366:n>=1&&n<=365}},{key:"set",value:function(o,n,a){return o.setUTCMonth(0,a),o.setUTCHours(0,0,0,0),o}}]),t}(q);function On(r,e,t){var i,o,n,a,s,l,d,u;ee(2,arguments);var c=rr(),h=be((i=(o=(n=(a=t==null?void 0:t.weekStartsOn)!==null&&a!==void 0?a:t==null||(s=t.locale)===null||s===void 0||(l=s.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:c.weekStartsOn)!==null&&o!==void 0?o:(d=c.locale)===null||d===void 0||(u=d.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&i!==void 0?i:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var p=ce(r),m=be(e),f=p.getUTCDay(),y=m%7,E=(y+7)%7,C=(E<h?7:0)+m-f;return p.setUTCDate(p.getUTCDate()+C),p}var uf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["D","i","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"E":case"EE":case"EEE":return a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"EEEE":default:return a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(q),cf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a,s){var l=function(u){var c=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+c};switch(n){case"e":case"ee":return se(ne(n.length,o),l);case"eo":return se(a.ordinalNumber(o,{unit:"day"}),l);case"eee":return a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"eeeee":return a.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"});case"eeee":default:return a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(q),hf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a,s){var l=function(u){var c=Math.floor((u-1)/7)*7;return(u+s.weekStartsOn+6)%7+c};switch(n){case"c":case"cc":return se(ne(n.length,o),l);case"co":return se(a.ordinalNumber(o,{unit:"day"}),l);case"ccc":return a.day(o,{width:"abbreviated",context:"standalone"})||a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"});case"ccccc":return a.day(o,{width:"narrow",context:"standalone"});case"cccccc":return a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"});case"cccc":default:return a.day(o,{width:"wide",context:"standalone"})||a.day(o,{width:"abbreviated",context:"standalone"})||a.day(o,{width:"short",context:"standalone"})||a.day(o,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(o,n){return n>=0&&n<=6}},{key:"set",value:function(o,n,a,s){return o=On(o,a,s),o.setUTCHours(0,0,0,0),o}}]),t}(q);function pf(r,e){ee(2,arguments);var t=be(e);t%7===0&&(t=t-7);var i=1,o=ce(r),n=o.getUTCDay(),a=t%7,s=(a+7)%7,l=(s<i?7:0)+t-n;return o.setUTCDate(o.getUTCDate()+l),o}var mf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",90),g(w(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){var s=function(d){return d===0?7:d};switch(n){case"i":case"ii":return ne(n.length,o);case"io":return a.ordinalNumber(o,{unit:"day"});case"iii":return se(a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s);case"iiiii":return se(a.day(o,{width:"narrow",context:"formatting"}),s);case"iiiiii":return se(a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s);case"iiii":default:return se(a.day(o,{width:"wide",context:"formatting"})||a.day(o,{width:"abbreviated",context:"formatting"})||a.day(o,{width:"short",context:"formatting"})||a.day(o,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(o,n){return n>=1&&n<=7}},{key:"set",value:function(o,n,a){return o=pf(o,a),o.setUTCHours(0,0,0,0),o}}]),t}(q),ff=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["b","B","H","k","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"a":case"aa":case"aaa":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(q),_f=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["a","B","H","k","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"b":case"bb":case"bbb":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(q),vf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",80),g(w(i),"incompatibleTokens",["a","b","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"B":case"BB":case"BBB":return a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(o,{width:"wide",context:"formatting"})||a.dayPeriod(o,{width:"abbreviated",context:"formatting"})||a.dayPeriod(o,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(o,n,a){return o.setUTCHours(Dn(a),0,0,0),o}}]),t}(q),gf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["H","K","k","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"h":return ie(ae.hour12h,o);case"ho":return a.ordinalNumber(o,{unit:"hour"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=12}},{key:"set",value:function(o,n,a){var s=o.getUTCHours()>=12;return s&&a<12?o.setUTCHours(a+12,0,0,0):!s&&a===12?o.setUTCHours(0,0,0,0):o.setUTCHours(a,0,0,0),o}}]),t}(q),bf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["a","b","h","K","k","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"H":return ie(ae.hour23h,o);case"Ho":return a.ordinalNumber(o,{unit:"hour"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=23}},{key:"set",value:function(o,n,a){return o.setUTCHours(a,0,0,0),o}}]),t}(q),yf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["h","H","k","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"K":return ie(ae.hour11h,o);case"Ko":return a.ordinalNumber(o,{unit:"hour"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=11}},{key:"set",value:function(o,n,a){var s=o.getUTCHours()>=12;return s&&a<12?o.setUTCHours(a+12,0,0,0):o.setUTCHours(a,0,0,0),o}}]),t}(q),wf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",70),g(w(i),"incompatibleTokens",["a","b","h","H","K","t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"k":return ie(ae.hour24h,o);case"ko":return a.ordinalNumber(o,{unit:"hour"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=1&&n<=24}},{key:"set",value:function(o,n,a){var s=a<=24?a%24:a;return o.setUTCHours(s,0,0,0),o}}]),t}(q),xf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",60),g(w(i),"incompatibleTokens",["t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"m":return ie(ae.minute,o);case"mo":return a.ordinalNumber(o,{unit:"minute"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=59}},{key:"set",value:function(o,n,a){return o.setUTCMinutes(a,0,0),o}}]),t}(q),Cf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",50),g(w(i),"incompatibleTokens",["t","T"]),i}return L(t,[{key:"parse",value:function(o,n,a){switch(n){case"s":return ie(ae.second,o);case"so":return a.ordinalNumber(o,{unit:"second"});default:return ne(n.length,o)}}},{key:"validate",value:function(o,n){return n>=0&&n<=59}},{key:"set",value:function(o,n,a){return o.setUTCSeconds(a,0),o}}]),t}(q),Ef=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",30),g(w(i),"incompatibleTokens",["t","T"]),i}return L(t,[{key:"parse",value:function(o,n){var a=function(l){return Math.floor(l*Math.pow(10,-n.length+3))};return se(ne(n.length,o),a)}},{key:"set",value:function(o,n,a){return o.setUTCMilliseconds(a),o}}]),t}(q),Tf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",10),g(w(i),"incompatibleTokens",["t","T","x"]),i}return L(t,[{key:"parse",value:function(o,n){switch(n){case"X":return Ve($e.basicOptionalMinutes,o);case"XX":return Ve($e.basic,o);case"XXXX":return Ve($e.basicOptionalSeconds,o);case"XXXXX":return Ve($e.extendedOptionalSeconds,o);case"XXX":default:return Ve($e.extended,o)}}},{key:"set",value:function(o,n,a){return n.timestampIsSet?o:new Date(o.getTime()-a)}}]),t}(q),Pf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",10),g(w(i),"incompatibleTokens",["t","T","X"]),i}return L(t,[{key:"parse",value:function(o,n){switch(n){case"x":return Ve($e.basicOptionalMinutes,o);case"xx":return Ve($e.basic,o);case"xxxx":return Ve($e.basicOptionalSeconds,o);case"xxxxx":return Ve($e.extendedOptionalSeconds,o);case"xxx":default:return Ve($e.extended,o)}}},{key:"set",value:function(o,n,a){return n.timestampIsSet?o:new Date(o.getTime()-a)}}]),t}(q),Af=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",40),g(w(i),"incompatibleTokens","*"),i}return L(t,[{key:"parse",value:function(o){return ad(o)}},{key:"set",value:function(o,n,a){return[new Date(a*1e3),{timestampIsSet:!0}]}}]),t}(q),kf=function(r){F(t,r);var e=$(t);function t(){var i;B(this,t);for(var o=arguments.length,n=new Array(o),a=0;a<o;a++)n[a]=arguments[a];return i=e.call.apply(e,[this].concat(n)),g(w(i),"priority",20),g(w(i),"incompatibleTokens","*"),i}return L(t,[{key:"parse",value:function(o){return ad(o)}},{key:"set",value:function(o,n,a){return[new Date(a),{timestampIsSet:!0}]}}]),t}(q),If={G:new qm,y:new Ym,Y:new Gm,R:new Xm,u:new Km,Q:new Qm,q:new Jm,M:new Zm,L:new ef,w:new rf,I:new nf,d:new lf,D:new df,E:new uf,e:new cf,c:new hf,i:new mf,a:new ff,b:new _f,B:new vf,h:new gf,H:new bf,K:new yf,k:new wf,m:new xf,s:new Cf,S:new Ef,X:new Tf,x:new Pf,t:new Af,T:new kf},Sf=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Df=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Of=/^'([^]*?)'?$/,Nf=/''/g,Mf=/\S/,Bf=/[a-zA-Z]/;function Ka(r,e,t,i){var o,n,a,s,l,d,u,c,h,p,m,f,y,E;ee(3,arguments);var C=String(r),T=String(e),N=rr(),U=(o=(n=void 0)!==null&&n!==void 0?n:N.locale)!==null&&o!==void 0?o:rd;if(!U.match)throw new RangeError("locale must contain match property");var W=be((a=(s=(l=(d=void 0)!==null&&d!==void 0?d:void 0)!==null&&l!==void 0?l:N.firstWeekContainsDate)!==null&&s!==void 0?s:(u=N.locale)===null||u===void 0||(c=u.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!(W>=1&&W<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var me=be((h=(p=(m=(f=void 0)!==null&&f!==void 0?f:void 0)!==null&&m!==void 0?m:N.weekStartsOn)!==null&&p!==void 0?p:(y=N.locale)===null||y===void 0||(E=y.options)===null||E===void 0?void 0:E.weekStartsOn)!==null&&h!==void 0?h:0);if(!(me>=0&&me<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(T==="")return C===""?ce(t):new Date(NaN);var Y={firstWeekContainsDate:W,weekStartsOn:me,locale:U},O=[new jm],I=T.match(Df).map(function(J){var j=J[0];if(j in Ko){var ye=Ko[j];return ye(J,U.formatLong)}return J}).join("").match(Sf),S=[],A=Xa(I),de;try{var Je=function(){var j=de.value;!(i!=null&&i.useAdditionalWeekYearTokens)&&td(j)&&Ti(j,T,r),!(i!=null&&i.useAdditionalDayOfYearTokens)&&ed(j)&&Ti(j,T,r);var ye=j[0],ut=If[ye];if(ut){var ei=ut.incompatibleTokens;if(Array.isArray(ei)){var ti=S.find(function(sr){return ei.includes(sr.token)||sr.token===ye});if(ti)throw new RangeError("The format string mustn't contain `".concat(ti.fullToken,"` and `").concat(j,"` at the same time"))}else if(ut.incompatibleTokens==="*"&&S.length>0)throw new RangeError("The format string mustn't contain `".concat(j,"` and any other token at the same time"));S.push({token:ye,fullToken:j});var Pt=ut.run(C,j,U.match,Y);if(!Pt)return{v:new Date(NaN)};O.push(Pt.setter),C=Pt.rest}else{if(ye.match(Bf))throw new RangeError("Format string contains an unescaped latin alphabet character `"+ye+"`");if(j==="''"?j="'":ye==="'"&&(j=Lf(j)),C.indexOf(j)===0)C=C.slice(j.length);else return{v:new Date(NaN)}}};for(A.s();!(de=A.n()).done;){var Te=Je();if(Ke(Te)==="object")return Te.v}}catch(J){A.e(J)}finally{A.f()}if(C.length>0&&Mf.test(C))return new Date(NaN);var Ze=O.map(function(J){return J.priority}).sort(function(J,j){return j-J}).filter(function(J,j,ye){return ye.indexOf(J)===j}).map(function(J){return O.filter(function(j){return j.priority===J}).sort(function(j,ye){return ye.subPriority-j.subPriority})}).map(function(J){return J[0]}),Me=ce(t);if(isNaN(Me.getTime()))return new Date(NaN);var ue=Xl(Me,Gl(Me)),K={},te=Xa(Ze),Zr;try{for(te.s();!(Zr=te.n()).done;){var ar=Zr.value;if(!ar.validate(ue,Y))return new Date(NaN);var dt=ar.set(ue,K,Y);Array.isArray(dt)?(ue=dt[0],Hm(K,dt[1])):ue=dt}}catch(J){te.e(J)}finally{te.f()}return ue}function Lf(r){return r.match(Of)[1].replace(Nf,"'")}function zf(r,e){ee(2,arguments);var t=be(e);return Mp(r,-t)}function Qa(r,e){kn(r,e)}function Hf(r){wt.set(r)}const Ja={en:{titleBonusesHistory:"Bonus History",dateFrom:"From:",dateTo:"To:",dateFilter:"Filter",noBonusHistory:"You have no bonuses for the selected period."},"zh-hk":{titleBonusesHistory:"獎金歷史",dateFrom:"從:",dateTo:"至:",dateFilter:"篩選",noBonusHistory:"您目前沒有獎金歷史。"},fr:{titleBonusesHistory:"Historique du bonus",dateFrom:"De:",dateTo:"A:",dateFilter:"Filtre",noBonusHistory:"Vous n'avez pas d'historique de bonus pour le moment."},ro:{titleBonusesHistory:"Istoric bonusuri",dateFrom:"De la",dateTo:"La",dateFilter:"Filtru",noBonusHistory:"Nu ai bonusuri pentru perioada selectata."},es:{titleBonusesHistory:"Historial de Bonos",dateFrom:"Desde:",dateTo:"A:",dateFilter:"Filtro",noBonusHistory:"No tiene Bonos para el periodo seleccionado."},pt:{titleBonusesHistory:"Histórico de bônus",dateFrom:"A partir de:",dateTo:"Para:",dateFilter:"Filtro:",noBonusHistory:"Você não tem histórico de bônus no momento."},hr:{titleBonusesHistory:"Povijest bonusa",dateFrom:"Od:",dateTo:"Do:",dateFilter:"Filter",noBonusHistory:"Nemate bonusa u povijesti."},"pt-br":{titleBonusesHistory:"Histórico de bônus",dateFrom:"De:",dateTo:"PARA:",dateFilter:"Filtro",noBonusHistory:"Não há bônus para o período selecionado"},"es-mx":{titleBonusesHistory:"Historial de bonos",dateFrom:"De:",dateTo:"A:",dateFilter:"Filtro",noBonusHistory:"No tiene bonus para el periodo seleccionado"},tr:{titleBonusesHistory:"Bonus Geçmişi",dateFrom:"İtibaren:",dateTo:"İle:",dateFilter:"Filtre",noBonusHistory:"Seçilen dönem için bonusunuz yok."},"en-us":{titleBonusesHistory:"Bonus History",dateFrom:"From:",dateTo:"To:",dateFilter:"Filter",noBonusHistory:"You have no bonuses for the selected period."}},Rf={GRANTED:"/v1/bonus/granted"},Za={TYPES:"standard,freeBet,freeRound,cashBack,stakeBack,oddsBoost,wagering",STATUS_ACTIVE:"active",STATUS_COMPLETED:"completed,released,forfeited,expired,closed"};function Ff(t){return pr(this,arguments,function*(r,e={}){const i=typeof r=="string"?r:r.toString(),o=yield fetch(i,e);let n=null;try{n=yield o.json()}catch(l){n=null}if(o.ok&&n)return n;const a=n&&typeof n=="object"?n:{},s={success:!1,errorMessage:typeof a.errorMessage=="string"&&a.errorMessage||o.statusText||String(o.status),errorCode:typeof a.errorCode=="number"?a.errorCode:void 0};return ct(ct({},a),s)})}function $f(r,e,t){return pr(this,null,function*(){const i=new URL(`${r}${Rf.GRANTED}`);Object.entries(t).forEach(([n,a])=>{a!=null&&i.searchParams.append(n,String(a))});const o={};return e&&(o["x-SessionId"]=e),Ff(i,{headers:o})})}if(typeof window!="undefined"){let r=function(e){return function(...t){try{return e.apply(this,t)}catch(i){if(i instanceof DOMException&&i.message.includes("has already been used with this registry")||i.message.includes("Cannot define multiple custom elements with the same tag name"))return!1;throw i}}};customElements.define=r(customElements.define),Promise.resolve().then(()=>require("./PlayerBonusCard-CxACrSzY.cjs")).then(({default:e})=>{!customElements.get("player-bonus-card")&&customElements.define("player-bonus-card",e.element)})}var Vf=Object.defineProperty,Uf=Object.defineProperties,Wf=Object.getOwnPropertyDescriptors,es=Object.getOwnPropertySymbols,jf=Object.prototype.hasOwnProperty,qf=Object.prototype.propertyIsEnumerable,Jo=(r,e,t)=>e in r?Vf(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,ki=(r,e)=>{for(var t in e||(e={}))jf.call(e,t)&&Jo(r,t,e[t]);if(es)for(var t of es(e))qf.call(e,t)&&Jo(r,t,e[t]);return r},dd=(r,e)=>Uf(r,Wf(e)),ve=(r,e,t)=>(Jo(r,typeof e!="symbol"?e+"":e,t),t),Ii=(r,e,t)=>new Promise((i,o)=>{var n=l=>{try{s(t.next(l))}catch(d){o(d)}},a=l=>{try{s(t.throw(l))}catch(d){o(d)}},s=l=>l.done?i(l.value):Promise.resolve(l.value).then(n,a);s((t=t.apply(r,e)).next())});/**
|
|
20
20
|
* @license
|
|
21
21
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
22
22
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
23
|
-
*/function
|
|
23
|
+
*/function k(r,e="24.5.10"){Object.defineProperty(r,"version",{get(){return e}});const t=customElements.get(r.is);if(!t)customElements.define(r.is,r);else{const i=t.version;i&&r.version&&i===r.version?console.warn(`The component ${r.is} has been loaded twice`):console.error(`Tried to define ${r.is} version ${r.version} when version ${t.version} is already in use. Something will probably break.`)}}/**
|
|
24
24
|
* @license
|
|
25
25
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
26
26
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
27
|
-
*/class
|
|
27
|
+
*/class Yf extends HTMLElement{static get is(){return"vaadin-lumo-styles"}}k(Yf);/**
|
|
28
28
|
* @license
|
|
29
29
|
* Copyright 2019 Google LLC
|
|
30
30
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
31
|
-
*/const gi=globalThis,Nn=gi.ShadowRoot&&(gi.ShadyCSS===void 0||gi.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Mn=Symbol(),ts=new WeakMap;let Bn=class{constructor(r,e,t){if(this._$cssResult$=!0,t!==Mn)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=r,this.t=e}get styleSheet(){let r=this.o;const e=this.t;if(Nn&&r===void 0){const t=e!==void 0&&e.length===1;t&&(r=ts.get(e)),r===void 0&&((this.o=r=new CSSStyleSheet).replaceSync(this.cssText),t&&ts.set(e,r))}return r}toString(){return this.cssText}};const
|
|
31
|
+
*/const gi=globalThis,Nn=gi.ShadowRoot&&(gi.ShadyCSS===void 0||gi.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Mn=Symbol(),ts=new WeakMap;let Bn=class{constructor(r,e,t){if(this._$cssResult$=!0,t!==Mn)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=r,this.t=e}get styleSheet(){let r=this.o;const e=this.t;if(Nn&&r===void 0){const t=e!==void 0&&e.length===1;t&&(r=ts.get(e)),r===void 0&&((this.o=r=new CSSStyleSheet).replaceSync(this.cssText),t&&ts.set(e,r))}return r}toString(){return this.cssText}};const Gf=r=>new Bn(typeof r=="string"?r:r+"",void 0,Mn),v=(r,...e)=>{const t=r.length===1?r[0]:e.reduce((i,o,n)=>i+(a=>{if(a._$cssResult$===!0)return a.cssText;if(typeof a=="number")return a;throw Error("Value passed to 'css' function must be a 'css' function result: "+a+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(o)+r[n+1],r[0]);return new Bn(t,r,Mn)},ud=(r,e)=>{if(Nn)r.adoptedStyleSheets=e.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const t of e){const i=document.createElement("style"),o=gi.litNonce;o!==void 0&&i.setAttribute("nonce",o),i.textContent=t.cssText,r.appendChild(i)}},rs=Nn?r=>r:r=>r instanceof CSSStyleSheet?(e=>{let t="";for(const i of e.cssRules)t+=i.cssText;return Gf(t)})(r):r;/**
|
|
32
32
|
* @license
|
|
33
33
|
* Copyright 2017 Google LLC
|
|
34
34
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
35
|
-
*/const{is:
|
|
35
|
+
*/const{is:Xf,defineProperty:Kf,getOwnPropertyDescriptor:Qf,getOwnPropertyNames:Jf,getOwnPropertySymbols:Zf,getPrototypeOf:e_}=Object,Xt=globalThis,is=Xt.trustedTypes,t_=is?is.emptyScript:"",os=Xt.reactiveElementPolyfillSupport,Pr=(r,e)=>r,Zo={toAttribute(r,e){switch(e){case Boolean:r=r?t_:null;break;case Object:case Array:r=r==null?r:JSON.stringify(r)}return r},fromAttribute(r,e){let t=r;switch(e){case Boolean:t=r!==null;break;case Number:t=r===null?null:Number(r);break;case Object:case Array:try{t=JSON.parse(r)}catch(i){t=null}}return t}},cd=(r,e)=>!Xf(r,e),ns={attribute:!0,type:String,converter:Zo,reflect:!1,useDefault:!1,hasChanged:cd};Symbol.metadata!=null||(Symbol.metadata=Symbol("metadata")),Xt.litPropertyMetadata!=null||(Xt.litPropertyMetadata=new WeakMap);let Lt=class extends HTMLElement{static addInitializer(r){var e;this._$Ei(),((e=this.l)!=null?e:this.l=[]).push(r)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(r,e=ns){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(r)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(r,e),!e.noAccessor){const t=Symbol(),i=this.getPropertyDescriptor(r,t,e);i!==void 0&&Kf(this.prototype,r,i)}}static getPropertyDescriptor(r,e,t){var i;const{get:o,set:n}=(i=Qf(this.prototype,r))!=null?i:{get(){return this[e]},set(a){this[e]=a}};return{get:o,set(a){const s=o==null?void 0:o.call(this);n==null||n.call(this,a),this.requestUpdate(r,s,t)},configurable:!0,enumerable:!0}}static getPropertyOptions(r){var e;return(e=this.elementProperties.get(r))!=null?e:ns}static _$Ei(){if(this.hasOwnProperty(Pr("elementProperties")))return;const r=e_(this);r.finalize(),r.l!==void 0&&(this.l=[...r.l]),this.elementProperties=new Map(r.elementProperties)}static finalize(){if(this.hasOwnProperty(Pr("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(Pr("properties"))){const e=this.properties,t=[...Jf(e),...Zf(e)];for(const i of t)this.createProperty(i,e[i])}const r=this[Symbol.metadata];if(r!==null){const e=litPropertyMetadata.get(r);if(e!==void 0)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[e,t]of this.elementProperties){const i=this._$Eu(e,t);i!==void 0&&this._$Eh.set(i,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(r){const e=[];if(Array.isArray(r)){const t=new Set(r.flat(1/0).reverse());for(const i of t)e.unshift(rs(i))}else r!==void 0&&e.push(rs(r));return e}static _$Eu(r,e){const t=e.attribute;return t===!1?void 0:typeof t=="string"?t:typeof r=="string"?r.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var r;this._$ES=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$E_(),this.requestUpdate(),(r=this.constructor.l)==null||r.forEach(e=>e(this))}addController(r){var e,t;((e=this._$EO)!=null?e:this._$EO=new Set).add(r),this.renderRoot!==void 0&&this.isConnected&&((t=r.hostConnected)==null||t.call(r))}removeController(r){var e;(e=this._$EO)==null||e.delete(r)}_$E_(){const r=new Map,e=this.constructor.elementProperties;for(const t of e.keys())this.hasOwnProperty(t)&&(r.set(t,this[t]),delete this[t]);r.size>0&&(this._$Ep=r)}createRenderRoot(){var r;const e=(r=this.shadowRoot)!=null?r:this.attachShadow(this.constructor.shadowRootOptions);return ud(e,this.constructor.elementStyles),e}connectedCallback(){var r;this.renderRoot!=null||(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(r=this._$EO)==null||r.forEach(e=>{var t;return(t=e.hostConnected)==null?void 0:t.call(e)})}enableUpdating(r){}disconnectedCallback(){var r;(r=this._$EO)==null||r.forEach(e=>{var t;return(t=e.hostDisconnected)==null?void 0:t.call(e)})}attributeChangedCallback(r,e,t){this._$AK(r,t)}_$ET(r,e){var t;const i=this.constructor.elementProperties.get(r),o=this.constructor._$Eu(r,i);if(o!==void 0&&i.reflect===!0){const n=(((t=i.converter)==null?void 0:t.toAttribute)!==void 0?i.converter:Zo).toAttribute(e,i.type);this._$Em=r,n==null?this.removeAttribute(o):this.setAttribute(o,n),this._$Em=null}}_$AK(r,e){var t,i,o;const n=this.constructor,a=n._$Eh.get(r);if(a!==void 0&&this._$Em!==a){const s=n.getPropertyOptions(a),l=typeof s.converter=="function"?{fromAttribute:s.converter}:((t=s.converter)==null?void 0:t.fromAttribute)!==void 0?s.converter:Zo;this._$Em=a;const d=l.fromAttribute(e,s.type);this[a]=(o=d!=null?d:(i=this._$Ej)==null?void 0:i.get(a))!=null?o:d,this._$Em=null}}requestUpdate(r,e,t,i=!1,o){var n,a;if(r!==void 0){const s=this.constructor;if(i===!1&&(o=this[r]),t!=null||(t=s.getPropertyOptions(r)),!(((n=t.hasChanged)!=null?n:cd)(o,e)||t.useDefault&&t.reflect&&o===((a=this._$Ej)==null?void 0:a.get(r))&&!this.hasAttribute(s._$Eu(r,t))))return;this.C(r,e,t)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(r,e,{useDefault:t,reflect:i,wrapped:o},n){var a,s,l;t&&!((a=this._$Ej)!=null?a:this._$Ej=new Map).has(r)&&(this._$Ej.set(r,(s=n!=null?n:e)!=null?s:this[r]),o!==!0||n!==void 0)||(this._$AL.has(r)||(this.hasUpdated||t||(e=void 0),this._$AL.set(r,e)),i===!0&&this._$Em!==r&&((l=this._$Eq)!=null?l:this._$Eq=new Set).add(r))}_$EP(){return Ii(this,null,function*(){this.isUpdatePending=!0;try{yield this._$ES}catch(e){Promise.reject(e)}const r=this.scheduleUpdate();return r!=null&&(yield r),!this.isUpdatePending})}scheduleUpdate(){return this.performUpdate()}performUpdate(){var r;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot!=null||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[o,n]of this._$Ep)this[o]=n;this._$Ep=void 0}const i=this.constructor.elementProperties;if(i.size>0)for(const[o,n]of i){const{wrapped:a}=n,s=this[o];a!==!0||this._$AL.has(o)||s===void 0||this.C(o,void 0,n,s)}}let e=!1;const t=this._$AL;try{e=this.shouldUpdate(t),e?(this.willUpdate(t),(r=this._$EO)==null||r.forEach(i=>{var o;return(o=i.hostUpdate)==null?void 0:o.call(i)}),this.update(t)):this._$EM()}catch(i){throw e=!1,this._$EM(),i}e&&this._$AE(t)}willUpdate(r){}_$AE(r){var e;(e=this._$EO)==null||e.forEach(t=>{var i;return(i=t.hostUpdated)==null?void 0:i.call(t)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(r)),this.updated(r)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(r){return!0}update(r){this._$Eq&&(this._$Eq=this._$Eq.forEach(e=>this._$ET(e,this[e]))),this._$EM()}updated(r){}firstUpdated(r){}};var as;Lt.elementStyles=[],Lt.shadowRootOptions={mode:"open"},Lt[Pr("elementProperties")]=new Map,Lt[Pr("finalized")]=new Map,os==null||os({ReactiveElement:Lt}),((as=Xt.reactiveElementVersions)!=null?as:Xt.reactiveElementVersions=[]).push("2.1.2");/**
|
|
36
36
|
* @license
|
|
37
37
|
* Copyright 2017 Google LLC
|
|
38
38
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
39
|
-
*/const Si=globalThis,ss=r=>r,Di=Si.trustedTypes,ls=Di?Di.createPolicy("lit-html",{createHTML:r=>r}):void 0,hd="$lit$",
|
|
40
|
-
\f\r]`,
|
|
41
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),cs=/'/g,hs=/"/g,md=/^(?:script|style|textarea|title)$/i,Kt=Symbol.for("lit-noChange"),pe=Symbol.for("lit-nothing"),ps=new WeakMap,
|
|
39
|
+
*/const Si=globalThis,ss=r=>r,Di=Si.trustedTypes,ls=Di?Di.createPolicy("lit-html",{createHTML:r=>r}):void 0,hd="$lit$",rt=`lit$${Math.random().toFixed(9).slice(2)}$`,pd="?"+rt,r_=`<${pd}>`,bt=document,Dr=()=>bt.createComment(""),Or=r=>r===null||typeof r!="object"&&typeof r!="function",Ln=Array.isArray,i_=r=>Ln(r)||typeof(r==null?void 0:r[Symbol.iterator])=="function",go=`[
|
|
40
|
+
\f\r]`,vr=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,ds=/-->/g,us=/>/g,ht=RegExp(`>|${go}(?:([^\\s"'>=/]+)(${go}*=${go}*(?:[^
|
|
41
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),cs=/'/g,hs=/"/g,md=/^(?:script|style|textarea|title)$/i,Kt=Symbol.for("lit-noChange"),pe=Symbol.for("lit-nothing"),ps=new WeakMap,ft=bt.createTreeWalker(bt,129);function fd(r,e){if(!Ln(r)||!r.hasOwnProperty("raw"))throw Error("invalid template strings array");return ls!==void 0?ls.createHTML(e):e}const o_=(r,e)=>{const t=r.length-1,i=[];let o,n=e===2?"<svg>":e===3?"<math>":"",a=vr;for(let s=0;s<t;s++){const l=r[s];let d,u,c=-1,h=0;for(;h<l.length&&(a.lastIndex=h,u=a.exec(l),u!==null);)h=a.lastIndex,a===vr?u[1]==="!--"?a=ds:u[1]!==void 0?a=us:u[2]!==void 0?(md.test(u[2])&&(o=RegExp("</"+u[2],"g")),a=ht):u[3]!==void 0&&(a=ht):a===ht?u[0]===">"?(a=o!=null?o:vr,c=-1):u[1]===void 0?c=-2:(c=a.lastIndex-u[2].length,d=u[1],a=u[3]===void 0?ht:u[3]==='"'?hs:cs):a===hs||a===cs?a=ht:a===ds||a===us?a=vr:(a=ht,o=void 0);const p=a===ht&&r[s+1].startsWith("/>")?" ":"";n+=a===vr?l+r_:c>=0?(i.push(d),l.slice(0,c)+hd+l.slice(c)+rt+p):l+rt+(c===-2?s:p)}return[fd(r,n+(r[t]||"<?>")+(e===2?"</svg>":e===3?"</math>":"")),i]};class Nr{constructor({strings:e,_$litType$:t},i){let o;this.parts=[];let n=0,a=0;const s=e.length-1,l=this.parts,[d,u]=o_(e,t);if(this.el=Nr.createElement(d,i),ft.currentNode=this.el.content,t===2||t===3){const c=this.el.content.firstChild;c.replaceWith(...c.childNodes)}for(;(o=ft.nextNode())!==null&&l.length<s;){if(o.nodeType===1){if(o.hasAttributes())for(const c of o.getAttributeNames())if(c.endsWith(hd)){const h=u[a++],p=o.getAttribute(c).split(rt),m=/([.?@])?(.*)/.exec(h);l.push({type:1,index:n,name:m[2],strings:p,ctor:m[1]==="."?a_:m[1]==="?"?s_:m[1]==="@"?l_:Yi}),o.removeAttribute(c)}else c.startsWith(rt)&&(l.push({type:6,index:n}),o.removeAttribute(c));if(md.test(o.tagName)){const c=o.textContent.split(rt),h=c.length-1;if(h>0){o.textContent=Di?Di.emptyScript:"";for(let p=0;p<h;p++)o.append(c[p],Dr()),ft.nextNode(),l.push({type:2,index:++n});o.append(c[h],Dr())}}}else if(o.nodeType===8)if(o.data===pd)l.push({type:2,index:n});else{let c=-1;for(;(c=o.data.indexOf(rt,c+1))!==-1;)l.push({type:7,index:n}),c+=rt.length-1}n++}}static createElement(e,t){const i=bt.createElement("template");return i.innerHTML=e,i}}function Qt(r,e,t=r,i){var o,n,a;if(e===Kt)return e;let s=i!==void 0?(o=t._$Co)==null?void 0:o[i]:t._$Cl;const l=Or(e)?void 0:e._$litDirective$;return(s==null?void 0:s.constructor)!==l&&((n=s==null?void 0:s._$AO)==null||n.call(s,!1),l===void 0?s=void 0:(s=new l(r),s._$AT(r,t,i)),i!==void 0?((a=t._$Co)!=null?a:t._$Co=[])[i]=s:t._$Cl=s),s!==void 0&&(e=Qt(r,s._$AS(r,e.values),s,i)),e}class n_{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){var t;const{el:{content:i},parts:o}=this._$AD,n=((t=e==null?void 0:e.creationScope)!=null?t:bt).importNode(i,!0);ft.currentNode=n;let a=ft.nextNode(),s=0,l=0,d=o[0];for(;d!==void 0;){if(s===d.index){let u;d.type===2?u=new jr(a,a.nextSibling,this,e):d.type===1?u=new d.ctor(a,d.name,d.strings,this,e):d.type===6&&(u=new d_(a,this,e)),this._$AV.push(u),d=o[++l]}s!==(d==null?void 0:d.index)&&(a=ft.nextNode(),s++)}return ft.currentNode=bt,n}p(e){let t=0;for(const i of this._$AV)i!==void 0&&(i.strings!==void 0?(i._$AI(e,i,t),t+=i.strings.length-2):i._$AI(e[t])),t++}}class jr{get _$AU(){var e,t;return(t=(e=this._$AM)==null?void 0:e._$AU)!=null?t:this._$Cv}constructor(e,t,i,o){var n;this.type=2,this._$AH=pe,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=i,this.options=o,this._$Cv=(n=o==null?void 0:o.isConnected)!=null?n:!0}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return t!==void 0&&(e==null?void 0:e.nodeType)===11&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=Qt(this,e,t),Or(e)?e===pe||e==null||e===""?(this._$AH!==pe&&this._$AR(),this._$AH=pe):e!==this._$AH&&e!==Kt&&this._(e):e._$litType$!==void 0?this.$(e):e.nodeType!==void 0?this.T(e):i_(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==pe&&Or(this._$AH)?this._$AA.nextSibling.data=e:this.T(bt.createTextNode(e)),this._$AH=e}$(e){var t;const{values:i,_$litType$:o}=e,n=typeof o=="number"?this._$AC(e):(o.el===void 0&&(o.el=Nr.createElement(fd(o.h,o.h[0]),this.options)),o);if(((t=this._$AH)==null?void 0:t._$AD)===n)this._$AH.p(i);else{const a=new n_(n,this),s=a.u(this.options);a.p(i),this.T(s),this._$AH=a}}_$AC(e){let t=ps.get(e.strings);return t===void 0&&ps.set(e.strings,t=new Nr(e)),t}k(e){Ln(this._$AH)||(this._$AH=[],this._$AR());const t=this._$AH;let i,o=0;for(const n of e)o===t.length?t.push(i=new jr(this.O(Dr()),this.O(Dr()),this,this.options)):i=t[o],i._$AI(n),o++;o<t.length&&(this._$AR(i&&i._$AB.nextSibling,o),t.length=o)}_$AR(e=this._$AA.nextSibling,t){var i;for((i=this._$AP)==null?void 0:i.call(this,!1,!0,t);e!==this._$AB;){const o=ss(e).nextSibling;ss(e).remove(),e=o}}setConnected(e){var t;this._$AM===void 0&&(this._$Cv=e,(t=this._$AP)==null||t.call(this,e))}}class Yi{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,i,o,n){this.type=1,this._$AH=pe,this._$AN=void 0,this.element=e,this.name=t,this._$AM=o,this.options=n,i.length>2||i[0]!==""||i[1]!==""?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=pe}_$AI(e,t=this,i,o){const n=this.strings;let a=!1;if(n===void 0)e=Qt(this,e,t,0),a=!Or(e)||e!==this._$AH&&e!==Kt,a&&(this._$AH=e);else{const s=e;let l,d;for(e=n[0],l=0;l<n.length-1;l++)d=Qt(this,s[i+l],t,l),d===Kt&&(d=this._$AH[l]),a||(a=!Or(d)||d!==this._$AH[l]),d===pe?e=pe:e!==pe&&(e+=(d!=null?d:"")+n[l+1]),this._$AH[l]=d}a&&!o&&this.j(e)}j(e){e===pe?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,e!=null?e:"")}}class a_ extends Yi{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===pe?void 0:e}}class s_ extends Yi{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==pe)}}class l_ extends Yi{constructor(e,t,i,o,n){super(e,t,i,o,n),this.type=5}_$AI(e,t=this){var i;if((e=(i=Qt(this,e,t,0))!=null?i:pe)===Kt)return;const o=this._$AH,n=e===pe&&o!==pe||e.capture!==o.capture||e.once!==o.once||e.passive!==o.passive,a=e!==pe&&(o===pe||n);n&&this.element.removeEventListener(this.name,this,o),a&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t,i;typeof this._$AH=="function"?this._$AH.call((i=(t=this.options)==null?void 0:t.host)!=null?i:this.element,e):this._$AH.handleEvent(e)}}class d_{constructor(e,t,i){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(e){Qt(this,e)}}const ms=Si.litHtmlPolyfillSupport;var fs;ms==null||ms(Nr,jr),((fs=Si.litHtmlVersions)!=null?fs:Si.litHtmlVersions=[]).push("3.3.3");const _d=(r,e,t)=>{var i,o;const n=(i=t==null?void 0:t.renderBefore)!=null?i:e;let a=n._$litPart$;if(a===void 0){const s=(o=t==null?void 0:t.renderBefore)!=null?o:null;n._$litPart$=a=new jr(e.insertBefore(Dr(),s),s,void 0,t!=null?t:{})}return a._$AI(r),a};/**
|
|
42
42
|
* @license
|
|
43
43
|
* Copyright 2017 Google LLC
|
|
44
44
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
45
|
-
*/const
|
|
45
|
+
*/const Mr=globalThis;class Rt extends Lt{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var e;const t=super.createRenderRoot();return(e=this.renderOptions).renderBefore!=null||(e.renderBefore=t.firstChild),t}update(e){const t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=_d(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),(e=this._$Do)==null||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._$Do)==null||e.setConnected(!1)}render(){return Kt}}var _s;Rt._$litElement$=!0,Rt.finalized=!0,(_s=Mr.litElementHydrateSupport)==null||_s.call(Mr,{LitElement:Rt});const vs=Mr.litElementPolyfillSupport;vs==null||vs({LitElement:Rt});var gs;((gs=Mr.litElementVersions)!=null?gs:Mr.litElementVersions=[]).push("4.2.2");/**
|
|
46
46
|
* @license
|
|
47
47
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
48
48
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -50,17 +50,17 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
50
50
|
* @license
|
|
51
51
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
52
52
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
53
|
-
*/const vd=[],en=new Set,zn=new Set;function gd(r){return r&&Object.prototype.hasOwnProperty.call(r,"__themes")}function
|
|
54
|
-
`)}const Oi="vaadin-themable-mixin-style";function
|
|
53
|
+
*/const vd=[],en=new Set,zn=new Set;function gd(r){return r&&Object.prototype.hasOwnProperty.call(r,"__themes")}function u_(r){return gd(customElements.get(r))}function c_(r=[]){return[r].flat(1/0).filter(e=>e instanceof Bn?!0:(console.warn("An item in styles is not of type CSSResult. Use `unsafeCSS` or `css`."),!1))}function bd(r,e){return(r||"").split(" ").some(t=>new RegExp(`^${t.split("*").join(".*")}$`,"u").test(e))}function yd(r){return r.map(e=>e.cssText).join(`
|
|
54
|
+
`)}const Oi="vaadin-themable-mixin-style";function h_(r,e){const t=document.createElement("style");t.id=Oi,t.textContent=yd(r),e.content.appendChild(t)}function p_(r){if(!r.shadowRoot)return;const e=r.constructor;if(r instanceof Rt)[...r.shadowRoot.querySelectorAll("style")].forEach(t=>t.remove()),ud(r.shadowRoot,e.elementStyles);else{const t=r.shadowRoot.getElementById(Oi),i=e.prototype._template;t.textContent=i.content.getElementById(Oi).textContent}}function m_(r){en.forEach(e=>{const t=e.deref();t instanceof r?p_(t):t||en.delete(e)})}function wd(r){if(r.prototype instanceof Rt)r.elementStyles=r.finalizeStyles(r.styles);else{const e=r.prototype._template;e.content.getElementById(Oi).textContent=yd(r.getStylesForThis())}zn.forEach(e=>{const t=customElements.get(e);t!==r&&t.prototype instanceof r&&wd(t)})}function f_(r,e){const t=r.__themes;return!t||!e?!1:t.some(i=>i.styles.some(o=>e.some(n=>n.cssText===o.cssText)))}function x(r,e,t={}){e=c_(e),window.Vaadin&&window.Vaadin.styleModules?window.Vaadin.styleModules.registerStyles(r,e,t):vd.push({themeFor:r,styles:e,include:t.include,moduleId:t.moduleId}),r&&zn.forEach(i=>{if(bd(r,i)&&u_(i)){const o=customElements.get(i);f_(o,e)?console.warn(`Registering styles that already exist for ${i}`):(!window.Vaadin||!window.Vaadin.suppressPostFinalizeStylesWarning)&&console.warn(`The custom element definition for "${i}" was finalized before a style module was registered. Ideally, import component specific style modules before importing the corresponding custom element. This warning can be suppressed by setting "window.Vaadin.suppressPostFinalizeStylesWarning = true".`),wd(o),m_(o)}})}function tn(){return window.Vaadin&&window.Vaadin.styleModules?window.Vaadin.styleModules.getAllThemes():vd}function __(r=""){let e=0;return r.startsWith("lumo-")||r.startsWith("material-")?e=1:r.startsWith("vaadin-")&&(e=2),e}function xd(r){const e=[];return r.include&&[].concat(r.include).forEach(t=>{const i=tn().find(o=>o.moduleId===t);i?e.push(...xd(i),...i.styles):console.warn(`Included moduleId ${t} not found in style registry`)},r.styles),e}function v_(r){const e=`${r}-default-theme`,t=tn().filter(i=>i.moduleId!==e&&bd(i.themeFor,r)).map(i=>dd(ki({},i),{styles:[...xd(i),...i.styles],includePriority:__(i.moduleId)})).sort((i,o)=>o.includePriority-i.includePriority);return t.length>0?t:tn().filter(i=>i.moduleId===e)}const X=r=>class extends Gi(r){constructor(){super(),en.add(new WeakRef(this))}static finalize(){if(super.finalize(),this.is&&zn.add(this.is),this.elementStyles)return;const e=this.prototype._template;!e||gd(this)||h_(this.getStylesForThis(),e)}static finalizeStyles(e){const t=this.getStylesForThis();return e?[...[e].flat(1/0),...t]:t}static getStylesForThis(){const e=r.__themes||[],t=Object.getPrototypeOf(this.prototype),i=(t?t.constructor.__themes:[])||[];this.__themes=[...e,...i,...v_(this.is)];const o=this.__themes.flatMap(n=>n.styles);return o.filter((n,a)=>a===o.lastIndexOf(n))}};/**
|
|
55
55
|
* @license
|
|
56
56
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
57
57
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
58
|
-
*/const
|
|
59
|
-
`).replace(":host","html"),document.head.insertAdjacentElement("afterbegin",t)},ir=(r,...e)=>{
|
|
58
|
+
*/const g_=(r,...e)=>{const t=document.createElement("style");t.id=r,t.textContent=e.map(i=>i.toString()).join(`
|
|
59
|
+
`).replace(":host","html"),document.head.insertAdjacentElement("afterbegin",t)},ir=(r,...e)=>{g_(`lumo-${r}`,e)};/**
|
|
60
60
|
* @license
|
|
61
61
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
62
62
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
63
|
-
*/const
|
|
63
|
+
*/const b_=v`
|
|
64
64
|
:host {
|
|
65
65
|
/* Base (background) */
|
|
66
66
|
--lumo-base-color: #fff;
|
|
@@ -145,7 +145,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
145
145
|
--lumo-disabled-text-color: GrayText;
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
|
-
`;ir("color-props",
|
|
148
|
+
`;ir("color-props",b_);const y_=v`
|
|
149
149
|
[theme~='dark'] {
|
|
150
150
|
/* Base (background) */
|
|
151
151
|
--lumo-base-color: hsl(214, 35%, 21%);
|
|
@@ -263,11 +263,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
263
263
|
pre code {
|
|
264
264
|
background: transparent;
|
|
265
265
|
}
|
|
266
|
-
`;
|
|
266
|
+
`;x("",y_,{moduleId:"lumo-color"});/**
|
|
267
267
|
* @license
|
|
268
268
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
269
269
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
270
|
-
*/const
|
|
270
|
+
*/const w_=v`
|
|
271
271
|
@font-face {
|
|
272
272
|
font-family: 'lumo-icons';
|
|
273
273
|
src: url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABEgAAsAAAAAIjQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAQwAAAFZAIUuKY21hcAAAAYgAAAD4AAADrsCU8d5nbHlmAAACgAAAC2cAABeAWri7U2hlYWQAAA3oAAAAMAAAADZa/6SsaGhlYQAADhgAAAAdAAAAJAbpA35obXR4AAAOOAAAABAAAACspBAAAGxvY2EAAA5IAAAAWAAAAFh57oA4bWF4cAAADqAAAAAfAAAAIAFKAXBuYW1lAAAOwAAAATEAAAIuUUJZCHBvc3QAAA/0AAABKwAAAelm8SzVeJxjYGRgYOBiMGCwY2BycfMJYeDLSSzJY5BiYGGAAJA8MpsxJzM9kYEDxgPKsYBpDiBmg4gCACY7BUgAeJxjYGS+yDiBgZWBgamKaQ8DA0MPhGZ8wGDIyAQUZWBlZsAKAtJcUxgcXjG+0mIO+p/FEMUcxDANKMwIkgMABn8MLQB4nO3SWW6DMABF0UtwCEnIPM/zhLK8LqhfXRybSP14XUYtHV9hGYQwQBNIo3cUIPkhQeM7rib1ekqnXg981XuC1qvy84lzojleh3puxL0hPjGjRU473teloEefAUNGjJkwZcacBUtWrNmwZceeA0dOnLlw5cadB09elPGhGf+j0NTI/65KfXerT6JhqKnpRKtgOpuqaTrtKjPUlqHmhto21I7pL6i6hlqY3q7qGWrfUAeGOjTUkaGODXViqFNDnRnq3FAXhro01JWhrg11Y6hbQ90Z6t5QD4Z6NNSToZ4N9WKoV0O9GerdUB+G+jTUl6GWRvkL24BkEXictVh9bFvVFb/nxvbz+7Rf/N6zHcd2bCfP+Wic1Z9N0jpNHCD9SNqqoVBgbQoMjY+pjA4hNnWa2pV1rHSIif0DGkyT2k10Kmu1Cag6huj4ZpqYBHSqJsTEJgZCG3TaVBFv595nO3ZIv4RIrPPuvefe884599zzO/cRF8G/tgn6CFFImNgkR0ggX8wlspbhSSWSdrC5ozd30s2dw5afzvgtyz9/zG9t1hV4RtF1pXolowvtzc2z6L2aYUQM45jKH9WDTvd1LRDoDASYWhfTzTyvboXz6uZX4ARX5wrF39y+HM2+CJ8d0pkyqBIqoze3D12ez4DrFoYzxI8dWwMrDlZ2DMqQAR9AROsJU+2smlTPaTTco52BVxXa2a2+I8vvqd2dVHm1LoPeTn/AZPRYGthDYOeZjBjKoFsVGulR3lGU95SeCK44oHU7MhWUGUKZDT3oSUcG2GWuh+EDDfUYA/jhIhl0TOsJNYSEu7mQmi3UzfXwZKA4BsVsHLXQYGgJW95qEtpJ1VcW9HiTriZBlFEqxsDjA09yCNUoQxxwd7KWSTt2y3GTKifkqHRCoWZc3m11Wa/dKdFgXD4kSYfkeJBKd8KMz7J8dZn/cGRCcLGDnA2Ge3bKzcvlnTDNthFWLH7Xt80ua5FMjA4WKelWv5Xo16vHuYzpRbJhhdVlftuRK0VlR27D9lu5TF0DPBi60OrHNO0AfP/uRWvhn/U3LXICE+nh+3IHPUJ8JE6GyBjZQLbjGchlrSgYngF8zyrIF4NJD3atUcgWsWunGN/UHX5B5/yg7uF87Nqp4Gf52F3gH73DjEZNRoqCKAr9giQJp5rGJABpiVE2htNhW9R8nw0jqYjCYcY4LIjwYNScf4WN06IZnZCEqsI4cFaQbo4Z1TsZBx40YhXkHOecaYE5oY37IIQ+iJJ+UsDYSun5MuRSBRZRUUhlY2DqOGajOR6zrSU/5My6l2DnusH1GQgnw5BZP7iuYM/ahcfQ7Z8y51ddfutvuwNqWQ0cBYr8fj0U0vsHpwerVaB2sWhXT2NExi2r1KUE2tUuVMnkepVQrxTmpQrZTG4iu8he8iPyM3KcPE/+RP5KPoE2CEAKclCBzXATxkYOtUY/o961PWRqsj0chRrHFBbtrjP9/P0ven5pcbRdpL94vfsy33e5+izuwz3nFLFPVNayPZx/jdG1fOChflFRvYzsW6L18efgLrSWIgvcqnGJYi4skO4xREURjbDuxKke5v0T3Mrzkt2fi31uyZlLLrqIpEuXXsMlgw442Jb0GAxjS1DM20kBoCzHLXm/jEm0IltdcvU0fEW24jgiwwRjVd9u4NJHcIyoHJcwvyVqgqj5hqBJ1ZWSJryh9p56UWhX1XbhRbW2ZopuZWsQd5y8mEQ8M+C6xjRYxZbDKWf5AgY+Qq/l6wSPk16zDFjowYuu+wjx13mfkxbyDDxadYT/LijZyI0THB+6yfLaWsRcO82zo9mWTNtpO18qlorZoIVMwSN40tky5DOQ1MCIAe24mvlsuwIIxPb10+uXDQ4uWz/9m3rj+ql7p6bufZARuPVq5tXtsn6KwfP8Jy0TeWOyNhUJN6mhX5rkUTtUppQWEMNTqEdaCGKFYKJaQrCE4JtDLYOlNEKmO5kBTPGY2A0N2sY3+dVlo1N9ycBsIGtOjQ2p/tlZvzo0ur4v6cOh8NTospB7U/X40KahoU3bGIH97dnwmtHlYffVG3R1YOwKM2vNhrPhCT5zk64sG53oS4b31aYjqe/B7+kQiXBN+b6h21hNUPMq29B8CU4elINdygMPKF1B+WBTG7Z9ZshpN/xwEuuDQZR+nuoo4CDaAiiwXmLpmukMQyPf/JMclqgL1ixZQ/nnP2VbdUODFGt2fgBvL123rlLYu/6A9ckb7F3K0/CyBMEu6aQoPscroCcacVehvyQyCZAsizsWWBkoLC+WAiWnOksLKaeuQDzGuqSk42aiYTiJ4zf9afl17SrqaTO1f+XlZAfIuYcq7/IqYMaMrksOJ6vHkOCPDq943xcCnHqVD9pHFRpMqSPXrIua1WNs+tOz1U+ciTCDpPk+c4QYJIHnYhxP/kVPAq+ahFpVhPcHp8qyarhiF+HsBU9Hrl+UZa876fbKipL0KqB6OdUveErgtOI97fZ63ae9SvWU6k2w1JfwqnUbHsYcFCJFrC/W12zIMMirWYEHxMPs6LGYSdkSZ5TsNP9PCpwnWC3HKZ1lydNjWHC2Mn3l6vL0dHn1ldP3LTSrX+vKrBqv7KmMr8p0SR6P1NqF63or6XRlIyO90f7+kf7+myOhvt4tq7f09oUiTc2/dycGgqFQcCDRLYmi1NL7fk0CknVMxEg/cdfs/TnpJMNkgqwj17B8beVazSrVbU4lG67IZYOCnWrYy3yBR9cyWcChywos3LJBEdhhFoAdYjiw0rLGm0xU5OzoGm5/ZfmHjVZpNNg6SznzGKDdwv2cCtVn6Eaxo12cfxLprpVtTcZ6hVx6dow7Yq7e8LXO8PY9Jgjoze9yCtU5FNbegcKkQMdCbt9au/te4Ebe0jkc0ukUL32eYnTpNs20h0KpUOhZPYwVcfhZnfdqeCvDfXiuCbAoYWcXERPc/mDQD3/hdF+wK4i/xv3kYfprIpAuMkk2kW3kdtS0kBIKpZwp8KxmsCyfM1MFzAss9LBkDxRyThiaqTLwKYKJVTwmWTudMyz+yks09346MDh4m72yOxCKrt1XMlQ1qPVlTEVVQ1ofdK/sCWjtZu9qGwZ8YZ9PPWlo1IV3eW3+U0aXblP39zrt+JPf6UhEQ1rUjNBULN+utyuaDNW34kpAVuSOeMTyWbSNWnooFu+QFNWQ4d/Ox4IPWx41fP/fB/Rjeoz08ezPA9TysMtmnOXfGN7Ui3xIYLDALrlDLOP09qtJuY2OeL0+QZXdRnR1nxRVBF/SOyKKPpcrn9mWzH4rH9IidE+PTNU2182+hOgSItrE1slByS24vaLvJpxOqe4Pduf3HJkZ+jLqUz9rRzB7p8gKcgWZwV1L8JtUS5Z2JxZSOCuBoMTQihMzLbCPA0KqGMAljRQjONklW/wjnXKy8vxT/Elvm3/KiMUMOoV0/vnDYlhec0SMKtt3/kKMyOt33tj2bqxQLsTjSGLl+EAsNhCnTyRGktW55EgCn/A4PlnWn+Mg8bgZrWqHxTbPwMuyy1u5YeZF2SUM7JRhddwRgiRuxpmgJmxn9ZW7XpcF3ViX/ar6ptRpGJ0S9Adg4qhb9sI3vbL7qNJV/y4i07t5TZBiho1imFoMz3gED+CtjYUxvP4SOxov4bFoNPg5aR1e+G4UgDPoedJTpogyCJ7oYvRqoVS0MQAy+CoNEdTDUjok5ZHZL/WtjV7rFj3PKQE3iKp7ou+rIxN3b9LB1dGjeT4cvKo3FrnWpYpuaFd/h3dtV8UeKN1Y9hpR3dt4p0H/zKuPQq0kZQUIIpuDfoiETsnIk+gCWMJZUXHtE8V9LkUc2TE8vOMbO4ax/MACabzyaGXc7u3FBr11ThBdB8SIeMAlCntG2KThHSPsaj2Dc9KNyY2a0KZ7ODaTHoRiFkeYz+shZBpCS4X6471KKKnuHd84edfk5F37d1XO5bbkcltu2ZLNbvnPXiUVAnVvprJrP+NObryjxrllS65md6Tm6wzFHRR4dY3QUUjb7MgxaIixU8hspi98fl/Xc+IB4iU66eCVL9YfAfahiSUt4TONS8x0D8W7u8vd3fGWx6OXlM/U1IoU/s61PGhpyXRFa3eReq2qG56lvmYtXavCC1iN7lbiBpWxXHU+cSlztVLVz0tVN600fVsLxaVDknhYioeoXP3t4lqV1r79MAw0GCI1FTL1YIGzPL1MMlJ9ZsN9P7lvA2yr9ZFUzwzPrVgxN/x/SS+chwB4nGNgZGBgAOLPrYdY4vltvjJwM78AijDUqG5oRND/XzNPZboF5HIwMIFEAU/lC+J4nGNgZGBgDvqfBSRfMAAB81QGRgZUoA0AVvYDbwAAAHicY2BgYGB+MTQwAM8EJo8AAAAAAE4AmgDoAQoBLAFOAXABmgHEAe4CGgKcAugEmgS8BNYE8gUOBSoFegXQBf4GRAZmBrYHGAeQCBgIUghqCP4JRgm+CdoKBAo+CoQKugr0C1QLmgvAeJxjYGRgYNBmTGEQZQABJiDmAkIGhv9gPgMAGJQBvAB4nG2RPU7DMBiG3/QP0UoIBGJh8QILavozdmRo9w7d09RpUzlx5LgVvQMn4BAcgoEzcAgOwVvzSZVQbcnf48fvFysJgGt8IcJxROiG9TgauODuj5ukG+EW+UG4jR4ehTv0Q+EunjER7uEWmk+IWpc0d3gVbuAKb8JN+nfhFvlDuI17fAp36L+Fu1jgR7iHp+jF7Arbz1Nb1nO93pnEncSJFtrVuS3VKB6e5EyX2iVer9TyoOr9eux9pjJnCzW1pdfGWFU5u9WpjzfeV5PBIBMfp7aAwQ4FLPrIkbKWqDHn+67pDRK4s4lzbsEux5qHvcIIMb/nueSMyTKkE3jWFdNLHLjW2PPmMa1Hxn3GjGW/wjT0HtOG09JU4WxLk9LH2ISuiv9twJn9y8fh9uIXI+BknAAAAHicbY7ZboMwEEW5CVBCSLrv+76kfJRjTwHFsdGAG+Xvy5JUfehIHp0rnxmNN/D6ir3/a4YBhvARIMQOIowQY4wEE0yxiz3s4wCHOMIxTnCKM5zjApe4wjVucIs73OMBj3jCM17wije84wMzfHqJ0EVmUkmmJo77oOmrHvfIRZbXsTCZplTZldlgb3TYGVHProwFs11t1A57tcON2rErR3PBqcwF1/6ctI6k0GSU4JHMSS6WghdJQ99sTbfuN7QLJ9vQ37dNrgyktnIxlDYLJNuqitpRbYWKFNuyDT6pog6oOYKHtKakeakqKjHXpPwlGRcsC+OqxLIiJpXqoqqDMreG2l5bv9Ri3TRX+c23DZna9WFFgmXuO6Ps1Jm/w6ErW8N3FbHn/QC444j0AA==)
|
|
@@ -320,11 +320,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
320
320
|
--lumo-icons-upload: '\\ea29';
|
|
321
321
|
--lumo-icons-user: '\\ea2a';
|
|
322
322
|
}
|
|
323
|
-
`;ir("font-icons",
|
|
323
|
+
`;ir("font-icons",w_);/**
|
|
324
324
|
* @license
|
|
325
325
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
326
326
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
327
|
-
*/const
|
|
327
|
+
*/const x_=v`
|
|
328
328
|
:host {
|
|
329
329
|
--lumo-size-xs: 1.625rem;
|
|
330
330
|
--lumo-size-s: 1.875rem;
|
|
@@ -339,11 +339,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
339
339
|
/* For backwards compatibility */
|
|
340
340
|
--lumo-icon-size: var(--lumo-icon-size-m);
|
|
341
341
|
}
|
|
342
|
-
`;ir("sizing-props",
|
|
342
|
+
`;ir("sizing-props",x_);/**
|
|
343
343
|
* @license
|
|
344
344
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
345
345
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
346
|
-
*/const
|
|
346
|
+
*/const C_=v`
|
|
347
347
|
:host {
|
|
348
348
|
/* Square */
|
|
349
349
|
--lumo-space-xs: 0.25rem;
|
|
@@ -366,11 +366,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
366
366
|
--lumo-space-tall-l: var(--lumo-space-l) calc(var(--lumo-space-l) / 2);
|
|
367
367
|
--lumo-space-tall-xl: var(--lumo-space-xl) calc(var(--lumo-space-xl) / 2);
|
|
368
368
|
}
|
|
369
|
-
`;ir("spacing-props",
|
|
369
|
+
`;ir("spacing-props",C_);/**
|
|
370
370
|
* @license
|
|
371
371
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
372
372
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
373
|
-
*/const
|
|
373
|
+
*/const E_=v`
|
|
374
374
|
:host {
|
|
375
375
|
/* Border radius */
|
|
376
376
|
--lumo-border-radius-s: 0.25em; /* Checkbox, badge, date-picker year indicator, etc */
|
|
@@ -470,11 +470,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
470
470
|
--vaadin-input-field-value-font-size: var(--lumo-font-size-m);
|
|
471
471
|
--vaadin-input-field-value-font-weight: 500;
|
|
472
472
|
}
|
|
473
|
-
`;ir("style-props",
|
|
473
|
+
`;ir("style-props",E_);/**
|
|
474
474
|
* @license
|
|
475
475
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
476
476
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
477
|
-
*/const
|
|
477
|
+
*/const T_=v`
|
|
478
478
|
:host {
|
|
479
479
|
/* prettier-ignore */
|
|
480
480
|
--lumo-font-family: -apple-system, BlinkMacSystemFont, 'Roboto', 'Segoe UI', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
|
|
@@ -494,7 +494,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
494
494
|
--lumo-line-height-s: 1.375;
|
|
495
495
|
--lumo-line-height-m: 1.625;
|
|
496
496
|
}
|
|
497
|
-
`,
|
|
497
|
+
`,P_=v`
|
|
498
498
|
body,
|
|
499
499
|
:host {
|
|
500
500
|
font-family: var(--lumo-font-family);
|
|
@@ -586,7 +586,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
586
586
|
border-left: none;
|
|
587
587
|
border-right: 2px solid var(--lumo-contrast-30pct);
|
|
588
588
|
}
|
|
589
|
-
`;
|
|
589
|
+
`;x("",P_,{moduleId:"lumo-typography"});ir("typography-props",T_);x("vaadin-checkbox",v`
|
|
590
590
|
:host {
|
|
591
591
|
color: var(--vaadin-checkbox-label-color, var(--lumo-body-text-color));
|
|
592
592
|
font-size: var(--vaadin-checkbox-label-font-size, var(--lumo-font-size-m));
|
|
@@ -906,7 +906,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
906
906
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
907
907
|
Code distributed by Google as part of the polymer project is also
|
|
908
908
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
909
|
-
*/let
|
|
909
|
+
*/let A_=/(url\()([^)]*)(\))/g,k_=/(^\/[^\/])|(^#)|(^[\w-\d]*:)/,ai,Ie;function Ar(r,e){if(r&&k_.test(r)||r==="//")return r;if(ai===void 0){ai=!1;try{const t=new URL("b","http://a");t.pathname="c%20d",ai=t.href==="http://a/c%20d"}catch(t){}}if(e||(e=document.baseURI||window.location.href),ai)try{return new URL(r,e).href}catch(t){return r}return Ie||(Ie=document.implementation.createHTMLDocument("temp"),Ie.base=Ie.createElement("base"),Ie.head.appendChild(Ie.base),Ie.anchor=Ie.createElement("a"),Ie.body.appendChild(Ie.anchor)),Ie.base.href=e,Ie.anchor.href=r,Ie.anchor.href||r}function Hn(r,e){return r.replace(A_,function(t,i,o,n){return i+"'"+Ar(o.replace(/["']/g,""),e)+"'"+n})}function Rn(r){return r.substring(0,r.lastIndexOf("/")+1)}/**
|
|
910
910
|
@license
|
|
911
911
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
912
912
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -914,7 +914,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
914
914
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
915
915
|
Code distributed by Google as part of the polymer project is also
|
|
916
916
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
917
|
-
*/const Cd=!window.ShadyDOM||!window.ShadyDOM.inUse;!window.ShadyCSS||window.ShadyCSS.nativeCss;const
|
|
917
|
+
*/const Cd=!window.ShadyDOM||!window.ShadyDOM.inUse;!window.ShadyCSS||window.ShadyCSS.nativeCss;const I_=Cd&&"adoptedStyleSheets"in Document.prototype&&"replaceSync"in CSSStyleSheet.prototype&&(()=>{try{const r=new CSSStyleSheet;r.replaceSync("");const e=document.createElement("div");return e.attachShadow({mode:"open"}),e.shadowRoot.adoptedStyleSheets=[r],e.shadowRoot.adoptedStyleSheets[0]===r}catch(r){return!1}})();let S_=window.Polymer&&window.Polymer.rootPath||Rn(document.baseURI||window.location.href),Ni=window.Polymer&&window.Polymer.sanitizeDOMValue||void 0;window.Polymer&&window.Polymer.setPassiveTouchGestures;let Mi=window.Polymer&&window.Polymer.strictTemplatePolicy||!1,D_=window.Polymer&&window.Polymer.allowTemplateFromDomModule||!1,Ed=window.Polymer&&window.Polymer.legacyOptimizations||!1,Td=window.Polymer&&window.Polymer.legacyWarnings||!1,O_=window.Polymer&&window.Polymer.syncInitialRender||!1,rn=window.Polymer&&window.Polymer.legacyUndefined||!1,N_=window.Polymer&&window.Polymer.orderedComputed||!1,bs=window.Polymer&&window.Polymer.removeNestedTemplates||!1,M_=window.Polymer&&window.Polymer.fastDomIf||!1,ys=window.Polymer&&window.Polymer.suppressTemplateNotifications||!1;window.Polymer&&window.Polymer.legacyNoObservedAttributes;let B_=window.Polymer&&window.Polymer.useAdoptedStyleSheetsWithBuiltCSS||!1;/**
|
|
918
918
|
@license
|
|
919
919
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
920
920
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -922,7 +922,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
922
922
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
923
923
|
Code distributed by Google as part of the polymer project is also
|
|
924
924
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
925
|
-
*/let
|
|
925
|
+
*/let L_=0;const le=function(r){let e=r.__mixinApplications;e||(e=new WeakMap,r.__mixinApplications=e);let t=L_++;function i(o){let n=o.__mixinSet;if(n&&n[t])return o;let a=e,s=a.get(o);if(!s){s=r(o),a.set(o,s);let l=Object.create(s.__mixinSet||n||null);l[t]=!0,s.__mixinSet=l}return s}return i};/**
|
|
926
926
|
@license
|
|
927
927
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
928
928
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -930,7 +930,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
930
930
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
931
931
|
Code distributed by Google as part of the polymer project is also
|
|
932
932
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
933
|
-
*/let Fn={},Pd={};function ws(r,e){Fn[r]=Pd[r.toLowerCase()]=e}function xs(r){return Fn[r]||Pd[r.toLowerCase()]}function
|
|
933
|
+
*/let Fn={},Pd={};function ws(r,e){Fn[r]=Pd[r.toLowerCase()]=e}function xs(r){return Fn[r]||Pd[r.toLowerCase()]}function z_(r){r.querySelector("style")&&console.warn("dom-module %s has style outside template",r.id)}class Br extends HTMLElement{static get observedAttributes(){return["id"]}static import(e,t){if(e){let i=xs(e);return i&&t?i.querySelector(t):i}return null}attributeChangedCallback(e,t,i,o){t!==i&&this.register()}get assetpath(){if(!this.__assetpath){const e=window.HTMLImports&&HTMLImports.importForElement?HTMLImports.importForElement(this)||document:this.ownerDocument,t=Ar(this.getAttribute("assetpath")||"",e.baseURI);this.__assetpath=Rn(t)}return this.__assetpath}register(e){if(e=e||this.id,e){if(Mi&&xs(e)!==void 0)throw ws(e,null),new Error(`strictTemplatePolicy: dom-module ${e} re-registered`);this.id=e,ws(e,this),z_(this)}}}Br.prototype.modules=Fn;customElements.define("dom-module",Br);/**
|
|
934
934
|
@license
|
|
935
935
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
936
936
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -938,7 +938,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
938
938
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
939
939
|
Code distributed by Google as part of the polymer project is also
|
|
940
940
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
941
|
-
*/const
|
|
941
|
+
*/const H_="link[rel=import][type~=css]",R_="include",Cs="shady-unscoped";function Ad(r){return Br.import(r)}function Es(r){let e=r.body?r.body:r;const t=Hn(e.textContent,r.baseURI),i=document.createElement("style");return i.textContent=t,i}function F_(r){const e=r.trim().split(/\s+/),t=[];for(let i=0;i<e.length;i++)t.push(...$_(e[i]));return t}function $_(r){const e=Ad(r);if(!e)return console.warn("Could not find style data in module named",r),[];if(e._styles===void 0){const t=[];t.push(...Id(e));const i=e.querySelector("template");i&&t.push(...kd(i,e.assetpath)),e._styles=t}return e._styles}function kd(r,e){if(!r._styles){const t=[],i=r.content.querySelectorAll("style");for(let o=0;o<i.length;o++){let n=i[o],a=n.getAttribute(R_);a&&t.push(...F_(a).filter(function(s,l,d){return d.indexOf(s)===l})),e&&(n.textContent=Hn(n.textContent,e)),t.push(n)}r._styles=t}return r._styles}function V_(r){let e=Ad(r);return e?Id(e):[]}function Id(r){const e=[],t=r.querySelectorAll(H_);for(let i=0;i<t.length;i++){let o=t[i];if(o.import){const n=o.import,a=o.hasAttribute(Cs);if(a&&!n._unscopedStyle){const s=Es(n);s.setAttribute(Cs,""),n._unscopedStyle=s}else n._style||(n._style=Es(n));e.push(a?n._unscopedStyle:n._style)}}return e}/**
|
|
942
942
|
@license
|
|
943
943
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
944
944
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -954,7 +954,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
954
954
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
955
955
|
Code distributed by Google as part of the polymer project is also
|
|
956
956
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
957
|
-
*/function on(r){return r.indexOf(".")>=0}function
|
|
957
|
+
*/function on(r){return r.indexOf(".")>=0}function xt(r){let e=r.indexOf(".");return e===-1?r:r.slice(0,e)}function Sd(r,e){return r.indexOf(e+".")===0}function Lr(r,e){return e.indexOf(r+".")===0}function zr(r,e,t){return e+t.slice(r.length)}function U_(r,e){return r===e||Sd(r,e)||Lr(r,e)}function xr(r){if(Array.isArray(r)){let e=[];for(let t=0;t<r.length;t++){let i=r[t].toString().split(".");for(let o=0;o<i.length;o++)e.push(i[o])}return e.join(".")}else return r}function Dd(r){return Array.isArray(r)?xr(r).split("."):r.toString().split(".")}function Pe(r,e,t){let i=r,o=Dd(e);for(let n=0;n<o.length;n++){if(!i)return;let a=o[n];i=i[a]}return t&&(t.path=o.join(".")),i}function Ts(r,e,t){let i=r,o=Dd(e),n=o[o.length-1];if(o.length>1){for(let a=0;a<o.length-1;a++){let s=o[a];if(i=i[s],!i)return}i[n]=t}else i[e]=t;return o.join(".")}/**
|
|
958
958
|
@license
|
|
959
959
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
960
960
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -962,7 +962,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
962
962
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
963
963
|
Code distributed by Google as part of the polymer project is also
|
|
964
964
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
965
|
-
*/const Bi={},
|
|
965
|
+
*/const Bi={},W_=/-[a-z]/g,j_=/([A-Z])/g;function Od(r){return Bi[r]||(Bi[r]=r.indexOf("-")<0?r:r.replace(W_,e=>e[1].toUpperCase()))}function Xi(r){return Bi[r]||(Bi[r]=r.replace(j_,"-$1").toLowerCase())}/**
|
|
966
966
|
@license
|
|
967
967
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
968
968
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -970,7 +970,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
970
970
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
971
971
|
Code distributed by Google as part of the polymer project is also
|
|
972
972
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
973
|
-
*/let
|
|
973
|
+
*/let q_=0,Nd=0,Ft=[],Y_=0,nn=!1,Md=document.createTextNode("");new window.MutationObserver(G_).observe(Md,{characterData:!0});function G_(){nn=!1;const r=Ft.length;for(let e=0;e<r;e++){let t=Ft[e];if(t)try{t()}catch(i){setTimeout(()=>{throw i})}}Ft.splice(0,r),Nd+=r}const X_={after(r){return{run(e){return window.setTimeout(e,r)},cancel(e){window.clearTimeout(e)}}},run(r,e){return window.setTimeout(r,e)},cancel(r){window.clearTimeout(r)}},Bd={run(r){return nn||(nn=!0,Md.textContent=Y_++),Ft.push(r),q_++},cancel(r){const e=r-Nd;if(e>=0){if(!Ft[e])throw new Error("invalid async handle: "+r);Ft[e]=null}}};/**
|
|
974
974
|
@license
|
|
975
975
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
976
976
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -978,7 +978,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
978
978
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
979
979
|
Code distributed by Google as part of the polymer project is also
|
|
980
980
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
981
|
-
*/const
|
|
981
|
+
*/const K_=Bd,Ld=le(r=>{class e extends r{static createProperties(i){const o=this.prototype;for(let n in i)n in o||o._createPropertyAccessor(n)}static attributeNameForProperty(i){return i.toLowerCase()}static typeForProperty(i){}_createPropertyAccessor(i,o){this._addPropertyToAttributeMap(i),this.hasOwnProperty(JSCompiler_renameProperty("__dataHasAccessor",this))||(this.__dataHasAccessor=Object.assign({},this.__dataHasAccessor)),this.__dataHasAccessor[i]||(this.__dataHasAccessor[i]=!0,this._definePropertyAccessor(i,o))}_addPropertyToAttributeMap(i){this.hasOwnProperty(JSCompiler_renameProperty("__dataAttributes",this))||(this.__dataAttributes=Object.assign({},this.__dataAttributes));let o=this.__dataAttributes[i];return o||(o=this.constructor.attributeNameForProperty(i),this.__dataAttributes[o]=i),o}_definePropertyAccessor(i,o){Object.defineProperty(this,i,{get(){return this.__data[i]},set:o?function(){}:function(n){this._setPendingProperty(i,n,!0)&&this._invalidateProperties()}})}constructor(){super(),this.__dataEnabled=!1,this.__dataReady=!1,this.__dataInvalid=!1,this.__data={},this.__dataPending=null,this.__dataOld=null,this.__dataInstanceProps=null,this.__dataCounter=0,this.__serializing=!1,this._initializeProperties()}ready(){this.__dataReady=!0,this._flushProperties()}_initializeProperties(){for(let i in this.__dataHasAccessor)this.hasOwnProperty(i)&&(this.__dataInstanceProps=this.__dataInstanceProps||{},this.__dataInstanceProps[i]=this[i],delete this[i])}_initializeInstanceProperties(i){Object.assign(this,i)}_setProperty(i,o){this._setPendingProperty(i,o)&&this._invalidateProperties()}_getProperty(i){return this.__data[i]}_setPendingProperty(i,o,n){let a=this.__data[i],s=this._shouldPropertyChange(i,o,a);return s&&(this.__dataPending||(this.__dataPending={},this.__dataOld={}),this.__dataOld&&!(i in this.__dataOld)&&(this.__dataOld[i]=a),this.__data[i]=o,this.__dataPending[i]=o),s}_isPropertyPending(i){return!!(this.__dataPending&&this.__dataPending.hasOwnProperty(i))}_invalidateProperties(){!this.__dataInvalid&&this.__dataReady&&(this.__dataInvalid=!0,K_.run(()=>{this.__dataInvalid&&(this.__dataInvalid=!1,this._flushProperties())}))}_enableProperties(){this.__dataEnabled||(this.__dataEnabled=!0,this.__dataInstanceProps&&(this._initializeInstanceProperties(this.__dataInstanceProps),this.__dataInstanceProps=null),this.ready())}_flushProperties(){this.__dataCounter++;const i=this.__data,o=this.__dataPending,n=this.__dataOld;this._shouldPropertiesChange(i,o,n)&&(this.__dataPending=null,this.__dataOld=null,this._propertiesChanged(i,o,n)),this.__dataCounter--}_shouldPropertiesChange(i,o,n){return!!o}_propertiesChanged(i,o,n){}_shouldPropertyChange(i,o,n){return n!==o&&(n===n||o===o)}attributeChangedCallback(i,o,n,a){o!==n&&this._attributeToProperty(i,n),super.attributeChangedCallback&&super.attributeChangedCallback(i,o,n,a)}_attributeToProperty(i,o,n){if(!this.__serializing){const a=this.__dataAttributes,s=a&&a[i]||i;this[s]=this._deserializeValue(o,n||this.constructor.typeForProperty(s))}}_propertyToAttribute(i,o,n){this.__serializing=!0,n=arguments.length<3?this[i]:n,this._valueToNodeAttribute(this,n,o||this.constructor.attributeNameForProperty(i)),this.__serializing=!1}_valueToNodeAttribute(i,o,n){const a=this._serializeValue(o);(n==="class"||n==="name"||n==="slot")&&(i=fe(i)),a===void 0?i.removeAttribute(n):i.setAttribute(n,a===""&&window.trustedTypes?window.trustedTypes.emptyScript:a)}_serializeValue(i){switch(typeof i){case"boolean":return i?"":void 0;default:return i!=null?i.toString():void 0}}_deserializeValue(i,o){switch(o){case Boolean:return i!==null;case Number:return Number(i);default:return i}}}return e});/**
|
|
982
982
|
@license
|
|
983
983
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
984
984
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -986,7 +986,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
986
986
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
987
987
|
Code distributed by Google as part of the polymer project is also
|
|
988
988
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
989
|
-
*/const zd={};let si=HTMLElement.prototype;for(;si;){let r=Object.getOwnPropertyNames(si);for(let e=0;e<r.length;e++)zd[r[e]]=!0;si=Object.getPrototypeOf(si)}const
|
|
989
|
+
*/const zd={};let si=HTMLElement.prototype;for(;si;){let r=Object.getOwnPropertyNames(si);for(let e=0;e<r.length;e++)zd[r[e]]=!0;si=Object.getPrototypeOf(si)}const Q_=window.trustedTypes?r=>trustedTypes.isHTML(r)||trustedTypes.isScript(r)||trustedTypes.isScriptURL(r):()=>!1;function J_(r,e){if(!zd[e]){let t=r[e];t!==void 0&&(r.__data?r._setPendingProperty(e,t):(r.__dataProto?r.hasOwnProperty(JSCompiler_renameProperty("__dataProto",r))||(r.__dataProto=Object.create(r.__dataProto)):r.__dataProto={},r.__dataProto[e]=t))}}const Z_=le(r=>{const e=Ld(r);class t extends e{static createPropertiesForAttributes(){let o=this.observedAttributes;for(let n=0;n<o.length;n++)this.prototype._createPropertyAccessor(Od(o[n]))}static attributeNameForProperty(o){return Xi(o)}_initializeProperties(){this.__dataProto&&(this._initializeProtoProperties(this.__dataProto),this.__dataProto=null),super._initializeProperties()}_initializeProtoProperties(o){for(let n in o)this._setProperty(n,o[n])}_ensureAttribute(o,n){const a=this;a.hasAttribute(o)||this._valueToNodeAttribute(a,n,o)}_serializeValue(o){switch(typeof o){case"object":if(o instanceof Date)return o.toString();if(o){if(Q_(o))return o;try{return JSON.stringify(o)}catch(n){return""}}default:return super._serializeValue(o)}}_deserializeValue(o,n){let a;switch(n){case Object:try{a=JSON.parse(o)}catch(s){a=o}break;case Array:try{a=JSON.parse(o)}catch(s){a=null,console.warn(`Polymer::Attributes: couldn't decode Array as JSON: ${o}`)}break;case Date:a=isNaN(o)?String(o):Number(o),a=new Date(a);break;default:a=super._deserializeValue(o,n);break}return a}_definePropertyAccessor(o,n){J_(this,o),super._definePropertyAccessor(o,n)}_hasAccessor(o){return this.__dataHasAccessor&&this.__dataHasAccessor[o]}_isPropertyPending(o){return!!(this.__dataPending&&o in this.__dataPending)}}return t});/**
|
|
990
990
|
@license
|
|
991
991
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
992
992
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -994,7 +994,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
994
994
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
995
995
|
Code distributed by Google as part of the polymer project is also
|
|
996
996
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
997
|
-
*/const
|
|
997
|
+
*/const ev={"dom-if":!0,"dom-repeat":!0};let Ps=!1,As=!1;function tv(){if(!Ps){Ps=!0;const r=document.createElement("textarea");r.placeholder="a",As=r.placeholder===r.textContent}return As}function rv(r){tv()&&r.localName==="textarea"&&r.placeholder&&r.placeholder===r.textContent&&(r.textContent=null)}const iv=(()=>{const r=window.trustedTypes&&window.trustedTypes.createPolicy("polymer-template-event-attribute-policy",{createScript:e=>e});return(e,t,i)=>{const o=t.getAttribute(i);if(r&&i.startsWith("on-")){e.setAttribute(i,r.createScript(o,i));return}e.setAttribute(i,o)}})();function ov(r){let e=r.getAttribute("is");if(e&&ev[e]){let t=r;for(t.removeAttribute("is"),r=t.ownerDocument.createElement(e),t.parentNode.replaceChild(r,t),r.appendChild(t);t.attributes.length;){const{name:i}=t.attributes[0];iv(r,t,i),t.removeAttribute(i)}}return r}function Hd(r,e){let t=e.parentInfo&&Hd(r,e.parentInfo);if(t){for(let i=t.firstChild,o=0;i;i=i.nextSibling)if(e.parentIndex===o++)return i}else return r}function nv(r,e,t,i){i.id&&(e[i.id]=t)}function av(r,e,t){if(t.events&&t.events.length)for(let i=0,o=t.events,n;i<o.length&&(n=o[i]);i++)r._addMethodEventListenerToNode(e,n.name,n.value,r)}function sv(r,e,t,i){t.templateInfo&&(e._templateInfo=t.templateInfo,e._parentTemplateInfo=i)}function lv(r,e,t){return r=r._methodHost||r,function(i){r[t]?r[t](i,i.detail):console.warn("listener method `"+t+"` not defined")}}const dv=le(r=>{class e extends r{static _parseTemplate(i,o){if(!i._templateInfo){let n=i._templateInfo={};n.nodeInfoList=[],n.nestedTemplate=!!o,n.stripWhiteSpace=o&&o.stripWhiteSpace||i.hasAttribute&&i.hasAttribute("strip-whitespace"),this._parseTemplateContent(i,n,{parent:null})}return i._templateInfo}static _parseTemplateContent(i,o,n){return this._parseTemplateNode(i.content,o,n)}static _parseTemplateNode(i,o,n){let a=!1,s=i;return s.localName=="template"&&!s.hasAttribute("preserve-content")?a=this._parseTemplateNestedTemplate(s,o,n)||a:s.localName==="slot"&&(o.hasInsertionPoint=!0),rv(s),s.firstChild&&this._parseTemplateChildNodes(s,o,n),s.hasAttributes&&s.hasAttributes()&&(a=this._parseTemplateNodeAttributes(s,o,n)||a),a||n.noted}static _parseTemplateChildNodes(i,o,n){if(!(i.localName==="script"||i.localName==="style"))for(let a=i.firstChild,s=0,l;a;a=l){if(a.localName=="template"&&(a=ov(a)),l=a.nextSibling,a.nodeType===Node.TEXT_NODE){let u=l;for(;u&&u.nodeType===Node.TEXT_NODE;)a.textContent+=u.textContent,l=u.nextSibling,i.removeChild(u),u=l;if(o.stripWhiteSpace&&!a.textContent.trim()){i.removeChild(a);continue}}let d={parentIndex:s,parentInfo:n};this._parseTemplateNode(a,o,d)&&(d.infoIndex=o.nodeInfoList.push(d)-1),a.parentNode&&s++}}static _parseTemplateNestedTemplate(i,o,n){let a=i,s=this._parseTemplate(a,o);return(s.content=a.content.ownerDocument.createDocumentFragment()).appendChild(a.content),n.templateInfo=s,!0}static _parseTemplateNodeAttributes(i,o,n){let a=!1,s=Array.from(i.attributes);for(let l=s.length-1,d;d=s[l];l--)a=this._parseTemplateNodeAttribute(i,o,n,d.name,d.value)||a;return a}static _parseTemplateNodeAttribute(i,o,n,a,s){return a.slice(0,3)==="on-"?(i.removeAttribute(a),n.events=n.events||[],n.events.push({name:a.slice(3),value:s}),!0):a==="id"?(n.id=s,!0):!1}static _contentForTemplate(i){let o=i._templateInfo;return o&&o.content||i.content}_stampTemplate(i,o){i&&!i.content&&window.HTMLTemplateElement&&HTMLTemplateElement.decorate&&HTMLTemplateElement.decorate(i),o=o||this.constructor._parseTemplate(i);let n=o.nodeInfoList,a=o.content||i.content,s=document.importNode(a,!0);s.__noInsertionPoint=!o.hasInsertionPoint;let l=s.nodeList=new Array(n.length);s.$={};for(let d=0,u=n.length,c;d<u&&(c=n[d]);d++){let h=l[d]=Hd(s,c);nv(this,s.$,h,c),sv(this,h,c,o),av(this,h,c)}return s=s,s}_addMethodEventListenerToNode(i,o,n,a){a=a||i;let s=lv(a,o,n);return this._addEventListenerToNode(i,o,s),s}_addEventListenerToNode(i,o,n){i.addEventListener(o,n)}_removeEventListenerFromNode(i,o,n){i.removeEventListener(o,n)}}return e});/**
|
|
998
998
|
* @fileoverview
|
|
999
999
|
* @suppress {checkPrototypalTypes}
|
|
1000
1000
|
* @license Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
@@ -1004,7 +1004,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1004
1004
|
* be found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by
|
|
1005
1005
|
* Google as part of the polymer project is also subject to an additional IP
|
|
1006
1006
|
* rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1007
|
-
*/let Rr=0;const Fr=[],V={COMPUTE:"__computeEffects",REFLECT:"__reflectEffects",NOTIFY:"__notifyEffects",PROPAGATE:"__propagateEffects",OBSERVE:"__observeEffects",READ_ONLY:"__readOnly"},Rd="__computeInfo",dv=/[A-Z]/;function bo(r,e,t){let i=r[e];if(!i)i=r[e]={};else if(!r.hasOwnProperty(e)&&(i=r[e]=Object.create(r[e]),t))for(let o in i){let n=i[o],a=i[o]=Array(n.length);for(let s=0;s<n.length;s++)a[s]=n[s]}return i}function Er(r,e,t,i,o,n){if(e){let a=!1;const s=Rr++;for(let l in t){let d=o?wt(l):l,u=e[d];if(u)for(let c=0,h=u.length,p;c<h&&(p=u[c]);c++)(!p.info||p.info.lastRun!==s)&&(!o||$n(l,p.trigger))&&(p.info&&(p.info.lastRun=s),p.fn(r,l,t,i,p.info,o,n),a=!0)}return a}return!1}function uv(r,e,t,i,o,n,a,s){let l=!1,d=a?wt(i):i,u=e[d];if(u)for(let c=0,h=u.length,p;c<h&&(p=u[c]);c++)(!p.info||p.info.lastRun!==t)&&(!a||$n(i,p.trigger))&&(p.info&&(p.info.lastRun=t),p.fn(r,i,o,n,p.info,a,s),l=!0);return l}function $n(r,e){if(e){let t=e.name;return t==r||!!(e.structured&&Sd(t,r))||!!(e.wildcard&&zr(t,r))}else return!0}function ks(r,e,t,i,o){let n=typeof o.method=="string"?r[o.method]:o.method,a=o.property;n?n.call(r,r.__data[a],i[a]):o.dynamicFn||console.warn("observer method `"+o.method+"` not defined")}function cv(r,e,t,i,o){let n=r[V.NOTIFY],a,s=Rr++;for(let d in e)e[d]&&(n&&uv(r,n,s,d,t,i,o)||o&&hv(r,d,t))&&(a=!0);let l;a&&(l=r.__dataHost)&&l._invalidateProperties&&l._invalidateProperties()}function hv(r,e,t){let i=wt(e);if(i!==e){let o=Xi(i)+"-changed";return Fd(r,o,t[e],e),!0}return!1}function Fd(r,e,t,i){let o={value:t,queueProperty:!0};i&&(o.path=i),fe(r).dispatchEvent(new CustomEvent(e,{detail:o}))}function pv(r,e,t,i,o,n){let a=(n?wt(e):e)!=e?e:null,s=a?Pe(r,a):r.__data[e];a&&s===void 0&&(s=t[e]),Fd(r,o.eventName,s,a)}function mv(r,e,t,i,o){let n,a=r.detail,s=a&&a.path;s?(i=Hr(t,i,s),n=a&&a.value):n=r.currentTarget[t],n=o?!n:n,(!e[V.READ_ONLY]||!e[V.READ_ONLY][i])&&e._setPendingPropertyOrPath(i,n,!0,!!s)&&(!a||!a.queueProperty)&&e._invalidateProperties()}function fv(r,e,t,i,o){let n=r.__data[e];Ni&&(n=Ni(n,o.attrName,"attribute",r)),r._propertyToAttribute(e,o.attrName,n)}function _v(r,e,t,i){let o=r[V.COMPUTE];if(o)if(O_){Rr++;const n=gv(r),a=[];for(let l in e)Is(l,o,a,n,i);let s;for(;s=a.shift();)$d(r,"",e,t,s)&&Is(s.methodInfo,o,a,n,i);Object.assign(t,r.__dataOld),Object.assign(e,r.__dataPending),r.__dataPending=null}else{let n=e;for(;Er(r,o,n,t,i);)Object.assign(t,r.__dataOld),Object.assign(e,r.__dataPending),n=r.__dataPending,r.__dataPending=null}}const vv=(r,e,t)=>{let i=0,o=e.length-1,n=-1;for(;i<=o;){const a=i+o>>1,s=t.get(e[a].methodInfo)-t.get(r.methodInfo);if(s<0)i=a+1;else if(s>0)o=a-1;else{n=a;break}}n<0&&(n=o+1),e.splice(n,0,r)},Is=(r,e,t,i,o)=>{const n=o?wt(r):r,a=e[n];if(a)for(let s=0;s<a.length;s++){const l=a[s];l.info.lastRun!==Rr&&(!o||$n(r,l.trigger))&&(l.info.lastRun=Rr,vv(l.info,t,i))}};function gv(r){let e=r.constructor.__orderedComputedDeps;if(!e){e=new Map;const t=r[V.COMPUTE];let{counts:i,ready:o,total:n}=bv(r),a;for(;a=o.shift();){e.set(a,e.size);const s=t[a];s&&s.forEach(l=>{const d=l.info.methodInfo;--n,--i[d]===0&&o.push(d)})}n!==0&&console.warn(`Computed graph for ${r.localName} incomplete; circular?`),r.constructor.__orderedComputedDeps=e}return e}function bv(r){const e=r[Rd],t={},i=r[V.COMPUTE],o=[];let n=0;for(let a in e){const s=e[a];n+=t[a]=s.args.filter(l=>!l.literal).length+(s.dynamicFn?1:0)}for(let a in i)e[a]||o.push(a);return{counts:t,ready:o,total:n}}function $d(r,e,t,i,o){let n=an(r,e,t,i,o);if(n===Fr)return!1;let a=o.methodInfo;return r.__dataHasAccessor&&r.__dataHasAccessor[a]?r._setPendingProperty(a,n,!0):(r[a]=n,!1)}function yv(r,e,t){let i=r.__dataLinkedPaths;if(i){let o;for(let n in i){let a=i[n];zr(n,e)?(o=Hr(n,a,e),r._setPendingPropertyOrPath(o,t,!0,!0)):zr(a,e)&&(o=Hr(a,n,e),r._setPendingPropertyOrPath(o,t,!0,!0))}}}function yo(r,e,t,i,o,n,a){t.bindings=t.bindings||[];let s={kind:i,target:o,parts:n,literal:a,isCompound:n.length!==1};if(t.bindings.push(s),Tv(s)){let{event:d,negate:u}=s.parts[0];s.listenerEvent=d||Xi(o)+"-changed",s.listenerNegate=u}let l=e.nodeInfoList.length;for(let d=0;d<s.parts.length;d++){let u=s.parts[d];u.compoundIndex=d,wv(r,e,s,u,l)}}function wv(r,e,t,i,o){if(!i.literal)if(t.kind==="attribute"&&t.target[0]==="-")console.warn("Cannot set attribute "+t.target+' because "-" is not a valid attribute starting character');else{let n=i.dependencies,a={index:o,binding:t,part:i,evaluator:r};for(let s=0;s<n.length;s++){let l=n[s];typeof l=="string"&&(l=Ud(l),l.wildcard=!0),r._addTemplatePropertyEffect(e,l.rootProperty,{fn:xv,info:a,trigger:l})}}}function xv(r,e,t,i,o,n,a){let s=a[o.index],l=o.binding,d=o.part;if(n&&d.source&&e.length>d.source.length&&l.kind=="property"&&!l.isCompound&&s.__isPropertyEffectsClient&&s.__dataHasAccessor&&s.__dataHasAccessor[l.target]){let u=t[e];e=Hr(d.source,l.target,e),s._setPendingPropertyOrPath(e,u,!1,!0)&&r._enqueueClient(s)}else{let u=o.evaluator._evaluateBinding(r,d,e,t,i,n);u!==Fr&&Cv(r,s,l,d,u)}}function Cv(r,e,t,i,o){if(o=Ev(e,o,t,i),Ni&&(o=Ni(o,t.target,t.kind,e)),t.kind=="attribute")r._valueToNodeAttribute(e,o,t.target);else{let n=t.target;e.__isPropertyEffectsClient&&e.__dataHasAccessor&&e.__dataHasAccessor[n]?(!e[V.READ_ONLY]||!e[V.READ_ONLY][n])&&e._setPendingProperty(n,o)&&r._enqueueClient(e):r._setUnmanagedPropertyToNode(e,n,o)}}function Ev(r,e,t,i){if(t.isCompound){let o=r.__dataCompoundStorage[t.target];o[i.compoundIndex]=e,e=o.join("")}return t.kind!=="attribute"&&(t.target==="textContent"||t.target==="value"&&(r.localName==="input"||r.localName==="textarea"))&&(e=e==null?"":e),e}function Tv(r){return!!r.target&&r.kind!="attribute"&&r.kind!="text"&&!r.isCompound&&r.parts[0].mode==="{"}function Pv(r,e){let{nodeList:t,nodeInfoList:i}=e;if(i.length)for(let o=0;o<i.length;o++){let n=i[o],a=t[o],s=n.bindings;if(s)for(let l=0;l<s.length;l++){let d=s[l];Av(a,d),kv(a,r,d)}a.__dataHost=r}}function Av(r,e){if(e.isCompound){let t=r.__dataCompoundStorage||(r.__dataCompoundStorage={}),i=e.parts,o=new Array(i.length);for(let a=0;a<i.length;a++)o[a]=i[a].literal;let n=e.target;t[n]=o,e.literal&&e.kind=="property"&&(n==="className"&&(r=fe(r)),r[n]=e.literal)}}function kv(r,e,t){if(t.listenerEvent){let i=t.parts[0];r.addEventListener(t.listenerEvent,function(o){mv(o,e,t.target,i.source,i.negate)})}}function Ss(r,e,t,i,o,n){n=e.static||n&&(typeof n!="object"||n[e.methodName]);let a={methodName:e.methodName,args:e.args,methodInfo:o,dynamicFn:n};for(let s=0,l;s<e.args.length&&(l=e.args[s]);s++)l.literal||r._addPropertyEffect(l.rootProperty,t,{fn:i,info:a,trigger:l});return n&&r._addPropertyEffect(e.methodName,t,{fn:i,info:a}),a}function an(r,e,t,i,o){let n=r._methodHost||r,a=n[o.methodName];if(a){let s=r._marshalArgs(o.args,e,t);return s===Fr?Fr:a.apply(n,s)}else o.dynamicFn||console.warn("method `"+o.methodName+"` not defined")}const Iv=[],Vd="(?:[a-zA-Z_$][\\w.:$\\-*]*)",Sv="(?:[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)",Dv="(?:'(?:[^'\\\\]|\\\\.)*')",Ov='(?:"(?:[^"\\\\]|\\\\.)*")',Nv="(?:"+Dv+"|"+Ov+")",Ds="(?:("+Vd+"|"+Sv+"|"+Nv+")\\s*)",Mv="(?:"+Ds+"(?:,\\s*"+Ds+")*)",Bv="(?:\\(\\s*(?:"+Mv+"?)\\)\\s*)",Lv="("+Vd+"\\s*"+Bv+"?)",zv="(\\[\\[|{{)\\s*",Hv="(?:]]|}})",Rv="(?:(!)\\s*)?",Fv=zv+Rv+Lv+Hv,Os=new RegExp(Fv,"g");function Ns(r){let e="";for(let t=0;t<r.length;t++){let i=r[t].literal;e+=i||""}return e}function wo(r){let e=r.match(/([^\s]+?)\(([\s\S]*)\)/);if(e){let t={methodName:e[1],static:!0,args:Iv};if(e[2].trim()){let i=e[2].replace(/\\,/g,",").split(",");return $v(i,t)}else return t}return null}function $v(r,e){return e.args=r.map(function(t){let i=Ud(t);return i.literal||(e.static=!1),i},this),e}function Ud(r){let e=r.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),t={name:e,value:"",literal:!1},i=e[0];switch(i==="-"&&(i=e[1]),i>="0"&&i<="9"&&(i="#"),i){case"'":case'"':t.value=e.slice(1,-1),t.literal=!0;break;case"#":t.value=Number(e),t.literal=!0;break}return t.literal||(t.rootProperty=wt(e),t.structured=on(e),t.structured&&(t.wildcard=e.slice(-2)==".*",t.wildcard&&(t.name=e.slice(0,-2)))),t}function Ms(r,e,t){let i=Pe(r,t);return i===void 0&&(i=e[t]),i}function Wd(r,e,t,i){const o={indexSplices:i};rn&&!r._overrideLegacyUndefined&&(e.splices=o),r.notifyPath(t+".splices",o),r.notifyPath(t+".length",e.length),rn&&!r._overrideLegacyUndefined&&(o.indexSplices=[])}function br(r,e,t,i,o,n){Wd(r,e,t,[{index:i,addedCount:o,removed:n,object:e,type:"splice"}])}function Vv(r){return r[0].toUpperCase()+r.substring(1)}const Vn=de(r=>{const e=lv(J_(r));class t extends e{constructor(){super(),this.__isPropertyEffectsClient=!0,this.__dataClientsReady,this.__dataPendingClients,this.__dataToNotify,this.__dataLinkedPaths,this.__dataHasPaths,this.__dataCompoundStorage,this.__dataHost,this.__dataTemp,this.__dataClientsInitialized,this.__data,this.__dataPending,this.__dataOld,this.__computeEffects,this.__computeInfo,this.__reflectEffects,this.__notifyEffects,this.__propagateEffects,this.__observeEffects,this.__readOnly,this.__templateInfo,this._overrideLegacyUndefined}get PROPERTY_EFFECT_TYPES(){return V}_initializeProperties(){super._initializeProperties(),this._registerHost(),this.__dataClientsReady=!1,this.__dataPendingClients=null,this.__dataToNotify=null,this.__dataLinkedPaths=null,this.__dataHasPaths=!1,this.__dataCompoundStorage=this.__dataCompoundStorage||null,this.__dataHost=this.__dataHost||null,this.__dataTemp={},this.__dataClientsInitialized=!1}_registerHost(){if(yr.length){let o=yr[yr.length-1];o._enqueueClient(this),this.__dataHost=o}}_initializeProtoProperties(o){this.__data=Object.create(o),this.__dataPending=Object.create(o),this.__dataOld={}}_initializeInstanceProperties(o){let n=this[V.READ_ONLY];for(let a in o)(!n||!n[a])&&(this.__dataPending=this.__dataPending||{},this.__dataOld=this.__dataOld||{},this.__data[a]=this.__dataPending[a]=o[a])}_addPropertyEffect(o,n,a){this._createPropertyAccessor(o,n==V.READ_ONLY);let s=bo(this,n,!0)[o];s||(s=this[n][o]=[]),s.push(a)}_removePropertyEffect(o,n,a){let s=bo(this,n,!0)[o],l=s.indexOf(a);l>=0&&s.splice(l,1)}_hasPropertyEffect(o,n){let a=this[n];return!!(a&&a[o])}_hasReadOnlyEffect(o){return this._hasPropertyEffect(o,V.READ_ONLY)}_hasNotifyEffect(o){return this._hasPropertyEffect(o,V.NOTIFY)}_hasReflectEffect(o){return this._hasPropertyEffect(o,V.REFLECT)}_hasComputedEffect(o){return this._hasPropertyEffect(o,V.COMPUTE)}_setPendingPropertyOrPath(o,n,a,s){if(s||wt(Array.isArray(o)?o[0]:o)!==o){if(!s){let l=Pe(this,o);if(o=Ts(this,o,n),!o||!super._shouldPropertyChange(o,n,l))return!1}if(this.__dataHasPaths=!0,this._setPendingProperty(o,n,a))return yv(this,o,n),!0}else{if(this.__dataHasAccessor&&this.__dataHasAccessor[o])return this._setPendingProperty(o,n,a);this[o]=n}return!1}_setUnmanagedPropertyToNode(o,n,a){(a!==o[n]||typeof a=="object")&&(n==="className"&&(o=fe(o)),o[n]=a)}_setPendingProperty(o,n,a){let s=this.__dataHasPaths&&on(o),l=s?this.__dataTemp:this.__data;return this._shouldPropertyChange(o,n,l[o])?(this.__dataPending||(this.__dataPending={},this.__dataOld={}),o in this.__dataOld||(this.__dataOld[o]=this.__data[o]),s?this.__dataTemp[o]=n:this.__data[o]=n,this.__dataPending[o]=n,(s||this[V.NOTIFY]&&this[V.NOTIFY][o])&&(this.__dataToNotify=this.__dataToNotify||{},this.__dataToNotify[o]=a),!0):!1}_setProperty(o,n){this._setPendingProperty(o,n,!0)&&this._invalidateProperties()}_invalidateProperties(){this.__dataReady&&this._flushProperties()}_enqueueClient(o){this.__dataPendingClients=this.__dataPendingClients||[],o!==this&&this.__dataPendingClients.push(o)}_flushClients(){this.__dataClientsReady?this.__enableOrFlushClients():(this.__dataClientsReady=!0,this._readyClients(),this.__dataReady=!0)}__enableOrFlushClients(){let o=this.__dataPendingClients;if(o){this.__dataPendingClients=null;for(let n=0;n<o.length;n++){let a=o[n];a.__dataEnabled?a.__dataPending&&a._flushProperties():a._enableProperties()}}}_readyClients(){this.__enableOrFlushClients()}setProperties(o,n){for(let a in o)(n||!this[V.READ_ONLY]||!this[V.READ_ONLY][a])&&this._setPendingPropertyOrPath(a,o[a],!0);this._invalidateProperties()}ready(){this._flushProperties(),this.__dataClientsReady||this._flushClients(),this.__dataPending&&this._flushProperties()}_propertiesChanged(o,n,a){let s=this.__dataHasPaths;this.__dataHasPaths=!1;let l;_v(this,n,a,s),l=this.__dataToNotify,this.__dataToNotify=null,this._propagatePropertyChanges(n,a,s),this._flushClients(),Er(this,this[V.REFLECT],n,a,s),Er(this,this[V.OBSERVE],n,a,s),l&&cv(this,l,n,a,s),this.__dataCounter==1&&(this.__dataTemp={})}_propagatePropertyChanges(o,n,a){this[V.PROPAGATE]&&Er(this,this[V.PROPAGATE],o,n,a),this.__templateInfo&&this._runEffectsForTemplate(this.__templateInfo,o,n,a)}_runEffectsForTemplate(o,n,a,s){const l=(d,u)=>{Er(this,o.propertyEffects,d,a,u,o.nodeList);for(let c=o.firstChild;c;c=c.nextSibling)this._runEffectsForTemplate(c,d,a,u)};o.runEffects?o.runEffects(l,n,s):l(n,s)}linkPaths(o,n){o=Cr(o),n=Cr(n),this.__dataLinkedPaths=this.__dataLinkedPaths||{},this.__dataLinkedPaths[o]=n}unlinkPaths(o){o=Cr(o),this.__dataLinkedPaths&&delete this.__dataLinkedPaths[o]}notifySplices(o,n){let a={path:""},s=Pe(this,o,a);Wd(this,s,a.path,n)}get(o,n){return Pe(n||this,o)}set(o,n,a){a?Ts(a,o,n):(!this[V.READ_ONLY]||!this[V.READ_ONLY][o])&&this._setPendingPropertyOrPath(o,n,!0)&&this._invalidateProperties()}push(o,...n){let a={path:""},s=Pe(this,o,a),l=s.length,d=s.push(...n);return n.length&&br(this,s,a.path,l,n.length,[]),d}pop(o){let n={path:""},a=Pe(this,o,n),s=!!a.length,l=a.pop();return s&&br(this,a,n.path,a.length,0,[l]),l}splice(o,n,a,...s){let l={path:""},d=Pe(this,o,l);n<0?n=d.length-Math.floor(-n):n&&(n=Math.floor(n));let u;return arguments.length===2?u=d.splice(n):u=d.splice(n,a,...s),(s.length||u.length)&&br(this,d,l.path,n,s.length,u),u}shift(o){let n={path:""},a=Pe(this,o,n),s=!!a.length,l=a.shift();return s&&br(this,a,n.path,0,0,[l]),l}unshift(o,...n){let a={path:""},s=Pe(this,o,a),l=s.unshift(...n);return n.length&&br(this,s,a.path,0,n.length,[]),l}notifyPath(o,n){let a;if(arguments.length==1){let s={path:""};n=Pe(this,o,s),a=s.path}else Array.isArray(o)?a=Cr(o):a=o;this._setPendingPropertyOrPath(a,n,!0,!0)&&this._invalidateProperties()}_createReadOnlyProperty(o,n){this._addPropertyEffect(o,V.READ_ONLY),n&&(this["_set"+Vv(o)]=function(a){this._setProperty(o,a)})}_createPropertyObserver(o,n,a){let s={property:o,method:n,dynamicFn:!!a};this._addPropertyEffect(o,V.OBSERVE,{fn:ks,info:s,trigger:{name:o}}),a&&this._addPropertyEffect(n,V.OBSERVE,{fn:ks,info:s,trigger:{name:n}})}_createMethodObserver(o,n){let a=wo(o);if(!a)throw new Error("Malformed observer expression '"+o+"'");Ss(this,a,V.OBSERVE,an,null,n)}_createNotifyingProperty(o){this._addPropertyEffect(o,V.NOTIFY,{fn:pv,info:{eventName:Xi(o)+"-changed",property:o}})}_createReflectedProperty(o){let n=this.constructor.attributeNameForProperty(o);n[0]==="-"?console.warn("Property "+o+" cannot be reflected to attribute "+n+' because "-" is not a valid starting attribute name. Use a lowercase first letter for the property instead.'):this._addPropertyEffect(o,V.REFLECT,{fn:fv,info:{attrName:n}})}_createComputedProperty(o,n,a){let s=wo(n);if(!s)throw new Error("Malformed computed expression '"+n+"'");const l=Ss(this,s,V.COMPUTE,$d,o,a);bo(this,Rd)[o]=l}_marshalArgs(o,n,a){const s=this.__data,l=[];for(let d=0,u=o.length;d<u;d++){let{name:c,structured:h,wildcard:p,value:m,literal:f}=o[d];if(!f)if(p){const y=zr(c,n),E=Ms(s,a,y?n:c);m={path:y?n:c,value:E,base:y?Pe(s,c):E}}else m=h?Ms(s,a,c):s[c];if(rn&&!this._overrideLegacyUndefined&&m===void 0&&o.length>1)return Fr;l[d]=m}return l}static addPropertyEffect(o,n,a){this.prototype._addPropertyEffect(o,n,a)}static createPropertyObserver(o,n,a){this.prototype._createPropertyObserver(o,n,a)}static createMethodObserver(o,n){this.prototype._createMethodObserver(o,n)}static createNotifyingProperty(o){this.prototype._createNotifyingProperty(o)}static createReadOnlyProperty(o,n){this.prototype._createReadOnlyProperty(o,n)}static createReflectedProperty(o){this.prototype._createReflectedProperty(o)}static createComputedProperty(o,n,a){this.prototype._createComputedProperty(o,n,a)}static bindTemplate(o){return this.prototype._bindTemplate(o)}_bindTemplate(o,n){let a=this.constructor._parseTemplate(o),s=this.__preBoundTemplateInfo==a;if(!s)for(let l in a.propertyEffects)this._createPropertyAccessor(l);if(n)if(a=Object.create(a),a.wasPreBound=s,!this.__templateInfo)this.__templateInfo=a;else{const l=o._parentTemplateInfo||this.__templateInfo,d=l.lastChild;a.parent=l,l.lastChild=a,a.previousSibling=d,d?d.nextSibling=a:l.firstChild=a}else this.__preBoundTemplateInfo=a;return a}static _addTemplatePropertyEffect(o,n,a){let s=o.hostProps=o.hostProps||{};s[n]=!0;let l=o.propertyEffects=o.propertyEffects||{};(l[n]=l[n]||[]).push(a)}_stampTemplate(o,n){n=n||this._bindTemplate(o,!0),yr.push(this);let a=super._stampTemplate(o,n);if(yr.pop(),n.nodeList=a.nodeList,!n.wasPreBound){let s=n.childNodes=[];for(let l=a.firstChild;l;l=l.nextSibling)s.push(l)}return a.templateInfo=n,Pv(this,n),this.__dataClientsReady&&(this._runEffectsForTemplate(n,this.__data,null,!1),this._flushClients()),a}_removeBoundDom(o){const n=o.templateInfo,{previousSibling:a,nextSibling:s,parent:l}=n;a?a.nextSibling=s:l&&(l.firstChild=s),s?s.previousSibling=a:l&&(l.lastChild=a),n.nextSibling=n.previousSibling=null;let d=n.childNodes;for(let u=0;u<d.length;u++){let c=d[u];fe(fe(c).parentNode).removeChild(c)}}static _parseTemplateNode(o,n,a){let s=e._parseTemplateNode.call(this,o,n,a);if(o.nodeType===Node.TEXT_NODE){let l=this._parseBindings(o.textContent,n);l&&(o.textContent=Ns(l)||" ",yo(this,n,a,"text","textContent",l),s=!0)}return s}static _parseTemplateNodeAttribute(o,n,a,s,l){let d=this._parseBindings(l,n);if(d){let u=s,c="property";dv.test(s)?c="attribute":s[s.length-1]=="$"&&(s=s.slice(0,-1),c="attribute");let h=Ns(d);return h&&c=="attribute"&&(s=="class"&&o.hasAttribute("class")&&(h+=" "+o.getAttribute(s)),o.setAttribute(s,h)),c=="attribute"&&u=="disable-upgrade$"&&o.setAttribute(s,""),o.localName==="input"&&u==="value"&&o.setAttribute(u,""),o.removeAttribute(u),c==="property"&&(s=Od(s)),yo(this,n,a,c,s,d,h),!0}else return e._parseTemplateNodeAttribute.call(this,o,n,a,s,l)}static _parseTemplateNestedTemplate(o,n,a){let s=e._parseTemplateNestedTemplate.call(this,o,n,a);const l=o.parentNode,d=a.templateInfo,u=l.localName==="dom-if",c=l.localName==="dom-repeat";bs&&(u||c)&&(l.removeChild(o),a=a.parentInfo,a.templateInfo=d,a.noted=!0,s=!1);let h=d.hostProps;if(N_&&u)h&&(n.hostProps=Object.assign(n.hostProps||{},h),bs||(a.parentInfo.noted=!0));else{let p="{";for(let m in h){let f=[{mode:p,source:m,dependencies:[m],hostProp:!0}];yo(this,n,a,"property","_host_"+m,f)}}return s}static _parseBindings(o,n){let a=[],s=0,l;for(;(l=Os.exec(o))!==null;){l.index>s&&a.push({literal:o.slice(s,l.index)});let d=l[1][0],u=!!l[2],c=l[3].trim(),h=!1,p="",m=-1;d=="{"&&(m=c.indexOf("::"))>0&&(p=c.substring(m+2),c=c.substring(0,m),h=!0);let f=wo(c),y=[];if(f){let{args:E,methodName:x}=f;for(let D=0;D<E.length;D++){let j=E[D];j.literal||y.push(j)}let A=n.dynamicFns;(A&&A[x]||f.static)&&(y.push(x),f.dynamicFn=!0)}else y.push(c);a.push({source:c,mode:d,negate:u,customEvent:h,signature:f,dependencies:y,event:p}),s=Os.lastIndex}if(s&&s<o.length){let d=o.substring(s);d&&a.push({literal:d})}return a.length?a:null}static _evaluateBinding(o,n,a,s,l,d){let u;return n.signature?u=an(o,a,s,l,n.signature):a!=n.source?u=Pe(o,n.source):d&&on(a)?u=Pe(o,a):u=o.__data[a],n.negate&&(u=!u),u}}return t}),yr=[];/**
|
|
1007
|
+
*/let Hr=0;const Rr=[],V={COMPUTE:"__computeEffects",REFLECT:"__reflectEffects",NOTIFY:"__notifyEffects",PROPAGATE:"__propagateEffects",OBSERVE:"__observeEffects",READ_ONLY:"__readOnly"},Rd="__computeInfo",uv=/[A-Z]/;function bo(r,e,t){let i=r[e];if(!i)i=r[e]={};else if(!r.hasOwnProperty(e)&&(i=r[e]=Object.create(r[e]),t))for(let o in i){let n=i[o],a=i[o]=Array(n.length);for(let s=0;s<n.length;s++)a[s]=n[s]}return i}function Cr(r,e,t,i,o,n){if(e){let a=!1;const s=Hr++;for(let l in t){let d=o?xt(l):l,u=e[d];if(u)for(let c=0,h=u.length,p;c<h&&(p=u[c]);c++)(!p.info||p.info.lastRun!==s)&&(!o||$n(l,p.trigger))&&(p.info&&(p.info.lastRun=s),p.fn(r,l,t,i,p.info,o,n),a=!0)}return a}return!1}function cv(r,e,t,i,o,n,a,s){let l=!1,d=a?xt(i):i,u=e[d];if(u)for(let c=0,h=u.length,p;c<h&&(p=u[c]);c++)(!p.info||p.info.lastRun!==t)&&(!a||$n(i,p.trigger))&&(p.info&&(p.info.lastRun=t),p.fn(r,i,o,n,p.info,a,s),l=!0);return l}function $n(r,e){if(e){let t=e.name;return t==r||!!(e.structured&&Sd(t,r))||!!(e.wildcard&&Lr(t,r))}else return!0}function ks(r,e,t,i,o){let n=typeof o.method=="string"?r[o.method]:o.method,a=o.property;n?n.call(r,r.__data[a],i[a]):o.dynamicFn||console.warn("observer method `"+o.method+"` not defined")}function hv(r,e,t,i,o){let n=r[V.NOTIFY],a,s=Hr++;for(let d in e)e[d]&&(n&&cv(r,n,s,d,t,i,o)||o&&pv(r,d,t))&&(a=!0);let l;a&&(l=r.__dataHost)&&l._invalidateProperties&&l._invalidateProperties()}function pv(r,e,t){let i=xt(e);if(i!==e){let o=Xi(i)+"-changed";return Fd(r,o,t[e],e),!0}return!1}function Fd(r,e,t,i){let o={value:t,queueProperty:!0};i&&(o.path=i),fe(r).dispatchEvent(new CustomEvent(e,{detail:o}))}function mv(r,e,t,i,o,n){let a=(n?xt(e):e)!=e?e:null,s=a?Pe(r,a):r.__data[e];a&&s===void 0&&(s=t[e]),Fd(r,o.eventName,s,a)}function fv(r,e,t,i,o){let n,a=r.detail,s=a&&a.path;s?(i=zr(t,i,s),n=a&&a.value):n=r.currentTarget[t],n=o?!n:n,(!e[V.READ_ONLY]||!e[V.READ_ONLY][i])&&e._setPendingPropertyOrPath(i,n,!0,!!s)&&(!a||!a.queueProperty)&&e._invalidateProperties()}function _v(r,e,t,i,o){let n=r.__data[e];Ni&&(n=Ni(n,o.attrName,"attribute",r)),r._propertyToAttribute(e,o.attrName,n)}function vv(r,e,t,i){let o=r[V.COMPUTE];if(o)if(N_){Hr++;const n=bv(r),a=[];for(let l in e)Is(l,o,a,n,i);let s;for(;s=a.shift();)$d(r,"",e,t,s)&&Is(s.methodInfo,o,a,n,i);Object.assign(t,r.__dataOld),Object.assign(e,r.__dataPending),r.__dataPending=null}else{let n=e;for(;Cr(r,o,n,t,i);)Object.assign(t,r.__dataOld),Object.assign(e,r.__dataPending),n=r.__dataPending,r.__dataPending=null}}const gv=(r,e,t)=>{let i=0,o=e.length-1,n=-1;for(;i<=o;){const a=i+o>>1,s=t.get(e[a].methodInfo)-t.get(r.methodInfo);if(s<0)i=a+1;else if(s>0)o=a-1;else{n=a;break}}n<0&&(n=o+1),e.splice(n,0,r)},Is=(r,e,t,i,o)=>{const n=o?xt(r):r,a=e[n];if(a)for(let s=0;s<a.length;s++){const l=a[s];l.info.lastRun!==Hr&&(!o||$n(r,l.trigger))&&(l.info.lastRun=Hr,gv(l.info,t,i))}};function bv(r){let e=r.constructor.__orderedComputedDeps;if(!e){e=new Map;const t=r[V.COMPUTE];let{counts:i,ready:o,total:n}=yv(r),a;for(;a=o.shift();){e.set(a,e.size);const s=t[a];s&&s.forEach(l=>{const d=l.info.methodInfo;--n,--i[d]===0&&o.push(d)})}n!==0&&console.warn(`Computed graph for ${r.localName} incomplete; circular?`),r.constructor.__orderedComputedDeps=e}return e}function yv(r){const e=r[Rd],t={},i=r[V.COMPUTE],o=[];let n=0;for(let a in e){const s=e[a];n+=t[a]=s.args.filter(l=>!l.literal).length+(s.dynamicFn?1:0)}for(let a in i)e[a]||o.push(a);return{counts:t,ready:o,total:n}}function $d(r,e,t,i,o){let n=an(r,e,t,i,o);if(n===Rr)return!1;let a=o.methodInfo;return r.__dataHasAccessor&&r.__dataHasAccessor[a]?r._setPendingProperty(a,n,!0):(r[a]=n,!1)}function wv(r,e,t){let i=r.__dataLinkedPaths;if(i){let o;for(let n in i){let a=i[n];Lr(n,e)?(o=zr(n,a,e),r._setPendingPropertyOrPath(o,t,!0,!0)):Lr(a,e)&&(o=zr(a,n,e),r._setPendingPropertyOrPath(o,t,!0,!0))}}}function yo(r,e,t,i,o,n,a){t.bindings=t.bindings||[];let s={kind:i,target:o,parts:n,literal:a,isCompound:n.length!==1};if(t.bindings.push(s),Pv(s)){let{event:d,negate:u}=s.parts[0];s.listenerEvent=d||Xi(o)+"-changed",s.listenerNegate=u}let l=e.nodeInfoList.length;for(let d=0;d<s.parts.length;d++){let u=s.parts[d];u.compoundIndex=d,xv(r,e,s,u,l)}}function xv(r,e,t,i,o){if(!i.literal)if(t.kind==="attribute"&&t.target[0]==="-")console.warn("Cannot set attribute "+t.target+' because "-" is not a valid attribute starting character');else{let n=i.dependencies,a={index:o,binding:t,part:i,evaluator:r};for(let s=0;s<n.length;s++){let l=n[s];typeof l=="string"&&(l=Ud(l),l.wildcard=!0),r._addTemplatePropertyEffect(e,l.rootProperty,{fn:Cv,info:a,trigger:l})}}}function Cv(r,e,t,i,o,n,a){let s=a[o.index],l=o.binding,d=o.part;if(n&&d.source&&e.length>d.source.length&&l.kind=="property"&&!l.isCompound&&s.__isPropertyEffectsClient&&s.__dataHasAccessor&&s.__dataHasAccessor[l.target]){let u=t[e];e=zr(d.source,l.target,e),s._setPendingPropertyOrPath(e,u,!1,!0)&&r._enqueueClient(s)}else{let u=o.evaluator._evaluateBinding(r,d,e,t,i,n);u!==Rr&&Ev(r,s,l,d,u)}}function Ev(r,e,t,i,o){if(o=Tv(e,o,t,i),Ni&&(o=Ni(o,t.target,t.kind,e)),t.kind=="attribute")r._valueToNodeAttribute(e,o,t.target);else{let n=t.target;e.__isPropertyEffectsClient&&e.__dataHasAccessor&&e.__dataHasAccessor[n]?(!e[V.READ_ONLY]||!e[V.READ_ONLY][n])&&e._setPendingProperty(n,o)&&r._enqueueClient(e):r._setUnmanagedPropertyToNode(e,n,o)}}function Tv(r,e,t,i){if(t.isCompound){let o=r.__dataCompoundStorage[t.target];o[i.compoundIndex]=e,e=o.join("")}return t.kind!=="attribute"&&(t.target==="textContent"||t.target==="value"&&(r.localName==="input"||r.localName==="textarea"))&&(e=e==null?"":e),e}function Pv(r){return!!r.target&&r.kind!="attribute"&&r.kind!="text"&&!r.isCompound&&r.parts[0].mode==="{"}function Av(r,e){let{nodeList:t,nodeInfoList:i}=e;if(i.length)for(let o=0;o<i.length;o++){let n=i[o],a=t[o],s=n.bindings;if(s)for(let l=0;l<s.length;l++){let d=s[l];kv(a,d),Iv(a,r,d)}a.__dataHost=r}}function kv(r,e){if(e.isCompound){let t=r.__dataCompoundStorage||(r.__dataCompoundStorage={}),i=e.parts,o=new Array(i.length);for(let a=0;a<i.length;a++)o[a]=i[a].literal;let n=e.target;t[n]=o,e.literal&&e.kind=="property"&&(n==="className"&&(r=fe(r)),r[n]=e.literal)}}function Iv(r,e,t){if(t.listenerEvent){let i=t.parts[0];r.addEventListener(t.listenerEvent,function(o){fv(o,e,t.target,i.source,i.negate)})}}function Ss(r,e,t,i,o,n){n=e.static||n&&(typeof n!="object"||n[e.methodName]);let a={methodName:e.methodName,args:e.args,methodInfo:o,dynamicFn:n};for(let s=0,l;s<e.args.length&&(l=e.args[s]);s++)l.literal||r._addPropertyEffect(l.rootProperty,t,{fn:i,info:a,trigger:l});return n&&r._addPropertyEffect(e.methodName,t,{fn:i,info:a}),a}function an(r,e,t,i,o){let n=r._methodHost||r,a=n[o.methodName];if(a){let s=r._marshalArgs(o.args,e,t);return s===Rr?Rr:a.apply(n,s)}else o.dynamicFn||console.warn("method `"+o.methodName+"` not defined")}const Sv=[],Vd="(?:[a-zA-Z_$][\\w.:$\\-*]*)",Dv="(?:[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)",Ov="(?:'(?:[^'\\\\]|\\\\.)*')",Nv='(?:"(?:[^"\\\\]|\\\\.)*")',Mv="(?:"+Ov+"|"+Nv+")",Ds="(?:("+Vd+"|"+Dv+"|"+Mv+")\\s*)",Bv="(?:"+Ds+"(?:,\\s*"+Ds+")*)",Lv="(?:\\(\\s*(?:"+Bv+"?)\\)\\s*)",zv="("+Vd+"\\s*"+Lv+"?)",Hv="(\\[\\[|{{)\\s*",Rv="(?:]]|}})",Fv="(?:(!)\\s*)?",$v=Hv+Fv+zv+Rv,Os=new RegExp($v,"g");function Ns(r){let e="";for(let t=0;t<r.length;t++){let i=r[t].literal;e+=i||""}return e}function wo(r){let e=r.match(/([^\s]+?)\(([\s\S]*)\)/);if(e){let t={methodName:e[1],static:!0,args:Sv};if(e[2].trim()){let i=e[2].replace(/\\,/g,",").split(",");return Vv(i,t)}else return t}return null}function Vv(r,e){return e.args=r.map(function(t){let i=Ud(t);return i.literal||(e.static=!1),i},this),e}function Ud(r){let e=r.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),t={name:e,value:"",literal:!1},i=e[0];switch(i==="-"&&(i=e[1]),i>="0"&&i<="9"&&(i="#"),i){case"'":case'"':t.value=e.slice(1,-1),t.literal=!0;break;case"#":t.value=Number(e),t.literal=!0;break}return t.literal||(t.rootProperty=xt(e),t.structured=on(e),t.structured&&(t.wildcard=e.slice(-2)==".*",t.wildcard&&(t.name=e.slice(0,-2)))),t}function Ms(r,e,t){let i=Pe(r,t);return i===void 0&&(i=e[t]),i}function Wd(r,e,t,i){const o={indexSplices:i};rn&&!r._overrideLegacyUndefined&&(e.splices=o),r.notifyPath(t+".splices",o),r.notifyPath(t+".length",e.length),rn&&!r._overrideLegacyUndefined&&(o.indexSplices=[])}function gr(r,e,t,i,o,n){Wd(r,e,t,[{index:i,addedCount:o,removed:n,object:e,type:"splice"}])}function Uv(r){return r[0].toUpperCase()+r.substring(1)}const Vn=le(r=>{const e=dv(Z_(r));class t extends e{constructor(){super(),this.__isPropertyEffectsClient=!0,this.__dataClientsReady,this.__dataPendingClients,this.__dataToNotify,this.__dataLinkedPaths,this.__dataHasPaths,this.__dataCompoundStorage,this.__dataHost,this.__dataTemp,this.__dataClientsInitialized,this.__data,this.__dataPending,this.__dataOld,this.__computeEffects,this.__computeInfo,this.__reflectEffects,this.__notifyEffects,this.__propagateEffects,this.__observeEffects,this.__readOnly,this.__templateInfo,this._overrideLegacyUndefined}get PROPERTY_EFFECT_TYPES(){return V}_initializeProperties(){super._initializeProperties(),this._registerHost(),this.__dataClientsReady=!1,this.__dataPendingClients=null,this.__dataToNotify=null,this.__dataLinkedPaths=null,this.__dataHasPaths=!1,this.__dataCompoundStorage=this.__dataCompoundStorage||null,this.__dataHost=this.__dataHost||null,this.__dataTemp={},this.__dataClientsInitialized=!1}_registerHost(){if(br.length){let o=br[br.length-1];o._enqueueClient(this),this.__dataHost=o}}_initializeProtoProperties(o){this.__data=Object.create(o),this.__dataPending=Object.create(o),this.__dataOld={}}_initializeInstanceProperties(o){let n=this[V.READ_ONLY];for(let a in o)(!n||!n[a])&&(this.__dataPending=this.__dataPending||{},this.__dataOld=this.__dataOld||{},this.__data[a]=this.__dataPending[a]=o[a])}_addPropertyEffect(o,n,a){this._createPropertyAccessor(o,n==V.READ_ONLY);let s=bo(this,n,!0)[o];s||(s=this[n][o]=[]),s.push(a)}_removePropertyEffect(o,n,a){let s=bo(this,n,!0)[o],l=s.indexOf(a);l>=0&&s.splice(l,1)}_hasPropertyEffect(o,n){let a=this[n];return!!(a&&a[o])}_hasReadOnlyEffect(o){return this._hasPropertyEffect(o,V.READ_ONLY)}_hasNotifyEffect(o){return this._hasPropertyEffect(o,V.NOTIFY)}_hasReflectEffect(o){return this._hasPropertyEffect(o,V.REFLECT)}_hasComputedEffect(o){return this._hasPropertyEffect(o,V.COMPUTE)}_setPendingPropertyOrPath(o,n,a,s){if(s||xt(Array.isArray(o)?o[0]:o)!==o){if(!s){let l=Pe(this,o);if(o=Ts(this,o,n),!o||!super._shouldPropertyChange(o,n,l))return!1}if(this.__dataHasPaths=!0,this._setPendingProperty(o,n,a))return wv(this,o,n),!0}else{if(this.__dataHasAccessor&&this.__dataHasAccessor[o])return this._setPendingProperty(o,n,a);this[o]=n}return!1}_setUnmanagedPropertyToNode(o,n,a){(a!==o[n]||typeof a=="object")&&(n==="className"&&(o=fe(o)),o[n]=a)}_setPendingProperty(o,n,a){let s=this.__dataHasPaths&&on(o),l=s?this.__dataTemp:this.__data;return this._shouldPropertyChange(o,n,l[o])?(this.__dataPending||(this.__dataPending={},this.__dataOld={}),o in this.__dataOld||(this.__dataOld[o]=this.__data[o]),s?this.__dataTemp[o]=n:this.__data[o]=n,this.__dataPending[o]=n,(s||this[V.NOTIFY]&&this[V.NOTIFY][o])&&(this.__dataToNotify=this.__dataToNotify||{},this.__dataToNotify[o]=a),!0):!1}_setProperty(o,n){this._setPendingProperty(o,n,!0)&&this._invalidateProperties()}_invalidateProperties(){this.__dataReady&&this._flushProperties()}_enqueueClient(o){this.__dataPendingClients=this.__dataPendingClients||[],o!==this&&this.__dataPendingClients.push(o)}_flushClients(){this.__dataClientsReady?this.__enableOrFlushClients():(this.__dataClientsReady=!0,this._readyClients(),this.__dataReady=!0)}__enableOrFlushClients(){let o=this.__dataPendingClients;if(o){this.__dataPendingClients=null;for(let n=0;n<o.length;n++){let a=o[n];a.__dataEnabled?a.__dataPending&&a._flushProperties():a._enableProperties()}}}_readyClients(){this.__enableOrFlushClients()}setProperties(o,n){for(let a in o)(n||!this[V.READ_ONLY]||!this[V.READ_ONLY][a])&&this._setPendingPropertyOrPath(a,o[a],!0);this._invalidateProperties()}ready(){this._flushProperties(),this.__dataClientsReady||this._flushClients(),this.__dataPending&&this._flushProperties()}_propertiesChanged(o,n,a){let s=this.__dataHasPaths;this.__dataHasPaths=!1;let l;vv(this,n,a,s),l=this.__dataToNotify,this.__dataToNotify=null,this._propagatePropertyChanges(n,a,s),this._flushClients(),Cr(this,this[V.REFLECT],n,a,s),Cr(this,this[V.OBSERVE],n,a,s),l&&hv(this,l,n,a,s),this.__dataCounter==1&&(this.__dataTemp={})}_propagatePropertyChanges(o,n,a){this[V.PROPAGATE]&&Cr(this,this[V.PROPAGATE],o,n,a),this.__templateInfo&&this._runEffectsForTemplate(this.__templateInfo,o,n,a)}_runEffectsForTemplate(o,n,a,s){const l=(d,u)=>{Cr(this,o.propertyEffects,d,a,u,o.nodeList);for(let c=o.firstChild;c;c=c.nextSibling)this._runEffectsForTemplate(c,d,a,u)};o.runEffects?o.runEffects(l,n,s):l(n,s)}linkPaths(o,n){o=xr(o),n=xr(n),this.__dataLinkedPaths=this.__dataLinkedPaths||{},this.__dataLinkedPaths[o]=n}unlinkPaths(o){o=xr(o),this.__dataLinkedPaths&&delete this.__dataLinkedPaths[o]}notifySplices(o,n){let a={path:""},s=Pe(this,o,a);Wd(this,s,a.path,n)}get(o,n){return Pe(n||this,o)}set(o,n,a){a?Ts(a,o,n):(!this[V.READ_ONLY]||!this[V.READ_ONLY][o])&&this._setPendingPropertyOrPath(o,n,!0)&&this._invalidateProperties()}push(o,...n){let a={path:""},s=Pe(this,o,a),l=s.length,d=s.push(...n);return n.length&&gr(this,s,a.path,l,n.length,[]),d}pop(o){let n={path:""},a=Pe(this,o,n),s=!!a.length,l=a.pop();return s&&gr(this,a,n.path,a.length,0,[l]),l}splice(o,n,a,...s){let l={path:""},d=Pe(this,o,l);n<0?n=d.length-Math.floor(-n):n&&(n=Math.floor(n));let u;return arguments.length===2?u=d.splice(n):u=d.splice(n,a,...s),(s.length||u.length)&&gr(this,d,l.path,n,s.length,u),u}shift(o){let n={path:""},a=Pe(this,o,n),s=!!a.length,l=a.shift();return s&&gr(this,a,n.path,0,0,[l]),l}unshift(o,...n){let a={path:""},s=Pe(this,o,a),l=s.unshift(...n);return n.length&&gr(this,s,a.path,0,n.length,[]),l}notifyPath(o,n){let a;if(arguments.length==1){let s={path:""};n=Pe(this,o,s),a=s.path}else Array.isArray(o)?a=xr(o):a=o;this._setPendingPropertyOrPath(a,n,!0,!0)&&this._invalidateProperties()}_createReadOnlyProperty(o,n){this._addPropertyEffect(o,V.READ_ONLY),n&&(this["_set"+Uv(o)]=function(a){this._setProperty(o,a)})}_createPropertyObserver(o,n,a){let s={property:o,method:n,dynamicFn:!!a};this._addPropertyEffect(o,V.OBSERVE,{fn:ks,info:s,trigger:{name:o}}),a&&this._addPropertyEffect(n,V.OBSERVE,{fn:ks,info:s,trigger:{name:n}})}_createMethodObserver(o,n){let a=wo(o);if(!a)throw new Error("Malformed observer expression '"+o+"'");Ss(this,a,V.OBSERVE,an,null,n)}_createNotifyingProperty(o){this._addPropertyEffect(o,V.NOTIFY,{fn:mv,info:{eventName:Xi(o)+"-changed",property:o}})}_createReflectedProperty(o){let n=this.constructor.attributeNameForProperty(o);n[0]==="-"?console.warn("Property "+o+" cannot be reflected to attribute "+n+' because "-" is not a valid starting attribute name. Use a lowercase first letter for the property instead.'):this._addPropertyEffect(o,V.REFLECT,{fn:_v,info:{attrName:n}})}_createComputedProperty(o,n,a){let s=wo(n);if(!s)throw new Error("Malformed computed expression '"+n+"'");const l=Ss(this,s,V.COMPUTE,$d,o,a);bo(this,Rd)[o]=l}_marshalArgs(o,n,a){const s=this.__data,l=[];for(let d=0,u=o.length;d<u;d++){let{name:c,structured:h,wildcard:p,value:m,literal:f}=o[d];if(!f)if(p){const y=Lr(c,n),E=Ms(s,a,y?n:c);m={path:y?n:c,value:E,base:y?Pe(s,c):E}}else m=h?Ms(s,a,c):s[c];if(rn&&!this._overrideLegacyUndefined&&m===void 0&&o.length>1)return Rr;l[d]=m}return l}static addPropertyEffect(o,n,a){this.prototype._addPropertyEffect(o,n,a)}static createPropertyObserver(o,n,a){this.prototype._createPropertyObserver(o,n,a)}static createMethodObserver(o,n){this.prototype._createMethodObserver(o,n)}static createNotifyingProperty(o){this.prototype._createNotifyingProperty(o)}static createReadOnlyProperty(o,n){this.prototype._createReadOnlyProperty(o,n)}static createReflectedProperty(o){this.prototype._createReflectedProperty(o)}static createComputedProperty(o,n,a){this.prototype._createComputedProperty(o,n,a)}static bindTemplate(o){return this.prototype._bindTemplate(o)}_bindTemplate(o,n){let a=this.constructor._parseTemplate(o),s=this.__preBoundTemplateInfo==a;if(!s)for(let l in a.propertyEffects)this._createPropertyAccessor(l);if(n)if(a=Object.create(a),a.wasPreBound=s,!this.__templateInfo)this.__templateInfo=a;else{const l=o._parentTemplateInfo||this.__templateInfo,d=l.lastChild;a.parent=l,l.lastChild=a,a.previousSibling=d,d?d.nextSibling=a:l.firstChild=a}else this.__preBoundTemplateInfo=a;return a}static _addTemplatePropertyEffect(o,n,a){let s=o.hostProps=o.hostProps||{};s[n]=!0;let l=o.propertyEffects=o.propertyEffects||{};(l[n]=l[n]||[]).push(a)}_stampTemplate(o,n){n=n||this._bindTemplate(o,!0),br.push(this);let a=super._stampTemplate(o,n);if(br.pop(),n.nodeList=a.nodeList,!n.wasPreBound){let s=n.childNodes=[];for(let l=a.firstChild;l;l=l.nextSibling)s.push(l)}return a.templateInfo=n,Av(this,n),this.__dataClientsReady&&(this._runEffectsForTemplate(n,this.__data,null,!1),this._flushClients()),a}_removeBoundDom(o){const n=o.templateInfo,{previousSibling:a,nextSibling:s,parent:l}=n;a?a.nextSibling=s:l&&(l.firstChild=s),s?s.previousSibling=a:l&&(l.lastChild=a),n.nextSibling=n.previousSibling=null;let d=n.childNodes;for(let u=0;u<d.length;u++){let c=d[u];fe(fe(c).parentNode).removeChild(c)}}static _parseTemplateNode(o,n,a){let s=e._parseTemplateNode.call(this,o,n,a);if(o.nodeType===Node.TEXT_NODE){let l=this._parseBindings(o.textContent,n);l&&(o.textContent=Ns(l)||" ",yo(this,n,a,"text","textContent",l),s=!0)}return s}static _parseTemplateNodeAttribute(o,n,a,s,l){let d=this._parseBindings(l,n);if(d){let u=s,c="property";uv.test(s)?c="attribute":s[s.length-1]=="$"&&(s=s.slice(0,-1),c="attribute");let h=Ns(d);return h&&c=="attribute"&&(s=="class"&&o.hasAttribute("class")&&(h+=" "+o.getAttribute(s)),o.setAttribute(s,h)),c=="attribute"&&u=="disable-upgrade$"&&o.setAttribute(s,""),o.localName==="input"&&u==="value"&&o.setAttribute(u,""),o.removeAttribute(u),c==="property"&&(s=Od(s)),yo(this,n,a,c,s,d,h),!0}else return e._parseTemplateNodeAttribute.call(this,o,n,a,s,l)}static _parseTemplateNestedTemplate(o,n,a){let s=e._parseTemplateNestedTemplate.call(this,o,n,a);const l=o.parentNode,d=a.templateInfo,u=l.localName==="dom-if",c=l.localName==="dom-repeat";bs&&(u||c)&&(l.removeChild(o),a=a.parentInfo,a.templateInfo=d,a.noted=!0,s=!1);let h=d.hostProps;if(M_&&u)h&&(n.hostProps=Object.assign(n.hostProps||{},h),bs||(a.parentInfo.noted=!0));else{let p="{";for(let m in h){let f=[{mode:p,source:m,dependencies:[m],hostProp:!0}];yo(this,n,a,"property","_host_"+m,f)}}return s}static _parseBindings(o,n){let a=[],s=0,l;for(;(l=Os.exec(o))!==null;){l.index>s&&a.push({literal:o.slice(s,l.index)});let d=l[1][0],u=!!l[2],c=l[3].trim(),h=!1,p="",m=-1;d=="{"&&(m=c.indexOf("::"))>0&&(p=c.substring(m+2),c=c.substring(0,m),h=!0);let f=wo(c),y=[];if(f){let{args:E,methodName:C}=f;for(let N=0;N<E.length;N++){let U=E[N];U.literal||y.push(U)}let T=n.dynamicFns;(T&&T[C]||f.static)&&(y.push(C),f.dynamicFn=!0)}else y.push(c);a.push({source:c,mode:d,negate:u,customEvent:h,signature:f,dependencies:y,event:p}),s=Os.lastIndex}if(s&&s<o.length){let d=o.substring(s);d&&a.push({literal:d})}return a.length?a:null}static _evaluateBinding(o,n,a,s,l,d){let u;return n.signature?u=an(o,a,s,l,n.signature):a!=n.source?u=Pe(o,n.source):d&&on(a)?u=Pe(o,a):u=o.__data[a],n.negate&&(u=!u),u}}return t}),br=[];/**
|
|
1008
1008
|
@license
|
|
1009
1009
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1010
1010
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1020,7 +1020,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
1020
1020
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1021
1021
|
Code distributed by Google as part of the polymer project is also
|
|
1022
1022
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1023
|
-
*/function
|
|
1023
|
+
*/function Wv(r){const e={};for(let t in r){const i=r[t];e[t]=typeof i=="function"?{type:i}:i}return e}const jv=le(r=>{const e=Ld(r);function t(n){const a=Object.getPrototypeOf(n);return a.prototype instanceof o?a:null}function i(n){if(!n.hasOwnProperty(JSCompiler_renameProperty("__ownProperties",n))){let a=null;if(n.hasOwnProperty(JSCompiler_renameProperty("properties",n))){const s=n.properties;s&&(a=Wv(s))}n.__ownProperties=a}return n.__ownProperties}class o extends e{static get observedAttributes(){if(!this.hasOwnProperty(JSCompiler_renameProperty("__observedAttributes",this))){this.prototype;const a=this._properties;this.__observedAttributes=a?Object.keys(a).map(s=>this.prototype._addPropertyToAttributeMap(s)):[]}return this.__observedAttributes}static finalize(){if(!this.hasOwnProperty(JSCompiler_renameProperty("__finalized",this))){const a=t(this);a&&a.finalize(),this.__finalized=!0,this._finalizeClass()}}static _finalizeClass(){const a=i(this);a&&this.createProperties(a)}static get _properties(){if(!this.hasOwnProperty(JSCompiler_renameProperty("__properties",this))){const a=t(this);this.__properties=Object.assign({},a&&a._properties,i(this))}return this.__properties}static typeForProperty(a){const s=this._properties[a];return s&&s.type}_initializeProperties(){this.constructor.finalize(),super._initializeProperties()}connectedCallback(){super.connectedCallback&&super.connectedCallback(),this._enableProperties()}disconnectedCallback(){super.disconnectedCallback&&super.disconnectedCallback()}}return o});/**
|
|
1024
1024
|
* @fileoverview
|
|
1025
1025
|
* @suppress {checkPrototypalTypes}
|
|
1026
1026
|
* @license Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
@@ -1030,7 +1030,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1030
1030
|
* be found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by
|
|
1031
1031
|
* Google as part of the polymer project is also subject to an additional IP
|
|
1032
1032
|
* rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1033
|
-
*/const
|
|
1033
|
+
*/const qv="3.5.2",Bs=window.ShadyCSS&&window.ShadyCSS.cssBuild,Yv=le(r=>{const e=jv(Vn(r));function t(l){if(!l.hasOwnProperty(JSCompiler_renameProperty("__propertyDefaults",l))){l.__propertyDefaults=null;let d=l._properties;for(let u in d){let c=d[u];"value"in c&&(l.__propertyDefaults=l.__propertyDefaults||{},l.__propertyDefaults[u]=c)}}return l.__propertyDefaults}function i(l){return l.hasOwnProperty(JSCompiler_renameProperty("__ownObservers",l))||(l.__ownObservers=l.hasOwnProperty(JSCompiler_renameProperty("observers",l))?l.observers:null),l.__ownObservers}function o(l,d,u,c){u.computed&&(u.readOnly=!0),u.computed&&(l._hasReadOnlyEffect(d)?console.warn(`Cannot redefine computed property '${d}'.`):l._createComputedProperty(d,u.computed,c)),u.readOnly&&!l._hasReadOnlyEffect(d)?l._createReadOnlyProperty(d,!u.computed):u.readOnly===!1&&l._hasReadOnlyEffect(d)&&console.warn(`Cannot make readOnly property '${d}' non-readOnly.`),u.reflectToAttribute&&!l._hasReflectEffect(d)?l._createReflectedProperty(d):u.reflectToAttribute===!1&&l._hasReflectEffect(d)&&console.warn(`Cannot make reflected property '${d}' non-reflected.`),u.notify&&!l._hasNotifyEffect(d)?l._createNotifyingProperty(d):u.notify===!1&&l._hasNotifyEffect(d)&&console.warn(`Cannot make notify property '${d}' non-notify.`),u.observer&&l._createPropertyObserver(d,u.observer,c[u.observer]),l._addPropertyToAttributeMap(d)}function n(l,d,u,c){if(!Bs){const h=d.content.querySelectorAll("style"),p=kd(d),m=V_(u),f=d.content.firstElementChild;for(let E=0;E<m.length;E++){let C=m[E];C.textContent=l._processStyleText(C.textContent,c),d.content.insertBefore(C,f)}let y=0;for(let E=0;E<p.length;E++){let C=p[E],T=h[y];T!==C?(C=C.cloneNode(!0),T.parentNode.insertBefore(C,T)):y++,C.textContent=l._processStyleText(C.textContent,c)}}if(window.ShadyCSS&&window.ShadyCSS.prepareTemplate(d,u),B_&&Bs&&I_){const h=d.content.querySelectorAll("style");if(h){let p="";Array.from(h).forEach(m=>{p+=m.textContent,m.parentNode.removeChild(m)}),l._styleSheet=new CSSStyleSheet,l._styleSheet.replaceSync(p)}}}function a(l){let d=null;if(l&&(!Mi||D_)&&(d=Br.import(l,"template"),Mi&&!d))throw new Error(`strictTemplatePolicy: expecting dom-module or null template for ${l}`);return d}class s extends e{static get polymerElementVersion(){return qv}static _finalizeClass(){e._finalizeClass.call(this);const d=i(this);d&&this.createObservers(d,this._properties),this._prepareTemplate()}static _prepareTemplate(){let d=this.template;d&&(typeof d=="string"?(console.error("template getter must return HTMLTemplateElement"),d=null):Ed||(d=d.cloneNode(!0))),this.prototype._template=d}static createProperties(d){for(let u in d)o(this.prototype,u,d[u],d)}static createObservers(d,u){const c=this.prototype;for(let h=0;h<d.length;h++)c._createMethodObserver(d[h],u)}static get template(){if(!this.hasOwnProperty(JSCompiler_renameProperty("_template",this))){let d=this.prototype.hasOwnProperty(JSCompiler_renameProperty("_template",this.prototype))?this.prototype._template:void 0;typeof d=="function"&&(d=d()),this._template=d!==void 0?d:this.hasOwnProperty(JSCompiler_renameProperty("is",this))&&a(this.is)||Object.getPrototypeOf(this.prototype).constructor.template}return this._template}static set template(d){this._template=d}static get importPath(){if(!this.hasOwnProperty(JSCompiler_renameProperty("_importPath",this))){const d=this.importMeta;if(d)this._importPath=Rn(d.url);else{const u=Br.import(this.is);this._importPath=u&&u.assetpath||Object.getPrototypeOf(this.prototype).constructor.importPath}}return this._importPath}constructor(){super(),this._template,this._importPath,this.rootPath,this.importPath,this.root,this.$}_initializeProperties(){this.constructor.finalize(),this.constructor._finalizeTemplate(this.localName),super._initializeProperties(),this.rootPath=S_,this.importPath=this.constructor.importPath;let d=t(this.constructor);if(d)for(let u in d){let c=d[u];if(this._canApplyPropertyDefault(u)){let h=typeof c.value=="function"?c.value.call(this):c.value;this._hasAccessor(u)?this._setPendingProperty(u,h,!0):this[u]=h}}}_canApplyPropertyDefault(d){return!this.hasOwnProperty(d)}static _processStyleText(d,u){return Hn(d,u)}static _finalizeTemplate(d){const u=this.prototype._template;if(u&&!u.__polymerFinalized){u.__polymerFinalized=!0;const c=this.importPath,h=c?Ar(c):"";n(this,u,d,h),this.prototype._bindTemplate(u)}}connectedCallback(){window.ShadyCSS&&this._template&&window.ShadyCSS.styleElement(this),super.connectedCallback()}ready(){this._template&&(this.root=this._stampTemplate(this._template),this.$=this.root.$),super.ready()}_readyClients(){this._template&&(this.root=this._attachDom(this.root)),super._readyClients()}_attachDom(d){const u=fe(this);if(u.attachShadow)return d?(u.shadowRoot||(u.attachShadow({mode:"open",shadyUpgradeFragment:d}),u.shadowRoot.appendChild(d),this.constructor._styleSheet&&(u.shadowRoot.adoptedStyleSheets=[this.constructor._styleSheet])),O_&&window.ShadyDOM&&window.ShadyDOM.flushInitial(u.shadowRoot),u.shadowRoot):null;throw new Error("ShadowDOM not available. PolymerElement can create dom as children instead of in ShadowDOM by setting `this.root = this;` before `ready`.")}updateStyles(d){window.ShadyCSS&&window.ShadyCSS.styleSubtree(this,d)}resolveUrl(d,u){return!u&&this.importPath&&(u=Ar(this.importPath)),Ar(d,u)}static _parseTemplateContent(d,u,c){return u.dynamicFns=u.dynamicFns||this._properties,e._parseTemplateContent.call(this,d,u,c)}static _addTemplatePropertyEffect(d,u,c){return Td&&!(u in this._properties)&&!(c.info.part.signature&&c.info.part.signature.static)&&!c.info.part.hostProp&&!d.nestedTemplate&&console.warn(`Property '${u}' used in template but not declared in 'properties'; attribute will not be observed.`),e._addTemplatePropertyEffect.call(this,d,u,c)}}return s});/**
|
|
1034
1034
|
@license
|
|
1035
1035
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1036
1036
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1038,7 +1038,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
1038
1038
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1039
1039
|
Code distributed by Google as part of the polymer project is also
|
|
1040
1040
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1041
|
-
*/const Ls=window.trustedTypes&&trustedTypes.createPolicy("polymer-html-literal",{createHTML:r=>r});class jd{constructor(e,t){Yd(e,t);const i=t.reduce((o,n,a)=>o+qd(n)+e[a+1],e[0]);this.value=i.toString()}toString(){return this.value}}function qd(r){if(r instanceof jd)return r.value;throw new Error(`non-literal value passed to Polymer's htmlLiteral function: ${r}`)}function
|
|
1041
|
+
*/const Ls=window.trustedTypes&&trustedTypes.createPolicy("polymer-html-literal",{createHTML:r=>r});class jd{constructor(e,t){Yd(e,t);const i=t.reduce((o,n,a)=>o+qd(n)+e[a+1],e[0]);this.value=i.toString()}toString(){return this.value}}function qd(r){if(r instanceof jd)return r.value;throw new Error(`non-literal value passed to Polymer's htmlLiteral function: ${r}`)}function Gv(r){if(r instanceof HTMLTemplateElement)return r.innerHTML;if(r instanceof jd)return qd(r);throw new Error(`non-template value passed to Polymer's html function: ${r}`)}const z=function(r,...e){Yd(r,e);const t=document.createElement("template");let i=e.reduce((o,n,a)=>o+Gv(n)+r[a+1],r[0]);return Ls&&(i=Ls.createHTML(i)),t.innerHTML=i,t},Yd=(r,e)=>{if(!Array.isArray(r)||!Array.isArray(r.raw)||e.length!==r.length-1)throw new TypeError("Invalid call to the html template tag")};/**
|
|
1042
1042
|
@license
|
|
1043
1043
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1044
1044
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1046,7 +1046,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
1046
1046
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1047
1047
|
Code distributed by Google as part of the polymer project is also
|
|
1048
1048
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1049
|
-
*/const
|
|
1049
|
+
*/const H=Yv(HTMLElement),Xv=/\/\*[\*!]\s+vaadin-dev-mode:start([\s\S]*)vaadin-dev-mode:end\s+\*\*\//i,bi=window.Vaadin&&window.Vaadin.Flow&&window.Vaadin.Flow.clients;function Kv(){function r(){return!0}return Gd(r)}function Qv(){try{return Jv()?!0:Zv()?bi?!eg():!Kv():!1}catch(r){return!1}}function Jv(){return localStorage.getItem("vaadin.developmentmode.force")}function Zv(){return["localhost","127.0.0.1"].indexOf(window.location.hostname)>=0}function eg(){return!!(bi&&Object.keys(bi).map(r=>bi[r]).filter(r=>r.productionMode).length>0)}function Gd(r,e){if(typeof r!="function")return;const t=Xv.exec(r.toString());if(t)try{r=new Function(t[1])}catch(i){console.log("vaadin-development-mode-detector: uncommentAndRun() failed",i)}return r(e)}window.Vaadin=window.Vaadin||{};const zs=function(r,e){if(window.Vaadin.developmentMode)return Gd(r,e)};window.Vaadin.developmentMode===void 0&&(window.Vaadin.developmentMode=Qv());function tg(){/*! vaadin-dev-mode:start
|
|
1050
1050
|
(function () {
|
|
1051
1051
|
'use strict';
|
|
1052
1052
|
|
|
@@ -1524,7 +1524,7 @@ try {
|
|
|
1524
1524
|
|
|
1525
1525
|
}());
|
|
1526
1526
|
|
|
1527
|
-
vaadin-dev-mode:end **/}const
|
|
1527
|
+
vaadin-dev-mode:end **/}const rg=function(){if(typeof zs=="function")return zs(tg)};/**
|
|
1528
1528
|
* @license
|
|
1529
1529
|
* Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1530
1530
|
* This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1532,7 +1532,7 @@ try {
|
|
|
1532
1532
|
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1533
1533
|
* Code distributed by Google as part of the polymer project is also
|
|
1534
1534
|
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1535
|
-
*/let Hs=0,Xd=0;const $t=[];let sn=!1;function
|
|
1535
|
+
*/let Hs=0,Xd=0;const $t=[];let sn=!1;function ig(){sn=!1;const r=$t.length;for(let e=0;e<r;e++){const t=$t[e];if(t)try{t()}catch(i){setTimeout(()=>{throw i})}}$t.splice(0,r),Xd+=r}const nt={after(r){return{run(e){return window.setTimeout(e,r)},cancel(e){window.clearTimeout(e)}}},run(r,e){return window.setTimeout(r,e)},cancel(r){window.clearTimeout(r)}},Fr={run(r){return window.requestAnimationFrame(r)},cancel(r){window.cancelAnimationFrame(r)}},Kd={run(r){return window.requestIdleCallback?window.requestIdleCallback(r):window.setTimeout(r,16)},cancel(r){window.cancelIdleCallback?window.cancelIdleCallback(r):window.clearTimeout(r)}},Li={run(r){sn||(sn=!0,queueMicrotask(()=>ig())),$t.push(r);const e=Hs;return Hs+=1,e},cancel(r){const e=r-Xd;if(e>=0){if(!$t[e])throw new Error(`invalid async handle: ${r}`);$t[e]=null}}};/**
|
|
1536
1536
|
@license
|
|
1537
1537
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1538
1538
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1540,19 +1540,19 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
1540
1540
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1541
1541
|
Code distributed by Google as part of the polymer project is also
|
|
1542
1542
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1543
|
-
*/const
|
|
1543
|
+
*/const $r=new Set;let Se=class ln{static debounce(e,t,i){return e instanceof ln?e._cancelAsync():e=new ln,e.setConfig(t,i),e}constructor(){this._asyncModule=null,this._callback=null,this._timer=null}setConfig(e,t){this._asyncModule=e,this._callback=t,this._timer=this._asyncModule.run(()=>{this._timer=null,$r.delete(this),this._callback()})}cancel(){this.isActive()&&(this._cancelAsync(),$r.delete(this))}_cancelAsync(){this.isActive()&&(this._asyncModule.cancel(this._timer),this._timer=null)}flush(){this.isActive()&&(this.cancel(),this._callback())}isActive(){return this._timer!=null}};function Qd(r){$r.add(r)}function og(){const r=!!$r.size;return $r.forEach(e=>{try{e.flush()}catch(t){setTimeout(()=>{throw t})}}),r}const Er=()=>{let r;do r=og();while(r)};/**
|
|
1544
1544
|
* @license
|
|
1545
1545
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1546
1546
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1547
|
-
*/const
|
|
1547
|
+
*/const je=[];function dn(r,e,t=r.getAttribute("dir")){e?r.setAttribute("dir",e):t!=null&&r.removeAttribute("dir")}function un(){return document.documentElement.getAttribute("dir")}function ng(){const r=un();je.forEach(e=>{dn(e,r)})}const ag=new MutationObserver(ng);ag.observe(document.documentElement,{attributes:!0,attributeFilter:["dir"]});const Oe=r=>class extends r{static get properties(){return{dir:{type:String,value:"",reflectToAttribute:!0,converter:{fromAttribute:e=>e||"",toAttribute:e=>e===""?null:e}}}}get __isRTL(){return this.getAttribute("dir")==="rtl"}connectedCallback(){super.connectedCallback(),(!this.hasAttribute("dir")||this.__restoreSubscription)&&(this.__subscribe(),dn(this,un(),null))}attributeChangedCallback(e,t,i){if(super.attributeChangedCallback(e,t,i),e!=="dir")return;const o=un(),n=i===o&&je.indexOf(this)===-1,a=!i&&t&&je.indexOf(this)===-1;n||a?(this.__subscribe(),dn(this,o,i)):i!==o&&t===o&&this.__unsubscribe()}disconnectedCallback(){super.disconnectedCallback(),this.__restoreSubscription=je.includes(this),this.__unsubscribe()}_valueToNodeAttribute(e,t,i){i==="dir"&&t===""&&!e.hasAttribute("dir")||super._valueToNodeAttribute(e,t,i)}_attributeToProperty(e,t,i){e==="dir"&&!t?this.dir="":super._attributeToProperty(e,t,i)}__subscribe(){je.includes(this)||je.push(this)}__unsubscribe(){je.includes(this)&&je.splice(je.indexOf(this),1)}};/**
|
|
1548
1548
|
* @license
|
|
1549
1549
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1550
1550
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1551
|
-
*/window.Vaadin||(window.Vaadin={});window.Vaadin.registrations||(window.Vaadin.registrations=[]);window.Vaadin.developmentModeCallback||(window.Vaadin.developmentModeCallback={});window.Vaadin.developmentModeCallback["vaadin-usage-statistics"]=function(){
|
|
1551
|
+
*/window.Vaadin||(window.Vaadin={});window.Vaadin.registrations||(window.Vaadin.registrations=[]);window.Vaadin.developmentModeCallback||(window.Vaadin.developmentModeCallback={});window.Vaadin.developmentModeCallback["vaadin-usage-statistics"]=function(){rg()};let xo;const Rs=new Set,Ne=r=>class extends Oe(r){static finalize(){super.finalize();const{is:e}=this;e&&!Rs.has(e)&&(window.Vaadin.registrations.push(this),Rs.add(e),window.Vaadin.developmentModeCallback&&(xo=Se.debounce(xo,Kd,()=>{window.Vaadin.developmentModeCallback["vaadin-usage-statistics"]()}),Qd(xo)))}constructor(){super(),document.doctype===null&&console.warn('Vaadin components require the "standards mode" declaration. Please add <!DOCTYPE html> to the HTML document.')}};/**
|
|
1552
1552
|
* @license
|
|
1553
1553
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1554
1554
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1555
|
-
*/function
|
|
1555
|
+
*/function sg(r){const e=[];for(;r;){if(r.nodeType===Node.DOCUMENT_NODE){e.push(r);break}if(r.nodeType===Node.DOCUMENT_FRAGMENT_NODE){e.push(r),r=r.host;continue}if(r.assignedSlot){r=r.assignedSlot;continue}r=r.parentNode}return e}function Jd(r){const e=[];let t;return r.localName==="slot"?t=r.assignedElements():(e.push(r),t=[...r.children]),t.forEach(i=>e.push(...Jd(i))),e}function Un(r){return r?new Set(r.split(" ")):new Set}function Ki(r){return r?[...r].join(" "):""}function Zd(r,e,t){const i=Un(r.getAttribute(e));i.add(t),r.setAttribute(e,Ki(i))}function lg(r,e,t){const i=Un(r.getAttribute(e));if(i.delete(t),i.size===0){r.removeAttribute(e);return}r.setAttribute(e,Ki(i))}function dg(r){return r.nodeType===Node.TEXT_NODE&&r.textContent.trim()===""}/**
|
|
1556
1556
|
* @license
|
|
1557
1557
|
* Copyright (c) 2023 - 2024 Vaadin Ltd.
|
|
1558
1558
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -1560,15 +1560,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1560
1560
|
* @license
|
|
1561
1561
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1562
1562
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1563
|
-
*/let
|
|
1563
|
+
*/let ug=0;function qr(){return ug++}/**
|
|
1564
1564
|
* @license
|
|
1565
1565
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1566
1566
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1567
|
-
*/class xe extends EventTarget{static generateId(e,t="default"){return`${t}-${e.localName}-${
|
|
1567
|
+
*/class xe extends EventTarget{static generateId(e,t="default"){return`${t}-${e.localName}-${qr()}`}constructor(e,t,i,o={}){super();const{initializer:n,multiple:a,observe:s,useUniqueId:l,uniqueIdPrefix:d}=o;this.host=e,this.slotName=t,this.tagName=i,this.observe=typeof s=="boolean"?s:!0,this.multiple=typeof a=="boolean"?a:!1,this.slotInitializer=n,a&&(this.nodes=[]),l&&(this.defaultId=this.constructor.generateId(e,d||t))}hostConnected(){this.initialized||(this.multiple?this.initMultiple():this.initSingle(),this.observe&&this.observeSlot(),this.initialized=!0)}initSingle(){let e=this.getSlotChild();e?(this.node=e,this.initAddedNode(e)):(e=this.attachDefaultNode(),this.initNode(e))}initMultiple(){const e=this.getSlotChildren();if(e.length===0){const t=this.attachDefaultNode();t&&(this.nodes=[t],this.initNode(t))}else this.nodes=e,e.forEach(t=>{this.initAddedNode(t)})}attachDefaultNode(){const{host:e,slotName:t,tagName:i}=this;let o=this.defaultNode;return!o&&i&&(o=document.createElement(i),o instanceof Element&&(t!==""&&o.setAttribute("slot",t),this.defaultNode=o)),o&&(this.node=o,e.appendChild(o)),o}getSlotChildren(){const{slotName:e}=this;return Array.from(this.host.childNodes).filter(t=>t.nodeType===Node.ELEMENT_NODE&&t.slot===e||t.nodeType===Node.TEXT_NODE&&t.textContent.trim()&&e==="")}getSlotChild(){return this.getSlotChildren()[0]}initNode(e){const{slotInitializer:t}=this;t&&t(e,this.host)}initCustomNode(e){}teardownNode(e){}initAddedNode(e){e!==this.defaultNode&&(this.initCustomNode(e),this.initNode(e))}observeSlot(){const{slotName:e}=this,t=e===""?"slot:not([name])":`slot[name=${e}]`,i=this.host.shadowRoot.querySelector(t);this.__slotObserver=new Wn(i,({addedNodes:o,removedNodes:n})=>{const a=this.multiple?this.nodes:[this.node],s=o.filter(l=>!dg(l)&&!a.includes(l));n.length&&(this.nodes=a.filter(l=>!n.includes(l)),n.forEach(l=>{this.teardownNode(l)})),s&&s.length>0&&(this.multiple?(this.defaultNode&&this.defaultNode.remove(),this.nodes=[...a,...s].filter(l=>l!==this.defaultNode),s.forEach(l=>{this.initAddedNode(l)})):(this.node&&this.node.remove(),this.node=s[0],this.initAddedNode(this.node)))})}}/**
|
|
1568
1568
|
* @license
|
|
1569
1569
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
1570
1570
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1571
|
-
*/class
|
|
1571
|
+
*/class Qe extends xe{constructor(e){super(e,"tooltip"),this.setTarget(e)}initCustomNode(e){e.target=this.target,this.ariaTarget!==void 0&&(e.ariaTarget=this.ariaTarget),this.context!==void 0&&(e.context=this.context),this.manual!==void 0&&(e.manual=this.manual),this.opened!==void 0&&(e.opened=this.opened),this.position!==void 0&&(e._position=this.position),this.shouldShow!==void 0&&(e.shouldShow=this.shouldShow),this.__notifyChange()}teardownNode(){this.__notifyChange()}setAriaTarget(e){this.ariaTarget=e;const t=this.node;t&&(t.ariaTarget=e)}setContext(e){this.context=e;const t=this.node;t&&(t.context=e)}setManual(e){this.manual=e;const t=this.node;t&&(t.manual=e)}setOpened(e){this.opened=e;const t=this.node;t&&(t.opened=e)}setPosition(e){this.position=e;const t=this.node;t&&(t._position=e)}setShouldShow(e){this.shouldShow=e;const t=this.node;t&&(t.shouldShow=e)}setTarget(e){this.target=e;const t=this.node;t&&(t.target=e)}__notifyChange(){this.dispatchEvent(new CustomEvent("tooltip-changed",{detail:{node:this.node}}))}}/**
|
|
1572
1572
|
@license
|
|
1573
1573
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
1574
1574
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -1576,27 +1576,27 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
1576
1576
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
1577
1577
|
Code distributed by Google as part of the polymer project is also
|
|
1578
1578
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
1579
|
-
*/const
|
|
1579
|
+
*/const cg=r=>r,eu=typeof document.head.style.touchAction=="string",cn="__polymerGestures",Co="__polymerGesturesHandled",hn="__polymerGesturesTouchAction",Fs=25,$s=5,hg=2,pg=["mousedown","mousemove","mouseup","click"],mg=[0,1,4,2],fg=function(){try{return new MouseEvent("test",{buttons:1}).buttons===1}catch(r){return!1}}();function tu(r){return pg.indexOf(r)>-1}let _g=!1;(function(){try{const r=Object.defineProperty({},"passive",{get(){_g=!0}});window.addEventListener("test",null,r),window.removeEventListener("test",null,r)}catch(r){}})();const vg=navigator.userAgent.match(/iP(?:[oa]d|hone)|Android/u),gg={button:!0,command:!0,fieldset:!0,input:!0,keygen:!0,optgroup:!0,option:!0,select:!0,textarea:!0};function vt(r){const e=r.type;if(!tu(e))return!1;if(e==="mousemove"){let t=r.buttons===void 0?1:r.buttons;return r instanceof window.MouseEvent&&!fg&&(t=mg[r.which]||0),!!(t&1)}return(r.button===void 0?0:r.button)===0}function bg(r){if(r.type==="click"){if(r.detail===0)return!0;const e=at(r);if(!e.nodeType||e.nodeType!==Node.ELEMENT_NODE)return!0;const t=e.getBoundingClientRect(),i=r.pageX,o=r.pageY;return!(i>=t.left&&i<=t.right&&o>=t.top&&o<=t.bottom)}return!1}const qe={touch:{x:0,y:0,id:-1,scrollDecided:!1}};function yg(r){let e="auto";const t=iu(r);for(let i=0,o;i<t.length;i++)if(o=t[i],o[hn]){e=o[hn];break}return e}function ru(r,e,t){r.movefn=e,r.upfn=t,document.addEventListener("mousemove",e),document.addEventListener("mouseup",t)}function Vt(r){document.removeEventListener("mousemove",r.movefn),document.removeEventListener("mouseup",r.upfn),r.movefn=null,r.upfn=null}const iu=window.ShadyDOM&&window.ShadyDOM.noPatch?window.ShadyDOM.composedPath:r=>r.composedPath&&r.composedPath()||[],jn={},_t=[];function wg(r,e){let t=document.elementFromPoint(r,e),i=t;for(;i&&i.shadowRoot&&!window.ShadyDOM;){const o=i;if(i=i.shadowRoot.elementFromPoint(r,e),o===i)break;i&&(t=i)}return t}function at(r){const e=iu(r);return e.length>0?e[0]:r.target}function xg(r){const e=r.type,t=r.currentTarget[cn];if(!t)return;const i=t[e];if(!i)return;if(!r[Co]&&(r[Co]={},e.startsWith("touch"))){const n=r.changedTouches[0];if(e==="touchstart"&&r.touches.length===1&&(qe.touch.id=n.identifier),qe.touch.id!==n.identifier)return;eu||(e==="touchstart"||e==="touchmove")&&Cg(r)}const o=r[Co];if(!o.skip){for(let n=0,a;n<_t.length;n++)a=_t[n],i[a.name]&&!o[a.name]&&a.flow&&a.flow.start.indexOf(r.type)>-1&&a.reset&&a.reset();for(let n=0,a;n<_t.length;n++)a=_t[n],i[a.name]&&!o[a.name]&&(o[a.name]=!0,a[e](r))}}function Cg(r){const e=r.changedTouches[0],t=r.type;if(t==="touchstart")qe.touch.x=e.clientX,qe.touch.y=e.clientY,qe.touch.scrollDecided=!1;else if(t==="touchmove"){if(qe.touch.scrollDecided)return;qe.touch.scrollDecided=!0;const i=yg(r);let o=!1;const n=Math.abs(qe.touch.x-e.clientX),a=Math.abs(qe.touch.y-e.clientY);r.cancelable&&(i==="none"?o=!0:i==="pan-x"?o=a>n:i==="pan-y"&&(o=n>a)),o?r.preventDefault():zi("track")}}function Re(r,e,t){return jn[e]?(Eg(r,e,t),!0):!1}function Eg(r,e,t){const i=jn[e],o=i.deps,n=i.name;let a=r[cn];a||(r[cn]=a={});for(let s=0,l,d;s<o.length;s++)l=o[s],!(vg&&tu(l)&&l!=="click")&&(d=a[l],d||(a[l]=d={_count:0}),d._count===0&&r.addEventListener(l,xg,void 0),d[n]=(d[n]||0)+1,d._count=(d._count||0)+1);r.addEventListener(e,t),i.touchAction&&ou(r,i.touchAction)}function qn(r){_t.push(r),r.emits.forEach(e=>{jn[e]=r})}function Tg(r){for(let e=0,t;e<_t.length;e++){t=_t[e];for(let i=0,o;i<t.emits.length;i++)if(o=t.emits[i],o===r)return t}return null}function ou(r,e){eu&&r instanceof HTMLElement&&Li.run(()=>{r.style.touchAction=e}),r[hn]=e}function Yn(r,e,t){const i=new Event(e,{bubbles:!0,cancelable:!0,composed:!0});if(i.detail=t,cg(r).dispatchEvent(i),i.defaultPrevented){const o=t.preventer||t.sourceEvent;o&&o.preventDefault&&o.preventDefault()}}function zi(r){const e=Tg(r);e.info&&(e.info.prevent=!0)}qn({name:"downup",deps:["mousedown","touchstart","touchend"],flow:{start:["mousedown","touchstart"],end:["mouseup","touchend"]},emits:["down","up"],info:{movefn:null,upfn:null},reset(){Vt(this.info)},mousedown(r){if(!vt(r))return;const e=at(r),t=this,i=n=>{vt(n)||(yr("up",e,n),Vt(t.info))},o=n=>{vt(n)&&yr("up",e,n),Vt(t.info)};ru(this.info,i,o),yr("down",e,r)},touchstart(r){yr("down",at(r),r.changedTouches[0],r)},touchend(r){yr("up",at(r),r.changedTouches[0],r)}});function yr(r,e,t,i){e&&Yn(e,r,{x:t.clientX,y:t.clientY,sourceEvent:t,preventer:i,prevent(o){return zi(o)}})}qn({name:"track",touchAction:"none",deps:["mousedown","touchstart","touchmove","touchend"],flow:{start:["mousedown","touchstart"],end:["mouseup","touchend"]},emits:["track"],info:{x:0,y:0,state:"start",started:!1,moves:[],addMove(r){this.moves.length>hg&&this.moves.shift(),this.moves.push(r)},movefn:null,upfn:null,prevent:!1},reset(){this.info.state="start",this.info.started=!1,this.info.moves=[],this.info.x=0,this.info.y=0,this.info.prevent=!1,Vt(this.info)},mousedown(r){if(!vt(r))return;const e=at(r),t=this,i=n=>{const a=n.clientX,s=n.clientY;Vs(t.info,a,s)&&(t.info.state=t.info.started?n.type==="mouseup"?"end":"track":"start",t.info.state==="start"&&zi("tap"),t.info.addMove({x:a,y:s}),vt(n)||(t.info.state="end",Vt(t.info)),e&&Eo(t.info,e,n),t.info.started=!0)},o=n=>{t.info.started&&i(n),Vt(t.info)};ru(this.info,i,o),this.info.x=r.clientX,this.info.y=r.clientY},touchstart(r){const e=r.changedTouches[0];this.info.x=e.clientX,this.info.y=e.clientY},touchmove(r){const e=at(r),t=r.changedTouches[0],i=t.clientX,o=t.clientY;Vs(this.info,i,o)&&(this.info.state==="start"&&zi("tap"),this.info.addMove({x:i,y:o}),Eo(this.info,e,t),this.info.state="track",this.info.started=!0)},touchend(r){const e=at(r),t=r.changedTouches[0];this.info.started&&(this.info.state="end",this.info.addMove({x:t.clientX,y:t.clientY}),Eo(this.info,e,t))}});function Vs(r,e,t){if(r.prevent)return!1;if(r.started)return!0;const i=Math.abs(r.x-e),o=Math.abs(r.y-t);return i>=$s||o>=$s}function Eo(r,e,t){if(!e)return;const i=r.moves[r.moves.length-2],o=r.moves[r.moves.length-1],n=o.x-r.x,a=o.y-r.y;let s,l=0;i&&(s=o.x-i.x,l=o.y-i.y),Yn(e,"track",{state:r.state,x:t.clientX,y:t.clientY,dx:n,dy:a,ddx:s,ddy:l,sourceEvent:t,hover(){return wg(t.clientX,t.clientY)}})}qn({name:"tap",deps:["mousedown","click","touchstart","touchend"],flow:{start:["mousedown","touchstart"],end:["click","touchend"]},emits:["tap"],info:{x:NaN,y:NaN,prevent:!1},reset(){this.info.x=NaN,this.info.y=NaN,this.info.prevent=!1},mousedown(r){vt(r)&&(this.info.x=r.clientX,this.info.y=r.clientY)},click(r){vt(r)&&Us(this.info,r)},touchstart(r){const e=r.changedTouches[0];this.info.x=e.clientX,this.info.y=e.clientY},touchend(r){Us(this.info,r.changedTouches[0],r)}});function Us(r,e,t){const i=Math.abs(e.clientX-r.x),o=Math.abs(e.clientY-r.y),n=at(t||e);!n||gg[n.localName]&&n.hasAttribute("disabled")||(isNaN(i)||isNaN(o)||i<=Fs&&o<=Fs||bg(e))&&(r.prevent||Yn(n,"tap",{x:e.clientX,y:e.clientY,sourceEvent:e,preventer:t}))}/**
|
|
1580
1580
|
* @license
|
|
1581
1581
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1582
1582
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1583
|
-
*/const or=
|
|
1583
|
+
*/const or=le(r=>class extends r{static get properties(){return{disabled:{type:Boolean,value:!1,observer:"_disabledChanged",reflectToAttribute:!0}}}_disabledChanged(e){this._setAriaDisabled(e)}_setAriaDisabled(e){e?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled")}click(){this.disabled||super.click()}});/**
|
|
1584
1584
|
* @license
|
|
1585
1585
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1586
1586
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1587
|
-
*/const
|
|
1587
|
+
*/const Ct=le(r=>class extends r{ready(){super.ready(),this.addEventListener("keydown",e=>{this._onKeyDown(e)}),this.addEventListener("keyup",e=>{this._onKeyUp(e)})}_onKeyDown(e){switch(e.key){case"Enter":this._onEnter(e);break;case"Escape":this._onEscape(e);break}}_onKeyUp(e){}_onEnter(e){}_onEscape(e){}});/**
|
|
1588
1588
|
* @license
|
|
1589
1589
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1590
1590
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1591
|
-
*/const Gn=r=>class extends or(
|
|
1591
|
+
*/const Gn=r=>class extends or(Ct(r)){get _activeKeys(){return[" "]}ready(){super.ready(),Re(this,"down",e=>{this._shouldSetActive(e)&&this._setActive(!0)}),Re(this,"up",()=>{this._setActive(!1)})}disconnectedCallback(){super.disconnectedCallback(),this._setActive(!1)}_shouldSetActive(e){return!this.disabled}_onKeyDown(e){super._onKeyDown(e),this._shouldSetActive(e)&&this._activeKeys.includes(e.key)&&(this._setActive(!0),document.addEventListener("keyup",t=>{this._activeKeys.includes(t.key)&&this._setActive(!1)},{once:!0}))}_setActive(e){this.toggleAttribute("active",e)}};/**
|
|
1592
1592
|
* @license
|
|
1593
1593
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1594
1594
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1595
|
-
*/let Xn=!1;window.addEventListener("keydown",()=>{Xn=!0},{capture:!0});window.addEventListener("mousedown",()=>{Xn=!1},{capture:!0});function pn(){let r=document.activeElement||document.body;for(;r.shadowRoot&&r.shadowRoot.activeElement;)r=r.shadowRoot.activeElement;return r}function Qi(){return Xn}function nu(r){const e=r.style;if(e.visibility==="hidden"||e.display==="none")return!0;const t=window.getComputedStyle(r);return t.visibility==="hidden"||t.display==="none"}function
|
|
1595
|
+
*/let Xn=!1;window.addEventListener("keydown",()=>{Xn=!0},{capture:!0});window.addEventListener("mousedown",()=>{Xn=!1},{capture:!0});function pn(){let r=document.activeElement||document.body;for(;r.shadowRoot&&r.shadowRoot.activeElement;)r=r.shadowRoot.activeElement;return r}function Qi(){return Xn}function nu(r){const e=r.style;if(e.visibility==="hidden"||e.display==="none")return!0;const t=window.getComputedStyle(r);return t.visibility==="hidden"||t.display==="none"}function Pg(r,e){const t=Math.max(r.tabIndex,0),i=Math.max(e.tabIndex,0);return t===0||i===0?i>t:t>i}function Ag(r,e){const t=[];for(;r.length>0&&e.length>0;)Pg(r[0],e[0])?t.push(e.shift()):t.push(r.shift());return t.concat(r,e)}function mn(r){const e=r.length;if(e<2)return r;const t=Math.ceil(e/2),i=mn(r.slice(0,t)),o=mn(r.slice(t));return Ag(i,o)}function fn(r){return r.offsetParent===null&&r.clientWidth===0&&r.clientHeight===0?!0:nu(r)}function Kn(r){return r.matches('[tabindex="-1"]')?!1:r.matches("input, select, textarea, button, object")?r.matches(":not([disabled])"):r.matches("a[href], area[href], iframe, [tabindex], [contentEditable]")}function Qn(r){return r.getRootNode().activeElement===r}function kg(r){if(!Kn(r))return-1;const e=r.getAttribute("tabindex")||0;return Number(e)}function au(r,e){if(r.nodeType!==Node.ELEMENT_NODE||nu(r))return!1;const t=r,i=kg(t);let o=i>0;i>=0&&e.push(t);let n=[];return t.localName==="slot"?n=t.assignedNodes({flatten:!0}):n=(t.shadowRoot||t).children,[...n].forEach(a=>{o=au(a,e)||o}),o}function Ig(r){const e=[];return au(r,e)?mn(e):e}/**
|
|
1596
1596
|
* @license
|
|
1597
1597
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1598
1598
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1599
|
-
*/const
|
|
1599
|
+
*/const Et=le(r=>class extends r{get _keyboardActive(){return Qi()}ready(){this.addEventListener("focusin",e=>{this._shouldSetFocus(e)&&this._setFocused(!0)}),this.addEventListener("focusout",e=>{this._shouldRemoveFocus(e)&&this._setFocused(!1)}),super.ready()}disconnectedCallback(){super.disconnectedCallback(),this.hasAttribute("focused")&&this._setFocused(!1)}_setFocused(e){this.toggleAttribute("focused",e),this.toggleAttribute("focus-ring",e&&this._keyboardActive)}_shouldSetFocus(e){return!0}_shouldRemoveFocus(e){return!0}});/**
|
|
1600
1600
|
* @license
|
|
1601
1601
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1602
1602
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -1604,35 +1604,35 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1604
1604
|
* @license
|
|
1605
1605
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1606
1606
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1607
|
-
*/const Ji=
|
|
1607
|
+
*/const Ji=le(r=>class extends Et(su(r)){static get properties(){return{autofocus:{type:Boolean},focusElement:{type:Object,readOnly:!0,observer:"_focusElementChanged"},_lastTabIndex:{value:0}}}constructor(){super(),this._boundOnBlur=this._onBlur.bind(this),this._boundOnFocus=this._onFocus.bind(this)}ready(){super.ready(),this.autofocus&&!this.disabled&&requestAnimationFrame(()=>{this.focus(),this.setAttribute("focus-ring","")})}focus(){this.focusElement&&!this.disabled&&this.focusElement.focus()}blur(){this.focusElement&&this.focusElement.blur()}click(){this.focusElement&&!this.disabled&&this.focusElement.click()}_focusElementChanged(e,t){e?(e.disabled=this.disabled,this._addFocusListeners(e),this.__forwardTabIndex(this.tabindex)):t&&this._removeFocusListeners(t)}_addFocusListeners(e){e.addEventListener("blur",this._boundOnBlur),e.addEventListener("focus",this._boundOnFocus)}_removeFocusListeners(e){e.removeEventListener("blur",this._boundOnBlur),e.removeEventListener("focus",this._boundOnFocus)}_onFocus(e){e.stopPropagation(),this.dispatchEvent(new Event("focus"))}_onBlur(e){e.stopPropagation(),this.dispatchEvent(new Event("blur"))}_shouldSetFocus(e){return e.target===this.focusElement}_shouldRemoveFocus(e){return e.target===this.focusElement}_disabledChanged(e,t){super._disabledChanged(e,t),this.focusElement&&(this.focusElement.disabled=e),e&&this.blur()}_tabindexChanged(e){this.__forwardTabIndex(e)}__forwardTabIndex(e){e!==void 0&&this.focusElement&&(this.focusElement.tabIndex=e,e!==-1&&(this.tabindex=void 0)),this.disabled&&e&&(e!==-1&&(this._lastTabIndex=e),this.tabindex=void 0)}});/**
|
|
1608
1608
|
* @license
|
|
1609
1609
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1610
1610
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1611
|
-
*/const Jn=
|
|
1611
|
+
*/const Jn=le(r=>class extends r{static get properties(){return{stateTarget:{type:Object,observer:"_stateTargetChanged"}}}static get delegateAttrs(){return[]}static get delegateProps(){return[]}ready(){super.ready(),this._createDelegateAttrsObserver(),this._createDelegatePropsObserver()}_stateTargetChanged(e){e&&(this._ensureAttrsDelegated(),this._ensurePropsDelegated())}_createDelegateAttrsObserver(){this._createMethodObserver(`_delegateAttrsChanged(${this.constructor.delegateAttrs.join(", ")})`)}_createDelegatePropsObserver(){this._createMethodObserver(`_delegatePropsChanged(${this.constructor.delegateProps.join(", ")})`)}_ensureAttrsDelegated(){this.constructor.delegateAttrs.forEach(e=>{this._delegateAttribute(e,this[e])})}_ensurePropsDelegated(){this.constructor.delegateProps.forEach(e=>{this._delegateProperty(e,this[e])})}_delegateAttrsChanged(...e){this.constructor.delegateAttrs.forEach((t,i)=>{this._delegateAttribute(t,e[i])})}_delegatePropsChanged(...e){this.constructor.delegateProps.forEach((t,i)=>{this._delegateProperty(t,e[i])})}_delegateAttribute(e,t){this.stateTarget&&(e==="invalid"&&this._delegateAttribute("aria-invalid",t?"true":!1),typeof t=="boolean"?this.stateTarget.toggleAttribute(e,t):t?this.stateTarget.setAttribute(e,t):this.stateTarget.removeAttribute(e))}_delegateProperty(e,t){this.stateTarget&&(this.stateTarget[e]=t)}});/**
|
|
1612
1612
|
* @license
|
|
1613
1613
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1614
1614
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1615
|
-
*/const
|
|
1615
|
+
*/const Yr=le(r=>class extends r{static get properties(){return{inputElement:{type:Object,readOnly:!0,observer:"_inputElementChanged"},type:{type:String,readOnly:!0},value:{type:String,value:"",observer:"_valueChanged",notify:!0,sync:!0},_hasInputValue:{type:Boolean,value:!1,observer:"_hasInputValueChanged"}}}constructor(){super(),this._boundOnInput=this.__onInput.bind(this),this._boundOnChange=this._onChange.bind(this)}get _hasValue(){return this.value!=null&&this.value!==""}get _inputElementValueProperty(){return"value"}get _inputElementValue(){return this.inputElement?this.inputElement[this._inputElementValueProperty]:void 0}set _inputElementValue(e){this.inputElement&&(this.inputElement[this._inputElementValueProperty]=e)}clear(){this._hasInputValue=!1,this.value="",this._inputElementValue=""}_addInputListeners(e){e.addEventListener("input",this._boundOnInput),e.addEventListener("change",this._boundOnChange)}_removeInputListeners(e){e.removeEventListener("input",this._boundOnInput),e.removeEventListener("change",this._boundOnChange)}_forwardInputValue(e){this.inputElement&&(this._inputElementValue=e!=null?e:"")}_inputElementChanged(e,t){e?this._addInputListeners(e):t&&this._removeInputListeners(t)}_hasInputValueChanged(e,t){(e||t)&&this.dispatchEvent(new CustomEvent("has-input-value-changed"))}__onInput(e){this._setHasInputValue(e),this._onInput(e)}_onInput(e){const t=e.composedPath()[0];this.__userInput=e.isTrusted,this.value=t.value,this.__userInput=!1}_onChange(e){}_toggleHasValue(e){this.toggleAttribute("has-value",e)}_valueChanged(e,t){this._toggleHasValue(this._hasValue),!(e===""&&t===void 0)&&(this.__userInput||this._forwardInputValue(e))}_setHasInputValue(e){const t=e.composedPath()[0];this._hasInputValue=t.value.length>0}});/**
|
|
1616
1616
|
* @license
|
|
1617
1617
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1618
1618
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1619
|
-
*/const
|
|
1619
|
+
*/const Sg=le(r=>class extends Jn(or(Yr(r))){static get properties(){return{checked:{type:Boolean,value:!1,notify:!0,reflectToAttribute:!0}}}static get delegateProps(){return[...super.delegateProps,"checked"]}_onChange(e){const t=e.target;this._toggleChecked(t.checked)}_toggleChecked(e){this.checked=e}});/**
|
|
1620
1620
|
* @license
|
|
1621
1621
|
* Copyright (c) 2023 - 2024 Vaadin Ltd.
|
|
1622
1622
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1623
|
-
*/const To=new Map;function Zn(r){return To.has(r)||To.set(r,new WeakMap),To.get(r)}function lu(r,e){r&&r.removeAttribute(e)}function du(r,e){if(!r||!e)return;const t=Zn(e);if(t.has(r))return;const i=Un(r.getAttribute(e));t.set(r,new Set(i))}function
|
|
1623
|
+
*/const To=new Map;function Zn(r){return To.has(r)||To.set(r,new WeakMap),To.get(r)}function lu(r,e){r&&r.removeAttribute(e)}function du(r,e){if(!r||!e)return;const t=Zn(e);if(t.has(r))return;const i=Un(r.getAttribute(e));t.set(r,new Set(i))}function Dg(r,e){if(!r||!e)return;const t=Zn(e),i=t.get(r);!i||i.size===0?r.removeAttribute(e):Zd(r,e,Ki(i)),t.delete(r)}function Ut(r,e,t={newId:null,oldId:null,fromUser:!1}){if(!r||!e)return;const{newId:i,oldId:o,fromUser:n}=t,a=Zn(e),s=a.get(r);if(!n&&s){o&&s.delete(o),i&&s.add(i);return}n&&(s?i||a.delete(r):du(r,e),lu(r,e)),lg(r,e,o);const l=i||Ki(s);l&&Zd(r,e,l)}function Og(r,e){du(r,e),lu(r,e)}/**
|
|
1624
1624
|
* @license
|
|
1625
1625
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1626
1626
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1627
|
-
*/class
|
|
1627
|
+
*/class Ng{constructor(e){this.host=e,this.__required=!1}setTarget(e){this.__target=e,this.__setAriaRequiredAttribute(this.__required),this.__setLabelIdToAriaAttribute(this.__labelId,this.__labelId),this.__labelIdFromUser!=null&&this.__setLabelIdToAriaAttribute(this.__labelIdFromUser,this.__labelIdFromUser,!0),this.__setErrorIdToAriaAttribute(this.__errorId),this.__setHelperIdToAriaAttribute(this.__helperId),this.setAriaLabel(this.__label)}setRequired(e){this.__setAriaRequiredAttribute(e),this.__required=e}setAriaLabel(e){this.__setAriaLabelToAttribute(e),this.__label=e}setLabelId(e,t=!1){const i=t?this.__labelIdFromUser:this.__labelId;this.__setLabelIdToAriaAttribute(e,i,t),t?this.__labelIdFromUser=e:this.__labelId=e}setErrorId(e){this.__setErrorIdToAriaAttribute(e,this.__errorId),this.__errorId=e}setHelperId(e){this.__setHelperIdToAriaAttribute(e,this.__helperId),this.__helperId=e}__setAriaLabelToAttribute(e){this.__target&&(e?(Og(this.__target,"aria-labelledby"),this.__target.setAttribute("aria-label",e)):this.__label&&(Dg(this.__target,"aria-labelledby"),this.__target.removeAttribute("aria-label")))}__setLabelIdToAriaAttribute(e,t,i){Ut(this.__target,"aria-labelledby",{newId:e,oldId:t,fromUser:i})}__setErrorIdToAriaAttribute(e,t){Ut(this.__target,"aria-describedby",{newId:e,oldId:t,fromUser:!1})}__setHelperIdToAriaAttribute(e,t){Ut(this.__target,"aria-describedby",{newId:e,oldId:t,fromUser:!1})}__setAriaRequiredAttribute(e){this.__target&&(["input","textarea"].includes(this.__target.localName)||(e?this.__target.setAttribute("aria-required","true"):this.__target.removeAttribute("aria-required")))}}/**
|
|
1628
1628
|
* @license
|
|
1629
1629
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1630
1630
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1631
|
-
*/const
|
|
1631
|
+
*/const Ue=le(r=>typeof r.prototype.addController=="function"?r:class extends r{constructor(){super(),this.__controllers=new Set}connectedCallback(){super.connectedCallback(),this.__controllers.forEach(e=>{e.hostConnected&&e.hostConnected()})}disconnectedCallback(){super.disconnectedCallback(),this.__controllers.forEach(e=>{e.hostDisconnected&&e.hostDisconnected()})}addController(e){this.__controllers.add(e),this.$!==void 0&&this.isConnected&&e.hostConnected&&e.hostConnected()}removeController(e){this.__controllers.delete(e)}});/**
|
|
1632
1632
|
* @license
|
|
1633
1633
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
1634
1634
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1635
|
-
*/const
|
|
1635
|
+
*/const ze=document.createElement("div");ze.style.position="fixed";ze.style.clip="rect(0px, 0px, 0px, 0px)";ze.setAttribute("aria-live","polite");document.body.appendChild(ze);let li;function yi(r,e={}){const t=e.mode||"polite",i=e.timeout===void 0?150:e.timeout;t==="alert"?(ze.removeAttribute("aria-live"),ze.removeAttribute("role"),li=Se.debounce(li,Fr,()=>{ze.setAttribute("role","alert")})):(li&&li.cancel(),ze.removeAttribute("role"),ze.setAttribute("aria-live",t)),ze.textContent="",setTimeout(()=>{ze.textContent=r},i)}/**
|
|
1636
1636
|
* @license
|
|
1637
1637
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
1638
1638
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -1640,11 +1640,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1640
1640
|
* @license
|
|
1641
1641
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1642
1642
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1643
|
-
*/class
|
|
1643
|
+
*/class Mg extends ea{constructor(e){super(e,"error-message","div")}setErrorMessage(e){this.errorMessage=e,this.updateDefaultNode(this.node)}setInvalid(e){this.invalid=e,this.updateDefaultNode(this.node)}initAddedNode(e){e!==this.defaultNode&&this.initCustomNode(e)}initNode(e){this.updateDefaultNode(e)}initCustomNode(e){e.textContent&&!this.errorMessage&&(this.errorMessage=e.textContent.trim()),super.initCustomNode(e)}restoreDefaultNode(){this.attachDefaultNode()}updateDefaultNode(e){const{errorMessage:t,invalid:i}=this,o=!!(i&&t&&t.trim()!=="");e&&(e.textContent=o?t:"",e.hidden=!o,o&&yi(t,{mode:"assertive"})),super.updateDefaultNode(e)}}/**
|
|
1644
1644
|
* @license
|
|
1645
1645
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1646
1646
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1647
|
-
*/class
|
|
1647
|
+
*/class Bg extends ea{constructor(e){super(e,"helper",null)}setHelperText(e){this.helperText=e,this.getSlotChild()||this.restoreDefaultNode(),this.node===this.defaultNode&&this.updateDefaultNode(this.node)}restoreDefaultNode(){const{helperText:e}=this;if(e&&e.trim()!==""){this.tagName="div";const t=this.attachDefaultNode();this.observeNode(t)}}updateDefaultNode(e){e&&(e.textContent=this.helperText),super.updateDefaultNode(e)}initCustomNode(e){super.initCustomNode(e),this.observeNode(e)}}/**
|
|
1648
1648
|
* @license
|
|
1649
1649
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1650
1650
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -1652,31 +1652,31 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1652
1652
|
* @license
|
|
1653
1653
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1654
1654
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1655
|
-
*/const
|
|
1655
|
+
*/const Lg=le(r=>class extends Ue(r){static get properties(){return{label:{type:String,observer:"_labelChanged"}}}constructor(){super(),this._labelController=new uu(this),this._labelController.addEventListener("slot-content-changed",e=>{this.toggleAttribute("has-label",e.detail.hasContent)})}get _labelId(){const e=this._labelNode;return e&&e.id}get _labelNode(){return this._labelController.node}ready(){super.ready(),this.addController(this._labelController)}_labelChanged(e){this._labelController.setLabel(e)}});/**
|
|
1656
1656
|
* @license
|
|
1657
1657
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1658
1658
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1659
|
-
*/const ta=
|
|
1659
|
+
*/const ta=le(r=>class extends r{static get properties(){return{invalid:{type:Boolean,reflectToAttribute:!0,notify:!0,value:!1},required:{type:Boolean,reflectToAttribute:!0}}}validate(){const e=this.checkValidity();return this._setInvalid(!e),this.dispatchEvent(new CustomEvent("validated",{detail:{valid:e}})),e}checkValidity(){return!this.required||!!this.value}_setInvalid(e){this._shouldSetInvalid(e)&&(this.invalid=e)}_shouldSetInvalid(e){return!0}});/**
|
|
1660
1660
|
* @license
|
|
1661
1661
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1662
1662
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1663
|
-
*/const Zi=r=>class extends ta(
|
|
1663
|
+
*/const Zi=r=>class extends ta(Lg(Ue(r))){static get properties(){return{ariaTarget:{type:Object,observer:"_ariaTargetChanged"},errorMessage:{type:String,observer:"_errorMessageChanged"},helperText:{type:String,observer:"_helperTextChanged"},accessibleName:{type:String,observer:"_accessibleNameChanged"},accessibleNameRef:{type:String,observer:"_accessibleNameRefChanged"}}}static get observers(){return["_invalidChanged(invalid)","_requiredChanged(required)"]}constructor(){super(),this._fieldAriaController=new Ng(this),this._helperController=new Bg(this),this._errorController=new Mg(this),this._errorController.addEventListener("slot-content-changed",e=>{this.toggleAttribute("has-error-message",e.detail.hasContent)}),this._labelController.addEventListener("slot-content-changed",e=>{const{hasContent:t,node:i}=e.detail;this.__labelChanged(t,i)}),this._helperController.addEventListener("slot-content-changed",e=>{const{hasContent:t,node:i}=e.detail;this.toggleAttribute("has-helper",t),this.__helperChanged(t,i)})}get _errorNode(){return this._errorController.node}get _helperNode(){return this._helperController.node}ready(){super.ready(),this.addController(this._fieldAriaController),this.addController(this._helperController),this.addController(this._errorController)}__helperChanged(e,t){e?this._fieldAriaController.setHelperId(t.id):this._fieldAriaController.setHelperId(null)}_accessibleNameChanged(e){this._fieldAriaController.setAriaLabel(e)}_accessibleNameRefChanged(e){this._fieldAriaController.setLabelId(e,!0)}__labelChanged(e,t){e?this._fieldAriaController.setLabelId(t.id):this._fieldAriaController.setLabelId(null)}_errorMessageChanged(e){this._errorController.setErrorMessage(e)}_helperTextChanged(e){this._helperController.setHelperText(e)}_ariaTargetChanged(e){e&&this._fieldAriaController.setTarget(e)}_requiredChanged(e){this._fieldAriaController.setRequired(e)}_invalidChanged(e){this._errorController.setInvalid(e),setTimeout(()=>{if(e){const t=this._errorNode;this._fieldAriaController.setErrorId(t&&t.id)}else this._fieldAriaController.setErrorId(null)})}};/**
|
|
1664
1664
|
* @license
|
|
1665
1665
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1666
1666
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1667
|
-
*/class
|
|
1667
|
+
*/class Gr extends xe{constructor(e,t,i={}){const{uniqueIdPrefix:o}=i;super(e,"input","input",{initializer:(n,a)=>{a.value&&(n.value=a.value),a.type&&n.setAttribute("type",a.type),n.id=this.defaultId,typeof t=="function"&&t(n)},useUniqueId:!0,uniqueIdPrefix:o})}}/**
|
|
1668
1668
|
* @license
|
|
1669
1669
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1670
1670
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1671
|
-
*/class
|
|
1671
|
+
*/class Xr{constructor(e,t){this.input=e,this.__preventDuplicateLabelClick=this.__preventDuplicateLabelClick.bind(this),t.addEventListener("slot-content-changed",i=>{this.__initLabel(i.detail.node)}),this.__initLabel(t.node)}__initLabel(e){e&&(e.addEventListener("click",this.__preventDuplicateLabelClick),this.input&&e.setAttribute("for",this.input.id))}__preventDuplicateLabelClick(){const e=t=>{t.stopImmediatePropagation(),this.input.removeEventListener("click",e)};this.input.addEventListener("click",e)}}/**
|
|
1672
1672
|
* @license
|
|
1673
1673
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
1674
1674
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1675
|
-
*/const
|
|
1675
|
+
*/const zg=r=>class extends Zi(Sg(Ji(Gn(r)))){static get properties(){return{indeterminate:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0},name:{type:String,value:""},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},tabindex:{type:Number,value:0,reflectToAttribute:!0}}}static get observers(){return["__readonlyChanged(readonly, inputElement)"]}static get delegateProps(){return[...super.delegateProps,"indeterminate"]}static get delegateAttrs(){return[...super.delegateAttrs,"name","invalid","required"]}constructor(){super(),this._setType("checkbox"),this._boundOnInputClick=this._onInputClick.bind(this),this.value="on"}ready(){super.ready(),this.addController(new Gr(this,e=>{this._setInputElement(e),this._setFocusElement(e),this.stateTarget=e,this.ariaTarget=e})),this.addController(new Xr(this.inputElement,this._labelController)),this._createMethodObserver("_checkedChanged(checked)")}_shouldSetActive(e){return this.readonly||e.target.localName==="a"||e.target===this._helperNode||e.target===this._errorNode?!1:super._shouldSetActive(e)}_addInputListeners(e){super._addInputListeners(e),e.addEventListener("click",this._boundOnInputClick)}_removeInputListeners(e){super._removeInputListeners(e),e.removeEventListener("click",this._boundOnInputClick)}_onInputClick(e){this.readonly&&e.preventDefault()}__readonlyChanged(e,t){t&&(e?t.setAttribute("aria-readonly","true"):t.removeAttribute("aria-readonly"))}_toggleChecked(e){this.indeterminate&&(this.indeterminate=!1),super._toggleChecked(e)}checkValidity(){return!this.required||!!this.checked}_setFocused(e){super._setFocused(e),!e&&document.hasFocus()&&this.validate()}_checkedChanged(e){(e||this.__oldChecked)&&this.validate(),this.__oldChecked=e}_requiredChanged(e){super._requiredChanged(e),e===!1&&this.validate()}_onRequiredIndicatorClick(){this._labelNode.click()}};/**
|
|
1676
1676
|
* @license
|
|
1677
1677
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
1678
1678
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1679
|
-
*/const
|
|
1679
|
+
*/const Hg=v`
|
|
1680
1680
|
:host {
|
|
1681
1681
|
display: inline-block;
|
|
1682
1682
|
}
|
|
@@ -1768,7 +1768,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1768
1768
|
* @license
|
|
1769
1769
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
1770
1770
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1771
|
-
*/
|
|
1771
|
+
*/x("vaadin-checkbox",Hg,{moduleId:"vaadin-checkbox-styles"});class Rg extends zg(Ne(X(H))){static get is(){return"vaadin-checkbox"}static get template(){return z`
|
|
1772
1772
|
<div class="vaadin-checkbox-container">
|
|
1773
1773
|
<div part="checkbox" aria-hidden="true"></div>
|
|
1774
1774
|
<slot name="input"></slot>
|
|
@@ -1784,7 +1784,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1784
1784
|
</div>
|
|
1785
1785
|
</div>
|
|
1786
1786
|
<slot name="tooltip"></slot>
|
|
1787
|
-
`}ready(){super.ready(),this._tooltipController=new
|
|
1787
|
+
`}ready(){super.ready(),this._tooltipController=new Qe(this),this._tooltipController.setAriaTarget(this.inputElement),this.addController(this._tooltipController)}}k(Rg);/**
|
|
1788
1788
|
* @license
|
|
1789
1789
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
1790
1790
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -1960,7 +1960,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1960
1960
|
margin-left: 0;
|
|
1961
1961
|
margin-right: calc(var(--lumo-border-radius-m) / 4);
|
|
1962
1962
|
}
|
|
1963
|
-
`;
|
|
1963
|
+
`;x("",ra,{moduleId:"lumo-required-field"});const Fg=v`
|
|
1964
1964
|
:host {
|
|
1965
1965
|
color: var(--lumo-body-text-color);
|
|
1966
1966
|
font-size: var(--lumo-font-size-m);
|
|
@@ -2003,15 +2003,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2003
2003
|
color: var(--lumo-secondary-text-color);
|
|
2004
2004
|
}
|
|
2005
2005
|
}
|
|
2006
|
-
`;
|
|
2006
|
+
`;x("vaadin-checkbox-group",[ra,cu,Fg],{moduleId:"lumo-checkbox-group"});/**
|
|
2007
2007
|
* @license
|
|
2008
2008
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
2009
2009
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
2010
|
-
*/const
|
|
2010
|
+
*/const $g=r=>class extends Zi(Et(or(r))){static get properties(){return{value:{type:Array,value:()=>[],notify:!0,sync:!0,observer:"__valueChanged"},readonly:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"__readonlyChanged"}}}constructor(){super(),this.__registerCheckbox=this.__registerCheckbox.bind(this),this.__unregisterCheckbox=this.__unregisterCheckbox.bind(this),this.__onCheckboxCheckedChanged=this.__onCheckboxCheckedChanged.bind(this),this._tooltipController=new Qe(this),this._tooltipController.addEventListener("tooltip-changed",e=>{const t=e.detail.node;if(t&&t.isConnected){const i=this.__checkboxes.map(o=>o.inputElement);this._tooltipController.setAriaTarget(i)}else this._tooltipController.setAriaTarget([])})}get __checkboxes(){return this.__filterCheckboxes([...this.children])}ready(){super.ready(),this.ariaTarget=this,this.setAttribute("role","group");const e=this.shadowRoot.querySelector("slot:not([name])");this._observer=new Wn(e,({addedNodes:t,removedNodes:i})=>{const o=this.__filterCheckboxes(t),n=this.__filterCheckboxes(i);o.forEach(this.__registerCheckbox),n.forEach(this.__unregisterCheckbox);const a=this.__checkboxes.map(s=>s.inputElement);this._tooltipController.setAriaTarget(a),this.__warnOfCheckboxesWithoutValue(o)}),this.addController(this._tooltipController)}checkValidity(){return!this.required||!!(this.value&&this.value.length>0)}__filterCheckboxes(e){return e.filter(t=>t.nodeType===Node.ELEMENT_NODE&&t.localName==="vaadin-checkbox")}__warnOfCheckboxesWithoutValue(e){e.some(t=>{const{value:i}=t;return!t.hasAttribute("value")&&(!i||i==="on")})&&console.warn("Please provide the value attribute to all the checkboxes inside the checkbox group.")}__registerCheckbox(e){e.addEventListener("checked-changed",this.__onCheckboxCheckedChanged),this.disabled&&(e.disabled=!0),this.readonly&&(e.readonly=!0),e.checked?this.__addCheckboxToValue(e.value):this.value&&this.value.includes(e.value)&&(e.checked=!0)}__unregisterCheckbox(e){e.removeEventListener("checked-changed",this.__onCheckboxCheckedChanged),e.checked&&this.__removeCheckboxFromValue(e.value)}_disabledChanged(e,t){super._disabledChanged(e,t),!(!e&&t===void 0)&&t!==e&&this.__checkboxes.forEach(i=>{i.disabled=e})}__addCheckboxToValue(e){this.value?this.value.includes(e)||(this.value=[...this.value,e]):this.value=[e]}__removeCheckboxFromValue(e){this.value&&this.value.includes(e)&&(this.value=this.value.filter(t=>t!==e))}__onCheckboxCheckedChanged(e){const t=e.target;t.checked?this.__addCheckboxToValue(t.value):this.__removeCheckboxFromValue(t.value)}__valueChanged(e,t){e&&e.length===0&&t===void 0||(this.toggleAttribute("has-value",e&&e.length>0),this.__checkboxes.forEach(i=>{i.checked=e&&e.includes(i.value)}),t!==void 0&&this.validate())}__readonlyChanged(e,t){(e||t)&&this.__checkboxes.forEach(i=>{i.readonly=e})}_shouldRemoveFocus(e){return!this.contains(e.relatedTarget)}_setFocused(e){super._setFocused(e),!e&&document.hasFocus()&&this.validate()}};/**
|
|
2011
2011
|
* @license
|
|
2012
2012
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
2013
2013
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
2014
|
-
*/const
|
|
2014
|
+
*/const Vg=v`
|
|
2015
2015
|
:host {
|
|
2016
2016
|
display: inline-flex;
|
|
2017
2017
|
}
|
|
@@ -2044,7 +2044,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2044
2044
|
* @license
|
|
2045
2045
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
2046
2046
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
2047
|
-
*/
|
|
2047
|
+
*/x("vaadin-checkbox-group",Vg,{moduleId:"vaadin-checkbox-group-styles"});class Ug extends $g(Ne(X(H))){static get is(){return"vaadin-checkbox-group"}static get template(){return z`
|
|
2048
2048
|
<div class="vaadin-group-field-container">
|
|
2049
2049
|
<div part="label">
|
|
2050
2050
|
<slot name="label"></slot>
|
|
@@ -2065,7 +2065,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2065
2065
|
</div>
|
|
2066
2066
|
|
|
2067
2067
|
<slot name="tooltip"></slot>
|
|
2068
|
-
`}}
|
|
2068
|
+
`}}k(Ug);/**
|
|
2069
2069
|
* @license
|
|
2070
2070
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
2071
2071
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -2134,7 +2134,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2134
2134
|
opacity: 1;
|
|
2135
2135
|
}
|
|
2136
2136
|
}
|
|
2137
|
-
`;
|
|
2137
|
+
`;x("",nr,{moduleId:"lumo-overlay"});/**
|
|
2138
2138
|
* @license
|
|
2139
2139
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
2140
2140
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -2168,7 +2168,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2168
2168
|
opacity: 0;
|
|
2169
2169
|
}
|
|
2170
2170
|
}
|
|
2171
|
-
`;
|
|
2171
|
+
`;x("",eo,{moduleId:"lumo-menu-overlay-core"});const Wg=v`
|
|
2172
2172
|
/* Small viewport (bottom sheet) styles */
|
|
2173
2173
|
/* Use direct media queries instead of the state attributes ([phone] and [fullscreen]) provided by the elements */
|
|
2174
2174
|
@media (max-width: 450px), (max-height: 450px) {
|
|
@@ -2230,7 +2230,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2230
2230
|
transform: translateY(150%);
|
|
2231
2231
|
}
|
|
2232
2232
|
}
|
|
2233
|
-
`,ia=[nr,eo,
|
|
2233
|
+
`,ia=[nr,eo,Wg];x("",ia,{moduleId:"lumo-menu-overlay"});const jg=v`
|
|
2234
2234
|
[part='overlay'] {
|
|
2235
2235
|
/*
|
|
2236
2236
|
Width:
|
|
@@ -2275,7 +2275,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2275
2275
|
max-height: 70vh;
|
|
2276
2276
|
}
|
|
2277
2277
|
}
|
|
2278
|
-
`;
|
|
2278
|
+
`;x("vaadin-date-picker-overlay",[ia,jg],{moduleId:"lumo-date-picker-overlay"});const hu=v`
|
|
2279
2279
|
:host {
|
|
2280
2280
|
/* Sizing */
|
|
2281
2281
|
--lumo-button-size: var(--lumo-size-m);
|
|
@@ -2551,7 +2551,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2551
2551
|
margin-left: 0;
|
|
2552
2552
|
margin-right: 0;
|
|
2553
2553
|
}
|
|
2554
|
-
`;
|
|
2554
|
+
`;x("vaadin-button",hu,{moduleId:"lumo-button"});x("vaadin-date-picker-year",v`
|
|
2555
2555
|
:host([current]) [part='year-number'] {
|
|
2556
2556
|
color: var(--lumo-primary-text-color);
|
|
2557
2557
|
}
|
|
@@ -2575,7 +2575,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2575
2575
|
color: var(--lumo-disabled-text-color);
|
|
2576
2576
|
content: '\\2022';
|
|
2577
2577
|
}
|
|
2578
|
-
`,{moduleId:"lumo-date-picker-year"});
|
|
2578
|
+
`,{moduleId:"lumo-date-picker-year"});x("vaadin-date-picker-overlay-content",v`
|
|
2579
2579
|
:host {
|
|
2580
2580
|
position: relative;
|
|
2581
2581
|
/* Background for the year scroller, placed here as we are using a mask image on the actual years part */
|
|
@@ -2725,7 +2725,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2725
2725
|
padding-left: 50px;
|
|
2726
2726
|
}
|
|
2727
2727
|
}
|
|
2728
|
-
`,{moduleId:"lumo-date-picker-overlay-content"});
|
|
2728
|
+
`,{moduleId:"lumo-date-picker-overlay-content"});x("vaadin-month-calendar",v`
|
|
2729
2729
|
:host {
|
|
2730
2730
|
-moz-user-select: none;
|
|
2731
2731
|
-webkit-user-select: none;
|
|
@@ -2872,7 +2872,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
2872
2872
|
:host([disabled]) * {
|
|
2873
2873
|
color: var(--lumo-disabled-text-color) !important;
|
|
2874
2874
|
}
|
|
2875
|
-
`,{moduleId:"lumo-month-calendar"});
|
|
2875
|
+
`,{moduleId:"lumo-month-calendar"});x("vaadin-input-container",v`
|
|
2876
2876
|
:host {
|
|
2877
2877
|
background: var(--_background);
|
|
2878
2878
|
padding: 0 calc(0.375em + var(--_input-container-radius) / 4 - 1px);
|
|
@@ -3081,11 +3081,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3081
3081
|
font-family: 'lumo-icons';
|
|
3082
3082
|
display: block;
|
|
3083
3083
|
}
|
|
3084
|
-
`;
|
|
3084
|
+
`;x("",oa,{moduleId:"lumo-field-button"});/**
|
|
3085
3085
|
* @license
|
|
3086
3086
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3087
3087
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3088
|
-
*/const
|
|
3088
|
+
*/const qg=v`
|
|
3089
3089
|
:host {
|
|
3090
3090
|
--lumo-text-field-size: var(--lumo-size-m);
|
|
3091
3091
|
color: var(--vaadin-input-field-value-color, var(--lumo-body-text-color));
|
|
@@ -3216,7 +3216,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3216
3216
|
[part='clear-button']::before {
|
|
3217
3217
|
content: var(--lumo-icons-cross);
|
|
3218
3218
|
}
|
|
3219
|
-
`,
|
|
3219
|
+
`,Tt=[ra,oa,cu,qg];x("",Tt,{moduleId:"lumo-input-field-shared-styles"});const Yg=v`
|
|
3220
3220
|
[part='toggle-button']::before {
|
|
3221
3221
|
content: var(--lumo-icons-calendar);
|
|
3222
3222
|
}
|
|
@@ -3238,15 +3238,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3238
3238
|
:host([dir='rtl']) [part='input-field'] ::slotted(input:placeholder-shown) {
|
|
3239
3239
|
--_lumo-text-field-overflow-mask-image: none;
|
|
3240
3240
|
}
|
|
3241
|
-
`;
|
|
3241
|
+
`;x("vaadin-date-picker",[Tt,Yg],{moduleId:"lumo-date-picker"});/**
|
|
3242
3242
|
* @license
|
|
3243
3243
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3244
3244
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3245
|
-
*/const
|
|
3245
|
+
*/const Gg=r=>class extends r{static get properties(){return{disabled:{type:Boolean,reflectToAttribute:!0},readonly:{type:Boolean,reflectToAttribute:!0},invalid:{type:Boolean,reflectToAttribute:!0}}}ready(){super.ready(),this.addEventListener("pointerdown",e=>{e.target===this&&e.preventDefault()}),this.addEventListener("click",e=>{e.target===this&&this.shadowRoot.querySelector("slot:not([name])").assignedNodes({flatten:!0}).forEach(t=>t.focus&&t.focus())})}};/**
|
|
3246
3246
|
* @license
|
|
3247
3247
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3248
3248
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3249
|
-
*/const
|
|
3249
|
+
*/const Xg=v`
|
|
3250
3250
|
:host {
|
|
3251
3251
|
display: flex;
|
|
3252
3252
|
align-items: center;
|
|
@@ -3315,15 +3315,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3315
3315
|
* @license
|
|
3316
3316
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3317
3317
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3318
|
-
*/
|
|
3318
|
+
*/x("vaadin-input-container",Xg,{moduleId:"vaadin-input-container-styles"});class pu extends Gg(X(Oe(H))){static get is(){return"vaadin-input-container"}static get template(){return z`
|
|
3319
3319
|
<slot name="prefix"></slot>
|
|
3320
3320
|
<slot></slot>
|
|
3321
3321
|
<slot name="suffix"></slot>
|
|
3322
|
-
`}}
|
|
3322
|
+
`}}k(pu);/**
|
|
3323
3323
|
* @license
|
|
3324
3324
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3325
3325
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3326
|
-
*/const
|
|
3326
|
+
*/const Kr=v`
|
|
3327
3327
|
:host {
|
|
3328
3328
|
z-index: 200;
|
|
3329
3329
|
position: fixed;
|
|
@@ -3390,55 +3390,55 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3390
3390
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3391
3391
|
Code distributed by Google as part of the polymer project is also
|
|
3392
3392
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3393
|
-
*/let _n=!1,
|
|
3393
|
+
*/let _n=!1,Kg=[],mu=[];function Qg(){_n=!0,requestAnimationFrame(function(){_n=!1,Jg(Kg),setTimeout(function(){Zg(mu)})})}function Jg(r){for(;r.length;)fu(r.shift())}function Zg(r){for(let e=0,t=r.length;e<t;e++)fu(r.shift())}function fu(r){const e=r[0],t=r[1],i=r[2];try{t.apply(e,i)}catch(o){setTimeout(()=>{throw o})}}function na(r,e,t){_n||Qg(),mu.push([r,e,t])}/**
|
|
3394
3394
|
* @license
|
|
3395
3395
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3396
3396
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3397
|
-
*/const to=r=>r.test(navigator.userAgent),vn=r=>r.test(navigator.platform),
|
|
3397
|
+
*/const to=r=>r.test(navigator.userAgent),vn=r=>r.test(navigator.platform),eb=r=>r.test(navigator.vendor);to(/Android/u);to(/Chrome/u)&&eb(/Google Inc/u);to(/Firefox/u);const tb=vn(/^iPad/u)||vn(/^Mac/u)&&navigator.maxTouchPoints>1,rb=vn(/^iPhone/u),aa=rb||tb,ib=to(/^((?!chrome|android).)*safari/iu),gn=(()=>{try{return document.createEvent("TouchEvent"),!0}catch(r){return!1}})();/**
|
|
3398
3398
|
* @license
|
|
3399
3399
|
* Copyright (c) 2017 Anton Korzunov
|
|
3400
3400
|
* SPDX-License-Identifier: MIT
|
|
3401
|
-
*/let Nt=new WeakMap,di=new WeakMap,ui={},Po=0;const Ws=r=>r&&r.nodeType===Node.ELEMENT_NODE,Ao=(...r)=>{console.error(`Error: ${r.join(" ")}. Skip setting aria-hidden.`)},
|
|
3401
|
+
*/let Nt=new WeakMap,di=new WeakMap,ui={},Po=0;const Ws=r=>r&&r.nodeType===Node.ELEMENT_NODE,Ao=(...r)=>{console.error(`Error: ${r.join(" ")}. Skip setting aria-hidden.`)},ob=(r,e)=>Ws(r)?e.map(t=>{if(!Ws(t))return Ao(t,"is not a valid element"),null;let i=t;for(;i&&i!==r;){if(r.contains(i))return t;i=i.getRootNode().host}return Ao(t,"is not contained inside",r),null}).filter(t=>!!t):(Ao(r,"is not a valid element"),[]),nb=(r,e,t,i)=>{const o=ob(e,Array.isArray(r)?r:[r]);ui[t]||(ui[t]=new WeakMap);const n=ui[t],a=[],s=new Set,l=new Set(o),d=c=>{if(!c||s.has(c))return;s.add(c);const h=c.assignedSlot;h&&d(h),d(c.parentNode||c.host)};o.forEach(d);const u=c=>{if(!c||l.has(c))return;const h=c.shadowRoot;(h?[...c.children,...h.children]:[...c.children]).forEach(p=>{if(!["template","script","style"].includes(p.localName))if(s.has(p))u(p);else{const m=p.getAttribute(i),f=m!==null&&m!=="false",y=(Nt.get(p)||0)+1,E=(n.get(p)||0)+1;Nt.set(p,y),n.set(p,E),a.push(p),y===1&&f&&di.set(p,!0),E===1&&p.setAttribute(t,"true"),f||p.setAttribute(i,"true")}})};return u(e),s.clear(),Po+=1,()=>{a.forEach(c=>{const h=Nt.get(c)-1,p=n.get(c)-1;Nt.set(c,h),n.set(c,p),h||(di.has(c)?di.delete(c):c.removeAttribute(i)),p||c.removeAttribute(t)}),Po-=1,Po||(Nt=new WeakMap,Nt=new WeakMap,di=new WeakMap,ui={})}},_u=(r,e=document.body,t="data-aria-hidden")=>{const i=Array.from(Array.isArray(r)?r:[r]);return e&&i.push(...Array.from(e.querySelectorAll("[aria-live]"))),nb(i,e,t,"aria-hidden")};/**
|
|
3402
3402
|
* @license
|
|
3403
3403
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3404
3404
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3405
|
-
*/class
|
|
3405
|
+
*/class ab{constructor(e,t){this.host=e,this.callback=typeof t=="function"?t:()=>e}showModal(){const e=this.callback();this.__showOthers=_u(e)}close(){this.__showOthers&&(this.__showOthers(),this.__showOthers=null)}}/**
|
|
3406
3406
|
* @license
|
|
3407
3407
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3408
3408
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3409
|
-
*/class
|
|
3409
|
+
*/class sb{saveFocus(e){this.focusNode=e||pn()}restoreFocus(e){const t=this.focusNode;if(!t)return;const i=e?e.preventScroll:!1;pn()===document.body?setTimeout(()=>t.focus({preventScroll:i})):t.focus({preventScroll:i}),this.focusNode=null}}/**
|
|
3410
3410
|
* @license
|
|
3411
3411
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3412
3412
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3413
|
-
*/const ko=[];class
|
|
3413
|
+
*/const ko=[];class lb{constructor(e){this.host=e,this.__trapNode=null,this.__onKeyDown=this.__onKeyDown.bind(this)}get __focusableElements(){return Ig(this.__trapNode)}get __focusedElementIndex(){const e=this.__focusableElements;return e.indexOf(e.filter(Qn).pop())}hostConnected(){document.addEventListener("keydown",this.__onKeyDown)}hostDisconnected(){document.removeEventListener("keydown",this.__onKeyDown)}trapFocus(e){if(this.__trapNode=e,this.__focusableElements.length===0)throw this.__trapNode=null,new Error("The trap node should have at least one focusable descendant or be focusable itself.");ko.push(this),this.__focusedElementIndex===-1&&this.__focusableElements[0].focus()}releaseFocus(){this.__trapNode=null,ko.pop()}__onKeyDown(e){if(this.__trapNode&&this===Array.from(ko).pop()&&e.key==="Tab"){e.preventDefault();const t=e.shiftKey;this.__focusNextElement(t)}}__focusNextElement(e=!1){const t=this.__focusableElements,i=e?-1:1,o=this.__focusedElementIndex,n=(t.length+o+i)%t.length,a=t[n];a.focus(),a.localName==="input"&&a.select()}}/**
|
|
3414
3414
|
* @license
|
|
3415
3415
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3416
3416
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3417
|
-
*/const
|
|
3417
|
+
*/const db=r=>class extends Ue(r){static get properties(){return{focusTrap:{type:Boolean,value:!1},restoreFocusOnClose:{type:Boolean,value:!1},restoreFocusNode:{type:HTMLElement}}}constructor(){super(),this.__ariaModalController=new ab(this),this.__focusTrapController=new lb(this),this.__focusRestorationController=new sb}ready(){super.ready(),this.addController(this.__ariaModalController),this.addController(this.__focusTrapController),this.addController(this.__focusRestorationController)}_resetFocus(){if(this.focusTrap&&(this.__ariaModalController.close(),this.__focusTrapController.releaseFocus()),this.restoreFocusOnClose&&this._shouldRestoreFocus()){const e=!Qi();this.__focusRestorationController.restoreFocus({preventScroll:e})}}_saveFocus(){this.restoreFocusOnClose&&this.__focusRestorationController.saveFocus(this.restoreFocusNode)}_trapFocus(){this.focusTrap&&(this.__ariaModalController.showModal(),this.__focusTrapController.trapFocus(this.$.overlay))}_shouldRestoreFocus(){const e=pn();return e===document.body||this._deepContains(e)}_deepContains(e){if(this.contains(e))return!0;let t=e;const i=e.ownerDocument;for(;t&&t!==i&&t!==this;)t=t.parentNode||t.host;return t===this}};/**
|
|
3418
3418
|
* @license
|
|
3419
3419
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3420
3420
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3421
|
-
*/const vu=()=>Array.from(document.body.children).filter(r=>r instanceof HTMLElement&&r._hasOverlayStackMixin&&!r.hasAttribute("closing")).sort((r,e)=>r.__zIndex-e.__zIndex||0),bn=()=>vu().filter(r=>r.$.overlay),
|
|
3421
|
+
*/const vu=()=>Array.from(document.body.children).filter(r=>r instanceof HTMLElement&&r._hasOverlayStackMixin&&!r.hasAttribute("closing")).sort((r,e)=>r.__zIndex-e.__zIndex||0),bn=()=>vu().filter(r=>r.$.overlay),ub=r=>r===bn().pop(),gu=r=>class extends r{constructor(){super(),this._hasOverlayStackMixin=!0}get _last(){return ub(this)}bringToFront(){let e="";const t=vu().filter(i=>i!==this).pop();t&&(e=t.__zIndex+1),this.style.zIndex=e,this.__zIndex=e||parseFloat(getComputedStyle(this).zIndex)}_enterModalState(){document.body.style.pointerEvents!=="none"&&(this._previousDocumentPointerEvents=document.body.style.pointerEvents,document.body.style.pointerEvents="none"),bn().forEach(e=>{e!==this&&(e.$.overlay.style.pointerEvents="none")})}_exitModalState(){this._previousDocumentPointerEvents!==void 0&&(document.body.style.pointerEvents=this._previousDocumentPointerEvents,delete this._previousDocumentPointerEvents);const e=bn();let t;for(;(t=e.pop())&&!(t!==this&&(t.$.overlay.style.removeProperty("pointer-events"),!t.modeless)););}};/**
|
|
3422
3422
|
* @license
|
|
3423
3423
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3424
3424
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3425
|
-
*/const
|
|
3425
|
+
*/const Qr=r=>class extends db(gu(r)){static get properties(){return{opened:{type:Boolean,notify:!0,observer:"_openedChanged",reflectToAttribute:!0},owner:{type:Object},model:{type:Object},renderer:{type:Object},modeless:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_modelessChanged"},hidden:{type:Boolean,reflectToAttribute:!0,observer:"_hiddenChanged"},withBackdrop:{type:Boolean,value:!1,reflectToAttribute:!0}}}static get observers(){return["_rendererOrDataChanged(renderer, owner, model, opened)"]}constructor(){super(),this._boundMouseDownListener=this._mouseDownListener.bind(this),this._boundMouseUpListener=this._mouseUpListener.bind(this),this._boundOutsideClickListener=this._outsideClickListener.bind(this),this._boundKeydownListener=this._keydownListener.bind(this),aa&&(this._boundIosResizeListener=()=>this._detectIosNavbar())}ready(){super.ready(),this.addEventListener("click",()=>{}),this.$.backdrop.addEventListener("click",()=>{}),this.addEventListener("mouseup",()=>{document.activeElement===document.body&&this.$.overlay.getAttribute("tabindex")==="0"&&this.$.overlay.focus()})}connectedCallback(){super.connectedCallback(),this._boundIosResizeListener&&(this._detectIosNavbar(),window.addEventListener("resize",this._boundIosResizeListener))}disconnectedCallback(){super.disconnectedCallback(),this._boundIosResizeListener&&window.removeEventListener("resize",this._boundIosResizeListener)}requestContentUpdate(){this.renderer&&this.renderer.call(this.owner,this,this.owner,this.model)}close(e){const t=new CustomEvent("vaadin-overlay-close",{bubbles:!0,cancelable:!0,detail:{sourceEvent:e}});this.dispatchEvent(t),t.defaultPrevented||(this.opened=!1)}_detectIosNavbar(){if(!this.opened)return;const e=window.innerHeight,t=window.innerWidth>e,i=document.documentElement.clientHeight;t&&i>e?this.style.setProperty("--vaadin-overlay-viewport-bottom",`${i-e}px`):this.style.setProperty("--vaadin-overlay-viewport-bottom","0")}_addGlobalListeners(){document.addEventListener("mousedown",this._boundMouseDownListener),document.addEventListener("mouseup",this._boundMouseUpListener),document.documentElement.addEventListener("click",this._boundOutsideClickListener,!0)}_removeGlobalListeners(){document.removeEventListener("mousedown",this._boundMouseDownListener),document.removeEventListener("mouseup",this._boundMouseUpListener),document.documentElement.removeEventListener("click",this._boundOutsideClickListener,!0)}_rendererOrDataChanged(e,t,i,o){const n=this._oldOwner!==t||this._oldModel!==i;this._oldModel=i,this._oldOwner=t;const a=this._oldRenderer!==e,s=this._oldRenderer!==void 0;this._oldRenderer=e;const l=this._oldOpened!==o;this._oldOpened=o,a&&s&&(this.innerHTML="",delete this._$litPart$),o&&e&&(a||l||n)&&this.requestContentUpdate()}_modelessChanged(e){e?(this._removeGlobalListeners(),this._exitModalState()):this.opened&&(this._addGlobalListeners(),this._enterModalState())}_openedChanged(e,t){e?(this._saveFocus(),this._animatedOpening(),na(this,()=>{this._trapFocus();const i=new CustomEvent("vaadin-overlay-open",{bubbles:!0});this.dispatchEvent(i)}),document.addEventListener("keydown",this._boundKeydownListener),this.modeless||this._addGlobalListeners()):t&&(this._resetFocus(),this._animatedClosing(),document.removeEventListener("keydown",this._boundKeydownListener),this.modeless||this._removeGlobalListeners())}_hiddenChanged(e){e&&this.hasAttribute("closing")&&this._flushAnimation("closing")}_shouldAnimate(){const e=getComputedStyle(this),t=e.getPropertyValue("animation-name");return e.getPropertyValue("display")!=="none"&&t&&t!=="none"}_enqueueAnimation(e,t){const i=`__${e}Handler`,o=n=>{n&&n.target!==this||(t(),this.removeEventListener("animationend",o),delete this[i])};this[i]=o,this.addEventListener("animationend",o)}_flushAnimation(e){const t=`__${e}Handler`;typeof this[t]=="function"&&this[t]()}_animatedOpening(){this.parentNode===document.body&&this.hasAttribute("closing")&&this._flushAnimation("closing"),this._attachOverlay(),this.modeless||this._enterModalState(),this.setAttribute("opening",""),this._shouldAnimate()?this._enqueueAnimation("opening",()=>{this._finishOpening()}):this._finishOpening()}_attachOverlay(){this._placeholder=document.createComment("vaadin-overlay-placeholder"),this.parentNode.insertBefore(this._placeholder,this),document.body.appendChild(this),this.bringToFront()}_finishOpening(){this.removeAttribute("opening")}_finishClosing(){this._detachOverlay(),this.$.overlay.style.removeProperty("pointer-events"),this.removeAttribute("closing"),this.dispatchEvent(new CustomEvent("vaadin-overlay-closed"))}_animatedClosing(){this.hasAttribute("opening")&&this._flushAnimation("opening"),this._placeholder&&(this._exitModalState(),this.setAttribute("closing",""),this.dispatchEvent(new CustomEvent("vaadin-overlay-closing")),this._shouldAnimate()?this._enqueueAnimation("closing",()=>{this._finishClosing()}):this._finishClosing())}_detachOverlay(){this._placeholder.parentNode.insertBefore(this,this._placeholder),this._placeholder.parentNode.removeChild(this._placeholder)}_mouseDownListener(e){this._mouseDownInside=e.composedPath().indexOf(this.$.overlay)>=0}_mouseUpListener(e){this._mouseUpInside=e.composedPath().indexOf(this.$.overlay)>=0}_shouldCloseOnOutsideClick(e){return this._last}_outsideClickListener(e){if(e.composedPath().includes(this.$.overlay)||this._mouseDownInside||this._mouseUpInside){this._mouseDownInside=!1,this._mouseUpInside=!1;return}if(!this._shouldCloseOnOutsideClick(e))return;const t=new CustomEvent("vaadin-overlay-outside-click",{bubbles:!0,cancelable:!0,detail:{sourceEvent:e}});this.dispatchEvent(t),this.opened&&!t.defaultPrevented&&this.close(e)}_keydownListener(e){if(this._last&&!(this.modeless&&!e.composedPath().includes(this.$.overlay))&&e.key==="Escape"){const t=new CustomEvent("vaadin-overlay-escape-press",{bubbles:!0,cancelable:!0,detail:{sourceEvent:e}});this.dispatchEvent(t),this.opened&&!t.defaultPrevented&&this.close(e)}}};/**
|
|
3426
3426
|
* @license
|
|
3427
3427
|
* Copyright (c) 2024 Vaadin Ltd.
|
|
3428
3428
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3429
|
-
*/function
|
|
3429
|
+
*/function cb(r,e){let t=null;const i=document.documentElement;function o(){t&&t.disconnect(),t=null}function n(a=!1,s=1){o();const{left:l,top:d,width:u,height:c}=r.getBoundingClientRect();if(a||e(),!u||!c)return;const h=Math.floor(d),p=Math.floor(i.clientWidth-(l+u)),m=Math.floor(i.clientHeight-(d+c)),f=Math.floor(l),y={rootMargin:`${-h}px ${-p}px ${-m}px ${-f}px`,threshold:Math.max(0,Math.min(1,s))||1};let E=!0;function C(T){let N=T[0].intersectionRatio;if(N!==s){if(!E)return n();N===0&&(N=1e-7),n(!1,N)}E=!1}t=new IntersectionObserver(C,y),t.observe(r)}return n(!0),o}/**
|
|
3430
3430
|
* @license
|
|
3431
3431
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3432
3432
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3433
|
-
*/const Io={start:"top",end:"bottom"},So={start:"left",end:"right"},js=new ResizeObserver(r=>{setTimeout(()=>{r.forEach(e=>{e.target.__overlay&&e.target.__overlay._updatePosition()})})}),sa=r=>class extends r{static get properties(){return{positionTarget:{type:Object,value:null,sync:!0},horizontalAlign:{type:String,value:"start",sync:!0},verticalAlign:{type:String,value:"top",sync:!0},noHorizontalOverlap:{type:Boolean,value:!1,sync:!0},noVerticalOverlap:{type:Boolean,value:!1,sync:!0},requiredVerticalSpace:{type:Number,value:0,sync:!0}}}static get observers(){return["__positionSettingsChanged(horizontalAlign, verticalAlign, noHorizontalOverlap, noVerticalOverlap, requiredVerticalSpace)","__overlayOpenedChanged(opened, positionTarget)"]}constructor(){super(),this.__onScroll=this.__onScroll.bind(this),this._updatePosition=this._updatePosition.bind(this)}connectedCallback(){super.connectedCallback(),this.opened&&this.__addUpdatePositionEventListeners()}disconnectedCallback(){super.disconnectedCallback(),this.__removeUpdatePositionEventListeners()}__addUpdatePositionEventListeners(){window.visualViewport.addEventListener("resize",this._updatePosition),window.visualViewport.addEventListener("scroll",this.__onScroll,!0),this.__positionTargetAncestorRootNodes=
|
|
3433
|
+
*/const Io={start:"top",end:"bottom"},So={start:"left",end:"right"},js=new ResizeObserver(r=>{setTimeout(()=>{r.forEach(e=>{e.target.__overlay&&e.target.__overlay._updatePosition()})})}),sa=r=>class extends r{static get properties(){return{positionTarget:{type:Object,value:null,sync:!0},horizontalAlign:{type:String,value:"start",sync:!0},verticalAlign:{type:String,value:"top",sync:!0},noHorizontalOverlap:{type:Boolean,value:!1,sync:!0},noVerticalOverlap:{type:Boolean,value:!1,sync:!0},requiredVerticalSpace:{type:Number,value:0,sync:!0}}}static get observers(){return["__positionSettingsChanged(horizontalAlign, verticalAlign, noHorizontalOverlap, noVerticalOverlap, requiredVerticalSpace)","__overlayOpenedChanged(opened, positionTarget)"]}constructor(){super(),this.__onScroll=this.__onScroll.bind(this),this._updatePosition=this._updatePosition.bind(this)}connectedCallback(){super.connectedCallback(),this.opened&&this.__addUpdatePositionEventListeners()}disconnectedCallback(){super.disconnectedCallback(),this.__removeUpdatePositionEventListeners()}__addUpdatePositionEventListeners(){window.visualViewport.addEventListener("resize",this._updatePosition),window.visualViewport.addEventListener("scroll",this.__onScroll,!0),this.__positionTargetAncestorRootNodes=sg(this.positionTarget),this.__positionTargetAncestorRootNodes.forEach(e=>{e.addEventListener("scroll",this.__onScroll,!0)}),this.positionTarget&&(this.__observePositionTargetMove=cb(this.positionTarget,()=>{this._updatePosition()}))}__removeUpdatePositionEventListeners(){window.visualViewport.removeEventListener("resize",this._updatePosition),window.visualViewport.removeEventListener("scroll",this.__onScroll,!0),this.__positionTargetAncestorRootNodes&&(this.__positionTargetAncestorRootNodes.forEach(e=>{e.removeEventListener("scroll",this.__onScroll,!0)}),this.__positionTargetAncestorRootNodes=null),this.__observePositionTargetMove&&(this.__observePositionTargetMove(),this.__observePositionTargetMove=null)}__overlayOpenedChanged(e,t){if(this.__removeUpdatePositionEventListeners(),t&&(t.__overlay=null,js.unobserve(t),e&&(this.__addUpdatePositionEventListeners(),t.__overlay=this,js.observe(t))),e){const i=getComputedStyle(this);this.__margins||(this.__margins={},["top","bottom","left","right"].forEach(o=>{this.__margins[o]=parseInt(i[o],10)})),this._updatePosition(),requestAnimationFrame(()=>this._updatePosition())}}__positionSettingsChanged(){this._updatePosition()}__onScroll(e){e.target instanceof Node&&this.contains(e.target)||this._updatePosition()}_updatePosition(){if(!this.positionTarget||!this.opened||!this.__margins)return;const e=this.positionTarget.getBoundingClientRect();if(e.width===0&&e.height===0&&this.opened){this.opened=!1;return}const t=this.__shouldAlignStartVertically(e);this.style.justifyContent=t?"flex-start":"flex-end";const i=this.__isRTL,o=this.__shouldAlignStartHorizontally(e,i),n=!i&&o||i&&!o;this.style.alignItems=n?"flex-start":"flex-end";const a=this.getBoundingClientRect(),s=this.__calculatePositionInOneDimension(e,a,this.noVerticalOverlap,Io,this,t),l=this.__calculatePositionInOneDimension(e,a,this.noHorizontalOverlap,So,this,o);Object.assign(this.style,s,l),this.toggleAttribute("bottom-aligned",!t),this.toggleAttribute("top-aligned",t),this.toggleAttribute("end-aligned",!n),this.toggleAttribute("start-aligned",n)}__shouldAlignStartHorizontally(e,t){const i=Math.max(this.__oldContentWidth||0,this.$.overlay.offsetWidth);this.__oldContentWidth=this.$.overlay.offsetWidth;const o=Math.min(window.innerWidth,document.documentElement.clientWidth),n=!t&&this.horizontalAlign==="start"||t&&this.horizontalAlign==="end";return this.__shouldAlignStart(e,i,o,this.__margins,n,this.noHorizontalOverlap,So)}__shouldAlignStartVertically(e){const t=this.requiredVerticalSpace||Math.max(this.__oldContentHeight||0,this.$.overlay.offsetHeight);this.__oldContentHeight=this.$.overlay.offsetHeight;const i=Math.min(window.innerHeight,document.documentElement.clientHeight),o=this.verticalAlign==="top";return this.__shouldAlignStart(e,t,i,this.__margins,o,this.noVerticalOverlap,Io)}__shouldAlignStart(e,t,i,o,n,a,s){const l=i-e[a?s.end:s.start]-o[s.end],d=e[a?s.start:s.end]-o[s.start],u=n?l:d,c=u>(n?d:l)||u>t;return n===c}__adjustBottomProperty(e,t,i){let o;if(e===t.end){if(t.end===Io.end){const n=Math.min(window.innerHeight,document.documentElement.clientHeight);if(i>n&&this.__oldViewportHeight){const a=this.__oldViewportHeight-n;o=i-a}this.__oldViewportHeight=n}if(t.end===So.end){const n=Math.min(window.innerWidth,document.documentElement.clientWidth);if(i>n&&this.__oldViewportWidth){const a=this.__oldViewportWidth-n;o=i-a}this.__oldViewportWidth=n}}return o}__calculatePositionInOneDimension(e,t,i,o,n,a){const s=a?o.start:o.end,l=a?o.end:o.start,d=parseFloat(n.style[s]||getComputedStyle(n)[s]),u=this.__adjustBottomProperty(s,o,d),c=t[a?o.start:o.end]-e[i===a?o.end:o.start],h=u?`${u}px`:`${d+c*(a?-1:1)}px`;return{[s]:h,[l]:""}}};/**
|
|
3434
3434
|
* @license
|
|
3435
3435
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
3436
3436
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3437
|
-
*/const
|
|
3437
|
+
*/const hb=r=>class extends sa(Qr(r)){_shouldCloseOnOutsideClick(e){return!e.composedPath().includes(this.positionTarget)}_mouseDownListener(e){super._mouseDownListener(e),this._shouldCloseOnOutsideClick(e)&&!Kn(e.composedPath()[0])&&e.preventDefault()}};/**
|
|
3438
3438
|
* @license
|
|
3439
3439
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3440
3440
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3441
|
-
*/const
|
|
3441
|
+
*/const pb=v`
|
|
3442
3442
|
[part='overlay'] {
|
|
3443
3443
|
display: flex;
|
|
3444
3444
|
flex: auto;
|
|
@@ -3457,14 +3457,14 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3457
3457
|
* @license
|
|
3458
3458
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3459
3459
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3460
|
-
*/
|
|
3460
|
+
*/x("vaadin-date-picker-overlay",[Kr,pb],{moduleId:"vaadin-date-picker-overlay-styles"});class mb extends hb(Oe(X(H))){static get is(){return"vaadin-date-picker-overlay"}static get template(){return z`
|
|
3461
3461
|
<div id="backdrop" part="backdrop" hidden$="[[!withBackdrop]]"></div>
|
|
3462
3462
|
<div part="overlay" id="overlay">
|
|
3463
3463
|
<div part="content" id="content">
|
|
3464
3464
|
<slot></slot>
|
|
3465
3465
|
</div>
|
|
3466
3466
|
</div>
|
|
3467
|
-
`}}
|
|
3467
|
+
`}}k(mb);/**
|
|
3468
3468
|
* @license
|
|
3469
3469
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3470
3470
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -3528,7 +3528,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3528
3528
|
outline-color: GrayText;
|
|
3529
3529
|
}
|
|
3530
3530
|
}
|
|
3531
|
-
`,
|
|
3531
|
+
`,fb=r=>r`
|
|
3532
3532
|
<div class="vaadin-button-container">
|
|
3533
3533
|
<span part="prefix" aria-hidden="true">
|
|
3534
3534
|
<slot name="prefix"></slot>
|
|
@@ -3545,15 +3545,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3545
3545
|
* @license
|
|
3546
3546
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3547
3547
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3548
|
-
*/const la=r=>class extends Gn(su(
|
|
3548
|
+
*/const la=r=>class extends Gn(su(Et(r))){static get properties(){return{tabindex:{type:Number,value:0,reflectToAttribute:!0}}}get _activeKeys(){return["Enter"," "]}ready(){super.ready(),this.hasAttribute("role")||this.setAttribute("role","button")}_onKeyDown(e){super._onKeyDown(e),!(e.altKey||e.shiftKey||e.ctrlKey||e.metaKey)&&this._activeKeys.includes(e.key)&&(e.preventDefault(),this.click())}};/**
|
|
3549
3549
|
* @license
|
|
3550
3550
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
3551
3551
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3552
|
-
*/
|
|
3552
|
+
*/x("vaadin-button",bu,{moduleId:"vaadin-button-styles"});class _b extends la(Ne(X(Ue(H)))){static get is(){return"vaadin-button"}static get template(){return fb(z)}ready(){super.ready(),this._tooltipController=new Qe(this),this.addController(this._tooltipController)}}k(_b);/**
|
|
3553
3553
|
* @license
|
|
3554
3554
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3555
3555
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3556
|
-
*/function
|
|
3556
|
+
*/function vb(r){let e=r.getDay();e===0&&(e=7);const t=4-e,i=new Date(r.getTime()+t*24*3600*1e3),o=new Date(0,0);o.setFullYear(i.getFullYear());const n=i.getTime()-o.getTime(),a=Math.round(n/(24*3600*1e3));return Math.floor(a/7+1)}function yn(r){const e=new Date(r);return e.setHours(0,0,0,0),e}function Xe(r,e,t=yn){return r instanceof Date&&e instanceof Date&&t(r).getTime()===t(e).getTime()}function da(r){return{day:r.getDate(),month:r.getMonth(),year:r.getFullYear()}}function Jt(r,e,t,i){let o=!1;if(typeof i=="function"&&r){const n=da(r);o=i(n)}return(!e||r>=e)&&(!t||r<=t)&&!o}function yu(r,e){return e.filter(t=>t!==void 0).reduce((t,i)=>{if(!i)return t;if(!t)return i;const o=Math.abs(r.getTime()-i.getTime()),n=Math.abs(t.getTime()-r.getTime());return o<n?i:t})}function wu(r){const e=new Date,t=new Date(e);return t.setDate(1),t.setMonth(parseInt(r)+e.getMonth()),t}function gb(r,e,t=0,i=1){if(e>99)throw new Error("The provided year cannot have more than 2 digits.");if(e<0)throw new Error("The provided year cannot be negative.");let o=e+Math.floor(r.getFullYear()/100)*100;return r<new Date(o-50,t,i)?o-=100:r>new Date(o+50,t,i)&&(o+=100),o}function wr(r){const e=/^([-+]\d{1}|\d{2,4}|[-+]\d{6})-(\d{1,2})-(\d{1,2})$/u.exec(r);if(!e)return;const t=new Date(0,0);return t.setFullYear(parseInt(e[1],10)),t.setMonth(parseInt(e[2],10)-1),t.setDate(parseInt(e[3],10)),t}function bb(r){const e=(l,d="00")=>(d+l).substr((d+l).length-d.length);let t="",i="0000",o=r.year;o<0?(o=-o,t="-",i="000000"):r.year>=1e4&&(t="+",i="000000");const n=t+e(o,i),a=e(r.month+1),s=e(r.day);return[n,a,s].join("-")}function yb(r){return r instanceof Date?bb({year:r.getFullYear(),month:r.getMonth(),day:r.getDate()}):""}/**
|
|
3557
3557
|
@license
|
|
3558
3558
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3559
3559
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3561,7 +3561,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3561
3561
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3562
3562
|
Code distributed by Google as part of the polymer project is also
|
|
3563
3563
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3564
|
-
*/class Hi{constructor(){this._asyncModule=null,this._callback=null,this._timer=null}setConfig(e,t){this._asyncModule=e,this._callback=t,this._timer=this._asyncModule.run(()=>{this._timer=null,
|
|
3564
|
+
*/class Hi{constructor(){this._asyncModule=null,this._callback=null,this._timer=null}setConfig(e,t){this._asyncModule=e,this._callback=t,this._timer=this._asyncModule.run(()=>{this._timer=null,Vr.delete(this),this._callback()})}cancel(){this.isActive()&&(this._cancelAsync(),Vr.delete(this))}_cancelAsync(){this.isActive()&&(this._asyncModule.cancel(this._timer),this._timer=null)}flush(){this.isActive()&&(this.cancel(),this._callback())}isActive(){return this._timer!=null}static debounce(e,t,i){return e instanceof Hi?e._cancelAsync():e=new Hi,e.setConfig(t,i),e}}let Vr=new Set;const wb=function(r){Vr.add(r)},xb=function(){const r=!!Vr.size;return Vr.forEach(e=>{try{e.flush()}catch(t){setTimeout(()=>{throw t})}}),r};/**
|
|
3565
3565
|
@license
|
|
3566
3566
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3567
3567
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3569,7 +3569,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3569
3569
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3570
3570
|
Code distributed by Google as part of the polymer project is also
|
|
3571
3571
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3572
|
-
*/const ua=function(){let r,e;do r=window.ShadyDOM&&ShadyDOM.flush(),window.ShadyCSS&&window.ShadyCSS.ScopingShim&&window.ShadyCSS.ScopingShim.flush(),e=
|
|
3572
|
+
*/const ua=function(){let r,e;do r=window.ShadyDOM&&ShadyDOM.flush(),window.ShadyCSS&&window.ShadyCSS.ScopingShim&&window.ShadyCSS.ScopingShim.flush(),e=xb();while(r||e)};/**
|
|
3573
3573
|
* @license
|
|
3574
3574
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3575
3575
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -3623,7 +3623,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3623
3623
|
<div class="buffer"></div>
|
|
3624
3624
|
<div id="fullHeight"></div>
|
|
3625
3625
|
</div>
|
|
3626
|
-
`;class Cu extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}).appendChild(xu.content.cloneNode(!0)),this.bufferSize=20,this._initialScroll=5e5,this._initialIndex=0,this._activated=!1}get active(){return this._activated}set active(e){e&&!this._activated&&(this._createPool(),this._activated=!0)}get bufferOffset(){return this._buffers[0].offsetTop}get itemHeight(){if(!this._itemHeightVal){const e=getComputedStyle(this).getPropertyValue("--vaadin-infinite-scroller-item-height"),t="background-position";this.$.fullHeight.style.setProperty(t,e);const i=getComputedStyle(this.$.fullHeight).getPropertyValue(t);this.$.fullHeight.style.removeProperty(t),this._itemHeightVal=parseFloat(i)}return this._itemHeightVal}get _bufferHeight(){return this.itemHeight*this.bufferSize}get position(){return(this.$.scroller.scrollTop-this._buffers[0].translateY)/this.itemHeight+this._firstIndex}set position(e){this._preventScrollEvent=!0,e>this._firstIndex&&e<this._firstIndex+this.bufferSize*2?this.$.scroller.scrollTop=this.itemHeight*(e-this._firstIndex)+this._buffers[0].translateY:(this._initialIndex=~~e,this._reset(),this._scrollDisabled=!0,this.$.scroller.scrollTop+=e%1*this.itemHeight,this._scrollDisabled=!1),this._mayHaveMomentum&&(this.$.scroller.classList.add("notouchscroll"),this._mayHaveMomentum=!1,setTimeout(()=>{this.$.scroller.classList.remove("notouchscroll")},10))}connectedCallback(){this._ready||(this._ready=!0,this.$={},this.shadowRoot.querySelectorAll("[id]").forEach(e=>{this.$[e.id]=e}),this.$.scroller.addEventListener("scroll",()=>this._scroll()),this._buffers=[...this.shadowRoot.querySelectorAll(".buffer")],this.$.fullHeight.style.height=`${this._initialScroll*2}px`)}forceUpdate(){this._debouncerScrollFinish&&this._debouncerScrollFinish.flush(),this._debouncerUpdateClones&&(this._buffers[0].updated=this._buffers[1].updated=!1,this._updateClones(),this._debouncerUpdateClones.cancel()),ua()}_createElement(){}_updateElement(e,t){}_finishInit(){this._initDone||(this._buffers.forEach(e=>{[...e.children].forEach(t=>{this._ensureStampedInstance(t._itemWrapper)})}),this._buffers[0].translateY||this._reset(),this._initDone=!0,this.dispatchEvent(new CustomEvent("init-done")))}_translateBuffer(e){const t=e?1:0;this._buffers[t].translateY=this._buffers[t?0:1].translateY+this._bufferHeight*(t?-1:1),this._buffers[t].style.transform=`translate3d(0, ${this._buffers[t].translateY}px, 0)`,this._buffers[t].updated=!1,this._buffers.reverse()}_scroll(){if(this._scrollDisabled)return;const e=this.$.scroller.scrollTop;(e<this._bufferHeight||e>this._initialScroll*2-this._bufferHeight)&&(this._initialIndex=~~this.position,this._reset());const t=this.itemHeight+this.bufferOffset,i=e>this._buffers[1].translateY+t,o=e<this._buffers[0].translateY+t;(i||o)&&(this._translateBuffer(o),this._updateClones()),this._preventScrollEvent||(this.dispatchEvent(new CustomEvent("custom-scroll",{bubbles:!1,composed:!0})),this._mayHaveMomentum=!0),this._preventScrollEvent=!1,this._debouncerScrollFinish=
|
|
3626
|
+
`;class Cu extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}).appendChild(xu.content.cloneNode(!0)),this.bufferSize=20,this._initialScroll=5e5,this._initialIndex=0,this._activated=!1}get active(){return this._activated}set active(e){e&&!this._activated&&(this._createPool(),this._activated=!0)}get bufferOffset(){return this._buffers[0].offsetTop}get itemHeight(){if(!this._itemHeightVal){const e=getComputedStyle(this).getPropertyValue("--vaadin-infinite-scroller-item-height"),t="background-position";this.$.fullHeight.style.setProperty(t,e);const i=getComputedStyle(this.$.fullHeight).getPropertyValue(t);this.$.fullHeight.style.removeProperty(t),this._itemHeightVal=parseFloat(i)}return this._itemHeightVal}get _bufferHeight(){return this.itemHeight*this.bufferSize}get position(){return(this.$.scroller.scrollTop-this._buffers[0].translateY)/this.itemHeight+this._firstIndex}set position(e){this._preventScrollEvent=!0,e>this._firstIndex&&e<this._firstIndex+this.bufferSize*2?this.$.scroller.scrollTop=this.itemHeight*(e-this._firstIndex)+this._buffers[0].translateY:(this._initialIndex=~~e,this._reset(),this._scrollDisabled=!0,this.$.scroller.scrollTop+=e%1*this.itemHeight,this._scrollDisabled=!1),this._mayHaveMomentum&&(this.$.scroller.classList.add("notouchscroll"),this._mayHaveMomentum=!1,setTimeout(()=>{this.$.scroller.classList.remove("notouchscroll")},10))}connectedCallback(){this._ready||(this._ready=!0,this.$={},this.shadowRoot.querySelectorAll("[id]").forEach(e=>{this.$[e.id]=e}),this.$.scroller.addEventListener("scroll",()=>this._scroll()),this._buffers=[...this.shadowRoot.querySelectorAll(".buffer")],this.$.fullHeight.style.height=`${this._initialScroll*2}px`)}forceUpdate(){this._debouncerScrollFinish&&this._debouncerScrollFinish.flush(),this._debouncerUpdateClones&&(this._buffers[0].updated=this._buffers[1].updated=!1,this._updateClones(),this._debouncerUpdateClones.cancel()),ua()}_createElement(){}_updateElement(e,t){}_finishInit(){this._initDone||(this._buffers.forEach(e=>{[...e.children].forEach(t=>{this._ensureStampedInstance(t._itemWrapper)})}),this._buffers[0].translateY||this._reset(),this._initDone=!0,this.dispatchEvent(new CustomEvent("init-done")))}_translateBuffer(e){const t=e?1:0;this._buffers[t].translateY=this._buffers[t?0:1].translateY+this._bufferHeight*(t?-1:1),this._buffers[t].style.transform=`translate3d(0, ${this._buffers[t].translateY}px, 0)`,this._buffers[t].updated=!1,this._buffers.reverse()}_scroll(){if(this._scrollDisabled)return;const e=this.$.scroller.scrollTop;(e<this._bufferHeight||e>this._initialScroll*2-this._bufferHeight)&&(this._initialIndex=~~this.position,this._reset());const t=this.itemHeight+this.bufferOffset,i=e>this._buffers[1].translateY+t,o=e<this._buffers[0].translateY+t;(i||o)&&(this._translateBuffer(o),this._updateClones()),this._preventScrollEvent||(this.dispatchEvent(new CustomEvent("custom-scroll",{bubbles:!1,composed:!0})),this._mayHaveMomentum=!0),this._preventScrollEvent=!1,this._debouncerScrollFinish=Se.debounce(this._debouncerScrollFinish,nt.after(200),()=>{const n=this.$.scroller.getBoundingClientRect();!this._isVisible(this._buffers[0],n)&&!this._isVisible(this._buffers[1],n)&&(this.position=this.position)})}_reset(){this._scrollDisabled=!0,this.$.scroller.scrollTop=this._initialScroll,this._buffers[0].translateY=this._initialScroll-this._bufferHeight,this._buffers[1].translateY=this._initialScroll,this._buffers.forEach(e=>{e.style.transform=`translate3d(0, ${e.translateY}px, 0)`}),this._buffers[0].updated=this._buffers[1].updated=!1,this._updateClones(!0),this._debouncerUpdateClones=Se.debounce(this._debouncerUpdateClones,nt.after(200),()=>{this._buffers[0].updated=this._buffers[1].updated=!1,this._updateClones()}),this._scrollDisabled=!1}_createPool(){const e=this.getBoundingClientRect();this._buffers.forEach(t=>{for(let i=0;i<this.bufferSize;i++){const o=document.createElement("div");o.style.height=`${this.itemHeight}px`,o.instance={};const n=`vaadin-infinite-scroller-item-content-${qr()}`,a=document.createElement("slot");a.setAttribute("name",n),a._itemWrapper=o,t.appendChild(a),o.setAttribute("slot",n),this.appendChild(o),this._isVisible(o,e)&&this._ensureStampedInstance(o)}}),requestAnimationFrame(()=>{this._finishInit()})}_ensureStampedInstance(e){if(e.firstElementChild)return;const t=e.instance;e.instance=this._createElement(),e.appendChild(e.instance),Object.keys(t).forEach(i=>{e.instance[i]=t[i]})}_updateClones(e){this._firstIndex=Math.round((this._buffers[0].translateY-this._initialScroll)/this.itemHeight)+this._initialIndex;const t=e?this.$.scroller.getBoundingClientRect():void 0;this._buffers.forEach((i,o)=>{if(!i.updated){const n=this._firstIndex+this.bufferSize*o;[...i.children].forEach((a,s)=>{const l=a._itemWrapper;(!e||this._isVisible(l,t))&&this._updateElement(l.instance,n+s)}),i.updated=!0}})}_isVisible(e,t){const i=e.getBoundingClientRect();return i.bottom>t.top&&i.top<t.bottom}}/**
|
|
3627
3627
|
* @license
|
|
3628
3628
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3629
3629
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -3639,7 +3639,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3639
3639
|
height: 100%;
|
|
3640
3640
|
}
|
|
3641
3641
|
</style>
|
|
3642
|
-
`;class
|
|
3642
|
+
`;class Cb extends Cu{static get is(){return"vaadin-date-picker-month-scroller"}constructor(){super(),this.bufferSize=3,this.shadowRoot.appendChild(Eu.content.cloneNode(!0))}_createElement(){return document.createElement("vaadin-month-calendar")}_updateElement(e,t){e.month=wu(t)}}k(Cb);/**
|
|
3643
3643
|
* @license
|
|
3644
3644
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3645
3645
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -3677,15 +3677,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3677
3677
|
border-left-color: #000;
|
|
3678
3678
|
}
|
|
3679
3679
|
</style>
|
|
3680
|
-
`;class
|
|
3680
|
+
`;class Eb extends Cu{static get is(){return"vaadin-date-picker-year-scroller"}constructor(){super(),this.bufferSize=12,this.shadowRoot.appendChild(Tu.content.cloneNode(!0))}_createElement(){return document.createElement("vaadin-date-picker-year")}_updateElement(e,t){e.year=this._yearAfterXYears(t)}_yearAfterXYears(e){const t=new Date,i=new Date(t);return i.setFullYear(parseInt(e)+t.getFullYear()),i.getFullYear()}}k(Eb);/**
|
|
3681
3681
|
* @license
|
|
3682
3682
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3683
3683
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3684
|
-
*/const
|
|
3684
|
+
*/const Tb=r=>class extends r{static get properties(){return{year:{type:String,sync:!0},selectedDate:{type:Object,sync:!0}}}static get observers(){return["__updateSelected(year, selectedDate)"]}__updateSelected(e,t){this.toggleAttribute("selected",t&&t.getFullYear()===e),this.toggleAttribute("current",e===new Date().getFullYear())}};/**
|
|
3685
3685
|
* @license
|
|
3686
3686
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3687
3687
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3688
|
-
*/class
|
|
3688
|
+
*/class Pb extends X(Tb(H)){static get is(){return"vaadin-date-picker-year"}static get template(){return z`
|
|
3689
3689
|
<style>
|
|
3690
3690
|
:host {
|
|
3691
3691
|
display: block;
|
|
@@ -3694,7 +3694,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3694
3694
|
</style>
|
|
3695
3695
|
<div part="year-number">[[year]]</div>
|
|
3696
3696
|
<div part="year-separator" aria-hidden="true"></div>
|
|
3697
|
-
`}}
|
|
3697
|
+
`}}k(Pb);/**
|
|
3698
3698
|
@license
|
|
3699
3699
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3700
3700
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3702,7 +3702,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3702
3702
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3703
3703
|
Code distributed by Google as part of the polymer project is also
|
|
3704
3704
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3705
|
-
*/function ca(r,e,t,i,o){let n;o&&(n=typeof t=="object"&&t!==null,n&&(i=r.__dataTemp[e]));let a=i!==t&&(i===i||t===t);return n&&a&&(r.__dataTemp[e]=t),a}const ha=
|
|
3705
|
+
*/function ca(r,e,t,i,o){let n;o&&(n=typeof t=="object"&&t!==null,n&&(i=r.__dataTemp[e]));let a=i!==t&&(i===i||t===t);return n&&a&&(r.__dataTemp[e]=t),a}const ha=le(r=>{class e extends r{_shouldPropertyChange(i,o,n){return ca(this,i,o,n,!0)}}return e}),Ab=le(r=>{class e extends r{static get properties(){return{mutableData:Boolean}}_shouldPropertyChange(i,o,n){return ca(this,i,o,n,this.mutableData)}}return e});ha._mutablePropertyChange=ca;/**
|
|
3706
3706
|
@license
|
|
3707
3707
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3708
3708
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3710,7 +3710,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3710
3710
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3711
3711
|
Code distributed by Google as part of the polymer project is also
|
|
3712
3712
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3713
|
-
*/let wn=null;function xn(){return wn}xn.prototype=Object.create(HTMLTemplateElement.prototype,{constructor:{value:xn,writable:!0}});const Pu=Vn(xn),
|
|
3713
|
+
*/let wn=null;function xn(){return wn}xn.prototype=Object.create(HTMLTemplateElement.prototype,{constructor:{value:xn,writable:!0}});const Pu=Vn(xn),kb=ha(Pu);function Ib(r,e){wn=r,Object.setPrototypeOf(r,e.prototype),new e,wn=null}const Sb=Vn(class{});function Db(r,e){for(let t=0;t<e.length;t++){let i=e[t];if(!!r!=!!i.__hideTemplateChildren__)if(i.nodeType===Node.TEXT_NODE)r?(i.__polymerTextContent__=i.textContent,i.textContent=""):i.textContent=i.__polymerTextContent__;else if(i.localName==="slot")if(r)i.__polymerReplaced__=document.createComment("hidden-slot"),fe(fe(i).parentNode).replaceChild(i.__polymerReplaced__,i);else{const o=i.__polymerReplaced__;o&&fe(fe(o).parentNode).replaceChild(i,o)}else i.style&&(r?(i.__polymerDisplay__=i.style.display,i.style.display="none"):i.style.display=i.__polymerDisplay__);i.__hideTemplateChildren__=r,i._showHideChildren&&i._showHideChildren(r)}}class lt extends Sb{constructor(e){super(),this._configureProperties(e),this.root=this._stampTemplate(this.__dataHost);let t=[];this.children=t;for(let o=this.root.firstChild;o;o=o.nextSibling)t.push(o),o.__templatizeInstance=this;this.__templatizeOwner&&this.__templatizeOwner.__hideTemplateChildren__&&this._showHideChildren(!0);let i=this.__templatizeOptions;(e&&i.instanceProps||!i.instanceProps)&&this._enableProperties()}_configureProperties(e){if(this.__templatizeOptions.forwardHostProp)for(let t in this.__hostProps)this._setPendingProperty(t,this.__dataHost["_host_"+t]);for(let t in e)this._setPendingProperty(t,e[t])}forwardHostProp(e,t){this._setPendingPropertyOrPath(e,t,!1,!0)&&this.__dataHost._enqueueClient(this)}_addEventListenerToNode(e,t,i){if(this._methodHost&&this.__templatizeOptions.parentModel)this._methodHost._addEventListenerToNode(e,t,o=>{o.model=this,i(o)});else{let o=this.__dataHost.__dataHost;o&&o._addEventListenerToNode(e,t,i)}}_showHideChildren(e){Db(e,this.children)}_setUnmanagedPropertyToNode(e,t,i){e.__hideTemplateChildren__&&e.nodeType==Node.TEXT_NODE&&t=="textContent"?e.__polymerTextContent__=i:super._setUnmanagedPropertyToNode(e,t,i)}get parentModel(){let e=this.__parentModel;if(!e){let t;e=this;do e=e.__dataHost.__dataHost;while((t=e.__templatizeOptions)&&!t.parentModel);this.__parentModel=e}return e}dispatchEvent(e){return!0}}lt.prototype.__dataHost;lt.prototype.__templatizeOptions;lt.prototype._methodHost;lt.prototype.__templatizeOwner;lt.prototype.__hostProps;const Ob=ha(lt);function qs(r){let e=r.__dataHost;return e&&e._methodHost||e}function Nb(r,e,t){let i=t.mutableData?Ob:lt;Cn.mixin&&(i=Cn.mixin(i));let o=class extends i{};return o.prototype.__templatizeOptions=t,o.prototype._bindTemplate(r),Lb(o,r,e,t),o}function Mb(r,e,t,i){let o=t.forwardHostProp;if(o&&e.hasHostProps){const n=r.localName=="template";let a=e.templatizeTemplateClass;if(!a){if(n){let l=t.mutableData?kb:Pu;class d extends l{}a=e.templatizeTemplateClass=d}else{const l=r.constructor;class d extends l{}a=e.templatizeTemplateClass=d}let s=e.hostProps;for(let l in s)a.prototype._addPropertyEffect("_host_"+l,a.prototype.PROPERTY_EFFECT_TYPES.PROPAGATE,{fn:Bb(l,o)}),a.prototype._createNotifyingProperty("_host_"+l);Td&&i&&Rb(e,t,i)}if(r.__dataProto&&Object.assign(r.__data,r.__dataProto),n)Ib(r,a),r.__dataTemp={},r.__dataPending=null,r.__dataOld=null,r._enableProperties();else{Object.setPrototypeOf(r,a.prototype);const s=e.hostProps;for(let l in s)if(l="_host_"+l,l in r){const d=r[l];delete r[l],r.__data[l]=d}}}}function Bb(r,e){return function(t,i,o){e.call(t.__templatizeOwner,i.substring(6),o[i])}}function Lb(r,e,t,i){let o=t.hostProps||{};for(let n in i.instanceProps){delete o[n];let a=i.notifyInstanceProp;a&&r.prototype._addPropertyEffect(n,r.prototype.PROPERTY_EFFECT_TYPES.NOTIFY,{fn:zb(n,a)})}if(i.forwardHostProp&&e.__dataHost)for(let n in o)t.hasHostProps||(t.hasHostProps=!0),r.prototype._addPropertyEffect(n,r.prototype.PROPERTY_EFFECT_TYPES.NOTIFY,{fn:Hb()})}function zb(r,e){return function(t,i,o){e.call(t.__templatizeOwner,t,i,o[i])}}function Hb(){return function(r,e,t){r.__dataHost._setPendingPropertyOrPath("_host_"+e,t[e],!0,!0)}}function Cn(r,e,t){if(Mi&&!qs(r))throw new Error("strictTemplatePolicy: template owner not trusted");if(t=t||{},r.__templatizeOwner)throw new Error("A <template> can only be templatized once");r.__templatizeOwner=e;let i=(e?e.constructor:lt)._parseTemplate(r),o=i.templatizeInstanceClass;o||(o=Nb(r,i,t),i.templatizeInstanceClass=o);const n=qs(r);Mb(r,i,t,n);let a=class extends o{};return a.prototype._methodHost=n,a.prototype.__dataHost=r,a.prototype.__templatizeOwner=e,a.prototype.__hostProps=i.hostProps,a=a,a}function Rb(r,e,t){const i=t.constructor._properties,{propertyEffects:o}=r,{instanceProps:n}=e;for(let a in o)if(!i[a]&&!(n&&n[a])){const s=o[a];for(let l=0;l<s.length;l++){const{part:d}=s[l].info;if(!(d.signature&&d.signature.static)){console.warn(`Property '${a}' used in template but not declared in 'properties'; attribute will not be observed.`);break}}}}function Fb(r,e){let t;for(;e;)if(t=e.__dataHost?e:e.__templatizeInstance)if(t.__dataHost!=r)e=t.__dataHost;else return t;else e=fe(e).parentNode;return null}/**
|
|
3714
3714
|
@license
|
|
3715
3715
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3716
3716
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3718,7 +3718,7 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3718
3718
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3719
3719
|
Code distributed by Google as part of the polymer project is also
|
|
3720
3720
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3721
|
-
*/let Ys=!1;function
|
|
3721
|
+
*/let Ys=!1;function $b(){if(Ed&&!Cd){if(!Ys){Ys=!0;const r=document.createElement("style");r.textContent="dom-bind,dom-if,dom-repeat{display:none;}",document.head.appendChild(r)}return!0}return!1}/**
|
|
3722
3722
|
@license
|
|
3723
3723
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
3724
3724
|
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
|
@@ -3726,15 +3726,15 @@ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
|
|
3726
3726
|
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
3727
3727
|
Code distributed by Google as part of the polymer project is also
|
|
3728
3728
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3729
|
-
*/const
|
|
3729
|
+
*/const Vb=Ab(H);class Gs extends Vb{static get is(){return"dom-repeat"}static get template(){return null}static get properties(){return{items:{type:Array},as:{type:String,value:"item"},indexAs:{type:String,value:"index"},itemsIndexAs:{type:String,value:"itemsIndex"},sort:{type:Function,observer:"__sortChanged"},filter:{type:Function,observer:"__filterChanged"},observe:{type:String,observer:"__observeChanged"},delay:Number,renderedItemCount:{type:Number,notify:!ys,readOnly:!0},initialCount:{type:Number},targetFramerate:{type:Number,value:20},_targetFrameTime:{type:Number,computed:"__computeFrameTime(targetFramerate)"},notifyDomChange:{type:Boolean},reuseChunkedInstances:{type:Boolean}}}static get observers(){return["__itemsChanged(items.*)"]}constructor(){super(),this.__instances=[],this.__renderDebouncer=null,this.__itemsIdxToInstIdx={},this.__chunkCount=null,this.__renderStartTime=null,this.__itemsArrayChanged=!1,this.__shouldMeasureChunk=!1,this.__shouldContinueChunking=!1,this.__chunkingId=0,this.__sortFn=null,this.__filterFn=null,this.__observePaths=null,this.__ctor=null,this.__isDetached=!0,this.template=null,this._templateInfo}disconnectedCallback(){super.disconnectedCallback(),this.__isDetached=!0;for(let e=0;e<this.__instances.length;e++)this.__detachInstance(e);this.__chunkingId&&cancelAnimationFrame(this.__chunkingId)}connectedCallback(){if(super.connectedCallback(),$b()||(this.style.display="none"),this.__isDetached){this.__isDetached=!1;let e=fe(fe(this).parentNode);for(let t=0;t<this.__instances.length;t++)this.__attachInstance(t,e);this.__chunkingId&&this.__render()}}__ensureTemplatized(){if(!this.__ctor){const e=this;let t=this.template=e._templateInfo?e:this.querySelector("template");if(!t){let o=new MutationObserver(()=>{if(this.querySelector("template"))o.disconnect(),this.__render();else throw new Error("dom-repeat requires a <template> child")});return o.observe(this,{childList:!0}),!1}let i={};i[this.as]=!0,i[this.indexAs]=!0,i[this.itemsIndexAs]=!0,this.__ctor=Cn(t,this,{mutableData:this.mutableData,parentModel:!0,instanceProps:i,forwardHostProp:function(o,n){let a=this.__instances;for(let s=0,l;s<a.length&&(l=a[s]);s++)l.forwardHostProp(o,n)},notifyInstanceProp:function(o,n,a){if(U_(this.as,n)){let s=o[this.itemsIndexAs];n==this.as&&(this.items[s]=a);let l=zr(this.as,`${JSCompiler_renameProperty("items",this)}.${s}`,n);this.notifyPath(l,a)}}})}return!0}__getMethodHost(){return this.__dataHost._methodHost||this.__dataHost}__functionFromPropertyValue(e){if(typeof e=="string"){let t=e,i=this.__getMethodHost();return function(){return i[t].apply(i,arguments)}}return e}__sortChanged(e){this.__sortFn=this.__functionFromPropertyValue(e),this.items&&this.__debounceRender(this.__render)}__filterChanged(e){this.__filterFn=this.__functionFromPropertyValue(e),this.items&&this.__debounceRender(this.__render)}__computeFrameTime(e){return Math.ceil(1e3/e)}__observeChanged(){this.__observePaths=this.observe&&this.observe.replace(".*",".").split(" ")}__handleObservedPaths(e){if(this.__sortFn||this.__filterFn){if(!e)this.__debounceRender(this.__render,this.delay);else if(this.__observePaths){let t=this.__observePaths;for(let i=0;i<t.length;i++)e.indexOf(t[i])===0&&this.__debounceRender(this.__render,this.delay)}}}__itemsChanged(e){this.items&&!Array.isArray(this.items)&&console.warn("dom-repeat expected array for `items`, found",this.items),this.__handleItemPath(e.path,e.value)||(e.path==="items"&&(this.__itemsArrayChanged=!0),this.__debounceRender(this.__render))}__debounceRender(e,t=0){this.__renderDebouncer=Hi.debounce(this.__renderDebouncer,t>0?X_.after(t):Bd,e.bind(this)),wb(this.__renderDebouncer)}render(){this.__debounceRender(this.__render),ua()}__render(){if(!this.__ensureTemplatized())return;let e=this.items||[];const t=this.__sortAndFilterItems(e),i=this.__calculateLimit(t.length);this.__updateInstances(e,i,t),this.initialCount&&(this.__shouldMeasureChunk||this.__shouldContinueChunking)&&(cancelAnimationFrame(this.__chunkingId),this.__chunkingId=requestAnimationFrame(()=>{this.__chunkingId=null,this.__continueChunking()})),this._setRenderedItemCount(this.__instances.length),(!ys||this.notifyDomChange)&&this.dispatchEvent(new CustomEvent("dom-change",{bubbles:!0,composed:!0}))}__sortAndFilterItems(e){let t=new Array(e.length);for(let i=0;i<e.length;i++)t[i]=i;return this.__filterFn&&(t=t.filter((i,o,n)=>this.__filterFn(e[i],o,n))),this.__sortFn&&t.sort((i,o)=>this.__sortFn(e[i],e[o])),t}__calculateLimit(e){let t=e;const i=this.__instances.length;if(this.initialCount){let o;!this.__chunkCount||this.__itemsArrayChanged&&!this.reuseChunkedInstances?(t=Math.min(e,this.initialCount),o=Math.max(t-i,0),this.__chunkCount=o||1):(o=Math.min(Math.max(e-i,0),this.__chunkCount),t=Math.min(i+o,e)),this.__shouldMeasureChunk=o===this.__chunkCount,this.__shouldContinueChunking=t<e,this.__renderStartTime=performance.now()}return this.__itemsArrayChanged=!1,t}__continueChunking(){if(this.__shouldMeasureChunk){const e=performance.now()-this.__renderStartTime,t=this._targetFrameTime/e;this.__chunkCount=Math.round(this.__chunkCount*t)||1}this.__shouldContinueChunking&&this.__debounceRender(this.__render)}__updateInstances(e,t,i){const o=this.__itemsIdxToInstIdx={};let n;for(n=0;n<t;n++){let a=this.__instances[n],s=i[n],l=e[s];o[s]=n,a?(a._setPendingProperty(this.as,l),a._setPendingProperty(this.indexAs,n),a._setPendingProperty(this.itemsIndexAs,s),a._flushProperties()):this.__insertInstance(l,n,s)}for(let a=this.__instances.length-1;a>=n;a--)this.__detachAndRemoveInstance(a)}__detachInstance(e){let t=this.__instances[e];const i=fe(t.root);for(let o=0;o<t.children.length;o++){let n=t.children[o];i.appendChild(n)}return t}__attachInstance(e,t){let i=this.__instances[e];t.insertBefore(i.root,this)}__detachAndRemoveInstance(e){this.__detachInstance(e),this.__instances.splice(e,1)}__stampInstance(e,t,i){let o={};return o[this.as]=e,o[this.indexAs]=t,o[this.itemsIndexAs]=i,new this.__ctor(o)}__insertInstance(e,t,i){const o=this.__stampInstance(e,t,i);let n=this.__instances[t+1],a=n?n.children[0]:this;return fe(fe(this).parentNode).insertBefore(o.root,a),this.__instances[t]=o,o}_showHideChildren(e){for(let t=0;t<this.__instances.length;t++)this.__instances[t]._showHideChildren(e)}__handleItemPath(e,t){let i=e.slice(6),o=i.indexOf("."),n=o<0?i:i.substring(0,o);if(n==parseInt(n,10)){let a=o<0?"":i.substring(o+1);this.__handleObservedPaths(a);let s=this.__itemsIdxToInstIdx[n],l=this.__instances[s];if(l){let d=this.as+(a?"."+a:"");l._setPendingPropertyOrPath(d,t,!1,!0),l._flushProperties()}return!0}}itemForElement(e){let t=this.modelForElement(e);return t&&t[this.as]}indexForElement(e){let t=this.modelForElement(e);return t&&t[this.indexAs]}modelForElement(e){return Fb(this.template,e)}}customElements.define(Gs.is,Gs);/**
|
|
3730
3730
|
* @license
|
|
3731
3731
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3732
3732
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3733
|
-
*/const
|
|
3733
|
+
*/const Ub=r=>class extends Et(r){static get properties(){return{month:{type:Object,value:new Date,sync:!0},selectedDate:{type:Object,notify:!0,sync:!0},focusedDate:{type:Object},showWeekNumbers:{type:Boolean,value:!1},i18n:{type:Object},ignoreTaps:{type:Boolean},minDate:{type:Date,value:null,sync:!0},maxDate:{type:Date,value:null,sync:!0},isDateDisabled:{type:Function,value:()=>!1},disabled:{type:Boolean,reflectToAttribute:!0},_days:{type:Array},_weeks:{type:Array},_notTapping:{type:Boolean}}}static get observers(){return["__focusedDateChanged(focusedDate, _days)"]}get focusableDateElement(){return[...this.shadowRoot.querySelectorAll("[part~=date]")].find(e=>Xe(e.date,this.focusedDate))}ready(){super.ready(),Re(this.$.monthGrid,"tap",this._handleTap.bind(this))}_isDisabled(e,t,i){const o=new Date(0,0);o.setFullYear(e.getFullYear()),o.setMonth(e.getMonth()),o.setDate(1);const n=new Date(0,0);return n.setFullYear(e.getFullYear()),n.setMonth(e.getMonth()+1),n.setDate(0),t&&i&&t.getMonth()===i.getMonth()&&t.getMonth()===e.getMonth()&&i.getDate()-t.getDate()>=0?!1:!Jt(o,t,i)&&!Jt(n,t,i)}_getTitle(e,t){if(!(e===void 0||t===void 0))return t.formatTitle(t.monthNames[e.getMonth()],e.getFullYear())}_onMonthGridTouchStart(){this._notTapping=!1,setTimeout(()=>{this._notTapping=!0},300)}_dateAdd(e,t){e.setDate(e.getDate()+t)}_applyFirstDayOfWeek(e,t){if(!(e===void 0||t===void 0))return e.slice(t).concat(e.slice(0,t))}_getWeekDayNames(e,t){if(e===void 0||t===void 0)return[];const{weekdays:i,weekdaysShort:o,firstDayOfWeek:n}=e,a=this._applyFirstDayOfWeek(o,n);return this._applyFirstDayOfWeek(i,n).map((s,l)=>({weekDay:s,weekDayShort:a[l]})).slice(0,7)}__focusedDateChanged(e,t){Array.isArray(t)&&t.some(i=>Xe(i,e))?this.removeAttribute("aria-hidden"):this.setAttribute("aria-hidden","true")}_getDate(e){return e?e.getDate():""}_showWeekSeparator(e,t){return e&&t&&t.firstDayOfWeek===1}_isToday(e){return Xe(new Date,e)}_getDays(e,t){if(e===void 0||t===void 0)return[];const i=new Date(0,0);for(i.setFullYear(e.getFullYear()),i.setMonth(e.getMonth()),i.setDate(1);i.getDay()!==t.firstDayOfWeek;)this._dateAdd(i,-1);const o=[],n=i.getMonth(),a=e.getMonth();for(;i.getMonth()===a||i.getMonth()===n;)o.push(i.getMonth()===a?new Date(i.getTime()):null),this._dateAdd(i,1);return o}_getWeeks(e){return e.reduce((t,i,o)=>(o%7===0&&t.push([]),t[t.length-1].push(i),t),[])}_handleTap(e){!this.ignoreTaps&&!this._notTapping&&e.target.date&&!e.target.hasAttribute("disabled")&&(this.selectedDate=e.target.date,this.dispatchEvent(new CustomEvent("date-tap",{detail:{date:e.target.date},bubbles:!0,composed:!0})))}_preventDefault(e){e.preventDefault()}__getWeekNumber(e){const t=e.reduce((i,o)=>!i&&o?o:i);return vb(t)}__getDayAriaLabel(e){if(!e)return"";let t=`${this._getDate(e)} ${this.i18n.monthNames[e.getMonth()]} ${e.getFullYear()}, ${this.i18n.weekdays[e.getDay()]}`;return this._isToday(e)&&(t+=`, ${this.i18n.today}`),t}};/**
|
|
3734
3734
|
* @license
|
|
3735
3735
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3736
3736
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3737
|
-
*/const
|
|
3737
|
+
*/const Wb=v`
|
|
3738
3738
|
:host {
|
|
3739
3739
|
display: block;
|
|
3740
3740
|
}
|
|
@@ -3794,7 +3794,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3794
3794
|
* @license
|
|
3795
3795
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3796
3796
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3797
|
-
*/
|
|
3797
|
+
*/x("vaadin-month-calendar",Wb,{moduleId:"vaadin-month-calendar-styles"});class jb extends Ub(X(H)){static get template(){return z`
|
|
3798
3798
|
<div part="month-header" id="month-header" aria-hidden="true">[[_getTitle(month, i18n)]]</div>
|
|
3799
3799
|
<table
|
|
3800
3800
|
id="monthGrid"
|
|
@@ -3836,7 +3836,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3836
3836
|
</template>
|
|
3837
3837
|
</tbody>
|
|
3838
3838
|
</table>
|
|
3839
|
-
`}static get is(){return"vaadin-month-calendar"}static get properties(){return{_days:{type:Array,computed:"_getDays(month, i18n, minDate, maxDate, isDateDisabled)"},_weeks:{type:Array,computed:"_getWeeks(_days)"},disabled:{type:Boolean,reflectToAttribute:!0,computed:"_isDisabled(month, minDate, maxDate)"}}}static get observers(){return["_showWeekNumbersChanged(showWeekNumbers, i18n)"]}_showWeekNumbersChanged(e,t){e&&t&&t.firstDayOfWeek===1?this.setAttribute("week-numbers",""):this.removeAttribute("week-numbers")}__getDatePart(e,t,i,o,n,a){const s=["date"],l=e>yn(new Date),d=e<yn(new Date);return this.__isDayDisabled(e,o,n,a)&&s.push("disabled"),this.__isDayFocused(e,t)&&s.push("focused"),this.__isDaySelected(e,i)&&s.push("selected"),this._isToday(e)&&s.push("today"),d&&s.push("past"),l&&s.push("future"),s.join(" ")}__isDayFocused(e,t){return
|
|
3839
|
+
`}static get is(){return"vaadin-month-calendar"}static get properties(){return{_days:{type:Array,computed:"_getDays(month, i18n, minDate, maxDate, isDateDisabled)"},_weeks:{type:Array,computed:"_getWeeks(_days)"},disabled:{type:Boolean,reflectToAttribute:!0,computed:"_isDisabled(month, minDate, maxDate)"}}}static get observers(){return["_showWeekNumbersChanged(showWeekNumbers, i18n)"]}_showWeekNumbersChanged(e,t){e&&t&&t.firstDayOfWeek===1?this.setAttribute("week-numbers",""):this.removeAttribute("week-numbers")}__getDatePart(e,t,i,o,n,a){const s=["date"],l=e>yn(new Date),d=e<yn(new Date);return this.__isDayDisabled(e,o,n,a)&&s.push("disabled"),this.__isDayFocused(e,t)&&s.push("focused"),this.__isDaySelected(e,i)&&s.push("selected"),this._isToday(e)&&s.push("today"),d&&s.push("past"),l&&s.push("future"),s.join(" ")}__isDayFocused(e,t){return Xe(e,t)}__isDaySelected(e,t){return Xe(e,t)}__getDayAriaSelected(e,t){if(this.__isDaySelected(e,t))return"true"}__isDayDisabled(e,t,i,o){return!Jt(e,t,i,o)}__getDayAriaDisabled(e,t,i,o){if(!(e===void 0||t===void 0&&i===void 0&&o===void 0)&&this.__isDayDisabled(e,t,i,o))return"true"}__getDayTabindex(e,t){return this.__isDayFocused(e,t)?"0":"-1"}}k(jb);/**
|
|
3840
3840
|
* @license
|
|
3841
3841
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3842
3842
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -3844,11 +3844,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3844
3844
|
* @license
|
|
3845
3845
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3846
3846
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3847
|
-
*/const jb=r=>class extends r{static get properties(){return{scrollDuration:{type:Number,value:300},selectedDate:{type:Object,value:null,sync:!0},focusedDate:{type:Object,notify:!0,observer:"_focusedDateChanged",sync:!0},_focusedMonthDate:Number,initialPosition:{type:Object,observer:"_initialPositionChanged"},_originDate:{type:Object,value:new Date},_visibleMonthIndex:Number,_desktopMode:{type:Boolean,observer:"_desktopModeChanged"},_desktopMediaQuery:{type:String,value:"(min-width: 375px)"},_translateX:{observer:"_translateXChanged"},_yearScrollerWidth:{value:50},i18n:{type:Object},showWeekNumbers:{type:Boolean,value:!1},_ignoreTaps:Boolean,_notTapping:Boolean,minDate:{type:Object,sync:!0},maxDate:{type:Object,sync:!0},isDateDisabled:{type:Function},label:String,_cancelButton:{type:Object},_todayButton:{type:Object},calendars:{type:Array,value:()=>[]},years:{type:Array,value:()=>[]}}}static get observers(){return["__updateCalendars(calendars, i18n, minDate, maxDate, selectedDate, focusedDate, showWeekNumbers, _ignoreTaps, _theme, isDateDisabled)","__updateCancelButton(_cancelButton, i18n)","__updateTodayButton(_todayButton, i18n, minDate, maxDate, isDateDisabled)","__updateYears(years, selectedDate, _theme)"]}get __useSubMonthScrolling(){return this._monthScroller.clientHeight<this._monthScroller.itemHeight+this._monthScroller.bufferOffset}get focusableDateElement(){return this.calendars.map(e=>e.focusableDateElement).find(Boolean)}_addListeners(){ou(this.$.scrollers,"pan-y"),Fe(this.$.scrollers,"track",this._track.bind(this)),Fe(this.shadowRoot.querySelector('[part="clear-button"]'),"tap",this._clear.bind(this)),Fe(this.shadowRoot.querySelector('[part="toggle-button"]'),"tap",this._cancel.bind(this)),Fe(this.shadowRoot.querySelector('[part="years-toggle-button"]'),"tap",this._toggleYearScroller.bind(this))}_initControllers(){this.addController(new pa(this._desktopMediaQuery,e=>{this._desktopMode=e})),this.addController(new xe(this,"today-button","vaadin-button",{observe:!1,initializer:e=>{e.setAttribute("theme","tertiary"),e.addEventListener("keydown",t=>this.__onTodayButtonKeyDown(t)),Fe(e,"tap",this._onTodayTap.bind(this)),this._todayButton=e}})),this.addController(new xe(this,"cancel-button","vaadin-button",{observe:!1,initializer:e=>{e.setAttribute("theme","tertiary"),e.addEventListener("keydown",t=>this.__onCancelButtonKeyDown(t)),Fe(e,"tap",this._cancel.bind(this)),this._cancelButton=e}})),this.__initMonthScroller(),this.__initYearScroller()}reset(){this._closeYearScroller(),this._toggleAnimateClass(!0)}focusCancel(){this._cancelButton.focus()}scrollToDate(e,t){const i=this.__useSubMonthScrolling?this._calculateWeekScrollOffset(e):0;this._scrollToPosition(this._differenceInMonths(e,this._originDate)+i,t),this._monthScroller.forceUpdate()}__initMonthScroller(){this.addController(new xe(this,"months","vaadin-date-picker-month-scroller",{observe:!1,initializer:e=>{e.addEventListener("custom-scroll",()=>{this._onMonthScroll()}),e.addEventListener("touchstart",()=>{this._onMonthScrollTouchStart()}),e.addEventListener("keydown",t=>{this.__onMonthCalendarKeyDown(t)}),e.addEventListener("init-done",()=>{const t=[...this.querySelectorAll("vaadin-month-calendar")];t.forEach(i=>{i.addEventListener("selected-date-changed",o=>{this.selectedDate=o.detail.value})}),this.calendars=t}),this._monthScroller=e}}))}__initYearScroller(){this.addController(new xe(this,"years","vaadin-date-picker-year-scroller",{observe:!1,initializer:e=>{e.setAttribute("aria-hidden","true"),Fe(e,"tap",t=>{this._onYearTap(t)}),e.addEventListener("custom-scroll",()=>{this._onYearScroll()}),e.addEventListener("touchstart",()=>{this._onYearScrollTouchStart()}),e.addEventListener("init-done",()=>{this.years=[...this.querySelectorAll("vaadin-date-picker-year")]}),this._yearScroller=e}}))}__updateCancelButton(e,t){e&&(e.textContent=t&&t.cancel)}__updateTodayButton(e,t,i,o,n){e&&(e.textContent=t&&t.today,e.disabled=!this._isTodayAllowed(i,o,n))}__updateCalendars(e,t,i,o,n,a,s,l,d,u){e&&e.length&&e.forEach(c=>{c.i18n=t,c.minDate=i,c.maxDate=o,c.isDateDisabled=u,c.focusedDate=a,c.selectedDate=n,c.showWeekNumbers=s,c.ignoreTaps=l,d?c.setAttribute("theme",d):c.removeAttribute("theme")})}__updateYears(e,t,i){e&&e.length&&e.forEach(o=>{o.selectedDate=t,i?o.setAttribute("theme",i):o.removeAttribute("theme")})}_selectDate(e){return this._dateAllowed(e)?(this.selectedDate=e,this.dispatchEvent(new CustomEvent("date-selected",{detail:{date:e},bubbles:!0,composed:!0})),!0):!1}_desktopModeChanged(e){this.toggleAttribute("desktop",e)}_focusedDateChanged(e){this.revealDate(e)}revealDate(e,t=!0){if(!e)return;const i=this._differenceInMonths(e,this._originDate);if(this.__useSubMonthScrolling){const s=this._calculateWeekScrollOffset(e);this._scrollToPosition(i+s,t);return}const o=this._monthScroller.position>i,n=Math.max(this._monthScroller.itemHeight,this._monthScroller.clientHeight-this._monthScroller.bufferOffset*2)/this._monthScroller.itemHeight,a=this._monthScroller.position+n-1<i;o?this._scrollToPosition(i,t):a&&this._scrollToPosition(i-n+1,t)}_calculateWeekScrollOffset(e){const t=new Date(0,0);t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(1);let i=0;for(;t.getDate()<e.getDate();)t.setDate(t.getDate()+1),t.getDay()===this.i18n.firstDayOfWeek&&(i+=1);return i/6}_initialPositionChanged(e){this._monthScroller&&this._yearScroller&&(this._monthScroller.active=!0,this._yearScroller.active=!0),this.scrollToDate(e)}_repositionYearScroller(){const e=this._monthScroller.position;this._visibleMonthIndex=Math.floor(e),this._yearScroller.position=(e+this._originDate.getMonth())/12}_repositionMonthScroller(){this._monthScroller.position=this._yearScroller.position*12-this._originDate.getMonth(),this._visibleMonthIndex=Math.floor(this._monthScroller.position)}_onMonthScroll(){this._repositionYearScroller(),this._doIgnoreTaps()}_onYearScroll(){this._repositionMonthScroller(),this._doIgnoreTaps()}_onYearScrollTouchStart(){this._notTapping=!1,setTimeout(()=>{this._notTapping=!0},300),this._repositionMonthScroller()}_onMonthScrollTouchStart(){this._repositionYearScroller()}_doIgnoreTaps(){this._ignoreTaps=!0,this._debouncer=De.debounce(this._debouncer,at.after(300),()=>{this._ignoreTaps=!1})}_formatDisplayed(e,t,i){return e&&t&&typeof t.formatDate=="function"?t.formatDate(da(e)):i}_onTodayTap(){const e=this._getTodayMidnight();Math.abs(this._monthScroller.position-this._differenceInMonths(e,this._originDate))<.001?(this._selectDate(e),this._close()):this._scrollToCurrentMonth()}_scrollToCurrentMonth(){this.focusedDate&&(this.focusedDate=new Date),this.scrollToDate(new Date,!0)}_onYearTap(e){if(!this._ignoreTaps&&!this._notTapping){const t=(e.detail.y-(this._yearScroller.getBoundingClientRect().top+this._yearScroller.clientHeight/2))/this._yearScroller.itemHeight;this._scrollToPosition(this._monthScroller.position+t*12,!0)}}_scrollToPosition(e,t){if(this._targetPosition!==void 0){this._targetPosition=e;return}if(!t){this._monthScroller.position=e,this._monthScroller.forceUpdate(),this._targetPosition=void 0,this._repositionYearScroller(),this.__tryFocusDate();return}this._targetPosition=e;let i;this._revealPromise=new Promise(l=>{i=l});const o=(l,d,u,c)=>(l/=c/2,l<1?u/2*l*l+d:(l-=1,-u/2*(l*(l-2)-1)+d));let n=0;const a=this._monthScroller.position,s=l=>{n||(n=l);const d=l-n;if(d<this.scrollDuration){const u=o(d,a,this._targetPosition-a,this.scrollDuration);this._monthScroller.position=u,window.requestAnimationFrame(s)}else this.dispatchEvent(new CustomEvent("scroll-animation-finished",{bubbles:!0,composed:!0,detail:{position:this._targetPosition,oldPosition:a}})),this._monthScroller.position=this._targetPosition,this._monthScroller.forceUpdate(),this._targetPosition=void 0,i(),this._revealPromise=void 0;setTimeout(this._repositionYearScroller.bind(this),1)};window.requestAnimationFrame(s)}_limit(e,t){return Math.min(t.max,Math.max(t.min,e))}_handleTrack(e){if(Math.abs(e.detail.dx)<10||Math.abs(e.detail.ddy)>10)return;Math.abs(e.detail.ddx)>this._yearScrollerWidth/3&&this._toggleAnimateClass(!0);const t=this._translateX+e.detail.ddx;this._translateX=this._limit(t,{min:0,max:this._yearScrollerWidth})}_track(e){if(!this._desktopMode)switch(e.detail.state){case"start":this._toggleAnimateClass(!1);break;case"track":this._handleTrack(e);break;case"end":this._toggleAnimateClass(!0),this._translateX>=this._yearScrollerWidth/2?this._closeYearScroller():this._openYearScroller();break}}_toggleAnimateClass(e){e?this.classList.add("animate"):this.classList.remove("animate")}_toggleYearScroller(){this._isYearScrollerVisible()?this._closeYearScroller():this._openYearScroller()}_openYearScroller(){this._translateX=0,this.setAttribute("years-visible","")}_closeYearScroller(){this.removeAttribute("years-visible"),this._translateX=this._yearScrollerWidth}_isYearScrollerVisible(){return this._translateX<this._yearScrollerWidth/2}_translateXChanged(e){this._desktopMode||(this._monthScroller.style.transform=`translateX(${e-this._yearScrollerWidth}px)`,this._yearScroller.style.transform=`translateX(${e}px)`)}_yearAfterXMonths(e){return wu(e).getFullYear()}_differenceInMonths(e,t){return(e.getFullYear()-t.getFullYear())*12-t.getMonth()+e.getMonth()}_clear(){this._selectDate("")}_close(){this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}_cancel(){this.focusedDate=this.selectedDate,this._close()}_preventDefault(e){e.preventDefault()}__toggleDate(e){Ke(e,this.selectedDate)?(this._clear(),this.focusedDate=e):this._selectDate(e)}__onMonthCalendarKeyDown(e){let t=!1;switch(e.key){case"ArrowDown":this._moveFocusByDays(7),t=!0;break;case"ArrowUp":this._moveFocusByDays(-7),t=!0;break;case"ArrowRight":this._moveFocusByDays(this.__isRTL?-1:1),t=!0;break;case"ArrowLeft":this._moveFocusByDays(this.__isRTL?1:-1),t=!0;break;case"Enter":this._selectDate(this.focusedDate)&&(this._close(),t=!0);break;case" ":this.__toggleDate(this.focusedDate),t=!0;break;case"Home":this._moveFocusInsideMonth(this.focusedDate,"minDate"),t=!0;break;case"End":this._moveFocusInsideMonth(this.focusedDate,"maxDate"),t=!0;break;case"PageDown":this._moveFocusByMonths(e.shiftKey?12:1),t=!0;break;case"PageUp":this._moveFocusByMonths(e.shiftKey?-12:-1),t=!0;break;case"Tab":this._onTabKeyDown(e,"calendar");break}t&&(e.preventDefault(),e.stopPropagation())}_onTabKeyDown(e,t){switch(e.stopPropagation(),t){case"calendar":e.shiftKey&&(e.preventDefault(),this.hasAttribute("fullscreen")?this.focusCancel():this.__focusInput());break;case"today":e.shiftKey&&(e.preventDefault(),this.focusDateElement());break;case"cancel":e.shiftKey||(e.preventDefault(),this.hasAttribute("fullscreen")?this.focusDateElement():this.__focusInput());break}}__onTodayButtonKeyDown(e){e.key==="Tab"&&this._onTabKeyDown(e,"today")}__onCancelButtonKeyDown(e){e.key==="Tab"&&this._onTabKeyDown(e,"cancel")}__focusInput(){this.dispatchEvent(new CustomEvent("focus-input",{bubbles:!0,composed:!0}))}__tryFocusDate(){if(this.__pendingDateFocus){const e=this.focusableDateElement;e&&Ke(e.date,this.__pendingDateFocus)&&(delete this.__pendingDateFocus,e.focus())}}focusDate(e,t){return Ii(this,null,function*(){const i=e||this.selectedDate||this.initialPosition||new Date;this.focusedDate=i,t||(this._focusedMonthDate=i.getDate()),yield this.focusDateElement(!1)})}focusDateElement(e=!0){return Ii(this,null,function*(){this.__pendingDateFocus=this.focusedDate,this.calendars.length||(yield new Promise(t=>{na(this,()=>{ua(),t()})})),e&&this.revealDate(this.focusedDate),this._revealPromise&&(yield this._revealPromise),this.__tryFocusDate()})}_focusClosestDate(e){this.focusDate(yu(e,[this.minDate,this.maxDate]))}_focusAllowedDate(e,t,i){this._dateAllowed(e,void 0,void 0,()=>!1)?this.focusDate(e,i):this._dateAllowed(this.focusedDate)?t>0?this.focusDate(this.maxDate):this.focusDate(this.minDate):this._focusClosestDate(this.focusedDate)}_getDateDiff(e,t){const i=new Date(0,0);return i.setFullYear(this.focusedDate.getFullYear()),i.setMonth(this.focusedDate.getMonth()+e),t&&i.setDate(this.focusedDate.getDate()+t),i}_moveFocusByDays(e){const t=this._getDateDiff(0,e);this._focusAllowedDate(t,e,!1)}_moveFocusByMonths(e){const t=this._getDateDiff(e),i=t.getMonth();this._focusedMonthDate||(this._focusedMonthDate=this.focusedDate.getDate()),t.setDate(this._focusedMonthDate),t.getMonth()!==i&&t.setDate(0),this._focusAllowedDate(t,e,!0)}_moveFocusInsideMonth(e,t){const i=new Date(0,0);i.setFullYear(e.getFullYear()),t==="minDate"?(i.setMonth(e.getMonth()),i.setDate(1)):(i.setMonth(e.getMonth()+1),i.setDate(0)),this._dateAllowed(i)?this.focusDate(i):this._dateAllowed(e)?this.focusDate(this[t]):this._focusClosestDate(e)}_dateAllowed(e,t=this.minDate,i=this.maxDate,o=this.isDateDisabled){return Jt(e,t,i,o)}_isTodayAllowed(e,t,i){return this._dateAllowed(this._getTodayMidnight(),e,t,i)}_getTodayMidnight(){const e=new Date,t=new Date(0,0);return t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(e.getDate()),t}};/**
|
|
3847
|
+
*/const qb=r=>class extends r{static get properties(){return{scrollDuration:{type:Number,value:300},selectedDate:{type:Object,value:null,sync:!0},focusedDate:{type:Object,notify:!0,observer:"_focusedDateChanged",sync:!0},_focusedMonthDate:Number,initialPosition:{type:Object,observer:"_initialPositionChanged"},_originDate:{type:Object,value:new Date},_visibleMonthIndex:Number,_desktopMode:{type:Boolean,observer:"_desktopModeChanged"},_desktopMediaQuery:{type:String,value:"(min-width: 375px)"},_translateX:{observer:"_translateXChanged"},_yearScrollerWidth:{value:50},i18n:{type:Object},showWeekNumbers:{type:Boolean,value:!1},_ignoreTaps:Boolean,_notTapping:Boolean,minDate:{type:Object,sync:!0},maxDate:{type:Object,sync:!0},isDateDisabled:{type:Function},label:String,_cancelButton:{type:Object},_todayButton:{type:Object},calendars:{type:Array,value:()=>[]},years:{type:Array,value:()=>[]}}}static get observers(){return["__updateCalendars(calendars, i18n, minDate, maxDate, selectedDate, focusedDate, showWeekNumbers, _ignoreTaps, _theme, isDateDisabled)","__updateCancelButton(_cancelButton, i18n)","__updateTodayButton(_todayButton, i18n, minDate, maxDate, isDateDisabled)","__updateYears(years, selectedDate, _theme)"]}get __useSubMonthScrolling(){return this._monthScroller.clientHeight<this._monthScroller.itemHeight+this._monthScroller.bufferOffset}get focusableDateElement(){return this.calendars.map(e=>e.focusableDateElement).find(Boolean)}_addListeners(){ou(this.$.scrollers,"pan-y"),Re(this.$.scrollers,"track",this._track.bind(this)),Re(this.shadowRoot.querySelector('[part="clear-button"]'),"tap",this._clear.bind(this)),Re(this.shadowRoot.querySelector('[part="toggle-button"]'),"tap",this._cancel.bind(this)),Re(this.shadowRoot.querySelector('[part="years-toggle-button"]'),"tap",this._toggleYearScroller.bind(this))}_initControllers(){this.addController(new pa(this._desktopMediaQuery,e=>{this._desktopMode=e})),this.addController(new xe(this,"today-button","vaadin-button",{observe:!1,initializer:e=>{e.setAttribute("theme","tertiary"),e.addEventListener("keydown",t=>this.__onTodayButtonKeyDown(t)),Re(e,"tap",this._onTodayTap.bind(this)),this._todayButton=e}})),this.addController(new xe(this,"cancel-button","vaadin-button",{observe:!1,initializer:e=>{e.setAttribute("theme","tertiary"),e.addEventListener("keydown",t=>this.__onCancelButtonKeyDown(t)),Re(e,"tap",this._cancel.bind(this)),this._cancelButton=e}})),this.__initMonthScroller(),this.__initYearScroller()}reset(){this._closeYearScroller(),this._toggleAnimateClass(!0)}focusCancel(){this._cancelButton.focus()}scrollToDate(e,t){const i=this.__useSubMonthScrolling?this._calculateWeekScrollOffset(e):0;this._scrollToPosition(this._differenceInMonths(e,this._originDate)+i,t),this._monthScroller.forceUpdate()}__initMonthScroller(){this.addController(new xe(this,"months","vaadin-date-picker-month-scroller",{observe:!1,initializer:e=>{e.addEventListener("custom-scroll",()=>{this._onMonthScroll()}),e.addEventListener("touchstart",()=>{this._onMonthScrollTouchStart()}),e.addEventListener("keydown",t=>{this.__onMonthCalendarKeyDown(t)}),e.addEventListener("init-done",()=>{const t=[...this.querySelectorAll("vaadin-month-calendar")];t.forEach(i=>{i.addEventListener("selected-date-changed",o=>{this.selectedDate=o.detail.value})}),this.calendars=t}),this._monthScroller=e}}))}__initYearScroller(){this.addController(new xe(this,"years","vaadin-date-picker-year-scroller",{observe:!1,initializer:e=>{e.setAttribute("aria-hidden","true"),Re(e,"tap",t=>{this._onYearTap(t)}),e.addEventListener("custom-scroll",()=>{this._onYearScroll()}),e.addEventListener("touchstart",()=>{this._onYearScrollTouchStart()}),e.addEventListener("init-done",()=>{this.years=[...this.querySelectorAll("vaadin-date-picker-year")]}),this._yearScroller=e}}))}__updateCancelButton(e,t){e&&(e.textContent=t&&t.cancel)}__updateTodayButton(e,t,i,o,n){e&&(e.textContent=t&&t.today,e.disabled=!this._isTodayAllowed(i,o,n))}__updateCalendars(e,t,i,o,n,a,s,l,d,u){e&&e.length&&e.forEach(c=>{c.i18n=t,c.minDate=i,c.maxDate=o,c.isDateDisabled=u,c.focusedDate=a,c.selectedDate=n,c.showWeekNumbers=s,c.ignoreTaps=l,d?c.setAttribute("theme",d):c.removeAttribute("theme")})}__updateYears(e,t,i){e&&e.length&&e.forEach(o=>{o.selectedDate=t,i?o.setAttribute("theme",i):o.removeAttribute("theme")})}_selectDate(e){return this._dateAllowed(e)?(this.selectedDate=e,this.dispatchEvent(new CustomEvent("date-selected",{detail:{date:e},bubbles:!0,composed:!0})),!0):!1}_desktopModeChanged(e){this.toggleAttribute("desktop",e)}_focusedDateChanged(e){this.revealDate(e)}revealDate(e,t=!0){if(!e)return;const i=this._differenceInMonths(e,this._originDate);if(this.__useSubMonthScrolling){const s=this._calculateWeekScrollOffset(e);this._scrollToPosition(i+s,t);return}const o=this._monthScroller.position>i,n=Math.max(this._monthScroller.itemHeight,this._monthScroller.clientHeight-this._monthScroller.bufferOffset*2)/this._monthScroller.itemHeight,a=this._monthScroller.position+n-1<i;o?this._scrollToPosition(i,t):a&&this._scrollToPosition(i-n+1,t)}_calculateWeekScrollOffset(e){const t=new Date(0,0);t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(1);let i=0;for(;t.getDate()<e.getDate();)t.setDate(t.getDate()+1),t.getDay()===this.i18n.firstDayOfWeek&&(i+=1);return i/6}_initialPositionChanged(e){this._monthScroller&&this._yearScroller&&(this._monthScroller.active=!0,this._yearScroller.active=!0),this.scrollToDate(e)}_repositionYearScroller(){const e=this._monthScroller.position;this._visibleMonthIndex=Math.floor(e),this._yearScroller.position=(e+this._originDate.getMonth())/12}_repositionMonthScroller(){this._monthScroller.position=this._yearScroller.position*12-this._originDate.getMonth(),this._visibleMonthIndex=Math.floor(this._monthScroller.position)}_onMonthScroll(){this._repositionYearScroller(),this._doIgnoreTaps()}_onYearScroll(){this._repositionMonthScroller(),this._doIgnoreTaps()}_onYearScrollTouchStart(){this._notTapping=!1,setTimeout(()=>{this._notTapping=!0},300),this._repositionMonthScroller()}_onMonthScrollTouchStart(){this._repositionYearScroller()}_doIgnoreTaps(){this._ignoreTaps=!0,this._debouncer=Se.debounce(this._debouncer,nt.after(300),()=>{this._ignoreTaps=!1})}_formatDisplayed(e,t,i){return e&&t&&typeof t.formatDate=="function"?t.formatDate(da(e)):i}_onTodayTap(){const e=this._getTodayMidnight();Math.abs(this._monthScroller.position-this._differenceInMonths(e,this._originDate))<.001?(this._selectDate(e),this._close()):this._scrollToCurrentMonth()}_scrollToCurrentMonth(){this.focusedDate&&(this.focusedDate=new Date),this.scrollToDate(new Date,!0)}_onYearTap(e){if(!this._ignoreTaps&&!this._notTapping){const t=(e.detail.y-(this._yearScroller.getBoundingClientRect().top+this._yearScroller.clientHeight/2))/this._yearScroller.itemHeight;this._scrollToPosition(this._monthScroller.position+t*12,!0)}}_scrollToPosition(e,t){if(this._targetPosition!==void 0){this._targetPosition=e;return}if(!t){this._monthScroller.position=e,this._monthScroller.forceUpdate(),this._targetPosition=void 0,this._repositionYearScroller(),this.__tryFocusDate();return}this._targetPosition=e;let i;this._revealPromise=new Promise(l=>{i=l});const o=(l,d,u,c)=>(l/=c/2,l<1?u/2*l*l+d:(l-=1,-u/2*(l*(l-2)-1)+d));let n=0;const a=this._monthScroller.position,s=l=>{n||(n=l);const d=l-n;if(d<this.scrollDuration){const u=o(d,a,this._targetPosition-a,this.scrollDuration);this._monthScroller.position=u,window.requestAnimationFrame(s)}else this.dispatchEvent(new CustomEvent("scroll-animation-finished",{bubbles:!0,composed:!0,detail:{position:this._targetPosition,oldPosition:a}})),this._monthScroller.position=this._targetPosition,this._monthScroller.forceUpdate(),this._targetPosition=void 0,i(),this._revealPromise=void 0;setTimeout(this._repositionYearScroller.bind(this),1)};window.requestAnimationFrame(s)}_limit(e,t){return Math.min(t.max,Math.max(t.min,e))}_handleTrack(e){if(Math.abs(e.detail.dx)<10||Math.abs(e.detail.ddy)>10)return;Math.abs(e.detail.ddx)>this._yearScrollerWidth/3&&this._toggleAnimateClass(!0);const t=this._translateX+e.detail.ddx;this._translateX=this._limit(t,{min:0,max:this._yearScrollerWidth})}_track(e){if(!this._desktopMode)switch(e.detail.state){case"start":this._toggleAnimateClass(!1);break;case"track":this._handleTrack(e);break;case"end":this._toggleAnimateClass(!0),this._translateX>=this._yearScrollerWidth/2?this._closeYearScroller():this._openYearScroller();break}}_toggleAnimateClass(e){e?this.classList.add("animate"):this.classList.remove("animate")}_toggleYearScroller(){this._isYearScrollerVisible()?this._closeYearScroller():this._openYearScroller()}_openYearScroller(){this._translateX=0,this.setAttribute("years-visible","")}_closeYearScroller(){this.removeAttribute("years-visible"),this._translateX=this._yearScrollerWidth}_isYearScrollerVisible(){return this._translateX<this._yearScrollerWidth/2}_translateXChanged(e){this._desktopMode||(this._monthScroller.style.transform=`translateX(${e-this._yearScrollerWidth}px)`,this._yearScroller.style.transform=`translateX(${e}px)`)}_yearAfterXMonths(e){return wu(e).getFullYear()}_differenceInMonths(e,t){return(e.getFullYear()-t.getFullYear())*12-t.getMonth()+e.getMonth()}_clear(){this._selectDate("")}_close(){this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}_cancel(){this.focusedDate=this.selectedDate,this._close()}_preventDefault(e){e.preventDefault()}__toggleDate(e){Xe(e,this.selectedDate)?(this._clear(),this.focusedDate=e):this._selectDate(e)}__onMonthCalendarKeyDown(e){let t=!1;switch(e.key){case"ArrowDown":this._moveFocusByDays(7),t=!0;break;case"ArrowUp":this._moveFocusByDays(-7),t=!0;break;case"ArrowRight":this._moveFocusByDays(this.__isRTL?-1:1),t=!0;break;case"ArrowLeft":this._moveFocusByDays(this.__isRTL?1:-1),t=!0;break;case"Enter":this._selectDate(this.focusedDate)&&(this._close(),t=!0);break;case" ":this.__toggleDate(this.focusedDate),t=!0;break;case"Home":this._moveFocusInsideMonth(this.focusedDate,"minDate"),t=!0;break;case"End":this._moveFocusInsideMonth(this.focusedDate,"maxDate"),t=!0;break;case"PageDown":this._moveFocusByMonths(e.shiftKey?12:1),t=!0;break;case"PageUp":this._moveFocusByMonths(e.shiftKey?-12:-1),t=!0;break;case"Tab":this._onTabKeyDown(e,"calendar");break}t&&(e.preventDefault(),e.stopPropagation())}_onTabKeyDown(e,t){switch(e.stopPropagation(),t){case"calendar":e.shiftKey&&(e.preventDefault(),this.hasAttribute("fullscreen")?this.focusCancel():this.__focusInput());break;case"today":e.shiftKey&&(e.preventDefault(),this.focusDateElement());break;case"cancel":e.shiftKey||(e.preventDefault(),this.hasAttribute("fullscreen")?this.focusDateElement():this.__focusInput());break}}__onTodayButtonKeyDown(e){e.key==="Tab"&&this._onTabKeyDown(e,"today")}__onCancelButtonKeyDown(e){e.key==="Tab"&&this._onTabKeyDown(e,"cancel")}__focusInput(){this.dispatchEvent(new CustomEvent("focus-input",{bubbles:!0,composed:!0}))}__tryFocusDate(){if(this.__pendingDateFocus){const e=this.focusableDateElement;e&&Xe(e.date,this.__pendingDateFocus)&&(delete this.__pendingDateFocus,e.focus())}}focusDate(e,t){return Ii(this,null,function*(){const i=e||this.selectedDate||this.initialPosition||new Date;this.focusedDate=i,t||(this._focusedMonthDate=i.getDate()),yield this.focusDateElement(!1)})}focusDateElement(e=!0){return Ii(this,null,function*(){this.__pendingDateFocus=this.focusedDate,this.calendars.length||(yield new Promise(t=>{na(this,()=>{ua(),t()})})),e&&this.revealDate(this.focusedDate),this._revealPromise&&(yield this._revealPromise),this.__tryFocusDate()})}_focusClosestDate(e){this.focusDate(yu(e,[this.minDate,this.maxDate]))}_focusAllowedDate(e,t,i){this._dateAllowed(e,void 0,void 0,()=>!1)?this.focusDate(e,i):this._dateAllowed(this.focusedDate)?t>0?this.focusDate(this.maxDate):this.focusDate(this.minDate):this._focusClosestDate(this.focusedDate)}_getDateDiff(e,t){const i=new Date(0,0);return i.setFullYear(this.focusedDate.getFullYear()),i.setMonth(this.focusedDate.getMonth()+e),t&&i.setDate(this.focusedDate.getDate()+t),i}_moveFocusByDays(e){const t=this._getDateDiff(0,e);this._focusAllowedDate(t,e,!1)}_moveFocusByMonths(e){const t=this._getDateDiff(e),i=t.getMonth();this._focusedMonthDate||(this._focusedMonthDate=this.focusedDate.getDate()),t.setDate(this._focusedMonthDate),t.getMonth()!==i&&t.setDate(0),this._focusAllowedDate(t,e,!0)}_moveFocusInsideMonth(e,t){const i=new Date(0,0);i.setFullYear(e.getFullYear()),t==="minDate"?(i.setMonth(e.getMonth()),i.setDate(1)):(i.setMonth(e.getMonth()+1),i.setDate(0)),this._dateAllowed(i)?this.focusDate(i):this._dateAllowed(e)?this.focusDate(this[t]):this._focusClosestDate(e)}_dateAllowed(e,t=this.minDate,i=this.maxDate,o=this.isDateDisabled){return Jt(e,t,i,o)}_isTodayAllowed(e,t,i){return this._dateAllowed(this._getTodayMidnight(),e,t,i)}_getTodayMidnight(){const e=new Date,t=new Date(0,0);return t.setFullYear(e.getFullYear()),t.setMonth(e.getMonth()),t.setDate(e.getDate()),t}};/**
|
|
3848
3848
|
* @license
|
|
3849
3849
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3850
3850
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3851
|
-
*/const
|
|
3851
|
+
*/const Yb=v`
|
|
3852
3852
|
:host {
|
|
3853
3853
|
display: flex;
|
|
3854
3854
|
flex-direction: column;
|
|
@@ -3912,7 +3912,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3912
3912
|
* @license
|
|
3913
3913
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
3914
3914
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3915
|
-
*/
|
|
3915
|
+
*/x("vaadin-date-picker-overlay-content",Yb,{moduleId:"vaadin-date-picker-overlay-content-styles"});class Gb extends qb(Ue(X(Oe(H)))){static get template(){return z`
|
|
3916
3916
|
<div part="overlay-header" on-touchend="_preventDefault" aria-hidden="true">
|
|
3917
3917
|
<div part="label">[[_formatDisplayed(selectedDate, i18n, label)]]</div>
|
|
3918
3918
|
<div part="clear-button" hidden$="[[!selectedDate]]"></div>
|
|
@@ -3932,32 +3932,32 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3932
3932
|
<slot name="today-button"></slot>
|
|
3933
3933
|
<slot name="cancel-button"></slot>
|
|
3934
3934
|
</div>
|
|
3935
|
-
`}static get is(){return"vaadin-date-picker-overlay-content"}ready(){super.ready(),this.setAttribute("role","dialog"),this._addListeners(),this._initControllers()}}
|
|
3935
|
+
`}static get is(){return"vaadin-date-picker-overlay-content"}ready(){super.ready(),this.setAttribute("role","dialog"),this._addListeners(),this._initControllers()}}k(Gb);/**
|
|
3936
3936
|
* @license
|
|
3937
3937
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3938
3938
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3939
|
-
*/const Do=new WeakMap;function
|
|
3939
|
+
*/const Do=new WeakMap;function Xb(r){return Do.has(r)||Do.set(r,new Set),Do.get(r)}function Kb(r,e){const t=document.createElement("style");t.textContent=r,e===document?document.head.appendChild(t):e.insertBefore(t,e.firstChild)}const Au=le(r=>class extends r{get slotStyles(){return{}}connectedCallback(){super.connectedCallback(),this.__applySlotStyles()}__applySlotStyles(){const e=this.getRootNode(),t=Xb(e);this.slotStyles.forEach(i=>{t.has(i)||(Kb(i,e),t.add(i))})}});/**
|
|
3940
3940
|
* @license
|
|
3941
3941
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3942
3942
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3943
|
-
*/const
|
|
3943
|
+
*/const Qb=r=>class extends Yr(Ct(r)){static get properties(){return{clearButtonVisible:{type:Boolean,reflectToAttribute:!0,value:!1}}}get clearElement(){return console.warn(`Please implement the 'clearElement' property in <${this.localName}>`),null}ready(){super.ready(),this.clearElement&&(this.clearElement.addEventListener("mousedown",e=>this._onClearButtonMouseDown(e)),this.clearElement.addEventListener("click",e=>this._onClearButtonClick(e)))}_onClearButtonClick(e){e.preventDefault(),this._onClearAction()}_onClearButtonMouseDown(e){e.preventDefault(),gn||this.inputElement.focus()}_onEscape(e){super._onEscape(e),this.clearButtonVisible&&this.value&&!this.readonly&&(e.stopPropagation(),this._onClearAction())}_onClearAction(){this._inputElementValue="",this.inputElement.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),this.inputElement.dispatchEvent(new Event("change",{bubbles:!0}))}};/**
|
|
3944
3944
|
* @license
|
|
3945
3945
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3946
3946
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3947
|
-
*/const ma=
|
|
3947
|
+
*/const ma=le(r=>class extends Jn(ta(Yr(r))){static get constraints(){return["required"]}static get delegateAttrs(){return[...super.delegateAttrs,"required"]}ready(){super.ready(),this._createConstraintsObserver()}checkValidity(){return this.inputElement&&this._hasValidConstraints(this.constructor.constraints.map(e=>this[e]))?this.inputElement.checkValidity():!this.invalid}_hasValidConstraints(e){return e.some(t=>this.__isValidConstraint(t))}_createConstraintsObserver(){this._createMethodObserver(`_constraintsChanged(stateTarget, ${this.constructor.constraints.join(", ")})`)}_constraintsChanged(e,...t){if(!e)return;const i=this._hasValidConstraints(t),o=this.__previousHasConstraints&&!i;(this._hasValue||this.invalid)&&i?this.validate():o&&this._setInvalid(!1),this.__previousHasConstraints=i}_onChange(e){e.stopPropagation(),this.validate(),this.dispatchEvent(new CustomEvent("change",{detail:{sourceEvent:e},bubbles:e.bubbles,cancelable:e.cancelable}))}__isValidConstraint(e){return!!e||e===0}});/**
|
|
3948
3948
|
* @license
|
|
3949
3949
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3950
3950
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3951
|
-
*/const ro=r=>class extends Au(Ji(ma(Zi(
|
|
3951
|
+
*/const ro=r=>class extends Au(Ji(ma(Zi(Qb(Ct(r)))))){static get properties(){return{allowedCharPattern:{type:String,observer:"_allowedCharPatternChanged"},autoselect:{type:Boolean,value:!1},name:{type:String,reflectToAttribute:!0},placeholder:{type:String,reflectToAttribute:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},title:{type:String,reflectToAttribute:!0}}}static get delegateAttrs(){return[...super.delegateAttrs,"name","type","placeholder","readonly","invalid","title"]}constructor(){super(),this._boundOnPaste=this._onPaste.bind(this),this._boundOnDrop=this._onDrop.bind(this),this._boundOnBeforeInput=this._onBeforeInput.bind(this)}get slotStyles(){return[`
|
|
3952
3952
|
:is(input[slot='input'], textarea[slot='textarea'])::placeholder {
|
|
3953
3953
|
font: inherit;
|
|
3954
3954
|
color: inherit;
|
|
3955
3955
|
}
|
|
3956
|
-
`]}_onFocus(e){super._onFocus(e),this.autoselect&&this.inputElement&&this.inputElement.select()}_onChange(e){e.stopPropagation(),this.validate(),this.dispatchEvent(new CustomEvent("change",{detail:{sourceEvent:e},bubbles:e.bubbles,cancelable:e.cancelable}))}_addInputListeners(e){super._addInputListeners(e),e.addEventListener("paste",this._boundOnPaste),e.addEventListener("drop",this._boundOnDrop),e.addEventListener("beforeinput",this._boundOnBeforeInput)}_removeInputListeners(e){super._removeInputListeners(e),e.removeEventListener("paste",this._boundOnPaste),e.removeEventListener("drop",this._boundOnDrop),e.removeEventListener("beforeinput",this._boundOnBeforeInput)}_onKeyDown(e){super._onKeyDown(e),this.allowedCharPattern&&!this.__shouldAcceptKey(e)&&e.target===this.inputElement&&(e.preventDefault(),this._markInputPrevented())}_markInputPrevented(){this.setAttribute("input-prevented",""),this._preventInputDebouncer=
|
|
3956
|
+
`]}_onFocus(e){super._onFocus(e),this.autoselect&&this.inputElement&&this.inputElement.select()}_onChange(e){e.stopPropagation(),this.validate(),this.dispatchEvent(new CustomEvent("change",{detail:{sourceEvent:e},bubbles:e.bubbles,cancelable:e.cancelable}))}_addInputListeners(e){super._addInputListeners(e),e.addEventListener("paste",this._boundOnPaste),e.addEventListener("drop",this._boundOnDrop),e.addEventListener("beforeinput",this._boundOnBeforeInput)}_removeInputListeners(e){super._removeInputListeners(e),e.removeEventListener("paste",this._boundOnPaste),e.removeEventListener("drop",this._boundOnDrop),e.removeEventListener("beforeinput",this._boundOnBeforeInput)}_onKeyDown(e){super._onKeyDown(e),this.allowedCharPattern&&!this.__shouldAcceptKey(e)&&e.target===this.inputElement&&(e.preventDefault(),this._markInputPrevented())}_markInputPrevented(){this.setAttribute("input-prevented",""),this._preventInputDebouncer=Se.debounce(this._preventInputDebouncer,nt.after(200),()=>{this.removeAttribute("input-prevented")})}__shouldAcceptKey(e){return e.metaKey||e.ctrlKey||!e.key||e.key.length!==1||this.__allowedCharRegExp.test(e.key)}_onPaste(e){if(this.allowedCharPattern){const t=e.clipboardData.getData("text");this.__allowedTextRegExp.test(t)||(e.preventDefault(),this._markInputPrevented())}}_onDrop(e){if(this.allowedCharPattern){const t=e.dataTransfer.getData("text");this.__allowedTextRegExp.test(t)||(e.preventDefault(),this._markInputPrevented())}}_onBeforeInput(e){this.allowedCharPattern&&e.data&&!this.__allowedTextRegExp.test(e.data)&&(e.preventDefault(),this._markInputPrevented())}_allowedCharPatternChanged(e){if(e)try{this.__allowedCharRegExp=new RegExp(`^${e}$`,"u"),this.__allowedTextRegExp=new RegExp(`^${e}*$`,"u")}catch(t){console.error(t)}}};/**
|
|
3957
3957
|
* @license
|
|
3958
3958
|
* Copyright (c) 2021 - 2024 Vaadin Ltd..
|
|
3959
3959
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3960
|
-
*/const
|
|
3960
|
+
*/const Jb=v`
|
|
3961
3961
|
[part='clear-button'] {
|
|
3962
3962
|
display: none;
|
|
3963
3963
|
cursor: default;
|
|
@@ -4024,11 +4024,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4024
4024
|
* @license
|
|
4025
4025
|
* Copyright (c) 2021 - 2024 Vaadin Ltd..
|
|
4026
4026
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4027
|
-
*/const io=[ku,Iu,
|
|
4027
|
+
*/const io=[ku,Iu,Jb];/**
|
|
4028
4028
|
* @license
|
|
4029
4029
|
* Copyright (c) 2023 - 2024 Vaadin Ltd.
|
|
4030
4030
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4031
|
-
*/const
|
|
4031
|
+
*/const Jr=r=>class extends r{static get properties(){return{overlayClass:{type:String},_overlayElement:{type:Object}}}static get observers(){return["__updateOverlayClassNames(overlayClass, _overlayElement)"]}__updateOverlayClassNames(e,t){if(!t||e===void 0)return;const{classList:i}=t;if(this.__initialClasses||(this.__initialClasses=new Set(i)),Array.isArray(this.__previousClasses)){const n=this.__previousClasses.filter(a=>!this.__initialClasses.has(a));n.length>0&&i.remove(...n)}const o=typeof e=="string"?e.split(" ").filter(Boolean):[];o.length>0&&i.add(...o),this.__previousClasses=o}};/**
|
|
4032
4032
|
* @license
|
|
4033
4033
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4034
4034
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4036,11 +4036,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4036
4036
|
* @license
|
|
4037
4037
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
4038
4038
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4039
|
-
*/const Jb=r=>class extends Zr(We(Ji(ma(xt(r))))){static get properties(){return{_selectedDate:{type:Object,sync:!0},_focusedDate:{type:Object,sync:!0},value:{type:String,notify:!0,value:"",sync:!0},initialPosition:String,opened:{type:Boolean,reflectToAttribute:!0,notify:!0,observer:"_openedChanged",sync:!0},autoOpenDisabled:Boolean,showWeekNumbers:{type:Boolean,value:!1,sync:!0},_fullscreen:{type:Boolean,value:!1,sync:!0},_fullscreenMediaQuery:{value:"(max-width: 450px), (max-height: 450px)"},i18n:{type:Object,sync:!0,value:()=>({monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekdaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDayOfWeek:0,today:"Today",cancel:"Cancel",referenceDate:"",formatDate(e){const t=String(e.year).replace(/\d+/u,i=>"0000".substr(i.length)+i);return[e.month+1,e.day,t].join("/")},parseDate(e){const t=e.split("/"),i=new Date;let o,n=i.getMonth(),a=i.getFullYear();if(t.length===3){if(n=parseInt(t[0])-1,o=parseInt(t[1]),a=parseInt(t[2]),t[2].length<3&&a>=0){const s=this.referenceDate?xr(this.referenceDate):new Date;a=vb(s,a,n,o)}}else t.length===2?(n=parseInt(t[0])-1,o=parseInt(t[1])):t.length===1&&(o=parseInt(t[0]));if(o!==void 0)return{day:o,month:n,year:a}},formatTitle:(e,t)=>`${e} ${t}`})},min:{type:String,sync:!0},max:{type:String,sync:!0},isDateDisabled:{type:Function},_minDate:{type:Date,computed:"__computeMinOrMaxDate(min)",sync:!0},_maxDate:{type:Date,computed:"__computeMinOrMaxDate(max)",sync:!0},_noInput:{type:Boolean,computed:"_isNoInput(inputElement, _fullscreen, _ios, i18n, opened, autoOpenDisabled)"},_ios:{type:Boolean,value:aa},_focusOverlayOnOpen:Boolean,_overlayContent:{type:Object,sync:!0},_hasInputValue:{type:Boolean}}}static get observers(){return["_selectedDateChanged(_selectedDate, i18n)","_focusedDateChanged(_focusedDate, i18n)","__updateOverlayContent(_overlayContent, i18n, label, _minDate, _maxDate, _focusedDate, _selectedDate, showWeekNumbers, isDateDisabled)","__updateOverlayContentTheme(_overlayContent, _theme)","__updateOverlayContentFullScreen(_overlayContent, _fullscreen)"]}static get constraints(){return[...super.constraints,"min","max"]}constructor(){super(),this._boundOnClick=this._onClick.bind(this),this._boundOnScroll=this._onScroll.bind(this),this._boundOverlayRenderer=this._overlayRenderer.bind(this)}get _inputElementValue(){return super._inputElementValue}set _inputElementValue(e){super._inputElementValue=e,this._hasInputValue=!1}get clearElement(){return null}get _nativeInput(){return this.inputElement?this.inputElement.focusElement||this.inputElement:null}get __unparsableValue(){return!this._inputElementValue||this.__parseDate(this._inputElementValue)?"":this._inputElementValue}_onFocus(e){super._onFocus(e),this._noInput&&!Qi()&&e.target.blur()}_onBlur(e){super._onBlur(e),this.opened||(this.__commitParsedOrFocusedDate(),document.hasFocus()&&this.validate())}ready(){super.ready(),this.addEventListener("click",this._boundOnClick),this.addController(new pa(this._fullscreenMediaQuery,t=>{this._fullscreen=t})),this.addController(new Su(this));const e=this.$.overlay;this._overlayElement=e,e.renderer=this._boundOverlayRenderer,this.addEventListener("mousedown",()=>this.__bringToFront()),this.addEventListener("touchstart",()=>this.__bringToFront())}disconnectedCallback(){super.disconnectedCallback(),this.opened=!1}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.$.overlay.close()}_overlayRenderer(e){if(e.firstChild)return;const t=document.createElement("vaadin-date-picker-overlay-content");e.appendChild(t),this._overlayContent=t,t.addEventListener("close",()=>{this._close()}),t.addEventListener("focus-input",this._focusAndSelect.bind(this)),t.addEventListener("date-tap",i=>{this.__commitDate(i.detail.date),this._close()}),t.addEventListener("date-selected",i=>{this.__commitDate(i.detail.date)}),t.addEventListener("focusin",()=>{this._keyboardActive&&this._setFocused(!0)}),t.addEventListener("focusout",i=>{this._shouldRemoveFocus(i)&&this._setFocused(!1)}),t.addEventListener("focused-date-changed",i=>{this._focusedDate=i.detail.value}),t.addEventListener("click",i=>i.stopPropagation())}__parseDate(e){if(!this.i18n.parseDate)return;let t=this.i18n.parseDate(e);if(t&&(t=xr(`${t.year}-${t.month+1}-${t.day}`)),t&&!isNaN(t.getTime()))return t}__formatDate(e){if(this.i18n.formatDate)return this.i18n.formatDate(da(e))}checkValidity(){const e=this._inputElementValue,t=!e||!!this._selectedDate&&e===this.__formatDate(this._selectedDate),i=!this._selectedDate||Jt(this._selectedDate,this._minDate,this._maxDate,this.isDateDisabled);let o=!0;return this.inputElement&&(this.inputElement.checkValidity?o=this.inputElement.checkValidity():this.inputElement.validate&&(o=this.inputElement.validate())),t&&i&&o}_shouldSetFocus(e){return!this._shouldKeepFocusRing}_shouldRemoveFocus(e){const{relatedTarget:t}=e;return this.opened&&t!==null&&t!==document.body&&!this.contains(t)&&!this._overlayContent.contains(t)?!0:!this.opened}_setFocused(e){super._setFocused(e),this._shouldKeepFocusRing=e&&this._keyboardActive}__commitValueChange(){const e=this.__unparsableValue;this.__committedValue!==this.value?(this.validate(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))):this.__committedUnparsableValue!==e&&(this.validate(),this.dispatchEvent(new CustomEvent("unparsable-change"))),this.__committedValue=this.value,this.__committedUnparsableValue=e}__commitDate(e){this.__keepCommittedValue=!0,this._selectedDate=e,this.__keepCommittedValue=!1,this.__commitValueChange()}_close(){this._focus(),this.close()}__bringToFront(){requestAnimationFrame(()=>{this.$.overlay.bringToFront()})}_isNoInput(e,t,i,o,n,a){return!e||t&&(!a||n)||i&&n||!o.parseDate}_formatISO(e){return bb(e)}_inputElementChanged(e){super._inputElementChanged(e),e&&(e.autocomplete="off",e.setAttribute("role","combobox"),e.setAttribute("aria-haspopup","dialog"),e.setAttribute("aria-expanded",!!this.opened),this._applyInputValue(this._selectedDate))}_openedChanged(e){this.inputElement&&this.inputElement.setAttribute("aria-expanded",e)}_selectedDateChanged(e,t){e===void 0||t===void 0||(this.__keepInputValue||this._applyInputValue(e),this.value=this._formatISO(e),this._ignoreFocusedDateChange=!0,this._focusedDate=e,this._ignoreFocusedDateChange=!1)}_focusedDateChanged(e,t){e===void 0||t===void 0||!this._ignoreFocusedDateChange&&!this._noInput&&this._applyInputValue(e)}_valueChanged(e,t){const i=xr(e);if(e&&!i){this.value=t;return}e?Ke(this._selectedDate,i)||(this._selectedDate=i,t!==void 0&&this.validate()):this._selectedDate=null,this.__keepCommittedValue||(this.__committedValue=this.value,this.__committedUnparsableValue=""),this._toggleHasValue(this._hasValue)}__updateOverlayContent(e,t,i,o,n,a,s,l,d){e&&(e.i18n=t,e.label=i,e.minDate=o,e.maxDate=n,e.focusedDate=a,e.selectedDate=s,e.showWeekNumbers=l,e.isDateDisabled=d)}__updateOverlayContentTheme(e,t){e&&(t?e.setAttribute("theme",t):e.removeAttribute("theme"))}__updateOverlayContentFullScreen(e,t){e&&e.toggleAttribute("fullscreen",t)}_onOverlayEscapePress(){this._focusedDate=this._selectedDate,this._closedByEscape=!0,this._close(),this._closedByEscape=!1}_onOverlayOpened(){const e=this._overlayContent;e.reset();const t=this._getInitialPosition();e.initialPosition=t;const i=e.focusedDate||t;e.scrollToDate(i),this._ignoreFocusedDateChange=!0,e.focusedDate=i,this._ignoreFocusedDateChange=!1,window.addEventListener("scroll",this._boundOnScroll,!0),this._focusOverlayOnOpen?(e.focusDateElement(),this._focusOverlayOnOpen=!1):this._focus();const o=this._nativeInput;this._noInput&&o&&(o.blur(),this._overlayContent.focusDateElement());const n=this._noInput?e:[o,e];this.__showOthers=_u(n)}_getInitialPosition(){const e=xr(this.initialPosition),t=this._selectedDate||this._overlayContent.initialPosition||e||new Date;return e||Jt(t,this._minDate,this._maxDate,this.isDateDisabled)?t:this._minDate||this._maxDate?yu(t,[this._minDate,this._maxDate]):new Date}__commitParsedOrFocusedDate(){if(this._ignoreFocusedDateChange=!0,this.i18n.parseDate){const e=this._inputElementValue||"",t=this.__parseDate(e);t?this.__commitDate(t):(this.__keepInputValue=!0,this.__commitDate(null),this.__keepInputValue=!1)}else this._focusedDate&&this.__commitDate(this._focusedDate);this._ignoreFocusedDateChange=!1}_onOverlayClosed(){this.__showOthers&&(this.__showOthers(),this.__showOthers=null),window.removeEventListener("scroll",this._boundOnScroll,!0),this._closedByEscape&&this._applyInputValue(this._selectedDate),this.__commitParsedOrFocusedDate(),this._nativeInput&&this._nativeInput.selectionStart&&(this._nativeInput.selectionStart=this._nativeInput.selectionEnd),!this.value&&!this._keyboardActive&&this.validate()}_onScroll(e){(e.target===window||!this._overlayContent.contains(e.target))&&this._overlayContent._repositionYearScroller()}_focus(){this._noInput||this.inputElement.focus()}_focusAndSelect(){this._focus(),this._setSelectionRange(0,this._inputElementValue.length)}_applyInputValue(e){this._inputElementValue=e?this.__formatDate(e):""}_setSelectionRange(e,t){this._nativeInput&&this._nativeInput.setSelectionRange&&this._nativeInput.setSelectionRange(e,t)}_onChange(e){e.stopPropagation()}_onClick(e){this._isClearButton(e)||this._onHostClick(e)}_onHostClick(e){(!this.autoOpenDisabled||this._noInput)&&(e.preventDefault(),this.open())}_onClearButtonClick(e){e.preventDefault(),this.__commitDate(null)}_onKeyDown(e){switch(super._onKeyDown(e),this._noInput&&[9].indexOf(e.keyCode)===-1&&e.preventDefault(),e.key){case"ArrowDown":case"ArrowUp":e.preventDefault(),this.opened?this._overlayContent.focusDateElement():(this._focusOverlayOnOpen=!0,this.open());break;case"Tab":this.opened&&(e.preventDefault(),e.stopPropagation(),this._setSelectionRange(0,0),e.shiftKey?this._overlayContent.focusCancel():this._overlayContent.focusDateElement());break}}_onEnter(e){this.opened?this.close():this.__commitParsedOrFocusedDate()}_onEscape(e){if(!this.opened){if(this.clearButtonVisible&&this.value&&!this.readonly){e.stopPropagation(),this._onClearButtonClick(e);return}this.inputElement.value===""?this.__commitDate(null):this._applyInputValue(this._selectedDate)}}_isClearButton(e){return e.composedPath()[0]===this.clearElement}_onInput(){if(!this.opened&&this._inputElementValue&&!this.autoOpenDisabled&&this.open(),this._inputElementValue){const e=this.__parseDate(this._inputElementValue);e&&(this._ignoreFocusedDateChange=!0,Ke(e,this._focusedDate)||(this._focusedDate=e),this._ignoreFocusedDateChange=!1)}}__computeMinOrMaxDate(e){return xr(e)}};/**
|
|
4039
|
+
*/const Zb=r=>class extends Jr(Ue(Ji(ma(Ct(r))))){static get properties(){return{_selectedDate:{type:Object,sync:!0},_focusedDate:{type:Object,sync:!0},value:{type:String,notify:!0,value:"",sync:!0},initialPosition:String,opened:{type:Boolean,reflectToAttribute:!0,notify:!0,observer:"_openedChanged",sync:!0},autoOpenDisabled:Boolean,showWeekNumbers:{type:Boolean,value:!1,sync:!0},_fullscreen:{type:Boolean,value:!1,sync:!0},_fullscreenMediaQuery:{value:"(max-width: 450px), (max-height: 450px)"},i18n:{type:Object,sync:!0,value:()=>({monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekdaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDayOfWeek:0,today:"Today",cancel:"Cancel",referenceDate:"",formatDate(e){const t=String(e.year).replace(/\d+/u,i=>"0000".substr(i.length)+i);return[e.month+1,e.day,t].join("/")},parseDate(e){const t=e.split("/"),i=new Date;let o,n=i.getMonth(),a=i.getFullYear();if(t.length===3){if(n=parseInt(t[0])-1,o=parseInt(t[1]),a=parseInt(t[2]),t[2].length<3&&a>=0){const s=this.referenceDate?wr(this.referenceDate):new Date;a=gb(s,a,n,o)}}else t.length===2?(n=parseInt(t[0])-1,o=parseInt(t[1])):t.length===1&&(o=parseInt(t[0]));if(o!==void 0)return{day:o,month:n,year:a}},formatTitle:(e,t)=>`${e} ${t}`})},min:{type:String,sync:!0},max:{type:String,sync:!0},isDateDisabled:{type:Function},_minDate:{type:Date,computed:"__computeMinOrMaxDate(min)",sync:!0},_maxDate:{type:Date,computed:"__computeMinOrMaxDate(max)",sync:!0},_noInput:{type:Boolean,computed:"_isNoInput(inputElement, _fullscreen, _ios, i18n, opened, autoOpenDisabled)"},_ios:{type:Boolean,value:aa},_focusOverlayOnOpen:Boolean,_overlayContent:{type:Object,sync:!0},_hasInputValue:{type:Boolean}}}static get observers(){return["_selectedDateChanged(_selectedDate, i18n)","_focusedDateChanged(_focusedDate, i18n)","__updateOverlayContent(_overlayContent, i18n, label, _minDate, _maxDate, _focusedDate, _selectedDate, showWeekNumbers, isDateDisabled)","__updateOverlayContentTheme(_overlayContent, _theme)","__updateOverlayContentFullScreen(_overlayContent, _fullscreen)"]}static get constraints(){return[...super.constraints,"min","max"]}constructor(){super(),this._boundOnClick=this._onClick.bind(this),this._boundOnScroll=this._onScroll.bind(this),this._boundOverlayRenderer=this._overlayRenderer.bind(this)}get _inputElementValue(){return super._inputElementValue}set _inputElementValue(e){super._inputElementValue=e,this._hasInputValue=!1}get clearElement(){return null}get _nativeInput(){return this.inputElement?this.inputElement.focusElement||this.inputElement:null}get __unparsableValue(){return!this._inputElementValue||this.__parseDate(this._inputElementValue)?"":this._inputElementValue}_onFocus(e){super._onFocus(e),this._noInput&&!Qi()&&e.target.blur()}_onBlur(e){super._onBlur(e),this.opened||(this.__commitParsedOrFocusedDate(),document.hasFocus()&&this.validate())}ready(){super.ready(),this.addEventListener("click",this._boundOnClick),this.addController(new pa(this._fullscreenMediaQuery,t=>{this._fullscreen=t})),this.addController(new Su(this));const e=this.$.overlay;this._overlayElement=e,e.renderer=this._boundOverlayRenderer,this.addEventListener("mousedown",()=>this.__bringToFront()),this.addEventListener("touchstart",()=>this.__bringToFront())}disconnectedCallback(){super.disconnectedCallback(),this.opened=!1}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.$.overlay.close()}_overlayRenderer(e){if(e.firstChild)return;const t=document.createElement("vaadin-date-picker-overlay-content");e.appendChild(t),this._overlayContent=t,t.addEventListener("close",()=>{this._close()}),t.addEventListener("focus-input",this._focusAndSelect.bind(this)),t.addEventListener("date-tap",i=>{this.__commitDate(i.detail.date),this._close()}),t.addEventListener("date-selected",i=>{this.__commitDate(i.detail.date)}),t.addEventListener("focusin",()=>{this._keyboardActive&&this._setFocused(!0)}),t.addEventListener("focusout",i=>{this._shouldRemoveFocus(i)&&this._setFocused(!1)}),t.addEventListener("focused-date-changed",i=>{this._focusedDate=i.detail.value}),t.addEventListener("click",i=>i.stopPropagation())}__parseDate(e){if(!this.i18n.parseDate)return;let t=this.i18n.parseDate(e);if(t&&(t=wr(`${t.year}-${t.month+1}-${t.day}`)),t&&!isNaN(t.getTime()))return t}__formatDate(e){if(this.i18n.formatDate)return this.i18n.formatDate(da(e))}checkValidity(){const e=this._inputElementValue,t=!e||!!this._selectedDate&&e===this.__formatDate(this._selectedDate),i=!this._selectedDate||Jt(this._selectedDate,this._minDate,this._maxDate,this.isDateDisabled);let o=!0;return this.inputElement&&(this.inputElement.checkValidity?o=this.inputElement.checkValidity():this.inputElement.validate&&(o=this.inputElement.validate())),t&&i&&o}_shouldSetFocus(e){return!this._shouldKeepFocusRing}_shouldRemoveFocus(e){const{relatedTarget:t}=e;return this.opened&&t!==null&&t!==document.body&&!this.contains(t)&&!this._overlayContent.contains(t)?!0:!this.opened}_setFocused(e){super._setFocused(e),this._shouldKeepFocusRing=e&&this._keyboardActive}__commitValueChange(){const e=this.__unparsableValue;this.__committedValue!==this.value?(this.validate(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))):this.__committedUnparsableValue!==e&&(this.validate(),this.dispatchEvent(new CustomEvent("unparsable-change"))),this.__committedValue=this.value,this.__committedUnparsableValue=e}__commitDate(e){this.__keepCommittedValue=!0,this._selectedDate=e,this.__keepCommittedValue=!1,this.__commitValueChange()}_close(){this._focus(),this.close()}__bringToFront(){requestAnimationFrame(()=>{this.$.overlay.bringToFront()})}_isNoInput(e,t,i,o,n,a){return!e||t&&(!a||n)||i&&n||!o.parseDate}_formatISO(e){return yb(e)}_inputElementChanged(e){super._inputElementChanged(e),e&&(e.autocomplete="off",e.setAttribute("role","combobox"),e.setAttribute("aria-haspopup","dialog"),e.setAttribute("aria-expanded",!!this.opened),this._applyInputValue(this._selectedDate))}_openedChanged(e){this.inputElement&&this.inputElement.setAttribute("aria-expanded",e)}_selectedDateChanged(e,t){e===void 0||t===void 0||(this.__keepInputValue||this._applyInputValue(e),this.value=this._formatISO(e),this._ignoreFocusedDateChange=!0,this._focusedDate=e,this._ignoreFocusedDateChange=!1)}_focusedDateChanged(e,t){e===void 0||t===void 0||!this._ignoreFocusedDateChange&&!this._noInput&&this._applyInputValue(e)}_valueChanged(e,t){const i=wr(e);if(e&&!i){this.value=t;return}e?Xe(this._selectedDate,i)||(this._selectedDate=i,t!==void 0&&this.validate()):this._selectedDate=null,this.__keepCommittedValue||(this.__committedValue=this.value,this.__committedUnparsableValue=""),this._toggleHasValue(this._hasValue)}__updateOverlayContent(e,t,i,o,n,a,s,l,d){e&&(e.i18n=t,e.label=i,e.minDate=o,e.maxDate=n,e.focusedDate=a,e.selectedDate=s,e.showWeekNumbers=l,e.isDateDisabled=d)}__updateOverlayContentTheme(e,t){e&&(t?e.setAttribute("theme",t):e.removeAttribute("theme"))}__updateOverlayContentFullScreen(e,t){e&&e.toggleAttribute("fullscreen",t)}_onOverlayEscapePress(){this._focusedDate=this._selectedDate,this._closedByEscape=!0,this._close(),this._closedByEscape=!1}_onOverlayOpened(){const e=this._overlayContent;e.reset();const t=this._getInitialPosition();e.initialPosition=t;const i=e.focusedDate||t;e.scrollToDate(i),this._ignoreFocusedDateChange=!0,e.focusedDate=i,this._ignoreFocusedDateChange=!1,window.addEventListener("scroll",this._boundOnScroll,!0),this._focusOverlayOnOpen?(e.focusDateElement(),this._focusOverlayOnOpen=!1):this._focus();const o=this._nativeInput;this._noInput&&o&&(o.blur(),this._overlayContent.focusDateElement());const n=this._noInput?e:[o,e];this.__showOthers=_u(n)}_getInitialPosition(){const e=wr(this.initialPosition),t=this._selectedDate||this._overlayContent.initialPosition||e||new Date;return e||Jt(t,this._minDate,this._maxDate,this.isDateDisabled)?t:this._minDate||this._maxDate?yu(t,[this._minDate,this._maxDate]):new Date}__commitParsedOrFocusedDate(){if(this._ignoreFocusedDateChange=!0,this.i18n.parseDate){const e=this._inputElementValue||"",t=this.__parseDate(e);t?this.__commitDate(t):(this.__keepInputValue=!0,this.__commitDate(null),this.__keepInputValue=!1)}else this._focusedDate&&this.__commitDate(this._focusedDate);this._ignoreFocusedDateChange=!1}_onOverlayClosed(){this.__showOthers&&(this.__showOthers(),this.__showOthers=null),window.removeEventListener("scroll",this._boundOnScroll,!0),this._closedByEscape&&this._applyInputValue(this._selectedDate),this.__commitParsedOrFocusedDate(),this._nativeInput&&this._nativeInput.selectionStart&&(this._nativeInput.selectionStart=this._nativeInput.selectionEnd),!this.value&&!this._keyboardActive&&this.validate()}_onScroll(e){(e.target===window||!this._overlayContent.contains(e.target))&&this._overlayContent._repositionYearScroller()}_focus(){this._noInput||this.inputElement.focus()}_focusAndSelect(){this._focus(),this._setSelectionRange(0,this._inputElementValue.length)}_applyInputValue(e){this._inputElementValue=e?this.__formatDate(e):""}_setSelectionRange(e,t){this._nativeInput&&this._nativeInput.setSelectionRange&&this._nativeInput.setSelectionRange(e,t)}_onChange(e){e.stopPropagation()}_onClick(e){this._isClearButton(e)||this._onHostClick(e)}_onHostClick(e){(!this.autoOpenDisabled||this._noInput)&&(e.preventDefault(),this.open())}_onClearButtonClick(e){e.preventDefault(),this.__commitDate(null)}_onKeyDown(e){switch(super._onKeyDown(e),this._noInput&&[9].indexOf(e.keyCode)===-1&&e.preventDefault(),e.key){case"ArrowDown":case"ArrowUp":e.preventDefault(),this.opened?this._overlayContent.focusDateElement():(this._focusOverlayOnOpen=!0,this.open());break;case"Tab":this.opened&&(e.preventDefault(),e.stopPropagation(),this._setSelectionRange(0,0),e.shiftKey?this._overlayContent.focusCancel():this._overlayContent.focusDateElement());break}}_onEnter(e){this.opened?this.close():this.__commitParsedOrFocusedDate()}_onEscape(e){if(!this.opened){if(this.clearButtonVisible&&this.value&&!this.readonly){e.stopPropagation(),this._onClearButtonClick(e);return}this.inputElement.value===""?this.__commitDate(null):this._applyInputValue(this._selectedDate)}}_isClearButton(e){return e.composedPath()[0]===this.clearElement}_onInput(){if(!this.opened&&this._inputElementValue&&!this.autoOpenDisabled&&this.open(),this._inputElementValue){const e=this.__parseDate(this._inputElementValue);e&&(this._ignoreFocusedDateChange=!0,Xe(e,this._focusedDate)||(this._focusedDate=e),this._ignoreFocusedDateChange=!1)}}__computeMinOrMaxDate(e){return wr(e)}};/**
|
|
4040
4040
|
* @license
|
|
4041
4041
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
4042
4042
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4043
|
-
*/const
|
|
4043
|
+
*/const ey=v`
|
|
4044
4044
|
:host([opened]) {
|
|
4045
4045
|
pointer-events: auto;
|
|
4046
4046
|
}
|
|
@@ -4057,7 +4057,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4057
4057
|
* @license
|
|
4058
4058
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
4059
4059
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4060
|
-
*/
|
|
4060
|
+
*/x("vaadin-date-picker",[io,ey],{moduleId:"vaadin-date-picker-styles"});class ty extends Zb(ro(X(Ne(H)))){static get is(){return"vaadin-date-picker"}static get template(){return z`
|
|
4061
4061
|
<div class="vaadin-date-picker-container">
|
|
4062
4062
|
<div part="label">
|
|
4063
4063
|
<slot name="label"></slot>
|
|
@@ -4099,23 +4099,23 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4099
4099
|
></vaadin-date-picker-overlay>
|
|
4100
4100
|
|
|
4101
4101
|
<slot name="tooltip"></slot>
|
|
4102
|
-
`}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new
|
|
4102
|
+
`}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new Gr(this,e=>{this._setInputElement(e),this._setFocusElement(e),this.stateTarget=e,this.ariaTarget=e},{uniqueIdPrefix:"search-input"})),this.addController(new Xr(this.inputElement,this._labelController)),this._tooltipController=new Qe(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow(e=>!e.opened),this.shadowRoot.querySelector('[part="toggle-button"]').addEventListener("mousedown",e=>e.preventDefault()),this.$.overlay.addEventListener("vaadin-overlay-close",this._onVaadinOverlayClose.bind(this))}_onVaadinOverlayClose(e){e.detail.sourceEvent&&e.detail.sourceEvent.composedPath().includes(this)&&e.preventDefault()}_toggle(e){e.stopPropagation(),this.$.overlay.opened?this.close():this.open()}_openedChanged(e){super._openedChanged(e),this.$.overlay.positionTarget=this.shadowRoot.querySelector('[part="input-field"]'),this.$.overlay.noVerticalOverlap=!0}}k(ty);/**
|
|
4103
4103
|
* @license
|
|
4104
4104
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
4105
4105
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4106
|
-
*/
|
|
4106
|
+
*/x("vaadin-text-field",Tt,{moduleId:"lumo-text-field-styles"});/**
|
|
4107
4107
|
* @license
|
|
4108
4108
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4109
4109
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4110
|
-
*/const
|
|
4110
|
+
*/const ry=r=>class extends ro(r){static get properties(){return{autocomplete:{type:String},autocorrect:{type:String},autocapitalize:{type:String,reflectToAttribute:!0}}}static get delegateAttrs(){return[...super.delegateAttrs,"autocapitalize","autocomplete","autocorrect"]}get __data(){return this.__dataValue||{}}set __data(e){this.__dataValue=e}_inputElementChanged(e){super._inputElementChanged(e),e&&(e.value&&e.value!==this.value&&(console.warn(`Please define value on the <${this.localName}> component!`),e.value=""),this.value&&(e.value=this.value))}_setFocused(e){super._setFocused(e),!e&&document.hasFocus()&&this.validate()}_onInput(e){super._onInput(e),this.invalid&&this.validate()}_valueChanged(e,t){super._valueChanged(e,t),t!==void 0&&this.invalid&&this.validate()}};/**
|
|
4111
4111
|
* @license
|
|
4112
4112
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4113
4113
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4114
|
-
*/const
|
|
4114
|
+
*/const iy=r=>class extends ry(r){static get properties(){return{maxlength:{type:Number},minlength:{type:Number},pattern:{type:String}}}static get delegateAttrs(){return[...super.delegateAttrs,"maxlength","minlength","pattern"]}static get constraints(){return[...super.constraints,"maxlength","minlength","pattern"]}constructor(){super(),this._setType("text")}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new Gr(this,e=>{this._setInputElement(e),this._setFocusElement(e),this.stateTarget=e,this.ariaTarget=e})),this.addController(new Xr(this.inputElement,this._labelController))}};/**
|
|
4115
4115
|
* @license
|
|
4116
4116
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
4117
4117
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4118
|
-
*/
|
|
4118
|
+
*/x("vaadin-text-field",io,{moduleId:"vaadin-text-field-styles"});class Du extends iy(X(Ne(H))){static get is(){return"vaadin-text-field"}static get template(){return z`
|
|
4119
4119
|
<div class="vaadin-field-container">
|
|
4120
4120
|
<div part="label">
|
|
4121
4121
|
<slot name="label"></slot>
|
|
@@ -4144,11 +4144,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4144
4144
|
</div>
|
|
4145
4145
|
</div>
|
|
4146
4146
|
<slot name="tooltip"></slot>
|
|
4147
|
-
`}static get properties(){return{maxlength:{type:Number},minlength:{type:Number}}}ready(){super.ready(),this._tooltipController=new
|
|
4147
|
+
`}static get properties(){return{maxlength:{type:Number},minlength:{type:Number}}}ready(){super.ready(),this._tooltipController=new Qe(this),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this.addController(this._tooltipController)}}k(Du);/**
|
|
4148
4148
|
* @license
|
|
4149
4149
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4150
4150
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4151
|
-
*/const
|
|
4151
|
+
*/const oy=v`
|
|
4152
4152
|
:host {
|
|
4153
4153
|
position: absolute;
|
|
4154
4154
|
right: 0;
|
|
@@ -4161,11 +4161,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4161
4161
|
background: transparent;
|
|
4162
4162
|
outline: none;
|
|
4163
4163
|
}
|
|
4164
|
-
`;
|
|
4164
|
+
`;x("vaadin-password-field-button",[hu,oy],{moduleId:"lumo-password-field-button"});/**
|
|
4165
4165
|
* @license
|
|
4166
4166
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4167
4167
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4168
|
-
*/const
|
|
4168
|
+
*/const ny=v`
|
|
4169
4169
|
[part='reveal-button']::before {
|
|
4170
4170
|
content: var(--lumo-icons-eye);
|
|
4171
4171
|
}
|
|
@@ -4183,15 +4183,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4183
4183
|
[part='reveal-button'][hidden] {
|
|
4184
4184
|
display: none !important;
|
|
4185
4185
|
}
|
|
4186
|
-
`;
|
|
4186
|
+
`;x("vaadin-password-field",[Tt,ny],{moduleId:"lumo-password-field"});/**
|
|
4187
4187
|
* @license
|
|
4188
4188
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4189
4189
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4190
|
-
*/
|
|
4190
|
+
*/x("vaadin-password-field-button",bu,{moduleId:"vaadin-password-field-button-styles"});class ay extends la(Oe(X(H))){static get is(){return"vaadin-password-field-button"}static get template(){return z``}}k(ay);/**
|
|
4191
4191
|
* @license
|
|
4192
4192
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4193
4193
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4194
|
-
*/const
|
|
4194
|
+
*/const sy=r=>class extends Au(or(Et(Yr(r)))){static get properties(){return{revealButtonHidden:{type:Boolean,observer:"_revealButtonHiddenChanged",value:!1},passwordVisible:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_passwordVisibleChanged",readOnly:!0},i18n:{type:Object,value:()=>({reveal:"Show password"})}}}static get observers(){return["__i18nChanged(i18n)"]}constructor(){super(),this._setType("password"),this.__boundRevealButtonClick=this._onRevealButtonClick.bind(this),this.__boundRevealButtonMouseDown=this._onRevealButtonMouseDown.bind(this),this.__lastChange=""}get slotStyles(){const e=this.localName;return[...super.slotStyles,`
|
|
4195
4195
|
${e} [slot="input"]::-ms-reveal {
|
|
4196
4196
|
display: none;
|
|
4197
4197
|
}
|
|
@@ -4199,11 +4199,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4199
4199
|
* @license
|
|
4200
4200
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4201
4201
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4202
|
-
*/const
|
|
4202
|
+
*/const ly=z`
|
|
4203
4203
|
<div part="reveal-button" slot="suffix">
|
|
4204
4204
|
<slot name="reveal"></slot>
|
|
4205
4205
|
</div>
|
|
4206
|
-
`;let ci;class
|
|
4206
|
+
`;let ci;class dy extends sy(Du){static get is(){return"vaadin-password-field"}static get template(){if(!ci){ci=super.template.cloneNode(!0);const e=ly.content.querySelector('[part="reveal-button"]');ci.content.querySelector('[part="input-field"]').appendChild(e)}return ci}}k(dy);const oo=v`
|
|
4207
4207
|
:host {
|
|
4208
4208
|
display: flex;
|
|
4209
4209
|
align-items: center;
|
|
@@ -4287,7 +4287,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4287
4287
|
width: var(--lumo-icon-size-m);
|
|
4288
4288
|
height: var(--lumo-icon-size-m);
|
|
4289
4289
|
}
|
|
4290
|
-
`;
|
|
4290
|
+
`;x("vaadin-item",oo,{moduleId:"lumo-item"});const Ou=v`
|
|
4291
4291
|
:host {
|
|
4292
4292
|
transition: background-color 100ms;
|
|
4293
4293
|
overflow: hidden;
|
|
@@ -4299,7 +4299,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4299
4299
|
:host([focused]:not([disabled])) {
|
|
4300
4300
|
box-shadow: inset 0 0 0 var(--_focus-ring-width) var(--_focus-ring-color);
|
|
4301
4301
|
}
|
|
4302
|
-
`;
|
|
4302
|
+
`;x("vaadin-combo-box-item",[oo,Ou],{moduleId:"lumo-combo-box-item"});/**
|
|
4303
4303
|
* @license
|
|
4304
4304
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
4305
4305
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4374,16 +4374,16 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4374
4374
|
top: var(--lumo-space-s);
|
|
4375
4375
|
margin-inline: auto 0;
|
|
4376
4376
|
}
|
|
4377
|
-
`;
|
|
4377
|
+
`;x("vaadin-combo-box-overlay",[nr,eo,Mu,Nu,Bu,v`
|
|
4378
4378
|
:host {
|
|
4379
4379
|
--_vaadin-combo-box-items-container-border-width: var(--lumo-space-xs);
|
|
4380
4380
|
--_vaadin-combo-box-items-container-border-style: solid;
|
|
4381
4381
|
}
|
|
4382
|
-
`],{moduleId:"lumo-combo-box-overlay"});const
|
|
4382
|
+
`],{moduleId:"lumo-combo-box-overlay"});const uy=v`
|
|
4383
4383
|
[part='toggle-button']::before {
|
|
4384
4384
|
content: var(--lumo-icons-dropdown);
|
|
4385
4385
|
}
|
|
4386
|
-
`;
|
|
4386
|
+
`;x("vaadin-combo-box",[Tt,uy],{moduleId:"lumo-combo-box"});/**
|
|
4387
4387
|
* @license
|
|
4388
4388
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4389
4389
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4391,7 +4391,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4391
4391
|
* @license
|
|
4392
4392
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4393
4393
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4394
|
-
*/class
|
|
4394
|
+
*/class cy extends Lu(X(Oe(H))){static get template(){return z`
|
|
4395
4395
|
<style>
|
|
4396
4396
|
:host {
|
|
4397
4397
|
display: block;
|
|
@@ -4405,7 +4405,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4405
4405
|
<div part="content">
|
|
4406
4406
|
<slot></slot>
|
|
4407
4407
|
</div>
|
|
4408
|
-
`}static get is(){return"vaadin-combo-box-item"}}
|
|
4408
|
+
`}static get is(){return"vaadin-combo-box-item"}}k(cy);/**
|
|
4409
4409
|
* @license
|
|
4410
4410
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4411
4411
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4413,7 +4413,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4413
4413
|
* @license
|
|
4414
4414
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4415
4415
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4416
|
-
*/const
|
|
4416
|
+
*/const hy=v`
|
|
4417
4417
|
#overlay {
|
|
4418
4418
|
width: var(--vaadin-combo-box-overlay-width, var(--_vaadin-combo-box-overlay-default-width, auto));
|
|
4419
4419
|
}
|
|
@@ -4423,13 +4423,13 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4423
4423
|
flex-direction: column;
|
|
4424
4424
|
height: 100%;
|
|
4425
4425
|
}
|
|
4426
|
-
`;
|
|
4426
|
+
`;x("vaadin-combo-box-overlay",[Kr,hy],{moduleId:"vaadin-combo-box-overlay-styles"});class py extends zu(Qr(Oe(X(H)))){static get is(){return"vaadin-combo-box-overlay"}static get template(){return z`
|
|
4427
4427
|
<div id="backdrop" part="backdrop" hidden></div>
|
|
4428
4428
|
<div part="overlay" id="overlay">
|
|
4429
4429
|
<div part="loader"></div>
|
|
4430
4430
|
<div part="content" id="content"><slot></slot></div>
|
|
4431
4431
|
</div>
|
|
4432
|
-
`}}
|
|
4432
|
+
`}}k(py);/**
|
|
4433
4433
|
* @license
|
|
4434
4434
|
* Copyright (c) 2023 - 2024 Vaadin Ltd.
|
|
4435
4435
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4441,23 +4441,23 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4441
4441
|
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
4442
4442
|
* Code distributed by Google as part of the polymer project is also
|
|
4443
4443
|
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
4444
|
-
*/const Xs=navigator.userAgent.match(/iP(?:hone|ad;(?: U;)? CPU) OS (\d+)/u),
|
|
4444
|
+
*/const Xs=navigator.userAgent.match(/iP(?:hone|ad;(?: U;)? CPU) OS (\d+)/u),my=Xs&&Xs[1]>=8,Ks=3,fy={_ratio:.5,_scrollerPaddingTop:0,_scrollPosition:0,_physicalSize:0,_physicalAverage:0,_physicalAverageCount:0,_physicalTop:0,_virtualCount:0,_estScrollHeight:0,_scrollHeight:0,_viewportHeight:0,_viewportWidth:0,_physicalItems:null,_physicalSizes:null,_firstVisibleIndexVal:null,_lastVisibleIndexVal:null,_maxPages:2,_templateCost:0,get _physicalBottom(){return this._physicalTop+this._physicalSize},get _scrollBottom(){return this._scrollPosition+this._viewportHeight},get _virtualEnd(){return this._virtualStart+this._physicalCount-1},get _hiddenContentSize(){return this._physicalSize-this._viewportHeight},get _maxScrollTop(){return this._estScrollHeight-this._viewportHeight+this._scrollOffset},get _maxVirtualStart(){const r=this._virtualCount;return Math.max(0,r-this._physicalCount)},get _virtualStart(){return this._virtualStartVal||0},set _virtualStart(r){r=this._clamp(r,0,this._maxVirtualStart),this._virtualStartVal=r},get _physicalStart(){return this._physicalStartVal||0},set _physicalStart(r){r%=this._physicalCount,r<0&&(r=this._physicalCount+r),this._physicalStartVal=r},get _physicalEnd(){return(this._physicalStart+this._physicalCount-1)%this._physicalCount},get _physicalCount(){return this._physicalCountVal||0},set _physicalCount(r){this._physicalCountVal=r},get _optPhysicalSize(){return this._viewportHeight===0?1/0:this._viewportHeight*this._maxPages},get _isVisible(){return!!(this.offsetWidth||this.offsetHeight)},get firstVisibleIndex(){let r=this._firstVisibleIndexVal;if(r==null){let e=this._physicalTop+this._scrollOffset;r=this._iterateItems((t,i)=>{if(e+=this._getPhysicalSizeIncrement(t),e>this._scrollPosition)return i})||0,this._firstVisibleIndexVal=r}return r},get lastVisibleIndex(){let r=this._lastVisibleIndexVal;if(r==null){let e=this._physicalTop+this._scrollOffset;this._iterateItems((t,i)=>{e<this._scrollBottom&&(r=i),e+=this._getPhysicalSizeIncrement(t)}),this._lastVisibleIndexVal=r}return r},get _scrollOffset(){return this._scrollerPaddingTop+this.scrollOffset},_scrollHandler(){const r=Math.max(0,Math.min(this._maxScrollTop,this._scrollTop));let e=r-this._scrollPosition;const t=e>=0;if(this._scrollPosition=r,this._firstVisibleIndexVal=null,this._lastVisibleIndexVal=null,Math.abs(e)>this._physicalSize&&this._physicalSize>0){e-=this._scrollOffset;const i=Math.round(e/this._physicalAverage);this._virtualStart+=i,this._physicalStart+=i,this._physicalTop=Math.min(Math.floor(this._virtualStart)*this._physicalAverage,this._scrollPosition),this._update()}else if(this._physicalCount>0){const i=this._getReusables(t);t?(this._physicalTop=i.physicalTop,this._virtualStart+=i.indexes.length,this._physicalStart+=i.indexes.length):(this._virtualStart-=i.indexes.length,this._physicalStart-=i.indexes.length),this._update(i.indexes,t?null:i.indexes),this._debounce("_increasePoolIfNeeded",this._increasePoolIfNeeded.bind(this,0),Li)}},_getReusables(r){let e,t,i;const o=[],n=this._hiddenContentSize*this._ratio,a=this._virtualStart,s=this._virtualEnd,l=this._physicalCount;let d=this._physicalTop+this._scrollOffset;const u=this._physicalBottom+this._scrollOffset,c=this._scrollPosition,h=this._scrollBottom;for(r?(e=this._physicalStart,t=c-d):(e=this._physicalEnd,t=u-h);i=this._getPhysicalSizeIncrement(e),t-=i,!(o.length>=l||t<=n);)if(r){if(s+o.length+1>=this._virtualCount||d+i>=c-this._scrollOffset)break;o.push(e),d+=i,e=(e+1)%l}else{if(a-o.length<=0||d+this._physicalSize-i<=h)break;o.push(e),d-=i,e=e===0?l-1:e-1}return{indexes:o,physicalTop:d-this._scrollOffset}},_update(r,e){if(!(r&&r.length===0||this._physicalCount===0)){if(this._assignModels(r),this._updateMetrics(r),e)for(;e.length;){const t=e.pop();this._physicalTop-=this._getPhysicalSizeIncrement(t)}this._positionItems(),this._updateScrollerSize()}},_isClientFull(){return this._scrollBottom!==0&&this._physicalBottom-1>=this._scrollBottom&&this._physicalTop<=this._scrollPosition},_increasePoolIfNeeded(r){const e=this._clamp(this._physicalCount+r,Ks,this._virtualCount-this._virtualStart)-this._physicalCount;let t=Math.round(this._physicalCount*.5);if(!(e<0)){if(e>0){const i=window.performance.now();[].push.apply(this._physicalItems,this._createPool(e));for(let o=0;o<e;o++)this._physicalSizes.push(0);this._physicalCount+=e,this._physicalStart>this._physicalEnd&&this._isIndexRendered(this._focusedVirtualIndex)&&this._getPhysicalIndex(this._focusedVirtualIndex)<this._physicalEnd&&(this._physicalStart+=e),this._update(),this._templateCost=(window.performance.now()-i)/e,t=Math.round(this._physicalCount*.5)}this._virtualEnd>=this._virtualCount-1||t===0||(this._isClientFull()?this._physicalSize<this._optPhysicalSize&&this._debounce("_increasePoolIfNeeded",this._increasePoolIfNeeded.bind(this,this._clamp(Math.round(50/this._templateCost),1,t)),Kd):this._debounce("_increasePoolIfNeeded",this._increasePoolIfNeeded.bind(this,t),Li))}},_render(){if(!(!this.isAttached||!this._isVisible))if(this._physicalCount!==0){const r=this._getReusables(!0);this._physicalTop=r.physicalTop,this._virtualStart+=r.indexes.length,this._physicalStart+=r.indexes.length,this._update(r.indexes),this._update(),this._increasePoolIfNeeded(0)}else this._virtualCount>0&&(this.updateViewportBoundaries(),this._increasePoolIfNeeded(Ks))},_itemsChanged(r){r.path==="items"&&(this._virtualStart=0,this._physicalTop=0,this._virtualCount=this.items?this.items.length:0,this._physicalIndexForKey={},this._firstVisibleIndexVal=null,this._lastVisibleIndexVal=null,this._physicalItems||(this._physicalItems=[]),this._physicalSizes||(this._physicalSizes=[]),this._physicalStart=0,this._scrollTop>this._scrollOffset&&this._resetScrollPosition(0),this._debounce("_render",this._render,Fr))},_iterateItems(r,e){let t,i,o,n;if(arguments.length===2&&e){for(n=0;n<e.length;n++)if(t=e[n],i=this._computeVidx(t),(o=r.call(this,t,i))!=null)return o}else{for(t=this._physicalStart,i=this._virtualStart;t<this._physicalCount;t++,i++)if((o=r.call(this,t,i))!=null)return o;for(t=0;t<this._physicalStart;t++,i++)if((o=r.call(this,t,i))!=null)return o}},_computeVidx(r){return r>=this._physicalStart?this._virtualStart+(r-this._physicalStart):this._virtualStart+(this._physicalCount-this._physicalStart)+r},_positionItems(){this._adjustScrollPosition();let r=this._physicalTop;this._iterateItems(e=>{this.translate3d(0,`${r}px`,0,this._physicalItems[e]),r+=this._physicalSizes[e]})},_getPhysicalSizeIncrement(r){return this._physicalSizes[r]},_adjustScrollPosition(){const r=this._virtualStart===0?this._physicalTop:Math.min(this._scrollPosition+this._physicalTop,0);if(r!==0){this._physicalTop-=r;const e=this._scrollPosition;!my&&e>0&&this._resetScrollPosition(e-r)}},_resetScrollPosition(r){this.scrollTarget&&r>=0&&(this._scrollTop=r,this._scrollPosition=this._scrollTop)},_updateScrollerSize(r){const e=this._physicalBottom+Math.max(this._virtualCount-this._physicalCount-this._virtualStart,0)*this._physicalAverage;this._estScrollHeight=e,(r||this._scrollHeight===0||this._scrollPosition>=e-this._physicalSize||Math.abs(e-this._scrollHeight)>=this._viewportHeight)&&(this.$.items.style.height=`${e}px`,this._scrollHeight=e)},scrollToIndex(r){if(typeof r!="number"||r<0||r>this.items.length-1||(Er(),this._physicalCount===0))return;r=this._clamp(r,0,this._virtualCount-1),(!this._isIndexRendered(r)||r>=this._maxVirtualStart)&&(this._virtualStart=r-1),this._assignModels(),this._updateMetrics(),this._physicalTop=this._virtualStart*this._physicalAverage;let e=this._physicalStart,t=this._virtualStart,i=0;const o=this._hiddenContentSize;for(;t<r&&i<=o;)i+=this._getPhysicalSizeIncrement(e),e=(e+1)%this._physicalCount,t+=1;this._updateScrollerSize(!0),this._positionItems(),this._resetScrollPosition(this._physicalTop+this._scrollOffset+i),this._increasePoolIfNeeded(0),this._firstVisibleIndexVal=null,this._lastVisibleIndexVal=null},_resetAverage(){this._physicalAverage=0,this._physicalAverageCount=0},_resizeHandler(){this._debounce("_render",()=>{this._firstVisibleIndexVal=null,this._lastVisibleIndexVal=null,this._isVisible?(this.updateViewportBoundaries(),this.toggleScrollListener(!0),this._resetAverage(),this._render()):this.toggleScrollListener(!1)},Fr)},_isIndexRendered(r){return r>=this._virtualStart&&r<=this._virtualEnd},_getPhysicalIndex(r){return(this._physicalStart+(r-this._virtualStart))%this._physicalCount},_clamp(r,e,t){return Math.min(t,Math.max(e,r))},_debounce(r,e,t){this._debouncers||(this._debouncers={}),this._debouncers[r]=Se.debounce(this._debouncers[r],t,e.bind(this)),Qd(this._debouncers[r])}};/**
|
|
4445
4445
|
* @license
|
|
4446
4446
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4447
4447
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4448
|
-
*/const fy=1e5,Oo=1e3;class Hu{constructor({createElements:e,updateElement:t,scrollTarget:i,scrollContainer:o,elementsContainer:n,reorderElements:a}){this.isAttached=!0,this._vidxOffset=0,this.createElements=e,this.updateElement=t,this.scrollTarget=i,this.scrollContainer=o,this.elementsContainer=n||o,this.reorderElements=a,this._maxPages=1.3,this.__placeholderHeight=200,this.__elementHeightQueue=Array(10),this.timeouts={SCROLL_REORDER:500,IGNORE_WHEEL:500,FIX_INVALID_ITEM_POSITIONING:100},this.__resizeObserver=new ResizeObserver(()=>this._resizeHandler()),getComputedStyle(this.scrollTarget).overflow==="visible"&&(this.scrollTarget.style.overflow="auto"),getComputedStyle(this.scrollContainer).position==="static"&&(this.scrollContainer.style.position="relative"),this.__resizeObserver.observe(this.scrollTarget),this.scrollTarget.addEventListener("scroll",()=>this._scrollHandler()),new ResizeObserver(([{contentRect:s}])=>{const l=s.width===0&&s.height===0;!l&&this.__scrollTargetHidden&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition),this.__scrollTargetHidden=l}).observe(this.scrollTarget),this._scrollLineHeight=this._getScrollLineHeight(),this.scrollTarget.addEventListener("wheel",s=>this.__onWheel(s)),this.scrollTarget.addEventListener("virtualizer-element-focused",s=>this.__onElementFocused(s)),this.elementsContainer.addEventListener("focusin",()=>{this.scrollTarget.dispatchEvent(new CustomEvent("virtualizer-element-focused",{detail:{element:this.__getFocusedElement()}}))}),this.reorderElements&&(this.scrollTarget.addEventListener("mousedown",()=>{this.__mouseDown=!0}),this.scrollTarget.addEventListener("mouseup",()=>{this.__mouseDown=!1,this.__pendingReorder&&this.__reorderElements()}))}get scrollOffset(){return 0}get adjustedFirstVisibleIndex(){return this.firstVisibleIndex+this._vidxOffset}get adjustedLastVisibleIndex(){return this.lastVisibleIndex+this._vidxOffset}get _maxVirtualIndexOffset(){return this.size-this._virtualCount}__hasPlaceholders(){return this.__getVisibleElements().some(e=>e.__virtualizerPlaceholder)}scrollToIndex(e){if(typeof e!="number"||isNaN(e)||this.size===0||!this.scrollTarget.offsetHeight)return;delete this.__pendingScrollToIndex,this._physicalCount<=3&&this.flush(),e=this._clamp(e,0,this.size-1);const t=this.__getVisibleElements().length;let i=Math.floor(e/this.size*this._virtualCount);this._virtualCount-i<t?(i=this._virtualCount-(this.size-e),this._vidxOffset=this._maxVirtualIndexOffset):i<t?e<Oo?(i=e,this._vidxOffset=0):(i=Oo,this._vidxOffset=e-i):this._vidxOffset=e-i,this.__skipNextVirtualIndexAdjust=!0,super.scrollToIndex(i),this.adjustedFirstVisibleIndex!==e&&this._scrollTop<this._maxScrollTop&&!this.grid&&(this._scrollTop-=this.__getIndexScrollOffset(e)||0),this._scrollHandler(),this.__hasPlaceholders()&&(this.__pendingScrollToIndex=e)}flush(){this.scrollTarget.offsetHeight!==0&&(this._resizeHandler(),Tr(),this._scrollHandler(),this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.flush(),this.__scrollReorderDebouncer&&this.__scrollReorderDebouncer.flush(),this.__debouncerWheelAnimationFrame&&this.__debouncerWheelAnimationFrame.flush())}update(e=0,t=this.size-1){const i=[];this.__getVisibleElements().forEach(o=>{o.__virtualIndex>=e&&o.__virtualIndex<=t&&(this.__updateElement(o,o.__virtualIndex,!0),i.push(o))}),this.__afterElementsUpdated(i)}_updateMetrics(e){Tr();let t=0,i=0;const o=this._physicalAverageCount,n=this._physicalAverage;this._iterateItems((a,s)=>{i+=this._physicalSizes[a],this._physicalSizes[a]=Math.ceil(this.__getBorderBoxHeight(this._physicalItems[a])),t+=this._physicalSizes[a],this._physicalAverageCount+=this._physicalSizes[a]?1:0},e),this._physicalSize=this._physicalSize+t-i,this._physicalAverageCount!==o&&(this._physicalAverage=Math.round((n*o+t)/this._physicalAverageCount))}__getBorderBoxHeight(e){const t=getComputedStyle(e),i=parseFloat(t.height)||0;if(t.boxSizing==="border-box")return i;const o=parseFloat(t.paddingBottom)||0,n=parseFloat(t.paddingTop)||0,a=parseFloat(t.borderBottomWidth)||0,s=parseFloat(t.borderTopWidth)||0;return i+o+n+a+s}__updateElement(e,t,i){e.__virtualizerPlaceholder&&(e.style.paddingTop="",e.style.opacity="",e.__virtualizerPlaceholder=!1),!this.__preventElementUpdates&&(e.__lastUpdatedIndex!==t||i)&&(this.updateElement(e,t),e.__lastUpdatedIndex=t)}__afterElementsUpdated(e){e.forEach(t=>{const i=t.offsetHeight;if(i===0)t.style.paddingTop=`${this.__placeholderHeight}px`,t.style.opacity="0",t.__virtualizerPlaceholder=!0,this.__placeholderClearDebouncer=De.debounce(this.__placeholderClearDebouncer,$r,()=>this._resizeHandler());else{this.__elementHeightQueue.push(i),this.__elementHeightQueue.shift();const o=this.__elementHeightQueue.filter(n=>n!==void 0);this.__placeholderHeight=Math.round(o.reduce((n,a)=>n+a,0)/o.length)}}),this.__pendingScrollToIndex!==void 0&&!this.__hasPlaceholders()&&this.scrollToIndex(this.__pendingScrollToIndex)}__getIndexScrollOffset(e){const t=this.__getVisibleElements().find(i=>i.__virtualIndex===e);return t?this.scrollTarget.getBoundingClientRect().top-t.getBoundingClientRect().top:void 0}get size(){return this.__size}set size(e){if(e===this.size)return;this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.cancel(),this._debouncers&&this._debouncers._increasePoolIfNeeded&&this._debouncers._increasePoolIfNeeded.cancel(),this.__preventElementUpdates=!0;let t,i;if(e>0&&(t=this.adjustedFirstVisibleIndex,i=this.__getIndexScrollOffset(t)),this.__size=e,this._itemsChanged({path:"items"}),Tr(),e>0){t=Math.min(t,e-1),this.scrollToIndex(t);const o=this.__getIndexScrollOffset(t);i!==void 0&&o!==void 0&&(this._scrollTop+=i-o)}this.__preventElementUpdates=!1,this._isVisible||this._assignModels(),this.elementsContainer.children.length||requestAnimationFrame(()=>this._resizeHandler()),this._resizeHandler(),Tr(),this._debounce("_update",this._update,Li)}get _scrollTop(){return this.scrollTarget.scrollTop}set _scrollTop(e){this.scrollTarget.scrollTop=e}get items(){return{length:Math.min(this.size,fy)}}get offsetHeight(){return this.scrollTarget.offsetHeight}get $(){return{items:this.scrollContainer}}updateViewportBoundaries(){const e=window.getComputedStyle(this.scrollTarget);this._scrollerPaddingTop=this.scrollTarget===this?0:parseInt(e["padding-top"],10),this._isRTL=e.direction==="rtl",this._viewportWidth=this.elementsContainer.offsetWidth,this._viewportHeight=this.scrollTarget.offsetHeight,this._scrollPageHeight=this._viewportHeight-this._scrollLineHeight,this.grid&&this._updateGridMetrics()}setAttribute(){}_createPool(e){const t=this.createElements(e),i=document.createDocumentFragment();return t.forEach(o=>{o.style.position="absolute",i.appendChild(o),this.__resizeObserver.observe(o)}),this.elementsContainer.appendChild(i),t}_assignModels(e){const t=[];this._iterateItems((i,o)=>{const n=this._physicalItems[i];n.hidden=o>=this.size,n.hidden?delete n.__lastUpdatedIndex:(n.__virtualIndex=o+(this._vidxOffset||0),this.__updateElement(n,n.__virtualIndex),t.push(n))},e),this.__afterElementsUpdated(t)}_isClientFull(){return setTimeout(()=>{this.__clientFull=!0}),this.__clientFull||super._isClientFull()}translate3d(e,t,i,o){o.style.transform=`translateY(${t})`}toggleScrollListener(){}__getFocusedElement(e=this.__getVisibleElements()){return e.find(t=>t.contains(this.elementsContainer.getRootNode().activeElement)||t.contains(this.scrollTarget.getRootNode().activeElement))}__nextFocusableSiblingMissing(e,t){return t.indexOf(e)===t.length-1&&this.size>e.__virtualIndex+1}__previousFocusableSiblingMissing(e,t){return t.indexOf(e)===0&&e.__virtualIndex>0}__onElementFocused(e){if(!this.reorderElements)return;const t=e.detail.element;if(!t)return;const i=this.__getVisibleElements();(this.__previousFocusableSiblingMissing(t,i)||this.__nextFocusableSiblingMissing(t,i))&&this.flush();const o=this.__getVisibleElements();this.__nextFocusableSiblingMissing(t,o)?(this._scrollTop+=Math.ceil(t.getBoundingClientRect().bottom)-Math.floor(this.scrollTarget.getBoundingClientRect().bottom-1),this.flush()):this.__previousFocusableSiblingMissing(t,o)&&(this._scrollTop-=Math.ceil(this.scrollTarget.getBoundingClientRect().top+1)-Math.floor(t.getBoundingClientRect().top),this.flush())}_scrollHandler(){if(this.scrollTarget.offsetHeight===0)return;this._adjustVirtualIndexOffset(this._scrollTop-(this.__previousScrollTop||0));const e=this.scrollTarget.scrollTop-this._scrollPosition;if(super._scrollHandler(),this._physicalCount!==0){const t=e>=0,i=this._getReusables(!t);i.indexes.length&&(this._physicalTop=i.physicalTop,t?(this._virtualStart-=i.indexes.length,this._physicalStart-=i.indexes.length):(this._virtualStart+=i.indexes.length,this._physicalStart+=i.indexes.length),this._resizeHandler())}e&&(this.__fixInvalidItemPositioningDebouncer=De.debounce(this.__fixInvalidItemPositioningDebouncer,at.after(this.timeouts.FIX_INVALID_ITEM_POSITIONING),()=>this.__fixInvalidItemPositioning())),this.reorderElements&&(this.__scrollReorderDebouncer=De.debounce(this.__scrollReorderDebouncer,at.after(this.timeouts.SCROLL_REORDER),()=>this.__reorderElements())),this.__previousScrollTop=this._scrollTop,this._scrollTop===0&&this.firstVisibleIndex!==0&&Math.abs(e)>0&&this.scrollToIndex(0)}__fixInvalidItemPositioning(){if(!this.scrollTarget.isConnected)return;const e=this._physicalTop>this._scrollTop,t=this._physicalBottom<this._scrollBottom,i=this.adjustedFirstVisibleIndex===0,o=this.adjustedLastVisibleIndex===this.size-1;if(e&&!i||t&&!o){const n=t,a=this._ratio;this._ratio=0,this._scrollPosition=this._scrollTop+(n?-1:1),this._scrollHandler(),this._ratio=a}}__onWheel(e){if(e.ctrlKey||this._hasScrolledAncestor(e.target,e.deltaX,e.deltaY))return;let t=e.deltaY;if(e.deltaMode===WheelEvent.DOM_DELTA_LINE?t*=this._scrollLineHeight:e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._scrollPageHeight),this._deltaYAcc||(this._deltaYAcc=0),this._wheelAnimationFrame){this._deltaYAcc+=t,e.preventDefault();return}t+=this._deltaYAcc,this._deltaYAcc=0,this._wheelAnimationFrame=!0,this.__debouncerWheelAnimationFrame=De.debounce(this.__debouncerWheelAnimationFrame,$r,()=>{this._wheelAnimationFrame=!1});const i=Math.abs(e.deltaX)+Math.abs(t);this._canScroll(this.scrollTarget,e.deltaX,t)?(e.preventDefault(),this.scrollTarget.scrollTop+=t,this.scrollTarget.scrollLeft+=e.deltaX,this._hasResidualMomentum=!0,this._ignoreNewWheel=!0,this._debouncerIgnoreNewWheel=De.debounce(this._debouncerIgnoreNewWheel,at.after(this.timeouts.IGNORE_WHEEL),()=>{this._ignoreNewWheel=!1})):this._hasResidualMomentum&&i<=this._previousMomentum||this._ignoreNewWheel?e.preventDefault():i>this._previousMomentum&&(this._hasResidualMomentum=!1),this._previousMomentum=i}_hasScrolledAncestor(e,t,i){if(e===this.scrollTarget||e===this.scrollTarget.getRootNode().host)return!1;if(this._canScroll(e,t,i)&&["auto","scroll"].indexOf(getComputedStyle(e).overflow)!==-1)return!0;if(e!==this&&e.parentElement)return this._hasScrolledAncestor(e.parentElement,t,i)}_canScroll(e,t,i){return i>0&&e.scrollTop<e.scrollHeight-e.offsetHeight||i<0&&e.scrollTop>0||t>0&&e.scrollLeft<e.scrollWidth-e.offsetWidth||t<0&&e.scrollLeft>0}_increasePoolIfNeeded(e){if(this._physicalCount>2&&e){const t=Math.ceil(this._optPhysicalSize/this._physicalAverage)-this._physicalCount;super._increasePoolIfNeeded(Math.max(e,Math.min(100,t)))}else super._increasePoolIfNeeded(e)}get _optPhysicalSize(){const e=super._optPhysicalSize;return e<=0||this.__hasPlaceholders()?e:e+this.__getItemHeightBuffer()}__getItemHeightBuffer(){if(this._physicalCount===0)return 0;const e=Math.ceil(this._viewportHeight*(this._maxPages-1)/2),t=Math.max(...this._physicalSizes);return t>Math.min(...this._physicalSizes)?Math.max(0,t-e):0}_getScrollLineHeight(){const e=document.createElement("div");e.style.fontSize="initial",e.style.display="none",document.body.appendChild(e);const t=window.getComputedStyle(e).fontSize;return document.body.removeChild(e),t?window.parseInt(t):void 0}__getVisibleElements(){return Array.from(this.elementsContainer.children).filter(e=>!e.hidden)}__reorderElements(){if(this.__mouseDown){this.__pendingReorder=!0;return}this.__pendingReorder=!1;const e=this._virtualStart+(this._vidxOffset||0),t=this.__getVisibleElements(),i=this.__getFocusedElement(t)||t[0];if(!i)return;const o=i.__virtualIndex-e,n=t.indexOf(i)-o;if(n>0)for(let a=0;a<n;a++)this.elementsContainer.appendChild(t[a]);else if(n<0)for(let a=t.length+n;a<t.length;a++)this.elementsContainer.insertBefore(t[a],t[0]);if(rb){const{transform:a}=this.scrollTarget.style;this.scrollTarget.style.transform="translateZ(0)",setTimeout(()=>{this.scrollTarget.style.transform=a})}}_adjustVirtualIndexOffset(e){const t=this._maxVirtualIndexOffset;if(this._virtualCount>=this.size)this._vidxOffset=0;else if(this.__skipNextVirtualIndexAdjust)this.__skipNextVirtualIndexAdjust=!1;else if(Math.abs(e)>1e4){const i=this._scrollTop/(this.scrollTarget.scrollHeight-this.scrollTarget.clientHeight);this._vidxOffset=Math.round(i*t)}else{const i=this._vidxOffset,o=Oo,n=100;this._scrollTop===0?(this._vidxOffset=0,i!==this._vidxOffset&&super.scrollToIndex(0)):this.firstVisibleIndex<o&&this._vidxOffset>0&&(this._vidxOffset-=Math.min(this._vidxOffset,n),super.scrollToIndex(this.firstVisibleIndex+(i-this._vidxOffset))),this._scrollTop>=this._maxScrollTop&&this._maxScrollTop>0?(this._vidxOffset=t,i!==this._vidxOffset&&super.scrollToIndex(this._virtualCount-1)):this.firstVisibleIndex>this._virtualCount-o&&this._vidxOffset<t&&(this._vidxOffset+=Math.min(t-this._vidxOffset,n),super.scrollToIndex(this.firstVisibleIndex-(this._vidxOffset-i)))}}}Object.setPrototypeOf(Hu.prototype,my);class _y{constructor(e){this.__adapter=new Hu(e)}get firstVisibleIndex(){return this.__adapter.adjustedFirstVisibleIndex}get lastVisibleIndex(){return this.__adapter.adjustedLastVisibleIndex}get size(){return this.__adapter.size}set size(e){this.__adapter.size=e}scrollToIndex(e){this.__adapter.scrollToIndex(e)}update(e=0,t=this.size-1){this.__adapter.update(e,t)}flush(){this.__adapter.flush()}}/**
|
|
4448
|
+
*/const _y=1e5,Oo=1e3;class Hu{constructor({createElements:e,updateElement:t,scrollTarget:i,scrollContainer:o,elementsContainer:n,reorderElements:a}){this.isAttached=!0,this._vidxOffset=0,this.createElements=e,this.updateElement=t,this.scrollTarget=i,this.scrollContainer=o,this.elementsContainer=n||o,this.reorderElements=a,this._maxPages=1.3,this.__placeholderHeight=200,this.__elementHeightQueue=Array(10),this.timeouts={SCROLL_REORDER:500,IGNORE_WHEEL:500,FIX_INVALID_ITEM_POSITIONING:100},this.__resizeObserver=new ResizeObserver(()=>this._resizeHandler()),getComputedStyle(this.scrollTarget).overflow==="visible"&&(this.scrollTarget.style.overflow="auto"),getComputedStyle(this.scrollContainer).position==="static"&&(this.scrollContainer.style.position="relative"),this.__resizeObserver.observe(this.scrollTarget),this.scrollTarget.addEventListener("scroll",()=>this._scrollHandler()),new ResizeObserver(([{contentRect:s}])=>{const l=s.width===0&&s.height===0;!l&&this.__scrollTargetHidden&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition),this.__scrollTargetHidden=l}).observe(this.scrollTarget),this._scrollLineHeight=this._getScrollLineHeight(),this.scrollTarget.addEventListener("wheel",s=>this.__onWheel(s)),this.scrollTarget.addEventListener("virtualizer-element-focused",s=>this.__onElementFocused(s)),this.elementsContainer.addEventListener("focusin",()=>{this.scrollTarget.dispatchEvent(new CustomEvent("virtualizer-element-focused",{detail:{element:this.__getFocusedElement()}}))}),this.reorderElements&&(this.scrollTarget.addEventListener("mousedown",()=>{this.__mouseDown=!0}),this.scrollTarget.addEventListener("mouseup",()=>{this.__mouseDown=!1,this.__pendingReorder&&this.__reorderElements()}))}get scrollOffset(){return 0}get adjustedFirstVisibleIndex(){return this.firstVisibleIndex+this._vidxOffset}get adjustedLastVisibleIndex(){return this.lastVisibleIndex+this._vidxOffset}get _maxVirtualIndexOffset(){return this.size-this._virtualCount}__hasPlaceholders(){return this.__getVisibleElements().some(e=>e.__virtualizerPlaceholder)}scrollToIndex(e){if(typeof e!="number"||isNaN(e)||this.size===0||!this.scrollTarget.offsetHeight)return;delete this.__pendingScrollToIndex,this._physicalCount<=3&&this.flush(),e=this._clamp(e,0,this.size-1);const t=this.__getVisibleElements().length;let i=Math.floor(e/this.size*this._virtualCount);this._virtualCount-i<t?(i=this._virtualCount-(this.size-e),this._vidxOffset=this._maxVirtualIndexOffset):i<t?e<Oo?(i=e,this._vidxOffset=0):(i=Oo,this._vidxOffset=e-i):this._vidxOffset=e-i,this.__skipNextVirtualIndexAdjust=!0,super.scrollToIndex(i),this.adjustedFirstVisibleIndex!==e&&this._scrollTop<this._maxScrollTop&&!this.grid&&(this._scrollTop-=this.__getIndexScrollOffset(e)||0),this._scrollHandler(),this.__hasPlaceholders()&&(this.__pendingScrollToIndex=e)}flush(){this.scrollTarget.offsetHeight!==0&&(this._resizeHandler(),Er(),this._scrollHandler(),this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.flush(),this.__scrollReorderDebouncer&&this.__scrollReorderDebouncer.flush(),this.__debouncerWheelAnimationFrame&&this.__debouncerWheelAnimationFrame.flush())}update(e=0,t=this.size-1){const i=[];this.__getVisibleElements().forEach(o=>{o.__virtualIndex>=e&&o.__virtualIndex<=t&&(this.__updateElement(o,o.__virtualIndex,!0),i.push(o))}),this.__afterElementsUpdated(i)}_updateMetrics(e){Er();let t=0,i=0;const o=this._physicalAverageCount,n=this._physicalAverage;this._iterateItems((a,s)=>{i+=this._physicalSizes[a],this._physicalSizes[a]=Math.ceil(this.__getBorderBoxHeight(this._physicalItems[a])),t+=this._physicalSizes[a],this._physicalAverageCount+=this._physicalSizes[a]?1:0},e),this._physicalSize=this._physicalSize+t-i,this._physicalAverageCount!==o&&(this._physicalAverage=Math.round((n*o+t)/this._physicalAverageCount))}__getBorderBoxHeight(e){const t=getComputedStyle(e),i=parseFloat(t.height)||0;if(t.boxSizing==="border-box")return i;const o=parseFloat(t.paddingBottom)||0,n=parseFloat(t.paddingTop)||0,a=parseFloat(t.borderBottomWidth)||0,s=parseFloat(t.borderTopWidth)||0;return i+o+n+a+s}__updateElement(e,t,i){e.__virtualizerPlaceholder&&(e.style.paddingTop="",e.style.opacity="",e.__virtualizerPlaceholder=!1),!this.__preventElementUpdates&&(e.__lastUpdatedIndex!==t||i)&&(this.updateElement(e,t),e.__lastUpdatedIndex=t)}__afterElementsUpdated(e){e.forEach(t=>{const i=t.offsetHeight;if(i===0)t.style.paddingTop=`${this.__placeholderHeight}px`,t.style.opacity="0",t.__virtualizerPlaceholder=!0,this.__placeholderClearDebouncer=Se.debounce(this.__placeholderClearDebouncer,Fr,()=>this._resizeHandler());else{this.__elementHeightQueue.push(i),this.__elementHeightQueue.shift();const o=this.__elementHeightQueue.filter(n=>n!==void 0);this.__placeholderHeight=Math.round(o.reduce((n,a)=>n+a,0)/o.length)}}),this.__pendingScrollToIndex!==void 0&&!this.__hasPlaceholders()&&this.scrollToIndex(this.__pendingScrollToIndex)}__getIndexScrollOffset(e){const t=this.__getVisibleElements().find(i=>i.__virtualIndex===e);return t?this.scrollTarget.getBoundingClientRect().top-t.getBoundingClientRect().top:void 0}get size(){return this.__size}set size(e){if(e===this.size)return;this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.cancel(),this._debouncers&&this._debouncers._increasePoolIfNeeded&&this._debouncers._increasePoolIfNeeded.cancel(),this.__preventElementUpdates=!0;let t,i;if(e>0&&(t=this.adjustedFirstVisibleIndex,i=this.__getIndexScrollOffset(t)),this.__size=e,this._itemsChanged({path:"items"}),Er(),e>0){t=Math.min(t,e-1),this.scrollToIndex(t);const o=this.__getIndexScrollOffset(t);i!==void 0&&o!==void 0&&(this._scrollTop+=i-o)}this.__preventElementUpdates=!1,this._isVisible||this._assignModels(),this.elementsContainer.children.length||requestAnimationFrame(()=>this._resizeHandler()),this._resizeHandler(),Er(),this._debounce("_update",this._update,Li)}get _scrollTop(){return this.scrollTarget.scrollTop}set _scrollTop(e){this.scrollTarget.scrollTop=e}get items(){return{length:Math.min(this.size,_y)}}get offsetHeight(){return this.scrollTarget.offsetHeight}get $(){return{items:this.scrollContainer}}updateViewportBoundaries(){const e=window.getComputedStyle(this.scrollTarget);this._scrollerPaddingTop=this.scrollTarget===this?0:parseInt(e["padding-top"],10),this._isRTL=e.direction==="rtl",this._viewportWidth=this.elementsContainer.offsetWidth,this._viewportHeight=this.scrollTarget.offsetHeight,this._scrollPageHeight=this._viewportHeight-this._scrollLineHeight,this.grid&&this._updateGridMetrics()}setAttribute(){}_createPool(e){const t=this.createElements(e),i=document.createDocumentFragment();return t.forEach(o=>{o.style.position="absolute",i.appendChild(o),this.__resizeObserver.observe(o)}),this.elementsContainer.appendChild(i),t}_assignModels(e){const t=[];this._iterateItems((i,o)=>{const n=this._physicalItems[i];n.hidden=o>=this.size,n.hidden?delete n.__lastUpdatedIndex:(n.__virtualIndex=o+(this._vidxOffset||0),this.__updateElement(n,n.__virtualIndex),t.push(n))},e),this.__afterElementsUpdated(t)}_isClientFull(){return setTimeout(()=>{this.__clientFull=!0}),this.__clientFull||super._isClientFull()}translate3d(e,t,i,o){o.style.transform=`translateY(${t})`}toggleScrollListener(){}__getFocusedElement(e=this.__getVisibleElements()){return e.find(t=>t.contains(this.elementsContainer.getRootNode().activeElement)||t.contains(this.scrollTarget.getRootNode().activeElement))}__nextFocusableSiblingMissing(e,t){return t.indexOf(e)===t.length-1&&this.size>e.__virtualIndex+1}__previousFocusableSiblingMissing(e,t){return t.indexOf(e)===0&&e.__virtualIndex>0}__onElementFocused(e){if(!this.reorderElements)return;const t=e.detail.element;if(!t)return;const i=this.__getVisibleElements();(this.__previousFocusableSiblingMissing(t,i)||this.__nextFocusableSiblingMissing(t,i))&&this.flush();const o=this.__getVisibleElements();this.__nextFocusableSiblingMissing(t,o)?(this._scrollTop+=Math.ceil(t.getBoundingClientRect().bottom)-Math.floor(this.scrollTarget.getBoundingClientRect().bottom-1),this.flush()):this.__previousFocusableSiblingMissing(t,o)&&(this._scrollTop-=Math.ceil(this.scrollTarget.getBoundingClientRect().top+1)-Math.floor(t.getBoundingClientRect().top),this.flush())}_scrollHandler(){if(this.scrollTarget.offsetHeight===0)return;this._adjustVirtualIndexOffset(this._scrollTop-(this.__previousScrollTop||0));const e=this.scrollTarget.scrollTop-this._scrollPosition;if(super._scrollHandler(),this._physicalCount!==0){const t=e>=0,i=this._getReusables(!t);i.indexes.length&&(this._physicalTop=i.physicalTop,t?(this._virtualStart-=i.indexes.length,this._physicalStart-=i.indexes.length):(this._virtualStart+=i.indexes.length,this._physicalStart+=i.indexes.length),this._resizeHandler())}e&&(this.__fixInvalidItemPositioningDebouncer=Se.debounce(this.__fixInvalidItemPositioningDebouncer,nt.after(this.timeouts.FIX_INVALID_ITEM_POSITIONING),()=>this.__fixInvalidItemPositioning())),this.reorderElements&&(this.__scrollReorderDebouncer=Se.debounce(this.__scrollReorderDebouncer,nt.after(this.timeouts.SCROLL_REORDER),()=>this.__reorderElements())),this.__previousScrollTop=this._scrollTop,this._scrollTop===0&&this.firstVisibleIndex!==0&&Math.abs(e)>0&&this.scrollToIndex(0)}__fixInvalidItemPositioning(){if(!this.scrollTarget.isConnected)return;const e=this._physicalTop>this._scrollTop,t=this._physicalBottom<this._scrollBottom,i=this.adjustedFirstVisibleIndex===0,o=this.adjustedLastVisibleIndex===this.size-1;if(e&&!i||t&&!o){const n=t,a=this._ratio;this._ratio=0,this._scrollPosition=this._scrollTop+(n?-1:1),this._scrollHandler(),this._ratio=a}}__onWheel(e){if(e.ctrlKey||this._hasScrolledAncestor(e.target,e.deltaX,e.deltaY))return;let t=e.deltaY;if(e.deltaMode===WheelEvent.DOM_DELTA_LINE?t*=this._scrollLineHeight:e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._scrollPageHeight),this._deltaYAcc||(this._deltaYAcc=0),this._wheelAnimationFrame){this._deltaYAcc+=t,e.preventDefault();return}t+=this._deltaYAcc,this._deltaYAcc=0,this._wheelAnimationFrame=!0,this.__debouncerWheelAnimationFrame=Se.debounce(this.__debouncerWheelAnimationFrame,Fr,()=>{this._wheelAnimationFrame=!1});const i=Math.abs(e.deltaX)+Math.abs(t);this._canScroll(this.scrollTarget,e.deltaX,t)?(e.preventDefault(),this.scrollTarget.scrollTop+=t,this.scrollTarget.scrollLeft+=e.deltaX,this._hasResidualMomentum=!0,this._ignoreNewWheel=!0,this._debouncerIgnoreNewWheel=Se.debounce(this._debouncerIgnoreNewWheel,nt.after(this.timeouts.IGNORE_WHEEL),()=>{this._ignoreNewWheel=!1})):this._hasResidualMomentum&&i<=this._previousMomentum||this._ignoreNewWheel?e.preventDefault():i>this._previousMomentum&&(this._hasResidualMomentum=!1),this._previousMomentum=i}_hasScrolledAncestor(e,t,i){if(e===this.scrollTarget||e===this.scrollTarget.getRootNode().host)return!1;if(this._canScroll(e,t,i)&&["auto","scroll"].indexOf(getComputedStyle(e).overflow)!==-1)return!0;if(e!==this&&e.parentElement)return this._hasScrolledAncestor(e.parentElement,t,i)}_canScroll(e,t,i){return i>0&&e.scrollTop<e.scrollHeight-e.offsetHeight||i<0&&e.scrollTop>0||t>0&&e.scrollLeft<e.scrollWidth-e.offsetWidth||t<0&&e.scrollLeft>0}_increasePoolIfNeeded(e){if(this._physicalCount>2&&e){const t=Math.ceil(this._optPhysicalSize/this._physicalAverage)-this._physicalCount;super._increasePoolIfNeeded(Math.max(e,Math.min(100,t)))}else super._increasePoolIfNeeded(e)}get _optPhysicalSize(){const e=super._optPhysicalSize;return e<=0||this.__hasPlaceholders()?e:e+this.__getItemHeightBuffer()}__getItemHeightBuffer(){if(this._physicalCount===0)return 0;const e=Math.ceil(this._viewportHeight*(this._maxPages-1)/2),t=Math.max(...this._physicalSizes);return t>Math.min(...this._physicalSizes)?Math.max(0,t-e):0}_getScrollLineHeight(){const e=document.createElement("div");e.style.fontSize="initial",e.style.display="none",document.body.appendChild(e);const t=window.getComputedStyle(e).fontSize;return document.body.removeChild(e),t?window.parseInt(t):void 0}__getVisibleElements(){return Array.from(this.elementsContainer.children).filter(e=>!e.hidden)}__reorderElements(){if(this.__mouseDown){this.__pendingReorder=!0;return}this.__pendingReorder=!1;const e=this._virtualStart+(this._vidxOffset||0),t=this.__getVisibleElements(),i=this.__getFocusedElement(t)||t[0];if(!i)return;const o=i.__virtualIndex-e,n=t.indexOf(i)-o;if(n>0)for(let a=0;a<n;a++)this.elementsContainer.appendChild(t[a]);else if(n<0)for(let a=t.length+n;a<t.length;a++)this.elementsContainer.insertBefore(t[a],t[0]);if(ib){const{transform:a}=this.scrollTarget.style;this.scrollTarget.style.transform="translateZ(0)",setTimeout(()=>{this.scrollTarget.style.transform=a})}}_adjustVirtualIndexOffset(e){const t=this._maxVirtualIndexOffset;if(this._virtualCount>=this.size)this._vidxOffset=0;else if(this.__skipNextVirtualIndexAdjust)this.__skipNextVirtualIndexAdjust=!1;else if(Math.abs(e)>1e4){const i=this._scrollTop/(this.scrollTarget.scrollHeight-this.scrollTarget.clientHeight);this._vidxOffset=Math.round(i*t)}else{const i=this._vidxOffset,o=Oo,n=100;this._scrollTop===0?(this._vidxOffset=0,i!==this._vidxOffset&&super.scrollToIndex(0)):this.firstVisibleIndex<o&&this._vidxOffset>0&&(this._vidxOffset-=Math.min(this._vidxOffset,n),super.scrollToIndex(this.firstVisibleIndex+(i-this._vidxOffset))),this._scrollTop>=this._maxScrollTop&&this._maxScrollTop>0?(this._vidxOffset=t,i!==this._vidxOffset&&super.scrollToIndex(this._virtualCount-1)):this.firstVisibleIndex>this._virtualCount-o&&this._vidxOffset<t&&(this._vidxOffset+=Math.min(t-this._vidxOffset,n),super.scrollToIndex(this.firstVisibleIndex-(this._vidxOffset-i)))}}}Object.setPrototypeOf(Hu.prototype,fy);class vy{constructor(e){this.__adapter=new Hu(e)}get firstVisibleIndex(){return this.__adapter.adjustedFirstVisibleIndex}get lastVisibleIndex(){return this.__adapter.adjustedLastVisibleIndex}get size(){return this.__adapter.size}set size(e){this.__adapter.size=e}scrollToIndex(e){this.__adapter.scrollToIndex(e)}update(e=0,t=this.size-1){this.__adapter.update(e,t)}flush(){this.__adapter.flush()}}/**
|
|
4449
4449
|
* @license
|
|
4450
4450
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4451
4451
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4452
|
-
*/const
|
|
4452
|
+
*/const st=class{toString(){return""}};/**
|
|
4453
4453
|
* @license
|
|
4454
4454
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4455
4455
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4456
|
-
*/const Ru=r=>class extends r{static get properties(){return{items:{type:Array,sync:!0,observer:"__itemsChanged"},focusedIndex:{type:Number,sync:!0,observer:"__focusedIndexChanged"},loading:{type:Boolean,sync:!0,observer:"__loadingChanged"},opened:{type:Boolean,sync:!0,observer:"__openedChanged"},selectedItem:{type:Object,sync:!0,observer:"__selectedItemChanged"},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged"},itemIdPath:{type:String},owner:{type:Object},getItemLabel:{type:Object},renderer:{type:Object,sync:!0,observer:"__rendererChanged"},theme:{type:String}}}constructor(){super(),this.__boundOnItemClick=this.__onItemClick.bind(this)}get _viewportTotalPaddingBottom(){if(this._cachedViewportTotalPaddingBottom===void 0){const e=window.getComputedStyle(this.$.selector);this._cachedViewportTotalPaddingBottom=[e.paddingBottom,e.borderBottomWidth].map(t=>parseInt(t,10)).reduce((t,i)=>t+i)}return this._cachedViewportTotalPaddingBottom}ready(){super.ready(),this.setAttribute("role","listbox"),this.id=`${this.localName}-${
|
|
4456
|
+
*/const Ru=r=>class extends r{static get properties(){return{items:{type:Array,sync:!0,observer:"__itemsChanged"},focusedIndex:{type:Number,sync:!0,observer:"__focusedIndexChanged"},loading:{type:Boolean,sync:!0,observer:"__loadingChanged"},opened:{type:Boolean,sync:!0,observer:"__openedChanged"},selectedItem:{type:Object,sync:!0,observer:"__selectedItemChanged"},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged"},itemIdPath:{type:String},owner:{type:Object},getItemLabel:{type:Object},renderer:{type:Object,sync:!0,observer:"__rendererChanged"},theme:{type:String}}}constructor(){super(),this.__boundOnItemClick=this.__onItemClick.bind(this)}get _viewportTotalPaddingBottom(){if(this._cachedViewportTotalPaddingBottom===void 0){const e=window.getComputedStyle(this.$.selector);this._cachedViewportTotalPaddingBottom=[e.paddingBottom,e.borderBottomWidth].map(t=>parseInt(t,10)).reduce((t,i)=>t+i)}return this._cachedViewportTotalPaddingBottom}ready(){super.ready(),this.setAttribute("role","listbox"),this.id=`${this.localName}-${qr()}`,this.__hostTagName=this.constructor.is.replace("-scroller",""),this.addEventListener("click",e=>e.stopPropagation()),this.__patchWheelOverScrolling()}requestContentUpdate(){this.__virtualizer&&(this.items&&(this.__virtualizer.size=this.items.length),this.opened&&this.__virtualizer.update())}scrollIntoView(e){if(!this.__virtualizer||!(this.opened&&e>=0))return;const t=this._visibleItemsCount();let i=e;e>this.__virtualizer.lastVisibleIndex-1?(this.__virtualizer.scrollToIndex(e),i=e-t+1):e>this.__virtualizer.firstVisibleIndex&&(i=this.__virtualizer.firstVisibleIndex),this.__virtualizer.scrollToIndex(Math.max(0,i));const o=[...this.children].find(l=>!l.hidden&&l.index===this.__virtualizer.lastVisibleIndex);if(!o||e!==o.index)return;const n=o.getBoundingClientRect(),a=this.getBoundingClientRect(),s=n.bottom-a.bottom+this._viewportTotalPaddingBottom;s>0&&(this.scrollTop+=s)}_isItemSelected(e,t,i){return e instanceof st?!1:i&&e!==void 0&&t!==void 0?Ri(i,e)===Ri(i,t):e===t}__initVirtualizer(){this.__virtualizer=new vy({createElements:this.__createElements.bind(this),updateElement:this._updateElement.bind(this),elementsContainer:this,scrollTarget:this,scrollContainer:this.$.selector,reorderElements:!0})}__itemsChanged(e){e&&this.__virtualizer&&this.requestContentUpdate()}__loadingChanged(){this.requestContentUpdate()}__openedChanged(e){e&&(this.__virtualizer||this.__initVirtualizer(),this.requestContentUpdate())}__selectedItemChanged(){this.requestContentUpdate()}__itemClassNameGeneratorChanged(e,t){(e||t)&&this.requestContentUpdate()}__focusedIndexChanged(e,t){e!==t&&this.requestContentUpdate(),e>=0&&!this.loading&&this.scrollIntoView(e)}__rendererChanged(e,t){(e||t)&&this.requestContentUpdate()}__createElements(e){return[...Array(e)].map(()=>{const t=document.createElement(`${this.__hostTagName}-item`);return t.addEventListener("click",this.__boundOnItemClick),t.tabIndex="-1",t.style.width="100%",t})}_updateElement(e,t){const i=this.items[t],o=this.focusedIndex,n=this._isItemSelected(i,this.selectedItem,this.itemIdPath);e.setProperties({item:i,index:t,label:this.getItemLabel(i),selected:n,renderer:this.renderer,focused:!this.loading&&o===t}),typeof this.itemClassNameGenerator=="function"?e.className=this.itemClassNameGenerator(i):e.className!==""&&(e.className=""),e.performUpdate&&!e.hasUpdated&&e.performUpdate(),e.id=`${this.__hostTagName}-item-${t}`,e.setAttribute("role",t!==void 0?"option":!1),e.setAttribute("aria-selected",n.toString()),e.setAttribute("aria-posinset",t+1),e.setAttribute("aria-setsize",this.items.length),this.theme?e.setAttribute("theme",this.theme):e.removeAttribute("theme"),i instanceof st&&this.__requestItemByIndex(t)}__onItemClick(e){this.dispatchEvent(new CustomEvent("selection-changed",{detail:{item:e.currentTarget.item}}))}__patchWheelOverScrolling(){this.$.selector.addEventListener("wheel",e=>{const t=this.scrollTop===0,i=this.scrollHeight-this.scrollTop-this.clientHeight<=1;(t&&e.deltaY<0||i&&e.deltaY>0)&&e.preventDefault()})}__requestItemByIndex(e){requestAnimationFrame(()=>{this.dispatchEvent(new CustomEvent("index-requested",{detail:{index:e}}))})}_visibleItemsCount(){return this.__virtualizer.scrollToIndex(this.__virtualizer.firstVisibleIndex),this.__virtualizer.size>0?this.__virtualizer.lastVisibleIndex-this.__virtualizer.firstVisibleIndex+1:0}};/**
|
|
4457
4457
|
* @license
|
|
4458
4458
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4459
4459
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4460
|
-
*/class
|
|
4460
|
+
*/class gy extends Ru(H){static get is(){return"vaadin-combo-box-scroller"}static get template(){return z`
|
|
4461
4461
|
<style>
|
|
4462
4462
|
:host {
|
|
4463
4463
|
display: block;
|
|
@@ -4484,11 +4484,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4484
4484
|
<div id="selector">
|
|
4485
4485
|
<slot></slot>
|
|
4486
4486
|
</div>
|
|
4487
|
-
`}}
|
|
4487
|
+
`}}k(gy);/**
|
|
4488
4488
|
* @license
|
|
4489
4489
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4490
4490
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4491
|
-
*/const
|
|
4491
|
+
*/const by=r=>class extends ma(r){static get properties(){return{pattern:{type:String}}}static get delegateAttrs(){return[...super.delegateAttrs,"pattern"]}static get constraints(){return[...super.constraints,"pattern"]}};/**
|
|
4492
4492
|
* @license
|
|
4493
4493
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4494
4494
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4500,11 +4500,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4500
4500
|
* @license
|
|
4501
4501
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4502
4502
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4503
|
-
*/class
|
|
4503
|
+
*/class yy extends EventTarget{constructor(e,{size:t,pageSize:i,isExpanded:o,getItemId:n,isPlaceholder:a,placeholder:s,dataProvider:l,dataProviderParams:d}){super(),ve(this,"host"),ve(this,"dataProvider"),ve(this,"dataProviderParams"),ve(this,"pageSize"),ve(this,"isExpanded"),ve(this,"getItemId"),ve(this,"rootCache"),ve(this,"placeholder"),ve(this,"isPlaceholder"),this.host=e,this.pageSize=i,this.getItemId=n,this.isExpanded=o,this.placeholder=s,this.isPlaceholder=a,this.dataProvider=l,this.dataProviderParams=d,this.rootCache=this.__createRootCache(t)}get flatSize(){return this.rootCache.flatSize}get __cacheContext(){return{isExpanded:this.isExpanded,placeholder:this.placeholder,__controller:this}}isLoading(){return this.rootCache.isLoading}setPageSize(e){this.pageSize=e,this.clearCache()}setDataProvider(e){this.dataProvider=e,this.clearCache()}recalculateFlatSize(){this.rootCache.recalculateFlatSize()}clearCache(){this.rootCache=this.__createRootCache(this.rootCache.size)}getFlatIndexContext(e){return Fi(this.rootCache,e)}getItemContext(e){return Fu({getItemId:this.getItemId},this.rootCache,e)}getFlatIndexByPath(e){return $u(this.rootCache,e)}ensureFlatIndexLoaded(e){const{cache:t,page:i,item:o}=this.getFlatIndexContext(e);this.__isItemLoaded(o)||this.__loadCachePage(t,i)}ensureFlatIndexHierarchy(e){const{cache:t,item:i,index:o}=this.getFlatIndexContext(e);if(this.__isItemLoaded(i)&&this.isExpanded(i)&&!t.getSubCache(o)){const n=t.createSubCache(o);this.__loadCachePage(n,0)}}loadFirstPage(){this.__loadCachePage(this.rootCache,0)}__createRootCache(e){return new fa(this.__cacheContext,this.pageSize,e)}__loadCachePage(e,t){if(!this.dataProvider||e.pendingRequests[t])return;let i={page:t,pageSize:this.pageSize,parentItem:e.parentItem};this.dataProviderParams&&(i=ki(ki({},i),this.dataProviderParams()));const o=(n,a)=>{e.pendingRequests[t]===o&&(a!==void 0?e.size=a:i.parentItem&&(e.size=n.length),e.setPage(t,n),this.recalculateFlatSize(),this.dispatchEvent(new CustomEvent("page-received")),delete e.pendingRequests[t],this.dispatchEvent(new CustomEvent("page-loaded")))};e.pendingRequests[t]=o,this.dispatchEvent(new CustomEvent("page-requested")),this.dataProvider(i,o)}__isItemLoaded(e){return this.isPlaceholder?!this.isPlaceholder(e):this.placeholder?e!==this.placeholder:!!e}}/**
|
|
4504
4504
|
* @license
|
|
4505
4505
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4506
4506
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4507
|
-
*/const Vu=r=>class extends r{static get properties(){return{pageSize:{type:Number,value:50,observer:"_pageSizeChanged",sync:!0},size:{type:Number,observer:"_sizeChanged",sync:!0},dataProvider:{type:Object,observer:"_dataProviderChanged",sync:!0},__dataProviderInitialized:{type:Boolean,value:!1},__previousDataProviderFilter:{type:String}}}static get observers(){return["_dataProviderFilterChanged(filter)","_warnDataProviderValue(dataProvider, value)","_ensureFirstPage(opened)"]}constructor(){super(),this.__dataProviderController=new
|
|
4507
|
+
*/const Vu=r=>class extends r{static get properties(){return{pageSize:{type:Number,value:50,observer:"_pageSizeChanged",sync:!0},size:{type:Number,observer:"_sizeChanged",sync:!0},dataProvider:{type:Object,observer:"_dataProviderChanged",sync:!0},__dataProviderInitialized:{type:Boolean,value:!1},__previousDataProviderFilter:{type:String}}}static get observers(){return["_dataProviderFilterChanged(filter)","_warnDataProviderValue(dataProvider, value)","_ensureFirstPage(opened)"]}constructor(){super(),this.__dataProviderController=new yy(this,{placeholder:new st,isPlaceholder:e=>e instanceof st,dataProviderParams:()=>({filter:this.filter})}),this.__dataProviderController.addEventListener("page-requested",this.__onDataProviderPageRequested.bind(this)),this.__dataProviderController.addEventListener("page-loaded",this.__onDataProviderPageLoaded.bind(this))}ready(){super.ready(),this._scroller.addEventListener("index-requested",e=>{if(!this._shouldFetchData())return;const t=e.detail.index;t!==void 0&&this.__dataProviderController.ensureFlatIndexLoaded(t)}),this.__dataProviderInitialized=!0,this.dataProvider&&this.__synchronizeControllerState()}_dataProviderFilterChanged(e){if(this.__previousDataProviderFilter===void 0&&e===""){this.__previousDataProviderFilter=e;return}this.__previousDataProviderFilter!==e&&(this.__previousDataProviderFilter=e,this.__keepOverlayOpened=!0,this.size=void 0,this.clearCache(),this.__keepOverlayOpened=!1)}_shouldFetchData(){return this.dataProvider?this.opened||this.filter&&this.filter.length:!1}_ensureFirstPage(e){!this._shouldFetchData()||!e||(this._forceNextRequest||this.size===void 0?(this._forceNextRequest=!1,this.__dataProviderController.loadFirstPage()):this.size>0&&this.__dataProviderController.ensureFlatIndexLoaded(0))}__onDataProviderPageRequested(){this.loading=!0}__onDataProviderPageLoaded(){const{rootCache:e}=this.__dataProviderController;e.items=[...e.items],this.__synchronizeControllerState(),!this.opened&&!this._isInputFocused()&&this._commitValue()}clearCache(){this.dataProvider&&(this.__dataProviderController.clearCache(),this.__synchronizeControllerState(),this._shouldFetchData()?(this._forceNextRequest=!1,this.__dataProviderController.loadFirstPage()):this._forceNextRequest=!0)}_sizeChanged(e){const{rootCache:t}=this.__dataProviderController;t.size!==e&&(t.size=e,t.items=[...t.items],this.__synchronizeControllerState())}_filteredItemsChanged(e){if(super._filteredItemsChanged(e),this.dataProvider&&e){const{rootCache:t}=this.__dataProviderController;t.items!==e&&(t.items=e,this.__synchronizeControllerState())}}__synchronizeControllerState(){if(this.__dataProviderInitialized&&this.dataProvider){const{rootCache:e}=this.__dataProviderController;this.size=e.size,this.filteredItems=e.items,this.loading=this.__dataProviderController.isLoading()}}_pageSizeChanged(e,t){if(Math.floor(e)!==e||e<1)throw this.pageSize=t,new Error("`pageSize` value must be an integer > 0");this.__dataProviderController.setPageSize(e),this.clearCache()}_dataProviderChanged(e,t){this._ensureItemsOrDataProvider(()=>{this.dataProvider=t}),this.__dataProviderController.setDataProvider(e),this.clearCache()}_ensureItemsOrDataProvider(e){if(this.items!==void 0&&this.dataProvider!==void 0)throw e(),new Error("Using `items` and `dataProvider` together is not supported")}_warnDataProviderValue(e,t){if(e&&t!==""&&(this.selectedItem===void 0||this.selectedItem===null)){const i=this.__getItemIndexByValue(this.filteredItems,t);(i<0||!this._getItemLabel(this.filteredItems[i]))&&console.warn("Warning: unable to determine the label for the provided `value`. Nothing to display in the text field. This usually happens when setting an initial `value` before any items are returned from the `dataProvider` callback. Consider setting `selectedItem` instead of `value`")}}};/**
|
|
4508
4508
|
* @license
|
|
4509
4509
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4510
4510
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
@@ -4512,11 +4512,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4512
4512
|
* @license
|
|
4513
4513
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4514
4514
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4515
|
-
*/function Qs(r){return r!=null}function Js(r,e){return r.findIndex(t=>t instanceof lt?!1:e(t))}const Uu=r=>class extends Zr(We(ta(Ct(xt(Gr(or(r))))))){static get properties(){return{opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0,observer:"_openedChanged"},autoOpenDisabled:{type:Boolean,sync:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},renderer:{type:Object,sync:!0},items:{type:Array,sync:!0,observer:"_itemsChanged"},allowCustomValue:{type:Boolean,value:!1},filteredItems:{type:Array,observer:"_filteredItemsChanged",sync:!0},_lastCommittedValue:String,loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},_focusedIndex:{type:Number,observer:"_focusedIndexChanged",value:-1,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},selectedItem:{type:Object,notify:!0,sync:!0},itemClassNameGenerator:{type:Object},itemLabelPath:{type:String,value:"label",observer:"_itemLabelPathChanged",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},_toggleElement:{type:Object,observer:"_toggleElementChanged"},_dropdownItems:{type:Array,sync:!0},_closeOnBlurIsPrevented:Boolean,_scroller:{type:Object,sync:!0},_overlayOpened:{type:Boolean,sync:!0,observer:"_overlayOpenedChanged"},__keepOverlayOpened:{type:Boolean,sync:!0}}}static get observers(){return["_selectedItemChanged(selectedItem, itemValuePath, itemLabelPath)","_openedOrItemsChanged(opened, _dropdownItems, loading, __keepOverlayOpened)","_updateScroller(_scroller, _dropdownItems, opened, loading, selectedItem, itemIdPath, _focusedIndex, renderer, _theme, itemClassNameGenerator)"]}constructor(){super(),this._boundOverlaySelectedItemChanged=this._overlaySelectedItemChanged.bind(this),this._boundOnClearButtonMouseDown=this.__onClearButtonMouseDown.bind(this),this._boundOnClick=this._onClick.bind(this),this._boundOnOverlayTouchAction=this._onOverlayTouchAction.bind(this),this._boundOnTouchend=this._onTouchend.bind(this)}get _tagNamePrefix(){return"vaadin-combo-box"}get _nativeInput(){return this.inputElement}_inputElementChanged(e){super._inputElementChanged(e);const t=this._nativeInput;t&&(t.autocomplete="off",t.autocapitalize="off",t.setAttribute("role","combobox"),t.setAttribute("aria-autocomplete","list"),t.setAttribute("aria-expanded",!!this.opened),t.setAttribute("spellcheck","false"),t.setAttribute("autocorrect","off"),this._revertInputValueToValue(),this.clearElement&&this.clearElement.addEventListener("mousedown",this._boundOnClearButtonMouseDown))}ready(){super.ready(),this._initOverlay(),this._initScroller(),this._lastCommittedValue=this.value,this.addEventListener("click",this._boundOnClick),this.addEventListener("touchend",this._boundOnTouchend);const e=()=>{requestAnimationFrame(()=>{this._overlayElement.bringToFront()})};this.addEventListener("mousedown",e),this.addEventListener("touchstart",e),no(this),this.addController(new Su(this))}disconnectedCallback(){super.disconnectedCallback(),this.close()}requestContentUpdate(){this._scroller&&(this._scroller.requestContentUpdate(),this._getItemElements().forEach(e=>{e.requestContentUpdate()}))}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.opened=!1}_propertiesChanged(e,t,i){super._propertiesChanged(e,t,i),t.filter!==void 0&&this._filterChanged(t.filter)}updated(e){super.updated(e),e.has("filter")&&this._filterChanged(this.filter)}_initOverlay(){const e=this.$.overlay;e._comboBox=this,e.addEventListener("touchend",this._boundOnOverlayTouchAction),e.addEventListener("touchmove",this._boundOnOverlayTouchAction),e.addEventListener("mousedown",t=>t.preventDefault()),e.addEventListener("opened-changed",t=>{this._overlayOpened=t.detail.value}),this._overlayElement=e}_initScroller(e){const t=document.createElement(`${this._tagNamePrefix}-scroller`);t.owner=e||this,t.getItemLabel=this._getItemLabel.bind(this),t.addEventListener("selection-changed",this._boundOverlaySelectedItemChanged);const i=this._overlayElement;i.renderer=o=>{o.innerHTML||o.appendChild(t)},i.requestContentUpdate(),this._scroller=t}_updateScroller(e,t,i,o,n,a,s,l,d,u){if(e&&(i&&(e.style.maxHeight=getComputedStyle(this).getPropertyValue(`--${this._tagNamePrefix}-overlay-max-height`)||"65vh"),e.setProperties({items:i?t:[],opened:i,loading:o,selectedItem:n,itemIdPath:a,focusedIndex:s,renderer:l,theme:d,itemClassNameGenerator:u}),e.performUpdate&&!e.hasUpdated))try{e.performUpdate()}catch(c){}}_openedOrItemsChanged(e,t,i,o){this._overlayOpened=e&&(o||i||!!(t&&t.length))}_overlayOpenedChanged(e,t){e?(this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-opened",{bubbles:!0,composed:!0})),this._onOpened()):t&&this._dropdownItems&&this._dropdownItems.length&&(this.close(),this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-closed",{bubbles:!0,composed:!0})))}_focusedIndexChanged(e,t){t!==void 0&&this._updateActiveDescendant(e)}_isInputFocused(){return this.inputElement&&Qn(this.inputElement)}_updateActiveDescendant(e){const t=this._nativeInput;if(!t)return;const i=this._getItemElements().find(o=>o.index===e);i?t.setAttribute("aria-activedescendant",i.id):t.removeAttribute("aria-activedescendant")}_openedChanged(e,t){if(t===void 0)return;e?!this._isInputFocused()&&!gn&&this.inputElement&&this.inputElement.focus():this._onClosed();const i=this._nativeInput;i&&(i.setAttribute("aria-expanded",!!e),e?i.setAttribute("aria-controls",this._scroller.id):i.removeAttribute("aria-controls"))}_onOverlayTouchAction(){this._closeOnBlurIsPrevented=!0,this.inputElement.blur(),this._closeOnBlurIsPrevented=!1}_isClearButton(e){return e.composedPath()[0]===this.clearElement}__onClearButtonMouseDown(e){e.preventDefault(),this.inputElement.focus()}_onClearButtonClick(e){e.preventDefault(),this._onClearAction(),this.opened&&this.requestContentUpdate()}_onToggleButtonClick(e){e.preventDefault(),this.opened?this.close():this.open()}_onHostClick(e){this.autoOpenDisabled||(e.preventDefault(),this.open())}_onClick(e){this._isClearButton(e)?this._onClearButtonClick(e):e.composedPath().includes(this._toggleElement)?this._onToggleButtonClick(e):this._onHostClick(e)}_onKeyDown(e){super._onKeyDown(e),e.key==="ArrowDown"?(this._onArrowDown(),e.preventDefault()):e.key==="ArrowUp"&&(this._onArrowUp(),e.preventDefault())}_getItemLabel(e){let t=e&&this.itemLabelPath?Ri(this.itemLabelPath,e):void 0;return t==null&&(t=e?e.toString():""),t}_getItemValue(e){let t=e&&this.itemValuePath?Ri(this.itemValuePath,e):void 0;return t===void 0&&(t=e?e.toString():""),t}_onArrowDown(){if(this.opened){const e=this._dropdownItems;e&&(this._focusedIndex=Math.min(e.length-1,this._focusedIndex+1),this._prefillFocusedItemLabel())}else this.open()}_onArrowUp(){if(this.opened){if(this._focusedIndex>-1)this._focusedIndex=Math.max(0,this._focusedIndex-1);else{const e=this._dropdownItems;e&&(this._focusedIndex=e.length-1)}this._prefillFocusedItemLabel()}else this.open()}_prefillFocusedItemLabel(){if(this._focusedIndex>-1){const e=this._dropdownItems[this._focusedIndex];this._inputElementValue=this._getItemLabel(e),this._markAllSelectionRange()}}_setSelectionRange(e,t){this._isInputFocused()&&this.inputElement.setSelectionRange&&this.inputElement.setSelectionRange(e,t)}_markAllSelectionRange(){this._inputElementValue!==void 0&&this._setSelectionRange(0,this._inputElementValue.length)}_clearSelectionRange(){if(this._inputElementValue!==void 0){const e=this._inputElementValue?this._inputElementValue.length:0;this._setSelectionRange(e,e)}}_closeOrCommit(){!this.opened&&!this.loading?this._commitValue():this.close()}_onEnter(e){if(!this._hasValidInputValue()){e.preventDefault(),e.stopPropagation();return}this.opened&&(e.preventDefault(),e.stopPropagation()),this._closeOrCommit()}_hasValidInputValue(){const e=this._focusedIndex<0&&this._inputElementValue!==""&&this._getItemLabel(this.selectedItem)!==this._inputElementValue;return this.allowCustomValue||!e}_onEscape(e){this.autoOpenDisabled&&(this.opened||this.value!==this._inputElementValue&&this._inputElementValue.length>0)?(e.stopPropagation(),this._focusedIndex=-1,this.cancel()):this.opened?(e.stopPropagation(),this._focusedIndex>-1?(this._focusedIndex=-1,this._revertInputValue()):this.cancel()):this.clearButtonVisible&&this.value&&!this.readonly&&(e.stopPropagation(),this._onClearAction())}_toggleElementChanged(e){e&&(e.addEventListener("mousedown",t=>t.preventDefault()),e.addEventListener("click",()=>{gn&&!this._isInputFocused()&&document.activeElement.blur()}))}_onClearAction(){this.selectedItem=null,this.allowCustomValue&&(this.value=""),this._detectAndDispatchChange()}_clearFilter(){this.filter=""}cancel(){this._revertInputValueToValue(),this._lastCommittedValue=this.value,this._closeOrCommit()}_onOpened(){this._lastCommittedValue=this.value}_onClosed(){(!this.loading||this.allowCustomValue)&&this._commitValue()}_commitValue(){if(this._focusedIndex>-1){const e=this._dropdownItems[this._focusedIndex];this.selectedItem!==e&&(this.selectedItem=e),this._inputElementValue=this._getItemLabel(this.selectedItem),this._focusedIndex=-1}else if(this._inputElementValue===""||this._inputElementValue===void 0)this.selectedItem=null,this.allowCustomValue&&(this.value="");else{const e=[this.selectedItem,...this._dropdownItems||[]],t=e[this.__getItemIndexByLabel(e,this._inputElementValue)];if(this.allowCustomValue&&!t){const i=this._inputElementValue;this._lastCustomValue=i;const o=new CustomEvent("custom-value-set",{detail:i,composed:!0,cancelable:!0,bubbles:!0});this.dispatchEvent(o),o.defaultPrevented||(this.value=i)}else!this.allowCustomValue&&!this.opened&&t?this.value=this._getItemValue(t):this._revertInputValueToValue()}this._detectAndDispatchChange(),this._clearSelectionRange(),this._clearFilter()}_onInput(e){const t=this._inputElementValue,i={};this.filter===t?this._filterChanged(this.filter):i.filter=t,!this.opened&&!this._isClearButton(e)&&!this.autoOpenDisabled&&(i.opened=!0),this.setProperties(i)}_onChange(e){e.stopPropagation()}_itemLabelPathChanged(e){typeof e!="string"&&console.error("You should set itemLabelPath to a valid string")}_filterChanged(e){this._scrollIntoView(0),this._focusedIndex=-1,this.items?this.filteredItems=this._filterItems(this.items,e):this._filteredItemsChanged(this.filteredItems)}_revertInputValue(){this.filter!==""?this._inputElementValue=this.filter:this._revertInputValueToValue(),this._clearSelectionRange()}_revertInputValueToValue(){this.allowCustomValue&&!this.selectedItem?this._inputElementValue=this.value:this._inputElementValue=this._getItemLabel(this.selectedItem)}_selectedItemChanged(e){if(e==null)this.filteredItems&&(this.allowCustomValue||(this.value=""),this._toggleHasValue(this._hasValue),this._inputElementValue=this.value);else{const t=this._getItemValue(e);if(this.value!==t&&(this.value=t,this.value!==t))return;this._toggleHasValue(!0),this._inputElementValue=this._getItemLabel(e)}}_valueChanged(e,t){e===""&&t===void 0||(Qs(e)?(this._getItemValue(this.selectedItem)!==e&&this._selectItemForValue(e),!this.selectedItem&&this.allowCustomValue&&(this._inputElementValue=e),this._toggleHasValue(this._hasValue)):this.selectedItem=null,this._clearFilter(),this._lastCommittedValue=void 0)}_detectAndDispatchChange(){document.hasFocus()&&this.validate(),this.value!==this._lastCommittedValue&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this._lastCommittedValue=this.value)}_itemsChanged(e,t){this._ensureItemsOrDataProvider(()=>{this.items=t}),e?this.filteredItems=e.slice(0):t&&(this.filteredItems=null)}_filteredItemsChanged(e){this._setDropdownItems(e)}_filterItems(e,t){return e&&e.filter(i=>(t=t?t.toString().toLowerCase():"",this._getItemLabel(i).toString().toLowerCase().indexOf(t)>-1))}_selectItemForValue(e){const t=this.__getItemIndexByValue(this.filteredItems,e),i=this.selectedItem;t>=0?this.selectedItem=this.filteredItems[t]:this.dataProvider&&this.selectedItem===void 0?this.selectedItem=void 0:this.selectedItem=null,this.selectedItem===null&&i===null&&this._selectedItemChanged(this.selectedItem)}_setDropdownItems(e){const t=this._dropdownItems;this._dropdownItems=e;const i=t?t[this._focusedIndex]:null,o=this.__getItemIndexByValue(e,this.value);(this.selectedItem===null||this.selectedItem===void 0)&&o>=0&&(this.selectedItem=e[o]);const n=this.__getItemIndexByValue(e,this._getItemValue(i));n>-1?this._focusedIndex=n:this._focusedIndex=this.__getItemIndexByLabel(e,this.filter)}_getItemElements(){return Array.from(this._scroller.querySelectorAll(`${this._tagNamePrefix}-item`))}_scrollIntoView(e){this._scroller&&this._scroller.scrollIntoView(e)}__getItemIndexByValue(e,t){return!e||!Qs(t)?-1:Js(e,i=>this._getItemValue(i)===t)}__getItemIndexByLabel(e,t){return!e||!t?-1:Js(e,i=>this._getItemLabel(i).toString().toLowerCase()===t.toString().toLowerCase())}_overlaySelectedItemChanged(e){e.stopPropagation(),!(e.detail.item instanceof lt)&&this.opened&&(this._focusedIndex=this.filteredItems.indexOf(e.detail.item),this.close())}_setFocused(e){if(super._setFocused(e),!e&&!this.readonly&&!this._closeOnBlurIsPrevented){if(!this.opened&&this.allowCustomValue&&this._inputElementValue===this._lastCustomValue){delete this._lastCustomValue;return}if(Qi()){this._closeOrCommit();return}this.opened?this._overlayOpened||this.close():this._commitValue()}}_shouldRemoveFocus(e){return e.relatedTarget&&e.relatedTarget.localName===`${this._tagNamePrefix}-item`?!1:e.relatedTarget===this._overlayElement?(e.composedPath()[0].focus(),!1):!0}_onTouchend(e){!this.clearElement||e.composedPath()[0]!==this.clearElement||(e.preventDefault(),this._onClearAction())}};/**
|
|
4515
|
+
*/function Qs(r){return r!=null}function Js(r,e){return r.findIndex(t=>t instanceof st?!1:e(t))}const Uu=r=>class extends Jr(Ue(ta(Et(Ct(Yr(or(r))))))){static get properties(){return{opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0,observer:"_openedChanged"},autoOpenDisabled:{type:Boolean,sync:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},renderer:{type:Object,sync:!0},items:{type:Array,sync:!0,observer:"_itemsChanged"},allowCustomValue:{type:Boolean,value:!1},filteredItems:{type:Array,observer:"_filteredItemsChanged",sync:!0},_lastCommittedValue:String,loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},_focusedIndex:{type:Number,observer:"_focusedIndexChanged",value:-1,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},selectedItem:{type:Object,notify:!0,sync:!0},itemClassNameGenerator:{type:Object},itemLabelPath:{type:String,value:"label",observer:"_itemLabelPathChanged",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},_toggleElement:{type:Object,observer:"_toggleElementChanged"},_dropdownItems:{type:Array,sync:!0},_closeOnBlurIsPrevented:Boolean,_scroller:{type:Object,sync:!0},_overlayOpened:{type:Boolean,sync:!0,observer:"_overlayOpenedChanged"},__keepOverlayOpened:{type:Boolean,sync:!0}}}static get observers(){return["_selectedItemChanged(selectedItem, itemValuePath, itemLabelPath)","_openedOrItemsChanged(opened, _dropdownItems, loading, __keepOverlayOpened)","_updateScroller(_scroller, _dropdownItems, opened, loading, selectedItem, itemIdPath, _focusedIndex, renderer, _theme, itemClassNameGenerator)"]}constructor(){super(),this._boundOverlaySelectedItemChanged=this._overlaySelectedItemChanged.bind(this),this._boundOnClearButtonMouseDown=this.__onClearButtonMouseDown.bind(this),this._boundOnClick=this._onClick.bind(this),this._boundOnOverlayTouchAction=this._onOverlayTouchAction.bind(this),this._boundOnTouchend=this._onTouchend.bind(this)}get _tagNamePrefix(){return"vaadin-combo-box"}get _nativeInput(){return this.inputElement}_inputElementChanged(e){super._inputElementChanged(e);const t=this._nativeInput;t&&(t.autocomplete="off",t.autocapitalize="off",t.setAttribute("role","combobox"),t.setAttribute("aria-autocomplete","list"),t.setAttribute("aria-expanded",!!this.opened),t.setAttribute("spellcheck","false"),t.setAttribute("autocorrect","off"),this._revertInputValueToValue(),this.clearElement&&this.clearElement.addEventListener("mousedown",this._boundOnClearButtonMouseDown))}ready(){super.ready(),this._initOverlay(),this._initScroller(),this._lastCommittedValue=this.value,this.addEventListener("click",this._boundOnClick),this.addEventListener("touchend",this._boundOnTouchend);const e=()=>{requestAnimationFrame(()=>{this._overlayElement.bringToFront()})};this.addEventListener("mousedown",e),this.addEventListener("touchstart",e),no(this),this.addController(new Su(this))}disconnectedCallback(){super.disconnectedCallback(),this.close()}requestContentUpdate(){this._scroller&&(this._scroller.requestContentUpdate(),this._getItemElements().forEach(e=>{e.requestContentUpdate()}))}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.opened=!1}_propertiesChanged(e,t,i){super._propertiesChanged(e,t,i),t.filter!==void 0&&this._filterChanged(t.filter)}updated(e){super.updated(e),e.has("filter")&&this._filterChanged(this.filter)}_initOverlay(){const e=this.$.overlay;e._comboBox=this,e.addEventListener("touchend",this._boundOnOverlayTouchAction),e.addEventListener("touchmove",this._boundOnOverlayTouchAction),e.addEventListener("mousedown",t=>t.preventDefault()),e.addEventListener("opened-changed",t=>{this._overlayOpened=t.detail.value}),this._overlayElement=e}_initScroller(e){const t=document.createElement(`${this._tagNamePrefix}-scroller`);t.owner=e||this,t.getItemLabel=this._getItemLabel.bind(this),t.addEventListener("selection-changed",this._boundOverlaySelectedItemChanged);const i=this._overlayElement;i.renderer=o=>{o.innerHTML||o.appendChild(t)},i.requestContentUpdate(),this._scroller=t}_updateScroller(e,t,i,o,n,a,s,l,d,u){if(e&&(i&&(e.style.maxHeight=getComputedStyle(this).getPropertyValue(`--${this._tagNamePrefix}-overlay-max-height`)||"65vh"),e.setProperties({items:i?t:[],opened:i,loading:o,selectedItem:n,itemIdPath:a,focusedIndex:s,renderer:l,theme:d,itemClassNameGenerator:u}),e.performUpdate&&!e.hasUpdated))try{e.performUpdate()}catch(c){}}_openedOrItemsChanged(e,t,i,o){this._overlayOpened=e&&(o||i||!!(t&&t.length))}_overlayOpenedChanged(e,t){e?(this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-opened",{bubbles:!0,composed:!0})),this._onOpened()):t&&this._dropdownItems&&this._dropdownItems.length&&(this.close(),this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-closed",{bubbles:!0,composed:!0})))}_focusedIndexChanged(e,t){t!==void 0&&this._updateActiveDescendant(e)}_isInputFocused(){return this.inputElement&&Qn(this.inputElement)}_updateActiveDescendant(e){const t=this._nativeInput;if(!t)return;const i=this._getItemElements().find(o=>o.index===e);i?t.setAttribute("aria-activedescendant",i.id):t.removeAttribute("aria-activedescendant")}_openedChanged(e,t){if(t===void 0)return;e?!this._isInputFocused()&&!gn&&this.inputElement&&this.inputElement.focus():this._onClosed();const i=this._nativeInput;i&&(i.setAttribute("aria-expanded",!!e),e?i.setAttribute("aria-controls",this._scroller.id):i.removeAttribute("aria-controls"))}_onOverlayTouchAction(){this._closeOnBlurIsPrevented=!0,this.inputElement.blur(),this._closeOnBlurIsPrevented=!1}_isClearButton(e){return e.composedPath()[0]===this.clearElement}__onClearButtonMouseDown(e){e.preventDefault(),this.inputElement.focus()}_onClearButtonClick(e){e.preventDefault(),this._onClearAction(),this.opened&&this.requestContentUpdate()}_onToggleButtonClick(e){e.preventDefault(),this.opened?this.close():this.open()}_onHostClick(e){this.autoOpenDisabled||(e.preventDefault(),this.open())}_onClick(e){this._isClearButton(e)?this._onClearButtonClick(e):e.composedPath().includes(this._toggleElement)?this._onToggleButtonClick(e):this._onHostClick(e)}_onKeyDown(e){super._onKeyDown(e),e.key==="ArrowDown"?(this._onArrowDown(),e.preventDefault()):e.key==="ArrowUp"&&(this._onArrowUp(),e.preventDefault())}_getItemLabel(e){let t=e&&this.itemLabelPath?Ri(this.itemLabelPath,e):void 0;return t==null&&(t=e?e.toString():""),t}_getItemValue(e){let t=e&&this.itemValuePath?Ri(this.itemValuePath,e):void 0;return t===void 0&&(t=e?e.toString():""),t}_onArrowDown(){if(this.opened){const e=this._dropdownItems;e&&(this._focusedIndex=Math.min(e.length-1,this._focusedIndex+1),this._prefillFocusedItemLabel())}else this.open()}_onArrowUp(){if(this.opened){if(this._focusedIndex>-1)this._focusedIndex=Math.max(0,this._focusedIndex-1);else{const e=this._dropdownItems;e&&(this._focusedIndex=e.length-1)}this._prefillFocusedItemLabel()}else this.open()}_prefillFocusedItemLabel(){if(this._focusedIndex>-1){const e=this._dropdownItems[this._focusedIndex];this._inputElementValue=this._getItemLabel(e),this._markAllSelectionRange()}}_setSelectionRange(e,t){this._isInputFocused()&&this.inputElement.setSelectionRange&&this.inputElement.setSelectionRange(e,t)}_markAllSelectionRange(){this._inputElementValue!==void 0&&this._setSelectionRange(0,this._inputElementValue.length)}_clearSelectionRange(){if(this._inputElementValue!==void 0){const e=this._inputElementValue?this._inputElementValue.length:0;this._setSelectionRange(e,e)}}_closeOrCommit(){!this.opened&&!this.loading?this._commitValue():this.close()}_onEnter(e){if(!this._hasValidInputValue()){e.preventDefault(),e.stopPropagation();return}this.opened&&(e.preventDefault(),e.stopPropagation()),this._closeOrCommit()}_hasValidInputValue(){const e=this._focusedIndex<0&&this._inputElementValue!==""&&this._getItemLabel(this.selectedItem)!==this._inputElementValue;return this.allowCustomValue||!e}_onEscape(e){this.autoOpenDisabled&&(this.opened||this.value!==this._inputElementValue&&this._inputElementValue.length>0)?(e.stopPropagation(),this._focusedIndex=-1,this.cancel()):this.opened?(e.stopPropagation(),this._focusedIndex>-1?(this._focusedIndex=-1,this._revertInputValue()):this.cancel()):this.clearButtonVisible&&this.value&&!this.readonly&&(e.stopPropagation(),this._onClearAction())}_toggleElementChanged(e){e&&(e.addEventListener("mousedown",t=>t.preventDefault()),e.addEventListener("click",()=>{gn&&!this._isInputFocused()&&document.activeElement.blur()}))}_onClearAction(){this.selectedItem=null,this.allowCustomValue&&(this.value=""),this._detectAndDispatchChange()}_clearFilter(){this.filter=""}cancel(){this._revertInputValueToValue(),this._lastCommittedValue=this.value,this._closeOrCommit()}_onOpened(){this._lastCommittedValue=this.value}_onClosed(){(!this.loading||this.allowCustomValue)&&this._commitValue()}_commitValue(){if(this._focusedIndex>-1){const e=this._dropdownItems[this._focusedIndex];this.selectedItem!==e&&(this.selectedItem=e),this._inputElementValue=this._getItemLabel(this.selectedItem),this._focusedIndex=-1}else if(this._inputElementValue===""||this._inputElementValue===void 0)this.selectedItem=null,this.allowCustomValue&&(this.value="");else{const e=[this.selectedItem,...this._dropdownItems||[]],t=e[this.__getItemIndexByLabel(e,this._inputElementValue)];if(this.allowCustomValue&&!t){const i=this._inputElementValue;this._lastCustomValue=i;const o=new CustomEvent("custom-value-set",{detail:i,composed:!0,cancelable:!0,bubbles:!0});this.dispatchEvent(o),o.defaultPrevented||(this.value=i)}else!this.allowCustomValue&&!this.opened&&t?this.value=this._getItemValue(t):this._revertInputValueToValue()}this._detectAndDispatchChange(),this._clearSelectionRange(),this._clearFilter()}_onInput(e){const t=this._inputElementValue,i={};this.filter===t?this._filterChanged(this.filter):i.filter=t,!this.opened&&!this._isClearButton(e)&&!this.autoOpenDisabled&&(i.opened=!0),this.setProperties(i)}_onChange(e){e.stopPropagation()}_itemLabelPathChanged(e){typeof e!="string"&&console.error("You should set itemLabelPath to a valid string")}_filterChanged(e){this._scrollIntoView(0),this._focusedIndex=-1,this.items?this.filteredItems=this._filterItems(this.items,e):this._filteredItemsChanged(this.filteredItems)}_revertInputValue(){this.filter!==""?this._inputElementValue=this.filter:this._revertInputValueToValue(),this._clearSelectionRange()}_revertInputValueToValue(){this.allowCustomValue&&!this.selectedItem?this._inputElementValue=this.value:this._inputElementValue=this._getItemLabel(this.selectedItem)}_selectedItemChanged(e){if(e==null)this.filteredItems&&(this.allowCustomValue||(this.value=""),this._toggleHasValue(this._hasValue),this._inputElementValue=this.value);else{const t=this._getItemValue(e);if(this.value!==t&&(this.value=t,this.value!==t))return;this._toggleHasValue(!0),this._inputElementValue=this._getItemLabel(e)}}_valueChanged(e,t){e===""&&t===void 0||(Qs(e)?(this._getItemValue(this.selectedItem)!==e&&this._selectItemForValue(e),!this.selectedItem&&this.allowCustomValue&&(this._inputElementValue=e),this._toggleHasValue(this._hasValue)):this.selectedItem=null,this._clearFilter(),this._lastCommittedValue=void 0)}_detectAndDispatchChange(){document.hasFocus()&&this.validate(),this.value!==this._lastCommittedValue&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this._lastCommittedValue=this.value)}_itemsChanged(e,t){this._ensureItemsOrDataProvider(()=>{this.items=t}),e?this.filteredItems=e.slice(0):t&&(this.filteredItems=null)}_filteredItemsChanged(e){this._setDropdownItems(e)}_filterItems(e,t){return e&&e.filter(i=>(t=t?t.toString().toLowerCase():"",this._getItemLabel(i).toString().toLowerCase().indexOf(t)>-1))}_selectItemForValue(e){const t=this.__getItemIndexByValue(this.filteredItems,e),i=this.selectedItem;t>=0?this.selectedItem=this.filteredItems[t]:this.dataProvider&&this.selectedItem===void 0?this.selectedItem=void 0:this.selectedItem=null,this.selectedItem===null&&i===null&&this._selectedItemChanged(this.selectedItem)}_setDropdownItems(e){const t=this._dropdownItems;this._dropdownItems=e;const i=t?t[this._focusedIndex]:null,o=this.__getItemIndexByValue(e,this.value);(this.selectedItem===null||this.selectedItem===void 0)&&o>=0&&(this.selectedItem=e[o]);const n=this.__getItemIndexByValue(e,this._getItemValue(i));n>-1?this._focusedIndex=n:this._focusedIndex=this.__getItemIndexByLabel(e,this.filter)}_getItemElements(){return Array.from(this._scroller.querySelectorAll(`${this._tagNamePrefix}-item`))}_scrollIntoView(e){this._scroller&&this._scroller.scrollIntoView(e)}__getItemIndexByValue(e,t){return!e||!Qs(t)?-1:Js(e,i=>this._getItemValue(i)===t)}__getItemIndexByLabel(e,t){return!e||!t?-1:Js(e,i=>this._getItemLabel(i).toString().toLowerCase()===t.toString().toLowerCase())}_overlaySelectedItemChanged(e){e.stopPropagation(),!(e.detail.item instanceof st)&&this.opened&&(this._focusedIndex=this.filteredItems.indexOf(e.detail.item),this.close())}_setFocused(e){if(super._setFocused(e),!e&&!this.readonly&&!this._closeOnBlurIsPrevented){if(!this.opened&&this.allowCustomValue&&this._inputElementValue===this._lastCustomValue){delete this._lastCustomValue;return}if(Qi()){this._closeOrCommit();return}this.opened?this._overlayOpened||this.close():this._commitValue()}}_shouldRemoveFocus(e){return e.relatedTarget&&e.relatedTarget.localName===`${this._tagNamePrefix}-item`?!1:e.relatedTarget===this._overlayElement?(e.composedPath()[0].focus(),!1):!0}_onTouchend(e){!this.clearElement||e.composedPath()[0]!==this.clearElement||(e.preventDefault(),this._onClearAction())}};/**
|
|
4516
4516
|
* @license
|
|
4517
4517
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4518
4518
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4519
|
-
*/
|
|
4519
|
+
*/x("vaadin-combo-box",io,{moduleId:"vaadin-combo-box-styles"});class wy extends Vu(Uu(by(ro(X(Ne(H)))))){static get is(){return"vaadin-combo-box"}static get template(){return z`
|
|
4520
4520
|
<style>
|
|
4521
4521
|
:host([opened]) {
|
|
4522
4522
|
pointer-events: auto;
|
|
@@ -4561,11 +4561,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4561
4561
|
></vaadin-combo-box-overlay>
|
|
4562
4562
|
|
|
4563
4563
|
<slot name="tooltip"></slot>
|
|
4564
|
-
`}static get properties(){return{_positionTarget:{type:Object}}}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new
|
|
4564
|
+
`}static get properties(){return{_positionTarget:{type:Object}}}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new Gr(this,e=>{this._setInputElement(e),this._setFocusElement(e),this.stateTarget=e,this.ariaTarget=e})),this.addController(new Xr(this.inputElement,this._labelController)),this._tooltipController=new Qe(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow(e=>!e.opened),this._positionTarget=this.shadowRoot.querySelector('[part="input-field"]'),this._toggleElement=this.$.toggleButton}_onClearButtonClick(e){e.stopPropagation(),super._onClearButtonClick(e)}_onHostClick(e){const t=e.composedPath();(t.includes(this._labelNode)||t.includes(this._positionTarget))&&super._onHostClick(e)}}k(wy);/**
|
|
4565
4565
|
* @license
|
|
4566
4566
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4567
4567
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4568
|
-
*/const
|
|
4568
|
+
*/const xy=v`
|
|
4569
4569
|
:host {
|
|
4570
4570
|
font-size: var(--lumo-font-size-xxs);
|
|
4571
4571
|
line-height: 1;
|
|
@@ -4654,27 +4654,27 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4654
4654
|
-webkit-text-fill-color: var(--lumo-disabled-text-color);
|
|
4655
4655
|
pointer-events: none;
|
|
4656
4656
|
}
|
|
4657
|
-
`;
|
|
4657
|
+
`;x("vaadin-multi-select-combo-box-chip",[oa,xy],{moduleId:"lumo-multi-select-combo-box-chip"});/**
|
|
4658
4658
|
* @license
|
|
4659
4659
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4660
4660
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4661
|
-
*/const
|
|
4661
|
+
*/const Cy=v`
|
|
4662
4662
|
@media (any-hover: hover) {
|
|
4663
4663
|
:host(:hover[readonly]) {
|
|
4664
4664
|
background-color: transparent;
|
|
4665
4665
|
cursor: default;
|
|
4666
4666
|
}
|
|
4667
4667
|
}
|
|
4668
|
-
`;
|
|
4668
|
+
`;x("vaadin-multi-select-combo-box-item",[oo,Ou,Cy],{moduleId:"lumo-multi-select-combo-box-item"});x("vaadin-multi-select-combo-box-overlay",[nr,eo,Mu,Nu,Bu,v`
|
|
4669
4669
|
:host {
|
|
4670
4670
|
--_vaadin-multi-select-combo-box-items-container-border-width: var(--lumo-space-xs);
|
|
4671
4671
|
--_vaadin-multi-select-combo-box-items-container-border-style: solid;
|
|
4672
4672
|
}
|
|
4673
|
-
`],{moduleId:"lumo-multi-select-combo-box-overlay"});
|
|
4673
|
+
`],{moduleId:"lumo-multi-select-combo-box-overlay"});x("vaadin-multi-select-combo-box-container",v`
|
|
4674
4674
|
:host([auto-expand-vertically]) {
|
|
4675
4675
|
padding-block: var(--lumo-space-xs);
|
|
4676
4676
|
}
|
|
4677
|
-
`,{moduleId:"lumo-multi-select-combo-box-container"});const
|
|
4677
|
+
`,{moduleId:"lumo-multi-select-combo-box-container"});const Ey=v`
|
|
4678
4678
|
:host([has-value]) {
|
|
4679
4679
|
padding-inline-start: 0;
|
|
4680
4680
|
}
|
|
@@ -4727,11 +4727,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4727
4727
|
color: var(--lumo-contrast-60pct);
|
|
4728
4728
|
cursor: var(--lumo-clickable-cursor);
|
|
4729
4729
|
}
|
|
4730
|
-
`;
|
|
4730
|
+
`;x("vaadin-multi-select-combo-box",[Tt,Ey],{moduleId:"lumo-multi-select-combo-box"});/**
|
|
4731
4731
|
* @license
|
|
4732
4732
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4733
4733
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4734
|
-
*/class
|
|
4734
|
+
*/class Ty extends X(H){static get is(){return"vaadin-multi-select-combo-box-chip"}static get properties(){return{disabled:{type:Boolean,reflectToAttribute:!0},readonly:{type:Boolean,reflectToAttribute:!0},label:{type:String},item:{type:Object}}}static get template(){return z`
|
|
4735
4735
|
<style>
|
|
4736
4736
|
:host {
|
|
4737
4737
|
display: inline-flex;
|
|
@@ -4760,11 +4760,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4760
4760
|
</style>
|
|
4761
4761
|
<div part="label">[[label]]</div>
|
|
4762
4762
|
<div part="remove-button" on-click="_onRemoveClick"></div>
|
|
4763
|
-
`}_onRemoveClick(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("item-removed",{detail:{item:this.item},bubbles:!0,composed:!0}))}}
|
|
4763
|
+
`}_onRemoveClick(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("item-removed",{detail:{item:this.item},bubbles:!0,composed:!0}))}}k(Ty);/**
|
|
4764
4764
|
* @license
|
|
4765
4765
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4766
4766
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4767
|
-
*/
|
|
4767
|
+
*/x("vaadin-multi-select-combo-box-container",v`
|
|
4768
4768
|
#wrapper {
|
|
4769
4769
|
display: flex;
|
|
4770
4770
|
width: 100%;
|
|
@@ -4774,11 +4774,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4774
4774
|
:host([auto-expand-vertically]) #wrapper {
|
|
4775
4775
|
flex-wrap: wrap;
|
|
4776
4776
|
}
|
|
4777
|
-
`,{moduleId:"vaadin-multi-select-combo-box-container-styles"});let hi;class
|
|
4777
|
+
`,{moduleId:"vaadin-multi-select-combo-box-container-styles"});let hi;class Py extends pu{static get is(){return"vaadin-multi-select-combo-box-container"}static get template(){if(!hi){hi=super.template.cloneNode(!0);const e=hi.content,t=e.querySelectorAll("slot"),i=document.createElement("div");i.setAttribute("id","wrapper"),e.insertBefore(i,t[2]),i.appendChild(t[0]),i.appendChild(t[1])}return hi}static get properties(){return{autoExpandVertically:{type:Boolean,reflectToAttribute:!0}}}}k(Py);/**
|
|
4778
4778
|
* @license
|
|
4779
4779
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4780
4780
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4781
|
-
*/class
|
|
4781
|
+
*/class Ay extends Lu(X(Oe(H))){static get is(){return"vaadin-multi-select-combo-box-item"}static get template(){return z`
|
|
4782
4782
|
<style>
|
|
4783
4783
|
:host {
|
|
4784
4784
|
display: block;
|
|
@@ -4792,11 +4792,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4792
4792
|
<div part="content">
|
|
4793
4793
|
<slot></slot>
|
|
4794
4794
|
</div>
|
|
4795
|
-
`}}
|
|
4795
|
+
`}}k(Ay);/**
|
|
4796
4796
|
* @license
|
|
4797
4797
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4798
4798
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4799
|
-
*/const
|
|
4799
|
+
*/const ky=v`
|
|
4800
4800
|
#overlay {
|
|
4801
4801
|
width: var(
|
|
4802
4802
|
--vaadin-multi-select-combo-box-overlay-width,
|
|
@@ -4809,17 +4809,17 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4809
4809
|
flex-direction: column;
|
|
4810
4810
|
height: 100%;
|
|
4811
4811
|
}
|
|
4812
|
-
`;
|
|
4812
|
+
`;x("vaadin-multi-select-combo-box-overlay",[Kr,ky],{moduleId:"vaadin-multi-select-combo-box-overlay-styles"});class Iy extends zu(Qr(Oe(X(H)))){static get is(){return"vaadin-multi-select-combo-box-overlay"}static get template(){return z`
|
|
4813
4813
|
<div id="backdrop" part="backdrop" hidden></div>
|
|
4814
4814
|
<div part="overlay" id="overlay">
|
|
4815
4815
|
<div part="loader"></div>
|
|
4816
4816
|
<div part="content" id="content"><slot></slot></div>
|
|
4817
4817
|
</div>
|
|
4818
|
-
`}}
|
|
4818
|
+
`}}k(Iy);/**
|
|
4819
4819
|
* @license
|
|
4820
4820
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4821
4821
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4822
|
-
*/class
|
|
4822
|
+
*/class Sy extends Ru(H){static get is(){return"vaadin-multi-select-combo-box-scroller"}static get template(){return z`
|
|
4823
4823
|
<style>
|
|
4824
4824
|
:host {
|
|
4825
4825
|
display: block;
|
|
@@ -4846,11 +4846,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4846
4846
|
<div id="selector">
|
|
4847
4847
|
<slot></slot>
|
|
4848
4848
|
</div>
|
|
4849
|
-
`}ready(){super.ready(),this.setAttribute("aria-multiselectable","true")}_isItemSelected(e,t,i){return e instanceof
|
|
4849
|
+
`}ready(){super.ready(),this.setAttribute("aria-multiselectable","true")}_isItemSelected(e,t,i){return e instanceof st||this.owner.readonly?!1:this.owner._findIndex(e,this.owner.selectedItems,i)>-1}_updateElement(e,t){super._updateElement(e,t),e.toggleAttribute("readonly",this.owner.readonly)}}k(Sy);/**
|
|
4850
4850
|
* @license
|
|
4851
4851
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4852
4852
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4853
|
-
*/class
|
|
4853
|
+
*/class Dy extends Vu(Uu(X(H))){static get is(){return"vaadin-multi-select-combo-box-internal"}static get template(){return z`
|
|
4854
4854
|
<style>
|
|
4855
4855
|
:host([opened]) {
|
|
4856
4856
|
pointer-events: auto;
|
|
@@ -4868,15 +4868,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4868
4868
|
no-vertical-overlap
|
|
4869
4869
|
restore-focus-node="[[inputElement]]"
|
|
4870
4870
|
></vaadin-multi-select-combo-box-overlay>
|
|
4871
|
-
`}static get properties(){return{filteredItems:{type:Array,notify:!0},keepFilter:{type:Boolean,value:!1},loading:{type:Boolean,notify:!0},size:{type:Number,notify:!0},selectedItems:{type:Array,value:()=>[]},selectedItemsOnTop:{type:Boolean,value:!1},lastFilter:{type:String,notify:!0},topGroup:{type:Array,observer:"_topGroupChanged"},_target:{type:Object}}}static get observers(){return["_readonlyChanged(readonly)"]}get clearElement(){return this.querySelector('[part="clear-button"]')}get _tagNamePrefix(){return"vaadin-multi-select-combo-box"}constructor(){super(),this.addEventListener("custom-value-set",this.__onCustomValueSet.bind(this))}open(){!this.disabled&&!(this.readonly&&this.selectedItems.length===0)&&(this.opened=!0)}ready(){super.ready(),this._target=this,this._toggleElement=this.querySelector(".toggle-button")}_readonlyChanged(){this._setDropdownItems(this.filteredItems)}_setDropdownItems(e){if(this.readonly){super._setDropdownItems(this.selectedItems);return}if(this.filter||!this.selectedItemsOnTop){super._setDropdownItems(e);return}if(e&&e.length&&this.topGroup&&this.topGroup.length){const t=e.filter(i=>this._comboBox._findIndex(i,this.topGroup,this.itemIdPath)===-1);super._setDropdownItems(this.topGroup.concat(t));return}super._setDropdownItems(e)}_topGroupChanged(e){e&&this._setDropdownItems(this.filteredItems)}_initScroller(){const e=this.getRootNode().host;this._comboBox=e,super._initScroller(e)}_onEnter(e){if(this.opened){if(e.preventDefault(),e.stopPropagation(),this.readonly)this.close();else if(this._hasValidInputValue()){const t=this._dropdownItems[this._focusedIndex];this._commitValue(),this._focusedIndex=this._dropdownItems.indexOf(t)}return}super._onEnter(e)}_onEscape(e){if(this.readonly){e.stopPropagation(),this.opened&&this.close();return}super._onEscape(e)}_clearFilter(){(!this.keepFilter||!this.opened)&&super._clearFilter()}_revertInputValueToValue(){super._revertInputValueToValue(),this.filter=""}_commitValue(){this.lastFilter=this.filter,super._commitValue()}_onArrowDown(){this.readonly?this.opened||this.open():super._onArrowDown()}_onArrowUp(){this.readonly?this.opened||this.open():super._onArrowUp()}_setFocused(e){e||(this._ignoreCommitValue=!0),super._setFocused(e),!e&&this.readonly&&!this._closeOnBlurIsPrevented&&this.close()}_onClosed(){this._ignoreCommitValue=!0,super._onClosed()}_detectAndDispatchChange(){if(this._ignoreCommitValue){this._ignoreCommitValue=!1,this.clear(),this._inputElementValue="";return}super._detectAndDispatchChange()}_overlaySelectedItemChanged(e){e.stopPropagation(),!this.readonly&&(e.detail.item instanceof
|
|
4871
|
+
`}static get properties(){return{filteredItems:{type:Array,notify:!0},keepFilter:{type:Boolean,value:!1},loading:{type:Boolean,notify:!0},size:{type:Number,notify:!0},selectedItems:{type:Array,value:()=>[]},selectedItemsOnTop:{type:Boolean,value:!1},lastFilter:{type:String,notify:!0},topGroup:{type:Array,observer:"_topGroupChanged"},_target:{type:Object}}}static get observers(){return["_readonlyChanged(readonly)"]}get clearElement(){return this.querySelector('[part="clear-button"]')}get _tagNamePrefix(){return"vaadin-multi-select-combo-box"}constructor(){super(),this.addEventListener("custom-value-set",this.__onCustomValueSet.bind(this))}open(){!this.disabled&&!(this.readonly&&this.selectedItems.length===0)&&(this.opened=!0)}ready(){super.ready(),this._target=this,this._toggleElement=this.querySelector(".toggle-button")}_readonlyChanged(){this._setDropdownItems(this.filteredItems)}_setDropdownItems(e){if(this.readonly){super._setDropdownItems(this.selectedItems);return}if(this.filter||!this.selectedItemsOnTop){super._setDropdownItems(e);return}if(e&&e.length&&this.topGroup&&this.topGroup.length){const t=e.filter(i=>this._comboBox._findIndex(i,this.topGroup,this.itemIdPath)===-1);super._setDropdownItems(this.topGroup.concat(t));return}super._setDropdownItems(e)}_topGroupChanged(e){e&&this._setDropdownItems(this.filteredItems)}_initScroller(){const e=this.getRootNode().host;this._comboBox=e,super._initScroller(e)}_onEnter(e){if(this.opened){if(e.preventDefault(),e.stopPropagation(),this.readonly)this.close();else if(this._hasValidInputValue()){const t=this._dropdownItems[this._focusedIndex];this._commitValue(),this._focusedIndex=this._dropdownItems.indexOf(t)}return}super._onEnter(e)}_onEscape(e){if(this.readonly){e.stopPropagation(),this.opened&&this.close();return}super._onEscape(e)}_clearFilter(){(!this.keepFilter||!this.opened)&&super._clearFilter()}_revertInputValueToValue(){super._revertInputValueToValue(),this.filter=""}_commitValue(){this.lastFilter=this.filter,super._commitValue()}_onArrowDown(){this.readonly?this.opened||this.open():super._onArrowDown()}_onArrowUp(){this.readonly?this.opened||this.open():super._onArrowUp()}_setFocused(e){e||(this._ignoreCommitValue=!0),super._setFocused(e),!e&&this.readonly&&!this._closeOnBlurIsPrevented&&this.close()}_onClosed(){this._ignoreCommitValue=!0,super._onClosed()}_detectAndDispatchChange(){if(this._ignoreCommitValue){this._ignoreCommitValue=!1,this.clear(),this._inputElementValue="";return}super._detectAndDispatchChange()}_overlaySelectedItemChanged(e){e.stopPropagation(),!this.readonly&&(e.detail.item instanceof st||this.opened&&(this.lastFilter=this.filter,this.dispatchEvent(new CustomEvent("combo-box-item-selected",{detail:{item:e.detail.item}}))))}_shouldFetchData(){return this.readonly?!1:super._shouldFetchData()}clearCache(){this.readonly||super.clearCache()}__onCustomValueSet(e){this._ignoreCommitValue&&e.stopImmediatePropagation()}}k(Dy);/**
|
|
4872
4872
|
* @license
|
|
4873
4873
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4874
4874
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4875
|
-
*/const pi=new ResizeObserver(r=>{setTimeout(()=>{r.forEach(e=>{e.target.resizables?e.target.resizables.forEach(t=>{t._onResize(e.contentRect)}):e.target._onResize(e.contentRect)})})}),Wu=
|
|
4875
|
+
*/const pi=new ResizeObserver(r=>{setTimeout(()=>{r.forEach(e=>{e.target.resizables?e.target.resizables.forEach(t=>{t._onResize(e.contentRect)}):e.target._onResize(e.contentRect)})})}),Wu=le(r=>class extends r{get _observeParent(){return!1}connectedCallback(){if(super.connectedCallback(),pi.observe(this),this._observeParent){const e=this.parentNode instanceof ShadowRoot?this.parentNode.host:this.parentNode;e.resizables||(e.resizables=new Set,pi.observe(e)),e.resizables.add(this),this.__parent=e}}disconnectedCallback(){super.disconnectedCallback(),pi.unobserve(this);const e=this.__parent;if(this._observeParent&&e){const t=e.resizables;t&&(t.delete(this),t.size===0&&pi.unobserve(e)),this.__parent=null}}_onResize(e){}});/**
|
|
4876
4876
|
* @license
|
|
4877
4877
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
4878
4878
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4879
|
-
*/const
|
|
4879
|
+
*/const Oy=v`
|
|
4880
4880
|
:host {
|
|
4881
4881
|
--input-min-width: var(--vaadin-multi-select-combo-box-input-min-width, 4em);
|
|
4882
4882
|
--_chip-min-width: var(--vaadin-multi-select-combo-box-chip-min-width, 50px);
|
|
@@ -4914,7 +4914,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4914
4914
|
:host([auto-expand-horizontally]) [class$='container'] {
|
|
4915
4915
|
width: auto;
|
|
4916
4916
|
}
|
|
4917
|
-
`;
|
|
4917
|
+
`;x("vaadin-multi-select-combo-box",[io,Oy],{moduleId:"vaadin-multi-select-combo-box-styles"});class Ny extends Wu(ro(X(Ne(H)))){static get is(){return"vaadin-multi-select-combo-box"}static get template(){return z`
|
|
4918
4918
|
<div class="vaadin-multi-select-combo-box-container">
|
|
4919
4919
|
<div part="label">
|
|
4920
4920
|
<slot name="label"></slot>
|
|
@@ -4990,7 +4990,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
4990
4990
|
color: transparent !important;
|
|
4991
4991
|
forced-color-adjust: none;
|
|
4992
4992
|
}
|
|
4993
|
-
`]}get clearElement(){return this.$.clearButton}get _chips(){return[...this.querySelectorAll('[slot="chip"]')]}get _hasValue(){return this.selectedItems&&this.selectedItems.length>0}ready(){super.ready(),this.addController(new
|
|
4993
|
+
`]}get clearElement(){return this.$.clearButton}get _chips(){return[...this.querySelectorAll('[slot="chip"]')]}get _hasValue(){return this.selectedItems&&this.selectedItems.length>0}ready(){super.ready(),this.addController(new Gr(this,e=>{this._setInputElement(e),this._setFocusElement(e),this.stateTarget=e,this.ariaTarget=e})),this.addController(new Xr(this.inputElement,this._labelController)),this._tooltipController=new Qe(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow(e=>!e.opened),this._inputField=this.shadowRoot.querySelector('[part="input-field"]'),this._overflowController=new xe(this,"overflow","vaadin-multi-select-combo-box-chip",{initializer:e=>{e.addEventListener("mousedown",t=>this._preventBlur(t)),this._overflow=e}}),this.addController(this._overflowController),this.__updateChips(),no(this)}checkValidity(){return this.required&&!this.readonly?this._hasValue:!0}clear(){this.__updateSelection([]),yi(this.i18n.cleared)}clearCache(){this.$&&this.$.comboBox&&this.$.comboBox.clearCache()}requestContentUpdate(){this.$&&this.$.comboBox&&this.$.comboBox.requestContentUpdate()}_disabledChanged(e,t){super._disabledChanged(e,t),(e||t)&&this.__updateChips()}_inputElementChanged(e){super._inputElementChanged(e),e&&this.$.comboBox._setInputElement(e)}_setFocused(e){super._setFocused(e),!e&&document.hasFocus()&&(this._focusedChipIndex=-1,this.validate())}_onResize(){this.__updateChips()}_delegateAttribute(e,t){if(this.stateTarget){if(e==="required"){this._delegateAttribute("aria-required",t?"true":!1);return}super._delegateAttribute(e,t)}}_autoExpandHorizontallyChanged(e,t){(e||t)&&this.__updateChips()}_autoExpandVerticallyChanged(e,t){(e||t)&&this.__updateChips()}_clearButtonVisibleChanged(e,t){(e||t)&&this.__updateChips()}_onFilteredItemsChanged(e){const{value:t}=e.detail;(Array.isArray(t)||t==null)&&(this.filteredItems=t)}_readonlyChanged(e,t){(e||t)&&this.__updateChips(),this.dataProvider&&this.clearCache()}__itemClassNameGeneratorChanged(e,t){(e||t)&&this.__updateChips()}_pageSizeChanged(e,t){(Math.floor(e)!==e||e<=0)&&(this.pageSize=t,console.error('"pageSize" value must be an integer > 0')),this.$.comboBox.pageSize=this.pageSize}_placeholderChanged(e){const t=this.__tmpA11yPlaceholder;t!==e&&(this.__savedPlaceholder=e,t&&(this.placeholder=t))}_selectedItemsChanged(e){if(this._toggleHasValue(this._hasValue),this._hasValue){const t=this._mergeItemLabels(e);this.__tmpA11yPlaceholder===void 0&&(this.__savedPlaceholder=this.placeholder),this.__tmpA11yPlaceholder=t,this.placeholder=t}else this.__tmpA11yPlaceholder!==void 0&&(delete this.__tmpA11yPlaceholder,this.placeholder=this.__savedPlaceholder);this.__updateChips(),this.requestContentUpdate(),this.opened&&this.$.comboBox.$.overlay._updateOverlayWidth()}_getItemLabel(e){return this.$.comboBox._getItemLabel(e)}_mergeItemLabels(e){return e.map(t=>this._getItemLabel(t)).join(", ")}_findIndex(e,t,i){if(i&&e){for(let o=0;o<t.length;o++)if(t[o]&&t[o][i]===e[i])return o;return-1}return t.indexOf(e)}__clearInternalValue(e=!1){!this.keepFilter||e?(this.filter="",this.$.comboBox.clear()):(this.$.comboBox.clear(),this._inputElementValue=this.filter)}__announceItem(e,t,i){const o=t?"selected":"deselected",n=this.i18n.total.replace("{count}",i||0);yi(`${e} ${this.i18n[o]} ${n}`)}__removeItem(e){const t=[...this.selectedItems];t.splice(t.indexOf(e),1),this.__updateSelection(t);const i=this._getItemLabel(e);this.__announceItem(i,!1,t.length)}__selectItem(e){const t=[...this.selectedItems],i=this._findIndex(e,t,this.itemIdPath),o=this._getItemLabel(e);let n=!1;if(i!==-1){const a=this._lastFilter;if(a&&a.toLowerCase()===o.toLowerCase()){this.__clearInternalValue();return}t.splice(i,1)}else t.push(e),n=!0;this.__updateSelection(t),this.__clearInternalValue(),this.__announceItem(o,n,t.length)}__updateSelection(e){this.selectedItems=e,this.validate(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}__updateTopGroup(e,t,i){e?i||(this._topGroup=[...t]):this._topGroup=[]}__createChip(e){const t=document.createElement("vaadin-multi-select-combo-box-chip");t.setAttribute("slot","chip"),t.item=e,t.disabled=this.disabled,t.readonly=this.readonly;const i=this._getItemLabel(e);return t.label=i,t.setAttribute("title",i),typeof this.itemClassNameGenerator=="function"&&(t.className=this.itemClassNameGenerator(e)),t.addEventListener("item-removed",o=>this._onItemRemoved(o)),t.addEventListener("mousedown",o=>this._preventBlur(o)),t}__getOverflowWidth(){const e=this._overflow;e.style.visibility="hidden",e.removeAttribute("hidden");const t=e.getAttribute("count");e.setAttribute("count","99");const i=getComputedStyle(e),o=e.clientWidth+parseInt(i.marginInlineStart);return e.setAttribute("count",t),e.setAttribute("hidden",""),e.style.visibility="",o}__updateChips(){if(!this._inputField||!this.inputElement)return;this._chips.forEach(a=>{a.remove()});const e=[...this.selectedItems],t=this._inputField.$.wrapper.clientWidth,i=parseInt(getComputedStyle(this.inputElement).flexBasis);let o=t-i;e.length>1&&(o-=this.__getOverflowWidth());const n=parseInt(getComputedStyle(this).getPropertyValue("--_chip-min-width"));if(this.autoExpandHorizontally){const a=[];for(let d=e.length-1,u=null;d>=0;d--){const c=this.__createChip(e[d]);this.insertBefore(c,u),u=c,a.unshift(c)}const s=[],l=this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth;if(!this.autoExpandVertically&&l<i){for(;a.length>1;){a.pop().remove(),s.unshift(e.pop());const d=s.length>0?i+this.__getOverflowWidth():i;if(this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth>=d)break}a.length===1&&(a[0].style.maxWidth=`${Math.max(n,o)}px`)}this._overflowItems=s;return}for(let a=e.length-1,s=null;a>=0;a--){const l=this.__createChip(e[a]);if(this.insertBefore(l,s),!this.autoExpandVertically&&this.$.chips.clientWidth>o)if(s===null)l.style.maxWidth=`${Math.max(n,o)}px`;else{l.remove();break}e.pop(),s=l}this._overflowItems=e}__updateOverflowChip(e,t,i,o){if(e){const n=t.length;e.label=`${n}`,e.setAttribute("count",`${n}`),e.setAttribute("title",this._mergeItemLabels(t)),e.toggleAttribute("hidden",n===0),e.disabled=i,e.readonly=o}}_onClearButtonTouchend(e){e.preventDefault(),e.stopPropagation(),this.clear()}_onClearButtonClick(e){e.stopPropagation(),this.clear()}_onChange(e){e.stopPropagation()}_onEscape(e){this.clearButtonVisible&&this.selectedItems&&this.selectedItems.length&&(e.stopPropagation(),this.selectedItems=[])}_onKeyDown(e){super._onKeyDown(e);const t=this._chips;if(!this.readonly&&t.length>0)switch(e.key){case"Backspace":this._onBackSpace(t);break;case"ArrowLeft":this._onArrowLeft(t,e);break;case"ArrowRight":this._onArrowRight(t,e);break;default:this._focusedChipIndex=-1;break}}_onArrowLeft(e,t){if(this.inputElement.selectionStart!==0)return;const i=this._focusedChipIndex;i!==-1&&t.preventDefault();let o;this.__isRTL?i===e.length-1?o=-1:i>-1&&(o=i+1):i===-1?o=e.length-1:i>0&&(o=i-1),o!==void 0&&(this._focusedChipIndex=o)}_onArrowRight(e,t){if(this.inputElement.selectionStart!==0)return;const i=this._focusedChipIndex;i!==-1&&t.preventDefault();let o;this.__isRTL?i===-1?o=e.length-1:i>0&&(o=i-1):i===e.length-1?o=-1:i>-1&&(o=i+1),o!==void 0&&(this._focusedChipIndex=o)}_onBackSpace(e){if(this.inputElement.selectionStart!==0)return;const t=this._focusedChipIndex;t===-1?this._focusedChipIndex=e.length-1:(this.__removeItem(e[t].item),this._focusedChipIndex=-1)}_focusedChipIndexChanged(e,t){if(e>-1||t>-1){const i=this._chips;if(i.forEach((o,n)=>{o.toggleAttribute("focused",n===e)}),e>-1){const o=i[e].item,n=this._getItemLabel(o);yi(`${n} ${this.i18n.focused}`)}}}_onComboBoxChange(){const e=this.$.comboBox.selectedItem;e&&this.__selectItem(e)}_onComboBoxItemSelected(e){this.__selectItem(e.detail.item)}_onCustomValueSet(e){e.preventDefault(),e.stopPropagation(),this.__clearInternalValue(!0),this.dispatchEvent(new CustomEvent("custom-value-set",{detail:e.detail,composed:!0,bubbles:!0}))}_onItemRemoved(e){this.__removeItem(e.detail.item)}_preventBlur(e){e.preventDefault()}}k(Ny);x("vaadin-notification-card",v`
|
|
4994
4994
|
:host {
|
|
4995
4995
|
position: relative;
|
|
4996
4996
|
margin: var(--lumo-space-s);
|
|
@@ -5208,11 +5208,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5208
5208
|
* @license
|
|
5209
5209
|
* Copyright 2020 Google LLC
|
|
5210
5210
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5211
|
-
*/const
|
|
5211
|
+
*/const My=(r,e)=>(r==null?void 0:r._$litType$)!==void 0;/**
|
|
5212
5212
|
* @license
|
|
5213
5213
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5214
5214
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5215
|
-
*/class
|
|
5215
|
+
*/class By extends gu(X(Ne(H))){static get template(){return z`
|
|
5216
5216
|
<style>
|
|
5217
5217
|
:host {
|
|
5218
5218
|
position: fixed;
|
|
@@ -5279,7 +5279,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5279
5279
|
<div region="bottom-end"><slot name="bottom-end"></slot></div>
|
|
5280
5280
|
</div>
|
|
5281
5281
|
<div region="bottom-stretch"><slot name="bottom-stretch"></slot></div>
|
|
5282
|
-
`}static get is(){return"vaadin-notification-container"}static get properties(){return{opened:{type:Boolean,value:!1,observer:"_openedChanged"}}}constructor(){super(),this._boundVaadinOverlayClose=this._onVaadinOverlayClose.bind(this),aa&&(this._boundIosResizeListener=()=>this._detectIosNavbar())}_openedChanged(e){e?(document.body.appendChild(this),document.addEventListener("vaadin-overlay-close",this._boundVaadinOverlayClose),this._boundIosResizeListener&&(this._detectIosNavbar(),window.addEventListener("resize",this._boundIosResizeListener))):(document.body.removeChild(this),document.removeEventListener("vaadin-overlay-close",this._boundVaadinOverlayClose),this._boundIosResizeListener&&window.removeEventListener("resize",this._boundIosResizeListener))}_detectIosNavbar(){const e=window.innerHeight,t=window.innerWidth>e,i=document.documentElement.clientHeight;t&&i>e?this.style.bottom=`${i-e}px`:this.style.bottom="0"}_onVaadinOverlayClose(e){const t=e.detail.sourceEvent;t&&t.composedPath().indexOf(this)>=0&&e.preventDefault()}}class
|
|
5282
|
+
`}static get is(){return"vaadin-notification-container"}static get properties(){return{opened:{type:Boolean,value:!1,observer:"_openedChanged"}}}constructor(){super(),this._boundVaadinOverlayClose=this._onVaadinOverlayClose.bind(this),aa&&(this._boundIosResizeListener=()=>this._detectIosNavbar())}_openedChanged(e){e?(document.body.appendChild(this),document.addEventListener("vaadin-overlay-close",this._boundVaadinOverlayClose),this._boundIosResizeListener&&(this._detectIosNavbar(),window.addEventListener("resize",this._boundIosResizeListener))):(document.body.removeChild(this),document.removeEventListener("vaadin-overlay-close",this._boundVaadinOverlayClose),this._boundIosResizeListener&&window.removeEventListener("resize",this._boundIosResizeListener))}_detectIosNavbar(){const e=window.innerHeight,t=window.innerWidth>e,i=document.documentElement.clientHeight;t&&i>e?this.style.bottom=`${i-e}px`:this.style.bottom="0"}_onVaadinOverlayClose(e){const t=e.detail.sourceEvent;t&&t.composedPath().indexOf(this)>=0&&e.preventDefault()}}class Ly extends X(H){static get template(){return z`
|
|
5283
5283
|
<style>
|
|
5284
5284
|
:host {
|
|
5285
5285
|
display: block;
|
|
@@ -5301,14 +5301,14 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5301
5301
|
<slot></slot>
|
|
5302
5302
|
</div>
|
|
5303
5303
|
</div>
|
|
5304
|
-
`}static get is(){return"vaadin-notification-card"}ready(){super.ready(),this.setAttribute("role","alert"),this.setAttribute("aria-live","polite")}}class
|
|
5304
|
+
`}static get is(){return"vaadin-notification-card"}ready(){super.ready(),this.setAttribute("role","alert"),this.setAttribute("aria-live","polite")}}class Ye extends Jr(Gi(Ne(H))){static get template(){return z`
|
|
5305
5305
|
<style>
|
|
5306
5306
|
:host {
|
|
5307
5307
|
display: none !important;
|
|
5308
5308
|
}
|
|
5309
5309
|
</style>
|
|
5310
5310
|
<vaadin-notification-card theme$="[[_theme]]"> </vaadin-notification-card>
|
|
5311
|
-
`}static get is(){return"vaadin-notification"}static get properties(){return{duration:{type:Number,value:5e3},opened:{type:Boolean,value:!1,notify:!0,observer:"_openedChanged"},position:{type:String,value:"bottom-start",observer:"_positionChanged"},renderer:Function}}static get observers(){return["_durationChanged(duration, opened)","_rendererChanged(renderer, opened, _overlayElement)"]}static show(e,t){return
|
|
5311
|
+
`}static get is(){return"vaadin-notification"}static get properties(){return{duration:{type:Number,value:5e3},opened:{type:Boolean,value:!1,notify:!0,observer:"_openedChanged"},position:{type:String,value:"bottom-start",observer:"_positionChanged"},renderer:Function}}static get observers(){return["_durationChanged(duration, opened)","_rendererChanged(renderer, opened, _overlayElement)"]}static show(e,t){return My(e)?Ye._createAndShowNotification(i=>{_d(e,i)},t):Ye._createAndShowNotification(i=>{i.innerText=e},t)}static _createAndShowNotification(e,t){const i=document.createElement(Ye.is);return t&&Number.isFinite(t.duration)&&(i.duration=t.duration),t&&t.position&&(i.position=t.position),t&&t.theme&&i.setAttribute("theme",t.theme),i.renderer=e,document.body.appendChild(i),i.opened=!0,i.addEventListener("opened-changed",o=>{o.detail.value||i.remove()}),i}get _container(){return Ye._container||(Ye._container=document.createElement("vaadin-notification-container"),document.body.appendChild(Ye._container)),Ye._container}get _card(){return this._overlayElement}ready(){super.ready(),this._overlayElement=this.shadowRoot.querySelector("vaadin-notification-card"),no(this)}disconnectedCallback(){super.disconnectedCallback(),queueMicrotask(()=>{this.isConnected||(this.opened=!1)})}requestContentUpdate(){this.renderer&&this.renderer(this._card,this)}_rendererChanged(e,t,i){if(!i)return;const o=this._oldRenderer!==e;this._oldRenderer=e,o&&(i.innerHTML="",delete i._$litPart$),t&&(this._didAnimateNotificationAppend||this._animatedAppendNotificationCard(),this.requestContentUpdate())}open(){this.opened=!0}close(){this.opened=!1}_openedChanged(e){e?(this._container.opened=!0,this._animatedAppendNotificationCard()):this._card&&this._closeNotificationCard()}__cleanUpOpeningClosingState(){this._card.removeAttribute("opening"),this._card.removeAttribute("closing"),this._card.removeEventListener("animationend",this.__animationEndListener)}_animatedAppendNotificationCard(){this._card?(this.__cleanUpOpeningClosingState(),this._card.setAttribute("opening",""),this._appendNotificationCard(),this.__animationEndListener=()=>this.__cleanUpOpeningClosingState(),this._card.addEventListener("animationend",this.__animationEndListener),this._didAnimateNotificationAppend=!0):this._didAnimateNotificationAppend=!1}_appendNotificationCard(){if(this._card){if(!this._container.shadowRoot.querySelector(`slot[name="${this.position}"]`)){console.warn(`Invalid alignment parameter provided: position=${this.position}`);return}this._container.bringToFront(),this._card.slot=this.position,this._container.firstElementChild&&/top/u.test(this.position)?this._container.insertBefore(this._card,this._container.firstElementChild):this._container.appendChild(this._card)}}_removeNotificationCard(){this._card.parentNode&&this._card.parentNode.removeChild(this._card),this._card.removeAttribute("closing"),this._container.opened=!!this._container.firstElementChild,this.dispatchEvent(new CustomEvent("closed"))}_closeNotificationCard(){this._durationTimeoutId&&clearTimeout(this._durationTimeoutId),this._animatedRemoveNotificationCard()}_animatedRemoveNotificationCard(){this.__cleanUpOpeningClosingState(),this._card.setAttribute("closing","");const e=getComputedStyle(this._card).getPropertyValue("animation-name");e&&e!=="none"?(this.__animationEndListener=()=>{this._removeNotificationCard(),this.__cleanUpOpeningClosingState()},this._card.addEventListener("animationend",this.__animationEndListener)):this._removeNotificationCard()}_positionChanged(){this.opened&&this._animatedAppendNotificationCard()}_durationChanged(e,t){t&&(clearTimeout(this._durationTimeoutId),e>0&&(this._durationTimeoutId=setTimeout(()=>this.close(),e)))}}k(By);k(Ly);k(Ye);const ju=v`
|
|
5312
5312
|
:host {
|
|
5313
5313
|
-webkit-tap-highlight-color: transparent;
|
|
5314
5314
|
--_lumo-item-selected-icon-display: var(--_lumo-list-box-item-selected-icon-display, block);
|
|
@@ -5322,11 +5322,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5322
5322
|
margin: var(--lumo-space-s) var(--lumo-border-radius-m);
|
|
5323
5323
|
background-color: var(--lumo-contrast-10pct);
|
|
5324
5324
|
}
|
|
5325
|
-
`;
|
|
5325
|
+
`;x("vaadin-list-box",ju,{moduleId:"lumo-list-box"});/**
|
|
5326
5326
|
* @license
|
|
5327
5327
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5328
5328
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5329
|
-
*/
|
|
5329
|
+
*/x("vaadin-select-item",oo,{moduleId:"lumo-select-item"});x("vaadin-select-list-box",ju,{moduleId:"lumo-select-list-box"});const zy=v`
|
|
5330
5330
|
:host(:not([theme*='align'])) ::slotted([slot='value']) {
|
|
5331
5331
|
text-align: start;
|
|
5332
5332
|
}
|
|
@@ -5369,7 +5369,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5369
5369
|
--_lumo-selected-item-height: var(--lumo-size-s);
|
|
5370
5370
|
--_lumo-selected-item-padding: 0;
|
|
5371
5371
|
}
|
|
5372
|
-
`;
|
|
5372
|
+
`;x("vaadin-select",[Tt,zy],{moduleId:"lumo-select"});x("vaadin-select-value-button",v`
|
|
5373
5373
|
:host {
|
|
5374
5374
|
font-family: var(--lumo-font-family);
|
|
5375
5375
|
font-size: var(--vaadin-input-field-value-font-size, var(--lumo-font-size-m));
|
|
@@ -5388,7 +5388,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5388
5388
|
::slotted(*:hover) {
|
|
5389
5389
|
background-color: transparent;
|
|
5390
5390
|
}
|
|
5391
|
-
`,{moduleId:"lumo-select-value-button"});const
|
|
5391
|
+
`,{moduleId:"lumo-select-value-button"});const Hy=v`
|
|
5392
5392
|
:host {
|
|
5393
5393
|
--_lumo-item-selected-icon-display: block;
|
|
5394
5394
|
}
|
|
@@ -5424,15 +5424,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5424
5424
|
:host([theme~='align-center']) {
|
|
5425
5425
|
text-align: center;
|
|
5426
5426
|
}
|
|
5427
|
-
`;
|
|
5427
|
+
`;x("vaadin-select-overlay",[ia,Hy],{moduleId:"lumo-select-overlay"});/**
|
|
5428
5428
|
* @license
|
|
5429
5429
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5430
5430
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5431
|
-
*/const qu=r=>class extends Gn(
|
|
5431
|
+
*/const qu=r=>class extends Gn(Et(r)){static get properties(){return{_hasVaadinItemMixin:{value:!0},selected:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_selectedChanged"},_value:String}}get _activeKeys(){return["Enter"," "]}get value(){return this._value!==void 0?this._value:this.textContent.trim()}set value(e){this._value=e}ready(){super.ready();const e=this.getAttribute("value");e!==null&&(this.value=e)}focus(){this.disabled||(super.focus(),this._setFocused(!0))}_shouldSetActive(e){return!this.disabled&&!(e.type==="keydown"&&e.defaultPrevented)}_selectedChanged(e){this.setAttribute("aria-selected",e)}_disabledChanged(e){super._disabledChanged(e),e&&(this.selected=!1,this.blur())}_onKeyDown(e){super._onKeyDown(e),this._activeKeys.includes(e.key)&&!e.defaultPrevented&&(e.preventDefault(),this.click())}};/**
|
|
5432
5432
|
* @license
|
|
5433
5433
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5434
5434
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5435
|
-
*/class
|
|
5435
|
+
*/class Ry extends qu(X(Oe(H))){static get is(){return"vaadin-select-item"}static get template(){return z`
|
|
5436
5436
|
<style>
|
|
5437
5437
|
:host {
|
|
5438
5438
|
display: inline-block;
|
|
@@ -5446,23 +5446,23 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5446
5446
|
<div part="content">
|
|
5447
5447
|
<slot></slot>
|
|
5448
5448
|
</div>
|
|
5449
|
-
`}ready(){super.ready(),this.setAttribute("role","option")}}
|
|
5449
|
+
`}ready(){super.ready(),this.setAttribute("role","option")}}k(Ry);/**
|
|
5450
5450
|
* @license
|
|
5451
5451
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
5452
5452
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5453
|
-
*/function Yu(r,e){const{scrollLeft:t}=r;return e!=="rtl"?t:r.scrollWidth-r.clientWidth+t}function
|
|
5453
|
+
*/function Yu(r,e){const{scrollLeft:t}=r;return e!=="rtl"?t:r.scrollWidth-r.clientWidth+t}function Fy(r,e,t){e!=="rtl"?r.scrollLeft=t:r.scrollLeft=r.clientWidth-r.scrollWidth+t}/**
|
|
5454
5454
|
* @license
|
|
5455
5455
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
5456
5456
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5457
|
-
*/const
|
|
5457
|
+
*/const $y=r=>class extends Ct(r){get focused(){return(this._getItems()||[]).find(Qn)}get _vertical(){return!0}focus(){const e=this._getItems();if(Array.isArray(e)){const t=this._getAvailableIndex(e,0,null,i=>!fn(i));t>=0&&this._focus(t)}}_getItems(){return Array.from(this.children)}_onKeyDown(e){if(super._onKeyDown(e),e.metaKey||e.ctrlKey)return;const{key:t}=e,i=this._getItems()||[],o=i.indexOf(this.focused);let n,a;const s=!this._vertical&&this.getAttribute("dir")==="rtl"?-1:1;this.__isPrevKey(t)?(a=-s,n=o-s):this.__isNextKey(t)?(a=s,n=o+s):t==="Home"?(a=1,n=0):t==="End"&&(a=-1,n=i.length-1),n=this._getAvailableIndex(i,n,a,l=>!fn(l)),n>=0&&(e.preventDefault(),this._focus(n,!0))}__isPrevKey(e){return this._vertical?e==="ArrowUp":e==="ArrowLeft"}__isNextKey(e){return this._vertical?e==="ArrowDown":e==="ArrowRight"}_focus(e,t=!1){const i=this._getItems();this._focusItem(i[e],t)}_focusItem(e){e&&(e.focus(),e.setAttribute("focus-ring",""))}_getAvailableIndex(e,t,i,o){const n=e.length;let a=t;for(let s=0;typeof a=="number"&&s<n;s+=1,a+=i||1){a<0?a=n-1:a>=n&&(a=0);const l=e[a];if(!l.hasAttribute("disabled")&&this.__isMatchingItem(l,o))return a}return-1}__isMatchingItem(e,t){return typeof t=="function"?t(e):!0}};/**
|
|
5458
5458
|
* @license
|
|
5459
5459
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5460
5460
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5461
|
-
*/const Gu=r=>class extends
|
|
5461
|
+
*/const Gu=r=>class extends $y(r){static get properties(){return{disabled:{type:Boolean,value:!1,reflectToAttribute:!0},selected:{type:Number,reflectToAttribute:!0,notify:!0},orientation:{type:String,reflectToAttribute:!0,value:""},items:{type:Array,readOnly:!0,notify:!0},_searchBuf:{type:String,value:""}}}static get observers(){return["_enhanceItems(items, orientation, selected, disabled)"]}get _isRTL(){return!this._vertical&&this.getAttribute("dir")==="rtl"}get _scrollerElement(){return console.warn(`Please implement the '_scrollerElement' property in <${this.localName}>`),this}get _vertical(){return this.orientation!=="horizontal"}focus(){this._observer&&this._observer.flush();const e=Array.isArray(this.items)?this.items:[],t=this._getAvailableIndex(e,0,null,i=>i.tabIndex===0&&!fn(i));t>=0?this._focus(t):super.focus()}ready(){super.ready(),this.addEventListener("click",t=>this._onClick(t));const e=this.shadowRoot.querySelector("slot:not([name])");this._observer=new Wn(e,()=>{this._setItems(this._filterItems(Jd(this)))})}_getItems(){return this.items}_enhanceItems(e,t,i,o){if(!o&&e){this.setAttribute("aria-orientation",t||"vertical"),e.forEach(a=>{t?a.setAttribute("orientation",t):a.removeAttribute("orientation")}),this._setFocusable(i<0||!i?0:i);const n=e[i];e.forEach(a=>{a.selected=a===n}),n&&!n.disabled&&this._scrollToItem(i)}}_filterItems(e){return e.filter(t=>t._hasVaadinItemMixin)}_onClick(e){if(e.metaKey||e.shiftKey||e.ctrlKey||e.defaultPrevented)return;const t=this._filterItems(e.composedPath())[0];let i;t&&!t.disabled&&(i=this.items.indexOf(t))>=0&&(this.selected=i)}_searchKey(e,t){this._searchReset=Se.debounce(this._searchReset,nt.after(500),()=>{this._searchBuf=""}),this._searchBuf+=t.toLowerCase(),this.items.some(o=>this.__isMatchingKey(o))||(this._searchBuf=t.toLowerCase());const i=this._searchBuf.length===1?e+1:e;return this._getAvailableIndex(this.items,i,1,o=>this.__isMatchingKey(o)&&getComputedStyle(o).display!=="none")}__isMatchingKey(e){return e.textContent.replace(/[^\p{L}\p{Nd}]/gu,"").toLowerCase().startsWith(this._searchBuf)}_onKeyDown(e){if(e.metaKey||e.ctrlKey)return;const t=e.key,i=this.items.indexOf(this.focused);if(/[\p{L}\p{Nd}]/u.test(t)&&t.length===1){const o=this._searchKey(i,t);o>=0&&this._focus(o);return}super._onKeyDown(e)}_isItemHidden(e){return getComputedStyle(e).display==="none"}_setFocusable(e){e=this._getAvailableIndex(this.items,e,1);const t=this.items[e];this.items.forEach(i=>{i.tabIndex=i===t?0:-1})}_focus(e){this.items.forEach((t,i)=>{t.focused=i===e}),this._setFocusable(e),this._scrollToItem(e),super._focus(e)}_scrollToItem(e){const t=this.items[e];if(!t)return;const i=this._vertical?["top","bottom"]:this._isRTL?["right","left"]:["left","right"],o=this._scrollerElement.getBoundingClientRect(),n=(this.items[e+1]||t).getBoundingClientRect(),a=(this.items[e-1]||t).getBoundingClientRect();let s=0;!this._isRTL&&n[i[1]]>=o[i[1]]||this._isRTL&&n[i[1]]<=o[i[1]]?s=n[i[1]]-o[i[1]]:(!this._isRTL&&a[i[0]]<=o[i[0]]||this._isRTL&&a[i[0]]>=o[i[0]])&&(s=a[i[0]]-o[i[0]]),this._scroll(s)}_scroll(e){if(this._vertical)this._scrollerElement.scrollTop+=e;else{const t=this.getAttribute("dir")||"ltr",i=Yu(this._scrollerElement,t)+e;Fy(this._scrollerElement,t,i)}}};/**
|
|
5462
5462
|
* @license
|
|
5463
5463
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5464
5464
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5465
|
-
*/class
|
|
5465
|
+
*/class Vy extends Gu(X(Oe(Ue(H)))){static get is(){return"vaadin-select-list-box"}static get template(){return z`
|
|
5466
5466
|
<style>
|
|
5467
5467
|
:host {
|
|
5468
5468
|
display: flex;
|
|
@@ -5482,15 +5482,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5482
5482
|
<div part="items">
|
|
5483
5483
|
<slot></slot>
|
|
5484
5484
|
</div>
|
|
5485
|
-
`}static get properties(){return{orientation:{readOnly:!0}}}get _scrollerElement(){return this.shadowRoot.querySelector('[part="items"]')}ready(){super.ready(),this.setAttribute("role","listbox")}}
|
|
5485
|
+
`}static get properties(){return{orientation:{readOnly:!0}}}get _scrollerElement(){return this.shadowRoot.querySelector('[part="items"]')}ready(){super.ready(),this.setAttribute("role","listbox")}}k(Vy);/**
|
|
5486
5486
|
* @license
|
|
5487
5487
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5488
5488
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5489
|
-
*/const
|
|
5489
|
+
*/const Uy=r=>class extends sa(Qr(Oe(r))){static get observers(){return["_updateOverlayWidth(opened, owner)"]}ready(){super.ready(),this.restoreFocusOnClose=!0}_getMenuElement(){return Array.from(this.children).find(e=>e.localName!=="style")}_updateOverlayWidth(e,t){if(e&&t){const i="--vaadin-select-overlay-width",o=getComputedStyle(t).getPropertyValue(i);o===""?this.style.removeProperty(i):this.style.setProperty(i,o)}}};/**
|
|
5490
5490
|
* @license
|
|
5491
5491
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5492
5492
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5493
|
-
*/const
|
|
5493
|
+
*/const Wy=v`
|
|
5494
5494
|
:host {
|
|
5495
5495
|
align-items: flex-start;
|
|
5496
5496
|
justify-content: flex-start;
|
|
@@ -5505,18 +5505,18 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5505
5505
|
outline: 3px solid;
|
|
5506
5506
|
}
|
|
5507
5507
|
}
|
|
5508
|
-
`;
|
|
5508
|
+
`;x("vaadin-select-overlay",[Kr,Wy],{moduleId:"vaadin-select-overlay-styles"});class jy extends Uy(X(H)){static get is(){return"vaadin-select-overlay"}static get template(){return z`
|
|
5509
5509
|
<div id="backdrop" part="backdrop" hidden$="[[!withBackdrop]]"></div>
|
|
5510
5510
|
<div part="overlay" id="overlay" tabindex="0">
|
|
5511
5511
|
<div part="content" id="content">
|
|
5512
5512
|
<slot></slot>
|
|
5513
5513
|
</div>
|
|
5514
5514
|
</div>
|
|
5515
|
-
`}ready(){super.ready(),this.owner=this.__dataHost,this.owner._overlayElement=this}requestContentUpdate(){if(super.requestContentUpdate(),this.owner){const e=this._getMenuElement();this.owner._assignMenuElement(e)}}}
|
|
5515
|
+
`}ready(){super.ready(),this.owner=this.__dataHost,this.owner._overlayElement=this}requestContentUpdate(){if(super.requestContentUpdate(),this.owner){const e=this._getMenuElement();this.owner._assignMenuElement(e)}}}k(jy);/**
|
|
5516
5516
|
* @license
|
|
5517
5517
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5518
5518
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5519
|
-
*/const
|
|
5519
|
+
*/const qy=v`
|
|
5520
5520
|
:host {
|
|
5521
5521
|
display: inline-block;
|
|
5522
5522
|
position: relative;
|
|
@@ -5562,17 +5562,17 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5562
5562
|
* @license
|
|
5563
5563
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5564
5564
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5565
|
-
*/
|
|
5565
|
+
*/x("vaadin-select-value-button",qy,{moduleId:"vaadin-select-value-button-styles"});class Yy extends la(X(H)){static get is(){return"vaadin-select-value-button"}static get template(){return z`
|
|
5566
5566
|
<div class="vaadin-button-container">
|
|
5567
5567
|
<span part="label">
|
|
5568
5568
|
<slot></slot>
|
|
5569
5569
|
</span>
|
|
5570
5570
|
</div>
|
|
5571
|
-
`}}
|
|
5571
|
+
`}}k(Yy);/**
|
|
5572
5572
|
* @license
|
|
5573
5573
|
* Copyright (c) 2021 - 2024 Vaadin Ltd..
|
|
5574
5574
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5575
|
-
*/const
|
|
5575
|
+
*/const Gy=v`
|
|
5576
5576
|
.sr-only {
|
|
5577
5577
|
border: 0 !important;
|
|
5578
5578
|
clip: rect(1px, 1px, 1px, 1px) !important;
|
|
@@ -5590,15 +5590,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5590
5590
|
* @license
|
|
5591
5591
|
* Copyright (c) 2023 - 2024 Vaadin Ltd.
|
|
5592
5592
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5593
|
-
*/class
|
|
5593
|
+
*/class Xy extends xe{constructor(e){super(e,"value","vaadin-select-value-button",{initializer:(t,i)=>{i._setFocusElement(t),i.ariaTarget=t,i.stateTarget=t,t.setAttribute("aria-haspopup","listbox")}})}}/**
|
|
5594
5594
|
* @license
|
|
5595
5595
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5596
5596
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5597
|
-
*/const
|
|
5597
|
+
*/const Ky=r=>class extends Jr(Ji(Jn(Ct(Zi(r))))){static get properties(){return{items:{type:Array,observer:"__itemsChanged"},opened:{type:Boolean,value:!1,notify:!0,reflectToAttribute:!0,sync:!0},renderer:{type:Object},value:{type:String,value:"",notify:!0,observer:"_valueChanged"},name:{type:String},placeholder:{type:String},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},noVerticalOverlap:{type:Boolean,value:!1},_phone:Boolean,_phoneMediaQuery:{value:"(max-width: 450px), (max-height: 450px)"},_inputContainer:Object,_items:Object}}static get delegateAttrs(){return[...super.delegateAttrs,"invalid"]}static get observers(){return["_updateAriaExpanded(opened, focusElement)","_updateSelectedItem(value, _items, placeholder)","_openedChanged(opened, _overlayElement, _inputContainer)"]}constructor(){super(),this._itemId=`value-${this.localName}-${qr()}`,this._srLabelController=new uu(this),this._srLabelController.slotName="sr-label"}disconnectedCallback(){super.disconnectedCallback(),this.opened=!1}ready(){super.ready(),this._inputContainer=this.shadowRoot.querySelector('[part~="input-field"]'),this._valueButtonController=new Xy(this),this.addController(this._valueButtonController),this.addController(this._srLabelController),this.addController(new pa(this._phoneMediaQuery,e=>{this._phone=e})),this._tooltipController=new Qe(this),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.focusElement),this.addController(this._tooltipController)}requestContentUpdate(){this._overlayElement&&(this._overlayElement.requestContentUpdate(),this._menuElement&&this._menuElement.items&&this._updateSelectedItem(this.value,this._menuElement.items))}_requiredChanged(e){super._requiredChanged(e),e===!1&&this.validate()}__itemsChanged(e,t){(e||t)&&this.requestContentUpdate()}_assignMenuElement(e){e&&e!==this.__lastMenuElement&&(this._menuElement=e,this.__initMenuItems(e),e.addEventListener("items-changed",()=>{this.__initMenuItems(e)}),e.addEventListener("selected-changed",()=>this.__updateValueButton()),e.addEventListener("keydown",t=>this._onKeyDownInside(t),!0),e.addEventListener("click",t=>{const i=t.composedPath().find(o=>o._hasVaadinItemMixin);this.__dispatchChangePending=!!(i&&i.value!==void 0&&i.value!==this.value),this.opened=!1},!0),this.__lastMenuElement=e)}__initMenuItems(e){e.items&&(this._items=e.items)}_valueChanged(e,t){this.toggleAttribute("has-value",!!e),t!==void 0&&!this.__dispatchChangePending&&this.validate()}_onClick(e){this.disabled||(e.preventDefault(),this.opened=!this.readonly)}_onToggleMouseDown(e){e.preventDefault()}_onKeyDown(e){if(e.target===this.focusElement&&!this.readonly&&!this.disabled&&!this.opened){if(/^(Enter|SpaceBar|\s|ArrowDown|Down|ArrowUp|Up)$/u.test(e.key))e.preventDefault(),this.opened=!0;else if(/[\p{L}\p{Nd}]/u.test(e.key)&&e.key.length===1){const t=this._menuElement.selected,i=t!==void 0?t:-1,o=this._menuElement._searchKey(i,e.key);o>=0&&(this.__dispatchChangePending=!0,this._updateAriaLive(!0),this._menuElement.selected=o)}}}_onKeyDownInside(e){/^(Tab)$/u.test(e.key)&&(this.opened=!1)}_openedChanged(e,t,i){if(!(!t||!i)){if(e){if(this.disabled||this.readonly){this.opened=!1;return}this._updateAriaLive(!1),t.style.setProperty("--vaadin-select-text-field-width",`${i.offsetWidth}px`);const o=this.hasAttribute("focus-ring");this._openedWithFocusRing=o,o&&this.removeAttribute("focus-ring")}else this.__oldOpened&&(this._openedWithFocusRing&&this.setAttribute("focus-ring",""),!this.__dispatchChangePending&&!this._keyboardActive&&this.validate());this.__oldOpened=e}}_updateAriaExpanded(e,t){t&&t.setAttribute("aria-expanded",e?"true":"false")}_updateAriaLive(e){this.focusElement&&(e?this.focusElement.setAttribute("aria-live","polite"):this.focusElement.removeAttribute("aria-live"))}__attachSelectedItem(e){let t;const i=e.getAttribute("label");i?t=this.__createItemElement({label:i}):t=e.cloneNode(!0),t._sourceItem=e,this.__appendValueItemElement(t,this.focusElement),t.selected=!0}__createItemElement(e){const t=document.createElement(e.component||"vaadin-select-item");return e.label&&(t.textContent=e.label),e.value&&(t.value=e.value),e.disabled&&(t.disabled=e.disabled),e.className&&(t.className=e.className),t}__appendValueItemElement(e,t){t.appendChild(e),e.removeAttribute("tabindex"),e.removeAttribute("aria-selected"),e.removeAttribute("role"),e.removeAttribute("focused"),e.removeAttribute("focus-ring"),e.removeAttribute("active"),e.setAttribute("id",this._itemId)}_accessibleNameChanged(e){this._srLabelController.setLabel(e),this._setCustomAriaLabelledBy(e?this._srLabelController.defaultId:null)}_accessibleNameRefChanged(e){this._setCustomAriaLabelledBy(e)}_setCustomAriaLabelledBy(e){const t=this._getLabelIdWithItemId(e);this._fieldAriaController.setLabelId(t,!0)}_getLabelIdWithItemId(e){const t=this._items&&this._items[this._menuElement.selected]||this.placeholder?this._itemId:"";return e?`${e} ${t}`.trim():null}__updateValueButton(){const e=this.focusElement;if(!e)return;e.innerHTML="";const t=this._items[this._menuElement.selected];if(e.removeAttribute("placeholder"),this._hasContent(t))this.__attachSelectedItem(t);else if(this.placeholder){const o=this.__createItemElement({label:this.placeholder});this.__appendValueItemElement(o,e),e.setAttribute("placeholder","")}!this._valueChanging&&t&&(this._selectedChanging=!0,this.value=t.value||"",this.__dispatchChangePending&&this.__dispatchChange(),delete this._selectedChanging);const i=t||this.placeholder?{newId:this._itemId}:{oldId:this._itemId};Ut(e,"aria-labelledby",i),(this.accessibleName||this.accessibleNameRef)&&this._setCustomAriaLabelledBy(this.accessibleNameRef||this._srLabelController.defaultId)}_hasContent(e){if(!e)return!1;const t=!!(e.hasAttribute("label")?e.getAttribute("label"):e.textContent.trim()),i=e.childElementCount>0;return t||i}_updateSelectedItem(e,t){if(t){const i=e==null?e:e.toString();this._menuElement.selected=t.reduce((o,n,a)=>o===void 0&&n.value===i?a:o,void 0),this._selectedChanging||(this._valueChanging=!0,this.__updateValueButton(),delete this._valueChanging)}}_shouldRemoveFocus(){return!this.opened}_setFocused(e){super._setFocused(e),!e&&document.hasFocus()&&this.validate()}checkValidity(){return!this.required||this.readonly||!!this.value}__defaultRenderer(e,t){if(!this.items||this.items.length===0){e.textContent="";return}let i=e.firstElementChild;i||(i=document.createElement("vaadin-select-list-box"),e.appendChild(i)),i.textContent="",this.items.forEach(o=>{i.appendChild(this.__createItemElement(o))})}__dispatchChange(){return Ii(this,null,function*(){this.updateComplete&&(yield this.updateComplete),this.validate(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this.__dispatchChangePending=!1})}};/**
|
|
5598
5598
|
* @license
|
|
5599
5599
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5600
5600
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5601
|
-
*/
|
|
5601
|
+
*/x("vaadin-select",[ku,Iu,Gy],{moduleId:"vaadin-select-styles"});class Qy extends Ky(Ne(X(H))){static get is(){return"vaadin-select"}static get template(){return z`
|
|
5602
5602
|
<style>
|
|
5603
5603
|
:host {
|
|
5604
5604
|
position: relative;
|
|
@@ -5651,7 +5651,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5651
5651
|
<div class="sr-only">
|
|
5652
5652
|
<slot name="sr-label"></slot>
|
|
5653
5653
|
</div>
|
|
5654
|
-
`}static get observers(){return["_rendererChanged(renderer, _overlayElement)"]}ready(){super.ready(),no(this)}_rendererChanged(e,t){t&&(t.renderer=e||this.__defaultRenderer,this.requestContentUpdate())}_onOverlayOpen(){this._menuElement&&this._menuElement.focus()}}
|
|
5654
|
+
`}static get observers(){return["_rendererChanged(renderer, _overlayElement)"]}ready(){super.ready(),no(this)}_rendererChanged(e,t){t&&(t.renderer=e||this.__defaultRenderer,this.requestContentUpdate())}_onOverlayOpen(){this._menuElement&&this._menuElement.focus()}}k(Qy);const Xu=v`
|
|
5655
5655
|
/* Optical centering */
|
|
5656
5656
|
:host::before,
|
|
5657
5657
|
:host::after {
|
|
@@ -5751,7 +5751,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5751
5751
|
transform: scale(1.02);
|
|
5752
5752
|
}
|
|
5753
5753
|
}
|
|
5754
|
-
`;
|
|
5754
|
+
`;x("vaadin-dialog-overlay",[nr,Xu],{moduleId:"lumo-dialog"});x("vaadin-confirm-dialog-overlay",[nr,Xu,v`
|
|
5755
5755
|
[part='header'] ::slotted(h3) {
|
|
5756
5756
|
margin-top: 0 !important;
|
|
5757
5757
|
margin-bottom: 0 !important;
|
|
@@ -5790,11 +5790,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5790
5790
|
* @license
|
|
5791
5791
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5792
5792
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5793
|
-
*/const
|
|
5793
|
+
*/const Jy=r=>class extends r{static get properties(){return{opened:{type:Boolean,value:!1,notify:!0},noCloseOnOutsideClick:{type:Boolean,value:!1},noCloseOnEsc:{type:Boolean,value:!1},modeless:{type:Boolean,value:!1},overlayRole:{type:String,value:"dialog"}}}ready(){super.ready();const e=this.$.overlay;e.addEventListener("vaadin-overlay-outside-click",this._handleOutsideClick.bind(this)),e.addEventListener("vaadin-overlay-escape-press",this._handleEscPress.bind(this)),e.addEventListener("vaadin-overlay-closed",this.__handleOverlayClosed.bind(this)),this._overlayElement=e}__handleOverlayClosed(){this.dispatchEvent(new CustomEvent("closed"))}connectedCallback(){super.connectedCallback(),this.__restoreOpened&&(this.opened=!0)}disconnectedCallback(){super.disconnectedCallback(),setTimeout(()=>{this.isConnected||(this.__restoreOpened=this.opened,this.opened=!1)})}_onOverlayOpened(e){e.detail.value===!1&&(this.opened=!1)}_handleOutsideClick(e){this.noCloseOnOutsideClick&&e.preventDefault()}_handleEscPress(e){this.noCloseOnEsc&&e.preventDefault()}_bringOverlayToFront(){this.modeless&&this._overlayElement.bringToFront()}};/**
|
|
5794
5794
|
* @license
|
|
5795
5795
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
5796
5796
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5797
|
-
*/const
|
|
5797
|
+
*/const Zy=v`
|
|
5798
5798
|
[part='header'],
|
|
5799
5799
|
[part='header-content'],
|
|
5800
5800
|
[part='footer'] {
|
|
@@ -5969,11 +5969,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5969
5969
|
* @license
|
|
5970
5970
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
5971
5971
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5972
|
-
*/const
|
|
5972
|
+
*/const e0=r=>class extends r{static get properties(){return{ariaLabel:{type:String,value:""},contentHeight:{type:String},contentWidth:{type:String}}}static get observers(){return["__updateContentHeight(contentHeight, _overlayElement)","__updateContentWidth(contentWidth, _overlayElement)"]}__updateDimension(e,t,i){const o=`--_vaadin-confirm-dialog-content-${t}`;i?e.style.setProperty(o,i):e.style.removeProperty(o)}__updateContentHeight(e,t){t&&this.__updateDimension(t,"height",e)}__updateContentWidth(e,t){t&&this.__updateDimension(t,"width",e)}};/**
|
|
5973
5973
|
* @license
|
|
5974
5974
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
5975
5975
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5976
|
-
*/const
|
|
5976
|
+
*/const t0=v`
|
|
5977
5977
|
:host {
|
|
5978
5978
|
--_vaadin-confirm-dialog-content-width: auto;
|
|
5979
5979
|
--_vaadin-confirm-dialog-content-height: auto;
|
|
@@ -5996,7 +5996,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
5996
5996
|
* @license
|
|
5997
5997
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
5998
5998
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
5999
|
-
*/
|
|
5999
|
+
*/x("vaadin-confirm-dialog-overlay",[Kr,Zy,t0],{moduleId:"vaadin-confirm-dialog-overlay-styles"});class r0 extends Qr(Oe(X(H))){static get is(){return"vaadin-confirm-dialog-overlay"}static get template(){return z`
|
|
6000
6000
|
<div part="backdrop" id="backdrop" hidden$="[[!withBackdrop]]"></div>
|
|
6001
6001
|
<div part="overlay" id="overlay" tabindex="0">
|
|
6002
6002
|
<section id="resizerContainer" class="resizer-container">
|
|
@@ -6017,7 +6017,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6017
6017
|
</footer>
|
|
6018
6018
|
</section>
|
|
6019
6019
|
</div>
|
|
6020
|
-
`}ready(){super.ready(),this.setAttribute("has-header",""),this.setAttribute("has-footer","")}}
|
|
6020
|
+
`}ready(){super.ready(),this.setAttribute("has-header",""),this.setAttribute("has-footer","")}}k(r0);class i0 extends e0(Jy(Jr(Gi(H)))){static get is(){return"vaadin-confirm-dialog-dialog"}static get template(){return z`
|
|
6021
6021
|
<style>
|
|
6022
6022
|
:host {
|
|
6023
6023
|
display: none;
|
|
@@ -6038,15 +6038,15 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6038
6038
|
restore-focus-on-close
|
|
6039
6039
|
focus-trap
|
|
6040
6040
|
></vaadin-confirm-dialog-overlay>
|
|
6041
|
-
`}}
|
|
6041
|
+
`}}k(i0);/**
|
|
6042
6042
|
* @license
|
|
6043
6043
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
6044
6044
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6045
|
-
*/const
|
|
6045
|
+
*/const o0=r=>class extends r{static get properties(){return{accessibleDescriptionRef:{type:String},opened:{type:Boolean,value:!1,notify:!0},header:{type:String,value:""},message:{type:String,value:""},confirmText:{type:String,value:"Confirm"},confirmTheme:{type:String,value:"primary"},noCloseOnEsc:{type:Boolean,value:!1},rejectButtonVisible:{type:Boolean,reflectToAttribute:!0,value:!1},rejectText:{type:String,value:"Reject"},rejectTheme:{type:String,value:"error tertiary"},cancelButtonVisible:{type:Boolean,reflectToAttribute:!0,value:!1},cancelText:{type:String,value:"Cancel"},cancelTheme:{type:String,value:"tertiary"},overlayClass:{type:String},_cancelButton:{type:Object},_confirmButton:{type:Object},_headerNode:{type:Object},_messageNodes:{type:Array,value:()=>[]},_overlayElement:{type:Object,sync:!0},_rejectButton:{type:Object},_contentHeight:{type:String},_contentWidth:{type:String}}}static get observers(){return["__updateConfirmButton(_confirmButton, confirmText, confirmTheme)","__updateCancelButton(_cancelButton, cancelText, cancelTheme, cancelButtonVisible)","__updateHeaderNode(_headerNode, header)","__updateMessageNodes(_messageNodes, message)","__updateRejectButton(_rejectButton, rejectText, rejectTheme, rejectButtonVisible)","__accessibleDescriptionRefChanged(_overlayElement, _messageNodes, accessibleDescriptionRef)"]}constructor(){super(),this.__cancel=this.__cancel.bind(this),this.__confirm=this.__confirm.bind(this),this.__reject=this.__reject.bind(this)}get __slottedNodes(){return[this._headerNode,...this._messageNodes,this._cancelButton,this._confirmButton,this._rejectButton]}ready(){super.ready(),this._headerController=new xe(this,"header","h3",{initializer:e=>{this._headerNode=e}}),this.addController(this._headerController),this._messageController=new xe(this,"","div",{multiple:!0,observe:!1,initializer:e=>{const t=document.createElement("div");t.style.display="contents";const i=`confirm-dialog-message-${qr()}`;t.id=i,this.appendChild(t),t.appendChild(e),this._messageNodes=[...this._messageNodes,t]}}),this.addController(this._messageController),this._cancelController=new xe(this,"cancel-button","vaadin-button",{initializer:e=>{this.__setupSlottedButton("cancel",e)}}),this.addController(this._cancelController),this._rejectController=new xe(this,"reject-button","vaadin-button",{initializer:e=>{this.__setupSlottedButton("reject",e)}}),this.addController(this._rejectController),this._confirmController=new xe(this,"confirm-button","vaadin-button",{initializer:e=>{this.__setupSlottedButton("confirm",e)}}),this.addController(this._confirmController)}_initOverlay(e){e.addEventListener("vaadin-overlay-escape-press",this._escPressed.bind(this)),e.addEventListener("vaadin-overlay-open",()=>this.__onDialogOpened()),e.addEventListener("vaadin-overlay-closed",()=>this.__onDialogClosed()),e.setAttribute("role","alertdialog")}__onDialogOpened(){const e=this._overlayElement;this.__slottedNodes.forEach(i=>{e.appendChild(i)});const t=e.querySelector('[slot="confirm-button"]');t&&t.focus()}__onDialogClosed(){this.__slottedNodes.forEach(e=>{this.appendChild(e)}),this.dispatchEvent(new CustomEvent("closed"))}__accessibleDescriptionRefChanged(e,t,i){!e||!t||(i!==void 0?Ut(e,"aria-describedby",{newId:i,oldId:this.__oldAccessibleDescriptionRef,fromUser:!0}):t.forEach(o=>{Ut(e,"aria-describedby",{newId:o.id})}),this.__oldAccessibleDescriptionRef=i)}__setupSlottedButton(e,t){const i=`_${e}Button`,o=`__${e}`;this[i]&&this[i]!==t&&this[i].remove(),t.addEventListener("click",this[o]),this[i]=t}__updateCancelButton(e,t,i,o){e&&(e===this._cancelController.defaultNode&&(e.textContent=t,e.setAttribute("theme",i)),e.toggleAttribute("hidden",!o))}__updateConfirmButton(e,t,i){e&&e===this._confirmController.defaultNode&&(e.textContent=t,e.setAttribute("theme",i))}__updateHeaderNode(e,t){e&&e===this._headerController.defaultNode&&(e.textContent=t)}__updateMessageNodes(e,t){if(e&&e.length>0){const i=e.find(o=>this._messageController.defaultNode&&o===this._messageController.defaultNode.parentElement);i&&(i.firstChild.textContent=t)}}__updateRejectButton(e,t,i,o){e&&(e===this._rejectController.defaultNode&&(e.textContent=t,e.setAttribute("theme",i)),e.toggleAttribute("hidden",!o))}_escPressed(e){e.defaultPrevented||this.__cancel()}__confirm(){this.dispatchEvent(new CustomEvent("confirm")),this.opened=!1}__cancel(){this.dispatchEvent(new CustomEvent("cancel")),this.opened=!1}__reject(){this.dispatchEvent(new CustomEvent("reject")),this.opened=!1}_getAriaLabel(e){return e||"confirmation"}};/**
|
|
6046
6046
|
* @license
|
|
6047
6047
|
* Copyright (c) 2018 - 2024 Vaadin Ltd.
|
|
6048
6048
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6049
|
-
*/class
|
|
6049
|
+
*/class n0 extends o0(Ne(Gi(Ue(H)))){static get template(){return z`
|
|
6050
6050
|
<style>
|
|
6051
6051
|
:host,
|
|
6052
6052
|
[hidden] {
|
|
@@ -6073,7 +6073,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6073
6073
|
<slot name="reject-button"></slot>
|
|
6074
6074
|
<slot name="confirm-button"></slot>
|
|
6075
6075
|
</div>
|
|
6076
|
-
`}static get is(){return"vaadin-confirm-dialog"}ready(){super.ready(),this._overlayElement=this.$.dialog.$.overlay,this._initOverlay(this._overlayElement)}}
|
|
6076
|
+
`}static get is(){return"vaadin-confirm-dialog"}ready(){super.ready(),this._overlayElement=this.$.dialog.$.overlay,this._initOverlay(this._overlayElement)}}k(n0);x("vaadin-tab",v`
|
|
6077
6077
|
:host {
|
|
6078
6078
|
box-sizing: border-box;
|
|
6079
6079
|
padding: 0.5rem 0.75rem;
|
|
@@ -6310,11 +6310,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6310
6310
|
* @license
|
|
6311
6311
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6312
6312
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6313
|
-
*/const
|
|
6313
|
+
*/const a0=r=>class extends qu(r){ready(){super.ready(),this.setAttribute("role","tab")}_onKeyUp(e){const t=this.hasAttribute("active");if(super._onKeyUp(e),t){const i=this.querySelector("a");i&&i.click()}}};/**
|
|
6314
6314
|
* @license
|
|
6315
6315
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6316
6316
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6317
|
-
*/const
|
|
6317
|
+
*/const s0=v`
|
|
6318
6318
|
:host {
|
|
6319
6319
|
display: block;
|
|
6320
6320
|
}
|
|
@@ -6337,10 +6337,10 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6337
6337
|
* @license
|
|
6338
6338
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6339
6339
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6340
|
-
*/
|
|
6340
|
+
*/x("vaadin-tab",s0,{moduleId:"vaadin-tab-styles"});class l0 extends Ne(X(a0(Ue(H)))){static get template(){return z`
|
|
6341
6341
|
<slot></slot>
|
|
6342
6342
|
<slot name="tooltip"></slot>
|
|
6343
|
-
`}static get is(){return"vaadin-tab"}ready(){super.ready(),this._tooltipController=new
|
|
6343
|
+
`}static get is(){return"vaadin-tab"}ready(){super.ready(),this._tooltipController=new Qe(this),this.addController(this._tooltipController)}}k(l0);x("vaadin-tabs",v`
|
|
6344
6344
|
:host {
|
|
6345
6345
|
-webkit-tap-highlight-color: transparent;
|
|
6346
6346
|
}
|
|
@@ -6582,11 +6582,11 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6582
6582
|
* @license
|
|
6583
6583
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6584
6584
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6585
|
-
*/const
|
|
6585
|
+
*/const d0=r=>class extends Wu(Gu(r)){static get properties(){return{orientation:{value:"horizontal",type:String,reflectToAttribute:!0,sync:!0},selected:{value:0,type:Number}}}static get observers(){return["__tabsItemsChanged(items)"]}constructor(){super(),this.__itemsResizeObserver=new ResizeObserver(()=>{setTimeout(()=>this._updateOverflow())})}get _scrollOffset(){return this._vertical?this._scrollerElement.offsetHeight:this._scrollerElement.offsetWidth}get _scrollerElement(){return this.$.scroll}get __direction(){return!this._vertical&&this.__isRTL?1:-1}ready(){super.ready(),this._scrollerElement.addEventListener("scroll",()=>this._updateOverflow()),this.setAttribute("role","tablist"),na(this,()=>{this._updateOverflow()})}_onResize(){this._updateOverflow()}__tabsItemsChanged(e){this.__itemsResizeObserver.disconnect(),(e||[]).forEach(t=>{this.__itemsResizeObserver.observe(t)}),this._updateOverflow()}_scrollForward(){const e=this._getNavigationButtonVisibleWidth("forward-button"),t=this._getNavigationButtonVisibleWidth("back-button"),i=this._scrollerElement.getBoundingClientRect(),o=[...this.items].reverse().find(s=>this._isItemVisible(s,e,t,i)).getBoundingClientRect(),n=20+this.shadowRoot.querySelector('[part="back-button"]').clientWidth;let a;if(this.__isRTL){const s=i.right-n;a=o.right-s}else{const s=i.left+n;a=o.left-s}-this.__direction*a<1&&(a=-this.__direction*(this._scrollOffset-n)),this._scroll(a)}_scrollBack(){const e=this._getNavigationButtonVisibleWidth("forward-button"),t=this._getNavigationButtonVisibleWidth("back-button"),i=this._scrollerElement.getBoundingClientRect(),o=this.items.find(s=>this._isItemVisible(s,e,t,i)).getBoundingClientRect(),n=20+this.shadowRoot.querySelector('[part="forward-button"]').clientWidth;let a;if(this.__isRTL){const s=i.left+n;a=o.left-s}else{const s=i.right-n;a=o.right-s}this.__direction*a<1&&(a=this.__direction*(this._scrollOffset-n)),this._scroll(a)}_isItemVisible(e,t,i,o){if(this._vertical)throw new Error("Visibility check is only supported for horizontal tabs.");const n=this.__isRTL?i:t,a=this.__isRTL?t:i,s=o.right-n,l=o.left+a,d=e.getBoundingClientRect();return s>Math.floor(d.left)&&l<Math.ceil(d.right)}_getNavigationButtonVisibleWidth(e){const t=this.shadowRoot.querySelector(`[part="${e}"]`);return window.getComputedStyle(t).opacity==="0"?0:t.clientWidth}_updateOverflow(){const e=this._vertical?this._scrollerElement.scrollTop:Yu(this._scrollerElement,this.getAttribute("dir")),t=this._vertical?this._scrollerElement.scrollHeight:this._scrollerElement.scrollWidth;let i=Math.floor(e)>1?"start":"";Math.ceil(e)<Math.ceil(t-this._scrollOffset)&&(i+=" end"),this.__direction===1&&(i=i.replace(/start|end/giu,o=>o==="start"?"end":"start")),i?this.setAttribute("overflow",i.trim()):this.removeAttribute("overflow")}};/**
|
|
6586
6586
|
* @license
|
|
6587
6587
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6588
6588
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6589
|
-
*/const
|
|
6589
|
+
*/const u0=v`
|
|
6590
6590
|
:host {
|
|
6591
6591
|
display: flex;
|
|
6592
6592
|
align-items: center;
|
|
@@ -6666,7 +6666,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6666
6666
|
* @license
|
|
6667
6667
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
6668
6668
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6669
|
-
*/
|
|
6669
|
+
*/x("vaadin-tabs",u0,{moduleId:"vaadin-tabs-styles"});class c0 extends d0(Ne(X(H))){static get template(){return z`
|
|
6670
6670
|
<div on-click="_scrollBack" part="back-button" aria-hidden="true"></div>
|
|
6671
6671
|
|
|
6672
6672
|
<div id="scroll" part="tabs">
|
|
@@ -6674,7 +6674,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6674
6674
|
</div>
|
|
6675
6675
|
|
|
6676
6676
|
<div on-click="_scrollForward" part="forward-button" aria-hidden="true"></div>
|
|
6677
|
-
`}static get is(){return"vaadin-tabs"}}
|
|
6677
|
+
`}static get is(){return"vaadin-tabs"}}k(c0);function h0(r){sl(r,"svelte-bp2unp",'.BonusesWrapper{background-color:var(--emw--color-pale, var(--emw--color-gray-50, #F1F1F1));border-radius:var(--emw--border-radius-large, 10px);color:var(--emw--color-typography-cotrast, #444444);padding:50px;max-width:850px}.BonusesWrapper.BonusesWrapperMobile{padding:20px 15px;max-width:unset}.MenuReturnButton{color:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E));display:inline-flex;align-items:center;column-gap:10px;margin-bottom:10px}.MenuReturnButton svg{fill:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E))}.BonusesTitle{font-size:var(--emw--font-size-x-large, 26px);color:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E));font-weight:var(--emw--font-weigh-normal, 400)}.BonusesTitleMobile{font-size:var(--emw--size-standard, 16px)}.BonusesTitleNone{display:none}.BonusCalendarWrapper{display:flex;gap:15px;padding-bottom:30px;align-items:center}.BonusCalendarWrapper.BonusCalendarWrapperMobile{flex-direction:column;gap:10px;padding-bottom:15px}.BonusesCalendarContainer{display:flex;gap:20px}.BonusesCalendarContainer.BonusesCalendarContainerMobile{flex-direction:row;gap:0;justify-content:space-between;padding-bottom:0;width:100%}.BonusesCalendarStartDate,.BonusesCalendarEndDate{color:var(--emw--color-gray-300, #58586B);display:flex;position:relative;align-items:center;gap:10px}.BonusesCalendarStartDate.BonusesCalendarMobile,.BonusesCalendarEndDate.BonusesCalendarMobile{flex-direction:column;align-items:flex-start;gap:5px;width:48%}.BonusesCalendarStartDate.BonusesCalendarMobile .VaadinDatePicker,.BonusesCalendarEndDate.BonusesCalendarMobile .VaadinDatePicker{width:100%;border-radius:var(--emw--border-radius-large, 10px)}.BonusesCalendarStartDate label,.BonusesCalendarEndDate label{font-size:var(--emw--font-size-small, 14px);font-weight:300}.BonusesCalendarStartDate input,.BonusesCalendarEndDate input{width:100%;height:44px;border:1px solid var(--emw--color-gray-100, #E6E6E6);border-radius:var(--emw--border-radius-small, 5px);box-sizing:border-box;padding:5px 15px;font-size:var(--emw--size-standard, 16px);line-height:18px;outline-color:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E))}.BonusesCalendarFilter{background-image:linear-gradient(to bottom, color-mix(in srgb, var(--emw--color-primary, #22B04E) 80%, black 20%), var(--emw--color-primary, #22B04E), color-mix(in srgb, var(--emw--color-primary, #22B04E) 80%, white 30%));border:2px solid var(--emw--button-border-color, #0E5924);color:var(--emw--button-text-color, #FFFFFF);border-radius:var(--emw--button-border-radius, 10px);cursor:pointer;width:120px;height:40px;font-size:var(--emw--font-size-medium, 15px);text-transform:uppercase;text-align:center;transition-duration:0.3s;box-sizing:border-box;padding:10px;outline:none}.BonusesCalendarFilter.BonusesCalendarFilterMobile{width:100%;height:44px}.BonusesCalendarFilter:active{background:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E))}.BonusesCalendarFilter:disabled{background-image:none;background-color:var(--emw--button-disabled-text-color, #cccccc);color:var(--emw--button-disabled-text-color, #666);cursor:not-allowed;opacity:0.7;pointer-events:none;border:2px solid var(--emw--button-disabled-border-color, #aaaaaa)}.BonusesGrid{display:grid;grid-template-columns:1fr 1fr;gap:50px;border-radius:var(--emw--border-radius-large, 10px)}.BonusesGrid.BonusesGridMobile{grid-template-columns:1fr;gap:20px}.BonusesPaginationWrapper{margin:40px 0;display:block;line-break:anywhere;line-height:2em}.BonusesPaginationWrapper.BonusesPaginationWrapperMobile{text-align:center}.BonusesPaginationWrapper .BonusesFirst,.BonusesPaginationWrapper .BonusesPrev,.BonusesPaginationWrapper .BonusesNext,.BonusesPaginationWrapper .BonusesLast,.BonusesPaginationWrapper .BonusesPage{all:unset;box-sizing:border-box;cursor:pointer}.BonusesPaginationWrapper .BonusesFirst,.BonusesPaginationWrapper .BonusesPrev,.BonusesPaginationWrapper .BonusesNext,.BonusesPaginationWrapper .BonusesLast{color:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E));font-size:var(--emw--size-standard, 16px);cursor:pointer;padding:5px 10px;font-weight:var(--emw--font-weight-bold, 700)}.BonusesPaginationWrapper .BonusesFirst.Inactive,.BonusesPaginationWrapper .BonusesPrev.Inactive,.BonusesPaginationWrapper .BonusesNext.Inactive,.BonusesPaginationWrapper .BonusesLast.Inactive{color:var(--emw--color-gray-100, #E6E6E6);cursor:default}.BonusesPaginationWrapper .BonusesPage{margin:0 5px;color:var(--emw--color-typography-cotrast, #444444);font-size:var(--emw--size-standard, 16px);cursor:pointer;padding:5px 10px;white-space:nowrap}.BonusesPaginationWrapper .BonusesPage.BonusPageActive{background-color:var(--emw--color-white, #FFFFFF);font-weight:var(--emw--font-weight-bold, 700);cursor:default}.ModalLoader{width:300px;height:300px;margin:0 auto;display:flex;align-items:center;justify-content:center}.ModalLoader:after{content:" ";display:block;width:64px;height:64px;margin:8px;border-radius:50%;border:5px solid var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E));border-color:var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E)) transparent var(--emw--pam-color-primary, var(--emw--color-primary, #22B04E)) transparent;animation:Loader 1.2s linear infinite}@keyframes Loader{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}')}function Zs(r,e,t){const i=r.slice();return i[56]=e[t],i[58]=t,i}function el(r,e,t){const i=r.slice();return i[59]=e[t],i}function p0(r){let e,t,i,o,n,a,s,l,d,u,c=r[24]("titleBonusesHistory")+"",h,p,m;return{c(){e=Q("div"),t=It("svg"),i=It("defs"),o=It("style"),n=Ce(`.aaa {
|
|
6678
6678
|
fill: var(--emw--pam-color-primary, var(--emw--color-primary, #22b04e));
|
|
6679
6679
|
}
|
|
6680
|
-
`),a=It("g"),s=It("g"),l=It("path"),d=Ae(),u=Q("h2"),h=Ce(c),O(l,"class","aaa"),O(l,"d","M7.5,0,6.136,1.364,11.3,6.526H0V8.474H11.3L6.136,13.636,7.5,15,15,7.5Z"),O(l,"transform","translate(15 15) rotate(180)"),O(s,"transform","translate(20 158)"),O(a,"transform","translate(-20 -158)"),O(t,"xmlns","http://www.w3.org/2000/svg"),O(t,"width","15"),O(t,"height","15"),O(t,"viewBox","0 0 15 15"),O(u,"class","BonusesTitleMobile"),O(e,"class","MenuReturnButton")},m(f,y){Ee(f,e,y),T(e,t),T(t,i),T(i,o),T(o,n),T(t,a),T(a,s),T(s,l),T(e,d),T(e,u),T(u,h),p||(m=ot(e,"click",r[33]),p=!0)},p(f,y){y[0]&8388608&&c!==(c=f[23]("titleBonusesHistory")+"")&&pt(h,c)},d(f){f&&ge(e),p=!1,m()}}}function p0(r){let e,t,i;function o(l,d){return l[22].length===0?_0:f0}let n=o(r),a=n(r),s=r[22].length!==0&&rl(r);return{c(){e=Q("div"),a.c(),t=Ae(),s&&s.c(),i=Pn(),O(e,"class","BonusesGrid "+(r[24]?"BonusesGridMobile":""))},m(l,d){Ee(l,e,d),a.m(e,null),Ee(l,t,d),s&&s.m(l,d),Ee(l,i,d)},p(l,d){n===(n=o(l))&&a?a.p(l,d):(a.d(1),a=n(l),a&&(a.c(),a.m(e,null))),l[22].length!==0?s?s.p(l,d):(s=rl(l),s.c(),s.m(i.parentNode,i)):s&&(s.d(1),s=null)},d(l){l&&(ge(e),ge(t),ge(i)),a.d(),s&&s.d(l)}}}function m0(r){let e;return{c(){e=Q("div"),O(e,"class","ModalLoader")},m(t,i){Ee(t,e,i)},p:Oe,d(t){t&&ge(e)}}}function f0(r){let e,t=wi(r[22]),i=[];for(let o=0;o<t.length;o+=1)i[o]=tl(el(r,t,o));return{c(){for(let o=0;o<i.length;o+=1)i[o].c();e=Pn()},m(o,n){for(let a=0;a<i.length;a+=1)i[a]&&i[a].m(o,n);Ee(o,e,n)},p(o,n){if(n[0]&4194719){t=wi(o[22]);let a;for(a=0;a<t.length;a+=1){const s=el(o,t,a);i[a]?i[a].p(s,n):(i[a]=tl(s),i[a].c(),i[a].m(e.parentNode,e))}for(;a<i.length;a+=1)i[a].d(1);i.length=t.length}},d(o){o&&ge(e),ll(i,o)}}}function _0(r){let e,t=r[23]("noBonusHistory")+"",i;return{c(){e=Q("p"),i=Ce(t)},m(o,n){Ee(o,e,n),T(e,i)},p(o,n){n[0]&8388608&&t!==(t=o[23]("noBonusHistory")+"")&&pt(i,t)},d(o){o&&ge(e)}}}function v0(r){let e,t,i,o,n,a,s,l,d,u,c,h,p;return{c(){e=Q("player-bonus-card"),_(e,"termsandconditionsdescription",t=r[58].termsandconditionsdescription),_(e,"termsandconditionsurl",i=r[58].termsandconditionsurl),_(e,"termsandconditionsasset",o=r[58].termsandconditionsasset),_(e,"bonuswalletid",n=r[58].walletId),_(e,"bonusdate",a=r[58].granted),_(e,"bonusstatus",s=r[58].status),_(e,"bonusname",l=r[58].name),_(e,"bonustype",d=r[58].type),_(e,"bonusamount",u=r[58].extension.grantedPlayerCurrencyAmount),_(e,"bonuswageringamount",c=`${r[58].fulfilledWR} / ${r[58].originalWageringRequirement}`),_(e,"bonusremainingamount",h=r[58].currentAmount),_(e,"bonuscurrency",p=r[58].currency),_(e,"lang",r[0]),_(e,"clientstyling",r[1]),_(e,"clientstylingurl",r[2]),_(e,"mbsource",r[3]),_(e,"translationurl",r[4]),_(e,"currencylocale",r[7]),_(e,"dateformat",r[8])},m(m,f){Ee(m,e,f)},p(m,f){f[0]&4194304&&t!==(t=m[58].termsandconditionsdescription)&&_(e,"termsandconditionsdescription",t),f[0]&4194304&&i!==(i=m[58].termsandconditionsurl)&&_(e,"termsandconditionsurl",i),f[0]&4194304&&o!==(o=m[58].termsandconditionsasset)&&_(e,"termsandconditionsasset",o),f[0]&4194304&&n!==(n=m[58].walletId)&&_(e,"bonuswalletid",n),f[0]&4194304&&a!==(a=m[58].granted)&&_(e,"bonusdate",a),f[0]&4194304&&s!==(s=m[58].status)&&_(e,"bonusstatus",s),f[0]&4194304&&l!==(l=m[58].name)&&_(e,"bonusname",l),f[0]&4194304&&d!==(d=m[58].type)&&_(e,"bonustype",d),f[0]&4194304&&u!==(u=m[58].extension.grantedPlayerCurrencyAmount)&&_(e,"bonusamount",u),f[0]&4194304&&c!==(c=`${m[58].fulfilledWR} / ${m[58].originalWageringRequirement}`)&&_(e,"bonuswageringamount",c),f[0]&4194304&&h!==(h=m[58].currentAmount)&&_(e,"bonusremainingamount",h),f[0]&4194304&&p!==(p=m[58].currency)&&_(e,"bonuscurrency",p),f[0]&1&&_(e,"lang",m[0]),f[0]&2&&_(e,"clientstyling",m[1]),f[0]&4&&_(e,"clientstylingurl",m[2]),f[0]&8&&_(e,"mbsource",m[3]),f[0]&16&&_(e,"translationurl",m[4]),f[0]&128&&_(e,"currencylocale",m[7]),f[0]&256&&_(e,"dateformat",m[8])},d(m){m&&ge(e)}}}function g0(r){let e,t,i,o,n,a,s,l,d,u;return{c(){e=Q("player-bonus-card"),_(e,"termsandconditionsdescription",t=r[58].termsandconditionsdescription),_(e,"termsandconditionsurl",i=r[58].termsandconditionsurl),_(e,"termsandconditionsasset",o=r[58].termsandconditionsasset),_(e,"bonuswalletid",n=r[58].walletId),_(e,"bonusdate",a=r[58].granted),_(e,"bonusstatus",s=r[58].status),_(e,"bonusname",l=r[58].name),_(e,"bonustype",d=r[58].type),_(e,"bonuscurrency",u=r[58].currency),_(e,"lang",r[0]),_(e,"clientstyling",r[1]),_(e,"clientstylingurl",r[2]),_(e,"mbsource",r[3]),_(e,"translationurl",r[4]),_(e,"currencylocale",r[7]),_(e,"dateformat",r[8])},m(c,h){Ee(c,e,h)},p(c,h){h[0]&4194304&&t!==(t=c[58].termsandconditionsdescription)&&_(e,"termsandconditionsdescription",t),h[0]&4194304&&i!==(i=c[58].termsandconditionsurl)&&_(e,"termsandconditionsurl",i),h[0]&4194304&&o!==(o=c[58].termsandconditionsasset)&&_(e,"termsandconditionsasset",o),h[0]&4194304&&n!==(n=c[58].walletId)&&_(e,"bonuswalletid",n),h[0]&4194304&&a!==(a=c[58].granted)&&_(e,"bonusdate",a),h[0]&4194304&&s!==(s=c[58].status)&&_(e,"bonusstatus",s),h[0]&4194304&&l!==(l=c[58].name)&&_(e,"bonusname",l),h[0]&4194304&&d!==(d=c[58].type)&&_(e,"bonustype",d),h[0]&4194304&&u!==(u=c[58].currency)&&_(e,"bonuscurrency",u),h[0]&1&&_(e,"lang",c[0]),h[0]&2&&_(e,"clientstyling",c[1]),h[0]&4&&_(e,"clientstylingurl",c[2]),h[0]&8&&_(e,"mbsource",c[3]),h[0]&16&&_(e,"translationurl",c[4]),h[0]&128&&_(e,"currencylocale",c[7]),h[0]&256&&_(e,"dateformat",c[8])},d(c){c&&ge(e)}}}function tl(r){let e;function t(n,a){return n[58].type==="freeRound"?g0:v0}let i=t(r),o=i(r);return{c(){o.c(),e=Pn()},m(n,a){o.m(n,a),Ee(n,e,a)},p(n,a){i===(i=t(n))&&o?o.p(n,a):(o.d(1),o=i(n),o&&(o.c(),o.m(e.parentNode,e)))},d(n){n&&ge(e),o.d(n)}}}function rl(r){let e,t,i,o,n,a,s,l,d,u,c,h,p,m,f,y,E,x,A,D,j,$,J,W=wi(Array(r[20])),X=[];for(let I=0;I<W.length;I+=1)X[I]=il(Zs(r,W,I));return{c(){e=Q("div"),t=Q("button"),i=Ce("|<"),a=Ae(),s=Q("button"),l=Ce("<"),c=Ae();for(let I=0;I<X.length;I+=1)X[I].c();h=Ae(),p=Q("button"),m=Ce(">"),E=Ae(),x=Q("button"),A=Ce(">|"),t.disabled=o=r[21]===0,O(t,"class",n="BonusesFirst "+(r[21]===0?"Inactive":"")),s.disabled=d=r[21]===0,O(s,"class",u="BonusesPrev "+(r[21]===0?"Inactive":"")),p.disabled=f=r[21]===r[20]-1,O(p,"class",y="BonusesNext "+(r[21]===r[20]-1?"Inactive":"")),x.disabled=D=r[21]===r[20]-1,O(x,"class",j="BonusesLast "+(r[21]===r[20]-1?"Inactive":"")),O(e,"class","BonusesPaginationWrapper "+(r[24]?"BonusesPaginationWrapperMobile":""))},m(I,P){Ee(I,e,P),T(e,t),T(t,i),T(e,a),T(e,s),T(s,l),T(e,c);for(let k=0;k<X.length;k+=1)X[k]&&X[k].m(e,null);T(e,h),T(e,p),T(p,m),T(e,E),T(e,x),T(x,A),$||(J=[ot(t,"click",r[37]),ot(s,"click",r[38]),ot(p,"click",r[40]),ot(x,"click",r[41])],$=!0)},p(I,P){if(P[0]&2097152&&o!==(o=I[21]===0)&&(t.disabled=o),P[0]&2097152&&n!==(n="BonusesFirst "+(I[21]===0?"Inactive":""))&&O(t,"class",n),P[0]&2097152&&d!==(d=I[21]===0)&&(s.disabled=d),P[0]&2097152&&u!==(u="BonusesPrev "+(I[21]===0?"Inactive":""))&&O(s,"class",u),P[0]&137363552){W=wi(Array(I[20]));let k;for(k=0;k<W.length;k+=1){const he=Zs(I,W,k);X[k]?X[k].p(he,P):(X[k]=il(he),X[k].c(),X[k].m(e,h))}for(;k<X.length;k+=1)X[k].d(1);X.length=W.length}P[0]&3145728&&f!==(f=I[21]===I[20]-1)&&(p.disabled=f),P[0]&3145728&&y!==(y="BonusesNext "+(I[21]===I[20]-1?"Inactive":""))&&O(p,"class",y),P[0]&3145728&&D!==(D=I[21]===I[20]-1)&&(x.disabled=D),P[0]&3145728&&j!==(j="BonusesLast "+(I[21]===I[20]-1?"Inactive":""))&&O(x,"class",j)},d(I){I&&ge(e),ll(X,I),$=!1,Zt(J)}}}function il(r){let e,t=r[57]+1+"",i,o,n,a,s;function l(){return r[39](r[57])}return{c(){e=Q("button"),i=Ce(t),e.disabled=o=r[57]===r[21],O(e,"class",n="BonusesPage "+(r[57]===r[21]?"BonusPageActive":""))},m(d,u){Ee(d,e,u),T(e,i),a||(s=ot(e,"click",l),a=!0)},p(d,u){r=d,u[0]&2097152&&o!==(o=r[57]===r[21])&&(e.disabled=o),u[0]&2097152&&n!==(n="BonusesPage "+(r[57]===r[21]?"BonusPageActive":""))&&O(e,"class",n)},d(d){d&&ge(e),a=!1,s()}}}function b0(r){let e,t,i,o,n=r[23]("titleBonusesHistory")+"",a,s,l,d,u,c,h=r[23]("dateFrom")+"",p,m,f,y,E,x,A=r[23]("dateTo")+"",D,j,$,J,W,X=r[23]("dateFilter")+"",I,P,k,he,Ze,Te=r[24]&&h0(r);function et(K,oe){return K[14]?m0:p0}let Be=et(r),ue=Be(r);return{c(){e=Q("div"),t=Q("div"),Te&&Te.c(),i=Ae(),o=Q("h2"),a=Ce(n),s=Ae(),l=Q("div"),d=Q("div"),u=Q("div"),c=Q("label"),p=Ce(h),m=Ae(),f=Q("vaadin-date-picker"),y=Ae(),E=Q("div"),x=Q("label"),D=Ce(A),j=Ae(),$=Q("vaadin-date-picker"),J=Ae(),W=Q("button"),I=Ce(X),k=Ae(),ue.c(),O(o,"class","BonusesTitle "+(r[24]?"BonusesTitleNone":"")),O(o,"part","BonusesTitle "+(r[24]?"BonusesTitleNone":"")),O(c,"for","BonusCalendarStartDate"),_(f,"max",r[25]),_(f,"value",r[12]),_(f,"placeholder",r[12]),_(f,"class","VaadinDatePicker"),O(u,"class","BonusesCalendarStartDate "+(r[24]?"BonusesCalendarMobile":"")),O(x,"for","BonusesCalendarEndDate"),_($,"max",r[25]),_($,"min",r[15]),_($,"value",r[13]),_($,"placeholder",r[13]),_($,"class","VaadinDatePicker"),O(E,"class","BonusesCalendarEndDate "+(r[24]?"BonusesCalendarMobile":"")),O(d,"class","BonusesCalendarContainer "+(r[24]?"BonusesCalendarContainerMobile":"")),O(W,"class","BonusesCalendarFilter "+(r[24]?"BonusesCalendarFilterMobile":"")),W.disabled=P=!r[16]||r[14],O(l,"class","BonusCalendarWrapper "+(r[24]?"BonusCalendarWrapperMobile":"")),O(t,"class","BonusesWrapper "+(r[24]?"BonusesWrapperMobile":""))},m(K,oe){Ee(K,e,oe),T(e,t),Te&&Te.m(t,null),T(t,i),T(t,o),T(o,a),T(t,s),T(t,l),T(l,d),T(d,u),T(u,c),T(c,p),T(u,m),T(u,f),r[34](f),T(d,y),T(d,E),T(E,x),T(x,D),T(E,j),T(E,$),r[35]($),T(l,J),T(l,W),T(W,I),T(t,k),ue.m(t,null),r[42](e),he||(Ze=ot(W,"click",r[36]),he=!0)},p(K,oe){K[24]&&Te.p(K,oe),oe[0]&8388608&&n!==(n=K[23]("titleBonusesHistory")+"")&&pt(a,n),oe[0]&8388608&&h!==(h=K[23]("dateFrom")+"")&&pt(p,h),oe[0]&4096&&_(f,"value",K[12]),oe[0]&4096&&_(f,"placeholder",K[12]),oe[0]&8388608&&A!==(A=K[23]("dateTo")+"")&&pt(D,A),oe[0]&32768&&_($,"min",K[15]),oe[0]&8192&&_($,"value",K[13]),oe[0]&8192&&_($,"placeholder",K[13]),oe[0]&8388608&&X!==(X=K[23]("dateFilter")+"")&&pt(I,X),oe[0]&81920&&P!==(P=!K[16]||K[14])&&(W.disabled=P),Be===(Be=et(K))&&ue?ue.p(K,oe):(ue.d(1),ue=Be(K),ue&&(ue.c(),ue.m(t,null)))},i:Oe,o:Oe,d(K){K&&ge(e),Te&&Te.d(),r[34](null),r[35](null),ue.d(),r[42](null),he=!1,Ze()}}}let Re=6;function y0(r){var i,o,n,a,s,l,d,u,c,h,p;const e=(i=r.initialWagerRequirementAmount)!=null?i:0,t=(o=r.remainingWagerRequirementAmount)!=null?o:0;return pr(ut({},r),{walletId:(n=r.bonusWalletID)!=null?n:void 0,granted:(a=r.grantedDate)!=null?a:void 0,expiryTime:(s=r.expiryDate)!=null?s:void 0,currentAmount:(l=r.remainingAmount)!=null?l:void 0,originalWageringRequirement:(d=r.initialWagerRequirementAmount)!=null?d:void 0,fulfilledWR:e-t,extension:{grantedPlayerCurrencyAmount:(u=r.amount)!=null?u:void 0},termsandconditionsurl:(c=r.url)!=null?c:void 0,termsandconditionsdescription:(h=r.description)!=null?h:void 0,termsandconditionsasset:(p=r.assets)!=null?p:void 0})}function w0(r,e,t){let i;al(r,ql,b=>t(23,i=b));let{endpoint:o=""}=e,{session:n=""}=e,{playerid:a=""}=e,{lang:s="en"}=e,{clientstyling:l=""}=e,{clientstylingurl:d=""}=e,{mbsource:u}=e,{translationurl:c=""}=e,{bonushistorystatus:h=""}=e,{bonushistorytype:p=""}=e,{currencylocale:m=""}=e,{currency:f=""}=e,{dateformat:y="dd-MM-yyyy"}=e,{gmversion:E=""}=e,x,A,D=!1,j=window.navigator.userAgent,$=Yl(j)!=="PC",J,W;const X=je(new Date,"yyyy-MM-dd");let I="",P=je(Lf(new Date,3),`${y||"yyyy-MM-dd"}`),k=je(new Date,`${y||"yyyy-MM-dd"}`),he=!0,Ze=0,Te=0,et=0,Be=0,ue=0,K=[];const oe=()=>{fetch(c).then(re=>re.json()).then(re=>{Object.keys(re).forEach(Ie=>{Qa(Ie,re[Ie])})}).catch(re=>{console.log(re)})};Object.keys(Ja).forEach(b=>{Qa(b,Ja[b])});const ar=()=>{window.postMessage({type:"PlayerAccountMenuActive",isMobile:$},window.location.href)},sr=(b,re)=>{const Ie=Ka(b,`${y||"yyyy-MM-dd"}`,new Date),At=re?Vp(Ie):Lp(Ie);return je(At,"yyyy-MM-dd'T'HH:mm:ss.SSS'Z'")},ke=(b,re,Ie)=>mr(this,null,function*(){var ga,ba;t(14,D=!0);let At=sr(P,!1),dr=sr(k,!0),_a,va;re&&(_a=re.split(",").map(_e=>`status=${_e}`).join(",")),Ie&&(va=Ie.split(",").map(_e=>`type=${_e}`).join(","));try{let tt=[],kt=0;if(E==="gm2"){const _e={pagination:`limit=${Re},offset=${b}`,language:s||"en",sortOrder:"desc",status:re!=null?re:Za.STATUS_COMPLETED,type:Ie!=null?Ie:Za.TYPES,startTime:At,endTime:dr},ur=yield Ff(o,n,_e),cr=ur.items;Array.isArray(cr)?tt=cr.map(y0):console.error("Unexpected history bonuses payload",ur),kt=(ga=ur.total)!=null?ga:0}else{const _e={method:"GET",headers:{"X-SessionId":n}},ur=`/v1/player/${a}/bonusWallet`,cr=new URL(`${o}${ur}`),ao=new URLSearchParams;let sc=`granted=[${At}~${dr}],${_a},${va}`;ao.set("pagination",`offset=${b},limit=${Re}`),ao.set("filter",sc),cr.search=ao.toString();const hr=yield(yield fetch(cr,_e)).json();Array.isArray(hr.items)?(hr.items.forEach(Le=>{var ya,wa;const ri=(wa=(ya=Le==null?void 0:Le.extension)==null?void 0:ya.bonus)==null?void 0:wa.presentation;ri&&(Le.termsandconditionsurl||(Le.termsandconditionsurl=ri.url),Le.termsandconditionsdescription||(Le.termsandconditionsdescription=ri.description),Le.termsandconditionsasset||(Le.termsandconditionsasset=ri.assets))}),tt=hr.items):console.error("Unexpected legacy bonus list payload",hr),kt=(ba=hr.total)!=null?ba:0}t(20,Be=Math.ceil(kt/Re)),b-Re>=0&&t(17,Ze=b-Re),b+Re<kt&&t(18,Te=b+Re),t(19,et=(Be-1)*Re),t(21,ue=b/Re),m&&tt.forEach(_e=>{_e.fulfilledWR=te(_e.fulfilledWR),_e.originalWageringRequirement=te(_e.originalWageringRequirement),_e.currentAmount=te(_e.currentAmount),_e.extension.grantedPlayerCurrencyAmount=te(_e.extension.grantedPlayerCurrencyAmount)}),t(22,K=tt),window.postMessage({type:"ScrollToTop"},window.location.href)}catch(tt){console.error(tt)}finally{t(14,D=!1)}}),te=b=>new Intl.NumberFormat(m,{style:"currency",currency:f}).format(b).replace(/\s/g,""),q=b=>{t(12,P=je(new Date(b.target.value),`${y||"yyyy-MM-dd"}`)),t(15,I=je(new Date(b.target.value),"yyyy-MM-dd"))},ye=b=>{t(13,k=je(new Date(b.target.value),`${y||"yyyy-MM-dd"}`))},Tt=()=>{const b=new Date(P),re=new Date(k);b.getTime()>re.getTime()?t(16,he=!1):t(16,he=!0)},ei=()=>{J.addEventListener("change",q,!1),W.addEventListener("change",ye,!1)},lr=b=>{const{year:re,month:Ie,day:At}=b,dr=new Date(re,Ie,At);return je(dr,y||"yyyy-MM-dd")},Pt=b=>{const re=Ka(b,y||"yyyy-MM-dd",new Date);return{year:re.getFullYear(),month:re.getMonth(),day:re.getDate()}};dl(()=>(t(10,J.i18n=pr(ut({},J.i18n),{formatDate:lr,parseDate:Pt}),J),t(11,W.i18n=pr(ut({},W.i18n),{formatDate:lr,parseDate:Pt}),W),()=>{J.removeEventListener("change",q),W.removeEventListener("change",ye)}));const ti=()=>{zf(s)},Qu=()=>ar();function Ju(b){zt[b?"unshift":"push"](()=>{J=b,t(10,J)})}function Zu(b){zt[b?"unshift":"push"](()=>{W=b,t(11,W)})}const ec=()=>ke(0,h,p),tc=()=>ke(0,h,p),rc=()=>ke(Ze,h,p),ic=b=>ke(b*Re,h,p),oc=()=>ke(Te,h,p),nc=()=>ke(et,h,p);function ac(b){zt[b?"unshift":"push"](()=>{x=b,t(9,x)})}return r.$$set=b=>{"endpoint"in b&&t(28,o=b.endpoint),"session"in b&&t(29,n=b.session),"playerid"in b&&t(30,a=b.playerid),"lang"in b&&t(0,s=b.lang),"clientstyling"in b&&t(1,l=b.clientstyling),"clientstylingurl"in b&&t(2,d=b.clientstylingurl),"mbsource"in b&&t(3,u=b.mbsource),"translationurl"in b&&t(4,c=b.translationurl),"bonushistorystatus"in b&&t(5,h=b.bonushistorystatus),"bonushistorytype"in b&&t(6,p=b.bonushistorytype),"currencylocale"in b&&t(7,m=b.currencylocale),"currency"in b&&t(31,f=b.currency),"dateformat"in b&&t(8,y=b.dateformat),"gmversion"in b&&t(32,E=b.gmversion)},r.$$.update=()=>{r.$$.dirty[0]&1&&s&&ti(),r.$$.dirty[0]&3072&&J&&W&&ei(),r.$$.dirty[0]&12288&&P&&k&&Tt(),r.$$.dirty[0]&1879048288&&n&&a&&o&&ke(0,h,p),r.$$.dirty[0]&514&&l&&x&&ml(x,l),r.$$.dirty[0]&516&&d&&x&&fl(x,d),r.$$.dirty[0]&520&&u&&x&&_l(x,`${u}.Style`,A),r.$$.dirty[0]&16&&c&&oe()},[s,l,d,u,c,h,p,m,y,x,J,W,P,k,D,I,he,Ze,Te,et,Be,ue,K,i,$,X,ar,ke,o,n,a,f,E,Qu,Ju,Zu,ec,tc,rc,ic,oc,nc,ac]}class Ku extends pl{constructor(e){super(),ul(this,e,w0,b0,Tn,{endpoint:28,session:29,playerid:30,lang:0,clientstyling:1,clientstylingurl:2,mbsource:3,translationurl:4,bonushistorystatus:5,bonushistorytype:6,currencylocale:7,currency:31,dateformat:8,gmversion:32},c0,[-1,-1])}get endpoint(){return this.$$.ctx[28]}set endpoint(e){this.$$set({endpoint:e}),me()}get session(){return this.$$.ctx[29]}set session(e){this.$$set({session:e}),me()}get playerid(){return this.$$.ctx[30]}set playerid(e){this.$$set({playerid:e}),me()}get lang(){return this.$$.ctx[0]}set lang(e){this.$$set({lang:e}),me()}get clientstyling(){return this.$$.ctx[1]}set clientstyling(e){this.$$set({clientstyling:e}),me()}get clientstylingurl(){return this.$$.ctx[2]}set clientstylingurl(e){this.$$set({clientstylingurl:e}),me()}get mbsource(){return this.$$.ctx[3]}set mbsource(e){this.$$set({mbsource:e}),me()}get translationurl(){return this.$$.ctx[4]}set translationurl(e){this.$$set({translationurl:e}),me()}get bonushistorystatus(){return this.$$.ctx[5]}set bonushistorystatus(e){this.$$set({bonushistorystatus:e}),me()}get bonushistorytype(){return this.$$.ctx[6]}set bonushistorytype(e){this.$$set({bonushistorytype:e}),me()}get currencylocale(){return this.$$.ctx[7]}set currencylocale(e){this.$$set({currencylocale:e}),me()}get currency(){return this.$$.ctx[31]}set currency(e){this.$$set({currency:e}),me()}get dateformat(){return this.$$.ctx[8]}set dateformat(e){this.$$set({dateformat:e}),me()}get gmversion(){return this.$$.ctx[32]}set gmversion(e){this.$$set({gmversion:e}),me()}}hl(Ku,{endpoint:{},session:{},playerid:{},lang:{},clientstyling:{},clientstylingurl:{},mbsource:{},translationurl:{},bonushistorystatus:{},bonushistorytype:{},currencylocale:{},currency:{},dateformat:{},gmversion:{}},[],[],!0);const x0=Object.freeze(Object.defineProperty({__proto__:null,default:Ku},Symbol.toStringTag,{value:"Module"}));exports.$format=ql;exports.$locale=yt;exports.PlayerBonusHistory_ce=x0;exports.SvelteComponent=pl;exports.addMessages=kn;exports.append=T;exports.append_styles=sl;exports.attr=O;exports.binding_callbacks=zt;exports.component_subscribe=al;exports.create_custom_element=hl;exports.detach=ge;exports.element=Q;exports.flush=me;exports.format=je;exports.getDevice=Yl;exports.init=ul;exports.insert=Ee;exports.listen=ot;exports.noop=Oe;exports.onMount=dl;exports.safe_not_equal=Tn;exports.setClientStyling=ml;exports.setClientStylingURL=fl;exports.setStreamStyling=_l;exports.set_data=pt;exports.space=Ae;exports.src_url_equal=pc;exports.text=Ce;
|
|
6680
|
+
`),a=It("g"),s=It("g"),l=It("path"),d=Ae(),u=Q("h2"),h=Ce(c),D(l,"class","aaa"),D(l,"d","M7.5,0,6.136,1.364,11.3,6.526H0V8.474H11.3L6.136,13.636,7.5,15,15,7.5Z"),D(l,"transform","translate(15 15) rotate(180)"),D(s,"transform","translate(20 158)"),D(a,"transform","translate(-20 -158)"),D(t,"xmlns","http://www.w3.org/2000/svg"),D(t,"width","15"),D(t,"height","15"),D(t,"viewBox","0 0 15 15"),D(u,"class","BonusesTitleMobile"),D(e,"class","MenuReturnButton")},m(f,y){Ee(f,e,y),P(e,t),P(t,i),P(i,o),P(o,n),P(t,a),P(a,s),P(s,l),P(e,d),P(e,u),P(u,h),p||(m=it(e,"click",r[34]),p=!0)},p(f,y){y[0]&16777216&&c!==(c=f[24]("titleBonusesHistory")+"")&&mt(h,c)},d(f){f&&ge(e),p=!1,m()}}}function m0(r){let e,t,i;function o(l,d){return l[23].length===0?v0:_0}let n=o(r),a=n(r),s=r[23].length!==0&&rl(r);return{c(){e=Q("div"),a.c(),t=Ae(),s&&s.c(),i=Pn(),D(e,"class","BonusesGrid "+(r[25]?"BonusesGridMobile":""))},m(l,d){Ee(l,e,d),a.m(e,null),Ee(l,t,d),s&&s.m(l,d),Ee(l,i,d)},p(l,d){n===(n=o(l))&&a?a.p(l,d):(a.d(1),a=n(l),a&&(a.c(),a.m(e,null))),l[23].length!==0?s?s.p(l,d):(s=rl(l),s.c(),s.m(i.parentNode,i)):s&&(s.d(1),s=null)},d(l){l&&(ge(e),ge(t),ge(i)),a.d(),s&&s.d(l)}}}function f0(r){let e;return{c(){e=Q("div"),D(e,"class","ModalLoader")},m(t,i){Ee(t,e,i)},p:De,d(t){t&&ge(e)}}}function _0(r){let e,t=wi(r[23]),i=[];for(let o=0;o<t.length;o+=1)i[o]=tl(el(r,t,o));return{c(){for(let o=0;o<i.length;o+=1)i[o].c();e=Pn()},m(o,n){for(let a=0;a<i.length;a+=1)i[a]&&i[a].m(o,n);Ee(o,e,n)},p(o,n){if(n[0]&8389535){t=wi(o[23]);let a;for(a=0;a<t.length;a+=1){const s=el(o,t,a);i[a]?i[a].p(s,n):(i[a]=tl(s),i[a].c(),i[a].m(e.parentNode,e))}for(;a<i.length;a+=1)i[a].d(1);i.length=t.length}},d(o){o&&ge(e),ll(i,o)}}}function v0(r){let e,t=r[24]("noBonusHistory")+"",i;return{c(){e=Q("p"),i=Ce(t)},m(o,n){Ee(o,e,n),P(e,i)},p(o,n){n[0]&16777216&&t!==(t=o[24]("noBonusHistory")+"")&&mt(i,t)},d(o){o&&ge(e)}}}function g0(r){let e,t,i,o,n,a,s,l,d,u,c,h,p;return{c(){e=Q("player-bonus-card"),_(e,"termsandconditionsdescription",t=r[59].termsandconditionsdescription),_(e,"termsandconditionsurl",i=r[59].termsandconditionsurl),_(e,"termsandconditionsasset",o=r[59].termsandconditionsasset),_(e,"bonuswalletid",n=r[59].walletId),_(e,"bonusdate",a=r[59].granted),_(e,"bonusstatus",s=r[59].status),_(e,"bonusname",l=r[59].name),_(e,"bonustype",d=r[59].type),_(e,"bonusamount",u=r[59].extension.grantedPlayerCurrencyAmount),_(e,"bonuswageringamount",c=`${r[59].fulfilledWR} / ${r[59].originalWageringRequirement}`),_(e,"bonusremainingamount",h=r[59].currentAmount),_(e,"bonuscurrency",p=r[59].currency),_(e,"lang",r[0]),_(e,"clientstyling",r[1]),_(e,"clientstylingurl",r[2]),_(e,"mbsource",r[3]),_(e,"translationurl",r[4]),_(e,"currencylocale",r[7]),_(e,"dateformat",r[8]),_(e,"filterbonusbalance",r[9])},m(m,f){Ee(m,e,f)},p(m,f){f[0]&8388608&&t!==(t=m[59].termsandconditionsdescription)&&_(e,"termsandconditionsdescription",t),f[0]&8388608&&i!==(i=m[59].termsandconditionsurl)&&_(e,"termsandconditionsurl",i),f[0]&8388608&&o!==(o=m[59].termsandconditionsasset)&&_(e,"termsandconditionsasset",o),f[0]&8388608&&n!==(n=m[59].walletId)&&_(e,"bonuswalletid",n),f[0]&8388608&&a!==(a=m[59].granted)&&_(e,"bonusdate",a),f[0]&8388608&&s!==(s=m[59].status)&&_(e,"bonusstatus",s),f[0]&8388608&&l!==(l=m[59].name)&&_(e,"bonusname",l),f[0]&8388608&&d!==(d=m[59].type)&&_(e,"bonustype",d),f[0]&8388608&&u!==(u=m[59].extension.grantedPlayerCurrencyAmount)&&_(e,"bonusamount",u),f[0]&8388608&&c!==(c=`${m[59].fulfilledWR} / ${m[59].originalWageringRequirement}`)&&_(e,"bonuswageringamount",c),f[0]&8388608&&h!==(h=m[59].currentAmount)&&_(e,"bonusremainingamount",h),f[0]&8388608&&p!==(p=m[59].currency)&&_(e,"bonuscurrency",p),f[0]&1&&_(e,"lang",m[0]),f[0]&2&&_(e,"clientstyling",m[1]),f[0]&4&&_(e,"clientstylingurl",m[2]),f[0]&8&&_(e,"mbsource",m[3]),f[0]&16&&_(e,"translationurl",m[4]),f[0]&128&&_(e,"currencylocale",m[7]),f[0]&256&&_(e,"dateformat",m[8]),f[0]&512&&_(e,"filterbonusbalance",m[9])},d(m){m&&ge(e)}}}function b0(r){let e,t,i,o,n,a,s,l,d,u;return{c(){e=Q("player-bonus-card"),_(e,"termsandconditionsdescription",t=r[59].termsandconditionsdescription),_(e,"termsandconditionsurl",i=r[59].termsandconditionsurl),_(e,"termsandconditionsasset",o=r[59].termsandconditionsasset),_(e,"bonuswalletid",n=r[59].walletId),_(e,"bonusdate",a=r[59].granted),_(e,"bonusstatus",s=r[59].status),_(e,"bonusname",l=r[59].name),_(e,"bonustype",d=r[59].type),_(e,"bonuscurrency",u=r[59].currency),_(e,"lang",r[0]),_(e,"clientstyling",r[1]),_(e,"clientstylingurl",r[2]),_(e,"mbsource",r[3]),_(e,"translationurl",r[4]),_(e,"currencylocale",r[7]),_(e,"dateformat",r[8]),_(e,"filterbonusbalance",r[9])},m(c,h){Ee(c,e,h)},p(c,h){h[0]&8388608&&t!==(t=c[59].termsandconditionsdescription)&&_(e,"termsandconditionsdescription",t),h[0]&8388608&&i!==(i=c[59].termsandconditionsurl)&&_(e,"termsandconditionsurl",i),h[0]&8388608&&o!==(o=c[59].termsandconditionsasset)&&_(e,"termsandconditionsasset",o),h[0]&8388608&&n!==(n=c[59].walletId)&&_(e,"bonuswalletid",n),h[0]&8388608&&a!==(a=c[59].granted)&&_(e,"bonusdate",a),h[0]&8388608&&s!==(s=c[59].status)&&_(e,"bonusstatus",s),h[0]&8388608&&l!==(l=c[59].name)&&_(e,"bonusname",l),h[0]&8388608&&d!==(d=c[59].type)&&_(e,"bonustype",d),h[0]&8388608&&u!==(u=c[59].currency)&&_(e,"bonuscurrency",u),h[0]&1&&_(e,"lang",c[0]),h[0]&2&&_(e,"clientstyling",c[1]),h[0]&4&&_(e,"clientstylingurl",c[2]),h[0]&8&&_(e,"mbsource",c[3]),h[0]&16&&_(e,"translationurl",c[4]),h[0]&128&&_(e,"currencylocale",c[7]),h[0]&256&&_(e,"dateformat",c[8]),h[0]&512&&_(e,"filterbonusbalance",c[9])},d(c){c&&ge(e)}}}function tl(r){let e;function t(n,a){return n[59].type==="freeRound"?b0:g0}let i=t(r),o=i(r);return{c(){o.c(),e=Pn()},m(n,a){o.m(n,a),Ee(n,e,a)},p(n,a){i===(i=t(n))&&o?o.p(n,a):(o.d(1),o=i(n),o&&(o.c(),o.m(e.parentNode,e)))},d(n){n&&ge(e),o.d(n)}}}function rl(r){let e,t,i,o,n,a,s,l,d,u,c,h,p,m,f,y,E,C,T,N,U,W,me,Y=wi(Array(r[21])),O=[];for(let I=0;I<Y.length;I+=1)O[I]=il(Zs(r,Y,I));return{c(){e=Q("div"),t=Q("button"),i=Ce("|<"),a=Ae(),s=Q("button"),l=Ce("<"),c=Ae();for(let I=0;I<O.length;I+=1)O[I].c();h=Ae(),p=Q("button"),m=Ce(">"),E=Ae(),C=Q("button"),T=Ce(">|"),t.disabled=o=r[22]===0,D(t,"class",n="BonusesFirst "+(r[22]===0?"Inactive":"")),s.disabled=d=r[22]===0,D(s,"class",u="BonusesPrev "+(r[22]===0?"Inactive":"")),p.disabled=f=r[22]===r[21]-1,D(p,"class",y="BonusesNext "+(r[22]===r[21]-1?"Inactive":"")),C.disabled=N=r[22]===r[21]-1,D(C,"class",U="BonusesLast "+(r[22]===r[21]-1?"Inactive":"")),D(e,"class","BonusesPaginationWrapper "+(r[25]?"BonusesPaginationWrapperMobile":""))},m(I,S){Ee(I,e,S),P(e,t),P(t,i),P(e,a),P(e,s),P(s,l),P(e,c);for(let A=0;A<O.length;A+=1)O[A]&&O[A].m(e,null);P(e,h),P(e,p),P(p,m),P(e,E),P(e,C),P(C,T),W||(me=[it(t,"click",r[38]),it(s,"click",r[39]),it(p,"click",r[41]),it(C,"click",r[42])],W=!0)},p(I,S){if(S[0]&4194304&&o!==(o=I[22]===0)&&(t.disabled=o),S[0]&4194304&&n!==(n="BonusesFirst "+(I[22]===0?"Inactive":""))&&D(t,"class",n),S[0]&4194304&&d!==(d=I[22]===0)&&(s.disabled=d),S[0]&4194304&&u!==(u="BonusesPrev "+(I[22]===0?"Inactive":""))&&D(s,"class",u),S[0]&274727008){Y=wi(Array(I[21]));let A;for(A=0;A<Y.length;A+=1){const de=Zs(I,Y,A);O[A]?O[A].p(de,S):(O[A]=il(de),O[A].c(),O[A].m(e,h))}for(;A<O.length;A+=1)O[A].d(1);O.length=Y.length}S[0]&6291456&&f!==(f=I[22]===I[21]-1)&&(p.disabled=f),S[0]&6291456&&y!==(y="BonusesNext "+(I[22]===I[21]-1?"Inactive":""))&&D(p,"class",y),S[0]&6291456&&N!==(N=I[22]===I[21]-1)&&(C.disabled=N),S[0]&6291456&&U!==(U="BonusesLast "+(I[22]===I[21]-1?"Inactive":""))&&D(C,"class",U)},d(I){I&&ge(e),ll(O,I),W=!1,Zt(me)}}}function il(r){let e,t=r[58]+1+"",i,o,n,a,s;function l(){return r[40](r[58])}return{c(){e=Q("button"),i=Ce(t),e.disabled=o=r[58]===r[22],D(e,"class",n="BonusesPage "+(r[58]===r[22]?"BonusPageActive":""))},m(d,u){Ee(d,e,u),P(e,i),a||(s=it(e,"click",l),a=!0)},p(d,u){r=d,u[0]&4194304&&o!==(o=r[58]===r[22])&&(e.disabled=o),u[0]&4194304&&n!==(n="BonusesPage "+(r[58]===r[22]?"BonusPageActive":""))&&D(e,"class",n)},d(d){d&&ge(e),a=!1,s()}}}function y0(r){let e,t,i,o,n=r[24]("titleBonusesHistory")+"",a,s,l,d,u,c,h=r[24]("dateFrom")+"",p,m,f,y,E,C,T=r[24]("dateTo")+"",N,U,W,me,Y,O=r[24]("dateFilter")+"",I,S,A,de,Je,Te=r[25]&&p0(r);function Ze(K,te){return K[15]?f0:m0}let Me=Ze(r),ue=Me(r);return{c(){e=Q("div"),t=Q("div"),Te&&Te.c(),i=Ae(),o=Q("h2"),a=Ce(n),s=Ae(),l=Q("div"),d=Q("div"),u=Q("div"),c=Q("label"),p=Ce(h),m=Ae(),f=Q("vaadin-date-picker"),y=Ae(),E=Q("div"),C=Q("label"),N=Ce(T),U=Ae(),W=Q("vaadin-date-picker"),me=Ae(),Y=Q("button"),I=Ce(O),A=Ae(),ue.c(),D(o,"class","BonusesTitle "+(r[25]?"BonusesTitleNone":"")),D(o,"part","BonusesTitle "+(r[25]?"BonusesTitleNone":"")),D(c,"for","BonusCalendarStartDate"),_(f,"max",r[26]),_(f,"value",r[13]),_(f,"placeholder",r[13]),_(f,"class","VaadinDatePicker"),D(u,"class","BonusesCalendarStartDate "+(r[25]?"BonusesCalendarMobile":"")),D(C,"for","BonusesCalendarEndDate"),_(W,"max",r[26]),_(W,"min",r[16]),_(W,"value",r[14]),_(W,"placeholder",r[14]),_(W,"class","VaadinDatePicker"),D(E,"class","BonusesCalendarEndDate "+(r[25]?"BonusesCalendarMobile":"")),D(d,"class","BonusesCalendarContainer "+(r[25]?"BonusesCalendarContainerMobile":"")),D(Y,"class","BonusesCalendarFilter "+(r[25]?"BonusesCalendarFilterMobile":"")),Y.disabled=S=!r[17]||r[15],D(l,"class","BonusCalendarWrapper "+(r[25]?"BonusCalendarWrapperMobile":"")),D(t,"class","BonusesWrapper "+(r[25]?"BonusesWrapperMobile":""))},m(K,te){Ee(K,e,te),P(e,t),Te&&Te.m(t,null),P(t,i),P(t,o),P(o,a),P(t,s),P(t,l),P(l,d),P(d,u),P(u,c),P(c,p),P(u,m),P(u,f),r[35](f),P(d,y),P(d,E),P(E,C),P(C,N),P(E,U),P(E,W),r[36](W),P(l,me),P(l,Y),P(Y,I),P(t,A),ue.m(t,null),r[43](e),de||(Je=it(Y,"click",r[37]),de=!0)},p(K,te){K[25]&&Te.p(K,te),te[0]&16777216&&n!==(n=K[24]("titleBonusesHistory")+"")&&mt(a,n),te[0]&16777216&&h!==(h=K[24]("dateFrom")+"")&&mt(p,h),te[0]&8192&&_(f,"value",K[13]),te[0]&8192&&_(f,"placeholder",K[13]),te[0]&16777216&&T!==(T=K[24]("dateTo")+"")&&mt(N,T),te[0]&65536&&_(W,"min",K[16]),te[0]&16384&&_(W,"value",K[14]),te[0]&16384&&_(W,"placeholder",K[14]),te[0]&16777216&&O!==(O=K[24]("dateFilter")+"")&&mt(I,O),te[0]&163840&&S!==(S=!K[17]||K[15])&&(Y.disabled=S),Me===(Me=Ze(K))&&ue?ue.p(K,te):(ue.d(1),ue=Me(K),ue&&(ue.c(),ue.m(t,null)))},i:De,o:De,d(K){K&&ge(e),Te&&Te.d(),r[35](null),r[36](null),ue.d(),r[43](null),de=!1,Je()}}}let He=6;function w0(r){var i,o,n,a,s,l,d,u,c,h,p;const e=(i=r.initialWagerRequirementAmount)!=null?i:0,t=(o=r.remainingWagerRequirementAmount)!=null?o:0;return hr(ct({},r),{walletId:(n=r.bonusWalletID)!=null?n:void 0,granted:(a=r.grantedDate)!=null?a:void 0,expiryTime:(s=r.expiryDate)!=null?s:void 0,currentAmount:(l=r.remainingAmount)!=null?l:void 0,originalWageringRequirement:(d=r.initialWagerRequirementAmount)!=null?d:void 0,fulfilledWR:e-t,extension:{grantedPlayerCurrencyAmount:(u=r.amount)!=null?u:void 0},termsandconditionsurl:(c=r.url)!=null?c:void 0,termsandconditionsdescription:(h=r.description)!=null?h:void 0,termsandconditionsasset:(p=r.assets)!=null?p:void 0})}function x0(r,e,t){let i;al(r,ql,b=>t(24,i=b));let{endpoint:o=""}=e,{session:n=""}=e,{playerid:a=""}=e,{lang:s="en"}=e,{clientstyling:l=""}=e,{clientstylingurl:d=""}=e,{mbsource:u}=e,{translationurl:c=""}=e,{bonushistorystatus:h=""}=e,{bonushistorytype:p=""}=e,{currencylocale:m=""}=e,{currency:f=""}=e,{dateformat:y="dd-MM-yyyy"}=e,{gmversion:E=""}=e,{filterbonusbalance:C="false"}=e,T,N,U=!1,W=window.navigator.userAgent,me=Yl(W)!=="PC",Y,O;const I=We(new Date,"yyyy-MM-dd");let S="",A=We(zf(new Date,3),`${y||"yyyy-MM-dd"}`),de=We(new Date,`${y||"yyyy-MM-dd"}`),Je=!0,Te=0,Ze=0,Me=0,ue=0,K=0,te=[];const Zr=()=>{fetch(c).then(re=>re.json()).then(re=>{Object.keys(re).forEach(ke=>{Qa(ke,re[ke])})}).catch(re=>{console.log(re)})};Object.keys(Ja).forEach(b=>{Qa(b,Ja[b])});const ar=()=>{window.postMessage({type:"PlayerAccountMenuActive",isMobile:me},window.location.href)},dt=(b,re)=>{const ke=Ka(b,`${y||"yyyy-MM-dd"}`,new Date),At=re?Up(ke):zp(ke);return We(At,"yyyy-MM-dd'T'HH:mm:ss.SSS'Z'")},J=(b,re,ke)=>pr(this,null,function*(){var ga,ba;t(15,U=!0);let At=dt(A,!1),lr=dt(de,!0),_a,va;re&&(_a=re.split(",").map(_e=>`status=${_e}`).join(",")),ke&&(va=ke.split(",").map(_e=>`type=${_e}`).join(","));try{let et=[],kt=0;if(E==="gm2"){const _e={pagination:`limit=${He},offset=${b}`,language:s||"en",sortOrder:"desc",status:re!=null?re:Za.STATUS_COMPLETED,type:ke!=null?ke:Za.TYPES,startTime:At,endTime:lr},dr=yield $f(o,n,_e),ur=dr.items;Array.isArray(ur)?et=ur.map(w0):console.error("Unexpected history bonuses payload",dr),kt=(ga=dr.total)!=null?ga:0}else{const _e={method:"GET",headers:{"X-SessionId":n}},dr=`/v1/player/${a}/bonusWallet`,ur=new URL(`${o}${dr}`),ao=new URLSearchParams;let lc=`granted=[${At}~${lr}],${_a},${va}`;ao.set("pagination",`offset=${b},limit=${He}`),ao.set("filter",lc),ur.search=ao.toString();const cr=yield(yield fetch(ur,_e)).json();Array.isArray(cr.items)?(cr.items.forEach(Be=>{var ya,wa;const ri=(wa=(ya=Be==null?void 0:Be.extension)==null?void 0:ya.bonus)==null?void 0:wa.presentation;ri&&(Be.termsandconditionsurl||(Be.termsandconditionsurl=ri.url),Be.termsandconditionsdescription||(Be.termsandconditionsdescription=ri.description),Be.termsandconditionsasset||(Be.termsandconditionsasset=ri.assets))}),et=cr.items):console.error("Unexpected legacy bonus list payload",cr),kt=(ba=cr.total)!=null?ba:0}t(21,ue=Math.ceil(kt/He)),b-He>=0&&t(18,Te=b-He),b+He<kt&&t(19,Ze=b+He),t(20,Me=(ue-1)*He),t(22,K=b/He),m&&et.forEach(_e=>{_e.fulfilledWR=j(_e.fulfilledWR),_e.originalWageringRequirement=j(_e.originalWageringRequirement),_e.currentAmount=j(_e.currentAmount),_e.extension.grantedPlayerCurrencyAmount=j(_e.extension.grantedPlayerCurrencyAmount)}),t(23,te=et),window.postMessage({type:"ScrollToTop"},window.location.href)}catch(et){console.error(et)}finally{t(15,U=!1)}}),j=b=>new Intl.NumberFormat(m,{style:"currency",currency:f}).format(b).replace(/\s/g,""),ye=b=>{t(13,A=We(new Date(b.target.value),`${y||"yyyy-MM-dd"}`)),t(16,S=We(new Date(b.target.value),"yyyy-MM-dd"))},ut=b=>{t(14,de=We(new Date(b.target.value),`${y||"yyyy-MM-dd"}`))},ei=()=>{const b=new Date(A),re=new Date(de);b.getTime()>re.getTime()?t(17,Je=!1):t(17,Je=!0)},ti=()=>{Y.addEventListener("change",ye,!1),O.addEventListener("change",ut,!1)},Pt=b=>{const{year:re,month:ke,day:At}=b,lr=new Date(re,ke,At);return We(lr,y||"yyyy-MM-dd")},sr=b=>{const re=Ka(b,y||"yyyy-MM-dd",new Date);return{year:re.getFullYear(),month:re.getMonth(),day:re.getDate()}};dl(()=>(t(11,Y.i18n=hr(ct({},Y.i18n),{formatDate:Pt,parseDate:sr}),Y),t(12,O.i18n=hr(ct({},O.i18n),{formatDate:Pt,parseDate:sr}),O),()=>{Y.removeEventListener("change",ye),O.removeEventListener("change",ut)}));const Qu=()=>{Hf(s)},Ju=()=>ar();function Zu(b){zt[b?"unshift":"push"](()=>{Y=b,t(11,Y)})}function ec(b){zt[b?"unshift":"push"](()=>{O=b,t(12,O)})}const tc=()=>J(0,h,p),rc=()=>J(0,h,p),ic=()=>J(Te,h,p),oc=b=>J(b*He,h,p),nc=()=>J(Ze,h,p),ac=()=>J(Me,h,p);function sc(b){zt[b?"unshift":"push"](()=>{T=b,t(10,T)})}return r.$$set=b=>{"endpoint"in b&&t(29,o=b.endpoint),"session"in b&&t(30,n=b.session),"playerid"in b&&t(31,a=b.playerid),"lang"in b&&t(0,s=b.lang),"clientstyling"in b&&t(1,l=b.clientstyling),"clientstylingurl"in b&&t(2,d=b.clientstylingurl),"mbsource"in b&&t(3,u=b.mbsource),"translationurl"in b&&t(4,c=b.translationurl),"bonushistorystatus"in b&&t(5,h=b.bonushistorystatus),"bonushistorytype"in b&&t(6,p=b.bonushistorytype),"currencylocale"in b&&t(7,m=b.currencylocale),"currency"in b&&t(32,f=b.currency),"dateformat"in b&&t(8,y=b.dateformat),"gmversion"in b&&t(33,E=b.gmversion),"filterbonusbalance"in b&&t(9,C=b.filterbonusbalance)},r.$$.update=()=>{r.$$.dirty[0]&1&&s&&Qu(),r.$$.dirty[0]&6144&&Y&&O&&ti(),r.$$.dirty[0]&24576&&A&&de&&ei(),r.$$.dirty[0]&1610612832|r.$$.dirty[1]&1&&n&&a&&o&&J(0,h,p),r.$$.dirty[0]&1026&&l&&T&&ml(T,l),r.$$.dirty[0]&1028&&d&&T&&fl(T,d),r.$$.dirty[0]&1032&&u&&T&&_l(T,`${u}.Style`,N),r.$$.dirty[0]&16&&c&&Zr()},[s,l,d,u,c,h,p,m,y,C,T,Y,O,A,de,U,S,Je,Te,Ze,Me,ue,K,te,i,me,I,ar,J,o,n,a,f,E,Ju,Zu,ec,tc,rc,ic,oc,nc,ac,sc]}class Ku extends pl{constructor(e){super(),ul(this,e,x0,y0,Tn,{endpoint:29,session:30,playerid:31,lang:0,clientstyling:1,clientstylingurl:2,mbsource:3,translationurl:4,bonushistorystatus:5,bonushistorytype:6,currencylocale:7,currency:32,dateformat:8,gmversion:33,filterbonusbalance:9},h0,[-1,-1])}get endpoint(){return this.$$.ctx[29]}set endpoint(e){this.$$set({endpoint:e}),he()}get session(){return this.$$.ctx[30]}set session(e){this.$$set({session:e}),he()}get playerid(){return this.$$.ctx[31]}set playerid(e){this.$$set({playerid:e}),he()}get lang(){return this.$$.ctx[0]}set lang(e){this.$$set({lang:e}),he()}get clientstyling(){return this.$$.ctx[1]}set clientstyling(e){this.$$set({clientstyling:e}),he()}get clientstylingurl(){return this.$$.ctx[2]}set clientstylingurl(e){this.$$set({clientstylingurl:e}),he()}get mbsource(){return this.$$.ctx[3]}set mbsource(e){this.$$set({mbsource:e}),he()}get translationurl(){return this.$$.ctx[4]}set translationurl(e){this.$$set({translationurl:e}),he()}get bonushistorystatus(){return this.$$.ctx[5]}set bonushistorystatus(e){this.$$set({bonushistorystatus:e}),he()}get bonushistorytype(){return this.$$.ctx[6]}set bonushistorytype(e){this.$$set({bonushistorytype:e}),he()}get currencylocale(){return this.$$.ctx[7]}set currencylocale(e){this.$$set({currencylocale:e}),he()}get currency(){return this.$$.ctx[32]}set currency(e){this.$$set({currency:e}),he()}get dateformat(){return this.$$.ctx[8]}set dateformat(e){this.$$set({dateformat:e}),he()}get gmversion(){return this.$$.ctx[33]}set gmversion(e){this.$$set({gmversion:e}),he()}get filterbonusbalance(){return this.$$.ctx[9]}set filterbonusbalance(e){this.$$set({filterbonusbalance:e}),he()}}hl(Ku,{endpoint:{},session:{},playerid:{},lang:{},clientstyling:{},clientstylingurl:{},mbsource:{},translationurl:{},bonushistorystatus:{},bonushistorytype:{},currencylocale:{},currency:{},dateformat:{},gmversion:{},filterbonusbalance:{}},[],[],!0);const C0=Object.freeze(Object.defineProperty({__proto__:null,default:Ku},Symbol.toStringTag,{value:"Module"}));exports.$format=ql;exports.$locale=wt;exports.PlayerBonusHistory_ce=C0;exports.SvelteComponent=pl;exports.addMessages=kn;exports.append=P;exports.append_styles=sl;exports.attr=D;exports.binding_callbacks=zt;exports.component_subscribe=al;exports.create_custom_element=hl;exports.detach=ge;exports.element=Q;exports.flush=he;exports.format=We;exports.getDevice=Yl;exports.init=ul;exports.insert=Ee;exports.listen=it;exports.noop=De;exports.onMount=dl;exports.safe_not_equal=Tn;exports.setClientStyling=ml;exports.setClientStylingURL=fl;exports.setStreamStyling=_l;exports.set_data=mt;exports.space=Ae;exports.src_url_equal=mc;exports.text=Ce;
|