@nyaruka/temba-components 0.35.0 → 0.35.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/{30636513.js → 41042aab.js} +89 -64
  3. package/dist/index.js +89 -64
  4. package/dist/sw.js +1 -1
  5. package/dist/sw.js.map +1 -1
  6. package/dist/templates/components-body.html +1 -1
  7. package/dist/templates/components-head.html +1 -1
  8. package/out-tsc/src/contacts/ContactPending.js +30 -35
  9. package/out-tsc/src/contacts/ContactPending.js.map +1 -1
  10. package/out-tsc/src/contacts/events.js +24 -10
  11. package/out-tsc/src/contacts/events.js.map +1 -1
  12. package/out-tsc/src/date/TembaDate.js +37 -11
  13. package/out-tsc/src/date/TembaDate.js.map +1 -1
  14. package/out-tsc/src/dropdown/Dropdown.js +30 -5
  15. package/out-tsc/src/dropdown/Dropdown.js.map +1 -1
  16. package/out-tsc/src/list/RunList.js +17 -16
  17. package/out-tsc/src/list/RunList.js.map +1 -1
  18. package/out-tsc/src/store/Store.js +12 -26
  19. package/out-tsc/src/store/Store.js.map +1 -1
  20. package/out-tsc/src/vectoricon/index.js +3 -0
  21. package/out-tsc/src/vectoricon/index.js.map +1 -1
  22. package/out-tsc/test/temba-contact-history.test.js +5 -8
  23. package/out-tsc/test/temba-contact-history.test.js.map +1 -1
  24. package/out-tsc/test/temba-date.test.js +3 -9
  25. package/out-tsc/test/temba-date.test.js.map +1 -1
  26. package/out-tsc/test/utils.test.js +9 -0
  27. package/out-tsc/test/utils.test.js.map +1 -1
  28. package/package.json +1 -1
  29. package/screenshots/truth/contacts/contact-active-default.png +0 -0
  30. package/screenshots/truth/contacts/contact-active-show-chat-history.png +0 -0
  31. package/screenshots/truth/contacts/contact-active-show-chat-msg.png +0 -0
  32. package/screenshots/truth/contacts/contact-archived-hide-chat-msg.png +0 -0
  33. package/screenshots/truth/contacts/contact-archived-show-chat-history.png +0 -0
  34. package/screenshots/truth/contacts/contact-blocked-hide-chat-msg.png +0 -0
  35. package/screenshots/truth/contacts/contact-blocked-show-chat-history.png +0 -0
  36. package/screenshots/truth/contacts/contact-stopped-hide-chat-msg.png +0 -0
  37. package/screenshots/truth/contacts/contact-stopped-show-chat-history.png +0 -0
  38. package/screenshots/truth/contacts/fields-updated.png +0 -0
  39. package/screenshots/truth/contacts/history-expanded.png +0 -0
  40. package/screenshots/truth/contacts/history.png +0 -0
  41. package/screenshots/truth/date/duration.png +0 -0
  42. package/src/contacts/ContactPending.ts +38 -34
  43. package/src/contacts/events.ts +24 -10
  44. package/src/date/TembaDate.ts +40 -11
  45. package/src/dropdown/Dropdown.ts +29 -5
  46. package/src/list/RunList.ts +17 -28
  47. package/src/store/Store.ts +13 -37
  48. package/src/vectoricon/index.ts +3 -0
  49. package/test/temba-contact-history.test.ts +7 -7
  50. package/test/temba-date.test.ts +3 -8
  51. package/test/utils.test.ts +10 -1
