UNPKG

ll-package

Version:

1 lines 68.6 kB
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const D=require("../../../../_virtual/luxon.js");Object.defineProperty(D.__exports,"__esModule",{value:!0});class P extends Error{}class Rn extends P{constructor(e){super(`Invalid DateTime: ${e.toMessage()}`)}}class qn extends P{constructor(e){super(`Invalid Interval: ${e.toMessage()}`)}}class Hn extends P{constructor(e){super(`Invalid Duration: ${e.toMessage()}`)}}class Q extends P{}class Lt extends P{constructor(e){super(`Invalid unit ${e}`)}}class M extends P{}class A extends P{constructor(){super("Zone is an abstract class")}}const c="numeric",L="short",E="long",Me={year:c,month:c,day:c},Zt={year:c,month:L,day:c},Yn={year:c,month:L,day:c,weekday:L},$t={year:c,month:E,day:c},At={year:c,month:E,day:c,weekday:E},zt={hour:c,minute:c},Ut={hour:c,minute:c,second:c},Rt={hour:c,minute:c,second:c,timeZoneName:L},qt={hour:c,minute:c,second:c,timeZoneName:E},Ht={hour:c,minute:c,hourCycle:"h23"},Yt={hour:c,minute:c,second:c,hourCycle:"h23"},_t={hour:c,minute:c,second:c,hourCycle:"h23",timeZoneName:L},Pt={hour:c,minute:c,second:c,hourCycle:"h23",timeZoneName:E},Gt={year:c,month:c,day:c,hour:c,minute:c},Jt={year:c,month:c,day:c,hour:c,minute:c,second:c},Bt={year:c,month:L,day:c,hour:c,minute:c},jt={year:c,month:L,day:c,hour:c,minute:c,second:c},_n={year:c,month:L,day:c,weekday:L,hour:c,minute:c},Qt={year:c,month:E,day:c,hour:c,minute:c,timeZoneName:L},Kt={year:c,month:E,day:c,hour:c,minute:c,second:c,timeZoneName:L},Xt={year:c,month:E,day:c,weekday:E,hour:c,minute:c,timeZoneName:E},en={year:c,month:E,day:c,weekday:E,hour:c,minute:c,second:c,timeZoneName:E};class te{get type(){throw new A}get name(){throw new A}get ianaName(){return this.name}get isUniversal(){throw new A}offsetName(e,t){throw new A}formatOffset(e,t){throw new A}offset(e){throw new A}equals(e){throw new A}get isValid(){throw new A}}let Le=null;class me extends te{static get instance(){return Le===null&&(Le=new me),Le}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(e,{format:t,locale:r}){return fn(e,t,r)}formatOffset(e,t){return de(this.offset(e),t)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}}let Ne={};function Pn(n){return Ne[n]||(Ne[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"})),Ne[n]}const Gn={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function Jn(n,e){const t=n.format(e).replace(/\u200E/g,""),r=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(t),[,s,i,a,o,u,l,f]=r;return[a,s,i,o,u,l,f]}function Bn(n,e){const t=n.formatToParts(e),r=[];for(let s=0;s<t.length;s++){const{type:i,value:a}=t[s],o=Gn[i];i==="era"?r[o]=a:h(o)||(r[o]=parseInt(a,10))}return r}let ke={};class $ extends te{static create(e){return ke[e]||(ke[e]=new $(e)),ke[e]}static resetCache(){ke={},Ne={}}static isValidSpecifier(e){return this.isValidZone(e)}static isValidZone(e){if(!e)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:e}).format(),!0}catch{return!1}}constructor(e){super(),this.zoneName=e,this.valid=$.isValidZone(e)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(e,{format:t,locale:r}){return fn(e,t,r,this.name)}formatOffset(e,t){return de(this.offset(e),t)}offset(e){const t=new Date(e);if(isNaN(t))return NaN;const r=Pn(this.name);let[s,i,a,o,u,l,f]=r.formatToParts?Bn(r,t):Jn(r,t);o==="BC"&&(s=-Math.abs(s)+1);const T=Fe({year:s,month:i,day:a,hour:u===24?0:u,minute:l,second:f,millisecond:0});let d=+t;const v=d%1e3;return d-=v>=0?v:1e3+v,(T-d)/(60*1e3)}equals(e){return e.type==="iana"&&e.name===this.name}get isValid(){return this.valid}}let it={};function jn(n,e={}){const t=JSON.stringify([n,e]);let r=it[t];return r||(r=new Intl.ListFormat(n,e),it[t]=r),r}let He={};function Ye(n,e={}){const t=JSON.stringify([n,e]);let r=He[t];return r||(r=new Intl.DateTimeFormat(n,e),He[t]=r),r}let _e={};function Qn(n,e={}){const t=JSON.stringify([n,e]);let r=_e[t];return r||(r=new Intl.NumberFormat(n,e),_e[t]=r),r}let Pe={};function Kn(n,e={}){const{base:t,...r}=e,s=JSON.stringify([n,r]);let i=Pe[s];return i||(i=new Intl.RelativeTimeFormat(n,e),Pe[s]=i),i}let ce=null;function Xn(){return ce||(ce=new Intl.DateTimeFormat().resolvedOptions().locale,ce)}let at={};function er(n){let e=at[n];if(!e){const t=new Intl.Locale(n);e="getWeekInfo"in t?t.getWeekInfo():t.weekInfo,at[n]=e}return e}function tr(n){const e=n.indexOf("-x-");e!==-1&&(n=n.substring(0,e));const t=n.indexOf("-u-");if(t===-1)return[n];{let r,s;try{r=Ye(n).resolvedOptions(),s=n}catch{const u=n.substring(0,t);r=Ye(u).resolvedOptions(),s=u}const{numberingSystem:i,calendar:a}=r;return[s,i,a]}}function nr(n,e,t){return(t||e)&&(n.includes("-u-")||(n+="-u"),t&&(n+=`-ca-${t}`),e&&(n+=`-nu-${e}`)),n}function rr(n){const e=[];for(let t=1;t<=12;t++){const r=m.utc(2009,t,1);e.push(n(r))}return e}function sr(n){const e=[];for(let t=1;t<=7;t++){const r=m.utc(2016,11,13+t);e.push(n(r))}return e}function Te(n,e,t,r){const s=n.listingMode();return s==="error"?null:s==="en"?t(e):r(e)}function ir(n){return n.numberingSystem&&n.numberingSystem!=="latn"?!1:n.numberingSystem==="latn"||!n.locale||n.locale.startsWith("en")||new Intl.DateTimeFormat(n.intl).resolvedOptions().numberingSystem==="latn"}class ar{constructor(e,t,r){this.padTo=r.padTo||0,this.floor=r.floor||!1;const{padTo:s,floor:i,...a}=r;if(!t||Object.keys(a).length>0){const o={useGrouping:!1,...r};r.padTo>0&&(o.minimumIntegerDigits=r.padTo),this.inf=Qn(e,o)}}format(e){if(this.inf){const t=this.floor?Math.floor(e):e;return this.inf.format(t)}else{const t=this.floor?Math.floor(e):Ke(e,3);return O(t,this.padTo)}}}class or{constructor(e,t,r){this.opts=r,this.originalZone=void 0;let s;if(this.opts.timeZone)this.dt=e;else if(e.zone.type==="fixed"){const a=-1*(e.offset/60),o=a>=0?`Etc/GMT+${a}`:`Etc/GMT${a}`;e.offset!==0&&$.create(o).valid?(s=o,this.dt=e):(s="UTC",this.dt=e.offset===0?e:e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone)}else e.zone.type==="system"?this.dt=e:e.zone.type==="iana"?(this.dt=e,s=e.zone.name):(s="UTC",this.dt=e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone);const i={...this.opts};i.timeZone=i.timeZone||s,this.dtf=Ye(t,i)}format(){return this.originalZone?this.formatToParts().map(({value:e})=>e).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const e=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?e.map(t=>{if(t.type==="timeZoneName"){const r=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...t,value:r}}else return t}):e}resolvedOptions(){return this.dtf.resolvedOptions()}}class ur{constructor(e,t,r){this.opts={style:"long",...r},!t&&ln()&&(this.rtf=Kn(e,r))}format(e,t){return this.rtf?this.rtf.format(e,t):Er(t,e,this.opts.numeric,this.opts.style!=="long")}formatToParts(e,t){return this.rtf?this.rtf.formatToParts(e,t):[]}}const lr={firstDay:1,minimalDays:4,weekend:[6,7]};class k{static fromOpts(e){return k.create(e.locale,e.numberingSystem,e.outputCalendar,e.weekSettings,e.defaultToEN)}static create(e,t,r,s,i=!1){const a=e||p.defaultLocale,o=a||(i?"en-US":Xn()),u=t||p.defaultNumberingSystem,l=r||p.defaultOutputCalendar,f=Ge(s)||p.defaultWeekSettings;return new k(o,u,l,f,a)}static resetCache(){ce=null,He={},_e={},Pe={}}static fromObject({locale:e,numberingSystem:t,outputCalendar:r,weekSettings:s}={}){return k.create(e,t,r,s)}constructor(e,t,r,s,i){const[a,o,u]=tr(e);this.locale=a,this.numberingSystem=t||o||null,this.outputCalendar=r||u||null,this.weekSettings=s,this.intl=nr(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=i,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=ir(this)),this.fastNumbersCached}listingMode(){const e=this.isEnglish(),t=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return e&&t?"en":"intl"}clone(e){return!e||Object.getOwnPropertyNames(e).length===0?this:k.create(e.locale||this.specifiedLocale,e.numberingSystem||this.numberingSystem,e.outputCalendar||this.outputCalendar,Ge(e.weekSettings)||this.weekSettings,e.defaultToEN||!1)}redefaultToEN(e={}){return this.clone({...e,defaultToEN:!0})}redefaultToSystem(e={}){return this.clone({...e,defaultToEN:!1})}months(e,t=!1){return Te(this,e,mn,()=>{const r=t?{month:e,day:"numeric"}:{month:e},s=t?"format":"standalone";return this.monthsCache[s][e]||(this.monthsCache[s][e]=rr(i=>this.extract(i,r,"month"))),this.monthsCache[s][e]})}weekdays(e,t=!1){return Te(this,e,wn,()=>{const r=t?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},s=t?"format":"standalone";return this.weekdaysCache[s][e]||(this.weekdaysCache[s][e]=sr(i=>this.extract(i,r,"weekday"))),this.weekdaysCache[s][e]})}meridiems(){return Te(this,void 0,()=>kn,()=>{if(!this.meridiemCache){const e={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[m.utc(2016,11,13,9),m.utc(2016,11,13,19)].map(t=>this.extract(t,e,"dayperiod"))}return this.meridiemCache})}eras(e){return Te(this,e,Tn,()=>{const t={era:e};return this.eraCache[e]||(this.eraCache[e]=[m.utc(-40,1,1),m.utc(2017,1,1)].map(r=>this.extract(r,t,"era"))),this.eraCache[e]})}extract(e,t,r){const s=this.dtFormatter(e,t),i=s.formatToParts(),a=i.find(o=>o.type.toLowerCase()===r);return a?a.value:null}numberFormatter(e={}){return new ar(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,t={}){return new or(e,this.intl,t)}relFormatter(e={}){return new ur(this.intl,this.isEnglish(),e)}listFormatter(e={}){return jn(this.intl,e)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:cn()?er(this.locale):lr}getStartOfWeek(){return this.getWeekSettings().firstDay}getMinDaysInFirstWeek(){return this.getWeekSettings().minimalDays}getWeekendDays(){return this.getWeekSettings().weekend}equals(e){return this.locale===e.locale&&this.numberingSystem===e.numberingSystem&&this.outputCalendar===e.outputCalendar}}let Ze=null;class I extends te{static get utcInstance(){return Ze===null&&(Ze=new I(0)),Ze}static instance(e){return e===0?I.utcInstance:new I(e)}static parseSpecifier(e){if(e){const t=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(t)return new I(Ve(t[1],t[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${de(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${de(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,t){return de(this.fixed,t)}get isUniversal(){return!0}offset(){return this.fixed}equals(e){return e.type==="fixed"&&e.fixed===this.fixed}get isValid(){return!0}}class tn extends te{constructor(e){super(),this.zoneName=e}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 R(n,e){if(h(n)||n===null)return e;if(n instanceof te)return n;if(dr(n)){const t=n.toLowerCase();return t==="default"?e:t==="local"||t==="system"?me.instance:t==="utc"||t==="gmt"?I.utcInstance:I.parseSpecifier(t)||$.create(n)}else return _(n)?I.instance(n):typeof n=="object"&&"offset"in n&&typeof n.offset=="function"?n:new tn(n)}let ot=()=>Date.now(),ut="system",lt=null,ct=null,ft=null,dt=60,ht,mt=null;class p{static get now(){return ot}static set now(e){ot=e}static set defaultZone(e){ut=e}static get defaultZone(){return R(ut,me.instance)}static get defaultLocale(){return lt}static set defaultLocale(e){lt=e}static get defaultNumberingSystem(){return ct}static set defaultNumberingSystem(e){ct=e}static get defaultOutputCalendar(){return ft}static set defaultOutputCalendar(e){ft=e}static get defaultWeekSettings(){return mt}static set defaultWeekSettings(e){mt=Ge(e)}static get twoDigitCutoffYear(){return dt}static set twoDigitCutoffYear(e){dt=e%100}static get throwOnInvalid(){return ht}static set throwOnInvalid(e){ht=e}static resetCaches(){k.resetCache(),$.resetCache()}}class W{constructor(e,t){this.reason=e,this.explanation=t}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const nn=[0,31,59,90,120,151,181,212,243,273,304,334],rn=[0,31,60,91,121,152,182,213,244,274,305,335];function b(n,e){return new W("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${n}, which is invalid`)}function Be(n,e,t){const r=new Date(Date.UTC(n,e-1,t));n<100&&n>=0&&r.setUTCFullYear(r.getUTCFullYear()-1900);const s=r.getUTCDay();return s===0?7:s}function sn(n,e,t){return t+(ye(n)?rn:nn)[e-1]}function an(n,e){const t=ye(n)?rn:nn,r=t.findIndex(i=>i<e),s=e-t[r];return{month:r+1,day:s}}function je(n,e){return(n-e+7)%7+1}function Ee(n,e=4,t=1){const{year:r,month:s,day:i}=n,a=sn(r,s,i),o=je(Be(r,s,i),t);let u=Math.floor((a-o+14-e)/7),l;return u<1?(l=r-1,u=he(l,e,t)):u>he(r,e,t)?(l=r+1,u=1):l=r,{weekYear:l,weekNumber:u,weekday:o,...Ce(n)}}function yt(n,e=4,t=1){const{weekYear:r,weekNumber:s,weekday:i}=n,a=je(Be(r,1,e),t),o=K(r);let u=s*7+i-a-7+e,l;u<1?(l=r-1,u+=K(l)):u>o?(l=r+1,u-=K(r)):l=r;const{month:f,day:y}=an(l,u);return{year:l,month:f,day:y,...Ce(n)}}function $e(n){const{year:e,month:t,day:r}=n,s=sn(e,t,r);return{year:e,ordinal:s,...Ce(n)}}function gt(n){const{year:e,ordinal:t}=n,{month:r,day:s}=an(e,t);return{year:e,month:r,day:s,...Ce(n)}}function wt(n,e){if(!h(n.localWeekday)||!h(n.localWeekNumber)||!h(n.localWeekYear)){if(!h(n.weekday)||!h(n.weekNumber)||!h(n.weekYear))throw new Q("Cannot mix locale-based week fields with ISO-based week fields");return h(n.localWeekday)||(n.weekday=n.localWeekday),h(n.localWeekNumber)||(n.weekNumber=n.localWeekNumber),h(n.localWeekYear)||(n.weekYear=n.localWeekYear),delete n.localWeekday,delete n.localWeekNumber,delete n.localWeekYear,{minDaysInFirstWeek:e.getMinDaysInFirstWeek(),startOfWeek:e.getStartOfWeek()}}else return{minDaysInFirstWeek:4,startOfWeek:1}}function cr(n,e=4,t=1){const r=be(n.weekYear),s=F(n.weekNumber,1,he(n.weekYear,e,t)),i=F(n.weekday,1,7);return r?s?i?!1:b("weekday",n.weekday):b("week",n.weekNumber):b("weekYear",n.weekYear)}function fr(n){const e=be(n.year),t=F(n.ordinal,1,K(n.year));return e?t?!1:b("ordinal",n.ordinal):b("year",n.year)}function on(n){const e=be(n.year),t=F(n.month,1,12),r=F(n.day,1,De(n.year,n.month));return e?t?r?!1:b("day",n.day):b("month",n.month):b("year",n.year)}function un(n){const{hour:e,minute:t,second:r,millisecond:s}=n,i=F(e,0,23)||e===24&&t===0&&r===0&&s===0,a=F(t,0,59),o=F(r,0,59),u=F(s,0,999);return i?a?o?u?!1:b("millisecond",s):b("second",r):b("minute",t):b("hour",e)}function h(n){return typeof n>"u"}function _(n){return typeof n=="number"}function be(n){return typeof n=="number"&&n%1===0}function dr(n){return typeof n=="string"}function hr(n){return Object.prototype.toString.call(n)==="[object Date]"}function ln(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function cn(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function mr(n){return Array.isArray(n)?n:[n]}function kt(n,e,t){if(n.length!==0)return n.reduce((r,s)=>{const i=[e(s),s];return r&&t(r[0],i[0])===r[0]?r:i},null)[1]}function yr(n,e){return e.reduce((t,r)=>(t[r]=n[r],t),{})}function ee(n,e){return Object.prototype.hasOwnProperty.call(n,e)}function Ge(n){if(n==null)return null;if(typeof n!="object")throw new M("Week settings must be an object");if(!F(n.firstDay,1,7)||!F(n.minimalDays,1,7)||!Array.isArray(n.weekend)||n.weekend.some(e=>!F(e,1,7)))throw new M("Invalid week settings");return{firstDay:n.firstDay,minimalDays:n.minimalDays,weekend:Array.from(n.weekend)}}function F(n,e,t){return be(n)&&n>=e&&n<=t}function gr(n,e){return n-e*Math.floor(n/e)}function O(n,e=2){const t=n<0;let r;return t?r="-"+(""+-n).padStart(e,"0"):r=(""+n).padStart(e,"0"),r}function U(n){if(!(h(n)||n===null||n===""))return parseInt(n,10)}function q(n){if(!(h(n)||n===null||n===""))return parseFloat(n)}function Qe(n){if(!(h(n)||n===null||n==="")){const e=parseFloat("0."+n)*1e3;return Math.floor(e)}}function Ke(n,e,t=!1){const r=10**e;return(t?Math.trunc:Math.round)(n*r)/r}function ye(n){return n%4===0&&(n%100!==0||n%400===0)}function K(n){return ye(n)?366:365}function De(n,e){const t=gr(e-1,12)+1,r=n+(e-t)/12;return t===2?ye(r)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][t-1]}function Fe(n){let e=Date.UTC(n.year,n.month-1,n.day,n.hour,n.minute,n.second,n.millisecond);return n.year<100&&n.year>=0&&(e=new Date(e),e.setUTCFullYear(n.year,n.month-1,n.day)),+e}function Tt(n,e,t){return-je(Be(n,1,e),t)+e-1}function he(n,e=4,t=1){const r=Tt(n,e,t),s=Tt(n+1,e,t);return(K(n)-r+s)/7}function Je(n){return n>99?n:n>p.twoDigitCutoffYear?1900+n:2e3+n}function fn(n,e,t,r=null){const s=new Date(n),i={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};r&&(i.timeZone=r);const a={timeZoneName:e,...i},o=new Intl.DateTimeFormat(t,a).formatToParts(s).find(u=>u.type.toLowerCase()==="timezonename");return o?o.value:null}function Ve(n,e){let t=parseInt(n,10);Number.isNaN(t)&&(t=0);const r=parseInt(e,10)||0,s=t<0||Object.is(t,-0)?-r:r;return t*60+s}function dn(n){const e=Number(n);if(typeof n=="boolean"||n===""||Number.isNaN(e))throw new M(`Invalid unit value ${n}`);return e}function xe(n,e){const t={};for(const r in n)if(ee(n,r)){const s=n[r];if(s==null)continue;t[e(r)]=dn(s)}return t}function de(n,e){const t=Math.trunc(Math.abs(n/60)),r=Math.trunc(Math.abs(n%60)),s=n>=0?"+":"-";switch(e){case"short":return`${s}${O(t,2)}:${O(r,2)}`;case"narrow":return`${s}${t}${r>0?`:${r}`:""}`;case"techie":return`${s}${O(t,2)}${O(r,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function Ce(n){return yr(n,["hour","minute","second","millisecond"])}const wr=["January","February","March","April","May","June","July","August","September","October","November","December"],hn=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],kr=["J","F","M","A","M","J","J","A","S","O","N","D"];function mn(n){switch(n){case"narrow":return[...kr];case"short":return[...hn];case"long":return[...wr];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 yn=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],gn=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Tr=["M","T","W","T","F","S","S"];function wn(n){switch(n){case"narrow":return[...Tr];case"short":return[...gn];case"long":return[...yn];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const kn=["AM","PM"],Sr=["Before Christ","Anno Domini"],pr=["BC","AD"],Or=["B","A"];function Tn(n){switch(n){case"narrow":return[...Or];case"short":return[...pr];case"long":return[...Sr];default:return null}}function vr(n){return kn[n.hour<12?0:1]}function Nr(n,e){return wn(e)[n.weekday-1]}function Ir(n,e){return mn(e)[n.month-1]}function Mr(n,e){return Tn(e)[n.year<0?0:1]}function Er(n,e,t="always",r=!1){const s={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."]},i=["hours","minutes","seconds"].indexOf(n)===-1;if(t==="auto"&&i){const y=n==="days";switch(e){case 1:return y?"tomorrow":`next ${s[n][0]}`;case-1:return y?"yesterday":`last ${s[n][0]}`;case 0:return y?"today":`this ${s[n][0]}`}}const a=Object.is(e,-0)||e<0,o=Math.abs(e),u=o===1,l=s[n],f=r?u?l[1]:l[2]||l[1]:u?s[n][0]:n;return a?`${o} ${f} ago`:`in ${o} ${f}`}function St(n,e){let t="";for(const r of n)r.literal?t+=r.val:t+=e(r.val);return t}const Dr={D:Me,DD:Zt,DDD:$t,DDDD:At,t:zt,tt:Ut,ttt:Rt,tttt:qt,T:Ht,TT:Yt,TTT:_t,TTTT:Pt,f:Gt,ff:Bt,fff:Qt,ffff:Xt,F:Jt,FF:jt,FFF:Kt,FFFF:en};class N{static create(e,t={}){return new N(e,t)}static parseFormat(e){let t=null,r="",s=!1;const i=[];for(let a=0;a<e.length;a++){const o=e.charAt(a);o==="'"?(r.length>0&&i.push({literal:s||/^\s+$/.test(r),val:r}),t=null,r="",s=!s):s||o===t?r+=o:(r.length>0&&i.push({literal:/^\s+$/.test(r),val:r}),r=o,t=o)}return r.length>0&&i.push({literal:s||/^\s+$/.test(r),val:r}),i}static macroTokenToFormatOpts(e){return Dr[e]}constructor(e,t){this.opts=t,this.loc=e,this.systemLoc=null}formatWithSystemDefault(e,t){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(e,{...this.opts,...t}).format()}dtFormatter(e,t={}){return this.loc.dtFormatter(e,{...this.opts,...t})}formatDateTime(e,t){return this.dtFormatter(e,t).format()}formatDateTimeParts(e,t){return this.dtFormatter(e,t).formatToParts()}formatInterval(e,t){return this.dtFormatter(e.start,t).dtf.formatRange(e.start.toJSDate(),e.end.toJSDate())}resolvedOptions(e,t){return this.dtFormatter(e,t).resolvedOptions()}num(e,t=0){if(this.opts.forceSimple)return O(e,t);const r={...this.opts};return t>0&&(r.padTo=t),this.loc.numberFormatter(r).format(e)}formatDateTimeFromString(e,t){const r=this.loc.listingMode()==="en",s=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",i=(d,v)=>this.loc.extract(e,d,v),a=d=>e.isOffsetFixed&&e.offset===0&&d.allowZ?"Z":e.isValid?e.zone.formatOffset(e.ts,d.format):"",o=()=>r?vr(e):i({hour:"numeric",hourCycle:"h12"},"dayperiod"),u=(d,v)=>r?Ir(e,d):i(v?{month:d}:{month:d,day:"numeric"},"month"),l=(d,v)=>r?Nr(e,d):i(v?{weekday:d}:{weekday:d,month:"long",day:"numeric"},"weekday"),f=d=>{const v=N.macroTokenToFormatOpts(d);return v?this.formatWithSystemDefault(e,v):d},y=d=>r?Mr(e,d):i({era:d},"era"),T=d=>{switch(d){case"S":return this.num(e.millisecond);case"u":case"SSS":return this.num(e.millisecond,3);case"s":return this.num(e.second);case"ss":return this.num(e.second,2);case"uu":return this.num(Math.floor(e.millisecond/10),2);case"uuu":return this.num(Math.floor(e.millisecond/100));case"m":return this.num(e.minute);case"mm":return this.num(e.minute,2);case"h":return this.num(e.hour%12===0?12:e.hour%12);case"hh":return this.num(e.hour%12===0?12:e.hour%12,2);case"H":return this.num(e.hour);case"HH":return this.num(e.hour,2);case"Z":return a({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return a({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return a({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return e.zone.offsetName(e.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return e.zone.offsetName(e.ts,{format:"long",locale:this.loc.locale});case"z":return e.zoneName;case"a":return o();case"d":return s?i({day:"numeric"},"day"):this.num(e.day);case"dd":return s?i({day:"2-digit"},"day"):this.num(e.day,2);case"c":return this.num(e.weekday);case"ccc":return l("short",!0);case"cccc":return l("long",!0);case"ccccc":return l("narrow",!0);case"E":return this.num(e.weekday);case"EEE":return l("short",!1);case"EEEE":return l("long",!1);case"EEEEE":return l("narrow",!1);case"L":return s?i({month:"numeric",day:"numeric"},"month"):this.num(e.month);case"LL":return s?i({month:"2-digit",day:"numeric"},"month"):this.num(e.month,2);case"LLL":return u("short",!0);case"LLLL":return u("long",!0);case"LLLLL":return u("narrow",!0);case"M":return s?i({month:"numeric"},"month"):this.num(e.month);case"MM":return s?i({month:"2-digit"},"month"):this.num(e.month,2);case"MMM":return u("short",!1);case"MMMM":return u("long",!1);case"MMMMM":return u("narrow",!1);case"y":return s?i({year:"numeric"},"year"):this.num(e.year);case"yy":return s?i({year:"2-digit"},"year"):this.num(e.year.toString().slice(-2),2);case"yyyy":return s?i({year:"numeric"},"year"):this.num(e.year,4);case"yyyyyy":return s?i({year:"numeric"},"year"):this.num(e.year,6);case"G":return y("short");case"GG":return y("long");case"GGGGG":return y("narrow");case"kk":return this.num(e.weekYear.toString().slice(-2),2);case"kkkk":return this.num(e.weekYear,4);case"W":return this.num(e.weekNumber);case"WW":return this.num(e.weekNumber,2);case"n":return this.num(e.localWeekNumber);case"nn":return this.num(e.localWeekNumber,2);case"ii":return this.num(e.localWeekYear.toString().slice(-2),2);case"iiii":return this.num(e.localWeekYear,4);case"o":return this.num(e.ordinal);case"ooo":return this.num(e.ordinal,3);case"q":return this.num(e.quarter);case"qq":return this.num(e.quarter,2);case"X":return this.num(Math.floor(e.ts/1e3));case"x":return this.num(e.ts);default:return f(d)}};return St(N.parseFormat(t),T)}formatDurationFromString(e,t){const r=u=>{switch(u[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}},s=u=>l=>{const f=r(l);return f?this.num(u.get(f),l.length):l},i=N.parseFormat(t),a=i.reduce((u,{literal:l,val:f})=>l?u:u.concat(f),[]),o=e.shiftTo(...a.map(r).filter(u=>u));return St(i,s(o))}}const Sn=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function ne(...n){const e=n.reduce((t,r)=>t+r.source,"");return RegExp(`^${e}$`)}function re(...n){return e=>n.reduce(([t,r,s],i)=>{const[a,o,u]=i(e,s);return[{...t,...a},o||r,u]},[{},null,1]).slice(0,2)}function se(n,...e){if(n==null)return[null,null];for(const[t,r]of e){const s=t.exec(n);if(s)return r(s)}return[null,null]}function pn(...n){return(e,t)=>{const r={};let s;for(s=0;s<n.length;s++)r[n[s]]=U(e[t+s]);return[r,null,t+s]}}const On=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,xr=`(?:${On.source}?(?:\\[(${Sn.source})\\])?)?`,Xe=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,vn=RegExp(`${Xe.source}${xr}`),et=RegExp(`(?:T${vn.source})?`),br=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Fr=/(\d{4})-?W(\d\d)(?:-?(\d))?/,Vr=/(\d{4})-?(\d{3})/,Cr=pn("weekYear","weekNumber","weekDay"),Wr=pn("year","ordinal"),Lr=/(\d{4})-(\d\d)-(\d\d)/,Nn=RegExp(`${Xe.source} ?(?:${On.source}|(${Sn.source}))?`),Zr=RegExp(`(?: ${Nn.source})?`);function X(n,e,t){const r=n[e];return h(r)?t:U(r)}function $r(n,e){return[{year:X(n,e),month:X(n,e+1,1),day:X(n,e+2,1)},null,e+3]}function ie(n,e){return[{hours:X(n,e,0),minutes:X(n,e+1,0),seconds:X(n,e+2,0),milliseconds:Qe(n[e+3])},null,e+4]}function ge(n,e){const t=!n[e]&&!n[e+1],r=Ve(n[e+1],n[e+2]),s=t?null:I.instance(r);return[{},s,e+3]}function we(n,e){const t=n[e]?$.create(n[e]):null;return[{},t,e+1]}const Ar=RegExp(`^T?${Xe.source}$`),zr=/^-?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 Ur(n){const[e,t,r,s,i,a,o,u,l]=n,f=e[0]==="-",y=u&&u[0]==="-",T=(d,v=!1)=>d!==void 0&&(v||d&&f)?-d:d;return[{years:T(q(t)),months:T(q(r)),weeks:T(q(s)),days:T(q(i)),hours:T(q(a)),minutes:T(q(o)),seconds:T(q(u),u==="-0"),milliseconds:T(Qe(l),y)}]}const Rr={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function tt(n,e,t,r,s,i,a){const o={year:e.length===2?Je(U(e)):U(e),month:hn.indexOf(t)+1,day:U(r),hour:U(s),minute:U(i)};return a&&(o.second=U(a)),n&&(o.weekday=n.length>3?yn.indexOf(n)+1:gn.indexOf(n)+1),o}const qr=/^(?:(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 Hr(n){const[,e,t,r,s,i,a,o,u,l,f,y]=n,T=tt(e,s,r,t,i,a,o);let d;return u?d=Rr[u]:l?d=0:d=Ve(f,y),[T,new I(d)]}function Yr(n){return n.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const _r=/^(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$/,Pr=/^(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$/,Gr=/^(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 pt(n){const[,e,t,r,s,i,a,o]=n;return[tt(e,s,r,t,i,a,o),I.utcInstance]}function Jr(n){const[,e,t,r,s,i,a,o]=n;return[tt(e,o,t,r,s,i,a),I.utcInstance]}const Br=ne(br,et),jr=ne(Fr,et),Qr=ne(Vr,et),Kr=ne(vn),In=re($r,ie,ge,we),Xr=re(Cr,ie,ge,we),es=re(Wr,ie,ge,we),ts=re(ie,ge,we);function ns(n){return se(n,[Br,In],[jr,Xr],[Qr,es],[Kr,ts])}function rs(n){return se(Yr(n),[qr,Hr])}function ss(n){return se(n,[_r,pt],[Pr,pt],[Gr,Jr])}function is(n){return se(n,[zr,Ur])}const as=re(ie);function os(n){return se(n,[Ar,as])}const us=ne(Lr,Zr),ls=ne(Nn),cs=re(ie,ge,we);function fs(n){return se(n,[us,In],[ls,cs])}const Ot="Invalid Duration",Mn={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},ds={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3},...Mn},x=146097/400,B=146097/4800,hs={years:{quarters:4,months:12,weeks:x/7,days:x,hours:x*24,minutes:x*24*60,seconds:x*24*60*60,milliseconds:x*24*60*60*1e3},quarters:{months:3,weeks:x/28,days:x/4,hours:x*24/4,minutes:x*24*60/4,seconds:x*24*60*60/4,milliseconds:x*24*60*60*1e3/4},months:{weeks:B/7,days:B,hours:B*24,minutes:B*24*60,seconds:B*24*60*60,milliseconds:B*24*60*60*1e3},...Mn},Y=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],ms=Y.slice(0).reverse();function z(n,e,t=!1){const r={values:t?e.values:{...n.values,...e.values||{}},loc:n.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||n.conversionAccuracy,matrix:e.matrix||n.matrix};return new g(r)}function En(n,e){var t;let r=(t=e.milliseconds)!=null?t:0;for(const s of ms.slice(1))e[s]&&(r+=e[s]*n[s].milliseconds);return r}function vt(n,e){const t=En(n,e)<0?-1:1;Y.reduceRight((r,s)=>{if(h(e[s]))return r;if(r){const i=e[r]*t,a=n[s][r],o=Math.floor(i/a);e[s]+=o*t,e[r]-=o*a*t}return s},null),Y.reduce((r,s)=>{if(h(e[s]))return r;if(r){const i=e[r]%1;e[r]-=i,e[s]+=i*n[r][s]}return s},null)}function ys(n){const e={};for(const[t,r]of Object.entries(n))r!==0&&(e[t]=r);return e}class g{constructor(e){const t=e.conversionAccuracy==="longterm"||!1;let r=t?hs:ds;e.matrix&&(r=e.matrix),this.values=e.values,this.loc=e.loc||k.create(),this.conversionAccuracy=t?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=r,this.isLuxonDuration=!0}static fromMillis(e,t){return g.fromObject({milliseconds:e},t)}static fromObject(e,t={}){if(e==null||typeof e!="object")throw new M(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new g({values:xe(e,g.normalizeUnit),loc:k.fromObject(t),conversionAccuracy:t.conversionAccuracy,matrix:t.matrix})}static fromDurationLike(e){if(_(e))return g.fromMillis(e);if(g.isDuration(e))return e;if(typeof e=="object")return g.fromObject(e);throw new M(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,t){const[r]=is(e);return r?g.fromObject(r,t):g.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static fromISOTime(e,t){const[r]=os(e);return r?g.fromObject(r,t):g.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static invalid(e,t=null){if(!e)throw new M("need to specify a reason the Duration is invalid");const r=e instanceof W?e:new W(e,t);if(p.throwOnInvalid)throw new Hn(r);return new g({invalid:r})}static normalizeUnit(e){const t={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"}[e&&e.toLowerCase()];if(!t)throw new Lt(e);return t}static isDuration(e){return e&&e.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(e,t={}){const r={...t,floor:t.round!==!1&&t.floor!==!1};return this.isValid?N.create(this.loc,r).formatDurationFromString(this,e):Ot}toHuman(e={}){if(!this.isValid)return Ot;const t=Y.map(r=>{const s=this.values[r];return h(s)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...e,unit:r.slice(0,-1)}).format(s)}).filter(r=>r);return this.loc.listFormatter({type:"conjunction",style:e.listStyle||"narrow",...e}).format(t)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let e="P";return this.years!==0&&(e+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(e+=this.months+this.quarters*3+"M"),this.weeks!==0&&(e+=this.weeks+"W"),this.days!==0&&(e+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(e+="T"),this.hours!==0&&(e+=this.hours+"H"),this.minutes!==0&&(e+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(e+=Ke(this.seconds+this.milliseconds/1e3,3)+"S"),e==="P"&&(e+="T0S"),e}toISOTime(e={}){if(!this.isValid)return null;const t=this.toMillis();return t<0||t>=864e5?null:(e={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...e,includeOffset:!1},m.fromMillis(t,{zone:"UTC"}).toISOTime(e))}toJSON(){return this.toISO()}toString(){return this.toISO()}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Duration { values: ${JSON.stringify(this.values)} }`:`Duration { Invalid, reason: ${this.invalidReason} }`}toMillis(){return this.isValid?En(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(e){if(!this.isValid)return this;const t=g.fromDurationLike(e),r={};for(const s of Y)(ee(t.values,s)||ee(this.values,s))&&(r[s]=t.get(s)+this.get(s));return z(this,{values:r},!0)}minus(e){if(!this.isValid)return this;const t=g.fromDurationLike(e);return this.plus(t.negate())}mapUnits(e){if(!this.isValid)return this;const t={};for(const r of Object.keys(this.values))t[r]=dn(e(this.values[r],r));return z(this,{values:t},!0)}get(e){return this[g.normalizeUnit(e)]}set(e){if(!this.isValid)return this;const t={...this.values,...xe(e,g.normalizeUnit)};return z(this,{values:t})}reconfigure({locale:e,numberingSystem:t,conversionAccuracy:r,matrix:s}={}){const a={loc:this.loc.clone({locale:e,numberingSystem:t}),matrix:s,conversionAccuracy:r};return z(this,a)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;const e=this.toObject();return vt(this.matrix,e),z(this,{values:e},!0)}rescale(){if(!this.isValid)return this;const e=ys(this.normalize().shiftToAll().toObject());return z(this,{values:e},!0)}shiftTo(...e){if(!this.isValid)return this;if(e.length===0)return this;e=e.map(a=>g.normalizeUnit(a));const t={},r={},s=this.toObject();let i;for(const a of Y)if(e.indexOf(a)>=0){i=a;let o=0;for(const l in r)o+=this.matrix[l][a]*r[l],r[l]=0;_(s[a])&&(o+=s[a]);const u=Math.trunc(o);t[a]=u,r[a]=(o*1e3-u*1e3)/1e3}else _(s[a])&&(r[a]=s[a]);for(const a in r)r[a]!==0&&(t[i]+=a===i?r[a]:r[a]/this.matrix[i][a]);return vt(this.matrix,t),z(this,{values:t},!0)}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const e={};for(const t of Object.keys(this.values))e[t]=this.values[t]===0?0:-this.values[t];return z(this,{values:e},!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 this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(e){if(!this.isValid||!e.isValid||!this.loc.equals(e.loc))return!1;function t(r,s){return r===void 0||r===0?s===void 0||s===0:r===s}for(const r of Y)if(!t(this.values[r],e.values[r]))return!1;return!0}}const j="Invalid Interval";function gs(n,e){return!n||!n.isValid?S.invalid("missing or invalid start"):!e||!e.isValid?S.invalid("missing or invalid end"):e<n?S.invalid("end before start",`The end of an interval must be after its start, but you had start=${n.toISO()} and end=${e.toISO()}`):null}class S{constructor(e){this.s=e.start,this.e=e.end,this.invalid=e.invalid||null,this.isLuxonInterval=!0}static invalid(e,t=null){if(!e)throw new M("need to specify a reason the Interval is invalid");const r=e instanceof W?e:new W(e,t);if(p.throwOnInvalid)throw new qn(r);return new S({invalid:r})}static fromDateTimes(e,t){const r=le(e),s=le(t),i=gs(r,s);return i??new S({start:r,end:s})}static after(e,t){const r=g.fromDurationLike(t),s=le(e);return S.fromDateTimes(s,s.plus(r))}static before(e,t){const r=g.fromDurationLike(t),s=le(e);return S.fromDateTimes(s.minus(r),s)}static fromISO(e,t){const[r,s]=(e||"").split("/",2);if(r&&s){let i,a;try{i=m.fromISO(r,t),a=i.isValid}catch{a=!1}let o,u;try{o=m.fromISO(s,t),u=o.isValid}catch{u=!1}if(a&&u)return S.fromDateTimes(i,o);if(a){const l=g.fromISO(s,t);if(l.isValid)return S.after(i,l)}else if(u){const l=g.fromISO(r,t);if(l.isValid)return S.before(o,l)}}return S.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static isInterval(e){return e&&e.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(e="milliseconds"){return this.isValid?this.toDuration(e).get(e):NaN}count(e="milliseconds",t){if(!this.isValid)return NaN;const r=this.start.startOf(e,t);let s;return t!=null&&t.useLocaleWeeks?s=this.end.reconfigure({locale:r.locale}):s=this.end,s=s.startOf(e,t),Math.floor(s.diff(r,e).get(e))+(s.valueOf()!==this.end.valueOf())}hasSame(e){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,e):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(e){return this.isValid?this.s>e:!1}isBefore(e){return this.isValid?this.e<=e:!1}contains(e){return this.isValid?this.s<=e&&this.e>e:!1}set({start:e,end:t}={}){return this.isValid?S.fromDateTimes(e||this.s,t||this.e):this}splitAt(...e){if(!this.isValid)return[];const t=e.map(le).filter(a=>this.contains(a)).sort((a,o)=>a.toMillis()-o.toMillis()),r=[];let{s}=this,i=0;for(;s<this.e;){const a=t[i]||this.e,o=+a>+this.e?this.e:a;r.push(S.fromDateTimes(s,o)),s=o,i+=1}return r}splitBy(e){const t=g.fromDurationLike(e);if(!this.isValid||!t.isValid||t.as("milliseconds")===0)return[];let{s:r}=this,s=1,i;const a=[];for(;r<this.e;){const o=this.start.plus(t.mapUnits(u=>u*s));i=+o>+this.e?this.e:o,a.push(S.fromDateTimes(r,i)),r=i,s+=1}return a}divideEqually(e){return this.isValid?this.splitBy(this.length()/e).slice(0,e):[]}overlaps(e){return this.e>e.s&&this.s<e.e}abutsStart(e){return this.isValid?+this.e==+e.s:!1}abutsEnd(e){return this.isValid?+e.e==+this.s:!1}engulfs(e){return this.isValid?this.s<=e.s&&this.e>=e.e:!1}equals(e){return!this.isValid||!e.isValid?!1:this.s.equals(e.s)&&this.e.equals(e.e)}intersection(e){if(!this.isValid)return this;const t=this.s>e.s?this.s:e.s,r=this.e<e.e?this.e:e.e;return t>=r?null:S.fromDateTimes(t,r)}union(e){if(!this.isValid)return this;const t=this.s<e.s?this.s:e.s,r=this.e>e.e?this.e:e.e;return S.fromDateTimes(t,r)}static merge(e){const[t,r]=e.sort((s,i)=>s.s-i.s).reduce(([s,i],a)=>i?i.overlaps(a)||i.abutsStart(a)?[s,i.union(a)]:[s.concat([i]),a]:[s,a],[[],null]);return r&&t.push(r),t}static xor(e){let t=null,r=0;const s=[],i=e.map(u=>[{time:u.s,type:"s"},{time:u.e,type:"e"}]),a=Array.prototype.concat(...i),o=a.sort((u,l)=>u.time-l.time);for(const u of o)r+=u.type==="s"?1:-1,r===1?t=u.time:(t&&+t!=+u.time&&s.push(S.fromDateTimes(t,u.time)),t=null);return S.merge(s)}difference(...e){return S.xor([this].concat(e)).map(t=>this.intersection(t)).filter(t=>t&&!t.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:j}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Interval { start: ${this.s.toISO()}, end: ${this.e.toISO()} }`:`Interval { Invalid, reason: ${this.invalidReason} }`}toLocaleString(e=Me,t={}){return this.isValid?N.create(this.s.loc.clone(t),e).formatInterval(this):j}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:j}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:j}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:j}toFormat(e,{separator:t=" – "}={}){return this.isValid?`${this.s.toFormat(e)}${t}${this.e.toFormat(e)}`:j}toDuration(e,t){return this.isValid?this.e.diff(this.s,e,t):g.invalid(this.invalidReason)}mapEndpoints(e){return S.fromDateTimes(e(this.s),e(this.e))}}class fe{static hasDST(e=p.defaultZone){const t=m.now().setZone(e).set({month:12});return!e.isUniversal&&t.offset!==t.set({month:6}).offset}static isValidIANAZone(e){return $.isValidZone(e)}static normalizeZone(e){return R(e,p.defaultZone)}static getStartOfWeek({locale:e=null,locObj:t=null}={}){return(t||k.create(e)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:e=null,locObj:t=null}={}){return(t||k.create(e)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:e=null,locObj:t=null}={}){return(t||k.create(e)).getWeekendDays().slice()}static months(e="long",{locale:t=null,numberingSystem:r=null,locObj:s=null,outputCalendar:i="gregory"}={}){return(s||k.create(t,r,i)).months(e)}static monthsFormat(e="long",{locale:t=null,numberingSystem:r=null,locObj:s=null,outputCalendar:i="gregory"}={}){return(s||k.create(t,r,i)).months(e,!0)}static weekdays(e="long",{locale:t=null,numberingSystem:r=null,locObj:s=null}={}){return(s||k.create(t,r,null)).weekdays(e)}static weekdaysFormat(e="long",{locale:t=null,numberingSystem:r=null,locObj:s=null}={}){return(s||k.create(t,r,null)).weekdays(e,!0)}static meridiems({locale:e=null}={}){return k.create(e).meridiems()}static eras(e="short",{locale:t=null}={}){return k.create(t,null,"gregory").eras(e)}static features(){return{relative:ln(),localeWeek:cn()}}}function Nt(n,e){const t=s=>s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),r=t(e)-t(n);return Math.floor(g.fromMillis(r).as("days"))}function ws(n,e,t){const r=[["years",(u,l)=>l.year-u.year],["quarters",(u,l)=>l.quarter-u.quarter+(l.year-u.year)*4],["months",(u,l)=>l.month-u.month+(l.year-u.year)*12],["weeks",(u,l)=>{const f=Nt(u,l);return(f-f%7)/7}],["days",Nt]],s={},i=n;let a,o;for(const[u,l]of r)t.indexOf(u)>=0&&(a=u,s[u]=l(n,e),o=i.plus(s),o>e?(s[u]--,n=i.plus(s),n>e&&(o=n,s[u]--,n=i.plus(s))):n=o);return[n,s,o,a]}function ks(n,e,t,r){let[s,i,a,o]=ws(n,e,t);const u=e-s,l=t.filter(y=>["hours","minutes","seconds","milliseconds"].indexOf(y)>=0);l.length===0&&(a<e&&(a=s.plus({[o]:1})),a!==s&&(i[o]=(i[o]||0)+u/(a-s)));const f=g.fromObject(i,r);return l.length>0?g.fromMillis(u,r).shiftTo(...l).plus(f):f}const nt={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},It={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]},Ts=nt.hanidec.replace(/[\[|\]]/g,"").split("");function Ss(n){let e=parseInt(n,10);if(isNaN(e)){e="";for(let t=0;t<n.length;t++){const r=n.charCodeAt(t);if(n[t].search(nt.hanidec)!==-1)e+=Ts.indexOf(n[t]);else for(const s in It){const[i,a]=It[s];r>=i&&r<=a&&(e+=r-i)}}return parseInt(e,10)}else return e}function V({numberingSystem:n},e=""){return new RegExp(`${nt[n||"latn"]}${e}`)}const ps="missing Intl.DateTimeFormat.formatToParts support";function w(n,e=t=>t){return{regex:n,deser:([t])=>e(Ss(t))}}const Os=" ",Dn=`[ ${Os}]`,xn=new RegExp(Dn,"g");function vs(n){return n.replace(/\./g,"\\.?").replace(xn,Dn)}function Mt(n){return n.replace(/\./g,"").replace(xn," ").toLowerCase()}function C(n,e){return n===null?null:{regex:RegExp(n.map(vs).join("|")),deser:([t])=>n.findIndex(r=>Mt(t)===Mt(r))+e}}function Et(n,e){return{regex:n,deser:([,t,r])=>Ve(t,r),groups:e}}function Se(n){return{regex:n,deser:([e])=>e}}function Ns(n){return n.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Is(n,e){const t=V(e),r=V(e,"{2}"),s=V(e,"{3}"),i=V(e,"{4}"),a=V(e,"{6}"),o=V(e,"{1,2}"),u=V(e,"{1,3}"),l=V(e,"{1,6}"),f=V(e,"{1,9}"),y=V(e,"{2,4}"),T=V(e,"{4,6}"),d=Z=>({regex:RegExp(Ns(Z.val)),deser:([J])=>J,literal:!0}),G=(Z=>{if(n.literal)return d(Z);switch(Z.val){case"G":return C(e.eras("short"),0);case"GG":return C(e.eras("long"),0);case"y":return w(l);case"yy":return w(y,Je);case"yyyy":return w(i);case"yyyyy":return w(T);case"yyyyyy":return w(a);case"M":return w(o);case"MM":return w(r);case"MMM":return C(e.months("short",!0),1);case"MMMM":return C(e.months("long",!0),1);case"L":return w(o);case"LL":return w(r);case"LLL":return C(e.months("short",!1),1);case"LLLL":return C(e.months("long",!1),1);case"d":return w(o);case"dd":return w(r);case"o":return w(u);case"ooo":return w(s);case"HH":return w(r);case"H":return w(o);case"hh":return w(r);case"h":return w(o);case"mm":return w(r);case"m":return w(o);case"q":return w(o);case"qq":return w(r);case"s":return w(o);case"ss":return w(r);case"S":return w(u);case"SSS":return w(s);case"u":return Se(f);case"uu":return Se(o);case"uuu":return w(t);case"a":return C(e.meridiems(),0);case"kkkk":return w(i);case"kk":return w(y,Je);case"W":return w(o);case"WW":return w(r);case"E":case"c":return w(t);case"EEE":return C(e.weekdays("short",!1),1);case"EEEE":return C(e.weekdays("long",!1),1);case"ccc":return C(e.weekdays("short",!0),1);case"cccc":return C(e.weekdays("long",!0),1);case"Z":case"ZZ":return Et(new RegExp(`([+-]${o.source})(?::(${r.source}))?`),2);case"ZZZ":return Et(new RegExp(`([+-]${o.source})(${r.source})?`),2);case"z":return Se(/[a-z_+-/]{1,256}?/i);case" ":return Se(/[^\S\n\r]/);default:return d(Z)}})(n)||{invalidReason:ps};return G.token=n,G}const Ms={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",hour12:{numeric:"h","2-digit":"hh"},hour24:{numeric:"H","2-digit":"HH"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};function Es(n,e,t){const{type:r,value:s}=n;if(r==="literal"){const u=/^\s+$/.test(s);return{literal:!u,val:u?" ":s}}const i=e[r];let a=r;r==="hour"&&(e.hour12!=null?a=e.hour12?"hour12":"hour24":e.hourCycle!=null?e.hourCycle==="h11"||e.hourCycle==="h12"?a="hour12":a="hour24":a=t.hour12?"hour12":"hour24");let o=Ms[a];if(typeof o=="object"&&(o=o[i]),o)return{literal:!1,val:o}}function Ds(n){return[`^${n.map(t=>t.regex).reduce((t,r)=>`${t}(${r.source})`,"")}$`,n]}function xs(n,e,t){const r=n.match(e);if(r){const s={};let i=1;for(const a in t)if(ee(t,a)){const o=t[a],u=o.groups?o.groups+1:1;!o.literal&&o.token&&(s[o.token.val[0]]=o.deser(r.slice(i,i+u))),i+=u}return[r,s]}else return[r,{}]}function bs(n){const e=i=>{switch(i){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}};let t=null,r;return h(n.z)||(t=$.create(n.z)),h(n.Z)||(t||(t=new I(n.Z)),r=n.Z),h(n.q)||(n.M=(n.q-1)*3+1),h(n.h)||(n.h<12&&n.a===1?n.h+=12:n.h===12&&n.a===0&&(n.h=0)),n.G===0&&n.y&&(n.y=-n.y),h(n.u)||(n.S=Qe(n.u)),[Object.keys(n).reduce((i,a)=>{const o=e(a);return o&&(i[o]=n[a]),i},{}),t,r]}let Ae=null;function Fs(){return Ae||(Ae=m.fromMillis(1555555555555)),Ae}function Vs(n,e){if(n.literal)return n;const t=N.macroTokenToFormatOpts(n.val),r=Vn(t,e);return r==null||r.includes(void 0)?n:r}function bn(n,e){return Array.prototype.concat(...n.map(t=>Vs(t,e)))}function Fn(n,e,t){const r=bn(N.parseFormat(t),n),s=r.map(a=>Is(a,n)),i=s.find(a=>a.invalidReason);if(i)return{input:e,tokens:r,invalidReason:i.invalidReason};{const[a,o]=Ds(s),u=RegExp(a,"i"),[l,f]=xs(e,u,o),[y,T,d]=f?bs(f):[null,null,void 0];if(ee(f,"a")&&ee(f,"H"))throw new Q("Can't include meridiem when specifying 24-hour format");return{input:e,tokens:r,regex:u,rawMatches:l,matches:f,result:y,zone:T,specificOffset:d}}}function Cs(n,e,t){const{result:r,z