@bitrix24/b24jssdk
Version:
Bitrix24 REST API JavaScript SDK
8 lines • 410 kB
JavaScript
var My=Object.defineProperty;var a=(R,H)=>My(R,"name",{value:H,configurable:!0});/**
* @package @bitrix24/b24jssdk
* @version 1.1.0
* @copyright (c) 2026 Bitrix24
* @license MIT
* @see https://github.com/bitrix24/b24jssdk
* @see https://bitrix24.github.io/b24jssdk/
*/(function(R,H){typeof exports=="object"&&typeof module<"u"?H(exports):typeof define=="function"&&define.amd?define(["exports"],H):(R=typeof globalThis<"u"?globalThis:R||self,H(R.B24Js={}))})(this,(function(R){"use strict";var H=(r=>(r[r.DEBUG=0]="DEBUG",r[r.INFO=1]="INFO",r[r.NOTICE=2]="NOTICE",r[r.WARNING=3]="WARNING",r[r.ERROR=4]="ERROR",r[r.CRITICAL=5]="CRITICAL",r[r.ALERT=6]="ALERT",r[r.EMERGENCY=7]="EMERGENCY",r))(H||{});class vt extends Error{static{a(this,"LuxonError")}}class Dc extends vt{static{a(this,"InvalidDateTimeError")}constructor(e){super(`Invalid DateTime: ${e.toMessage()}`)}}class Mc extends vt{static{a(this,"InvalidIntervalError")}constructor(e){super(`Invalid Interval: ${e.toMessage()}`)}}class Lc extends vt{static{a(this,"InvalidDurationError")}constructor(e){super(`Invalid Duration: ${e.toMessage()}`)}}class Lt extends vt{static{a(this,"ConflictingSpecificationError")}}class xn extends vt{static{a(this,"InvalidUnitError")}constructor(e){super(`Invalid unit ${e}`)}}class Ie extends vt{static{a(this,"InvalidArgumentError")}}class pt extends vt{static{a(this,"ZoneIsAbstractError")}constructor(){super("Zone is an abstract class")}}const M="numeric",Ye="short",Be="long",Sr={year:M,month:M,day:M},$n={year:M,month:Ye,day:M},Pc={year:M,month:Ye,day:M,weekday:Ye},jn={year:M,month:Be,day:M},Bn={year:M,month:Be,day:M,weekday:Be},Un={hour:M,minute:M},Vn={hour:M,minute:M,second:M},qn={hour:M,minute:M,second:M,timeZoneName:Ye},Wn={hour:M,minute:M,second:M,timeZoneName:Be},Hn={hour:M,minute:M,hourCycle:"h23"},zn={hour:M,minute:M,second:M,hourCycle:"h23"},Jn={hour:M,minute:M,second:M,hourCycle:"h23",timeZoneName:Ye},Gn={hour:M,minute:M,second:M,hourCycle:"h23",timeZoneName:Be},Yn={year:M,month:M,day:M,hour:M,minute:M},Zn={year:M,month:M,day:M,hour:M,minute:M,second:M},Kn={year:M,month:Ye,day:M,hour:M,minute:M},Xn={year:M,month:Ye,day:M,hour:M,minute:M,second:M},Fc={year:M,month:Ye,day:M,weekday:Ye,hour:M,minute:M},Qn={year:M,month:Be,day:M,hour:M,minute:M,timeZoneName:Ye},ei={year:M,month:Be,day:M,hour:M,minute:M,second:M,timeZoneName:Ye},ti={year:M,month:Be,day:M,weekday:Be,hour:M,minute:M,timeZoneName:Be},ri={year:M,month:Be,day:M,weekday:Be,hour:M,minute:M,second:M,timeZoneName:Be};class Kt{static{a(this,"Zone")}get type(){throw new pt}get name(){throw new pt}get ianaName(){return this.name}get isUniversal(){throw new pt}offsetName(e,t){throw new pt}formatOffset(e,t){throw new pt}offset(e){throw new pt}equals(e){throw new pt}get isValid(){throw new pt}}let fs=null;class vr extends Kt{static{a(this,"SystemZone")}static get instance(){return fs===null&&(fs=new vr),fs}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(e,{format:t,locale:s}){return Ai(e,t,s)}formatOffset(e,t){return tr(this.offset(e),t)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}}const ps=new Map;function xc(r){let e=ps.get(r);return e===void 0&&(e=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:r,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"}),ps.set(r,e)),e}a(xc,"makeDTF");const $c={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function jc(r,e){const t=r.format(e).replace(/\u200E/g,""),s=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(t),[,n,i,c,o,u,h,l]=s;return[c,n,i,o,u,h,l]}a(jc,"hackyOffset");function Bc(r,e){const t=r.formatToParts(e),s=[];for(let n=0;n<t.length;n++){const{type:i,value:c}=t[n],o=$c[i];i==="era"?s[o]=c:J(o)||(s[o]=parseInt(c,10))}return s}a(Bc,"partsOffset");const gs=new Map;class at extends Kt{static{a(this,"IANAZone")}static create(e){let t=gs.get(e);return t===void 0&&gs.set(e,t=new at(e)),t}static resetCache(){gs.clear(),ps.clear()}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=at.isValidZone(e)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(e,{format:t,locale:s}){return Ai(e,t,s,this.name)}formatOffset(e,t){return tr(this.offset(e),t)}offset(e){if(!this.valid)return NaN;const t=new Date(e);if(isNaN(t))return NaN;const s=xc(this.name);let[n,i,c,o,u,h,l]=s.formatToParts?Bc(s,t):jc(s,t);o==="BC"&&(n=-Math.abs(n)+1);const p=Ir({year:n,month:i,day:c,hour:u===24?0:u,minute:h,second:l,millisecond:0});let f=+t;const d=f%1e3;return f-=d>=0?d:1e3+d,(p-f)/(60*1e3)}equals(e){return e.type==="iana"&&e.name===this.name}get isValid(){return this.valid}}let si={};function Uc(r,e={}){const t=JSON.stringify([r,e]);let s=si[t];return s||(s=new Intl.ListFormat(r,e),si[t]=s),s}a(Uc,"getCachedLF");const ms=new Map;function ys(r,e={}){const t=JSON.stringify([r,e]);let s=ms.get(t);return s===void 0&&(s=new Intl.DateTimeFormat(r,e),ms.set(t,s)),s}a(ys,"getCachedDTF");const bs=new Map;function Vc(r,e={}){const t=JSON.stringify([r,e]);let s=bs.get(t);return s===void 0&&(s=new Intl.NumberFormat(r,e),bs.set(t,s)),s}a(Vc,"getCachedINF");const _s=new Map;function qc(r,e={}){const{base:t,...s}=e,n=JSON.stringify([r,s]);let i=_s.get(n);return i===void 0&&(i=new Intl.RelativeTimeFormat(r,e),_s.set(n,i)),i}a(qc,"getCachedRTF");let Xt=null;function Wc(){return Xt||(Xt=new Intl.DateTimeFormat().resolvedOptions().locale,Xt)}a(Wc,"systemLocale");const ws=new Map;function ni(r){let e=ws.get(r);return e===void 0&&(e=new Intl.DateTimeFormat(r).resolvedOptions(),ws.set(r,e)),e}a(ni,"getCachedIntResolvedOptions");const Ss=new Map;function Hc(r){let e=Ss.get(r);if(!e){const t=new Intl.Locale(r);e="getWeekInfo"in t?t.getWeekInfo():t.weekInfo,"minimalDays"in e||(e={...ii,...e}),Ss.set(r,e)}return e}a(Hc,"getCachedWeekInfo");function zc(r){const e=r.indexOf("-x-");e!==-1&&(r=r.substring(0,e));const t=r.indexOf("-u-");if(t===-1)return[r];{let s,n;try{s=ys(r).resolvedOptions(),n=r}catch{const u=r.substring(0,t);s=ys(u).resolvedOptions(),n=u}const{numberingSystem:i,calendar:c}=s;return[n,i,c]}}a(zc,"parseLocaleString");function Jc(r,e,t){return(t||e)&&(r.includes("-u-")||(r+="-u"),t&&(r+=`-ca-${t}`),e&&(r+=`-nu-${e}`)),r}a(Jc,"intlConfigString");function Gc(r){const e=[];for(let t=1;t<=12;t++){const s=V.utc(2009,t,1);e.push(r(s))}return e}a(Gc,"mapMonths");function Yc(r){const e=[];for(let t=1;t<=7;t++){const s=V.utc(2016,11,13+t);e.push(r(s))}return e}a(Yc,"mapWeekdays");function Er(r,e,t,s){const n=r.listingMode();return n==="error"?null:n==="en"?t(e):s(e)}a(Er,"listStuff");function Zc(r){return r.numberingSystem&&r.numberingSystem!=="latn"?!1:r.numberingSystem==="latn"||!r.locale||r.locale.startsWith("en")||ni(r.locale).numberingSystem==="latn"}a(Zc,"supportsFastNumbers");class Kc{static{a(this,"PolyNumberFormatter")}constructor(e,t,s){this.padTo=s.padTo||0,this.floor=s.floor||!1;const{padTo:n,floor:i,...c}=s;if(!t||Object.keys(c).length>0){const o={useGrouping:!1,...s};s.padTo>0&&(o.minimumIntegerDigits=s.padTo),this.inf=Vc(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):Cs(e,3);return we(t,this.padTo)}}}class Xc{static{a(this,"PolyDateFormatter")}constructor(e,t,s){this.opts=s,this.originalZone=void 0;let n;if(this.opts.timeZone)this.dt=e;else if(e.zone.type==="fixed"){const c=-1*(e.offset/60),o=c>=0?`Etc/GMT+${c}`:`Etc/GMT${c}`;e.offset!==0&&at.create(o).valid?(n=o,this.dt=e):(n="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,n=e.zone.name):(n="UTC",this.dt=e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone);const i={...this.opts};i.timeZone=i.timeZone||n,this.dtf=ys(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 s=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...t,value:s}}else return t}):e}resolvedOptions(){return this.dtf.resolvedOptions()}}class Qc{static{a(this,"PolyRelFormatter")}constructor(e,t,s){this.opts={style:"long",...s},!t&&Oi()&&(this.rtf=qc(e,s))}format(e,t){return this.rtf?this.rtf.format(e,t):Sl(t,e,this.opts.numeric,this.opts.style!=="long")}formatToParts(e,t){return this.rtf?this.rtf.formatToParts(e,t):[]}}const ii={firstDay:1,minimalDays:4,weekend:[6,7]};class se{static{a(this,"Locale")}static fromOpts(e){return se.create(e.locale,e.numberingSystem,e.outputCalendar,e.weekSettings,e.defaultToEN)}static create(e,t,s,n,i=!1){const c=e||de.defaultLocale,o=c||(i?"en-US":Wc()),u=t||de.defaultNumberingSystem,h=s||de.defaultOutputCalendar,l=As(n)||de.defaultWeekSettings;return new se(o,u,h,l,c)}static resetCache(){Xt=null,ms.clear(),bs.clear(),_s.clear(),ws.clear(),Ss.clear()}static fromObject({locale:e,numberingSystem:t,outputCalendar:s,weekSettings:n}={}){return se.create(e,t,s,n)}constructor(e,t,s,n,i){const[c,o,u]=zc(e);this.locale=c,this.numberingSystem=t||o||null,this.outputCalendar=s||u||null,this.weekSettings=n,this.intl=Jc(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=Zc(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:se.create(e.locale||this.specifiedLocale,e.numberingSystem||this.numberingSystem,e.outputCalendar||this.outputCalendar,As(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 Er(this,e,Ni,()=>{const s=this.intl==="ja"||this.intl.startsWith("ja-");t&=!s;const n=t?{month:e,day:"numeric"}:{month:e},i=t?"format":"standalone";if(!this.monthsCache[i][e]){const c=s?o=>this.dtFormatter(o,n).format():o=>this.extract(o,n,"month");this.monthsCache[i][e]=Gc(c)}return this.monthsCache[i][e]})}weekdays(e,t=!1){return Er(this,e,Li,()=>{const s=t?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},n=t?"format":"standalone";return this.weekdaysCache[n][e]||(this.weekdaysCache[n][e]=Yc(i=>this.extract(i,s,"weekday"))),this.weekdaysCache[n][e]})}meridiems(){return Er(this,void 0,()=>Pi,()=>{if(!this.meridiemCache){const e={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[V.utc(2016,11,13,9),V.utc(2016,11,13,19)].map(t=>this.extract(t,e,"dayperiod"))}return this.meridiemCache})}eras(e){return Er(this,e,Fi,()=>{const t={era:e};return this.eraCache[e]||(this.eraCache[e]=[V.utc(-40,1,1),V.utc(2017,1,1)].map(s=>this.extract(s,t,"era"))),this.eraCache[e]})}extract(e,t,s){const n=this.dtFormatter(e,t),i=n.formatToParts(),c=i.find(o=>o.type.toLowerCase()===s);return c?c.value:null}numberFormatter(e={}){return new Kc(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,t={}){return new Xc(e,this.intl,t)}relFormatter(e={}){return new Qc(this.intl,this.isEnglish(),e)}listFormatter(e={}){return Uc(this.intl,e)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||ni(this.intl).locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:Ti()?Hc(this.locale):ii}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}toString(){return`Locale(${this.locale}, ${this.numberingSystem}, ${this.outputCalendar})`}}let vs=null;class Me extends Kt{static{a(this,"FixedOffsetZone")}static get utcInstance(){return vs===null&&(vs=new Me(0)),vs}static instance(e){return e===0?Me.utcInstance:new Me(e)}static parseSpecifier(e){if(e){const t=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(t)return new Me(Ar(t[1],t[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${tr(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${tr(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,t){return tr(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 el extends Kt{static{a(this,"InvalidZone")}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 gt(r,e){if(J(r)||r===null)return e;if(r instanceof Kt)return r;if(ol(r)){const t=r.toLowerCase();return t==="default"?e:t==="local"||t==="system"?vr.instance:t==="utc"||t==="gmt"?Me.utcInstance:Me.parseSpecifier(t)||at.create(r)}else return mt(r)?Me.instance(r):typeof r=="object"&&"offset"in r&&typeof r.offset=="function"?r:new el(r)}a(gt,"normalizeZone");const Es={arab:"[\u0660-\u0669]",arabext:"[\u06F0-\u06F9]",bali:"[\u1B50-\u1B59]",beng:"[\u09E6-\u09EF]",deva:"[\u0966-\u096F]",fullwide:"[\uFF10-\uFF19]",gujr:"[\u0AE6-\u0AEF]",hanidec:"[\u3007|\u4E00|\u4E8C|\u4E09|\u56DB|\u4E94|\u516D|\u4E03|\u516B|\u4E5D]",khmr:"[\u17E0-\u17E9]",knda:"[\u0CE6-\u0CEF]",laoo:"[\u0ED0-\u0ED9]",limb:"[\u1946-\u194F]",mlym:"[\u0D66-\u0D6F]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0B66-\u0B6F]",tamldec:"[\u0BE6-\u0BEF]",telu:"[\u0C66-\u0C6F]",thai:"[\u0E50-\u0E59]",tibt:"[\u0F20-\u0F29]",latn:"\\d"},oi={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]},tl=Es.hanidec.replace(/[\[|\]]/g,"").split("");function rl(r){let e=parseInt(r,10);if(isNaN(e)){e="";for(let t=0;t<r.length;t++){const s=r.charCodeAt(t);if(r[t].search(Es.hanidec)!==-1)e+=tl.indexOf(r[t]);else for(const n in oi){const[i,c]=oi[n];s>=i&&s<=c&&(e+=s-i)}}return parseInt(e,10)}else return e}a(rl,"parseDigits");const Os=new Map;function sl(){Os.clear()}a(sl,"resetDigitRegexCache");function Ze({numberingSystem:r},e=""){const t=r||"latn";let s=Os.get(t);s===void 0&&(s=new Map,Os.set(t,s));let n=s.get(e);return n===void 0&&(n=new RegExp(`${Es[t]}${e}`),s.set(e,n)),n}a(Ze,"digitRegex");let ai=a(()=>Date.now(),"now"),ci="system",li=null,ui=null,hi=null,di=60,fi,pi=null;class de{static{a(this,"Settings")}static get now(){return ai}static set now(e){ai=e}static set defaultZone(e){ci=e}static get defaultZone(){return gt(ci,vr.instance)}static get defaultLocale(){return li}static set defaultLocale(e){li=e}static get defaultNumberingSystem(){return ui}static set defaultNumberingSystem(e){ui=e}static get defaultOutputCalendar(){return hi}static set defaultOutputCalendar(e){hi=e}static get defaultWeekSettings(){return pi}static set defaultWeekSettings(e){pi=As(e)}static get twoDigitCutoffYear(){return di}static set twoDigitCutoffYear(e){di=e%100}static get throwOnInvalid(){return fi}static set throwOnInvalid(e){fi=e}static resetCaches(){se.resetCache(),at.resetCache(),V.resetCache(),sl()}}class Ke{static{a(this,"Invalid")}constructor(e,t){this.reason=e,this.explanation=t}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const gi=[0,31,59,90,120,151,181,212,243,273,304,334],mi=[0,31,60,91,121,152,182,213,244,274,305,335];function He(r,e){return new Ke("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${r}, which is invalid`)}a(He,"unitOutOfRange");function Ts(r,e,t){const s=new Date(Date.UTC(r,e-1,t));r<100&&r>=0&&s.setUTCFullYear(s.getUTCFullYear()-1900);const n=s.getUTCDay();return n===0?7:n}a(Ts,"dayOfWeek");function yi(r,e,t){return t+(Qt(r)?mi:gi)[e-1]}a(yi,"computeOrdinal");function bi(r,e){const t=Qt(r)?mi:gi,s=t.findIndex(i=>i<e),n=e-t[s];return{month:s+1,day:n}}a(bi,"uncomputeOrdinal");function ks(r,e){return(r-e+7)%7+1}a(ks,"isoWeekdayToLocal");function Or(r,e=4,t=1){const{year:s,month:n,day:i}=r,c=yi(s,n,i),o=ks(Ts(s,n,i),t);let u=Math.floor((c-o+14-e)/7),h;return u<1?(h=s-1,u=er(h,e,t)):u>er(s,e,t)?(h=s+1,u=1):h=s,{weekYear:h,weekNumber:u,weekday:o,...Cr(r)}}a(Or,"gregorianToWeek");function _i(r,e=4,t=1){const{weekYear:s,weekNumber:n,weekday:i}=r,c=ks(Ts(s,1,e),t),o=Ft(s);let u=n*7+i-c-7+e,h;u<1?(h=s-1,u+=Ft(h)):u>o?(h=s+1,u-=Ft(s)):h=s;const{month:l,day:g}=bi(h,u);return{year:h,month:l,day:g,...Cr(r)}}a(_i,"weekToGregorian");function Is(r){const{year:e,month:t,day:s}=r,n=yi(e,t,s);return{year:e,ordinal:n,...Cr(r)}}a(Is,"gregorianToOrdinal");function wi(r){const{year:e,ordinal:t}=r,{month:s,day:n}=bi(e,t);return{year:e,month:s,day:n,...Cr(r)}}a(wi,"ordinalToGregorian");function Si(r,e){if(!J(r.localWeekday)||!J(r.localWeekNumber)||!J(r.localWeekYear)){if(!J(r.weekday)||!J(r.weekNumber)||!J(r.weekYear))throw new Lt("Cannot mix locale-based week fields with ISO-based week fields");return J(r.localWeekday)||(r.weekday=r.localWeekday),J(r.localWeekNumber)||(r.weekNumber=r.localWeekNumber),J(r.localWeekYear)||(r.weekYear=r.localWeekYear),delete r.localWeekday,delete r.localWeekNumber,delete r.localWeekYear,{minDaysInFirstWeek:e.getMinDaysInFirstWeek(),startOfWeek:e.getStartOfWeek()}}else return{minDaysInFirstWeek:4,startOfWeek:1}}a(Si,"usesLocalWeekValues");function nl(r,e=4,t=1){const s=Tr(r.weekYear),n=ze(r.weekNumber,1,er(r.weekYear,e,t)),i=ze(r.weekday,1,7);return s?n?i?!1:He("weekday",r.weekday):He("week",r.weekNumber):He("weekYear",r.weekYear)}a(nl,"hasInvalidWeekData");function il(r){const e=Tr(r.year),t=ze(r.ordinal,1,Ft(r.year));return e?t?!1:He("ordinal",r.ordinal):He("year",r.year)}a(il,"hasInvalidOrdinalData");function vi(r){const e=Tr(r.year),t=ze(r.month,1,12),s=ze(r.day,1,kr(r.year,r.month));return e?t?s?!1:He("day",r.day):He("month",r.month):He("year",r.year)}a(vi,"hasInvalidGregorianData");function Ei(r){const{hour:e,minute:t,second:s,millisecond:n}=r,i=ze(e,0,23)||e===24&&t===0&&s===0&&n===0,c=ze(t,0,59),o=ze(s,0,59),u=ze(n,0,999);return i?c?o?u?!1:He("millisecond",n):He("second",s):He("minute",t):He("hour",e)}a(Ei,"hasInvalidTimeData");function J(r){return typeof r>"u"}a(J,"isUndefined$1");function mt(r){return typeof r=="number"}a(mt,"isNumber$1");function Tr(r){return typeof r=="number"&&r%1===0}a(Tr,"isInteger");function ol(r){return typeof r=="string"}a(ol,"isString$1");function al(r){return Object.prototype.toString.call(r)==="[object Date]"}a(al,"isDate$1");function Oi(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}a(Oi,"hasRelative");function Ti(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}a(Ti,"hasLocaleWeekInfo");function cl(r){return Array.isArray(r)?r:[r]}a(cl,"maybeArray");function ki(r,e,t){if(r.length!==0)return r.reduce((s,n)=>{const i=[e(n),n];return s&&t(s[0],i[0])===s[0]?s:i},null)[1]}a(ki,"bestBy");function ll(r,e){return e.reduce((t,s)=>(t[s]=r[s],t),{})}a(ll,"pick$1");function Pt(r,e){return Object.prototype.hasOwnProperty.call(r,e)}a(Pt,"hasOwnProperty$1");function As(r){if(r==null)return null;if(typeof r!="object")throw new Ie("Week settings must be an object");if(!ze(r.firstDay,1,7)||!ze(r.minimalDays,1,7)||!Array.isArray(r.weekend)||r.weekend.some(e=>!ze(e,1,7)))throw new Ie("Invalid week settings");return{firstDay:r.firstDay,minimalDays:r.minimalDays,weekend:Array.from(r.weekend)}}a(As,"validateWeekSettings");function ze(r,e,t){return Tr(r)&&r>=e&&r<=t}a(ze,"integerBetween");function ul(r,e){return r-e*Math.floor(r/e)}a(ul,"floorMod");function we(r,e=2){const t=r<0;let s;return t?s="-"+(""+-r).padStart(e,"0"):s=(""+r).padStart(e,"0"),s}a(we,"padStart");function yt(r){if(!(J(r)||r===null||r===""))return parseInt(r,10)}a(yt,"parseInteger");function Et(r){if(!(J(r)||r===null||r===""))return parseFloat(r)}a(Et,"parseFloating");function Rs(r){if(!(J(r)||r===null||r==="")){const e=parseFloat("0."+r)*1e3;return Math.floor(e)}}a(Rs,"parseMillis");function Cs(r,e,t="round"){const s=10**e;switch(t){case"expand":return r>0?Math.ceil(r*s)/s:Math.floor(r*s)/s;case"trunc":return Math.trunc(r*s)/s;case"round":return Math.round(r*s)/s;case"floor":return Math.floor(r*s)/s;case"ceil":return Math.ceil(r*s)/s;default:throw new RangeError(`Value rounding ${t} is out of range`)}}a(Cs,"roundTo");function Qt(r){return r%4===0&&(r%100!==0||r%400===0)}a(Qt,"isLeapYear");function Ft(r){return Qt(r)?366:365}a(Ft,"daysInYear");function kr(r,e){const t=ul(e-1,12)+1,s=r+(e-t)/12;return t===2?Qt(s)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][t-1]}a(kr,"daysInMonth");function Ir(r){let e=Date.UTC(r.year,r.month-1,r.day,r.hour,r.minute,r.second,r.millisecond);return r.year<100&&r.year>=0&&(e=new Date(e),e.setUTCFullYear(r.year,r.month-1,r.day)),+e}a(Ir,"objToLocalTS");function Ii(r,e,t){return-ks(Ts(r,1,e),t)+e-1}a(Ii,"firstWeekOffset");function er(r,e=4,t=1){const s=Ii(r,e,t),n=Ii(r+1,e,t);return(Ft(r)-s+n)/7}a(er,"weeksInWeekYear");function Ns(r){return r>99?r:r>de.twoDigitCutoffYear?1900+r:2e3+r}a(Ns,"untruncateYear");function Ai(r,e,t,s=null){const n=new Date(r),i={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};s&&(i.timeZone=s);const c={timeZoneName:e,...i},o=new Intl.DateTimeFormat(t,c).formatToParts(n).find(u=>u.type.toLowerCase()==="timezonename");return o?o.value:null}a(Ai,"parseZoneInfo");function Ar(r,e){let t=parseInt(r,10);Number.isNaN(t)&&(t=0);const s=parseInt(e,10)||0,n=t<0||Object.is(t,-0)?-s:s;return t*60+n}a(Ar,"signedOffset");function Ri(r){const e=Number(r);if(typeof r=="boolean"||r===""||!Number.isFinite(e))throw new Ie(`Invalid unit value ${r}`);return e}a(Ri,"asNumber");function Rr(r,e){const t={};for(const s in r)if(Pt(r,s)){const n=r[s];if(n==null)continue;t[e(s)]=Ri(n)}return t}a(Rr,"normalizeObject");function tr(r,e){const t=Math.trunc(Math.abs(r/60)),s=Math.trunc(Math.abs(r%60)),n=r>=0?"+":"-";switch(e){case"short":return`${n}${we(t,2)}:${we(s,2)}`;case"narrow":return`${n}${t}${s>0?`:${s}`:""}`;case"techie":return`${n}${we(t,2)}${we(s,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}a(tr,"formatOffset");function Cr(r){return ll(r,["hour","minute","second","millisecond"])}a(Cr,"timeObject");const hl=["January","February","March","April","May","June","July","August","September","October","November","December"],Ci=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dl=["J","F","M","A","M","J","J","A","S","O","N","D"];function Ni(r){switch(r){case"narrow":return[...dl];case"short":return[...Ci];case"long":return[...hl];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}}a(Ni,"months");const Di=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],Mi=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],fl=["M","T","W","T","F","S","S"];function Li(r){switch(r){case"narrow":return[...fl];case"short":return[...Mi];case"long":return[...Di];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}a(Li,"weekdays");const Pi=["AM","PM"],pl=["Before Christ","Anno Domini"],gl=["BC","AD"],ml=["B","A"];function Fi(r){switch(r){case"narrow":return[...ml];case"short":return[...gl];case"long":return[...pl];default:return null}}a(Fi,"eras");function yl(r){return Pi[r.hour<12?0:1]}a(yl,"meridiemForDateTime");function bl(r,e){return Li(e)[r.weekday-1]}a(bl,"weekdayForDateTime");function _l(r,e){return Ni(e)[r.month-1]}a(_l,"monthForDateTime");function wl(r,e){return Fi(e)[r.year<0?0:1]}a(wl,"eraForDateTime");function Sl(r,e,t="always",s=!1){const n={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(r)===-1;if(t==="auto"&&i){const g=r==="days";switch(e){case 1:return g?"tomorrow":`next ${n[r][0]}`;case-1:return g?"yesterday":`last ${n[r][0]}`;case 0:return g?"today":`this ${n[r][0]}`}}const c=Object.is(e,-0)||e<0,o=Math.abs(e),u=o===1,h=n[r],l=s?u?h[1]:h[2]||h[1]:u?n[r][0]:r;return c?`${o} ${l} ago`:`in ${o} ${l}`}a(Sl,"formatRelativeTime");function xi(r,e){let t="";for(const s of r)s.literal?t+=s.val:t+=e(s.val);return t}a(xi,"stringifyTokens");const vl={D:Sr,DD:$n,DDD:jn,DDDD:Bn,t:Un,tt:Vn,ttt:qn,tttt:Wn,T:Hn,TT:zn,TTT:Jn,TTTT:Gn,f:Yn,ff:Kn,fff:Qn,ffff:ti,F:Zn,FF:Xn,FFF:ei,FFFF:ri};class Ae{static{a(this,"Formatter")}static create(e,t={}){return new Ae(e,t)}static parseFormat(e){let t=null,s="",n=!1;const i=[];for(let c=0;c<e.length;c++){const o=e.charAt(c);o==="'"?((s.length>0||n)&&i.push({literal:n||/^\s+$/.test(s),val:s===""?"'":s}),t=null,s="",n=!n):n||o===t?s+=o:(s.length>0&&i.push({literal:/^\s+$/.test(s),val:s}),s=o,t=o)}return s.length>0&&i.push({literal:n||/^\s+$/.test(s),val:s}),i}static macroTokenToFormatOpts(e){return vl[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,s=void 0){if(this.opts.forceSimple)return we(e,t);const n={...this.opts};return t>0&&(n.padTo=t),s&&(n.signDisplay=s),this.loc.numberFormatter(n).format(e)}formatDateTimeFromString(e,t){const s=this.loc.listingMode()==="en",n=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",i=a((f,d)=>this.loc.extract(e,f,d),"string"),c=a(f=>e.isOffsetFixed&&e.offset===0&&f.allowZ?"Z":e.isValid?e.zone.formatOffset(e.ts,f.format):"","formatOffset"),o=a(()=>s?yl(e):i({hour:"numeric",hourCycle:"h12"},"dayperiod"),"meridiem"),u=a((f,d)=>s?_l(e,f):i(d?{month:f}:{month:f,day:"numeric"},"month"),"month"),h=a((f,d)=>s?bl(e,f):i(d?{weekday:f}:{weekday:f,month:"long",day:"numeric"},"weekday"),"weekday"),l=a(f=>{const d=Ae.macroTokenToFormatOpts(f);return d?this.formatWithSystemDefault(e,d):f},"maybeMacro"),g=a(f=>s?wl(e,f):i({era:f},"era"),"era"),p=a(f=>{switch(f){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 c({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return c({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return c({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 n?i({day:"numeric"},"day"):this.num(e.day);case"dd":return n?i({day:"2-digit"},"day"):this.num(e.day,2);case"c":return this.num(e.weekday);case"ccc":return h("short",!0);case"cccc":return h("long",!0);case"ccccc":return h("narrow",!0);case"E":return this.num(e.weekday);case"EEE":return h("short",!1);case"EEEE":return h("long",!1);case"EEEEE":return h("narrow",!1);case"L":return n?i({month:"numeric",day:"numeric"},"month"):this.num(e.month);case"LL":return n?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 n?i({month:"numeric"},"month"):this.num(e.month);case"MM":return n?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 n?i({year:"numeric"},"year"):this.num(e.year);case"yy":return n?i({year:"2-digit"},"year"):this.num(e.year.toString().slice(-2),2);case"yyyy":return n?i({year:"numeric"},"year"):this.num(e.year,4);case"yyyyyy":return n?i({year:"numeric"},"year"):this.num(e.year,6);case"G":return g("short");case"GG":return g("long");case"GGGGG":return g("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 l(f)}},"tokenToString");return xi(Ae.parseFormat(t),p)}formatDurationFromString(e,t){const s=this.opts.signMode==="negativeLargestOnly"?-1:1,n=a(l=>{switch(l[0]){case"S":return"milliseconds";case"s":return"seconds";case"m":return"minutes";case"h":return"hours";case"d":return"days";case"w":return"weeks";case"M":return"months";case"y":return"years";default:return null}},"tokenToField"),i=a((l,g)=>p=>{const f=n(p);if(f){const d=g.isNegativeDuration&&f!==g.largestUnit?s:1;let m;return this.opts.signMode==="negativeLargestOnly"&&f!==g.largestUnit?m="never":this.opts.signMode==="all"?m="always":m="auto",this.num(l.get(f)*d,p.length,m)}else return p},"tokenToString"),c=Ae.parseFormat(t),o=c.reduce((l,{literal:g,val:p})=>g?l:l.concat(p),[]),u=e.shiftTo(...o.map(n).filter(l=>l)),h={isNegativeDuration:u<0,largestUnit:Object.keys(u.values)[0]};return xi(c,i(u,h))}}const $i=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function xt(...r){const e=r.reduce((t,s)=>t+s.source,"");return RegExp(`^${e}$`)}a(xt,"combineRegexes");function $t(...r){return e=>r.reduce(([t,s,n],i)=>{const[c,o,u]=i(e,n);return[{...t,...c},o||s,u]},[{},null,1]).slice(0,2)}a($t,"combineExtractors");function jt(r,...e){if(r==null)return[null,null];for(const[t,s]of e){const n=t.exec(r);if(n)return s(n)}return[null,null]}a(jt,"parse");function ji(...r){return(e,t)=>{const s={};let n;for(n=0;n<r.length;n++)s[r[n]]=yt(e[t+n]);return[s,null,t+n]}}a(ji,"simpleParse");const Bi=/(?:([Zz])|([+-]\d\d)(?::?(\d\d))?)/,El=`(?:${Bi.source}?(?:\\[(${$i.source})\\])?)?`,Ds=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Ui=RegExp(`${Ds.source}${El}`),Ms=RegExp(`(?:[Tt]${Ui.source})?`),Ol=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Tl=/(\d{4})-?W(\d\d)(?:-?(\d))?/,kl=/(\d{4})-?(\d{3})/,Il=ji("weekYear","weekNumber","weekDay"),Al=ji("year","ordinal"),Rl=/(\d{4})-(\d\d)-(\d\d)/,Vi=RegExp(`${Ds.source} ?(?:${Bi.source}|(${$i.source}))?`),Cl=RegExp(`(?: ${Vi.source})?`);function Bt(r,e,t){const s=r[e];return J(s)?t:yt(s)}a(Bt,"int");function Nl(r,e){return[{year:Bt(r,e),month:Bt(r,e+1,1),day:Bt(r,e+2,1)},null,e+3]}a(Nl,"extractISOYmd");function Ut(r,e){return[{hours:Bt(r,e,0),minutes:Bt(r,e+1,0),seconds:Bt(r,e+2,0),milliseconds:Rs(r[e+3])},null,e+4]}a(Ut,"extractISOTime");function rr(r,e){const t=!r[e]&&!r[e+1],s=Ar(r[e+1],r[e+2]),n=t?null:Me.instance(s);return[{},n,e+3]}a(rr,"extractISOOffset");function sr(r,e){const t=r[e]?at.create(r[e]):null;return[{},t,e+1]}a(sr,"extractIANAZone");const Dl=RegExp(`^T?${Ds.source}$`),Ml=/^-?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 Ll(r){const[e,t,s,n,i,c,o,u,h]=r,l=e[0]==="-",g=u&&u[0]==="-",p=a((f,d=!1)=>f!==void 0&&(d||f&&l)?-f:f,"maybeNegate");return[{years:p(Et(t)),months:p(Et(s)),weeks:p(Et(n)),days:p(Et(i)),hours:p(Et(c)),minutes:p(Et(o)),seconds:p(Et(u),u==="-0"),milliseconds:p(Rs(h),g)}]}a(Ll,"extractISODuration");const Pl={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Ls(r,e,t,s,n,i,c){const o={year:e.length===2?Ns(yt(e)):yt(e),month:Ci.indexOf(t)+1,day:yt(s),hour:yt(n),minute:yt(i)};return c&&(o.second=yt(c)),r&&(o.weekday=r.length>3?Di.indexOf(r)+1:Mi.indexOf(r)+1),o}a(Ls,"fromStrings");const Fl=/^(?:(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 xl(r){const[,e,t,s,n,i,c,o,u,h,l,g]=r,p=Ls(e,n,s,t,i,c,o);let f;return u?f=Pl[u]:h?f=0:f=Ar(l,g),[p,new Me(f)]}a(xl,"extractRFC2822");function $l(r){return r.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}a($l,"preprocessRFC2822");const jl=/^(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$/,Bl=/^(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$/,Ul=/^(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 qi(r){const[,e,t,s,n,i,c,o]=r;return[Ls(e,n,s,t,i,c,o),Me.utcInstance]}a(qi,"extractRFC1123Or850");function Vl(r){const[,e,t,s,n,i,c,o]=r;return[Ls(e,o,t,s,n,i,c),Me.utcInstance]}a(Vl,"extractASCII");const ql=xt(Ol,Ms),Wl=xt(Tl,Ms),Hl=xt(kl,Ms),zl=xt(Ui),Wi=$t(Nl,Ut,rr,sr),Jl=$t(Il,Ut,rr,sr),Gl=$t(Al,Ut,rr,sr),Yl=$t(Ut,rr,sr);function Zl(r){return jt(r,[ql,Wi],[Wl,Jl],[Hl,Gl],[zl,Yl])}a(Zl,"parseISODate");function Kl(r){return jt($l(r),[Fl,xl])}a(Kl,"parseRFC2822Date");function Xl(r){return jt(r,[jl,qi],[Bl,qi],[Ul,Vl])}a(Xl,"parseHTTPDate");function Ql(r){return jt(r,[Ml,Ll])}a(Ql,"parseISODuration");const eu=$t(Ut);function tu(r){return jt(r,[Dl,eu])}a(tu,"parseISOTimeOnly");const ru=xt(Rl,Cl),su=xt(Vi),nu=$t(Ut,rr,sr);function iu(r){return jt(r,[ru,Wi],[su,nu])}a(iu,"parseSQL");const Hi="Invalid Duration",zi={weeks:{days:7,hours:168,minutes:10080,seconds:10080*60,milliseconds:10080*60*1e3},days:{hours:24,minutes:1440,seconds:1440*60,milliseconds:1440*60*1e3},hours:{minutes:60,seconds:3600,milliseconds:3600*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},ou={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:2184,minutes:2184*60,seconds:2184*60*60,milliseconds:2184*60*60*1e3},months:{weeks:4,days:30,hours:720,minutes:720*60,seconds:720*60*60,milliseconds:720*60*60*1e3},...zi},Je=146097/400,Vt=146097/4800,au={years:{quarters:4,months:12,weeks:Je/7,days:Je,hours:Je*24,minutes:Je*24*60,seconds:Je*24*60*60,milliseconds:Je*24*60*60*1e3},quarters:{months:3,weeks:Je/28,days:Je/4,hours:Je*24/4,minutes:Je*24*60/4,seconds:Je*24*60*60/4,milliseconds:Je*24*60*60*1e3/4},months:{weeks:Vt/7,days:Vt,hours:Vt*24,minutes:Vt*24*60,seconds:Vt*24*60*60,milliseconds:Vt*24*60*60*1e3},...zi},Ot=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],cu=Ot.slice(0).reverse();function ct(r,e,t=!1){const s={values:t?e.values:{...r.values,...e.values||{}},loc:r.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||r.conversionAccuracy,matrix:e.matrix||r.matrix};return new Q(s)}a(ct,"clone$1");function Ji(r,e){let t=e.milliseconds??0;for(const s of cu.slice(1))e[s]&&(t+=e[s]*r[s].milliseconds);return t}a(Ji,"durationToMillis");function Gi(r,e){const t=Ji(r,e)<0?-1:1;Ot.reduceRight((s,n)=>{if(J(e[n]))return s;if(s){const i=e[s]*t,c=r[n][s],o=Math.floor(i/c);e[n]+=o*t,e[s]-=o*c*t}return n},null),Ot.reduce((s,n)=>{if(J(e[n]))return s;if(s){const i=e[s]%1;e[s]-=i,e[n]+=i*r[s][n]}return n},null)}a(Gi,"normalizeValues");function Yi(r){const e={};for(const[t,s]of Object.entries(r))s!==0&&(e[t]=s);return e}a(Yi,"removeZeroes");class Q{static{a(this,"Duration")}constructor(e){const t=e.conversionAccuracy==="longterm"||!1;let s=t?au:ou;e.matrix&&(s=e.matrix),this.values=e.values,this.loc=e.loc||se.create(),this.conversionAccuracy=t?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=s,this.isLuxonDuration=!0}static fromMillis(e,t){return Q.fromObject({milliseconds:e},t)}static fromObject(e,t={}){if(e==null||typeof e!="object")throw new Ie(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new Q({values:Rr(e,Q.normalizeUnit),loc:se.fromObject(t),conversionAccuracy:t.conversionAccuracy,matrix:t.matrix})}static fromDurationLike(e){if(mt(e))return Q.fromMillis(e);if(Q.isDuration(e))return e;if(typeof e=="object")return Q.fromObject(e);throw new Ie(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,t){const[s]=Ql(e);return s?Q.fromObject(s,t):Q.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static fromISOTime(e,t){const[s]=tu(e);return s?Q.fromObject(s,t):Q.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static invalid(e,t=null){if(!e)throw new Ie("need to specify a reason the Duration is invalid");const s=e instanceof Ke?e:new Ke(e,t);if(de.throwOnInvalid)throw new Lc(s);return new Q({invalid:s})}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 xn(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 s={...t,floor:t.round!==!1&&t.floor!==!1};return this.isValid?Ae.create(this.loc,s).formatDurationFromString(this,e):Hi}toHuman(e={}){if(!this.isValid)return Hi;const t=e.showZeros!==!1,s=Ot.map(n=>{const i=this.values[n];return J(i)||i===0&&!t?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...e,unit:n.slice(0,-1)}).format(i)}).filter(n=>n);return this.loc.listFormatter({type:"conjunction",style:e.listStyle||"narrow",...e}).format(s)}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+=Cs(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},V.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?Ji(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(e){if(!this.isValid)return this;const t=Q.fromDurationLike(e),s={};for(const n of Ot)(Pt(t.values,n)||Pt(this.values,n))&&(s[n]=t.get(n)+this.get(n));return ct(this,{values:s},!0)}minus(e){if(!this.isValid)return this;const t=Q.fromDurationLike(e);return this.plus(t.negate())}mapUnits(e){if(!this.isValid)return this;const t={};for(const s of Object.keys(this.values))t[s]=Ri(e(this.values[s],s));return ct(this,{values:t},!0)}get(e){return this[Q.normalizeUnit(e)]}set(e){if(!this.isValid)return this;const t={...this.values,...Rr(e,Q.normalizeUnit)};return ct(this,{values:t})}reconfigure({locale:e,numberingSystem:t,conversionAccuracy:s,matrix:n}={}){const c={loc:this.loc.clone({locale:e,numberingSystem:t}),matrix:n,conversionAccuracy:s};return ct(this,c)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;const e=this.toObject();return Gi(this.matrix,e),ct(this,{values:e},!0)}rescale(){if(!this.isValid)return this;const e=Yi(this.normalize().shiftToAll().toObject());return ct(this,{values:e},!0)}shiftTo(...e){if(!this.isValid)return this;if(e.length===0)return this;e=e.map(c=>Q.normalizeUnit(c));const t={},s={},n=this.toObject();let i;for(const c of Ot)if(e.indexOf(c)>=0){i=c;let o=0;for(const h in s)o+=this.matrix[h][c]*s[h],s[h]=0;mt(n[c])&&(o+=n[c]);const u=Math.trunc(o);t[c]=u,s[c]=(o*1e3-u*1e3)/1e3}else mt(n[c])&&(s[c]=n[c]);for(const c in s)s[c]!==0&&(t[i]+=c===i?s[c]:s[c]/this.matrix[i][c]);return Gi(this.matrix,t),ct(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 ct(this,{values:e},!0)}removeZeros(){if(!this.isValid)return this;const e=Yi(this.values);return ct(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(s,n){return s===void 0||s===0?n===void 0||n===0:s===n}a(t,"eq");for(const s of Ot)if(!t(this.values[s],e.values[s]))return!1;return!0}}const qt="Invalid Interval";function lu(r,e){return!r||!r.isValid?fe.invalid("missing or invalid start"):!e||!e.isValid?fe.invalid("missing or invalid end"):e<r?fe.invalid("end before start",`The end of an interval must be after its start, but you had start=${r.toISO()} and end=${e.toISO()}`):null}a(lu,"validateStartEnd");class fe{static{a(this,"Interval")}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 Ie("need to specify a reason the Interval is invalid");const s=e instanceof Ke?e:new Ke(e,t);if(de.throwOnInvalid)throw new Mc(s);return new fe({invalid:s})}static fromDateTimes(e,t){const s=or(e),n=or(t),i=lu(s,n);return i??new fe({start:s,end:n})}static after(e,t){const s=Q.fromDurationLike(t),n=or(e);return fe.fromDateTimes(n,n.plus(s))}static before(e,t){const s=Q.fromDurationLike(t),n=or(e);return fe.fromDateTimes(n.minus(s),n)}static fromISO(e,t){const[s,n]=(e||"").split("/",2);if(s&&n){let i,c;try{i=V.fromISO(s,t),c=i.isValid}catch{c=!1}let o,u;try{o=V.fromISO(n,t),u=o.isValid}catch{u=!1}if(c&&u)return fe.fromDateTimes(i,o);if(c){const h=Q.fromISO(n,t);if(h.isValid)return fe.after(i,h)}else if(u){const h=Q.fromISO(s,t);if(h.isValid)return fe.before(o,h)}}return fe.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 lastDateTime(){return this.isValid&&this.e?this.e.minus(1):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 s=this.start.startOf(e,t);let n;return t?.useLocaleWeeks?n=this.end.reconfigure({locale:s.locale}):n=this.end,n=n.startOf(e,t),Math.floor(n.diff(s,e).get(e))+(n.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?fe.fromDateTimes(e||this.s,t||this.e):this}splitAt(...e){if(!this.isValid)return[];const t=e.map(or).filter(c=>this.contains(c)).sort((c,o)=>c.toMillis()-o.toMillis()),s=[];let{s:n}=this,i=0;for(;n<this.e;){const c=t[i]||this.e,o=+c>+this.e?this.e:c;s.push(fe.fromDateTimes(n,o)),n=o,i+=1}return s}splitBy(e){const t=Q.fromDurationLike(e);if(!this.isValid||!t.isValid||t.as("milliseconds")===0)return[];let{s}=this,n=1,i;const c=[];for(;s<this.e;){const o=this.start.plus(t.mapUnits(u=>u*n));i=+o>+this.e?this.e:o,c.push(fe.fromDateTimes(s,i)),s=i,n+=1}return c}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,s=this.e<e.e?this.e:e.e;return t>=s?null:fe.fromDateTimes(t,s)}union(e){if(!this.isValid)return this;const t=this.s<e.s?this.s:e.s,s=this.e>e.e?this.e:e.e;return fe.fromDateTimes(t,s)}static merge(e){const[t,s]=e.sort((n,i)=>n.s-i.s).reduce(([n,i],c)=>i?i.overlaps(c)||i.abutsStart(c)?[n,i.union(c)]:[n.concat([i]),c]:[n,c],[[],null]);return s&&t.push(s),t}static xor(e){let t=null,s=0;const n=[],i=e.map(u=>[{time:u.s,type:"s"},{time:u.e,type:"e"}]),c=Array.prototype.concat(...i),o=c.sort((u,h)=>u.time-h.time);for(const u of o)s+=u.type==="s"?1:-1,s===1?t=u.time:(t&&+t!=+u.time&&n.push(fe.fromDateTimes(t,u.time)),t=null);return fe.merge(n)}difference(...e){return fe.xor([this].concat(e)).map(t=>this.intersection(t)).filter(t=>t&&!t.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:qt}[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=Sr,t={}){return this.isValid?Ae.create(this.s.loc.clone(t),e).formatInterval(this):qt}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:qt}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:qt}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:qt}toFormat(e,{separator:t=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(e)}${t}${this.e.toFormat(e)}`:qt}toDuration(e,t){return this.isValid?this.e.diff(this.s,e,t):Q.invalid(this.invalidReason)}mapEndpoints(e){return fe.fromDateTimes(e(this.s),e(this.e))}}class Nr{static{a(this,"Info")}static hasDST(e=de.defaultZone){const t=V.now().setZone(e).set({month:12});return!e.isUniversal&&t.offset!==t.set({month:6}).offset}static isValidIANAZone(e){return at.isValidZone(e)}static normalizeZone(e){return gt(e,de.defaultZone)}static getStartOfWeek({locale:e=null,locObj:t=null}={}){return(t||se.create(e)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:e=null,locObj:t=null}={}){return(t||se.create(e)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:e=null,locObj:t=null}={}){return(t||se.create(e)).getWeekendDays().slice()}static months(e="long",{locale:t=null,numberingSystem:s=null,locObj:n=null,outputCalendar:i="gregory"}={}){return(n||se.create(t,s,i)).months(e)}static monthsFormat(e="long",{locale:t=null,numberingSystem:s=null,locObj:n=null,outputCalendar:i="gregory"}={}){return(n||se.create(t,s,i)).months(e,!0)}static weekdays(e="long",{locale:t=null,numberingSystem:s=null,locObj:n=null}={}){return(n||se.create(t,s,null)).weekdays(e)}static weekdaysFormat(e="long",{locale:t=null,numberingSystem:s=null,locObj:n=null}={}){return(n||se.create(t,s,null)).weekdays(e,!0)}static meridiems({locale:e=null}={}){return se.create(e).meridiems()}static eras(e="short",{locale:t=null}={}){return se.create(t,null,"gregory").eras(e)}static features(){return{relative:Oi(),localeWeek:Ti()}}}function Zi(r,e){const t=a(n=>n.toUTC(0,{keep