@@ -1,4 +1,4 @@
1
- function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(s<3?o(r):s>3?o(e,i,r):o(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r}const e=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),n=new WeakMap;class o{constructor(t,e,n){if(this._$cssResult$=!0,n!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=n.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&n.set(i,t))}return t}toString(){return this.cssText}}const s=(t,...e)=>{const n=1===t.length?t[0]:e.reduce(((e,i,n)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[n+1]),t[0]);return new o(n,t,i)},r=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new o("string"==typeof t?t:t+"",void 0,i))(e)})(t):t;var a;const l=window.trustedTypes,c=l?l.emptyScript:"",h=window.reactiveElementPolyfillSupport,d={toAttribute(t,e){switch(e){case Boolean:t=t?c:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},u=(t,e)=>e!==t&&(e==e||t==t),p={attribute:!0,type:String,converter:d,reflect:!1,hasChanged:u};class m extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var e;null!==(e=this.h)&&void 0!==e||(this.h=[]),this.h.push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const n=this._$Ep(i,e);void 0!==n&&(this._$Ev.set(n,i),t.push(n))})),t}static createProperty(t,e=p){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){const i="symbol"==typeof t?Symbol():"__"+t,n=this.getPropertyDescriptor(t,i,e);void 0!==n&&Object.defineProperty(this.prototype,t,n)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(n){const o=this[t];this[e]=n,this.requestUpdate(t,o,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||p}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,e=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const i of e)this.createProperty(i,t[i])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(r(t))}else void 0!==t&&e.push(r(t));return e}static _$Ep(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,i;(null!==(e=this._$ES)&&void 0!==e?e:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(i=t.hostConnected)||void 0===i||i.call(t))}removeController(t){var e;null===(e=this._$ES)||void 0===e||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])}))}createRenderRoot(){var t;const i=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return((t,i)=>{e?t.adoptedStyleSheets=i.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):i.forEach((e=>{const i=document.createElement("style"),n=window.litNonce;void 0!==n&&i.setAttribute("nonce",n),i.textContent=e.cssText,t.appendChild(i)}))})(i,this.constructor.elementStyles),i}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostConnected)||void 0===e?void 0:e.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostDisconnected)||void 0===e?void 0:e.call(t)}))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$EO(t,e,i=p){var n,o;const s=this.constructor._$Ep(t,i);if(void 0!==s&&!0===i.reflect){const r=(null!==(o=null===(n=i.converter)||void 0===n?void 0:n.toAttribute)&&void 0!==o?o:d.toAttribute)(e,i.type);this._$El=t,null==r?this.removeAttribute(s):this.setAttribute(s,r),this._$El=null}}_$AK(t,e){var i,n;const o=this.constructor,s=o._$Ev.get(t);if(void 0!==s&&this._$El!==s){const t=o.getPropertyOptions(s),r=t.converter,a=null!==(n=null!==(i=null==r?void 0:r.fromAttribute)&&void 0!==i?i:"function"==typeof r?r:null)&&void 0!==n?n:d.fromAttribute;this._$El=s,this[s]=a(e,t.type),this._$El=null}}requestUpdate(t,e,i){let n=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||u)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):n=!1),!this.isUpdatePending&&n&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,e)=>this[e]=t)),this._$Ei=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(i)):this._$Ek()}catch(t){throw e=!1,this._$Ek(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$ES)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$EO(e,this[e],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}}var f;m.finalized=!0,m.elementProperties=new Map,m.elementStyles=[],m.shadowRootOptions={mode:"open"},null==h||h({ReactiveElement:m}),(null!==(a=globalThis.reactiveElementVersions)&&void 0!==a?a:globalThis.reactiveElementVersions=[]).push("1.3.4");const g=globalThis.trustedTypes,v=g?g.createPolicy("lit-html",{createHTML:t=>t}):void 0,y=`lit$${(Math.random()+"").slice(9)}$`,b="?"+y,_=`<${b}>`,x=document,w=(t="")=>x.createComment(t),k=t=>null===t||"object"!=typeof t&&"function"!=typeof t,S=Array.isArray,C=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,E=/-->/g,T=/>/g,$=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),O=/'/g,A=/"/g,M=/^(?:script|style|textarea|title)$/i,P=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),z=Symbol.for("lit-noChange"),I=Symbol.for("lit-nothing"),D=new WeakMap,N=x.createTreeWalker(x,129,null,!1),R=(t,e)=>{const i=t.length-1,n=[];let o,s=2===e?"<svg>":"",r=C;for(let e=0;e<i;e++){const i=t[e];let a,l,c=-1,h=0;for(;h<i.length&&(r.lastIndex=h,l=r.exec(i),null!==l);)h=r.lastIndex,r===C?"!--"===l[1]?r=E:void 0!==l[1]?r=T:void 0!==l[2]?(M.test(l[2])&&(o=RegExp("</"+l[2],"g")),r=$):void 0!==l[3]&&(r=$):r===$?">"===l[0]?(r=null!=o?o:C,c=-1):void 0===l[1]?c=-2:(c=r.lastIndex-l[2].length,a=l[1],r=void 0===l[3]?$:'"'===l[3]?A:O):r===A||r===O?r=$:r===E||r===T?r=C:(r=$,o=void 0);const d=r===$&&t[e+1].startsWith("/>")?" ":"";s+=r===C?i+_:c>=0?(n.push(a),i.slice(0,c)+"$lit$"+i.slice(c)+y+d):i+y+(-2===c?(n.push(void 0),e):d)}const a=s+(t[i]||"<?>")+(2===e?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==v?v.createHTML(a):a,n]};class B{constructor({strings:t,_$litType$:e},i){let n;this.parts=[];let o=0,s=0;const r=t.length-1,a=this.parts,[l,c]=R(t,e);if(this.el=B.createElement(l,i),N.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(n=N.nextNode())&&a.length<r;){if(1===n.nodeType){if(n.hasAttributes()){const t=[];for(const e of n.getAttributeNames())if(e.endsWith("$lit$")||e.startsWith(y)){const i=c[s++];if(t.push(e),void 0!==i){const t=n.getAttribute(i.toLowerCase()+"$lit$").split(y),e=/([.?@])?(.*)/.exec(i);a.push({type:1,index:o,name:e[2],strings:t,ctor:"."===e[1]?V:"?"===e[1]?H:"@"===e[1]?G:U})}else a.push({type:6,index:o})}for(const e of t)n.removeAttribute(e)}if(M.test(n.tagName)){const t=n.textContent.split(y),e=t.length-1;if(e>0){n.textContent=g?g.emptyScript:"";for(let i=0;i<e;i++)n.append(t[i],w()),N.nextNode(),a.push({type:2,index:++o});n.append(t[e],w())}}}else if(8===n.nodeType)if(n.data===b)a.push({type:2,index:o});else{let t=-1;for(;-1!==(t=n.data.indexOf(y,t+1));)a.push({type:7,index:o}),t+=y.length-1}o++}}static createElement(t,e){const i=x.createElement("template");return i.innerHTML=t,i}}function q(t,e,i=t,n){var o,s,r,a;if(e===z)return e;let l=void 0!==n?null===(o=i._$Cl)||void 0===o?void 0:o[n]:i._$Cu;const c=k(e)?void 0:e._$litDirective$;return(null==l?void 0:l.constructor)!==c&&(null===(s=null==l?void 0:l._$AO)||void 0===s||s.call(l,!1),void 0===c?l=void 0:(l=new c(t),l._$AT(t,i,n)),void 0!==n?(null!==(r=(a=i)._$Cl)&&void 0!==r?r:a._$Cl=[])[n]=l:i._$Cu=l),void 0!==l&&(e=q(t,l._$AS(t,e.values),l,n)),e}class F{constructor(t,e){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var e;const{el:{content:i},parts:n}=this._$AD,o=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:x).importNode(i,!0);N.currentNode=o;let s=N.nextNode(),r=0,a=0,l=n[0];for(;void 0!==l;){if(r===l.index){let e;2===l.type?e=new Z(s,s.nextSibling,this,t):1===l.type?e=new l.ctor(s,l.name,l.strings,this,t):6===l.type&&(e=new W(s,this,t)),this.v.push(e),l=n[++a]}r!==(null==l?void 0:l.index)&&(s=N.nextNode(),r++)}return o}m(t){let e=0;for(const i of this.v)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class Z{constructor(t,e,i,n){var o;this.type=2,this._$AH=I,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=n,this._$C_=null===(o=null==n?void 0:n.isConnected)||void 0===o||o}get _$AU(){var t,e;return null!==(e=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==e?e:this._$C_}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=q(this,t,e),k(t)?t===I||null==t||""===t?(this._$AH!==I&&this._$AR(),this._$AH=I):t!==this._$AH&&t!==z&&this.T(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.k(t):(t=>S(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.S(t):this.T(t)}j(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.j(t))}T(t){this._$AH!==I&&k(this._$AH)?this._$AA.nextSibling.data=t:this.k(x.createTextNode(t)),this._$AH=t}$(t){var e;const{values:i,_$litType$:n}=t,o="number"==typeof n?this._$AC(t):(void 0===n.el&&(n.el=B.createElement(n.h,this.options)),n);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===o)this._$AH.m(i);else{const t=new F(o,this),e=t.p(this.options);t.m(i),this.k(e),this._$AH=t}}_$AC(t){let e=D.get(t.strings);return void 0===e&&D.set(t.strings,e=new B(t)),e}S(t){S(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,n=0;for(const o of t)n===e.length?e.push(i=new Z(this.j(w()),this.j(w()),this,this.options)):i=e[n],i._$AI(o),n++;n<e.length&&(this._$AR(i&&i._$AB.nextSibling,n),e.length=n)}_$AR(t=this._$AA.nextSibling,e){var i;for(null===(i=this._$AP)||void 0===i||i.call(this,!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){var e;void 0===this._$AM&&(this._$C_=t,null===(e=this._$AP)||void 0===e||e.call(this,t))}}class U{constructor(t,e,i,n,o){this.type=1,this._$AH=I,this._$AN=void 0,this.element=t,this.name=e,this._$AM=n,this.options=o,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=I}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,n){const o=this.strings;let s=!1;if(void 0===o)t=q(this,t,e,0),s=!k(t)||t!==this._$AH&&t!==z,s&&(this._$AH=t);else{const n=t;let r,a;for(t=o[0],r=0;r<o.length-1;r++)a=q(this,n[i+r],e,r),a===z&&(a=this._$AH[r]),s||(s=!k(a)||a!==this._$AH[r]),a===I?t=I:t!==I&&(t+=(null!=a?a:"")+o[r+1]),this._$AH[r]=a}s&&!n&&this.P(t)}P(t){t===I?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class V extends U{constructor(){super(...arguments),this.type=3}P(t){this.element[this.name]=t===I?void 0:t}}const j=g?g.emptyScript:"";class H extends U{constructor(){super(...arguments),this.type=4}P(t){t&&t!==I?this.element.setAttribute(this.name,j):this.element.removeAttribute(this.name)}}class G extends U{constructor(t,e,i,n,o){super(t,e,i,n,o),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=q(this,t,e,0))&&void 0!==i?i:I)===z)return;const n=this._$AH,o=t===I&&n!==I||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,s=t!==I&&(n===I||o);o&&this.element.removeEventListener(this.name,this,n),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,i;"function"==typeof this._$AH?this._$AH.call(null!==(i=null===(e=this.options)||void 0===e?void 0:e.host)&&void 0!==i?i:this.element,t):this._$AH.handleEvent(t)}}class W{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){q(this,t)}}const K=window.litHtmlPolyfillSupport;var Y,J;null==K||K(B,Z),(null!==(f=globalThis.litHtmlVersions)&&void 0!==f?f:globalThis.litHtmlVersions=[]).push("2.2.7");class X extends m{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;const i=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=i.firstChild),i}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,i)=>{var n,o;const s=null!==(n=null==i?void 0:i.renderBefore)&&void 0!==n?n:e;let r=s._$litPart$;if(void 0===r){const t=null!==(o=null==i?void 0:i.renderBefore)&&void 0!==o?o:null;s._$litPart$=r=new Z(e.insertBefore(w(),t),t,void 0,null!=i?i:{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return z}}X.finalized=!0,X._$litElement$=!0,null===(Y=globalThis.litElementHydrateSupport)||void 0===Y||Y.call(globalThis,{LitElement:X});const Q=globalThis.litElementPolyfillSupport;null==Q||Q({LitElement:X}),(null!==(J=globalThis.litElementVersions)&&void 0!==J?J:globalThis.litElementVersions=[]).push("3.2.2");class tt extends X{constructor(){super(...arguments),this.eles={}}getEventHandlers(){return[]}connectedCallback(){super.connectedCallback();for(const t of this.getEventHandlers())t.isDocument?document.addEventListener(t.event,t.method.bind(this)):this.addEventListener(t.event,t.method.bind(this))}disconnectedCallback(){for(const t of this.getEventHandlers())t.isDocument?document.removeEventListener(t.event,t.method):this.removeEventListener(t.event,t.method);super.disconnectedCallback()}fireEvent(t){return this.dispatchEvent(new Event(t,{bubbles:!0,composed:!0}))}fireCustomEvent(t,e={}){const i=new CustomEvent(t,{detail:e,bubbles:!0,composed:!0});return this.dispatchEvent(i)}dispatchEvent(t){super.dispatchEvent(t);const e=t.target;if(e){const i=e["-"+t.type];if(i)return i(t);return new Function("event",`with(document) {\n with(this) {\n let handler = ${e.getAttribute("-"+t.type)};\n if(typeof handler === 'function') { \n handler(event) ;\n }\n }\n }`).call(e,t)}}closestElement(t,e=this){return function e(i){if(!i||i===document||i===window)return null;i.assignedSlot&&(i=i.assignedSlot);const n=i.closest(t);return n||e(i.getRootNode().host)}(e)}getDiv(t){let e=this.eles[t];return e||(e=this.shadowRoot.querySelector(t),e&&(this.eles[t]=e),e)}}const et=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}};function it(t){return(e,i)=>void 0!==i?((t,e,i)=>{e.constructor.createProperty(i,t)})(t,e,i):et(t,e)}var nt,ot;null===(nt=window.HTMLSlotElement)||void 0===nt||nt.prototype.assignedElements;class st extends tt{constructor(){super(...arguments),this.hiddenInputs=[],this.name="",this.values=[],this.value="",this.inputRoot=this,this.disabled=!1}setValue(t){t?this.setValues([t]):this.setValues([]),this.value=t}setValues(t){this.values=t,this.requestUpdate("values")}addValue(t){this.values.push(t),this.requestUpdate("values")}removeValue(t){this.values=this.values.filter((e=>e!==t)),this.requestUpdate("values")}popValue(){this.values.pop(),this.requestUpdate("values")}clear(){this.values=[],this.requestUpdate("values")}serializeValue(t){return JSON.stringify(t)}updateInputs(){for(let t=null;t=this.hiddenInputs.pop();)t.remove();for(const t of this.values){const e=this.getAttribute("name");if(e){const i=document.createElement("input");i.setAttribute("type","hidden"),i.setAttribute("name",e),i.setAttribute("value",this.serializeValue(t)),this.hiddenInputs.push(i),this.inputRoot.parentElement.appendChild(i)}}}updated(t){super.updated(t),t.has("values")&&this.updateInputs()}}t([it({type:String})],st.prototype,"name",void 0),t([it({type:String,attribute:"help_text"})],st.prototype,"helpText",void 0),t([it({type:Boolean,attribute:"help_always"})],st.prototype,"helpAlways",void 0),t([it({type:Boolean,attribute:"widget_only"})],st.prototype,"widgetOnly",void 0),t([it({type:Boolean,attribute:"hide_label"})],st.prototype,"hideLabel",void 0),t([it({type:String})],st.prototype,"label",void 0),t([it({type:Array})],st.prototype,"errors",void 0),t([it({type:Array})],st.prototype,"values",void 0),t([it({type:String})],st.prototype,"value",void 0),t([it({attribute:!1})],st.prototype,"inputRoot",void 0),t([it({type:Boolean})],st.prototype,"disabled",void 0),function(t){t.account="user-01",t.active="play",t.add_note="file-02",t.airtime="bank-note-01",t.archive="archive",t.arrow_up="chevron-up",t.arrow_down="chevron-down",t.arrow_left="chevron-left",t.arrow_right="chevron-right",t.attachment="paperclip",t.broadcast="announcement-01",t.call="phone-call-01",t.call_missed="phone-call-02",t.campaign="clock-refresh",t.campaigns="clock-refresh",t.check="check",t.checkbox="square",t.checkbox_checked="check-square",t.contact="user-01",t.contact_blocked="message-x-square",t.contact_stopped="slash-octagon",t.contact_updated="user-edit",t.contacts="user-01",t.copy="copy-04",t.delete="trash-03",t.delete_small="x",t.download="download-01",t.email="mail-01",t.error="alert-circle",t.event="zap",t.fields="user-edit",t.flow="flow",t.flow_interrupted="x-close",t.flow_ivr="phone-call-01",t.flow_message="message-square-02",t.flow_user="activity",t.flows="flow",t.group="users-01",t.group_smart="atom-01",t.help="help-circle",t.inbox="inbox-01",t.label="tag-01",t.language="globe-01",t.link="link-external-01",t.log="file-02",t.menu="menu-01",t.menu_collapse="chevron-left-double",t.message="message-square-02",t.messages="message-square-02",t.org_active="credit-card-02",t.org_anonymous="glasses-01",t.org_bulk="credit-card-plus",t.org_flagged="flag-01",t.org_new="stars-02",t.org_suspended="slash-circle-01",t.org_verified="check-verified-02",t.featured="star-01",t.resthooks="share-07",t.restore="play",t.search="search-refraction",t.select_open="chevron-down",t.select_clear="x",t.service="magic-wand-01",t.settings="settings-02",t.sort="chevron-selector-vertical",t.staff="hard-drive",t.tickets="agent",t.tickets_all="archive",t.tickets_closed="check",t.tickets_mine="coffee",t.tickets_open="inbox-01",t.tickets_unassigned="inbox-01",t.two_factor_enabled="shield-02",t.two_factor_disabled="shield-01",t.trigger="signal-01",t.triggers="signal-01",t.updated="edit-02",t.upload="upload-cloud-01",t.usages="link-04",t.user="users-01",t.users="users-01",t.user_beta="shield-zap",t.webhook="link-external-01",t.workspace="folder",t.zendesk="zendesk"}(ot||(ot={}));class rt extends st{constructor(){super(...arguments),this.name="",this.disabled=!1,this.size=1.2,this.animateChange="pulse"}static get styles(){return s`
1
+ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(s<3?o(r):s>3?o(e,i,r):o(e,i))||r);return s>3&&r&&Object.defineProperty(e,i,r),r}const e=window.ShadowRoot&&(void 0===window.ShadyCSS||window.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),n=new WeakMap;class o{constructor(t,e,n){if(this._$cssResult$=!0,n!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=n.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&n.set(i,t))}return t}toString(){return this.cssText}}const s=(t,...e)=>{const n=1===t.length?t[0]:e.reduce(((e,i,n)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[n+1]),t[0]);return new o(n,t,i)},r=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new o("string"==typeof t?t:t+"",void 0,i))(e)})(t):t;var a;const l=window.trustedTypes,c=l?l.emptyScript:"",h=window.reactiveElementPolyfillSupport,d={toAttribute(t,e){switch(e){case Boolean:t=t?c:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},u=(t,e)=>e!==t&&(e==e||t==t),p={attribute:!0,type:String,converter:d,reflect:!1,hasChanged:u};class m extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this.u()}static addInitializer(t){var e;null!==(e=this.h)&&void 0!==e||(this.h=[]),this.h.push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((e,i)=>{const n=this._$Ep(i,e);void 0!==n&&(this._$Ev.set(n,i),t.push(n))})),t}static createProperty(t,e=p){if(e.state&&(e.attribute=!1),this.finalize(),this.elementProperties.set(t,e),!e.noAccessor&&!this.prototype.hasOwnProperty(t)){const i="symbol"==typeof t?Symbol():"__"+t,n=this.getPropertyDescriptor(t,i,e);void 0!==n&&Object.defineProperty(this.prototype,t,n)}}static getPropertyDescriptor(t,e,i){return{get(){return this[e]},set(n){const o=this[t];this[e]=n,this.requestUpdate(t,o,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||p}static finalize(){if(this.hasOwnProperty("finalized"))return!1;this.finalized=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,e=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const i of e)this.createProperty(i,t[i])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(r(t))}else void 0!==t&&e.push(r(t));return e}static _$Ep(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}u(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var e,i;(null!==(e=this._$ES)&&void 0!==e?e:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(i=t.hostConnected)||void 0===i||i.call(t))}removeController(t){var e;null===(e=this._$ES)||void 0===e||e.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,e)=>{this.hasOwnProperty(e)&&(this._$Ei.set(e,this[e]),delete this[e])}))}createRenderRoot(){var t;const i=null!==(t=this.shadowRoot)&&void 0!==t?t:this.attachShadow(this.constructor.shadowRootOptions);return((t,i)=>{e?t.adoptedStyleSheets=i.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):i.forEach((e=>{const i=document.createElement("style"),n=window.litNonce;void 0!==n&&i.setAttribute("nonce",n),i.textContent=e.cssText,t.appendChild(i)}))})(i,this.constructor.elementStyles),i}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostConnected)||void 0===e?void 0:e.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostDisconnected)||void 0===e?void 0:e.call(t)}))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$EO(t,e,i=p){var n,o;const s=this.constructor._$Ep(t,i);if(void 0!==s&&!0===i.reflect){const r=(null!==(o=null===(n=i.converter)||void 0===n?void 0:n.toAttribute)&&void 0!==o?o:d.toAttribute)(e,i.type);this._$El=t,null==r?this.removeAttribute(s):this.setAttribute(s,r),this._$El=null}}_$AK(t,e){var i,n;const o=this.constructor,s=o._$Ev.get(t);if(void 0!==s&&this._$El!==s){const t=o.getPropertyOptions(s),r=t.converter,a=null!==(n=null!==(i=null==r?void 0:r.fromAttribute)&&void 0!==i?i:"function"==typeof r?r:null)&&void 0!==n?n:d.fromAttribute;this._$El=s,this[s]=a(e,t.type),this._$El=null}}requestUpdate(t,e,i){let n=!0;void 0!==t&&(((i=i||this.constructor.getPropertyOptions(t)).hasChanged||u)(this[t],e)?(this._$AL.has(t)||this._$AL.set(t,e),!0===i.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,i))):n=!1),!this.isUpdatePending&&n&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,e)=>this[e]=t)),this._$Ei=void 0);let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var e;return null===(e=t.hostUpdate)||void 0===e?void 0:e.call(t)})),this.update(i)):this._$Ek()}catch(t){throw e=!1,this._$Ek(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null===(e=this._$ES)||void 0===e||e.forEach((t=>{var e;return null===(e=t.hostUpdated)||void 0===e?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,e)=>this._$EO(e,this[e],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}}var f;m.finalized=!0,m.elementProperties=new Map,m.elementStyles=[],m.shadowRootOptions={mode:"open"},null==h||h({ReactiveElement:m}),(null!==(a=globalThis.reactiveElementVersions)&&void 0!==a?a:globalThis.reactiveElementVersions=[]).push("1.3.4");const g=globalThis.trustedTypes,v=g?g.createPolicy("lit-html",{createHTML:t=>t}):void 0,y=`lit$${(Math.random()+"").slice(9)}$`,b="?"+y,_=`<${b}>`,x=document,w=(t="")=>x.createComment(t),k=t=>null===t||"object"!=typeof t&&"function"!=typeof t,S=Array.isArray,C=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,E=/-->/g,T=/>/g,$=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),O=/'/g,A=/"/g,M=/^(?:script|style|textarea|title)$/i,P=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),z=Symbol.for("lit-noChange"),I=Symbol.for("lit-nothing"),D=new WeakMap,N=x.createTreeWalker(x,129,null,!1),R=(t,e)=>{const i=t.length-1,n=[];let o,s=2===e?"<svg>":"",r=C;for(let e=0;e<i;e++){const i=t[e];let a,l,c=-1,h=0;for(;h<i.length&&(r.lastIndex=h,l=r.exec(i),null!==l);)h=r.lastIndex,r===C?"!--"===l[1]?r=E:void 0!==l[1]?r=T:void 0!==l[2]?(M.test(l[2])&&(o=RegExp("</"+l[2],"g")),r=$):void 0!==l[3]&&(r=$):r===$?">"===l[0]?(r=null!=o?o:C,c=-1):void 0===l[1]?c=-2:(c=r.lastIndex-l[2].length,a=l[1],r=void 0===l[3]?$:'"'===l[3]?A:O):r===A||r===O?r=$:r===E||r===T?r=C:(r=$,o=void 0);const d=r===$&&t[e+1].startsWith("/>")?" ":"";s+=r===C?i+_:c>=0?(n.push(a),i.slice(0,c)+"$lit$"+i.slice(c)+y+d):i+y+(-2===c?(n.push(void 0),e):d)}const a=s+(t[i]||"<?>")+(2===e?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==v?v.createHTML(a):a,n]};class B{constructor({strings:t,_$litType$:e},i){let n;this.parts=[];let o=0,s=0;const r=t.length-1,a=this.parts,[l,c]=R(t,e);if(this.el=B.createElement(l,i),N.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(n=N.nextNode())&&a.length<r;){if(1===n.nodeType){if(n.hasAttributes()){const t=[];for(const e of n.getAttributeNames())if(e.endsWith("$lit$")||e.startsWith(y)){const i=c[s++];if(t.push(e),void 0!==i){const t=n.getAttribute(i.toLowerCase()+"$lit$").split(y),e=/([.?@])?(.*)/.exec(i);a.push({type:1,index:o,name:e[2],strings:t,ctor:"."===e[1]?V:"?"===e[1]?H:"@"===e[1]?G:U})}else a.push({type:6,index:o})}for(const e of t)n.removeAttribute(e)}if(M.test(n.tagName)){const t=n.textContent.split(y),e=t.length-1;if(e>0){n.textContent=g?g.emptyScript:"";for(let i=0;i<e;i++)n.append(t[i],w()),N.nextNode(),a.push({type:2,index:++o});n.append(t[e],w())}}}else if(8===n.nodeType)if(n.data===b)a.push({type:2,index:o});else{let t=-1;for(;-1!==(t=n.data.indexOf(y,t+1));)a.push({type:7,index:o}),t+=y.length-1}o++}}static createElement(t,e){const i=x.createElement("template");return i.innerHTML=t,i}}function q(t,e,i=t,n){var o,s,r,a;if(e===z)return e;let l=void 0!==n?null===(o=i._$Cl)||void 0===o?void 0:o[n]:i._$Cu;const c=k(e)?void 0:e._$litDirective$;return(null==l?void 0:l.constructor)!==c&&(null===(s=null==l?void 0:l._$AO)||void 0===s||s.call(l,!1),void 0===c?l=void 0:(l=new c(t),l._$AT(t,i,n)),void 0!==n?(null!==(r=(a=i)._$Cl)&&void 0!==r?r:a._$Cl=[])[n]=l:i._$Cu=l),void 0!==l&&(e=q(t,l._$AS(t,e.values),l,n)),e}class F{constructor(t,e){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var e;const{el:{content:i},parts:n}=this._$AD,o=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:x).importNode(i,!0);N.currentNode=o;let s=N.nextNode(),r=0,a=0,l=n[0];for(;void 0!==l;){if(r===l.index){let e;2===l.type?e=new Z(s,s.nextSibling,this,t):1===l.type?e=new l.ctor(s,l.name,l.strings,this,t):6===l.type&&(e=new W(s,this,t)),this.v.push(e),l=n[++a]}r!==(null==l?void 0:l.index)&&(s=N.nextNode(),r++)}return o}m(t){let e=0;for(const i of this.v)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class Z{constructor(t,e,i,n){var o;this.type=2,this._$AH=I,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=n,this._$C_=null===(o=null==n?void 0:n.isConnected)||void 0===o||o}get _$AU(){var t,e;return null!==(e=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==e?e:this._$C_}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=q(this,t,e),k(t)?t===I||null==t||""===t?(this._$AH!==I&&this._$AR(),this._$AH=I):t!==this._$AH&&t!==z&&this.T(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.k(t):(t=>S(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.S(t):this.T(t)}j(t,e=this._$AB){return this._$AA.parentNode.insertBefore(t,e)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.j(t))}T(t){this._$AH!==I&&k(this._$AH)?this._$AA.nextSibling.data=t:this.k(x.createTextNode(t)),this._$AH=t}$(t){var e;const{values:i,_$litType$:n}=t,o="number"==typeof n?this._$AC(t):(void 0===n.el&&(n.el=B.createElement(n.h,this.options)),n);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===o)this._$AH.m(i);else{const t=new F(o,this),e=t.p(this.options);t.m(i),this.k(e),this._$AH=t}}_$AC(t){let e=D.get(t.strings);return void 0===e&&D.set(t.strings,e=new B(t)),e}S(t){S(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,n=0;for(const o of t)n===e.length?e.push(i=new Z(this.j(w()),this.j(w()),this,this.options)):i=e[n],i._$AI(o),n++;n<e.length&&(this._$AR(i&&i._$AB.nextSibling,n),e.length=n)}_$AR(t=this._$AA.nextSibling,e){var i;for(null===(i=this._$AP)||void 0===i||i.call(this,!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){var e;void 0===this._$AM&&(this._$C_=t,null===(e=this._$AP)||void 0===e||e.call(this,t))}}class U{constructor(t,e,i,n,o){this.type=1,this._$AH=I,this._$AN=void 0,this.element=t,this.name=e,this._$AM=n,this.options=o,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=I}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,n){const o=this.strings;let s=!1;if(void 0===o)t=q(this,t,e,0),s=!k(t)||t!==this._$AH&&t!==z,s&&(this._$AH=t);else{const n=t;let r,a;for(t=o[0],r=0;r<o.length-1;r++)a=q(this,n[i+r],e,r),a===z&&(a=this._$AH[r]),s||(s=!k(a)||a!==this._$AH[r]),a===I?t=I:t!==I&&(t+=(null!=a?a:"")+o[r+1]),this._$AH[r]=a}s&&!n&&this.P(t)}P(t){t===I?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class V extends U{constructor(){super(...arguments),this.type=3}P(t){this.element[this.name]=t===I?void 0:t}}const j=g?g.emptyScript:"";class H extends U{constructor(){super(...arguments),this.type=4}P(t){t&&t!==I?this.element.setAttribute(this.name,j):this.element.removeAttribute(this.name)}}class G extends U{constructor(t,e,i,n,o){super(t,e,i,n,o),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=q(this,t,e,0))&&void 0!==i?i:I)===z)return;const n=this._$AH,o=t===I&&n!==I||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,s=t!==I&&(n===I||o);o&&this.element.removeEventListener(this.name,this,n),s&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,i;"function"==typeof this._$AH?this._$AH.call(null!==(i=null===(e=this.options)||void 0===e?void 0:e.host)&&void 0!==i?i:this.element,t):this._$AH.handleEvent(t)}}class W{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){q(this,t)}}const K=window.litHtmlPolyfillSupport;var Y,J;null==K||K(B,Z),(null!==(f=globalThis.litHtmlVersions)&&void 0!==f?f:globalThis.litHtmlVersions=[]).push("2.2.7");class X extends m{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,e;const i=super.createRenderRoot();return null!==(t=(e=this.renderOptions).renderBefore)&&void 0!==t||(e.renderBefore=i.firstChild),i}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,i)=>{var n,o;const s=null!==(n=null==i?void 0:i.renderBefore)&&void 0!==n?n:e;let r=s._$litPart$;if(void 0===r){const t=null!==(o=null==i?void 0:i.renderBefore)&&void 0!==o?o:null;s._$litPart$=r=new Z(e.insertBefore(w(),t),t,void 0,null!=i?i:{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return z}}X.finalized=!0,X._$litElement$=!0,null===(Y=globalThis.litElementHydrateSupport)||void 0===Y||Y.call(globalThis,{LitElement:X});const Q=globalThis.litElementPolyfillSupport;null==Q||Q({LitElement:X}),(null!==(J=globalThis.litElementVersions)&&void 0!==J?J:globalThis.litElementVersions=[]).push("3.2.2");class tt extends X{constructor(){super(...arguments),this.eles={}}getEventHandlers(){return[]}connectedCallback(){super.connectedCallback();for(const t of this.getEventHandlers())t.isDocument?document.addEventListener(t.event,t.method.bind(this)):this.addEventListener(t.event,t.method.bind(this))}disconnectedCallback(){for(const t of this.getEventHandlers())t.isDocument?document.removeEventListener(t.event,t.method):this.removeEventListener(t.event,t.method);super.disconnectedCallback()}fireEvent(t){return this.dispatchEvent(new Event(t,{bubbles:!0,composed:!0}))}fireCustomEvent(t,e={}){const i=new CustomEvent(t,{detail:e,bubbles:!0,composed:!0});return this.dispatchEvent(i)}dispatchEvent(t){super.dispatchEvent(t);const e=t.target;if(e){const i=e["-"+t.type];if(i)return i(t);return new Function("event",`with(document) {\n with(this) {\n let handler = ${e.getAttribute("-"+t.type)};\n if(typeof handler === 'function') { \n handler(event) ;\n }\n }\n }`).call(e,t)}}closestElement(t,e=this){return function e(i){if(!i||i===document||i===window)return null;i.assignedSlot&&(i=i.assignedSlot);const n=i.closest(t);return n||e(i.getRootNode().host)}(e)}getDiv(t){let e=this.eles[t];return e||(e=this.shadowRoot.querySelector(t),e&&(this.eles[t]=e),e)}}const et=(t,e)=>"method"===e.kind&&e.descriptor&&!("value"in e.descriptor)?{...e,finisher(i){i.createProperty(e.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:e.key,initializer(){"function"==typeof e.initializer&&(this[e.key]=e.initializer.call(this))},finisher(i){i.createProperty(e.key,t)}};function it(t){return(e,i)=>void 0!==i?((t,e,i)=>{e.constructor.createProperty(i,t)})(t,e,i):et(t,e)}var nt,ot;null===(nt=window.HTMLSlotElement)||void 0===nt||nt.prototype.assignedElements;class st extends tt{constructor(){super(...arguments),this.hiddenInputs=[],this.name="",this.values=[],this.value="",this.inputRoot=this,this.disabled=!1}setValue(t){t?this.setValues([t]):this.setValues([]),this.value=t}setValues(t){this.values=t,this.requestUpdate("values")}addValue(t){this.values.push(t),this.requestUpdate("values")}removeValue(t){this.values=this.values.filter((e=>e!==t)),this.requestUpdate("values")}popValue(){this.values.pop(),this.requestUpdate("values")}clear(){this.values=[],this.requestUpdate("values")}serializeValue(t){return JSON.stringify(t)}updateInputs(){for(let t=null;t=this.hiddenInputs.pop();)t.remove();for(const t of this.values){const e=this.getAttribute("name");if(e){const i=document.createElement("input");i.setAttribute("type","hidden"),i.setAttribute("name",e),i.setAttribute("value",this.serializeValue(t)),this.hiddenInputs.push(i),this.inputRoot.parentElement.appendChild(i)}}}updated(t){super.updated(t),t.has("values")&&this.updateInputs()}}t([it({type:String})],st.prototype,"name",void 0),t([it({type:String,attribute:"help_text"})],st.prototype,"helpText",void 0),t([it({type:Boolean,attribute:"help_always"})],st.prototype,"helpAlways",void 0),t([it({type:Boolean,attribute:"widget_only"})],st.prototype,"widgetOnly",void 0),t([it({type:Boolean,attribute:"hide_label"})],st.prototype,"hideLabel",void 0),t([it({type:String})],st.prototype,"label",void 0),t([it({type:Array})],st.prototype,"errors",void 0),t([it({type:Array})],st.prototype,"values",void 0),t([it({type:String})],st.prototype,"value",void 0),t([it({attribute:!1})],st.prototype,"inputRoot",void 0),t([it({type:Boolean})],st.prototype,"disabled",void 0),function(t){t.analytics="bar-chart-01",t.account="user-01",t.active="play",t.add_note="file-02",t.airtime="bank-note-01",t.archive="archive",t.arrow_up="chevron-up",t.arrow_down="chevron-down",t.arrow_left="chevron-left",t.arrow_right="chevron-right",t.attachment="paperclip",t.broadcast="announcement-01",t.call="phone-call-01",t.call_missed="phone-call-02",t.campaign="clock-refresh",t.campaigns="clock-refresh",t.check="check",t.checkbox="square",t.checkbox_checked="check-square",t.contact="user-01",t.contact_blocked="message-x-square",t.contact_stopped="slash-octagon",t.contact_updated="user-edit",t.contacts="user-01",t.copy="copy-04",t.delete="trash-03",t.delete_small="x",t.download="download-01",t.email="mail-01",t.error="alert-circle",t.event="zap",t.fields="user-edit",t.flow="flow",t.flow_interrupted="x-close",t.flow_ivr="phone-call-01",t.flow_message="message-square-02",t.flow_user="activity",t.flows="flow",t.group="users-01",t.group_smart="atom-01",t.help="help-circle",t.inbox="inbox-01",t.label="tag-01",t.language="globe-01",t.link="link-external-01",t.log="file-02",t.menu="menu-01",t.menu_collapse="chevron-left-double",t.message="message-square-02",t.messages="message-square-02",t.org_active="credit-card-02",t.org_anonymous="glasses-01",t.org_bulk="credit-card-plus",t.org_flagged="flag-01",t.org_new="stars-02",t.org_suspended="slash-circle-01",t.org_verified="check-verified-02",t.overview="pie-chart-01",t.featured="star-01",t.resthooks="share-07",t.restore="play",t.runs="rows-03",t.search="search-refraction",t.select_open="chevron-down",t.select_clear="x",t.service="magic-wand-01",t.settings="settings-02",t.sort="chevron-selector-vertical",t.staff="hard-drive",t.tickets="agent",t.tickets_all="archive",t.tickets_closed="check",t.tickets_mine="coffee",t.tickets_open="inbox-01",t.tickets_unassigned="inbox-01",t.two_factor_enabled="shield-02",t.two_factor_disabled="shield-01",t.trigger="signal-01",t.triggers="signal-01",t.updated="edit-02",t.upload="upload-cloud-01",t.usages="link-04",t.user="users-01",t.users="users-01",t.user_beta="shield-zap",t.webhook="link-external-01",t.workspace="folder",t.zendesk="zendesk"}(ot||(ot={}));class rt extends st{constructor(){super(...arguments),this.name="",this.disabled=!1,this.size=1.2,this.animateChange="pulse"}static get styles(){return s`
2
2
  :host {
3
3
  color: var(--color-text);
4
4
  display: inline-block;
@@ -221,7 +221,7 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
221
221
  <slot></slot>
222
222
  </div>
223
223
  </temba-field>
224
- `}}t([it({type:Boolean})],pt.prototype,"textarea",void 0),t([it({type:String})],pt.prototype,"placeholder",void 0),t([it({type:String})],pt.prototype,"value",void 0),t([it({type:Boolean})],pt.prototype,"password",void 0),t([it({type:Number})],pt.prototype,"maxlength",void 0),t([it({type:Object})],pt.prototype,"inputElement",void 0),t([it({type:Boolean})],pt.prototype,"clearable",void 0),t([it({type:Boolean})],pt.prototype,"gsm",void 0),t([it({type:String})],pt.prototype,"counter",void 0),t([it({type:Boolean})],pt.prototype,"loading",void 0),t([it({type:Boolean})],pt.prototype,"submitOnEnter",void 0),t([it()],pt.prototype,"onBlur",void 0),t([it({type:Boolean})],pt.prototype,"autogrow",void 0);const mt=/(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))/,ft=(t={})=>{const e=(t=>{for(const e of document.cookie.split(";")){const i=e.indexOf("=");let n=e.substr(0,i),o=e.substr(i+1);if(n=n.trim(),o=o.trim(),n===t)return o}return null})("csrftoken"),i=e?{"X-CSRFToken":e}:{};return i["X-Requested-With"]="XMLHttpRequest",Object.keys(t).forEach((e=>{i[e]=t[e]})),i},gt=(t,e=null,i={})=>new Promise(((n,o)=>{const s={method:"GET",headers:ft(i)};e&&(s.signal=e.signal),fetch(t,s).then((t=>{t.text().then((i=>{let o={};try{o=JSON.parse(i)}catch(t){}n({controller:e,body:i,json:o,headers:t.headers,status:t.status})}))})).catch((t=>{o(t)}))})),vt=t=>{const e=[];Object.keys(t).forEach((i=>{t[i]&&e.push(i)}));let i=e.join(" ");return i.trim().length>0&&(i=" "+i),i},yt=(t,e=null)=>new Promise(((i,n)=>{gt(t,e).then((t=>{i({results:t.json.results,next:t.json.next})})).catch((t=>n(t)))})),bt=async t=>{if(!t)return new Promise((t=>t([])));let e=[],i=t;for(;i;){const t=await yt(i);t.results&&(e=e.concat(t.results)),i=t.next}return e},_t=t=>new Promise(((e,i)=>{gt(t).then((t=>{e({assets:t.json.results,next:t.json.next})})).catch((t=>i(t)))})),xt=async t=>{if(!t)return new Promise((t=>t([])));let e=[],i=t;for(;i;){const t=await _t(i);e=e.concat(t.assets),i=t.next}return e},wt=(t,e,i={},n=null)=>{const o=ft(i);n&&(o["Content-Type"]=n);const s={method:"POST",headers:o,body:e};return new Promise(((e,i)=>{fetch(t,s).then((async t=>{t.text().then((i=>{let n={};try{n=JSON.parse(i)}catch(t){}e({body:i,json:n,headers:t.headers,status:t.status})}))})).catch((t=>{i(t)}))}))},kt=(t,e)=>wt(t,JSON.stringify(e),!1,"application/json"),St=t=>{const e=t.parentNode||t.host;if(e){const t=e instanceof HTMLElement&&window.getComputedStyle(e).overflowY,i=t&&!(t.includes("hidden")||t.includes("visible"));return e?i&&e.scrollHeight>=e.clientHeight?e:St(e):null}return null};const Ct=new class{getCurrentDate(){return new Date}},Et=(t,e={suffix:""})=>{const{compareDate:i,hideRecentText:n,suffix:o}=e,s=i||Ct.getCurrentDate(),r=Math.floor((s.getTime()-t.getTime())/1e3);if(r<60)return i?r+"s"+o:!n&&o?o:"just now";if(r<3600)return Math.round(r/60)+"m"+o;if(r<=86400)return Math.round(r/3600)+"h"+o;if(r<=2592e3)return Math.round(r/86400)+"d"+o;if(r<15552e3)return Math.round(r/2592e3)+"mth"+o;return t.getDate()+" "+t.toDateString().match(/ [a-zA-Z]*/)[0].replace(" ","")+(t.getFullYear()==s.getFullYear()?"":" "+t.getFullYear())},Tt=(t,e)=>{let i=!0;return function(...n){i&&(i=!1,t.apply(this,n),setTimeout((()=>{i=!0}),e))}},$t=(t,e="and")=>1===t.length?t[0]:2===t.length?"html"===t[0].type?P`${t[0]} ${e} ${t[1]}`:t.join(" "+e+" "):"html"===t[0].type?t.map(((i,n)=>n<t.length-1?P`${i}, `:P`${e} ${i}`)):t.join(", ")+e+t[t.length-1],Lt=(t,e,i="and")=>$t(t.map(e),i),Ot=t=>"true"===((t=>{let e=null;if(document.cookie&&""!=document.cookie){const i=document.cookie.split(";");for(let n=0;n<i.length;n++){const o=i[n].trim();if(o.substring(0,t.length+1)==t+"="){e=decodeURIComponent(o.substring(t.length+1));break}}}return e})(t)||"");var At;!function(t){t.MENU_COLLAPSED="menu-collapsed",t.TICKET_SHOW_DETAILS="tickets.show-details"}(At||(At={}));var Mt,Pt,zt,It;!function(t){t.DayFirst="day_first",t.MonthFirst="month_first",t.YearFirst="year_first"}(Mt||(Mt={})),function(t){t.CampaignEvent="campaign_event",t.ScheduledBroadcast="scheduled_broadcast",t.ScheduledTrigger="scheduled_trigger"}(Pt||(Pt={})),function(t){t.Open="open",t.Closed="closed"}(zt||(zt={})),function(t){t.Loaded="temba-loaded",t.Canceled="temba-canceled",t.CursorChanged="temba-cursor-changed",t.Refreshed="temba-refreshed",t.Selection="temba-selection",t.ButtonClicked="temba-button-clicked",t.DialogHidden="temba-dialog-hidden",t.ScrollThreshold="temba-scroll-threshold",t.ContentChanged="temba-content-changed",t.ContextChanged="temba-context-changed",t.FetchComplete="temba-fetch-complete",t.Submitted="temba-submitted",t.Redirected="temba-redirected",t.NoPath="temba-no-path",t.StoreUpdated="temba-store-updated",t.Ready="temba-ready",t.OrderChanged="temba-order-changed",t.DragStart="temba-drag-start",t.DragStop="temba-drag-stop"}(It||(It={}));class Dt{constructor(t=0,e=0){this.first=null,this.items=Object.create(null),this.last=null,this.max=t,this.size=0,this.ttl=e}has(t){return t in this.items}clear(){return this.first=null,this.items=Object.create(null),this.last=null,this.size=0,this}delete(t){if(this.has(t)){const e=this.items[t];delete this.items[t],this.size--,null!==e.prev&&(e.prev.next=e.next),null!==e.next&&(e.next.prev=e.prev),this.first===e&&(this.first=e.next),this.last===e&&(this.last=e.prev)}return this}evict(t=!1){if(t||this.size>0){const t=this.first;delete this.items[t.key],this.size--,0===this.size?(this.first=null,this.last=null):(this.first=t.next,this.first.prev=null)}return this}get(t){let e;if(this.has(t)){const i=this.items[t];this.ttl>0&&i.expiry<=(new Date).getTime()?this.delete(t):(e=i.value,this.set(t,e,!0))}return e}keys(){return Object.keys(this.items)}set(t,e,i=!1){let n;if(i||this.has(t)){if(n=this.items[t],n.value=e,this.last!==n){const t=this.last,e=n.next,i=n.prev;this.first===n&&(this.first=n.next),n.next=null,n.prev=this.last,t.next=n,null!==i&&(i.next=e),null!==e&&(e.prev=i)}}else this.max>0&&this.size===this.max&&this.evict(!0),n=this.items[t]={expiry:this.ttl>0?(new Date).getTime()+this.ttl:this.ttl,key:t,prev:this.last,next:null,value:e},1==++this.size?this.first=n:this.last.next=n;return this.last=n,this}}function Nt(t=1e3,e=0){if(isNaN(t)||t<0)throw new TypeError("Invalid max value");if(isNaN(e)||e<0)throw new TypeError("Invalid ttl value");return new Dt(t,e)}var Rt=function(){function t(){var t=this;this.languages={ar:{y:function(t){return 1===t?"سنة":"سنوات"},mo:function(t){return 1===t?"شهر":"أشهر"},w:function(t){return 1===t?"أسبوع":"أسابيع"},d:function(t){return 1===t?"يوم":"أيام"},h:function(t){return 1===t?"ساعة":"ساعات"},m:function(e){return["دقيقة","دقائق"][t.getArabicForm(e)]},s:function(t){return 1===t?"ثانية":"ثواني"},ms:function(t){return 1===t?"جزء من الثانية":"أجزاء من الثانية"},decimal:","},bg:{y:function(e){return["години","година","години"][t.getSlavicForm(e)]},mo:function(e){return["месеца","месец","месеца"][t.getSlavicForm(e)]},w:function(e){return["седмици","седмица","седмици"][t.getSlavicForm(e)]},d:function(e){return["дни","ден","дни"][t.getSlavicForm(e)]},h:function(e){return["часа","час","часа"][t.getSlavicForm(e)]},m:function(e){return["минути","минута","минути"][t.getSlavicForm(e)]},s:function(e){return["секунди","секунда","секунди"][t.getSlavicForm(e)]},ms:function(e){return["милисекунди","милисекунда","милисекунди"][t.getSlavicForm(e)]},decimal:","},ca:{y:function(t){return"any"+(1===t?"":"s")},mo:function(t){return"mes"+(1===t?"":"os")},w:function(t){return"setman"+(1===t?"a":"es")},d:function(t){return"di"+(1===t?"a":"es")},h:function(t){return"hor"+(1===t?"a":"es")},m:function(t){return"minut"+(1===t?"":"s")},s:function(t){return"segon"+(1===t?"":"s")},ms:function(t){return"milisegon"+(1===t?"":"s")},decimal:","},cs:{y:function(e){return["rok","roku","roky","let"][t.getCzechOrSlovakForm(e)]},mo:function(e){return["měsíc","měsíce","měsíce","měsíců"][t.getCzechOrSlovakForm(e)]},w:function(e){return["týden","týdne","týdny","týdnů"][t.getCzechOrSlovakForm(e)]},d:function(e){return["den","dne","dny","dní"][t.getCzechOrSlovakForm(e)]},h:function(e){return["hodina","hodiny","hodiny","hodin"][t.getCzechOrSlovakForm(e)]},m:function(e){return["minuta","minuty","minuty","minut"][t.getCzechOrSlovakForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekund"][t.getCzechOrSlovakForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekund"][t.getCzechOrSlovakForm(e)]},decimal:","},da:{y:function(){return"år"},mo:function(t){return"måned"+(1===t?"":"er")},w:function(t){return"uge"+(1===t?"":"r")},d:function(t){return"dag"+(1===t?"":"e")},h:function(t){return"time"+(1===t?"":"r")},m:function(t){return"minut"+(1===t?"":"ter")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},de:{y:function(t){return"Jahr"+(1===t?"":"e")},mo:function(t){return"Monat"+(1===t?"":"e")},w:function(t){return"Woche"+(1===t?"":"n")},d:function(t){return"Tag"+(1===t?"":"e")},h:function(t){return"Stunde"+(1===t?"":"n")},m:function(t){return"Minute"+(1===t?"":"n")},s:function(t){return"Sekunde"+(1===t?"":"n")},ms:function(t){return"Millisekunde"+(1===t?"":"n")},decimal:","},el:{y:function(t){return 1===t?"χρόνος":"χρόνια"},mo:function(t){return 1===t?"μήνας":"μήνες"},w:function(t){return 1===t?"εβδομάδα":"εβδομάδες"},d:function(t){return 1===t?"μέρα":"μέρες"},h:function(t){return 1===t?"ώρα":"ώρες"},m:function(t){return 1===t?"λεπτό":"λεπτά"},s:function(t){return 1===t?"δευτερόλεπτο":"δευτερόλεπτα"},ms:function(t){return 1===t?"χιλιοστό του δευτερολέπτου":"χιλιοστά του δευτερολέπτου"},decimal:","},en:{y:function(t){return"year"+(1===t?"":"s")},mo:function(t){return"month"+(1===t?"":"s")},w:function(t){return"week"+(1===t?"":"s")},d:function(t){return"day"+(1===t?"":"s")},h:function(t){return"hour"+(1===t?"":"s")},m:function(t){return"minute"+(1===t?"":"s")},s:function(t){return"second"+(1===t?"":"s")},ms:function(t){return"millisecond"+(1===t?"":"s")},decimal:"."},es:{y:function(t){return"año"+(1===t?"":"s")},mo:function(t){return"mes"+(1===t?"":"es")},w:function(t){return"semana"+(1===t?"":"s")},d:function(t){return"día"+(1===t?"":"s")},h:function(t){return"hora"+(1===t?"":"s")},m:function(t){return"minuto"+(1===t?"":"s")},s:function(t){return"segundo"+(1===t?"":"s")},ms:function(t){return"milisegundo"+(1===t?"":"s")},decimal:","},et:{y:function(t){return"aasta"+(1===t?"":"t")},mo:function(t){return"kuu"+(1===t?"":"d")},w:function(t){return"nädal"+(1===t?"":"at")},d:function(t){return"päev"+(1===t?"":"a")},h:function(t){return"tund"+(1===t?"":"i")},m:function(t){return"minut"+(1===t?"":"it")},s:function(t){return"sekund"+(1===t?"":"it")},ms:function(t){return"millisekund"+(1===t?"":"it")},decimal:","},fa:{y:function(){return"سال"},mo:function(){return"ماه"},w:function(){return"هفته"},d:function(){return"روز"},h:function(){return"ساعت"},m:function(){return"دقیقه"},s:function(){return"ثانیه"},ms:function(){return"میلی ثانیه"},decimal:"."},fi:{y:function(t){return 1===t?"vuosi":"vuotta"},mo:function(t){return 1===t?"kuukausi":"kuukautta"},w:function(t){return"viikko"+(1===t?"":"a")},d:function(t){return"päivä"+(1===t?"":"ä")},h:function(t){return"tunti"+(1===t?"":"a")},m:function(t){return"minuutti"+(1===t?"":"a")},s:function(t){return"sekunti"+(1===t?"":"a")},ms:function(t){return"millisekunti"+(1===t?"":"a")},decimal:","},fo:{y:function(){return"ár"},mo:function(t){return 1===t?"mánaður":"mánaðir"},w:function(t){return 1===t?"vika":"vikur"},d:function(t){return 1===t?"dagur":"dagar"},h:function(t){return 1===t?"tími":"tímar"},m:function(t){return 1===t?"minuttur":"minuttir"},s:function(){return"sekund"},ms:function(){return"millisekund"},decimal:","},fr:{y:function(t){return"an"+(t>=2?"s":"")},mo:function(){return"mois"},w:function(t){return"semaine"+(t>=2?"s":"")},d:function(t){return"jour"+(t>=2?"s":"")},h:function(t){return"heure"+(t>=2?"s":"")},m:function(t){return"minute"+(t>=2?"s":"")},s:function(t){return"seconde"+(t>=2?"s":"")},ms:function(t){return"milliseconde"+(t>=2?"s":"")},decimal:","},hr:{y:function(t){return t%10==2||t%10==3||t%10==4?"godine":"godina"},mo:function(t){return 1===t?"mjesec":2===t||3===t||4===t?"mjeseca":"mjeseci"},w:function(t){return t%10==1&&11!==t?"tjedan":"tjedna"},d:function(t){return 1===t?"dan":"dana"},h:function(t){return 1===t?"sat":2===t||3===t||4===t?"sata":"sati"},m:function(t){var e=t%10;return 2!==e&&3!==e&&4!==e||!(t<10||t>14)?"minuta":"minute"},s:function(t){return 10===t||11===t||12===t||13===t||14===t||16===t||17===t||18===t||19===t||t%10==5?"sekundi":t%10==1?"sekunda":t%10==2||t%10==3||t%10==4?"sekunde":"sekundi"},ms:function(t){return 1===t?"milisekunda":t%10==2||t%10==3||t%10==4?"milisekunde":"milisekundi"},decimal:","},hu:{y:function(){return"év"},mo:function(){return"hónap"},w:function(){return"hét"},d:function(){return"nap"},h:function(){return"óra"},m:function(){return"perc"},s:function(){return"másodperc"},ms:function(){return"ezredmásodperc"},decimal:","},id:{y:function(){return"tahun"},mo:function(){return"bulan"},w:function(){return"minggu"},d:function(){return"hari"},h:function(){return"jam"},m:function(){return"menit"},s:function(){return"detik"},ms:function(){return"milidetik"},decimal:"."},is:{y:function(){return"ár"},mo:function(t){return"mánuð"+(1===t?"ur":"ir")},w:function(t){return"vik"+(1===t?"a":"ur")},d:function(t){return"dag"+(1===t?"ur":"ar")},h:function(t){return"klukkutím"+(1===t?"i":"ar")},m:function(t){return"mínút"+(1===t?"a":"ur")},s:function(t){return"sekúnd"+(1===t?"a":"ur")},ms:function(t){return"millisekúnd"+(1===t?"a":"ur")},decimal:"."},it:{y:function(t){return"ann"+(1===t?"o":"i")},mo:function(t){return"mes"+(1===t?"e":"i")},w:function(t){return"settiman"+(1===t?"a":"e")},d:function(t){return"giorn"+(1===t?"o":"i")},h:function(t){return"or"+(1===t?"a":"e")},m:function(t){return"minut"+(1===t?"o":"i")},s:function(t){return"second"+(1===t?"o":"i")},ms:function(t){return"millisecond"+(1===t?"o":"i")},decimal:","},ja:{y:function(){return"年"},mo:function(){return"月"},w:function(){return"週"},d:function(){return"日"},h:function(){return"時間"},m:function(){return"分"},s:function(){return"秒"},ms:function(){return"ミリ秒"},decimal:"."},ko:{y:function(){return"년"},mo:function(){return"개월"},w:function(){return"주일"},d:function(){return"일"},h:function(){return"시간"},m:function(){return"분"},s:function(){return"초"},ms:function(){return"밀리 초"},decimal:"."},lo:{y:function(){return"ປີ"},mo:function(){return"ເດືອນ"},w:function(){return"ອາທິດ"},d:function(){return"ມື້"},h:function(){return"ຊົ່ວໂມງ"},m:function(){return"ນາທີ"},s:function(){return"ວິນາທີ"},ms:function(){return"ມິນລິວິນາທີ"},decimal:","},lt:{y:function(t){return t%10==0||t%100>=10&&t%100<=20?"metų":"metai"},mo:function(e){return["mėnuo","mėnesiai","mėnesių"][t.getLithuanianForm(e)]},w:function(e){return["savaitė","savaitės","savaičių"][t.getLithuanianForm(e)]},d:function(e){return["diena","dienos","dienų"][t.getLithuanianForm(e)]},h:function(e){return["valanda","valandos","valandų"][t.getLithuanianForm(e)]},m:function(e){return["minutė","minutės","minučių"][t.getLithuanianForm(e)]},s:function(e){return["sekundė","sekundės","sekundžių"][t.getLithuanianForm(e)]},ms:function(e){return["milisekundė","milisekundės","milisekundžių"][t.getLithuanianForm(e)]},decimal:","},lv:{y:function(e){return["gads","gadi"][t.getLatvianForm(e)]},mo:function(e){return["mēnesis","mēneši"][t.getLatvianForm(e)]},w:function(e){return["nedēļa","nedēļas"][t.getLatvianForm(e)]},d:function(e){return["diena","dienas"][t.getLatvianForm(e)]},h:function(e){return["stunda","stundas"][t.getLatvianForm(e)]},m:function(e){return["minūte","minūtes"][t.getLatvianForm(e)]},s:function(e){return["sekunde","sekundes"][t.getLatvianForm(e)]},ms:function(e){return["milisekunde","milisekundes"][t.getLatvianForm(e)]},decimal:","},ms:{y:function(){return"tahun"},mo:function(){return"bulan"},w:function(){return"minggu"},d:function(){return"hari"},h:function(){return"jam"},m:function(){return"minit"},s:function(){return"saat"},ms:function(){return"milisaat"},decimal:"."},nl:{y:function(){return"jaar"},mo:function(t){return 1===t?"maand":"maanden"},w:function(t){return 1===t?"week":"weken"},d:function(t){return 1===t?"dag":"dagen"},h:function(){return"uur"},m:function(t){return 1===t?"minuut":"minuten"},s:function(t){return 1===t?"seconde":"seconden"},ms:function(t){return 1===t?"milliseconde":"milliseconden"},decimal:","},no:{y:function(){return"år"},mo:function(t){return"måned"+(1===t?"":"er")},w:function(t){return"uke"+(1===t?"":"r")},d:function(t){return"dag"+(1===t?"":"er")},h:function(t){return"time"+(1===t?"":"r")},m:function(t){return"minutt"+(1===t?"":"er")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},pl:{y:function(e){return["rok","roku","lata","lat"][t.getPolishForm(e)]},mo:function(e){return["miesiąc","miesiąca","miesiące","miesięcy"][t.getPolishForm(e)]},w:function(e){return["tydzień","tygodnia","tygodnie","tygodni"][t.getPolishForm(e)]},d:function(e){return["dzień","dnia","dni","dni"][t.getPolishForm(e)]},h:function(e){return["godzina","godziny","godziny","godzin"][t.getPolishForm(e)]},m:function(e){return["minuta","minuty","minuty","minut"][t.getPolishForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekund"][t.getPolishForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekund"][t.getPolishForm(e)]},decimal:","},pt:{y:function(t){return"ano"+(1===t?"":"s")},mo:function(t){return 1===t?"mês":"meses"},w:function(t){return"semana"+(1===t?"":"s")},d:function(t){return"dia"+(1===t?"":"s")},h:function(t){return"hora"+(1===t?"":"s")},m:function(t){return"minuto"+(1===t?"":"s")},s:function(t){return"segundo"+(1===t?"":"s")},ms:function(t){return"milissegundo"+(1===t?"":"s")},decimal:","},ro:{y:function(t){return 1===t?"an":"ani"},mo:function(t){return 1===t?"lună":"luni"},w:function(t){return 1===t?"săptămână":"săptămâni"},d:function(t){return 1===t?"zi":"zile"},h:function(t){return 1===t?"oră":"ore"},m:function(t){return 1===t?"minut":"minute"},s:function(t){return 1===t?"secundă":"secunde"},ms:function(t){return 1===t?"milisecundă":"milisecunde"},decimal:","},ru:{y:function(e){return["лет","год","года"][t.getSlavicForm(e)]},mo:function(e){return["месяцев","месяц","месяца"][t.getSlavicForm(e)]},w:function(e){return["недель","неделя","недели"][t.getSlavicForm(e)]},d:function(e){return["дней","день","дня"][t.getSlavicForm(e)]},h:function(e){return["часов","час","часа"][t.getSlavicForm(e)]},m:function(e){return["минут","минута","минуты"][t.getSlavicForm(e)]},s:function(e){return["секунд","секунда","секунды"][t.getSlavicForm(e)]},ms:function(e){return["миллисекунд","миллисекунда","миллисекунды"][t.getSlavicForm(e)]},decimal:","},uk:{y:function(e){return["років","рік","роки"][t.getSlavicForm(e)]},mo:function(e){return["місяців","місяць","місяці"][t.getSlavicForm(e)]},w:function(e){return["тижнів","тиждень","тижні"][t.getSlavicForm(e)]},d:function(e){return["днів","день","дні"][t.getSlavicForm(e)]},h:function(e){return["годин","година","години"][t.getSlavicForm(e)]},m:function(e){return["хвилин","хвилина","хвилини"][t.getSlavicForm(e)]},s:function(e){return["секунд","секунда","секунди"][t.getSlavicForm(e)]},ms:function(e){return["мілісекунд","мілісекунда","мілісекунди"][t.getSlavicForm(e)]},decimal:","},ur:{y:function(){return"سال"},mo:function(t){return 1===t?"مہینہ":"مہینے"},w:function(t){return 1===t?"ہفتہ":"ہفتے"},d:function(){return"دن"},h:function(t){return 1===t?"گھنٹہ":"گھنٹے"},m:function(){return"منٹ"},s:function(){return"سیکنڈ"},ms:function(){return"ملی سیکنڈ"},decimal:"."},sk:{y:function(e){return["rok","roky","roky","rokov"][t.getCzechOrSlovakForm(e)]},mo:function(e){return["mesiac","mesiace","mesiace","mesiacov"][t.getCzechOrSlovakForm(e)]},w:function(e){return["týždeň","týždne","týždne","týždňov"][t.getCzechOrSlovakForm(e)]},d:function(e){return["deň","dni","dni","dní"][t.getCzechOrSlovakForm(e)]},h:function(e){return["hodina","hodiny","hodiny","hodín"][t.getCzechOrSlovakForm(e)]},m:function(e){return["minúta","minúty","minúty","minút"][t.getCzechOrSlovakForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekúnd"][t.getCzechOrSlovakForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekúnd"][t.getCzechOrSlovakForm(e)]},decimal:","},sv:{y:function(){return"år"},mo:function(t){return"månad"+(1===t?"":"er")},w:function(t){return"veck"+(1===t?"a":"or")},d:function(t){return"dag"+(1===t?"":"ar")},h:function(t){return"timm"+(1===t?"e":"ar")},m:function(t){return"minut"+(1===t?"":"er")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},tr:{y:function(){return"yıl"},mo:function(){return"ay"},w:function(){return"hafta"},d:function(){return"gün"},h:function(){return"saat"},m:function(){return"dakika"},s:function(){return"saniye"},ms:function(){return"milisaniye"},decimal:","},th:{y:function(){return"ปี"},mo:function(){return"เดือน"},w:function(){return"อาทิตย์"},d:function(){return"วัน"},h:function(){return"ชั่วโมง"},m:function(){return"นาที"},s:function(){return"วินาที"},ms:function(){return"มิลลิวินาที"},decimal:"."},vi:{y:function(){return"năm"},mo:function(){return"tháng"},w:function(){return"tuần"},d:function(){return"ngày"},h:function(){return"giờ"},m:function(){return"phút"},s:function(){return"giây"},ms:function(){return"mili giây"},decimal:","},zh_CN:{y:function(){return"年"},mo:function(){return"个月"},w:function(){return"周"},d:function(){return"天"},h:function(){return"小时"},m:function(){return"分钟"},s:function(){return"秒"},ms:function(){return"毫秒"},decimal:"."},zh_TW:{y:function(){return"年"},mo:function(){return"個月"},w:function(){return"周"},d:function(){return"天"},h:function(){return"小時"},m:function(){return"分鐘"},s:function(){return"秒"},ms:function(){return"毫秒"},decimal:"."}}}return t.prototype.addLanguage=function(t,e){this.languages[t]=e},t.prototype.getCzechForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&t%100<10?2:3},t.prototype.getPolishForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&!(t%100>10&&t%100<20)?2:3},t.prototype.getSlavicForm=function(t){return Math.floor(t)!==t?2:t>=5&&t<=20||t%10>=5&&t%10<=9||t%10==0?0:t%10==1?1:t>1?2:0},t.prototype.getLithuanianForm=function(t){return 1===t||t%10==1&&t%100>20?0:Math.floor(t)!==t||t%10>=2&&t%100>20||t%10>=2&&t%100<10?1:2},t.prototype.getArabicForm=function(t){return t<=2?0:t>2&&t<11?1:0},t.prototype.getCzechOrSlovakForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&t%100<10?2:3},t.prototype.getLatvianForm=function(t){return 1===t||t%10==1&&t%100!=11?0:1},t}(),Bt=function(){function t(t){this.languageUtil=t,this.defaultOptions={language:"en",delimiter:", ",spacer:" ",conjunction:"",serialComma:!0,units:["y","mo","w","d","h","m","s"],languages:{},largest:10,decimal:".",round:!1,unitMeasures:{y:315576e5,mo:26298e5,w:6048e5,d:864e5,h:36e5,m:6e4,s:1e3,ms:1}},this.options=void 0,this.options=this.defaultOptions}return t.prototype.humanize=function(t,e){var i=void 0!==e?this.extend(this.options,e):this.defaultOptions;return this.doHumanization(t,i)},t.prototype.setOptions=function(t){this.options=void 0!==t?this.extend(this.defaultOptions,t):this.defaultOptions},t.prototype.getSupportedLanguages=function(){var t=[];for(var e in this.languageUtil.languages)this.languageUtil.languages.hasOwnProperty(e)&&t.push(e);return t},t.prototype.addLanguage=function(t,e){this.languageUtil.addLanguage(t,e)},t.prototype.doHumanization=function(t,e){var i,n,o;t=Math.abs(t);var s=e.languages[e.language]||this.languageUtil.languages[e.language];if(!s)throw new Error("No language "+s+".");var r,a,l,c=[];for(i=0,n=e.units.length;i<n;i++)r=e.units[i],a=e.unitMeasures[r],l=i+1===n?t/a:Math.floor(t/a),c.push({unitCount:l,unitName:r}),t-=l*a;var h=0;for(i=0;i<c.length;i++)if(c[i].unitCount){h=i;break}if(e.round){var d=void 0,u=void 0;for(i=c.length-1;i>=0&&((o=c[i]).unitCount=Math.round(o.unitCount),0!==i);i--)u=c[i-1],d=e.unitMeasures[u.unitName]/e.unitMeasures[o.unitName],(o.unitCount%d==0||e.largest&&e.largest-1<i-h)&&(u.unitCount+=o.unitCount/d,o.unitCount=0)}var p=[];for(i=0,c.length;i<n&&((o=c[i]).unitCount&&p.push(this.render(o.unitCount,o.unitName,s,e)),p.length!==e.largest);i++);return p.length?e.conjunction&&1!==p.length?2===p.length?p.join(e.conjunction):p.length>2?p.slice(0,-1).join(e.delimiter)+(e.serialComma?",":"")+e.conjunction+p.slice(-1):void 0:p.join(e.delimiter):this.render(0,e.units[e.units.length-1],s,e)},t.prototype.render=function(t,e,i,n){var o;o=void 0===n.decimal?i.decimal:n.decimal;var s=t.toString().replace(".",o.toString()),r=i[e](t);return s+n.spacer+r},t.prototype.extend=function(t,e){for(var i in e)t.hasOwnProperty(i)&&(t[i]=e[i]);return t},t}();class qt extends Error{}class Ft extends qt{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}}class Zt extends qt{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}}class Ut extends qt{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}}class Vt extends qt{}class jt extends qt{constructor(t){super(`Invalid unit ${t}`)}}class Ht extends qt{}class Gt extends qt{constructor(){super("Zone is an abstract class")}}const Wt="numeric",Kt="short",Yt="long",Jt={year:Wt,month:Wt,day:Wt},Xt={year:Wt,month:Kt,day:Wt},Qt={year:Wt,month:Kt,day:Wt,weekday:Kt},te={year:Wt,month:Yt,day:Wt},ee={year:Wt,month:Yt,day:Wt,weekday:Yt},ie={hour:Wt,minute:Wt},ne={hour:Wt,minute:Wt,second:Wt},oe={hour:Wt,minute:Wt,second:Wt,timeZoneName:Kt},se={hour:Wt,minute:Wt,second:Wt,timeZoneName:Yt},re={hour:Wt,minute:Wt,hourCycle:"h23"},ae={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23"},le={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23",timeZoneName:Kt},ce={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23",timeZoneName:Yt},he={year:Wt,month:Wt,day:Wt,hour:Wt,minute:Wt},de={year:Wt,month:Wt,day:Wt,hour:Wt,minute:Wt,second:Wt},ue={year:Wt,month:Kt,day:Wt,hour:Wt,minute:Wt},pe={year:Wt,month:Kt,day:Wt,hour:Wt,minute:Wt,second:Wt},me={year:Wt,month:Kt,day:Wt,weekday:Kt,hour:Wt,minute:Wt},fe={year:Wt,month:Yt,day:Wt,hour:Wt,minute:Wt,timeZoneName:Kt},ge={year:Wt,month:Yt,day:Wt,hour:Wt,minute:Wt,second:Wt,timeZoneName:Kt},ve={year:Wt,month:Yt,day:Wt,weekday:Yt,hour:Wt,minute:Wt,timeZoneName:Yt},ye={year:Wt,month:Yt,day:Wt,weekday:Yt,hour:Wt,minute:Wt,second:Wt,timeZoneName:Yt};function be(t){return void 0===t}function _e(t){return"number"==typeof t}function xe(t){return"number"==typeof t&&t%1==0}function we(){try{return"undefined"!=typeof Intl&&!!Intl.RelativeTimeFormat}catch(t){return!1}}function ke(t,e,i){if(0!==t.length)return t.reduce(((t,n)=>{const o=[e(n),n];return t&&i(t[0],o[0])===t[0]?t:o}),null)[1]}function Se(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Ce(t,e,i){return xe(t)&&t>=e&&t<=i}function Ee(t,e=2){let i;return i=t<0?"-"+(""+-t).padStart(e,"0"):(""+t).padStart(e,"0"),i}function Te(t){return be(t)||null===t||""===t?void 0:parseInt(t,10)}function $e(t){return be(t)||null===t||""===t?void 0:parseFloat(t)}function Le(t){if(!be(t)&&null!==t&&""!==t){const e=1e3*parseFloat("0."+t);return Math.floor(e)}}function Oe(t,e,i=!1){const n=10**e;return(i?Math.trunc:Math.round)(t*n)/n}function Ae(t){return t%4==0&&(t%100!=0||t%400==0)}function Me(t){return Ae(t)?366:365}function Pe(t,e){const i=function(t,e){return t-e*Math.floor(t/e)}(e-1,12)+1;return 2===i?Ae(t+(e-i)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][i-1]}function ze(t){let e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(e.getUTCFullYear()-1900)),+e}function Ie(t){const e=(t+Math.floor(t/4)-Math.floor(t/100)+Math.floor(t/400))%7,i=t-1,n=(i+Math.floor(i/4)-Math.floor(i/100)+Math.floor(i/400))%7;return 4===e||3===n?53:52}function De(t){return t>99?t:t>60?1900+t:2e3+t}function Ne(t,e,i,n=null){const o=new Date(t),s={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};n&&(s.timeZone=n);const r={timeZoneName:e,...s},a=new Intl.DateTimeFormat(i,r).formatToParts(o).find((t=>"timezonename"===t.type.toLowerCase()));return a?a.value:null}function Re(t,e){let i=parseInt(t,10);Number.isNaN(i)&&(i=0);const n=parseInt(e,10)||0;return 60*i+(i<0||Object.is(i,-0)?-n:n)}function Be(t){const e=Number(t);if("boolean"==typeof t||""===t||Number.isNaN(e))throw new Ht(`Invalid unit value ${t}`);return e}function qe(t,e){const i={};for(const n in t)if(Se(t,n)){const o=t[n];if(null==o)continue;i[e(n)]=Be(o)}return i}function Fe(t,e){const i=Math.trunc(Math.abs(t/60)),n=Math.trunc(Math.abs(t%60)),o=t>=0?"+":"-";switch(e){case"short":return`${o}${Ee(i,2)}:${Ee(n,2)}`;case"narrow":return`${o}${i}${n>0?`:${n}`:""}`;case"techie":return`${o}${Ee(i,2)}${Ee(n,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function Ze(t){return function(t,e){return e.reduce(((e,i)=>(e[i]=t[i],e)),{})}(t,["hour","minute","second","millisecond"])}const Ue=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/,Ve=["January","February","March","April","May","June","July","August","September","October","November","December"],je=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],He=["J","F","M","A","M","J","J","A","S","O","N","D"];function Ge(t){switch(t){case"narrow":return[...He];case"short":return[...je];case"long":return[...Ve];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const We=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],Ke=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Ye=["M","T","W","T","F","S","S"];function Je(t){switch(t){case"narrow":return[...Ye];case"short":return[...Ke];case"long":return[...We];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const Xe=["AM","PM"],Qe=["Before Christ","Anno Domini"],ti=["BC","AD"],ei=["B","A"];function ii(t){switch(t){case"narrow":return[...ei];case"short":return[...ti];case"long":return[...Qe];default:return null}}function ni(t,e){let i="";for(const n of t)n.literal?i+=n.val:i+=e(n.val);return i}const oi={D:Jt,DD:Xt,DDD:te,DDDD:ee,t:ie,tt:ne,ttt:oe,tttt:se,T:re,TT:ae,TTT:le,TTTT:ce,f:he,ff:ue,fff:fe,ffff:ve,F:de,FF:pe,FFF:ge,FFFF:ye};class si{static create(t,e={}){return new si(t,e)}static parseFormat(t){let e=null,i="",n=!1;const o=[];for(let s=0;s<t.length;s++){const r=t.charAt(s);"'"===r?(i.length>0&&o.push({literal:n,val:i}),e=null,i="",n=!n):n||r===e?i+=r:(i.length>0&&o.push({literal:!1,val:i}),i=r,e=r)}return i.length>0&&o.push({literal:n,val:i}),o}static macroTokenToFormatOpts(t){return oi[t]}constructor(t,e){this.opts=e,this.loc=t,this.systemLoc=null}formatWithSystemDefault(t,e){null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem());return this.systemLoc.dtFormatter(t,{...this.opts,...e}).format()}formatDateTime(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).format()}formatDateTimeParts(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).formatToParts()}resolvedOptions(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).resolvedOptions()}num(t,e=0){if(this.opts.forceSimple)return Ee(t,e);const i={...this.opts};return e>0&&(i.padTo=e),this.loc.numberFormatter(i).format(t)}formatDateTimeFromString(t,e){const i="en"===this.loc.listingMode(),n=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,o=(e,i)=>this.loc.extract(t,e,i),s=e=>t.isOffsetFixed&&0===t.offset&&e.allowZ?"Z":t.isValid?t.zone.formatOffset(t.ts,e.format):"",r=()=>i?function(t){return Xe[t.hour<12?0:1]}(t):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),a=(e,n)=>i?function(t,e){return Ge(e)[t.month-1]}(t,e):o(n?{month:e}:{month:e,day:"numeric"},"month"),l=(e,n)=>i?function(t,e){return Je(e)[t.weekday-1]}(t,e):o(n?{weekday:e}:{weekday:e,month:"long",day:"numeric"},"weekday"),c=e=>{const i=si.macroTokenToFormatOpts(e);return i?this.formatWithSystemDefault(t,i):e},h=e=>i?function(t,e){return ii(e)[t.year<0?0:1]}(t,e):o({era:e},"era");return ni(si.parseFormat(e),(e=>{switch(e){case"S":return this.num(t.millisecond);case"u":case"SSS":return this.num(t.millisecond,3);case"s":return this.num(t.second);case"ss":return this.num(t.second,2);case"uu":return this.num(Math.floor(t.millisecond/10),2);case"uuu":return this.num(Math.floor(t.millisecond/100));case"m":return this.num(t.minute);case"mm":return this.num(t.minute,2);case"h":return this.num(t.hour%12==0?12:t.hour%12);case"hh":return this.num(t.hour%12==0?12:t.hour%12,2);case"H":return this.num(t.hour);case"HH":return this.num(t.hour,2);case"Z":return s({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return s({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return s({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return t.zone.offsetName(t.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return t.zone.offsetName(t.ts,{format:"long",locale:this.loc.locale});case"z":return t.zoneName;case"a":return r();case"d":return n?o({day:"numeric"},"day"):this.num(t.day);case"dd":return n?o({day:"2-digit"},"day"):this.num(t.day,2);case"c":case"E":return this.num(t.weekday);case"ccc":return l("short",!0);case"cccc":return l("long",!0);case"ccccc":return l("narrow",!0);case"EEE":return l("short",!1);case"EEEE":return l("long",!1);case"EEEEE":return l("narrow",!1);case"L":return n?o({month:"numeric",day:"numeric"},"month"):this.num(t.month);case"LL":return n?o({month:"2-digit",day:"numeric"},"month"):this.num(t.month,2);case"LLL":return a("short",!0);case"LLLL":return a("long",!0);case"LLLLL":return a("narrow",!0);case"M":return n?o({month:"numeric"},"month"):this.num(t.month);case"MM":return n?o({month:"2-digit"},"month"):this.num(t.month,2);case"MMM":return a("short",!1);case"MMMM":return a("long",!1);case"MMMMM":return a("narrow",!1);case"y":return n?o({year:"numeric"},"year"):this.num(t.year);case"yy":return n?o({year:"2-digit"},"year"):this.num(t.year.toString().slice(-2),2);case"yyyy":return n?o({year:"numeric"},"year"):this.num(t.year,4);case"yyyyyy":return n?o({year:"numeric"},"year"):this.num(t.year,6);case"G":return h("short");case"GG":return h("long");case"GGGGG":return h("narrow");case"kk":return this.num(t.weekYear.toString().slice(-2),2);case"kkkk":return this.num(t.weekYear,4);case"W":return this.num(t.weekNumber);case"WW":return this.num(t.weekNumber,2);case"o":return this.num(t.ordinal);case"ooo":return this.num(t.ordinal,3);case"q":return this.num(t.quarter);case"qq":return this.num(t.quarter,2);case"X":return this.num(Math.floor(t.ts/1e3));case"x":return this.num(t.ts);default:return c(e)}}))}formatDurationFromString(t,e){const i=t=>{switch(t[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},n=si.parseFormat(e),o=n.reduce(((t,{literal:e,val:i})=>e?t:t.concat(i)),[]),s=t.shiftTo(...o.map(i).filter((t=>t)));return ni(n,(t=>e=>{const n=i(e);return n?this.num(t.get(n),e.length):e})(s))}}class ri{constructor(t,e){this.reason=t,this.explanation=e}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}class ai{get type(){throw new Gt}get name(){throw new Gt}get ianaName(){return this.name}get isUniversal(){throw new Gt}offsetName(t,e){throw new Gt}formatOffset(t,e){throw new Gt}offset(t){throw new Gt}equals(t){throw new Gt}get isValid(){throw new Gt}}let li=null;class ci extends ai{static get instance(){return null===li&&(li=new ci),li}get type(){return"system"}get name(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(t,{format:e,locale:i}){return Ne(t,e,i)}formatOffset(t,e){return Fe(this.offset(t),e)}offset(t){return-new Date(t).getTimezoneOffset()}equals(t){return"system"===t.type}get isValid(){return!0}}let hi={};const di={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};let ui={};class pi extends ai{static create(t){return ui[t]||(ui[t]=new pi(t)),ui[t]}static resetCache(){ui={},hi={}}static isValidSpecifier(t){return this.isValidZone(t)}static isValidZone(t){if(!t)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:t}).format(),!0}catch(t){return!1}}constructor(t){super(),this.zoneName=t,this.valid=pi.isValidZone(t)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(t,{format:e,locale:i}){return Ne(t,e,i,this.name)}formatOffset(t,e){return Fe(this.offset(t),e)}offset(t){const e=new Date(t);if(isNaN(e))return NaN;const i=(n=this.name,hi[n]||(hi[n]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:n,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),hi[n]);var n;let[o,s,r,a,l,c,h]=i.formatToParts?function(t,e){const i=t.formatToParts(e),n=[];for(let t=0;t<i.length;t++){const{type:e,value:o}=i[t],s=di[e];"era"===e?n[s]=o:be(s)||(n[s]=parseInt(o,10))}return n}(i,e):function(t,e){const i=t.format(e).replace(/\u200E/g,""),n=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(i),[,o,s,r,a,l,c,h]=n;return[r,o,s,a,l,c,h]}(i,e);"BC"===a&&(o=1-Math.abs(o));let d=+e;const u=d%1e3;return d-=u>=0?u:1e3+u,(ze({year:o,month:s,day:r,hour:24===l?0:l,minute:c,second:h,millisecond:0})-d)/6e4}equals(t){return"iana"===t.type&&t.name===this.name}get isValid(){return this.valid}}let mi=null;class fi extends ai{static get utcInstance(){return null===mi&&(mi=new fi(0)),mi}static instance(t){return 0===t?fi.utcInstance:new fi(t)}static parseSpecifier(t){if(t){const e=t.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(e)return new fi(Re(e[1],e[2]))}return null}constructor(t){super(),this.fixed=t}get type(){return"fixed"}get name(){return 0===this.fixed?"UTC":`UTC${Fe(this.fixed,"narrow")}`}get ianaName(){return 0===this.fixed?"Etc/UTC":`Etc/GMT${Fe(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(t,e){return Fe(this.fixed,e)}get isUniversal(){return!0}offset(){return this.fixed}equals(t){return"fixed"===t.type&&t.fixed===this.fixed}get isValid(){return!0}}class gi extends ai{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function vi(t,e){if(be(t)||null===t)return e;if(t instanceof ai)return t;if(function(t){return"string"==typeof t}(t)){const i=t.toLowerCase();return"local"===i||"system"===i?e:"utc"===i||"gmt"===i?fi.utcInstance:fi.parseSpecifier(i)||pi.create(t)}return _e(t)?fi.instance(t):"object"==typeof t&&t.offset&&"number"==typeof t.offset?t:new gi(t)}let yi,bi=()=>Date.now(),_i="system",xi=null,wi=null,ki=null;class Si{static get now(){return bi}static set now(t){bi=t}static set defaultZone(t){_i=t}static get defaultZone(){return vi(_i,ci.instance)}static get defaultLocale(){return xi}static set defaultLocale(t){xi=t}static get defaultNumberingSystem(){return wi}static set defaultNumberingSystem(t){wi=t}static get defaultOutputCalendar(){return ki}static set defaultOutputCalendar(t){ki=t}static get throwOnInvalid(){return yi}static set throwOnInvalid(t){yi=t}static resetCaches(){Ii.resetCache(),pi.resetCache()}}let Ci={};let Ei={};function Ti(t,e={}){const i=JSON.stringify([t,e]);let n=Ei[i];return n||(n=new Intl.DateTimeFormat(t,e),Ei[i]=n),n}let $i={};let Li={};let Oi=null;function Ai(t,e,i,n,o){const s=t.listingMode(i);return"error"===s?null:"en"===s?n(e):o(e)}class Mi{constructor(t,e,i){this.padTo=i.padTo||0,this.floor=i.floor||!1;const{padTo:n,floor:o,...s}=i;if(!e||Object.keys(s).length>0){const e={useGrouping:!1,...i};i.padTo>0&&(e.minimumIntegerDigits=i.padTo),this.inf=function(t,e={}){const i=JSON.stringify([t,e]);let n=$i[i];return n||(n=new Intl.NumberFormat(t,e),$i[i]=n),n}(t,e)}}format(t){if(this.inf){const e=this.floor?Math.floor(t):t;return this.inf.format(e)}return Ee(this.floor?Math.floor(t):Oe(t,3),this.padTo)}}class Pi{constructor(t,e,i){let n;if(this.opts=i,t.zone.isUniversal){const e=t.offset/60*-1,o=e>=0?`Etc/GMT+${e}`:`Etc/GMT${e}`;0!==t.offset&&pi.create(o).valid?(n=o,this.dt=t):(n="UTC",i.timeZoneName?this.dt=t:this.dt=0===t.offset?t:Po.fromMillis(t.ts+60*t.offset*1e3))}else"system"===t.zone.type?this.dt=t:(this.dt=t,n=t.zone.name);const o={...this.opts};n&&(o.timeZone=n),this.dtf=Ti(e,o)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class zi{constructor(t,e,i){this.opts={style:"long",...i},!e&&we()&&(this.rtf=function(t,e={}){const{base:i,...n}=e,o=JSON.stringify([t,n]);let s=Li[o];return s||(s=new Intl.RelativeTimeFormat(t,e),Li[o]=s),s}(t,i))}format(t,e){return this.rtf?this.rtf.format(t,e):function(t,e,i="always",n=!1){const o={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},s=-1===["hours","minutes","seconds"].indexOf(t);if("auto"===i&&s){const i="days"===t;switch(e){case 1:return i?"tomorrow":`next ${o[t][0]}`;case-1:return i?"yesterday":`last ${o[t][0]}`;case 0:return i?"today":`this ${o[t][0]}`}}const r=Object.is(e,-0)||e<0,a=Math.abs(e),l=1===a,c=o[t],h=n?l?c[1]:c[2]||c[1]:l?o[t][0]:t;return r?`${a} ${h} ago`:`in ${a} ${h}`}(e,t,this.opts.numeric,"long"!==this.opts.style)}formatToParts(t,e){return this.rtf?this.rtf.formatToParts(t,e):[]}}class Ii{static fromOpts(t){return Ii.create(t.locale,t.numberingSystem,t.outputCalendar,t.defaultToEN)}static create(t,e,i,n=!1){const o=t||Si.defaultLocale,s=o||(n?"en-US":Oi||(Oi=(new Intl.DateTimeFormat).resolvedOptions().locale,Oi)),r=e||Si.defaultNumberingSystem,a=i||Si.defaultOutputCalendar;return new Ii(s,r,a,o)}static resetCache(){Oi=null,Ei={},$i={},Li={}}static fromObject({locale:t,numberingSystem:e,outputCalendar:i}={}){return Ii.create(t,e,i)}constructor(t,e,i,n){const[o,s,r]=function(t){const e=t.indexOf("-u-");if(-1===e)return[t];{let i;const n=t.substring(0,e);try{i=Ti(t).resolvedOptions()}catch(t){i=Ti(n).resolvedOptions()}const{numberingSystem:o,calendar:s}=i;return[n,o,s]}}(t);this.locale=o,this.numberingSystem=e||s||null,this.outputCalendar=i||r||null,this.intl=function(t,e,i){return i||e?(t+="-u",i&&(t+=`-ca-${i}`),e&&(t+=`-nu-${e}`),t):t}(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=n,this.fastNumbersCached=null}get fastNumbers(){var t;return null==this.fastNumbersCached&&(this.fastNumbersCached=(!(t=this).numberingSystem||"latn"===t.numberingSystem)&&("latn"===t.numberingSystem||!t.locale||t.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(t.intl).resolvedOptions().numberingSystem)),this.fastNumbersCached}listingMode(){const t=this.isEnglish(),e=!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar);return t&&e?"en":"intl"}clone(t){return t&&0!==Object.getOwnPropertyNames(t).length?Ii.create(t.locale||this.specifiedLocale,t.numberingSystem||this.numberingSystem,t.outputCalendar||this.outputCalendar,t.defaultToEN||!1):this}redefaultToEN(t={}){return this.clone({...t,defaultToEN:!0})}redefaultToSystem(t={}){return this.clone({...t,defaultToEN:!1})}months(t,e=!1,i=!0){return Ai(this,t,i,Ge,(()=>{const i=e?{month:t,day:"numeric"}:{month:t},n=e?"format":"standalone";return this.monthsCache[n][t]||(this.monthsCache[n][t]=function(t){const e=[];for(let i=1;i<=12;i++){const n=Po.utc(2016,i,1);e.push(t(n))}return e}((t=>this.extract(t,i,"month")))),this.monthsCache[n][t]}))}weekdays(t,e=!1,i=!0){return Ai(this,t,i,Je,(()=>{const i=e?{weekday:t,year:"numeric",month:"long",day:"numeric"}:{weekday:t},n=e?"format":"standalone";return this.weekdaysCache[n][t]||(this.weekdaysCache[n][t]=function(t){const e=[];for(let i=1;i<=7;i++){const n=Po.utc(2016,11,13+i);e.push(t(n))}return e}((t=>this.extract(t,i,"weekday")))),this.weekdaysCache[n][t]}))}meridiems(t=!0){return Ai(this,void 0,t,(()=>Xe),(()=>{if(!this.meridiemCache){const t={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Po.utc(2016,11,13,9),Po.utc(2016,11,13,19)].map((e=>this.extract(e,t,"dayperiod")))}return this.meridiemCache}))}eras(t,e=!0){return Ai(this,t,e,ii,(()=>{const e={era:t};return this.eraCache[t]||(this.eraCache[t]=[Po.utc(-40,1,1),Po.utc(2017,1,1)].map((t=>this.extract(t,e,"era")))),this.eraCache[t]}))}extract(t,e,i){const n=this.dtFormatter(t,e).formatToParts().find((t=>t.type.toLowerCase()===i));return n?n.value:null}numberFormatter(t={}){return new Mi(this.intl,t.forceSimple||this.fastNumbers,t)}dtFormatter(t,e={}){return new Pi(t,this.intl,e)}relFormatter(t={}){return new zi(this.intl,this.isEnglish(),t)}listFormatter(t={}){return function(t,e={}){const i=JSON.stringify([t,e]);let n=Ci[i];return n||(n=new Intl.ListFormat(t,e),Ci[i]=n),n}(this.intl,t)}isEnglish(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(t){return this.locale===t.locale&&this.numberingSystem===t.numberingSystem&&this.outputCalendar===t.outputCalendar}}function Di(...t){const e=t.reduce(((t,e)=>t+e.source),"");return RegExp(`^${e}$`)}function Ni(...t){return e=>t.reduce((([t,i,n],o)=>{const[s,r,a]=o(e,n);return[{...t,...s},r||i,a]}),[{},null,1]).slice(0,2)}function Ri(t,...e){if(null==t)return[null,null];for(const[i,n]of e){const e=i.exec(t);if(e)return n(e)}return[null,null]}function Bi(...t){return(e,i)=>{const n={};let o;for(o=0;o<t.length;o++)n[t[o]]=Te(e[i+o]);return[n,null,i+o]}}const qi=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,Fi=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Zi=RegExp(`${Fi.source}${`(?:${qi.source}?(?:\\[(${Ue.source})\\])?)?`}`),Ui=RegExp(`(?:T${Zi.source})?`),Vi=Bi("weekYear","weekNumber","weekDay"),ji=Bi("year","ordinal"),Hi=RegExp(`${Fi.source} ?(?:${qi.source}|(${Ue.source}))?`),Gi=RegExp(`(?: ${Hi.source})?`);function Wi(t,e,i){const n=t[e];return be(n)?i:Te(n)}function Ki(t,e){return[{hours:Wi(t,e,0),minutes:Wi(t,e+1,0),seconds:Wi(t,e+2,0),milliseconds:Le(t[e+3])},null,e+4]}function Yi(t,e){const i=!t[e]&&!t[e+1],n=Re(t[e+1],t[e+2]);return[{},i?null:fi.instance(n),e+3]}function Ji(t,e){return[{},t[e]?pi.create(t[e]):null,e+1]}const Xi=RegExp(`^T?${Fi.source}$`),Qi=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function tn(t){const[e,i,n,o,s,r,a,l,c]=t,h="-"===e[0],d=l&&"-"===l[0],u=(t,e=!1)=>void 0!==t&&(e||t&&h)?-t:t;return[{years:u($e(i)),months:u($e(n)),weeks:u($e(o)),days:u($e(s)),hours:u($e(r)),minutes:u($e(a)),seconds:u($e(l),"-0"===l),milliseconds:u(Le(c),d)}]}const en={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function nn(t,e,i,n,o,s,r){const a={year:2===e.length?De(Te(e)):Te(e),month:je.indexOf(i)+1,day:Te(n),hour:Te(o),minute:Te(s)};return r&&(a.second=Te(r)),t&&(a.weekday=t.length>3?We.indexOf(t)+1:Ke.indexOf(t)+1),a}const on=/^(?:(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\d)(\d\d)))$/;function sn(t){const[,e,i,n,o,s,r,a,l,c,h,d]=t,u=nn(e,o,n,i,s,r,a);let p;return p=l?en[l]:c?0:Re(h,d),[u,new fi(p)]}const rn=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,an=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,ln=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function cn(t){const[,e,i,n,o,s,r,a]=t;return[nn(e,o,n,i,s,r,a),fi.utcInstance]}function hn(t){const[,e,i,n,o,s,r,a]=t;return[nn(e,a,i,n,o,s,r),fi.utcInstance]}const dn=Di(/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ui),un=Di(/(\d{4})-?W(\d\d)(?:-?(\d))?/,Ui),pn=Di(/(\d{4})-?(\d{3})/,Ui),mn=Di(Zi),fn=Ni((function(t,e){return[{year:Wi(t,e),month:Wi(t,e+1,1),day:Wi(t,e+2,1)},null,e+3]}),Ki,Yi,Ji),gn=Ni(Vi,Ki,Yi,Ji),vn=Ni(ji,Ki,Yi,Ji),yn=Ni(Ki,Yi,Ji);const bn=Ni(Ki);const _n=Di(/(\d{4})-(\d\d)-(\d\d)/,Gi),xn=Di(Hi),wn=Ni(Ki,Yi,Ji);const kn={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},Sn={years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6},...kn},Cn={years:{quarters:4,months:12,weeks:52.1775,days:365.2425,hours:8765.82,minutes:525949.2,seconds:525949.2*60,milliseconds:525949.2*60*1e3},quarters:{months:3,weeks:13.044375,days:91.310625,hours:2191.455,minutes:131487.3,seconds:525949.2*60/4,milliseconds:7889237999.999999},months:{weeks:30.436875/7,days:30.436875,hours:730.485,minutes:43829.1,seconds:2629746,milliseconds:2629746e3},...kn},En=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Tn=En.slice(0).reverse();function $n(t,e,i=!1){const n={values:i?e.values:{...t.values,...e.values||{}},loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy};return new On(n)}function Ln(t,e,i,n,o){const s=t[o][i],r=e[i]/s,a=!(Math.sign(r)===Math.sign(n[o]))&&0!==n[o]&&Math.abs(r)<=1?function(t){return t<0?Math.floor(t):Math.ceil(t)}(r):Math.trunc(r);n[o]+=a,e[i]-=a*s}class On{constructor(t){const e="longterm"===t.conversionAccuracy||!1;this.values=t.values,this.loc=t.loc||Ii.create(),this.conversionAccuracy=e?"longterm":"casual",this.invalid=t.invalid||null,this.matrix=e?Cn:Sn,this.isLuxonDuration=!0}static fromMillis(t,e){return On.fromObject({milliseconds:t},e)}static fromObject(t,e={}){if(null==t||"object"!=typeof t)throw new Ht("Duration.fromObject: argument expected to be an object, got "+(null===t?"null":typeof t));return new On({values:qe(t,On.normalizeUnit),loc:Ii.fromObject(e),conversionAccuracy:e.conversionAccuracy})}static fromDurationLike(t){if(_e(t))return On.fromMillis(t);if(On.isDuration(t))return t;if("object"==typeof t)return On.fromObject(t);throw new Ht(`Unknown duration argument ${t} of type ${typeof t}`)}static fromISO(t,e){const[i]=function(t){return Ri(t,[Qi,tn])}(t);return i?On.fromObject(i,e):On.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static fromISOTime(t,e){const[i]=function(t){return Ri(t,[Xi,bn])}(t);return i?On.fromObject(i,e):On.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the Duration is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Ut(i);return new On({invalid:i})}static normalizeUnit(t){const e={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[t?t.toLowerCase():t];if(!e)throw new jt(t);return e}static isDuration(t){return t&&t.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(t,e={}){const i={...e,floor:!1!==e.round&&!1!==e.floor};return this.isValid?si.create(this.loc,i).formatDurationFromString(this,t):"Invalid Duration"}toHuman(t={}){const e=En.map((e=>{const i=this.values[e];return be(i)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...t,unit:e.slice(0,-1)}).format(i)})).filter((t=>t));return this.loc.listFormatter({type:"conjunction",style:t.listStyle||"narrow",...t}).format(e)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let t="P";return 0!==this.years&&(t+=this.years+"Y"),0===this.months&&0===this.quarters||(t+=this.months+3*this.quarters+"M"),0!==this.weeks&&(t+=this.weeks+"W"),0!==this.days&&(t+=this.days+"D"),0===this.hours&&0===this.minutes&&0===this.seconds&&0===this.milliseconds||(t+="T"),0!==this.hours&&(t+=this.hours+"H"),0!==this.minutes&&(t+=this.minutes+"M"),0===this.seconds&&0===this.milliseconds||(t+=Oe(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===t&&(t+="T0S"),t}toISOTime(t={}){if(!this.isValid)return null;const e=this.toMillis();if(e<0||e>=864e5)return null;t={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...t};const i=this.shiftTo("hours","minutes","seconds","milliseconds");let n="basic"===t.format?"hhmm":"hh:mm";t.suppressSeconds&&0===i.seconds&&0===i.milliseconds||(n+="basic"===t.format?"ss":":ss",t.suppressMilliseconds&&0===i.milliseconds||(n+=".SSS"));let o=i.toFormat(n);return t.includePrefix&&(o="T"+o),o}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(t){if(!this.isValid)return this;const e=On.fromDurationLike(t),i={};for(const t of En)(Se(e.values,t)||Se(this.values,t))&&(i[t]=e.get(t)+this.get(t));return $n(this,{values:i},!0)}minus(t){if(!this.isValid)return this;const e=On.fromDurationLike(t);return this.plus(e.negate())}mapUnits(t){if(!this.isValid)return this;const e={};for(const i of Object.keys(this.values))e[i]=Be(t(this.values[i],i));return $n(this,{values:e},!0)}get(t){return this[On.normalizeUnit(t)]}set(t){if(!this.isValid)return this;return $n(this,{values:{...this.values,...qe(t,On.normalizeUnit)}})}reconfigure({locale:t,numberingSystem:e,conversionAccuracy:i}={}){const n={loc:this.loc.clone({locale:t,numberingSystem:e})};return i&&(n.conversionAccuracy=i),$n(this,n)}as(t){return this.isValid?this.shiftTo(t).get(t):NaN}normalize(){if(!this.isValid)return this;const t=this.toObject();return function(t,e){Tn.reduce(((i,n)=>be(e[n])?i:(i&&Ln(t,e,i,e,n),n)),null)}(this.matrix,t),$n(this,{values:t},!0)}shiftTo(...t){if(!this.isValid)return this;if(0===t.length)return this;t=t.map((t=>On.normalizeUnit(t)));const e={},i={},n=this.toObject();let o;for(const s of En)if(t.indexOf(s)>=0){o=s;let t=0;for(const e in i)t+=this.matrix[e][s]*i[e],i[e]=0;_e(n[s])&&(t+=n[s]);const r=Math.trunc(t);e[s]=r,i[s]=(1e3*t-1e3*r)/1e3;for(const t in n)En.indexOf(t)>En.indexOf(s)&&Ln(this.matrix,n,t,e,s)}else _e(n[s])&&(i[s]=n[s]);for(const t in i)0!==i[t]&&(e[o]+=t===o?i[t]:i[t]/this.matrix[o][t]);return $n(this,{values:e},!0).normalize()}negate(){if(!this.isValid)return this;const t={};for(const e of Object.keys(this.values))t[e]=0===this.values[e]?0:-this.values[e];return $n(this,{values:t},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(t){if(!this.isValid||!t.isValid)return!1;if(!this.loc.equals(t.loc))return!1;for(const n of En)if(e=this.values[n],i=t.values[n],!(void 0===e||0===e?void 0===i||0===i:e===i))return!1;var e,i;return!0}}const An="Invalid Interval";class Mn{constructor(t){this.s=t.start,this.e=t.end,this.invalid=t.invalid||null,this.isLuxonInterval=!0}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the Interval is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Zt(i);return new Mn({invalid:i})}static fromDateTimes(t,e){const i=zo(t),n=zo(e),o=function(t,e){return t&&t.isValid?e&&e.isValid?e<t?Mn.invalid("end before start",`The end of an interval must be after its start, but you had start=${t.toISO()} and end=${e.toISO()}`):null:Mn.invalid("missing or invalid end"):Mn.invalid("missing or invalid start")}(i,n);return null==o?new Mn({start:i,end:n}):o}static after(t,e){const i=On.fromDurationLike(e),n=zo(t);return Mn.fromDateTimes(n,n.plus(i))}static before(t,e){const i=On.fromDurationLike(e),n=zo(t);return Mn.fromDateTimes(n.minus(i),n)}static fromISO(t,e){const[i,n]=(t||"").split("/",2);if(i&&n){let t,o,s,r;try{t=Po.fromISO(i,e),o=t.isValid}catch(n){o=!1}try{s=Po.fromISO(n,e),r=s.isValid}catch(n){r=!1}if(o&&r)return Mn.fromDateTimes(t,s);if(o){const i=On.fromISO(n,e);if(i.isValid)return Mn.after(t,i)}else if(r){const t=On.fromISO(i,e);if(t.isValid)return Mn.before(s,t)}}return Mn.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static isInterval(t){return t&&t.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return null===this.invalidReason}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(t="milliseconds"){return this.isValid?this.toDuration(t).get(t):NaN}count(t="milliseconds"){if(!this.isValid)return NaN;const e=this.start.startOf(t),i=this.end.startOf(t);return Math.floor(i.diff(e,t).get(t))+1}hasSame(t){return!!this.isValid&&(this.isEmpty()||this.e.minus(1).hasSame(this.s,t))}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(t){return!!this.isValid&&this.s>t}isBefore(t){return!!this.isValid&&this.e<=t}contains(t){return!!this.isValid&&(this.s<=t&&this.e>t)}set({start:t,end:e}={}){return this.isValid?Mn.fromDateTimes(t||this.s,e||this.e):this}splitAt(...t){if(!this.isValid)return[];const e=t.map(zo).filter((t=>this.contains(t))).sort(),i=[];let{s:n}=this,o=0;for(;n<this.e;){const t=e[o]||this.e,s=+t>+this.e?this.e:t;i.push(Mn.fromDateTimes(n,s)),n=s,o+=1}return i}splitBy(t){const e=On.fromDurationLike(t);if(!this.isValid||!e.isValid||0===e.as("milliseconds"))return[];let i,{s:n}=this,o=1;const s=[];for(;n<this.e;){const t=this.start.plus(e.mapUnits((t=>t*o)));i=+t>+this.e?this.e:t,s.push(Mn.fromDateTimes(n,i)),n=i,o+=1}return s}divideEqually(t){return this.isValid?this.splitBy(this.length()/t).slice(0,t):[]}overlaps(t){return this.e>t.s&&this.s<t.e}abutsStart(t){return!!this.isValid&&+this.e==+t.s}abutsEnd(t){return!!this.isValid&&+t.e==+this.s}engulfs(t){return!!this.isValid&&(this.s<=t.s&&this.e>=t.e)}equals(t){return!(!this.isValid||!t.isValid)&&(this.s.equals(t.s)&&this.e.equals(t.e))}intersection(t){if(!this.isValid)return this;const e=this.s>t.s?this.s:t.s,i=this.e<t.e?this.e:t.e;return e>=i?null:Mn.fromDateTimes(e,i)}union(t){if(!this.isValid)return this;const e=this.s<t.s?this.s:t.s,i=this.e>t.e?this.e:t.e;return Mn.fromDateTimes(e,i)}static merge(t){const[e,i]=t.sort(((t,e)=>t.s-e.s)).reduce((([t,e],i)=>e?e.overlaps(i)||e.abutsStart(i)?[t,e.union(i)]:[t.concat([e]),i]:[t,i]),[[],null]);return i&&e.push(i),e}static xor(t){let e=null,i=0;const n=[],o=t.map((t=>[{time:t.s,type:"s"},{time:t.e,type:"e"}])),s=Array.prototype.concat(...o).sort(((t,e)=>t.time-e.time));for(const t of s)i+="s"===t.type?1:-1,1===i?e=t.time:(e&&+e!=+t.time&&n.push(Mn.fromDateTimes(e,t.time)),e=null);return Mn.merge(n)}difference(...t){return Mn.xor([this].concat(t)).map((t=>this.intersection(t))).filter((t=>t&&!t.isEmpty()))}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:An}toISO(t){return this.isValid?`${this.s.toISO(t)}/${this.e.toISO(t)}`:An}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:An}toISOTime(t){return this.isValid?`${this.s.toISOTime(t)}/${this.e.toISOTime(t)}`:An}toFormat(t,{separator:e=" – "}={}){return this.isValid?`${this.s.toFormat(t)}${e}${this.e.toFormat(t)}`:An}toDuration(t,e){return this.isValid?this.e.diff(this.s,t,e):On.invalid(this.invalidReason)}mapEndpoints(t){return Mn.fromDateTimes(t(this.s),t(this.e))}}class Pn{static hasDST(t=Si.defaultZone){const e=Po.now().setZone(t).set({month:12});return!t.isUniversal&&e.offset!==e.set({month:6}).offset}static isValidIANAZone(t){return pi.isValidZone(t)}static normalizeZone(t){return vi(t,Si.defaultZone)}static months(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null,outputCalendar:o="gregory"}={}){return(n||Ii.create(e,i,o)).months(t)}static monthsFormat(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null,outputCalendar:o="gregory"}={}){return(n||Ii.create(e,i,o)).months(t,!0)}static weekdays(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null}={}){return(n||Ii.create(e,i,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null}={}){return(n||Ii.create(e,i,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Ii.create(t).meridiems()}static eras(t="short",{locale:e=null}={}){return Ii.create(e,null,"gregory").eras(t)}static features(){return{relative:we()}}}function zn(t,e){const i=t=>t.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),n=i(e)-i(t);return Math.floor(On.fromMillis(n).as("days"))}function In(t,e,i,n){let[o,s,r,a]=function(t,e,i){const n=[["years",(t,e)=>e.year-t.year],["quarters",(t,e)=>e.quarter-t.quarter],["months",(t,e)=>e.month-t.month+12*(e.year-t.year)],["weeks",(t,e)=>{const i=zn(t,e);return(i-i%7)/7}],["days",zn]],o={};let s,r;for(const[a,l]of n)if(i.indexOf(a)>=0){s=a;let i=l(t,e);r=t.plus({[a]:i}),r>e?(t=t.plus({[a]:i-1}),i-=1):t=r,o[a]=i}return[t,o,r,s]}(t,e,i);const l=e-o,c=i.filter((t=>["hours","minutes","seconds","milliseconds"].indexOf(t)>=0));0===c.length&&(r<e&&(r=o.plus({[a]:1})),r!==o&&(s[a]=(s[a]||0)+l/(r-o)));const h=On.fromObject(s,n);return c.length>0?On.fromMillis(l,n).shiftTo(...c).plus(h):h}const Dn={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},Nn={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},Rn=Dn.hanidec.replace(/[\[|\]]/g,"").split("");function Bn({numberingSystem:t},e=""){return new RegExp(`${Dn[t||"latn"]}${e}`)}function qn(t,e=(t=>t)){return{regex:t,deser:([t])=>e(function(t){let e=parseInt(t,10);if(isNaN(e)){e="";for(let i=0;i<t.length;i++){const n=t.charCodeAt(i);if(-1!==t[i].search(Dn.hanidec))e+=Rn.indexOf(t[i]);else for(const t in Nn){const[i,o]=Nn[t];n>=i&&n<=o&&(e+=n-i)}}return parseInt(e,10)}return e}(t))}}const Fn=`[ ${String.fromCharCode(160)}]`,Zn=new RegExp(Fn,"g");function Un(t){return t.replace(/\./g,"\\.?").replace(Zn,Fn)}function Vn(t){return t.replace(/\./g,"").replace(Zn," ").toLowerCase()}function jn(t,e){return null===t?null:{regex:RegExp(t.map(Un).join("|")),deser:([i])=>t.findIndex((t=>Vn(i)===Vn(t)))+e}}function Hn(t,e){return{regex:t,deser:([,t,e])=>Re(t,e),groups:e}}function Gn(t){return{regex:t,deser:([t])=>t}}const Wn={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"}};let Kn=null;function Yn(t,e){if(t.literal)return t;const i=si.macroTokenToFormatOpts(t.val);if(!i)return t;const n=si.create(e,i).formatDateTimeParts((Kn||(Kn=Po.fromMillis(1555555555555)),Kn)).map((t=>function(t,e,i){const{type:n,value:o}=t;if("literal"===n)return{literal:!0,val:o};const s=i[n];let r=Wn[n];return"object"==typeof r&&(r=r[s]),r?{literal:!1,val:r}:void 0}(t,0,i)));return n.includes(void 0)?t:n}function Jn(t,e,i){const n=function(t,e){return Array.prototype.concat(...t.map((t=>Yn(t,e))))}(si.parseFormat(i),t),o=n.map((e=>function(t,e){const i=Bn(e),n=Bn(e,"{2}"),o=Bn(e,"{3}"),s=Bn(e,"{4}"),r=Bn(e,"{6}"),a=Bn(e,"{1,2}"),l=Bn(e,"{1,3}"),c=Bn(e,"{1,6}"),h=Bn(e,"{1,9}"),d=Bn(e,"{2,4}"),u=Bn(e,"{4,6}"),p=t=>{return{regex:RegExp((e=t.val,e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"))),deser:([t])=>t,literal:!0};var e},m=(m=>{if(t.literal)return p(m);switch(m.val){case"G":return jn(e.eras("short",!1),0);case"GG":return jn(e.eras("long",!1),0);case"y":return qn(c);case"yy":case"kk":return qn(d,De);case"yyyy":case"kkkk":return qn(s);case"yyyyy":return qn(u);case"yyyyyy":return qn(r);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return qn(a);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return qn(n);case"MMM":return jn(e.months("short",!0,!1),1);case"MMMM":return jn(e.months("long",!0,!1),1);case"LLL":return jn(e.months("short",!1,!1),1);case"LLLL":return jn(e.months("long",!1,!1),1);case"o":case"S":return qn(l);case"ooo":case"SSS":return qn(o);case"u":return Gn(h);case"uu":return Gn(a);case"uuu":case"E":case"c":return qn(i);case"a":return jn(e.meridiems(),0);case"EEE":return jn(e.weekdays("short",!1,!1),1);case"EEEE":return jn(e.weekdays("long",!1,!1),1);case"ccc":return jn(e.weekdays("short",!0,!1),1);case"cccc":return jn(e.weekdays("long",!0,!1),1);case"Z":case"ZZ":return Hn(new RegExp(`([+-]${a.source})(?::(${n.source}))?`),2);case"ZZZ":return Hn(new RegExp(`([+-]${a.source})(${n.source})?`),2);case"z":return Gn(/[a-z_+-/]{1,256}?/i);default:return p(m)}})(t)||{invalidReason:"missing Intl.DateTimeFormat.formatToParts support"};return m.token=t,m}(e,t))),s=o.find((t=>t.invalidReason));if(s)return{input:e,tokens:n,invalidReason:s.invalidReason};{const[t,i]=function(t){const e=t.map((t=>t.regex)).reduce(((t,e)=>`${t}(${e.source})`),"");return[`^${e}$`,t]}(o),s=RegExp(t,"i"),[r,a]=function(t,e,i){const n=t.match(e);if(n){const t={};let e=1;for(const o in i)if(Se(i,o)){const s=i[o],r=s.groups?s.groups+1:1;!s.literal&&s.token&&(t[s.token.val[0]]=s.deser(n.slice(e,e+r))),e+=r}return[n,t]}return[n,{}]}(e,s,i),[l,c,h]=a?function(t){let e,i=null;be(t.z)||(i=pi.create(t.z)),be(t.Z)||(i||(i=new fi(t.Z)),e=t.Z),be(t.q)||(t.M=3*(t.q-1)+1),be(t.h)||(t.h<12&&1===t.a?t.h+=12:12===t.h&&0===t.a&&(t.h=0)),0===t.G&&t.y&&(t.y=-t.y),be(t.u)||(t.S=Le(t.u));const n=Object.keys(t).reduce(((e,i)=>{const n=(t=>{switch(t){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}})(i);return n&&(e[n]=t[i]),e}),{});return[n,i,e]}(a):[null,null,void 0];if(Se(a,"a")&&Se(a,"H"))throw new Vt("Can't include meridiem when specifying 24-hour format");return{input:e,tokens:n,regex:s,rawMatches:r,matches:a,result:l,zone:c,specificOffset:h}}}const Xn=[0,31,59,90,120,151,181,212,243,273,304,334],Qn=[0,31,60,91,121,152,182,213,244,274,305,335];function to(t,e){return new ri("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${t}, which is invalid`)}function eo(t,e,i){const n=new Date(Date.UTC(t,e-1,i));t<100&&t>=0&&n.setUTCFullYear(n.getUTCFullYear()-1900);const o=n.getUTCDay();return 0===o?7:o}function io(t,e,i){return i+(Ae(t)?Qn:Xn)[e-1]}function no(t,e){const i=Ae(t)?Qn:Xn,n=i.findIndex((t=>t<e));return{month:n+1,day:e-i[n]}}function oo(t){const{year:e,month:i,day:n}=t,o=io(e,i,n),s=eo(e,i,n);let r,a=Math.floor((o-s+10)/7);return a<1?(r=e-1,a=Ie(r)):a>Ie(e)?(r=e+1,a=1):r=e,{weekYear:r,weekNumber:a,weekday:s,...Ze(t)}}function so(t){const{weekYear:e,weekNumber:i,weekday:n}=t,o=eo(e,1,4),s=Me(e);let r,a=7*i+n-o-3;a<1?(r=e-1,a+=Me(r)):a>s?(r=e+1,a-=Me(e)):r=e;const{month:l,day:c}=no(r,a);return{year:r,month:l,day:c,...Ze(t)}}function ro(t){const{year:e,month:i,day:n}=t;return{year:e,ordinal:io(e,i,n),...Ze(t)}}function ao(t){const{year:e,ordinal:i}=t,{month:n,day:o}=no(e,i);return{year:e,month:n,day:o,...Ze(t)}}function lo(t){const e=xe(t.year),i=Ce(t.month,1,12),n=Ce(t.day,1,Pe(t.year,t.month));return e?i?!n&&to("day",t.day):to("month",t.month):to("year",t.year)}function co(t){const{hour:e,minute:i,second:n,millisecond:o}=t,s=Ce(e,0,23)||24===e&&0===i&&0===n&&0===o,r=Ce(i,0,59),a=Ce(n,0,59),l=Ce(o,0,999);return s?r?a?!l&&to("millisecond",o):to("second",n):to("minute",i):to("hour",e)}const ho="Invalid DateTime";function uo(t){return new ri("unsupported zone",`the zone "${t.name}" is not supported`)}function po(t){return null===t.weekData&&(t.weekData=oo(t.c)),t.weekData}function mo(t,e){const i={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new Po({...i,...e,old:i})}function fo(t,e,i){let n=t-60*e*1e3;const o=i.offset(n);if(e===o)return[n,e];n-=60*(o-e)*1e3;const s=i.offset(n);return o===s?[n,o]:[t-60*Math.min(o,s)*1e3,Math.max(o,s)]}function go(t,e){const i=new Date(t+=60*e*1e3);return{year:i.getUTCFullYear(),month:i.getUTCMonth()+1,day:i.getUTCDate(),hour:i.getUTCHours(),minute:i.getUTCMinutes(),second:i.getUTCSeconds(),millisecond:i.getUTCMilliseconds()}}function vo(t,e,i){return fo(ze(t),e,i)}function yo(t,e){const i=t.o,n=t.c.year+Math.trunc(e.years),o=t.c.month+Math.trunc(e.months)+3*Math.trunc(e.quarters),s={...t.c,year:n,month:o,day:Math.min(t.c.day,Pe(n,o))+Math.trunc(e.days)+7*Math.trunc(e.weeks)},r=On.fromObject({years:e.years-Math.trunc(e.years),quarters:e.quarters-Math.trunc(e.quarters),months:e.months-Math.trunc(e.months),weeks:e.weeks-Math.trunc(e.weeks),days:e.days-Math.trunc(e.days),hours:e.hours,minutes:e.minutes,seconds:e.seconds,milliseconds:e.milliseconds}).as("milliseconds"),a=ze(s);let[l,c]=fo(a,i,t.zone);return 0!==r&&(l+=r,c=t.zone.offset(l)),{ts:l,o:c}}function bo(t,e,i,n,o,s){const{setZone:r,zone:a}=i;if(t&&0!==Object.keys(t).length){const n=e||a,o=Po.fromObject(t,{...i,zone:n,specificOffset:s});return r?o:o.setZone(a)}return Po.invalid(new ri("unparsable",`the input "${o}" can't be parsed as ${n}`))}function _o(t,e,i=!0){return t.isValid?si.create(Ii.create("en-US"),{allowZ:i,forceSimple:!0}).formatDateTimeFromString(t,e):null}function xo(t,e){const i=t.c.year>9999||t.c.year<0;let n="";return i&&t.c.year>=0&&(n+="+"),n+=Ee(t.c.year,i?6:4),e?(n+="-",n+=Ee(t.c.month),n+="-",n+=Ee(t.c.day)):(n+=Ee(t.c.month),n+=Ee(t.c.day)),n}function wo(t,e,i,n,o,s){let r=Ee(t.c.hour);return e?(r+=":",r+=Ee(t.c.minute),0===t.c.second&&i||(r+=":")):r+=Ee(t.c.minute),0===t.c.second&&i||(r+=Ee(t.c.second),0===t.c.millisecond&&n||(r+=".",r+=Ee(t.c.millisecond,3))),o&&(t.isOffsetFixed&&0===t.offset&&!s?r+="Z":t.o<0?(r+="-",r+=Ee(Math.trunc(-t.o/60)),r+=":",r+=Ee(Math.trunc(-t.o%60))):(r+="+",r+=Ee(Math.trunc(t.o/60)),r+=":",r+=Ee(Math.trunc(t.o%60)))),s&&(r+="["+t.zone.ianaName+"]"),r}const ko={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},So={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},Co={ordinal:1,hour:0,minute:0,second:0,millisecond:0},Eo=["year","month","day","hour","minute","second","millisecond"],To=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],$o=["year","ordinal","hour","minute","second","millisecond"];function Lo(t){const e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new jt(t);return e}function Oo(t,e){const i=vi(e.zone,Si.defaultZone),n=Ii.fromObject(e),o=Si.now();let s,r;if(be(t.year))s=o;else{for(const e of Eo)be(t[e])&&(t[e]=ko[e]);const e=lo(t)||co(t);if(e)return Po.invalid(e);const n=i.offset(o);[s,r]=vo(t,n,i)}return new Po({ts:s,zone:i,loc:n,o:r})}function Ao(t,e,i){const n=!!be(i.round)||i.round,o=(t,o)=>{t=Oe(t,n||i.calendary?0:2,!0);return e.loc.clone(i).relFormatter(i).format(t,o)},s=n=>i.calendary?e.hasSame(t,n)?0:e.startOf(n).diff(t.startOf(n),n).get(n):e.diff(t,n).get(n);if(i.unit)return o(s(i.unit),i.unit);for(const t of i.units){const e=s(t);if(Math.abs(e)>=1)return o(e,t)}return o(t>e?-0:0,i.units[i.units.length-1])}function Mo(t){let e,i={};return t.length>0&&"object"==typeof t[t.length-1]?(i=t[t.length-1],e=Array.from(t).slice(0,t.length-1)):e=Array.from(t),[i,e]}class Po{constructor(t){const e=t.zone||Si.defaultZone;let i=t.invalid||(Number.isNaN(t.ts)?new ri("invalid input"):null)||(e.isValid?null:uo(e));this.ts=be(t.ts)?Si.now():t.ts;let n=null,o=null;if(!i){if(t.old&&t.old.ts===this.ts&&t.old.zone.equals(e))[n,o]=[t.old.c,t.old.o];else{const t=e.offset(this.ts);n=go(this.ts,t),i=Number.isNaN(n.year)?new ri("invalid input"):null,n=i?null:n,o=i?null:t}}this._zone=e,this.loc=t.loc||Ii.create(),this.invalid=i,this.weekData=null,this.c=n,this.o=o,this.isLuxonDateTime=!0}static now(){return new Po({})}static local(){const[t,e]=Mo(arguments),[i,n,o,s,r,a,l]=e;return Oo({year:i,month:n,day:o,hour:s,minute:r,second:a,millisecond:l},t)}static utc(){const[t,e]=Mo(arguments),[i,n,o,s,r,a,l]=e;return t.zone=fi.utcInstance,Oo({year:i,month:n,day:o,hour:s,minute:r,second:a,millisecond:l},t)}static fromJSDate(t,e={}){const i=function(t){return"[object Date]"===Object.prototype.toString.call(t)}(t)?t.valueOf():NaN;if(Number.isNaN(i))return Po.invalid("invalid input");const n=vi(e.zone,Si.defaultZone);return n.isValid?new Po({ts:i,zone:n,loc:Ii.fromObject(e)}):Po.invalid(uo(n))}static fromMillis(t,e={}){if(_e(t))return t<-864e13||t>864e13?Po.invalid("Timestamp out of range"):new Po({ts:t,zone:vi(e.zone,Si.defaultZone),loc:Ii.fromObject(e)});throw new Ht(`fromMillis requires a numerical input, but received a ${typeof t} with value ${t}`)}static fromSeconds(t,e={}){if(_e(t))return new Po({ts:1e3*t,zone:vi(e.zone,Si.defaultZone),loc:Ii.fromObject(e)});throw new Ht("fromSeconds requires a numerical input")}static fromObject(t,e={}){t=t||{};const i=vi(e.zone,Si.defaultZone);if(!i.isValid)return Po.invalid(uo(i));const n=Si.now(),o=be(e.specificOffset)?i.offset(n):e.specificOffset,s=qe(t,Lo),r=!be(s.ordinal),a=!be(s.year),l=!be(s.month)||!be(s.day),c=a||l,h=s.weekYear||s.weekNumber,d=Ii.fromObject(e);if((c||r)&&h)throw new Vt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(l&&r)throw new Vt("Can't mix ordinal dates with month/day");const u=h||s.weekday&&!c;let p,m,f=go(n,o);u?(p=To,m=So,f=oo(f)):r?(p=$o,m=Co,f=ro(f)):(p=Eo,m=ko);let g=!1;for(const t of p){be(s[t])?s[t]=g?m[t]:f[t]:g=!0}const v=u?function(t){const e=xe(t.weekYear),i=Ce(t.weekNumber,1,Ie(t.weekYear)),n=Ce(t.weekday,1,7);return e?i?!n&&to("weekday",t.weekday):to("week",t.week):to("weekYear",t.weekYear)}(s):r?function(t){const e=xe(t.year),i=Ce(t.ordinal,1,Me(t.year));return e?!i&&to("ordinal",t.ordinal):to("year",t.year)}(s):lo(s),y=v||co(s);if(y)return Po.invalid(y);const b=u?so(s):r?ao(s):s,[_,x]=vo(b,o,i),w=new Po({ts:_,zone:i,o:x,loc:d});return s.weekday&&c&&t.weekday!==w.weekday?Po.invalid("mismatched weekday",`you can't specify both a weekday of ${s.weekday} and a date of ${w.toISO()}`):w}static fromISO(t,e={}){const[i,n]=function(t){return Ri(t,[dn,fn],[un,gn],[pn,vn],[mn,yn])}(t);return bo(i,n,e,"ISO 8601",t)}static fromRFC2822(t,e={}){const[i,n]=function(t){return Ri(function(t){return t.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(t),[on,sn])}(t);return bo(i,n,e,"RFC 2822",t)}static fromHTTP(t,e={}){const[i,n]=function(t){return Ri(t,[rn,cn],[an,cn],[ln,hn])}(t);return bo(i,n,e,"HTTP",e)}static fromFormat(t,e,i={}){if(be(t)||be(e))throw new Ht("fromFormat requires an input string and a format");const{locale:n=null,numberingSystem:o=null}=i,s=Ii.fromOpts({locale:n,numberingSystem:o,defaultToEN:!0}),[r,a,l,c]=function(t,e,i){const{result:n,zone:o,specificOffset:s,invalidReason:r}=Jn(t,e,i);return[n,o,s,r]}(s,t,e);return c?Po.invalid(c):bo(r,a,i,`format ${e}`,t,l)}static fromString(t,e,i={}){return Po.fromFormat(t,e,i)}static fromSQL(t,e={}){const[i,n]=function(t){return Ri(t,[_n,fn],[xn,wn])}(t);return bo(i,n,e,"SQL",t)}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the DateTime is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Ft(i);return new Po({invalid:i})}static isDateTime(t){return t&&t.isLuxonDateTime||!1}get(t){return this[t]}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?po(this).weekYear:NaN}get weekNumber(){return this.isValid?po(this).weekNumber:NaN}get weekday(){return this.isValid?po(this).weekday:NaN}get ordinal(){return this.isValid?ro(this.c).ordinal:NaN}get monthShort(){return this.isValid?Pn.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?Pn.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?Pn.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?Pn.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}get isInLeapYear(){return Ae(this.year)}get daysInMonth(){return Pe(this.year,this.month)}get daysInYear(){return this.isValid?Me(this.year):NaN}get weeksInWeekYear(){return this.isValid?Ie(this.weekYear):NaN}resolvedLocaleOptions(t={}){const{locale:e,numberingSystem:i,calendar:n}=si.create(this.loc.clone(t),t).resolvedOptions(this);return{locale:e,numberingSystem:i,outputCalendar:n}}toUTC(t=0,e={}){return this.setZone(fi.instance(t),e)}toLocal(){return this.setZone(Si.defaultZone)}setZone(t,{keepLocalTime:e=!1,keepCalendarTime:i=!1}={}){if((t=vi(t,Si.defaultZone)).equals(this.zone))return this;if(t.isValid){let n=this.ts;if(e||i){const e=t.offset(this.ts),i=this.toObject();[n]=vo(i,e,t)}return mo(this,{ts:n,zone:t})}return Po.invalid(uo(t))}reconfigure({locale:t,numberingSystem:e,outputCalendar:i}={}){return mo(this,{loc:this.loc.clone({locale:t,numberingSystem:e,outputCalendar:i})})}setLocale(t){return this.reconfigure({locale:t})}set(t){if(!this.isValid)return this;const e=qe(t,Lo),i=!be(e.weekYear)||!be(e.weekNumber)||!be(e.weekday),n=!be(e.ordinal),o=!be(e.year),s=!be(e.month)||!be(e.day),r=o||s,a=e.weekYear||e.weekNumber;if((r||n)&&a)throw new Vt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(s&&n)throw new Vt("Can't mix ordinal dates with month/day");let l;i?l=so({...oo(this.c),...e}):be(e.ordinal)?(l={...this.toObject(),...e},be(e.day)&&(l.day=Math.min(Pe(l.year,l.month),l.day))):l=ao({...ro(this.c),...e});const[c,h]=vo(l,this.o,this.zone);return mo(this,{ts:c,o:h})}plus(t){if(!this.isValid)return this;return mo(this,yo(this,On.fromDurationLike(t)))}minus(t){if(!this.isValid)return this;return mo(this,yo(this,On.fromDurationLike(t).negate()))}startOf(t){if(!this.isValid)return this;const e={},i=On.normalizeUnit(t);switch(i){case"years":e.month=1;case"quarters":case"months":e.day=1;case"weeks":case"days":e.hour=0;case"hours":e.minute=0;case"minutes":e.second=0;case"seconds":e.millisecond=0}if("weeks"===i&&(e.weekday=1),"quarters"===i){const t=Math.ceil(this.month/3);e.month=3*(t-1)+1}return this.set(e)}endOf(t){return this.isValid?this.plus({[t]:1}).startOf(t).minus(1):this}toFormat(t,e={}){return this.isValid?si.create(this.loc.redefaultToEN(e)).formatDateTimeFromString(this,t):ho}toLocaleString(t=Jt,e={}){return this.isValid?si.create(this.loc.clone(e),t).formatDateTime(this):ho}toLocaleParts(t={}){return this.isValid?si.create(this.loc.clone(t),t).formatDateTimeParts(this):[]}toISO({format:t="extended",suppressSeconds:e=!1,suppressMilliseconds:i=!1,includeOffset:n=!0,extendedZone:o=!1}={}){if(!this.isValid)return null;const s="extended"===t;let r=xo(this,s);return r+="T",r+=wo(this,s,e,i,n,o),r}toISODate({format:t="extended"}={}){return this.isValid?xo(this,"extended"===t):null}toISOWeekDate(){return _o(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:t=!1,suppressSeconds:e=!1,includeOffset:i=!0,includePrefix:n=!1,extendedZone:o=!1,format:s="extended"}={}){if(!this.isValid)return null;return(n?"T":"")+wo(this,"extended"===s,e,t,i,o)}toRFC2822(){return _o(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return _o(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?xo(this,!0):null}toSQLTime({includeOffset:t=!0,includeZone:e=!1,includeOffsetSpace:i=!0}={}){let n="HH:mm:ss.SSS";return(e||t)&&(i&&(n+=" "),e?n+="z":t&&(n+="ZZ")),_o(this,n,!0)}toSQL(t={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(t)}`:null}toString(){return this.isValid?this.toISO():ho}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(t={}){if(!this.isValid)return{};const e={...this.c};return t.includeConfig&&(e.outputCalendar=this.outputCalendar,e.numberingSystem=this.loc.numberingSystem,e.locale=this.loc.locale),e}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(t,e="milliseconds",i={}){if(!this.isValid||!t.isValid)return On.invalid("created by diffing an invalid DateTime");const n={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=(a=e,Array.isArray(a)?a:[a]).map(On.normalizeUnit),s=t.valueOf()>this.valueOf(),r=In(s?this:t,s?t:this,o,n);var a;return s?r.negate():r}diffNow(t="milliseconds",e={}){return this.diff(Po.now(),t,e)}until(t){return this.isValid?Mn.fromDateTimes(this,t):this}hasSame(t,e){if(!this.isValid)return!1;const i=t.valueOf(),n=this.setZone(t.zone,{keepLocalTime:!0});return n.startOf(e)<=i&&i<=n.endOf(e)}equals(t){return this.isValid&&t.isValid&&this.valueOf()===t.valueOf()&&this.zone.equals(t.zone)&&this.loc.equals(t.loc)}toRelative(t={}){if(!this.isValid)return null;const e=t.base||Po.fromObject({},{zone:this.zone}),i=t.padding?this<e?-t.padding:t.padding:0;let n=["years","months","days","hours","minutes","seconds"],o=t.unit;return Array.isArray(t.unit)&&(n=t.unit,o=void 0),Ao(e,this.plus(i),{...t,numeric:"always",units:n,unit:o})}toRelativeCalendar(t={}){return this.isValid?Ao(t.base||Po.fromObject({},{zone:this.zone}),this,{...t,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...t){if(!t.every(Po.isDateTime))throw new Ht("min requires all arguments be DateTimes");return ke(t,(t=>t.valueOf()),Math.min)}static max(...t){if(!t.every(Po.isDateTime))throw new Ht("max requires all arguments be DateTimes");return ke(t,(t=>t.valueOf()),Math.max)}static fromFormatExplain(t,e,i={}){const{locale:n=null,numberingSystem:o=null}=i;return Jn(Ii.fromOpts({locale:n,numberingSystem:o,defaultToEN:!0}),t,e)}static fromStringExplain(t,e,i={}){return Po.fromFormatExplain(t,e,i)}static get DATE_SHORT(){return Jt}static get DATE_MED(){return Xt}static get DATE_MED_WITH_WEEKDAY(){return Qt}static get DATE_FULL(){return te}static get DATE_HUGE(){return ee}static get TIME_SIMPLE(){return ie}static get TIME_WITH_SECONDS(){return ne}static get TIME_WITH_SHORT_OFFSET(){return oe}static get TIME_WITH_LONG_OFFSET(){return se}static get TIME_24_SIMPLE(){return re}static get TIME_24_WITH_SECONDS(){return ae}static get TIME_24_WITH_SHORT_OFFSET(){return le}static get TIME_24_WITH_LONG_OFFSET(){return ce}static get DATETIME_SHORT(){return he}static get DATETIME_SHORT_WITH_SECONDS(){return de}static get DATETIME_MED(){return ue}static get DATETIME_MED_WITH_SECONDS(){return pe}static get DATETIME_MED_WITH_WEEKDAY(){return me}static get DATETIME_FULL(){return fe}static get DATETIME_FULL_WITH_SECONDS(){return ge}static get DATETIME_HUGE(){return ve}static get DATETIME_HUGE_WITH_SECONDS(){return ye}}function zo(t){if(Po.isDateTime(t))return t;if(t&&t.valueOf&&_e(t.valueOf()))return Po.fromJSDate(t);if(t&&"object"==typeof t)return Po.fromObject(t);throw new Ht(`Unknown datetime argument: ${t}, of type ${typeof t}`)}class Io extends tt{constructor(){super(...arguments),this.ttl=6e4,this.max=20,this.keyedAssets={},this.locale=[...navigator.languages],this.fields={},this.groups={},this.languages={},this.featuredFields=[],this.langService=new Rt,this.humanizer=new Bt(this.langService),this.pendingResolves={},this.fetching={}}reset(){this.cache=Nt(this.max,this.ttl);const t=[];this.completionEndpoint&&t.push(gt(this.completionEndpoint).then((t=>{this.schema=t.json.context,this.fnOptions=t.json.functions}))),this.fieldsEndpoint&&t.push(this.refreshFields()),this.globalsEndpoint&&t.push(xt(this.globalsEndpoint).then((t=>{this.keyedAssets.globals=t.map((t=>t.key))}))),this.languagesEndpoint&&t.push(xt(this.languagesEndpoint).then((t=>{this.languages=t.reduce((function(t,e){return t[e.value]=e.name,t}),{})}))),this.groupsEndpoint&&t.push(xt(this.groupsEndpoint).then((t=>{t.forEach((t=>{this.groups[t.uuid]=t}))}))),this.workspaceEndpoint&&t.push(gt(this.workspaceEndpoint).then((t=>{this.workspace=t.json;const e=t.headers.get("content-language");e&&(this.locale=[e,...this.locale])}))),this.httpComplete=Promise.all(t)}firstUpdated(){this.reset()}getLanguageCode(){return this.locale.length>0?this.locale[0].split("-")[0]:"en"}refreshFields(){return xt(this.fieldsEndpoint).then((t=>{this.keyedAssets.fields=[],this.featuredFields=[],t.forEach((t=>{this.keyedAssets.fields.push(t.key),this.fields[t.key]=t,t.featured&&this.featuredFields.push(t)})),this.featuredFields.sort(((t,e)=>e.priority-t.priority)),this.keyedAssets.fields.sort(),this.fireCustomEvent(It.StoreUpdated,{url:this.fieldsEndpoint,data:this.keyedAssets.fields})}))}getShortDuration(t,e=null,i=!1){const n=e||Po.now(),o=t.diff(n).valueOf();return i?this.humanizer.humanize(o,{language:this.getLanguageCode(),largest:1,round:!0}):Math.abs(o)<6e4?"just now":this.humanizer.humanize(o,{language:this.getLanguageCode(),largest:1,round:!1})}getShortDurationFromIso(t,e=null,i=!1){const n=Po.fromISO(t),o=e?Po.fromISO(e):Po.now();return this.getShortDuration(n,o,i)}setKeyedAssets(t,e){this.keyedAssets[t]=e}updated(t){super.updated(t)}getCompletionSchema(){return this.schema}getFunctions(){return this.fnOptions}getKeyedAssets(){return this.keyedAssets}getFieldKeys(){return this.keyedAssets.fields}getContactField(t){return this.fields[t]}getFeaturedFields(){return this.featuredFields}getLanguageName(t){return this.languages[t]}isDynamicGroup(t){const e=this.groups[t];return!(!e||!e.query)}getWorkspace(){return this.workspace}formatDate(t){return new Date(t).toLocaleString(this.locale,{year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric"})}postUrl(t,e="",i={},n=null){return wt(t,e,i,n)}getUrl(t,e){return!(e=e||{}).force&&this.cache.has(t)?new Promise((e=>{e(this.cache.get(t))})):gt(t,e.controller,e.headers||{}).then((e=>new Promise(((i,n)=>{e.status>=200&&e.status<=300?(this.cache.set(t,e),i(e)):n("Status: "+e.status)}))))}getResults(t,e){e=e||{};const i="results_"+t,n=this.cache.get(i);return!e.force&&n?new Promise((t=>{t(n)})):new Promise((e=>{const n=this.pendingResolves[t]||[];n.push(e),this.pendingResolves[t]=n,n.length<=1&&bt(t).then((e=>{this.cache.set(i,e);const n=this.pendingResolves[t]||[];for(;n.length>0;){n.pop()(e)}}))}))}updateCache(t,e){this.cache.set(t,e),this.fireCustomEvent(It.StoreUpdated,{url:t,data:e})}makeRequest(t,e){const i=this.fetching[t],n=(new Date).getTime();if(i&&n-i<500)return;this.fetching[t]=n,e=e||{};const o=this.cache.get(t);o&&!e.force?this.fireCustomEvent(It.StoreUpdated,{url:t,data:o}):bt(t).then((i=>{i=e.prepareData?e.prepareData(i):i,this.cache.set(t,i),this.fireCustomEvent(It.StoreUpdated,{url:t,data:i}),delete this.fetching[t]}))}}t([it({type:Number})],Io.prototype,"ttl",void 0),t([it({type:Number})],Io.prototype,"max",void 0),t([it({type:String,attribute:"completion"})],Io.prototype,"completionEndpoint",void 0),t([it({type:String,attribute:"fields"})],Io.prototype,"fieldsEndpoint",void 0),t([it({type:String,attribute:"groups"})],Io.prototype,"groupsEndpoint",void 0),t([it({type:String,attribute:"globals"})],Io.prototype,"globalsEndpoint",void 0),t([it({type:String,attribute:"languages"})],Io.prototype,"languagesEndpoint",void 0),t([it({type:String,attribute:"workspace"})],Io.prototype,"workspaceEndpoint",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"schema",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"fnOptions",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"keyedAssets",void 0);class Do extends tt{constructor(){super(...arguments),this.marginHorizontal=0,this.marginVertical=7,this.scrollPct=75,this.cursorIndex=-1,this.nameKey="name",this.loading=!1,this.hideShadow=!1,this.getName=function(t){return t[this.nameKey||"name"]},this.renderInputOption=function(){return null},this.scrollHeight=0,this.triggerScroll=!1,this.scrollParent=null,this.setCursor=Tt((function(t){t!==this.cursorIndex&&(this.cursorIndex=t)}),50)}static get styles(){return s`
224
+ `}}t([it({type:Boolean})],pt.prototype,"textarea",void 0),t([it({type:String})],pt.prototype,"placeholder",void 0),t([it({type:String})],pt.prototype,"value",void 0),t([it({type:Boolean})],pt.prototype,"password",void 0),t([it({type:Number})],pt.prototype,"maxlength",void 0),t([it({type:Object})],pt.prototype,"inputElement",void 0),t([it({type:Boolean})],pt.prototype,"clearable",void 0),t([it({type:Boolean})],pt.prototype,"gsm",void 0),t([it({type:String})],pt.prototype,"counter",void 0),t([it({type:Boolean})],pt.prototype,"loading",void 0),t([it({type:Boolean})],pt.prototype,"submitOnEnter",void 0),t([it()],pt.prototype,"onBlur",void 0),t([it({type:Boolean})],pt.prototype,"autogrow",void 0);const mt=/(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))/,ft=(t={})=>{const e=(t=>{for(const e of document.cookie.split(";")){const i=e.indexOf("=");let n=e.substr(0,i),o=e.substr(i+1);if(n=n.trim(),o=o.trim(),n===t)return o}return null})("csrftoken"),i=e?{"X-CSRFToken":e}:{};return i["X-Requested-With"]="XMLHttpRequest",Object.keys(t).forEach((e=>{i[e]=t[e]})),i},gt=(t,e=null,i={})=>new Promise(((n,o)=>{const s={method:"GET",headers:ft(i)};e&&(s.signal=e.signal),fetch(t,s).then((t=>{t.text().then((i=>{let o={};try{o=JSON.parse(i)}catch(t){}n({controller:e,body:i,json:o,headers:t.headers,status:t.status})}))})).catch((t=>{o(t)}))})),vt=t=>{const e=[];Object.keys(t).forEach((i=>{t[i]&&e.push(i)}));let i=e.join(" ");return i.trim().length>0&&(i=" "+i),i},yt=(t,e=null)=>new Promise(((i,n)=>{gt(t,e).then((t=>{i({results:t.json.results,next:t.json.next})})).catch((t=>n(t)))})),bt=async t=>{if(!t)return new Promise((t=>t([])));let e=[],i=t;for(;i;){const t=await yt(i);t.results&&(e=e.concat(t.results)),i=t.next}return e},_t=t=>new Promise(((e,i)=>{gt(t).then((t=>{e({assets:t.json.results,next:t.json.next})})).catch((t=>i(t)))})),xt=async t=>{if(!t)return new Promise((t=>t([])));let e=[],i=t;for(;i;){const t=await _t(i);e=e.concat(t.assets),i=t.next}return e},wt=(t,e,i={},n=null)=>{const o=ft(i);n&&(o["Content-Type"]=n);const s={method:"POST",headers:o,body:e};return new Promise(((e,i)=>{fetch(t,s).then((async t=>{t.text().then((i=>{let n={};try{n=JSON.parse(i)}catch(t){}e({body:i,json:n,headers:t.headers,status:t.status})}))})).catch((t=>{i(t)}))}))},kt=(t,e)=>wt(t,JSON.stringify(e),!1,"application/json"),St=t=>{const e=t.parentNode||t.host;if(e){const t=e instanceof HTMLElement&&window.getComputedStyle(e).overflowY,i=t&&!(t.includes("hidden")||t.includes("visible"));return e?i&&e.scrollHeight>=e.clientHeight?e:St(e):null}return null};const Ct=new class{getCurrentDate(){return new Date}},Et=(t,e={suffix:""})=>{const{compareDate:i,hideRecentText:n,suffix:o}=e,s=i||Ct.getCurrentDate(),r=Math.floor((s.getTime()-t.getTime())/1e3);if(r<60)return i?r+"s"+o:!n&&o?o:"just now";if(r<3600)return Math.round(r/60)+"m"+o;if(r<=86400)return Math.round(r/3600)+"h"+o;if(r<=2592e3)return Math.round(r/86400)+"d"+o;if(r<15552e3)return Math.round(r/2592e3)+"mth"+o;return t.getDate()+" "+t.toDateString().match(/ [a-zA-Z]*/)[0].replace(" ","")+(t.getFullYear()==s.getFullYear()?"":" "+t.getFullYear())},Tt=(t,e)=>{let i=!0;return function(...n){i&&(i=!1,t.apply(this,n),setTimeout((()=>{i=!0}),e))}},$t=(t,e="and")=>1===t.length?t[0]:2===t.length?"html"===t[0].type?P`${t[0]} ${e} ${t[1]}`:t.join(" "+e+" "):"html"===t[0].type?t.map(((i,n)=>n<t.length-1?P`${i}, `:P`${e} ${i}`)):t.join(", ")+e+t[t.length-1],Lt=(t,e,i="and")=>$t(t.map(e),i),Ot=t=>"true"===((t=>{let e=null;if(document.cookie&&""!=document.cookie){const i=document.cookie.split(";");for(let n=0;n<i.length;n++){const o=i[n].trim();if(o.substring(0,t.length+1)==t+"="){e=decodeURIComponent(o.substring(t.length+1));break}}}return e})(t)||"");var At;!function(t){t.MENU_COLLAPSED="menu-collapsed",t.TICKET_SHOW_DETAILS="tickets.show-details"}(At||(At={}));var Mt,Pt,zt,It;!function(t){t.DayFirst="day_first",t.MonthFirst="month_first",t.YearFirst="year_first"}(Mt||(Mt={})),function(t){t.CampaignEvent="campaign_event",t.ScheduledBroadcast="scheduled_broadcast",t.ScheduledTrigger="scheduled_trigger"}(Pt||(Pt={})),function(t){t.Open="open",t.Closed="closed"}(zt||(zt={})),function(t){t.Loaded="temba-loaded",t.Canceled="temba-canceled",t.CursorChanged="temba-cursor-changed",t.Refreshed="temba-refreshed",t.Selection="temba-selection",t.ButtonClicked="temba-button-clicked",t.DialogHidden="temba-dialog-hidden",t.ScrollThreshold="temba-scroll-threshold",t.ContentChanged="temba-content-changed",t.ContextChanged="temba-context-changed",t.FetchComplete="temba-fetch-complete",t.Submitted="temba-submitted",t.Redirected="temba-redirected",t.NoPath="temba-no-path",t.StoreUpdated="temba-store-updated",t.Ready="temba-ready",t.OrderChanged="temba-order-changed",t.DragStart="temba-drag-start",t.DragStop="temba-drag-stop"}(It||(It={}));class Dt{constructor(t=0,e=0){this.first=null,this.items=Object.create(null),this.last=null,this.max=t,this.size=0,this.ttl=e}has(t){return t in this.items}clear(){return this.first=null,this.items=Object.create(null),this.last=null,this.size=0,this}delete(t){if(this.has(t)){const e=this.items[t];delete this.items[t],this.size--,null!==e.prev&&(e.prev.next=e.next),null!==e.next&&(e.next.prev=e.prev),this.first===e&&(this.first=e.next),this.last===e&&(this.last=e.prev)}return this}evict(t=!1){if(t||this.size>0){const t=this.first;delete this.items[t.key],this.size--,0===this.size?(this.first=null,this.last=null):(this.first=t.next,this.first.prev=null)}return this}get(t){let e;if(this.has(t)){const i=this.items[t];this.ttl>0&&i.expiry<=(new Date).getTime()?this.delete(t):(e=i.value,this.set(t,e,!0))}return e}keys(){return Object.keys(this.items)}set(t,e,i=!1){let n;if(i||this.has(t)){if(n=this.items[t],n.value=e,this.last!==n){const t=this.last,e=n.next,i=n.prev;this.first===n&&(this.first=n.next),n.next=null,n.prev=this.last,t.next=n,null!==i&&(i.next=e),null!==e&&(e.prev=i)}}else this.max>0&&this.size===this.max&&this.evict(!0),n=this.items[t]={expiry:this.ttl>0?(new Date).getTime()+this.ttl:this.ttl,key:t,prev:this.last,next:null,value:e},1==++this.size?this.first=n:this.last.next=n;return this.last=n,this}}function Nt(t=1e3,e=0){if(isNaN(t)||t<0)throw new TypeError("Invalid max value");if(isNaN(e)||e<0)throw new TypeError("Invalid ttl value");return new Dt(t,e)}var Rt=function(){function t(){var t=this;this.languages={ar:{y:function(t){return 1===t?"سنة":"سنوات"},mo:function(t){return 1===t?"شهر":"أشهر"},w:function(t){return 1===t?"أسبوع":"أسابيع"},d:function(t){return 1===t?"يوم":"أيام"},h:function(t){return 1===t?"ساعة":"ساعات"},m:function(e){return["دقيقة","دقائق"][t.getArabicForm(e)]},s:function(t){return 1===t?"ثانية":"ثواني"},ms:function(t){return 1===t?"جزء من الثانية":"أجزاء من الثانية"},decimal:","},bg:{y:function(e){return["години","година","години"][t.getSlavicForm(e)]},mo:function(e){return["месеца","месец","месеца"][t.getSlavicForm(e)]},w:function(e){return["седмици","седмица","седмици"][t.getSlavicForm(e)]},d:function(e){return["дни","ден","дни"][t.getSlavicForm(e)]},h:function(e){return["часа","час","часа"][t.getSlavicForm(e)]},m:function(e){return["минути","минута","минути"][t.getSlavicForm(e)]},s:function(e){return["секунди","секунда","секунди"][t.getSlavicForm(e)]},ms:function(e){return["милисекунди","милисекунда","милисекунди"][t.getSlavicForm(e)]},decimal:","},ca:{y:function(t){return"any"+(1===t?"":"s")},mo:function(t){return"mes"+(1===t?"":"os")},w:function(t){return"setman"+(1===t?"a":"es")},d:function(t){return"di"+(1===t?"a":"es")},h:function(t){return"hor"+(1===t?"a":"es")},m:function(t){return"minut"+(1===t?"":"s")},s:function(t){return"segon"+(1===t?"":"s")},ms:function(t){return"milisegon"+(1===t?"":"s")},decimal:","},cs:{y:function(e){return["rok","roku","roky","let"][t.getCzechOrSlovakForm(e)]},mo:function(e){return["měsíc","měsíce","měsíce","měsíců"][t.getCzechOrSlovakForm(e)]},w:function(e){return["týden","týdne","týdny","týdnů"][t.getCzechOrSlovakForm(e)]},d:function(e){return["den","dne","dny","dní"][t.getCzechOrSlovakForm(e)]},h:function(e){return["hodina","hodiny","hodiny","hodin"][t.getCzechOrSlovakForm(e)]},m:function(e){return["minuta","minuty","minuty","minut"][t.getCzechOrSlovakForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekund"][t.getCzechOrSlovakForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekund"][t.getCzechOrSlovakForm(e)]},decimal:","},da:{y:function(){return"år"},mo:function(t){return"måned"+(1===t?"":"er")},w:function(t){return"uge"+(1===t?"":"r")},d:function(t){return"dag"+(1===t?"":"e")},h:function(t){return"time"+(1===t?"":"r")},m:function(t){return"minut"+(1===t?"":"ter")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},de:{y:function(t){return"Jahr"+(1===t?"":"e")},mo:function(t){return"Monat"+(1===t?"":"e")},w:function(t){return"Woche"+(1===t?"":"n")},d:function(t){return"Tag"+(1===t?"":"e")},h:function(t){return"Stunde"+(1===t?"":"n")},m:function(t){return"Minute"+(1===t?"":"n")},s:function(t){return"Sekunde"+(1===t?"":"n")},ms:function(t){return"Millisekunde"+(1===t?"":"n")},decimal:","},el:{y:function(t){return 1===t?"χρόνος":"χρόνια"},mo:function(t){return 1===t?"μήνας":"μήνες"},w:function(t){return 1===t?"εβδομάδα":"εβδομάδες"},d:function(t){return 1===t?"μέρα":"μέρες"},h:function(t){return 1===t?"ώρα":"ώρες"},m:function(t){return 1===t?"λεπτό":"λεπτά"},s:function(t){return 1===t?"δευτερόλεπτο":"δευτερόλεπτα"},ms:function(t){return 1===t?"χιλιοστό του δευτερολέπτου":"χιλιοστά του δευτερολέπτου"},decimal:","},en:{y:function(t){return"year"+(1===t?"":"s")},mo:function(t){return"month"+(1===t?"":"s")},w:function(t){return"week"+(1===t?"":"s")},d:function(t){return"day"+(1===t?"":"s")},h:function(t){return"hour"+(1===t?"":"s")},m:function(t){return"minute"+(1===t?"":"s")},s:function(t){return"second"+(1===t?"":"s")},ms:function(t){return"millisecond"+(1===t?"":"s")},decimal:"."},es:{y:function(t){return"año"+(1===t?"":"s")},mo:function(t){return"mes"+(1===t?"":"es")},w:function(t){return"semana"+(1===t?"":"s")},d:function(t){return"día"+(1===t?"":"s")},h:function(t){return"hora"+(1===t?"":"s")},m:function(t){return"minuto"+(1===t?"":"s")},s:function(t){return"segundo"+(1===t?"":"s")},ms:function(t){return"milisegundo"+(1===t?"":"s")},decimal:","},et:{y:function(t){return"aasta"+(1===t?"":"t")},mo:function(t){return"kuu"+(1===t?"":"d")},w:function(t){return"nädal"+(1===t?"":"at")},d:function(t){return"päev"+(1===t?"":"a")},h:function(t){return"tund"+(1===t?"":"i")},m:function(t){return"minut"+(1===t?"":"it")},s:function(t){return"sekund"+(1===t?"":"it")},ms:function(t){return"millisekund"+(1===t?"":"it")},decimal:","},fa:{y:function(){return"سال"},mo:function(){return"ماه"},w:function(){return"هفته"},d:function(){return"روز"},h:function(){return"ساعت"},m:function(){return"دقیقه"},s:function(){return"ثانیه"},ms:function(){return"میلی ثانیه"},decimal:"."},fi:{y:function(t){return 1===t?"vuosi":"vuotta"},mo:function(t){return 1===t?"kuukausi":"kuukautta"},w:function(t){return"viikko"+(1===t?"":"a")},d:function(t){return"päivä"+(1===t?"":"ä")},h:function(t){return"tunti"+(1===t?"":"a")},m:function(t){return"minuutti"+(1===t?"":"a")},s:function(t){return"sekunti"+(1===t?"":"a")},ms:function(t){return"millisekunti"+(1===t?"":"a")},decimal:","},fo:{y:function(){return"ár"},mo:function(t){return 1===t?"mánaður":"mánaðir"},w:function(t){return 1===t?"vika":"vikur"},d:function(t){return 1===t?"dagur":"dagar"},h:function(t){return 1===t?"tími":"tímar"},m:function(t){return 1===t?"minuttur":"minuttir"},s:function(){return"sekund"},ms:function(){return"millisekund"},decimal:","},fr:{y:function(t){return"an"+(t>=2?"s":"")},mo:function(){return"mois"},w:function(t){return"semaine"+(t>=2?"s":"")},d:function(t){return"jour"+(t>=2?"s":"")},h:function(t){return"heure"+(t>=2?"s":"")},m:function(t){return"minute"+(t>=2?"s":"")},s:function(t){return"seconde"+(t>=2?"s":"")},ms:function(t){return"milliseconde"+(t>=2?"s":"")},decimal:","},hr:{y:function(t){return t%10==2||t%10==3||t%10==4?"godine":"godina"},mo:function(t){return 1===t?"mjesec":2===t||3===t||4===t?"mjeseca":"mjeseci"},w:function(t){return t%10==1&&11!==t?"tjedan":"tjedna"},d:function(t){return 1===t?"dan":"dana"},h:function(t){return 1===t?"sat":2===t||3===t||4===t?"sata":"sati"},m:function(t){var e=t%10;return 2!==e&&3!==e&&4!==e||!(t<10||t>14)?"minuta":"minute"},s:function(t){return 10===t||11===t||12===t||13===t||14===t||16===t||17===t||18===t||19===t||t%10==5?"sekundi":t%10==1?"sekunda":t%10==2||t%10==3||t%10==4?"sekunde":"sekundi"},ms:function(t){return 1===t?"milisekunda":t%10==2||t%10==3||t%10==4?"milisekunde":"milisekundi"},decimal:","},hu:{y:function(){return"év"},mo:function(){return"hónap"},w:function(){return"hét"},d:function(){return"nap"},h:function(){return"óra"},m:function(){return"perc"},s:function(){return"másodperc"},ms:function(){return"ezredmásodperc"},decimal:","},id:{y:function(){return"tahun"},mo:function(){return"bulan"},w:function(){return"minggu"},d:function(){return"hari"},h:function(){return"jam"},m:function(){return"menit"},s:function(){return"detik"},ms:function(){return"milidetik"},decimal:"."},is:{y:function(){return"ár"},mo:function(t){return"mánuð"+(1===t?"ur":"ir")},w:function(t){return"vik"+(1===t?"a":"ur")},d:function(t){return"dag"+(1===t?"ur":"ar")},h:function(t){return"klukkutím"+(1===t?"i":"ar")},m:function(t){return"mínút"+(1===t?"a":"ur")},s:function(t){return"sekúnd"+(1===t?"a":"ur")},ms:function(t){return"millisekúnd"+(1===t?"a":"ur")},decimal:"."},it:{y:function(t){return"ann"+(1===t?"o":"i")},mo:function(t){return"mes"+(1===t?"e":"i")},w:function(t){return"settiman"+(1===t?"a":"e")},d:function(t){return"giorn"+(1===t?"o":"i")},h:function(t){return"or"+(1===t?"a":"e")},m:function(t){return"minut"+(1===t?"o":"i")},s:function(t){return"second"+(1===t?"o":"i")},ms:function(t){return"millisecond"+(1===t?"o":"i")},decimal:","},ja:{y:function(){return"年"},mo:function(){return"月"},w:function(){return"週"},d:function(){return"日"},h:function(){return"時間"},m:function(){return"分"},s:function(){return"秒"},ms:function(){return"ミリ秒"},decimal:"."},ko:{y:function(){return"년"},mo:function(){return"개월"},w:function(){return"주일"},d:function(){return"일"},h:function(){return"시간"},m:function(){return"분"},s:function(){return"초"},ms:function(){return"밀리 초"},decimal:"."},lo:{y:function(){return"ປີ"},mo:function(){return"ເດືອນ"},w:function(){return"ອາທິດ"},d:function(){return"ມື້"},h:function(){return"ຊົ່ວໂມງ"},m:function(){return"ນາທີ"},s:function(){return"ວິນາທີ"},ms:function(){return"ມິນລິວິນາທີ"},decimal:","},lt:{y:function(t){return t%10==0||t%100>=10&&t%100<=20?"metų":"metai"},mo:function(e){return["mėnuo","mėnesiai","mėnesių"][t.getLithuanianForm(e)]},w:function(e){return["savaitė","savaitės","savaičių"][t.getLithuanianForm(e)]},d:function(e){return["diena","dienos","dienų"][t.getLithuanianForm(e)]},h:function(e){return["valanda","valandos","valandų"][t.getLithuanianForm(e)]},m:function(e){return["minutė","minutės","minučių"][t.getLithuanianForm(e)]},s:function(e){return["sekundė","sekundės","sekundžių"][t.getLithuanianForm(e)]},ms:function(e){return["milisekundė","milisekundės","milisekundžių"][t.getLithuanianForm(e)]},decimal:","},lv:{y:function(e){return["gads","gadi"][t.getLatvianForm(e)]},mo:function(e){return["mēnesis","mēneši"][t.getLatvianForm(e)]},w:function(e){return["nedēļa","nedēļas"][t.getLatvianForm(e)]},d:function(e){return["diena","dienas"][t.getLatvianForm(e)]},h:function(e){return["stunda","stundas"][t.getLatvianForm(e)]},m:function(e){return["minūte","minūtes"][t.getLatvianForm(e)]},s:function(e){return["sekunde","sekundes"][t.getLatvianForm(e)]},ms:function(e){return["milisekunde","milisekundes"][t.getLatvianForm(e)]},decimal:","},ms:{y:function(){return"tahun"},mo:function(){return"bulan"},w:function(){return"minggu"},d:function(){return"hari"},h:function(){return"jam"},m:function(){return"minit"},s:function(){return"saat"},ms:function(){return"milisaat"},decimal:"."},nl:{y:function(){return"jaar"},mo:function(t){return 1===t?"maand":"maanden"},w:function(t){return 1===t?"week":"weken"},d:function(t){return 1===t?"dag":"dagen"},h:function(){return"uur"},m:function(t){return 1===t?"minuut":"minuten"},s:function(t){return 1===t?"seconde":"seconden"},ms:function(t){return 1===t?"milliseconde":"milliseconden"},decimal:","},no:{y:function(){return"år"},mo:function(t){return"måned"+(1===t?"":"er")},w:function(t){return"uke"+(1===t?"":"r")},d:function(t){return"dag"+(1===t?"":"er")},h:function(t){return"time"+(1===t?"":"r")},m:function(t){return"minutt"+(1===t?"":"er")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},pl:{y:function(e){return["rok","roku","lata","lat"][t.getPolishForm(e)]},mo:function(e){return["miesiąc","miesiąca","miesiące","miesięcy"][t.getPolishForm(e)]},w:function(e){return["tydzień","tygodnia","tygodnie","tygodni"][t.getPolishForm(e)]},d:function(e){return["dzień","dnia","dni","dni"][t.getPolishForm(e)]},h:function(e){return["godzina","godziny","godziny","godzin"][t.getPolishForm(e)]},m:function(e){return["minuta","minuty","minuty","minut"][t.getPolishForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekund"][t.getPolishForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekund"][t.getPolishForm(e)]},decimal:","},pt:{y:function(t){return"ano"+(1===t?"":"s")},mo:function(t){return 1===t?"mês":"meses"},w:function(t){return"semana"+(1===t?"":"s")},d:function(t){return"dia"+(1===t?"":"s")},h:function(t){return"hora"+(1===t?"":"s")},m:function(t){return"minuto"+(1===t?"":"s")},s:function(t){return"segundo"+(1===t?"":"s")},ms:function(t){return"milissegundo"+(1===t?"":"s")},decimal:","},ro:{y:function(t){return 1===t?"an":"ani"},mo:function(t){return 1===t?"lună":"luni"},w:function(t){return 1===t?"săptămână":"săptămâni"},d:function(t){return 1===t?"zi":"zile"},h:function(t){return 1===t?"oră":"ore"},m:function(t){return 1===t?"minut":"minute"},s:function(t){return 1===t?"secundă":"secunde"},ms:function(t){return 1===t?"milisecundă":"milisecunde"},decimal:","},ru:{y:function(e){return["лет","год","года"][t.getSlavicForm(e)]},mo:function(e){return["месяцев","месяц","месяца"][t.getSlavicForm(e)]},w:function(e){return["недель","неделя","недели"][t.getSlavicForm(e)]},d:function(e){return["дней","день","дня"][t.getSlavicForm(e)]},h:function(e){return["часов","час","часа"][t.getSlavicForm(e)]},m:function(e){return["минут","минута","минуты"][t.getSlavicForm(e)]},s:function(e){return["секунд","секунда","секунды"][t.getSlavicForm(e)]},ms:function(e){return["миллисекунд","миллисекунда","миллисекунды"][t.getSlavicForm(e)]},decimal:","},uk:{y:function(e){return["років","рік","роки"][t.getSlavicForm(e)]},mo:function(e){return["місяців","місяць","місяці"][t.getSlavicForm(e)]},w:function(e){return["тижнів","тиждень","тижні"][t.getSlavicForm(e)]},d:function(e){return["днів","день","дні"][t.getSlavicForm(e)]},h:function(e){return["годин","година","години"][t.getSlavicForm(e)]},m:function(e){return["хвилин","хвилина","хвилини"][t.getSlavicForm(e)]},s:function(e){return["секунд","секунда","секунди"][t.getSlavicForm(e)]},ms:function(e){return["мілісекунд","мілісекунда","мілісекунди"][t.getSlavicForm(e)]},decimal:","},ur:{y:function(){return"سال"},mo:function(t){return 1===t?"مہینہ":"مہینے"},w:function(t){return 1===t?"ہفتہ":"ہفتے"},d:function(){return"دن"},h:function(t){return 1===t?"گھنٹہ":"گھنٹے"},m:function(){return"منٹ"},s:function(){return"سیکنڈ"},ms:function(){return"ملی سیکنڈ"},decimal:"."},sk:{y:function(e){return["rok","roky","roky","rokov"][t.getCzechOrSlovakForm(e)]},mo:function(e){return["mesiac","mesiace","mesiace","mesiacov"][t.getCzechOrSlovakForm(e)]},w:function(e){return["týždeň","týždne","týždne","týždňov"][t.getCzechOrSlovakForm(e)]},d:function(e){return["deň","dni","dni","dní"][t.getCzechOrSlovakForm(e)]},h:function(e){return["hodina","hodiny","hodiny","hodín"][t.getCzechOrSlovakForm(e)]},m:function(e){return["minúta","minúty","minúty","minút"][t.getCzechOrSlovakForm(e)]},s:function(e){return["sekunda","sekundy","sekundy","sekúnd"][t.getCzechOrSlovakForm(e)]},ms:function(e){return["milisekunda","milisekundy","milisekundy","milisekúnd"][t.getCzechOrSlovakForm(e)]},decimal:","},sv:{y:function(){return"år"},mo:function(t){return"månad"+(1===t?"":"er")},w:function(t){return"veck"+(1===t?"a":"or")},d:function(t){return"dag"+(1===t?"":"ar")},h:function(t){return"timm"+(1===t?"e":"ar")},m:function(t){return"minut"+(1===t?"":"er")},s:function(t){return"sekund"+(1===t?"":"er")},ms:function(t){return"millisekund"+(1===t?"":"er")},decimal:","},tr:{y:function(){return"yıl"},mo:function(){return"ay"},w:function(){return"hafta"},d:function(){return"gün"},h:function(){return"saat"},m:function(){return"dakika"},s:function(){return"saniye"},ms:function(){return"milisaniye"},decimal:","},th:{y:function(){return"ปี"},mo:function(){return"เดือน"},w:function(){return"อาทิตย์"},d:function(){return"วัน"},h:function(){return"ชั่วโมง"},m:function(){return"นาที"},s:function(){return"วินาที"},ms:function(){return"มิลลิวินาที"},decimal:"."},vi:{y:function(){return"năm"},mo:function(){return"tháng"},w:function(){return"tuần"},d:function(){return"ngày"},h:function(){return"giờ"},m:function(){return"phút"},s:function(){return"giây"},ms:function(){return"mili giây"},decimal:","},zh_CN:{y:function(){return"年"},mo:function(){return"个月"},w:function(){return"周"},d:function(){return"天"},h:function(){return"小时"},m:function(){return"分钟"},s:function(){return"秒"},ms:function(){return"毫秒"},decimal:"."},zh_TW:{y:function(){return"年"},mo:function(){return"個月"},w:function(){return"周"},d:function(){return"天"},h:function(){return"小時"},m:function(){return"分鐘"},s:function(){return"秒"},ms:function(){return"毫秒"},decimal:"."}}}return t.prototype.addLanguage=function(t,e){this.languages[t]=e},t.prototype.getCzechForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&t%100<10?2:3},t.prototype.getPolishForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&!(t%100>10&&t%100<20)?2:3},t.prototype.getSlavicForm=function(t){return Math.floor(t)!==t?2:t>=5&&t<=20||t%10>=5&&t%10<=9||t%10==0?0:t%10==1?1:t>1?2:0},t.prototype.getLithuanianForm=function(t){return 1===t||t%10==1&&t%100>20?0:Math.floor(t)!==t||t%10>=2&&t%100>20||t%10>=2&&t%100<10?1:2},t.prototype.getArabicForm=function(t){return t<=2?0:t>2&&t<11?1:0},t.prototype.getCzechOrSlovakForm=function(t){return 1===t?0:Math.floor(t)!==t?1:t%10>=2&&t%10<=4&&t%100<10?2:3},t.prototype.getLatvianForm=function(t){return 1===t||t%10==1&&t%100!=11?0:1},t}(),Bt=function(){function t(t){this.languageUtil=t,this.defaultOptions={language:"en",delimiter:", ",spacer:" ",conjunction:"",serialComma:!0,units:["y","mo","w","d","h","m","s"],languages:{},largest:10,decimal:".",round:!1,unitMeasures:{y:315576e5,mo:26298e5,w:6048e5,d:864e5,h:36e5,m:6e4,s:1e3,ms:1}},this.options=void 0,this.options=this.defaultOptions}return t.prototype.humanize=function(t,e){var i=void 0!==e?this.extend(this.options,e):this.defaultOptions;return this.doHumanization(t,i)},t.prototype.setOptions=function(t){this.options=void 0!==t?this.extend(this.defaultOptions,t):this.defaultOptions},t.prototype.getSupportedLanguages=function(){var t=[];for(var e in this.languageUtil.languages)this.languageUtil.languages.hasOwnProperty(e)&&t.push(e);return t},t.prototype.addLanguage=function(t,e){this.languageUtil.addLanguage(t,e)},t.prototype.doHumanization=function(t,e){var i,n,o;t=Math.abs(t);var s=e.languages[e.language]||this.languageUtil.languages[e.language];if(!s)throw new Error("No language "+s+".");var r,a,l,c=[];for(i=0,n=e.units.length;i<n;i++)r=e.units[i],a=e.unitMeasures[r],l=i+1===n?t/a:Math.floor(t/a),c.push({unitCount:l,unitName:r}),t-=l*a;var h=0;for(i=0;i<c.length;i++)if(c[i].unitCount){h=i;break}if(e.round){var d=void 0,u=void 0;for(i=c.length-1;i>=0&&((o=c[i]).unitCount=Math.round(o.unitCount),0!==i);i--)u=c[i-1],d=e.unitMeasures[u.unitName]/e.unitMeasures[o.unitName],(o.unitCount%d==0||e.largest&&e.largest-1<i-h)&&(u.unitCount+=o.unitCount/d,o.unitCount=0)}var p=[];for(i=0,c.length;i<n&&((o=c[i]).unitCount&&p.push(this.render(o.unitCount,o.unitName,s,e)),p.length!==e.largest);i++);return p.length?e.conjunction&&1!==p.length?2===p.length?p.join(e.conjunction):p.length>2?p.slice(0,-1).join(e.delimiter)+(e.serialComma?",":"")+e.conjunction+p.slice(-1):void 0:p.join(e.delimiter):this.render(0,e.units[e.units.length-1],s,e)},t.prototype.render=function(t,e,i,n){var o;o=void 0===n.decimal?i.decimal:n.decimal;var s=t.toString().replace(".",o.toString()),r=i[e](t);return s+n.spacer+r},t.prototype.extend=function(t,e){for(var i in e)t.hasOwnProperty(i)&&(t[i]=e[i]);return t},t}();class qt extends Error{}class Ft extends qt{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}}class Zt extends qt{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}}class Ut extends qt{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}}class Vt extends qt{}class jt extends qt{constructor(t){super(`Invalid unit ${t}`)}}class Ht extends qt{}class Gt extends qt{constructor(){super("Zone is an abstract class")}}const Wt="numeric",Kt="short",Yt="long",Jt={year:Wt,month:Wt,day:Wt},Xt={year:Wt,month:Kt,day:Wt},Qt={year:Wt,month:Kt,day:Wt,weekday:Kt},te={year:Wt,month:Yt,day:Wt},ee={year:Wt,month:Yt,day:Wt,weekday:Yt},ie={hour:Wt,minute:Wt},ne={hour:Wt,minute:Wt,second:Wt},oe={hour:Wt,minute:Wt,second:Wt,timeZoneName:Kt},se={hour:Wt,minute:Wt,second:Wt,timeZoneName:Yt},re={hour:Wt,minute:Wt,hourCycle:"h23"},ae={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23"},le={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23",timeZoneName:Kt},ce={hour:Wt,minute:Wt,second:Wt,hourCycle:"h23",timeZoneName:Yt},he={year:Wt,month:Wt,day:Wt,hour:Wt,minute:Wt},de={year:Wt,month:Wt,day:Wt,hour:Wt,minute:Wt,second:Wt},ue={year:Wt,month:Kt,day:Wt,hour:Wt,minute:Wt},pe={year:Wt,month:Kt,day:Wt,hour:Wt,minute:Wt,second:Wt},me={year:Wt,month:Kt,day:Wt,weekday:Kt,hour:Wt,minute:Wt},fe={year:Wt,month:Yt,day:Wt,hour:Wt,minute:Wt,timeZoneName:Kt},ge={year:Wt,month:Yt,day:Wt,hour:Wt,minute:Wt,second:Wt,timeZoneName:Kt},ve={year:Wt,month:Yt,day:Wt,weekday:Yt,hour:Wt,minute:Wt,timeZoneName:Yt},ye={year:Wt,month:Yt,day:Wt,weekday:Yt,hour:Wt,minute:Wt,second:Wt,timeZoneName:Yt};function be(t){return void 0===t}function _e(t){return"number"==typeof t}function xe(t){return"number"==typeof t&&t%1==0}function we(){try{return"undefined"!=typeof Intl&&!!Intl.RelativeTimeFormat}catch(t){return!1}}function ke(t,e,i){if(0!==t.length)return t.reduce(((t,n)=>{const o=[e(n),n];return t&&i(t[0],o[0])===t[0]?t:o}),null)[1]}function Se(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Ce(t,e,i){return xe(t)&&t>=e&&t<=i}function Ee(t,e=2){let i;return i=t<0?"-"+(""+-t).padStart(e,"0"):(""+t).padStart(e,"0"),i}function Te(t){return be(t)||null===t||""===t?void 0:parseInt(t,10)}function $e(t){return be(t)||null===t||""===t?void 0:parseFloat(t)}function Le(t){if(!be(t)&&null!==t&&""!==t){const e=1e3*parseFloat("0."+t);return Math.floor(e)}}function Oe(t,e,i=!1){const n=10**e;return(i?Math.trunc:Math.round)(t*n)/n}function Ae(t){return t%4==0&&(t%100!=0||t%400==0)}function Me(t){return Ae(t)?366:365}function Pe(t,e){const i=function(t,e){return t-e*Math.floor(t/e)}(e-1,12)+1;return 2===i?Ae(t+(e-i)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][i-1]}function ze(t){let e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(e.getUTCFullYear()-1900)),+e}function Ie(t){const e=(t+Math.floor(t/4)-Math.floor(t/100)+Math.floor(t/400))%7,i=t-1,n=(i+Math.floor(i/4)-Math.floor(i/100)+Math.floor(i/400))%7;return 4===e||3===n?53:52}function De(t){return t>99?t:t>60?1900+t:2e3+t}function Ne(t,e,i,n=null){const o=new Date(t),s={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};n&&(s.timeZone=n);const r={timeZoneName:e,...s},a=new Intl.DateTimeFormat(i,r).formatToParts(o).find((t=>"timezonename"===t.type.toLowerCase()));return a?a.value:null}function Re(t,e){let i=parseInt(t,10);Number.isNaN(i)&&(i=0);const n=parseInt(e,10)||0;return 60*i+(i<0||Object.is(i,-0)?-n:n)}function Be(t){const e=Number(t);if("boolean"==typeof t||""===t||Number.isNaN(e))throw new Ht(`Invalid unit value ${t}`);return e}function qe(t,e){const i={};for(const n in t)if(Se(t,n)){const o=t[n];if(null==o)continue;i[e(n)]=Be(o)}return i}function Fe(t,e){const i=Math.trunc(Math.abs(t/60)),n=Math.trunc(Math.abs(t%60)),o=t>=0?"+":"-";switch(e){case"short":return`${o}${Ee(i,2)}:${Ee(n,2)}`;case"narrow":return`${o}${i}${n>0?`:${n}`:""}`;case"techie":return`${o}${Ee(i,2)}${Ee(n,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function Ze(t){return function(t,e){return e.reduce(((e,i)=>(e[i]=t[i],e)),{})}(t,["hour","minute","second","millisecond"])}const Ue=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/,Ve=["January","February","March","April","May","June","July","August","September","October","November","December"],je=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],He=["J","F","M","A","M","J","J","A","S","O","N","D"];function Ge(t){switch(t){case"narrow":return[...He];case"short":return[...je];case"long":return[...Ve];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const We=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],Ke=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Ye=["M","T","W","T","F","S","S"];function Je(t){switch(t){case"narrow":return[...Ye];case"short":return[...Ke];case"long":return[...We];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const Xe=["AM","PM"],Qe=["Before Christ","Anno Domini"],ti=["BC","AD"],ei=["B","A"];function ii(t){switch(t){case"narrow":return[...ei];case"short":return[...ti];case"long":return[...Qe];default:return null}}function ni(t,e){let i="";for(const n of t)n.literal?i+=n.val:i+=e(n.val);return i}const oi={D:Jt,DD:Xt,DDD:te,DDDD:ee,t:ie,tt:ne,ttt:oe,tttt:se,T:re,TT:ae,TTT:le,TTTT:ce,f:he,ff:ue,fff:fe,ffff:ve,F:de,FF:pe,FFF:ge,FFFF:ye};class si{static create(t,e={}){return new si(t,e)}static parseFormat(t){let e=null,i="",n=!1;const o=[];for(let s=0;s<t.length;s++){const r=t.charAt(s);"'"===r?(i.length>0&&o.push({literal:n,val:i}),e=null,i="",n=!n):n||r===e?i+=r:(i.length>0&&o.push({literal:!1,val:i}),i=r,e=r)}return i.length>0&&o.push({literal:n,val:i}),o}static macroTokenToFormatOpts(t){return oi[t]}constructor(t,e){this.opts=e,this.loc=t,this.systemLoc=null}formatWithSystemDefault(t,e){null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem());return this.systemLoc.dtFormatter(t,{...this.opts,...e}).format()}formatDateTime(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).format()}formatDateTimeParts(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).formatToParts()}resolvedOptions(t,e={}){return this.loc.dtFormatter(t,{...this.opts,...e}).resolvedOptions()}num(t,e=0){if(this.opts.forceSimple)return Ee(t,e);const i={...this.opts};return e>0&&(i.padTo=e),this.loc.numberFormatter(i).format(t)}formatDateTimeFromString(t,e){const i="en"===this.loc.listingMode(),n=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,o=(e,i)=>this.loc.extract(t,e,i),s=e=>t.isOffsetFixed&&0===t.offset&&e.allowZ?"Z":t.isValid?t.zone.formatOffset(t.ts,e.format):"",r=()=>i?function(t){return Xe[t.hour<12?0:1]}(t):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),a=(e,n)=>i?function(t,e){return Ge(e)[t.month-1]}(t,e):o(n?{month:e}:{month:e,day:"numeric"},"month"),l=(e,n)=>i?function(t,e){return Je(e)[t.weekday-1]}(t,e):o(n?{weekday:e}:{weekday:e,month:"long",day:"numeric"},"weekday"),c=e=>{const i=si.macroTokenToFormatOpts(e);return i?this.formatWithSystemDefault(t,i):e},h=e=>i?function(t,e){return ii(e)[t.year<0?0:1]}(t,e):o({era:e},"era");return ni(si.parseFormat(e),(e=>{switch(e){case"S":return this.num(t.millisecond);case"u":case"SSS":return this.num(t.millisecond,3);case"s":return this.num(t.second);case"ss":return this.num(t.second,2);case"uu":return this.num(Math.floor(t.millisecond/10),2);case"uuu":return this.num(Math.floor(t.millisecond/100));case"m":return this.num(t.minute);case"mm":return this.num(t.minute,2);case"h":return this.num(t.hour%12==0?12:t.hour%12);case"hh":return this.num(t.hour%12==0?12:t.hour%12,2);case"H":return this.num(t.hour);case"HH":return this.num(t.hour,2);case"Z":return s({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return s({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return s({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return t.zone.offsetName(t.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return t.zone.offsetName(t.ts,{format:"long",locale:this.loc.locale});case"z":return t.zoneName;case"a":return r();case"d":return n?o({day:"numeric"},"day"):this.num(t.day);case"dd":return n?o({day:"2-digit"},"day"):this.num(t.day,2);case"c":case"E":return this.num(t.weekday);case"ccc":return l("short",!0);case"cccc":return l("long",!0);case"ccccc":return l("narrow",!0);case"EEE":return l("short",!1);case"EEEE":return l("long",!1);case"EEEEE":return l("narrow",!1);case"L":return n?o({month:"numeric",day:"numeric"},"month"):this.num(t.month);case"LL":return n?o({month:"2-digit",day:"numeric"},"month"):this.num(t.month,2);case"LLL":return a("short",!0);case"LLLL":return a("long",!0);case"LLLLL":return a("narrow",!0);case"M":return n?o({month:"numeric"},"month"):this.num(t.month);case"MM":return n?o({month:"2-digit"},"month"):this.num(t.month,2);case"MMM":return a("short",!1);case"MMMM":return a("long",!1);case"MMMMM":return a("narrow",!1);case"y":return n?o({year:"numeric"},"year"):this.num(t.year);case"yy":return n?o({year:"2-digit"},"year"):this.num(t.year.toString().slice(-2),2);case"yyyy":return n?o({year:"numeric"},"year"):this.num(t.year,4);case"yyyyyy":return n?o({year:"numeric"},"year"):this.num(t.year,6);case"G":return h("short");case"GG":return h("long");case"GGGGG":return h("narrow");case"kk":return this.num(t.weekYear.toString().slice(-2),2);case"kkkk":return this.num(t.weekYear,4);case"W":return this.num(t.weekNumber);case"WW":return this.num(t.weekNumber,2);case"o":return this.num(t.ordinal);case"ooo":return this.num(t.ordinal,3);case"q":return this.num(t.quarter);case"qq":return this.num(t.quarter,2);case"X":return this.num(Math.floor(t.ts/1e3));case"x":return this.num(t.ts);default:return c(e)}}))}formatDurationFromString(t,e){const i=t=>{switch(t[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},n=si.parseFormat(e),o=n.reduce(((t,{literal:e,val:i})=>e?t:t.concat(i)),[]),s=t.shiftTo(...o.map(i).filter((t=>t)));return ni(n,(t=>e=>{const n=i(e);return n?this.num(t.get(n),e.length):e})(s))}}class ri{constructor(t,e){this.reason=t,this.explanation=e}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}class ai{get type(){throw new Gt}get name(){throw new Gt}get ianaName(){return this.name}get isUniversal(){throw new Gt}offsetName(t,e){throw new Gt}formatOffset(t,e){throw new Gt}offset(t){throw new Gt}equals(t){throw new Gt}get isValid(){throw new Gt}}let li=null;class ci extends ai{static get instance(){return null===li&&(li=new ci),li}get type(){return"system"}get name(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(t,{format:e,locale:i}){return Ne(t,e,i)}formatOffset(t,e){return Fe(this.offset(t),e)}offset(t){return-new Date(t).getTimezoneOffset()}equals(t){return"system"===t.type}get isValid(){return!0}}let hi={};const di={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};let ui={};class pi extends ai{static create(t){return ui[t]||(ui[t]=new pi(t)),ui[t]}static resetCache(){ui={},hi={}}static isValidSpecifier(t){return this.isValidZone(t)}static isValidZone(t){if(!t)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:t}).format(),!0}catch(t){return!1}}constructor(t){super(),this.zoneName=t,this.valid=pi.isValidZone(t)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(t,{format:e,locale:i}){return Ne(t,e,i,this.name)}formatOffset(t,e){return Fe(this.offset(t),e)}offset(t){const e=new Date(t);if(isNaN(e))return NaN;const i=(n=this.name,hi[n]||(hi[n]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:n,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),hi[n]);var n;let[o,s,r,a,l,c,h]=i.formatToParts?function(t,e){const i=t.formatToParts(e),n=[];for(let t=0;t<i.length;t++){const{type:e,value:o}=i[t],s=di[e];"era"===e?n[s]=o:be(s)||(n[s]=parseInt(o,10))}return n}(i,e):function(t,e){const i=t.format(e).replace(/\u200E/g,""),n=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(i),[,o,s,r,a,l,c,h]=n;return[r,o,s,a,l,c,h]}(i,e);"BC"===a&&(o=1-Math.abs(o));let d=+e;const u=d%1e3;return d-=u>=0?u:1e3+u,(ze({year:o,month:s,day:r,hour:24===l?0:l,minute:c,second:h,millisecond:0})-d)/6e4}equals(t){return"iana"===t.type&&t.name===this.name}get isValid(){return this.valid}}let mi=null;class fi extends ai{static get utcInstance(){return null===mi&&(mi=new fi(0)),mi}static instance(t){return 0===t?fi.utcInstance:new fi(t)}static parseSpecifier(t){if(t){const e=t.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(e)return new fi(Re(e[1],e[2]))}return null}constructor(t){super(),this.fixed=t}get type(){return"fixed"}get name(){return 0===this.fixed?"UTC":`UTC${Fe(this.fixed,"narrow")}`}get ianaName(){return 0===this.fixed?"Etc/UTC":`Etc/GMT${Fe(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(t,e){return Fe(this.fixed,e)}get isUniversal(){return!0}offset(){return this.fixed}equals(t){return"fixed"===t.type&&t.fixed===this.fixed}get isValid(){return!0}}class gi extends ai{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function vi(t,e){if(be(t)||null===t)return e;if(t instanceof ai)return t;if(function(t){return"string"==typeof t}(t)){const i=t.toLowerCase();return"local"===i||"system"===i?e:"utc"===i||"gmt"===i?fi.utcInstance:fi.parseSpecifier(i)||pi.create(t)}return _e(t)?fi.instance(t):"object"==typeof t&&t.offset&&"number"==typeof t.offset?t:new gi(t)}let yi,bi=()=>Date.now(),_i="system",xi=null,wi=null,ki=null;class Si{static get now(){return bi}static set now(t){bi=t}static set defaultZone(t){_i=t}static get defaultZone(){return vi(_i,ci.instance)}static get defaultLocale(){return xi}static set defaultLocale(t){xi=t}static get defaultNumberingSystem(){return wi}static set defaultNumberingSystem(t){wi=t}static get defaultOutputCalendar(){return ki}static set defaultOutputCalendar(t){ki=t}static get throwOnInvalid(){return yi}static set throwOnInvalid(t){yi=t}static resetCaches(){Ii.resetCache(),pi.resetCache()}}let Ci={};let Ei={};function Ti(t,e={}){const i=JSON.stringify([t,e]);let n=Ei[i];return n||(n=new Intl.DateTimeFormat(t,e),Ei[i]=n),n}let $i={};let Li={};let Oi=null;function Ai(t,e,i,n,o){const s=t.listingMode(i);return"error"===s?null:"en"===s?n(e):o(e)}class Mi{constructor(t,e,i){this.padTo=i.padTo||0,this.floor=i.floor||!1;const{padTo:n,floor:o,...s}=i;if(!e||Object.keys(s).length>0){const e={useGrouping:!1,...i};i.padTo>0&&(e.minimumIntegerDigits=i.padTo),this.inf=function(t,e={}){const i=JSON.stringify([t,e]);let n=$i[i];return n||(n=new Intl.NumberFormat(t,e),$i[i]=n),n}(t,e)}}format(t){if(this.inf){const e=this.floor?Math.floor(t):t;return this.inf.format(e)}return Ee(this.floor?Math.floor(t):Oe(t,3),this.padTo)}}class Pi{constructor(t,e,i){let n;if(this.opts=i,t.zone.isUniversal){const e=t.offset/60*-1,o=e>=0?`Etc/GMT+${e}`:`Etc/GMT${e}`;0!==t.offset&&pi.create(o).valid?(n=o,this.dt=t):(n="UTC",i.timeZoneName?this.dt=t:this.dt=0===t.offset?t:Po.fromMillis(t.ts+60*t.offset*1e3))}else"system"===t.zone.type?this.dt=t:(this.dt=t,n=t.zone.name);const o={...this.opts};n&&(o.timeZone=n),this.dtf=Ti(e,o)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class zi{constructor(t,e,i){this.opts={style:"long",...i},!e&&we()&&(this.rtf=function(t,e={}){const{base:i,...n}=e,o=JSON.stringify([t,n]);let s=Li[o];return s||(s=new Intl.RelativeTimeFormat(t,e),Li[o]=s),s}(t,i))}format(t,e){return this.rtf?this.rtf.format(t,e):function(t,e,i="always",n=!1){const o={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},s=-1===["hours","minutes","seconds"].indexOf(t);if("auto"===i&&s){const i="days"===t;switch(e){case 1:return i?"tomorrow":`next ${o[t][0]}`;case-1:return i?"yesterday":`last ${o[t][0]}`;case 0:return i?"today":`this ${o[t][0]}`}}const r=Object.is(e,-0)||e<0,a=Math.abs(e),l=1===a,c=o[t],h=n?l?c[1]:c[2]||c[1]:l?o[t][0]:t;return r?`${a} ${h} ago`:`in ${a} ${h}`}(e,t,this.opts.numeric,"long"!==this.opts.style)}formatToParts(t,e){return this.rtf?this.rtf.formatToParts(t,e):[]}}class Ii{static fromOpts(t){return Ii.create(t.locale,t.numberingSystem,t.outputCalendar,t.defaultToEN)}static create(t,e,i,n=!1){const o=t||Si.defaultLocale,s=o||(n?"en-US":Oi||(Oi=(new Intl.DateTimeFormat).resolvedOptions().locale,Oi)),r=e||Si.defaultNumberingSystem,a=i||Si.defaultOutputCalendar;return new Ii(s,r,a,o)}static resetCache(){Oi=null,Ei={},$i={},Li={}}static fromObject({locale:t,numberingSystem:e,outputCalendar:i}={}){return Ii.create(t,e,i)}constructor(t,e,i,n){const[o,s,r]=function(t){const e=t.indexOf("-u-");if(-1===e)return[t];{let i;const n=t.substring(0,e);try{i=Ti(t).resolvedOptions()}catch(t){i=Ti(n).resolvedOptions()}const{numberingSystem:o,calendar:s}=i;return[n,o,s]}}(t);this.locale=o,this.numberingSystem=e||s||null,this.outputCalendar=i||r||null,this.intl=function(t,e,i){return i||e?(t+="-u",i&&(t+=`-ca-${i}`),e&&(t+=`-nu-${e}`),t):t}(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=n,this.fastNumbersCached=null}get fastNumbers(){var t;return null==this.fastNumbersCached&&(this.fastNumbersCached=(!(t=this).numberingSystem||"latn"===t.numberingSystem)&&("latn"===t.numberingSystem||!t.locale||t.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(t.intl).resolvedOptions().numberingSystem)),this.fastNumbersCached}listingMode(){const t=this.isEnglish(),e=!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar);return t&&e?"en":"intl"}clone(t){return t&&0!==Object.getOwnPropertyNames(t).length?Ii.create(t.locale||this.specifiedLocale,t.numberingSystem||this.numberingSystem,t.outputCalendar||this.outputCalendar,t.defaultToEN||!1):this}redefaultToEN(t={}){return this.clone({...t,defaultToEN:!0})}redefaultToSystem(t={}){return this.clone({...t,defaultToEN:!1})}months(t,e=!1,i=!0){return Ai(this,t,i,Ge,(()=>{const i=e?{month:t,day:"numeric"}:{month:t},n=e?"format":"standalone";return this.monthsCache[n][t]||(this.monthsCache[n][t]=function(t){const e=[];for(let i=1;i<=12;i++){const n=Po.utc(2016,i,1);e.push(t(n))}return e}((t=>this.extract(t,i,"month")))),this.monthsCache[n][t]}))}weekdays(t,e=!1,i=!0){return Ai(this,t,i,Je,(()=>{const i=e?{weekday:t,year:"numeric",month:"long",day:"numeric"}:{weekday:t},n=e?"format":"standalone";return this.weekdaysCache[n][t]||(this.weekdaysCache[n][t]=function(t){const e=[];for(let i=1;i<=7;i++){const n=Po.utc(2016,11,13+i);e.push(t(n))}return e}((t=>this.extract(t,i,"weekday")))),this.weekdaysCache[n][t]}))}meridiems(t=!0){return Ai(this,void 0,t,(()=>Xe),(()=>{if(!this.meridiemCache){const t={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Po.utc(2016,11,13,9),Po.utc(2016,11,13,19)].map((e=>this.extract(e,t,"dayperiod")))}return this.meridiemCache}))}eras(t,e=!0){return Ai(this,t,e,ii,(()=>{const e={era:t};return this.eraCache[t]||(this.eraCache[t]=[Po.utc(-40,1,1),Po.utc(2017,1,1)].map((t=>this.extract(t,e,"era")))),this.eraCache[t]}))}extract(t,e,i){const n=this.dtFormatter(t,e).formatToParts().find((t=>t.type.toLowerCase()===i));return n?n.value:null}numberFormatter(t={}){return new Mi(this.intl,t.forceSimple||this.fastNumbers,t)}dtFormatter(t,e={}){return new Pi(t,this.intl,e)}relFormatter(t={}){return new zi(this.intl,this.isEnglish(),t)}listFormatter(t={}){return function(t,e={}){const i=JSON.stringify([t,e]);let n=Ci[i];return n||(n=new Intl.ListFormat(t,e),Ci[i]=n),n}(this.intl,t)}isEnglish(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(t){return this.locale===t.locale&&this.numberingSystem===t.numberingSystem&&this.outputCalendar===t.outputCalendar}}function Di(...t){const e=t.reduce(((t,e)=>t+e.source),"");return RegExp(`^${e}$`)}function Ni(...t){return e=>t.reduce((([t,i,n],o)=>{const[s,r,a]=o(e,n);return[{...t,...s},r||i,a]}),[{},null,1]).slice(0,2)}function Ri(t,...e){if(null==t)return[null,null];for(const[i,n]of e){const e=i.exec(t);if(e)return n(e)}return[null,null]}function Bi(...t){return(e,i)=>{const n={};let o;for(o=0;o<t.length;o++)n[t[o]]=Te(e[i+o]);return[n,null,i+o]}}const qi=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,Fi=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Zi=RegExp(`${Fi.source}${`(?:${qi.source}?(?:\\[(${Ue.source})\\])?)?`}`),Ui=RegExp(`(?:T${Zi.source})?`),Vi=Bi("weekYear","weekNumber","weekDay"),ji=Bi("year","ordinal"),Hi=RegExp(`${Fi.source} ?(?:${qi.source}|(${Ue.source}))?`),Gi=RegExp(`(?: ${Hi.source})?`);function Wi(t,e,i){const n=t[e];return be(n)?i:Te(n)}function Ki(t,e){return[{hours:Wi(t,e,0),minutes:Wi(t,e+1,0),seconds:Wi(t,e+2,0),milliseconds:Le(t[e+3])},null,e+4]}function Yi(t,e){const i=!t[e]&&!t[e+1],n=Re(t[e+1],t[e+2]);return[{},i?null:fi.instance(n),e+3]}function Ji(t,e){return[{},t[e]?pi.create(t[e]):null,e+1]}const Xi=RegExp(`^T?${Fi.source}$`),Qi=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function tn(t){const[e,i,n,o,s,r,a,l,c]=t,h="-"===e[0],d=l&&"-"===l[0],u=(t,e=!1)=>void 0!==t&&(e||t&&h)?-t:t;return[{years:u($e(i)),months:u($e(n)),weeks:u($e(o)),days:u($e(s)),hours:u($e(r)),minutes:u($e(a)),seconds:u($e(l),"-0"===l),milliseconds:u(Le(c),d)}]}const en={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function nn(t,e,i,n,o,s,r){const a={year:2===e.length?De(Te(e)):Te(e),month:je.indexOf(i)+1,day:Te(n),hour:Te(o),minute:Te(s)};return r&&(a.second=Te(r)),t&&(a.weekday=t.length>3?We.indexOf(t)+1:Ke.indexOf(t)+1),a}const on=/^(?:(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\d)(\d\d)))$/;function sn(t){const[,e,i,n,o,s,r,a,l,c,h,d]=t,u=nn(e,o,n,i,s,r,a);let p;return p=l?en[l]:c?0:Re(h,d),[u,new fi(p)]}const rn=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,an=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,ln=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function cn(t){const[,e,i,n,o,s,r,a]=t;return[nn(e,o,n,i,s,r,a),fi.utcInstance]}function hn(t){const[,e,i,n,o,s,r,a]=t;return[nn(e,a,i,n,o,s,r),fi.utcInstance]}const dn=Di(/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ui),un=Di(/(\d{4})-?W(\d\d)(?:-?(\d))?/,Ui),pn=Di(/(\d{4})-?(\d{3})/,Ui),mn=Di(Zi),fn=Ni((function(t,e){return[{year:Wi(t,e),month:Wi(t,e+1,1),day:Wi(t,e+2,1)},null,e+3]}),Ki,Yi,Ji),gn=Ni(Vi,Ki,Yi,Ji),vn=Ni(ji,Ki,Yi,Ji),yn=Ni(Ki,Yi,Ji);const bn=Ni(Ki);const _n=Di(/(\d{4})-(\d\d)-(\d\d)/,Gi),xn=Di(Hi),wn=Ni(Ki,Yi,Ji);const kn={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},Sn={years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6},...kn},Cn={years:{quarters:4,months:12,weeks:52.1775,days:365.2425,hours:8765.82,minutes:525949.2,seconds:525949.2*60,milliseconds:525949.2*60*1e3},quarters:{months:3,weeks:13.044375,days:91.310625,hours:2191.455,minutes:131487.3,seconds:525949.2*60/4,milliseconds:7889237999.999999},months:{weeks:30.436875/7,days:30.436875,hours:730.485,minutes:43829.1,seconds:2629746,milliseconds:2629746e3},...kn},En=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Tn=En.slice(0).reverse();function $n(t,e,i=!1){const n={values:i?e.values:{...t.values,...e.values||{}},loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy};return new On(n)}function Ln(t,e,i,n,o){const s=t[o][i],r=e[i]/s,a=!(Math.sign(r)===Math.sign(n[o]))&&0!==n[o]&&Math.abs(r)<=1?function(t){return t<0?Math.floor(t):Math.ceil(t)}(r):Math.trunc(r);n[o]+=a,e[i]-=a*s}class On{constructor(t){const e="longterm"===t.conversionAccuracy||!1;this.values=t.values,this.loc=t.loc||Ii.create(),this.conversionAccuracy=e?"longterm":"casual",this.invalid=t.invalid||null,this.matrix=e?Cn:Sn,this.isLuxonDuration=!0}static fromMillis(t,e){return On.fromObject({milliseconds:t},e)}static fromObject(t,e={}){if(null==t||"object"!=typeof t)throw new Ht("Duration.fromObject: argument expected to be an object, got "+(null===t?"null":typeof t));return new On({values:qe(t,On.normalizeUnit),loc:Ii.fromObject(e),conversionAccuracy:e.conversionAccuracy})}static fromDurationLike(t){if(_e(t))return On.fromMillis(t);if(On.isDuration(t))return t;if("object"==typeof t)return On.fromObject(t);throw new Ht(`Unknown duration argument ${t} of type ${typeof t}`)}static fromISO(t,e){const[i]=function(t){return Ri(t,[Qi,tn])}(t);return i?On.fromObject(i,e):On.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static fromISOTime(t,e){const[i]=function(t){return Ri(t,[Xi,bn])}(t);return i?On.fromObject(i,e):On.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the Duration is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Ut(i);return new On({invalid:i})}static normalizeUnit(t){const e={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[t?t.toLowerCase():t];if(!e)throw new jt(t);return e}static isDuration(t){return t&&t.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(t,e={}){const i={...e,floor:!1!==e.round&&!1!==e.floor};return this.isValid?si.create(this.loc,i).formatDurationFromString(this,t):"Invalid Duration"}toHuman(t={}){const e=En.map((e=>{const i=this.values[e];return be(i)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...t,unit:e.slice(0,-1)}).format(i)})).filter((t=>t));return this.loc.listFormatter({type:"conjunction",style:t.listStyle||"narrow",...t}).format(e)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let t="P";return 0!==this.years&&(t+=this.years+"Y"),0===this.months&&0===this.quarters||(t+=this.months+3*this.quarters+"M"),0!==this.weeks&&(t+=this.weeks+"W"),0!==this.days&&(t+=this.days+"D"),0===this.hours&&0===this.minutes&&0===this.seconds&&0===this.milliseconds||(t+="T"),0!==this.hours&&(t+=this.hours+"H"),0!==this.minutes&&(t+=this.minutes+"M"),0===this.seconds&&0===this.milliseconds||(t+=Oe(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===t&&(t+="T0S"),t}toISOTime(t={}){if(!this.isValid)return null;const e=this.toMillis();if(e<0||e>=864e5)return null;t={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...t};const i=this.shiftTo("hours","minutes","seconds","milliseconds");let n="basic"===t.format?"hhmm":"hh:mm";t.suppressSeconds&&0===i.seconds&&0===i.milliseconds||(n+="basic"===t.format?"ss":":ss",t.suppressMilliseconds&&0===i.milliseconds||(n+=".SSS"));let o=i.toFormat(n);return t.includePrefix&&(o="T"+o),o}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(t){if(!this.isValid)return this;const e=On.fromDurationLike(t),i={};for(const t of En)(Se(e.values,t)||Se(this.values,t))&&(i[t]=e.get(t)+this.get(t));return $n(this,{values:i},!0)}minus(t){if(!this.isValid)return this;const e=On.fromDurationLike(t);return this.plus(e.negate())}mapUnits(t){if(!this.isValid)return this;const e={};for(const i of Object.keys(this.values))e[i]=Be(t(this.values[i],i));return $n(this,{values:e},!0)}get(t){return this[On.normalizeUnit(t)]}set(t){if(!this.isValid)return this;return $n(this,{values:{...this.values,...qe(t,On.normalizeUnit)}})}reconfigure({locale:t,numberingSystem:e,conversionAccuracy:i}={}){const n={loc:this.loc.clone({locale:t,numberingSystem:e})};return i&&(n.conversionAccuracy=i),$n(this,n)}as(t){return this.isValid?this.shiftTo(t).get(t):NaN}normalize(){if(!this.isValid)return this;const t=this.toObject();return function(t,e){Tn.reduce(((i,n)=>be(e[n])?i:(i&&Ln(t,e,i,e,n),n)),null)}(this.matrix,t),$n(this,{values:t},!0)}shiftTo(...t){if(!this.isValid)return this;if(0===t.length)return this;t=t.map((t=>On.normalizeUnit(t)));const e={},i={},n=this.toObject();let o;for(const s of En)if(t.indexOf(s)>=0){o=s;let t=0;for(const e in i)t+=this.matrix[e][s]*i[e],i[e]=0;_e(n[s])&&(t+=n[s]);const r=Math.trunc(t);e[s]=r,i[s]=(1e3*t-1e3*r)/1e3;for(const t in n)En.indexOf(t)>En.indexOf(s)&&Ln(this.matrix,n,t,e,s)}else _e(n[s])&&(i[s]=n[s]);for(const t in i)0!==i[t]&&(e[o]+=t===o?i[t]:i[t]/this.matrix[o][t]);return $n(this,{values:e},!0).normalize()}negate(){if(!this.isValid)return this;const t={};for(const e of Object.keys(this.values))t[e]=0===this.values[e]?0:-this.values[e];return $n(this,{values:t},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(t){if(!this.isValid||!t.isValid)return!1;if(!this.loc.equals(t.loc))return!1;for(const n of En)if(e=this.values[n],i=t.values[n],!(void 0===e||0===e?void 0===i||0===i:e===i))return!1;var e,i;return!0}}const An="Invalid Interval";class Mn{constructor(t){this.s=t.start,this.e=t.end,this.invalid=t.invalid||null,this.isLuxonInterval=!0}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the Interval is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Zt(i);return new Mn({invalid:i})}static fromDateTimes(t,e){const i=zo(t),n=zo(e),o=function(t,e){return t&&t.isValid?e&&e.isValid?e<t?Mn.invalid("end before start",`The end of an interval must be after its start, but you had start=${t.toISO()} and end=${e.toISO()}`):null:Mn.invalid("missing or invalid end"):Mn.invalid("missing or invalid start")}(i,n);return null==o?new Mn({start:i,end:n}):o}static after(t,e){const i=On.fromDurationLike(e),n=zo(t);return Mn.fromDateTimes(n,n.plus(i))}static before(t,e){const i=On.fromDurationLike(e),n=zo(t);return Mn.fromDateTimes(n.minus(i),n)}static fromISO(t,e){const[i,n]=(t||"").split("/",2);if(i&&n){let t,o,s,r;try{t=Po.fromISO(i,e),o=t.isValid}catch(n){o=!1}try{s=Po.fromISO(n,e),r=s.isValid}catch(n){r=!1}if(o&&r)return Mn.fromDateTimes(t,s);if(o){const i=On.fromISO(n,e);if(i.isValid)return Mn.after(t,i)}else if(r){const t=On.fromISO(i,e);if(t.isValid)return Mn.before(s,t)}}return Mn.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static isInterval(t){return t&&t.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return null===this.invalidReason}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(t="milliseconds"){return this.isValid?this.toDuration(t).get(t):NaN}count(t="milliseconds"){if(!this.isValid)return NaN;const e=this.start.startOf(t),i=this.end.startOf(t);return Math.floor(i.diff(e,t).get(t))+1}hasSame(t){return!!this.isValid&&(this.isEmpty()||this.e.minus(1).hasSame(this.s,t))}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(t){return!!this.isValid&&this.s>t}isBefore(t){return!!this.isValid&&this.e<=t}contains(t){return!!this.isValid&&(this.s<=t&&this.e>t)}set({start:t,end:e}={}){return this.isValid?Mn.fromDateTimes(t||this.s,e||this.e):this}splitAt(...t){if(!this.isValid)return[];const e=t.map(zo).filter((t=>this.contains(t))).sort(),i=[];let{s:n}=this,o=0;for(;n<this.e;){const t=e[o]||this.e,s=+t>+this.e?this.e:t;i.push(Mn.fromDateTimes(n,s)),n=s,o+=1}return i}splitBy(t){const e=On.fromDurationLike(t);if(!this.isValid||!e.isValid||0===e.as("milliseconds"))return[];let i,{s:n}=this,o=1;const s=[];for(;n<this.e;){const t=this.start.plus(e.mapUnits((t=>t*o)));i=+t>+this.e?this.e:t,s.push(Mn.fromDateTimes(n,i)),n=i,o+=1}return s}divideEqually(t){return this.isValid?this.splitBy(this.length()/t).slice(0,t):[]}overlaps(t){return this.e>t.s&&this.s<t.e}abutsStart(t){return!!this.isValid&&+this.e==+t.s}abutsEnd(t){return!!this.isValid&&+t.e==+this.s}engulfs(t){return!!this.isValid&&(this.s<=t.s&&this.e>=t.e)}equals(t){return!(!this.isValid||!t.isValid)&&(this.s.equals(t.s)&&this.e.equals(t.e))}intersection(t){if(!this.isValid)return this;const e=this.s>t.s?this.s:t.s,i=this.e<t.e?this.e:t.e;return e>=i?null:Mn.fromDateTimes(e,i)}union(t){if(!this.isValid)return this;const e=this.s<t.s?this.s:t.s,i=this.e>t.e?this.e:t.e;return Mn.fromDateTimes(e,i)}static merge(t){const[e,i]=t.sort(((t,e)=>t.s-e.s)).reduce((([t,e],i)=>e?e.overlaps(i)||e.abutsStart(i)?[t,e.union(i)]:[t.concat([e]),i]:[t,i]),[[],null]);return i&&e.push(i),e}static xor(t){let e=null,i=0;const n=[],o=t.map((t=>[{time:t.s,type:"s"},{time:t.e,type:"e"}])),s=Array.prototype.concat(...o).sort(((t,e)=>t.time-e.time));for(const t of s)i+="s"===t.type?1:-1,1===i?e=t.time:(e&&+e!=+t.time&&n.push(Mn.fromDateTimes(e,t.time)),e=null);return Mn.merge(n)}difference(...t){return Mn.xor([this].concat(t)).map((t=>this.intersection(t))).filter((t=>t&&!t.isEmpty()))}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:An}toISO(t){return this.isValid?`${this.s.toISO(t)}/${this.e.toISO(t)}`:An}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:An}toISOTime(t){return this.isValid?`${this.s.toISOTime(t)}/${this.e.toISOTime(t)}`:An}toFormat(t,{separator:e=" – "}={}){return this.isValid?`${this.s.toFormat(t)}${e}${this.e.toFormat(t)}`:An}toDuration(t,e){return this.isValid?this.e.diff(this.s,t,e):On.invalid(this.invalidReason)}mapEndpoints(t){return Mn.fromDateTimes(t(this.s),t(this.e))}}class Pn{static hasDST(t=Si.defaultZone){const e=Po.now().setZone(t).set({month:12});return!t.isUniversal&&e.offset!==e.set({month:6}).offset}static isValidIANAZone(t){return pi.isValidZone(t)}static normalizeZone(t){return vi(t,Si.defaultZone)}static months(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null,outputCalendar:o="gregory"}={}){return(n||Ii.create(e,i,o)).months(t)}static monthsFormat(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null,outputCalendar:o="gregory"}={}){return(n||Ii.create(e,i,o)).months(t,!0)}static weekdays(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null}={}){return(n||Ii.create(e,i,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:e=null,numberingSystem:i=null,locObj:n=null}={}){return(n||Ii.create(e,i,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Ii.create(t).meridiems()}static eras(t="short",{locale:e=null}={}){return Ii.create(e,null,"gregory").eras(t)}static features(){return{relative:we()}}}function zn(t,e){const i=t=>t.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),n=i(e)-i(t);return Math.floor(On.fromMillis(n).as("days"))}function In(t,e,i,n){let[o,s,r,a]=function(t,e,i){const n=[["years",(t,e)=>e.year-t.year],["quarters",(t,e)=>e.quarter-t.quarter],["months",(t,e)=>e.month-t.month+12*(e.year-t.year)],["weeks",(t,e)=>{const i=zn(t,e);return(i-i%7)/7}],["days",zn]],o={};let s,r;for(const[a,l]of n)if(i.indexOf(a)>=0){s=a;let i=l(t,e);r=t.plus({[a]:i}),r>e?(t=t.plus({[a]:i-1}),i-=1):t=r,o[a]=i}return[t,o,r,s]}(t,e,i);const l=e-o,c=i.filter((t=>["hours","minutes","seconds","milliseconds"].indexOf(t)>=0));0===c.length&&(r<e&&(r=o.plus({[a]:1})),r!==o&&(s[a]=(s[a]||0)+l/(r-o)));const h=On.fromObject(s,n);return c.length>0?On.fromMillis(l,n).shiftTo(...c).plus(h):h}const Dn={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},Nn={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},Rn=Dn.hanidec.replace(/[\[|\]]/g,"").split("");function Bn({numberingSystem:t},e=""){return new RegExp(`${Dn[t||"latn"]}${e}`)}function qn(t,e=(t=>t)){return{regex:t,deser:([t])=>e(function(t){let e=parseInt(t,10);if(isNaN(e)){e="";for(let i=0;i<t.length;i++){const n=t.charCodeAt(i);if(-1!==t[i].search(Dn.hanidec))e+=Rn.indexOf(t[i]);else for(const t in Nn){const[i,o]=Nn[t];n>=i&&n<=o&&(e+=n-i)}}return parseInt(e,10)}return e}(t))}}const Fn=`[ ${String.fromCharCode(160)}]`,Zn=new RegExp(Fn,"g");function Un(t){return t.replace(/\./g,"\\.?").replace(Zn,Fn)}function Vn(t){return t.replace(/\./g,"").replace(Zn," ").toLowerCase()}function jn(t,e){return null===t?null:{regex:RegExp(t.map(Un).join("|")),deser:([i])=>t.findIndex((t=>Vn(i)===Vn(t)))+e}}function Hn(t,e){return{regex:t,deser:([,t,e])=>Re(t,e),groups:e}}function Gn(t){return{regex:t,deser:([t])=>t}}const Wn={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"}};let Kn=null;function Yn(t,e){if(t.literal)return t;const i=si.macroTokenToFormatOpts(t.val);if(!i)return t;const n=si.create(e,i).formatDateTimeParts((Kn||(Kn=Po.fromMillis(1555555555555)),Kn)).map((t=>function(t,e,i){const{type:n,value:o}=t;if("literal"===n)return{literal:!0,val:o};const s=i[n];let r=Wn[n];return"object"==typeof r&&(r=r[s]),r?{literal:!1,val:r}:void 0}(t,0,i)));return n.includes(void 0)?t:n}function Jn(t,e,i){const n=function(t,e){return Array.prototype.concat(...t.map((t=>Yn(t,e))))}(si.parseFormat(i),t),o=n.map((e=>function(t,e){const i=Bn(e),n=Bn(e,"{2}"),o=Bn(e,"{3}"),s=Bn(e,"{4}"),r=Bn(e,"{6}"),a=Bn(e,"{1,2}"),l=Bn(e,"{1,3}"),c=Bn(e,"{1,6}"),h=Bn(e,"{1,9}"),d=Bn(e,"{2,4}"),u=Bn(e,"{4,6}"),p=t=>{return{regex:RegExp((e=t.val,e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"))),deser:([t])=>t,literal:!0};var e},m=(m=>{if(t.literal)return p(m);switch(m.val){case"G":return jn(e.eras("short",!1),0);case"GG":return jn(e.eras("long",!1),0);case"y":return qn(c);case"yy":case"kk":return qn(d,De);case"yyyy":case"kkkk":return qn(s);case"yyyyy":return qn(u);case"yyyyyy":return qn(r);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return qn(a);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return qn(n);case"MMM":return jn(e.months("short",!0,!1),1);case"MMMM":return jn(e.months("long",!0,!1),1);case"LLL":return jn(e.months("short",!1,!1),1);case"LLLL":return jn(e.months("long",!1,!1),1);case"o":case"S":return qn(l);case"ooo":case"SSS":return qn(o);case"u":return Gn(h);case"uu":return Gn(a);case"uuu":case"E":case"c":return qn(i);case"a":return jn(e.meridiems(),0);case"EEE":return jn(e.weekdays("short",!1,!1),1);case"EEEE":return jn(e.weekdays("long",!1,!1),1);case"ccc":return jn(e.weekdays("short",!0,!1),1);case"cccc":return jn(e.weekdays("long",!0,!1),1);case"Z":case"ZZ":return Hn(new RegExp(`([+-]${a.source})(?::(${n.source}))?`),2);case"ZZZ":return Hn(new RegExp(`([+-]${a.source})(${n.source})?`),2);case"z":return Gn(/[a-z_+-/]{1,256}?/i);default:return p(m)}})(t)||{invalidReason:"missing Intl.DateTimeFormat.formatToParts support"};return m.token=t,m}(e,t))),s=o.find((t=>t.invalidReason));if(s)return{input:e,tokens:n,invalidReason:s.invalidReason};{const[t,i]=function(t){const e=t.map((t=>t.regex)).reduce(((t,e)=>`${t}(${e.source})`),"");return[`^${e}$`,t]}(o),s=RegExp(t,"i"),[r,a]=function(t,e,i){const n=t.match(e);if(n){const t={};let e=1;for(const o in i)if(Se(i,o)){const s=i[o],r=s.groups?s.groups+1:1;!s.literal&&s.token&&(t[s.token.val[0]]=s.deser(n.slice(e,e+r))),e+=r}return[n,t]}return[n,{}]}(e,s,i),[l,c,h]=a?function(t){let e,i=null;be(t.z)||(i=pi.create(t.z)),be(t.Z)||(i||(i=new fi(t.Z)),e=t.Z),be(t.q)||(t.M=3*(t.q-1)+1),be(t.h)||(t.h<12&&1===t.a?t.h+=12:12===t.h&&0===t.a&&(t.h=0)),0===t.G&&t.y&&(t.y=-t.y),be(t.u)||(t.S=Le(t.u));const n=Object.keys(t).reduce(((e,i)=>{const n=(t=>{switch(t){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}})(i);return n&&(e[n]=t[i]),e}),{});return[n,i,e]}(a):[null,null,void 0];if(Se(a,"a")&&Se(a,"H"))throw new Vt("Can't include meridiem when specifying 24-hour format");return{input:e,tokens:n,regex:s,rawMatches:r,matches:a,result:l,zone:c,specificOffset:h}}}const Xn=[0,31,59,90,120,151,181,212,243,273,304,334],Qn=[0,31,60,91,121,152,182,213,244,274,305,335];function to(t,e){return new ri("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${t}, which is invalid`)}function eo(t,e,i){const n=new Date(Date.UTC(t,e-1,i));t<100&&t>=0&&n.setUTCFullYear(n.getUTCFullYear()-1900);const o=n.getUTCDay();return 0===o?7:o}function io(t,e,i){return i+(Ae(t)?Qn:Xn)[e-1]}function no(t,e){const i=Ae(t)?Qn:Xn,n=i.findIndex((t=>t<e));return{month:n+1,day:e-i[n]}}function oo(t){const{year:e,month:i,day:n}=t,o=io(e,i,n),s=eo(e,i,n);let r,a=Math.floor((o-s+10)/7);return a<1?(r=e-1,a=Ie(r)):a>Ie(e)?(r=e+1,a=1):r=e,{weekYear:r,weekNumber:a,weekday:s,...Ze(t)}}function so(t){const{weekYear:e,weekNumber:i,weekday:n}=t,o=eo(e,1,4),s=Me(e);let r,a=7*i+n-o-3;a<1?(r=e-1,a+=Me(r)):a>s?(r=e+1,a-=Me(e)):r=e;const{month:l,day:c}=no(r,a);return{year:r,month:l,day:c,...Ze(t)}}function ro(t){const{year:e,month:i,day:n}=t;return{year:e,ordinal:io(e,i,n),...Ze(t)}}function ao(t){const{year:e,ordinal:i}=t,{month:n,day:o}=no(e,i);return{year:e,month:n,day:o,...Ze(t)}}function lo(t){const e=xe(t.year),i=Ce(t.month,1,12),n=Ce(t.day,1,Pe(t.year,t.month));return e?i?!n&&to("day",t.day):to("month",t.month):to("year",t.year)}function co(t){const{hour:e,minute:i,second:n,millisecond:o}=t,s=Ce(e,0,23)||24===e&&0===i&&0===n&&0===o,r=Ce(i,0,59),a=Ce(n,0,59),l=Ce(o,0,999);return s?r?a?!l&&to("millisecond",o):to("second",n):to("minute",i):to("hour",e)}const ho="Invalid DateTime";function uo(t){return new ri("unsupported zone",`the zone "${t.name}" is not supported`)}function po(t){return null===t.weekData&&(t.weekData=oo(t.c)),t.weekData}function mo(t,e){const i={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new Po({...i,...e,old:i})}function fo(t,e,i){let n=t-60*e*1e3;const o=i.offset(n);if(e===o)return[n,e];n-=60*(o-e)*1e3;const s=i.offset(n);return o===s?[n,o]:[t-60*Math.min(o,s)*1e3,Math.max(o,s)]}function go(t,e){const i=new Date(t+=60*e*1e3);return{year:i.getUTCFullYear(),month:i.getUTCMonth()+1,day:i.getUTCDate(),hour:i.getUTCHours(),minute:i.getUTCMinutes(),second:i.getUTCSeconds(),millisecond:i.getUTCMilliseconds()}}function vo(t,e,i){return fo(ze(t),e,i)}function yo(t,e){const i=t.o,n=t.c.year+Math.trunc(e.years),o=t.c.month+Math.trunc(e.months)+3*Math.trunc(e.quarters),s={...t.c,year:n,month:o,day:Math.min(t.c.day,Pe(n,o))+Math.trunc(e.days)+7*Math.trunc(e.weeks)},r=On.fromObject({years:e.years-Math.trunc(e.years),quarters:e.quarters-Math.trunc(e.quarters),months:e.months-Math.trunc(e.months),weeks:e.weeks-Math.trunc(e.weeks),days:e.days-Math.trunc(e.days),hours:e.hours,minutes:e.minutes,seconds:e.seconds,milliseconds:e.milliseconds}).as("milliseconds"),a=ze(s);let[l,c]=fo(a,i,t.zone);return 0!==r&&(l+=r,c=t.zone.offset(l)),{ts:l,o:c}}function bo(t,e,i,n,o,s){const{setZone:r,zone:a}=i;if(t&&0!==Object.keys(t).length){const n=e||a,o=Po.fromObject(t,{...i,zone:n,specificOffset:s});return r?o:o.setZone(a)}return Po.invalid(new ri("unparsable",`the input "${o}" can't be parsed as ${n}`))}function _o(t,e,i=!0){return t.isValid?si.create(Ii.create("en-US"),{allowZ:i,forceSimple:!0}).formatDateTimeFromString(t,e):null}function xo(t,e){const i=t.c.year>9999||t.c.year<0;let n="";return i&&t.c.year>=0&&(n+="+"),n+=Ee(t.c.year,i?6:4),e?(n+="-",n+=Ee(t.c.month),n+="-",n+=Ee(t.c.day)):(n+=Ee(t.c.month),n+=Ee(t.c.day)),n}function wo(t,e,i,n,o,s){let r=Ee(t.c.hour);return e?(r+=":",r+=Ee(t.c.minute),0===t.c.second&&i||(r+=":")):r+=Ee(t.c.minute),0===t.c.second&&i||(r+=Ee(t.c.second),0===t.c.millisecond&&n||(r+=".",r+=Ee(t.c.millisecond,3))),o&&(t.isOffsetFixed&&0===t.offset&&!s?r+="Z":t.o<0?(r+="-",r+=Ee(Math.trunc(-t.o/60)),r+=":",r+=Ee(Math.trunc(-t.o%60))):(r+="+",r+=Ee(Math.trunc(t.o/60)),r+=":",r+=Ee(Math.trunc(t.o%60)))),s&&(r+="["+t.zone.ianaName+"]"),r}const ko={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},So={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},Co={ordinal:1,hour:0,minute:0,second:0,millisecond:0},Eo=["year","month","day","hour","minute","second","millisecond"],To=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],$o=["year","ordinal","hour","minute","second","millisecond"];function Lo(t){const e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new jt(t);return e}function Oo(t,e){const i=vi(e.zone,Si.defaultZone),n=Ii.fromObject(e),o=Si.now();let s,r;if(be(t.year))s=o;else{for(const e of Eo)be(t[e])&&(t[e]=ko[e]);const e=lo(t)||co(t);if(e)return Po.invalid(e);const n=i.offset(o);[s,r]=vo(t,n,i)}return new Po({ts:s,zone:i,loc:n,o:r})}function Ao(t,e,i){const n=!!be(i.round)||i.round,o=(t,o)=>{t=Oe(t,n||i.calendary?0:2,!0);return e.loc.clone(i).relFormatter(i).format(t,o)},s=n=>i.calendary?e.hasSame(t,n)?0:e.startOf(n).diff(t.startOf(n),n).get(n):e.diff(t,n).get(n);if(i.unit)return o(s(i.unit),i.unit);for(const t of i.units){const e=s(t);if(Math.abs(e)>=1)return o(e,t)}return o(t>e?-0:0,i.units[i.units.length-1])}function Mo(t){let e,i={};return t.length>0&&"object"==typeof t[t.length-1]?(i=t[t.length-1],e=Array.from(t).slice(0,t.length-1)):e=Array.from(t),[i,e]}class Po{constructor(t){const e=t.zone||Si.defaultZone;let i=t.invalid||(Number.isNaN(t.ts)?new ri("invalid input"):null)||(e.isValid?null:uo(e));this.ts=be(t.ts)?Si.now():t.ts;let n=null,o=null;if(!i){if(t.old&&t.old.ts===this.ts&&t.old.zone.equals(e))[n,o]=[t.old.c,t.old.o];else{const t=e.offset(this.ts);n=go(this.ts,t),i=Number.isNaN(n.year)?new ri("invalid input"):null,n=i?null:n,o=i?null:t}}this._zone=e,this.loc=t.loc||Ii.create(),this.invalid=i,this.weekData=null,this.c=n,this.o=o,this.isLuxonDateTime=!0}static now(){return new Po({})}static local(){const[t,e]=Mo(arguments),[i,n,o,s,r,a,l]=e;return Oo({year:i,month:n,day:o,hour:s,minute:r,second:a,millisecond:l},t)}static utc(){const[t,e]=Mo(arguments),[i,n,o,s,r,a,l]=e;return t.zone=fi.utcInstance,Oo({year:i,month:n,day:o,hour:s,minute:r,second:a,millisecond:l},t)}static fromJSDate(t,e={}){const i=function(t){return"[object Date]"===Object.prototype.toString.call(t)}(t)?t.valueOf():NaN;if(Number.isNaN(i))return Po.invalid("invalid input");const n=vi(e.zone,Si.defaultZone);return n.isValid?new Po({ts:i,zone:n,loc:Ii.fromObject(e)}):Po.invalid(uo(n))}static fromMillis(t,e={}){if(_e(t))return t<-864e13||t>864e13?Po.invalid("Timestamp out of range"):new Po({ts:t,zone:vi(e.zone,Si.defaultZone),loc:Ii.fromObject(e)});throw new Ht(`fromMillis requires a numerical input, but received a ${typeof t} with value ${t}`)}static fromSeconds(t,e={}){if(_e(t))return new Po({ts:1e3*t,zone:vi(e.zone,Si.defaultZone),loc:Ii.fromObject(e)});throw new Ht("fromSeconds requires a numerical input")}static fromObject(t,e={}){t=t||{};const i=vi(e.zone,Si.defaultZone);if(!i.isValid)return Po.invalid(uo(i));const n=Si.now(),o=be(e.specificOffset)?i.offset(n):e.specificOffset,s=qe(t,Lo),r=!be(s.ordinal),a=!be(s.year),l=!be(s.month)||!be(s.day),c=a||l,h=s.weekYear||s.weekNumber,d=Ii.fromObject(e);if((c||r)&&h)throw new Vt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(l&&r)throw new Vt("Can't mix ordinal dates with month/day");const u=h||s.weekday&&!c;let p,m,f=go(n,o);u?(p=To,m=So,f=oo(f)):r?(p=$o,m=Co,f=ro(f)):(p=Eo,m=ko);let g=!1;for(const t of p){be(s[t])?s[t]=g?m[t]:f[t]:g=!0}const v=u?function(t){const e=xe(t.weekYear),i=Ce(t.weekNumber,1,Ie(t.weekYear)),n=Ce(t.weekday,1,7);return e?i?!n&&to("weekday",t.weekday):to("week",t.week):to("weekYear",t.weekYear)}(s):r?function(t){const e=xe(t.year),i=Ce(t.ordinal,1,Me(t.year));return e?!i&&to("ordinal",t.ordinal):to("year",t.year)}(s):lo(s),y=v||co(s);if(y)return Po.invalid(y);const b=u?so(s):r?ao(s):s,[_,x]=vo(b,o,i),w=new Po({ts:_,zone:i,o:x,loc:d});return s.weekday&&c&&t.weekday!==w.weekday?Po.invalid("mismatched weekday",`you can't specify both a weekday of ${s.weekday} and a date of ${w.toISO()}`):w}static fromISO(t,e={}){const[i,n]=function(t){return Ri(t,[dn,fn],[un,gn],[pn,vn],[mn,yn])}(t);return bo(i,n,e,"ISO 8601",t)}static fromRFC2822(t,e={}){const[i,n]=function(t){return Ri(function(t){return t.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(t),[on,sn])}(t);return bo(i,n,e,"RFC 2822",t)}static fromHTTP(t,e={}){const[i,n]=function(t){return Ri(t,[rn,cn],[an,cn],[ln,hn])}(t);return bo(i,n,e,"HTTP",e)}static fromFormat(t,e,i={}){if(be(t)||be(e))throw new Ht("fromFormat requires an input string and a format");const{locale:n=null,numberingSystem:o=null}=i,s=Ii.fromOpts({locale:n,numberingSystem:o,defaultToEN:!0}),[r,a,l,c]=function(t,e,i){const{result:n,zone:o,specificOffset:s,invalidReason:r}=Jn(t,e,i);return[n,o,s,r]}(s,t,e);return c?Po.invalid(c):bo(r,a,i,`format ${e}`,t,l)}static fromString(t,e,i={}){return Po.fromFormat(t,e,i)}static fromSQL(t,e={}){const[i,n]=function(t){return Ri(t,[_n,fn],[xn,wn])}(t);return bo(i,n,e,"SQL",t)}static invalid(t,e=null){if(!t)throw new Ht("need to specify a reason the DateTime is invalid");const i=t instanceof ri?t:new ri(t,e);if(Si.throwOnInvalid)throw new Ft(i);return new Po({invalid:i})}static isDateTime(t){return t&&t.isLuxonDateTime||!1}get(t){return this[t]}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?po(this).weekYear:NaN}get weekNumber(){return this.isValid?po(this).weekNumber:NaN}get weekday(){return this.isValid?po(this).weekday:NaN}get ordinal(){return this.isValid?ro(this.c).ordinal:NaN}get monthShort(){return this.isValid?Pn.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?Pn.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?Pn.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?Pn.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}get isInLeapYear(){return Ae(this.year)}get daysInMonth(){return Pe(this.year,this.month)}get daysInYear(){return this.isValid?Me(this.year):NaN}get weeksInWeekYear(){return this.isValid?Ie(this.weekYear):NaN}resolvedLocaleOptions(t={}){const{locale:e,numberingSystem:i,calendar:n}=si.create(this.loc.clone(t),t).resolvedOptions(this);return{locale:e,numberingSystem:i,outputCalendar:n}}toUTC(t=0,e={}){return this.setZone(fi.instance(t),e)}toLocal(){return this.setZone(Si.defaultZone)}setZone(t,{keepLocalTime:e=!1,keepCalendarTime:i=!1}={}){if((t=vi(t,Si.defaultZone)).equals(this.zone))return this;if(t.isValid){let n=this.ts;if(e||i){const e=t.offset(this.ts),i=this.toObject();[n]=vo(i,e,t)}return mo(this,{ts:n,zone:t})}return Po.invalid(uo(t))}reconfigure({locale:t,numberingSystem:e,outputCalendar:i}={}){return mo(this,{loc:this.loc.clone({locale:t,numberingSystem:e,outputCalendar:i})})}setLocale(t){return this.reconfigure({locale:t})}set(t){if(!this.isValid)return this;const e=qe(t,Lo),i=!be(e.weekYear)||!be(e.weekNumber)||!be(e.weekday),n=!be(e.ordinal),o=!be(e.year),s=!be(e.month)||!be(e.day),r=o||s,a=e.weekYear||e.weekNumber;if((r||n)&&a)throw new Vt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(s&&n)throw new Vt("Can't mix ordinal dates with month/day");let l;i?l=so({...oo(this.c),...e}):be(e.ordinal)?(l={...this.toObject(),...e},be(e.day)&&(l.day=Math.min(Pe(l.year,l.month),l.day))):l=ao({...ro(this.c),...e});const[c,h]=vo(l,this.o,this.zone);return mo(this,{ts:c,o:h})}plus(t){if(!this.isValid)return this;return mo(this,yo(this,On.fromDurationLike(t)))}minus(t){if(!this.isValid)return this;return mo(this,yo(this,On.fromDurationLike(t).negate()))}startOf(t){if(!this.isValid)return this;const e={},i=On.normalizeUnit(t);switch(i){case"years":e.month=1;case"quarters":case"months":e.day=1;case"weeks":case"days":e.hour=0;case"hours":e.minute=0;case"minutes":e.second=0;case"seconds":e.millisecond=0}if("weeks"===i&&(e.weekday=1),"quarters"===i){const t=Math.ceil(this.month/3);e.month=3*(t-1)+1}return this.set(e)}endOf(t){return this.isValid?this.plus({[t]:1}).startOf(t).minus(1):this}toFormat(t,e={}){return this.isValid?si.create(this.loc.redefaultToEN(e)).formatDateTimeFromString(this,t):ho}toLocaleString(t=Jt,e={}){return this.isValid?si.create(this.loc.clone(e),t).formatDateTime(this):ho}toLocaleParts(t={}){return this.isValid?si.create(this.loc.clone(t),t).formatDateTimeParts(this):[]}toISO({format:t="extended",suppressSeconds:e=!1,suppressMilliseconds:i=!1,includeOffset:n=!0,extendedZone:o=!1}={}){if(!this.isValid)return null;const s="extended"===t;let r=xo(this,s);return r+="T",r+=wo(this,s,e,i,n,o),r}toISODate({format:t="extended"}={}){return this.isValid?xo(this,"extended"===t):null}toISOWeekDate(){return _o(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:t=!1,suppressSeconds:e=!1,includeOffset:i=!0,includePrefix:n=!1,extendedZone:o=!1,format:s="extended"}={}){if(!this.isValid)return null;return(n?"T":"")+wo(this,"extended"===s,e,t,i,o)}toRFC2822(){return _o(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return _o(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?xo(this,!0):null}toSQLTime({includeOffset:t=!0,includeZone:e=!1,includeOffsetSpace:i=!0}={}){let n="HH:mm:ss.SSS";return(e||t)&&(i&&(n+=" "),e?n+="z":t&&(n+="ZZ")),_o(this,n,!0)}toSQL(t={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(t)}`:null}toString(){return this.isValid?this.toISO():ho}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(t={}){if(!this.isValid)return{};const e={...this.c};return t.includeConfig&&(e.outputCalendar=this.outputCalendar,e.numberingSystem=this.loc.numberingSystem,e.locale=this.loc.locale),e}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(t,e="milliseconds",i={}){if(!this.isValid||!t.isValid)return On.invalid("created by diffing an invalid DateTime");const n={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=(a=e,Array.isArray(a)?a:[a]).map(On.normalizeUnit),s=t.valueOf()>this.valueOf(),r=In(s?this:t,s?t:this,o,n);var a;return s?r.negate():r}diffNow(t="milliseconds",e={}){return this.diff(Po.now(),t,e)}until(t){return this.isValid?Mn.fromDateTimes(this,t):this}hasSame(t,e){if(!this.isValid)return!1;const i=t.valueOf(),n=this.setZone(t.zone,{keepLocalTime:!0});return n.startOf(e)<=i&&i<=n.endOf(e)}equals(t){return this.isValid&&t.isValid&&this.valueOf()===t.valueOf()&&this.zone.equals(t.zone)&&this.loc.equals(t.loc)}toRelative(t={}){if(!this.isValid)return null;const e=t.base||Po.fromObject({},{zone:this.zone}),i=t.padding?this<e?-t.padding:t.padding:0;let n=["years","months","days","hours","minutes","seconds"],o=t.unit;return Array.isArray(t.unit)&&(n=t.unit,o=void 0),Ao(e,this.plus(i),{...t,numeric:"always",units:n,unit:o})}toRelativeCalendar(t={}){return this.isValid?Ao(t.base||Po.fromObject({},{zone:this.zone}),this,{...t,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...t){if(!t.every(Po.isDateTime))throw new Ht("min requires all arguments be DateTimes");return ke(t,(t=>t.valueOf()),Math.min)}static max(...t){if(!t.every(Po.isDateTime))throw new Ht("max requires all arguments be DateTimes");return ke(t,(t=>t.valueOf()),Math.max)}static fromFormatExplain(t,e,i={}){const{locale:n=null,numberingSystem:o=null}=i;return Jn(Ii.fromOpts({locale:n,numberingSystem:o,defaultToEN:!0}),t,e)}static fromStringExplain(t,e,i={}){return Po.fromFormatExplain(t,e,i)}static get DATE_SHORT(){return Jt}static get DATE_MED(){return Xt}static get DATE_MED_WITH_WEEKDAY(){return Qt}static get DATE_FULL(){return te}static get DATE_HUGE(){return ee}static get TIME_SIMPLE(){return ie}static get TIME_WITH_SECONDS(){return ne}static get TIME_WITH_SHORT_OFFSET(){return oe}static get TIME_WITH_LONG_OFFSET(){return se}static get TIME_24_SIMPLE(){return re}static get TIME_24_WITH_SECONDS(){return ae}static get TIME_24_WITH_SHORT_OFFSET(){return le}static get TIME_24_WITH_LONG_OFFSET(){return ce}static get DATETIME_SHORT(){return he}static get DATETIME_SHORT_WITH_SECONDS(){return de}static get DATETIME_MED(){return ue}static get DATETIME_MED_WITH_SECONDS(){return pe}static get DATETIME_MED_WITH_WEEKDAY(){return me}static get DATETIME_FULL(){return fe}static get DATETIME_FULL_WITH_SECONDS(){return ge}static get DATETIME_HUGE(){return ve}static get DATETIME_HUGE_WITH_SECONDS(){return ye}}function zo(t){if(Po.isDateTime(t))return t;if(t&&t.valueOf&&_e(t.valueOf()))return Po.fromJSDate(t);if(t&&"object"==typeof t)return Po.fromObject(t);throw new Ht(`Unknown datetime argument: ${t}, of type ${typeof t}`)}class Io extends tt{constructor(){super(...arguments),this.ttl=6e4,this.max=20,this.keyedAssets={},this.locale=[...navigator.languages],this.fields={},this.groups={},this.languages={},this.featuredFields=[],this.langService=new Rt,this.humanizer=new Bt(this.langService),this.pendingResolves={},this.fetching={}}getLocale(){return this.locale[0]}reset(){this.cache=Nt(this.max,this.ttl);const t=[];this.completionEndpoint&&t.push(gt(this.completionEndpoint).then((t=>{this.schema=t.json.context,this.fnOptions=t.json.functions}))),this.fieldsEndpoint&&t.push(this.refreshFields()),this.globalsEndpoint&&t.push(xt(this.globalsEndpoint).then((t=>{this.keyedAssets.globals=t.map((t=>t.key))}))),this.languagesEndpoint&&t.push(xt(this.languagesEndpoint).then((t=>{this.languages=t.reduce((function(t,e){return t[e.value]=e.name,t}),{})}))),this.groupsEndpoint&&t.push(xt(this.groupsEndpoint).then((t=>{t.forEach((t=>{this.groups[t.uuid]=t}))}))),this.workspaceEndpoint&&t.push(gt(this.workspaceEndpoint).then((t=>{this.workspace=t.json;const e=t.headers.get("content-language");e&&(this.locale=[e,...this.locale])}))),this.httpComplete=Promise.all(t)}firstUpdated(){this.reset()}getLanguageCode(){return this.locale.length>0?this.locale[0].split("-")[0]:"en"}refreshFields(){return xt(this.fieldsEndpoint).then((t=>{this.keyedAssets.fields=[],this.featuredFields=[],t.forEach((t=>{this.keyedAssets.fields.push(t.key),this.fields[t.key]=t,t.featured&&this.featuredFields.push(t)})),this.featuredFields.sort(((t,e)=>e.priority-t.priority)),this.keyedAssets.fields.sort(),this.fireCustomEvent(It.StoreUpdated,{url:this.fieldsEndpoint,data:this.keyedAssets.fields})}))}getShortDuration(t,e=null){const i=e||Po.now();return t.setLocale(this.locale[0]).toRelative({base:i,style:"long"})}getShortDurationFromIso(t,e=null){const i=Po.fromISO(t),n=e?Po.fromISO(e):Po.now();return this.getShortDuration(i,n)}setKeyedAssets(t,e){this.keyedAssets[t]=e}updated(t){super.updated(t)}getCompletionSchema(){return this.schema}getFunctions(){return this.fnOptions}getKeyedAssets(){return this.keyedAssets}getFieldKeys(){return this.keyedAssets.fields}getContactField(t){return this.fields[t]}getFeaturedFields(){return this.featuredFields}getLanguageName(t){return this.languages[t]}isDynamicGroup(t){const e=this.groups[t];return!(!e||!e.query)}getWorkspace(){return this.workspace}formatDate(t){return Po.fromISO(t).setLocale(this.getLocale()).toLocaleString(Po.DATETIME_SHORT)}postUrl(t,e="",i={},n=null){return wt(t,e,i,n)}getUrl(t,e){return!(e=e||{}).force&&this.cache.has(t)?new Promise((e=>{e(this.cache.get(t))})):gt(t,e.controller,e.headers||{}).then((e=>new Promise(((i,n)=>{e.status>=200&&e.status<=300?(this.cache.set(t,e),i(e)):n("Status: "+e.status)}))))}getResults(t,e){e=e||{};const i="results_"+t,n=this.cache.get(i);return!e.force&&n?new Promise((t=>{t(n)})):new Promise((e=>{const n=this.pendingResolves[t]||[];n.push(e),this.pendingResolves[t]=n,n.length<=1&&bt(t).then((e=>{this.cache.set(i,e);const n=this.pendingResolves[t]||[];for(;n.length>0;){n.pop()(e)}}))}))}updateCache(t,e){this.cache.set(t,e),this.fireCustomEvent(It.StoreUpdated,{url:t,data:e})}makeRequest(t,e){const i=this.fetching[t],n=(new Date).getTime();if(i&&n-i<500)return;this.fetching[t]=n,e=e||{};const o=this.cache.get(t);o&&!e.force?this.fireCustomEvent(It.StoreUpdated,{url:t,data:o}):bt(t).then((i=>{i=e.prepareData?e.prepareData(i):i,this.cache.set(t,i),this.fireCustomEvent(It.StoreUpdated,{url:t,data:i}),delete this.fetching[t]}))}}t([it({type:Number})],Io.prototype,"ttl",void 0),t([it({type:Number})],Io.prototype,"max",void 0),t([it({type:String,attribute:"completion"})],Io.prototype,"completionEndpoint",void 0),t([it({type:String,attribute:"fields"})],Io.prototype,"fieldsEndpoint",void 0),t([it({type:String,attribute:"groups"})],Io.prototype,"groupsEndpoint",void 0),t([it({type:String,attribute:"globals"})],Io.prototype,"globalsEndpoint",void 0),t([it({type:String,attribute:"languages"})],Io.prototype,"languagesEndpoint",void 0),t([it({type:String,attribute:"workspace"})],Io.prototype,"workspaceEndpoint",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"schema",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"fnOptions",void 0),t([it({type:Object,attribute:!1})],Io.prototype,"keyedAssets",void 0);class Do extends tt{constructor(){super(...arguments),this.marginHorizontal=0,this.marginVertical=7,this.scrollPct=75,this.cursorIndex=-1,this.nameKey="name",this.loading=!1,this.hideShadow=!1,this.getName=function(t){return t[this.nameKey||"name"]},this.renderInputOption=function(){return null},this.scrollHeight=0,this.triggerScroll=!1,this.scrollParent=null,this.setCursor=Tt((function(t){t!==this.cursorIndex&&(this.cursorIndex=t)}),50)}static get styles(){return s`
225
225
  .options-container {
226
226
  background: var(--color-options-bg);
227
227
  user-select: none;
@@ -1926,7 +1926,11 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
1926
1926
  name="${ot.broadcast}"
1927
1927
  ></temba-icon>
1928
1928
  <div class="recipients">${t.recipient_count} contacts</div>
1929
- <div class="separator">•</div>`),s.push(P`<div class="time">${Et(new Date(t.created_on))}</div>`),P`<div style="display:flex;align-items:flex-start">
1929
+ <div class="separator">•</div>`),s.push(P`<temba-date
1930
+ class="time"
1931
+ value="${t.created_on}"
1932
+ display="duration"
1933
+ ></temba-date>`),P`<div style="display:flex;align-items:flex-start">
1930
1934
  <div style="display:flex;flex-direction:column">
1931
1935
  ${t.msg.text?P`<div class="msg">${t.msg.text}</div>`:null}
1932
1936
  ${t.msg.attachments?P`<div class="attachments">
@@ -2002,7 +2006,11 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
2002
2006
  ${Vr(t.created_by)} ${e} this ticket
2003
2007
  </div>
2004
2008
  <div class="subtext" style="justify-content:center">
2005
- ${Et(n,{hideRecentText:!0,suffix:" ago"})}
2009
+ <temba-date
2010
+ class="time"
2011
+ value="${n}"
2012
+ display="duration"
2013
+ ></temba-date>
2006
2014
  </div>
2007
2015
  </div>
2008
2016
  `},Xr=(t,e,i)=>{const n=Yr(t);return i?P`<div class="" style="display: flex">
@@ -2273,8 +2281,8 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
2273
2281
  .tickets .note-summary {
2274
2282
  display: flex;
2275
2283
  flex-direction: row;
2276
- line-height: 0.5;
2277
- font-size: 80%;
2284
+ font-size: 85%;
2285
+ margin-top: -0.5em;
2278
2286
  color: rgba(0, 0, 0, 0.6);
2279
2287
  padding: 8px 3px;
2280
2288
  }
@@ -2344,12 +2352,11 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
2344
2352
 
2345
2353
  .msg-summary {
2346
2354
  display: flex;
2347
- line-height: 0.5;
2348
-
2349
- font-size: 80%;
2355
+ font-size: 85%;
2350
2356
  color: rgba(0, 0, 0, 0.6);
2351
2357
  padding: 6px 3px;
2352
2358
  margin-bottom: 0.5em;
2359
+ margin-top: -0.5em;
2353
2360
  }
2354
2361
 
2355
2362
  .msg-summary temba-icon.log {
@@ -2649,23 +2656,31 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
2649
2656
  <div class="description">${t.note}</div>
2650
2657
  <div class="note-summary">
2651
2658
  <div style="flex-grow:1"></div>
2652
- <div class="time">${Et(new Date(t.created_on))}</div>
2659
+ <temba-date
2660
+ class="time"
2661
+ value="${t.created_on}"
2662
+ display="duration"
2663
+ ></temba-date>
2653
2664
  </div>
2654
2665
  </div>
2655
2666
  <div style="margin-left:0.8em;margin-top:0.3em;font-size:0.8em">
2656
2667
  ${Gr(t.created_by,e)}
2657
2668
  </div>
2658
- </div>`)(t,this.agent);case jr.TICKET_ASSIGNED:return(t=>{const e=new Date(t.created_on);return P`
2669
+ </div>`)(t,this.agent);case jr.TICKET_ASSIGNED:return(t=>P`
2659
2670
  <div class="assigned active">
2660
2671
  <div style="text-align:center">
2661
2672
  ${t.assignee?t.assignee.id===t.created_by.id?P`${Vr(t.created_by)} took this ticket`:P`${Vr(t.created_by)} assigned this ticket to
2662
2673
  <div class="attn">${Vr(t.assignee)}</div>`:P`${Vr(t.created_by)} unassigned this ticket`}
2663
2674
  </div>
2664
2675
  <div class="subtext" style="justify-content:center">
2665
- ${Et(e,{hideRecentText:!0,suffix:" ago"})}
2676
+ <temba-date
2677
+ class="time"
2678
+ value="${t.created_on}"
2679
+ display="duration"
2680
+ ></temba-date>
2666
2681
  </div>
2667
2682
  </div>
2668
- `})(t);case jr.TICKET_REOPENED:return Jr(t,"reopened",!this.ticket);case jr.TICKET_CLOSED:return Jr(t,"closed",!this.ticket);case jr.ERROR:case jr.FAILURE:return(t=>P`
2683
+ `)(t);case jr.TICKET_REOPENED:return Jr(t,"reopened",!this.ticket);case jr.TICKET_CLOSED:return Jr(t,"closed",!this.ticket);case jr.ERROR:case jr.FAILURE:return(t=>P`
2669
2684
  <temba-icon
2670
2685
  name="${ot.error}"
2671
2686
  style="--icon-color:var(--color-error)"
@@ -3990,11 +4005,20 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
3990
4005
  cursor: pointer;
3991
4006
  text-decoration: underline;
3992
4007
  }
3993
- `}handleClick(t){window.goto(t)}render(){return P`<slot href="${this.href}" @click="${this.handleClick}"></slot>`}}t([it({type:String})],fa.prototype,"href",void 0);class ga extends tt{constructor(){super(...arguments),this.open=!1,this.arrowSize=6,this.arrowOffset=2*this.arrowSize,this.offsetX=-10,this.offsetY=0}static get styles(){return s`
4008
+ `}handleClick(t){window.goto(t)}render(){return P`<slot href="${this.href}" @click="${this.handleClick}"></slot>`}}t([it({type:String})],fa.prototype,"href",void 0);class ga extends tt{constructor(){super(...arguments),this.open=!1,this.dropAlign="left",this.arrowSize=6,this.arrowOffset=2*this.arrowSize,this.offsetX=-10,this.offsetY=0}static get styles(){return s`
4009
+ .wrapper {
4010
+ position: relative;
4011
+ }
4012
+
3994
4013
  .toggle {
3995
4014
  cursor: pointer;
3996
4015
  }
3997
4016
 
4017
+ .dropdown-wrapper {
4018
+ position: relative;
4019
+ overflow: auto;
4020
+ }
4021
+
3998
4022
  .dropdown {
3999
4023
  position: absolute;
4000
4024
  opacity: 0;
@@ -4032,15 +4056,25 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4032
4056
  pointer-events: auto;
4033
4057
  transform: translateY(0.5em);
4034
4058
  }
4035
- `}firstUpdated(t){super.firstUpdated(t);const e=this.shadowRoot.querySelector(".dropdown"),i=this.shadowRoot.querySelector(".arrow");i.style.borderWidth=this.arrowSize+"px",i.style.top="-"+this.arrowSize+"px",this.arrowOffset<0?i.style.right=Math.abs(this.arrowOffset)+"px":i.style.left=this.arrowOffset+"px",e.style.marginTop=this.offsetY+"px",e.offsetLeft+e.clientWidth>window.outerWidth?e.style.marginLeft="-"+(e.clientWidth-this.clientWidth-this.offsetX)+"px":e.style.marginLeft=this.offsetX+"px",e.addEventListener("blur",(()=>{window.setTimeout((()=>{this.open=!1}),200)}))}updated(t){super.updated(t),t.has("open")&&(this.open?this.classList.add("open"):this.classList.remove("open"))}handleOpen(){if(!this.open){this.open=!0;this.shadowRoot.querySelector(".dropdown").focus()}}render(){return P`
4036
- <div class=${this.open?"open":""}>
4037
- <slot name="toggle" class="toggle" @click="${this.handleOpen}"></slot>
4038
- <div class="dropdown" tabindex="0">
4059
+ `}firstUpdated(t){super.firstUpdated(t);const e=this.shadowRoot.querySelector(".dropdown"),i=this.shadowRoot.querySelector(".arrow");i.style.borderWidth=this.arrowSize+"px",i.style.top="-"+this.arrowSize+"px",this.arrowOffset<0?i.style.right=Math.abs(this.arrowOffset)+"px":i.style.left=this.arrowOffset+"px",e.style.marginTop=this.offsetY+"px",e.offsetLeft+e.clientWidth>window.outerWidth?e.style.marginLeft="-"+(e.clientWidth-this.clientWidth-this.offsetX)+"px":e.style.marginLeft=this.offsetX+"px",e.addEventListener("blur",(()=>{window.setTimeout((()=>{this.open=!1,this.shadowRoot.host.blur()}),200)}))}updated(t){super.updated(t),t.has("open")&&(this.open?this.classList.add("open"):this.classList.remove("open"))}handleToggleClicked(){if(!this.open){this.open=!0;this.shadowRoot.querySelector(".dropdown").focus()}}render(){return P`
4060
+ <div class="wrapper ${this.open?"open":""}">
4061
+ <slot
4062
+ name="toggle"
4063
+ class="toggle"
4064
+ @click="${this.handleToggleClicked}"
4065
+ ></slot>
4066
+ <div
4067
+ class="dropdown"
4068
+ tabindex="0"
4069
+ style="${"right"==this.dropAlign?"right:0":""}"
4070
+ >
4039
4071
  <div class="arrow"></div>
4040
- <slot name="dropdown"></slot>
4072
+ <div class="dropdown-wrapper">
4073
+ <slot name="dropdown" tabindex="1"></slot>
4074
+ </div>
4041
4075
  </div>
4042
4076
  </div>
4043
- `}}t([it({type:Boolean})],ga.prototype,"open",void 0),t([it({type:Number})],ga.prototype,"arrowSize",void 0),t([it({type:Number})],ga.prototype,"arrowOffset",void 0),t([it({type:Number})],ga.prototype,"offsetX",void 0),t([it({type:Number})],ga.prototype,"offsetY",void 0);class va extends tt{constructor(){super(...arguments),this.collapses=!1,this.index=0}static get styles(){return s`
4077
+ `}}t([it({type:Boolean})],ga.prototype,"open",void 0),t([it({type:String,attribute:"drop_align"})],ga.prototype,"dropAlign",void 0),t([it({type:Number})],ga.prototype,"arrowSize",void 0),t([it({type:Number})],ga.prototype,"arrowOffset",void 0),t([it({type:Number})],ga.prototype,"offsetX",void 0),t([it({type:Number})],ga.prototype,"offsetY",void 0);class va extends tt{constructor(){super(...arguments),this.collapses=!1,this.index=0}static get styles(){return s`
4044
4078
  :host {
4045
4079
  display: flex;
4046
4080
  flex-direction: column;
@@ -4563,7 +4597,7 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4563
4597
  </temba-textinput>
4564
4598
  `}
4565
4599
  </div>
4566
- `}}t([it({type:String})],ka.prototype,"key",void 0),t([it({type:String})],ka.prototype,"value",void 0),t([it({type:String})],ka.prototype,"name",void 0),t([it({type:String})],ka.prototype,"type",void 0),t([it({type:String})],ka.prototype,"timezone",void 0),t([it({type:String})],ka.prototype,"icon",void 0),t([it({type:String})],ka.prototype,"iconClass",void 0);const Sa={stopped:{name:"Stopped",icon:"x-octagon"},blocked:{name:"Blocked",icon:"slash"},archived:{name:"Archived",icon:"archive"}};const Ca={[Pt.CampaignEvent]:ot.campaign,[Pt.ScheduledBroadcast]:ot.message,[Pt.ScheduledTrigger]:ot.trigger};class Ea extends Br{constructor(){super(...arguments),this.lang_weekly="Weekly",this.lang_daily="Daily",this.lang_once="Once",this.REPEAT_PERIOD={O:this.lang_once,D:this.lang_daily,W:this.lang_weekly}}static get styles(){return s`
4600
+ `}}t([it({type:String})],ka.prototype,"key",void 0),t([it({type:String})],ka.prototype,"value",void 0),t([it({type:String})],ka.prototype,"name",void 0),t([it({type:String})],ka.prototype,"type",void 0),t([it({type:String})],ka.prototype,"timezone",void 0),t([it({type:String})],ka.prototype,"icon",void 0),t([it({type:String})],ka.prototype,"iconClass",void 0);const Sa={stopped:{name:"Stopped",icon:"x-octagon"},blocked:{name:"Blocked",icon:"slash"},archived:{name:"Archived",icon:"archive"}};const Ca={[Pt.CampaignEvent]:ot.campaign,[Pt.ScheduledBroadcast]:ot.message,[Pt.ScheduledTrigger]:ot.trigger};class Ea extends Br{constructor(){super(),this.lang_weekly="Weekly",this.lang_daily="Daily",this.lang_once="Once",this.REPEAT_PERIOD={O:this.lang_once,D:this.lang_daily,W:this.lang_weekly},this.handleEventClicked=this.handleEventClicked.bind(this)}static get styles(){return s`
4567
4601
  :host {
4568
4602
  }
4569
4603
 
@@ -4622,6 +4656,12 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4622
4656
  0 0 0px 1px rgba(0, 0, 0, 0.02);
4623
4657
  }
4624
4658
 
4659
+ .event:hover {
4660
+ cursor: pointer;
4661
+ box-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.055),
4662
+ 0 0 0px 2px var(--color-link-primary);
4663
+ }
4664
+
4625
4665
  .time {
4626
4666
  white-space: nowrap;
4627
4667
  background: rgba(0, 0, 0, 0.02);
@@ -4658,17 +4698,14 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4658
4698
  margin-right: 0.25em;
4659
4699
  }
4660
4700
 
4661
- .campaign_event .scheduled-by:hover {
4662
- color: var(--color-link-primary);
4663
- --icon-color: var(--color-link-primary);
4664
- cursor: pointer;
4665
- }
4666
-
4667
4701
  .scheduled-by .name {
4668
4702
  flex-grow: 1;
4669
4703
  }
4670
- `}updated(t){super.updated(t),t.has("contact")&&(this.contact?this.url=`/contact/scheduled/${this.contact}/`:this.url=null)}renderEvent(t){return P`
4671
- <div class="event ${t.type}">
4704
+ `}updated(t){super.updated(t),t.has("contact")&&(this.contact?this.url=`/contact/scheduled/${this.contact}/`:this.url=null)}handleEventClicked(t){this.fireCustomEvent(It.Selection,t)}renderEvent(t){return P`
4705
+ <div
4706
+ class="event ${t.type}"
4707
+ @click="${()=>this.handleEventClicked(t)}"
4708
+ >
4672
4709
  <div class="type">
4673
4710
  <temba-icon
4674
4711
  size="2"
@@ -4678,24 +4715,12 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4678
4715
 
4679
4716
  <div class="details">
4680
4717
  <div>
4681
- ${t.flow?P`
4682
- <div
4683
- class="flow linked"
4684
- href="/flow/editor/${t.flow.uuid}/"
4685
- onclick="goto(event)"
4686
- >
4687
- ${t.flow.name}
4688
- </div>
4689
- `:null}
4718
+ ${t.flow?P` Start ${t.flow.name}`:null}
4690
4719
  ${t.message?P` <div class="message">${t.message}</div> `:null}
4691
4720
  </div>
4692
4721
 
4693
4722
  <div class="scheduled-by">
4694
- ${t.campaign?P`<div
4695
- style="display:flex"
4696
- href="/campaign/read/${t.campaign.uuid}/"
4697
- onclick="goto(event, this)"
4698
- >
4723
+ ${t.campaign?P`<div style="display:flex">
4699
4724
  <temba-icon name="${ot.campaign}"></temba-icon>
4700
4725
  <div class="name">${t.campaign.name}</div>
4701
4726
  </div>`:P`
@@ -4897,7 +4922,7 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4897
4922
  </div>
4898
4923
 
4899
4924
  <div style="flex-shrink:1">
4900
- ${this.store.getShortDurationFromIso(t.modified_on)}
4925
+ <temba-date value="${t.modified_on}" display="duration" />
4901
4926
  </div>
4902
4927
  ${this.getIcon(t)}
4903
4928
  </div>
@@ -4938,7 +4963,7 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4938
4963
  >
4939
4964
  Last Updated
4940
4965
  </div>
4941
- `}renderFooter(){if(!this.selectedRun||!this.resultKeys)return null;const t=this.selectedRun.exit_type,e=Object.keys(this.selectedRun.values);return P` <div
4966
+ `}renderFooter(){if(!this.selectedRun||!this.resultKeys)return null;const t=Object.keys(this.selectedRun.values);return P` <div
4942
4967
  style="margin-top: 1.5em; margin-bottom:0.5em;flex-grow:1;border-radius:var(--curvature); border: 1px solid var(--color-widget-border);"
4943
4968
  >
4944
4969
  <div style="display:flex;flex-direction:column;">
@@ -4957,18 +4982,24 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4957
4982
  style="display:flex;margin-left:-0.2em;margin-top:0.25em;font-size: 0.65em"
4958
4983
  >
4959
4984
  ${this.selectedRun.exit_type?P`
4960
- ${this.getIcon(this.selectedRun)}
4961
- <div style="margin-left:0.5em;flex-grow:1">
4962
- ${(([t,...e],i=navigator.language)=>void 0===t?"":t.toLocaleUpperCase(i)+e.join(""))(this.selectedRun.exit_type)}
4963
- ${"completed"==t?P` in
4964
- ${this.store.getShortDurationFromIso(this.selectedRun.created_on,this.selectedRun.exited_on,!0)}`:null}
4965
- ${"interrupted"==t||"expired"==t?P` after
4966
- ${this.store.getShortDurationFromIso(this.selectedRun.created_on,this.selectedRun.exited_on,!0)}`:null}
4985
+ <div style="margin-left:2em;flex-grow:1;display:flex">
4986
+ ${this.getIcon(this.selectedRun)}
4987
+ <div style="margin-left:0.5em">
4988
+ ${(([t,...e],i=navigator.language)=>void 0===t?"":t.toLocaleUpperCase(i)+e.join(""))(this.selectedRun.exit_type)}&nbsp;
4989
+ </div>
4990
+ <temba-date
4991
+ value="${this.selectedRun.exited_on}"
4992
+ compare="${this.selectedRun.created_on}"
4993
+ display="duration"
4994
+ />
4967
4995
  </div>
4968
4996
  `:P`${this.getIcon(this.selectedRun)}
4969
- <div style="margin-left:0.5em;flex-grow:1">
4970
- Active for
4971
- ${this.store.getShortDurationFromIso(this.selectedRun.created_on,null,!0)}
4997
+ <div style="margin-left:1.5em;flex-grow:1;display:flex">
4998
+ <div>Started&nbsp;</div>
4999
+ <temba-date
5000
+ value="${this.selectedRun.created_on}"
5001
+ display="duration"
5002
+ />
4972
5003
  </div>`}
4973
5004
  </div>
4974
5005
  </div>
@@ -4991,7 +5022,7 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
4991
5022
  ></temba-icon>
4992
5023
  </div>
4993
5024
 
4994
- ${e.length>0?P`
5025
+ ${t.length>0?P`
4995
5026
  <div
4996
5027
  style="padding:1em;overflow-y:auto;overflow-x:hidden;max-height:15vh;"
4997
5028
  >
@@ -5388,20 +5419,14 @@ function t(t,e,i,n){var o,s=arguments.length,r=s<3?e:null===n?n=Object.getOwnPro
5388
5419
  <div class="container">
5389
5420
  <slot @mousedown=${this.handleMouseDown}></slot>
5390
5421
  </div>
5391
- `}}t([it({type:String})],Da.prototype,"draggingId",void 0);const Na={date:Po.DATE_SHORT,datetime:Po.DATETIME_SHORT,duration:"duration"};class Ra extends tt{constructor(){super(...arguments),this.display="date"}static get styles(){return s`
5422
+ `}}t([it({type:String})],Da.prototype,"draggingId",void 0);const Na={date:Po.DATE_SHORT,datetime:Po.DATETIME_SHORT,time:Po.TIME_SIMPLE,timedate:"timedate",duration:"duration",relative:"relative",day:"LLL d"};class Ra extends tt{constructor(){super(...arguments),this.display="date"}static get styles(){return s`
5392
5423
  .date {
5393
5424
  display: block;
5394
5425
  overflow: hidden;
5395
5426
  text-overflow: ellipsis;
5396
5427
  white-space: nowrap;
5397
5428
  }
5398
- `}firstUpdated(t){super.firstUpdated(t),t.has("value")&&(this.datetime=Po.fromISO(this.value),this.store=document.querySelector("temba-store"))}connectedCallback(){super.connectedCallback()}render(){return this.datetime?this.display===Na.duration?P`<div class="date">
5399
- ${this.store.getShortDuration(this.datetime)}
5400
- </div>`:P`
5401
- <div class="date">
5402
- ${this.datetime.toLocaleString(Na[this.display])}
5403
- </div>
5404
- `:null}}function Ba(t,e){window.customElements.get(t)||window.customElements.define(t,e)}t([it({type:String})],Ra.prototype,"value",void 0),t([it({type:String})],Ra.prototype,"display",void 0),t([it({type:Object,attribute:!1})],Ra.prototype,"datetime",void 0),Ba("temba-anchor",fa),Ba("temba-alert",oa),Ba("temba-store",Io),Ba("temba-textinput",pt),Ba("temba-datepicker",Ma),Ba("temba-date",Ra),Ba("temba-completion",Sr),Ba("temba-checkbox",rt),Ba("temba-select",kr),Ba("temba-options",Do),Ba("temba-loading",Lr),Ba("temba-button",Tr),Ba("temba-omnibox",ca),Ba("temba-tip",ua),Ba("temba-contact-name",_a),Ba("temba-contact-name-fetch",Aa),Ba("temba-contact-field",ka),Ba("temba-contact-fields",wa),Ba("temba-field-manager",Ia),Ba("temba-urn",xa),Ba("temba-field",$r),Ba("temba-dialog",Er),Ba("temba-modax",Cr),Ba("temba-charcount",Rr),Ba("temba-contact-history",ta),Ba("temba-contact-chat",Fr),Ba("temba-contact-details",na),Ba("temba-ticket-list",ia),Ba("temba-list",ea),Ba("temba-sortable-list",Da),Ba("temba-run-list",La),Ba("temba-flow-details",Oa),Ba("temba-label",ba),Ba("temba-menu",ma),Ba("temba-contact-search",sa),Ba("temba-icon",ra),Ba("temba-dropdown",ga),Ba("temba-tabs",va),Ba("temba-tab",ya),Ba("temba-contact-badges",class extends qr{static get styles(){return s`
5429
+ `}firstUpdated(t){super.firstUpdated(t),t.has("value")&&(this.datetime=Po.fromISO(this.value),this.store=document.querySelector("temba-store"))}connectedCallback(){super.connectedCallback()}render(){if(this.datetime&&this.store){this.datetime.setLocale(this.store.getLocale());let t="";if(this.display===Na.timedate){const e=Math.abs(this.datetime.diffNow().milliseconds/1e3/60/60);t=e<24?this.datetime.toLocaleString(Na.time):e<8760?this.datetime.toFormat(Na.day):this.datetime.toLocaleString(Na.date)}else if(this.display===Na.relative){if(Math.abs(this.datetime.diffNow().milliseconds/1e3/60)<1)return P`<div class="date">just now</div>`;t=this.store.getShortDuration(this.datetime)}else if(this.display===Na.duration){if(Math.abs(this.datetime.diffNow().milliseconds/1e3/60)<1)return P`<div class="date">just now</div>`;t=this.store.getShortDuration(this.datetime)}else t=this.display===Na.day?this.datetime.toLocaleString(Na.day):this.datetime.toLocaleString(Na[this.display]);return P`<div class="date">${t}</div>`}}}function Ba(t,e){window.customElements.get(t)||window.customElements.define(t,e)}t([it({type:String})],Ra.prototype,"value",void 0),t([it({type:String})],Ra.prototype,"display",void 0),t([it({type:Object,attribute:!1})],Ra.prototype,"datetime",void 0),Ba("temba-anchor",fa),Ba("temba-alert",oa),Ba("temba-store",Io),Ba("temba-textinput",pt),Ba("temba-datepicker",Ma),Ba("temba-date",Ra),Ba("temba-completion",Sr),Ba("temba-checkbox",rt),Ba("temba-select",kr),Ba("temba-options",Do),Ba("temba-loading",Lr),Ba("temba-button",Tr),Ba("temba-omnibox",ca),Ba("temba-tip",ua),Ba("temba-contact-name",_a),Ba("temba-contact-name-fetch",Aa),Ba("temba-contact-field",ka),Ba("temba-contact-fields",wa),Ba("temba-field-manager",Ia),Ba("temba-urn",xa),Ba("temba-field",$r),Ba("temba-dialog",Er),Ba("temba-modax",Cr),Ba("temba-charcount",Rr),Ba("temba-contact-history",ta),Ba("temba-contact-chat",Fr),Ba("temba-contact-details",na),Ba("temba-ticket-list",ia),Ba("temba-list",ea),Ba("temba-sortable-list",Da),Ba("temba-run-list",La),Ba("temba-flow-details",Oa),Ba("temba-label",ba),Ba("temba-menu",ma),Ba("temba-contact-search",sa),Ba("temba-icon",ra),Ba("temba-dropdown",ga),Ba("temba-tabs",va),Ba("temba-tab",ya),Ba("temba-contact-badges",class extends qr{static get styles(){return s`
5405
5430
  temba-label {
5406
5431
  margin: 0.3em;
5407
5432
  }