-
Notifications
You must be signed in to change notification settings - Fork 0
/
1.0.0.js
128 lines (126 loc) · 304 KB
/
1.0.0.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
var app=function(){"use strict";function e(){}const t=e=>e;function n(e,t){for(const n in t)e[n]=t[n];return e}function i(e){return e()}function r(){return Object.create(null)}function s(e){e.forEach(i)}function o(e){return"function"==typeof e}function a(e,t){return e!=e?t==t:e!==t||e&&"object"==typeof e||"function"==typeof e}let l;function c(e,t){return l||(l=document.createElement("a")),l.href=t,e===l.href}function u(t,...n){if(null==t)return e;const i=t.subscribe(...n);return i.unsubscribe?()=>i.unsubscribe():i}function d(e){let t;return u(e,(e=>t=e))(),t}function h(e,t,n){e.$$.on_destroy.push(u(t,n))}function f(e,t,n,i){if(e){const r=p(e,t,n,i);return e[0](r)}}function p(e,t,i,r){return e[1]&&r?n(i.ctx.slice(),e[1](r(t))):i.ctx}function m(e,t,n,i){if(e[2]&&i){const r=e[2](i(n));if(void 0===t.dirty)return r;if("object"==typeof r){const e=[],n=Math.max(t.dirty.length,r.length);for(let i=0;i<n;i+=1)e[i]=t.dirty[i]|r[i];return e}return t.dirty|r}return t.dirty}function g(e,t,n,i,r,s){if(r){const o=p(t,n,i,s);e.p(o,r)}}function v(e){if(e.ctx.length>32){const t=[],n=e.ctx.length/32;for(let e=0;e<n;e++)t[e]=-1;return t}return-1}function y(e){const t={};for(const n in e)"$"!==n[0]&&(t[n]=e[n]);return t}function _(e,t){const n={};t=new Set(t);for(const i in e)t.has(i)||"$"===i[0]||(n[i]=e[i]);return n}function $(e){let t=!1;return function(...n){t||(t=!0,e.call(this,...n))}}function b(e){return null==e?"":e}function w(e,t,n){return e.set(n),t}function E(t){return t&&o(t.destroy)?t.destroy:e}const x="undefined"!=typeof window;let C=x?()=>window.performance.now():()=>Date.now(),T=x?e=>requestAnimationFrame(e):e;const S=new Set;function k(e){S.forEach((t=>{t.c(e)||(S.delete(t),t.f())})),0!==S.size&&T(k)}function O(e,t){e.appendChild(t)}function L(e){if(!e)return document;const t=e.getRootNode?e.getRootNode():e.ownerDocument;return t&&t.host?t:e.ownerDocument}function A(e){const t=D("style");return function(e,t){O(e.head||e,t)}(L(e),t),t.sheet}function I(e,t,n){e.insertBefore(t,n||null)}function M(e){e.parentNode.removeChild(e)}function N(e,t){for(let n=0;n<e.length;n+=1)e[n]&&e[n].d(t)}function D(e){return document.createElement(e)}function P(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function R(e){return document.createTextNode(e)}function U(){return R(" ")}function V(){return R("")}function F(e,t,n,i){return e.addEventListener(t,n,i),()=>e.removeEventListener(t,n,i)}function Y(e,t,n){null==n?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function j(e,t){const n=Object.getOwnPropertyDescriptors(e.__proto__);for(const i in t)null==t[i]?e.removeAttribute(i):"style"===i?e.style.cssText=t[i]:"__value"===i?e.value=e[i]=t[i]:n[i]&&n[i].set?e[i]=t[i]:Y(e,i,t[i])}function H(e,t){t=""+t,e.wholeText!==t&&(e.data=t)}function z(e,t){e.value=null==t?"":t}function G(e,t,n,i){null===n?e.style.removeProperty(t):e.style.setProperty(t,n,i?"important":"")}function B(e,t,n){e.classList[n?"add":"remove"](t)}function W(e,t,n=!1){const i=document.createEvent("CustomEvent");return i.initCustomEvent(e,n,!1,t),i}class q{constructor(){this.e=this.n=null}c(e){this.h(e)}m(e,t,n=null){this.e||(this.e=D(t.nodeName),this.t=t,this.c(e)),this.i(n)}h(e){this.e.innerHTML=e,this.n=Array.from(this.e.childNodes)}i(e){for(let t=0;t<this.n.length;t+=1)I(this.t,this.n[t],e)}p(e){this.d(),this.h(e),this.i(this.a)}d(){this.n.forEach(M)}}const Z=new Map;let X,K=0;function J(e,t,n,i,r,s,o,a=0){const l=16.666/i;let c="{\n";for(let e=0;e<=1;e+=l){const i=t+(n-t)*s(e);c+=100*e+`%{${o(i,1-i)}}\n`}const u=c+`100% {${o(n,1-n)}}\n}`,d=`__svelte_${function(e){let t=5381,n=e.length;for(;n--;)t=(t<<5)-t^e.charCodeAt(n);return t>>>0}(u)}_${a}`,h=L(e),{stylesheet:f,rules:p}=Z.get(h)||function(e,t){const n={stylesheet:A(t),rules:{}};return Z.set(e,n),n}(h,e);p[d]||(p[d]=!0,f.insertRule(`@keyframes ${d} ${u}`,f.cssRules.length));const m=e.style.animation||"";return e.style.animation=`${m?`${m}, `:""}${d} ${i}ms linear ${r}ms 1 both`,K+=1,d}function Q(e,t){const n=(e.style.animation||"").split(", "),i=n.filter(t?e=>e.indexOf(t)<0:e=>-1===e.indexOf("__svelte")),r=n.length-i.length;r&&(e.style.animation=i.join(", "),K-=r,K||T((()=>{K||(Z.forEach((e=>{const{stylesheet:t}=e;let n=t.cssRules.length;for(;n--;)t.deleteRule(n);e.rules={}})),Z.clear())})))}function ee(e){X=e}function te(){if(!X)throw new Error("Function called outside component initialization");return X}function ne(e){te().$$.on_mount.push(e)}function ie(e){te().$$.on_destroy.push(e)}function re(){const e=te();return(t,n)=>{const i=e.$$.callbacks[t];if(i){const r=W(t,n);i.slice().forEach((t=>{t.call(e,r)}))}}}function se(e,t){te().$$.context.set(e,t)}function oe(e){return te().$$.context.get(e)}function ae(e,t){const n=e.$$.callbacks[t.type];n&&n.slice().forEach((e=>e.call(this,t)))}const le=[],ce=[],ue=[],de=[],he=Promise.resolve();let fe=!1;function pe(){fe||(fe=!0,he.then(be))}function me(){return pe(),he}function ge(e){ue.push(e)}function ve(e){de.push(e)}const ye=new Set;let _e,$e=0;function be(){const e=X;do{for(;$e<le.length;){const e=le[$e];$e++,ee(e),we(e.$$)}for(ee(null),le.length=0,$e=0;ce.length;)ce.pop()();for(let e=0;e<ue.length;e+=1){const t=ue[e];ye.has(t)||(ye.add(t),t())}ue.length=0}while(le.length);for(;de.length;)de.pop()();fe=!1,ye.clear(),ee(e)}function we(e){if(null!==e.fragment){e.update(),s(e.before_update);const t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(ge)}}function Ee(e,t,n){e.dispatchEvent(W(`${t?"intro":"outro"}${n}`))}const xe=new Set;let Ce;function Te(){Ce={r:0,c:[],p:Ce}}function Se(){Ce.r||s(Ce.c),Ce=Ce.p}function ke(e,t){e&&e.i&&(xe.delete(e),e.i(t))}function Oe(e,t,n,i){if(e&&e.o){if(xe.has(e))return;xe.add(e),Ce.c.push((()=>{xe.delete(e),i&&(n&&e.d(1),i())})),e.o(t)}}const Le={duration:0};function Ae(n,i,r,a){let l=i(n,r),c=a?0:1,u=null,d=null,h=null;function f(){h&&Q(n,h)}function p(e,t){const n=e.b-c;return t*=Math.abs(n),{a:c,b:e.b,d:n,duration:t,start:e.start,end:e.start+t,group:e.group}}function m(i){const{delay:r=0,duration:o=300,easing:a=t,tick:m=e,css:g}=l||Le,v={start:C()+r,b:i};i||(v.group=Ce,Ce.r+=1),u||d?d=v:(g&&(f(),h=J(n,c,i,o,r,a,g)),i&&m(0,1),u=p(v,o),ge((()=>Ee(n,i,"start"))),function(e){let t;0===S.size&&T(k),new Promise((n=>{S.add(t={c:e,f:n})}))}((e=>{if(d&&e>d.start&&(u=p(d,o),d=null,Ee(n,u.b,"start"),g&&(f(),h=J(n,c,u.b,u.duration,0,a,l.css))),u)if(e>=u.end)m(c=u.b,1-c),Ee(n,u.b,"end"),d||(u.b?f():--u.group.r||s(u.group.c)),u=null;else if(e>=u.start){const t=e-u.start;c=u.a+u.d*a(t/u.duration),m(c,1-c)}return!(!u&&!d)})))}return{run(e){o(l)?(_e||(_e=Promise.resolve(),_e.then((()=>{_e=null}))),_e).then((()=>{l=l(),m(e)})):m(e)},end(){f(),u=d=null}}}const Ie="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function Me(e,t){const n={},i={},r={$$scope:1};let s=e.length;for(;s--;){const o=e[s],a=t[s];if(a){for(const e in o)e in a||(i[e]=1);for(const e in a)r[e]||(n[e]=a[e],r[e]=1);e[s]=a}else for(const e in o)r[e]=1}for(const e in i)e in n||(n[e]=void 0);return n}function Ne(e){return"object"==typeof e&&null!==e?e:{}}function De(e,t,n){const i=e.$$.props[t];void 0!==i&&(e.$$.bound[i]=n,n(e.$$.ctx[i]))}function Pe(e){e&&e.c()}function Re(e,t,n,r){const{fragment:a,on_mount:l,on_destroy:c,after_update:u}=e.$$;a&&a.m(t,n),r||ge((()=>{const t=l.map(i).filter(o);c?c.push(...t):s(t),e.$$.on_mount=[]})),u.forEach(ge)}function Ue(e,t){const n=e.$$;null!==n.fragment&&(s(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function Ve(t,n,i,o,a,l,c,u=[-1]){const d=X;ee(t);const h=t.$$={fragment:null,ctx:null,props:l,update:e,not_equal:a,bound:r(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(n.context||(d?d.$$.context:[])),callbacks:r(),dirty:u,skip_bound:!1,root:n.target||d.$$.root};c&&c(h.root);let f=!1;if(h.ctx=i?i(t,n.props||{},((e,n,...i)=>{const r=i.length?i[0]:n;return h.ctx&&a(h.ctx[e],h.ctx[e]=r)&&(!h.skip_bound&&h.bound[e]&&h.bound[e](r),f&&function(e,t){-1===e.$$.dirty[0]&&(le.push(e),pe(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}(t,e)),n})):[],h.update(),f=!0,s(h.before_update),h.fragment=!!o&&o(h.ctx),n.target){if(n.hydrate){const e=function(e){return Array.from(e.childNodes)}(n.target);h.fragment&&h.fragment.l(e),e.forEach(M)}else h.fragment&&h.fragment.c();n.intro&&ke(t.$$.fragment),Re(t,n.target,n.anchor,n.customElement),be()}ee(d)}class Fe{$destroy(){Ue(this,1),this.$destroy=e}$on(e,t){const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{const e=n.indexOf(t);-1!==e&&n.splice(e,1)}}$set(e){var t;this.$$set&&(t=e,0!==Object.keys(t).length)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const Ye=[];function je(t,n=e){let i;const r=new Set;function s(e){if(a(t,e)&&(t=e,i)){const e=!Ye.length;for(const e of r)e[1](),Ye.push(e,t);if(e){for(let e=0;e<Ye.length;e+=2)Ye[e][0](Ye[e+1]);Ye.length=0}}}return{set:s,update:function(e){s(e(t))},subscribe:function(o,a=e){const l=[o,a];return r.add(l),1===r.size&&(i=n(s)||e),o(t),()=>{r.delete(l),0===r.size&&(i(),i=null)}}}}function He(t,n,i){const r=!Array.isArray(t),a=r?[t]:t,l=n.length<2;return c=t=>{let i=!1;const c=[];let d=0,h=e;const f=()=>{if(d)return;h();const i=n(r?c[0]:c,t);l?t(i):h=o(i)?i:e},p=a.map(((e,t)=>u(e,(e=>{c[t]=e,d&=~(1<<t),i&&f()}),(()=>{d|=1<<t}))));return i=!0,f(),function(){s(p),h()}},{subscribe:je(i,c).subscribe};var c}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function ze(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Ge=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===Be}(e)}(e)};var Be="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function We(e,t){return!1!==t.clone&&t.isMergeableObject(e)?Je((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function qe(e,t,n){return e.concat(t).map((function(e){return We(e,n)}))}function Ze(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter((function(t){return e.propertyIsEnumerable(t)})):[]}(e))}function Xe(e,t){try{return t in e}catch(e){return!1}}function Ke(e,t,n){var i={};return n.isMergeableObject(e)&&Ze(e).forEach((function(t){i[t]=We(e[t],n)})),Ze(t).forEach((function(r){(function(e,t){return Xe(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,r)||(Xe(e,r)&&n.isMergeableObject(t[r])?i[r]=function(e,t){if(!t.customMerge)return Je;var n=t.customMerge(e);return"function"==typeof n?n:Je}(r,n)(e[r],t[r],n):i[r]=We(t[r],n))})),i}function Je(e,t,n){(n=n||{}).arrayMerge=n.arrayMerge||qe,n.isMergeableObject=n.isMergeableObject||Ge,n.cloneUnlessOtherwiseSpecified=We;var i=Array.isArray(t);return i===Array.isArray(e)?i?n.arrayMerge(e,t,n):Ke(e,t,n):We(t,n)}Je.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce((function(e,n){return Je(e,n,t)}),{})};var Qe=Je,et=function(e,t){return et=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},et(e,t)};function tt(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}et(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var nt,it,rt,st=function(){return st=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},st.apply(this,arguments)};function ot(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function at(e,t,n){if(n||2===arguments.length)for(var i,r=0,s=t.length;r<s;r++)!i&&r in t||(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}function lt(e){return e.type===it.literal}function ct(e){return e.type===it.argument}function ut(e){return e.type===it.number}function dt(e){return e.type===it.date}function ht(e){return e.type===it.time}function ft(e){return e.type===it.select}function pt(e){return e.type===it.plural}function mt(e){return e.type===it.pound}function gt(e){return e.type===it.tag}function vt(e){return!(!e||"object"!=typeof e||e.type!==rt.number)}function yt(e){return!(!e||"object"!=typeof e||e.type!==rt.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(nt||(nt={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(it||(it={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(rt||(rt={}));var _t=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,$t=/(?:[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 bt(e){var t={};return e.replace($t,(function(e){var n=e.length;switch(e[0]){case"G":t.era=4===n?"long":5===n?"narrow":"short";break;case"y":t.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][n-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===n?"short":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][n-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][n-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][n-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][n-1];break;case"s":t.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=n<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""})),t}var wt=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;var Et,xt=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,Ct=/^(@+)?(\+|#+)?[rs]?$/g,Tt=/(\*)(0+)|(#+)(0+)|(0+)/g,St=/^(0+)$/;function kt(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(Ct,(function(e,n,i){return"string"!=typeof i?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===i?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof i?i.length:0)),""})),t}function Ot(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function Lt(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if("+!"===n?(t.signDisplay="always",e=e.slice(2)):"+?"===n&&(t.signDisplay="exceptZero",e=e.slice(2)),!St.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function At(e){var t=Ot(e);return t||{}}function It(e){for(var t={},n=0,i=e;n<i.length;n++){var r=i[n];switch(r.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=r.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=r.options[0].replace(/^(.*?)-/,"");continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=st(st(st({},t),{notation:"scientific"}),r.options.reduce((function(e,t){return st(st({},e),At(t))}),{}));continue;case"engineering":t=st(st(st({},t),{notation:"engineering"}),r.options.reduce((function(e,t){return st(st({},e),At(t))}),{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(r.options[0]);continue;case"integer-width":if(r.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");r.options[0].replace(Tt,(function(e,n,i,r,s,o){if(n)t.minimumIntegerDigits=i.length;else{if(r&&s)throw new Error("We currently do not support maximum integer digits");if(o)throw new Error("We currently do not support exact integer digits")}return""}));continue}if(St.test(r.stem))t.minimumIntegerDigits=r.stem.length;else if(xt.test(r.stem)){if(r.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");r.stem.replace(xt,(function(e,n,i,r,s,o){return"*"===i?t.minimumFractionDigits=n.length:r&&"#"===r[0]?t.maximumFractionDigits=r.length:s&&o?(t.minimumFractionDigits=s.length,t.maximumFractionDigits=s.length+o.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""}));var s=r.options[0];"w"===s?t=st(st({},t),{trailingZeroDisplay:"stripIfInteger"}):s&&(t=st(st({},t),kt(s)))}else if(Ct.test(r.stem))t=st(st({},t),kt(r.stem));else{var o=Ot(r.stem);o&&(t=st(st({},t),o));var a=Lt(r.stem);a&&(t=st(st({},t),a))}}return t}var Mt=new RegExp("^".concat(_t.source,"*")),Nt=new RegExp("".concat(_t.source,"*$"));function Dt(e,t){return{start:e,end:t}}var Pt=!!String.prototype.startsWith,Rt=!!String.fromCodePoint,Ut=!!Object.fromEntries,Vt=!!String.prototype.codePointAt,Ft=!!String.prototype.trimStart,Yt=!!String.prototype.trimEnd,jt=!!Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},Ht=!0;try{Ht="a"===(null===(Et=Kt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===Et?void 0:Et[0])}catch(e){Ht=!1}var zt,Gt=Pt?function(e,t,n){return e.startsWith(t,n)}:function(e,t,n){return e.slice(n,n+t.length)===t},Bt=Rt?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n,i="",r=e.length,s=0;r>s;){if((n=e[s++])>1114111)throw RangeError(n+" is not a valid code point");i+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return i},Wt=Ut?Object.fromEntries:function(e){for(var t={},n=0,i=e;n<i.length;n++){var r=i[n],s=r[0],o=r[1];t[s]=o}return t},qt=Vt?function(e,t){return e.codePointAt(t)}:function(e,t){var n=e.length;if(!(t<0||t>=n)){var i,r=e.charCodeAt(t);return r<55296||r>56319||t+1===n||(i=e.charCodeAt(t+1))<56320||i>57343?r:i-56320+(r-55296<<10)+65536}},Zt=Ft?function(e){return e.trimStart()}:function(e){return e.replace(Mt,"")},Xt=Yt?function(e){return e.trimEnd()}:function(e){return e.replace(Nt,"")};function Kt(e,t){return new RegExp(e,t)}if(Ht){var Jt=Kt("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");zt=function(e,t){var n;return Jt.lastIndex=t,null!==(n=Jt.exec(e)[1])&&void 0!==n?n:""}}else zt=function(e,t){for(var n=[];;){var i=qt(e,t);if(void 0===i||nn(i)||rn(i))break;n.push(i),t+=i>=65536?2:1}return Bt.apply(void 0,n)};var Qt=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,n){for(var i=[];!this.isEOF();){var r=this.char();if(123===r){if((s=this.parseArgument(e,n)).err)return s;i.push(s.val)}else{if(125===r&&e>0)break;if(35!==r||"plural"!==t&&"selectordinal"!==t){if(60===r&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(nt.UNMATCHED_CLOSING_TAG,Dt(this.clonePosition(),this.clonePosition()))}if(60===r&&!this.ignoreTag&&en(this.peek()||0)){if((s=this.parseTag(e,t)).err)return s;i.push(s.val)}else{var s;if((s=this.parseLiteral(e,t)).err)return s;i.push(s.val)}}else{var o=this.clonePosition();this.bump(),i.push({type:it.pound,location:Dt(o,this.clonePosition())})}}}return{val:i,err:null}},e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();var i=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:it.literal,value:"<".concat(i,"/>"),location:Dt(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var r=this.parseMessage(e+1,t,!0);if(r.err)return r;var s=r.val,o=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!en(this.char()))return this.error(nt.INVALID_TAG,Dt(o,this.clonePosition()));var a=this.clonePosition();return i!==this.parseTagName()?this.error(nt.UNMATCHED_CLOSING_TAG,Dt(a,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:it.tag,value:i,children:s,location:Dt(n,this.clonePosition())},err:null}:this.error(nt.INVALID_TAG,Dt(o,this.clonePosition())))}return this.error(nt.UNCLOSED_TAG,Dt(n,this.clonePosition()))}return this.error(nt.INVALID_TAG,Dt(n,this.clonePosition()))},e.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&tn(this.char());)this.bump();return this.message.slice(e,this.offset())},e.prototype.parseLiteral=function(e,t){for(var n=this.clonePosition(),i="";;){var r=this.tryParseQuote(t);if(r)i+=r;else{var s=this.tryParseUnquoted(e,t);if(s)i+=s;else{var o=this.tryParseLeftAngleBracket();if(!o)break;i+=o}}}var a=Dt(n,this.clonePosition());return{val:{type:it.literal,value:i,location:a},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(en(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(n);this.bump()}return Bt.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===t||"selectordinal"===t)||125===n&&e>0?null:(this.bump(),Bt(n))},e.prototype.parseArgument=function(e,t){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(nt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(nt.EMPTY_ARGUMENT,Dt(n,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(nt.MALFORMED_ARGUMENT,Dt(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(nt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:it.argument,value:i,location:Dt(n,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(nt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(n,this.clonePosition())):this.parseArgumentOptions(e,t,i,n);default:return this.error(nt.MALFORMED_ARGUMENT,Dt(n,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=zt(this.message,t),i=t+n.length;return this.bumpTo(i),{value:n,location:Dt(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,i){var r,s=this.clonePosition(),o=this.parseIdentifierIfPossible().value,a=this.clonePosition();switch(o){case"":return this.error(nt.EXPECT_ARGUMENT_TYPE,Dt(s,a));case"number":case"date":case"time":this.bumpSpace();var l=null;if(this.bumpIf(",")){this.bumpSpace();var c=this.clonePosition();if((g=this.parseSimpleArgStyleIfPossible()).err)return g;if(0===(h=Xt(g.val)).length)return this.error(nt.EXPECT_ARGUMENT_STYLE,Dt(this.clonePosition(),this.clonePosition()));l={style:h,styleLocation:Dt(c,this.clonePosition())}}if((v=this.tryParseArgumentClose(i)).err)return v;var u=Dt(i,this.clonePosition());if(l&&Gt(null==l?void 0:l.style,"::",0)){var d=Zt(l.style.slice(2));if("number"===o)return(g=this.parseNumberSkeletonFromString(d,l.styleLocation)).err?g:{val:{type:it.number,value:n,location:u,style:g.val},err:null};if(0===d.length)return this.error(nt.EXPECT_DATE_TIME_SKELETON,u);var h={type:rt.dateTime,pattern:d,location:l.styleLocation,parsedOptions:this.shouldParseSkeletons?bt(d):{}};return{val:{type:"date"===o?it.date:it.time,value:n,location:u,style:h},err:null}}return{val:{type:"number"===o?it.number:"date"===o?it.date:it.time,value:n,location:u,style:null!==(r=null==l?void 0:l.style)&&void 0!==r?r:null},err:null};case"plural":case"selectordinal":case"select":var f=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(nt.EXPECT_SELECT_ARGUMENT_OPTIONS,Dt(f,st({},f)));this.bumpSpace();var p=this.parseIdentifierIfPossible(),m=0;if("select"!==o&&"offset"===p.value){if(!this.bumpIf(":"))return this.error(nt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,Dt(this.clonePosition(),this.clonePosition()));var g;if(this.bumpSpace(),(g=this.tryParseDecimalInteger(nt.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,nt.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return g;this.bumpSpace(),p=this.parseIdentifierIfPossible(),m=g.val}var v,y=this.tryParsePluralOrSelectOptions(e,o,t,p);if(y.err)return y;if((v=this.tryParseArgumentClose(i)).err)return v;var _=Dt(i,this.clonePosition());return"select"===o?{val:{type:it.select,value:n,options:Wt(y.val),location:_},err:null}:{val:{type:it.plural,value:n,options:Wt(y.val),offset:m,pluralType:"plural"===o?"cardinal":"ordinal",location:_},err:null};default:return this.error(nt.INVALID_ARGUMENT_TYPE,Dt(s,a))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(nt.EXPECT_ARGUMENT_CLOSING_BRACE,Dt(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(nt.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,Dt(n,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var n=[];try{n=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=e.split(wt).filter((function(e){return e.length>0})),n=[],i=0,r=t;i<r.length;i++){var s=r[i].split("/");if(0===s.length)throw new Error("Invalid number skeleton");for(var o=s[0],a=s.slice(1),l=0,c=a;l<c.length;l++)if(0===c[l].length)throw new Error("Invalid number skeleton");n.push({stem:o,options:a})}return n}(e)}catch(e){return this.error(nt.INVALID_NUMBER_SKELETON,t)}return{val:{type:rt.number,tokens:n,location:t,parsedOptions:this.shouldParseSkeletons?It(n):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,n,i){for(var r,s=!1,o=[],a=new Set,l=i.value,c=i.location;;){if(0===l.length){var u=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var d=this.tryParseDecimalInteger(nt.EXPECT_PLURAL_ARGUMENT_SELECTOR,nt.INVALID_PLURAL_ARGUMENT_SELECTOR);if(d.err)return d;c=Dt(u,this.clonePosition()),l=this.message.slice(u.offset,this.offset())}if(a.has(l))return this.error("select"===t?nt.DUPLICATE_SELECT_ARGUMENT_SELECTOR:nt.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,c);"other"===l&&(s=!0),this.bumpSpace();var h=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?nt.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:nt.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,Dt(this.clonePosition(),this.clonePosition()));var f=this.parseMessage(e+1,t,n);if(f.err)return f;var p=this.tryParseArgumentClose(h);if(p.err)return p;o.push([l,{value:f.val,location:Dt(h,this.clonePosition())}]),a.add(l),this.bumpSpace(),l=(r=this.parseIdentifierIfPossible()).value,c=r.location}return 0===o.length?this.error("select"===t?nt.EXPECT_SELECT_ARGUMENT_SELECTOR:nt.EXPECT_PLURAL_ARGUMENT_SELECTOR,Dt(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!s?this.error(nt.MISSING_OTHER_CLAUSE,Dt(this.clonePosition(),this.clonePosition())):{val:o,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var n=1,i=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var r=!1,s=0;!this.isEOF();){var o=this.char();if(!(o>=48&&o<=57))break;r=!0,s=10*s+(o-48),this.bump()}var a=Dt(i,this.clonePosition());return r?jt(s*=n)?{val:s,err:null}:this.error(t,a):this.error(e,a)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=qt(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if(Gt(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),n=this.message.indexOf(e,t);return n>=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&nn(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),n=this.message.charCodeAt(t+(e>=65536?2:1));return null!=n?n:null},e}();function en(e){return e>=97&&e<=122||e>=65&&e<=90}function tn(e){return 45===e||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function nn(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function rn(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function sn(e){e.forEach((function(e){if(delete e.location,ft(e)||pt(e))for(var t in e.options)delete e.options[t].location,sn(e.options[t].value);else ut(e)&&vt(e.style)||(dt(e)||ht(e))&&yt(e.style)?delete e.style.location:gt(e)&&sn(e.children)}))}function on(e,t){void 0===t&&(t={}),t=st({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new Qt(e,t).parse();if(n.err){var i=SyntaxError(nt[n.err.kind]);throw i.location=n.err.location,i.originalMessage=n.err.message,i}return(null==t?void 0:t.captureLocation)||sn(n.val),n.val}function an(e,t){var n=t&&t.cache?t.cache:mn,i=t&&t.serializer?t.serializer:hn;return(t&&t.strategy?t.strategy:dn)(e,{cache:n,serializer:i})}function ln(e,t,n,i){var r,s=null==(r=i)||"number"==typeof r||"boolean"==typeof r?i:n(i),o=t.get(s);return void 0===o&&(o=e.call(this,i),t.set(s,o)),o}function cn(e,t,n){var i=Array.prototype.slice.call(arguments,3),r=n(i),s=t.get(r);return void 0===s&&(s=e.apply(this,i),t.set(r,s)),s}function un(e,t,n,i,r){return n.bind(t,e,i,r)}function dn(e,t){return un(e,this,1===e.length?ln:cn,t.cache.create(),t.serializer)}var hn=function(){return JSON.stringify(arguments)};function fn(){this.cache=Object.create(null)}fn.prototype.get=function(e){return this.cache[e]},fn.prototype.set=function(e,t){this.cache[e]=t};var pn,mn={create:function(){return new fn}},gn={variadic:function(e,t){return un(e,this,cn,t.cache.create(),t.serializer)},monadic:function(e,t){return un(e,this,ln,t.cache.create(),t.serializer)}};!function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"}(pn||(pn={}));var vn,yn=function(e){function t(t,n,i){var r=e.call(this,t)||this;return r.code=n,r.originalMessage=i,r}return tt(t,e),t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),_n=function(e){function t(t,n,i,r){return e.call(this,'Invalid values for "'.concat(t,'": "').concat(n,'". Options are "').concat(Object.keys(i).join('", "'),'"'),pn.INVALID_VALUE,r)||this}return tt(t,e),t}(yn),$n=function(e){function t(t,n,i){return e.call(this,'Value for "'.concat(t,'" must be of type ').concat(n),pn.INVALID_VALUE,i)||this}return tt(t,e),t}(yn),bn=function(e){function t(t,n){return e.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(n,'"'),pn.MISSING_VALUE,n)||this}return tt(t,e),t}(yn);function wn(e){return"function"==typeof e}function En(e,t,n,i,r,s,o){if(1===e.length&<(e[0]))return[{type:vn.literal,value:e[0].value}];for(var a=[],l=0,c=e;l<c.length;l++){var u=c[l];if(lt(u))a.push({type:vn.literal,value:u.value});else if(mt(u))"number"==typeof s&&a.push({type:vn.literal,value:n.getNumberFormat(t).format(s)});else{var d=u.value;if(!r||!(d in r))throw new bn(d,o);var h=r[d];if(ct(u))h&&"string"!=typeof h&&"number"!=typeof h||(h="string"==typeof h||"number"==typeof h?String(h):""),a.push({type:"string"==typeof h?vn.literal:vn.object,value:h});else if(dt(u)){var f="string"==typeof u.style?i.date[u.style]:yt(u.style)?u.style.parsedOptions:void 0;a.push({type:vn.literal,value:n.getDateTimeFormat(t,f).format(h)})}else if(ht(u)){f="string"==typeof u.style?i.time[u.style]:yt(u.style)?u.style.parsedOptions:i.time.medium;a.push({type:vn.literal,value:n.getDateTimeFormat(t,f).format(h)})}else if(ut(u)){(f="string"==typeof u.style?i.number[u.style]:vt(u.style)?u.style.parsedOptions:void 0)&&f.scale&&(h*=f.scale||1),a.push({type:vn.literal,value:n.getNumberFormat(t,f).format(h)})}else{if(gt(u)){var p=u.children,m=u.value,g=r[m];if(!wn(g))throw new $n(m,"function",o);var v=g(En(p,t,n,i,r,s).map((function(e){return e.value})));Array.isArray(v)||(v=[v]),a.push.apply(a,v.map((function(e){return{type:"string"==typeof e?vn.literal:vn.object,value:e}})))}if(ft(u)){if(!(y=u.options[h]||u.options.other))throw new _n(u.value,h,Object.keys(u.options),o);a.push.apply(a,En(y.value,t,n,i,r))}else if(pt(u)){var y;if(!(y=u.options["=".concat(h)])){if(!Intl.PluralRules)throw new yn('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',pn.MISSING_INTL_API,o);var _=n.getPluralRules(t,{type:u.pluralType}).select(h-(u.offset||0));y=u.options[_]||u.options.other}if(!y)throw new _n(u.value,h,Object.keys(u.options),o);a.push.apply(a,En(y.value,t,n,i,r,h-(u.offset||0)))}else;}}}return function(e){return e.length<2?e:e.reduce((function(e,t){var n=e[e.length-1];return n&&n.type===vn.literal&&t.type===vn.literal?n.value+=t.value:e.push(t),e}),[])}(a)}function xn(e,t){return t?Object.keys(e).reduce((function(n,i){var r,s;return n[i]=(r=e[i],(s=t[i])?st(st(st({},r||{}),s||{}),Object.keys(r).reduce((function(e,t){return e[t]=st(st({},r[t]),s[t]||{}),e}),{})):r),n}),st({},e)):e}function Cn(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}!function(e){e[e.literal=0]="literal",e[e.object=1]="object"}(vn||(vn={}));var Tn=function(){function e(t,n,i,r){var s=this;if(void 0===n&&(n=e.defaultLocale),this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(e){var t=s.formatToParts(e);if(1===t.length)return t[0].value;var n=t.reduce((function(e,t){return e.length&&t.type===vn.literal&&"string"==typeof e[e.length-1]?e[e.length-1]+=t.value:e.push(t.value),e}),[]);return n.length<=1?n[0]||"":n},this.formatToParts=function(e){return En(s.ast,s.locales,s.formatters,s.formats,e,void 0,s.message)},this.resolvedOptions=function(){return{locale:Intl.NumberFormat.supportedLocalesOf(s.locales)[0]}},this.getAst=function(){return s.ast},"string"==typeof t){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");this.ast=e.__parse(t,{ignoreTag:null==r?void 0:r.ignoreTag})}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=xn(e.formats,i),this.locales=n,this.formatters=r&&r.formatters||function(e){return void 0===e&&(e={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:an((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,at([void 0],t,!1)))}),{cache:Cn(e.number),strategy:gn.variadic}),getDateTimeFormat:an((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,at([void 0],t,!1)))}),{cache:Cn(e.dateTime),strategy:gn.variadic}),getPluralRules:an((function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,at([void 0],t,!1)))}),{cache:Cn(e.pluralRules),strategy:gn.variadic})}}(this.formatterCache)}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=(new Intl.NumberFormat).resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.__parse=on,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}(),Sn=Tn;const kn={},On=(e,t,n)=>n?(t in kn||(kn[t]={}),e in kn[t]||(kn[t][e]=n),n):n,Ln=(e,t)=>{if(null==t)return;if(t in kn&&e in kn[t])return kn[t][e];const n=qn(t);for(let i=0;i<n.length;i++){const r=Nn(n[i],e);if(r)return On(e,t,r)}};let An;const In=je({});function Mn(e){return e in An}function Nn(e,t){if(!Mn(e))return null;const n=function(e){return An[e]||null}(e);return function(e,t){if(null==t)return;if(t in e)return e[t];const n=t.split(".");let i=e;for(let e=0;e<n.length;e++)if("object"==typeof i){if(e>0){const t=n.slice(e,n.length).join(".");if(t in i){i=i[t];break}}i=i[n[e]]}else i=void 0;return i}(n,t)}He([In],(([e])=>Object.keys(e))),In.subscribe((e=>An=e));const Dn={};function Pn(e){return Dn[e]}function Rn(e){return null!=e&&qn(e).some((e=>{var t;return null===(t=Pn(e))||void 0===t?void 0:t.size}))}function Un(e,t){const n=Promise.all(t.map((t=>(function(e,t){Dn[e].delete(t),0===Dn[e].size&&delete Dn[e]}(e,t),t().then((e=>e.default||e))))));return n.then((t=>function(e,...t){delete kn[e],In.update((n=>(n[e]=Qe.all([n[e]||{},...t]),n)))}(e,...t)))}const Vn={};function Fn(e){if(!Rn(e))return e in Vn?Vn[e]:Promise.resolve();const t=function(e){return qn(e).map((e=>{const t=Pn(e);return[e,t?[...t]:[]]})).filter((([,e])=>e.length>0))}(e);return Vn[e]=Promise.all(t.map((([e,t])=>Un(e,t)))).then((()=>{if(Rn(e))return Fn(e);delete Vn[e]})),Vn[e]}
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */function Yn(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]])}return n}const jn={fallbackLocale:null,loadingDelay:200,formats:{number:{scientific:{notation:"scientific"},engineering:{notation:"engineering"},compactLong:{notation:"compact",compactDisplay:"long"},compactShort:{notation:"compact",compactDisplay:"short"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0};function Hn(){return jn}const zn=je(!1);let Gn;const Bn=je(null);function Wn(e){return e.split("-").map(((e,t,n)=>n.slice(0,t+1).join("-"))).reverse()}function qn(e,t=Hn().fallbackLocale){const n=Wn(e);return t?[...new Set([...n,...Wn(t)])]:n}function Zn(){return null!=Gn?Gn:void 0}Bn.subscribe((e=>{Gn=null!=e?e:void 0,"undefined"!=typeof window&&null!=e&&document.documentElement.setAttribute("lang",e)}));const Xn=Object.assign(Object.assign({},Bn),{set:e=>{if(e&&function(e){if(null==e)return;const t=qn(e);for(let e=0;e<t.length;e++){const n=t[e];if(Mn(n))return n}}(e)&&Rn(e)){const{loadingDelay:t}=Hn();let n;return"undefined"!=typeof window&&null!=Zn()&&t?n=window.setTimeout((()=>zn.set(!0)),t):zn.set(!0),Fn(e).then((()=>{Bn.set(e)})).finally((()=>{clearTimeout(n),zn.set(!1)}))}return Bn.set(e)}}),Kn=e=>{const t=Object.create(null);return n=>{const i=JSON.stringify(n);return i in t?t[i]:t[i]=e(n)}},Jn=(e,t)=>{const{formats:n}=Hn();if(e in n&&t in n[e])return n[e][t];throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`)},Qn=Kn((e=>{var{locale:t,format:n}=e,i=Yn(e,["locale","format"]);if(null==t)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return n&&(i=Jn("number",n)),new Intl.NumberFormat(t,i)})),ei=Kn((e=>{var{locale:t,format:n}=e,i=Yn(e,["locale","format"]);if(null==t)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return n?i=Jn("date",n):0===Object.keys(i).length&&(i=Jn("date","short")),new Intl.DateTimeFormat(t,i)})),ti=Kn((e=>{var{locale:t,format:n}=e,i=Yn(e,["locale","format"]);if(null==t)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return n?i=Jn("time",n):0===Object.keys(i).length&&(i=Jn("time","short")),new Intl.DateTimeFormat(t,i)})),ni=Kn(((e,t=Zn())=>new Sn(e,t,Hn().formats,{ignoreTag:Hn().ignoreTag}))),ii=(e,t={})=>{var n,i,r,s;let o=t;"object"==typeof e&&(o=e,e=o.id);const{values:a,locale:l=Zn(),default:c}=o;if(null==l)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let u=Ln(e,l);if(u){if("string"!=typeof u)return console.warn(`[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof u}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),u}else u=null!==(s=null!==(r=null===(i=(n=Hn()).handleMissingMessage)||void 0===i?void 0:i.call(n,{locale:l,id:e,defaultValue:c}))&&void 0!==r?r:c)&&void 0!==s?s:e;if(!a)return u;let d=u;try{d=ni(u,l).format(a)}catch(t){console.warn(`[svelte-i18n] Message "${e}" has syntax error:`,t.message)}return d},ri=(e,t)=>((e={})=>{var{locale:t=Zn()}=e,n=Yn(e,["locale"]);return ti(Object.assign({locale:t},n))})(t).format(e),si=(e,t)=>((e={})=>{var{locale:t=Zn()}=e,n=Yn(e,["locale"]);return ei(Object.assign({locale:t},n))})(t).format(e),oi=(e,t)=>((e={})=>{var{locale:t=Zn()}=e,n=Yn(e,["locale"]);return Qn(Object.assign({locale:t},n))})(t).format(e),ai=(e,t=Zn())=>Ln(e,t),li=He([Xn,In],(()=>ii));He([Xn],(()=>ri)),He([Xn],(()=>si)),He([Xn],(()=>oi)),He([Xn,In],(()=>ai));class ci extends Fe{constructor(e){super(),Ve(this,e,null,null,a,{})}}var ui,di={exports:{}};(ui=di).exports=function(){var e,t;function n(){return e.apply(null,arguments)}function i(t){e=t}function r(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function s(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function o(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function a(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(o(e,t))return!1;return!0}function l(e){return void 0===e}function c(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function u(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function d(e,t){var n,i=[],r=e.length;for(n=0;n<r;++n)i.push(t(e[n],n));return i}function h(e,t){for(var n in t)o(t,n)&&(e[n]=t[n]);return o(t,"toString")&&(e.toString=t.toString),o(t,"valueOf")&&(e.valueOf=t.valueOf),e}function f(e,t,n,i){return qn(e,t,n,i,!0).utc()}function p(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function m(e){return null==e._pf&&(e._pf=p()),e._pf}function g(e){if(null==e._isValid){var n=m(e),i=t.call(n.parsedDateParts,(function(e){return null!=e})),r=!isNaN(e._d.getTime())&&n.overflow<0&&!n.empty&&!n.invalidEra&&!n.invalidMonth&&!n.invalidWeekday&&!n.weekdayMismatch&&!n.nullInput&&!n.invalidFormat&&!n.userInvalidated&&(!n.meridiem||n.meridiem&&i);if(e._strict&&(r=r&&0===n.charsLeftOver&&0===n.unusedTokens.length&&void 0===n.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return r;e._isValid=r}return e._isValid}function v(e){var t=f(NaN);return null!=e?h(m(t),e):m(t).userInvalidated=!0,t}t=Array.prototype.some?Array.prototype.some:function(e){var t,n=Object(this),i=n.length>>>0;for(t=0;t<i;t++)if(t in n&&e.call(this,n[t],t,n))return!0;return!1};var y=n.momentProperties=[],_=!1;function $(e,t){var n,i,r,s=y.length;if(l(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),l(t._i)||(e._i=t._i),l(t._f)||(e._f=t._f),l(t._l)||(e._l=t._l),l(t._strict)||(e._strict=t._strict),l(t._tzm)||(e._tzm=t._tzm),l(t._isUTC)||(e._isUTC=t._isUTC),l(t._offset)||(e._offset=t._offset),l(t._pf)||(e._pf=m(t)),l(t._locale)||(e._locale=t._locale),s>0)for(n=0;n<s;n++)l(r=t[i=y[n]])||(e[i]=r);return e}function b(e){$(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===_&&(_=!0,n.updateOffset(this),_=!1)}function w(e){return e instanceof b||null!=e&&null!=e._isAMomentObject}function E(e){!1===n.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function x(e,t){var i=!0;return h((function(){if(null!=n.deprecationHandler&&n.deprecationHandler(null,e),i){var r,s,a,l=[],c=arguments.length;for(s=0;s<c;s++){if(r="","object"==typeof arguments[s]){for(a in r+="\n["+s+"] ",arguments[0])o(arguments[0],a)&&(r+=a+": "+arguments[0][a]+", ");r=r.slice(0,-2)}else r=arguments[s];l.push(r)}E(e+"\nArguments: "+Array.prototype.slice.call(l).join("")+"\n"+(new Error).stack),i=!1}return t.apply(this,arguments)}),t)}var C,T={};function S(e,t){null!=n.deprecationHandler&&n.deprecationHandler(e,t),T[e]||(E(t),T[e]=!0)}function k(e){return"undefined"!=typeof Function&&e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function O(e){var t,n;for(n in e)o(e,n)&&(k(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function L(e,t){var n,i=h({},e);for(n in t)o(t,n)&&(s(e[n])&&s(t[n])?(i[n]={},h(i[n],e[n]),h(i[n],t[n])):null!=t[n]?i[n]=t[n]:delete i[n]);for(n in e)o(e,n)&&!o(t,n)&&s(e[n])&&(i[n]=h({},i[n]));return i}function A(e){null!=e&&this.set(e)}n.suppressDeprecationWarnings=!1,n.deprecationHandler=null,C=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)o(e,t)&&n.push(t);return n};var I={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function M(e,t,n){var i=this._calendar[e]||this._calendar.sameElse;return k(i)?i.call(t,n):i}function N(e,t,n){var i=""+Math.abs(e),r=t-i.length;return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,r)).toString().substr(1)+i}var D=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,P=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,R={},U={};function V(e,t,n,i){var r=i;"string"==typeof i&&(r=function(){return this[i]()}),e&&(U[e]=r),t&&(U[t[0]]=function(){return N(r.apply(this,arguments),t[1],t[2])}),n&&(U[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function F(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function Y(e){var t,n,i=e.match(D);for(t=0,n=i.length;t<n;t++)U[i[t]]?i[t]=U[i[t]]:i[t]=F(i[t]);return function(t){var r,s="";for(r=0;r<n;r++)s+=k(i[r])?i[r].call(t,e):i[r];return s}}function j(e,t){return e.isValid()?(t=H(t,e.localeData()),R[t]=R[t]||Y(t),R[t](e)):e.localeData().invalidDate()}function H(e,t){var n=5;function i(e){return t.longDateFormat(e)||e}for(P.lastIndex=0;n>=0&&P.test(e);)e=e.replace(P,i),P.lastIndex=0,n-=1;return e}var z={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};function G(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(D).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])}var B="Invalid date";function W(){return this._invalidDate}var q="%d",Z=/\d{1,2}/;function X(e){return this._ordinal.replace("%d",e)}var K={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function J(e,t,n,i){var r=this._relativeTime[n];return k(r)?r(e,t,n,i):r.replace(/%d/i,e)}function Q(e,t){var n=this._relativeTime[e>0?"future":"past"];return k(n)?n(t):n.replace(/%s/i,t)}var ee={};function te(e,t){var n=e.toLowerCase();ee[n]=ee[n+"s"]=ee[t]=e}function ne(e){return"string"==typeof e?ee[e]||ee[e.toLowerCase()]:void 0}function ie(e){var t,n,i={};for(n in e)o(e,n)&&(t=ne(n))&&(i[t]=e[n]);return i}var re={};function se(e,t){re[e]=t}function oe(e){var t,n=[];for(t in e)o(e,t)&&n.push({unit:t,priority:re[t]});return n.sort((function(e,t){return e.priority-t.priority})),n}function ae(e){return e%4==0&&e%100!=0||e%400==0}function le(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function ce(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=le(t)),n}function ue(e,t){return function(i){return null!=i?(he(this,e,i),n.updateOffset(this,t),this):de(this,e)}}function de(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function he(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&ae(e.year())&&1===e.month()&&29===e.date()?(n=ce(n),e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),Qe(n,e.month()))):e._d["set"+(e._isUTC?"UTC":"")+t](n))}function fe(e){return k(this[e=ne(e)])?this[e]():this}function pe(e,t){if("object"==typeof e){var n,i=oe(e=ie(e)),r=i.length;for(n=0;n<r;n++)this[i[n].unit](e[i[n].unit])}else if(k(this[e=ne(e)]))return this[e](t);return this}var me,ge=/\d/,ve=/\d\d/,ye=/\d{3}/,_e=/\d{4}/,$e=/[+-]?\d{6}/,be=/\d\d?/,we=/\d\d\d\d?/,Ee=/\d\d\d\d\d\d?/,xe=/\d{1,3}/,Ce=/\d{1,4}/,Te=/[+-]?\d{1,6}/,Se=/\d+/,ke=/[+-]?\d+/,Oe=/Z|[+-]\d\d:?\d\d/gi,Le=/Z|[+-]\d\d(?::?\d\d)?/gi,Ae=/[+-]?\d+(\.\d{1,3})?/,Ie=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;function Me(e,t,n){me[e]=k(t)?t:function(e,i){return e&&n?n:t}}function Ne(e,t){return o(me,e)?me[e](t._strict,t._locale):new RegExp(De(e))}function De(e){return Pe(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,i,r){return t||n||i||r})))}function Pe(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}me={};var Re={};function Ue(e,t){var n,i,r=t;for("string"==typeof e&&(e=[e]),c(t)&&(r=function(e,n){n[t]=ce(e)}),i=e.length,n=0;n<i;n++)Re[e[n]]=r}function Ve(e,t){Ue(e,(function(e,n,i,r){i._w=i._w||{},t(e,i._w,i,r)}))}function Fe(e,t,n){null!=t&&o(Re,e)&&Re[e](t,n._a,n,e)}var Ye,je=0,He=1,Ge=2,Be=3,We=4,qe=5,Ze=6,Xe=7,Ke=8;function Je(e,t){return(e%t+t)%t}function Qe(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=Je(t,12);return e+=(t-n)/12,1===n?ae(e)?29:28:31-n%7%2}Ye=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},V("M",["MM",2],"Mo",(function(){return this.month()+1})),V("MMM",0,0,(function(e){return this.localeData().monthsShort(this,e)})),V("MMMM",0,0,(function(e){return this.localeData().months(this,e)})),te("month","M"),se("month",8),Me("M",be),Me("MM",be,ve),Me("MMM",(function(e,t){return t.monthsShortRegex(e)})),Me("MMMM",(function(e,t){return t.monthsRegex(e)})),Ue(["M","MM"],(function(e,t){t[He]=ce(e)-1})),Ue(["MMM","MMMM"],(function(e,t,n,i){var r=n._locale.monthsParse(e,i,n._strict);null!=r?t[He]=r:m(n).invalidMonth=e}));var et="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),tt="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),nt=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,it=Ie,rt=Ie;function st(e,t){return e?r(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||nt).test(t)?"format":"standalone"][e.month()]:r(this._months)?this._months:this._months.standalone}function ot(e,t){return e?r(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[nt.test(t)?"format":"standalone"][e.month()]:r(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function at(e,t,n){var i,r,s,o=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],i=0;i<12;++i)s=f([2e3,i]),this._shortMonthsParse[i]=this.monthsShort(s,"").toLocaleLowerCase(),this._longMonthsParse[i]=this.months(s,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(r=Ye.call(this._shortMonthsParse,o))?r:null:-1!==(r=Ye.call(this._longMonthsParse,o))?r:null:"MMM"===t?-1!==(r=Ye.call(this._shortMonthsParse,o))||-1!==(r=Ye.call(this._longMonthsParse,o))?r:null:-1!==(r=Ye.call(this._longMonthsParse,o))||-1!==(r=Ye.call(this._shortMonthsParse,o))?r:null}function lt(e,t,n){var i,r,s;if(this._monthsParseExact)return at.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),i=0;i<12;i++){if(r=f([2e3,i]),n&&!this._longMonthsParse[i]&&(this._longMonthsParse[i]=new RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[i]=new RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),n||this._monthsParse[i]||(s="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[i]=new RegExp(s.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[i].test(e))return i;if(n&&"MMM"===t&&this._shortMonthsParse[i].test(e))return i;if(!n&&this._monthsParse[i].test(e))return i}}function ct(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=ce(t);else if(!c(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),Qe(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function ut(e){return null!=e?(ct(this,e),n.updateOffset(this,!0),this):de(this,"Month")}function dt(){return Qe(this.year(),this.month())}function ht(e){return this._monthsParseExact?(o(this,"_monthsRegex")||pt.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(o(this,"_monthsShortRegex")||(this._monthsShortRegex=it),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)}function ft(e){return this._monthsParseExact?(o(this,"_monthsRegex")||pt.call(this),e?this._monthsStrictRegex:this._monthsRegex):(o(this,"_monthsRegex")||(this._monthsRegex=rt),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)}function pt(){function e(e,t){return t.length-e.length}var t,n,i=[],r=[],s=[];for(t=0;t<12;t++)n=f([2e3,t]),i.push(this.monthsShort(n,"")),r.push(this.months(n,"")),s.push(this.months(n,"")),s.push(this.monthsShort(n,""));for(i.sort(e),r.sort(e),s.sort(e),t=0;t<12;t++)i[t]=Pe(i[t]),r[t]=Pe(r[t]);for(t=0;t<24;t++)s[t]=Pe(s[t]);this._monthsRegex=new RegExp("^("+s.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+i.join("|")+")","i")}function mt(e){return ae(e)?366:365}V("Y",0,0,(function(){var e=this.year();return e<=9999?N(e,4):"+"+e})),V(0,["YY",2],0,(function(){return this.year()%100})),V(0,["YYYY",4],0,"year"),V(0,["YYYYY",5],0,"year"),V(0,["YYYYYY",6,!0],0,"year"),te("year","y"),se("year",1),Me("Y",ke),Me("YY",be,ve),Me("YYYY",Ce,_e),Me("YYYYY",Te,$e),Me("YYYYYY",Te,$e),Ue(["YYYYY","YYYYYY"],je),Ue("YYYY",(function(e,t){t[je]=2===e.length?n.parseTwoDigitYear(e):ce(e)})),Ue("YY",(function(e,t){t[je]=n.parseTwoDigitYear(e)})),Ue("Y",(function(e,t){t[je]=parseInt(e,10)})),n.parseTwoDigitYear=function(e){return ce(e)+(ce(e)>68?1900:2e3)};var gt=ue("FullYear",!0);function vt(){return ae(this.year())}function yt(e,t,n,i,r,s,o){var a;return e<100&&e>=0?(a=new Date(e+400,t,n,i,r,s,o),isFinite(a.getFullYear())&&a.setFullYear(e)):a=new Date(e,t,n,i,r,s,o),a}function _t(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function $t(e,t,n){var i=7+t-n;return-(7+_t(e,0,i).getUTCDay()-t)%7+i-1}function bt(e,t,n,i,r){var s,o,a=1+7*(t-1)+(7+n-i)%7+$t(e,i,r);return a<=0?o=mt(s=e-1)+a:a>mt(e)?(s=e+1,o=a-mt(e)):(s=e,o=a),{year:s,dayOfYear:o}}function wt(e,t,n){var i,r,s=$t(e.year(),t,n),o=Math.floor((e.dayOfYear()-s-1)/7)+1;return o<1?i=o+Et(r=e.year()-1,t,n):o>Et(e.year(),t,n)?(i=o-Et(e.year(),t,n),r=e.year()+1):(r=e.year(),i=o),{week:i,year:r}}function Et(e,t,n){var i=$t(e,t,n),r=$t(e+1,t,n);return(mt(e)-i+r)/7}function xt(e){return wt(e,this._week.dow,this._week.doy).week}V("w",["ww",2],"wo","week"),V("W",["WW",2],"Wo","isoWeek"),te("week","w"),te("isoWeek","W"),se("week",5),se("isoWeek",5),Me("w",be),Me("ww",be,ve),Me("W",be),Me("WW",be,ve),Ve(["w","ww","W","WW"],(function(e,t,n,i){t[i.substr(0,1)]=ce(e)}));var Ct={dow:0,doy:6};function Tt(){return this._week.dow}function St(){return this._week.doy}function kt(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")}function Ot(e){var t=wt(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")}function Lt(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}function At(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function It(e,t){return e.slice(t,7).concat(e.slice(0,t))}V("d",0,"do","day"),V("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),V("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),V("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),V("e",0,0,"weekday"),V("E",0,0,"isoWeekday"),te("day","d"),te("weekday","e"),te("isoWeekday","E"),se("day",11),se("weekday",11),se("isoWeekday",11),Me("d",be),Me("e",be),Me("E",be),Me("dd",(function(e,t){return t.weekdaysMinRegex(e)})),Me("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),Me("dddd",(function(e,t){return t.weekdaysRegex(e)})),Ve(["dd","ddd","dddd"],(function(e,t,n,i){var r=n._locale.weekdaysParse(e,i,n._strict);null!=r?t.d=r:m(n).invalidWeekday=e})),Ve(["d","e","E"],(function(e,t,n,i){t[i]=ce(e)}));var Mt="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Nt="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Dt="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Pt=Ie,Rt=Ie,Ut=Ie;function Vt(e,t){var n=r(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?It(n,this._week.dow):e?n[e.day()]:n}function Ft(e){return!0===e?It(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort}function Yt(e){return!0===e?It(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin}function jt(e,t,n){var i,r,s,o=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],i=0;i<7;++i)s=f([2e3,1]).day(i),this._minWeekdaysParse[i]=this.weekdaysMin(s,"").toLocaleLowerCase(),this._shortWeekdaysParse[i]=this.weekdaysShort(s,"").toLocaleLowerCase(),this._weekdaysParse[i]=this.weekdays(s,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(r=Ye.call(this._weekdaysParse,o))?r:null:"ddd"===t?-1!==(r=Ye.call(this._shortWeekdaysParse,o))?r:null:-1!==(r=Ye.call(this._minWeekdaysParse,o))?r:null:"dddd"===t?-1!==(r=Ye.call(this._weekdaysParse,o))||-1!==(r=Ye.call(this._shortWeekdaysParse,o))||-1!==(r=Ye.call(this._minWeekdaysParse,o))?r:null:"ddd"===t?-1!==(r=Ye.call(this._shortWeekdaysParse,o))||-1!==(r=Ye.call(this._weekdaysParse,o))||-1!==(r=Ye.call(this._minWeekdaysParse,o))?r:null:-1!==(r=Ye.call(this._minWeekdaysParse,o))||-1!==(r=Ye.call(this._weekdaysParse,o))||-1!==(r=Ye.call(this._shortWeekdaysParse,o))?r:null}function Ht(e,t,n){var i,r,s;if(this._weekdaysParseExact)return jt.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),i=0;i<7;i++){if(r=f([2e3,1]).day(i),n&&!this._fullWeekdaysParse[i]&&(this._fullWeekdaysParse[i]=new RegExp("^"+this.weekdays(r,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[i]=new RegExp("^"+this.weekdaysShort(r,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[i]=new RegExp("^"+this.weekdaysMin(r,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[i]||(s="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[i]=new RegExp(s.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[i].test(e))return i;if(n&&"ddd"===t&&this._shortWeekdaysParse[i].test(e))return i;if(n&&"dd"===t&&this._minWeekdaysParse[i].test(e))return i;if(!n&&this._weekdaysParse[i].test(e))return i}}function zt(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=Lt(e,this.localeData()),this.add(e-t,"d")):t}function Gt(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")}function Bt(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=At(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7}function Wt(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||Xt.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(o(this,"_weekdaysRegex")||(this._weekdaysRegex=Pt),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function qt(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||Xt.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(o(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Rt),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function Zt(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||Xt.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(o(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Ut),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function Xt(){function e(e,t){return t.length-e.length}var t,n,i,r,s,o=[],a=[],l=[],c=[];for(t=0;t<7;t++)n=f([2e3,1]).day(t),i=Pe(this.weekdaysMin(n,"")),r=Pe(this.weekdaysShort(n,"")),s=Pe(this.weekdays(n,"")),o.push(i),a.push(r),l.push(s),c.push(i),c.push(r),c.push(s);o.sort(e),a.sort(e),l.sort(e),c.sort(e),this._weekdaysRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+a.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function Kt(){return this.hours()%12||12}function Jt(){return this.hours()||24}function Qt(e,t){V(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function en(e,t){return t._meridiemParse}function tn(e){return"p"===(e+"").toLowerCase().charAt(0)}V("H",["HH",2],0,"hour"),V("h",["hh",2],0,Kt),V("k",["kk",2],0,Jt),V("hmm",0,0,(function(){return""+Kt.apply(this)+N(this.minutes(),2)})),V("hmmss",0,0,(function(){return""+Kt.apply(this)+N(this.minutes(),2)+N(this.seconds(),2)})),V("Hmm",0,0,(function(){return""+this.hours()+N(this.minutes(),2)})),V("Hmmss",0,0,(function(){return""+this.hours()+N(this.minutes(),2)+N(this.seconds(),2)})),Qt("a",!0),Qt("A",!1),te("hour","h"),se("hour",13),Me("a",en),Me("A",en),Me("H",be),Me("h",be),Me("k",be),Me("HH",be,ve),Me("hh",be,ve),Me("kk",be,ve),Me("hmm",we),Me("hmmss",Ee),Me("Hmm",we),Me("Hmmss",Ee),Ue(["H","HH"],Be),Ue(["k","kk"],(function(e,t,n){var i=ce(e);t[Be]=24===i?0:i})),Ue(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),Ue(["h","hh"],(function(e,t,n){t[Be]=ce(e),m(n).bigHour=!0})),Ue("hmm",(function(e,t,n){var i=e.length-2;t[Be]=ce(e.substr(0,i)),t[We]=ce(e.substr(i)),m(n).bigHour=!0})),Ue("hmmss",(function(e,t,n){var i=e.length-4,r=e.length-2;t[Be]=ce(e.substr(0,i)),t[We]=ce(e.substr(i,2)),t[qe]=ce(e.substr(r)),m(n).bigHour=!0})),Ue("Hmm",(function(e,t,n){var i=e.length-2;t[Be]=ce(e.substr(0,i)),t[We]=ce(e.substr(i))})),Ue("Hmmss",(function(e,t,n){var i=e.length-4,r=e.length-2;t[Be]=ce(e.substr(0,i)),t[We]=ce(e.substr(i,2)),t[qe]=ce(e.substr(r))}));var nn=/[ap]\.?m?\.?/i,rn=ue("Hours",!0);function sn(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}var on,an={calendar:I,longDateFormat:z,invalidDate:B,ordinal:q,dayOfMonthOrdinalParse:Z,relativeTime:K,months:et,monthsShort:tt,week:Ct,weekdays:Mt,weekdaysMin:Dt,weekdaysShort:Nt,meridiemParse:nn},ln={},cn={};function un(e,t){var n,i=Math.min(e.length,t.length);for(n=0;n<i;n+=1)if(e[n]!==t[n])return n;return i}function dn(e){return e?e.toLowerCase().replace("_","-"):e}function hn(e){for(var t,n,i,r,s=0;s<e.length;){for(t=(r=dn(e[s]).split("-")).length,n=(n=dn(e[s+1]))?n.split("-"):null;t>0;){if(i=pn(r.slice(0,t).join("-")))return i;if(n&&n.length>=t&&un(r,n)>=t-1)break;t--}s++}return on}function fn(e){return null!=e.match("^[^/\\\\]*$")}function pn(e){var t=null;if(void 0===ln[e]&&ui&&ui.exports&&fn(e))try{t=on._abbr,ze("./locale/"+e),mn(t)}catch(t){ln[e]=null}return ln[e]}function mn(e,t){var n;return e&&((n=l(t)?yn(e):gn(e,t))?on=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),on._abbr}function gn(e,t){if(null!==t){var n,i=an;if(t.abbr=e,null!=ln[e])S("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),i=ln[e]._config;else if(null!=t.parentLocale)if(null!=ln[t.parentLocale])i=ln[t.parentLocale]._config;else{if(null==(n=pn(t.parentLocale)))return cn[t.parentLocale]||(cn[t.parentLocale]=[]),cn[t.parentLocale].push({name:e,config:t}),null;i=n._config}return ln[e]=new A(L(i,t)),cn[e]&&cn[e].forEach((function(e){gn(e.name,e.config)})),mn(e),ln[e]}return delete ln[e],null}function vn(e,t){if(null!=t){var n,i,r=an;null!=ln[e]&&null!=ln[e].parentLocale?ln[e].set(L(ln[e]._config,t)):(null!=(i=pn(e))&&(r=i._config),t=L(r,t),null==i&&(t.abbr=e),(n=new A(t)).parentLocale=ln[e],ln[e]=n),mn(e)}else null!=ln[e]&&(null!=ln[e].parentLocale?(ln[e]=ln[e].parentLocale,e===mn()&&mn(e)):null!=ln[e]&&delete ln[e]);return ln[e]}function yn(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return on;if(!r(e)){if(t=pn(e))return t;e=[e]}return hn(e)}function _n(){return C(ln)}function $n(e){var t,n=e._a;return n&&-2===m(e).overflow&&(t=n[He]<0||n[He]>11?He:n[Ge]<1||n[Ge]>Qe(n[je],n[He])?Ge:n[Be]<0||n[Be]>24||24===n[Be]&&(0!==n[We]||0!==n[qe]||0!==n[Ze])?Be:n[We]<0||n[We]>59?We:n[qe]<0||n[qe]>59?qe:n[Ze]<0||n[Ze]>999?Ze:-1,m(e)._overflowDayOfYear&&(t<je||t>Ge)&&(t=Ge),m(e)._overflowWeeks&&-1===t&&(t=Xe),m(e)._overflowWeekday&&-1===t&&(t=Ke),m(e).overflow=t),e}var bn=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,wn=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,En=/Z|[+-]\d\d(?::?\d\d)?/,xn=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],Cn=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Tn=/^\/?Date\((-?\d+)/i,Sn=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,kn={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function On(e){var t,n,i,r,s,o,a=e._i,l=bn.exec(a)||wn.exec(a),c=xn.length,u=Cn.length;if(l){for(m(e).iso=!0,t=0,n=c;t<n;t++)if(xn[t][1].exec(l[1])){r=xn[t][0],i=!1!==xn[t][2];break}if(null==r)return void(e._isValid=!1);if(l[3]){for(t=0,n=u;t<n;t++)if(Cn[t][1].exec(l[3])){s=(l[2]||" ")+Cn[t][0];break}if(null==s)return void(e._isValid=!1)}if(!i&&null!=s)return void(e._isValid=!1);if(l[4]){if(!En.exec(l[4]))return void(e._isValid=!1);o="Z"}e._f=r+(s||"")+(o||""),Yn(e)}else e._isValid=!1}function Ln(e,t,n,i,r,s){var o=[An(e),tt.indexOf(t),parseInt(n,10),parseInt(i,10),parseInt(r,10)];return s&&o.push(parseInt(s,10)),o}function An(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function In(e){return e.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function Mn(e,t,n){return!e||Nt.indexOf(e)===new Date(t[0],t[1],t[2]).getDay()||(m(n).weekdayMismatch=!0,n._isValid=!1,!1)}function Nn(e,t,n){if(e)return kn[e];if(t)return 0;var i=parseInt(n,10),r=i%100;return(i-r)/100*60+r}function Dn(e){var t,n=Sn.exec(In(e._i));if(n){if(t=Ln(n[4],n[3],n[2],n[5],n[6],n[7]),!Mn(n[1],t,e))return;e._a=t,e._tzm=Nn(n[8],n[9],n[10]),e._d=_t.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),m(e).rfc2822=!0}else e._isValid=!1}function Pn(e){var t=Tn.exec(e._i);null===t?(On(e),!1===e._isValid&&(delete e._isValid,Dn(e),!1===e._isValid&&(delete e._isValid,e._strict?e._isValid=!1:n.createFromInputFallback(e)))):e._d=new Date(+t[1])}function Rn(e,t,n){return null!=e?e:null!=t?t:n}function Un(e){var t=new Date(n.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function Vn(e){var t,n,i,r,s,o=[];if(!e._d){for(i=Un(e),e._w&&null==e._a[Ge]&&null==e._a[He]&&Fn(e),null!=e._dayOfYear&&(s=Rn(e._a[je],i[je]),(e._dayOfYear>mt(s)||0===e._dayOfYear)&&(m(e)._overflowDayOfYear=!0),n=_t(s,0,e._dayOfYear),e._a[He]=n.getUTCMonth(),e._a[Ge]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=o[t]=i[t];for(;t<7;t++)e._a[t]=o[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[Be]&&0===e._a[We]&&0===e._a[qe]&&0===e._a[Ze]&&(e._nextDay=!0,e._a[Be]=0),e._d=(e._useUTC?_t:yt).apply(null,o),r=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[Be]=24),e._w&&void 0!==e._w.d&&e._w.d!==r&&(m(e).weekdayMismatch=!0)}}function Fn(e){var t,n,i,r,s,o,a,l,c;null!=(t=e._w).GG||null!=t.W||null!=t.E?(s=1,o=4,n=Rn(t.GG,e._a[je],wt(Zn(),1,4).year),i=Rn(t.W,1),((r=Rn(t.E,1))<1||r>7)&&(l=!0)):(s=e._locale._week.dow,o=e._locale._week.doy,c=wt(Zn(),s,o),n=Rn(t.gg,e._a[je],c.year),i=Rn(t.w,c.week),null!=t.d?((r=t.d)<0||r>6)&&(l=!0):null!=t.e?(r=t.e+s,(t.e<0||t.e>6)&&(l=!0)):r=s),i<1||i>Et(n,s,o)?m(e)._overflowWeeks=!0:null!=l?m(e)._overflowWeekday=!0:(a=bt(n,i,r,s,o),e._a[je]=a.year,e._dayOfYear=a.dayOfYear)}function Yn(e){if(e._f!==n.ISO_8601)if(e._f!==n.RFC_2822){e._a=[],m(e).empty=!0;var t,i,r,s,o,a,l,c=""+e._i,u=c.length,d=0;for(l=(r=H(e._f,e._locale).match(D)||[]).length,t=0;t<l;t++)s=r[t],(i=(c.match(Ne(s,e))||[])[0])&&((o=c.substr(0,c.indexOf(i))).length>0&&m(e).unusedInput.push(o),c=c.slice(c.indexOf(i)+i.length),d+=i.length),U[s]?(i?m(e).empty=!1:m(e).unusedTokens.push(s),Fe(s,i,e)):e._strict&&!i&&m(e).unusedTokens.push(s);m(e).charsLeftOver=u-d,c.length>0&&m(e).unusedInput.push(c),e._a[Be]<=12&&!0===m(e).bigHour&&e._a[Be]>0&&(m(e).bigHour=void 0),m(e).parsedDateParts=e._a.slice(0),m(e).meridiem=e._meridiem,e._a[Be]=jn(e._locale,e._a[Be],e._meridiem),null!==(a=m(e).era)&&(e._a[je]=e._locale.erasConvertYear(a,e._a[je])),Vn(e),$n(e)}else Dn(e);else On(e)}function jn(e,t,n){var i;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((i=e.isPM(n))&&t<12&&(t+=12),i||12!==t||(t=0),t):t}function Hn(e){var t,n,i,r,s,o,a=!1,l=e._f.length;if(0===l)return m(e).invalidFormat=!0,void(e._d=new Date(NaN));for(r=0;r<l;r++)s=0,o=!1,t=$({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[r],Yn(t),g(t)&&(o=!0),s+=m(t).charsLeftOver,s+=10*m(t).unusedTokens.length,m(t).score=s,a?s<i&&(i=s,n=t):(null==i||s<i||o)&&(i=s,n=t,o&&(a=!0));h(e,n||t)}function zn(e){if(!e._d){var t=ie(e._i),n=void 0===t.day?t.date:t.day;e._a=d([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],(function(e){return e&&parseInt(e,10)})),Vn(e)}}function Gn(e){var t=new b($n(Bn(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function Bn(e){var t=e._i,n=e._f;return e._locale=e._locale||yn(e._l),null===t||void 0===n&&""===t?v({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),w(t)?new b($n(t)):(u(t)?e._d=t:r(n)?Hn(e):n?Yn(e):Wn(e),g(e)||(e._d=null),e))}function Wn(e){var t=e._i;l(t)?e._d=new Date(n.now()):u(t)?e._d=new Date(t.valueOf()):"string"==typeof t?Pn(e):r(t)?(e._a=d(t.slice(0),(function(e){return parseInt(e,10)})),Vn(e)):s(t)?zn(e):c(t)?e._d=new Date(t):n.createFromInputFallback(e)}function qn(e,t,n,i,o){var l={};return!0!==t&&!1!==t||(i=t,t=void 0),!0!==n&&!1!==n||(i=n,n=void 0),(s(e)&&a(e)||r(e)&&0===e.length)&&(e=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=o,l._l=n,l._i=e,l._f=t,l._strict=i,Gn(l)}function Zn(e,t,n,i){return qn(e,t,n,i,!1)}n.createFromInputFallback=x("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))})),n.ISO_8601=function(){},n.RFC_2822=function(){};var Xn=x("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=Zn.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:v()})),Kn=x("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=Zn.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:v()}));function Jn(e,t){var n,i;if(1===t.length&&r(t[0])&&(t=t[0]),!t.length)return Zn();for(n=t[0],i=1;i<t.length;++i)t[i].isValid()&&!t[i][e](n)||(n=t[i]);return n}function Qn(){return Jn("isBefore",[].slice.call(arguments,0))}function ei(){return Jn("isAfter",[].slice.call(arguments,0))}var ti=function(){return Date.now?Date.now():+new Date},ni=["year","quarter","month","week","day","hour","minute","second","millisecond"];function ii(e){var t,n,i=!1,r=ni.length;for(t in e)if(o(e,t)&&(-1===Ye.call(ni,t)||null!=e[t]&&isNaN(e[t])))return!1;for(n=0;n<r;++n)if(e[ni[n]]){if(i)return!1;parseFloat(e[ni[n]])!==ce(e[ni[n]])&&(i=!0)}return!0}function ri(){return this._isValid}function si(){return Oi(NaN)}function oi(e){var t=ie(e),n=t.year||0,i=t.quarter||0,r=t.month||0,s=t.week||t.isoWeek||0,o=t.day||0,a=t.hour||0,l=t.minute||0,c=t.second||0,u=t.millisecond||0;this._isValid=ii(t),this._milliseconds=+u+1e3*c+6e4*l+1e3*a*60*60,this._days=+o+7*s,this._months=+r+3*i+12*n,this._data={},this._locale=yn(),this._bubble()}function ai(e){return e instanceof oi}function li(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function ci(e,t,n){var i,r=Math.min(e.length,t.length),s=Math.abs(e.length-t.length),o=0;for(i=0;i<r;i++)(n&&e[i]!==t[i]||!n&&ce(e[i])!==ce(t[i]))&&o++;return o+s}function di(e,t){V(e,0,0,(function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+N(~~(e/60),2)+t+N(~~e%60,2)}))}di("Z",":"),di("ZZ",""),Me("Z",Le),Me("ZZ",Le),Ue(["Z","ZZ"],(function(e,t,n){n._useUTC=!0,n._tzm=fi(Le,e)}));var hi=/([\+\-]|\d\d)/gi;function fi(e,t){var n,i,r=(t||"").match(e);return null===r?null:0===(i=60*(n=((r[r.length-1]||[])+"").match(hi)||["-",0,0])[1]+ce(n[2]))?0:"+"===n[0]?i:-i}function pi(e,t){var i,r;return t._isUTC?(i=t.clone(),r=(w(e)||u(e)?e.valueOf():Zn(e).valueOf())-i.valueOf(),i._d.setTime(i._d.valueOf()+r),n.updateOffset(i,!1),i):Zn(e).local()}function mi(e){return-Math.round(e._d.getTimezoneOffset())}function gi(e,t,i){var r,s=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=fi(Le,e)))return this}else Math.abs(e)<16&&!i&&(e*=60);return!this._isUTC&&t&&(r=mi(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),s!==e&&(!t||this._changeInProgress?Ni(this,Oi(e-s,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?s:mi(this)}function vi(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function yi(e){return this.utcOffset(0,e)}function _i(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(mi(this),"m")),this}function $i(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=fi(Oe,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this}function bi(e){return!!this.isValid()&&(e=e?Zn(e).utcOffset():0,(this.utcOffset()-e)%60==0)}function wi(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Ei(){if(!l(this._isDSTShifted))return this._isDSTShifted;var e,t={};return $(t,this),(t=Bn(t))._a?(e=t._isUTC?f(t._a):Zn(t._a),this._isDSTShifted=this.isValid()&&ci(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function xi(){return!!this.isValid()&&!this._isUTC}function Ci(){return!!this.isValid()&&this._isUTC}function Ti(){return!!this.isValid()&&this._isUTC&&0===this._offset}n.updateOffset=function(){};var Si=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,ki=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Oi(e,t){var n,i,r,s=e,a=null;return ai(e)?s={ms:e._milliseconds,d:e._days,M:e._months}:c(e)||!isNaN(+e)?(s={},t?s[t]=+e:s.milliseconds=+e):(a=Si.exec(e))?(n="-"===a[1]?-1:1,s={y:0,d:ce(a[Ge])*n,h:ce(a[Be])*n,m:ce(a[We])*n,s:ce(a[qe])*n,ms:ce(li(1e3*a[Ze]))*n}):(a=ki.exec(e))?(n="-"===a[1]?-1:1,s={y:Li(a[2],n),M:Li(a[3],n),w:Li(a[4],n),d:Li(a[5],n),h:Li(a[6],n),m:Li(a[7],n),s:Li(a[8],n)}):null==s?s={}:"object"==typeof s&&("from"in s||"to"in s)&&(r=Ii(Zn(s.from),Zn(s.to)),(s={}).ms=r.milliseconds,s.M=r.months),i=new oi(s),ai(e)&&o(e,"_locale")&&(i._locale=e._locale),ai(e)&&o(e,"_isValid")&&(i._isValid=e._isValid),i}function Li(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Ai(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Ii(e,t){var n;return e.isValid()&&t.isValid()?(t=pi(t,e),e.isBefore(t)?n=Ai(e,t):((n=Ai(t,e)).milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function Mi(e,t){return function(n,i){var r;return null===i||isNaN(+i)||(S(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),r=n,n=i,i=r),Ni(this,Oi(n,i),e),this}}function Ni(e,t,i,r){var s=t._milliseconds,o=li(t._days),a=li(t._months);e.isValid()&&(r=null==r||r,a&&ct(e,de(e,"Month")+a*i),o&&he(e,"Date",de(e,"Date")+o*i),s&&e._d.setTime(e._d.valueOf()+s*i),r&&n.updateOffset(e,o||a))}Oi.fn=oi.prototype,Oi.invalid=si;var Di=Mi(1,"add"),Pi=Mi(-1,"subtract");function Ri(e){return"string"==typeof e||e instanceof String}function Ui(e){return w(e)||u(e)||Ri(e)||c(e)||Fi(e)||Vi(e)||null==e}function Vi(e){var t,n,i=s(e)&&!a(e),r=!1,l=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],c=l.length;for(t=0;t<c;t+=1)n=l[t],r=r||o(e,n);return i&&r}function Fi(e){var t=r(e),n=!1;return t&&(n=0===e.filter((function(t){return!c(t)&&Ri(e)})).length),t&&n}function Yi(e){var t,n,i=s(e)&&!a(e),r=!1,l=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"];for(t=0;t<l.length;t+=1)n=l[t],r=r||o(e,n);return i&&r}function ji(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function Hi(e,t){1===arguments.length&&(arguments[0]?Ui(arguments[0])?(e=arguments[0],t=void 0):Yi(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var i=e||Zn(),r=pi(i,this).startOf("day"),s=n.calendarFormat(this,r)||"sameElse",o=t&&(k(t[s])?t[s].call(this,i):t[s]);return this.format(o||this.localeData().calendar(s,this,Zn(i)))}function zi(){return new b(this)}function Gi(e,t){var n=w(e)?e:Zn(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=ne(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())}function Bi(e,t){var n=w(e)?e:Zn(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=ne(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())}function Wi(e,t,n,i){var r=w(e)?e:Zn(e),s=w(t)?t:Zn(t);return!!(this.isValid()&&r.isValid()&&s.isValid())&&("("===(i=i||"()")[0]?this.isAfter(r,n):!this.isBefore(r,n))&&(")"===i[1]?this.isBefore(s,n):!this.isAfter(s,n))}function qi(e,t){var n,i=w(e)?e:Zn(e);return!(!this.isValid()||!i.isValid())&&("millisecond"===(t=ne(t)||"millisecond")?this.valueOf()===i.valueOf():(n=i.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))}function Zi(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function Xi(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function Ki(e,t,n){var i,r,s;if(!this.isValid())return NaN;if(!(i=pi(e,this)).isValid())return NaN;switch(r=6e4*(i.utcOffset()-this.utcOffset()),t=ne(t)){case"year":s=Ji(this,i)/12;break;case"month":s=Ji(this,i);break;case"quarter":s=Ji(this,i)/3;break;case"second":s=(this-i)/1e3;break;case"minute":s=(this-i)/6e4;break;case"hour":s=(this-i)/36e5;break;case"day":s=(this-i-r)/864e5;break;case"week":s=(this-i-r)/6048e5;break;default:s=this-i}return n?s:le(s)}function Ji(e,t){if(e.date()<t.date())return-Ji(t,e);var n=12*(t.year()-e.year())+(t.month()-e.month()),i=e.clone().add(n,"months");return-(n+(t-i<0?(t-i)/(i-e.clone().add(n-1,"months")):(t-i)/(e.clone().add(n+1,"months")-i)))||0}function Qi(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function er(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?j(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):k(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",j(n,"Z")):j(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function tr(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,i,r="moment",s="";return this.isLocal()||(r=0===this.utcOffset()?"moment.utc":"moment.parseZone",s="Z"),e="["+r+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",n="-MM-DD[T]HH:mm:ss.SSS",i=s+'[")]',this.format(e+t+n+i)}function nr(e){e||(e=this.isUtc()?n.defaultFormatUtc:n.defaultFormat);var t=j(this,e);return this.localeData().postformat(t)}function ir(e,t){return this.isValid()&&(w(e)&&e.isValid()||Zn(e).isValid())?Oi({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function rr(e){return this.from(Zn(),e)}function sr(e,t){return this.isValid()&&(w(e)&&e.isValid()||Zn(e).isValid())?Oi({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function or(e){return this.to(Zn(),e)}function ar(e){var t;return void 0===e?this._locale._abbr:(null!=(t=yn(e))&&(this._locale=t),this)}n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",n.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var lr=x("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(e){return void 0===e?this.localeData():this.locale(e)}));function cr(){return this._locale}var ur=1e3,dr=60*ur,hr=60*dr,fr=3506328*hr;function pr(e,t){return(e%t+t)%t}function mr(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-fr:new Date(e,t,n).valueOf()}function gr(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-fr:Date.UTC(e,t,n)}function vr(e){var t,i;if(void 0===(e=ne(e))||"millisecond"===e||!this.isValid())return this;switch(i=this._isUTC?gr:mr,e){case"year":t=i(this.year(),0,1);break;case"quarter":t=i(this.year(),this.month()-this.month()%3,1);break;case"month":t=i(this.year(),this.month(),1);break;case"week":t=i(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=i(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=pr(t+(this._isUTC?0:this.utcOffset()*dr),hr);break;case"minute":t=this._d.valueOf(),t-=pr(t,dr);break;case"second":t=this._d.valueOf(),t-=pr(t,ur)}return this._d.setTime(t),n.updateOffset(this,!0),this}function yr(e){var t,i;if(void 0===(e=ne(e))||"millisecond"===e||!this.isValid())return this;switch(i=this._isUTC?gr:mr,e){case"year":t=i(this.year()+1,0,1)-1;break;case"quarter":t=i(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=i(this.year(),this.month()+1,1)-1;break;case"week":t=i(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=i(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=hr-pr(t+(this._isUTC?0:this.utcOffset()*dr),hr)-1;break;case"minute":t=this._d.valueOf(),t+=dr-pr(t,dr)-1;break;case"second":t=this._d.valueOf(),t+=ur-pr(t,ur)-1}return this._d.setTime(t),n.updateOffset(this,!0),this}function _r(){return this._d.valueOf()-6e4*(this._offset||0)}function $r(){return Math.floor(this.valueOf()/1e3)}function br(){return new Date(this.valueOf())}function wr(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function Er(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function xr(){return this.isValid()?this.toISOString():null}function Cr(){return g(this)}function Tr(){return h({},m(this))}function Sr(){return m(this).overflow}function kr(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function Or(e,t){var i,r,s,o=this._eras||yn("en")._eras;for(i=0,r=o.length;i<r;++i)switch("string"==typeof o[i].since&&(s=n(o[i].since).startOf("day"),o[i].since=s.valueOf()),typeof o[i].until){case"undefined":o[i].until=1/0;break;case"string":s=n(o[i].until).startOf("day").valueOf(),o[i].until=s.valueOf()}return o}function Lr(e,t,n){var i,r,s,o,a,l=this.eras();for(e=e.toUpperCase(),i=0,r=l.length;i<r;++i)if(s=l[i].name.toUpperCase(),o=l[i].abbr.toUpperCase(),a=l[i].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(o===e)return l[i];break;case"NNNN":if(s===e)return l[i];break;case"NNNNN":if(a===e)return l[i]}else if([s,o,a].indexOf(e)>=0)return l[i]}function Ar(e,t){var i=e.since<=e.until?1:-1;return void 0===t?n(e.since).year():n(e.since).year()+(t-e.offset)*i}function Ir(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].name;if(i[e].until<=n&&n<=i[e].since)return i[e].name}return""}function Mr(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].narrow;if(i[e].until<=n&&n<=i[e].since)return i[e].narrow}return""}function Nr(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].abbr;if(i[e].until<=n&&n<=i[e].since)return i[e].abbr}return""}function Dr(){var e,t,i,r,s=this.localeData().eras();for(e=0,t=s.length;e<t;++e)if(i=s[e].since<=s[e].until?1:-1,r=this.clone().startOf("day").valueOf(),s[e].since<=r&&r<=s[e].until||s[e].until<=r&&r<=s[e].since)return(this.year()-n(s[e].since).year())*i+s[e].offset;return this.year()}function Pr(e){return o(this,"_erasNameRegex")||Hr.call(this),e?this._erasNameRegex:this._erasRegex}function Rr(e){return o(this,"_erasAbbrRegex")||Hr.call(this),e?this._erasAbbrRegex:this._erasRegex}function Ur(e){return o(this,"_erasNarrowRegex")||Hr.call(this),e?this._erasNarrowRegex:this._erasRegex}function Vr(e,t){return t.erasAbbrRegex(e)}function Fr(e,t){return t.erasNameRegex(e)}function Yr(e,t){return t.erasNarrowRegex(e)}function jr(e,t){return t._eraYearOrdinalRegex||Se}function Hr(){var e,t,n=[],i=[],r=[],s=[],o=this.eras();for(e=0,t=o.length;e<t;++e)i.push(Pe(o[e].name)),n.push(Pe(o[e].abbr)),r.push(Pe(o[e].narrow)),s.push(Pe(o[e].name)),s.push(Pe(o[e].abbr)),s.push(Pe(o[e].narrow));this._erasRegex=new RegExp("^("+s.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+i.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+n.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+r.join("|")+")","i")}function zr(e,t){V(0,[e,e.length],0,t)}function Gr(e){return Kr.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function Br(e){return Kr.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)}function Wr(){return Et(this.year(),1,4)}function qr(){return Et(this.isoWeekYear(),1,4)}function Zr(){var e=this.localeData()._week;return Et(this.year(),e.dow,e.doy)}function Xr(){var e=this.localeData()._week;return Et(this.weekYear(),e.dow,e.doy)}function Kr(e,t,n,i,r){var s;return null==e?wt(this,i,r).year:(t>(s=Et(e,i,r))&&(t=s),Jr.call(this,e,t,n,i,r))}function Jr(e,t,n,i,r){var s=bt(e,t,n,i,r),o=_t(s.year,0,s.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}function Qr(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)}V("N",0,0,"eraAbbr"),V("NN",0,0,"eraAbbr"),V("NNN",0,0,"eraAbbr"),V("NNNN",0,0,"eraName"),V("NNNNN",0,0,"eraNarrow"),V("y",["y",1],"yo","eraYear"),V("y",["yy",2],0,"eraYear"),V("y",["yyy",3],0,"eraYear"),V("y",["yyyy",4],0,"eraYear"),Me("N",Vr),Me("NN",Vr),Me("NNN",Vr),Me("NNNN",Fr),Me("NNNNN",Yr),Ue(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,i){var r=n._locale.erasParse(e,i,n._strict);r?m(n).era=r:m(n).invalidEra=e})),Me("y",Se),Me("yy",Se),Me("yyy",Se),Me("yyyy",Se),Me("yo",jr),Ue(["y","yy","yyy","yyyy"],je),Ue(["yo"],(function(e,t,n,i){var r;n._locale._eraYearOrdinalRegex&&(r=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[je]=n._locale.eraYearOrdinalParse(e,r):t[je]=parseInt(e,10)})),V(0,["gg",2],0,(function(){return this.weekYear()%100})),V(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),zr("gggg","weekYear"),zr("ggggg","weekYear"),zr("GGGG","isoWeekYear"),zr("GGGGG","isoWeekYear"),te("weekYear","gg"),te("isoWeekYear","GG"),se("weekYear",1),se("isoWeekYear",1),Me("G",ke),Me("g",ke),Me("GG",be,ve),Me("gg",be,ve),Me("GGGG",Ce,_e),Me("gggg",Ce,_e),Me("GGGGG",Te,$e),Me("ggggg",Te,$e),Ve(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,i){t[i.substr(0,2)]=ce(e)})),Ve(["gg","GG"],(function(e,t,i,r){t[r]=n.parseTwoDigitYear(e)})),V("Q",0,"Qo","quarter"),te("quarter","Q"),se("quarter",7),Me("Q",ge),Ue("Q",(function(e,t){t[He]=3*(ce(e)-1)})),V("D",["DD",2],"Do","date"),te("date","D"),se("date",9),Me("D",be),Me("DD",be,ve),Me("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),Ue(["D","DD"],Ge),Ue("Do",(function(e,t){t[Ge]=ce(e.match(be)[0])}));var es=ue("Date",!0);function ts(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")}V("DDD",["DDDD",3],"DDDo","dayOfYear"),te("dayOfYear","DDD"),se("dayOfYear",4),Me("DDD",xe),Me("DDDD",ye),Ue(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=ce(e)})),V("m",["mm",2],0,"minute"),te("minute","m"),se("minute",14),Me("m",be),Me("mm",be,ve),Ue(["m","mm"],We);var ns=ue("Minutes",!1);V("s",["ss",2],0,"second"),te("second","s"),se("second",15),Me("s",be),Me("ss",be,ve),Ue(["s","ss"],qe);var is,rs,ss=ue("Seconds",!1);for(V("S",0,0,(function(){return~~(this.millisecond()/100)})),V(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),V(0,["SSS",3],0,"millisecond"),V(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),V(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),V(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),V(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),V(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),V(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),te("millisecond","ms"),se("millisecond",16),Me("S",xe,ge),Me("SS",xe,ve),Me("SSS",xe,ye),is="SSSS";is.length<=9;is+="S")Me(is,Se);function os(e,t){t[Ze]=ce(1e3*("0."+e))}for(is="S";is.length<=9;is+="S")Ue(is,os);function as(){return this._isUTC?"UTC":""}function ls(){return this._isUTC?"Coordinated Universal Time":""}rs=ue("Milliseconds",!1),V("z",0,0,"zoneAbbr"),V("zz",0,0,"zoneName");var cs=b.prototype;function us(e){return Zn(1e3*e)}function ds(){return Zn.apply(null,arguments).parseZone()}function hs(e){return e}cs.add=Di,cs.calendar=Hi,cs.clone=zi,cs.diff=Ki,cs.endOf=yr,cs.format=nr,cs.from=ir,cs.fromNow=rr,cs.to=sr,cs.toNow=or,cs.get=fe,cs.invalidAt=Sr,cs.isAfter=Gi,cs.isBefore=Bi,cs.isBetween=Wi,cs.isSame=qi,cs.isSameOrAfter=Zi,cs.isSameOrBefore=Xi,cs.isValid=Cr,cs.lang=lr,cs.locale=ar,cs.localeData=cr,cs.max=Kn,cs.min=Xn,cs.parsingFlags=Tr,cs.set=pe,cs.startOf=vr,cs.subtract=Pi,cs.toArray=wr,cs.toObject=Er,cs.toDate=br,cs.toISOString=er,cs.inspect=tr,"undefined"!=typeof Symbol&&null!=Symbol.for&&(cs[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),cs.toJSON=xr,cs.toString=Qi,cs.unix=$r,cs.valueOf=_r,cs.creationData=kr,cs.eraName=Ir,cs.eraNarrow=Mr,cs.eraAbbr=Nr,cs.eraYear=Dr,cs.year=gt,cs.isLeapYear=vt,cs.weekYear=Gr,cs.isoWeekYear=Br,cs.quarter=cs.quarters=Qr,cs.month=ut,cs.daysInMonth=dt,cs.week=cs.weeks=kt,cs.isoWeek=cs.isoWeeks=Ot,cs.weeksInYear=Zr,cs.weeksInWeekYear=Xr,cs.isoWeeksInYear=Wr,cs.isoWeeksInISOWeekYear=qr,cs.date=es,cs.day=cs.days=zt,cs.weekday=Gt,cs.isoWeekday=Bt,cs.dayOfYear=ts,cs.hour=cs.hours=rn,cs.minute=cs.minutes=ns,cs.second=cs.seconds=ss,cs.millisecond=cs.milliseconds=rs,cs.utcOffset=gi,cs.utc=yi,cs.local=_i,cs.parseZone=$i,cs.hasAlignedHourOffset=bi,cs.isDST=wi,cs.isLocal=xi,cs.isUtcOffset=Ci,cs.isUtc=Ti,cs.isUTC=Ti,cs.zoneAbbr=as,cs.zoneName=ls,cs.dates=x("dates accessor is deprecated. Use date instead.",es),cs.months=x("months accessor is deprecated. Use month instead",ut),cs.years=x("years accessor is deprecated. Use year instead",gt),cs.zone=x("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",vi),cs.isDSTShifted=x("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Ei);var fs=A.prototype;function ps(e,t,n,i){var r=yn(),s=f().set(i,t);return r[n](s,e)}function ms(e,t,n){if(c(e)&&(t=e,e=void 0),e=e||"",null!=t)return ps(e,t,n,"month");var i,r=[];for(i=0;i<12;i++)r[i]=ps(e,i,n,"month");return r}function gs(e,t,n,i){"boolean"==typeof e?(c(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,c(t)&&(n=t,t=void 0),t=t||"");var r,s=yn(),o=e?s._week.dow:0,a=[];if(null!=n)return ps(t,(n+o)%7,i,"day");for(r=0;r<7;r++)a[r]=ps(t,(r+o)%7,i,"day");return a}function vs(e,t){return ms(e,t,"months")}function ys(e,t){return ms(e,t,"monthsShort")}function _s(e,t,n){return gs(e,t,n,"weekdays")}function $s(e,t,n){return gs(e,t,n,"weekdaysShort")}function bs(e,t,n){return gs(e,t,n,"weekdaysMin")}fs.calendar=M,fs.longDateFormat=G,fs.invalidDate=W,fs.ordinal=X,fs.preparse=hs,fs.postformat=hs,fs.relativeTime=J,fs.pastFuture=Q,fs.set=O,fs.eras=Or,fs.erasParse=Lr,fs.erasConvertYear=Ar,fs.erasAbbrRegex=Rr,fs.erasNameRegex=Pr,fs.erasNarrowRegex=Ur,fs.months=st,fs.monthsShort=ot,fs.monthsParse=lt,fs.monthsRegex=ft,fs.monthsShortRegex=ht,fs.week=xt,fs.firstDayOfYear=St,fs.firstDayOfWeek=Tt,fs.weekdays=Vt,fs.weekdaysMin=Yt,fs.weekdaysShort=Ft,fs.weekdaysParse=Ht,fs.weekdaysRegex=Wt,fs.weekdaysShortRegex=qt,fs.weekdaysMinRegex=Zt,fs.isPM=tn,fs.meridiem=sn,mn("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===ce(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),n.lang=x("moment.lang is deprecated. Use moment.locale instead.",mn),n.langData=x("moment.langData is deprecated. Use moment.localeData instead.",yn);var ws=Math.abs;function Es(){var e=this._data;return this._milliseconds=ws(this._milliseconds),this._days=ws(this._days),this._months=ws(this._months),e.milliseconds=ws(e.milliseconds),e.seconds=ws(e.seconds),e.minutes=ws(e.minutes),e.hours=ws(e.hours),e.months=ws(e.months),e.years=ws(e.years),this}function xs(e,t,n,i){var r=Oi(t,n);return e._milliseconds+=i*r._milliseconds,e._days+=i*r._days,e._months+=i*r._months,e._bubble()}function Cs(e,t){return xs(this,e,t,1)}function Ts(e,t){return xs(this,e,t,-1)}function Ss(e){return e<0?Math.floor(e):Math.ceil(e)}function ks(){var e,t,n,i,r,s=this._milliseconds,o=this._days,a=this._months,l=this._data;return s>=0&&o>=0&&a>=0||s<=0&&o<=0&&a<=0||(s+=864e5*Ss(Ls(a)+o),o=0,a=0),l.milliseconds=s%1e3,e=le(s/1e3),l.seconds=e%60,t=le(e/60),l.minutes=t%60,n=le(t/60),l.hours=n%24,o+=le(n/24),a+=r=le(Os(o)),o-=Ss(Ls(r)),i=le(a/12),a%=12,l.days=o,l.months=a,l.years=i,this}function Os(e){return 4800*e/146097}function Ls(e){return 146097*e/4800}function As(e){if(!this.isValid())return NaN;var t,n,i=this._milliseconds;if("month"===(e=ne(e))||"quarter"===e||"year"===e)switch(t=this._days+i/864e5,n=this._months+Os(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(Ls(this._months)),e){case"week":return t/7+i/6048e5;case"day":return t+i/864e5;case"hour":return 24*t+i/36e5;case"minute":return 1440*t+i/6e4;case"second":return 86400*t+i/1e3;case"millisecond":return Math.floor(864e5*t)+i;default:throw new Error("Unknown unit "+e)}}function Is(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*ce(this._months/12):NaN}function Ms(e){return function(){return this.as(e)}}var Ns=Ms("ms"),Ds=Ms("s"),Ps=Ms("m"),Rs=Ms("h"),Us=Ms("d"),Vs=Ms("w"),Fs=Ms("M"),Ys=Ms("Q"),js=Ms("y");function Hs(){return Oi(this)}function zs(e){return e=ne(e),this.isValid()?this[e+"s"]():NaN}function Gs(e){return function(){return this.isValid()?this._data[e]:NaN}}var Bs=Gs("milliseconds"),Ws=Gs("seconds"),qs=Gs("minutes"),Zs=Gs("hours"),Xs=Gs("days"),Ks=Gs("months"),Js=Gs("years");function Qs(){return le(this.days()/7)}var eo=Math.round,to={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function no(e,t,n,i,r){return r.relativeTime(t||1,!!n,e,i)}function io(e,t,n,i){var r=Oi(e).abs(),s=eo(r.as("s")),o=eo(r.as("m")),a=eo(r.as("h")),l=eo(r.as("d")),c=eo(r.as("M")),u=eo(r.as("w")),d=eo(r.as("y")),h=s<=n.ss&&["s",s]||s<n.s&&["ss",s]||o<=1&&["m"]||o<n.m&&["mm",o]||a<=1&&["h"]||a<n.h&&["hh",a]||l<=1&&["d"]||l<n.d&&["dd",l];return null!=n.w&&(h=h||u<=1&&["w"]||u<n.w&&["ww",u]),(h=h||c<=1&&["M"]||c<n.M&&["MM",c]||d<=1&&["y"]||["yy",d])[2]=t,h[3]=+e>0,h[4]=i,no.apply(null,h)}function ro(e){return void 0===e?eo:"function"==typeof e&&(eo=e,!0)}function so(e,t){return void 0!==to[e]&&(void 0===t?to[e]:(to[e]=t,"s"===e&&(to.ss=t-1),!0))}function oo(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,i,r=!1,s=to;return"object"==typeof e&&(t=e,e=!1),"boolean"==typeof e&&(r=e),"object"==typeof t&&(s=Object.assign({},to,t),null!=t.s&&null==t.ss&&(s.ss=t.s-1)),i=io(this,!r,s,n=this.localeData()),r&&(i=n.pastFuture(+this,i)),n.postformat(i)}var ao=Math.abs;function lo(e){return(e>0)-(e<0)||+e}function co(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,i,r,s,o,a,l=ao(this._milliseconds)/1e3,c=ao(this._days),u=ao(this._months),d=this.asSeconds();return d?(e=le(l/60),t=le(e/60),l%=60,e%=60,n=le(u/12),u%=12,i=l?l.toFixed(3).replace(/\.?0+$/,""):"",r=d<0?"-":"",s=lo(this._months)!==lo(d)?"-":"",o=lo(this._days)!==lo(d)?"-":"",a=lo(this._milliseconds)!==lo(d)?"-":"",r+"P"+(n?s+n+"Y":"")+(u?s+u+"M":"")+(c?o+c+"D":"")+(t||e||l?"T":"")+(t?a+t+"H":"")+(e?a+e+"M":"")+(l?a+i+"S":"")):"P0D"}var uo=oi.prototype;return uo.isValid=ri,uo.abs=Es,uo.add=Cs,uo.subtract=Ts,uo.as=As,uo.asMilliseconds=Ns,uo.asSeconds=Ds,uo.asMinutes=Ps,uo.asHours=Rs,uo.asDays=Us,uo.asWeeks=Vs,uo.asMonths=Fs,uo.asQuarters=Ys,uo.asYears=js,uo.valueOf=Is,uo._bubble=ks,uo.clone=Hs,uo.get=zs,uo.milliseconds=Bs,uo.seconds=Ws,uo.minutes=qs,uo.hours=Zs,uo.days=Xs,uo.weeks=Qs,uo.months=Ks,uo.years=Js,uo.humanize=oo,uo.toISOString=co,uo.toString=co,uo.toJSON=co,uo.locale=ar,uo.localeData=cr,uo.toIsoString=x("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",co),uo.lang=lr,V("X",0,0,"unix"),V("x",0,0,"valueOf"),Me("x",ke),Me("X",Ae),Ue("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),Ue("x",(function(e,t,n){n._d=new Date(ce(e))})),
//! moment.js
n.version="2.29.3",i(Zn),n.fn=cs,n.min=Qn,n.max=ei,n.now=ti,n.utc=f,n.unix=us,n.months=vs,n.isDate=u,n.locale=mn,n.invalid=v,n.duration=Oi,n.isMoment=w,n.weekdays=_s,n.parseZone=ds,n.localeData=yn,n.isDuration=ai,n.monthsShort=ys,n.weekdaysMin=bs,n.defineLocale=gn,n.updateLocale=vn,n.locales=_n,n.weekdaysShort=$s,n.normalizeUnits=ne,n.relativeTimeRounding=ro,n.relativeTimeThreshold=so,n.calendarFormat=ji,n.prototype=cs,n.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},n}();var hi=di.exports;function fi(e){const t=e-1;return t*t*t+1}function pi(e,{delay:n=0,duration:i=400,easing:r=t}={}){const s=+getComputedStyle(e).opacity;return{delay:n,duration:i,easing:r,css:e=>"opacity: "+e*s}}function mi(e,{delay:t=0,duration:n=400,easing:i=fi}={}){const r=getComputedStyle(e),s=+r.opacity,o=parseFloat(r.height),a=parseFloat(r.paddingTop),l=parseFloat(r.paddingBottom),c=parseFloat(r.marginTop),u=parseFloat(r.marginBottom),d=parseFloat(r.borderTopWidth),h=parseFloat(r.borderBottomWidth);return{delay:t,duration:n,easing:i,css:e=>`overflow: hidden;opacity: ${Math.min(20*e,1)*s};height: ${e*o}px;padding-top: ${e*a}px;padding-bottom: ${e*l}px;margin-top: ${e*c}px;margin-bottom: ${e*u}px;border-top-width: ${e*d}px;border-bottom-width: ${e*h}px;`}}const gi=je(!1);function vi(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function yi(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 25 25"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class _i extends Fe{constructor(e){super(),Ve(this,e,yi,vi,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function $i(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M12,4L9.91,6.09L12,8.18M4.27,3L3,4.27L7.73,9H3V15H7L12,20V13.27L16.25,17.53C15.58,18.04 14.83,18.46 14,18.7V20.77C15.38,20.45 16.63,19.82 17.68,18.96L19.73,21L21,19.73L12,10.73M19,12C19,12.94 18.8,13.82 18.46,14.64L19.97,16.15C20.62,14.91 21,13.5 21,12C21,7.72 18,4.14 14,3.23V5.29C16.89,6.15 19,8.83 19,12M16.5,12C16.5,10.23 15.5,8.71 14,7.97V10.18L16.45,12.63C16.5,12.43 16.5,12.21 16.5,12Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function bi(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 25 25"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class wi extends Fe{constructor(e){super(),Ve(this,e,bi,$i,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Ei(t){let n,i,r,s,o;return{c(){n=P("svg"),i=P("path"),r=P("path"),s=P("path"),o=P("path"),Y(i,"d","M21.6311 7.14844L20.3213 8.4887L23.3311 11.5684L20.3213 14.648L21.6311 15.9883L25.9501 11.569L25.9494 11.5684L25.9501 11.5677L21.6311 7.14844Z"),Y(i,"fill",t[2]),Y(r,"d","M10.0625 15.9883V11.5684H23.0213"),Y(r,"stroke",t[2]),Y(r,"stroke-width","2"),Y(r,"stroke-linecap","square"),Y(s,"d","M13.3015 28.1445L14.6113 26.8043L11.6016 23.7246L14.6113 20.6449L13.3015 19.3047L8.98254 23.7239L8.9832 23.7246L8.98254 23.7253L13.3015 28.1445Z"),Y(s,"fill",t[2]),Y(o,"d","M24.8701 19.3047V23.7246H11.9113"),Y(o,"stroke",t[2]),Y(o,"stroke-width","2"),Y(o,"stroke-linecap","square"),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"fill","none"),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o)},p(e,[t]){4&t&&Y(i,"fill",e[2]),4&t&&Y(r,"stroke",e[2]),4&t&&Y(s,"fill",e[2]),4&t&&Y(o,"stroke",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function xi(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="5 5 25 25"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Ci extends Fe{constructor(e){super(),Ve(this,e,xi,Ei,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Ti(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M12.3726 9.49033C12.5713 9.381 12.7944 9.33236 13.0173 9.34976C13.2402 9.36717 13.4543 9.44994 13.636 9.58898L20.2178 14.6125V10.6456C20.2178 10.3013 20.3458 9.97117 20.5737 9.72774C20.8015 9.4843 21.1105 9.34754 21.4327 9.34754C21.7548 9.34754 22.0638 9.4843 22.2917 9.72774C22.5195 9.97117 22.6475 10.3013 22.6475 10.6456V23.6262C22.6475 23.9705 22.5195 24.3007 22.2917 24.5441C22.0638 24.7875 21.7548 24.9243 21.4327 24.9243C21.1105 24.9243 20.8015 24.7875 20.5737 24.5441C20.3458 24.3007 20.2178 23.9705 20.2178 23.6262V19.6593L13.6336 24.6828C13.4519 24.821 13.2382 24.9031 13.0158 24.9202C12.7934 24.9372 12.5709 24.8885 12.3726 24.7793C12.1744 24.6702 12.0081 24.5049 11.892 24.3015C11.7758 24.0981 11.7143 23.8645 11.7142 23.6262V10.6456C11.714 10.407 11.7753 10.1729 11.8915 9.96909C12.0076 9.76528 12.1741 9.59962 12.3726 9.49033Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Si(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="5 5 25 25"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class ki extends Fe{constructor(e){super(),Ve(this,e,Si,Ti,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Oi(e){let t,n;return t=new wi({props:{size:e[0]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};1&n&&(i.size=e[0]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Li(e){let t,n;return t=new _i({props:{size:e[0]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};1&n&&(i.size=e[0]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Ai(e){let t,n,i,r,o,a,l,c,u,d,h,f;n=new Ci({props:{size:e[0]}});const p=[Li,Oi],m=[];function g(e,t){return e[1]?1:0}return o=g(e),a=m[o]=p[o](e),u=new ki({props:{size:e[0]}}),{c(){t=D("button"),Pe(n.$$.fragment),i=U(),r=D("button"),a.c(),l=U(),c=D("button"),Pe(u.$$.fragment),Y(t,"class","svelte-10vm5bb"),Y(r,"class","mute svelte-10vm5bb"),Y(c,"class","svelte-10vm5bb")},m(s,a){I(s,t,a),Re(n,t,null),I(s,i,a),I(s,r,a),m[o].m(r,null),I(s,l,a),I(s,c,a),Re(u,c,null),d=!0,h||(f=[F(t,"click",e[3]),F(r,"click",e[4]),F(c,"click",e[5])],h=!0)},p(e,[t]){const i={};1&t&&(i.size=e[0]),n.$set(i);let s=o;o=g(e),o===s?m[o].p(e,t):(Te(),Oe(m[s],1,1,(()=>{m[s]=null})),Se(),a=m[o],a?a.p(e,t):(a=m[o]=p[o](e),a.c()),ke(a,1),a.m(r,null));const l={};1&t&&(l.size=e[0]),u.$set(l)},i(e){d||(ke(n.$$.fragment,e),ke(a),ke(u.$$.fragment,e),d=!0)},o(e){Oe(n.$$.fragment,e),Oe(a),Oe(u.$$.fragment,e),d=!1},d(e){e&&M(t),Ue(n),e&&M(i),e&&M(r),m[o].d(),e&&M(l),e&&M(c),Ue(u),h=!1,s(f)}}}function Ii(e,t,n){let i;h(e,gi,(e=>n(1,i=e)));let{size:r}=t;const s=re();return e.$$set=e=>{"size"in e&&n(0,r=e.size)},[r,i,s,()=>s("replay"),()=>{w(gi,i=!i,i)},()=>s("skip")]}class Mi extends Fe{constructor(e){super(),Ve(this,e,Ii,Ai,a,{size:0})}}const Ni=je(),Di=je(!1),Pi=je(!1),Ri=je(!1);function Ui(t){let n,i,r,s=t[0].toFixed(0)+"";return{c(){n=D("div"),i=D("p"),r=R(s),Y(i,"class","svelte-bboabt"),Y(n,"class","pie-pressure svelte-bboabt"),Y(n,"style",t[1])},m(e,t){I(e,n,t),O(n,i),O(i,r)},p(e,[t]){1&t&&s!==(s=e[0].toFixed(0)+"")&&H(r,s),2&t&&Y(n,"style",e[1])},i:e,o:e,d(e){e&&M(n)}}}function Vi(e,t,n){let i,r,s;h(e,Ri,(e=>n(4,i=e))),h(e,Di,(e=>n(5,r=e))),h(e,Ni,(e=>n(6,s=e)));let{isAboutToEnd:o=!1}=t;const a=re(),l=1/60,c=s.background?s.background.replaceAll(" ","").split(",").map(Number):[0,0,0],u=[255,0,0];let d,f=15,p="";return e.$$set=e=>{"isAboutToEnd"in e&&n(2,o=e.isAboutToEnd)},e.$$.update=()=>{32&e.$$.dirty&&r&&(n(0,f=15),w(Di,r=!1,r)),1&e.$$.dirty&&!f&&a("timerEnded"),1&e.$$.dirty&&n(2,o=f<5),24&e.$$.dirty&&(i?clearInterval(d):n(3,d=setInterval((()=>{n(0,f=Math.max(f-l,0)),0===f&&(clearInterval(d),n(3,d=null));const e=Math.min(1,2.5*f/15);let t=[];for(let n=0;n<3;n++)t.push(e*c[n]+(1-e)*u[n]);n(1,p=`--gradient: conic-gradient(\n rgb(${t.join(",")}) ${f*(100/15)}%,\n rgba(var(--body), 0) ${f*(100/15)}%,\n rgba(var(--body),0 )\n );\n`)}),1e3*l)))},[f,p,o,d,i,r]}class Fi extends Fe{constructor(e){super(),Ve(this,e,Vi,Ui,a,{isAboutToEnd:2})}}function Yi(t){let n,i,r,s,o,a,l,c;return{c(){n=D("div"),i=D("div"),r=U(),s=D("div"),o=U(),a=D("div"),l=U(),c=D("div"),Y(i,"class","svelte-1chgn94"),Y(s,"class","svelte-1chgn94"),Y(a,"class","svelte-1chgn94"),Y(c,"class","svelte-1chgn94"),Y(n,"class","lds-ellipsis svelte-1chgn94"),Y(n,"style",t[0])},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o),O(n,a),O(n,l),O(n,c)},p:e,i:e,o:e,d(e){e&&M(n)}}}function ji(e,t,n){let{size:i=8}=t;const r=`--size: ${i}`;return e.$$set=e=>{"size"in e&&n(1,i=e.size)},[r,i]}class Hi extends Fe{constructor(e){super(),Ve(this,e,ji,Yi,a,{size:1})}}const zi=je([]),Gi=He(zi,(e=>e)),Bi=je(!0),Wi=je(!1);var qi=Object.getOwnPropertySymbols,Zi=Object.prototype.hasOwnProperty,Xi=Object.prototype.propertyIsEnumerable;function Ki(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var Ji=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach((function(e){i[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,i,r=Ki(e),s=1;s<arguments.length;s++){for(var o in n=Object(arguments[s]))Zi.call(n,o)&&(r[o]=n[o]);if(qi){i=qi(n);for(var a=0;a<i.length;a++)Xi.call(n,i[a])&&(r[i[a]]=n[i[a]])}}return r};function Qi(e,t){return t.encode?t.strict?encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})):encodeURIComponent(e):e}function er(e){return Array.isArray(e)?e.sort():"object"==typeof e?er(Object.keys(e)).sort((function(e,t){return Number(e)-Number(t)})).map((function(t){return e[t]})):e}var tr=function(e,t){var n=function(e){var t;switch(e.arrayFormat){case"index":return function(e,n,i){t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===i[e]&&(i[e]={}),i[e][t[1]]=n):i[e]=n};case"bracket":return function(e,n,i){t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t&&void 0!==i[e]?i[e]=[].concat(i[e],n):i[e]=n};default:return function(e,t,n){void 0!==n[e]?n[e]=[].concat(n[e],t):n[e]=t}}}(t=Ji({arrayFormat:"none"},t)),i=Object.create(null);return"string"!=typeof e?i:(e=e.trim().replace(/^(\?|#|&)/,""))?(e.split("&").forEach((function(e){var t=e.replace(/\+/g," ").split("="),r=t.shift(),s=t.length>0?t.join("="):void 0;s=void 0===s?null:decodeURIComponent(s),n(decodeURIComponent(r),s,i)})),Object.keys(i).sort().reduce((function(e,t){var n=i[t];return Boolean(n)&&"object"==typeof n&&!Array.isArray(n)?e[t]=er(n):e[t]=n,e}),Object.create(null))):i},nr=function(e,t){var n=function(e){switch(e.arrayFormat){case"index":return function(t,n,i){return null===n?[Qi(t,e),"[",i,"]"].join(""):[Qi(t,e),"[",Qi(i,e),"]=",Qi(n,e)].join("")};case"bracket":return function(t,n){return null===n?Qi(t,e):[Qi(t,e),"[]=",Qi(n,e)].join("")};default:return function(t,n){return null===n?Qi(t,e):[Qi(t,e),"=",Qi(n,e)].join("")}}}(t=Ji({encode:!0,strict:!0,arrayFormat:"none"},t));return e?Object.keys(e).sort().map((function(i){var r=e[i];if(void 0===r)return"";if(null===r)return Qi(i,t);if(Array.isArray(r)){var s=[];return r.slice().forEach((function(e){void 0!==e&&s.push(n(i,e,s.length))})),s.join("&")}return Qi(i,t)+"="+Qi(r,t)})).filter((function(e){return e.length>0})).join("&"):""};var ir=function(e,t){var n,i=t||{get:function(e){return n[e]},set:function(e,t){n[e]=t},has:function(e){return Object.prototype.hasOwnProperty.call(n,e)},delete:function(e){delete n[e]},object:n=Object.create(null)};function r(e){i.delete(e)}function s(e,t){i.set(e,t)}return{has:function(e){return i.has(e)},get:function(t){return i.has(t)||"function"!=typeof e||i.set(t,e(t)),i.get(t)},remove:r,delete:r,unset:r,set:s,put:s,add:s,getUnderlyingDataStructure:function(){return t||i.object}}},rr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},sr=function(e){return Object.getOwnPropertyNames(e).map((function(t){return e[t]}))},or=function(e,t,n){var i=void 0===t?"undefined":rr(t);if(i!==n)throw new Error("Expected "+e+" to be "+n+" but it was "+i)},ar=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Object.create(null),t=ir((function(){return Object.create(null)}));return e.on=function(e,n){or("event",e,"string"),or("listener",n,"function");var i=Math.random().toString(),r=t.get(e);return r[i]=n,function(){delete r[i]}},e.once=function(t,n){or("event",t,"string"),or("listener",n,"function");var i=e.on(t,(function(){n.apply(void 0,arguments),i()}));return i},e.emit=function(e){for(var n=arguments.length,i=Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];or("event",e,"string");var s=t.get(e);sr(s).forEach((function(e){return e.apply(void 0,i)}))},e},lr=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return e.apply(window.history,n)};function cr(e){var t=window.history.pushState,n=window.history.replaceState;window.history.replaceState=function(){for(var t=arguments.length,i=Array(t),r=0;r<t;r++)i[r]=arguments[r];lr.apply(void 0,[n].concat(i)),e()},window.history.pushState=function(){for(var n=arguments.length,i=Array(n),r=0;r<n;r++)i[r]=arguments[r];lr.apply(void 0,[t].concat(i)),e()}}function ur(){}function dr(e,t){for(var n in t)e[n]=t[n];return e}function hr(e,t){t.appendChild(e)}function fr(e,t,n){t.insertBefore(e,n)}function pr(e){e.parentNode.removeChild(e)}function mr(e,t){for(;e.firstChild;)t.appendChild(e.firstChild)}function gr(e){return document.createElement(e)}function vr(e,t){e._handlers=Object.create(null),e._bind=t._bind,e.options=t,e.root=t.root||e,e.store=t.store||e.root.store}function yr(e){for(;e&&e.length;)e.shift()()}var _r={destroy:function(e){this.destroy=ur,this.fire("destroy"),this.set=ur,this._fragment.d(!1!==e),this._fragment=null,this._state={}},get:function(){return this._state},fire:function(e,t){var n=e in this._handlers&&this._handlers[e].slice();if(n)for(var i=0;i<n.length;i+=1){var r=n[i];r.__calling||(r.__calling=!0,r.call(this,t),r.__calling=!1)}},on:function(e,t){var n=this._handlers[e]||(this._handlers[e]=[]);return n.push(t),{cancel:function(){var e=n.indexOf(t);~e&&n.splice(e,1)}}},set:function(e){this._set(dr({},e)),this.root._lock||(this.root._lock=!0,yr(this.root._beforecreate),yr(this.root._oncreate),yr(this.root._aftercreate),this.root._lock=!1)},_recompute:ur,_set:function(e){var t=this._state,n={},i=!1;for(var r in e)this._differs(e[r],t[r])&&(n[r]=i=!0);i&&(this._state=dr(dr({},t),e),this._recompute(n,this._state),this._bind&&this._bind(n,this._state),this._fragment&&(this.fire("state",{changed:n,current:this._state,previous:t}),this._fragment.p(n,this._state),this.fire("update",{changed:n,current:this._state,previous:t})))},_mount:function(e,t){this._fragment[this._fragment.i?"i":"m"](e,t||null)},_differs:function(e,t){return e!=e?t==t:e!==t||e&&"object"==typeof e||"function"==typeof e}};var $r={onClick:function(e){if(function(e){return!e.defaultPrevented&&!function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e)&&function(e){return 0===e.button}(e)}(e)){e.preventDefault();var t=this.get(),n=t.querystring,i=t.parameters,r=t.meta,s=t.hash;this.fire("navigate",{querystring:n,parameters:i,meta:r,hash:s})}}};function br(e,t){var n;function i(e){return e.parameters?wr:Er}var r=i(t),s=r(e,t);return{c:function(){s.c(),n=document.createComment("")},m:function(e,t){s.m(e,t),fr(n,e,t)},p:function(t,o){r===(r=i(o))&&s?s.p(t,o):(s.d(1),(s=r(e,o)).c(),s.m(n.parentNode,n))},d:function(e){s.d(e),e&&pr(n)}}}function wr(e,t){var n,i,r=e._slotted.default;function s(t){e.onClick(t)}return{c:function(){var e,r;n=gr("a"),e="click",r=s,n.addEventListener(e,r,!1),n.href=i=""+t.querystring+t.hash,n.className=t.className,n.style.cssText=t.style},m:function(t,i){fr(n,t,i),r&&hr(r,n),e.refs.link=n},p:function(e,t){(e.querystring||e.hash)&&i!==(i=""+t.querystring+t.hash)&&(n.href=i),e.className&&(n.className=t.className),e.style&&(n.style.cssText=t.style)},d:function(t){var i,o;t&&pr(n),r&&mr(n,r),i="click",o=s,n.removeEventListener(i,o,!1),e.refs.link===n&&(e.refs.link=null)}}}function Er(e,t){var n,i=e._slotted.default;return{c:function(){(n=gr("a")).className=t.className,n.style.cssText=t.style},m:function(e,t){fr(n,e,t),i&&hr(i,n)},p:function(e,t){e.className&&(n.className=t.className),e.style&&(n.style.cssText=t.style)},d:function(e){e&&pr(n),i&&mr(n,i)}}}function xr(e){vr(this,e),this.refs={},this._state=dr({className:"",style:"",meta:null,anchor:""},e.data),this._recompute({parametersToQuerystring:1,parameters:1,anchor:1},this._state),this._intro=!0,this._slotted=e.slots||{},this.slots={},this._fragment=br(this,this._state),e.target&&(this._fragment.c(),this._mount(e.target,e.anchor))}function Cr(e,t,n){history.replaceState(e,t,n)}function Tr(e,t,n){history.pushState(e,t,n)}function Sr(){var e=location.search;return{querystring:e,parameters:tr(e)}}function kr(e){window.addEventListener("popstate",e)}function Or(e){return"?"+nr(e)}function Lr(e){return Object.assign({},e,{data:Object.assign({},e.data,{parametersToQuerystring:Or})})}dr(xr.prototype,_r),dr(xr.prototype,$r),xr.prototype._recompute=function(e,t){var n,i;(e.parametersToQuerystring||e.parameters)&&this._differs(t.querystring,t.querystring=(0,(n=t).parametersToQuerystring)(n.parameters))&&(e.querystring=!0),e.anchor&&this._differs(t.hash,t.hash=(i=t.anchor)?"#"+i:"")&&(e.hash=!0)};var Ar=function(e){return e.replace(/^#/,"")},Ir=function(e){return e.replace(/^\?/,"")},Mr=function(){return Ar(window.location.hash)},Nr=function(e){return e&&e.scrollIntoView()},Dr=function(e){return e&&document.getElementById(e)};var Pr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=Object.assign({pushState:Tr,replaceState:Cr,currentQuerystring:Sr,onPopState:kr,onPushOrReplaceState:cr},e),n=t.pushState,i=t.replaceState,r=t.currentQuerystring,s=t.onPopState,o=t.onPushOrReplaceState,a=ar(),l=!1,c=function(){if(!l){var e=r(),t=e.querystring,n=e.parameters;a.emit("navigate",{querystring:t,parameters:n})}};function u(e){var t=e.querystring,s=e.parameters,o=e.element,c=e.meta,u=e.replace,d=e.hash,h=void 0===d?"":d;function f(e){a.emit(e,{querystring:t,parameters:s,meta:c,element:o,hash:h})}void 0===t&&(t=Or(s));var p=u?i:n;f("before navigate"),f("navigate"),l=!0;var m=r().querystring,g=Mr();Ir(m)!==Ir(t)?p(s,"",t+h):Ar(h)!==Mr()&&n(s,"",h),Mr()!==g&&Nr(Dr(Ar(h))),l=!1,f("after navigate")}return s(c),o(c),{navigate:u,Link:function(e){var t=new xr(Lr(e));return t.on("navigate",(function(e){var n=e.querystring,i=e.parameters,r=e.meta,s=e.hash;u({querystring:n,parameters:i,meta:r,element:t.refs.link,hash:s})})),t},attachQuerystringData:function(e){var t=a.on("navigate",(function(t){var n=t.parameters;e.set({querystringParameters:n})}));e.on("destroy",t),e.set({querystringParameters:r().parameters})},on:function(e,t){return a.on(e,t)},once:function(e,t){return a.once(e,t)},getCurrentQuerystring:function(){return r().querystring},getCurrentParameters:function(){return r().parameters}}};const Rr=Pr().getCurrentParameters(),Ur=je(Rr);Ur.subscribe((()=>{const e=new URLSearchParams;Object.entries(Rr).forEach((([t,n])=>e.append(t,n)));const t=e.toString();t.length>0&&history.pushState({},"",`?${t}`)}));const Vr=d(Ur),Fr={org_id:"cm8",head_id:"alana",theme:"light",language:void 0,api_base:"https://talk.crowdmedia.com",font:"",vm_version:1,time_pressure:!0,embed:!0,touch_to_start_icon:"https://talking-ui-assets-staging.s3.eu-west-1.amazonaws.com/touch.gif"},Yr=je(Fr),jr=je(!1),Hr=je(!1),zr=je(!1);let Gr=0;const Br=async(e="en-US")=>{const t=`${d(Yr).api_base}/bundle/lang/{locale}.json`.replace("{locale}",e);let n;try{const i=await fetch(t);if(n=await i.json(),"Not Found"===n?.detail)throw new Error("");In.set({[e]:n}),await Xn.set(e)}catch(t){Gr+=1,console.error(`Language ${e} not supported`),Gr<2&&await Br()}},Wr=He(Xn,(e=>"string"==typeof e));function qr(e,t,n){const i=e.slice();return i[28]=t[n],i[30]=n,i}function Zr(e){let t,n,i;return n=new Hi({props:{size:4}}),{c(){t=D("div"),Pe(n.$$.fragment),Y(t,"class","waiting-response svelte-21cta5")},m(e,r){I(e,t,r),Re(n,t,null),i=!0},i(e){i||(ke(n.$$.fragment,e),i=!0)},o(e){Oe(n.$$.fragment,e),i=!1},d(e){e&&M(t),Ue(n)}}}function Xr(t){let n;return{c(){n=D("div"),G(n,"width","35px"),G(n,"height","10px")},m(e,t){I(e,n,t)},p:e,i:e,o:e,d(e){e&&M(n)}}}function Kr(e){let t,n,i;function r(t){e[16](t)}let s={};return void 0!==e[3]&&(s.isAboutToEnd=e[3]),t=new Fi({props:s}),ce.push((()=>De(t,"isAboutToEnd",r))),t.$on("timerEnded",e[17]),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,i){const r={};!n&&8&i&&(n=!0,r.isAboutToEnd=e[3],ve((()=>n=!1))),t.$set(r)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(e){Ue(t,e)}}}function Jr(e){let t,n=e[0],i=[];for(let t=0;t<n.length;t+=1)i[t]=ns(qr(e,n,t));return{c(){t=D("div");for(let e=0;e<i.length;e+=1)i[e].c();Y(t,"class","suggestion-wrapper svelte-21cta5")},m(e,n){I(e,t,n);for(let e=0;e<i.length;e+=1)i[e].m(t,null)},p(e,r){if(10309&r){let s;for(n=e[0],s=0;s<n.length;s+=1){const o=qr(e,n,s);i[s]?i[s].p(o,r):(i[s]=ns(o),i[s].c(),i[s].m(t,null))}for(;s<i.length;s+=1)i[s].d(1);i.length=n.length}},d(e){e&&M(t),N(i,e)}}}function Qr(e){let t,n,i,r,o,a,l,c,u,d,h,f=e[30]+1+"";let p=function(e,t){return e[30]===rs?ts:es}(e),m=p(e);function g(){return e[23](e[28])}return{c(){t=D("div"),n=D("p"),i=R(f),r=U(),m.c(),o=U(),a=D("p"),l=U(),Y(n,"class","svelte-21cta5"),Y(a,"class","svelte-21cta5"),Y(t,"class","suggestion selectable svelte-21cta5"),B(t,"past-selected",e[28].selected)},m(s,c){I(s,t,c),O(t,n),O(n,i),O(t,r),m.m(t,null),O(t,o),O(t,a),O(t,l),u=!0,d||(h=[F(t,"introstart",e[19]),F(t,"outrostart",e[20]),F(t,"introend",e[21]),F(t,"outroend",e[22]),F(t,"click",g)],d=!0)},p(n,i){e=n,m.p(e,i),1&i&&B(t,"past-selected",e[28].selected)},i(e){u||(e&&ge((()=>{c||(c=Ae(t,mi,{},!0)),c.run(1)})),u=!0)},o(e){e&&(c||(c=Ae(t,mi,{},!1)),c.run(0)),u=!1},d(e){e&&M(t),m.d(),e&&c&&c.end(),d=!1,s(h)}}}function es(e){let t,n,i=e[28].text+"";return{c(){t=D("p"),n=R(i),Y(t,"class","svelte-21cta5")},m(e,i){I(e,t,i),O(t,n)},p(e,t){1&t&&i!==(i=e[28].text+"")&&H(n,i)},d(e){e&&M(t)}}}function ts(e){let t,n,i=e[28].text+"";return{c(){t=D("p"),n=R(i),Y(t,"class","svelte-21cta5")},m(i,r){I(i,t,r),O(t,n),e[18](t)},p(e,t){1&t&&i!==(i=e[28].text+"")&&H(n,i)},d(n){n&&M(t),e[18](null)}}}function ns(e){let t,n=e[28]?.text&&!e[6]&&Qr(e);return{c(){n&&n.c(),t=V()},m(e,i){n&&n.m(e,i),I(e,t,i)},p(e,i){e[28]?.text&&!e[6]?n?(n.p(e,i),65&i&&ke(n,1)):(n=Qr(e),n.c(),ke(n,1),n.m(t.parentNode,t)):n&&(Te(),Oe(n,1,1,(()=>{n=null})),Se())},d(e){n&&n.d(e),e&&M(t)}}}function is(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g=e[10]("chat-component.suggestions.title")+"",v=e[8]&&Zr();const y=[Kr,Xr],_=[];function $(e,t){return e[1]&&e[9].time_pressure&&!e[7]?0:1}r=$(e),s=_[r]=y[r](e);let w=e[0]&&Jr(e);return{c(){t=D("div"),n=D("div"),v&&v.c(),i=U(),s.c(),o=U(),a=D("div"),l=R(g),c=U(),u=D("div"),d=U(),w&&w.c(),Y(a,"class","suggestion-title svelte-21cta5"),B(a,"align-top",e[6]),B(a,"center-title",e[1]&&e[5]&&!e[4]&&!e[7]),G(u,"width","35px"),G(u,"height","10px"),Y(n,"class","suggestion-title-container svelte-21cta5"),B(n,"align-title-paused",e[1]&&e[5]&&!e[4]&&!e[7]),Y(t,"class",h=b("suggestion-container "+(e[6]?"suggestions-hidden":""))+" svelte-21cta5")},m(s,h){I(s,t,h),O(t,n),v&&v.m(n,null),O(n,i),_[r].m(n,null),O(n,o),O(n,a),O(a,l),O(n,c),O(n,u),O(t,d),w&&w.m(t,null),f=!0,p||(m=F(t,"click",e[24]),p=!0)},p(e,[c]){e[8]?v?256&c&&ke(v,1):(v=Zr(),v.c(),ke(v,1),v.m(n,i)):v&&(Te(),Oe(v,1,1,(()=>{v=null})),Se());let u=r;r=$(e),r===u?_[r].p(e,c):(Te(),Oe(_[u],1,1,(()=>{_[u]=null})),Se(),s=_[r],s?s.p(e,c):(s=_[r]=y[r](e),s.c()),ke(s,1),s.m(n,o)),(!f||1024&c)&&g!==(g=e[10]("chat-component.suggestions.title")+"")&&H(l,g),64&c&&B(a,"align-top",e[6]),178&c&&B(a,"center-title",e[1]&&e[5]&&!e[4]&&!e[7]),178&c&&B(n,"align-title-paused",e[1]&&e[5]&&!e[4]&&!e[7]),e[0]?w?w.p(e,c):(w=Jr(e),w.c(),w.m(t,null)):w&&(w.d(1),w=null),(!f||64&c&&h!==(h=b("suggestion-container "+(e[6]?"suggestions-hidden":""))+" svelte-21cta5"))&&Y(t,"class",h)},i(e){f||(ke(v),ke(s),f=!0)},o(e){Oe(v),Oe(s),f=!1},d(e){e&&M(t),v&&v.d(),_[r].d(),w&&w.d(),p=!1,m()}}}let rs=0;function ss(e,t,n){let i,r,s,o,a,l,c,u,d,f;h(e,Bi,(e=>n(14,r=e))),h(e,Hr,(e=>n(4,s=e))),h(e,Ri,(e=>n(5,o=e))),h(e,Gi,(e=>n(15,a=e))),h(e,Pi,(e=>n(7,l=e))),h(e,zr,(e=>n(8,c=e))),h(e,Yr,(e=>n(9,u=e))),h(e,li,(e=>n(10,d=e))),h(e,Wi,(e=>n(11,f=e)));const p=re(),m={next:"default",text:"default",skip:!1,selected:!1};let g,v,y,_,{currentSuggestions:$=Array(3).fill(m)}=t;const b=e=>{w(Bi,r=!0,r),p("optionSelected",e)};return e.$$set=e=>{"currentSuggestions"in e&&n(0,$=e.currentSuggestions)},e.$$.update=()=>{32768&e.$$.dirty&&(g=a[a.length-1],n(1,v="suggestions"===g?.type),v&&n(0,$=g.hook.inputs),r&&w(Pi,l=!0,l)),16434&e.$$.dirty&&n(6,i=!v||o&&!s||r),12&e.$$.dirty&&(_?y?.classList.add("blinking"):y?.classList.remove("blinking"))},[$,v,y,_,s,o,i,l,c,u,d,f,p,b,r,a,function(e){_=e,n(3,_)},()=>{p("optionSelected",$[0]),w(Ri,o=!1,o)},function(e){ce[e?"unshift":"push"]((()=>{y=e,n(2,y)}))},()=>w(Wi,f=!0,f),()=>w(Wi,f=!0,f),()=>w(Wi,f=!0,f),()=>w(Wi,f=!0,f),e=>b(e),()=>v&&w(Ri,o=!o,o)]}class os extends Fe{constructor(e){super(),Ve(this,e,ss,is,a,{currentSuggestions:0})}}const as=je(""),ls=je(!1),cs=je(!1),us=je(!1),ds=je(!1),hs=He([cs,ds],(()=>d(cs)||d(ds))),fs=He([hs,us],(()=>d(us)&&!d(hs))),ps=()=>{cs.set(!d(cs))},ms=()=>{us.set(!d(us))},{org_id:gs,head_id:vs}=d(Yr),ys=window.localStorage,_s=`chat:${window.location.origin+window.location.pathname}:${gs}:${vs}:`,$s=e=>{if(void 0!==ys){return ys.getItem(`${_s}${e}`)}},bs=(e,t)=>{void 0===ys||ys.setItem(`${_s}${e}`,t)},ws=je(""),Es=d(Yr).api_base+"/token",xs=async(e="anonymous",t="Password1")=>{let n=$s("access_token"),i=$s("user_id"),r=parseInt($s("session_id"))||0,s=!0;if("undefined"!==n&&n&&i&&"number"==typeof r){const e=1e3*JSON.parse(window.atob(n.split(".")[1])).exp;s=hi(new Date).add(15,"m").isAfter(e)}if(s){const s=await async function(e,t){let n,i,r;const s=new FormData;s.append("username",e),s.append("password",t);try{const e=await fetch(Es,{method:"POST",body:s}),t=await e.json();n=t.access_token,i=t.user_id,r=t.admin}catch(e){const t=e;t?.response?.data?.detail?ws.set(`Error:\n ${t.response.data.detail}`):ws.set(`${JSON.stringify(t)}`)}return bs("access_token",n),bs("user_id",i),{access_token:n,user_id:i,admin:r}}(e,t);s||ws.set("Error: Could not renew authentication token"),n=s.access_token,i=s.user_id,r++,bs("access_token",n),bs("user_id",i),bs("session_id",r.toString())}return e=JSON.parse(window.atob(n.split(".")[1])).username,{access_token:n,user_id:i,session_id:r}};const Cs=d(Yr).api_base+"/api/v1/asr_token";async function Ts(){let e=$s("asr_token"),t=$s("asr_region");const{access_token:n}=await xs();let i=!0;if(e&&t){const t=1e3*JSON.parse(window.atob(e.split(".")[1])).exp;i=hi(new Date).add(5,"m").isAfter(t)}if(i){const i=await async function(e){try{const t=await fetch(Cs,{headers:{Authorization:`Bearer ${e}`}}),n=await t.json(),i=n.token;return{token:i,region:n.region}}catch(e){return null}}(n);if(!i)return{token:"",region:""};e=i.token,t=i.region,bs("asr_token",e),bs("asr_region",t)}return{token:e,region:t}}let Ss,ks=!0;const Os=()=>{ks=!1,Ss.stopContinuousRecognitionAsync((()=>{Ss.stopKeywordRecognitionAsync((()=>{Ss.close()}))}))};function Ls(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M2,21L23,12L2,3V10L17,12L2,14V21Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3])},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function As(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 24 24"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Is extends Fe{constructor(e){super(),Ve(this,e,As,Ls,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Ms(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M12,2A3,3 0 0,1 15,5V11A3,3 0 0,1 12,14A3,3 0 0,1 9,11V5A3,3 0 0,1 12,2M19,11C19,14.53 16.39,17.44 13,17.93V21H11V17.93C7.61,17.44 5,14.53 5,11H7A5,5 0 0,0 12,16A5,5 0 0,0 17,11H19Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3])},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Ns(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 24 24"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Ds extends Fe{constructor(e){super(),Ve(this,e,Ns,Ms,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Ps(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M18,18H6V6H18V18Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3])},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Rs(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 24 24"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Us extends Fe{constructor(e){super(),Ve(this,e,Rs,Ps,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Vs(e){let t,n,i,r,s,o;return n=new Is({props:{size:"1.5em"}}),{c(){t=D("button"),Pe(n.$$.fragment),Y(t,"class","input-button shadow svelte-3pf3cz"),t.disabled=i=/^\s+$/.test(e[1])||!e[1]},m(i,a){I(i,t,a),Re(n,t,null),r=!0,s||(o=F(t,"click",e[19]),s=!0)},p(e,n){(!r||2&n&&i!==(i=/^\s+$/.test(e[1])||!e[1]))&&(t.disabled=i)},i(e){r||(ke(n.$$.fragment,e),r=!0)},o(e){Oe(n.$$.fragment,e),r=!1},d(e){e&&M(t),Ue(n),s=!1,o()}}}function Fs(e){let t,n,i,r,s,o;const a=[js,Ys],l=[];function c(e,t){return e[4]?0:1}return n=c(e),i=l[n]=a[n](e),{c(){t=D("button"),i.c(),Y(t,"class","input-button svelte-3pf3cz"),B(t,"recording",e[4])},m(i,a){I(i,t,a),l[n].m(t,null),r=!0,s||(o=F(t,"click",e[18]),s=!0)},p(e,r){let s=n;n=c(e),n!==s&&(Te(),Oe(l[s],1,1,(()=>{l[s]=null})),Se(),i=l[n],i||(i=l[n]=a[n](e),i.c()),ke(i,1),i.m(t,null)),16&r&&B(t,"recording",e[4])},i(e){r||(ke(i),r=!0)},o(e){Oe(i),r=!1},d(e){e&&M(t),l[n].d(),s=!1,o()}}}function Ys(e){let t,n;return t=new Ds({props:{size:"1.5em"}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function js(e){let t,n;return t=new Us({props:{size:"1.5em"}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Hs(t){let n,i,r,s,o;return{c(){n=D("button"),Y(n,"class","progress-bar svelte-3pf3cz")},m(e,i){I(e,n,i),r=!0,s||(o=F(n,"click",t[11]),s=!0)},p:e,i(e){r||(ge((()=>{i||(i=Ae(n,pi,{},!0)),i.run(1)})),r=!0)},o(e){i||(i=Ae(n,pi,{},!1)),i.run(0),r=!1},d(e){e&&M(n),e&&i&&i.end(),s=!1,o()}}}function zs(e){let t,n,i,r,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b;function w(t){e[15](t)}let E={};void 0!==e[3]&&(E.currentSuggestions=e[3]),i=new os({props:E}),ce.push((()=>De(i,"currentSuggestions",w))),i.$on("optionSelected",e[16]);const x=[Fs,Vs],C=[];function T(e,t){return 146&t&&(d=null),null==d&&(d=!((!e[7]||!/^\s+$/.test(e[1])&&e[1])&&!e[4])),d?0:1}h=T(e,-1),f=C[h]=x[h](e);let S=e[0]&&Hs(e);function k(t){e[20](t)}let L={};return void 0!==e[2]&&(L.size=e[2]),v=new Mi({props:L}),ce.push((()=>De(v,"size",k))),v.$on("skip",e[21]),v.$on("replay",e[22]),{c(){t=D("div"),n=D("div"),Pe(i.$$.fragment),o=U(),a=D("div"),l=D("input"),u=U(),f.c(),p=U(),S&&S.c(),m=U(),g=D("div"),Pe(v.$$.fragment),Y(l,"class","text-box svelte-3pf3cz"),l.disabled=e[5],Y(l,"placeholder",c=e[6]("chat-component.input-placeholder")),Y(a,"class","input-container svelte-3pf3cz"),Y(g,"class","controls svelte-3pf3cz"),B(g,"hide-chat-controls",!e[8]&&!e[9]),Y(n,"class","user-input svelte-3pf3cz"),Y(t,"class","user-input-container svelte-3pf3cz")},m(r,s){I(r,t,s),O(t,n),Re(i,n,null),O(n,o),O(n,a),O(a,l),z(l,e[1]),O(a,u),C[h].m(a,null),O(n,p),S&&S.m(n,null),O(n,m),O(n,g),Re(v,g,null),_=!0,$||(b=[F(l,"input",e[17]),F(l,"focus",e[11]),F(l,"keypress",e[14])],$=!0)},p(e,[t]){const s={};!r&&8&t&&(r=!0,s.currentSuggestions=e[3],ve((()=>r=!1))),i.$set(s),(!_||32&t)&&(l.disabled=e[5]),(!_||64&t&&c!==(c=e[6]("chat-component.input-placeholder")))&&Y(l,"placeholder",c),2&t&&l.value!==e[1]&&z(l,e[1]);let o=h;h=T(e,t),h===o?C[h].p(e,t):(Te(),Oe(C[o],1,1,(()=>{C[o]=null})),Se(),f=C[h],f?f.p(e,t):(f=C[h]=x[h](e),f.c()),ke(f,1),f.m(a,null)),e[0]?S?(S.p(e,t),1&t&&ke(S,1)):(S=Hs(e),S.c(),ke(S,1),S.m(n,m)):S&&(Te(),Oe(S,1,1,(()=>{S=null})),Se());const u={};!y&&4&t&&(y=!0,u.size=e[2],ve((()=>y=!1))),v.$set(u),768&t&&B(g,"hide-chat-controls",!e[8]&&!e[9])},i(e){_||(ke(i.$$.fragment,e),ke(f),ke(S),ke(v.$$.fragment,e),_=!0)},o(e){Oe(i.$$.fragment,e),Oe(f),Oe(S),Oe(v.$$.fragment,e),_=!1},d(e){e&&M(t),Ue(i),C[h].d(),S&&S.d(),Ue(v),$=!1,s(b)}}}function Gs(e,t,n){let i,r,s,o,a,l,c,u;h(e,as,(e=>n(1,i=e))),h(e,Ri,(e=>n(24,r=e))),h(e,Hr,(e=>n(4,s=e))),h(e,ls,(e=>n(5,o=e))),h(e,li,(e=>n(6,a=e))),h(e,jr,(e=>n(7,l=e))),h(e,hs,(e=>n(8,c=e))),h(e,fs,(e=>n(9,u=e)));let f,{isAsrCancellable:p=!1}=t,m="2em";const g=re();let v;const y=e=>{w(as,i=e,i)},_=(e,t)=>{w(as,i=e,i),w(Hr,s=!1,s),w(Ri,r=!1,r),t&&(n(0,p=!0),v=setTimeout((()=>{n(0,p=!1),E(),w(Ri,r=!1,r)}),2e3))},$=async()=>{w(Hr,s=!0,s),w(Ri,r=!0,r),await(async(e=(e=>{}),t=(e=>{}))=>{const n=await Ts(),i=window.SpeechSDK.SpeechConfig.fromAuthorizationToken(n.token,n.region);i.speechRecognitionLanguage=d(Yr).language;const r=window.SpeechSDK.AudioConfig.fromDefaultMicrophoneInput();Ss=new window.SpeechSDK.SpeechRecognizer(i,r),Ss.recognizing=(t,n)=>{n.result.text.length>0?e(n.result.text):window.SpeechSDK.ResultReason.NoMatch==n.result.reason&&Os()},Ss.recognized=(e,n)=>{window.SpeechSDK.ResultReason.RecognizedSpeech==n.result.reason&&n.result.text.length>0?(t(n.result.text,ks),Os()):window.SpeechSDK.ResultReason.NoMatch==n.result.reason&&Os()},Ss.canceled=()=>{Os()},Ss.sessionStopped=()=>{Os()},ks=!0,Ss.startContinuousRecognitionAsync()})(y,_)},b=()=>{w(Hr,s=!1,s),Os()},E=()=>{for(let e=0;e<f.length;e++){if(f[e].text===i)return void g("processUserInput")}if(null!=f[parseInt(i)-1])return w(as,i=f[parseInt(i)-1].text,i),void g("processUserInput");g("processUserInput")};return e.$$set=e=>{"isAsrCancellable"in e&&n(0,p=e.isAsrCancellable)},e.$$.update=()=>{2&e.$$.dirty&&i&&w(Ri,r=!1,r)},[p,i,m,f,s,o,a,l,c,u,g,()=>{n(0,p=!1),v&&clearTimeout(v)},$,b,e=>{"Enter"===e.code&&E()},function(e){f=e,n(3,f)},function(t){ae.call(this,e,t)},function(){i=this.value,as.set(i)},()=>s?b():$(),()=>g("processUserInput"),function(e){m=e,n(2,m)},function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)}]}class Bs extends Fe{constructor(e){super(),Ve(this,e,Gs,zs,a,{isAsrCancellable:0})}}function Ws(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"d","M12,19.2C9.5,19.2 7.29,17.92 6,16C6.03,14 10,12.9 12,12.9C14,12.9 17.97,14 18,16C16.71,17.92 14.5,19.2 12,19.2M12,5A3,3 0 0,1 15,8A3,3 0 0,1 12,11A3,3 0 0,1 9,8A3,3 0 0,1 12,5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3])},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function qs(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 24 24"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Zs extends Fe{constructor(e){super(),Ve(this,e,qs,Ws,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Xs(e){let t,n;return t=new Zs({props:{size:e[1],color:e[3]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};2&n&&(i.size=e[1]),8&n&&(i.color=e[3]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Ks(t){let n,i,r;return{c(){n=D("img"),c(n.src,i=t[0])||Y(n,"src",i),Y(n,"alt","avatar"),Y(n,"style",r=`height: ${t[1]}; width: ${t[1]};`),Y(n,"class","svelte-1ie2ift")},m(e,t){I(e,n,t)},p(e,t){1&t&&!c(n.src,i=e[0])&&Y(n,"src",i),2&t&&r!==(r=`height: ${e[1]}; width: ${e[1]};`)&&Y(n,"style",r)},i:e,o:e,d(e){e&&M(n)}}}function Js(e){let t,n,i,r;const s=[Ks,Xs],o=[];function a(e,t){return e[0]?0:1}return n=a(e),i=o[n]=s[n](e),{c(){t=D("div"),i.c(),Y(t,"style",e[2]),Y(t,"class","svelte-1ie2ift")},m(e,i){I(e,t,i),o[n].m(t,null),r=!0},p(e,[l]){let c=n;n=a(e),n===c?o[n].p(e,l):(Te(),Oe(o[c],1,1,(()=>{o[c]=null})),Se(),i=o[n],i?i.p(e,l):(i=o[n]=s[n](e),i.c()),ke(i,1),i.m(t,null)),(!r||4&l)&&Y(t,"style",e[2])},i(e){r||(ke(i),r=!0)},o(e){Oe(i),r=!1},d(e){e&&M(t),o[n].d()}}}function Qs(e,t,n){let{src:i=""}=t,{size:r="2em"}=t,{style:s}=t,{color:o="currentColor"}=t;return e.$$set=e=>{"src"in e&&n(0,i=e.src),"size"in e&&n(1,r=e.size),"style"in e&&n(2,s=e.style),"color"in e&&n(3,o=e.color)},[i,r,s,o]}class eo extends Fe{constructor(e){super(),Ve(this,e,Qs,Js,a,{src:0,size:1,style:2,color:3})}}var to=e=>e=/^\s+$/.test(e)?"‎":e.replaceAll(">",">").replaceAll("<","<").replaceAll("<br />","<br /><br />").replaceAll(">",">").replaceAll("<","<");function no(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g=to(e[6])+"";return i=new eo({props:{src:"backend"===e[0]?e[4]:e[5],size:"32px",style:"align-self: flex-start; margin: 0px 10px;"}}),{c(){t=D("div"),n=D("div"),Pe(i.$$.fragment),r=U(),s=D("div"),o=D("div"),a=D("span"),l=U(),c=D("div"),u=R(e[1]),d=U(),h=D("div"),Y(a,"class","svelte-13amlgp"),Y(o,"class","msg-text svelte-13amlgp"),B(o,"hoverable",e[3]),B(o,"bkd","backend"===e[0]),B(o,"usr","user"===e[0]),Y(c,"class","timestamp svelte-13amlgp"),B(c,"bkd","backend"===e[0]),B(c,"usr","user"===e[0]),Y(s,"class","text-container svelte-13amlgp"),B(s,"bkd","backend"===e[0]),B(s,"usr","user"===e[0]),Y(n,"class","container svelte-13amlgp"),B(n,"bkd","backend"===e[0]),B(n,"usr","user"===e[0]),Y(t,"class","msg svelte-13amlgp"),B(t,"bkd","backend"===e[0]),B(t,"usr","user"===e[0]),B(t,"sent",!e[2])},m(v,y){I(v,t,y),O(t,n),Re(i,n,null),O(n,r),O(n,s),O(s,o),O(o,a),a.innerHTML=g,O(s,l),O(s,c),O(c,u),O(s,d),O(s,h),f=!0,p||(m=F(o,"click",e[9]),p=!0)},p(e,[r]){const l={};49&r&&(l.src="backend"===e[0]?e[4]:e[5]),i.$set(l),(!f||64&r)&&g!==(g=to(e[6])+"")&&(a.innerHTML=g),8&r&&B(o,"hoverable",e[3]),1&r&&B(o,"bkd","backend"===e[0]),1&r&&B(o,"usr","user"===e[0]),(!f||2&r)&&H(u,e[1]),1&r&&B(c,"bkd","backend"===e[0]),1&r&&B(c,"usr","user"===e[0]),1&r&&B(s,"bkd","backend"===e[0]),1&r&&B(s,"usr","user"===e[0]),1&r&&B(n,"bkd","backend"===e[0]),1&r&&B(n,"usr","user"===e[0]),1&r&&B(t,"bkd","backend"===e[0]),1&r&&B(t,"usr","user"===e[0]),4&r&&B(t,"sent",!e[2])},i(e){f||(ke(i.$$.fragment,e),f=!0)},o(e){Oe(i.$$.fragment,e),f=!1},d(e){e&&M(t),Ue(i),p=!1,m()}}}function io(e,t,n){let{speaker:i}=t,{text:r=""}=t,{timestamp:s=""}=t,{is_sent:o=!0}=t,{clickable:a=!1}=t,{server_avatar:l=""}=t,{user_avatar:c=""}=t,{searchInput:u=""}=t,d="";return e.$$set=e=>{"speaker"in e&&n(0,i=e.speaker),"text"in e&&n(7,r=e.text),"timestamp"in e&&n(1,s=e.timestamp),"is_sent"in e&&n(2,o=e.is_sent),"clickable"in e&&n(3,a=e.clickable),"server_avatar"in e&&n(4,l=e.server_avatar),"user_avatar"in e&&n(5,c=e.user_avatar),"searchInput"in e&&n(8,u=e.searchInput)},e.$$.update=()=>{256&e.$$.dirty&&n(6,d=(e=>{if(e){const t=new RegExp((e=>e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"))(e),"gi");return r.replace(/(<mark class="highlight">|<\/mark>)/gim,"").replace(t,"<span class='highlight' >$&</span>")}return r})(u))},[i,s,o,a,l,c,d,r,u,function(t){ae.call(this,e,t)}]}class ro extends Fe{constructor(e){super(),Ve(this,e,io,no,a,{speaker:0,text:7,timestamp:1,is_sent:2,clickable:3,server_avatar:4,user_avatar:5,searchInput:8})}}function so(e){let t,n;return{c(){t=D("div"),n=R(e[0]),Y(t,"class","timestamp svelte-17knlnu"),G(t,"text-align","center")},m(e,i){I(e,t,i),O(t,n)},p(e,t){1&t&&H(n,e[0])},d(e){e&&M(t)}}}function oo(e){let t,n,i,r,s,o,a;const l=e[2].default,c=f(l,e,e[1],null);let u=e[0]&&so(e);return{c(){t=D("div"),n=D("div"),i=D("div"),c&&c.c(),r=U(),u&&u.c(),s=U(),o=D("div"),Y(i,"class","msg-text svelte-17knlnu"),Y(n,"class","container svelte-17knlnu"),Y(t,"class","msg svelte-17knlnu")},m(e,l){I(e,t,l),O(t,n),O(n,i),c&&c.m(i,null),O(n,r),u&&u.m(n,null),O(n,s),O(n,o),a=!0},p(e,[t]){c&&c.p&&(!a||2&t)&&g(c,l,e,e[1],a?m(l,e[1],t,null):v(e[1]),null),e[0]?u?u.p(e,t):(u=so(e),u.c(),u.m(n,s)):u&&(u.d(1),u=null)},i(e){a||(ke(c,e),a=!0)},o(e){Oe(c,e),a=!1},d(e){e&&M(t),c&&c.d(e),u&&u.d()}}}function ao(e,t,n){let{$$slots:i={},$$scope:r}=t,{timestamp:s}=t;return e.$$set=e=>{"timestamp"in e&&n(0,s=e.timestamp),"$$scope"in e&&n(1,r=e.$$scope)},[s,r,i]}class lo extends Fe{constructor(e){super(),Ve(this,e,ao,oo,a,{timestamp:0})}}function co(e){let t,n,i,r,s,o,a,l;return n=new Hi({props:{size:4}}),{c(){t=D("div"),Pe(n.$$.fragment),i=U(),r=D("img"),Y(t,"class","chat-media placeholder center-text svelte-1antikj"),B(t,"hidden",!e[2]),c(r.src,s=e[0])||Y(r,"src",s),Y(r,"alt","image"),Y(r,"class","chat-media svelte-1antikj"),B(r,"hidden",e[2])},m(s,c){I(s,t,c),Re(n,t,null),I(s,i,c),I(s,r,c),o=!0,a||(l=F(r,"load",e[4]),a=!0)},p(e,n){4&n&&B(t,"hidden",!e[2]),(!o||1&n&&!c(r.src,s=e[0]))&&Y(r,"src",s),4&n&&B(r,"hidden",e[2])},i(e){o||(ke(n.$$.fragment,e),o=!0)},o(e){Oe(n.$$.fragment,e),o=!1},d(e){e&&M(t),Ue(n),e&&M(i),e&&M(r),a=!1,l()}}}function uo(e){let t,n;return t=new lo({props:{timestamp:e[1]&&hi(e[1]).fromNow(),$$slots:{default:[co]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,[n]){const i={};2&n&&(i.timestamp=e[1]&&hi(e[1]).fromNow()),45&n&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function ho(e,t,n){let i;h(e,Wi,(e=>n(3,i=e)));let{media:r}=t,{timestamp:s}=t,o=!0;return e.$$set=e=>{"media"in e&&n(0,r=e.media),"timestamp"in e&&n(1,s=e.timestamp)},[r,s,o,i,()=>{me().then((()=>(n(2,o=!1),w(Wi,i=!0,i))))}]}class fo extends Fe{constructor(e){super(),Ve(this,e,ho,uo,a,{media:0,timestamp:1})}}function po(e,t,n){const i=e.slice();return i[29]=t[n].timestamp,i[30]=t[n].text,i[31]=t[n].type,i[32]=t[n].media,i[33]=t[n].visible,i[34]=t[n].speaker,i[35]=t[n].isSent,i[36]=t[n].url,i}function mo(e){let t,n,i,r;function s(t){e[16](t)}function a(t){e[17](t)}function l(){return e[18](e[36])}let c={searchInput:e[4],text:e[30],speaker:e[34],timestamp:hi(e[29]).fromNow(),is_sent:e[35],clickable:!!e[36]};return void 0!==e[0]&&(c.server_avatar=e[0]),void 0!==e[1]&&(c.user_avatar=e[1]),t=new ro({props:c}),ce.push((()=>De(t,"server_avatar",s))),ce.push((()=>De(t,"user_avatar",a))),t.$on("click",(function(){o(e[36]&&l)&&(e[36]&&l).apply(this,arguments)})),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),r=!0},p(r,s){e=r;const o={};16&s[0]&&(o.searchInput=e[4]),64&s[0]&&(o.text=e[30]),64&s[0]&&(o.speaker=e[34]),64&s[0]&&(o.timestamp=hi(e[29]).fromNow()),64&s[0]&&(o.is_sent=e[35]),64&s[0]&&(o.clickable=!!e[36]),!n&&1&s[0]&&(n=!0,o.server_avatar=e[0],ve((()=>n=!1))),!i&&2&s[0]&&(i=!0,o.user_avatar=e[1],ve((()=>i=!1))),t.$set(o)},i(e){r||(ke(t.$$.fragment,e),r=!0)},o(e){Oe(t.$$.fragment,e),r=!1},d(e){Ue(t,e)}}}function go(e){let t,n;return t=new fo({props:{media:e[32],timestamp:e[29]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};64&n[0]&&(i.media=e[32]),64&n[0]&&(i.timestamp=e[29]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function vo(e){let t,n;return t=new lo({props:{timestamp:e[29]&&hi(e[29]).fromNow(),$$slots:{default:[yo]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};64&n[0]&&(i.timestamp=e[29]&&hi(e[29]).fromNow()),64&n[0]|256&n[1]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function yo(e){let t,n,i=to(e[30])+"";return{c(){t=new q,n=V(),t.a=n},m(e,r){t.m(i,e,r),I(e,n,r)},p(e,n){64&n[0]&&i!==(i=to(e[30])+"")&&t.p(i)},d(e){e&&M(n),e&&t.d()}}}function _o(e){let t,n,i,r;const s=[vo,go,mo],o=[];function a(e,t){return"info"===e[31]?0:"media"===e[31]?1:e[33]?2:-1}return~(t=a(e))&&(n=o[t]=s[t](e)),{c(){n&&n.c(),i=V()},m(e,n){~t&&o[t].m(e,n),I(e,i,n),r=!0},p(e,r){let l=t;t=a(e),t===l?~t&&o[t].p(e,r):(n&&(Te(),Oe(o[l],1,1,(()=>{o[l]=null})),Se()),~t?(n=o[t],n?n.p(e,r):(n=o[t]=s[t](e),n.c()),ke(n,1),n.m(i.parentNode,i)):n=null)},i(e){r||(ke(n),r=!0)},o(e){Oe(n),r=!1},d(e){~t&&o[t].d(e),e&&M(i)}}}function $o(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b,w;s=new eo({props:{src:e[3],size:"1.0em",style:"margin-right: 1em;"}});let E=e[6],x=[];for(let t=0;t<E.length;t+=1)x[t]=_o(po(e,E,t));const C=e=>Oe(x[e],1,1,(()=>{x[e]=null}));return _=new Bs({}),_.$on("userInput",e[20]),_.$on("skip",e[21]),_.$on("replay",e[22]),_.$on("optionSelected",e[10]),_.$on("processUserInput",e[11]),{c(){t=D("div"),n=D("div"),i=D("div"),r=D("div"),Pe(s.$$.fragment),o=U(),a=D("div"),l=R(e[2]),c=U(),u=D("div"),d=D("input"),f=U(),p=D("div"),m=D("div");for(let e=0;e<x.length;e+=1)x[e].c();g=U(),v=D("div"),y=U(),Pe(_.$$.fragment),G(a,"font-size","small"),G(r,"display","flex"),G(r,"margin-bottom","0.5em"),Y(r,"class","hide-phone"),Y(d,"class","search-field svelte-6nw66v"),Y(d,"placeholder",h=e[9]("chat-component.search-bar.placeholder")),Y(d,"type","search"),Y(u,"class","search svelte-6nw66v"),Y(i,"class","chat-header svelte-6nw66v"),Y(n,"class","header-container svelte-6nw66v"),B(n,"hide-component",e[7]||e[8]),G(v,"height","1px"),Y(m,"class","msgs svelte-6nw66v"),Y(p,"class","msgs-container svelte-6nw66v"),B(p,"hide-component",e[7]||e[8]),Y(t,"class","chat-container svelte-6nw66v")},m(h,E){I(h,t,E),O(t,n),O(n,i),O(i,r),Re(s,r,null),O(r,o),O(r,a),O(a,l),O(i,c),O(i,u),O(u,d),z(d,e[4]),O(t,f),O(t,p),O(p,m);for(let e=0;e<x.length;e+=1)x[e].m(m,null);O(m,g),O(m,v),e[19](p),O(t,y),Re(_,t,null),$=!0,b||(w=F(d,"input",e[15]),b=!0)},p(e,t){const i={};if(8&t[0]&&(i.src=e[3]),s.$set(i),(!$||4&t[0])&&H(l,e[2]),(!$||512&t[0]&&h!==(h=e[9]("chat-component.search-bar.placeholder")))&&Y(d,"placeholder",h),16&t[0]&&z(d,e[4]),384&t[0]&&B(n,"hide-component",e[7]||e[8]),4179&t[0]){let n;for(E=e[6],n=0;n<E.length;n+=1){const i=po(e,E,n);x[n]?(x[n].p(i,t),ke(x[n],1)):(x[n]=_o(i),x[n].c(),ke(x[n],1),x[n].m(m,g))}for(Te(),n=E.length;n<x.length;n+=1)C(n);Se()}384&t[0]&&B(p,"hide-component",e[7]||e[8])},i(e){if(!$){ke(s.$$.fragment,e);for(let e=0;e<E.length;e+=1)ke(x[e]);ke(_.$$.fragment,e),$=!0}},o(e){Oe(s.$$.fragment,e),x=x.filter(Boolean);for(let e=0;e<x.length;e+=1)Oe(x[e]);Oe(_.$$.fragment,e),$=!1},d(n){n&&M(t),Ue(s),N(x,n),e[19](null),Ue(_),b=!1,w()}}}function bo(e,t,n){let i,r,s,o,a,l,c;h(e,Gi,(e=>n(13,r=e))),h(e,as,(e=>n(24,s=e))),h(e,Wi,(e=>n(14,o=e))),h(e,hs,(e=>n(7,a=e))),h(e,fs,(e=>n(8,l=e))),h(e,li,(e=>n(9,c=e)));let{name:u}=t,{server_avatar:d=""}=t,{user_avatar:f=""}=t,{header_avatar:p=""}=t;const m=re();let g;function v(){g&&g.scrollTop<g.scrollHeight&&n(5,g.scrollTop=g.scrollHeight+1e3,g)}ne((async()=>{await document.fonts.ready.then((()=>{v(),"smooth"!==g.style.scrollBehavior&&n(5,g.style.scrollBehavior="smooth",g),setTimeout((()=>{v()}),100)}));let e=r.length;Gi.subscribe((t=>{e!==r.length&&r[r.length-1]?.visible&&(w(Wi,o=!0,o),e=t.length)}))}));const y=e=>{m("play",e)};let _="";return e.$$set=e=>{"name"in e&&n(2,u=e.name),"server_avatar"in e&&n(0,d=e.server_avatar),"user_avatar"in e&&n(1,f=e.user_avatar),"header_avatar"in e&&n(3,p=e.header_avatar)},e.$$.update=()=>{16384&e.$$.dirty[0]&&o&&(setTimeout(v,50),w(Wi,o=!1,o)),8208&e.$$.dirty[0]&&n(6,i=r.filter((({text:e})=>!_||!e||e.toLowerCase().includes(_.toLowerCase()))))},[d,f,u,p,_,g,i,a,l,c,e=>{const t=e.detail.text;m("userInput",t),w(Wi,o=!0,o)},()=>{s&&!/^\s+$/.test(s)&&m("userInput",s),w(as,s="",s)},y,r,o,function(){_=this.value,n(4,_)},function(e){d=e,n(0,d)},function(e){f=e,n(1,f)},e=>y(e),function(e){ce[e?"unshift":"push"]((()=>{g=e,n(5,g)}))},function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)}]}class wo extends Fe{constructor(e){super(),Ve(this,e,bo,$o,a,{name:2,server_avatar:0,user_avatar:1,header_avatar:3},null,[-1,-1])}}function Eo(e){let t,n,i,r,o,a;const l=e[3].default,c=f(l,e,e[2],null);return{c(){t=D("div"),n=D("div"),c&&c.c(),Y(n,"class","container svelte-1how3gs"),Y(t,"class","modal center-text full-screen svelte-1how3gs")},m(i,s){I(i,t,s),O(t,n),c&&c.m(n,null),r=!0,o||(a=[F(window,"keydown",e[0]),F(n,"keydown",e[0])],o=!0)},p(e,[t]){c&&c.p&&(!r||4&t)&&g(c,l,e,e[2],r?m(l,e[2],t,null):v(e[2]),null)},i(e){r||(ke(c,e),ge((()=>{i||(i=Ae(t,pi,{},!0)),i.run(1)})),r=!0)},o(e){Oe(c,e),i||(i=Ae(t,pi,{},!1)),i.run(0),r=!1},d(e){e&&M(t),c&&c.d(e),e&&i&&i.end(),o=!1,s(a)}}}function xo(e,t,n){let{$$slots:i={},$$scope:r}=t,{onEscCb:s=(()=>null)}=t;return e.$$set=e=>{"onEscCb"in e&&n(1,s=e.onEscCb),"$$scope"in e&&n(2,r=e.$$scope)},[e=>{"Escape"===e.key&&s()},s,r,i]}class Co extends Fe{constructor(e){super(),Ve(this,e,xo,Eo,a,{onEscCb:1})}}function To(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b=e[0]("microphone-access.title")+"",w=e[0]("microphone-access.paragraph-1")+"",E=e[0]("microphone-access.paragraph-2")+"",x=e[0]("microphone-access.link")+"",C=e[0]("microphone-access.paragraph-3")+"",T=e[0]("microphone-access.exit")+"";return{c(){t=D("h2"),n=R(b),i=U(),r=D("p"),s=R(w),o=U(),a=D("p"),l=R(E),c=U(),u=D("a"),d=R(x),h=R("\n ."),f=U(),p=D("p"),m=R(C),g=U(),v=D("button"),y=R(T),Y(t,"class","svelte-na186b"),Y(r,"class","svelte-na186b"),Y(u,"href","https://csi-covid19.github.io/Technology/enable-microphone.pdf"),Y(u,"target","_blank"),Y(u,"rel","noreferrer noopener"),Y(a,"class","svelte-na186b"),Y(p,"class","svelte-na186b"),Y(v,"class","svelte-na186b")},m(b,w){I(b,t,w),O(t,n),I(b,i,w),I(b,r,w),O(r,s),I(b,o,w),I(b,a,w),O(a,l),O(a,c),O(a,u),O(u,d),O(a,h),I(b,f,w),I(b,p,w),O(p,m),I(b,g,w),I(b,v,w),O(v,y),_||($=F(v,"click",e[1]),_=!0)},p(e,t){1&t&&b!==(b=e[0]("microphone-access.title")+"")&&H(n,b),1&t&&w!==(w=e[0]("microphone-access.paragraph-1")+"")&&H(s,w),1&t&&E!==(E=e[0]("microphone-access.paragraph-2")+"")&&H(l,E),1&t&&x!==(x=e[0]("microphone-access.link")+"")&&H(d,x),1&t&&C!==(C=e[0]("microphone-access.paragraph-3")+"")&&H(m,C),1&t&&T!==(T=e[0]("microphone-access.exit")+"")&&H(y,T)},d(e){e&&M(t),e&&M(i),e&&M(r),e&&M(o),e&&M(a),e&&M(f),e&&M(p),e&&M(g),e&&M(v),_=!1,$()}}}function So(e){let t,n;return t=new Co({props:{onEscCb:e[1],$$slots:{default:[To]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,[n]){const i={};17&n&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function ko(e,t,n){let i,r;h(e,gi,(e=>n(3,i=e))),h(e,li,(e=>n(0,r=e)));let{asrModal:s=!0}=t;return e.$$set=e=>{"asrModal"in e&&n(2,s=e.asrModal)},[r,()=>{n(2,s=!1),w(gi,i=!1,i)},s]}class Oo extends Fe{constructor(e){super(),Ve(this,e,ko,So,a,{asrModal:2})}}function Lo(t){let n,i,r,s,o,a,l;return{c(){n=P("svg"),i=P("path"),r=P("path"),s=P("path"),o=P("path"),a=P("path"),l=P("path"),Y(i,"d","M9.93333 9.5333C11.7333 9.5333 13.1333 8.06664 13.1333 6.26664C13.1333 4.46663 11.6667 3.06664 9.86666 3.06664C8.06666 3.06664 6.66666 4.5333 6.66666 6.26664C6.66666 8.06664 8.13333 9.5333 9.93333 9.5333ZM9.86666 4.39997C9.93333 4.39997 9.93333 4.39997 9.86666 4.39997C10.9333 4.39997 11.8 5.26664 11.8 6.3333C11.8 7.39997 10.9333 8.19997 9.86666 8.19997C8.8 8.19997 8 7.3333 8 6.3333C8 5.26664 8.86666 4.39997 9.86666 4.39997V4.39997Z"),Y(i,"fill",t[2]),Y(i,"fill-opacity","0.5"),Y(r,"d","M19.8 9.13337C18.5333 8.00004 16.8667 7.40004 15.1333 7.4667H14.6C14.4667 8.00004 14.2667 8.4667 14 8.8667C14.4 8.80004 14.7333 8.80004 15.1333 8.80004C16.4 8.73337 17.6667 9.13337 18.6667 9.8667V14.6667H20V9.33337L19.8 9.13337Z"),Y(r,"fill","black"),Y(r,"fill-opacity","0.5"),Y(s,"d","M13.6 3.20006C13.9333 2.40006 14.8667 2.00006 15.7333 2.3334C16.5333 2.66673 16.9333 3.60006 16.6 4.46673C16.3333 5.06673 15.7333 5.46673 15.1333 5.46673C15 5.46673 14.8 5.46673 14.6667 5.40006C14.7333 5.7334 14.7333 6.06673 14.7333 6.3334V6.7334C14.8667 6.7334 15 6.80006 15.1333 6.80006C16.8 6.80006 18.1333 5.46673 18.1333 3.86673C18.1333 2.20006 16.8 0.86673 15.2 0.86673C14.1333 0.86673 13.2 1.40006 12.6667 2.3334C13 2.5334 13.3333 2.80006 13.6 3.20006V3.20006Z"),Y(s,"fill","black"),Y(s,"fill-opacity","0.5"),Y(o,"d","M6 8.93333C5.73333 8.53333 5.53333 8.06666 5.4 7.53333H4.86667C3.13333 7.46666 1.46667 8.06666 0.2 9.13333L0 9.33333V14.6667H1.33333V9.86666C2.4 9.13333 3.6 8.73333 4.86667 8.8C5.26667 8.8 5.66667 8.86666 6 8.93333Z"),Y(o,"fill","black"),Y(o,"fill-opacity","0.5"),Y(a,"d","M4.86666 6.73328C5 6.73328 5.13333 6.73328 5.26666 6.66662V6.26662C5.26666 5.93328 5.26666 5.59995 5.33333 5.33328C5.2 5.39995 5 5.39995 4.86666 5.39995C4 5.39995 3.26666 4.66662 3.26666 3.79995C3.26666 2.93328 4 2.19995 4.86666 2.19995C5.53333 2.19995 6.13333 2.59995 6.4 3.19995C6.66666 2.86662 7.06666 2.53328 7.4 2.26662C6.53333 0.866615 4.73333 0.399949 3.33333 1.26662C1.93333 2.13328 1.46666 3.93328 2.33333 5.33328C2.86666 6.19995 3.8 6.73328 4.86666 6.73328V6.73328Z"),Y(a,"fill","black"),Y(a,"fill-opacity","0.5"),Y(l,"d","M15.4 13.1333L15.2667 12.9333C13.9333 11.4667 12.0667 10.6 10.0667 10.6667C8.06667 10.6 6.13333 11.4667 4.8 12.9333L4.66667 13.1333V18.2C4.66667 18.8 5.13333 19.3333 5.8 19.3333H14.3333C14.9333 19.3333 15.4667 18.8 15.4667 18.2V13.1333H15.4ZM14.0667 18H6V13.6C7.06667 12.5333 8.53333 12 10.0667 12C11.5333 11.9333 13 12.5333 14.0667 13.6V18Z"),Y(l,"fill","black"),Y(l,"fill-opacity","0.5"),Y(n,"height",t[1]),Y(n,"width",t[0]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o),O(n,a),O(n,l)},p(e,[t]){4&t&&Y(i,"fill",e[2]),2&t&&Y(n,"height",e[1]),1&t&&Y(n,"width",e[0]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Ao(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 20 20"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Io extends Fe{constructor(e){super(),Ve(this,e,Ao,Lo,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Mo(e){let t,n,i,r,s,o,a,l,c,u,d,h,f=e[2]("video-component.session-count")+"";return i=new Io({props:{size:"1.5em"}}),{c(){t=D("div"),n=D("div"),Pe(i.$$.fragment),r=U(),s=D("div"),o=D("span"),a=R(f),l=U(),c=D("span"),u=D("span"),d=R(e[0]),Y(n,"class","icon svelte-12re2l9"),G(o,"opacity","0.7"),Y(u,"style",""),Y(c,"class","session-counter svelte-12re2l9"),Y(s,"class","icon user-count-text svelte-12re2l9"),Y(t,"class","user-count hide-phone svelte-12re2l9"),B(t,"horizontal-screen",e[1])},m(e,f){I(e,t,f),O(t,n),Re(i,n,null),O(t,r),O(t,s),O(s,o),O(o,a),O(s,l),O(s,c),O(c,u),O(u,d),h=!0},p(e,[n]){(!h||4&n)&&f!==(f=e[2]("video-component.session-count")+"")&&H(a,f),(!h||1&n)&&H(d,e[0]),2&n&&B(t,"horizontal-screen",e[1])},i(e){h||(ke(i.$$.fragment,e),h=!0)},o(e){Oe(i.$$.fragment,e),h=!1},d(e){e&&M(t),Ue(i)}}}function No(e,t,n){let i,r;h(e,fs,(e=>n(1,i=e))),h(e,li,(e=>n(2,r=e)));let{sessionCount:s=0}=t;return e.$$set=e=>{"sessionCount"in e&&n(0,s=e.sessionCount)},[s,i,r]}class Do extends Fe{constructor(e){super(),Ve(this,e,No,Mo,a,{sessionCount:0})}}const Po=je(""),Ro=je(0),Uo={};async function Vo(e){if(!Uo[e])try{const t=(new Date).getTime(),n=await fetch(e),i=await n.blob(),r=i.size,s=(new Date).getTime(),o=r/((s-t)/1e3)/1048576;Ro.set(o),Uo[e]=i}catch(e){const t=e;if(404===t?.response?.status)return null;t?.response?.data?.detail?ws.set(`Error:\n ${t.response.data.detail}`):ws.set(`${JSON.stringify(t)}`)}return Uo[e]}function Fo(t){let n,i,r,s,o,a;return{c(){n=P("svg"),i=P("rect"),r=P("path"),s=P("path"),o=P("path"),a=P("path"),Y(i,"width","26"),Y(i,"height","26"),Y(i,"rx","10"),Y(i,"fill",t[2]),Y(r,"d","M13.3262 21.8462L15.4095 20.1795M13.3262 21.8462V14.3462V21.8462ZM13.3262 21.8462L11.2428 20.1795L13.3262 21.8462Z"),Y(r,"stroke","white"),Y(r,"stroke-width","2"),Y(r,"stroke-linecap","round"),Y(r,"stroke-linejoin","round"),Y(s,"d","M7.52118 11.1103C6.73302 11.3086 6.04441 11.7879 5.58473 12.4582C5.12504 13.1284 4.92592 13.9434 5.02477 14.7501C5.12362 15.5568 5.51365 16.2996 6.12157 16.839C6.72949 17.3785 7.51346 17.6773 8.32618 17.6795H9.15951"),Y(s,"stroke","white"),Y(s,"stroke-width","2"),Y(s,"stroke-linecap","round"),Y(s,"stroke-linejoin","round"),Y(o,"d","M16.5179 9.46112C16.233 8.33326 15.53 7.3559 14.5513 6.72717C13.5726 6.09843 12.3914 5.86536 11.2472 6.07521C10.1031 6.28505 9.08147 6.92211 8.38957 7.85723C7.69768 8.79236 7.38724 9.95559 7.52119 11.1111C7.52119 11.1111 7.64869 11.8461 7.90952 12.2628"),Y(o,"stroke","white"),Y(o,"stroke-width","2"),Y(o,"stroke-linecap","round"),Y(o,"stroke-linejoin","round"),Y(a,"d","M17.4928 17.6795C18.0812 17.6791 18.6628 17.5541 19.1994 17.3127C19.736 17.0713 20.2153 16.719 20.6059 16.279C20.9966 15.8391 21.2896 15.3213 21.4657 14.7599C21.6418 14.1985 21.697 13.6062 21.6277 13.0219C21.5583 12.4377 21.3661 11.8747 21.0635 11.3701C20.7609 10.8655 20.3549 10.4307 19.8722 10.0943C19.3895 9.75792 18.841 9.52758 18.2628 9.41845C17.6847 9.30932 17.09 9.32388 16.5178 9.46115L15.4095 9.76282"),Y(a,"stroke","white"),Y(a,"stroke-width","2"),Y(a,"stroke-linecap","round"),Y(a,"stroke-linejoin","round"),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"fill",t[2]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o),O(n,a)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3]),4&t&&Y(n,"fill",e[2])},i:e,o:e,d(e){e&&M(n)}}}function Yo(e,t,n){let{size:i="1em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 26 26"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class jo extends Fe{constructor(e){super(),Ve(this,e,Yo,Fo,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Ho(e){let t,n,i,r,s,o,a,l,c,u,d=e[2]("video-component.download")+"";return r=new jo({props:{size:"1.5em"}}),{c(){t=D("div"),n=D("div"),i=D("div"),Pe(r.$$.fragment),s=U(),o=D("div"),a=R(d),Y(i,"class","icon download hide-phone svelte-19dqrfr"),B(i,"hidden",!e[1]),G(o,"color","rgb(var(--download-button-font))"),Y(n,"class","download-area svelte-19dqrfr"),Y(t,"class","download-container svelte-19dqrfr"),B(t,"download-horizontal",e[0])},m(d,h){I(d,t,h),O(t,n),O(n,i),Re(r,i,null),O(n,s),O(n,o),O(o,a),l=!0,c||(u=F(n,"click",e[3]),c=!0)},p(e,[n]){2&n&&B(i,"hidden",!e[1]),(!l||4&n)&&d!==(d=e[2]("video-component.download")+"")&&H(a,d),1&n&&B(t,"download-horizontal",e[0])},i(e){l||(ke(r.$$.fragment,e),l=!0)},o(e){Oe(r.$$.fragment,e),l=!1},d(e){e&&M(t),Ue(r),c=!1,u()}}}function zo(e,t,n){let i,r,s;h(e,fs,(e=>n(0,i=e))),h(e,Po,(e=>n(1,r=e))),h(e,li,(e=>n(2,s=e)));return[i,r,s,()=>(async(e,t="video.mp4")=>{const n=await fetch(e+"?nocache"),i=await n.blob(),r=URL.createObjectURL(i),s=document.createElement("a");s.style.display="none",s.href=r,s.download=t,s.click(),s.remove()})(r)]}class Go extends Fe{constructor(e){super(),Ve(this,e,zo,Ho,a,{})}}function Bo(t){let n,i;return{c(){n=P("svg"),i=P("circle"),Y(i,"cx","5"),Y(i,"cy","5"),Y(i,"r","5"),Y(i,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){4&t&&Y(i,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Wo(e,t,n){let{size:i="0.6em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 10 10"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class qo extends Fe{constructor(e){super(),Ve(this,e,Wo,Bo,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Zo(t){let n,i,r,s,o,a;return{c(){n=P("svg"),i=P("path"),r=P("path"),s=P("path"),o=P("path"),a=P("path"),Y(i,"class","logo-letter"),Y(i,"d","M0,59.61C0,21.58,22,0,57.22,0c30.44,0,53.46,19.82,53.54,48.43H78.31C77.51,35.32,69,26.61,57.22,26.61c-13.91,0-22.7,12.31-22.7,32.92,0,20.86,8.71,33.17,22.78,33.17,11.66,0,20.13-8.55,21.17-21.9h32.45c-.16,28.77-22.62,48.51-53.7,48.51C21.9,119.31,0,97.65,0,59.61Z"),Y(r,"class","logo-letter"),Y(r,"d","M192.3,117.31H158.42V2h51.22c30.77,0,46.59,14.46,46.59,39.15,0,13.59-6.55,26.69-18.62,32.45l21.9,43.71H221.63L203.41,78.63H192.3Zm0-61h14c9.5,0,15.34-5.84,15.34-14.55,0-8.55-6.16-14.7-15.27-14.7H192.3Z"),Y(s,"class","logo-letter"),Y(s,"d","M418,59.69c0,36.84-22.46,59.62-58.1,59.62s-58.09-22.78-58.09-59.62S324.27,0,359.91,0,418,22.85,418,59.69Zm-81.67,0c0,19.9,9.35,32.61,23.57,32.61s23.58-12.71,23.58-32.61S374.06,27,359.91,27,336.34,39.72,336.34,59.69Z"),Y(o,"class","logo-letter"),Y(o,"d","M518.81,117.31h-32L457.12,2h35l13.27,72.88H506L523.21,2h26.21L566.6,74.88h.64L580.5,2h35L585.78,117.31h-32l-17.18-66H536Z"),Y(a,"class","logo-letter"),Y(a,"d","M710.7,2c35,0,55.54,19.9,55.54,56.81s-20.61,58.5-55.54,58.5H661.4V2ZM695.28,90.38h10.63c16.94,0,25.81-10.31,25.81-31.57,0-19.41-9.59-29.88-25.81-29.88H695.28Z"),Y(n,"viewBox",t[3]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"fill",t[2])},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o),O(n,a)},p(e,[t]){8&t&&Y(n,"viewBox",e[3]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),4&t&&Y(n,"fill",e[2])},i:e,o:e,d(e){e&&M(n)}}}function Xo(e,t,n){let{size:i="2em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 766.24 119.31"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class Ko extends Fe{constructor(e){super(),Ve(this,e,Xo,Zo,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function Jo(t){let n,i,r;return{c(){n=P("svg"),i=P("path"),r=P("path"),Y(i,"d","M19.9294 11.5064L19.9294 15.3659L28.7978 15.3659L28.7978 24.2343L32.6573 24.2343L32.6573 11.5084L32.6553 11.5084L32.6553 11.5064L19.9294 11.5064Z"),Y(i,"fill",t[2]),Y(r,"d","M24.2532 32.1537L24.2532 28.2942L15.3848 28.2942L15.3848 19.4258L11.5253 19.4258L11.5253 32.1518L11.5273 32.1517L11.5273 32.1537L24.2532 32.1537Z"),Y(r,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i),O(n,r)},p(e,[t]){4&t&&Y(i,"fill",e[2]),4&t&&Y(r,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function Qo(e,t,n){let{size:i="2.5em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 45 45"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class ea extends Fe{constructor(e){super(),Ve(this,e,Qo,Jo,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function ta(e){let t,n,i,r,s,o,a,l,u=e[6]("video-component.touch-to-start")+"";return{c(){t=D("div"),n=D("img"),r=U(),s=D("div"),o=R(u),Y(n,"alt","touch icon"),c(n.src,i=e[5].touch_to_start_icon)||Y(n,"src",i),Y(n,"class","touch-icon svelte-qtd466"),Y(s,"class","svelte-qtd466"),Y(t,"class","video-item start center-text full-screen-video svelte-qtd466")},m(e,i){I(e,t,i),O(t,n),O(t,r),O(t,s),O(s,o),l=!0},p(e,t){(!l||32&t&&!c(n.src,i=e[5].touch_to_start_icon))&&Y(n,"src",i),(!l||64&t)&&u!==(u=e[6]("video-component.touch-to-start")+"")&&H(o,u)},i(e){l||(ge((()=>{a||(a=Ae(t,pi,{},!0)),a.run(1)})),l=!0)},o(e){a||(a=Ae(t,pi,{},!1)),a.run(0),l=!1},d(e){e&&M(t),e&&a&&a.end()}}}function na(e){let t,n,i,r,s=e[1]&&ia(e);return i=new Go({}),{c(){t=D("div"),s&&s.c(),n=U(),Pe(i.$$.fragment),Y(t,"class","video-header-right svelte-qtd466")},m(e,o){I(e,t,o),s&&s.m(t,null),O(t,n),Re(i,t,null),r=!0},p(e,i){e[1]?s?(s.p(e,i),2&i&&ke(s,1)):(s=ia(e),s.c(),ke(s,1),s.m(t,n)):s&&(Te(),Oe(s,1,1,(()=>{s=null})),Se())},i(e){r||(ke(s),ke(i.$$.fragment,e),r=!0)},o(e){Oe(s),Oe(i.$$.fragment,e),r=!1},d(e){e&&M(t),s&&s.d(),Ue(i)}}}function ia(e){let t,n;return t=new Do({props:{sessionCount:e[0]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};1&n&&(i.sessionCount=e[0]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function ra(t){let n,i,r,s,o;return i=new ea({}),{c(){n=D("div"),Pe(i.$$.fragment),Y(n,"class","full-screen-button svelte-qtd466")},m(e,t){I(e,n,t),Re(i,n,null),r=!0,s||(o=F(n,"click",ps),s=!0)},p:e,i(e){r||(ke(i.$$.fragment,e),r=!0)},o(e){Oe(i.$$.fragment,e),r=!1},d(e){e&&M(n),Ue(i),s=!1,o()}}}function sa(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g,v,y=e[6]("video-component.title")+"";r=new qo({}),m=new Go({});let _=e[1]&&oa(e);return{c(){t=D("div"),n=D("div"),i=D("div"),Pe(r.$$.fragment),s=U(),o=D("div"),a=D("span"),l=R(e[2]),c=U(),u=D("span"),u.textContent="BETA",d=U(),h=D("div"),f=R(y),p=U(),Pe(m.$$.fragment),g=U(),_&&_.c(),Y(i,"class","bulletpoint svelte-qtd466"),G(a,"opacity","0.9"),Y(a,"class","svelte-qtd466"),Y(u,"class","highlight svelte-qtd466"),G(h,"opacity","0.9"),h.hidden=!0,Y(h,"class","svelte-qtd466"),Y(o,"class","title-text svelte-qtd466"),Y(n,"class","hide-phone title svelte-qtd466"),Y(t,"class","video-bottom svelte-qtd466")},m(e,y){I(e,t,y),O(t,n),O(n,i),Re(r,i,null),O(n,s),O(n,o),O(o,a),O(a,l),O(o,c),O(o,u),O(o,d),O(o,h),O(h,f),O(n,p),Re(m,n,null),O(t,g),_&&_.m(t,null),v=!0},p(e,n){(!v||4&n)&&H(l,e[2]),(!v||64&n)&&y!==(y=e[6]("video-component.title")+"")&&H(f,y),e[1]?_?(_.p(e,n),2&n&&ke(_,1)):(_=oa(e),_.c(),ke(_,1),_.m(t,null)):_&&(Te(),Oe(_,1,1,(()=>{_=null})),Se())},i(e){v||(ke(r.$$.fragment,e),ke(m.$$.fragment,e),ke(_),v=!0)},o(e){Oe(r.$$.fragment,e),Oe(m.$$.fragment,e),Oe(_),v=!1},d(e){e&&M(t),Ue(r),Ue(m),_&&_.d()}}}function oa(e){let t,n;return t=new Do({props:{sessionCount:e[0]}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};1&n&&(i.sessionCount=e[0]),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function aa(e){let t,n,i,r,s,o,a,l,c,u,d,h,p,y,_,$,b,w,E,x=e[3]&&ta(e);o=new Ko({props:{size:"3em"}});let C=e[8]&&na(e);const T=e[11].default,S=f(T,e,e[10],null);let k=!e[9]&&ra();function L(t){e[12](t)}let A={};void 0!==e[4]&&(A.size=e[4]),y=new Mi({props:A}),ce.push((()=>De(y,"size",L))),y.$on("skip",e[13]),y.$on("replay",e[14]);let N=!e[8]&&!e[7]&&sa(e);return{c(){x&&x.c(),t=U(),n=D("div"),i=D("div"),r=D("div"),s=D("div"),Pe(o.$$.fragment),a=U(),l=D("span"),l.innerHTML='CROWD MEDIA - <em style="font-style: italic; opacity: 0.75;" class="svelte-qtd466">"We Ship"</em>',c=U(),C&&C.c(),u=U(),S&&S.c(),d=U(),k&&k.c(),h=U(),p=D("div"),Pe(y.$$.fragment),$=U(),b=D("div"),w=U(),N&&N.c(),G(l,"margin-left","3em"),G(l,"font-weight","200"),G(l,"opacity","0.9"),Y(l,"class","hide-phone svelte-qtd466"),Y(s,"class","video-header-left svelte-qtd466"),Y(r,"class","video-header svelte-qtd466"),B(r,"full-screen-hide",e[7]),Y(p,"class","controls backdrop-blur svelte-qtd466"),B(p,"full-screen-hide",e[7]||e[8]),Y(i,"class","video-container svelte-qtd466"),B(i,"is-full-screen-video",e[7]),Y(b,"class","rectangle svelte-qtd466"),Y(n,"class","video-container-container svelte-qtd466")},m(e,f){x&&x.m(e,f),I(e,t,f),I(e,n,f),O(n,i),O(i,r),O(r,s),Re(o,s,null),O(s,a),O(s,l),O(r,c),C&&C.m(r,null),O(i,u),S&&S.m(i,null),O(i,d),k&&k.m(i,null),O(i,h),O(i,p),Re(y,p,null),O(n,$),O(n,b),O(n,w),N&&N.m(n,null),E=!0},p(e,[s]){e[3]?x?(x.p(e,s),8&s&&ke(x,1)):(x=ta(e),x.c(),ke(x,1),x.m(t.parentNode,t)):x&&(Te(),Oe(x,1,1,(()=>{x=null})),Se()),e[8]?C?(C.p(e,s),256&s&&ke(C,1)):(C=na(e),C.c(),ke(C,1),C.m(r,null)):C&&(Te(),Oe(C,1,1,(()=>{C=null})),Se()),128&s&&B(r,"full-screen-hide",e[7]),S&&S.p&&(!E||1024&s)&&g(S,T,e,e[10],E?m(T,e[10],s,null):v(e[10]),null),e[9]?k&&(Te(),Oe(k,1,1,(()=>{k=null})),Se()):k?(k.p(e,s),512&s&&ke(k,1)):(k=ra(),k.c(),ke(k,1),k.m(i,h));const o={};!_&&16&s&&(_=!0,o.size=e[4],ve((()=>_=!1))),y.$set(o),384&s&&B(p,"full-screen-hide",e[7]||e[8]),128&s&&B(i,"is-full-screen-video",e[7]),e[8]||e[7]?N&&(Te(),Oe(N,1,1,(()=>{N=null})),Se()):N?(N.p(e,s),384&s&&ke(N,1)):(N=sa(e),N.c(),ke(N,1),N.m(n,null))},i(e){E||(ke(x),ke(o.$$.fragment,e),ke(C),ke(S,e),ke(k),ke(y.$$.fragment,e),ke(N),E=!0)},o(e){Oe(x),Oe(o.$$.fragment,e),Oe(C),Oe(S,e),Oe(k),Oe(y.$$.fragment,e),Oe(N),E=!1},d(e){x&&x.d(e),e&&M(t),e&&M(n),Ue(o),C&&C.d(),S&&S.d(e),k&&k.d(),Ue(y),N&&N.d()}}}function la(e,t,n){let i,r,s,o,a;h(e,Yr,(e=>n(5,i=e))),h(e,li,(e=>n(6,r=e))),h(e,hs,(e=>n(7,s=e))),h(e,fs,(e=>n(8,o=e))),h(e,ds,(e=>n(9,a=e)));let{$$slots:l={},$$scope:c}=t,{sessionCount:u=0}=t,{show_count:d=!1}=t,{name:f}=t,{start:p=!0}=t,m="2em";return e.$$set=e=>{"sessionCount"in e&&n(0,u=e.sessionCount),"show_count"in e&&n(1,d=e.show_count),"name"in e&&n(2,f=e.name),"start"in e&&n(3,p=e.start),"$$scope"in e&&n(10,c=e.$$scope)},[u,d,f,p,m,i,r,s,o,a,c,l,function(e){m=e,n(4,m)},function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)}]}class ca extends Fe{constructor(e){super(),Ve(this,e,la,aa,a,{sessionCount:0,show_count:1,name:2,start:3})}}const ua=je({x:0,y:0,distanceToBottom:0,distanceToRight:0});function da(e){let t,n,i,r,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b,w,E,x,C,T,S,k,O,L,A,N,P,V,j,H,G,B,W;return{c(){t=D("br"),n=R("\n currentTime"),i=D("input"),r=R("\n duration"),o=D("input"),a=R("\n playDrift"),l=D("input"),c=U(),u=D("br"),d=R("\n src"),h=D("input"),f=U(),p=D("br"),m=R("\n src"),g=D("input"),v=U(),y=D("br"),_=R("\n\n paused"),$=D("input"),b=R("\n pausing"),w=D("input"),E=R("\n\n start"),x=D("input"),C=R("\n muted"),T=D("input"),S=R("\n loop"),k=D("input"),O=U(),L=D("br"),A=U(),N=D("input"),V=U(),j=D("input"),H=U(),G=D("input"),Y(i,"type","text"),Y(i,"class","svelte-aghhqj"),Y(o,"type","text"),Y(o,"class","svelte-aghhqj"),Y(l,"type","text"),Y(l,"class","svelte-aghhqj"),Y(h,"class","lg svelte-aghhqj"),Y(h,"type","text"),Y(g,"class","lg svelte-aghhqj"),Y(g,"type","text"),Y($,"type","checkbox"),Y($,"class","svelte-aghhqj"),Y(w,"type","checkbox"),Y(w,"class","svelte-aghhqj"),Y(x,"type","checkbox"),Y(x,"class","svelte-aghhqj"),Y(T,"type","checkbox"),Y(T,"class","svelte-aghhqj"),Y(k,"type","checkbox"),Y(k,"class","svelte-aghhqj"),Y(N,"type","button"),N.value=P=e[1]?"PLAY":"PAUSE",Y(N,"class","svelte-aghhqj"),Y(j,"type","button"),j.value="set to 0",Y(j,"class","svelte-aghhqj"),Y(G,"type","button"),G.value="set to 2",Y(G,"class","svelte-aghhqj")},m(s,M){I(s,t,M),I(s,n,M),I(s,i,M),z(i,e[2]),I(s,r,M),I(s,o,M),z(o,e[3]),I(s,a,M),I(s,l,M),z(l,e[14]),I(s,c,M),I(s,u,M),I(s,d,M),I(s,h,M),z(h,e[10]),I(s,f,M),I(s,p,M),I(s,m,M),I(s,g,M),z(g,e[10]),I(s,v,M),I(s,y,M),I(s,_,M),I(s,$,M),$.checked=e[1],I(s,b,M),I(s,w,M),w.checked=e[9],I(s,E,M),I(s,x,M),x.checked=e[0],I(s,C,M),I(s,T,M),T.checked=e[18],I(s,S,M),I(s,k,M),k.checked=e[4],I(s,O,M),I(s,L,M),I(s,A,M),I(s,N,M),I(s,V,M),I(s,j,M),I(s,H,M),I(s,G,M),B||(W=[F(i,"input",e[35]),F(o,"input",e[36]),F(l,"input",e[37]),F(h,"input",e[38]),F(g,"input",e[39]),F($,"change",e[40]),F(w,"change",e[41]),F(x,"change",e[42]),F(T,"change",e[43]),F(k,"change",e[44]),F(N,"click",e[45]),F(j,"click",e[46]),F(G,"click",e[47])],B=!0)},p(e,t){4&t[0]&&i.value!==e[2]&&z(i,e[2]),8&t[0]&&o.value!==e[3]&&z(o,e[3]),16384&t[0]&&l.value!==e[14]&&z(l,e[14]),1024&t[0]&&h.value!==e[10]&&z(h,e[10]),1024&t[0]&&g.value!==e[10]&&z(g,e[10]),2&t[0]&&($.checked=e[1]),512&t[0]&&(w.checked=e[9]),1&t[0]&&(x.checked=e[0]),262144&t[0]&&(T.checked=e[18]),16&t[0]&&(k.checked=e[4]),2&t[0]&&P!==(P=e[1]?"PLAY":"PAUSE")&&(N.value=P)},d(e){e&&M(t),e&&M(n),e&&M(i),e&&M(r),e&&M(o),e&&M(a),e&&M(l),e&&M(c),e&&M(u),e&&M(d),e&&M(h),e&&M(f),e&&M(p),e&&M(m),e&&M(g),e&&M(v),e&&M(y),e&&M(_),e&&M($),e&&M(b),e&&M(w),e&&M(E),e&&M(x),e&&M(C),e&&M(T),e&&M(S),e&&M(k),e&&M(O),e&&M(L),e&&M(A),e&&M(N),e&&M(V),e&&M(j),e&&M(H),e&&M(G),B=!1,s(W)}}}function ha(t){let n,i,r,a,l,u,d,h,f,p,m,g,v,y=!1,_=!0;function $(){cancelAnimationFrame(f),n.paused||(f=T($),y=!0),t[27].call(n)}let w=t[8]&&da(t);return{c(){n=D("video"),i=D("track"),p=U(),w&&w.c(),m=V(),Y(i,"kind","captions"),Y(n,"width",r=t[15].x),Y(n,"height",a=t[15].y),n.playsInline=!0,Y(n,"class",l=b(t[23].class)+" svelte-aghhqj"),Y(n,"style",u=`--fade-time: ${t[7]}s; ${!t[12]&&t[0]?"cursor: pointer":""}; ${t[11]?"opacity: 0":""}; ${t[5]};`),c(n.src,d=t[13])||Y(n,"src",d),n.muted=t[18],n.autoplay=h=!t[1]||t[0]&&t[18],n.loop=t[4],n.controls=!1,void 0===t[3]&&ge((()=>t[28].call(n))),B(n,"fade-out",t[6]&&(t[1]||t[9])),B(n,"full-screen",t[16]),B(n,"object-fit-cover",t[16]||t[17]),B(n,"outline",!hs)},m(e,r){I(e,n,r),O(n,i),I(e,p,r),w&&w.m(e,r),I(e,m,r),g||(v=[F(n,"canplay",t[25],{once:!0}),F(n,"loadedmetadata",t[26],{once:!0}),F(n,"timeupdate",$),F(n,"durationchange",t[28]),F(n,"play",t[29]),F(n,"pause",t[29]),F(n,"click",(function(){o(t[0]&&t[30])&&(t[0]&&t[30]).apply(this,arguments)}),{once:!0}),F(n,"pause",t[31]),F(n,"play",t[32]),F(n,"seeked",t[33]),F(n,"ended",t[34])],g=!0)},p(e,i){t=e,32768&i[0]&&r!==(r=t[15].x)&&Y(n,"width",r),32768&i[0]&&a!==(a=t[15].y)&&Y(n,"height",a),8388608&i[0]&&l!==(l=b(t[23].class)+" svelte-aghhqj")&&Y(n,"class",l),6305&i[0]&&u!==(u=`--fade-time: ${t[7]}s; ${!t[12]&&t[0]?"cursor: pointer":""}; ${t[11]?"opacity: 0":""}; ${t[5]};`)&&Y(n,"style",u),8192&i[0]&&!c(n.src,d=t[13])&&Y(n,"src",d),262144&i[0]&&(n.muted=t[18]),262147&i[0]&&h!==(h=!t[1]||t[0]&&t[18])&&(n.autoplay=h),16&i[0]&&(n.loop=t[4]),!y&&4&i[0]&&!isNaN(t[2])&&(n.currentTime=t[2]),y=!1,2&i[0]&&_!==(_=t[1])&&n[_?"pause":"play"](),8389186&i[0]&&B(n,"fade-out",t[6]&&(t[1]||t[9])),8454144&i[0]&&B(n,"full-screen",t[16]),8585216&i[0]&&B(n,"object-fit-cover",t[16]||t[17]),8388608&i[0]&&B(n,"outline",!hs),t[8]?w?w.p(t,i):(w=da(t),w.c(),w.m(m.parentNode,m)):w&&(w.d(1),w=null)},i:e,o:e,d(e){e&&M(n),e&&M(p),w&&w.d(e),e&&M(m),g=!1,s(v)}}}function fa(e,t,i){let r,s,o,a,l;h(e,Po,(e=>i(10,r=e))),h(e,ua,(e=>i(15,s=e))),h(e,hs,(e=>i(16,o=e))),h(e,fs,(e=>i(17,a=e))),h(e,gi,(e=>i(18,l=e)));let c,{start:u=!0}=t,{loop:d=!1}=t,{style:f=""}=t,{fadeOutPaused:p=!0}=t,{fadeTime:m=.3}=t,{paused:g=!0}=t,{currentTime:v=0}=t,{duration:_=0}=t,$=!1,b=!0,{debug:E=!1}=t,x=!1;const C=re(),T=e=>{i(2,v=e),!g&&L(1e3*v)},S=()=>{g&&(L(1e3*v),i(1,g=!1))},k=()=>window.performance.now();let O;const L=(e=0)=>i(24,O=k()-e);let A;return e.$$set=e=>{i(23,t=n(n({},t),y(e))),"start"in e&&i(0,u=e.start),"loop"in e&&i(4,d=e.loop),"style"in e&&i(5,f=e.style),"fadeOutPaused"in e&&i(6,p=e.fadeOutPaused),"fadeTime"in e&&i(7,m=e.fadeTime),"paused"in e&&i(1,g=e.paused),"currentTime"in e&&i(2,v=e.currentTime),"duration"in e&&i(3,_=e.duration),"debug"in e&&i(8,E=e.debug)},e.$$.update=()=>{1025&e.$$.dirty[0]&&(r?(i(1,g=!0),i(9,$=!1),Vo(r).then((e=>{i(13,c=URL.createObjectURL(e)),C("displayChatMessage"),x&&u&&i(1,g=!1),i(11,b=!1)}))):u&&(i(11,b=!0),i(13,c="https://talking-ui-assets-staging.s3.eu-west-1.amazonaws.com/blank.mp4"))),654&e.$$.dirty[0]&&_>0&&!g&&!$&&v+m>=_&&i(9,$=!0),16777222&e.$$.dirty[0]&&!g&&i(14,A=k()-O-1e3*v)},t=y(t),[u,g,v,_,d,f,p,m,E,$,r,b,x,c,A,s,o,a,l,C,T,S,L,t,O,()=>C("ready"),()=>C("ready"),function(){v=this.currentTime,i(2,v)},function(){_=this.duration,i(3,_)},function(){g=this.paused,i(1,g),i(10,r),i(0,u)},()=>{w(gi,l=!1,l),i(12,x=!0),S(),C("firstClick")},()=>{C("pause"),i(2,v=0),i(9,$=!1)},()=>{L(1e3*v),i(9,$=!1)},()=>{L(1e3*v),i(9,$=!1)},()=>{C("ended"),i(2,v=0),i(9,$=!1)},function(){v=this.value,i(2,v)},function(){_=this.value,i(3,_)},function(){A=this.value,i(14,A),i(1,g),i(24,O),i(2,v),i(10,r),i(0,u)},function(){r=this.value,Po.set(r)},function(){r=this.value,Po.set(r)},function(){g=this.checked,i(1,g),i(10,r),i(0,u)},function(){$=this.checked,i(9,$),i(10,r),i(0,u),i(3,_),i(1,g),i(2,v),i(7,m)},function(){u=this.checked,i(0,u)},function(){l=this.checked,gi.set(l)},function(){d=this.checked,i(4,d)},()=>i(1,g=!g),()=>T(0),()=>T(2)]}class pa extends Fe{constructor(e){super(),Ve(this,e,fa,ha,a,{start:0,loop:4,style:5,fadeOutPaused:6,fadeTime:7,paused:1,currentTime:2,duration:3,debug:8},null,[-1,-1])}}const{window:ma}=Ie;function ga(t){let n,i,r,o,a,l,u;return{c(){n=D("video"),i=D("track"),Y(i,"kind","captions"),n.playsInline=!0,Y(n,"class",r=b(t[7].class)+" svelte-1gda3bp"),Y(n,"style",o=`cursor: pointer; ${t[0]};`),c(n.src,a=t[1])||Y(n,"src",a),n.muted=!0,n.autoplay=!0,n.loop=!0,n.controls=!1,B(n,"full-screen",t[4]),B(n,"horizontal-screen",t[3])},m(e,r){I(e,n,r),O(n,i),t[8](n),l||(u=[F(ma,"resize",t[6]),F(n,"canplay",t[5],{once:!0})],l=!0)},p(e,[t]){128&t&&r!==(r=b(e[7].class)+" svelte-1gda3bp")&&Y(n,"class",r),1&t&&o!==(o=`cursor: pointer; ${e[0]};`)&&Y(n,"style",o),2&t&&!c(n.src,a=e[1])&&Y(n,"src",a),144&t&&B(n,"full-screen",e[4]),136&t&&B(n,"horizontal-screen",e[3])},i:e,o:e,d(e){e&&M(n),t[8](null),l=!1,s(u)}}}function va(e,t,i){let r,s,o;h(e,fs,(e=>i(3,r=e))),h(e,hs,(e=>i(4,s=e))),h(e,ua,(e=>i(9,o=e)));const a=re();let l,{style:c=""}=t,{src:u}=t;const d=()=>{const e=l.getBoundingClientRect(),t=window.innerHeight-e.bottom,n=window.innerWidth-e.right;w(ua,o={x:l.clientWidth,y:l.clientHeight,distanceToBottom:t,distanceToRight:n},o)};return e.$$set=e=>{i(7,t=n(n({},t),y(e))),"style"in e&&i(0,c=e.style),"src"in e&&i(1,u=e.src)},e.$$.update=()=>{28&e.$$.dirty&&l&&me().then((()=>d()))},t=y(t),[c,u,l,r,s,()=>{d(),a("ready")},d,t,function(e){ce[e?"unshift":"push"]((()=>{l=e,i(2,l)}))}]}class ya extends Fe{constructor(e){super(),Ve(this,e,va,ga,a,{style:0,src:1})}}const _a=je(!1);function $a(e){let t,n,i,r,s,o,a,l,c;function u(t){e[20](t)}function d(t){e[21](t)}let h={class:"video-item",fadeOutPaused:!1,start:!0,muted:!0,loop:!0};function f(t){e[23](t)}function p(t){e[24](t)}function m(t){e[25](t)}void 0!==e[5]&&(h.src=e[5]),void 0!==e[10]&&(h.currentTime=e[10]),t=new ya({props:h}),ce.push((()=>De(t,"src",u))),ce.push((()=>De(t,"currentTime",d))),t.$on("ready",$(e[22]));let g={class:"video-item "+(e[9]?"full-screen-video":""),fadeOutPaused:!0,start:!0,loop:!1,debug:!1};return void 0!==e[8]&&(g.src=e[8]),void 0!==e[0]&&(g.paused=e[0]),void 0!==e[1]&&(g.currentTime=e[1]),s=new pa({props:g}),ce.push((()=>De(s,"src",f))),ce.push((()=>De(s,"paused",p))),ce.push((()=>De(s,"currentTime",m))),s.$on("play",e[26]),s.$on("ready",$(e[27])),s.$on("ended",e[28]),s.$on("pause",e[29]),s.$on("firstClick",e[30]),s.$on("displayChatMessage",e[12]),{c(){Pe(t.$$.fragment),r=U(),Pe(s.$$.fragment)},m(e,n){Re(t,e,n),I(e,r,n),Re(s,e,n),c=!0},p(e,r){const c={};!n&&32&r[0]&&(n=!0,c.src=e[5],ve((()=>n=!1))),!i&&1024&r[0]&&(i=!0,c.currentTime=e[10],ve((()=>i=!1))),t.$set(c);const u={};512&r[0]&&(u.class="video-item "+(e[9]?"full-screen-video":"")),!o&&256&r[0]&&(o=!0,u.src=e[8],ve((()=>o=!1))),!a&&1&r[0]&&(a=!0,u.paused=e[0],ve((()=>a=!1))),!l&&2&r[0]&&(l=!0,u.currentTime=e[1],ve((()=>l=!1))),s.$set(u)},i(e){c||(ke(t.$$.fragment,e),ke(s.$$.fragment,e),c=!0)},o(e){Oe(t.$$.fragment,e),Oe(s.$$.fragment,e),c=!1},d(e){Ue(t,e),e&&M(r),Ue(s,e)}}}function ba(e){let t,n,i,r,s,o;function a(t){e[31](t)}function l(t){e[32](t)}function c(t){e[33](t)}function u(t){e[34](t)}let d={$$slots:{default:[$a]},$$scope:{ctx:e}};return void 0!==e[2]&&(d.sessionCount=e[2]),void 0!==e[3]&&(d.show_count=e[3]),void 0!==e[4]&&(d.name=e[4]),void 0!==e[9]&&(d.start=e[9]),t=new ca({props:d}),ce.push((()=>De(t,"sessionCount",a))),ce.push((()=>De(t,"show_count",l))),ce.push((()=>De(t,"name",c))),ce.push((()=>De(t,"start",u))),t.$on("skip",e[35]),t.$on("replay",e[36]),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),o=!0},p(e,o){const a={};2019&o[0]|256&o[1]&&(a.$$scope={dirty:o,ctx:e}),!n&&4&o[0]&&(n=!0,a.sessionCount=e[2],ve((()=>n=!1))),!i&&8&o[0]&&(i=!0,a.show_count=e[3],ve((()=>i=!1))),!r&&16&o[0]&&(r=!0,a.name=e[4],ve((()=>r=!1))),!s&&512&o[0]&&(s=!0,a.start=e[9],ve((()=>s=!1))),t.$set(a)},i(e){o||(ke(t.$$.fragment,e),o=!0)},o(e){Oe(t.$$.fragment,e),o=!1},d(e){Ue(t,e)}}}function wa(e,t,n){let i,r,s;h(e,zr,(e=>n(37,i=e))),h(e,Po,(e=>n(38,r=e))),h(e,_a,(e=>n(19,s=e)));const o=re();let a,{paused:l=!0}=t,{currentTime:c=0}=t,{sessionCount:u=0}=t,{show_count:d=!1}=t,{name:f}=t,{idleVideoSrc:p}=t;const m=()=>{n(0,l=!0),n(1,c=0)};let g=null;let v=!0,y=0,_=!1,$=!1;return e.$$set=e=>{"paused"in e&&n(0,l=e.paused),"currentTime"in e&&n(1,c=e.currentTime),"sessionCount"in e&&n(2,u=e.sessionCount),"show_count"in e&&n(3,d=e.show_count),"name"in e&&n(4,f=e.name),"idleVideoSrc"in e&&n(5,p=e.idleVideoSrc)},e.$$.update=()=>{786432&e.$$.dirty[0]&&s&&(clearTimeout(g),w(_a,s=!1,s)),192&e.$$.dirty[0]&&$&&_&&o("ready")},[l,c,u,d,f,p,_,$,a,v,y,o,()=>{o("displayChatMessage",r),w(zr,i=!1,i)},e=>{if(w(zr,i=!1,i),g&&(clearTimeout(g),n(18,g=null)),e){m();const e=r;w(Po,r=void 0,r),w(Po,r=e,r)}},undefined,m,()=>{w(zr,i=!1,i),g&&(clearTimeout(g),n(18,g=null)),w(zr,i=!1,i)},()=>{n(18,g=setTimeout((()=>{w(zr,i=!0,i)}),1e3))},g,s,function(e){p=e,n(5,p)},function(e){y=e,n(10,y)},()=>{n(6,_=!0)},function(e){a=e,n(8,a)},function(e){l=e,n(0,l)},function(e){c=e,n(1,c)},()=>{setTimeout((()=>{n(10,y=c)}),400)},()=>{n(7,$=!0)},()=>o("talking_end"),function(t){ae.call(this,e,t)},()=>{n(9,v=!1)},function(e){u=e,n(2,u)},function(e){d=e,n(3,d)},function(e){f=e,n(4,f)},function(e){v=e,n(9,v)},function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)}]}class Ea extends Fe{constructor(e){super(),Ve(this,e,wa,ba,a,{paused:0,currentTime:1,sessionCount:2,show_count:3,name:4,idleVideoSrc:5,on_video_received:13,on_cache_check:14,skipTalkingVideo:15,on_video_synth_error:16,on_enter:17},null,[-1,-1])}get on_video_received(){return this.$$.ctx[13]}get on_cache_check(){return this.$$.ctx[14]}get skipTalkingVideo(){return this.$$.ctx[15]}get on_video_synth_error(){return this.$$.ctx[16]}get on_enter(){return this.$$.ctx[17]}}function xa(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g,v,y=e[0]("error.title")+"",_=e[0]("error.description")+"",$=e[1].replaceAll("\n","<br />")+"";return d=new Ko({}),{c(){t=D("div"),n=D("div"),i=R(y),r=U(),s=D("div"),o=R(_),a=U(),l=D("div"),c=U(),u=D("div"),Pe(d.$$.fragment),h=U(),f=D("div"),p=U(),m=D("div"),Y(n,"class","title svelte-9ozsye"),Y(s,"class","svelte-9ozsye"),Y(l,"class","error-msg svelte-9ozsye"),Y(u,"class","decoration logo svelte-9ozsye"),Y(f,"class","decoration rectangle one svelte-9ozsye"),Y(m,"class","decoration rectangle two svelte-9ozsye"),Y(t,"class","error center-text full-screen svelte-9ozsye")},m(e,g){I(e,t,g),O(t,n),O(n,i),O(t,r),O(t,s),O(s,o),O(t,a),O(t,l),l.innerHTML=$,O(t,c),O(t,u),Re(d,u,null),O(t,h),O(t,f),O(t,p),O(t,m),v=!0},p(e,[t]){(!v||1&t)&&y!==(y=e[0]("error.title")+"")&&H(i,y),(!v||1&t)&&_!==(_=e[0]("error.description")+"")&&H(o,_),(!v||2&t)&&$!==($=e[1].replaceAll("\n","<br />")+"")&&(l.innerHTML=$)},i(e){v||(ke(d.$$.fragment,e),ge((()=>{g||(g=Ae(t,pi,{},!0)),g.run(1)})),v=!0)},o(e){Oe(d.$$.fragment,e),g||(g=Ae(t,pi,{},!1)),g.run(0),v=!1},d(e){e&&M(t),Ue(d),e&&g&&g.end()}}}function Ca(e,t,n){let i,r;return h(e,li,(e=>n(0,i=e))),h(e,ws,(e=>n(1,r=e))),[i,r]}class Ta extends Fe{constructor(e){super(),Ve(this,e,Ca,xa,a,{})}}const Sa="anonymous";function ka(e,t,n){let i;h(e,Yr,(e=>n(9,i=e)));const r=`${i.api_base}/token`;let s,o,{logged_username:a=Sa}=t,{access_token:l=""}=t,{_user_id:c=""}=t,{decoded_token:u}=t,d=Sa;const f=async()=>(d=Sa,s="Password1",await p()),p=async e=>{const t=new FormData;t.append("username",d),t.append("password",s);try{const e=await fetch(r,{method:"POST",body:t}),i=await e.json();n(0,l=i.access_token),n(2,c=i.user_id),await me()}catch(t){const n=t;if(401!==n?.response?.status_code||d===Sa){let t="";if(n?.response?.data?.detail){const e=n.response.data.detail;if("string"==typeof e)t=`${e}`;else if("object"==typeof e){const n=e;for(let e=0;e<n.length;e++){const i=n[e];e>0&&(t+="\n"),t+=i.msg+": "+i.loc[1]}}}else t=`${JSON.stringify(n)}`;e?e(t):ws.set(t)}return}if(l){n(1,a=d),o&&(clearTimeout(o),o=void 0);const e=hi(1e3*u.exp).valueOf()-hi().valueOf();o=setTimeout((()=>{o=void 0,p()}),Math.floor(.8*e))}return{access_token:l,typed_token:u,_user_id:c}};return ne((async()=>{await f()})),e.$$set=e=>{"logged_username"in e&&n(1,a=e.logged_username),"access_token"in e&&n(0,l=e.access_token),"_user_id"in e&&n(2,c=e._user_id),"decoded_token"in e&&n(3,u=e.decoded_token)},e.$$.update=()=>{1&e.$$.dirty&&n(3,u=l&&JSON.parse(window.atob(l.split(".")[1])))},[l,a,c,u,async(e,t,n)=>(d=e,s=t,await p(n)),f]}class Oa extends Fe{constructor(e){super(),Ve(this,e,ka,null,a,{logged_username:1,access_token:0,_user_id:2,decoded_token:3,login:4,logout:5})}get login(){return this.$$.ctx[4]}get logout(){return this.$$.ctx[5]}}
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/var La=function(){function e(e){void 0===e&&(e={}),this.adapter=e}return Object.defineProperty(e,"cssClasses",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(e,"strings",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(e,"numbers",{get:function(){return{}},enumerable:!1,configurable:!0}),Object.defineProperty(e,"defaultAdapter",{get:function(){return{}},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.destroy=function(){},e}();
/**
* @license
* Copyright 2019 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/var Aa=Object.freeze({__proto__:null,applyPassive:function(e){return void 0===e&&(e=window),!!function(e){void 0===e&&(e=window);var t=!1;try{var n={get passive(){return t=!0,!1}},i=function(){};e.document.addEventListener("test",i,n),e.document.removeEventListener("test",i,n)}catch(e){t=!1}return t}(e)&&{passive:!0}}});
/**
* @license
* Copyright 2018 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/function Ia(e,t){return(e.matches||e.webkitMatchesSelector||e.msMatchesSelector).call(e,t)}var Ma,Na=Object.freeze({__proto__:null,closest:function(e,t){if(e.closest)return e.closest(t);for(var n=e;n;){if(Ia(n,t))return n;n=n.parentElement}return null},matches:Ia,estimateScrollWidth:function(e){var t=e;if(null!==t.offsetParent)return t.scrollWidth;var n=t.cloneNode(!0);n.style.setProperty("position","absolute"),n.style.setProperty("transform","translate(-9999px, -9999px)"),document.documentElement.appendChild(n);var i=n.scrollWidth;return document.documentElement.removeChild(n),i}}),Da={LABEL_FLOAT_ABOVE:"mdc-floating-label--float-above",LABEL_REQUIRED:"mdc-floating-label--required",LABEL_SHAKE:"mdc-floating-label--shake",ROOT:"mdc-floating-label"},Pa=function(e){function t(n){var i=e.call(this,st(st({},t.defaultAdapter),n))||this;return i.shakeAnimationEndHandler=function(){i.handleShakeAnimationEnd()},i}return tt(t,e),Object.defineProperty(t,"cssClasses",{get:function(){return Da},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},getWidth:function(){return 0},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){this.adapter.registerInteractionHandler("animationend",this.shakeAnimationEndHandler)},t.prototype.destroy=function(){this.adapter.deregisterInteractionHandler("animationend",this.shakeAnimationEndHandler)},t.prototype.getWidth=function(){return this.adapter.getWidth()},t.prototype.shake=function(e){var n=t.cssClasses.LABEL_SHAKE;e?this.adapter.addClass(n):this.adapter.removeClass(n)},t.prototype.float=function(e){var n=t.cssClasses,i=n.LABEL_FLOAT_ABOVE,r=n.LABEL_SHAKE;e?this.adapter.addClass(i):(this.adapter.removeClass(i),this.adapter.removeClass(r))},t.prototype.setRequired=function(e){var n=t.cssClasses.LABEL_REQUIRED;e?this.adapter.addClass(n):this.adapter.removeClass(n)},t.prototype.handleShakeAnimationEnd=function(){var e=t.cssClasses.LABEL_SHAKE;this.adapter.removeClass(e)},t}(La),Ra={LINE_RIPPLE_ACTIVE:"mdc-line-ripple--active",LINE_RIPPLE_DEACTIVATING:"mdc-line-ripple--deactivating"},Ua=function(e){function t(n){var i=e.call(this,st(st({},t.defaultAdapter),n))||this;return i.transitionEndHandler=function(e){i.handleTransitionEnd(e)},i}return tt(t,e),Object.defineProperty(t,"cssClasses",{get:function(){return Ra},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},setStyle:function(){},registerEventHandler:function(){},deregisterEventHandler:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){this.adapter.registerEventHandler("transitionend",this.transitionEndHandler)},t.prototype.destroy=function(){this.adapter.deregisterEventHandler("transitionend",this.transitionEndHandler)},t.prototype.activate=function(){this.adapter.removeClass(Ra.LINE_RIPPLE_DEACTIVATING),this.adapter.addClass(Ra.LINE_RIPPLE_ACTIVE)},t.prototype.setRippleCenter=function(e){this.adapter.setStyle("transform-origin",e+"px center")},t.prototype.deactivate=function(){this.adapter.addClass(Ra.LINE_RIPPLE_DEACTIVATING)},t.prototype.handleTransitionEnd=function(e){var t=this.adapter.hasClass(Ra.LINE_RIPPLE_DEACTIVATING);"opacity"===e.propertyName&&t&&(this.adapter.removeClass(Ra.LINE_RIPPLE_ACTIVE),this.adapter.removeClass(Ra.LINE_RIPPLE_DEACTIVATING))},t}(La),Va={NOTCH_ELEMENT_SELECTOR:".mdc-notched-outline__notch"},Fa={NOTCH_ELEMENT_PADDING:8},Ya={NO_LABEL:"mdc-notched-outline--no-label",OUTLINE_NOTCHED:"mdc-notched-outline--notched",OUTLINE_UPGRADED:"mdc-notched-outline--upgraded"},ja=function(e){function t(n){return e.call(this,st(st({},t.defaultAdapter),n))||this}return tt(t,e),Object.defineProperty(t,"strings",{get:function(){return Va},enumerable:!1,configurable:!0}),Object.defineProperty(t,"cssClasses",{get:function(){return Ya},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return Fa},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},setNotchWidthProperty:function(){},removeNotchWidthProperty:function(){}}},enumerable:!1,configurable:!0}),t.prototype.notch=function(e){var n=t.cssClasses.OUTLINE_NOTCHED;e>0&&(e+=Fa.NOTCH_ELEMENT_PADDING),this.adapter.setNotchWidthProperty(e),this.adapter.addClass(n)},t.prototype.closeNotch=function(){var e=t.cssClasses.OUTLINE_NOTCHED;this.adapter.removeClass(e),this.adapter.removeNotchWidthProperty()},t}(La),Ha={BG_FOCUSED:"mdc-ripple-upgraded--background-focused",FG_ACTIVATION:"mdc-ripple-upgraded--foreground-activation",FG_DEACTIVATION:"mdc-ripple-upgraded--foreground-deactivation",ROOT:"mdc-ripple-upgraded",UNBOUNDED:"mdc-ripple-upgraded--unbounded"},za={VAR_FG_SCALE:"--mdc-ripple-fg-scale",VAR_FG_SIZE:"--mdc-ripple-fg-size",VAR_FG_TRANSLATE_END:"--mdc-ripple-fg-translate-end",VAR_FG_TRANSLATE_START:"--mdc-ripple-fg-translate-start",VAR_LEFT:"--mdc-ripple-left",VAR_TOP:"--mdc-ripple-top"},Ga={DEACTIVATION_TIMEOUT_MS:225,FG_DEACTIVATION_MS:150,INITIAL_ORIGIN_SCALE:.6,PADDING:10,TAP_DELAY_MS:300};
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
/**
* @license
* Copyright 2016 Google Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
var Ba=["touchstart","pointerdown","mousedown","keydown"],Wa=["touchend","pointerup","mouseup","contextmenu"],qa=[],Za=function(e){function t(n){var i=e.call(this,st(st({},t.defaultAdapter),n))||this;return i.activationAnimationHasEnded=!1,i.activationTimer=0,i.fgDeactivationRemovalTimer=0,i.fgScale="0",i.frame={width:0,height:0},i.initialSize=0,i.layoutFrame=0,i.maxRadius=0,i.unboundedCoords={left:0,top:0},i.activationState=i.defaultActivationState(),i.activationTimerCallback=function(){i.activationAnimationHasEnded=!0,i.runDeactivationUXLogicIfReady()},i.activateHandler=function(e){i.activateImpl(e)},i.deactivateHandler=function(){i.deactivateImpl()},i.focusHandler=function(){i.handleFocus()},i.blurHandler=function(){i.handleBlur()},i.resizeHandler=function(){i.layout()},i}return tt(t,e),Object.defineProperty(t,"cssClasses",{get:function(){return Ha},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return za},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return Ga},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},browserSupportsCssVars:function(){return!0},computeBoundingRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},containsEventTarget:function(){return!0},deregisterDocumentInteractionHandler:function(){},deregisterInteractionHandler:function(){},deregisterResizeHandler:function(){},getWindowPageOffset:function(){return{x:0,y:0}},isSurfaceActive:function(){return!0},isSurfaceDisabled:function(){return!0},isUnbounded:function(){return!0},registerDocumentInteractionHandler:function(){},registerInteractionHandler:function(){},registerResizeHandler:function(){},removeClass:function(){},updateCssVariable:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){var e=this,n=this.supportsPressRipple();if(this.registerRootHandlers(n),n){var i=t.cssClasses,r=i.ROOT,s=i.UNBOUNDED;requestAnimationFrame((function(){e.adapter.addClass(r),e.adapter.isUnbounded()&&(e.adapter.addClass(s),e.layoutInternal())}))}},t.prototype.destroy=function(){var e=this;if(this.supportsPressRipple()){this.activationTimer&&(clearTimeout(this.activationTimer),this.activationTimer=0,this.adapter.removeClass(t.cssClasses.FG_ACTIVATION)),this.fgDeactivationRemovalTimer&&(clearTimeout(this.fgDeactivationRemovalTimer),this.fgDeactivationRemovalTimer=0,this.adapter.removeClass(t.cssClasses.FG_DEACTIVATION));var n=t.cssClasses,i=n.ROOT,r=n.UNBOUNDED;requestAnimationFrame((function(){e.adapter.removeClass(i),e.adapter.removeClass(r),e.removeCssVars()}))}this.deregisterRootHandlers(),this.deregisterDeactivationHandlers()},t.prototype.activate=function(e){this.activateImpl(e)},t.prototype.deactivate=function(){this.deactivateImpl()},t.prototype.layout=function(){var e=this;this.layoutFrame&&cancelAnimationFrame(this.layoutFrame),this.layoutFrame=requestAnimationFrame((function(){e.layoutInternal(),e.layoutFrame=0}))},t.prototype.setUnbounded=function(e){var n=t.cssClasses.UNBOUNDED;e?this.adapter.addClass(n):this.adapter.removeClass(n)},t.prototype.handleFocus=function(){var e=this;requestAnimationFrame((function(){return e.adapter.addClass(t.cssClasses.BG_FOCUSED)}))},t.prototype.handleBlur=function(){var e=this;requestAnimationFrame((function(){return e.adapter.removeClass(t.cssClasses.BG_FOCUSED)}))},t.prototype.supportsPressRipple=function(){return this.adapter.browserSupportsCssVars()},t.prototype.defaultActivationState=function(){return{activationEvent:void 0,hasDeactivationUXRun:!1,isActivated:!1,isProgrammatic:!1,wasActivatedByPointer:!1,wasElementMadeActive:!1}},t.prototype.registerRootHandlers=function(e){var t,n;if(e){try{for(var i=ot(Ba),r=i.next();!r.done;r=i.next()){var s=r.value;this.adapter.registerInteractionHandler(s,this.activateHandler)}}catch(e){t={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}this.adapter.isUnbounded()&&this.adapter.registerResizeHandler(this.resizeHandler)}this.adapter.registerInteractionHandler("focus",this.focusHandler),this.adapter.registerInteractionHandler("blur",this.blurHandler)},t.prototype.registerDeactivationHandlers=function(e){var t,n;if("keydown"===e.type)this.adapter.registerInteractionHandler("keyup",this.deactivateHandler);else try{for(var i=ot(Wa),r=i.next();!r.done;r=i.next()){var s=r.value;this.adapter.registerDocumentInteractionHandler(s,this.deactivateHandler)}}catch(e){t={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}},t.prototype.deregisterRootHandlers=function(){var e,t;try{for(var n=ot(Ba),i=n.next();!i.done;i=n.next()){var r=i.value;this.adapter.deregisterInteractionHandler(r,this.activateHandler)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}this.adapter.deregisterInteractionHandler("focus",this.focusHandler),this.adapter.deregisterInteractionHandler("blur",this.blurHandler),this.adapter.isUnbounded()&&this.adapter.deregisterResizeHandler(this.resizeHandler)},t.prototype.deregisterDeactivationHandlers=function(){var e,t;this.adapter.deregisterInteractionHandler("keyup",this.deactivateHandler);try{for(var n=ot(Wa),i=n.next();!i.done;i=n.next()){var r=i.value;this.adapter.deregisterDocumentInteractionHandler(r,this.deactivateHandler)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}},t.prototype.removeCssVars=function(){var e=this,n=t.strings;Object.keys(n).forEach((function(t){0===t.indexOf("VAR_")&&e.adapter.updateCssVariable(n[t],null)}))},t.prototype.activateImpl=function(e){var t=this;if(!this.adapter.isSurfaceDisabled()){var n=this.activationState;if(!n.isActivated){var i=this.previousActivationEvent;if(!(i&&void 0!==e&&i.type!==e.type)){n.isActivated=!0,n.isProgrammatic=void 0===e,n.activationEvent=e,n.wasActivatedByPointer=!n.isProgrammatic&&(void 0!==e&&("mousedown"===e.type||"touchstart"===e.type||"pointerdown"===e.type));var r=void 0!==e&&qa.length>0&&qa.some((function(e){return t.adapter.containsEventTarget(e)}));r?this.resetActivationState():(void 0!==e&&(qa.push(e.target),this.registerDeactivationHandlers(e)),n.wasElementMadeActive=this.checkElementMadeActive(e),n.wasElementMadeActive&&this.animateActivation(),requestAnimationFrame((function(){qa=[],n.wasElementMadeActive||void 0===e||" "!==e.key&&32!==e.keyCode||(n.wasElementMadeActive=t.checkElementMadeActive(e),n.wasElementMadeActive&&t.animateActivation()),n.wasElementMadeActive||(t.activationState=t.defaultActivationState())})))}}}},t.prototype.checkElementMadeActive=function(e){return void 0===e||"keydown"!==e.type||this.adapter.isSurfaceActive()},t.prototype.animateActivation=function(){var e=this,n=t.strings,i=n.VAR_FG_TRANSLATE_START,r=n.VAR_FG_TRANSLATE_END,s=t.cssClasses,o=s.FG_DEACTIVATION,a=s.FG_ACTIVATION,l=t.numbers.DEACTIVATION_TIMEOUT_MS;this.layoutInternal();var c="",u="";if(!this.adapter.isUnbounded()){var d=this.getFgTranslationCoordinates(),h=d.startPoint,f=d.endPoint;c=h.x+"px, "+h.y+"px",u=f.x+"px, "+f.y+"px"}this.adapter.updateCssVariable(i,c),this.adapter.updateCssVariable(r,u),clearTimeout(this.activationTimer),clearTimeout(this.fgDeactivationRemovalTimer),this.rmBoundedActivationClasses(),this.adapter.removeClass(o),this.adapter.computeBoundingRect(),this.adapter.addClass(a),this.activationTimer=setTimeout((function(){e.activationTimerCallback()}),l)},t.prototype.getFgTranslationCoordinates=function(){var e,t=this.activationState,n=t.activationEvent;return e=t.wasActivatedByPointer?function(e,t,n){if(!e)return{x:0,y:0};var i,r,s=t.x,o=t.y,a=s+n.left,l=o+n.top;if("touchstart"===e.type){var c=e;i=c.changedTouches[0].pageX-a,r=c.changedTouches[0].pageY-l}else{var u=e;i=u.pageX-a,r=u.pageY-l}return{x:i,y:r}}(n,this.adapter.getWindowPageOffset(),this.adapter.computeBoundingRect()):{x:this.frame.width/2,y:this.frame.height/2},{startPoint:e={x:e.x-this.initialSize/2,y:e.y-this.initialSize/2},endPoint:{x:this.frame.width/2-this.initialSize/2,y:this.frame.height/2-this.initialSize/2}}},t.prototype.runDeactivationUXLogicIfReady=function(){var e=this,n=t.cssClasses.FG_DEACTIVATION,i=this.activationState,r=i.hasDeactivationUXRun,s=i.isActivated;(r||!s)&&this.activationAnimationHasEnded&&(this.rmBoundedActivationClasses(),this.adapter.addClass(n),this.fgDeactivationRemovalTimer=setTimeout((function(){e.adapter.removeClass(n)}),Ga.FG_DEACTIVATION_MS))},t.prototype.rmBoundedActivationClasses=function(){var e=t.cssClasses.FG_ACTIVATION;this.adapter.removeClass(e),this.activationAnimationHasEnded=!1,this.adapter.computeBoundingRect()},t.prototype.resetActivationState=function(){var e=this;this.previousActivationEvent=this.activationState.activationEvent,this.activationState=this.defaultActivationState(),setTimeout((function(){return e.previousActivationEvent=void 0}),t.numbers.TAP_DELAY_MS)},t.prototype.deactivateImpl=function(){var e=this,t=this.activationState;if(t.isActivated){var n=st({},t);t.isProgrammatic?(requestAnimationFrame((function(){e.animateDeactivation(n)})),this.resetActivationState()):(this.deregisterDeactivationHandlers(),requestAnimationFrame((function(){e.activationState.hasDeactivationUXRun=!0,e.animateDeactivation(n),e.resetActivationState()})))}},t.prototype.animateDeactivation=function(e){var t=e.wasActivatedByPointer,n=e.wasElementMadeActive;(t||n)&&this.runDeactivationUXLogicIfReady()},t.prototype.layoutInternal=function(){var e=this;this.frame=this.adapter.computeBoundingRect();var n=Math.max(this.frame.height,this.frame.width);this.maxRadius=this.adapter.isUnbounded()?n:Math.sqrt(Math.pow(e.frame.width,2)+Math.pow(e.frame.height,2))+t.numbers.PADDING;var i=Math.floor(n*t.numbers.INITIAL_ORIGIN_SCALE);this.adapter.isUnbounded()&&i%2!=0?this.initialSize=i-1:this.initialSize=i,this.fgScale=""+this.maxRadius/this.initialSize,this.updateLayoutCssVars()},t.prototype.updateLayoutCssVars=function(){var e=t.strings,n=e.VAR_FG_SIZE,i=e.VAR_LEFT,r=e.VAR_TOP,s=e.VAR_FG_SCALE;this.adapter.updateCssVariable(n,this.initialSize+"px"),this.adapter.updateCssVariable(s,this.fgScale),this.adapter.isUnbounded()&&(this.unboundedCoords={left:Math.round(this.frame.width/2-this.initialSize/2),top:Math.round(this.frame.height/2-this.initialSize/2)},this.adapter.updateCssVariable(i,this.unboundedCoords.left+"px"),this.adapter.updateCssVariable(r,this.unboundedCoords.top+"px"))},t}(La),Xa={ARIA_CONTROLS:"aria-controls",ARIA_DESCRIBEDBY:"aria-describedby",INPUT_SELECTOR:".mdc-text-field__input",LABEL_SELECTOR:".mdc-floating-label",LEADING_ICON_SELECTOR:".mdc-text-field__icon--leading",LINE_RIPPLE_SELECTOR:".mdc-line-ripple",OUTLINE_SELECTOR:".mdc-notched-outline",PREFIX_SELECTOR:".mdc-text-field__affix--prefix",SUFFIX_SELECTOR:".mdc-text-field__affix--suffix",TRAILING_ICON_SELECTOR:".mdc-text-field__icon--trailing"},Ka={DISABLED:"mdc-text-field--disabled",FOCUSED:"mdc-text-field--focused",HELPER_LINE:"mdc-text-field-helper-line",INVALID:"mdc-text-field--invalid",LABEL_FLOATING:"mdc-text-field--label-floating",NO_LABEL:"mdc-text-field--no-label",OUTLINED:"mdc-text-field--outlined",ROOT:"mdc-text-field",TEXTAREA:"mdc-text-field--textarea",WITH_LEADING_ICON:"mdc-text-field--with-leading-icon",WITH_TRAILING_ICON:"mdc-text-field--with-trailing-icon",WITH_INTERNAL_COUNTER:"mdc-text-field--with-internal-counter"},Ja={LABEL_SCALE:.75},Qa=["pattern","min","max","required","step","minlength","maxlength"],el=["color","date","datetime-local","month","range","time","week"],tl=["mousedown","touchstart"],nl=["click","keydown"],il=function(e){function t(n,i){void 0===i&&(i={});var r=e.call(this,st(st({},t.defaultAdapter),n))||this;return r.isFocused=!1,r.receivedUserInput=!1,r.valid=!0,r.useNativeValidation=!0,r.validateOnValueChange=!0,r.helperText=i.helperText,r.characterCounter=i.characterCounter,r.leadingIcon=i.leadingIcon,r.trailingIcon=i.trailingIcon,r.inputFocusHandler=function(){r.activateFocus()},r.inputBlurHandler=function(){r.deactivateFocus()},r.inputInputHandler=function(){r.handleInput()},r.setPointerXOffset=function(e){r.setTransformOrigin(e)},r.textFieldInteractionHandler=function(){r.handleTextFieldInteraction()},r.validationAttributeChangeHandler=function(e){r.handleValidationAttributeChange(e)},r}return tt(t,e),Object.defineProperty(t,"cssClasses",{get:function(){return Ka},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return Xa},enumerable:!1,configurable:!0}),Object.defineProperty(t,"numbers",{get:function(){return Ja},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"shouldAlwaysFloat",{get:function(){var e=this.getNativeInput().type;return el.indexOf(e)>=0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"shouldFloat",{get:function(){return this.shouldAlwaysFloat||this.isFocused||!!this.getValue()||this.isBadInput()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"shouldShake",{get:function(){return!this.isFocused&&!this.isValid()&&!!this.getValue()},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!0},setInputAttr:function(){},removeInputAttr:function(){},registerTextFieldInteractionHandler:function(){},deregisterTextFieldInteractionHandler:function(){},registerInputInteractionHandler:function(){},deregisterInputInteractionHandler:function(){},registerValidationAttributeChangeHandler:function(){return new MutationObserver((function(){}))},deregisterValidationAttributeChangeHandler:function(){},getNativeInput:function(){return null},isFocused:function(){return!1},activateLineRipple:function(){},deactivateLineRipple:function(){},setLineRippleTransformOrigin:function(){},shakeLabel:function(){},floatLabel:function(){},setLabelRequired:function(){},hasLabel:function(){return!1},getLabelWidth:function(){return 0},hasOutline:function(){return!1},notchOutline:function(){},closeOutline:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){var e,t,n,i;this.adapter.hasLabel()&&this.getNativeInput().required&&this.adapter.setLabelRequired(!0),this.adapter.isFocused()?this.inputFocusHandler():this.adapter.hasLabel()&&this.shouldFloat&&(this.notchOutline(!0),this.adapter.floatLabel(!0),this.styleFloating(!0)),this.adapter.registerInputInteractionHandler("focus",this.inputFocusHandler),this.adapter.registerInputInteractionHandler("blur",this.inputBlurHandler),this.adapter.registerInputInteractionHandler("input",this.inputInputHandler);try{for(var r=ot(tl),s=r.next();!s.done;s=r.next()){var o=s.value;this.adapter.registerInputInteractionHandler(o,this.setPointerXOffset)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}try{for(var a=ot(nl),l=a.next();!l.done;l=a.next()){o=l.value;this.adapter.registerTextFieldInteractionHandler(o,this.textFieldInteractionHandler)}}catch(e){n={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}this.validationObserver=this.adapter.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler),this.setcharacterCounter(this.getValue().length)},t.prototype.destroy=function(){var e,t,n,i;this.adapter.deregisterInputInteractionHandler("focus",this.inputFocusHandler),this.adapter.deregisterInputInteractionHandler("blur",this.inputBlurHandler),this.adapter.deregisterInputInteractionHandler("input",this.inputInputHandler);try{for(var r=ot(tl),s=r.next();!s.done;s=r.next()){var o=s.value;this.adapter.deregisterInputInteractionHandler(o,this.setPointerXOffset)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}try{for(var a=ot(nl),l=a.next();!l.done;l=a.next()){o=l.value;this.adapter.deregisterTextFieldInteractionHandler(o,this.textFieldInteractionHandler)}}catch(e){n={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}this.adapter.deregisterValidationAttributeChangeHandler(this.validationObserver)},t.prototype.handleTextFieldInteraction=function(){var e=this.adapter.getNativeInput();e&&e.disabled||(this.receivedUserInput=!0)},t.prototype.handleValidationAttributeChange=function(e){var t=this;e.some((function(e){return Qa.indexOf(e)>-1&&(t.styleValidity(!0),t.adapter.setLabelRequired(t.getNativeInput().required),!0)})),e.indexOf("maxlength")>-1&&this.setcharacterCounter(this.getValue().length)},t.prototype.notchOutline=function(e){if(this.adapter.hasOutline()&&this.adapter.hasLabel())if(e){var t=this.adapter.getLabelWidth()*Ja.LABEL_SCALE;this.adapter.notchOutline(t)}else this.adapter.closeOutline()},t.prototype.activateFocus=function(){this.isFocused=!0,this.styleFocused(this.isFocused),this.adapter.activateLineRipple(),this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.adapter.shakeLabel(this.shouldShake)),!this.helperText||!this.helperText.isPersistent()&&this.helperText.isValidation()&&this.valid||this.helperText.showToScreenReader()},t.prototype.setTransformOrigin=function(e){if(!this.isDisabled()&&!this.adapter.hasOutline()){var t=e.touches,n=t?t[0]:e,i=n.target.getBoundingClientRect(),r=n.clientX-i.left;this.adapter.setLineRippleTransformOrigin(r)}},t.prototype.handleInput=function(){this.autoCompleteFocus(),this.setcharacterCounter(this.getValue().length)},t.prototype.autoCompleteFocus=function(){this.receivedUserInput||this.activateFocus()},t.prototype.deactivateFocus=function(){this.isFocused=!1,this.adapter.deactivateLineRipple();var e=this.isValid();this.styleValidity(e),this.styleFocused(this.isFocused),this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.adapter.shakeLabel(this.shouldShake)),this.shouldFloat||(this.receivedUserInput=!1)},t.prototype.getValue=function(){return this.getNativeInput().value},t.prototype.setValue=function(e){if(this.getValue()!==e&&(this.getNativeInput().value=e),this.setcharacterCounter(e.length),this.validateOnValueChange){var t=this.isValid();this.styleValidity(t)}this.adapter.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter.floatLabel(this.shouldFloat),this.styleFloating(this.shouldFloat),this.validateOnValueChange&&this.adapter.shakeLabel(this.shouldShake))},t.prototype.isValid=function(){return this.useNativeValidation?this.isNativeInputValid():this.valid},t.prototype.setValid=function(e){this.valid=e,this.styleValidity(e);var t=!e&&!this.isFocused&&!!this.getValue();this.adapter.hasLabel()&&this.adapter.shakeLabel(t)},t.prototype.setValidateOnValueChange=function(e){this.validateOnValueChange=e},t.prototype.getValidateOnValueChange=function(){return this.validateOnValueChange},t.prototype.setUseNativeValidation=function(e){this.useNativeValidation=e},t.prototype.isDisabled=function(){return this.getNativeInput().disabled},t.prototype.setDisabled=function(e){this.getNativeInput().disabled=e,this.styleDisabled(e)},t.prototype.setHelperTextContent=function(e){this.helperText&&this.helperText.setContent(e)},t.prototype.setLeadingIconAriaLabel=function(e){this.leadingIcon&&this.leadingIcon.setAriaLabel(e)},t.prototype.setLeadingIconContent=function(e){this.leadingIcon&&this.leadingIcon.setContent(e)},t.prototype.setTrailingIconAriaLabel=function(e){this.trailingIcon&&this.trailingIcon.setAriaLabel(e)},t.prototype.setTrailingIconContent=function(e){this.trailingIcon&&this.trailingIcon.setContent(e)},t.prototype.setcharacterCounter=function(e){if(this.characterCounter){var t=this.getNativeInput().maxLength;if(-1===t)throw new Error("MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.");this.characterCounter.setCounterValue(e,t)}},t.prototype.isBadInput=function(){return this.getNativeInput().validity.badInput||!1},t.prototype.isNativeInputValid=function(){return this.getNativeInput().validity.valid},t.prototype.styleValidity=function(e){var n=t.cssClasses.INVALID;if(e?this.adapter.removeClass(n):this.adapter.addClass(n),this.helperText){if(this.helperText.setValidity(e),!this.helperText.isValidation())return;var i=this.helperText.isVisible(),r=this.helperText.getId();i&&r?this.adapter.setInputAttr(Xa.ARIA_DESCRIBEDBY,r):this.adapter.removeInputAttr(Xa.ARIA_DESCRIBEDBY)}},t.prototype.styleFocused=function(e){var n=t.cssClasses.FOCUSED;e?this.adapter.addClass(n):this.adapter.removeClass(n)},t.prototype.styleDisabled=function(e){var n=t.cssClasses,i=n.DISABLED,r=n.INVALID;e?(this.adapter.addClass(i),this.adapter.removeClass(r)):this.adapter.removeClass(i),this.leadingIcon&&this.leadingIcon.setDisabled(e),this.trailingIcon&&this.trailingIcon.setDisabled(e)},t.prototype.styleFloating=function(e){var n=t.cssClasses.LABEL_FLOATING;e?this.adapter.addClass(n):this.adapter.removeClass(n)},t.prototype.getNativeInput=function(){return(this.adapter?this.adapter.getNativeInput():null)||{disabled:!1,maxLength:-1,required:!1,type:"input",validity:{badInput:!1,valid:!0},value:""}},t}(La);function rl(e){return Object.entries(e).filter((([e,t])=>""!==e&&t)).map((([e])=>e)).join(" ")}function sl(e,t,n,i={bubbles:!0},r=!1){if("undefined"!=typeof Event&&e){const s=new CustomEvent(t,Object.assign(Object.assign({},i),{detail:n}));if(null==e||e.dispatchEvent(s),r&&t.startsWith("SMUI")){const r=new CustomEvent(t.replace(/^SMUI/g,(()=>"MDC")),Object.assign(Object.assign({},i),{detail:n}));null==e||e.dispatchEvent(r),r.defaultPrevented&&s.preventDefault()}return s}}function ol(e,t){let n=Object.getOwnPropertyNames(e);const i={};for(let r=0;r<n.length;r++){const s=n[r],o=s.indexOf("$");-1!==o&&-1!==t.indexOf(s.substring(0,o+1))||-1===t.indexOf(s)&&(i[s]=e[s])}return i}const al=/^[a-z]+(?::(?:preventDefault|stopPropagation|passive|nonpassive|capture|once|self))+$/,ll=/^[^$]+(?:\$(?:preventDefault|stopPropagation|passive|nonpassive|capture|once|self))+$/;function cl(e){let t,n=[];function i(t){ae(e,t)}return e.$on=(e,i)=>{let r=e,s=()=>{};t?s=t(r,i):n.push([r,i]);return r.match(al)&&console&&console.warn('Event modifiers in SMUI now use "$" instead of ":", so that all events can be bound with modifiers. Please update your event binding: ',r),()=>{s()}},e=>{const r=[],s={};t=(t,n)=>{let o=t,a=n,l=!1;const c=o.match(al),u=o.match(ll),d=c||u;if(o.match(/^SMUI:\w+:/)){const e=o.split(":");let t="";for(let n=0;n<e.length;n++)t+=n===e.length-1?":"+e[n]:e[n].split("-").map((e=>e.slice(0,1).toUpperCase()+e.slice(1))).join("");console.warn(`The event ${o.split("$")[0]} has been renamed to ${t.split("$")[0]}.`),o=t}if(d){const e=o.split(c?":":"$");o=e[0];const t=Object.fromEntries(e.slice(1).map((e=>[e,!0])));t.passive&&(l=l||{},l.passive=!0),t.nonpassive&&(l=l||{},l.passive=!1),t.capture&&(l=l||{},l.capture=!0),t.once&&(l=l||{},l.once=!0),t.preventDefault&&(h=a,a=function(e){return e.preventDefault(),h.call(this,e)}),t.stopPropagation&&(a=function(e){return function(t){return t.stopPropagation(),e.call(this,t)}}(a))}var h;const f=F(e,o,a,l),p=()=>{f();const e=r.indexOf(p);e>-1&&r.splice(e,1)};return r.push(p),o in s||(s[o]=F(e,o,i)),p};for(let e=0;e<n.length;e++)t(n[e][0],n[e][1]);return{destroy:()=>{for(let e=0;e<r.length;e++)r[e]();for(let e of Object.entries(s))e[1]()}}}}function ul(e,t){let n=Object.getOwnPropertyNames(e);const i={};for(let r=0;r<n.length;r++){const s=n[r];s.substring(0,t.length)===t&&(i[s.substring(t.length)]=e[s])}return i}function dl(e,t){let n=[];if(t)for(let i=0;i<t.length;i++){const r=t[i],s=Array.isArray(r)?r[0]:r;Array.isArray(r)&&r.length>1?n.push(s(e,r[1])):n.push(s(e))}return{update(e){if((e&&e.length||0)!=n.length)throw new Error("You must not change the length of an actions array.");if(e)for(let t=0;t<e.length;t++){const i=n[t];if(i&&i.update){const n=e[t];Array.isArray(n)&&n.length>1?i.update(n[1]):i.update()}}},destroy(){for(let e=0;e<n.length;e++){const t=n[e];t&&t.destroy&&t.destroy()}}}}function hl(e){let t,i,r,a,l;const c=e[6].default,u=f(c,e,e[5],null);let d=[e[3]],h={};for(let e=0;e<d.length;e+=1)h=n(h,d[e]);return{c(){t=D("span"),u&&u.c(),j(t,h)},m(n,s){I(n,t,s),u&&u.m(t,null),e[7](t),r=!0,a||(l=[E(i=dl.call(null,t,e[0])),E(e[2].call(null,t))],a=!0)},p(e,[n]){u&&u.p&&(!r||32&n)&&g(u,c,e,e[5],r?m(c,e[5],n,null):v(e[5]),null),j(t,h=Me(d,[8&n&&e[3]])),i&&o(i.update)&&1&n&&i.update.call(null,e[0])},i(e){r||(ke(u,e),r=!0)},o(e){Oe(u,e),r=!1},d(n){n&&M(t),u&&u.d(n),e[7](null),a=!1,s(l)}}}function fl(e,t,i){const r=["use","getElement"];let s=_(t,r),{$$slots:o={},$$scope:a}=t,{use:l=[]}=t;const c=cl(te());let u;return e.$$set=e=>{t=n(n({},t),y(e)),i(3,s=_(t,r)),"use"in e&&i(0,l=e.use),"$$scope"in e&&i(5,a=e.$$scope)},[l,u,c,s,function(){return u},a,o,function(e){ce[e?"unshift":"push"]((()=>{u=e,i(1,u)}))}]}function pl(e){let t;const n=e[4].default,i=f(n,e,e[3],null);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,[r]){i&&i.p&&(!t||8&r)&&g(i,n,e,e[3],t?m(n,e[3],r,null):v(e[3]),null)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function ml(e,t,n){let i,{$$slots:r={},$$scope:s}=t,{key:o}=t,{value:a}=t;const l=je(a);return h(e,l,(e=>n(5,i=e))),se(o,l),ie((()=>{l.set(void 0)})),e.$$set=e=>{"key"in e&&n(1,o=e.key),"value"in e&&n(2,a=e.value),"$$scope"in e&&n(3,s=e.$$scope)},e.$$.update=()=>{4&e.$$.dirty&&w(l,i=a,i)},[l,o,a,s,r]}class gl extends Fe{constructor(e){super(),Ve(this,e,ml,pl,a,{key:1,value:2})}}const{applyPassive:vl}=Aa,{matches:yl}=Na;function _l(e,{ripple:t=!0,surface:n=!1,unbounded:i=!1,disabled:r=!1,color:s,active:o,rippleElement:a,eventTarget:l,activeTarget:c,addClass:u=(t=>e.classList.add(t)),removeClass:d=(t=>e.classList.remove(t)),addStyle:h=((t,n)=>e.style.setProperty(t,n)),initPromise:f=Promise.resolve()}={}){let p,m,g=oe("SMUI:addLayoutListener"),v=o,y=l,_=c;function $(){n?(u("mdc-ripple-surface"),"primary"===s?(u("smui-ripple-surface--primary"),d("smui-ripple-surface--secondary")):"secondary"===s?(d("smui-ripple-surface--primary"),u("smui-ripple-surface--secondary")):(d("smui-ripple-surface--primary"),d("smui-ripple-surface--secondary"))):(d("mdc-ripple-surface"),d("smui-ripple-surface--primary"),d("smui-ripple-surface--secondary")),p&&v!==o&&(v=o,o?p.activate():!1===o&&p.deactivate()),t&&!p?(p=new Za({addClass:u,browserSupportsCssVars:()=>function(e,t){void 0===t&&(t=!1);var n,i=e.CSS;if("boolean"==typeof Ma&&!t)return Ma;if(!i||"function"!=typeof i.supports)return!1;var r=i.supports("--css-vars","yes"),s=i.supports("(--css-vars: yes)")&&i.supports("color","#00000000");return n=r||s,t||(Ma=n),n}(window),computeBoundingRect:()=>(a||e).getBoundingClientRect(),containsEventTarget:t=>e.contains(t),deregisterDocumentInteractionHandler:(e,t)=>document.documentElement.removeEventListener(e,t,vl()),deregisterInteractionHandler:(t,n)=>(l||e).removeEventListener(t,n,vl()),deregisterResizeHandler:e=>window.removeEventListener("resize",e),getWindowPageOffset:()=>({x:window.pageXOffset,y:window.pageYOffset}),isSurfaceActive:()=>null==o?yl(c||e,":active"):o,isSurfaceDisabled:()=>!!r,isUnbounded:()=>!!i,registerDocumentInteractionHandler:(e,t)=>document.documentElement.addEventListener(e,t,vl()),registerInteractionHandler:(t,n)=>(l||e).addEventListener(t,n,vl()),registerResizeHandler:e=>window.addEventListener("resize",e),removeClass:d,updateCssVariable:h}),f.then((()=>{p&&(p.init(),p.setUnbounded(i))}))):p&&!t&&f.then((()=>{p&&(p.destroy(),p=void 0)})),!p||y===l&&_===c||(y=l,_=c,p.destroy(),requestAnimationFrame((()=>{p&&(p.init(),p.setUnbounded(i))}))),!t&&i&&u("mdc-ripple-upgraded--unbounded")}return $(),g&&(m=g((function(){p&&p.layout()}))),{update(p){({ripple:t,surface:n,unbounded:i,disabled:r,color:s,active:o,rippleElement:a,eventTarget:l,activeTarget:c,addClass:u,removeClass:d,addStyle:h,initPromise:f}=Object.assign({ripple:!0,surface:!1,unbounded:!1,disabled:!1,color:void 0,active:void 0,rippleElement:void 0,eventTarget:void 0,activeTarget:void 0,addClass:t=>e.classList.add(t),removeClass:t=>e.classList.remove(t),addStyle:(t,n)=>e.style.setProperty(t,n),initPromise:Promise.resolve()},p)),$()},destroy(){p&&(p.destroy(),p=void 0,d("mdc-ripple-surface"),d("smui-ripple-surface--primary"),d("smui-ripple-surface--secondary")),m&&m()}}}function $l(e){let t,i,r,a,l,c,u,d;const h=e[22].default,p=f(h,e,e[21],null);let y=[{class:i=rl({[e[3]]:!0,"mdc-floating-label":!0,"mdc-floating-label--float-above":e[0],"mdc-floating-label--required":e[1],...e[8]})},{style:r=Object.entries(e[9]).map(xl).concat([e[4]]).join(" ")},{for:a=e[5]||(e[11]?e[11].id:void 0)},e[12]],_={};for(let e=0;e<y.length;e+=1)_=n(_,y[e]);return{c(){t=D("label"),p&&p.c(),j(t,_)},m(n,i){I(n,t,i),p&&p.m(t,null),e[24](t),c=!0,u||(d=[E(l=dl.call(null,t,e[2])),E(e[10].call(null,t))],u=!0)},p(e,n){p&&p.p&&(!c||2097152&n)&&g(p,h,e,e[21],c?m(h,e[21],n,null):v(e[21]),null),j(t,_=Me(y,[(!c||267&n&&i!==(i=rl({[e[3]]:!0,"mdc-floating-label":!0,"mdc-floating-label--float-above":e[0],"mdc-floating-label--required":e[1],...e[8]})))&&{class:i},(!c||528&n&&r!==(r=Object.entries(e[9]).map(xl).concat([e[4]]).join(" ")))&&{style:r},(!c||32&n&&a!==(a=e[5]||(e[11]?e[11].id:void 0)))&&{for:a},4096&n&&e[12]])),l&&o(l.update)&&4&n&&l.update.call(null,e[2])},i(e){c||(ke(p,e),c=!0)},o(e){Oe(p,e),c=!1},d(n){n&&M(t),p&&p.d(n),e[24](null),u=!1,s(d)}}}function bl(e){let t,i,r,a,l,c,u;const d=e[22].default,h=f(d,e,e[21],null);let p=[{class:i=rl({[e[3]]:!0,"mdc-floating-label":!0,"mdc-floating-label--float-above":e[0],"mdc-floating-label--required":e[1],...e[8]})},{style:r=Object.entries(e[9]).map(El).concat([e[4]]).join(" ")},e[12]],y={};for(let e=0;e<p.length;e+=1)y=n(y,p[e]);return{c(){t=D("span"),h&&h.c(),j(t,y)},m(n,i){I(n,t,i),h&&h.m(t,null),e[23](t),l=!0,c||(u=[E(a=dl.call(null,t,e[2])),E(e[10].call(null,t))],c=!0)},p(e,n){h&&h.p&&(!l||2097152&n)&&g(h,d,e,e[21],l?m(d,e[21],n,null):v(e[21]),null),j(t,y=Me(p,[(!l||267&n&&i!==(i=rl({[e[3]]:!0,"mdc-floating-label":!0,"mdc-floating-label--float-above":e[0],"mdc-floating-label--required":e[1],...e[8]})))&&{class:i},(!l||528&n&&r!==(r=Object.entries(e[9]).map(El).concat([e[4]]).join(" ")))&&{style:r},4096&n&&e[12]])),a&&o(a.update)&&4&n&&a.update.call(null,e[2])},i(e){l||(ke(h,e),l=!0)},o(e){Oe(h,e),l=!1},d(n){n&&M(t),h&&h.d(n),e[23](null),c=!1,s(u)}}}function wl(e){let t,n,i,r;const s=[bl,$l],o=[];function a(e,t){return e[6]?0:1}return t=a(e),n=o[t]=s[t](e),{c(){n.c(),i=V()},m(e,n){o[t].m(e,n),I(e,i,n),r=!0},p(e,[r]){let l=t;t=a(e),t===l?o[t].p(e,r):(Te(),Oe(o[l],1,1,(()=>{o[l]=null})),Se(),n=o[t],n?n.p(e,r):(n=o[t]=s[t](e),n.c()),ke(n,1),n.m(i.parentNode,i))},i(e){r||(ke(n),r=!0)},o(e){Oe(n),r=!1},d(e){o[t].d(e),e&&M(i)}}}const El=([e,t])=>`${e}: ${t};`,xl=([e,t])=>`${e}: ${t};`;function Cl(e,t,i){const r=["use","class","style","for","floatAbove","required","wrapped","shake","float","setRequired","getWidth","getElement"];let s=_(t,r),{$$slots:o={},$$scope:a}=t;var l;const c=cl(te());let u,d,{use:h=[]}=t,{class:f=""}=t,{style:p=""}=t,{for:m}=t,{floatAbove:g=!1}=t,{required:v=!1}=t,{wrapped:$=!1}=t,b={},w={},E=null!==(l=oe("SMUI:generic:input:props"))&&void 0!==l?l:{},x=g,C=v;function T(e){b[e]||i(8,b[e]=!0,b)}function S(e){e in b&&!b[e]||i(8,b[e]=!1,b)}function k(e,t){w[e]!=t&&(""===t||null==t?(delete w[e],i(9,w)):i(9,w[e]=t,w))}function O(e){e in w&&(delete w[e],i(9,w))}function L(){return u}return ne((()=>{i(18,d=new Pa({addClass:T,removeClass:S,getWidth:()=>{var e,t;const n=L(),i=n.cloneNode(!0);null===(e=n.parentNode)||void 0===e||e.appendChild(i),i.classList.add("smui-floating-label--remove-transition"),i.classList.add("smui-floating-label--force-size"),i.classList.remove("mdc-floating-label--float-above");const r=i.scrollWidth;return null===(t=n.parentNode)||void 0===t||t.removeChild(i),r},registerInteractionHandler:(e,t)=>L().addEventListener(e,t),deregisterInteractionHandler:(e,t)=>L().removeEventListener(e,t)}));const e={get element(){return L()},addStyle:k,removeStyle:O};return sl(u,"SMUIFloatingLabel:mount",e),d.init(),()=>{sl(u,"SMUIFloatingLabel:unmount",e),d.destroy()}})),e.$$set=e=>{t=n(n({},t),y(e)),i(12,s=_(t,r)),"use"in e&&i(2,h=e.use),"class"in e&&i(3,f=e.class),"style"in e&&i(4,p=e.style),"for"in e&&i(5,m=e.for),"floatAbove"in e&&i(0,g=e.floatAbove),"required"in e&&i(1,v=e.required),"wrapped"in e&&i(6,$=e.wrapped),"$$scope"in e&&i(21,a=e.$$scope)},e.$$.update=()=>{786433&e.$$.dirty&&d&&x!==g&&(i(19,x=g),d.float(g)),1310722&e.$$.dirty&&d&&C!==v&&(i(20,C=v),d.setRequired(v))},[g,v,h,f,p,m,$,u,b,w,c,E,s,function(e){d.shake(e)},function(e){i(0,g=e)},function(e){i(1,v=e)},function(){return d.getWidth()},L,d,x,C,a,o,function(e){ce[e?"unshift":"push"]((()=>{u=e,i(7,u)}))},function(e){ce[e?"unshift":"push"]((()=>{u=e,i(7,u)}))}]}class Tl extends Fe{constructor(e){super(),Ve(this,e,Cl,wl,a,{use:2,class:3,style:4,for:5,floatAbove:0,required:1,wrapped:6,shake:13,float:14,setRequired:15,getWidth:16,getElement:17})}get shake(){return this.$$.ctx[13]}get float(){return this.$$.ctx[14]}get setRequired(){return this.$$.ctx[15]}get getWidth(){return this.$$.ctx[16]}get getElement(){return this.$$.ctx[17]}}function Sl(t){let i,r,a,l,c,u,d=[{class:r=rl({[t[1]]:!0,"mdc-line-ripple":!0,"mdc-line-ripple--active":t[3],...t[5]})},{style:a=Object.entries(t[6]).map(kl).concat([t[2]]).join(" ")},t[8]],h={};for(let e=0;e<d.length;e+=1)h=n(h,d[e]);return{c(){i=D("div"),j(i,h)},m(e,n){I(e,i,n),t[13](i),c||(u=[E(l=dl.call(null,i,t[0])),E(t[7].call(null,i))],c=!0)},p(e,[t]){j(i,h=Me(d,[42&t&&r!==(r=rl({[e[1]]:!0,"mdc-line-ripple":!0,"mdc-line-ripple--active":e[3],...e[5]}))&&{class:r},68&t&&a!==(a=Object.entries(e[6]).map(kl).concat([e[2]]).join(" "))&&{style:a},256&t&&e[8]])),l&&o(l.update)&&1&t&&l.update.call(null,e[0])},i:e,o:e,d(e){e&&M(i),t[13](null),c=!1,s(u)}}}const kl=([e,t])=>`${e}: ${t};`;function Ol(e,t,i){const r=["use","class","style","active","activate","deactivate","setRippleCenter","getElement"];let s=_(t,r);const o=cl(te());let a,l,{use:c=[]}=t,{class:u=""}=t,{style:d=""}=t,{active:h=!1}=t,f={},p={};function m(e){return e in f?f[e]:b().classList.contains(e)}function g(e){f[e]||i(5,f[e]=!0,f)}function v(e){e in f&&!f[e]||i(5,f[e]=!1,f)}function $(e,t){p[e]!=t&&(""===t||null==t?(delete p[e],i(6,p)):i(6,p[e]=t,p))}function b(){return a}return ne((()=>(l=new Ua({addClass:g,removeClass:v,hasClass:m,setStyle:$,registerEventHandler:(e,t)=>b().addEventListener(e,t),deregisterEventHandler:(e,t)=>b().removeEventListener(e,t)}),l.init(),()=>{l.destroy()}))),e.$$set=e=>{t=n(n({},t),y(e)),i(8,s=_(t,r)),"use"in e&&i(0,c=e.use),"class"in e&&i(1,u=e.class),"style"in e&&i(2,d=e.style),"active"in e&&i(3,h=e.active)},[c,u,d,h,a,f,p,o,s,function(){l.activate()},function(){l.deactivate()},function(e){l.setRippleCenter(e)},b,function(e){ce[e?"unshift":"push"]((()=>{a=e,i(4,a)}))}]}class Ll extends Fe{constructor(e){super(),Ve(this,e,Ol,Sl,a,{use:0,class:1,style:2,active:3,activate:9,deactivate:10,setRippleCenter:11,getElement:12})}get activate(){return this.$$.ctx[9]}get deactivate(){return this.$$.ctx[10]}get setRippleCenter(){return this.$$.ctx[11]}get getElement(){return this.$$.ctx[12]}}function Al(e){let t,n,i;const r=e[14].default,s=f(r,e,e[13],null);return{c(){t=D("div"),s&&s.c(),Y(t,"class","mdc-notched-outline__notch"),Y(t,"style",n=Object.entries(e[7]).map(Ml).join(" "))},m(e,n){I(e,t,n),s&&s.m(t,null),i=!0},p(e,o){s&&s.p&&(!i||8192&o)&&g(s,r,e,e[13],i?m(r,e[13],o,null):v(e[13]),null),(!i||128&o&&n!==(n=Object.entries(e[7]).map(Ml).join(" ")))&&Y(t,"style",n)},i(e){i||(ke(s,e),i=!0)},o(e){Oe(s,e),i=!1},d(e){e&&M(t),s&&s.d(e)}}}function Il(e){let t,i,r,a,l,c,u,d,h,f,p=!e[3]&&Al(e),m=[{class:c=rl({[e[1]]:!0,"mdc-notched-outline":!0,"mdc-notched-outline--notched":e[2],"mdc-notched-outline--no-label":e[3],...e[6]})},e[9]],g={};for(let e=0;e<m.length;e+=1)g=n(g,m[e]);return{c(){t=D("div"),i=D("div"),r=U(),p&&p.c(),a=U(),l=D("div"),Y(i,"class","mdc-notched-outline__leading"),Y(l,"class","mdc-notched-outline__trailing"),j(t,g)},m(n,s){I(n,t,s),O(t,i),O(t,r),p&&p.m(t,null),O(t,a),O(t,l),e[15](t),d=!0,h||(f=[E(u=dl.call(null,t,e[0])),E(e[8].call(null,t)),F(t,"SMUIFloatingLabel:mount",e[16]),F(t,"SMUIFloatingLabel:unmount",e[17])],h=!0)},p(e,[n]){e[3]?p&&(Te(),Oe(p,1,1,(()=>{p=null})),Se()):p?(p.p(e,n),8&n&&ke(p,1)):(p=Al(e),p.c(),ke(p,1),p.m(t,a)),j(t,g=Me(m,[(!d||78&n&&c!==(c=rl({[e[1]]:!0,"mdc-notched-outline":!0,"mdc-notched-outline--notched":e[2],"mdc-notched-outline--no-label":e[3],...e[6]})))&&{class:c},512&n&&e[9]])),u&&o(u.update)&&1&n&&u.update.call(null,e[0])},i(e){d||(ke(p),d=!0)},o(e){Oe(p),d=!1},d(n){n&&M(t),p&&p.d(),e[15](null),h=!1,s(f)}}}const Ml=([e,t])=>`${e}: ${t};`;function Nl(e,t,i){const r=["use","class","notched","noLabel","notch","closeNotch","getElement"];let s=_(t,r),{$$slots:o={},$$scope:a}=t;const l=cl(te());let c,u,d,{use:h=[]}=t,{class:f=""}=t,{notched:p=!1}=t,{noLabel:m=!1}=t,g={},v={};function $(e){g[e]||i(6,g[e]=!0,g)}function b(e){e in g&&!g[e]||i(6,g[e]=!1,g)}ne((()=>(u=new ja({addClass:$,removeClass:b,setNotchWidthProperty:e=>{return n=e+"px",void(v[t="width"]!=n&&(""===n||null==n?(delete v[t],i(7,v)):i(7,v[t]=n,v)));var t,n},removeNotchWidthProperty:()=>{var e;(e="width")in v&&(delete v[e],i(7,v))}}),u.init(),()=>{u.destroy()})));return e.$$set=e=>{t=n(n({},t),y(e)),i(9,s=_(t,r)),"use"in e&&i(0,h=e.use),"class"in e&&i(1,f=e.class),"notched"in e&&i(2,p=e.notched),"noLabel"in e&&i(3,m=e.noLabel),"$$scope"in e&&i(13,a=e.$$scope)},e.$$.update=()=>{16&e.$$.dirty&&(d?(d.addStyle("transition-duration","0s"),$("mdc-notched-outline--upgraded"),requestAnimationFrame((()=>{d&&d.removeStyle("transition-duration")}))):b("mdc-notched-outline--upgraded"))},[h,f,p,m,d,c,g,v,l,s,function(e){u.notch(e)},function(){u.closeNotch()},function(){return c},a,o,function(e){ce[e?"unshift":"push"]((()=>{c=e,i(5,c)}))},e=>i(4,d=e.detail),()=>i(4,d=void 0)]}class Dl extends Fe{constructor(e){super(),Ve(this,e,Nl,Il,a,{use:0,class:1,notched:2,noLabel:3,notch:10,closeNotch:11,getElement:12})}get notch(){return this.$$.ctx[10]}get closeNotch(){return this.$$.ctx[11]}get getElement(){return this.$$.ctx[12]}}function Pl(e){let t,i,r,a,l;const c=e[6].default,u=f(c,e,e[5],null);let d=[e[3]],h={};for(let e=0;e<d.length;e+=1)h=n(h,d[e]);return{c(){t=D("div"),u&&u.c(),j(t,h)},m(n,s){I(n,t,s),u&&u.m(t,null),e[7](t),r=!0,a||(l=[E(i=dl.call(null,t,e[0])),E(e[2].call(null,t))],a=!0)},p(e,[n]){u&&u.p&&(!r||32&n)&&g(u,c,e,e[5],r?m(c,e[5],n,null):v(e[5]),null),j(t,h=Me(d,[8&n&&e[3]])),i&&o(i.update)&&1&n&&i.update.call(null,e[0])},i(e){r||(ke(u,e),r=!0)},o(e){Oe(u,e),r=!1},d(n){n&&M(t),u&&u.d(n),e[7](null),a=!1,s(l)}}}function Rl(e,t,i){const r=["use","getElement"];let s=_(t,r),{$$slots:o={},$$scope:a}=t,{use:l=[]}=t;const c=cl(te());let u;return e.$$set=e=>{t=n(n({},t),y(e)),i(3,s=_(t,r)),"use"in e&&i(0,l=e.use),"$$scope"in e&&i(5,a=e.$$scope)},[l,u,c,s,function(){return u},a,o,function(e){ce[e?"unshift":"push"]((()=>{u=e,i(1,u)}))}]}class Ul extends Fe{constructor(e){super(),Ve(this,e,Rl,Pl,a,{use:0,getElement:4})}get getElement(){return this.$$.ctx[4]}}function Vl(e){let t;const n=e[10].default,i=f(n,e,e[12],null);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||4096&r)&&g(i,n,e,e[12],t?m(n,e[12],r,null):v(e[12]),null)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Fl(e){let t,i,r;const s=[{use:[e[7],...e[0]]},{class:rl({[e[1]]:!0,[e[5]]:!0,...e[4]})},e[6],e[8]];var o=e[2];function a(e){let t={$$slots:{default:[Vl]},$$scope:{ctx:e}};for(let e=0;e<s.length;e+=1)t=n(t,s[e]);return{props:t}}return o&&(t=new o(a(e)),e[11](t)),{c(){t&&Pe(t.$$.fragment),i=V()},m(e,n){t&&Re(t,e,n),I(e,i,n),r=!0},p(e,[n]){const r=499&n?Me(s,[129&n&&{use:[e[7],...e[0]]},50&n&&{class:rl({[e[1]]:!0,[e[5]]:!0,...e[4]})},64&n&&Ne(e[6]),256&n&&Ne(e[8])]):{};if(4096&n&&(r.$$scope={dirty:n,ctx:e}),o!==(o=e[2])){if(t){Te();const e=t;Oe(e.$$.fragment,1,0,(()=>{Ue(e,1)})),Se()}o?(t=new o(a(e)),e[11](t),Pe(t.$$.fragment),ke(t.$$.fragment,1),Re(t,i.parentNode,i)):t=null}else o&&t.$set(r)},i(e){r||(t&&ke(t.$$.fragment,e),r=!0)},o(e){t&&Oe(t.$$.fragment,e),r=!1},d(n){e[11](null),n&&M(i),t&&Ue(t,n)}}}const Yl={component:Ul,class:"",classMap:{},contexts:{},props:{}};function jl(e,t,i){const r=["use","class","component","getElement"];let s,o=_(t,r),{$$slots:a={},$$scope:l}=t,{use:c=[]}=t,{class:u=""}=t;const d=Yl.class,h={},f=[],p=Yl.contexts,m=Yl.props;let{component:g=Yl.component}=t;Object.entries(Yl.classMap).forEach((([e,t])=>{const n=oe(t);n&&"subscribe"in n&&f.push(n.subscribe((t=>{i(4,h[e]=t,h)})))}));const v=cl(te());for(let e in p)p.hasOwnProperty(e)&&se(e,p[e]);return ie((()=>{for(const e of f)e()})),e.$$set=e=>{t=n(n({},t),y(e)),i(8,o=_(t,r)),"use"in e&&i(0,c=e.use),"class"in e&&i(1,u=e.class),"component"in e&&i(2,g=e.component),"$$scope"in e&&i(12,l=e.$$scope)},[c,u,g,s,h,d,m,v,o,function(){return s.getElement()},a,function(e){ce[e?"unshift":"push"]((()=>{s=e,i(3,s)}))},l]}class Hl extends Fe{constructor(e){super(),Ve(this,e,jl,Fl,a,{use:0,class:1,component:2,getElement:9})}get getElement(){return this.$$.ctx[9]}}const zl=Object.assign({},Yl);function Gl(e){return new Proxy(Hl,{construct:function(t,n){return Object.assign(Yl,zl,e),new t(...n)},get:function(t,n){return Object.assign(Yl,zl,e),t[n]}})}const Bl=Ul,Wl=class extends Fe{constructor(e){super(),Ve(this,e,fl,hl,a,{use:0,getElement:4})}get getElement(){return this.$$.ctx[4]}};var ql=Gl({class:"mdc-text-field-helper-line",component:Bl}),Zl=Gl({class:"mdc-text-field__affix mdc-text-field__affix--prefix",component:Wl}),Xl=Gl({class:"mdc-text-field__affix mdc-text-field__affix--suffix",component:Wl});function Kl(t){let i,r,a,l,c,u=[{class:r=rl({[t[1]]:!0,"mdc-text-field__input":!0})},{type:t[2]},{placeholder:t[3]},t[4],t[6],t[10]],d={};for(let e=0;e<u.length;e+=1)d=n(d,u[e]);return{c(){i=D("input"),j(i,d)},m(e,n){I(e,i,n),i.autofocus&&i.focus(),t[26](i),l||(c=[E(a=dl.call(null,i,t[0])),E(t[7].call(null,i)),F(i,"input",t[27]),F(i,"change",t[9]),F(i,"blur",t[24]),F(i,"focus",t[25])],l=!0)},p(e,[t]){j(i,d=Me(u,[2&t&&r!==(r=rl({[e[1]]:!0,"mdc-text-field__input":!0}))&&{class:r},4&t&&{type:e[2]},8&t&&{placeholder:e[3]},16&t&&e[4],64&t&&e[6],1024&t&&e[10]])),a&&o(a.update)&&1&t&&a.update.call(null,e[0])},i:e,o:e,d(e){e&&M(i),t[26](null),l=!1,s(c)}}}function Jl(e,t,i){const r=["use","class","type","placeholder","value","files","dirty","invalid","updateInvalid","emptyValueNull","emptyValueUndefined","getAttr","addAttr","removeAttr","focus","blur","getElement"];let s=_(t,r);const o=cl(te());let a=()=>{};let{use:l=[]}=t,{class:c=""}=t,{type:u="text"}=t,{placeholder:d=" "}=t,{value:h=a}=t;const f=function(e){return e===a}(h);f&&(h="");let{files:p=null}=t,{dirty:m=!1}=t,{invalid:g=!1}=t,{updateInvalid:v=!0}=t,{emptyValueNull:$=null===h}=t;f&&$&&(h=null);let b,{emptyValueUndefined:w=void 0===h}=t;f&&w&&(h=void 0);let E={},x={};function C(e){if("file"!==u)if(""===e.currentTarget.value&&$)i(11,h=null);else if(""===e.currentTarget.value&&w)i(11,h=void 0);else switch(u){case"number":case"range":i(11,h=function(e){if(""===e){const e=new Number(Number.NaN);return e.length=0,e}return+e}(e.currentTarget.value));break;default:i(11,h=e.currentTarget.value)}else i(12,p=e.currentTarget.files)}function T(){return b}ne((()=>{v&&i(14,g=b.matches(":invalid"))}));return e.$$set=e=>{t=n(n({},t),y(e)),i(10,s=_(t,r)),"use"in e&&i(0,l=e.use),"class"in e&&i(1,c=e.class),"type"in e&&i(2,u=e.type),"placeholder"in e&&i(3,d=e.placeholder),"value"in e&&i(11,h=e.value),"files"in e&&i(12,p=e.files),"dirty"in e&&i(13,m=e.dirty),"invalid"in e&&i(14,g=e.invalid),"updateInvalid"in e&&i(15,v=e.updateInvalid),"emptyValueNull"in e&&i(16,$=e.emptyValueNull),"emptyValueUndefined"in e&&i(17,w=e.emptyValueUndefined)},e.$$.update=()=>{2068&e.$$.dirty&&("file"===u?(delete x.value,i(4,x),i(2,u),i(11,h)):i(4,x.value=null==h?"":h,x))},[l,c,u,d,x,b,E,o,C,function(e){"file"!==u&&"range"!==u||C(e),i(13,m=!0),v&&i(14,g=b.matches(":invalid"))},s,h,p,m,g,v,$,w,function(e){var t;return e in E?null!==(t=E[e])&&void 0!==t?t:null:T().getAttribute(e)},function(e,t){E[e]!==t&&i(6,E[e]=t,E)},function(e){e in E&&null==E[e]||i(6,E[e]=void 0,E)},function(){T().focus()},function(){T().blur()},T,function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)},function(e){ce[e?"unshift":"push"]((()=>{b=e,i(5,b)}))},e=>"file"!==u&&C(e)]}class Ql extends Fe{constructor(e){super(),Ve(this,e,Jl,Kl,a,{use:0,class:1,type:2,placeholder:3,value:11,files:12,dirty:13,invalid:14,updateInvalid:15,emptyValueNull:16,emptyValueUndefined:17,getAttr:18,addAttr:19,removeAttr:20,focus:21,blur:22,getElement:23})}get getAttr(){return this.$$.ctx[18]}get addAttr(){return this.$$.ctx[19]}get removeAttr(){return this.$$.ctx[20]}get focus(){return this.$$.ctx[21]}get blur(){return this.$$.ctx[22]}get getElement(){return this.$$.ctx[23]}}function ec(t){let i,r,a,l,c,u,d=[{class:r=rl({[t[2]]:!0,"mdc-text-field__input":!0})},{style:a=`${t[4]?"":"resize: none; "}${t[3]}`},t[6],t[9]],h={};for(let e=0;e<d.length;e+=1)h=n(h,d[e]);return{c(){i=D("textarea"),j(i,h)},m(e,n){I(e,i,n),i.autofocus&&i.focus(),t[21](i),z(i,t[0]),c||(u=[E(l=dl.call(null,i,t[1])),E(t[7].call(null,i)),F(i,"change",t[8]),F(i,"blur",t[19]),F(i,"focus",t[20]),F(i,"input",t[22])],c=!0)},p(e,[t]){j(i,h=Me(d,[4&t&&r!==(r=rl({[e[2]]:!0,"mdc-text-field__input":!0}))&&{class:r},24&t&&a!==(a=`${e[4]?"":"resize: none; "}${e[3]}`)&&{style:a},64&t&&e[6],512&t&&e[9]])),l&&o(l.update)&&2&t&&l.update.call(null,e[1]),1&t&&z(i,e[0])},i:e,o:e,d(e){e&&M(i),t[21](null),c=!1,s(u)}}}function tc(e,t,i){const r=["use","class","style","value","dirty","invalid","updateInvalid","resizable","getAttr","addAttr","removeAttr","focus","blur","getElement"];let s=_(t,r);const o=cl(te());let a,{use:l=[]}=t,{class:c=""}=t,{style:u=""}=t,{value:d=""}=t,{dirty:h=!1}=t,{invalid:f=!1}=t,{updateInvalid:p=!0}=t,{resizable:m=!0}=t,g={};function v(){return a}return ne((()=>{p&&i(11,f=a.matches(":invalid"))})),e.$$set=e=>{t=n(n({},t),y(e)),i(9,s=_(t,r)),"use"in e&&i(1,l=e.use),"class"in e&&i(2,c=e.class),"style"in e&&i(3,u=e.style),"value"in e&&i(0,d=e.value),"dirty"in e&&i(10,h=e.dirty),"invalid"in e&&i(11,f=e.invalid),"updateInvalid"in e&&i(12,p=e.updateInvalid),"resizable"in e&&i(4,m=e.resizable)},[d,l,c,u,m,a,g,o,function(){i(10,h=!0),p&&i(11,f=a.matches(":invalid"))},s,h,f,p,function(e){var t;return e in g?null!==(t=g[e])&&void 0!==t?t:null:v().getAttribute(e)},function(e,t){g[e]!==t&&i(6,g[e]=t,g)},function(e){e in g&&null==g[e]||i(6,g[e]=void 0,g)},function(){v().focus()},function(){v().blur()},v,function(t){ae.call(this,e,t)},function(t){ae.call(this,e,t)},function(e){ce[e?"unshift":"push"]((()=>{a=e,i(5,a)}))},function(){d=this.value,i(0,d)}]}class nc extends Fe{constructor(e){super(),Ve(this,e,tc,ec,a,{use:1,class:2,style:3,value:0,dirty:10,invalid:11,updateInvalid:12,resizable:4,getAttr:13,addAttr:14,removeAttr:15,focus:16,blur:17,getElement:18})}get getAttr(){return this.$$.ctx[13]}get addAttr(){return this.$$.ctx[14]}get removeAttr(){return this.$$.ctx[15]}get focus(){return this.$$.ctx[16]}get blur(){return this.$$.ctx[17]}get getElement(){return this.$$.ctx[18]}}const ic=e=>({}),rc=e=>({}),sc=e=>({}),oc=e=>({}),ac=e=>({}),lc=e=>({}),cc=e=>({}),uc=e=>({}),dc=e=>({}),hc=e=>({}),fc=e=>({}),pc=e=>({}),mc=e=>({}),gc=e=>({}),vc=e=>({}),yc=e=>({}),_c=e=>({}),$c=e=>({}),bc=e=>({}),wc=e=>({}),Ec=e=>({}),xc=e=>({}),Cc=e=>({}),Tc=e=>({});function Sc(e){let t,i,r,a,l,c,u,d,h,p,y,_,$,b;const w=e[51].label,x=f(w,e,e[90],hc);r=new gl({props:{key:"SMUI:textfield:icon:leading",value:!0,$$slots:{default:[Oc]},$$scope:{ctx:e}}});const C=e[51].default,T=f(C,e,e[90],null);c=new gl({props:{key:"SMUI:textfield:icon:leading",value:!1,$$slots:{default:[Lc]},$$scope:{ctx:e}}});const S=e[51].ripple,k=f(S,e,e[90],oc);let L=[{class:d=rl({[e[9]]:!0,"mdc-text-field":!0,"mdc-text-field--disabled":e[12],"mdc-text-field--textarea":e[14],"mdc-text-field--filled":"filled"===e[15],"mdc-text-field--outlined":"outlined"===e[15],"smui-text-field--standard":"standard"===e[15]&&!e[14],"mdc-text-field--no-label":e[16]||!e[42].label,"mdc-text-field--with-leading-icon":e[42].leadingIcon,"mdc-text-field--with-trailing-icon":e[42].trailingIcon,"mdc-text-field--invalid":e[1],...e[25]})},{style:h=Object.entries(e[26]).map(Jc).concat([e[10]]).join(" ")},ol(e[41],["input$","label$","ripple$","outline$","helperLine$"])],A={};for(let e=0;e<L.length;e+=1)A=n(A,L[e]);return{c(){t=D("div"),x&&x.c(),i=U(),Pe(r.$$.fragment),a=U(),T&&T.c(),l=U(),Pe(c.$$.fragment),u=U(),k&&k.c(),j(t,A)},m(n,s){I(n,t,s),x&&x.m(t,null),O(t,i),Re(r,t,null),O(t,a),T&&T.m(t,null),O(t,l),Re(c,t,null),O(t,u),k&&k.m(t,null),e[80](t),_=!0,$||(b=[E(p=_l.call(null,t,{ripple:e[11],unbounded:!1,addClass:e[38],removeClass:e[39],addStyle:e[40]})),E(y=dl.call(null,t,e[8])),E(e[34].call(null,t)),F(t,"SMUITextfieldLeadingIcon:mount",e[81]),F(t,"SMUITextfieldLeadingIcon:unmount",e[82]),F(t,"SMUITextfieldTrailingIcon:mount",e[83]),F(t,"SMUITextfieldTrailingIcon:unmount",e[84])],$=!0)},p(e,n){x&&x.p&&(!_||268435456&n[2])&&g(x,w,e,e[90],_?m(w,e[90],n,dc):v(e[90]),hc);const i={};268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),r.$set(i),T&&T.p&&(!_||268435456&n[2])&&g(T,C,e,e[90],_?m(C,e[90],n,null):v(e[90]),null);const s={};268435456&n[2]&&(s.$$scope={dirty:n,ctx:e}),c.$set(s),k&&k.p&&(!_||268435456&n[2])&&g(k,S,e,e[90],_?m(S,e[90],n,sc):v(e[90]),oc),j(t,A=Me(L,[(!_||33673730&n[0]|2048&n[1]&&d!==(d=rl({[e[9]]:!0,"mdc-text-field":!0,"mdc-text-field--disabled":e[12],"mdc-text-field--textarea":e[14],"mdc-text-field--filled":"filled"===e[15],"mdc-text-field--outlined":"outlined"===e[15],"smui-text-field--standard":"standard"===e[15]&&!e[14],"mdc-text-field--no-label":e[16]||!e[42].label,"mdc-text-field--with-leading-icon":e[42].leadingIcon,"mdc-text-field--with-trailing-icon":e[42].trailingIcon,"mdc-text-field--invalid":e[1],...e[25]})))&&{class:d},(!_||67109888&n[0]&&h!==(h=Object.entries(e[26]).map(Jc).concat([e[10]]).join(" ")))&&{style:h},1024&n[1]&&ol(e[41],["input$","label$","ripple$","outline$","helperLine$"])])),p&&o(p.update)&&2048&n[0]&&p.update.call(null,{ripple:e[11],unbounded:!1,addClass:e[38],removeClass:e[39],addStyle:e[40]}),y&&o(y.update)&&256&n[0]&&y.update.call(null,e[8])},i(e){_||(ke(x,e),ke(r.$$.fragment,e),ke(T,e),ke(c.$$.fragment,e),ke(k,e),_=!0)},o(e){Oe(x,e),Oe(r.$$.fragment,e),Oe(T,e),Oe(c.$$.fragment,e),Oe(k,e),_=!1},d(n){n&&M(t),x&&x.d(n),Ue(r),T&&T.d(n),Ue(c),k&&k.d(n),e[80](null),$=!1,s(b)}}}function kc(e){let t,i,r,a,l,c,u,d,h,p,y,_,$,b,w,x,C,T,S=!e[14]&&"outlined"!==e[15]&&Ac(e),k=(e[14]||"outlined"===e[15])&&Dc(e);a=new gl({props:{key:"SMUI:textfield:icon:leading",value:!0,$$slots:{default:[Vc]},$$scope:{ctx:e}}});const L=e[51].default,A=f(L,e,e[90],null),N=[Yc,Fc],P=[];function R(e,t){return e[14]&&"string"==typeof e[0]?0:1}u=R(e),d=P[u]=N[u](e),p=new gl({props:{key:"SMUI:textfield:icon:leading",value:!1,$$slots:{default:[Bc]},$$scope:{ctx:e}}});let V=!e[14]&&"outlined"!==e[15]&&e[11]&&Wc(e),Y=[{class:_=rl({[e[9]]:!0,"mdc-text-field":!0,"mdc-text-field--disabled":e[12],"mdc-text-field--textarea":e[14],"mdc-text-field--filled":"filled"===e[15],"mdc-text-field--outlined":"outlined"===e[15],"smui-text-field--standard":"standard"===e[15]&&!e[14],"mdc-text-field--no-label":e[16]||null==e[17]&&!e[42].label,"mdc-text-field--label-floating":e[28]||null!=e[0]&&""!==e[0],"mdc-text-field--with-leading-icon":e[35](e[22])?e[42].leadingIcon:e[22],"mdc-text-field--with-trailing-icon":e[35](e[23])?e[42].trailingIcon:e[23],"mdc-text-field--with-internal-counter":e[14]&&e[42].internalCounter,"mdc-text-field--invalid":e[1],...e[25]})},{style:$=Object.entries(e[26]).map(Kc).concat([e[10]]).join(" ")},{for:void 0},ol(e[41],["input$","label$","ripple$","outline$","helperLine$"])],H={};for(let e=0;e<Y.length;e+=1)H=n(H,Y[e]);return{c(){t=D("label"),S&&S.c(),i=U(),k&&k.c(),r=U(),Pe(a.$$.fragment),l=U(),A&&A.c(),c=U(),d.c(),h=U(),Pe(p.$$.fragment),y=U(),V&&V.c(),j(t,H)},m(n,s){I(n,t,s),S&&S.m(t,null),O(t,i),k&&k.m(t,null),O(t,r),Re(a,t,null),O(t,l),A&&A.m(t,null),O(t,c),P[u].m(t,null),O(t,h),Re(p,t,null),O(t,y),V&&V.m(t,null),e[73](t),x=!0,C||(T=[E(b=_l.call(null,t,{ripple:!e[14]&&"filled"===e[15],unbounded:!1,addClass:e[38],removeClass:e[39],addStyle:e[40],eventTarget:e[33],activeTarget:e[33],initPromise:e[37]})),E(w=dl.call(null,t,e[8])),E(e[34].call(null,t)),F(t,"SMUITextfieldLeadingIcon:mount",e[74]),F(t,"SMUITextfieldLeadingIcon:unmount",e[75]),F(t,"SMUITextfieldTrailingIcon:mount",e[76]),F(t,"SMUITextfieldTrailingIcon:unmount",e[77]),F(t,"SMUITextfieldCharacterCounter:mount",e[78]),F(t,"SMUITextfieldCharacterCounter:unmount",e[79])],C=!0)},p(e,n){e[14]||"outlined"===e[15]?S&&(Te(),Oe(S,1,1,(()=>{S=null})),Se()):S?(S.p(e,n),49152&n[0]&&ke(S,1)):(S=Ac(e),S.c(),ke(S,1),S.m(t,i)),e[14]||"outlined"===e[15]?k?(k.p(e,n),49152&n[0]&&ke(k,1)):(k=Dc(e),k.c(),ke(k,1),k.m(t,r)):k&&(Te(),Oe(k,1,1,(()=>{k=null})),Se());const s={};268435456&n[2]&&(s.$$scope={dirty:n,ctx:e}),a.$set(s),A&&A.p&&(!x||268435456&n[2])&&g(A,L,e,e[90],x?m(L,e[90],n,null):v(e[90]),null);let l=u;u=R(e),u===l?P[u].p(e,n):(Te(),Oe(P[l],1,1,(()=>{P[l]=null})),Se(),d=P[u],d?d.p(e,n):(d=P[u]=N[u](e),d.c()),ke(d,1),d.m(t,h));const c={};268435456&n[2]&&(c.$$scope={dirty:n,ctx:e}),p.$set(c),!e[14]&&"outlined"!==e[15]&&e[11]?V?(V.p(e,n),51200&n[0]&&ke(V,1)):(V=Wc(e),V.c(),ke(V,1),V.m(t,null)):V&&(Te(),Oe(V,1,1,(()=>{V=null})),Se()),j(t,H=Me(Y,[(!x||314823171&n[0]|2048&n[1]&&_!==(_=rl({[e[9]]:!0,"mdc-text-field":!0,"mdc-text-field--disabled":e[12],"mdc-text-field--textarea":e[14],"mdc-text-field--filled":"filled"===e[15],"mdc-text-field--outlined":"outlined"===e[15],"smui-text-field--standard":"standard"===e[15]&&!e[14],"mdc-text-field--no-label":e[16]||null==e[17]&&!e[42].label,"mdc-text-field--label-floating":e[28]||null!=e[0]&&""!==e[0],"mdc-text-field--with-leading-icon":e[35](e[22])?e[42].leadingIcon:e[22],"mdc-text-field--with-trailing-icon":e[35](e[23])?e[42].trailingIcon:e[23],"mdc-text-field--with-internal-counter":e[14]&&e[42].internalCounter,"mdc-text-field--invalid":e[1],...e[25]})))&&{class:_},(!x||67109888&n[0]&&$!==($=Object.entries(e[26]).map(Kc).concat([e[10]]).join(" ")))&&{style:$},{for:void 0},1024&n[1]&&ol(e[41],["input$","label$","ripple$","outline$","helperLine$"])])),b&&o(b.update)&&49152&n[0]|4&n[1]&&b.update.call(null,{ripple:!e[14]&&"filled"===e[15],unbounded:!1,addClass:e[38],removeClass:e[39],addStyle:e[40],eventTarget:e[33],activeTarget:e[33],initPromise:e[37]}),w&&o(w.update)&&256&n[0]&&w.update.call(null,e[8])},i(e){x||(ke(S),ke(k),ke(a.$$.fragment,e),ke(A,e),ke(d),ke(p.$$.fragment,e),ke(V),x=!0)},o(e){Oe(S),Oe(k),Oe(a.$$.fragment,e),Oe(A,e),Oe(d),Oe(p.$$.fragment,e),Oe(V),x=!1},d(n){n&&M(t),S&&S.d(),k&&k.d(),Ue(a),A&&A.d(n),P[u].d(),Ue(p),V&&V.d(),e[73](null),C=!1,s(T)}}}function Oc(e){let t;const n=e[51].leadingIcon,i=f(n,e,e[90],uc);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||268435456&r[2])&&g(i,n,e,e[90],t?m(n,e[90],r,cc):v(e[90]),uc)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Lc(e){let t;const n=e[51].trailingIcon,i=f(n,e,e[90],lc);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||268435456&r[2])&&g(i,n,e,e[90],t?m(n,e[90],r,ac):v(e[90]),lc)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Ac(e){let t,n,i,r="filled"===e[15]&&Ic(),s=!e[16]&&(null!=e[17]||e[42].label)&&Mc(e);return{c(){r&&r.c(),t=U(),s&&s.c(),n=V()},m(e,o){r&&r.m(e,o),I(e,t,o),s&&s.m(e,o),I(e,n,o),i=!0},p(e,i){"filled"===e[15]?r||(r=Ic(),r.c(),r.m(t.parentNode,t)):r&&(r.d(1),r=null),e[16]||null==e[17]&&!e[42].label?s&&(Te(),Oe(s,1,1,(()=>{s=null})),Se()):s?(s.p(e,i),196608&i[0]|2048&i[1]&&ke(s,1)):(s=Mc(e),s.c(),ke(s,1),s.m(n.parentNode,n))},i(e){i||(ke(s),i=!0)},o(e){Oe(s),i=!1},d(e){r&&r.d(e),e&&M(t),s&&s.d(e),e&&M(n)}}}function Ic(e){let t;return{c(){t=D("span"),Y(t,"class","mdc-text-field__ripple")},m(e,n){I(e,t,n)},d(e){e&&M(t)}}}function Mc(e){let t,i;const r=[{floatAbove:e[28]||null!=e[0]&&""!==e[0]},{required:e[13]},{wrapped:!0},ul(e[41],"label$")];let s={$$slots:{default:[Nc]},$$scope:{ctx:e}};for(let e=0;e<r.length;e+=1)s=n(s,r[e]);return t=new Tl({props:s}),e[52](t),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,n){const i=268443649&n[0]|1024&n[1]?Me(r,[268435457&n[0]&&{floatAbove:e[28]||null!=e[0]&&""!==e[0]},8192&n[0]&&{required:e[13]},r[2],1024&n[1]&&Ne(ul(e[41],"label$"))]):{};131072&n[0]|268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(n){e[52](null),Ue(t,n)}}}function Nc(e){let t,n,i=(null==e[17]?"":e[17])+"";const r=e[51].label,s=f(r,e,e[90],Tc);return{c(){t=R(i),s&&s.c()},m(e,i){I(e,t,i),s&&s.m(e,i),n=!0},p(e,o){(!n||131072&o[0])&&i!==(i=(null==e[17]?"":e[17])+"")&&H(t,i),s&&s.p&&(!n||268435456&o[2])&&g(s,r,e,e[90],n?m(r,e[90],o,Cc):v(e[90]),Tc)},i(e){n||(ke(s,e),n=!0)},o(e){Oe(s,e),n=!1},d(e){e&&M(t),s&&s.d(e)}}}function Dc(e){let t,i;const r=[{noLabel:e[16]||null==e[17]&&!e[42].label},ul(e[41],"outline$")];let s={$$slots:{default:[Uc]},$$scope:{ctx:e}};for(let e=0;e<r.length;e+=1)s=n(s,r[e]);return t=new Dl({props:s}),e[54](t),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,n){const i=196608&n[0]|3072&n[1]?Me(r,[196608&n[0]|2048&n[1]&&{noLabel:e[16]||null==e[17]&&!e[42].label},1024&n[1]&&Ne(ul(e[41],"outline$"))]):{};268640289&n[0]|3072&n[1]|268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(n){e[54](null),Ue(t,n)}}}function Pc(e){let t,i;const r=[{floatAbove:e[28]||null!=e[0]&&""!==e[0]},{required:e[13]},{wrapped:!0},ul(e[41],"label$")];let s={$$slots:{default:[Rc]},$$scope:{ctx:e}};for(let e=0;e<r.length;e+=1)s=n(s,r[e]);return t=new Tl({props:s}),e[53](t),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,n){const i=268443649&n[0]|1024&n[1]?Me(r,[268435457&n[0]&&{floatAbove:e[28]||null!=e[0]&&""!==e[0]},8192&n[0]&&{required:e[13]},r[2],1024&n[1]&&Ne(ul(e[41],"label$"))]):{};131072&n[0]|268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(n){e[53](null),Ue(t,n)}}}function Rc(e){let t,n,i=(null==e[17]?"":e[17])+"";const r=e[51].label,s=f(r,e,e[90],xc);return{c(){t=R(i),s&&s.c()},m(e,i){I(e,t,i),s&&s.m(e,i),n=!0},p(e,o){(!n||131072&o[0])&&i!==(i=(null==e[17]?"":e[17])+"")&&H(t,i),s&&s.p&&(!n||268435456&o[2])&&g(s,r,e,e[90],n?m(r,e[90],o,Ec):v(e[90]),xc)},i(e){n||(ke(s,e),n=!0)},o(e){Oe(s,e),n=!1},d(e){e&&M(t),s&&s.d(e)}}}function Uc(e){let t,n,i=!e[16]&&(null!=e[17]||e[42].label)&&Pc(e);return{c(){i&&i.c(),t=V()},m(e,r){i&&i.m(e,r),I(e,t,r),n=!0},p(e,n){e[16]||null==e[17]&&!e[42].label?i&&(Te(),Oe(i,1,1,(()=>{i=null})),Se()):i?(i.p(e,n),196608&n[0]|2048&n[1]&&ke(i,1)):(i=Pc(e),i.c(),ke(i,1),i.m(t.parentNode,t))},i(e){n||(ke(i),n=!0)},o(e){Oe(i),n=!1},d(e){i&&i.d(e),e&&M(t)}}}function Vc(e){let t;const n=e[51].leadingIcon,i=f(n,e,e[90],wc);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||268435456&r[2])&&g(i,n,e,e[90],t?m(n,e[90],r,bc):v(e[90]),wc)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Fc(e){let t,i,r,s,o,a,l,c,u,d;const h=e[51].prefix,p=f(h,e,e[90],yc);let y=null!=e[20]&&jc(e);const _=[{type:e[18]},{disabled:e[12]},{required:e[13]},{updateInvalid:e[19]},{"aria-controls":e[27]},{"aria-describedby":e[27]},e[16]&&null!=e[17]?{placeholder:e[17]}:{},ul(e[41],"input$")];function $(t){e[64](t)}function b(t){e[65](t)}function w(t){e[66](t)}function E(t){e[67](t)}let x={};for(let e=0;e<_.length;e+=1)x=n(x,_[e]);void 0!==e[0]&&(x.value=e[0]),void 0!==e[3]&&(x.files=e[3]),void 0!==e[4]&&(x.dirty=e[4]),void 0!==e[1]&&(x.invalid=e[1]),r=new Ql({props:x}),e[63](r),ce.push((()=>De(r,"value",$))),ce.push((()=>De(r,"files",b))),ce.push((()=>De(r,"dirty",w))),ce.push((()=>De(r,"invalid",E))),r.$on("blur",e[68]),r.$on("focus",e[69]),r.$on("blur",e[70]),r.$on("focus",e[71]);let C=null!=e[21]&&zc(e);const T=e[51].suffix,S=f(T,e,e[90],gc);return{c(){p&&p.c(),t=U(),y&&y.c(),i=U(),Pe(r.$$.fragment),c=U(),C&&C.c(),u=U(),S&&S.c()},m(e,n){p&&p.m(e,n),I(e,t,n),y&&y.m(e,n),I(e,i,n),Re(r,e,n),I(e,c,n),C&&C.m(e,n),I(e,u,n),S&&S.m(e,n),d=!0},p(e,t){p&&p.p&&(!d||268435456&t[2])&&g(p,h,e,e[90],d?m(h,e[90],t,vc):v(e[90]),yc),null!=e[20]?y?(y.p(e,t),1048576&t[0]&&ke(y,1)):(y=jc(e),y.c(),ke(y,1),y.m(i.parentNode,i)):y&&(Te(),Oe(y,1,1,(()=>{y=null})),Se());const n=135213056&t[0]|1024&t[1]?Me(_,[262144&t[0]&&{type:e[18]},4096&t[0]&&{disabled:e[12]},8192&t[0]&&{required:e[13]},524288&t[0]&&{updateInvalid:e[19]},134217728&t[0]&&{"aria-controls":e[27]},134217728&t[0]&&{"aria-describedby":e[27]},196608&t[0]&&Ne(e[16]&&null!=e[17]?{placeholder:e[17]}:{}),1024&t[1]&&Ne(ul(e[41],"input$"))]):{};!s&&1&t[0]&&(s=!0,n.value=e[0],ve((()=>s=!1))),!o&&8&t[0]&&(o=!0,n.files=e[3],ve((()=>o=!1))),!a&&16&t[0]&&(a=!0,n.dirty=e[4],ve((()=>a=!1))),!l&&2&t[0]&&(l=!0,n.invalid=e[1],ve((()=>l=!1))),r.$set(n),null!=e[21]?C?(C.p(e,t),2097152&t[0]&&ke(C,1)):(C=zc(e),C.c(),ke(C,1),C.m(u.parentNode,u)):C&&(Te(),Oe(C,1,1,(()=>{C=null})),Se()),S&&S.p&&(!d||268435456&t[2])&&g(S,T,e,e[90],d?m(T,e[90],t,mc):v(e[90]),gc)},i(e){d||(ke(p,e),ke(y),ke(r.$$.fragment,e),ke(C),ke(S,e),d=!0)},o(e){Oe(p,e),Oe(y),Oe(r.$$.fragment,e),Oe(C),Oe(S,e),d=!1},d(n){p&&p.d(n),n&&M(t),y&&y.d(n),n&&M(i),e[63](null),Ue(r,n),n&&M(c),C&&C.d(n),n&&M(u),S&&S.d(n)}}}function Yc(e){let t,i,r,s,o,a,l,c;const u=[{disabled:e[12]},{required:e[13]},{updateInvalid:e[19]},{"aria-controls":e[27]},{"aria-describedby":e[27]},ul(e[41],"input$")];function d(t){e[56](t)}function h(t){e[57](t)}function p(t){e[58](t)}let y={};for(let e=0;e<u.length;e+=1)y=n(y,u[e]);void 0!==e[0]&&(y.value=e[0]),void 0!==e[4]&&(y.dirty=e[4]),void 0!==e[1]&&(y.invalid=e[1]),i=new nc({props:y}),e[55](i),ce.push((()=>De(i,"value",d))),ce.push((()=>De(i,"dirty",h))),ce.push((()=>De(i,"invalid",p))),i.$on("blur",e[59]),i.$on("focus",e[60]),i.$on("blur",e[61]),i.$on("focus",e[62]);const _=e[51].internalCounter,$=f(_,e,e[90],$c);return{c(){t=D("span"),Pe(i.$$.fragment),a=U(),$&&$.c(),Y(t,"class",l=rl({"mdc-text-field__resizer":!("input$resizable"in e[41])||e[41].input$resizable}))},m(e,n){I(e,t,n),Re(i,t,null),O(t,a),$&&$.m(t,null),c=!0},p(e,n){const a=134754304&n[0]|1024&n[1]?Me(u,[4096&n[0]&&{disabled:e[12]},8192&n[0]&&{required:e[13]},524288&n[0]&&{updateInvalid:e[19]},134217728&n[0]&&{"aria-controls":e[27]},134217728&n[0]&&{"aria-describedby":e[27]},1024&n[1]&&Ne(ul(e[41],"input$"))]):{};!r&&1&n[0]&&(r=!0,a.value=e[0],ve((()=>r=!1))),!s&&16&n[0]&&(s=!0,a.dirty=e[4],ve((()=>s=!1))),!o&&2&n[0]&&(o=!0,a.invalid=e[1],ve((()=>o=!1))),i.$set(a),$&&$.p&&(!c||268435456&n[2])&&g($,_,e,e[90],c?m(_,e[90],n,_c):v(e[90]),$c),(!c||1024&n[1]&&l!==(l=rl({"mdc-text-field__resizer":!("input$resizable"in e[41])||e[41].input$resizable})))&&Y(t,"class",l)},i(e){c||(ke(i.$$.fragment,e),ke($,e),c=!0)},o(e){Oe(i.$$.fragment,e),Oe($,e),c=!1},d(n){n&&M(t),e[55](null),Ue(i),$&&$.d(n)}}}function jc(e){let t,n;return t=new Zl({props:{$$slots:{default:[Hc]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};1048576&n[0]|268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Hc(e){let t;return{c(){t=R(e[20])},m(e,n){I(e,t,n)},p(e,n){1048576&n[0]&&H(t,e[20])},d(e){e&&M(t)}}}function zc(e){let t,n;return t=new Xl({props:{$$slots:{default:[Gc]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,n){const i={};2097152&n[0]|268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function Gc(e){let t;return{c(){t=R(e[21])},m(e,n){I(e,t,n)},p(e,n){2097152&n[0]&&H(t,e[21])},d(e){e&&M(t)}}}function Bc(e){let t;const n=e[51].trailingIcon,i=f(n,e,e[90],pc);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||268435456&r[2])&&g(i,n,e,e[90],t?m(n,e[90],r,fc):v(e[90]),pc)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Wc(e){let t,i;const r=[ul(e[41],"ripple$")];let s={};for(let e=0;e<r.length;e+=1)s=n(s,r[e]);return t=new Ll({props:s}),e[72](t),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,n){const i=1024&n[1]?Me(r,[Ne(ul(e[41],"ripple$"))]):{};t.$set(i)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(n){e[72](null),Ue(t,n)}}}function qc(e){let t,i;const r=[ul(e[41],"helperLine$")];let s={$$slots:{default:[Zc]},$$scope:{ctx:e}};for(let e=0;e<r.length;e+=1)s=n(s,r[e]);return t=new ql({props:s}),t.$on("SMUITextfieldHelperText:id",e[85]),t.$on("SMUITextfieldHelperText:mount",e[86]),t.$on("SMUITextfieldHelperText:unmount",e[87]),t.$on("SMUITextfieldCharacterCounter:mount",e[88]),t.$on("SMUITextfieldCharacterCounter:unmount",e[89]),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,n){const i=1024&n[1]?Me(r,[Ne(ul(e[41],"helperLine$"))]):{};268435456&n[2]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(e){Ue(t,e)}}}function Zc(e){let t;const n=e[51].helper,i=f(n,e,e[90],rc);return{c(){i&&i.c()},m(e,n){i&&i.m(e,n),t=!0},p(e,r){i&&i.p&&(!t||268435456&r[2])&&g(i,n,e,e[90],t?m(n,e[90],r,ic):v(e[90]),rc)},i(e){t||(ke(i,e),t=!0)},o(e){Oe(i,e),t=!1},d(e){i&&i.d(e)}}}function Xc(e){let t,n,i,r,s;const o=[kc,Sc],a=[];t=function(e,t){return e[36]?0:1}(e),n=a[t]=o[t](e);let l=e[42].helper&&qc(e);return{c(){n.c(),i=U(),l&&l.c(),r=V()},m(e,n){a[t].m(e,n),I(e,i,n),l&&l.m(e,n),I(e,r,n),s=!0},p(e,t){n.p(e,t),e[42].helper?l?(l.p(e,t),2048&t[1]&&ke(l,1)):(l=qc(e),l.c(),ke(l,1),l.m(r.parentNode,r)):l&&(Te(),Oe(l,1,1,(()=>{l=null})),Se())},i(e){s||(ke(n),ke(l),s=!0)},o(e){Oe(n),Oe(l),s=!1},d(e){a[t].d(e),e&&M(i),l&&l.d(e),e&&M(r)}}}const Kc=([e,t])=>`${e}: ${t};`,Jc=([e,t])=>`${e}: ${t};`;function Qc(e,t,i){let r;const s=["use","class","style","ripple","disabled","required","textarea","variant","noLabel","label","type","value","files","invalid","updateInvalid","dirty","prefix","suffix","validateOnValueChange","useNativeValidation","withLeadingIcon","withTrailingIcon","input","floatingLabel","lineRipple","notchedOutline","focus","blur","layout","getElement"];let o=_(t,s),{$$slots:a={},$$scope:l}=t;const c=function(e){const t={};for(const n in e)t[n]=!0;return t}(a),{applyPassive:u}=Aa,d=cl(te());let h=()=>{};function f(e){return e===h}let{use:p=[]}=t,{class:m=""}=t,{style:g=""}=t,{ripple:v=!0}=t,{disabled:$=!1}=t,{required:b=!1}=t,{textarea:w=!1}=t,{variant:E=(w?"outlined":"standard")}=t,{noLabel:x=!1}=t,{label:C}=t,{type:T="text"}=t,{value:S=(o.input$emptyValueUndefined?void 0:h)}=t,{files:k=h}=t;const O=!f(S)||!f(k);f(S)&&(S=void 0),f(k)&&(k=null);let{invalid:L=h}=t,{updateInvalid:A=f(L)}=t;f(L)&&(L=!1);let I,M,N,D,P,R,U,V,F,{dirty:Y=!1}=t,{prefix:j}=t,{suffix:H}=t,{validateOnValueChange:z=A}=t,{useNativeValidation:G=A}=t,{withLeadingIcon:B=h}=t,{withTrailingIcon:W=h}=t,{input:q}=t,{floatingLabel:Z}=t,{lineRipple:X}=t,{notchedOutline:K}=t,J={},Q={},ee=!1,re=oe("SMUI:addLayoutListener"),se=new Promise((e=>P=e)),ae=S;function le(e){var t;return e in J?null!==(t=J[e])&&void 0!==t?t:null:fe().classList.contains(e)}function ue(e){J[e]||i(25,J[e]=!0,J)}function de(e){e in J&&!J[e]||i(25,J[e]=!1,J)}function he(){if(M){const e=M.shouldFloat;M.notchOutline(e)}}function fe(){return I}re&&(D=re(he)),ne((()=>{if(i(49,M=new il({addClass:ue,removeClass:de,hasClass:le,registerTextFieldInteractionHandler:(e,t)=>fe().addEventListener(e,t),deregisterTextFieldInteractionHandler:(e,t)=>fe().removeEventListener(e,t),registerValidationAttributeChangeHandler:e=>{const t=new MutationObserver((t=>{G&&e((e=>e.map((e=>e.attributeName)).filter((e=>e)))(t))})),n={attributes:!0};return q&&t.observe(q.getElement(),n),t},deregisterValidationAttributeChangeHandler:e=>{e.disconnect()},getNativeInput:()=>{var e;return null!==(e=null==q?void 0:q.getElement())&&void 0!==e?e:null},setInputAttr:(e,t)=>{null==q||q.addAttr(e,t)},removeInputAttr:e=>{null==q||q.removeAttr(e)},isFocused:()=>document.activeElement===(null==q?void 0:q.getElement()),registerInputInteractionHandler:(e,t)=>{null==q||q.getElement().addEventListener(e,t,u())},deregisterInputInteractionHandler:(e,t)=>{null==q||q.getElement().removeEventListener(e,t,u())},floatLabel:e=>Z&&Z.float(e),getLabelWidth:()=>Z?Z.getWidth():0,hasLabel:()=>!!Z,shakeLabel:e=>Z&&Z.shake(e),setLabelRequired:e=>Z&&Z.setRequired(e),activateLineRipple:()=>X&&X.activate(),deactivateLineRipple:()=>X&&X.deactivate(),setLineRippleTransformOrigin:e=>X&&X.setRippleCenter(e),closeOutline:()=>K&&K.closeNotch(),hasOutline:()=>!!K,notchOutline:e=>K&&K.notch(e)},{get helperText(){return V},get characterCounter(){return F},get leadingIcon(){return R},get trailingIcon(){return U}})),O){if(null==q)throw new Error("SMUI Textfield initialized without Input component.");M.init()}else me().then((()=>{if(null==q)throw new Error("SMUI Textfield initialized without Input component.");M.init()}));return P(),()=>{M.destroy()}})),ie((()=>{D&&D()}));return e.$$set=e=>{t=n(n({},t),y(e)),i(41,o=_(t,s)),"use"in e&&i(8,p=e.use),"class"in e&&i(9,m=e.class),"style"in e&&i(10,g=e.style),"ripple"in e&&i(11,v=e.ripple),"disabled"in e&&i(12,$=e.disabled),"required"in e&&i(13,b=e.required),"textarea"in e&&i(14,w=e.textarea),"variant"in e&&i(15,E=e.variant),"noLabel"in e&&i(16,x=e.noLabel),"label"in e&&i(17,C=e.label),"type"in e&&i(18,T=e.type),"value"in e&&i(0,S=e.value),"files"in e&&i(3,k=e.files),"invalid"in e&&i(1,L=e.invalid),"updateInvalid"in e&&i(19,A=e.updateInvalid),"dirty"in e&&i(4,Y=e.dirty),"prefix"in e&&i(20,j=e.prefix),"suffix"in e&&i(21,H=e.suffix),"validateOnValueChange"in e&&i(43,z=e.validateOnValueChange),"useNativeValidation"in e&&i(44,G=e.useNativeValidation),"withLeadingIcon"in e&&i(22,B=e.withLeadingIcon),"withTrailingIcon"in e&&i(23,W=e.withTrailingIcon),"input"in e&&i(2,q=e.input),"floatingLabel"in e&&i(5,Z=e.floatingLabel),"lineRipple"in e&&i(6,X=e.lineRipple),"notchedOutline"in e&&i(7,K=e.notchedOutline),"$$scope"in e&&i(90,l=e.$$scope)},e.$$.update=()=>{if(4&e.$$.dirty[0]&&i(33,r=q&&q.getElement()),524290&e.$$.dirty[0]|262144&e.$$.dirty[1]&&M&&M.isValid()!==!L&&(A?i(1,L=!M.isValid()):M.setValid(!L)),266240&e.$$.dirty[1]&&M&&M.getValidateOnValueChange()!==z&&M.setValidateOnValueChange(!f(z)&&z),270336&e.$$.dirty[1]&&M&&M.setUseNativeValidation(!!f(G)||G),4096&e.$$.dirty[0]|262144&e.$$.dirty[1]&&M&&M.setDisabled($),1&e.$$.dirty[0]|786432&e.$$.dirty[1]&&M&&O&&ae!==S){i(50,ae=S);const e=`${S}`;M.getValue()!==e&&M.setValue(e)}},[S,L,q,k,Y,Z,X,K,p,m,g,v,$,b,w,E,x,C,T,A,j,H,B,W,I,J,Q,N,ee,R,U,V,F,r,d,f,O,se,ue,de,function(e,t){Q[e]!=t&&(""===t||null==t?(delete Q[e],i(26,Q)):i(26,Q[e]=t,Q))},o,c,z,G,function(){null==q||q.focus()},function(){null==q||q.blur()},he,fe,M,ae,a,function(e){ce[e?"unshift":"push"]((()=>{Z=e,i(5,Z)}))},function(e){ce[e?"unshift":"push"]((()=>{Z=e,i(5,Z)}))},function(e){ce[e?"unshift":"push"]((()=>{K=e,i(7,K)}))},function(e){ce[e?"unshift":"push"]((()=>{q=e,i(2,q)}))},function(e){S=e,i(0,S)},function(e){Y=e,i(4,Y)},function(e){L=e,i(1,L),i(49,M),i(19,A)},()=>i(28,ee=!1),()=>i(28,ee=!0),e=>sl(I,"blur",e),e=>sl(I,"focus",e),function(e){ce[e?"unshift":"push"]((()=>{q=e,i(2,q)}))},function(e){S=e,i(0,S)},function(e){k=e,i(3,k)},function(e){Y=e,i(4,Y)},function(e){L=e,i(1,L),i(49,M),i(19,A)},()=>i(28,ee=!1),()=>i(28,ee=!0),e=>sl(I,"blur",e),e=>sl(I,"focus",e),function(e){ce[e?"unshift":"push"]((()=>{X=e,i(6,X)}))},function(e){ce[e?"unshift":"push"]((()=>{I=e,i(24,I)}))},e=>i(29,R=e.detail),()=>i(29,R=void 0),e=>i(30,U=e.detail),()=>i(30,U=void 0),e=>i(32,F=e.detail),()=>i(32,F=void 0),function(e){ce[e?"unshift":"push"]((()=>{I=e,i(24,I)}))},e=>i(29,R=e.detail),()=>i(29,R=void 0),e=>i(30,U=e.detail),()=>i(30,U=void 0),e=>i(27,N=e.detail),e=>i(31,V=e.detail),()=>{i(27,N=void 0),i(31,V=void 0)},e=>i(32,F=e.detail),()=>i(32,F=void 0),l]}class eu extends Fe{constructor(e){super(),Ve(this,e,Qc,Xc,a,{use:8,class:9,style:10,ripple:11,disabled:12,required:13,textarea:14,variant:15,noLabel:16,label:17,type:18,value:0,files:3,invalid:1,updateInvalid:19,dirty:4,prefix:20,suffix:21,validateOnValueChange:43,useNativeValidation:44,withLeadingIcon:22,withTrailingIcon:23,input:2,floatingLabel:5,lineRipple:6,notchedOutline:7,focus:45,blur:46,layout:47,getElement:48},null,[-1,-1,-1,-1])}get focus(){return this.$$.ctx[45]}get blur(){return this.$$.ctx[46]}get layout(){return this.$$.ctx[47]}get getElement(){return this.$$.ctx[48]}}function tu(e){let t,n,i,r=e[3].replaceAll("\n","<br />")+"";return{c(){t=D("div"),Y(t,"class","auth-error svelte-1b930v1")},m(e,n){I(e,t,n),t.innerHTML=r,i=!0},p(e,n){(!i||8&n)&&r!==(r=e[3].replaceAll("\n","<br />")+"")&&(t.innerHTML=r)},i(e){i||(ge((()=>{n||(n=Ae(t,pi,{},!0)),n.run(1)})),i=!0)},o(e){n||(n=Ae(t,pi,{},!1)),n.run(0),i=!1},d(e){e&&M(t),e&&n&&n.end()}}}function nu(e){let t,n,i,r,s,o,a,l;function c(t){e[9](t)}let u={type:"text",disabled:!!e[0],label:e[4]("login.username-placeholder")};function d(t){e[10](t)}void 0!==e[1]&&(u.value=e[1]),n=new eu({props:u}),ce.push((()=>De(n,"value",c)));let h={type:"password",disabled:!!e[0],label:e[4]("login.password-placeholder")};return void 0!==e[2]&&(h.value=e[2]),o=new eu({props:h}),ce.push((()=>De(o,"value",d))),{c(){t=D("div"),Pe(n.$$.fragment),r=U(),s=D("div"),Pe(o.$$.fragment),Y(t,"class","custom-input svelte-1b930v1"),Y(s,"class","custom-input svelte-1b930v1")},m(e,i){I(e,t,i),Re(n,t,null),I(e,r,i),I(e,s,i),Re(o,s,null),l=!0},p(e,t){const r={};1&t&&(r.disabled=!!e[0]),16&t&&(r.label=e[4]("login.username-placeholder")),!i&&2&t&&(i=!0,r.value=e[1],ve((()=>i=!1))),n.$set(r);const s={};1&t&&(s.disabled=!!e[0]),16&t&&(s.label=e[4]("login.password-placeholder")),!a&&4&t&&(a=!0,s.value=e[2],ve((()=>a=!1))),o.$set(s)},i(e){l||(ke(n.$$.fragment,e),ke(o.$$.fragment,e),l=!0)},o(e){Oe(n.$$.fragment,e),Oe(o.$$.fragment,e),l=!1},d(e){e&&M(t),Ue(n),e&&M(r),e&&M(s),Ue(o)}}}function iu(t){let n,i,r,s,o=t[4]("login.username")+"";return{c(){n=D("div"),i=R(o),r=U(),s=R(t[0])},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s)},p(e,t){16&t&&o!==(o=e[4]("login.username")+"")&&H(i,o),1&t&&H(s,e[0])},i:e,o:e,d(e){e&&M(n)}}}function ru(e){let t,n,i,r,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b,w=e[4]("login.title")+"",E=e[4]("login.description")+"",x=(e[0]?e[4]("login.logout"):e[4]("login.login"))+"",C=e[4]("login.cancel")+"";t=new Ko({props:{size:"4em"}});let T=e[3]&&tu(e);const S=[iu,nu],k=[];function L(e,t){return e[0]?0:1}return d=L(e),h=k[d]=S[d](e),{c(){Pe(t.$$.fragment),n=U(),i=D("h4"),r=R(w),o=U(),a=D("div"),l=R(E),c=U(),T&&T.c(),u=U(),h.c(),f=U(),p=D("button"),m=R(x),g=U(),v=D("button"),y=R(C),G(i,"width","85%"),G(i,"text-align","center"),G(a,"width","85%"),G(a,"padding","1em"),G(a,"text-align","center"),Y(p,"class","login svelte-1b930v1"),Y(v,"class","cancel svelte-1b930v1")},m(s,h){Re(t,s,h),I(s,n,h),I(s,i,h),O(i,r),I(s,o,h),I(s,a,h),O(a,l),I(s,c,h),T&&T.m(s,h),I(s,u,h),k[d].m(s,h),I(s,f,h),I(s,p,h),O(p,m),I(s,g,h),I(s,v,h),O(v,y),_=!0,$||(b=[F(p,"click",e[11]),F(v,"click",e[5])],$=!0)},p(e,t){(!_||16&t)&&w!==(w=e[4]("login.title")+"")&&H(r,w),(!_||16&t)&&E!==(E=e[4]("login.description")+"")&&H(l,E),e[3]?T?(T.p(e,t),8&t&&ke(T,1)):(T=tu(e),T.c(),ke(T,1),T.m(u.parentNode,u)):T&&(Te(),Oe(T,1,1,(()=>{T=null})),Se());let n=d;d=L(e),d===n?k[d].p(e,t):(Te(),Oe(k[n],1,1,(()=>{k[n]=null})),Se(),h=k[d],h?h.p(e,t):(h=k[d]=S[d](e),h.c()),ke(h,1),h.m(f.parentNode,f)),(!_||17&t)&&x!==(x=(e[0]?e[4]("login.logout"):e[4]("login.login"))+"")&&H(m,x),(!_||16&t)&&C!==(C=e[4]("login.cancel")+"")&&H(y,C)},i(e){_||(ke(t.$$.fragment,e),ke(T),ke(h),_=!0)},o(e){Oe(t.$$.fragment,e),Oe(T),Oe(h),_=!1},d(e){Ue(t,e),e&&M(n),e&&M(i),e&&M(o),e&&M(a),e&&M(c),T&&T.d(e),e&&M(u),k[d].d(e),e&&M(f),e&&M(p),e&&M(g),e&&M(v),$=!1,s(b)}}}function su(e){let t,n;return t=new Co({props:{onEscCb:e[5],$$slots:{default:[ru]},$$scope:{ctx:e}}}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},p(e,[n]){const i={};16415&n&&(i.$$scope={dirty:n,ctx:e}),t.$set(i)},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function ou(e,t,n){let i;h(e,li,(e=>n(4,i=e)));let{logged_username:r}=t,{auth_controller:s}=t,o="",a="",l="";const c=re(),u=()=>{s.logout(),n(2,a="")},d=e=>{n(3,l=e),n(1,o=""),n(2,a="")},f=()=>{s.login(o,a,d),n(2,a=a.replaceAll(/./g,"*"))};return e.$$set=e=>{"logged_username"in e&&n(0,r=e.logged_username),"auth_controller"in e&&n(8,s=e.auth_controller)},e.$$.update=()=>{1&e.$$.dirty&&r&&(n(1,o=r),n(2,a="**************")),6&e.$$.dirty&&(o||a)&&n(3,l="")},[r,o,a,l,i,()=>c("cancel"),u,f,s,function(e){o=e,n(1,o),n(0,r)},function(e){a=e,n(2,a),n(0,r)},()=>r?u():f()]}class au extends Fe{constructor(e){super(),Ve(this,e,ou,su,a,{logged_username:0,auth_controller:8})}}function lu(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"fill-rule","evenodd"),Y(i,"clip-rule","evenodd"),Y(i,"d","M2 0C0.895386 0 0 0.895416 0 2V33C0 34.1046 0.895386 35 2 35H35V0H2ZM10 7.94202L13.942 4L26.9399 16.998L26.938 17L26.9399 17.002L13.942 30L10 26.058L19.058 17L10 7.94202Z"),Y(i,"fill",t[0]),Y(n,"width",t[1]),Y(n,"height",t[2]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){1&t&&Y(i,"fill",e[0]),2&t&&Y(n,"width",e[1]),4&t&&Y(n,"height",e[2]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function cu(e,t,n){let{color:i="currentColor"}=t,{size:r="2.5em"}=t,{width:s=r}=t,{height:o=r}=t,{viewBox:a="0 0 35 35"}=t;return e.$$set=e=>{"color"in e&&n(0,i=e.color),"size"in e&&n(4,r=e.size),"width"in e&&n(1,s=e.width),"height"in e&&n(2,o=e.height),"viewBox"in e&&n(3,a=e.viewBox)},[i,s,o,a,r]}class uu extends Fe{constructor(e){super(),Ve(this,e,cu,lu,a,{color:0,size:4,width:1,height:2,viewBox:3})}}function du(t){let n,i;return{c(){n=P("svg"),i=P("path"),Y(i,"fill-rule","evenodd"),Y(i,"clip-rule","evenodd"),Y(i,"d","M2 35L35 35L35 4.17233e-06L2 4.17233e-06C0.895436 4.17233e-06 4.17233e-06 0.895436 4.17233e-06 2L4.17233e-06 33C4.17233e-06 34.1046 0.895436 35 2 35ZM25 27.058L21.058 31L8.06 18.002L8.062 18L8.06 17.998L21.058 5L25 8.942L15.942 18L25 27.058Z"),Y(i,"fill",t[0]),Y(n,"width",t[1]),Y(n,"height",t[2]),Y(n,"viewBox",t[3]),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i)},p(e,[t]){1&t&&Y(i,"fill",e[0]),2&t&&Y(n,"width",e[1]),4&t&&Y(n,"height",e[2]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function hu(e,t,n){let{color:i="currentColor"}=t,{size:r="2.5em"}=t,{width:s=r}=t,{height:o=r}=t,{viewBox:a="0 0 35 35"}=t;return e.$$set=e=>{"color"in e&&n(0,i=e.color),"size"in e&&n(4,r=e.size),"width"in e&&n(1,s=e.width),"height"in e&&n(2,o=e.height),"viewBox"in e&&n(3,a=e.viewBox)},[i,s,o,a,r]}class fu extends Fe{constructor(e){super(),Ve(this,e,hu,du,a,{color:0,size:4,width:1,height:2,viewBox:3})}}function pu(e){let t,n;return t=new uu({}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function mu(e){let t,n;return t=new fu({}),{c(){Pe(t.$$.fragment)},m(e,i){Re(t,e,i),n=!0},i(e){n||(ke(t.$$.fragment,e),n=!0)},o(e){Oe(t.$$.fragment,e),n=!1},d(e){Ue(t,e)}}}function gu(e){let t,n,i,r,s,o;const a=[mu,pu],l=[];function c(e,t){return e[1]?0:1}return n=c(e),i=l[n]=a[n](e),{c(){t=D("button"),i.c(),Y(t,"class","hide-chat svelte-1qvbvny"),B(t,"full-screen-hide",e[0]),B(t,"horizontal-hide-chat-button",e[1])},m(e,i){I(e,t,i),l[n].m(t,null),r=!0,s||(o=F(t,"click",ms),s=!0)},p(e,[r]){let s=n;n=c(e),n!==s&&(Te(),Oe(l[s],1,1,(()=>{l[s]=null})),Se(),i=l[n],i||(i=l[n]=a[n](e),i.c()),ke(i,1),i.m(t,null)),1&r&&B(t,"full-screen-hide",e[0]),2&r&&B(t,"horizontal-hide-chat-button",e[1])},i(e){r||(ke(i),r=!0)},o(e){Oe(i),r=!1},d(e){e&&M(t),l[n].d(),s=!1,o()}}}function vu(e,t,n){let i,r;return h(e,hs,(e=>n(0,i=e))),h(e,fs,(e=>n(1,r=e))),[i,r]}class yu extends Fe{constructor(e){super(),Ve(this,e,vu,gu,a,{})}}function _u(t){let n,i,r,s,o,a;return{c(){n=P("svg"),i=P("path"),r=P("path"),s=P("path"),o=P("path"),a=P("path"),Y(i,"d","M2.53469 38.6064L2.88379 38.2484C1.00975 36.4208 1.02996 33.3454 3.00011 31.7287L3.00012 31.7287C7.86239 27.7384 13.3326 24.4923 19.2238 22.1124C26.7615 19.0674 34.8406 17.5 43 17.5C51.1593 17.5 59.2385 19.0674 66.776 22.1124C72.6674 24.4923 78.1373 27.7384 82.9998 31.7287C84.9698 33.3455 84.9904 36.4208 83.1166 38.2485C81.4294 39.8938 78.7911 39.8956 76.9271 38.3795C72.8245 35.0424 68.2211 32.324 63.2694 30.3237C56.8428 27.7276 49.9553 26.3915 43 26.3915C36.0446 26.3915 29.1571 27.7276 22.7306 30.3237C17.7789 32.324 13.1755 35.0424 9.07277 38.3795L9.07276 38.3795C7.20894 39.8956 4.57093 39.8938 2.88379 38.2484L2.53469 38.6064Z"),Y(i,"fill",t[2]),Y(r,"d","M52.2373 63.7744L52.4821 63.3404L52.2373 63.7745C53.0564 64.2364 53.4653 65.019 53.4979 65.8677C53.5308 66.7252 53.1761 67.6463 52.4537 68.3259L52.791 68.6845L52.4537 68.3259L45.8012 74.5844C44.5036 75.8052 42.4964 75.8052 41.1988 74.5844L34.5463 68.3259L34.5463 68.3259C33.8239 67.6463 33.4692 66.7252 33.5021 65.8677C33.5347 65.019 33.9436 64.2364 34.7627 63.7745L34.7627 63.7744C35.4766 63.3718 36.2228 63.0181 36.9957 62.717L36.9958 62.7169C39.0571 61.9137 41.2673 61.5 43.5 61.5C45.7327 61.5 47.9429 61.9137 50.0042 62.7169L50.0043 62.717C50.7772 63.0181 51.5234 63.3718 52.2373 63.7744Z"),Y(r,"fill",t[2]),Y(s,"d","M77.755 15.2836C78.5171 14.5456 78.197 13.0391 77.0401 11.9187C75.8831 10.7984 74.3274 10.4884 73.5652 11.2264L14.8776 68.0574C14.1155 68.7954 14.4356 70.3019 15.5925 71.4223C16.7495 72.5426 18.3052 72.8526 19.0674 72.1146L77.755 15.2836Z"),Y(s,"fill",t[2]),Y(o,"d","M60.7628 35.8959L60.9153 35.5129L60.7628 35.8959C64.8359 37.5174 68.6391 39.685 72.0621 42.3274L72.3676 41.9316L72.0621 42.3274C73.942 43.7784 73.9696 46.6177 72.1987 48.3198C70.5927 49.8634 68.0616 49.8655 66.2267 48.4869L65.9263 48.8866L66.2267 48.4869C63.5453 46.4723 60.5875 44.812 57.4313 43.5555C52.8555 41.7338 47.9518 40.7963 43 40.7963C38.0482 40.7963 33.1445 41.7338 28.5687 43.5555L28.7484 44.0068L28.5687 43.5555C25.4125 44.812 22.4547 46.4723 19.7733 48.4869C17.9383 49.8655 15.4073 49.8634 13.8013 48.3198C12.0304 46.6177 12.0581 43.7784 13.9379 42.3274L13.9379 42.3274C17.3608 39.685 21.1641 37.5174 25.2372 35.8959L25.2372 35.8959C30.8681 33.654 36.904 32.5 43 32.5C49.0959 32.5 55.1319 33.654 60.7628 35.8959Z"),Y(o,"fill",t[2]),Y(a,"d","M24.8407 52.24L24.5566 51.8285L24.8407 52.24C30.2043 48.5362 36.738 46.5 43.5 46.5C50.262 46.5 56.7957 48.5362 62.1593 52.24C63.8968 53.4398 63.9407 55.9425 62.321 57.4532C60.8671 58.8092 58.5643 58.8101 56.803 57.6754C52.9169 55.1716 48.2825 53.8058 43.5 53.8058C38.7175 53.8058 34.0831 55.1716 30.197 57.6754C28.4357 58.8101 26.1329 58.8092 24.679 57.4532C23.0593 55.9425 23.1032 53.4397 24.8407 52.24Z"),Y(a,"fill",t[2]),Y(n,"width",t[0]),Y(n,"height",t[1]),Y(n,"viewBox",t[3]),Y(n,"fill","none"),Y(n,"xmlns","http://www.w3.org/2000/svg")},m(e,t){I(e,n,t),O(n,i),O(n,r),O(n,s),O(n,o),O(n,a)},p(e,[t]){4&t&&Y(i,"fill",e[2]),4&t&&Y(r,"fill",e[2]),4&t&&Y(s,"fill",e[2]),4&t&&Y(o,"fill",e[2]),4&t&&Y(a,"fill",e[2]),1&t&&Y(n,"width",e[0]),2&t&&Y(n,"height",e[1]),8&t&&Y(n,"viewBox",e[3])},i:e,o:e,d(e){e&&M(n)}}}function $u(e,t,n){let{size:i="2.5em"}=t,{width:r=i}=t,{height:s=i}=t,{color:o="currentColor"}=t,{viewBox:a="0 0 86 91"}=t;return e.$$set=e=>{"size"in e&&n(4,i=e.size),"width"in e&&n(0,r=e.width),"height"in e&&n(1,s=e.height),"color"in e&&n(2,o=e.color),"viewBox"in e&&n(3,a=e.viewBox)},[r,s,o,a,i]}class bu extends Fe{constructor(e){super(),Ve(this,e,$u,_u,a,{size:4,width:0,height:1,color:2,viewBox:3})}}function wu(e){let t,n,i,r,s,o,a=e[2]("connection-issues.low-bandwidth")+"";return s=new bu({}),{c(){t=D("div"),n=D("span"),i=R(a),r=U(),Pe(s.$$.fragment),Y(n,"class","svelte-1yr7nea"),Y(t,"class","svelte-1yr7nea")},m(e,a){I(e,t,a),O(t,n),O(n,i),O(t,r),Re(s,t,null),o=!0},p(e,t){(!o||4&t)&&a!==(a=e[2]("connection-issues.low-bandwidth")+"")&&H(i,a)},i(e){o||(ke(s.$$.fragment,e),o=!0)},o(e){Oe(s.$$.fragment,e),o=!1},d(e){e&&M(t),Ue(s)}}}function Eu(e){let t,n,i=e[0]>=Cu&&e[1]<=xu&&wu(e);return{c(){i&&i.c(),t=V()},m(e,r){i&&i.m(e,r),I(e,t,r),n=!0},p(e,[n]){e[0]>=Cu&&e[1]<=xu?i?(i.p(e,n),3&n&&ke(i,1)):(i=wu(e),i.c(),ke(i,1),i.m(t.parentNode,t)):i&&(Te(),Oe(i,1,1,(()=>{i=null})),Se())},i(e){n||(ke(i),n=!0)},o(e){Oe(i),n=!1},d(e){i&&i.d(e),e&&M(t)}}}const xu=.5,Cu=3;function Tu(e,t,n){let i,r,s;h(e,Ro,(e=>n(4,r=e))),h(e,li,(e=>n(2,s=e)));let o=0,a=Array(Cu).fill(0),l=!0;return e.$$.update=()=>{16&e.$$.dirty&&(l?l=!1:(n(0,o++,o),n(3,a[o%Cu]=r,a))),8&e.$$.dirty&&n(1,i=a.reduce(((e,t)=>e+t),0)/Cu)},[o,i,s,a,r]}class Su extends Fe{constructor(e){super(),Ve(this,e,Tu,Eu,a,{})}}const{org_id:ku,head_id:Ou}=d(Yr);let Lu;let Au,Iu,Mu=1e3,Nu=0,Du=parseInt($s("session_id"))||0;Du++,bs("session_id",Du.toString());let Pu=!1,Ru="",Uu="";Nu=parseInt($s("message_counter"))||0;const Vu=e=>{if(!e)return"";const t=e.split(" ");let n="";return t.forEach((e=>{if(e.length>15&&!e.includes("<br")&&!e.includes("href")&&!e.includes("_blank"))for(let t=e.length+1;t>0;t--)t%15==0&&(e=e.substring(0,t)+"­"+e.substring(t));n+=" "+e})),n.trim()},Fu=(e,t,n)=>{Ru=e,t&&(Au=t),n&&(Iu=n),Lu&&Lu.close()},Yu=(e,t,n,i,r,s=(()=>null),o=(()=>null),a=(e=>{}),l=(e=>{}),c=(()=>null),u=(()=>null),h)=>{Au=t,Ru=e,Iu=n;const f=d(Yr).api_base.replace("http","ws")+`/api/v1/switch/${i}/${r}`;Lu=new WebSocket(f),Lu.onmessage=function(e){const t=JSON.parse(e.data),{user_id:n,id:i,username:r,text:o,timestamp:f,event:p,video:m,op:g,users:v,hook:y,media:_,cached:$,error_reason:b}=t,w=d(zi);switch(p){case"text":if(r===Ru&&n===Iu)for(let e=w.length-1;e>=0;e--){const t=w[e];if(t.event===p&&t.id===i&&t.user_id===n&&t.text===o&&t.username===r){t.isSent=!0,m&&(t.url=m);break}}else{const e={id:i,user_id:n,username:r,timestamp:new Date(Date.parse(f)),speaker:"backend",text:Vu(o),isSent:!0,event:p,url:m,visible:!1};w.push(e)}m&&(Uu=m,s(m));break;case"hook":{_a.set(!0);const e={type:"suggestions",hook:y,disabled:!1};"options"===y.inputType&&(y.text||"voiceflowOptions"==y.hookname?Bi.set(!0):Bi.set(!1),w.push(e));break}case"media":{const e={type:"media",media:_,timestamp:new Date(Date.parse(f))};w.push(e);break}case"cache":u(!!$);break;case"aggregator_error":Hu(b||"There was an error processing your message",!0),h();break;case"conversation_end":Hu("Conversation ended",!0),c(),_a.set(!0);break;case"join":l(g);break;case"count":a(v);break;case"unrecoverable_error":ws.set(b),Lu.close(),Pu=!0;break;default:console.info("Got an unexpected event",p)}zi.set(w)},Lu.onopen=()=>{console.info("Websocket connection open"),Lu.send(Au),Mu=1e3,o()},Lu.onclose=()=>{console.info("Websocket connection closed"),Pu?d(ws)||ws.set("There was an error. Please try again or contact us"):setTimeout((()=>{Mu=Math.max(2*Mu,64e3),Yu(Ru,Au,Iu,i,r,s,o,a,l,c,u,h)}),Mu)},Lu.onerror=e=>{console.error("Websocket error",e),ws.set("Error connecting to our servers"),Pu=!0}},ju=e=>{const t=e.detail,n={id:++Nu,timestamp:new Date,speaker:"user",text:Vu(t),isSent:!1,user_id:Iu,username:Ru,event:"text",session_id:`${Iu}::${ku}::${Ou}::${Du.toString().padStart(5,"0")}`,visible:!0};bs("message_counter",Nu.toString());const i=d(zi);let r=i.length-1;for(;r>0;){const t=i[r];if("suggestions"===t.type&&!t.disabled){t.disabled=!0;const n=t.hook.inputs;for(let t=0;t<n.length;t++)n[t].text===e.detail&&(n[t].selected=!0);break}r--}zi.set([...i,n]),Lu&&(n.text=t,Lu.send(JSON.stringify(n)))},Hu=(e,t=!1)=>{const n={text:e,type:"info"};t&&(n.timestamp=new Date);const i=d(zi);i.push(n),zi.set(i)},zu="MediaSource"in window&&"addSourceBuffer"in window.MediaSource.prototype&&"appendBuffer"in window.SourceBuffer.prototype&&"onupdateend"in window.SourceBuffer.prototype&&MediaSource.isTypeSupported('video/mp4; codecs="avc1.64001F, mp4a.40.2"');var Gu="0, 224, 188",Bu="250, 122, 80",Wu="249, 219, 223",qu="100, 100, 100",Zu="40, 40, 40",Xu="250, 250, 250",Ku={primary:Gu,"primary-dimmed":"131, 205, 193",secondary:Bu,danger:Wu,shadow:qu,body:Zu,background:Xu,"chat-background":"linear-gradient(0deg,rgba(var(--background), 0.8) 0%,rgba(var(--background), 0.1) 100%)","download-button-font":"0, 163, 137","download-button-background":"255, 255, 255"},Ju=Object.freeze({__proto__:null,primary:Gu,secondary:Bu,danger:Wu,shadow:qu,body:Zu,background:Xu,default:Ku});const Qu=async e=>{try{return(await function(e){switch(e){case"./themes/dark.json":return Promise.resolve().then((function(){return gd}));case"./themes/light.json":return Promise.resolve().then((function(){return Ju}));default:return new Promise((function(t,n){("function"==typeof queueMicrotask?queueMicrotask:setTimeout)(n.bind(null,new Error("Unknown variable dynamic import: "+e)))}))}}(`./themes/${e}.json`)).default}catch{return Ku}};function ed(e){let t,n,i;function r(t){e[59](t)}let s={logged_username:"anonymous"!==(e[1]&&e[1])?e[1]:void 0};return void 0!==e[5]&&(s.auth_controller=e[5]),t=new au({props:s}),ce.push((()=>De(t,"auth_controller",r))),t.$on("cancel",e[60]),{c(){Pe(t.$$.fragment)},m(e,n){Re(t,e,n),i=!0},p(e,i){const r={};2&i[0]&&(r.logged_username="anonymous"!==(e[1]&&e[1])?e[1]:void 0),!n&&32&i[0]&&(n=!0,r.auth_controller=e[5],ve((()=>n=!1))),t.$set(r)},i(e){i||(ke(t.$$.fragment,e),i=!0)},o(e){Oe(t.$$.fragment,e),i=!1},d(e){Ue(t,e)}}}function td(e){let t,n,i;return n=new Hi({}),{c(){t=D("div"),Pe(n.$$.fragment),Y(t,"class","center-text loading full-screen svelte-vk7s48")},m(e,r){I(e,t,r),Re(n,t,null),i=!0},i(e){i||(ke(n.$$.fragment,e),i=!0)},o(e){Oe(n.$$.fragment,e),i=!1},d(e){e&&M(t),Ue(n)}}}function nd(e){let t,n,i,r;function s(t){e[61](t)}let o={};return void 0!==e[17]&&(o.asrModal=e[17]),n=new Oo({props:o}),ce.push((()=>De(n,"asrModal",s))),{c(){t=D("div"),Pe(n.$$.fragment),Y(t,"class","mic-access-modal svelte-vk7s48")},m(e,i){I(e,t,i),Re(n,t,null),r=!0},p(e,t){const r={};!i&&131072&t[0]&&(i=!0,r.asrModal=e[17],ve((()=>i=!1))),n.$set(r)},i(e){r||(ke(n.$$.fragment,e),r=!0)},o(e){Oe(n.$$.fragment,e),r=!1},d(e){e&&M(t),Ue(n)}}}function id(e){let t,n,i;return n=new Ta({}),{c(){t=D("div"),Pe(n.$$.fragment),Y(t,"class","loading svelte-vk7s48")},m(e,r){I(e,t,r),Re(n,t,null),i=!0},i(e){i||(ke(n.$$.fragment,e),i=!0)},o(e){Oe(n.$$.fragment,e),i=!1},d(e){e&&M(t),Ue(n)}}}function rd(e){let t,n,i,r,s,o,a,l,c,u,d,h,f,p,m,g,v,y,_,$,b,w,E,x,C,T,S,k,L,A,N,P,R,V,F;function j(t){e[39](t)}function H(t){e[40](t)}function z(t){e[41](t)}t=new ci({});let G={};function W(t){e[42](t)}function q(t){e[43](t)}function Z(t){e[44](t)}function X(t){e[45](t)}function K(t){e[46](t)}function J(t){e[47](t)}function Q(t){e[48](t)}function ee(t){e[49](t)}void 0!==e[1]&&(G.logged_username=e[1]),void 0!==e[3]&&(G.access_token=e[3]),void 0!==e[4]&&(G._user_id=e[4]),i=new Oa({props:G}),e[38](i),ce.push((()=>De(i,"logged_username",j))),ce.push((()=>De(i,"access_token",H))),ce.push((()=>De(i,"_user_id",z)));var te=e[22];function ne(e){let t={show_count:"opsp"===e[0]&&e[2]};return void 0!==e[11]&&(t.idleVideoSrc=e[11]),void 0!==e[20]&&(t.sessionCount=e[20]),void 0!==e[7]&&(t.name=e[7]),void 0!==e[15]&&(t.skipTalkingVideo=e[15]),void 0!==e[16]&&(t.on_video_synth_error=e[16]),void 0!==e[12]&&(t.on_video_received=e[12]),void 0!==e[13]&&(t.on_enter=e[13]),void 0!==e[14]&&(t.on_cache_check=e[14]),{props:t}}function ie(t){e[54](t)}function re(t){e[55](t)}function se(t){e[56](t)}function oe(t){e[57](t)}te&&(u=new te(ne(e)),ce.push((()=>De(u,"idleVideoSrc",W))),ce.push((()=>De(u,"sessionCount",q))),ce.push((()=>De(u,"name",Z))),ce.push((()=>De(u,"skipTalkingVideo",X))),ce.push((()=>De(u,"on_video_synth_error",K))),ce.push((()=>De(u,"on_video_received",J))),ce.push((()=>De(u,"on_enter",Q))),ce.push((()=>De(u,"on_cache_check",ee))),u.$on("ready",e[50]),u.$on("talking_end",e[51]),u.$on("pause",e[31]),u.$on("displayChatMessage",e[35]),u.$on("skip",e[34]),u.$on("replay",e[52]),u.$on("avatarClick",e[53])),$=new Su({}),w=new yu({});let ae={};void 0!==e[7]&&(ae.name=e[7]),void 0!==e[8]&&(ae.server_avatar=e[8]),void 0!==e[10]&&(ae.header_avatar=e[10]),void 0!==e[9]&&(ae.user_avatar=e[9]),C=new wo({props:ae}),ce.push((()=>De(C,"name",ie))),ce.push((()=>De(C,"server_avatar",re))),ce.push((()=>De(C,"header_avatar",se))),ce.push((()=>De(C,"user_avatar",oe))),C.$on("userInput",e[33]),C.$on("play",e[32]),C.$on("skip",e[34]),C.$on("replay",e[58]),C.$on("processUserInput",e[33]);let le=e[6]&&ed(e),ue=(!e[19]||!e[18]||!e[29])&&td(),de=!e[24]&&e[17]&&nd(e),he=e[23]&&id();return{c(){Pe(t.$$.fragment),n=U(),Pe(i.$$.fragment),a=U(),l=D("div"),c=D("div"),u&&Pe(u.$$.fragment),_=U(),Pe($.$$.fragment),b=U(),Pe(w.$$.fragment),E=U(),x=D("div"),Pe(C.$$.fragment),N=U(),le&&le.c(),P=U(),ue&&ue.c(),R=U(),de&&de.c(),V=U(),he&&he.c(),Y(c,"class","video svelte-vk7s48"),Y(x,"style",A=e[27]?`margin-bottom: ${e[28].distanceToBottom}px;\n margin-right: ${e[28].distanceToRight}px;`:""),Y(x,"class","svelte-vk7s48"),B(x,"chat",!e[26]&&!e[27]),B(x,"position-absolute-chat",e[26]||e[27]),Y(l,"class","app-container svelte-vk7s48"),Y(l,"style",e[21])},m(e,r){Re(t,e,r),I(e,n,r),Re(i,e,r),I(e,a,r),I(e,l,r),O(l,c),u&&Re(u,c,null),O(l,_),Re($,l,null),O(l,b),Re(w,l,null),O(l,E),O(l,x),Re(C,x,null),O(l,N),le&&le.m(l,null),O(l,P),ue&&ue.m(l,null),O(l,R),de&&de.m(l,null),O(l,V),he&&he.m(l,null),F=!0},p(e,t){const n={};!r&&2&t[0]&&(r=!0,n.logged_username=e[1],ve((()=>r=!1))),!s&&8&t[0]&&(s=!0,n.access_token=e[3],ve((()=>s=!1))),!o&&16&t[0]&&(o=!0,n._user_id=e[4],ve((()=>o=!1))),i.$set(n);const a={};if(5&t[0]&&(a.show_count="opsp"===e[0]&&e[2]),!d&&2048&t[0]&&(d=!0,a.idleVideoSrc=e[11],ve((()=>d=!1))),!h&&1048576&t[0]&&(h=!0,a.sessionCount=e[20],ve((()=>h=!1))),!f&&128&t[0]&&(f=!0,a.name=e[7],ve((()=>f=!1))),!p&&32768&t[0]&&(p=!0,a.skipTalkingVideo=e[15],ve((()=>p=!1))),!m&&65536&t[0]&&(m=!0,a.on_video_synth_error=e[16],ve((()=>m=!1))),!g&&4096&t[0]&&(g=!0,a.on_video_received=e[12],ve((()=>g=!1))),!v&&8192&t[0]&&(v=!0,a.on_enter=e[13],ve((()=>v=!1))),!y&&16384&t[0]&&(y=!0,a.on_cache_check=e[14],ve((()=>y=!1))),te!==(te=e[22])){if(u){Te();const e=u;Oe(e.$$.fragment,1,0,(()=>{Ue(e,1)})),Se()}te?(u=new te(ne(e)),ce.push((()=>De(u,"idleVideoSrc",W))),ce.push((()=>De(u,"sessionCount",q))),ce.push((()=>De(u,"name",Z))),ce.push((()=>De(u,"skipTalkingVideo",X))),ce.push((()=>De(u,"on_video_synth_error",K))),ce.push((()=>De(u,"on_video_received",J))),ce.push((()=>De(u,"on_enter",Q))),ce.push((()=>De(u,"on_cache_check",ee))),u.$on("ready",e[50]),u.$on("talking_end",e[51]),u.$on("pause",e[31]),u.$on("displayChatMessage",e[35]),u.$on("skip",e[34]),u.$on("replay",e[52]),u.$on("avatarClick",e[53]),Pe(u.$$.fragment),ke(u.$$.fragment,1),Re(u,c,null)):u=null}else te&&u.$set(a);const _={};!T&&128&t[0]&&(T=!0,_.name=e[7],ve((()=>T=!1))),!S&&256&t[0]&&(S=!0,_.server_avatar=e[8],ve((()=>S=!1))),!k&&1024&t[0]&&(k=!0,_.header_avatar=e[10],ve((()=>k=!1))),!L&&512&t[0]&&(L=!0,_.user_avatar=e[9],ve((()=>L=!1))),C.$set(_),(!F||402653184&t[0]&&A!==(A=e[27]?`margin-bottom: ${e[28].distanceToBottom}px;\n margin-right: ${e[28].distanceToRight}px;`:""))&&Y(x,"style",A),201326592&t[0]&&B(x,"chat",!e[26]&&!e[27]),201326592&t[0]&&B(x,"position-absolute-chat",e[26]||e[27]),e[6]?le?(le.p(e,t),64&t[0]&&ke(le,1)):(le=ed(e),le.c(),ke(le,1),le.m(l,P)):le&&(Te(),Oe(le,1,1,(()=>{le=null})),Se()),e[19]&&e[18]&&e[29]?ue&&(Te(),Oe(ue,1,1,(()=>{ue=null})),Se()):ue?537657344&t[0]&&ke(ue,1):(ue=td(),ue.c(),ke(ue,1),ue.m(l,R)),!e[24]&&e[17]?de?(de.p(e,t),16908288&t[0]&&ke(de,1)):(de=nd(e),de.c(),ke(de,1),de.m(l,V)):de&&(Te(),Oe(de,1,1,(()=>{de=null})),Se()),e[23]?he?8388608&t[0]&&ke(he,1):(he=id(),he.c(),ke(he,1),he.m(l,null)):he&&(Te(),Oe(he,1,1,(()=>{he=null})),Se()),(!F||2097152&t[0])&&Y(l,"style",e[21])},i(e){F||(ke(t.$$.fragment,e),ke(i.$$.fragment,e),u&&ke(u.$$.fragment,e),ke($.$$.fragment,e),ke(w.$$.fragment,e),ke(C.$$.fragment,e),ke(le),ke(ue),ke(de),ke(he),F=!0)},o(e){Oe(t.$$.fragment,e),Oe(i.$$.fragment,e),u&&Oe(u.$$.fragment,e),Oe($.$$.fragment,e),Oe(w.$$.fragment,e),Oe(C.$$.fragment,e),Oe(le),Oe(ue),Oe(de),Oe(he),F=!1},d(r){Ue(t,r),r&&M(n),e[38](null),Ue(i,r),r&&M(a),r&&M(l),u&&Ue(u),Ue($),Ue(w),Ue(C),le&&le.d(),ue&&ue.d(),de&&de.d(),he&&he.d()}}}const sd="en-US";function od(e,t,n){let i,r,s,o,a,l,c,u,f,p,m,g,v,y,_,$;h(e,Wi,(e=>n(65,i=e))),h(e,ls,(e=>n(66,r=e))),h(e,li,(e=>n(67,s=e))),h(e,zi,(e=>n(68,o=e))),h(e,Yr,(e=>n(69,a=e))),h(e,ws,(e=>n(23,l=e))),h(e,Ni,(e=>n(70,c=e))),h(e,jr,(e=>n(24,u=e))),h(e,Pi,(e=>n(25,f=e))),h(e,Po,(e=>n(71,p=e))),h(e,Di,(e=>n(72,m=e))),h(e,Bi,(e=>n(73,g=e))),h(e,hs,(e=>n(26,v=e))),h(e,fs,(e=>n(27,y=e))),h(e,ua,(e=>n(28,_=e))),h(e,Wr,(e=>n(29,$=e)));let{body_DOMStringMap:b}=t;console.info({version:"1.0.0"}),Xn.set(sd),ds.set(!0);let E,x,C,T,S="ttt",k=!1,O=!1,L="Digital Noone";s("peer-status.online");let A,I="",M="",N="",D="";const P=()=>{p===Uu&&Lu&&Lu.send(JSON.stringify({event:"request_next_video"}))},R=()=>{w(Bi,g=!1,g),w(Pi,f=!1,f),w(Di,m=!0,m),w(Wi,i=!0,i)};let U,V,F,Y,j,H=!1,z=!1,G=!1,B=0;const W=(e,t=!1)=>{e===p&&w(Po,p="",p),w(Po,p=e,p),U(t)};let q,Z;const X=()=>{clearInterval(Z),q=setTimeout((()=>{n(17,H=!0)}),1e3),async function(){if(!navigator.mediaDevices)throw console.warn("there are no mediadevices"),new Error;try{(await navigator.mediaDevices.getUserMedia({audio:!0})).getTracks().forEach((e=>e.stop()));const{token:e}=await Ts();return!!e}catch(e){throw"NotAllowedError"===e.name?console.warn("microphone access is blocked, no ASR available"):console.warn("some other error in microphone access"),new Error}}().then((e=>{w(jr,u=e,u),n(17,H=!1)})).catch((()=>{q&&clearTimeout(q),n(17,H=!1)}))},K=()=>{n(18,z=!0),Z=setInterval((()=>{document.hasFocus()&&X()}),500)};let J,Q="";const ee=zu?b.vm_version:"1";J=Ea;ne((async()=>{(e=>{const t=Fr;for(let n=0;n<Object.keys(e).length;n++){const i=Object.keys(e)[n],r=e[i];Object.prototype.hasOwnProperty.call(t,i)&&(t[i]=r)}const n=["Nunito","Helvetica","serif"].join(", ");t.font+=t?.font?", "+n:n,t.time_pressure="1"===e?.time_pressure||"true"===e?.time_pressure,["org_id","head_id","embed"].forEach((e=>{const n=Vr[e]??t[e];n&&(t[e]=n)})),Yr.set(t)})(b),await Br(sd);const{org_id:e,head_id:t}=a,u=a.api_base+"/";let d,h;w(Ni,c=await Qu(a.theme||""),c),w(Ni,c.font=a.font,c),n(21,Q=Object.entries(c).map((([e,t])=>`--${e}:${t}`)).join(";"));try{const n=await fetch(`${u}api/v1/head/${e}/${t}`);d=await n.json()}catch(e){const t=e;return void w(ws,l=t?.response?.data?.detail?`Error:\n ${t.response.data.detail}`:`${JSON.stringify(t)}`,l)}if(!d)return void w(ws,l="Error: head does not exist",l);n(7,L=d.name),n(0,S=d.operation_mode),w(Yr,a.language=a.language||d.language||sd,a),await Br(a.language);try{const n=fetch(`${u}api/v1/videos/${e}/${t}`);h=await(await n).json()}catch(e){const t=e;return void(t?.response?.data?.detail?ws.set(`Error:\n ${t.response.data.detail}`):ws.set(`${JSON.stringify(t)}`))}const f=h[0].video_id,p=await fetch(`${u}api/v1/idle/${e}/${t}/${f}`).then((e=>e.json()));n(11,A=URL.createObjectURL(await Vo(p)));try{const i=await fetch(`${u}api/v1/avatar/${e}/${t}/${f}`);n(37,D=await i.json())}catch(e){const t=e;return void(t?.response?.data?.detail?ws.set(`Error:\n ${t.response.data.detail}`):ws.set(`${JSON.stringify(t)}`))}"gc"==S&&w(zi,o=[],o),Yu(x,C,T,e,t,W,K,(e=>{n(20,B=e)}),(e=>{s(e||"opsp"!==S?"peer-status.online":"peer-status.away")}),(()=>{"2"===ee&&w(ls,r=!0,r)}),F,(()=>{j(),w(Wi,i=!0,i)}))}));return e.$$set=e=>{"body_DOMStringMap"in e&&n(36,b=e.body_DOMStringMap)},e.$$.update=()=>{2&e.$$.dirty[0]&&n(2,O="admin"===x),2&e.$$.dirty[0]&&"anonymous"!==x&&n(6,k=!1),26&e.$$.dirty[0]&&x&&Fu(x,C,T),5&e.$$.dirty[0]|64&e.$$.dirty[1]&&("opsp"===S&&O?(n(9,M=D),n(10,N=D),n(8,I="")):(n(9,M=""),n(10,N=D),n(8,I=D)))},[S,x,O,C,T,E,k,L,I,M,N,A,U,V,F,Y,j,H,z,G,B,Q,J,l,u,f,v,y,_,$,P,R,e=>{const t=e.detail;w(Pi,f=!0,f),W(t,!0)},e=>{ju(e),V()},()=>{Y(),P(),w(Pi,f=!1,f)},e=>{(e=>{const t=e.detail,n=d(zi);for(let e=n.length-1;e>=0;e--)if(n[e].url===t){n[e].visible=!0;break}zi.set(n)})(e),w(Wi,i=!0,i)},b,D,function(e){ce[e?"unshift":"push"]((()=>{E=e,n(5,E)}))},function(e){x=e,n(1,x)},function(e){C=e,n(3,C)},function(e){T=e,n(4,T)},function(e){A=e,n(11,A)},function(e){B=e,n(20,B)},function(e){L=e,n(7,L)},function(e){Y=e,n(15,Y)},function(e){j=e,n(16,j)},function(e){U=e,n(12,U)},function(e){V=e,n(13,V)},function(e){F=e,n(14,F)},()=>n(19,G=!0),()=>(R(),P()),()=>(U(!0),w(Pi,f=!0,f)),()=>n(6,k=!0),function(e){L=e,n(7,L)},function(e){I=e,n(8,I),n(0,S),n(2,O),n(37,D),n(1,x)},function(e){N=e,n(10,N),n(0,S),n(2,O),n(37,D),n(1,x)},function(e){M=e,n(9,M),n(0,S),n(2,O),n(37,D),n(1,x)},()=>(U(!0),w(Pi,f=!0,f)),function(e){E=e,n(5,E)},()=>n(6,k=!1),function(e){H=e,n(17,H)}]}const ad=document.getElementById("talking-head"),ld=new class extends Fe{constructor(e){super(),Ve(this,e,od,rd,a,{body_DOMStringMap:36},null,[-1,-1,-1])}}({target:ad,props:{body_DOMStringMap:ad.dataset}});var cd="130, 80, 223",ud="0, 122, 80",dd="249, 219, 223",hd="200, 200, 200",fd="240, 240, 240",pd="30, 30, 30",md={primary:cd,"primary-dimmed":"94, 52, 170",secondary:ud,danger:dd,shadow:hd,body:fd,background:pd,"chat-background":"rgba(var(--primary), 0.6)","download-button-font":"0, 163, 137","download-button-background":"255, 255, 255"},gd=Object.freeze({__proto__:null,primary:cd,secondary:ud,danger:dd,shadow:hd,body:fd,background:pd,default:md});return ld}();