Files
SIGE-WEB-snapshot/wp-content/plugins/broken-link-checker-seo/dist/assets/js/datetime.v8fTPlup.js

2 lines
67 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{S as Rn}from"./Close.CP9mbBVR.js";import{_ as qn}from"./dynamic-import-helper.DN_NaYa5.js";import{r as Hn,o as st,c as it,H as Yn,a as _n,E as Pn,I as Gn}from"./index.9_UWDUyH.js";const Jn={emits:["close-alert"],components:{SvgClose:Rn},props:{type:{type:String,default(){return"blue"}},size:{type:String,default(){return"medium"}},showClose:Boolean}};function Bn(n,e,t,r,s,i){const a=Hn("svg-close");return st(),it("div",{class:Gn(["aioseo-alert",{[t.type]:t.type,[t.size]:t.size}])},[Yn(n.$slots,"default"),t.showClose?(st(),it("span",{key:0,onClick:e[0]||(e[0]=o=>n.$emit("close-alert")),class:"aioseo-alert-close"},[_n(a)])):Pn("",!0)],2)}const Ks=qn(Jn,[["render",Bn]]);class _ extends Error{}class jn extends _{constructor(e){super(`Invalid DateTime: ${e.toMessage()}`)}}class Qn extends _{constructor(e){super(`Invalid Interval: ${e.toMessage()}`)}}class Kn extends _{constructor(e){super(`Invalid Duration: ${e.toMessage()}`)}}class j extends _{}class $t extends _{constructor(e){super(`Invalid unit ${e}`)}}class E extends _{}class Z extends _{constructor(){super("Zone is an abstract class")}}const c="numeric",W="short",M="long",Ne={year:c,month:c,day:c},Zt={year:c,month:W,day:c},Xn={year:c,month:W,day:c,weekday:W},At={year:c,month:M,day:c},zt={year:c,month:M,day:c,weekday:M},Ut={hour:c,minute:c},Rt={hour:c,minute:c,second:c},qt={hour:c,minute:c,second:c,timeZoneName:W},Ht={hour:c,minute:c,second:c,timeZoneName:M},Yt={hour:c,minute:c,hourCycle:"h23"},_t={hour:c,minute:c,second:c,hourCycle:"h23"},Pt={hour:c,minute:c,second:c,hourCycle:"h23",timeZoneName:W},Gt={hour:c,minute:c,second:c,hourCycle:"h23",timeZoneName:M},Jt={year:c,month:c,day:c,hour:c,minute:c},Bt={year:c,month:c,day:c,hour:c,minute:c,second:c},jt={year:c,month:W,day:c,hour:c,minute:c},Qt={year:c,month:W,day:c,hour:c,minute:c,second:c},er={year:c,month:W,day:c,weekday:W,hour:c,minute:c},Kt={year:c,month:M,day:c,hour:c,minute:c,timeZoneName:W},Xt={year:c,month:M,day:c,hour:c,minute:c,second:c,timeZoneName:W},en={year:c,month:M,day:c,weekday:M,hour:c,minute:c,timeZoneName:M},tn={year:c,month:M,day:c,weekday:M,hour:c,minute:c,second:c,timeZoneName:M};class fe{get type(){throw new Z}get name(){throw new Z}get ianaName(){return this.name}get isUniversal(){throw new Z}offsetName(e,t){throw new Z}formatOffset(e,t){throw new Z}offset(e){throw new Z}equals(e){throw new Z}get isValid(){throw new Z}}let We=null;class De extends fe{static get instance(){return We===null&&(We=new De),We}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 le(this.offset(e),t)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}}let Oe={};function tr(n){return Oe[n]||(Oe[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"})),Oe[n]}const nr={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function rr(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 sr(n,e){const t=n.formatToParts(e),r=[];for(let s=0;s<t.length;s++){const{type:i,value:a}=t[s],o=nr[i];i==="era"?r[o]=a:h(o)||(r[o]=parseInt(a,10))}return r}let ye={};class $ extends fe{static create(e){return ye[e]||(ye[e]=new $(e)),ye[e]}static resetCache(){ye={},Oe={}}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 le(this.offset(e),t)}offset(e){const t=new Date(e);if(isNaN(t))return NaN;const r=tr(this.name);let[s,i,a,o,u,l,f]=r.formatToParts?sr(r,t):rr(r,t);o==="BC"&&(s=-Math.abs(s)+1);const T=be({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 at={};function ir(n,e={}){const t=JSON.stringify([n,e]);let r=at[t];return r||(r=new Intl.ListFormat(n,e),at[t]=r),r}let qe={};function He(n,e={}){const t=JSON.stringify([n,e]);let r=qe[t];return r||(r=new Intl.DateTimeFormat(n,e),qe[t]=r),r}let Ye={};function ar(n,e={}){const t=JSON.stringify([n,e]);let r=Ye[t];return r||(r=new Intl.NumberFormat(n,e),Ye[t]=r),r}let _e={};function or(n,e={}){const{base:t,...r}=e,s=JSON.stringify([n,r]);let i=_e[s];return i||(i=new Intl.RelativeTimeFormat(n,e),_e[s]=i),i}let ue=null;function ur(){return ue||(ue=new Intl.DateTimeFormat().resolvedOptions().locale,ue)}let ot={};function lr(n){let e=ot[n];if(!e){const t=new Intl.Locale(n);e="getWeekInfo"in t?t.getWeekInfo():t.weekInfo,ot[n]=e}return e}function cr(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=He(n).resolvedOptions(),s=n}catch{const u=n.substring(0,t);r=He(u).resolvedOptions(),s=u}const{numberingSystem:i,calendar:a}=r;return[s,i,a]}}function fr(n,e,t){return(t||e)&&(n.includes("-u-")||(n+="-u"),t&&(n+=`-ca-${t}`),e&&(n+=`-nu-${e}`)),n}function dr(n){const e=[];for(let t=1;t<=12;t++){const r=m.utc(2009,t,1);e.push(n(r))}return e}function hr(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 ge(n,e,t,r){const s=n.listingMode();return s==="error"?null:s==="en"?t(e):r(e)}function mr(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 yr{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=ar(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):Qe(e,3);return O(t,this.padTo)}}}class gr{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=He(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 wr{constructor(e,t,r){this.opts={style:"long",...r},!t&&ln()&&(this.rtf=or(e,r))}format(e,t){return this.rtf?this.rtf.format(e,t):Zr(t,e,this.opts.numeric,this.opts.style!=="long")}formatToParts(e,t){return this.rtf?this.rtf.formatToParts(e,t):[]}}const kr={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":ur()),u=t||p.defaultNumberingSystem,l=r||p.defaultOutputCalendar,f=Pe(s)||p.defaultWeekSettings;return new k(o,u,l,f,a)}static resetCache(){ue=null,qe={},Ye={},_e={}}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]=cr(e);this.locale=a,this.numberingSystem=t||o||null,this.outputCalendar=r||u||null,this.weekSettings=s,this.intl=fr(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=mr(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,Pe(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 ge(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]=dr(i=>this.extract(i,r,"month"))),this.monthsCache[s][e]})}weekdays(e,t=!1){return ge(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]=hr(i=>this.extract(i,r,"weekday"))),this.weekdaysCache[s][e]})}meridiems(){return ge(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 ge(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 yr(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,t={}){return new gr(e,this.intl,t)}relFormatter(e={}){return new wr(this.intl,this.isEnglish(),e)}listFormatter(e={}){return ir(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()?lr(this.locale):kr}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 Le=null;class I extends fe{static get utcInstance(){return Le===null&&(Le=new I(0)),Le}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(Fe(t[1],t[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${le(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${le(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,t){return le(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 Tr extends fe{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 U(n,e){if(h(n)||n===null)return e;if(n instanceof fe)return n;if(Or(n)){const t=n.toLowerCase();return t==="default"?e:t==="local"||t==="system"?De.instance:t==="utc"||t==="gmt"?I.utcInstance:I.parseSpecifier(t)||$.create(n)}else return Y(n)?I.instance(n):typeof n=="object"&&"offset"in n&&typeof n.offset=="function"?n:new Tr(n)}let ut=()=>Date.now(),lt="system",ct=null,ft=null,dt=null,ht=60,mt,yt=null;class p{static get now(){return ut}static set now(e){ut=e}static set defaultZone(e){lt=e}static get defaultZone(){return U(lt,De.instance)}static get defaultLocale(){return ct}static set defaultLocale(e){ct=e}static get defaultNumberingSystem(){return ft}static set defaultNumberingSystem(e){ft=e}static get defaultOutputCalendar(){return dt}static set defaultOutputCalendar(e){dt=e}static get defaultWeekSettings(){return yt}static set defaultWeekSettings(e){yt=Pe(e)}static get twoDigitCutoffYear(){return ht}static set twoDigitCutoffYear(e){ht=e%100}static get throwOnInvalid(){return mt}static set throwOnInvalid(e){mt=e}static resetCaches(){k.resetCache(),$.resetCache()}}class V{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 x(n,e){return new V("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${n}, which is invalid`)}function Je(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+(de(n)?rn:nn)[e-1]}function an(n,e){const t=de(n)?rn:nn,r=t.findIndex(i=>i<e),s=e-t[r];return{month:r+1,day:s}}function Be(n,e){return(n-e+7)%7+1}function Ie(n,e=4,t=1){const{year:r,month:s,day:i}=n,a=sn(r,s,i),o=Be(Je(r,s,i),t);let u=Math.floor((a-o+14-e)/7),l;return u<1?(l=r-1,u=ce(l,e,t)):u>ce(r,e,t)?(l=r+1,u=1):l=r,{weekYear:l,weekNumber:u,weekday:o,...Ce(n)}}function gt(n,e=4,t=1){const{weekYear:r,weekNumber:s,weekday:i}=n,a=Be(Je(r,1,e),t),o=Q(r);let u=s*7+i-a-7+e,l;u<1?(l=r-1,u+=Q(l)):u>o?(l=r+1,u-=Q(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 wt(n){const{year:e,ordinal:t}=n,{month:r,day:s}=an(e,t);return{year:e,month:r,day:s,...Ce(n)}}function kt(n,e){if(!h(n.localWeekday)||!h(n.localWeekNumber)||!h(n.localWeekYear)){if(!h(n.weekday)||!h(n.weekNumber)||!h(n.weekYear))throw new j("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 Sr(n,e=4,t=1){const r=xe(n.weekYear),s=b(n.weekNumber,1,ce(n.weekYear,e,t)),i=b(n.weekday,1,7);return r?s?i?!1:x("weekday",n.weekday):x("week",n.weekNumber):x("weekYear",n.weekYear)}function pr(n){const e=xe(n.year),t=b(n.ordinal,1,Q(n.year));return e?t?!1:x("ordinal",n.ordinal):x("year",n.year)}function on(n){const e=xe(n.year),t=b(n.month,1,12),r=b(n.day,1,Ee(n.year,n.month));return e?t?r?!1:x("day",n.day):x("month",n.month):x("year",n.year)}function un(n){const{hour:e,minute:t,second:r,millisecond:s}=n,i=b(e,0,23)||e===24&&t===0&&r===0&&s===0,a=b(t,0,59),o=b(r,0,59),u=b(s,0,999);return i?a?o?u?!1:x("millisecond",s):x("second",r):x("minute",t):x("hour",e)}function h(n){return typeof n>"u"}function Y(n){return typeof n=="number"}function xe(n){return typeof n=="number"&&n%1===0}function Or(n){return typeof n=="string"}function vr(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 Nr(n){return Array.isArray(n)?n:[n]}function Tt(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 Ir(n,e){return e.reduce((t,r)=>(t[r]=n[r],t),{})}function X(n,e){return Object.prototype.hasOwnProperty.call(n,e)}function Pe(n){if(n==null)return null;if(typeof n!="object")throw new E("Week settings must be an object");if(!b(n.firstDay,1,7)||!b(n.minimalDays,1,7)||!Array.isArray(n.weekend)||n.weekend.some(e=>!b(e,1,7)))throw new E("Invalid week settings");return{firstDay:n.firstDay,minimalDays:n.minimalDays,weekend:Array.from(n.weekend)}}function b(n,e,t){return xe(n)&&n>=e&&n<=t}function Er(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 z(n){if(!(h(n)||n===null||n===""))return parseInt(n,10)}function R(n){if(!(h(n)||n===null||n===""))return parseFloat(n)}function je(n){if(!(h(n)||n===null||n==="")){const e=parseFloat("0."+n)*1e3;return Math.floor(e)}}function Qe(n,e,t=!1){const r=10**e;return(t?Math.trunc:Math.round)(n*r)/r}function de(n){return n%4===0&&(n%100!==0||n%400===0)}function Q(n){return de(n)?366:365}function Ee(n,e){const t=Er(e-1,12)+1,r=n+(e-t)/12;return t===2?de(r)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][t-1]}function be(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 St(n,e,t){return-Be(Je(n,1,e),t)+e-1}function ce(n,e=4,t=1){const r=St(n,e,t),s=St(n+1,e,t);return(Q(n)-r+s)/7}function Ge(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 Fe(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 E(`Invalid unit value ${n}`);return e}function Me(n,e){const t={};for(const r in n)if(X(n,r)){const s=n[r];if(s==null)continue;t[e(r)]=dn(s)}return t}function le(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 Ir(n,["hour","minute","second","millisecond"])}const Mr=["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"],Dr=["J","F","M","A","M","J","J","A","S","O","N","D"];function mn(n){switch(n){case"narrow":return[...Dr];case"short":return[...hn];case"long":return[...Mr];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"],xr=["M","T","W","T","F","S","S"];function wn(n){switch(n){case"narrow":return[...xr];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"],br=["Before Christ","Anno Domini"],Fr=["BC","AD"],Cr=["B","A"];function Tn(n){switch(n){case"narrow":return[...Cr];case"short":return[...Fr];case"long":return[...br];default:return null}}function Vr(n){return kn[n.hour<12?0:1]}function Wr(n,e){return wn(e)[n.weekday-1]}function Lr(n,e){return mn(e)[n.month-1]}function $r(n,e){return Tn(e)[n.year<0?0:1]}function Zr(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 pt(n,e){let t="";for(const r of n)r.literal?t+=r.val:t+=e(r.val);return t}const Ar={D:Ne,DD:Zt,DDD:At,DDDD:zt,t:Ut,tt:Rt,ttt:qt,tttt:Ht,T:Yt,TT:_t,TTT:Pt,TTTT:Gt,f:Jt,ff:jt,fff:Kt,ffff:en,F:Bt,FF:Qt,FFF:Xt,FFFF:tn};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 Ar[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?Lr(e,d):i(v?{month:d}:{month:d,day:"numeric"},"month"),l=(d,v)=>r?Wr(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?$r(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 pt(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 pt(i,s(o))}}const Sn=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function ee(...n){const e=n.reduce((t,r)=>t+r.source,"");return RegExp(`^${e}$`)}function te(...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 ne(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]]=z(e[t+s]);return[r,null,t+s]}}const On=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,zr=`(?:${On.source}?(?:\\[(${Sn.source})\\])?)?`,Ke=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,vn=RegExp(`${Ke.source}${zr}`),Xe=RegExp(`(?:T${vn.source})?`),Ur=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Rr=/(\d{4})-?W(\d\d)(?:-?(\d))?/,qr=/(\d{4})-?(\d{3})/,Hr=pn("weekYear","weekNumber","weekDay"),Yr=pn("year","ordinal"),_r=/(\d{4})-(\d\d)-(\d\d)/,Nn=RegExp(`${Ke.source} ?(?:${On.source}|(${Sn.source}))?`),Pr=RegExp(`(?: ${Nn.source})?`);function K(n,e,t){const r=n[e];return h(r)?t:z(r)}function Gr(n,e){return[{year:K(n,e),month:K(n,e+1,1),day:K(n,e+2,1)},null,e+3]}function re(n,e){return[{hours:K(n,e,0),minutes:K(n,e+1,0),seconds:K(n,e+2,0),milliseconds:je(n[e+3])},null,e+4]}function he(n,e){const t=!n[e]&&!n[e+1],r=Fe(n[e+1],n[e+2]),s=t?null:I.instance(r);return[{},s,e+3]}function me(n,e){const t=n[e]?$.create(n[e]):null;return[{},t,e+1]}const Jr=RegExp(`^T?${Ke.source}$`),Br=/^-?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 jr(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(R(t)),months:T(R(r)),weeks:T(R(s)),days:T(R(i)),hours:T(R(a)),minutes:T(R(o)),seconds:T(R(u),u==="-0"),milliseconds:T(je(l),y)}]}const Qr={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 et(n,e,t,r,s,i,a){const o={year:e.length===2?Ge(z(e)):z(e),month:hn.indexOf(t)+1,day:z(r),hour:z(s),minute:z(i)};return a&&(o.second=z(a)),n&&(o.weekday=n.length>3?yn.indexOf(n)+1:gn.indexOf(n)+1),o}const Kr=/^(?:(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 Xr(n){const[,e,t,r,s,i,a,o,u,l,f,y]=n,T=et(e,s,r,t,i,a,o);let d;return u?d=Qr[u]:l?d=0:d=Fe(f,y),[T,new I(d)]}function es(n){return n.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const ts=/^(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$/,ns=/^(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$/,rs=/^(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 Ot(n){const[,e,t,r,s,i,a,o]=n;return[et(e,s,r,t,i,a,o),I.utcInstance]}function ss(n){const[,e,t,r,s,i,a,o]=n;return[et(e,o,t,r,s,i,a),I.utcInstance]}const is=ee(Ur,Xe),as=ee(Rr,Xe),os=ee(qr,Xe),us=ee(vn),In=te(Gr,re,he,me),ls=te(Hr,re,he,me),cs=te(Yr,re,he,me),fs=te(re,he,me);function ds(n){return ne(n,[is,In],[as,ls],[os,cs],[us,fs])}function hs(n){return ne(es(n),[Kr,Xr])}function ms(n){return ne(n,[ts,Ot],[ns,Ot],[rs,ss])}function ys(n){return ne(n,[Br,jr])}const gs=te(re);function ws(n){return ne(n,[Jr,gs])}const ks=ee(_r,Pr),Ts=ee(Nn),Ss=te(re,he,me);function ps(n){return ne(n,[ks,In],[Ts,Ss])}const vt="Invalid Duration",En={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}},Os={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},...En},D=146097/400,J=146097/4800,vs={years:{quarters:4,months:12,weeks:D/7,days:D,hours:D*24,minutes:D*24*60,seconds:D*24*60*60,milliseconds:D*24*60*60*1e3},quarters:{months:3,weeks:D/28,days:D/4,hours:D*24/4,minutes:D*24*60/4,seconds:D*24*60*60/4,milliseconds:D*24*60*60*1e3/4},months:{weeks:J/7,days:J,hours:J*24,minutes:J*24*60,seconds:J*24*60*60,milliseconds:J*24*60*60*1e3},...En},H=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Ns=H.slice(0).reverse();function A(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 Mn(n,e){let t=e.milliseconds??0;for(const r of Ns.slice(1))e[r]&&(t+=e[r]*n[r].milliseconds);return t}function Nt(n,e){const t=Mn(n,e)<0?-1:1;H.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),H.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 Is(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?vs:Os;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 E(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new g({values:Me(e,g.normalizeUnit),loc:k.fromObject(t),conversionAccuracy:t.conversionAccuracy,matrix:t.matrix})}static fromDurationLike(e){if(Y(e))return g.fromMillis(e);if(g.isDuration(e))return e;if(typeof e=="object")return g.fromObject(e);throw new E(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,t){const[r]=ys(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]=ws(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 E("need to specify a reason the Duration is invalid");const r=e instanceof V?e:new V(e,t);if(p.throwOnInvalid)throw new Kn(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 $t(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):vt}toHuman(e={}){if(!this.isValid)return vt;const t=H.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+=Qe(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?Mn(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 H)(X(t.values,s)||X(this.values,s))&&(r[s]=t.get(s)+this.get(s));return A(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 A(this,{values:t},!0)}get(e){return this[g.normalizeUnit(e)]}set(e){if(!this.isValid)return this;const t={...this.values,...Me(e,g.normalizeUnit)};return A(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 A(this,a)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;const e=this.toObject();return Nt(this.matrix,e),A(this,{values:e},!0)}rescale(){if(!this.isValid)return this;const e=Is(this.normalize().shiftToAll().toObject());return A(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 H)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;Y(s[a])&&(o+=s[a]);const u=Math.trunc(o);t[a]=u,r[a]=(o*1e3-u*1e3)/1e3}else Y(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 Nt(this.matrix,t),A(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 A(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 H)if(!t(this.values[r],e.values[r]))return!1;return!0}}const B="Invalid Interval";function Es(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 E("need to specify a reason the Interval is invalid");const r=e instanceof V?e:new V(e,t);if(p.throwOnInvalid)throw new Qn(r);return new S({invalid:r})}static fromDateTimes(e,t){const r=oe(e),s=oe(t),i=Es(r,s);return i??new S({start:r,end:s})}static after(e,t){const r=g.fromDurationLike(t),s=oe(e);return S.fromDateTimes(s,s.plus(r))}static before(e,t){const r=g.fromDurationLike(t),s=oe(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(oe).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()})`:B}[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=Ne,t={}){return this.isValid?N.create(this.s.loc.clone(t),e).formatInterval(this):B}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:B}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:B}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:B}toFormat(e,{separator:t=" "}={}){return this.isValid?`${this.s.toFormat(e)}${t}${this.e.toFormat(e)}`:B}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 we{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 U(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 It(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 Ms(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=It(u,l);return(f-f%7)/7}],["days",It]],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 Ds(n,e,t,r){let[s,i,a,o]=Ms(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 tt={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[-৯]",deva:"[-९]",fullwide:"[-]",gujr:"[-૯]",hanidec:"[|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[-೯]",laoo:"[-໙]",limb:"[᥆-᥏]",mlym:"[-൯]",mong:"[᠐-᠙]",mymr:"[-၉]",orya:"[-୯]",tamldec:"[-௯]",telu:"[-౯]",thai:"[-๙]",tibt:"[༠-༩]",latn:"\\d"},Et={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]},xs=tt.hanidec.replace(/[\[|\]]/g,"").split("");function bs(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(tt.hanidec)!==-1)e+=xs.indexOf(n[t]);else for(const s in Et){const[i,a]=Et[s];r>=i&&r<=a&&(e+=r-i)}}return parseInt(e,10)}else return e}function F({numberingSystem:n},e=""){return new RegExp(`${tt[n||"latn"]}${e}`)}const Fs="missing Intl.DateTimeFormat.formatToParts support";function w(n,e=t=>t){return{regex:n,deser:([t])=>e(bs(t))}}const Cs=" ",Dn=`[ ${Cs}]`,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 Dt(n,e){return{regex:n,deser:([,t,r])=>Fe(t,r),groups:e}}function ke(n){return{regex:n,deser:([e])=>e}}function Ws(n){return n.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Ls(n,e){const t=F(e),r=F(e,"{2}"),s=F(e,"{3}"),i=F(e,"{4}"),a=F(e,"{6}"),o=F(e,"{1,2}"),u=F(e,"{1,3}"),l=F(e,"{1,6}"),f=F(e,"{1,9}"),y=F(e,"{2,4}"),T=F(e,"{4,6}"),d=L=>({regex:RegExp(Ws(L.val)),deser:([G])=>G,literal:!0}),P=(L=>{if(n.literal)return d(L);switch(L.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,Ge);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 ke(f);case"uu":return ke(o);case"uuu":return w(t);case"a":return C(e.meridiems(),0);case"kkkk":return w(i);case"kk":return w(y,Ge);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 Dt(new RegExp(`([+-]${o.source})(?::(${r.source}))?`),2);case"ZZZ":return Dt(new RegExp(`([+-]${o.source})(${r.source})?`),2);case"z":return ke(/[a-z_+-/]{1,256}?/i);case" ":return ke(/[^\S\n\r]/);default:return d(L)}})(n)||{invalidReason:Fs};return P.token=n,P}const $s={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 Zs(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=$s[a];if(typeof o=="object"&&(o=o[i]),o)return{literal:!1,val:o}}function As(n){return[`^${n.map(t=>t.regex).reduce((t,r)=>`${t}(${r.source})`,"")}$`,n]}function zs(n,e,t){const r=n.match(e);if(r){const s={};let i=1;for(const a in t)if(X(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 Us(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=je(n.u)),[Object.keys(n).reduce((i,a)=>{const o=e(a);return o&&(i[o]=n[a]),i},{}),t,r]}let Ze=null;function Rs(){return Ze||(Ze=m.fromMillis(1555555555555)),Ze}function qs(n,e){if(n.literal)return n;const t=N.macroTokenToFormatOpts(n.val),r=Cn(t,e);return r==null||r.includes(void 0)?n:r}function bn(n,e){return Array.prototype.concat(...n.map(t=>qs(t,e)))}function Fn(n,e,t){const r=bn(N.parseFormat(t),n),s=r.map(a=>Ls(a,n)),i=s.find(a=>a.invalidReason);if(i)return{input:e,tokens:r,invalidReason:i.invalidReason};{const[a,o]=As(s),u=RegExp(a,"i"),[l,f]=zs(e,u,o),[y,T,d]=f?Us(f):[null,null,void 0];if(X(f,"a")&&X(f,"H"))throw new j("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 Hs(n,e,t){const{result:r,zone:s,specificOffset:i,invalidReason:a}=Fn(n,e,t);return[r,s,i,a]}function Cn(n,e){if(!n)return null;const r=N.create(e,n).dtFormatter(Rs()),s=r.formatToParts(),i=r.resolvedOptions();return s.map(a=>Zs(a,n,i))}const Ae="Invalid DateTime",xt=864e13;function Te(n){return new V("unsupported zone",`the zone "${n.name}" is not supported`)}function ze(n){return n.weekData===null&&(n.weekData=Ie(n.c)),n.weekData}function Ue(n){return n.localWeekData===null&&(n.localWeekData=Ie(n.c,n.loc.getMinDaysInFirstWeek(),n.loc.getStartOfWeek())),n.localWeekData}function q(n,e){const t={ts:n.ts,zone:n.zone,c:n.c,o:n.o,loc:n.loc,invalid:n.invalid};return new m({...t,...e,old:t})}function Vn(n,e,t){let r=n-e*60*1e3;const s=t.offset(r);if(e===s)return[r,e];r-=(s-e)*60*1e3;const i=t.offset(r);return s===i?[r,s]:[n-Math.min(s,i)*60*1e3,Math.max(s,i)]}function Se(n,e){n+=e*60*1e3;const t=new Date(n);return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds(),millisecond:t.getUTCMilliseconds()}}function ve(n,e,t){return Vn(be(n),e,t)}function bt(n,e){const t=n.o,r=n.c.year+Math.trunc(e.years),s=n.c.month+Math.trunc(e.months)+Math.trunc(e.quarters)*3,i={...n.c,year:r,month:s,day:Math.min(n.c.day,Ee(r,s))+Math.trunc(e.days)+Math.trunc(e.weeks)*7},a=g.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"),o=be(i);let[u,l]=Vn(o,t,n.zone);return a!==0&&(u+=a,l=n.zone.offset(u)),{ts:u,o:l}}function ae(n,e,t,r,s,i){const{setZone:a,zone:o}=t;if(n&&Object.keys(n).length!==0||e){const u=e||o,l=m.fromObject(n,{...t,zone:u,specificOffset:i});return a?l:l.setZone(o)}else return m.invalid(new V("unparsable",`the input "${s}" can't be parsed as ${r}`))}function pe(n,e,t=!0){return n.isValid?N.create(k.create("en-US"),{allowZ:t,forceSimple:!0}).formatDateTimeFromString(n,e):null}function Re(n,e){const t=n.c.year>9999||n.c.year<0;let r="";return t&&n.c.year>=0&&(r+="+"),r+=O(n.c.year,t?6:4),e?(r+="-",r+=O(n.c.month),r+="-",r+=O(n.c.day)):(r+=O(n.c.month),r+=O(n.c.day)),r}function Ft(n,e,t,r,s,i){let a=O(n.c.hour);return e?(a+=":",a+=O(n.c.minute),(n.c.millisecond!==0||n.c.second!==0||!t)&&(a+=":")):a+=O(n.c.minute),(n.c.millisecond!==0||n.c.second!==0||!t)&&(a+=O(n.c.second),(n.c.millisecond!==0||!r)&&(a+=".",a+=O(n.c.millisecond,3))),s&&(n.isOffsetFixed&&n.offset===0&&!i?a+="Z":n.o<0?(a+="-",a+=O(Math.trunc(-n.o/60)),a+=":",a+=O(Math.trunc(-n.o%60))):(a+="+",a+=O(Math.trunc(n.o/60)),a+=":",a+=O(Math.trunc(n.o%60)))),i&&(a+="["+n.zone.ianaName+"]"),a}const Wn={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},Ys={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},_s={ordinal:1,hour:0,minute:0,second:0,millisecond:0},Ln=["year","month","day","hour","minute","second","millisecond"],Ps=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],Gs=["year","ordinal","hour","minute","second","millisecond"];function Js(n){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"}[n.toLowerCase()];if(!e)throw new $t(n);return e}function Ct(n){switch(n.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return Js(n)}}function Vt(n,e){const t=U(e.zone,p.defaultZone),r=k.fromObject(e),s=p.now();let i,a;if(h(n.year))i=s;else{for(const l of Ln)h(n[l])&&(n[l]=Wn[l]);const o=on(n)||un(n);if(o)return m.invalid(o);const u=t.offset(s);[i,a]=ve(n,u,t)}return new m({ts:i,zone:t,loc:r,o:a})}function Wt(n,e,t){const r=h(t.round)?!0:t.round,s=(a,o)=>(a=Qe(a,r||t.calendary?0:2,!0),e.loc.clone(t).relFormatter(t).format(a,o)),i=a=>t.calendary?e.hasSame(n,a)?0:e.startOf(a).diff(n.startOf(a),a).get(a):e.diff(n,a).get(a);if(t.unit)return s(i(t.unit),t.unit);for(const a of t.units){const o=i(a);if(Math.abs(o)>=1)return s(o,a)}return s(n>e?-0:0,t.units[t.units.length-1])}function Lt(n){let e={},t;return n.length>0&&typeof n[n.length-1]=="object"?(e=n[n.length-1],t=Array.from(n).slice(0,n.length-1)):t=Array.from(n),[e,t]}class m{constructor(e){const t=e.zone||p.defaultZone;let r=e.invalid||(Number.isNaN(e.ts)?new V("invalid input"):null)||(t.isValid?null:Te(t));this.ts=h(e.ts)?p.now():e.ts;let s=null,i=null;if(!r)if(e.old&&e.old.ts===this.ts&&e.old.zone.equals(t))[s,i]=[e.old.c,e.old.o];else{const o=t.offset(this.ts);s=Se(this.ts,o),r=Number.isNaN(s.year)?new V("invalid input"):null,s=r?null:s,i=r?null:o}this._zone=t,this.loc=e.loc||k.create(),this.invalid=r,this.weekData=null,this.localWeekData=null,this.c=s,this.o=i,this.isLuxonDateTime=!0}static now(){return new m({})}static local(){const[e,t]=Lt(arguments),[r,s,i,a,o,u,l]=t;return Vt({year:r,month:s,day:i,hour:a,minute:o,second:u,millisecond:l},e)}static utc(){const[e,t]=Lt(arguments),[r,s,i,a,o,u,l]=t;return e.zone=I.utcInstance,Vt({year:r,month:s,day:i,hour:a,minute:o,second:u,millisecond:l},e)}static fromJSDate(e,t={}){const r=vr(e)?e.valueOf():NaN;if(Number.isNaN(r))return m.invalid("invalid input");const s=U(t.zone,p.defaultZone);return s.isValid?new m({ts:r,zone:s,loc:k.fromObject(t)}):m.invalid(Te(s))}static fromMillis(e,t={}){if(Y(e))return e<-xt||e>xt?m.invalid("Timestamp out of range"):new m({ts:e,zone:U(t.zone,p.defaultZone),loc:k.fromObject(t)});throw new E(`fromMillis requires a numerical input, but received a ${typeof e} with value ${e}`)}static fromSeconds(e,t={}){if(Y(e))return new m({ts:e*1e3,zone:U(t.zone,p.defaultZone),loc:k.fromObject(t)});throw new E("fromSeconds requires a numerical input")}static fromObject(e,t={}){e=e||{};const r=U(t.zone,p.defaultZone);if(!r.isValid)return m.invalid(Te(r));const s=k.fromObject(t),i=Me(e,Ct),{minDaysInFirstWeek:a,startOfWeek:o}=kt(i,s),u=p.now(),l=h(t.specificOffset)?r.offset(u):t.specificOffset,f=!h(i.ordinal),y=!h(i.year),T=!h(i.month)||!h(i.day),d=y||T,v=i.weekYear||i.weekNumber;if((d||f)&&v)throw new j("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(T&&f)throw new j("Can't mix ordinal dates with month/day");const P=v||i.weekday&&!d;let L,G,se=Se(u,l);P?(L=Ps,G=Ys,se=Ie(se,a,o)):f?(L=Gs,G=_s,se=$e(se)):(L=Ln,G=Wn);let nt=!1;for(const ie of L){const Un=i[ie];h(Un)?nt?i[ie]=G[ie]:i[ie]=se[ie]:nt=!0}const $n=P?Sr(i,a,o):f?pr(i):on(i),rt=$n||un(i);if(rt)return m.invalid(rt);const Zn=P?gt(i,a,o):f?wt(i):i,[An,zn]=ve(Zn,l,r),Ve=new m({ts:An,zone:r,o:zn,loc:s});return i.weekday&&d&&e.weekday!==Ve.weekday?m.invalid("mismatched weekday",`you can't specify both a weekday of ${i.weekday} and a date of ${Ve.toISO()}`):Ve}static fromISO(e,t={}){const[r,s]=ds(e);return ae(r,s,t,"ISO 8601",e)}static fromRFC2822(e,t={}){const[r,s]=hs(e);return ae(r,s,t,"RFC 2822",e)}static fromHTTP(e,t={}){const[r,s]=ms(e);return ae(r,s,t,"HTTP",t)}static fromFormat(e,t,r={}){if(h(e)||h(t))throw new E("fromFormat requires an input string and a format");const{locale:s=null,numberingSystem:i=null}=r,a=k.fromOpts({locale:s,numberingSystem:i,defaultToEN:!0}),[o,u,l,f]=Hs(a,e,t);return f?m.invalid(f):ae(o,u,r,`format ${t}`,e,l)}static fromString(e,t,r={}){return m.fromFormat(e,t,r)}static fromSQL(e,t={}){const[r,s]=ps(e);return ae(r,s,t,"SQL",e)}static invalid(e,t=null){if(!e)throw new E("need to specify a reason the DateTime is invalid");const r=e instanceof V?e:new V(e,t);if(p.throwOnInvalid)throw new jn(r);return new m({invalid:r})}static isDateTime(e){return e&&e.isLuxonDateTime||!1}static parseFormatForOpts(e,t={}){const r=Cn(e,k.fromObject(t));return r?r.map(s=>s?s.val:null).join(""):null}static expandFormat(e,t={}){return bn(N.parseFormat(e),k.fromObject(t)).map(s=>s.val).join("")}get(e){return this[e]}get isValid(){return this.invalid===null}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?ze(this).weekYear:NaN}get weekNumber(){return this.isValid?ze(this).weekNumber:NaN}get weekday(){return this.isValid?ze(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?Ue(this).weekday:NaN}get localWeekNumber(){return this.isValid?Ue(this).weekNumber:NaN}get localWeekYear(){return this.isValid?Ue(this).weekYear:NaN}get ordinal(){return this.isValid?$e(this.c).ordinal:NaN}get monthShort(){return this.isValid?we.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?we.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?we.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?we.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?!1:this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset}getPossibleOffsets(){if(!this.isValid||this.isOffsetFixed)return[this];const e=864e5,t=6e4,r=be(this.c),s=this.zone.offset(r-e),i=this.zone.offset(r+e),a=this.zone.offset(r-s*t),o=this.zone.offset(r-i*t);if(a===o)return[this];const u=r-a*t,l=r-o*t,f=Se(u,a),y=Se(l,o);return f.hour===y.hour&&f.minute===y.minute&&f.second===y.second&&f.millisecond===y.millisecond?[q(this,{ts:u}),q(this,{ts:l})]:[this]}get isInLeapYear(){return de(this.year)}get daysInMonth(){return Ee(this.year,this.month)}get daysInYear(){return this.isValid?Q(this.year):NaN}get weeksInWeekYear(){return this.isValid?ce(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?ce(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(e={}){const{locale:t,numberingSystem:r,calendar:s}=N.create(this.loc.clone(e),e).resolvedOptions(this);return{locale:t,numberingSystem:r,outputCalendar:s}}toUTC(e=0,t={}){return this.setZone(I.instance(e),t)}toLocal(){return this.setZone(p.defaultZone)}setZone(e,{keepLocalTime:t=!1,keepCalendarTime:r=!1}={}){if(e=U(e,p.defaultZone),e.equals(this.zone))return this;if(e.isValid){let s=this.ts;if(t||r){const i=e.offset(this.ts),a=this.toObject();[s]=ve(a,i,e)}return q(this,{ts:s,zone:e})}else return m.invalid(Te(e))}reconfigure({locale:e,numberingSystem:t,outputCalendar:r}={}){const s=this.loc.clone({locale:e,numberingSystem:t,outputCalendar:r});return q(this,{loc:s})}setLocale(e){return this.reconfigure({locale:e})}set(e){if(!this.isValid)return this;const t=Me(e,Ct),{minDaysInFirstWeek:r,startOfWeek:s}=kt(t,this.loc),i=!h(t.weekYear)||!h(t.weekNumber)||!h(t.weekday),a=!h(t.ordinal),o=!h(t.year),u=!h(t.month)||!h(t.day),l=o||u,f=t.weekYear||t.weekNumber;if((l||a)&&f)throw new j("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(u&&a)throw new j("Can't mix ordinal dates with month/day");let y;i?y=gt({...Ie(this.c,r,s),...t},r,s):h(t.ordinal)?(y={...this.toObject(),...t},h(t.day)&&(y.day=Math.min(Ee(y.year,y.month),y.day))):y=wt({...$e(this.c),...t});const[T,d]=ve(y,this.o,this.zone);return q(this,{ts:T,o:d})}plus(e){if(!this.isValid)return this;const t=g.fromDurationLike(e);return q(this,bt(this,t))}minus(e){if(!this.isValid)return this;const t=g.fromDurationLike(e).negate();return q(this,bt(this,t))}startOf(e,{useLocaleWeeks:t=!1}={}){if(!this.isValid)return this;const r={},s=g.normalizeUnit(e);switch(s){case"years":r.month=1;case"quarters":case"months":r.day=1;case"weeks":case"days":r.hour=0;case"hours":r.minute=0;case"minutes":r.second=0;case"seconds":r.millisecond=0;break}if(s==="weeks")if(t){const i=this.loc.getStartOfWeek(),{weekday:a}=this;a<i&&(r.weekNumber=this.weekNumber-1),r.weekday=i}else r.weekday=1;if(s==="quarters"){const i=Math.ceil(this.month/3);r.month=(i-1)*3+1}return this.set(r)}endOf(e,t){return this.isValid?this.plus({[e]:1}).startOf(e,t).minus(1):this}toFormat(e,t={}){return this.isValid?N.create(this.loc.redefaultToEN(t)).formatDateTimeFromString(this,e):Ae}toLocaleString(e=Ne,t={}){return this.isValid?N.create(this.loc.clone(t),e).formatDateTime(this):Ae}toLocaleParts(e={}){return this.isValid?N.create(this.loc.clone(e),e).formatDateTimeParts(this):[]}toISO({format:e="extended",suppressSeconds:t=!1,suppressMilliseconds:r=!1,includeOffset:s=!0,extendedZone:i=!1}={}){if(!this.isValid)return null;const a=e==="extended";let o=Re(this,a);return o+="T",o+=Ft(this,a,t,r,s,i),o}toISODate({format:e="extended"}={}){return this.isValid?Re(this,e==="extended"):null}toISOWeekDate(){return pe(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:e=!1,suppressSeconds:t=!1,includeOffset:r=!0,includePrefix:s=!1,extendedZone:i=!1,format:a="extended"}={}){return this.isValid?(s?"T":"")+Ft(this,a==="extended",t,e,r,i):null}toRFC2822(){return pe(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return pe(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?Re(this,!0):null}toSQLTime({includeOffset:e=!0,includeZone:t=!1,includeOffsetSpace:r=!0}={}){let s="HH:mm:ss.SSS";return(t||e)&&(r&&(s+=" "),t?s+="z":e&&(s+="ZZ")),pe(this,s,!0)}toSQL(e={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(e)}`:null}toString(){return this.isValid?this.toISO():Ae}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`DateTime { ts: ${this.toISO()}, zone: ${this.zone.name}, locale: ${this.locale} }`:`DateTime { Invalid, reason: ${this.invalidReason} }`}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(e={}){if(!this.isValid)return{};const t={...this.c};return e.includeConfig&&(t.outputCalendar=this.outputCalendar,t.numberingSystem=this.loc.numberingSystem,t.locale=this.loc.locale),t}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(e,t="milliseconds",r={}){if(!this.isValid||!e.isValid)return g.invalid("created by diffing an invalid DateTime");const s={locale:this.locale,numberingSystem:this.numberingSystem,...r},i=Nr(t).map(g.normalizeUnit),a=e.valueOf()>this.valueOf(),o=a?this:e,u=a?e:this,l=Ds(o,u,i,s);return a?l.negate():l}diffNow(e="milliseconds",t={}){return this.diff(m.now(),e,t)}until(e){return this.isValid?S.fromDateTimes(this,e):this}hasSame(e,t,r){if(!this.isValid)return!1;const s=e.valueOf(),i=this.setZone(e.zone,{keepLocalTime:!0});return i.startOf(t,r)<=s&&s<=i.endOf(t,r)}equals(e){return this.isValid&&e.isValid&&this.valueOf()===e.valueOf()&&this.zone.equals(e.zone)&&this.loc.equals(e.loc)}toRelative(e={}){if(!this.isValid)return null;const t=e.base||m.fromObject({},{zone:this.zone}),r=e.padding?this<t?-e.padding:e.padding:0;let s=["years","months","days","hours","minutes","seconds"],i=e.unit;return Array.isArray(e.unit)&&(s=e.unit,i=void 0),Wt(t,this.plus(r),{...e,numeric:"always",units:s,unit:i})}toRelativeCalendar(e={}){return this.isValid?Wt(e.base||m.fromObject({},{zone:this.zone}),this,{...e,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...e){if(!e.every(m.isDateTime))throw new E("min requires all arguments be DateTimes");return Tt(e,t=>t.valueOf(),Math.min)}static max(...e){if(!e.every(m.isDateTime))throw new E("max requires all arguments be DateTimes");return Tt(e,t=>t.valueOf(),Math.max)}static fromFormatExplain(e,t,r={}){const{locale:s=null,numberingSystem:i=null}=r,a=k.fromOpts({locale:s,numberingSystem:i,defaultToEN:!0});return Fn(a,e,t)}static fromStringExplain(e,t,r={}){return m.fromFormatExplain(e,t,r)}static get DATE_SHORT(){return Ne}static get DATE_MED(){return Zt}static get DATE_MED_WITH_WEEKDAY(){return Xn}static get DATE_FULL(){return At}static get DATE_HUGE(){return zt}static get TIME_SIMPLE(){return Ut}static get TIME_WITH_SECONDS(){return Rt}static get TIME_WITH_SHORT_OFFSET(){return qt}static get TIME_WITH_LONG_OFFSET(){return Ht}static get TIME_24_SIMPLE(){return Yt}static get TIME_24_WITH_SECONDS(){return _t}static get TIME_24_WITH_SHORT_OFFSET(){return Pt}static get TIME_24_WITH_LONG_OFFSET(){return Gt}static get DATETIME_SHORT(){return Jt}static get DATETIME_SHORT_WITH_SECONDS(){return Bt}static get DATETIME_MED(){return jt}static get DATETIME_MED_WITH_SECONDS(){return Qt}static get DATETIME_MED_WITH_WEEKDAY(){return er}static get DATETIME_FULL(){return Kt}static get DATETIME_FULL_WITH_SECONDS(){return Xt}static get DATETIME_HUGE(){return en}static get DATETIME_HUGE_WITH_SECONDS(){return tn}}function oe(n){if(m.isDateTime(n))return n;if(n&&n.valueOf&&Y(n.valueOf()))return m.fromJSDate(n);if(n&&typeof n=="object")return m.fromObject(n);throw new E(`Unknown datetime argument: ${n}, of type ${typeof n}`)}export{Ks as C,m as D};