@malloy-publisher/server 0.0.161 → 0.0.165
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/api-doc.yaml +78 -0
- package/dist/app/assets/HomePage-QekMXs8r.js +1 -0
- package/dist/app/assets/{MainPage-CzAy2LSX.js → MainPage-DAyUfYba.js} +1 -1
- package/dist/app/assets/{ModelPage-uZf0eDBu.js → ModelPage-CrMryV1s.js} +1 -1
- package/dist/app/assets/PackagePage-DDaABD2A.js +1 -0
- package/dist/app/assets/ProjectPage-FAYUFGhL.js +1 -0
- package/dist/app/assets/RouteError-BKYctANX.js +1 -0
- package/dist/app/assets/{WorkbookPage-CBJ0x84n.js → WorkbookPage-DZEVYGW3.js} +1 -1
- package/dist/app/assets/{index-BoduKqUa.js → index-BvVmB5sv.js} +98 -98
- package/dist/app/assets/{index-D_8e14NE.js → index-CsC07BYd.js} +1 -1
- package/dist/app/assets/{index-Bl1fe3A7.js → index-DWhjtyBB.js} +1 -1
- package/dist/app/assets/{index.umd-DRsjT6d4.js → index.umd-DvM-lTQa.js} +1 -1
- package/dist/app/index.html +1 -1
- package/dist/instrumentation.js +4 -2
- package/dist/server.js +150 -18
- package/k6-tests/load-test/load-test.ts +30 -0
- package/package.json +5 -1
- package/src/health.ts +181 -0
- package/src/logger.ts +9 -1
- package/src/server.ts +42 -1
- package/src/service/model.spec.ts +5 -5
- package/src/service/model.ts +56 -19
- package/src/service/project_store.ts +5 -0
- package/dist/app/assets/HomePage-CgSTNEQW.js +0 -1
- package/dist/app/assets/PackagePage-BHvPFsmZ.js +0 -1
- package/dist/app/assets/ProjectPage-ndnv5nGp.js +0 -1
- package/dist/app/assets/RouteError-CZC9OOKh.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{U as I0,V as Mp}from"./index-BvVmB5sv.js";function qp(a,d){for(var y=0;y<d.length;y++){const m=d[y];if(typeof m!="string"&&!Array.isArray(m)){for(const h in m)if(h!=="default"&&!(h in a)){const u=Object.getOwnPropertyDescriptor(m,h);u&&Object.defineProperty(a,h,u.get?u:{enumerable:!0,get:()=>m[h]})}}}return Object.freeze(Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}))}var Cr={},ct={},Xe={},Ma;function pe(){if(Ma)return Xe;Ma=1;/*!
|
|
2
2
|
* Copyright 2016 The ANTLR Project. All rights reserved.
|
|
3
3
|
* Licensed under the BSD-3-Clause license. See LICENSE file in the project root for license information.
|
|
4
4
|
*/Object.defineProperty(Xe,"__esModule",{value:!0}),Xe.SuppressWarnings=Xe.Override=Xe.Nullable=Xe.NotNull=void 0;function a(h,u,r){}Xe.NotNull=a;function d(h,u,r){}Xe.Nullable=d;function y(h,u,r){}Xe.Override=y;function m(h){return(u,r,o)=>{}}return Xe.SuppressWarnings=m,Xe}var qa;function jp(){if(qa)return ct;qa=1;/*!
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{G as LL,r as T,j as R,H as Ht,R as rR,K as nR,L as ys}from"./index-BoduKqUa.js";import{r as n0,a as Oy,b as Fy,c as i0,d as s0,e as Ny,f as Iy,g as ky,h as My,j as By,k as Py,l as $y,m as qy,n as jy,o as o0,p as a0,q as u0,s as l0,t as iR,u as OL,v as Uy,w as ct}from"./index-D_8e14NE.js";import{a as b1}from"./index.umd-DRsjT6d4.js";var Co={},hg={},gr={},pg={},TC;function Ke(){return TC||(TC=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TD=e.ValueType=void 0,e.exprHasKids=t,e.exprHasE=r,e.exprIsLeaf=i,e.isAsymmetricExpr=a,e.mkTemporal=c,e.isRawCast=x,e.isFilterExprType=u,e.isTimeLiteral=d,e.isParameterType=f,e.paramHasValue=m,e.expressionIsScalar=h,e.expressionIsAggregate=p,e.expressionIsUngroupedAggregate=l,e.expressionInvolvesAggregate=C,e.expressionIsCalculation=E,e.expressionIsAnalytic=y,e.isExpressionTypeLEQ=S,e.maxExpressionType=v,e.maxOfExpressionTypes=A,e.hasExpression=w,e.isTemporalType=L,e.isAtomicFieldType=F,e.canOrderBy=P,e.isCastType=k,e.fieldIsIntrinsic=I,e.mkFieldDef=j,e.mkArrayDef=H,e.isRepeatedRecordFunctionParam=q,e.isRepeatedRecord=O,e.isRecordOrRepeatedRecord=W,e.isBasicArray=z,e.isMatrixOperation=ie,e.isJoinable=K,e.isJoined=fe,e.isJoinedSource=Z,e.isDateUnit=te,e.isTimestampUnit=Y,e.isExtractUnit=re,e.refIsStructDef=he,e.segmentHasErrors=xe,e.structHasErrors=X,e.isReduceSegment=de,e.isPartialSegment=ve,e.isProjectSegment=ce,e.isQuerySegment=Te,e.isSamplingRows=Qe,e.isSamplingPercent=Re,e.isSamplingEnable=Le,e.isRawSegment=Ie,e.isIndexSegment=Ge,e.bareFieldUsage=ot,e.isSegmentSQL=Ze,e.sourceBase=ut,e.isSourceDef=It,e.isBaseTable=Dt,e.isLiteral=Bt,e.mergeEvalSpaces=zt,e.isBasicAtomic=rr,e.getIdentifier=Qr,e.isTurtle=Jt,e.isAtomic=mr,e.isValueString=kr,e.isValueNumber=Jr,e.isValueBoolean=ft,e.isValueTimestamp=se,e.isValueDate=ae,e.mergeUniqueKeyRequirement=_e;function t(V){return"kids"in V}function r(V){return"e"in V}function i(V){return!(t(V)||r(V))}function a(V){return V.node==="aggregate"&&["sum","avg","count","distinct"].includes(V.function)}function o(V){return V.node!=="arrayLiteral"&&V.node!=="recordLiteral"}function c(V,Ae){if(!("typeDef"in V)){const Ne=typeof Ae=="string"?{type:Ae}:Ae;if(o(V))return{...V,typeDef:{...Ne}}}return V}function x(V){return"dstSQLType"in V}function u(V){return["string","number","boolean","date","timestamp","timestamptz"].includes(V)}function d(V){return V.node==="dateLiteral"||V.node==="timestampLiteral"||V.node==="timestamptzLiteral"}function f(V){return["string","number","boolean","date","timestamp","timestamptz","filter expression","error"].includes(V)}function m(V){return V.value!==null}function h(V){return V===void 0||V==="scalar"}function p(V){return V==="aggregate"||V==="ungrouped_aggregate"}function l(V){return V==="ungrouped_aggregate"}function C(V){return V==="aggregate"||V==="ungrouped_aggregate"||V==="aggregate_analytic"}function E(V){return V==="aggregate"||V==="scalar_analytic"||V==="aggregate_analytic"||V==="ungrouped_aggregate"}function y(V){return V==="aggregate_analytic"||V==="scalar_analytic"}function _(V){return{scalar:0,aggregate:1,ungrouped_aggregate:2,scalar_analytic:2,aggregate_analytic:3}[V]}function S(V,Ae){return V===Ae||_(V)<_(Ae)}function v(V,Ae){let Ne="scalar";return(V==="aggregate"||Ae==="aggregate")&&(Ne="aggregate"),(V==="ungrouped_aggregate"||Ae==="ungrouped_aggregate")&&(Ne="ungrouped_aggregate"),(V==="scalar_analytic"||Ae==="scalar_analytic")&&(Ne="scalar_analytic"),(V==="aggregate_analytic"||Ae==="aggregate_analytic")&&(Ne="aggregate_analytic"),(V==="scalar_analytic"&&Ae==="aggregate"||V==="aggregate"&&Ae==="scalar_analytic")&&(Ne="aggregate_analytic"),Ne}function A(V){return V.reduce(v,"scalar")}function w(V){return"e"in V&&V.e!==void 0}function L(V){return V==="date"||V==="timestamp"||V==="timestamptz"}function F(V){return["string","number","date","timestamp","timestamptz","boolean","json","sql native","record","array","error"].includes(V)}function P(V){return["string","number","date","boolean","date","timestamp","timestamptz"].includes(V)}function k(V){return["string","number","date","timestamp","timestamptz","boolean","json"].includes(V)}function I(V){return F(V.type)&&!w(V)}function j(V,Ae){if(z(V))return H(V.elementTypeDef,Ae);if(O(V)){const{type:Ue,fields:nt,elementTypeDef:lt}=V;return{type:Ue,fields:nt,elementTypeDef:lt,join:"many",name:Ae}}if(V.type==="record"){const{type:Ue,fields:nt}=V;return{type:Ue,fields:nt,join:"one",name:Ae}}const Ne={name:Ae,type:V.type};switch(V.type){case"sql native":return{...Ne,rawType:V.rawType};case"number":{const Ue=V.numberType;return Ue?{...Ne,numberType:Ue}:Ne}case"date":{const Ue=V.timeframe;return Ue?{name:Ae,type:"date",timeframe:Ue}:Ne}case"timestamp":{const Ue={name:Ae,type:"timestamp"};return V.timeframe&&(Ue.timeframe=V.timeframe),Ue}case"timestamptz":{const Ue={name:Ae,type:"timestamptz"};return V.timeframe&&(Ue.timeframe=V.timeframe),Ue}}return Ne}function H(V,Ae){if(V.type==="record")return{type:"array",join:"many",name:Ae,elementTypeDef:{type:"record_element"},fields:V.fields};const Ne=j(V,"value");return{type:"array",join:"many",name:Ae,elementTypeDef:V,fields:[Ne,{...Ne,name:"each",e:{node:"field",path:["value"]}}]}}function q(V){return V.type==="array"&&V.elementTypeDef.type==="record_element"}function O(V){return V.type==="array"&&V.elementTypeDef.type==="record_element"}function W(V){return V.type==="record"||V.type==="array"&&"elementTypeDef"in V&&V.elementTypeDef.type==="record_element"}function z(V){return V.type==="array"&&V.elementTypeDef.type!=="record_element"}function ie(V){return["left","right","full","inner"].includes(V)}function K(V){return["composite","table","sql_select","query_source","array","record"].includes(V.type)}function fe(V){return"join"in V}function Z(V){return It(V)&&fe(V)}function te(V){return["day","week","month","quarter","year"].includes(V)}function Y(V){return te(V)||["hour","minute","second"].includes(V)}function re(V){return Y(V)||V==="day_of_week"||V==="day_of_year"}var ue;(function(V){V.Date="date",V.Timestamp="timestamp",V.Number="number",V.String="string"})(ue||(e.ValueType=ue={}));function he(V){return typeof V!="string"}function xe(V){return!!((V.type==="reduce"||V.type==="project"||V.type==="partial")&&(V.extendSource&&V.extendSource.some(Ae=>Ae.type==="error")||V.queryFields.some(Ae=>Ae.type==="error")))}function X(V){return V.fields.some(Ae=>Ae.type==="error")}function de(V){return V.type==="reduce"}function ve(V){return V.type==="partial"}function ce(V){return V.type==="project"}function Te(V){return ce(V)||de(V)}function Qe(V){return V.rows!==void 0}function Re(V){return V.percent!==void 0}function Le(V){return V.enable!==void 0}function Ie(V){return V.type==="raw"}function Ge(V){return V.type==="index"}function ot(V){return V.uniqueKeyRequirement===void 0&&V.analyticFunctionUse===void 0}function Ze(V){return"sql"in V}function ut(V){return{...V}}function It(V){return V.type==="table"||V.type==="sql_select"||V.type==="query_source"||V.type==="query_result"||V.type==="finalize"||V.type==="nest_source"||V.type==="composite"}function Dt(V){return Z(V)?!1:!!It(V)}function Bt(V){return V==="literal"}function zt(...V){return V.length<=1&&V.every(Ae=>Ae==="literal")?"literal":V.every(Ae=>Ae==="constant"||Ae==="literal")?"constant":V.every(Ae=>Ae==="output"||Ae==="constant"||Ae==="literal")?"output":"input"}function rr(V){return V.type==="string"||L(V.type)||V.type==="number"||V.type==="boolean"||V.type==="json"||V.type==="sql native"||V.type==="error"}function Qr(V){return V.as!==void 0?V.as:V.name}function Jt(V){return V.type==="turtle"}function mr(V){return F(V.type)}function kr(V,Ae){return Ae.type==="string"}function Jr(V,Ae){return Ae.type==="number"}function ft(V,Ae){return Ae.type==="boolean"}function se(V,Ae){return Ae.type==="timestamp"}function ae(V,Ae){return Ae.type==="date"}e.TD={isAtomic(V){return V!==void 0&&F(V.type)},isBasicAtomic(V){return V!==void 0&&rr({type:V.type})},isString:V=>V?.type==="string",isNumber:V=>V?.type==="number",isBoolean:V=>V?.type==="boolean",isJSON:V=>V?.type==="json",isSQL:V=>V?.type==="sql native",isDate:V=>V?.type==="date",isTimestamp:V=>V?.type==="timestamp",isTimestamptz:V=>V?.type==="timestamptz",isAnyTimestamp(V){return V?.type==="timestamp"||V?.type==="timestamptz"},isTemporal(V){var Ae;const Ne=(Ae=V?.type)!==null&&Ae!==void 0?Ae:"";return L(Ne)},isError:V=>V?.type==="error",eq(V,Ae){if(V===void 0||Ae===void 0)return!1;function Ne(Ue,nt){const lt={};for(const pt of Ue.fields||[])if(pt.name)lt[pt.name]=pt;else return!1;for(const pt of nt.fields||[])if(!e.TD.eq(lt[pt.name],pt))return!1;return!0}return V.type==="array"&&Ae.type==="array"?V.elementTypeDef.type!==Ae.elementTypeDef.type?!1:V.elementTypeDef.type!=="record_element"&&Ae.elementTypeDef.type!=="record_element"?e.TD.eq(V.elementTypeDef,Ae.elementTypeDef):e.TD.isAtomic(V)&&e.TD.isAtomic(Ae)&&Ne(V,Ae):V.type==="record"&&Ae.type==="record"?e.TD.isAtomic(V)&&e.TD.isAtomic(Ae)&&Ne(V,Ae):V.type==="sql native"&&Ae.type==="sql native"?V.rawType!==void 0&&V.rawType===Ae.rawType:V.type===Ae.type}};function _e(V,Ae){return V?Ae?{isCount:V.isCount||Ae.isCount}:V:Ae}})(pg)),pg}var wC;function Js(){if(wC)return gr;wC=1,Object.defineProperty(gr,"__esModule",{value:!0}),gr.arg=t,gr.spread=r,gr.sql=i,gr.constant=a,gr.output=o,gr.literal=c,gr.variadicParam=x,gr.param=u,gr.makeParam=d,gr.maxScalar=f,gr.maxAggregate=m,gr.anyExprType=h,gr.maxUngroupedAggregate=p,gr.maxAnalytic=l,gr.minScalar=C,gr.minAggregate=E,gr.minAnalytic=y,gr.overload=_,gr.expandBlueprintMap=te,gr.expandOverrideMapFromBase=ue,gr.def=xe;const e=Ke();function t(X){return{node:"function_parameter",name:X}}function r(X,de=void 0,ve=void 0){return{node:"spread",e:X,prefix:de,suffix:ve}}function i(X,...de){const ve={node:"genericSQLExpr",kids:{args:[]},src:[]},ce=[...de];let Te="";for(const Qe of X){Te+=Qe;const Re=ce.shift();Re!==void 0&&(typeof Re=="string"?Te+=Re:(ve.src.push(Te),ve.kids.args.push(Re),Te=""))}return Te.length>0&&ve.src.push(Te),ve}function a(X){return{...X,evalSpace:"constant"}}function o(X){return{...X,evalSpace:"output"}}function c(X){return{...X,evalSpace:"literal"}}function x(X,...de){return{name:X,isVariadic:!0,allowedTypes:de}}function u(X,...de){return{name:X,isVariadic:!1,allowedTypes:de}}function d(X,...de){return{param:u(X,...de),arg:t(X)}}function f(X){return{...X,expressionType:"scalar",evalSpace:"input"}}function m(X){return{...X,expressionType:"aggregate",evalSpace:"input"}}function h(X){return{...X,expressionType:void 0,evalSpace:"input"}}function p(X){return{...X,expressionType:"ungrouped_aggregate",evalSpace:"input"}}function l(X){return{...X,expressionType:"aggregate_analytic",evalSpace:"input"}}function C(X){return{...X,expressionType:"scalar",evalSpace:"input"}}function E(X){return{...X,expressionType:"aggregate",evalSpace:"input"}}function y(X){return{...X,expressionType:"scalar_analytic",evalSpace:"input"}}function _(X,de,ve,ce){return{returnType:X,params:de,e:ve,needsWindowOrderBy:ce?.needsWindowOrderBy,between:ce?.between,isSymmetric:ce?.isSymmetric,supportsOrderBy:ce?.supportsOrderBy,defaultOrderByArgIndex:ce?.defaultOrderByArgIndex,supportsLimit:ce?.supportsLimit}}function S(X,de=!0,ve=!0){if(!de&&X==="any")throw new Error("Return type cannot include any");if(typeof X=="string")return{type:X};if("array"in X){const ce=de?S(X.array,!0):S(X.array,!1);return ce.type==="record"?{type:"array",elementTypeDef:{type:"record_element"},fields:ce.fields}:{type:"array",elementTypeDef:ce}}else if("record"in X){const ce=[];for(const[Te,Qe]of Object.entries(X.record)){const Re=de?S(Qe,!0):S(Qe,!1);e.TD.isAtomic(Re)&&ce.push((0,e.mkFieldDef)(Re,Te))}return{type:"record",fields:ce}}else if("generic"in X){if(!ve)throw new Error("Cannot use generic");return{type:"generic",generic:X.generic}}else if("sql_native"in X)return{type:"sql native",rawType:X.sql_native};throw new Error("Cannot figure out type")}function v(X){if(X==="any")throw new Error("Cannot return any type");if(typeof X=="string")return C({type:X});if("array"in X)return h(S(X,!1));if("record"in X)return h(S(X,!1));if("generic"in X)return C(S(X,!1));if("literal"in X)return c(C(S(X.literal,!1)));if("constant"in X)return a(C(S(X.constant,!1)));if("dimension"in X)return C(S(X.dimension,!1));if("measure"in X)return E(S(X.measure,!1));if("sql_native"in X)return h({type:"sql native",rawType:X.sql_native});if("calculation"in X)return y(S(X.calculation,!1));throw new Error("Invalid function blueprint")}function A(X){return typeof X=="string"||"array"in X||"record"in X||"generic"in X||"literal"in X||"constant"in X||"dimension"in X||"measure"in X||"calculation"in X||"sql_native"in X}function w(X){return A(X)?[X]:Array.isArray(X)?X:A(X.variadic)?[X.variadic]:X.variadic}function L(X){if(typeof X=="string")return h({type:X});if("generic"in X)return h(S(X));if("literal"in X)return c(f(S(X.literal)));if("constant"in X)return a(f(S(X.constant)));if("dimension"in X)return f(S(X.dimension));if("measure"in X)return m(S(X.measure));if("array"in X)return h(S(X,!1));if("record"in X)return h(S(X,!1));if("sql_native"in X)return h({type:"sql native",rawType:X.sql_native});if("calculation"in X)return l(S(X.calculation));throw new Error("Invalid function blueprint")}function F(X){return X.map(de=>L(de))}function P(X){return typeof X!="string"&&"variadic"in X}function k(X,de){return{name:X,allowedTypes:F(w(de)),isVariadic:P(de)}}function I(X){return Object.entries(X).map(ve=>k(ve[0],ve[1]))}function j(X){const de=[],ve=[];let ce=X;for(;ce.length>0;){const Qe=ce.indexOf("${");if(Qe===-1){de.push(ce);break}const Re=ce.slice(0,Qe);ce=ce.slice(Qe);const Le=ce.indexOf("}");if(Le===-1){de.push(Re+ce);break}const Ie=ce.slice(2,Le);ce=ce.slice(Le+1);const Ge=Ie.startsWith("..."),ot=Ie.endsWith(":"),Ze=Ge?Ie.slice(3):ot?Ie.slice(0,-1):Ie,ut={node:"function_parameter",name:Ze};de.push(Re),Ge?ve.push({node:"spread",e:ut,prefix:"",suffix:""}):ot&&Ze==="order_by"?ve.push({node:"aggregate_order_by"}):ot&&Ze==="limit"?ve.push({node:"aggregate_limit"}):ve.push(ut)}return{node:"genericSQLExpr",kids:{args:ve},src:de}}function H(X,de){return P(de)?{node:"spread",e:{node:"function_parameter",name:X},prefix:"",suffix:""}:{node:"function_parameter",name:X}}function q(X,de){const ve=Object.entries(de.takes),ce=ve.length>0?ve.length-1:0;return{node:"genericSQLExpr",kids:{args:ve.map(Te=>H(Te[0],Te[1]))},src:[`${X}(`,...Array(ce).fill(","),")"]}}function O(X){return"sql"in X.impl?j(X.impl.sql):"expr"in X.impl?X.impl.expr:q(X.impl.function,X)}function W(X){return{e:O(X),between:X.impl.between,needsWindowOrderBy:X.impl.needsWindowOrderBy,defaultOrderByArgIndex:X.impl.defaultOrderByArgIndex}}function z(X){if(X!==void 0)return Object.entries(X).map(([de,ve])=>({name:de,acceptibleTypes:ve.map(ce=>S(ce,!0,!1))}))}function ie(X){return{returnType:v(X.returns),params:I(X.takes),isSymmetric:X.isSymmetric,supportsOrderBy:X.supportsOrderBy,supportsLimit:X.supportsLimit,genericTypes:z(X.generic),...W(X)}}function K(X){return"takes"in X&&"returns"in X&&"impl"in X}function fe(X){return"function"in X||"sql"in X||"expr"in X}function Z(X){return K(X)?[ie(X)]:Object.values(X).flatMap(de=>ie(de))}function te(X){const de={};for(const ve in X)de[ve]=Z(X[ve]);return de}function Y(X,de){return[ie({...X,impl:de})]}function re(X,de,ve){if(fe(ve)){if(!K(de))throw new Error(`Malformed function override: ${X}. Attempt to override multiple overloads with a single overload (missing: ${Object.keys(de)})`);return Y(de,ve)}else{if(K(de))throw new Error(`Malformed function override: ${X}. Attempt to override a single overload with multiple overloads (extraneous: ${Object.keys(ve)})`);return Object.entries(ve).flatMap(([ce,Te])=>{const Qe=de[ce];if(Qe===void 0)throw new Error(`Malformed function override: ${X}. No overload named ${ce}`);return Y(Qe,Te)})}}function ue(X,de){const ve={};for(const ce in de){if(!(ce in X))throw new Error(`Malformed function override: ${ce}. No such function in Malloy standard`);ve[ce]=re(ce,X[ce],de[ce])}return ve}function*he(X){if(typeof X!="string"){if("generic"in X)yield X;else if("record"in X)for(const de of Object.values(X.record))yield*he(de);else for(const de of["array","literal","measure","dimension","measure","constant","cacluation"])if(de in X){yield*he(X[de]);return}}}function xe(X,de,ve,ce={}){let Te=!1;const Qe={};for(const Le of Object.values(de))for(const Ie of he(Le))Qe[Ie.generic]=["any"],Te=!0;Te&&ce.generic===void 0&&(ce.generic=Qe);const Re={takes:de,returns:ve,impl:{function:X.toUpperCase()},...ce};return{[X]:Re}}return gr}var mg={},DC;function Aa(){return DC||(DC=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Dialect=e.dayIndex=e.MAX_DECIMAL38=e.MIN_DECIMAL38=e.MAX_INT128=e.MIN_INT128=e.MAX_INT64=e.MIN_INT64=e.MAX_INT32=e.MIN_INT32=void 0,e.inDays=i,e.qtz=a;const t=Ke();e.MIN_INT32=-2147483648,e.MAX_INT32=2147483647,e.MIN_INT64=BigInt("-9223372036854775808"),e.MAX_INT64=BigInt("9223372036854775807"),e.MIN_INT128=BigInt("-170141183460469231731687303715884105728"),e.MAX_INT128=BigInt("170141183460469231731687303715884105727"),e.MIN_DECIMAL38=BigInt("-99999999999999999999999999999999999999"),e.MAX_DECIMAL38=BigInt("99999999999999999999999999999999999999");const r=["microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"];e.dayIndex=r.indexOf("day");function i(c){return r.indexOf(c)>=e.dayIndex}function a(c){const x=c.queryTimezone;if(!(x===void 0||x===c.systemTimezone))return x}class o{constructor(){this.cantPartitionWindowFunctionsOnExpressions=!1,this.supportsPipelinesInViews=!0,this.supportsArraysInData=!0,this.hasTimestamptz=!1,this.readsNestedData=!0,this.orderByClause="ordinal",this.nullMatchesFunctionSignature=!0,this.supportsSelectReplace=!0,this.supportsBigIntPrecision=!0,this.supportsComplexFilteredSources=!0,this.supportsTempTables=!0,this.hasModOperator=!0,this.supportsLeftJoinUnnest=!0,this.requiresExplicitUnnestOrdering=!1,this.supportsCountApprox=!1,this.supportsHyperLogLog=!1,this.supportsFullJoin=!0,this.nestedArrays=!0,this.compoundObjectInSchema=!0,this.booleanType="supported",this.likeEscape=!0,this.integerTypeMappings=[{min:BigInt(e.MIN_INT32),max:BigInt(e.MAX_INT32),numberType:"integer"},{min:e.MIN_INT64,max:e.MAX_INT64,numberType:"bigint"}]}literalNumberType(x){if(!/^-?\d+$/.test(x))return{type:"number",numberType:"float"};const d=BigInt(x);for(const f of this.integerTypeMappings)if(d>=f.min&&d<=f.max)return{type:"number",numberType:f.numberType};return{type:"number",numberType:"bigint"}}static makeTimeLiteralNode(x,u,d,f,m){var h;const p=(h=x?.hasTimestamptz)!==null&&h!==void 0?h:!1;return m==="date"?{node:"dateLiteral",literal:u,typeDef:{type:"date",timeframe:f!==void 0&&(0,t.isDateUnit)(f)?f:void 0}}:d&&p?{node:"timestamptzLiteral",literal:u,typeDef:{type:"timestamptz",timeframe:f},timezone:d}:d?{node:"timestampLiteral",literal:u,typeDef:{type:"timestamp",timeframe:f},timezone:d}:{node:"timestampLiteral",literal:u,typeDef:{type:"timestamp",timeframe:f}}}sqlFinalStage(x,u){throw new Error("Dialect has no final Stage but called Anyway")}sqlDateToString(x){return this.castToString(`DATE(${x})`)}sqlLiteralNumber(x){return x}ignoreInProject(x){return!1}needsCivilTimeComputation(x,u,d,f){const m=["day","week","month","quarter","year"],h=u!==void 0&&m.includes(u),p=d!==void 0&&m.includes(d),l=a(f);return{needed:t.TD.isAnyTimestamp(x)&&(h||p)&&l!==void 0,tz:l}}sqlTruncAndOffset(x,u,d,f){if(t.TD.isAnyTimestamp(x.typeDef)){const{needed:h,tz:p}=this.needsCivilTimeComputation(x.typeDef,d,f?.unit,u);if(h&&p){const l=this.sqlConvertToCivilTime(x.sql,p,x.typeDef);let C=l.sql;const E=l.typeDef;return d&&(C=this.sqlTruncate(C,d,E,!0,p)),f&&(C=this.sqlOffsetTime(C,f.op,f.magnitude,f.unit,E,!0,p)),this.sqlConvertFromCivilTime(C,p,x.typeDef)}}let m=x.sql;return d&&(m=this.sqlTruncate(m,d,x.typeDef,!1,a(u))),f&&(m=this.sqlOffsetTime(m,f.op,f.magnitude,f.unit,x.typeDef,!1,a(u))),m}exprToSQL(x,u){switch(u.node){case"now":return this.sqlNowExpr();case"timeDiff":return this.sqlMeasureTimeExpr(u);case"delta":{const d=u.kids.base;return d.node==="trunc"?this.sqlTruncAndOffset(d.e,x,d.units,{op:u.op,magnitude:u.kids.delta.sql,unit:u.units}):this.sqlTruncAndOffset(d,x,void 0,{op:u.op,magnitude:u.kids.delta.sql,unit:u.units})}case"trunc":return this.sqlTruncAndOffset(u.e,x,u.units);case"extract":return this.sqlTimeExtractExpr(x,u);case"cast":return this.sqlCast(x,u);case"regexpMatch":return this.sqlRegexpMatch(u);case"/":return this.divisionIsInteger?`${u.kids.left.sql}*1.0/${u.kids.right.sql}`:void 0;case"%":return this.hasModOperator?void 0:`MOD(${u.kids.left.sql},${u.kids.right.sql})`;case"dateLiteral":return this.sqlDateLiteral(x,u.literal);case"timestampLiteral":return this.sqlTimestampLiteral(x,u.literal,u.timezone);case"timestamptzLiteral":return this.sqlTimestamptzLiteral(x,u.literal,u.timezone);case"stringLiteral":return this.sqlLiteralString(u.literal);case"numberLiteral":return this.sqlLiteralNumber(u.literal);case"regexpLiteral":return this.sqlLiteralRegexp(u.literal);case"recordLiteral":return this.sqlLiteralRecord(u);case"arrayLiteral":return this.sqlLiteralArray(u)}}sqlSumDistinct(x,u,d){return"sqlSumDistinct called but not implemented"}sqlAggDistinct(x,u,d){return"sqlAggDistinct called but not implemented"}sqlSampleTable(x,u){if(u!==void 0)throw new Error(`Sampling is not supported on dialect ${this.name}.`);return x}sqlOrderBy(x,u){return`ORDER BY ${x.join(",")}`}sqlTzStr(x){return`"${x.queryTimezone}"`}sqlMakeUnnestKey(x,u){return this.concat(x,"'x'",u)}sqlStringAggDistinct(x,u,d){const f="__STRING_AGG_KS__",m="__STRING_AGG_KE__";return`REGEXP_REPLACE(
|
|
1
|
+
import{G as LL,r as T,j as R,H as Ht,R as rR,L as nR,N as ys}from"./index-BvVmB5sv.js";import{r as n0,a as Oy,b as Fy,c as i0,d as s0,e as Ny,f as Iy,g as ky,h as My,j as By,k as Py,l as $y,m as qy,n as jy,o as o0,p as a0,q as u0,s as l0,t as iR,u as OL,v as Uy,w as ct}from"./index-CsC07BYd.js";import{a as b1}from"./index.umd-DvM-lTQa.js";var Co={},hg={},gr={},pg={},TC;function Ke(){return TC||(TC=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TD=e.ValueType=void 0,e.exprHasKids=t,e.exprHasE=r,e.exprIsLeaf=i,e.isAsymmetricExpr=a,e.mkTemporal=c,e.isRawCast=x,e.isFilterExprType=u,e.isTimeLiteral=d,e.isParameterType=f,e.paramHasValue=m,e.expressionIsScalar=h,e.expressionIsAggregate=p,e.expressionIsUngroupedAggregate=l,e.expressionInvolvesAggregate=C,e.expressionIsCalculation=E,e.expressionIsAnalytic=y,e.isExpressionTypeLEQ=S,e.maxExpressionType=v,e.maxOfExpressionTypes=A,e.hasExpression=w,e.isTemporalType=L,e.isAtomicFieldType=F,e.canOrderBy=P,e.isCastType=k,e.fieldIsIntrinsic=I,e.mkFieldDef=j,e.mkArrayDef=H,e.isRepeatedRecordFunctionParam=q,e.isRepeatedRecord=O,e.isRecordOrRepeatedRecord=W,e.isBasicArray=z,e.isMatrixOperation=ie,e.isJoinable=K,e.isJoined=fe,e.isJoinedSource=Z,e.isDateUnit=te,e.isTimestampUnit=Y,e.isExtractUnit=re,e.refIsStructDef=he,e.segmentHasErrors=xe,e.structHasErrors=X,e.isReduceSegment=de,e.isPartialSegment=ve,e.isProjectSegment=ce,e.isQuerySegment=Te,e.isSamplingRows=Qe,e.isSamplingPercent=Re,e.isSamplingEnable=Le,e.isRawSegment=Ie,e.isIndexSegment=Ge,e.bareFieldUsage=ot,e.isSegmentSQL=Ze,e.sourceBase=ut,e.isSourceDef=It,e.isBaseTable=Dt,e.isLiteral=Bt,e.mergeEvalSpaces=zt,e.isBasicAtomic=rr,e.getIdentifier=Qr,e.isTurtle=Jt,e.isAtomic=mr,e.isValueString=kr,e.isValueNumber=Jr,e.isValueBoolean=ft,e.isValueTimestamp=se,e.isValueDate=ae,e.mergeUniqueKeyRequirement=_e;function t(V){return"kids"in V}function r(V){return"e"in V}function i(V){return!(t(V)||r(V))}function a(V){return V.node==="aggregate"&&["sum","avg","count","distinct"].includes(V.function)}function o(V){return V.node!=="arrayLiteral"&&V.node!=="recordLiteral"}function c(V,Ae){if(!("typeDef"in V)){const Ne=typeof Ae=="string"?{type:Ae}:Ae;if(o(V))return{...V,typeDef:{...Ne}}}return V}function x(V){return"dstSQLType"in V}function u(V){return["string","number","boolean","date","timestamp","timestamptz"].includes(V)}function d(V){return V.node==="dateLiteral"||V.node==="timestampLiteral"||V.node==="timestamptzLiteral"}function f(V){return["string","number","boolean","date","timestamp","timestamptz","filter expression","error"].includes(V)}function m(V){return V.value!==null}function h(V){return V===void 0||V==="scalar"}function p(V){return V==="aggregate"||V==="ungrouped_aggregate"}function l(V){return V==="ungrouped_aggregate"}function C(V){return V==="aggregate"||V==="ungrouped_aggregate"||V==="aggregate_analytic"}function E(V){return V==="aggregate"||V==="scalar_analytic"||V==="aggregate_analytic"||V==="ungrouped_aggregate"}function y(V){return V==="aggregate_analytic"||V==="scalar_analytic"}function _(V){return{scalar:0,aggregate:1,ungrouped_aggregate:2,scalar_analytic:2,aggregate_analytic:3}[V]}function S(V,Ae){return V===Ae||_(V)<_(Ae)}function v(V,Ae){let Ne="scalar";return(V==="aggregate"||Ae==="aggregate")&&(Ne="aggregate"),(V==="ungrouped_aggregate"||Ae==="ungrouped_aggregate")&&(Ne="ungrouped_aggregate"),(V==="scalar_analytic"||Ae==="scalar_analytic")&&(Ne="scalar_analytic"),(V==="aggregate_analytic"||Ae==="aggregate_analytic")&&(Ne="aggregate_analytic"),(V==="scalar_analytic"&&Ae==="aggregate"||V==="aggregate"&&Ae==="scalar_analytic")&&(Ne="aggregate_analytic"),Ne}function A(V){return V.reduce(v,"scalar")}function w(V){return"e"in V&&V.e!==void 0}function L(V){return V==="date"||V==="timestamp"||V==="timestamptz"}function F(V){return["string","number","date","timestamp","timestamptz","boolean","json","sql native","record","array","error"].includes(V)}function P(V){return["string","number","date","boolean","date","timestamp","timestamptz"].includes(V)}function k(V){return["string","number","date","timestamp","timestamptz","boolean","json"].includes(V)}function I(V){return F(V.type)&&!w(V)}function j(V,Ae){if(z(V))return H(V.elementTypeDef,Ae);if(O(V)){const{type:Ue,fields:nt,elementTypeDef:lt}=V;return{type:Ue,fields:nt,elementTypeDef:lt,join:"many",name:Ae}}if(V.type==="record"){const{type:Ue,fields:nt}=V;return{type:Ue,fields:nt,join:"one",name:Ae}}const Ne={name:Ae,type:V.type};switch(V.type){case"sql native":return{...Ne,rawType:V.rawType};case"number":{const Ue=V.numberType;return Ue?{...Ne,numberType:Ue}:Ne}case"date":{const Ue=V.timeframe;return Ue?{name:Ae,type:"date",timeframe:Ue}:Ne}case"timestamp":{const Ue={name:Ae,type:"timestamp"};return V.timeframe&&(Ue.timeframe=V.timeframe),Ue}case"timestamptz":{const Ue={name:Ae,type:"timestamptz"};return V.timeframe&&(Ue.timeframe=V.timeframe),Ue}}return Ne}function H(V,Ae){if(V.type==="record")return{type:"array",join:"many",name:Ae,elementTypeDef:{type:"record_element"},fields:V.fields};const Ne=j(V,"value");return{type:"array",join:"many",name:Ae,elementTypeDef:V,fields:[Ne,{...Ne,name:"each",e:{node:"field",path:["value"]}}]}}function q(V){return V.type==="array"&&V.elementTypeDef.type==="record_element"}function O(V){return V.type==="array"&&V.elementTypeDef.type==="record_element"}function W(V){return V.type==="record"||V.type==="array"&&"elementTypeDef"in V&&V.elementTypeDef.type==="record_element"}function z(V){return V.type==="array"&&V.elementTypeDef.type!=="record_element"}function ie(V){return["left","right","full","inner"].includes(V)}function K(V){return["composite","table","sql_select","query_source","array","record"].includes(V.type)}function fe(V){return"join"in V}function Z(V){return It(V)&&fe(V)}function te(V){return["day","week","month","quarter","year"].includes(V)}function Y(V){return te(V)||["hour","minute","second"].includes(V)}function re(V){return Y(V)||V==="day_of_week"||V==="day_of_year"}var ue;(function(V){V.Date="date",V.Timestamp="timestamp",V.Number="number",V.String="string"})(ue||(e.ValueType=ue={}));function he(V){return typeof V!="string"}function xe(V){return!!((V.type==="reduce"||V.type==="project"||V.type==="partial")&&(V.extendSource&&V.extendSource.some(Ae=>Ae.type==="error")||V.queryFields.some(Ae=>Ae.type==="error")))}function X(V){return V.fields.some(Ae=>Ae.type==="error")}function de(V){return V.type==="reduce"}function ve(V){return V.type==="partial"}function ce(V){return V.type==="project"}function Te(V){return ce(V)||de(V)}function Qe(V){return V.rows!==void 0}function Re(V){return V.percent!==void 0}function Le(V){return V.enable!==void 0}function Ie(V){return V.type==="raw"}function Ge(V){return V.type==="index"}function ot(V){return V.uniqueKeyRequirement===void 0&&V.analyticFunctionUse===void 0}function Ze(V){return"sql"in V}function ut(V){return{...V}}function It(V){return V.type==="table"||V.type==="sql_select"||V.type==="query_source"||V.type==="query_result"||V.type==="finalize"||V.type==="nest_source"||V.type==="composite"}function Dt(V){return Z(V)?!1:!!It(V)}function Bt(V){return V==="literal"}function zt(...V){return V.length<=1&&V.every(Ae=>Ae==="literal")?"literal":V.every(Ae=>Ae==="constant"||Ae==="literal")?"constant":V.every(Ae=>Ae==="output"||Ae==="constant"||Ae==="literal")?"output":"input"}function rr(V){return V.type==="string"||L(V.type)||V.type==="number"||V.type==="boolean"||V.type==="json"||V.type==="sql native"||V.type==="error"}function Qr(V){return V.as!==void 0?V.as:V.name}function Jt(V){return V.type==="turtle"}function mr(V){return F(V.type)}function kr(V,Ae){return Ae.type==="string"}function Jr(V,Ae){return Ae.type==="number"}function ft(V,Ae){return Ae.type==="boolean"}function se(V,Ae){return Ae.type==="timestamp"}function ae(V,Ae){return Ae.type==="date"}e.TD={isAtomic(V){return V!==void 0&&F(V.type)},isBasicAtomic(V){return V!==void 0&&rr({type:V.type})},isString:V=>V?.type==="string",isNumber:V=>V?.type==="number",isBoolean:V=>V?.type==="boolean",isJSON:V=>V?.type==="json",isSQL:V=>V?.type==="sql native",isDate:V=>V?.type==="date",isTimestamp:V=>V?.type==="timestamp",isTimestamptz:V=>V?.type==="timestamptz",isAnyTimestamp(V){return V?.type==="timestamp"||V?.type==="timestamptz"},isTemporal(V){var Ae;const Ne=(Ae=V?.type)!==null&&Ae!==void 0?Ae:"";return L(Ne)},isError:V=>V?.type==="error",eq(V,Ae){if(V===void 0||Ae===void 0)return!1;function Ne(Ue,nt){const lt={};for(const pt of Ue.fields||[])if(pt.name)lt[pt.name]=pt;else return!1;for(const pt of nt.fields||[])if(!e.TD.eq(lt[pt.name],pt))return!1;return!0}return V.type==="array"&&Ae.type==="array"?V.elementTypeDef.type!==Ae.elementTypeDef.type?!1:V.elementTypeDef.type!=="record_element"&&Ae.elementTypeDef.type!=="record_element"?e.TD.eq(V.elementTypeDef,Ae.elementTypeDef):e.TD.isAtomic(V)&&e.TD.isAtomic(Ae)&&Ne(V,Ae):V.type==="record"&&Ae.type==="record"?e.TD.isAtomic(V)&&e.TD.isAtomic(Ae)&&Ne(V,Ae):V.type==="sql native"&&Ae.type==="sql native"?V.rawType!==void 0&&V.rawType===Ae.rawType:V.type===Ae.type}};function _e(V,Ae){return V?Ae?{isCount:V.isCount||Ae.isCount}:V:Ae}})(pg)),pg}var wC;function Js(){if(wC)return gr;wC=1,Object.defineProperty(gr,"__esModule",{value:!0}),gr.arg=t,gr.spread=r,gr.sql=i,gr.constant=a,gr.output=o,gr.literal=c,gr.variadicParam=x,gr.param=u,gr.makeParam=d,gr.maxScalar=f,gr.maxAggregate=m,gr.anyExprType=h,gr.maxUngroupedAggregate=p,gr.maxAnalytic=l,gr.minScalar=C,gr.minAggregate=E,gr.minAnalytic=y,gr.overload=_,gr.expandBlueprintMap=te,gr.expandOverrideMapFromBase=ue,gr.def=xe;const e=Ke();function t(X){return{node:"function_parameter",name:X}}function r(X,de=void 0,ve=void 0){return{node:"spread",e:X,prefix:de,suffix:ve}}function i(X,...de){const ve={node:"genericSQLExpr",kids:{args:[]},src:[]},ce=[...de];let Te="";for(const Qe of X){Te+=Qe;const Re=ce.shift();Re!==void 0&&(typeof Re=="string"?Te+=Re:(ve.src.push(Te),ve.kids.args.push(Re),Te=""))}return Te.length>0&&ve.src.push(Te),ve}function a(X){return{...X,evalSpace:"constant"}}function o(X){return{...X,evalSpace:"output"}}function c(X){return{...X,evalSpace:"literal"}}function x(X,...de){return{name:X,isVariadic:!0,allowedTypes:de}}function u(X,...de){return{name:X,isVariadic:!1,allowedTypes:de}}function d(X,...de){return{param:u(X,...de),arg:t(X)}}function f(X){return{...X,expressionType:"scalar",evalSpace:"input"}}function m(X){return{...X,expressionType:"aggregate",evalSpace:"input"}}function h(X){return{...X,expressionType:void 0,evalSpace:"input"}}function p(X){return{...X,expressionType:"ungrouped_aggregate",evalSpace:"input"}}function l(X){return{...X,expressionType:"aggregate_analytic",evalSpace:"input"}}function C(X){return{...X,expressionType:"scalar",evalSpace:"input"}}function E(X){return{...X,expressionType:"aggregate",evalSpace:"input"}}function y(X){return{...X,expressionType:"scalar_analytic",evalSpace:"input"}}function _(X,de,ve,ce){return{returnType:X,params:de,e:ve,needsWindowOrderBy:ce?.needsWindowOrderBy,between:ce?.between,isSymmetric:ce?.isSymmetric,supportsOrderBy:ce?.supportsOrderBy,defaultOrderByArgIndex:ce?.defaultOrderByArgIndex,supportsLimit:ce?.supportsLimit}}function S(X,de=!0,ve=!0){if(!de&&X==="any")throw new Error("Return type cannot include any");if(typeof X=="string")return{type:X};if("array"in X){const ce=de?S(X.array,!0):S(X.array,!1);return ce.type==="record"?{type:"array",elementTypeDef:{type:"record_element"},fields:ce.fields}:{type:"array",elementTypeDef:ce}}else if("record"in X){const ce=[];for(const[Te,Qe]of Object.entries(X.record)){const Re=de?S(Qe,!0):S(Qe,!1);e.TD.isAtomic(Re)&&ce.push((0,e.mkFieldDef)(Re,Te))}return{type:"record",fields:ce}}else if("generic"in X){if(!ve)throw new Error("Cannot use generic");return{type:"generic",generic:X.generic}}else if("sql_native"in X)return{type:"sql native",rawType:X.sql_native};throw new Error("Cannot figure out type")}function v(X){if(X==="any")throw new Error("Cannot return any type");if(typeof X=="string")return C({type:X});if("array"in X)return h(S(X,!1));if("record"in X)return h(S(X,!1));if("generic"in X)return C(S(X,!1));if("literal"in X)return c(C(S(X.literal,!1)));if("constant"in X)return a(C(S(X.constant,!1)));if("dimension"in X)return C(S(X.dimension,!1));if("measure"in X)return E(S(X.measure,!1));if("sql_native"in X)return h({type:"sql native",rawType:X.sql_native});if("calculation"in X)return y(S(X.calculation,!1));throw new Error("Invalid function blueprint")}function A(X){return typeof X=="string"||"array"in X||"record"in X||"generic"in X||"literal"in X||"constant"in X||"dimension"in X||"measure"in X||"calculation"in X||"sql_native"in X}function w(X){return A(X)?[X]:Array.isArray(X)?X:A(X.variadic)?[X.variadic]:X.variadic}function L(X){if(typeof X=="string")return h({type:X});if("generic"in X)return h(S(X));if("literal"in X)return c(f(S(X.literal)));if("constant"in X)return a(f(S(X.constant)));if("dimension"in X)return f(S(X.dimension));if("measure"in X)return m(S(X.measure));if("array"in X)return h(S(X,!1));if("record"in X)return h(S(X,!1));if("sql_native"in X)return h({type:"sql native",rawType:X.sql_native});if("calculation"in X)return l(S(X.calculation));throw new Error("Invalid function blueprint")}function F(X){return X.map(de=>L(de))}function P(X){return typeof X!="string"&&"variadic"in X}function k(X,de){return{name:X,allowedTypes:F(w(de)),isVariadic:P(de)}}function I(X){return Object.entries(X).map(ve=>k(ve[0],ve[1]))}function j(X){const de=[],ve=[];let ce=X;for(;ce.length>0;){const Qe=ce.indexOf("${");if(Qe===-1){de.push(ce);break}const Re=ce.slice(0,Qe);ce=ce.slice(Qe);const Le=ce.indexOf("}");if(Le===-1){de.push(Re+ce);break}const Ie=ce.slice(2,Le);ce=ce.slice(Le+1);const Ge=Ie.startsWith("..."),ot=Ie.endsWith(":"),Ze=Ge?Ie.slice(3):ot?Ie.slice(0,-1):Ie,ut={node:"function_parameter",name:Ze};de.push(Re),Ge?ve.push({node:"spread",e:ut,prefix:"",suffix:""}):ot&&Ze==="order_by"?ve.push({node:"aggregate_order_by"}):ot&&Ze==="limit"?ve.push({node:"aggregate_limit"}):ve.push(ut)}return{node:"genericSQLExpr",kids:{args:ve},src:de}}function H(X,de){return P(de)?{node:"spread",e:{node:"function_parameter",name:X},prefix:"",suffix:""}:{node:"function_parameter",name:X}}function q(X,de){const ve=Object.entries(de.takes),ce=ve.length>0?ve.length-1:0;return{node:"genericSQLExpr",kids:{args:ve.map(Te=>H(Te[0],Te[1]))},src:[`${X}(`,...Array(ce).fill(","),")"]}}function O(X){return"sql"in X.impl?j(X.impl.sql):"expr"in X.impl?X.impl.expr:q(X.impl.function,X)}function W(X){return{e:O(X),between:X.impl.between,needsWindowOrderBy:X.impl.needsWindowOrderBy,defaultOrderByArgIndex:X.impl.defaultOrderByArgIndex}}function z(X){if(X!==void 0)return Object.entries(X).map(([de,ve])=>({name:de,acceptibleTypes:ve.map(ce=>S(ce,!0,!1))}))}function ie(X){return{returnType:v(X.returns),params:I(X.takes),isSymmetric:X.isSymmetric,supportsOrderBy:X.supportsOrderBy,supportsLimit:X.supportsLimit,genericTypes:z(X.generic),...W(X)}}function K(X){return"takes"in X&&"returns"in X&&"impl"in X}function fe(X){return"function"in X||"sql"in X||"expr"in X}function Z(X){return K(X)?[ie(X)]:Object.values(X).flatMap(de=>ie(de))}function te(X){const de={};for(const ve in X)de[ve]=Z(X[ve]);return de}function Y(X,de){return[ie({...X,impl:de})]}function re(X,de,ve){if(fe(ve)){if(!K(de))throw new Error(`Malformed function override: ${X}. Attempt to override multiple overloads with a single overload (missing: ${Object.keys(de)})`);return Y(de,ve)}else{if(K(de))throw new Error(`Malformed function override: ${X}. Attempt to override a single overload with multiple overloads (extraneous: ${Object.keys(ve)})`);return Object.entries(ve).flatMap(([ce,Te])=>{const Qe=de[ce];if(Qe===void 0)throw new Error(`Malformed function override: ${X}. No overload named ${ce}`);return Y(Qe,Te)})}}function ue(X,de){const ve={};for(const ce in de){if(!(ce in X))throw new Error(`Malformed function override: ${ce}. No such function in Malloy standard`);ve[ce]=re(ce,X[ce],de[ce])}return ve}function*he(X){if(typeof X!="string"){if("generic"in X)yield X;else if("record"in X)for(const de of Object.values(X.record))yield*he(de);else for(const de of["array","literal","measure","dimension","measure","constant","cacluation"])if(de in X){yield*he(X[de]);return}}}function xe(X,de,ve,ce={}){let Te=!1;const Qe={};for(const Le of Object.values(de))for(const Ie of he(Le))Qe[Ie.generic]=["any"],Te=!0;Te&&ce.generic===void 0&&(ce.generic=Qe);const Re={takes:de,returns:ve,impl:{function:X.toUpperCase()},...ce};return{[X]:Re}}return gr}var mg={},DC;function Aa(){return DC||(DC=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Dialect=e.dayIndex=e.MAX_DECIMAL38=e.MIN_DECIMAL38=e.MAX_INT128=e.MIN_INT128=e.MAX_INT64=e.MIN_INT64=e.MAX_INT32=e.MIN_INT32=void 0,e.inDays=i,e.qtz=a;const t=Ke();e.MIN_INT32=-2147483648,e.MAX_INT32=2147483647,e.MIN_INT64=BigInt("-9223372036854775808"),e.MAX_INT64=BigInt("9223372036854775807"),e.MIN_INT128=BigInt("-170141183460469231731687303715884105728"),e.MAX_INT128=BigInt("170141183460469231731687303715884105727"),e.MIN_DECIMAL38=BigInt("-99999999999999999999999999999999999999"),e.MAX_DECIMAL38=BigInt("99999999999999999999999999999999999999");const r=["microsecond","millisecond","second","minute","hour","day","week","month","quarter","year"];e.dayIndex=r.indexOf("day");function i(c){return r.indexOf(c)>=e.dayIndex}function a(c){const x=c.queryTimezone;if(!(x===void 0||x===c.systemTimezone))return x}class o{constructor(){this.cantPartitionWindowFunctionsOnExpressions=!1,this.supportsPipelinesInViews=!0,this.supportsArraysInData=!0,this.hasTimestamptz=!1,this.readsNestedData=!0,this.orderByClause="ordinal",this.nullMatchesFunctionSignature=!0,this.supportsSelectReplace=!0,this.supportsBigIntPrecision=!0,this.supportsComplexFilteredSources=!0,this.supportsTempTables=!0,this.hasModOperator=!0,this.supportsLeftJoinUnnest=!0,this.requiresExplicitUnnestOrdering=!1,this.supportsCountApprox=!1,this.supportsHyperLogLog=!1,this.supportsFullJoin=!0,this.nestedArrays=!0,this.compoundObjectInSchema=!0,this.booleanType="supported",this.likeEscape=!0,this.integerTypeMappings=[{min:BigInt(e.MIN_INT32),max:BigInt(e.MAX_INT32),numberType:"integer"},{min:e.MIN_INT64,max:e.MAX_INT64,numberType:"bigint"}]}literalNumberType(x){if(!/^-?\d+$/.test(x))return{type:"number",numberType:"float"};const d=BigInt(x);for(const f of this.integerTypeMappings)if(d>=f.min&&d<=f.max)return{type:"number",numberType:f.numberType};return{type:"number",numberType:"bigint"}}static makeTimeLiteralNode(x,u,d,f,m){var h;const p=(h=x?.hasTimestamptz)!==null&&h!==void 0?h:!1;return m==="date"?{node:"dateLiteral",literal:u,typeDef:{type:"date",timeframe:f!==void 0&&(0,t.isDateUnit)(f)?f:void 0}}:d&&p?{node:"timestamptzLiteral",literal:u,typeDef:{type:"timestamptz",timeframe:f},timezone:d}:d?{node:"timestampLiteral",literal:u,typeDef:{type:"timestamp",timeframe:f},timezone:d}:{node:"timestampLiteral",literal:u,typeDef:{type:"timestamp",timeframe:f}}}sqlFinalStage(x,u){throw new Error("Dialect has no final Stage but called Anyway")}sqlDateToString(x){return this.castToString(`DATE(${x})`)}sqlLiteralNumber(x){return x}ignoreInProject(x){return!1}needsCivilTimeComputation(x,u,d,f){const m=["day","week","month","quarter","year"],h=u!==void 0&&m.includes(u),p=d!==void 0&&m.includes(d),l=a(f);return{needed:t.TD.isAnyTimestamp(x)&&(h||p)&&l!==void 0,tz:l}}sqlTruncAndOffset(x,u,d,f){if(t.TD.isAnyTimestamp(x.typeDef)){const{needed:h,tz:p}=this.needsCivilTimeComputation(x.typeDef,d,f?.unit,u);if(h&&p){const l=this.sqlConvertToCivilTime(x.sql,p,x.typeDef);let C=l.sql;const E=l.typeDef;return d&&(C=this.sqlTruncate(C,d,E,!0,p)),f&&(C=this.sqlOffsetTime(C,f.op,f.magnitude,f.unit,E,!0,p)),this.sqlConvertFromCivilTime(C,p,x.typeDef)}}let m=x.sql;return d&&(m=this.sqlTruncate(m,d,x.typeDef,!1,a(u))),f&&(m=this.sqlOffsetTime(m,f.op,f.magnitude,f.unit,x.typeDef,!1,a(u))),m}exprToSQL(x,u){switch(u.node){case"now":return this.sqlNowExpr();case"timeDiff":return this.sqlMeasureTimeExpr(u);case"delta":{const d=u.kids.base;return d.node==="trunc"?this.sqlTruncAndOffset(d.e,x,d.units,{op:u.op,magnitude:u.kids.delta.sql,unit:u.units}):this.sqlTruncAndOffset(d,x,void 0,{op:u.op,magnitude:u.kids.delta.sql,unit:u.units})}case"trunc":return this.sqlTruncAndOffset(u.e,x,u.units);case"extract":return this.sqlTimeExtractExpr(x,u);case"cast":return this.sqlCast(x,u);case"regexpMatch":return this.sqlRegexpMatch(u);case"/":return this.divisionIsInteger?`${u.kids.left.sql}*1.0/${u.kids.right.sql}`:void 0;case"%":return this.hasModOperator?void 0:`MOD(${u.kids.left.sql},${u.kids.right.sql})`;case"dateLiteral":return this.sqlDateLiteral(x,u.literal);case"timestampLiteral":return this.sqlTimestampLiteral(x,u.literal,u.timezone);case"timestamptzLiteral":return this.sqlTimestamptzLiteral(x,u.literal,u.timezone);case"stringLiteral":return this.sqlLiteralString(u.literal);case"numberLiteral":return this.sqlLiteralNumber(u.literal);case"regexpLiteral":return this.sqlLiteralRegexp(u.literal);case"recordLiteral":return this.sqlLiteralRecord(u);case"arrayLiteral":return this.sqlLiteralArray(u)}}sqlSumDistinct(x,u,d){return"sqlSumDistinct called but not implemented"}sqlAggDistinct(x,u,d){return"sqlAggDistinct called but not implemented"}sqlSampleTable(x,u){if(u!==void 0)throw new Error(`Sampling is not supported on dialect ${this.name}.`);return x}sqlOrderBy(x,u){return`ORDER BY ${x.join(",")}`}sqlTzStr(x){return`"${x.queryTimezone}"`}sqlMakeUnnestKey(x,u){return this.concat(x,"'x'",u)}sqlStringAggDistinct(x,u,d){const f="__STRING_AGG_KS__",m="__STRING_AGG_KE__";return`REGEXP_REPLACE(
|
|
2
2
|
STRING_AGG(DISTINCT ${`concat('${f}', ${x}, '${m}', ${u})`}${d.length>0?","+d:""}),
|
|
3
3
|
'${f}.*?${m}',
|
|
4
4
|
''
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{N as t_e}from"./index-BoduKqUa.js";function Nkt(rA,nA){for(var jr=0;jr<nA.length;jr++){const Bt=nA[jr];if(typeof Bt!="string"&&!Array.isArray(Bt)){for(const Xu in Bt)if(Xu!=="default"&&!(Xu in rA)){const Tg=Object.getOwnPropertyDescriptor(Bt,Xu);Tg&&Object.defineProperty(rA,Xu,Tg.get?Tg:{enumerable:!0,get:()=>Bt[Xu]})}}}return Object.freeze(Object.defineProperty(rA,Symbol.toStringTag,{value:"Module"}))}var G_={exports:{}},Lkt=G_.exports,r_e;function Dkt(){return r_e||(r_e=1,(function(rA,nA){(function(jr,Bt){Bt(nA)})(Lkt,function(jr){class Bt{constructor(){this.tagOptionExtractors={}}addExtractor(e,...r){for(const i in r)this.tagOptionExtractors[r[i]]=e}activates(e){return!1}isValidMatch(e){return!0}matches(e){return e.renderer===this.rendererName}parseTagParameters(e){const r={};for(const i in this.tagOptionExtractors){const s=e.tag(i);s&&this.tagOptionExtractors[i](r,s)}return r}}function Xu(t){if(t.isArray())return t.values.map(e=>Xu(e));if(t.isNumber()||t.isBoolean()||t.isString()||t.isNull())return t.value;if(t.isTime())return t.value.toISOString();if(t.isJSON())try{return JSON.parse(t.value)}catch{return t.value}else if(t.isRecord()){const e={};for(const r of t.columns)e[r.field.name]=Xu(r);return e}return null}class Tg{constructor(e){this.document=e}async render(e){const r=this.document.createElement("pre");return r.appendChild(this.document.createTextNode(JSON.stringify(Xu(e),void 0,2))),r}}const _6=class extends Bt{create(e,r,i,s,o){return new Tg(e)}get rendererName(){return"json"}};_6.instance=new _6;let d_e=_6;class f_e{constructor(e,r,i){this.document=e,this.options=r,this.tagged=i}}class iA extends f_e{constructor(){super(...arguments),this.childRenderers={}}get defaultStylesForChildren(){return this.childrenStyleDefaults}static make(e,r,i,s,o){return new e(r,s,o)}}var w=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof t_e<"u"?t_e:typeof self<"u"?self:{};function sA(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function h_e(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function i(){return this instanceof i?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(i){var s=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(r,i,s.get?s:{enumerable:!0,get:function(){return t[i]}})}),r}function p_e(t,e,r,i){var s=-1,o=t==null?0:t.length;for(i&&o&&(r=t[++s]);++s<o;)r=e(r,t[s],s,t);return r}var m_e=p_e;function g_e(t){return function(e){return t?.[e]}}var y_e=g_e,v_e=y_e,x_e={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},b_e=v_e(x_e),E_e=b_e,S_e=typeof w=="object"&&w&&w.Object===Object&&w,T_e=S_e,__e=T_e,A_e=typeof self=="object"&&self&&self.Object===Object&&self,w_e=__e||A_e||Function("return this")(),O_e=w_e,R_e=O_e,C_e=R_e.Symbol,A6=C_e;function N_e(t,e){for(var r=-1,i=t==null?0:t.length,s=Array(i);++r<i;)s[r]=e(t[r],r,t);return s}var L_e=N_e,D_e=Array.isArray,k_e=D_e,TW=A6,_W=Object.prototype,I_e=_W.hasOwnProperty,M_e=_W.toString,ex=TW?TW.toStringTag:void 0;function F_e(t){var e=I_e.call(t,ex),r=t[ex];try{t[ex]=void 0;var i=!0}catch{}var s=M_e.call(t);return i&&(e?t[ex]=r:delete t[ex]),s}var P_e=F_e,$_e=Object.prototype,j_e=$_e.toString;function U_e(t){return j_e.call(t)}var q_e=U_e,AW=A6,B_e=P_e,z_e=q_e,Q_e="[object Null]",H_e="[object Undefined]",wW=AW?AW.toStringTag:void 0;function W_e(t){return t==null?t===void 0?H_e:Q_e:wW&&wW in Object(t)?B_e(t):z_e(t)}var G_e=W_e;function V_e(t){return t!=null&&typeof t=="object"}var Y_e=V_e,K_e=G_e,J_e=Y_e,X_e="[object Symbol]";function Z_e(t){return typeof t=="symbol"||J_e(t)&&K_e(t)==X_e}var eAe=Z_e,OW=A6,tAe=L_e,rAe=k_e,nAe=eAe,RW=OW?OW.prototype:void 0,CW=RW?RW.toString:void 0;function NW(t){if(typeof t=="string")return t;if(rAe(t))return tAe(t,NW)+"";if(nAe(t))return CW?CW.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var iAe=NW,sAe=iAe;function oAe(t){return t==null?"":sAe(t)}var w6=oAe,aAe=E_e,lAe=w6,uAe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,cAe="\\u0300-\\u036f",dAe="\\ufe20-\\ufe2f",fAe="\\u20d0-\\u20ff",hAe=cAe+dAe+fAe,pAe="["+hAe+"]",mAe=RegExp(pAe,"g");function gAe(t){return t=lAe(t),t&&t.replace(uAe,aAe).replace(mAe,"")}var yAe=gAe,vAe=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function xAe(t){return t.match(vAe)||[]}var bAe=xAe,EAe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function SAe(t){return EAe.test(t)}var TAe=SAe,LW="\\ud800-\\udfff",_Ae="\\u0300-\\u036f",AAe="\\ufe20-\\ufe2f",wAe="\\u20d0-\\u20ff",OAe=_Ae+AAe+wAe,DW="\\u2700-\\u27bf",kW="a-z\\xdf-\\xf6\\xf8-\\xff",RAe="\\xac\\xb1\\xd7\\xf7",CAe="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",NAe="\\u2000-\\u206f",LAe=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",IW="A-Z\\xc0-\\xd6\\xd8-\\xde",DAe="\\ufe0e\\ufe0f",MW=RAe+CAe+NAe+LAe,FW="['’]",PW="["+MW+"]",kAe="["+OAe+"]",$W="\\d+",IAe="["+DW+"]",jW="["+kW+"]",UW="[^"+LW+MW+$W+DW+kW+IW+"]",MAe="\\ud83c[\\udffb-\\udfff]",FAe="(?:"+kAe+"|"+MAe+")",PAe="[^"+LW+"]",qW="(?:\\ud83c[\\udde6-\\uddff]){2}",BW="[\\ud800-\\udbff][\\udc00-\\udfff]",_g="["+IW+"]",$Ae="\\u200d",zW="(?:"+jW+"|"+UW+")",jAe="(?:"+_g+"|"+UW+")",QW="(?:"+FW+"(?:d|ll|m|re|s|t|ve))?",HW="(?:"+FW+"(?:D|LL|M|RE|S|T|VE))?",WW=FAe+"?",GW="["+DAe+"]?",UAe="(?:"+$Ae+"(?:"+[PAe,qW,BW].join("|")+")"+GW+WW+")*",qAe="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",BAe="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",zAe=GW+WW+UAe,QAe="(?:"+[IAe,qW,BW].join("|")+")"+zAe,HAe=RegExp([_g+"?"+jW+"+"+QW+"(?="+[PW,_g,"$"].join("|")+")",jAe+"+"+HW+"(?="+[PW,_g+zW,"$"].join("|")+")",_g+"?"+zW+"+"+QW,_g+"+"+HW,BAe,qAe,$W,QAe].join("|"),"g");function WAe(t){return t.match(HAe)||[]}var GAe=WAe,VAe=bAe,YAe=TAe,KAe=w6,JAe=GAe;function XAe(t,e,r){return t=KAe(t),e=r?void 0:e,e===void 0?YAe(t)?JAe(t):VAe(t):t.match(e)||[]}var ZAe=XAe,e3e=m_e,t3e=yAe,r3e=ZAe,n3e="['’]",i3e=RegExp(n3e,"g");function s3e(t){return function(e){return e3e(r3e(t3e(e).replace(i3e,"")),t,"")}}var o3e=s3e;function a3e(t,e,r){var i=-1,s=t.length;e<0&&(e=-e>s?0:s+e),r=r>s?s:r,r<0&&(r+=s),s=e>r?0:r-e>>>0,e>>>=0;for(var o=Array(s);++i<s;)o[i]=t[i+e];return o}var l3e=a3e,u3e=l3e;function c3e(t,e,r){var i=t.length;return r=r===void 0?i:r,!e&&r>=i?t:u3e(t,e,r)}var d3e=c3e,f3e="\\ud800-\\udfff",h3e="\\u0300-\\u036f",p3e="\\ufe20-\\ufe2f",m3e="\\u20d0-\\u20ff",g3e=h3e+p3e+m3e,y3e="\\ufe0e\\ufe0f",v3e="\\u200d",x3e=RegExp("["+v3e+f3e+g3e+y3e+"]");function b3e(t){return x3e.test(t)}var VW=b3e;function E3e(t){return t.split("")}var S3e=E3e,YW="\\ud800-\\udfff",T3e="\\u0300-\\u036f",_3e="\\ufe20-\\ufe2f",A3e="\\u20d0-\\u20ff",w3e=T3e+_3e+A3e,O3e="\\ufe0e\\ufe0f",R3e="["+YW+"]",O6="["+w3e+"]",R6="\\ud83c[\\udffb-\\udfff]",C3e="(?:"+O6+"|"+R6+")",KW="[^"+YW+"]",JW="(?:\\ud83c[\\udde6-\\uddff]){2}",XW="[\\ud800-\\udbff][\\udc00-\\udfff]",N3e="\\u200d",ZW=C3e+"?",eG="["+O3e+"]?",L3e="(?:"+N3e+"(?:"+[KW,JW,XW].join("|")+")"+eG+ZW+")*",D3e=eG+ZW+L3e,k3e="(?:"+[KW+O6+"?",O6,JW,XW,R3e].join("|")+")",I3e=RegExp(R6+"(?="+R6+")|"+k3e+D3e,"g");function M3e(t){return t.match(I3e)||[]}var F3e=M3e,P3e=S3e,$3e=VW,j3e=F3e;function U3e(t){return $3e(t)?j3e(t):P3e(t)}var q3e=U3e,B3e=d3e,z3e=VW,Q3e=q3e,H3e=w6;function W3e(t){return function(e){e=H3e(e);var r=z3e(e)?Q3e(e):void 0,i=r?r[0]:e.charAt(0),s=r?B3e(r,1).join(""):e.slice(1);return i[t]()+s}}var G3e=W3e,V3e=G3e,Y3e=V3e("toUpperCase"),K3e=Y3e,J3e=o3e,X3e=K3e,Z3e=J3e(function(t,e,r){return t+(r?" ":"")+X3e(e)}),ewe=Z3e;const twe=sA(ewe);let Bh=class extends Error{},rwe=class extends Bh{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}},nwe=class extends Bh{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}},iwe=class extends Bh{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}},Ag=class extends Bh{},tG=class extends Bh{constructor(t){super(`Invalid unit ${t}`)}},yi=class extends Bh{},Ld=class extends Bh{constructor(){super("Zone is an abstract class")}};const qe="numeric",ma="short",Xs="long",oA={year:qe,month:qe,day:qe},rG={year:qe,month:ma,day:qe},swe={year:qe,month:ma,day:qe,weekday:ma},nG={year:qe,month:Xs,day:qe},iG={year:qe,month:Xs,day:qe,weekday:Xs},sG={hour:qe,minute:qe},oG={hour:qe,minute:qe,second:qe},aG={hour:qe,minute:qe,second:qe,timeZoneName:ma},lG={hour:qe,minute:qe,second:qe,timeZoneName:Xs},uG={hour:qe,minute:qe,hourCycle:"h23"},cG={hour:qe,minute:qe,second:qe,hourCycle:"h23"},dG={hour:qe,minute:qe,second:qe,hourCycle:"h23",timeZoneName:ma},fG={hour:qe,minute:qe,second:qe,hourCycle:"h23",timeZoneName:Xs},hG={year:qe,month:qe,day:qe,hour:qe,minute:qe},pG={year:qe,month:qe,day:qe,hour:qe,minute:qe,second:qe},mG={year:qe,month:ma,day:qe,hour:qe,minute:qe},gG={year:qe,month:ma,day:qe,hour:qe,minute:qe,second:qe},owe={year:qe,month:ma,day:qe,weekday:ma,hour:qe,minute:qe},yG={year:qe,month:Xs,day:qe,hour:qe,minute:qe,timeZoneName:ma},vG={year:qe,month:Xs,day:qe,hour:qe,minute:qe,second:qe,timeZoneName:ma},xG={year:qe,month:Xs,day:qe,weekday:Xs,hour:qe,minute:qe,timeZoneName:Xs},bG={year:qe,month:Xs,day:qe,weekday:Xs,hour:qe,minute:qe,second:qe,timeZoneName:Xs};let tx=class{get type(){throw new Ld}get name(){throw new Ld}get ianaName(){return this.name}get isUniversal(){throw new Ld}offsetName(t,e){throw new Ld}formatOffset(t,e){throw new Ld}offset(t){throw new Ld}equals(t){throw new Ld}get isValid(){throw new Ld}},C6=null,EG=class n_e extends tx{static get instance(){return C6===null&&(C6=new n_e),C6}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(e,{format:r,locale:i}){return GG(e,r,i)}formatOffset(e,r){return ix(this.offset(e),r)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}};const N6=new Map;function awe(t){let e=N6.get(t);return e===void 0&&(e=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"}),N6.set(t,e)),e}const lwe={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function uwe(t,e){const r=t.format(e).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(r),[,s,o,a,l,u,c,d]=i;return[a,s,o,l,u,c,d]}function cwe(t,e){const r=t.formatToParts(e),i=[];for(let s=0;s<r.length;s++){const{type:o,value:a}=r[s],l=lwe[o];o==="era"?i[l]=a:ot(l)||(i[l]=parseInt(a,10))}return i}const L6=new Map;let wg=class vW extends tx{static create(e){let r=L6.get(e);return r===void 0&&L6.set(e,r=new vW(e)),r}static resetCache(){L6.clear(),N6.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=vW.isValidZone(e)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(e,{format:r,locale:i}){return GG(e,r,i,this.name)}formatOffset(e,r){return ix(this.offset(e),r)}offset(e){if(!this.valid)return NaN;const r=new Date(e);if(isNaN(r))return NaN;const i=awe(this.name);let[s,o,a,l,u,c,d]=i.formatToParts?cwe(i,r):uwe(i,r);l==="BC"&&(s=-Math.abs(s)+1);const f=fA({year:s,month:o,day:a,hour:u===24?0:u,minute:c,second:d,millisecond:0});let h=+r;const m=h%1e3;return h-=m>=0?m:1e3+m,(f-h)/(60*1e3)}equals(e){return e.type==="iana"&&e.name===this.name}get isValid(){return this.valid}},SG={};function dwe(t,e={}){const r=JSON.stringify([t,e]);let i=SG[r];return i||(i=new Intl.ListFormat(t,e),SG[r]=i),i}const D6=new Map;function k6(t,e={}){const r=JSON.stringify([t,e]);let i=D6.get(r);return i===void 0&&(i=new Intl.DateTimeFormat(t,e),D6.set(r,i)),i}const I6=new Map;function fwe(t,e={}){const r=JSON.stringify([t,e]);let i=I6.get(r);return i===void 0&&(i=new Intl.NumberFormat(t,e),I6.set(r,i)),i}const M6=new Map;function hwe(t,e={}){const{base:r,...i}=e,s=JSON.stringify([t,i]);let o=M6.get(s);return o===void 0&&(o=new Intl.RelativeTimeFormat(t,e),M6.set(s,o)),o}let aA=null;function pwe(){return aA||(aA=new Intl.DateTimeFormat().resolvedOptions().locale,aA)}const F6=new Map;function TG(t){let e=F6.get(t);return e===void 0&&(e=new Intl.DateTimeFormat(t).resolvedOptions(),F6.set(t,e)),e}const P6=new Map;function mwe(t){let e=P6.get(t);if(!e){const r=new Intl.Locale(t);e="getWeekInfo"in r?r.getWeekInfo():r.weekInfo,"minimalDays"in e||(e={..._G,...e}),P6.set(t,e)}return e}function gwe(t){const e=t.indexOf("-x-");e!==-1&&(t=t.substring(0,e));const r=t.indexOf("-u-");if(r===-1)return[t];{let i,s;try{i=k6(t).resolvedOptions(),s=t}catch{const l=t.substring(0,r);i=k6(l).resolvedOptions(),s=l}const{numberingSystem:o,calendar:a}=i;return[s,o,a]}}function ywe(t,e,r){return(r||e)&&(t.includes("-u-")||(t+="-u"),r&&(t+=`-ca-${r}`),e&&(t+=`-nu-${e}`)),t}function vwe(t){const e=[];for(let r=1;r<=12;r++){const i=Ur.utc(2009,r,1);e.push(t(i))}return e}function xwe(t){const e=[];for(let r=1;r<=7;r++){const i=Ur.utc(2016,11,13+r);e.push(t(i))}return e}function lA(t,e,r,i){const s=t.listingMode();return s==="error"?null:s==="en"?r(e):i(e)}function bwe(t){return t.numberingSystem&&t.numberingSystem!=="latn"?!1:t.numberingSystem==="latn"||!t.locale||t.locale.startsWith("en")||TG(t.locale).numberingSystem==="latn"}let Ewe=class{constructor(t,e,r){this.padTo=r.padTo||0,this.floor=r.floor||!1;const{padTo:i,floor:s,...o}=r;if(!e||Object.keys(o).length>0){const a={useGrouping:!1,...r};r.padTo>0&&(a.minimumIntegerDigits=r.padTo),this.inf=fwe(t,a)}}format(t){if(this.inf){const e=this.floor?Math.floor(t):t;return this.inf.format(e)}else{const e=this.floor?Math.floor(t):W6(t,3);return yn(e,this.padTo)}}},Swe=class{constructor(t,e,r){this.opts=r,this.originalZone=void 0;let i;if(this.opts.timeZone)this.dt=t;else if(t.zone.type==="fixed"){const o=-1*(t.offset/60),a=o>=0?`Etc/GMT+${o}`:`Etc/GMT${o}`;t.offset!==0&&wg.create(a).valid?(i=a,this.dt=t):(i="UTC",this.dt=t.offset===0?t:t.setZone("UTC").plus({minutes:t.offset}),this.originalZone=t.zone)}else t.zone.type==="system"?this.dt=t:t.zone.type==="iana"?(this.dt=t,i=t.zone.name):(i="UTC",this.dt=t.setZone("UTC").plus({minutes:t.offset}),this.originalZone=t.zone);const s={...this.opts};s.timeZone=s.timeZone||i,this.dtf=k6(e,s)}format(){return this.originalZone?this.formatToParts().map(({value:t})=>t).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const t=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?t.map(e=>{if(e.type==="timeZoneName"){const r=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...e,value:r}}else return e}):t}resolvedOptions(){return this.dtf.resolvedOptions()}},Twe=class{constructor(t,e,r){this.opts={style:"long",...r},!e&&zG()&&(this.rtf=hwe(t,r))}format(t,e){return this.rtf?this.rtf.format(t,e):Hwe(e,t,this.opts.numeric,this.opts.style!=="long")}formatToParts(t,e){return this.rtf?this.rtf.formatToParts(t,e):[]}};const _G={firstDay:1,minimalDays:4,weekend:[6,7]};let Or=class V_{static fromOpts(e){return V_.create(e.locale,e.numberingSystem,e.outputCalendar,e.weekSettings,e.defaultToEN)}static create(e,r,i,s,o=!1){const a=e||Yr.defaultLocale,l=a||(o?"en-US":pwe()),u=r||Yr.defaultNumberingSystem,c=i||Yr.defaultOutputCalendar,d=Q6(s)||Yr.defaultWeekSettings;return new V_(l,u,c,d,a)}static resetCache(){aA=null,D6.clear(),I6.clear(),M6.clear(),F6.clear(),P6.clear()}static fromObject({locale:e,numberingSystem:r,outputCalendar:i,weekSettings:s}={}){return V_.create(e,r,i,s)}constructor(e,r,i,s,o){const[a,l,u]=gwe(e);this.locale=a,this.numberingSystem=r||l||null,this.outputCalendar=i||u||null,this.weekSettings=s,this.intl=ywe(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=o,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=bwe(this)),this.fastNumbersCached}listingMode(){const e=this.isEnglish(),r=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return e&&r?"en":"intl"}clone(e){return!e||Object.getOwnPropertyNames(e).length===0?this:V_.create(e.locale||this.specifiedLocale,e.numberingSystem||this.numberingSystem,e.outputCalendar||this.outputCalendar,Q6(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,r=!1){return lA(this,e,KG,()=>{const i=this.intl==="ja"||this.intl.startsWith("ja-");r&=!i;const s=r?{month:e,day:"numeric"}:{month:e},o=r?"format":"standalone";if(!this.monthsCache[o][e]){const a=i?l=>this.dtFormatter(l,s).format():l=>this.extract(l,s,"month");this.monthsCache[o][e]=vwe(a)}return this.monthsCache[o][e]})}weekdays(e,r=!1){return lA(this,e,ZG,()=>{const i=r?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},s=r?"format":"standalone";return this.weekdaysCache[s][e]||(this.weekdaysCache[s][e]=xwe(o=>this.extract(o,i,"weekday"))),this.weekdaysCache[s][e]})}meridiems(){return lA(this,void 0,()=>eV,()=>{if(!this.meridiemCache){const e={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Ur.utc(2016,11,13,9),Ur.utc(2016,11,13,19)].map(r=>this.extract(r,e,"dayperiod"))}return this.meridiemCache})}eras(e){return lA(this,e,tV,()=>{const r={era:e};return this.eraCache[e]||(this.eraCache[e]=[Ur.utc(-40,1,1),Ur.utc(2017,1,1)].map(i=>this.extract(i,r,"era"))),this.eraCache[e]})}extract(e,r,i){const s=this.dtFormatter(e,r),o=s.formatToParts(),a=o.find(l=>l.type.toLowerCase()===i);return a?a.value:null}numberFormatter(e={}){return new Ewe(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,r={}){return new Swe(e,this.intl,r)}relFormatter(e={}){return new Twe(this.intl,this.isEnglish(),e)}listFormatter(e={}){return dwe(this.intl,e)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||TG(this.intl).locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:QG()?mwe(this.locale):_G}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})`}},$6=null,Cl=class Y_ extends tx{static get utcInstance(){return $6===null&&($6=new Y_(0)),$6}static instance(e){return e===0?Y_.utcInstance:new Y_(e)}static parseSpecifier(e){if(e){const r=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(r)return new Y_(hA(r[1],r[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${ix(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${ix(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,r){return ix(this.fixed,r)}get isUniversal(){return!0}offset(){return this.fixed}equals(e){return e.type==="fixed"&&e.fixed===this.fixed}get isValid(){return!0}},_we=class extends tx{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}};function Dd(t,e){if(ot(t)||t===null)return e;if(t instanceof tx)return t;if(Nwe(t)){const r=t.toLowerCase();return r==="default"?e:r==="local"||r==="system"?EG.instance:r==="utc"||r==="gmt"?Cl.utcInstance:Cl.parseSpecifier(r)||wg.create(t)}else return kd(t)?Cl.instance(t):typeof t=="object"&&"offset"in t&&typeof t.offset=="function"?t:new _we(t)}const j6={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},AG={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]},Awe=j6.hanidec.replace(/[\[|\]]/g,"").split("");function wwe(t){let e=parseInt(t,10);if(isNaN(e)){e="";for(let r=0;r<t.length;r++){const i=t.charCodeAt(r);if(t[r].search(j6.hanidec)!==-1)e+=Awe.indexOf(t[r]);else for(const s in AG){const[o,a]=AG[s];i>=o&&i<=a&&(e+=i-o)}}return parseInt(e,10)}else return e}const U6=new Map;function Owe(){U6.clear()}function ga({numberingSystem:t},e=""){const r=t||"latn";let i=U6.get(r);i===void 0&&(i=new Map,U6.set(r,i));let s=i.get(e);return s===void 0&&(s=new RegExp(`${j6[r]}${e}`),i.set(e,s)),s}let wG=()=>Date.now(),OG="system",RG=null,CG=null,NG=null,LG=60,DG,kG=null,Yr=class{static get now(){return wG}static set now(t){wG=t}static set defaultZone(t){OG=t}static get defaultZone(){return Dd(OG,EG.instance)}static get defaultLocale(){return RG}static set defaultLocale(t){RG=t}static get defaultNumberingSystem(){return CG}static set defaultNumberingSystem(t){CG=t}static get defaultOutputCalendar(){return NG}static set defaultOutputCalendar(t){NG=t}static get defaultWeekSettings(){return kG}static set defaultWeekSettings(t){kG=Q6(t)}static get twoDigitCutoffYear(){return LG}static set twoDigitCutoffYear(t){LG=t%100}static get throwOnInvalid(){return DG}static set throwOnInvalid(t){DG=t}static resetCaches(){Or.resetCache(),wg.resetCache(),Ur.resetCache(),Owe()}},ya=class{constructor(t,e){this.reason=t,this.explanation=e}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}};const IG=[0,31,59,90,120,151,181,212,243,273,304,334],MG=[0,31,60,91,121,152,182,213,244,274,305,335];function wo(t,e){return new ya("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${t}, which is invalid`)}function q6(t,e,r){const i=new Date(Date.UTC(t,e-1,r));t<100&&t>=0&&i.setUTCFullYear(i.getUTCFullYear()-1900);const s=i.getUTCDay();return s===0?7:s}function FG(t,e,r){return r+(rx(t)?MG:IG)[e-1]}function PG(t,e){const r=rx(t)?MG:IG,i=r.findIndex(o=>o<e),s=e-r[i];return{month:i+1,day:s}}function B6(t,e){return(t-e+7)%7+1}function uA(t,e=4,r=1){const{year:i,month:s,day:o}=t,a=FG(i,s,o),l=B6(q6(i,s,o),r);let u=Math.floor((a-l+14-e)/7),c;return u<1?(c=i-1,u=nx(c,e,r)):u>nx(i,e,r)?(c=i+1,u=1):c=i,{weekYear:c,weekNumber:u,weekday:l,...mA(t)}}function $G(t,e=4,r=1){const{weekYear:i,weekNumber:s,weekday:o}=t,a=B6(q6(i,1,e),r),l=Rg(i);let u=s*7+o-a-7+e,c;u<1?(c=i-1,u+=Rg(c)):u>l?(c=i+1,u-=Rg(i)):c=i;const{month:d,day:f}=PG(c,u);return{year:c,month:d,day:f,...mA(t)}}function z6(t){const{year:e,month:r,day:i}=t,s=FG(e,r,i);return{year:e,ordinal:s,...mA(t)}}function jG(t){const{year:e,ordinal:r}=t,{month:i,day:s}=PG(e,r);return{year:e,month:i,day:s,...mA(t)}}function UG(t,e){if(!ot(t.localWeekday)||!ot(t.localWeekNumber)||!ot(t.localWeekYear)){if(!ot(t.weekday)||!ot(t.weekNumber)||!ot(t.weekYear))throw new Ag("Cannot mix locale-based week fields with ISO-based week fields");return ot(t.localWeekday)||(t.weekday=t.localWeekday),ot(t.localWeekNumber)||(t.weekNumber=t.localWeekNumber),ot(t.localWeekYear)||(t.weekYear=t.localWeekYear),delete t.localWeekday,delete t.localWeekNumber,delete t.localWeekYear,{minDaysInFirstWeek:e.getMinDaysInFirstWeek(),startOfWeek:e.getStartOfWeek()}}else return{minDaysInFirstWeek:4,startOfWeek:1}}function Rwe(t,e=4,r=1){const i=cA(t.weekYear),s=Oo(t.weekNumber,1,nx(t.weekYear,e,r)),o=Oo(t.weekday,1,7);return i?s?o?!1:wo("weekday",t.weekday):wo("week",t.weekNumber):wo("weekYear",t.weekYear)}function Cwe(t){const e=cA(t.year),r=Oo(t.ordinal,1,Rg(t.year));return e?r?!1:wo("ordinal",t.ordinal):wo("year",t.year)}function qG(t){const e=cA(t.year),r=Oo(t.month,1,12),i=Oo(t.day,1,dA(t.year,t.month));return e?r?i?!1:wo("day",t.day):wo("month",t.month):wo("year",t.year)}function BG(t){const{hour:e,minute:r,second:i,millisecond:s}=t,o=Oo(e,0,23)||e===24&&r===0&&i===0&&s===0,a=Oo(r,0,59),l=Oo(i,0,59),u=Oo(s,0,999);return o?a?l?u?!1:wo("millisecond",s):wo("second",i):wo("minute",r):wo("hour",e)}function ot(t){return typeof t>"u"}function kd(t){return typeof t=="number"}function cA(t){return typeof t=="number"&&t%1===0}function Nwe(t){return typeof t=="string"}function Lwe(t){return Object.prototype.toString.call(t)==="[object Date]"}function zG(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function QG(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function Dwe(t){return Array.isArray(t)?t:[t]}function HG(t,e,r){if(t.length!==0)return t.reduce((i,s)=>{const o=[e(s),s];return i&&r(i[0],o[0])===i[0]?i:o},null)[1]}function kwe(t,e){return e.reduce((r,i)=>(r[i]=t[i],r),{})}function Og(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Q6(t){if(t==null)return null;if(typeof t!="object")throw new yi("Week settings must be an object");if(!Oo(t.firstDay,1,7)||!Oo(t.minimalDays,1,7)||!Array.isArray(t.weekend)||t.weekend.some(e=>!Oo(e,1,7)))throw new yi("Invalid week settings");return{firstDay:t.firstDay,minimalDays:t.minimalDays,weekend:Array.from(t.weekend)}}function Oo(t,e,r){return cA(t)&&t>=e&&t<=r}function Iwe(t,e){return t-e*Math.floor(t/e)}function yn(t,e=2){const r=t<0;let i;return r?i="-"+(""+-t).padStart(e,"0"):i=(""+t).padStart(e,"0"),i}function Id(t){if(!(ot(t)||t===null||t===""))return parseInt(t,10)}function zh(t){if(!(ot(t)||t===null||t===""))return parseFloat(t)}function H6(t){if(!(ot(t)||t===null||t==="")){const e=parseFloat("0."+t)*1e3;return Math.floor(e)}}function W6(t,e,r="round"){const i=10**e;switch(r){case"expand":return t>0?Math.ceil(t*i)/i:Math.floor(t*i)/i;case"trunc":return Math.trunc(t*i)/i;case"round":return Math.round(t*i)/i;case"floor":return Math.floor(t*i)/i;case"ceil":return Math.ceil(t*i)/i;default:throw new RangeError(`Value rounding ${r} is out of range`)}}function rx(t){return t%4===0&&(t%100!==0||t%400===0)}function Rg(t){return rx(t)?366:365}function dA(t,e){const r=Iwe(e-1,12)+1,i=t+(e-r)/12;return r===2?rx(i)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function fA(t){let e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(t.year,t.month-1,t.day)),+e}function WG(t,e,r){return-B6(q6(t,1,e),r)+e-1}function nx(t,e=4,r=1){const i=WG(t,e,r),s=WG(t+1,e,r);return(Rg(t)-i+s)/7}function G6(t){return t>99?t:t>Yr.twoDigitCutoffYear?1900+t:2e3+t}function GG(t,e,r,i=null){const s=new Date(t),o={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};i&&(o.timeZone=i);const a={timeZoneName:e,...o},l=new Intl.DateTimeFormat(r,a).formatToParts(s).find(u=>u.type.toLowerCase()==="timezonename");return l?l.value:null}function hA(t,e){let r=parseInt(t,10);Number.isNaN(r)&&(r=0);const i=parseInt(e,10)||0,s=r<0||Object.is(r,-0)?-i:i;return r*60+s}function VG(t){const e=Number(t);if(typeof t=="boolean"||t===""||!Number.isFinite(e))throw new yi(`Invalid unit value ${t}`);return e}function pA(t,e){const r={};for(const i in t)if(Og(t,i)){const s=t[i];if(s==null)continue;r[e(i)]=VG(s)}return r}function ix(t,e){const r=Math.trunc(Math.abs(t/60)),i=Math.trunc(Math.abs(t%60)),s=t>=0?"+":"-";switch(e){case"short":return`${s}${yn(r,2)}:${yn(i,2)}`;case"narrow":return`${s}${r}${i>0?`:${i}`:""}`;case"techie":return`${s}${yn(r,2)}${yn(i,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function mA(t){return kwe(t,["hour","minute","second","millisecond"])}const Mwe=["January","February","March","April","May","June","July","August","September","October","November","December"],YG=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Fwe=["J","F","M","A","M","J","J","A","S","O","N","D"];function KG(t){switch(t){case"narrow":return[...Fwe];case"short":return[...YG];case"long":return[...Mwe];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 JG=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],XG=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Pwe=["M","T","W","T","F","S","S"];function ZG(t){switch(t){case"narrow":return[...Pwe];case"short":return[...XG];case"long":return[...JG];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const eV=["AM","PM"],$we=["Before Christ","Anno Domini"],jwe=["BC","AD"],Uwe=["B","A"];function tV(t){switch(t){case"narrow":return[...Uwe];case"short":return[...jwe];case"long":return[...$we];default:return null}}function qwe(t){return eV[t.hour<12?0:1]}function Bwe(t,e){return ZG(e)[t.weekday-1]}function zwe(t,e){return KG(e)[t.month-1]}function Qwe(t,e){return tV(e)[t.year<0?0:1]}function Hwe(t,e,r="always",i=!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."]},o=["hours","minutes","seconds"].indexOf(t)===-1;if(r==="auto"&&o){const f=t==="days";switch(e){case 1:return f?"tomorrow":`next ${s[t][0]}`;case-1:return f?"yesterday":`last ${s[t][0]}`;case 0:return f?"today":`this ${s[t][0]}`}}const a=Object.is(e,-0)||e<0,l=Math.abs(e),u=l===1,c=s[t],d=i?u?c[1]:c[2]||c[1]:u?s[t][0]:t;return a?`${l} ${d} ago`:`in ${l} ${d}`}function rV(t,e){let r="";for(const i of t)i.literal?r+=i.val:r+=e(i.val);return r}const Wwe={D:oA,DD:rG,DDD:nG,DDDD:iG,t:sG,tt:oG,ttt:aG,tttt:lG,T:uG,TT:cG,TTT:dG,TTTT:fG,f:hG,ff:mG,fff:yG,ffff:xG,F:pG,FF:gG,FFF:vG,FFFF:bG};let va=class K_{static create(e,r={}){return new K_(e,r)}static parseFormat(e){let r=null,i="",s=!1;const o=[];for(let a=0;a<e.length;a++){const l=e.charAt(a);l==="'"?((i.length>0||s)&&o.push({literal:s||/^\s+$/.test(i),val:i===""?"'":i}),r=null,i="",s=!s):s||l===r?i+=l:(i.length>0&&o.push({literal:/^\s+$/.test(i),val:i}),i=l,r=l)}return i.length>0&&o.push({literal:s||/^\s+$/.test(i),val:i}),o}static macroTokenToFormatOpts(e){return Wwe[e]}constructor(e,r){this.opts=r,this.loc=e,this.systemLoc=null}formatWithSystemDefault(e,r){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(e,{...this.opts,...r}).format()}dtFormatter(e,r={}){return this.loc.dtFormatter(e,{...this.opts,...r})}formatDateTime(e,r){return this.dtFormatter(e,r).format()}formatDateTimeParts(e,r){return this.dtFormatter(e,r).formatToParts()}formatInterval(e,r){return this.dtFormatter(e.start,r).dtf.formatRange(e.start.toJSDate(),e.end.toJSDate())}resolvedOptions(e,r){return this.dtFormatter(e,r).resolvedOptions()}num(e,r=0,i=void 0){if(this.opts.forceSimple)return yn(e,r);const s={...this.opts};return r>0&&(s.padTo=r),i&&(s.signDisplay=i),this.loc.numberFormatter(s).format(e)}formatDateTimeFromString(e,r){const i=this.loc.listingMode()==="en",s=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",o=(m,g)=>this.loc.extract(e,m,g),a=m=>e.isOffsetFixed&&e.offset===0&&m.allowZ?"Z":e.isValid?e.zone.formatOffset(e.ts,m.format):"",l=()=>i?qwe(e):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),u=(m,g)=>i?zwe(e,m):o(g?{month:m}:{month:m,day:"numeric"},"month"),c=(m,g)=>i?Bwe(e,m):o(g?{weekday:m}:{weekday:m,month:"long",day:"numeric"},"weekday"),d=m=>{const g=K_.macroTokenToFormatOpts(m);return g?this.formatWithSystemDefault(e,g):m},f=m=>i?Qwe(e,m):o({era:m},"era"),h=m=>{switch(m){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 l();case"d":return s?o({day:"numeric"},"day"):this.num(e.day);case"dd":return s?o({day:"2-digit"},"day"):this.num(e.day,2);case"c":return this.num(e.weekday);case"ccc":return c("short",!0);case"cccc":return c("long",!0);case"ccccc":return c("narrow",!0);case"E":return this.num(e.weekday);case"EEE":return c("short",!1);case"EEEE":return c("long",!1);case"EEEEE":return c("narrow",!1);case"L":return s?o({month:"numeric",day:"numeric"},"month"):this.num(e.month);case"LL":return s?o({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?o({month:"numeric"},"month"):this.num(e.month);case"MM":return s?o({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?o({year:"numeric"},"year"):this.num(e.year);case"yy":return s?o({year:"2-digit"},"year"):this.num(e.year.toString().slice(-2),2);case"yyyy":return s?o({year:"numeric"},"year"):this.num(e.year,4);case"yyyyyy":return s?o({year:"numeric"},"year"):this.num(e.year,6);case"G":return f("short");case"GG":return f("long");case"GGGGG":return f("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 d(m)}};return rV(K_.parseFormat(r),h)}formatDurationFromString(e,r){const i=this.opts.signMode==="negativeLargestOnly"?-1:1,s=d=>{switch(d[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}},o=(d,f)=>h=>{const m=s(h);if(m){const g=f.isNegativeDuration&&m!==f.largestUnit?i:1;let y;return this.opts.signMode==="negativeLargestOnly"&&m!==f.largestUnit?y="never":this.opts.signMode==="all"?y="always":y="auto",this.num(d.get(m)*g,h.length,y)}else return h},a=K_.parseFormat(r),l=a.reduce((d,{literal:f,val:h})=>f?d:d.concat(h),[]),u=e.shiftTo(...l.map(s).filter(d=>d)),c={isNegativeDuration:u<0,largestUnit:Object.keys(u.values)[0]};return rV(a,o(u,c))}};const nV=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Cg(...t){const e=t.reduce((r,i)=>r+i.source,"");return RegExp(`^${e}$`)}function Ng(...t){return e=>t.reduce(([r,i,s],o)=>{const[a,l,u]=o(e,s);return[{...r,...a},l||i,u]},[{},null,1]).slice(0,2)}function Lg(t,...e){if(t==null)return[null,null];for(const[r,i]of e){const s=r.exec(t);if(s)return i(s)}return[null,null]}function iV(...t){return(e,r)=>{const i={};let s;for(s=0;s<t.length;s++)i[t[s]]=Id(e[r+s]);return[i,null,r+s]}}const sV=/(?:([Zz])|([+-]\d\d)(?::?(\d\d))?)/,Gwe=`(?:${sV.source}?(?:\\[(${nV.source})\\])?)?`,V6=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,oV=RegExp(`${V6.source}${Gwe}`),Y6=RegExp(`(?:[Tt]${oV.source})?`),Vwe=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ywe=/(\d{4})-?W(\d\d)(?:-?(\d))?/,Kwe=/(\d{4})-?(\d{3})/,Jwe=iV("weekYear","weekNumber","weekDay"),Xwe=iV("year","ordinal"),Zwe=/(\d{4})-(\d\d)-(\d\d)/,aV=RegExp(`${V6.source} ?(?:${sV.source}|(${nV.source}))?`),eOe=RegExp(`(?: ${aV.source})?`);function Dg(t,e,r){const i=t[e];return ot(i)?r:Id(i)}function tOe(t,e){return[{year:Dg(t,e),month:Dg(t,e+1,1),day:Dg(t,e+2,1)},null,e+3]}function kg(t,e){return[{hours:Dg(t,e,0),minutes:Dg(t,e+1,0),seconds:Dg(t,e+2,0),milliseconds:H6(t[e+3])},null,e+4]}function sx(t,e){const r=!t[e]&&!t[e+1],i=hA(t[e+1],t[e+2]),s=r?null:Cl.instance(i);return[{},s,e+3]}function ox(t,e){const r=t[e]?wg.create(t[e]):null;return[{},r,e+1]}const rOe=RegExp(`^T?${V6.source}$`),nOe=/^-?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 iOe(t){const[e,r,i,s,o,a,l,u,c]=t,d=e[0]==="-",f=u&&u[0]==="-",h=(m,g=!1)=>m!==void 0&&(g||m&&d)?-m:m;return[{years:h(zh(r)),months:h(zh(i)),weeks:h(zh(s)),days:h(zh(o)),hours:h(zh(a)),minutes:h(zh(l)),seconds:h(zh(u),u==="-0"),milliseconds:h(H6(c),f)}]}const sOe={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function K6(t,e,r,i,s,o,a){const l={year:e.length===2?G6(Id(e)):Id(e),month:YG.indexOf(r)+1,day:Id(i),hour:Id(s),minute:Id(o)};return a&&(l.second=Id(a)),t&&(l.weekday=t.length>3?JG.indexOf(t)+1:XG.indexOf(t)+1),l}const oOe=/^(?:(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 aOe(t){const[,e,r,i,s,o,a,l,u,c,d,f]=t,h=K6(e,s,i,r,o,a,l);let m;return u?m=sOe[u]:c?m=0:m=hA(d,f),[h,new Cl(m)]}function lOe(t){return t.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const uOe=/^(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$/,cOe=/^(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$/,dOe=/^(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 lV(t){const[,e,r,i,s,o,a,l]=t;return[K6(e,s,i,r,o,a,l),Cl.utcInstance]}function fOe(t){const[,e,r,i,s,o,a,l]=t;return[K6(e,l,r,i,s,o,a),Cl.utcInstance]}const hOe=Cg(Vwe,Y6),pOe=Cg(Ywe,Y6),mOe=Cg(Kwe,Y6),gOe=Cg(oV),uV=Ng(tOe,kg,sx,ox),yOe=Ng(Jwe,kg,sx,ox),vOe=Ng(Xwe,kg,sx,ox),xOe=Ng(kg,sx,ox);function bOe(t){return Lg(t,[hOe,uV],[pOe,yOe],[mOe,vOe],[gOe,xOe])}function EOe(t){return Lg(lOe(t),[oOe,aOe])}function SOe(t){return Lg(t,[uOe,lV],[cOe,lV],[dOe,fOe])}function TOe(t){return Lg(t,[nOe,iOe])}const _Oe=Ng(kg);function AOe(t){return Lg(t,[rOe,_Oe])}const wOe=Cg(Zwe,eOe),OOe=Cg(aV),ROe=Ng(kg,sx,ox);function COe(t){return Lg(t,[wOe,uV],[OOe,ROe])}const cV="Invalid Duration",dV={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}},NOe={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},...dV},Ro=146097/400,Ig=146097/4800,LOe={years:{quarters:4,months:12,weeks:Ro/7,days:Ro,hours:Ro*24,minutes:Ro*24*60,seconds:Ro*24*60*60,milliseconds:Ro*24*60*60*1e3},quarters:{months:3,weeks:Ro/28,days:Ro/4,hours:Ro*24/4,minutes:Ro*24*60/4,seconds:Ro*24*60*60/4,milliseconds:Ro*24*60*60*1e3/4},months:{weeks:Ig/7,days:Ig,hours:Ig*24,minutes:Ig*24*60,seconds:Ig*24*60*60,milliseconds:Ig*24*60*60*1e3},...dV},Qh=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],DOe=Qh.slice(0).reverse();function Zu(t,e,r=!1){const i={values:r?e.values:{...t.values,...e.values||{}},loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy,matrix:e.matrix||t.matrix};return new vi(i)}function fV(t,e){let r=e.milliseconds??0;for(const i of DOe.slice(1))e[i]&&(r+=e[i]*t[i].milliseconds);return r}function hV(t,e){const r=fV(t,e)<0?-1:1;Qh.reduceRight((i,s)=>{if(ot(e[s]))return i;if(i){const o=e[i]*r,a=t[s][i],l=Math.floor(o/a);e[s]+=l*r,e[i]-=l*a*r}return s},null),Qh.reduce((i,s)=>{if(ot(e[s]))return i;if(i){const o=e[i]%1;e[i]-=o,e[s]+=o*t[i][s]}return s},null)}function pV(t){const e={};for(const[r,i]of Object.entries(t))i!==0&&(e[r]=i);return e}let vi=class gi{constructor(e){const r=e.conversionAccuracy==="longterm"||!1;let i=r?LOe:NOe;e.matrix&&(i=e.matrix),this.values=e.values,this.loc=e.loc||Or.create(),this.conversionAccuracy=r?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=i,this.isLuxonDuration=!0}static fromMillis(e,r){return gi.fromObject({milliseconds:e},r)}static fromObject(e,r={}){if(e==null||typeof e!="object")throw new yi(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new gi({values:pA(e,gi.normalizeUnit),loc:Or.fromObject(r),conversionAccuracy:r.conversionAccuracy,matrix:r.matrix})}static fromDurationLike(e){if(kd(e))return gi.fromMillis(e);if(gi.isDuration(e))return e;if(typeof e=="object")return gi.fromObject(e);throw new yi(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,r){const[i]=TOe(e);return i?gi.fromObject(i,r):gi.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static fromISOTime(e,r){const[i]=AOe(e);return i?gi.fromObject(i,r):gi.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the Duration is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new iwe(i);return new gi({invalid:i})}static normalizeUnit(e){const r={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(!r)throw new tG(e);return r}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,r={}){const i={...r,floor:r.round!==!1&&r.floor!==!1};return this.isValid?va.create(this.loc,i).formatDurationFromString(this,e):cV}toHuman(e={}){if(!this.isValid)return cV;const r=e.showZeros!==!1,i=Qh.map(s=>{const o=this.values[s];return ot(o)||o===0&&!r?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...e,unit:s.slice(0,-1)}).format(o)}).filter(s=>s);return this.loc.listFormatter({type:"conjunction",style:e.listStyle||"narrow",...e}).format(i)}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+=W6(this.seconds+this.milliseconds/1e3,3)+"S"),e==="P"&&(e+="T0S"),e}toISOTime(e={}){if(!this.isValid)return null;const r=this.toMillis();return r<0||r>=864e5?null:(e={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...e,includeOffset:!1},Ur.fromMillis(r,{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?fV(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(e){if(!this.isValid)return this;const r=gi.fromDurationLike(e),i={};for(const s of Qh)(Og(r.values,s)||Og(this.values,s))&&(i[s]=r.get(s)+this.get(s));return Zu(this,{values:i},!0)}minus(e){if(!this.isValid)return this;const r=gi.fromDurationLike(e);return this.plus(r.negate())}mapUnits(e){if(!this.isValid)return this;const r={};for(const i of Object.keys(this.values))r[i]=VG(e(this.values[i],i));return Zu(this,{values:r},!0)}get(e){return this[gi.normalizeUnit(e)]}set(e){if(!this.isValid)return this;const r={...this.values,...pA(e,gi.normalizeUnit)};return Zu(this,{values:r})}reconfigure({locale:e,numberingSystem:r,conversionAccuracy:i,matrix:s}={}){const o={loc:this.loc.clone({locale:e,numberingSystem:r}),matrix:s,conversionAccuracy:i};return Zu(this,o)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;const e=this.toObject();return hV(this.matrix,e),Zu(this,{values:e},!0)}rescale(){if(!this.isValid)return this;const e=pV(this.normalize().shiftToAll().toObject());return Zu(this,{values:e},!0)}shiftTo(...e){if(!this.isValid)return this;if(e.length===0)return this;e=e.map(a=>gi.normalizeUnit(a));const r={},i={},s=this.toObject();let o;for(const a of Qh)if(e.indexOf(a)>=0){o=a;let l=0;for(const c in i)l+=this.matrix[c][a]*i[c],i[c]=0;kd(s[a])&&(l+=s[a]);const u=Math.trunc(l);r[a]=u,i[a]=(l*1e3-u*1e3)/1e3}else kd(s[a])&&(i[a]=s[a]);for(const a in i)i[a]!==0&&(r[o]+=a===o?i[a]:i[a]/this.matrix[o][a]);return hV(this.matrix,r),Zu(this,{values:r},!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 r of Object.keys(this.values))e[r]=this.values[r]===0?0:-this.values[r];return Zu(this,{values:e},!0)}removeZeros(){if(!this.isValid)return this;const e=pV(this.values);return Zu(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 r(i,s){return i===void 0||i===0?s===void 0||s===0:i===s}for(const i of Qh)if(!r(this.values[i],e.values[i]))return!1;return!0}};const Mg="Invalid Interval";function kOe(t,e){return!t||!t.isValid?gA.invalid("missing or invalid start"):!e||!e.isValid?gA.invalid("missing or invalid end"):e<t?gA.invalid("end before start",`The end of an interval must be after its start, but you had start=${t.toISO()} and end=${e.toISO()}`):null}let gA=class ti{constructor(e){this.s=e.start,this.e=e.end,this.invalid=e.invalid||null,this.isLuxonInterval=!0}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the Interval is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new nwe(i);return new ti({invalid:i})}static fromDateTimes(e,r){const i=ux(e),s=ux(r);return kOe(i,s)??new ti({start:i,end:s})}static after(e,r){const i=vi.fromDurationLike(r),s=ux(e);return ti.fromDateTimes(s,s.plus(i))}static before(e,r){const i=vi.fromDurationLike(r),s=ux(e);return ti.fromDateTimes(s.minus(i),s)}static fromISO(e,r){const[i,s]=(e||"").split("/",2);if(i&&s){let o,a;try{o=Ur.fromISO(i,r),a=o.isValid}catch{a=!1}let l,u;try{l=Ur.fromISO(s,r),u=l.isValid}catch{u=!1}if(a&&u)return ti.fromDateTimes(o,l);if(a){const c=vi.fromISO(s,r);if(c.isValid)return ti.after(o,c)}else if(u){const c=vi.fromISO(i,r);if(c.isValid)return ti.before(l,c)}}return ti.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",r){if(!this.isValid)return NaN;const i=this.start.startOf(e,r);let s;return r!=null&&r.useLocaleWeeks?s=this.end.reconfigure({locale:i.locale}):s=this.end,s=s.startOf(e,r),Math.floor(s.diff(i,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:r}={}){return this.isValid?ti.fromDateTimes(e||this.s,r||this.e):this}splitAt(...e){if(!this.isValid)return[];const r=e.map(ux).filter(a=>this.contains(a)).sort((a,l)=>a.toMillis()-l.toMillis()),i=[];let{s}=this,o=0;for(;s<this.e;){const a=r[o]||this.e,l=+a>+this.e?this.e:a;i.push(ti.fromDateTimes(s,l)),s=l,o+=1}return i}splitBy(e){const r=vi.fromDurationLike(e);if(!this.isValid||!r.isValid||r.as("milliseconds")===0)return[];let{s:i}=this,s=1,o;const a=[];for(;i<this.e;){const l=this.start.plus(r.mapUnits(u=>u*s));o=+l>+this.e?this.e:l,a.push(ti.fromDateTimes(i,o)),i=o,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 r=this.s>e.s?this.s:e.s,i=this.e<e.e?this.e:e.e;return r>=i?null:ti.fromDateTimes(r,i)}union(e){if(!this.isValid)return this;const r=this.s<e.s?this.s:e.s,i=this.e>e.e?this.e:e.e;return ti.fromDateTimes(r,i)}static merge(e){const[r,i]=e.sort((s,o)=>s.s-o.s).reduce(([s,o],a)=>o?o.overlaps(a)||o.abutsStart(a)?[s,o.union(a)]:[s.concat([o]),a]:[s,a],[[],null]);return i&&r.push(i),r}static xor(e){let r=null,i=0;const s=[],o=e.map(u=>[{time:u.s,type:"s"},{time:u.e,type:"e"}]),a=Array.prototype.concat(...o),l=a.sort((u,c)=>u.time-c.time);for(const u of l)i+=u.type==="s"?1:-1,i===1?r=u.time:(r&&+r!=+u.time&&s.push(ti.fromDateTimes(r,u.time)),r=null);return ti.merge(s)}difference(...e){return ti.xor([this].concat(e)).map(r=>this.intersection(r)).filter(r=>r&&!r.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:Mg}[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=oA,r={}){return this.isValid?va.create(this.s.loc.clone(r),e).formatInterval(this):Mg}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:Mg}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:Mg}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:Mg}toFormat(e,{separator:r=" – "}={}){return this.isValid?`${this.s.toFormat(e)}${r}${this.e.toFormat(e)}`:Mg}toDuration(e,r){return this.isValid?this.e.diff(this.s,e,r):vi.invalid(this.invalidReason)}mapEndpoints(e){return ti.fromDateTimes(e(this.s),e(this.e))}},yA=class{static hasDST(t=Yr.defaultZone){const e=Ur.now().setZone(t).set({month:12});return!t.isUniversal&&e.offset!==e.set({month:6}).offset}static isValidIANAZone(t){return wg.isValidZone(t)}static normalizeZone(t){return Dd(t,Yr.defaultZone)}static getStartOfWeek({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getWeekendDays().slice()}static months(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null,outputCalendar:s="gregory"}={}){return(i||Or.create(e,r,s)).months(t)}static monthsFormat(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null,outputCalendar:s="gregory"}={}){return(i||Or.create(e,r,s)).months(t,!0)}static weekdays(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null}={}){return(i||Or.create(e,r,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null}={}){return(i||Or.create(e,r,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Or.create(t).meridiems()}static eras(t="short",{locale:e=null}={}){return Or.create(e,null,"gregory").eras(t)}static features(){return{relative:zG(),localeWeek:QG()}}};function mV(t,e){const r=s=>s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),i=r(e)-r(t);return Math.floor(vi.fromMillis(i).as("days"))}function IOe(t,e,r){const i=[["years",(u,c)=>c.year-u.year],["quarters",(u,c)=>c.quarter-u.quarter+(c.year-u.year)*4],["months",(u,c)=>c.month-u.month+(c.year-u.year)*12],["weeks",(u,c)=>{const d=mV(u,c);return(d-d%7)/7}],["days",mV]],s={},o=t;let a,l;for(const[u,c]of i)r.indexOf(u)>=0&&(a=u,s[u]=c(t,e),l=o.plus(s),l>e?(s[u]--,t=o.plus(s),t>e&&(l=t,s[u]--,t=o.plus(s))):t=l);return[t,s,l,a]}function MOe(t,e,r,i){let[s,o,a,l]=IOe(t,e,r);const u=e-s,c=r.filter(f=>["hours","minutes","seconds","milliseconds"].indexOf(f)>=0);c.length===0&&(a<e&&(a=s.plus({[l]:1})),a!==s&&(o[l]=(o[l]||0)+u/(a-s)));const d=vi.fromObject(o,i);return c.length>0?vi.fromMillis(u,i).shiftTo(...c).plus(d):d}const FOe="missing Intl.DateTimeFormat.formatToParts support";function Yt(t,e=r=>r){return{regex:t,deser:([r])=>e(wwe(r))}}const gV="[ ]",yV=new RegExp(gV,"g");function POe(t){return t.replace(/\./g,"\\.?").replace(yV,gV)}function vV(t){return t.replace(/\./g,"").replace(yV," ").toLowerCase()}function xa(t,e){return t===null?null:{regex:RegExp(t.map(POe).join("|")),deser:([r])=>t.findIndex(i=>vV(r)===vV(i))+e}}function xV(t,e){return{regex:t,deser:([,r,i])=>hA(r,i),groups:e}}function vA(t){return{regex:t,deser:([e])=>e}}function $Oe(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function jOe(t,e){const r=ga(e),i=ga(e,"{2}"),s=ga(e,"{3}"),o=ga(e,"{4}"),a=ga(e,"{6}"),l=ga(e,"{1,2}"),u=ga(e,"{1,3}"),c=ga(e,"{1,6}"),d=ga(e,"{1,9}"),f=ga(e,"{2,4}"),h=ga(e,"{4,6}"),m=y=>({regex:RegExp($Oe(y.val)),deser:([v])=>v,literal:!0}),g=(y=>{if(t.literal)return m(y);switch(y.val){case"G":return xa(e.eras("short"),0);case"GG":return xa(e.eras("long"),0);case"y":return Yt(c);case"yy":return Yt(f,G6);case"yyyy":return Yt(o);case"yyyyy":return Yt(h);case"yyyyyy":return Yt(a);case"M":return Yt(l);case"MM":return Yt(i);case"MMM":return xa(e.months("short",!0),1);case"MMMM":return xa(e.months("long",!0),1);case"L":return Yt(l);case"LL":return Yt(i);case"LLL":return xa(e.months("short",!1),1);case"LLLL":return xa(e.months("long",!1),1);case"d":return Yt(l);case"dd":return Yt(i);case"o":return Yt(u);case"ooo":return Yt(s);case"HH":return Yt(i);case"H":return Yt(l);case"hh":return Yt(i);case"h":return Yt(l);case"mm":return Yt(i);case"m":return Yt(l);case"q":return Yt(l);case"qq":return Yt(i);case"s":return Yt(l);case"ss":return Yt(i);case"S":return Yt(u);case"SSS":return Yt(s);case"u":return vA(d);case"uu":return vA(l);case"uuu":return Yt(r);case"a":return xa(e.meridiems(),0);case"kkkk":return Yt(o);case"kk":return Yt(f,G6);case"W":return Yt(l);case"WW":return Yt(i);case"E":case"c":return Yt(r);case"EEE":return xa(e.weekdays("short",!1),1);case"EEEE":return xa(e.weekdays("long",!1),1);case"ccc":return xa(e.weekdays("short",!0),1);case"cccc":return xa(e.weekdays("long",!0),1);case"Z":case"ZZ":return xV(new RegExp(`([+-]${l.source})(?::(${i.source}))?`),2);case"ZZZ":return xV(new RegExp(`([+-]${l.source})(${i.source})?`),2);case"z":return vA(/[a-z_+-/]{1,256}?/i);case" ":return vA(/[^\S\n\r]/);default:return m(y)}})(t)||{invalidReason:FOe};return g.token=t,g}const UOe={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 qOe(t,e,r){const{type:i,value:s}=t;if(i==="literal"){const u=/^\s+$/.test(s);return{literal:!u,val:u?" ":s}}const o=e[i];let a=i;i==="hour"&&(e.hour12!=null?a=e.hour12?"hour12":"hour24":e.hourCycle!=null?e.hourCycle==="h11"||e.hourCycle==="h12"?a="hour12":a="hour24":a=r.hour12?"hour12":"hour24");let l=UOe[a];if(typeof l=="object"&&(l=l[o]),l)return{literal:!1,val:l}}function BOe(t){return[`^${t.map(e=>e.regex).reduce((e,r)=>`${e}(${r.source})`,"")}$`,t]}function zOe(t,e,r){const i=t.match(e);if(i){const s={};let o=1;for(const a in r)if(Og(r,a)){const l=r[a],u=l.groups?l.groups+1:1;!l.literal&&l.token&&(s[l.token.val[0]]=l.deser(i.slice(o,o+u))),o+=u}return[i,s]}else return[i,{}]}function QOe(t){const e=s=>{switch(s){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 r=null,i;return ot(t.z)||(r=wg.create(t.z)),ot(t.Z)||(r||(r=new Cl(t.Z)),i=t.Z),ot(t.q)||(t.M=(t.q-1)*3+1),ot(t.h)||(t.h<12&&t.a===1?t.h+=12:t.h===12&&t.a===0&&(t.h=0)),t.G===0&&t.y&&(t.y=-t.y),ot(t.u)||(t.S=H6(t.u)),[Object.keys(t).reduce((s,o)=>{const a=e(o);return a&&(s[a]=t[o]),s},{}),r,i]}let J6=null;function HOe(){return J6||(J6=Ur.fromMillis(1555555555555)),J6}function WOe(t,e){if(t.literal)return t;const r=va.macroTokenToFormatOpts(t.val),i=TV(r,e);return i==null||i.includes(void 0)?t:i}function bV(t,e){return Array.prototype.concat(...t.map(r=>WOe(r,e)))}let EV=class{constructor(t,e){if(this.locale=t,this.format=e,this.tokens=bV(va.parseFormat(e),t),this.units=this.tokens.map(r=>jOe(r,t)),this.disqualifyingUnit=this.units.find(r=>r.invalidReason),!this.disqualifyingUnit){const[r,i]=BOe(this.units);this.regex=RegExp(r,"i"),this.handlers=i}}explainFromTokens(t){if(this.isValid){const[e,r]=zOe(t,this.regex,this.handlers),[i,s,o]=r?QOe(r):[null,null,void 0];if(Og(r,"a")&&Og(r,"H"))throw new Ag("Can't include meridiem when specifying 24-hour format");return{input:t,tokens:this.tokens,regex:this.regex,rawMatches:e,matches:r,result:i,zone:s,specificOffset:o}}else return{input:t,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}};function SV(t,e,r){return new EV(t,r).explainFromTokens(e)}function GOe(t,e,r){const{result:i,zone:s,specificOffset:o,invalidReason:a}=SV(t,e,r);return[i,s,o,a]}function TV(t,e){if(!t)return null;const r=va.create(e,t).dtFormatter(HOe()),i=r.formatToParts(),s=r.resolvedOptions();return i.map(o=>qOe(o,t,s))}const X6="Invalid DateTime",_V=864e13;function ax(t){return new ya("unsupported zone",`the zone "${t.name}" is not supported`)}function Z6(t){return t.weekData===null&&(t.weekData=uA(t.c)),t.weekData}function ek(t){return t.localWeekData===null&&(t.localWeekData=uA(t.c,t.loc.getMinDaysInFirstWeek(),t.loc.getStartOfWeek())),t.localWeekData}function Hh(t,e){const r={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new Ur({...r,...e,old:r})}function AV(t,e,r){let i=t-e*60*1e3;const s=r.offset(i);if(e===s)return[i,e];i-=(s-e)*60*1e3;const o=r.offset(i);return s===o?[i,s]:[t-Math.min(s,o)*60*1e3,Math.max(s,o)]}function xA(t,e){t+=e*60*1e3;const r=new Date(t);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function bA(t,e,r){return AV(fA(t),e,r)}function wV(t,e){const r=t.o,i=t.c.year+Math.trunc(e.years),s=t.c.month+Math.trunc(e.months)+Math.trunc(e.quarters)*3,o={...t.c,year:i,month:s,day:Math.min(t.c.day,dA(i,s))+Math.trunc(e.days)+Math.trunc(e.weeks)*7},a=vi.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"),l=fA(o);let[u,c]=AV(l,r,t.zone);return a!==0&&(u+=a,c=t.zone.offset(u)),{ts:u,o:c}}function Fg(t,e,r,i,s,o){const{setZone:a,zone:l}=r;if(t&&Object.keys(t).length!==0||e){const u=e||l,c=Ur.fromObject(t,{...r,zone:u,specificOffset:o});return a?c:c.setZone(l)}else return Ur.invalid(new ya("unparsable",`the input "${s}" can't be parsed as ${i}`))}function EA(t,e,r=!0){return t.isValid?va.create(Or.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(t,e):null}function tk(t,e,r){const i=t.c.year>9999||t.c.year<0;let s="";if(i&&t.c.year>=0&&(s+="+"),s+=yn(t.c.year,i?6:4),r==="year")return s;if(e){if(s+="-",s+=yn(t.c.month),r==="month")return s;s+="-"}else if(s+=yn(t.c.month),r==="month")return s;return s+=yn(t.c.day),s}function OV(t,e,r,i,s,o,a){let l=!r||t.c.millisecond!==0||t.c.second!==0,u="";switch(a){case"day":case"month":case"year":break;default:if(u+=yn(t.c.hour),a==="hour")break;if(e){if(u+=":",u+=yn(t.c.minute),a==="minute")break;l&&(u+=":",u+=yn(t.c.second))}else{if(u+=yn(t.c.minute),a==="minute")break;l&&(u+=yn(t.c.second))}if(a==="second")break;l&&(!i||t.c.millisecond!==0)&&(u+=".",u+=yn(t.c.millisecond,3))}return s&&(t.isOffsetFixed&&t.offset===0&&!o?u+="Z":t.o<0?(u+="-",u+=yn(Math.trunc(-t.o/60)),u+=":",u+=yn(Math.trunc(-t.o%60))):(u+="+",u+=yn(Math.trunc(t.o/60)),u+=":",u+=yn(Math.trunc(t.o%60)))),o&&(u+="["+t.zone.ianaName+"]"),u}const RV={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},VOe={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},YOe={ordinal:1,hour:0,minute:0,second:0,millisecond:0},SA=["year","month","day","hour","minute","second","millisecond"],KOe=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],JOe=["year","ordinal","hour","minute","second","millisecond"];function TA(t){const e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new tG(t);return e}function CV(t){switch(t.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return TA(t)}}function XOe(t){if(lx===void 0&&(lx=Yr.now()),t.type!=="iana")return t.offset(lx);const e=t.name;let r=rk.get(e);return r===void 0&&(r=t.offset(lx),rk.set(e,r)),r}function NV(t,e){const r=Dd(e.zone,Yr.defaultZone);if(!r.isValid)return Ur.invalid(ax(r));const i=Or.fromObject(e);let s,o;if(ot(t.year))s=Yr.now();else{for(const u of SA)ot(t[u])&&(t[u]=RV[u]);const a=qG(t)||BG(t);if(a)return Ur.invalid(a);const l=XOe(r);[s,o]=bA(t,l,r)}return new Ur({ts:s,zone:r,loc:i,o})}function LV(t,e,r){const i=ot(r.round)?!0:r.round,s=ot(r.rounding)?"trunc":r.rounding,o=(l,u)=>(l=W6(l,i||r.calendary?0:2,r.calendary?"round":s),e.loc.clone(r).relFormatter(r).format(l,u)),a=l=>r.calendary?e.hasSame(t,l)?0:e.startOf(l).diff(t.startOf(l),l).get(l):e.diff(t,l).get(l);if(r.unit)return o(a(r.unit),r.unit);for(const l of r.units){const u=a(l);if(Math.abs(u)>=1)return o(u,l)}return o(t>e?-0:0,r.units[r.units.length-1])}function DV(t){let e={},r;return t.length>0&&typeof t[t.length-1]=="object"?(e=t[t.length-1],r=Array.from(t).slice(0,t.length-1)):r=Array.from(t),[e,r]}let lx;const rk=new Map;let Ur=class $r{constructor(e){const r=e.zone||Yr.defaultZone;let i=e.invalid||(Number.isNaN(e.ts)?new ya("invalid input"):null)||(r.isValid?null:ax(r));this.ts=ot(e.ts)?Yr.now():e.ts;let s=null,o=null;if(!i)if(e.old&&e.old.ts===this.ts&&e.old.zone.equals(r))[s,o]=[e.old.c,e.old.o];else{const a=kd(e.o)&&!e.old?e.o:r.offset(this.ts);s=xA(this.ts,a),i=Number.isNaN(s.year)?new ya("invalid input"):null,s=i?null:s,o=i?null:a}this._zone=r,this.loc=e.loc||Or.create(),this.invalid=i,this.weekData=null,this.localWeekData=null,this.c=s,this.o=o,this.isLuxonDateTime=!0}static now(){return new $r({})}static local(){const[e,r]=DV(arguments),[i,s,o,a,l,u,c]=r;return NV({year:i,month:s,day:o,hour:a,minute:l,second:u,millisecond:c},e)}static utc(){const[e,r]=DV(arguments),[i,s,o,a,l,u,c]=r;return e.zone=Cl.utcInstance,NV({year:i,month:s,day:o,hour:a,minute:l,second:u,millisecond:c},e)}static fromJSDate(e,r={}){const i=Lwe(e)?e.valueOf():NaN;if(Number.isNaN(i))return $r.invalid("invalid input");const s=Dd(r.zone,Yr.defaultZone);return s.isValid?new $r({ts:i,zone:s,loc:Or.fromObject(r)}):$r.invalid(ax(s))}static fromMillis(e,r={}){if(kd(e))return e<-_V||e>_V?$r.invalid("Timestamp out of range"):new $r({ts:e,zone:Dd(r.zone,Yr.defaultZone),loc:Or.fromObject(r)});throw new yi(`fromMillis requires a numerical input, but received a ${typeof e} with value ${e}`)}static fromSeconds(e,r={}){if(kd(e))return new $r({ts:e*1e3,zone:Dd(r.zone,Yr.defaultZone),loc:Or.fromObject(r)});throw new yi("fromSeconds requires a numerical input")}static fromObject(e,r={}){e=e||{};const i=Dd(r.zone,Yr.defaultZone);if(!i.isValid)return $r.invalid(ax(i));const s=Or.fromObject(r),o=pA(e,CV),{minDaysInFirstWeek:a,startOfWeek:l}=UG(o,s),u=Yr.now(),c=ot(r.specificOffset)?i.offset(u):r.specificOffset,d=!ot(o.ordinal),f=!ot(o.year),h=!ot(o.month)||!ot(o.day),m=f||h,g=o.weekYear||o.weekNumber;if((m||d)&&g)throw new Ag("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(h&&d)throw new Ag("Can't mix ordinal dates with month/day");const y=g||o.weekday&&!m;let v,x,b=xA(u,c);y?(v=KOe,x=VOe,b=uA(b,a,l)):d?(v=JOe,x=YOe,b=z6(b)):(v=SA,x=RV);let E=!1;for(const L of v){const C=o[L];ot(C)?E?o[L]=x[L]:o[L]=b[L]:E=!0}const S=y?Rwe(o,a,l):d?Cwe(o):qG(o),T=S||BG(o);if(T)return $r.invalid(T);const A=y?$G(o,a,l):d?jG(o):o,[_,O]=bA(A,c,i),R=new $r({ts:_,zone:i,o:O,loc:s});return o.weekday&&m&&e.weekday!==R.weekday?$r.invalid("mismatched weekday",`you can't specify both a weekday of ${o.weekday} and a date of ${R.toISO()}`):R.isValid?R:$r.invalid(R.invalid)}static fromISO(e,r={}){const[i,s]=bOe(e);return Fg(i,s,r,"ISO 8601",e)}static fromRFC2822(e,r={}){const[i,s]=EOe(e);return Fg(i,s,r,"RFC 2822",e)}static fromHTTP(e,r={}){const[i,s]=SOe(e);return Fg(i,s,r,"HTTP",r)}static fromFormat(e,r,i={}){if(ot(e)||ot(r))throw new yi("fromFormat requires an input string and a format");const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0}),[l,u,c,d]=GOe(a,e,r);return d?$r.invalid(d):Fg(l,u,i,`format ${r}`,e,c)}static fromString(e,r,i={}){return $r.fromFormat(e,r,i)}static fromSQL(e,r={}){const[i,s]=COe(e);return Fg(i,s,r,"SQL",e)}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the DateTime is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new rwe(i);return new $r({invalid:i})}static isDateTime(e){return e&&e.isLuxonDateTime||!1}static parseFormatForOpts(e,r={}){const i=TV(e,Or.fromObject(r));return i?i.map(s=>s?s.val:null).join(""):null}static expandFormat(e,r={}){return bV(va.parseFormat(e),Or.fromObject(r)).map(i=>i.val).join("")}static resetCache(){lx=void 0,rk.clear()}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?Z6(this).weekYear:NaN}get weekNumber(){return this.isValid?Z6(this).weekNumber:NaN}get weekday(){return this.isValid?Z6(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?ek(this).weekday:NaN}get localWeekNumber(){return this.isValid?ek(this).weekNumber:NaN}get localWeekYear(){return this.isValid?ek(this).weekYear:NaN}get ordinal(){return this.isValid?z6(this.c).ordinal:NaN}get monthShort(){return this.isValid?yA.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?yA.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?yA.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?yA.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,r=6e4,i=fA(this.c),s=this.zone.offset(i-e),o=this.zone.offset(i+e),a=this.zone.offset(i-s*r),l=this.zone.offset(i-o*r);if(a===l)return[this];const u=i-a*r,c=i-l*r,d=xA(u,a),f=xA(c,l);return d.hour===f.hour&&d.minute===f.minute&&d.second===f.second&&d.millisecond===f.millisecond?[Hh(this,{ts:u}),Hh(this,{ts:c})]:[this]}get isInLeapYear(){return rx(this.year)}get daysInMonth(){return dA(this.year,this.month)}get daysInYear(){return this.isValid?Rg(this.year):NaN}get weeksInWeekYear(){return this.isValid?nx(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?nx(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(e={}){const{locale:r,numberingSystem:i,calendar:s}=va.create(this.loc.clone(e),e).resolvedOptions(this);return{locale:r,numberingSystem:i,outputCalendar:s}}toUTC(e=0,r={}){return this.setZone(Cl.instance(e),r)}toLocal(){return this.setZone(Yr.defaultZone)}setZone(e,{keepLocalTime:r=!1,keepCalendarTime:i=!1}={}){if(e=Dd(e,Yr.defaultZone),e.equals(this.zone))return this;if(e.isValid){let s=this.ts;if(r||i){const o=e.offset(this.ts),a=this.toObject();[s]=bA(a,o,e)}return Hh(this,{ts:s,zone:e})}else return $r.invalid(ax(e))}reconfigure({locale:e,numberingSystem:r,outputCalendar:i}={}){const s=this.loc.clone({locale:e,numberingSystem:r,outputCalendar:i});return Hh(this,{loc:s})}setLocale(e){return this.reconfigure({locale:e})}set(e){if(!this.isValid)return this;const r=pA(e,CV),{minDaysInFirstWeek:i,startOfWeek:s}=UG(r,this.loc),o=!ot(r.weekYear)||!ot(r.weekNumber)||!ot(r.weekday),a=!ot(r.ordinal),l=!ot(r.year),u=!ot(r.month)||!ot(r.day),c=l||u,d=r.weekYear||r.weekNumber;if((c||a)&&d)throw new Ag("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(u&&a)throw new Ag("Can't mix ordinal dates with month/day");let f;o?f=$G({...uA(this.c,i,s),...r},i,s):ot(r.ordinal)?(f={...this.toObject(),...r},ot(r.day)&&(f.day=Math.min(dA(f.year,f.month),f.day))):f=jG({...z6(this.c),...r});const[h,m]=bA(f,this.o,this.zone);return Hh(this,{ts:h,o:m})}plus(e){if(!this.isValid)return this;const r=vi.fromDurationLike(e);return Hh(this,wV(this,r))}minus(e){if(!this.isValid)return this;const r=vi.fromDurationLike(e).negate();return Hh(this,wV(this,r))}startOf(e,{useLocaleWeeks:r=!1}={}){if(!this.isValid)return this;const i={},s=vi.normalizeUnit(e);switch(s){case"years":i.month=1;case"quarters":case"months":i.day=1;case"weeks":case"days":i.hour=0;case"hours":i.minute=0;case"minutes":i.second=0;case"seconds":i.millisecond=0;break}if(s==="weeks")if(r){const o=this.loc.getStartOfWeek(),{weekday:a}=this;a<o&&(i.weekNumber=this.weekNumber-1),i.weekday=o}else i.weekday=1;if(s==="quarters"){const o=Math.ceil(this.month/3);i.month=(o-1)*3+1}return this.set(i)}endOf(e,r){return this.isValid?this.plus({[e]:1}).startOf(e,r).minus(1):this}toFormat(e,r={}){return this.isValid?va.create(this.loc.redefaultToEN(r)).formatDateTimeFromString(this,e):X6}toLocaleString(e=oA,r={}){return this.isValid?va.create(this.loc.clone(r),e).formatDateTime(this):X6}toLocaleParts(e={}){return this.isValid?va.create(this.loc.clone(e),e).formatDateTimeParts(this):[]}toISO({format:e="extended",suppressSeconds:r=!1,suppressMilliseconds:i=!1,includeOffset:s=!0,extendedZone:o=!1,precision:a="milliseconds"}={}){if(!this.isValid)return null;a=TA(a);const l=e==="extended";let u=tk(this,l,a);return SA.indexOf(a)>=3&&(u+="T"),u+=OV(this,l,r,i,s,o,a),u}toISODate({format:e="extended",precision:r="day"}={}){return this.isValid?tk(this,e==="extended",TA(r)):null}toISOWeekDate(){return EA(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:e=!1,suppressSeconds:r=!1,includeOffset:i=!0,includePrefix:s=!1,extendedZone:o=!1,format:a="extended",precision:l="milliseconds"}={}){return this.isValid?(l=TA(l),(s&&SA.indexOf(l)>=3?"T":"")+OV(this,a==="extended",r,e,i,o,l)):null}toRFC2822(){return EA(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return EA(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?tk(this,!0):null}toSQLTime({includeOffset:e=!0,includeZone:r=!1,includeOffsetSpace:i=!0}={}){let s="HH:mm:ss.SSS";return(r||e)&&(i&&(s+=" "),r?s+="z":e&&(s+="ZZ")),EA(this,s,!0)}toSQL(e={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(e)}`:null}toString(){return this.isValid?this.toISO():X6}[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 r={...this.c};return e.includeConfig&&(r.outputCalendar=this.outputCalendar,r.numberingSystem=this.loc.numberingSystem,r.locale=this.loc.locale),r}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(e,r="milliseconds",i={}){if(!this.isValid||!e.isValid)return vi.invalid("created by diffing an invalid DateTime");const s={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=Dwe(r).map(vi.normalizeUnit),a=e.valueOf()>this.valueOf(),l=a?this:e,u=a?e:this,c=MOe(l,u,o,s);return a?c.negate():c}diffNow(e="milliseconds",r={}){return this.diff($r.now(),e,r)}until(e){return this.isValid?gA.fromDateTimes(this,e):this}hasSame(e,r,i){if(!this.isValid)return!1;const s=e.valueOf(),o=this.setZone(e.zone,{keepLocalTime:!0});return o.startOf(r,i)<=s&&s<=o.endOf(r,i)}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 r=e.base||$r.fromObject({},{zone:this.zone}),i=e.padding?this<r?-e.padding:e.padding:0;let s=["years","months","days","hours","minutes","seconds"],o=e.unit;return Array.isArray(e.unit)&&(s=e.unit,o=void 0),LV(r,this.plus(i),{...e,numeric:"always",units:s,unit:o})}toRelativeCalendar(e={}){return this.isValid?LV(e.base||$r.fromObject({},{zone:this.zone}),this,{...e,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...e){if(!e.every($r.isDateTime))throw new yi("min requires all arguments be DateTimes");return HG(e,r=>r.valueOf(),Math.min)}static max(...e){if(!e.every($r.isDateTime))throw new yi("max requires all arguments be DateTimes");return HG(e,r=>r.valueOf(),Math.max)}static fromFormatExplain(e,r,i={}){const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});return SV(a,e,r)}static fromStringExplain(e,r,i={}){return $r.fromFormatExplain(e,r,i)}static buildFormatParser(e,r={}){const{locale:i=null,numberingSystem:s=null}=r,o=Or.fromOpts({locale:i,numberingSystem:s,defaultToEN:!0});return new EV(o,e)}static fromFormatParser(e,r,i={}){if(ot(e)||ot(r))throw new yi("fromFormatParser requires an input string and a format parser");const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});if(!a.equals(r.locale))throw new yi(`fromFormatParser called with a locale of ${a}, but the format parser was created for ${r.locale}`);const{result:l,zone:u,specificOffset:c,invalidReason:d}=r.explainFromTokens(e);return d?$r.invalid(d):Fg(l,u,i,`format ${r.format}`,e,c)}static get DATE_SHORT(){return oA}static get DATE_MED(){return rG}static get DATE_MED_WITH_WEEKDAY(){return swe}static get DATE_FULL(){return nG}static get DATE_HUGE(){return iG}static get TIME_SIMPLE(){return sG}static get TIME_WITH_SECONDS(){return oG}static get TIME_WITH_SHORT_OFFSET(){return aG}static get TIME_WITH_LONG_OFFSET(){return lG}static get TIME_24_SIMPLE(){return uG}static get TIME_24_WITH_SECONDS(){return cG}static get TIME_24_WITH_SHORT_OFFSET(){return dG}static get TIME_24_WITH_LONG_OFFSET(){return fG}static get DATETIME_SHORT(){return hG}static get DATETIME_SHORT_WITH_SECONDS(){return pG}static get DATETIME_MED(){return mG}static get DATETIME_MED_WITH_SECONDS(){return gG}static get DATETIME_MED_WITH_WEEKDAY(){return owe}static get DATETIME_FULL(){return yG}static get DATETIME_FULL_WITH_SECONDS(){return vG}static get DATETIME_HUGE(){return xG}static get DATETIME_HUGE_WITH_SECONDS(){return bG}};function ux(t){if(Ur.isDateTime(t))return t;if(t&&t.valueOf&&kd(t.valueOf()))return Ur.fromJSDate(t);if(t&&typeof t=="object")return Ur.fromObject(t);throw new yi(`Unknown datetime argument: ${t}, of type ${typeof t}`)}function Md(t,e,r=!1){if(t!==void 0)switch(t){case"ordinal":return{range:["#C2D5EE","#1A73E8"]};case"temporal":case"quantitative":return e?r?{range:["#6BA4EE","#EEA361"]}:{range:["#1A73E8","#E8710A"]}:{range:["#C2D5EE","#1A73E8"]};case"nominal":return r?{range:["#6BA4EE","#66CEDC","#EC72B8","#EEA361","#F9C85B","#AACD85","#B87CED","#ACB0B3"]}:{range:["#1A73E8","#12B5CB","#E52592","#E8710A","#F9AB00","#7CB342","#9334E6","#80868B"]}}}function Rr(t,e){return t.toString().padStart(e,"0")}function _A(t,e,r){e||(e="second");const i=Ur.fromJSDate(t,{zone:r??"UTC"});switch(e){case"year":return`${Rr(i.year,4)}`;case"quarter":{const s=Rr(i.year,4),o=Math.floor(i.month/3)+1;return`${s}-Q${o}`}case"month":{const s=Rr(i.year,2),o=Rr(i.month,2);return`${s}-${o}`}case"week":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2);return`${s}-${o}-${a}-WK`}case"day":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2);return`${s}-${o}-${a}`}case"hour":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2);return`${s}-${o}-${a} ${l}`}case"minute":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2),u=Rr(i.minute,2);return`${s}-${o}-${a} ${l}:${u}`}case"second":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2),u=Rr(i.minute,2),c=Rr(i.second,2);return`${s}-${o}-${a} ${l}:${u}:${c}`}default:throw new Error("Unknown timeframe.")}}function ZOe(t,e){const r=Ur.fromJSDate(t,{zone:e??"UTC"});return new Date(r.year,r.month-1,r.day,r.hour,r.minute,r.second,r.millisecond)}let nk;const eRe=100;async function AA(){const t=Date.now();if(!(nk&&t<nk+eRe))return nk=t,new Promise(e=>{setTimeout(e,0)})}function Co(t,e){const r=t.createElement("span");return r.classList.add("error"),r.appendChild(t.createTextNode(typeof e=="string"?e:e.message)),r}function cx(t){const e=t.createElement("span");return e.appendChild(t.createTextNode("∅")),e.classList.add("value-null"),e}function kV(t){const e=t.createElement("div");return e.classList.add("drill-icon"),e.innerHTML=`
|
|
1
|
+
import{U as t_e}from"./index-BvVmB5sv.js";function Nkt(rA,nA){for(var jr=0;jr<nA.length;jr++){const Bt=nA[jr];if(typeof Bt!="string"&&!Array.isArray(Bt)){for(const Xu in Bt)if(Xu!=="default"&&!(Xu in rA)){const Tg=Object.getOwnPropertyDescriptor(Bt,Xu);Tg&&Object.defineProperty(rA,Xu,Tg.get?Tg:{enumerable:!0,get:()=>Bt[Xu]})}}}return Object.freeze(Object.defineProperty(rA,Symbol.toStringTag,{value:"Module"}))}var G_={exports:{}},Lkt=G_.exports,r_e;function Dkt(){return r_e||(r_e=1,(function(rA,nA){(function(jr,Bt){Bt(nA)})(Lkt,function(jr){class Bt{constructor(){this.tagOptionExtractors={}}addExtractor(e,...r){for(const i in r)this.tagOptionExtractors[r[i]]=e}activates(e){return!1}isValidMatch(e){return!0}matches(e){return e.renderer===this.rendererName}parseTagParameters(e){const r={};for(const i in this.tagOptionExtractors){const s=e.tag(i);s&&this.tagOptionExtractors[i](r,s)}return r}}function Xu(t){if(t.isArray())return t.values.map(e=>Xu(e));if(t.isNumber()||t.isBoolean()||t.isString()||t.isNull())return t.value;if(t.isTime())return t.value.toISOString();if(t.isJSON())try{return JSON.parse(t.value)}catch{return t.value}else if(t.isRecord()){const e={};for(const r of t.columns)e[r.field.name]=Xu(r);return e}return null}class Tg{constructor(e){this.document=e}async render(e){const r=this.document.createElement("pre");return r.appendChild(this.document.createTextNode(JSON.stringify(Xu(e),void 0,2))),r}}const _6=class extends Bt{create(e,r,i,s,o){return new Tg(e)}get rendererName(){return"json"}};_6.instance=new _6;let d_e=_6;class f_e{constructor(e,r,i){this.document=e,this.options=r,this.tagged=i}}class iA extends f_e{constructor(){super(...arguments),this.childRenderers={}}get defaultStylesForChildren(){return this.childrenStyleDefaults}static make(e,r,i,s,o){return new e(r,s,o)}}var w=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof t_e<"u"?t_e:typeof self<"u"?self:{};function sA(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function h_e(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function i(){return this instanceof i?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(i){var s=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(r,i,s.get?s:{enumerable:!0,get:function(){return t[i]}})}),r}function p_e(t,e,r,i){var s=-1,o=t==null?0:t.length;for(i&&o&&(r=t[++s]);++s<o;)r=e(r,t[s],s,t);return r}var m_e=p_e;function g_e(t){return function(e){return t?.[e]}}var y_e=g_e,v_e=y_e,x_e={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},b_e=v_e(x_e),E_e=b_e,S_e=typeof w=="object"&&w&&w.Object===Object&&w,T_e=S_e,__e=T_e,A_e=typeof self=="object"&&self&&self.Object===Object&&self,w_e=__e||A_e||Function("return this")(),O_e=w_e,R_e=O_e,C_e=R_e.Symbol,A6=C_e;function N_e(t,e){for(var r=-1,i=t==null?0:t.length,s=Array(i);++r<i;)s[r]=e(t[r],r,t);return s}var L_e=N_e,D_e=Array.isArray,k_e=D_e,TW=A6,_W=Object.prototype,I_e=_W.hasOwnProperty,M_e=_W.toString,ex=TW?TW.toStringTag:void 0;function F_e(t){var e=I_e.call(t,ex),r=t[ex];try{t[ex]=void 0;var i=!0}catch{}var s=M_e.call(t);return i&&(e?t[ex]=r:delete t[ex]),s}var P_e=F_e,$_e=Object.prototype,j_e=$_e.toString;function U_e(t){return j_e.call(t)}var q_e=U_e,AW=A6,B_e=P_e,z_e=q_e,Q_e="[object Null]",H_e="[object Undefined]",wW=AW?AW.toStringTag:void 0;function W_e(t){return t==null?t===void 0?H_e:Q_e:wW&&wW in Object(t)?B_e(t):z_e(t)}var G_e=W_e;function V_e(t){return t!=null&&typeof t=="object"}var Y_e=V_e,K_e=G_e,J_e=Y_e,X_e="[object Symbol]";function Z_e(t){return typeof t=="symbol"||J_e(t)&&K_e(t)==X_e}var eAe=Z_e,OW=A6,tAe=L_e,rAe=k_e,nAe=eAe,RW=OW?OW.prototype:void 0,CW=RW?RW.toString:void 0;function NW(t){if(typeof t=="string")return t;if(rAe(t))return tAe(t,NW)+"";if(nAe(t))return CW?CW.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var iAe=NW,sAe=iAe;function oAe(t){return t==null?"":sAe(t)}var w6=oAe,aAe=E_e,lAe=w6,uAe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,cAe="\\u0300-\\u036f",dAe="\\ufe20-\\ufe2f",fAe="\\u20d0-\\u20ff",hAe=cAe+dAe+fAe,pAe="["+hAe+"]",mAe=RegExp(pAe,"g");function gAe(t){return t=lAe(t),t&&t.replace(uAe,aAe).replace(mAe,"")}var yAe=gAe,vAe=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function xAe(t){return t.match(vAe)||[]}var bAe=xAe,EAe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function SAe(t){return EAe.test(t)}var TAe=SAe,LW="\\ud800-\\udfff",_Ae="\\u0300-\\u036f",AAe="\\ufe20-\\ufe2f",wAe="\\u20d0-\\u20ff",OAe=_Ae+AAe+wAe,DW="\\u2700-\\u27bf",kW="a-z\\xdf-\\xf6\\xf8-\\xff",RAe="\\xac\\xb1\\xd7\\xf7",CAe="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",NAe="\\u2000-\\u206f",LAe=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",IW="A-Z\\xc0-\\xd6\\xd8-\\xde",DAe="\\ufe0e\\ufe0f",MW=RAe+CAe+NAe+LAe,FW="['’]",PW="["+MW+"]",kAe="["+OAe+"]",$W="\\d+",IAe="["+DW+"]",jW="["+kW+"]",UW="[^"+LW+MW+$W+DW+kW+IW+"]",MAe="\\ud83c[\\udffb-\\udfff]",FAe="(?:"+kAe+"|"+MAe+")",PAe="[^"+LW+"]",qW="(?:\\ud83c[\\udde6-\\uddff]){2}",BW="[\\ud800-\\udbff][\\udc00-\\udfff]",_g="["+IW+"]",$Ae="\\u200d",zW="(?:"+jW+"|"+UW+")",jAe="(?:"+_g+"|"+UW+")",QW="(?:"+FW+"(?:d|ll|m|re|s|t|ve))?",HW="(?:"+FW+"(?:D|LL|M|RE|S|T|VE))?",WW=FAe+"?",GW="["+DAe+"]?",UAe="(?:"+$Ae+"(?:"+[PAe,qW,BW].join("|")+")"+GW+WW+")*",qAe="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",BAe="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",zAe=GW+WW+UAe,QAe="(?:"+[IAe,qW,BW].join("|")+")"+zAe,HAe=RegExp([_g+"?"+jW+"+"+QW+"(?="+[PW,_g,"$"].join("|")+")",jAe+"+"+HW+"(?="+[PW,_g+zW,"$"].join("|")+")",_g+"?"+zW+"+"+QW,_g+"+"+HW,BAe,qAe,$W,QAe].join("|"),"g");function WAe(t){return t.match(HAe)||[]}var GAe=WAe,VAe=bAe,YAe=TAe,KAe=w6,JAe=GAe;function XAe(t,e,r){return t=KAe(t),e=r?void 0:e,e===void 0?YAe(t)?JAe(t):VAe(t):t.match(e)||[]}var ZAe=XAe,e3e=m_e,t3e=yAe,r3e=ZAe,n3e="['’]",i3e=RegExp(n3e,"g");function s3e(t){return function(e){return e3e(r3e(t3e(e).replace(i3e,"")),t,"")}}var o3e=s3e;function a3e(t,e,r){var i=-1,s=t.length;e<0&&(e=-e>s?0:s+e),r=r>s?s:r,r<0&&(r+=s),s=e>r?0:r-e>>>0,e>>>=0;for(var o=Array(s);++i<s;)o[i]=t[i+e];return o}var l3e=a3e,u3e=l3e;function c3e(t,e,r){var i=t.length;return r=r===void 0?i:r,!e&&r>=i?t:u3e(t,e,r)}var d3e=c3e,f3e="\\ud800-\\udfff",h3e="\\u0300-\\u036f",p3e="\\ufe20-\\ufe2f",m3e="\\u20d0-\\u20ff",g3e=h3e+p3e+m3e,y3e="\\ufe0e\\ufe0f",v3e="\\u200d",x3e=RegExp("["+v3e+f3e+g3e+y3e+"]");function b3e(t){return x3e.test(t)}var VW=b3e;function E3e(t){return t.split("")}var S3e=E3e,YW="\\ud800-\\udfff",T3e="\\u0300-\\u036f",_3e="\\ufe20-\\ufe2f",A3e="\\u20d0-\\u20ff",w3e=T3e+_3e+A3e,O3e="\\ufe0e\\ufe0f",R3e="["+YW+"]",O6="["+w3e+"]",R6="\\ud83c[\\udffb-\\udfff]",C3e="(?:"+O6+"|"+R6+")",KW="[^"+YW+"]",JW="(?:\\ud83c[\\udde6-\\uddff]){2}",XW="[\\ud800-\\udbff][\\udc00-\\udfff]",N3e="\\u200d",ZW=C3e+"?",eG="["+O3e+"]?",L3e="(?:"+N3e+"(?:"+[KW,JW,XW].join("|")+")"+eG+ZW+")*",D3e=eG+ZW+L3e,k3e="(?:"+[KW+O6+"?",O6,JW,XW,R3e].join("|")+")",I3e=RegExp(R6+"(?="+R6+")|"+k3e+D3e,"g");function M3e(t){return t.match(I3e)||[]}var F3e=M3e,P3e=S3e,$3e=VW,j3e=F3e;function U3e(t){return $3e(t)?j3e(t):P3e(t)}var q3e=U3e,B3e=d3e,z3e=VW,Q3e=q3e,H3e=w6;function W3e(t){return function(e){e=H3e(e);var r=z3e(e)?Q3e(e):void 0,i=r?r[0]:e.charAt(0),s=r?B3e(r,1).join(""):e.slice(1);return i[t]()+s}}var G3e=W3e,V3e=G3e,Y3e=V3e("toUpperCase"),K3e=Y3e,J3e=o3e,X3e=K3e,Z3e=J3e(function(t,e,r){return t+(r?" ":"")+X3e(e)}),ewe=Z3e;const twe=sA(ewe);let Bh=class extends Error{},rwe=class extends Bh{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}},nwe=class extends Bh{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}},iwe=class extends Bh{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}},Ag=class extends Bh{},tG=class extends Bh{constructor(t){super(`Invalid unit ${t}`)}},yi=class extends Bh{},Ld=class extends Bh{constructor(){super("Zone is an abstract class")}};const qe="numeric",ma="short",Xs="long",oA={year:qe,month:qe,day:qe},rG={year:qe,month:ma,day:qe},swe={year:qe,month:ma,day:qe,weekday:ma},nG={year:qe,month:Xs,day:qe},iG={year:qe,month:Xs,day:qe,weekday:Xs},sG={hour:qe,minute:qe},oG={hour:qe,minute:qe,second:qe},aG={hour:qe,minute:qe,second:qe,timeZoneName:ma},lG={hour:qe,minute:qe,second:qe,timeZoneName:Xs},uG={hour:qe,minute:qe,hourCycle:"h23"},cG={hour:qe,minute:qe,second:qe,hourCycle:"h23"},dG={hour:qe,minute:qe,second:qe,hourCycle:"h23",timeZoneName:ma},fG={hour:qe,minute:qe,second:qe,hourCycle:"h23",timeZoneName:Xs},hG={year:qe,month:qe,day:qe,hour:qe,minute:qe},pG={year:qe,month:qe,day:qe,hour:qe,minute:qe,second:qe},mG={year:qe,month:ma,day:qe,hour:qe,minute:qe},gG={year:qe,month:ma,day:qe,hour:qe,minute:qe,second:qe},owe={year:qe,month:ma,day:qe,weekday:ma,hour:qe,minute:qe},yG={year:qe,month:Xs,day:qe,hour:qe,minute:qe,timeZoneName:ma},vG={year:qe,month:Xs,day:qe,hour:qe,minute:qe,second:qe,timeZoneName:ma},xG={year:qe,month:Xs,day:qe,weekday:Xs,hour:qe,minute:qe,timeZoneName:Xs},bG={year:qe,month:Xs,day:qe,weekday:Xs,hour:qe,minute:qe,second:qe,timeZoneName:Xs};let tx=class{get type(){throw new Ld}get name(){throw new Ld}get ianaName(){return this.name}get isUniversal(){throw new Ld}offsetName(t,e){throw new Ld}formatOffset(t,e){throw new Ld}offset(t){throw new Ld}equals(t){throw new Ld}get isValid(){throw new Ld}},C6=null,EG=class n_e extends tx{static get instance(){return C6===null&&(C6=new n_e),C6}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(e,{format:r,locale:i}){return GG(e,r,i)}formatOffset(e,r){return ix(this.offset(e),r)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}};const N6=new Map;function awe(t){let e=N6.get(t);return e===void 0&&(e=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"}),N6.set(t,e)),e}const lwe={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function uwe(t,e){const r=t.format(e).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(r),[,s,o,a,l,u,c,d]=i;return[a,s,o,l,u,c,d]}function cwe(t,e){const r=t.formatToParts(e),i=[];for(let s=0;s<r.length;s++){const{type:o,value:a}=r[s],l=lwe[o];o==="era"?i[l]=a:ot(l)||(i[l]=parseInt(a,10))}return i}const L6=new Map;let wg=class vW extends tx{static create(e){let r=L6.get(e);return r===void 0&&L6.set(e,r=new vW(e)),r}static resetCache(){L6.clear(),N6.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=vW.isValidZone(e)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(e,{format:r,locale:i}){return GG(e,r,i,this.name)}formatOffset(e,r){return ix(this.offset(e),r)}offset(e){if(!this.valid)return NaN;const r=new Date(e);if(isNaN(r))return NaN;const i=awe(this.name);let[s,o,a,l,u,c,d]=i.formatToParts?cwe(i,r):uwe(i,r);l==="BC"&&(s=-Math.abs(s)+1);const f=fA({year:s,month:o,day:a,hour:u===24?0:u,minute:c,second:d,millisecond:0});let h=+r;const m=h%1e3;return h-=m>=0?m:1e3+m,(f-h)/(60*1e3)}equals(e){return e.type==="iana"&&e.name===this.name}get isValid(){return this.valid}},SG={};function dwe(t,e={}){const r=JSON.stringify([t,e]);let i=SG[r];return i||(i=new Intl.ListFormat(t,e),SG[r]=i),i}const D6=new Map;function k6(t,e={}){const r=JSON.stringify([t,e]);let i=D6.get(r);return i===void 0&&(i=new Intl.DateTimeFormat(t,e),D6.set(r,i)),i}const I6=new Map;function fwe(t,e={}){const r=JSON.stringify([t,e]);let i=I6.get(r);return i===void 0&&(i=new Intl.NumberFormat(t,e),I6.set(r,i)),i}const M6=new Map;function hwe(t,e={}){const{base:r,...i}=e,s=JSON.stringify([t,i]);let o=M6.get(s);return o===void 0&&(o=new Intl.RelativeTimeFormat(t,e),M6.set(s,o)),o}let aA=null;function pwe(){return aA||(aA=new Intl.DateTimeFormat().resolvedOptions().locale,aA)}const F6=new Map;function TG(t){let e=F6.get(t);return e===void 0&&(e=new Intl.DateTimeFormat(t).resolvedOptions(),F6.set(t,e)),e}const P6=new Map;function mwe(t){let e=P6.get(t);if(!e){const r=new Intl.Locale(t);e="getWeekInfo"in r?r.getWeekInfo():r.weekInfo,"minimalDays"in e||(e={..._G,...e}),P6.set(t,e)}return e}function gwe(t){const e=t.indexOf("-x-");e!==-1&&(t=t.substring(0,e));const r=t.indexOf("-u-");if(r===-1)return[t];{let i,s;try{i=k6(t).resolvedOptions(),s=t}catch{const l=t.substring(0,r);i=k6(l).resolvedOptions(),s=l}const{numberingSystem:o,calendar:a}=i;return[s,o,a]}}function ywe(t,e,r){return(r||e)&&(t.includes("-u-")||(t+="-u"),r&&(t+=`-ca-${r}`),e&&(t+=`-nu-${e}`)),t}function vwe(t){const e=[];for(let r=1;r<=12;r++){const i=Ur.utc(2009,r,1);e.push(t(i))}return e}function xwe(t){const e=[];for(let r=1;r<=7;r++){const i=Ur.utc(2016,11,13+r);e.push(t(i))}return e}function lA(t,e,r,i){const s=t.listingMode();return s==="error"?null:s==="en"?r(e):i(e)}function bwe(t){return t.numberingSystem&&t.numberingSystem!=="latn"?!1:t.numberingSystem==="latn"||!t.locale||t.locale.startsWith("en")||TG(t.locale).numberingSystem==="latn"}let Ewe=class{constructor(t,e,r){this.padTo=r.padTo||0,this.floor=r.floor||!1;const{padTo:i,floor:s,...o}=r;if(!e||Object.keys(o).length>0){const a={useGrouping:!1,...r};r.padTo>0&&(a.minimumIntegerDigits=r.padTo),this.inf=fwe(t,a)}}format(t){if(this.inf){const e=this.floor?Math.floor(t):t;return this.inf.format(e)}else{const e=this.floor?Math.floor(t):W6(t,3);return yn(e,this.padTo)}}},Swe=class{constructor(t,e,r){this.opts=r,this.originalZone=void 0;let i;if(this.opts.timeZone)this.dt=t;else if(t.zone.type==="fixed"){const o=-1*(t.offset/60),a=o>=0?`Etc/GMT+${o}`:`Etc/GMT${o}`;t.offset!==0&&wg.create(a).valid?(i=a,this.dt=t):(i="UTC",this.dt=t.offset===0?t:t.setZone("UTC").plus({minutes:t.offset}),this.originalZone=t.zone)}else t.zone.type==="system"?this.dt=t:t.zone.type==="iana"?(this.dt=t,i=t.zone.name):(i="UTC",this.dt=t.setZone("UTC").plus({minutes:t.offset}),this.originalZone=t.zone);const s={...this.opts};s.timeZone=s.timeZone||i,this.dtf=k6(e,s)}format(){return this.originalZone?this.formatToParts().map(({value:t})=>t).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const t=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?t.map(e=>{if(e.type==="timeZoneName"){const r=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...e,value:r}}else return e}):t}resolvedOptions(){return this.dtf.resolvedOptions()}},Twe=class{constructor(t,e,r){this.opts={style:"long",...r},!e&&zG()&&(this.rtf=hwe(t,r))}format(t,e){return this.rtf?this.rtf.format(t,e):Hwe(e,t,this.opts.numeric,this.opts.style!=="long")}formatToParts(t,e){return this.rtf?this.rtf.formatToParts(t,e):[]}};const _G={firstDay:1,minimalDays:4,weekend:[6,7]};let Or=class V_{static fromOpts(e){return V_.create(e.locale,e.numberingSystem,e.outputCalendar,e.weekSettings,e.defaultToEN)}static create(e,r,i,s,o=!1){const a=e||Yr.defaultLocale,l=a||(o?"en-US":pwe()),u=r||Yr.defaultNumberingSystem,c=i||Yr.defaultOutputCalendar,d=Q6(s)||Yr.defaultWeekSettings;return new V_(l,u,c,d,a)}static resetCache(){aA=null,D6.clear(),I6.clear(),M6.clear(),F6.clear(),P6.clear()}static fromObject({locale:e,numberingSystem:r,outputCalendar:i,weekSettings:s}={}){return V_.create(e,r,i,s)}constructor(e,r,i,s,o){const[a,l,u]=gwe(e);this.locale=a,this.numberingSystem=r||l||null,this.outputCalendar=i||u||null,this.weekSettings=s,this.intl=ywe(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=o,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=bwe(this)),this.fastNumbersCached}listingMode(){const e=this.isEnglish(),r=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return e&&r?"en":"intl"}clone(e){return!e||Object.getOwnPropertyNames(e).length===0?this:V_.create(e.locale||this.specifiedLocale,e.numberingSystem||this.numberingSystem,e.outputCalendar||this.outputCalendar,Q6(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,r=!1){return lA(this,e,KG,()=>{const i=this.intl==="ja"||this.intl.startsWith("ja-");r&=!i;const s=r?{month:e,day:"numeric"}:{month:e},o=r?"format":"standalone";if(!this.monthsCache[o][e]){const a=i?l=>this.dtFormatter(l,s).format():l=>this.extract(l,s,"month");this.monthsCache[o][e]=vwe(a)}return this.monthsCache[o][e]})}weekdays(e,r=!1){return lA(this,e,ZG,()=>{const i=r?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},s=r?"format":"standalone";return this.weekdaysCache[s][e]||(this.weekdaysCache[s][e]=xwe(o=>this.extract(o,i,"weekday"))),this.weekdaysCache[s][e]})}meridiems(){return lA(this,void 0,()=>eV,()=>{if(!this.meridiemCache){const e={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Ur.utc(2016,11,13,9),Ur.utc(2016,11,13,19)].map(r=>this.extract(r,e,"dayperiod"))}return this.meridiemCache})}eras(e){return lA(this,e,tV,()=>{const r={era:e};return this.eraCache[e]||(this.eraCache[e]=[Ur.utc(-40,1,1),Ur.utc(2017,1,1)].map(i=>this.extract(i,r,"era"))),this.eraCache[e]})}extract(e,r,i){const s=this.dtFormatter(e,r),o=s.formatToParts(),a=o.find(l=>l.type.toLowerCase()===i);return a?a.value:null}numberFormatter(e={}){return new Ewe(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,r={}){return new Swe(e,this.intl,r)}relFormatter(e={}){return new Twe(this.intl,this.isEnglish(),e)}listFormatter(e={}){return dwe(this.intl,e)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||TG(this.intl).locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:QG()?mwe(this.locale):_G}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})`}},$6=null,Cl=class Y_ extends tx{static get utcInstance(){return $6===null&&($6=new Y_(0)),$6}static instance(e){return e===0?Y_.utcInstance:new Y_(e)}static parseSpecifier(e){if(e){const r=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(r)return new Y_(hA(r[1],r[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${ix(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${ix(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,r){return ix(this.fixed,r)}get isUniversal(){return!0}offset(){return this.fixed}equals(e){return e.type==="fixed"&&e.fixed===this.fixed}get isValid(){return!0}},_we=class extends tx{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}};function Dd(t,e){if(ot(t)||t===null)return e;if(t instanceof tx)return t;if(Nwe(t)){const r=t.toLowerCase();return r==="default"?e:r==="local"||r==="system"?EG.instance:r==="utc"||r==="gmt"?Cl.utcInstance:Cl.parseSpecifier(r)||wg.create(t)}else return kd(t)?Cl.instance(t):typeof t=="object"&&"offset"in t&&typeof t.offset=="function"?t:new _we(t)}const j6={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},AG={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]},Awe=j6.hanidec.replace(/[\[|\]]/g,"").split("");function wwe(t){let e=parseInt(t,10);if(isNaN(e)){e="";for(let r=0;r<t.length;r++){const i=t.charCodeAt(r);if(t[r].search(j6.hanidec)!==-1)e+=Awe.indexOf(t[r]);else for(const s in AG){const[o,a]=AG[s];i>=o&&i<=a&&(e+=i-o)}}return parseInt(e,10)}else return e}const U6=new Map;function Owe(){U6.clear()}function ga({numberingSystem:t},e=""){const r=t||"latn";let i=U6.get(r);i===void 0&&(i=new Map,U6.set(r,i));let s=i.get(e);return s===void 0&&(s=new RegExp(`${j6[r]}${e}`),i.set(e,s)),s}let wG=()=>Date.now(),OG="system",RG=null,CG=null,NG=null,LG=60,DG,kG=null,Yr=class{static get now(){return wG}static set now(t){wG=t}static set defaultZone(t){OG=t}static get defaultZone(){return Dd(OG,EG.instance)}static get defaultLocale(){return RG}static set defaultLocale(t){RG=t}static get defaultNumberingSystem(){return CG}static set defaultNumberingSystem(t){CG=t}static get defaultOutputCalendar(){return NG}static set defaultOutputCalendar(t){NG=t}static get defaultWeekSettings(){return kG}static set defaultWeekSettings(t){kG=Q6(t)}static get twoDigitCutoffYear(){return LG}static set twoDigitCutoffYear(t){LG=t%100}static get throwOnInvalid(){return DG}static set throwOnInvalid(t){DG=t}static resetCaches(){Or.resetCache(),wg.resetCache(),Ur.resetCache(),Owe()}},ya=class{constructor(t,e){this.reason=t,this.explanation=e}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}};const IG=[0,31,59,90,120,151,181,212,243,273,304,334],MG=[0,31,60,91,121,152,182,213,244,274,305,335];function wo(t,e){return new ya("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${t}, which is invalid`)}function q6(t,e,r){const i=new Date(Date.UTC(t,e-1,r));t<100&&t>=0&&i.setUTCFullYear(i.getUTCFullYear()-1900);const s=i.getUTCDay();return s===0?7:s}function FG(t,e,r){return r+(rx(t)?MG:IG)[e-1]}function PG(t,e){const r=rx(t)?MG:IG,i=r.findIndex(o=>o<e),s=e-r[i];return{month:i+1,day:s}}function B6(t,e){return(t-e+7)%7+1}function uA(t,e=4,r=1){const{year:i,month:s,day:o}=t,a=FG(i,s,o),l=B6(q6(i,s,o),r);let u=Math.floor((a-l+14-e)/7),c;return u<1?(c=i-1,u=nx(c,e,r)):u>nx(i,e,r)?(c=i+1,u=1):c=i,{weekYear:c,weekNumber:u,weekday:l,...mA(t)}}function $G(t,e=4,r=1){const{weekYear:i,weekNumber:s,weekday:o}=t,a=B6(q6(i,1,e),r),l=Rg(i);let u=s*7+o-a-7+e,c;u<1?(c=i-1,u+=Rg(c)):u>l?(c=i+1,u-=Rg(i)):c=i;const{month:d,day:f}=PG(c,u);return{year:c,month:d,day:f,...mA(t)}}function z6(t){const{year:e,month:r,day:i}=t,s=FG(e,r,i);return{year:e,ordinal:s,...mA(t)}}function jG(t){const{year:e,ordinal:r}=t,{month:i,day:s}=PG(e,r);return{year:e,month:i,day:s,...mA(t)}}function UG(t,e){if(!ot(t.localWeekday)||!ot(t.localWeekNumber)||!ot(t.localWeekYear)){if(!ot(t.weekday)||!ot(t.weekNumber)||!ot(t.weekYear))throw new Ag("Cannot mix locale-based week fields with ISO-based week fields");return ot(t.localWeekday)||(t.weekday=t.localWeekday),ot(t.localWeekNumber)||(t.weekNumber=t.localWeekNumber),ot(t.localWeekYear)||(t.weekYear=t.localWeekYear),delete t.localWeekday,delete t.localWeekNumber,delete t.localWeekYear,{minDaysInFirstWeek:e.getMinDaysInFirstWeek(),startOfWeek:e.getStartOfWeek()}}else return{minDaysInFirstWeek:4,startOfWeek:1}}function Rwe(t,e=4,r=1){const i=cA(t.weekYear),s=Oo(t.weekNumber,1,nx(t.weekYear,e,r)),o=Oo(t.weekday,1,7);return i?s?o?!1:wo("weekday",t.weekday):wo("week",t.weekNumber):wo("weekYear",t.weekYear)}function Cwe(t){const e=cA(t.year),r=Oo(t.ordinal,1,Rg(t.year));return e?r?!1:wo("ordinal",t.ordinal):wo("year",t.year)}function qG(t){const e=cA(t.year),r=Oo(t.month,1,12),i=Oo(t.day,1,dA(t.year,t.month));return e?r?i?!1:wo("day",t.day):wo("month",t.month):wo("year",t.year)}function BG(t){const{hour:e,minute:r,second:i,millisecond:s}=t,o=Oo(e,0,23)||e===24&&r===0&&i===0&&s===0,a=Oo(r,0,59),l=Oo(i,0,59),u=Oo(s,0,999);return o?a?l?u?!1:wo("millisecond",s):wo("second",i):wo("minute",r):wo("hour",e)}function ot(t){return typeof t>"u"}function kd(t){return typeof t=="number"}function cA(t){return typeof t=="number"&&t%1===0}function Nwe(t){return typeof t=="string"}function Lwe(t){return Object.prototype.toString.call(t)==="[object Date]"}function zG(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function QG(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function Dwe(t){return Array.isArray(t)?t:[t]}function HG(t,e,r){if(t.length!==0)return t.reduce((i,s)=>{const o=[e(s),s];return i&&r(i[0],o[0])===i[0]?i:o},null)[1]}function kwe(t,e){return e.reduce((r,i)=>(r[i]=t[i],r),{})}function Og(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Q6(t){if(t==null)return null;if(typeof t!="object")throw new yi("Week settings must be an object");if(!Oo(t.firstDay,1,7)||!Oo(t.minimalDays,1,7)||!Array.isArray(t.weekend)||t.weekend.some(e=>!Oo(e,1,7)))throw new yi("Invalid week settings");return{firstDay:t.firstDay,minimalDays:t.minimalDays,weekend:Array.from(t.weekend)}}function Oo(t,e,r){return cA(t)&&t>=e&&t<=r}function Iwe(t,e){return t-e*Math.floor(t/e)}function yn(t,e=2){const r=t<0;let i;return r?i="-"+(""+-t).padStart(e,"0"):i=(""+t).padStart(e,"0"),i}function Id(t){if(!(ot(t)||t===null||t===""))return parseInt(t,10)}function zh(t){if(!(ot(t)||t===null||t===""))return parseFloat(t)}function H6(t){if(!(ot(t)||t===null||t==="")){const e=parseFloat("0."+t)*1e3;return Math.floor(e)}}function W6(t,e,r="round"){const i=10**e;switch(r){case"expand":return t>0?Math.ceil(t*i)/i:Math.floor(t*i)/i;case"trunc":return Math.trunc(t*i)/i;case"round":return Math.round(t*i)/i;case"floor":return Math.floor(t*i)/i;case"ceil":return Math.ceil(t*i)/i;default:throw new RangeError(`Value rounding ${r} is out of range`)}}function rx(t){return t%4===0&&(t%100!==0||t%400===0)}function Rg(t){return rx(t)?366:365}function dA(t,e){const r=Iwe(e-1,12)+1,i=t+(e-r)/12;return r===2?rx(i)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function fA(t){let e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(t.year,t.month-1,t.day)),+e}function WG(t,e,r){return-B6(q6(t,1,e),r)+e-1}function nx(t,e=4,r=1){const i=WG(t,e,r),s=WG(t+1,e,r);return(Rg(t)-i+s)/7}function G6(t){return t>99?t:t>Yr.twoDigitCutoffYear?1900+t:2e3+t}function GG(t,e,r,i=null){const s=new Date(t),o={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};i&&(o.timeZone=i);const a={timeZoneName:e,...o},l=new Intl.DateTimeFormat(r,a).formatToParts(s).find(u=>u.type.toLowerCase()==="timezonename");return l?l.value:null}function hA(t,e){let r=parseInt(t,10);Number.isNaN(r)&&(r=0);const i=parseInt(e,10)||0,s=r<0||Object.is(r,-0)?-i:i;return r*60+s}function VG(t){const e=Number(t);if(typeof t=="boolean"||t===""||!Number.isFinite(e))throw new yi(`Invalid unit value ${t}`);return e}function pA(t,e){const r={};for(const i in t)if(Og(t,i)){const s=t[i];if(s==null)continue;r[e(i)]=VG(s)}return r}function ix(t,e){const r=Math.trunc(Math.abs(t/60)),i=Math.trunc(Math.abs(t%60)),s=t>=0?"+":"-";switch(e){case"short":return`${s}${yn(r,2)}:${yn(i,2)}`;case"narrow":return`${s}${r}${i>0?`:${i}`:""}`;case"techie":return`${s}${yn(r,2)}${yn(i,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function mA(t){return kwe(t,["hour","minute","second","millisecond"])}const Mwe=["January","February","March","April","May","June","July","August","September","October","November","December"],YG=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Fwe=["J","F","M","A","M","J","J","A","S","O","N","D"];function KG(t){switch(t){case"narrow":return[...Fwe];case"short":return[...YG];case"long":return[...Mwe];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 JG=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],XG=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Pwe=["M","T","W","T","F","S","S"];function ZG(t){switch(t){case"narrow":return[...Pwe];case"short":return[...XG];case"long":return[...JG];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const eV=["AM","PM"],$we=["Before Christ","Anno Domini"],jwe=["BC","AD"],Uwe=["B","A"];function tV(t){switch(t){case"narrow":return[...Uwe];case"short":return[...jwe];case"long":return[...$we];default:return null}}function qwe(t){return eV[t.hour<12?0:1]}function Bwe(t,e){return ZG(e)[t.weekday-1]}function zwe(t,e){return KG(e)[t.month-1]}function Qwe(t,e){return tV(e)[t.year<0?0:1]}function Hwe(t,e,r="always",i=!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."]},o=["hours","minutes","seconds"].indexOf(t)===-1;if(r==="auto"&&o){const f=t==="days";switch(e){case 1:return f?"tomorrow":`next ${s[t][0]}`;case-1:return f?"yesterday":`last ${s[t][0]}`;case 0:return f?"today":`this ${s[t][0]}`}}const a=Object.is(e,-0)||e<0,l=Math.abs(e),u=l===1,c=s[t],d=i?u?c[1]:c[2]||c[1]:u?s[t][0]:t;return a?`${l} ${d} ago`:`in ${l} ${d}`}function rV(t,e){let r="";for(const i of t)i.literal?r+=i.val:r+=e(i.val);return r}const Wwe={D:oA,DD:rG,DDD:nG,DDDD:iG,t:sG,tt:oG,ttt:aG,tttt:lG,T:uG,TT:cG,TTT:dG,TTTT:fG,f:hG,ff:mG,fff:yG,ffff:xG,F:pG,FF:gG,FFF:vG,FFFF:bG};let va=class K_{static create(e,r={}){return new K_(e,r)}static parseFormat(e){let r=null,i="",s=!1;const o=[];for(let a=0;a<e.length;a++){const l=e.charAt(a);l==="'"?((i.length>0||s)&&o.push({literal:s||/^\s+$/.test(i),val:i===""?"'":i}),r=null,i="",s=!s):s||l===r?i+=l:(i.length>0&&o.push({literal:/^\s+$/.test(i),val:i}),i=l,r=l)}return i.length>0&&o.push({literal:s||/^\s+$/.test(i),val:i}),o}static macroTokenToFormatOpts(e){return Wwe[e]}constructor(e,r){this.opts=r,this.loc=e,this.systemLoc=null}formatWithSystemDefault(e,r){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(e,{...this.opts,...r}).format()}dtFormatter(e,r={}){return this.loc.dtFormatter(e,{...this.opts,...r})}formatDateTime(e,r){return this.dtFormatter(e,r).format()}formatDateTimeParts(e,r){return this.dtFormatter(e,r).formatToParts()}formatInterval(e,r){return this.dtFormatter(e.start,r).dtf.formatRange(e.start.toJSDate(),e.end.toJSDate())}resolvedOptions(e,r){return this.dtFormatter(e,r).resolvedOptions()}num(e,r=0,i=void 0){if(this.opts.forceSimple)return yn(e,r);const s={...this.opts};return r>0&&(s.padTo=r),i&&(s.signDisplay=i),this.loc.numberFormatter(s).format(e)}formatDateTimeFromString(e,r){const i=this.loc.listingMode()==="en",s=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",o=(m,g)=>this.loc.extract(e,m,g),a=m=>e.isOffsetFixed&&e.offset===0&&m.allowZ?"Z":e.isValid?e.zone.formatOffset(e.ts,m.format):"",l=()=>i?qwe(e):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),u=(m,g)=>i?zwe(e,m):o(g?{month:m}:{month:m,day:"numeric"},"month"),c=(m,g)=>i?Bwe(e,m):o(g?{weekday:m}:{weekday:m,month:"long",day:"numeric"},"weekday"),d=m=>{const g=K_.macroTokenToFormatOpts(m);return g?this.formatWithSystemDefault(e,g):m},f=m=>i?Qwe(e,m):o({era:m},"era"),h=m=>{switch(m){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 l();case"d":return s?o({day:"numeric"},"day"):this.num(e.day);case"dd":return s?o({day:"2-digit"},"day"):this.num(e.day,2);case"c":return this.num(e.weekday);case"ccc":return c("short",!0);case"cccc":return c("long",!0);case"ccccc":return c("narrow",!0);case"E":return this.num(e.weekday);case"EEE":return c("short",!1);case"EEEE":return c("long",!1);case"EEEEE":return c("narrow",!1);case"L":return s?o({month:"numeric",day:"numeric"},"month"):this.num(e.month);case"LL":return s?o({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?o({month:"numeric"},"month"):this.num(e.month);case"MM":return s?o({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?o({year:"numeric"},"year"):this.num(e.year);case"yy":return s?o({year:"2-digit"},"year"):this.num(e.year.toString().slice(-2),2);case"yyyy":return s?o({year:"numeric"},"year"):this.num(e.year,4);case"yyyyyy":return s?o({year:"numeric"},"year"):this.num(e.year,6);case"G":return f("short");case"GG":return f("long");case"GGGGG":return f("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 d(m)}};return rV(K_.parseFormat(r),h)}formatDurationFromString(e,r){const i=this.opts.signMode==="negativeLargestOnly"?-1:1,s=d=>{switch(d[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}},o=(d,f)=>h=>{const m=s(h);if(m){const g=f.isNegativeDuration&&m!==f.largestUnit?i:1;let y;return this.opts.signMode==="negativeLargestOnly"&&m!==f.largestUnit?y="never":this.opts.signMode==="all"?y="always":y="auto",this.num(d.get(m)*g,h.length,y)}else return h},a=K_.parseFormat(r),l=a.reduce((d,{literal:f,val:h})=>f?d:d.concat(h),[]),u=e.shiftTo(...l.map(s).filter(d=>d)),c={isNegativeDuration:u<0,largestUnit:Object.keys(u.values)[0]};return rV(a,o(u,c))}};const nV=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Cg(...t){const e=t.reduce((r,i)=>r+i.source,"");return RegExp(`^${e}$`)}function Ng(...t){return e=>t.reduce(([r,i,s],o)=>{const[a,l,u]=o(e,s);return[{...r,...a},l||i,u]},[{},null,1]).slice(0,2)}function Lg(t,...e){if(t==null)return[null,null];for(const[r,i]of e){const s=r.exec(t);if(s)return i(s)}return[null,null]}function iV(...t){return(e,r)=>{const i={};let s;for(s=0;s<t.length;s++)i[t[s]]=Id(e[r+s]);return[i,null,r+s]}}const sV=/(?:([Zz])|([+-]\d\d)(?::?(\d\d))?)/,Gwe=`(?:${sV.source}?(?:\\[(${nV.source})\\])?)?`,V6=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,oV=RegExp(`${V6.source}${Gwe}`),Y6=RegExp(`(?:[Tt]${oV.source})?`),Vwe=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Ywe=/(\d{4})-?W(\d\d)(?:-?(\d))?/,Kwe=/(\d{4})-?(\d{3})/,Jwe=iV("weekYear","weekNumber","weekDay"),Xwe=iV("year","ordinal"),Zwe=/(\d{4})-(\d\d)-(\d\d)/,aV=RegExp(`${V6.source} ?(?:${sV.source}|(${nV.source}))?`),eOe=RegExp(`(?: ${aV.source})?`);function Dg(t,e,r){const i=t[e];return ot(i)?r:Id(i)}function tOe(t,e){return[{year:Dg(t,e),month:Dg(t,e+1,1),day:Dg(t,e+2,1)},null,e+3]}function kg(t,e){return[{hours:Dg(t,e,0),minutes:Dg(t,e+1,0),seconds:Dg(t,e+2,0),milliseconds:H6(t[e+3])},null,e+4]}function sx(t,e){const r=!t[e]&&!t[e+1],i=hA(t[e+1],t[e+2]),s=r?null:Cl.instance(i);return[{},s,e+3]}function ox(t,e){const r=t[e]?wg.create(t[e]):null;return[{},r,e+1]}const rOe=RegExp(`^T?${V6.source}$`),nOe=/^-?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 iOe(t){const[e,r,i,s,o,a,l,u,c]=t,d=e[0]==="-",f=u&&u[0]==="-",h=(m,g=!1)=>m!==void 0&&(g||m&&d)?-m:m;return[{years:h(zh(r)),months:h(zh(i)),weeks:h(zh(s)),days:h(zh(o)),hours:h(zh(a)),minutes:h(zh(l)),seconds:h(zh(u),u==="-0"),milliseconds:h(H6(c),f)}]}const sOe={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function K6(t,e,r,i,s,o,a){const l={year:e.length===2?G6(Id(e)):Id(e),month:YG.indexOf(r)+1,day:Id(i),hour:Id(s),minute:Id(o)};return a&&(l.second=Id(a)),t&&(l.weekday=t.length>3?JG.indexOf(t)+1:XG.indexOf(t)+1),l}const oOe=/^(?:(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 aOe(t){const[,e,r,i,s,o,a,l,u,c,d,f]=t,h=K6(e,s,i,r,o,a,l);let m;return u?m=sOe[u]:c?m=0:m=hA(d,f),[h,new Cl(m)]}function lOe(t){return t.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const uOe=/^(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$/,cOe=/^(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$/,dOe=/^(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 lV(t){const[,e,r,i,s,o,a,l]=t;return[K6(e,s,i,r,o,a,l),Cl.utcInstance]}function fOe(t){const[,e,r,i,s,o,a,l]=t;return[K6(e,l,r,i,s,o,a),Cl.utcInstance]}const hOe=Cg(Vwe,Y6),pOe=Cg(Ywe,Y6),mOe=Cg(Kwe,Y6),gOe=Cg(oV),uV=Ng(tOe,kg,sx,ox),yOe=Ng(Jwe,kg,sx,ox),vOe=Ng(Xwe,kg,sx,ox),xOe=Ng(kg,sx,ox);function bOe(t){return Lg(t,[hOe,uV],[pOe,yOe],[mOe,vOe],[gOe,xOe])}function EOe(t){return Lg(lOe(t),[oOe,aOe])}function SOe(t){return Lg(t,[uOe,lV],[cOe,lV],[dOe,fOe])}function TOe(t){return Lg(t,[nOe,iOe])}const _Oe=Ng(kg);function AOe(t){return Lg(t,[rOe,_Oe])}const wOe=Cg(Zwe,eOe),OOe=Cg(aV),ROe=Ng(kg,sx,ox);function COe(t){return Lg(t,[wOe,uV],[OOe,ROe])}const cV="Invalid Duration",dV={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}},NOe={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},...dV},Ro=146097/400,Ig=146097/4800,LOe={years:{quarters:4,months:12,weeks:Ro/7,days:Ro,hours:Ro*24,minutes:Ro*24*60,seconds:Ro*24*60*60,milliseconds:Ro*24*60*60*1e3},quarters:{months:3,weeks:Ro/28,days:Ro/4,hours:Ro*24/4,minutes:Ro*24*60/4,seconds:Ro*24*60*60/4,milliseconds:Ro*24*60*60*1e3/4},months:{weeks:Ig/7,days:Ig,hours:Ig*24,minutes:Ig*24*60,seconds:Ig*24*60*60,milliseconds:Ig*24*60*60*1e3},...dV},Qh=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],DOe=Qh.slice(0).reverse();function Zu(t,e,r=!1){const i={values:r?e.values:{...t.values,...e.values||{}},loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy,matrix:e.matrix||t.matrix};return new vi(i)}function fV(t,e){let r=e.milliseconds??0;for(const i of DOe.slice(1))e[i]&&(r+=e[i]*t[i].milliseconds);return r}function hV(t,e){const r=fV(t,e)<0?-1:1;Qh.reduceRight((i,s)=>{if(ot(e[s]))return i;if(i){const o=e[i]*r,a=t[s][i],l=Math.floor(o/a);e[s]+=l*r,e[i]-=l*a*r}return s},null),Qh.reduce((i,s)=>{if(ot(e[s]))return i;if(i){const o=e[i]%1;e[i]-=o,e[s]+=o*t[i][s]}return s},null)}function pV(t){const e={};for(const[r,i]of Object.entries(t))i!==0&&(e[r]=i);return e}let vi=class gi{constructor(e){const r=e.conversionAccuracy==="longterm"||!1;let i=r?LOe:NOe;e.matrix&&(i=e.matrix),this.values=e.values,this.loc=e.loc||Or.create(),this.conversionAccuracy=r?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=i,this.isLuxonDuration=!0}static fromMillis(e,r){return gi.fromObject({milliseconds:e},r)}static fromObject(e,r={}){if(e==null||typeof e!="object")throw new yi(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new gi({values:pA(e,gi.normalizeUnit),loc:Or.fromObject(r),conversionAccuracy:r.conversionAccuracy,matrix:r.matrix})}static fromDurationLike(e){if(kd(e))return gi.fromMillis(e);if(gi.isDuration(e))return e;if(typeof e=="object")return gi.fromObject(e);throw new yi(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,r){const[i]=TOe(e);return i?gi.fromObject(i,r):gi.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static fromISOTime(e,r){const[i]=AOe(e);return i?gi.fromObject(i,r):gi.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the Duration is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new iwe(i);return new gi({invalid:i})}static normalizeUnit(e){const r={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(!r)throw new tG(e);return r}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,r={}){const i={...r,floor:r.round!==!1&&r.floor!==!1};return this.isValid?va.create(this.loc,i).formatDurationFromString(this,e):cV}toHuman(e={}){if(!this.isValid)return cV;const r=e.showZeros!==!1,i=Qh.map(s=>{const o=this.values[s];return ot(o)||o===0&&!r?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...e,unit:s.slice(0,-1)}).format(o)}).filter(s=>s);return this.loc.listFormatter({type:"conjunction",style:e.listStyle||"narrow",...e}).format(i)}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+=W6(this.seconds+this.milliseconds/1e3,3)+"S"),e==="P"&&(e+="T0S"),e}toISOTime(e={}){if(!this.isValid)return null;const r=this.toMillis();return r<0||r>=864e5?null:(e={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...e,includeOffset:!1},Ur.fromMillis(r,{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?fV(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(e){if(!this.isValid)return this;const r=gi.fromDurationLike(e),i={};for(const s of Qh)(Og(r.values,s)||Og(this.values,s))&&(i[s]=r.get(s)+this.get(s));return Zu(this,{values:i},!0)}minus(e){if(!this.isValid)return this;const r=gi.fromDurationLike(e);return this.plus(r.negate())}mapUnits(e){if(!this.isValid)return this;const r={};for(const i of Object.keys(this.values))r[i]=VG(e(this.values[i],i));return Zu(this,{values:r},!0)}get(e){return this[gi.normalizeUnit(e)]}set(e){if(!this.isValid)return this;const r={...this.values,...pA(e,gi.normalizeUnit)};return Zu(this,{values:r})}reconfigure({locale:e,numberingSystem:r,conversionAccuracy:i,matrix:s}={}){const o={loc:this.loc.clone({locale:e,numberingSystem:r}),matrix:s,conversionAccuracy:i};return Zu(this,o)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;const e=this.toObject();return hV(this.matrix,e),Zu(this,{values:e},!0)}rescale(){if(!this.isValid)return this;const e=pV(this.normalize().shiftToAll().toObject());return Zu(this,{values:e},!0)}shiftTo(...e){if(!this.isValid)return this;if(e.length===0)return this;e=e.map(a=>gi.normalizeUnit(a));const r={},i={},s=this.toObject();let o;for(const a of Qh)if(e.indexOf(a)>=0){o=a;let l=0;for(const c in i)l+=this.matrix[c][a]*i[c],i[c]=0;kd(s[a])&&(l+=s[a]);const u=Math.trunc(l);r[a]=u,i[a]=(l*1e3-u*1e3)/1e3}else kd(s[a])&&(i[a]=s[a]);for(const a in i)i[a]!==0&&(r[o]+=a===o?i[a]:i[a]/this.matrix[o][a]);return hV(this.matrix,r),Zu(this,{values:r},!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 r of Object.keys(this.values))e[r]=this.values[r]===0?0:-this.values[r];return Zu(this,{values:e},!0)}removeZeros(){if(!this.isValid)return this;const e=pV(this.values);return Zu(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 r(i,s){return i===void 0||i===0?s===void 0||s===0:i===s}for(const i of Qh)if(!r(this.values[i],e.values[i]))return!1;return!0}};const Mg="Invalid Interval";function kOe(t,e){return!t||!t.isValid?gA.invalid("missing or invalid start"):!e||!e.isValid?gA.invalid("missing or invalid end"):e<t?gA.invalid("end before start",`The end of an interval must be after its start, but you had start=${t.toISO()} and end=${e.toISO()}`):null}let gA=class ti{constructor(e){this.s=e.start,this.e=e.end,this.invalid=e.invalid||null,this.isLuxonInterval=!0}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the Interval is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new nwe(i);return new ti({invalid:i})}static fromDateTimes(e,r){const i=ux(e),s=ux(r);return kOe(i,s)??new ti({start:i,end:s})}static after(e,r){const i=vi.fromDurationLike(r),s=ux(e);return ti.fromDateTimes(s,s.plus(i))}static before(e,r){const i=vi.fromDurationLike(r),s=ux(e);return ti.fromDateTimes(s.minus(i),s)}static fromISO(e,r){const[i,s]=(e||"").split("/",2);if(i&&s){let o,a;try{o=Ur.fromISO(i,r),a=o.isValid}catch{a=!1}let l,u;try{l=Ur.fromISO(s,r),u=l.isValid}catch{u=!1}if(a&&u)return ti.fromDateTimes(o,l);if(a){const c=vi.fromISO(s,r);if(c.isValid)return ti.after(o,c)}else if(u){const c=vi.fromISO(i,r);if(c.isValid)return ti.before(l,c)}}return ti.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",r){if(!this.isValid)return NaN;const i=this.start.startOf(e,r);let s;return r!=null&&r.useLocaleWeeks?s=this.end.reconfigure({locale:i.locale}):s=this.end,s=s.startOf(e,r),Math.floor(s.diff(i,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:r}={}){return this.isValid?ti.fromDateTimes(e||this.s,r||this.e):this}splitAt(...e){if(!this.isValid)return[];const r=e.map(ux).filter(a=>this.contains(a)).sort((a,l)=>a.toMillis()-l.toMillis()),i=[];let{s}=this,o=0;for(;s<this.e;){const a=r[o]||this.e,l=+a>+this.e?this.e:a;i.push(ti.fromDateTimes(s,l)),s=l,o+=1}return i}splitBy(e){const r=vi.fromDurationLike(e);if(!this.isValid||!r.isValid||r.as("milliseconds")===0)return[];let{s:i}=this,s=1,o;const a=[];for(;i<this.e;){const l=this.start.plus(r.mapUnits(u=>u*s));o=+l>+this.e?this.e:l,a.push(ti.fromDateTimes(i,o)),i=o,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 r=this.s>e.s?this.s:e.s,i=this.e<e.e?this.e:e.e;return r>=i?null:ti.fromDateTimes(r,i)}union(e){if(!this.isValid)return this;const r=this.s<e.s?this.s:e.s,i=this.e>e.e?this.e:e.e;return ti.fromDateTimes(r,i)}static merge(e){const[r,i]=e.sort((s,o)=>s.s-o.s).reduce(([s,o],a)=>o?o.overlaps(a)||o.abutsStart(a)?[s,o.union(a)]:[s.concat([o]),a]:[s,a],[[],null]);return i&&r.push(i),r}static xor(e){let r=null,i=0;const s=[],o=e.map(u=>[{time:u.s,type:"s"},{time:u.e,type:"e"}]),a=Array.prototype.concat(...o),l=a.sort((u,c)=>u.time-c.time);for(const u of l)i+=u.type==="s"?1:-1,i===1?r=u.time:(r&&+r!=+u.time&&s.push(ti.fromDateTimes(r,u.time)),r=null);return ti.merge(s)}difference(...e){return ti.xor([this].concat(e)).map(r=>this.intersection(r)).filter(r=>r&&!r.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:Mg}[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=oA,r={}){return this.isValid?va.create(this.s.loc.clone(r),e).formatInterval(this):Mg}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:Mg}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:Mg}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:Mg}toFormat(e,{separator:r=" – "}={}){return this.isValid?`${this.s.toFormat(e)}${r}${this.e.toFormat(e)}`:Mg}toDuration(e,r){return this.isValid?this.e.diff(this.s,e,r):vi.invalid(this.invalidReason)}mapEndpoints(e){return ti.fromDateTimes(e(this.s),e(this.e))}},yA=class{static hasDST(t=Yr.defaultZone){const e=Ur.now().setZone(t).set({month:12});return!t.isUniversal&&e.offset!==e.set({month:6}).offset}static isValidIANAZone(t){return wg.isValidZone(t)}static normalizeZone(t){return Dd(t,Yr.defaultZone)}static getStartOfWeek({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:t=null,locObj:e=null}={}){return(e||Or.create(t)).getWeekendDays().slice()}static months(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null,outputCalendar:s="gregory"}={}){return(i||Or.create(e,r,s)).months(t)}static monthsFormat(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null,outputCalendar:s="gregory"}={}){return(i||Or.create(e,r,s)).months(t,!0)}static weekdays(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null}={}){return(i||Or.create(e,r,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:e=null,numberingSystem:r=null,locObj:i=null}={}){return(i||Or.create(e,r,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Or.create(t).meridiems()}static eras(t="short",{locale:e=null}={}){return Or.create(e,null,"gregory").eras(t)}static features(){return{relative:zG(),localeWeek:QG()}}};function mV(t,e){const r=s=>s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),i=r(e)-r(t);return Math.floor(vi.fromMillis(i).as("days"))}function IOe(t,e,r){const i=[["years",(u,c)=>c.year-u.year],["quarters",(u,c)=>c.quarter-u.quarter+(c.year-u.year)*4],["months",(u,c)=>c.month-u.month+(c.year-u.year)*12],["weeks",(u,c)=>{const d=mV(u,c);return(d-d%7)/7}],["days",mV]],s={},o=t;let a,l;for(const[u,c]of i)r.indexOf(u)>=0&&(a=u,s[u]=c(t,e),l=o.plus(s),l>e?(s[u]--,t=o.plus(s),t>e&&(l=t,s[u]--,t=o.plus(s))):t=l);return[t,s,l,a]}function MOe(t,e,r,i){let[s,o,a,l]=IOe(t,e,r);const u=e-s,c=r.filter(f=>["hours","minutes","seconds","milliseconds"].indexOf(f)>=0);c.length===0&&(a<e&&(a=s.plus({[l]:1})),a!==s&&(o[l]=(o[l]||0)+u/(a-s)));const d=vi.fromObject(o,i);return c.length>0?vi.fromMillis(u,i).shiftTo(...c).plus(d):d}const FOe="missing Intl.DateTimeFormat.formatToParts support";function Yt(t,e=r=>r){return{regex:t,deser:([r])=>e(wwe(r))}}const gV="[ ]",yV=new RegExp(gV,"g");function POe(t){return t.replace(/\./g,"\\.?").replace(yV,gV)}function vV(t){return t.replace(/\./g,"").replace(yV," ").toLowerCase()}function xa(t,e){return t===null?null:{regex:RegExp(t.map(POe).join("|")),deser:([r])=>t.findIndex(i=>vV(r)===vV(i))+e}}function xV(t,e){return{regex:t,deser:([,r,i])=>hA(r,i),groups:e}}function vA(t){return{regex:t,deser:([e])=>e}}function $Oe(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function jOe(t,e){const r=ga(e),i=ga(e,"{2}"),s=ga(e,"{3}"),o=ga(e,"{4}"),a=ga(e,"{6}"),l=ga(e,"{1,2}"),u=ga(e,"{1,3}"),c=ga(e,"{1,6}"),d=ga(e,"{1,9}"),f=ga(e,"{2,4}"),h=ga(e,"{4,6}"),m=y=>({regex:RegExp($Oe(y.val)),deser:([v])=>v,literal:!0}),g=(y=>{if(t.literal)return m(y);switch(y.val){case"G":return xa(e.eras("short"),0);case"GG":return xa(e.eras("long"),0);case"y":return Yt(c);case"yy":return Yt(f,G6);case"yyyy":return Yt(o);case"yyyyy":return Yt(h);case"yyyyyy":return Yt(a);case"M":return Yt(l);case"MM":return Yt(i);case"MMM":return xa(e.months("short",!0),1);case"MMMM":return xa(e.months("long",!0),1);case"L":return Yt(l);case"LL":return Yt(i);case"LLL":return xa(e.months("short",!1),1);case"LLLL":return xa(e.months("long",!1),1);case"d":return Yt(l);case"dd":return Yt(i);case"o":return Yt(u);case"ooo":return Yt(s);case"HH":return Yt(i);case"H":return Yt(l);case"hh":return Yt(i);case"h":return Yt(l);case"mm":return Yt(i);case"m":return Yt(l);case"q":return Yt(l);case"qq":return Yt(i);case"s":return Yt(l);case"ss":return Yt(i);case"S":return Yt(u);case"SSS":return Yt(s);case"u":return vA(d);case"uu":return vA(l);case"uuu":return Yt(r);case"a":return xa(e.meridiems(),0);case"kkkk":return Yt(o);case"kk":return Yt(f,G6);case"W":return Yt(l);case"WW":return Yt(i);case"E":case"c":return Yt(r);case"EEE":return xa(e.weekdays("short",!1),1);case"EEEE":return xa(e.weekdays("long",!1),1);case"ccc":return xa(e.weekdays("short",!0),1);case"cccc":return xa(e.weekdays("long",!0),1);case"Z":case"ZZ":return xV(new RegExp(`([+-]${l.source})(?::(${i.source}))?`),2);case"ZZZ":return xV(new RegExp(`([+-]${l.source})(${i.source})?`),2);case"z":return vA(/[a-z_+-/]{1,256}?/i);case" ":return vA(/[^\S\n\r]/);default:return m(y)}})(t)||{invalidReason:FOe};return g.token=t,g}const UOe={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 qOe(t,e,r){const{type:i,value:s}=t;if(i==="literal"){const u=/^\s+$/.test(s);return{literal:!u,val:u?" ":s}}const o=e[i];let a=i;i==="hour"&&(e.hour12!=null?a=e.hour12?"hour12":"hour24":e.hourCycle!=null?e.hourCycle==="h11"||e.hourCycle==="h12"?a="hour12":a="hour24":a=r.hour12?"hour12":"hour24");let l=UOe[a];if(typeof l=="object"&&(l=l[o]),l)return{literal:!1,val:l}}function BOe(t){return[`^${t.map(e=>e.regex).reduce((e,r)=>`${e}(${r.source})`,"")}$`,t]}function zOe(t,e,r){const i=t.match(e);if(i){const s={};let o=1;for(const a in r)if(Og(r,a)){const l=r[a],u=l.groups?l.groups+1:1;!l.literal&&l.token&&(s[l.token.val[0]]=l.deser(i.slice(o,o+u))),o+=u}return[i,s]}else return[i,{}]}function QOe(t){const e=s=>{switch(s){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 r=null,i;return ot(t.z)||(r=wg.create(t.z)),ot(t.Z)||(r||(r=new Cl(t.Z)),i=t.Z),ot(t.q)||(t.M=(t.q-1)*3+1),ot(t.h)||(t.h<12&&t.a===1?t.h+=12:t.h===12&&t.a===0&&(t.h=0)),t.G===0&&t.y&&(t.y=-t.y),ot(t.u)||(t.S=H6(t.u)),[Object.keys(t).reduce((s,o)=>{const a=e(o);return a&&(s[a]=t[o]),s},{}),r,i]}let J6=null;function HOe(){return J6||(J6=Ur.fromMillis(1555555555555)),J6}function WOe(t,e){if(t.literal)return t;const r=va.macroTokenToFormatOpts(t.val),i=TV(r,e);return i==null||i.includes(void 0)?t:i}function bV(t,e){return Array.prototype.concat(...t.map(r=>WOe(r,e)))}let EV=class{constructor(t,e){if(this.locale=t,this.format=e,this.tokens=bV(va.parseFormat(e),t),this.units=this.tokens.map(r=>jOe(r,t)),this.disqualifyingUnit=this.units.find(r=>r.invalidReason),!this.disqualifyingUnit){const[r,i]=BOe(this.units);this.regex=RegExp(r,"i"),this.handlers=i}}explainFromTokens(t){if(this.isValid){const[e,r]=zOe(t,this.regex,this.handlers),[i,s,o]=r?QOe(r):[null,null,void 0];if(Og(r,"a")&&Og(r,"H"))throw new Ag("Can't include meridiem when specifying 24-hour format");return{input:t,tokens:this.tokens,regex:this.regex,rawMatches:e,matches:r,result:i,zone:s,specificOffset:o}}else return{input:t,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}};function SV(t,e,r){return new EV(t,r).explainFromTokens(e)}function GOe(t,e,r){const{result:i,zone:s,specificOffset:o,invalidReason:a}=SV(t,e,r);return[i,s,o,a]}function TV(t,e){if(!t)return null;const r=va.create(e,t).dtFormatter(HOe()),i=r.formatToParts(),s=r.resolvedOptions();return i.map(o=>qOe(o,t,s))}const X6="Invalid DateTime",_V=864e13;function ax(t){return new ya("unsupported zone",`the zone "${t.name}" is not supported`)}function Z6(t){return t.weekData===null&&(t.weekData=uA(t.c)),t.weekData}function ek(t){return t.localWeekData===null&&(t.localWeekData=uA(t.c,t.loc.getMinDaysInFirstWeek(),t.loc.getStartOfWeek())),t.localWeekData}function Hh(t,e){const r={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new Ur({...r,...e,old:r})}function AV(t,e,r){let i=t-e*60*1e3;const s=r.offset(i);if(e===s)return[i,e];i-=(s-e)*60*1e3;const o=r.offset(i);return s===o?[i,s]:[t-Math.min(s,o)*60*1e3,Math.max(s,o)]}function xA(t,e){t+=e*60*1e3;const r=new Date(t);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function bA(t,e,r){return AV(fA(t),e,r)}function wV(t,e){const r=t.o,i=t.c.year+Math.trunc(e.years),s=t.c.month+Math.trunc(e.months)+Math.trunc(e.quarters)*3,o={...t.c,year:i,month:s,day:Math.min(t.c.day,dA(i,s))+Math.trunc(e.days)+Math.trunc(e.weeks)*7},a=vi.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"),l=fA(o);let[u,c]=AV(l,r,t.zone);return a!==0&&(u+=a,c=t.zone.offset(u)),{ts:u,o:c}}function Fg(t,e,r,i,s,o){const{setZone:a,zone:l}=r;if(t&&Object.keys(t).length!==0||e){const u=e||l,c=Ur.fromObject(t,{...r,zone:u,specificOffset:o});return a?c:c.setZone(l)}else return Ur.invalid(new ya("unparsable",`the input "${s}" can't be parsed as ${i}`))}function EA(t,e,r=!0){return t.isValid?va.create(Or.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(t,e):null}function tk(t,e,r){const i=t.c.year>9999||t.c.year<0;let s="";if(i&&t.c.year>=0&&(s+="+"),s+=yn(t.c.year,i?6:4),r==="year")return s;if(e){if(s+="-",s+=yn(t.c.month),r==="month")return s;s+="-"}else if(s+=yn(t.c.month),r==="month")return s;return s+=yn(t.c.day),s}function OV(t,e,r,i,s,o,a){let l=!r||t.c.millisecond!==0||t.c.second!==0,u="";switch(a){case"day":case"month":case"year":break;default:if(u+=yn(t.c.hour),a==="hour")break;if(e){if(u+=":",u+=yn(t.c.minute),a==="minute")break;l&&(u+=":",u+=yn(t.c.second))}else{if(u+=yn(t.c.minute),a==="minute")break;l&&(u+=yn(t.c.second))}if(a==="second")break;l&&(!i||t.c.millisecond!==0)&&(u+=".",u+=yn(t.c.millisecond,3))}return s&&(t.isOffsetFixed&&t.offset===0&&!o?u+="Z":t.o<0?(u+="-",u+=yn(Math.trunc(-t.o/60)),u+=":",u+=yn(Math.trunc(-t.o%60))):(u+="+",u+=yn(Math.trunc(t.o/60)),u+=":",u+=yn(Math.trunc(t.o%60)))),o&&(u+="["+t.zone.ianaName+"]"),u}const RV={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},VOe={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},YOe={ordinal:1,hour:0,minute:0,second:0,millisecond:0},SA=["year","month","day","hour","minute","second","millisecond"],KOe=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],JOe=["year","ordinal","hour","minute","second","millisecond"];function TA(t){const e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new tG(t);return e}function CV(t){switch(t.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return TA(t)}}function XOe(t){if(lx===void 0&&(lx=Yr.now()),t.type!=="iana")return t.offset(lx);const e=t.name;let r=rk.get(e);return r===void 0&&(r=t.offset(lx),rk.set(e,r)),r}function NV(t,e){const r=Dd(e.zone,Yr.defaultZone);if(!r.isValid)return Ur.invalid(ax(r));const i=Or.fromObject(e);let s,o;if(ot(t.year))s=Yr.now();else{for(const u of SA)ot(t[u])&&(t[u]=RV[u]);const a=qG(t)||BG(t);if(a)return Ur.invalid(a);const l=XOe(r);[s,o]=bA(t,l,r)}return new Ur({ts:s,zone:r,loc:i,o})}function LV(t,e,r){const i=ot(r.round)?!0:r.round,s=ot(r.rounding)?"trunc":r.rounding,o=(l,u)=>(l=W6(l,i||r.calendary?0:2,r.calendary?"round":s),e.loc.clone(r).relFormatter(r).format(l,u)),a=l=>r.calendary?e.hasSame(t,l)?0:e.startOf(l).diff(t.startOf(l),l).get(l):e.diff(t,l).get(l);if(r.unit)return o(a(r.unit),r.unit);for(const l of r.units){const u=a(l);if(Math.abs(u)>=1)return o(u,l)}return o(t>e?-0:0,r.units[r.units.length-1])}function DV(t){let e={},r;return t.length>0&&typeof t[t.length-1]=="object"?(e=t[t.length-1],r=Array.from(t).slice(0,t.length-1)):r=Array.from(t),[e,r]}let lx;const rk=new Map;let Ur=class $r{constructor(e){const r=e.zone||Yr.defaultZone;let i=e.invalid||(Number.isNaN(e.ts)?new ya("invalid input"):null)||(r.isValid?null:ax(r));this.ts=ot(e.ts)?Yr.now():e.ts;let s=null,o=null;if(!i)if(e.old&&e.old.ts===this.ts&&e.old.zone.equals(r))[s,o]=[e.old.c,e.old.o];else{const a=kd(e.o)&&!e.old?e.o:r.offset(this.ts);s=xA(this.ts,a),i=Number.isNaN(s.year)?new ya("invalid input"):null,s=i?null:s,o=i?null:a}this._zone=r,this.loc=e.loc||Or.create(),this.invalid=i,this.weekData=null,this.localWeekData=null,this.c=s,this.o=o,this.isLuxonDateTime=!0}static now(){return new $r({})}static local(){const[e,r]=DV(arguments),[i,s,o,a,l,u,c]=r;return NV({year:i,month:s,day:o,hour:a,minute:l,second:u,millisecond:c},e)}static utc(){const[e,r]=DV(arguments),[i,s,o,a,l,u,c]=r;return e.zone=Cl.utcInstance,NV({year:i,month:s,day:o,hour:a,minute:l,second:u,millisecond:c},e)}static fromJSDate(e,r={}){const i=Lwe(e)?e.valueOf():NaN;if(Number.isNaN(i))return $r.invalid("invalid input");const s=Dd(r.zone,Yr.defaultZone);return s.isValid?new $r({ts:i,zone:s,loc:Or.fromObject(r)}):$r.invalid(ax(s))}static fromMillis(e,r={}){if(kd(e))return e<-_V||e>_V?$r.invalid("Timestamp out of range"):new $r({ts:e,zone:Dd(r.zone,Yr.defaultZone),loc:Or.fromObject(r)});throw new yi(`fromMillis requires a numerical input, but received a ${typeof e} with value ${e}`)}static fromSeconds(e,r={}){if(kd(e))return new $r({ts:e*1e3,zone:Dd(r.zone,Yr.defaultZone),loc:Or.fromObject(r)});throw new yi("fromSeconds requires a numerical input")}static fromObject(e,r={}){e=e||{};const i=Dd(r.zone,Yr.defaultZone);if(!i.isValid)return $r.invalid(ax(i));const s=Or.fromObject(r),o=pA(e,CV),{minDaysInFirstWeek:a,startOfWeek:l}=UG(o,s),u=Yr.now(),c=ot(r.specificOffset)?i.offset(u):r.specificOffset,d=!ot(o.ordinal),f=!ot(o.year),h=!ot(o.month)||!ot(o.day),m=f||h,g=o.weekYear||o.weekNumber;if((m||d)&&g)throw new Ag("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(h&&d)throw new Ag("Can't mix ordinal dates with month/day");const y=g||o.weekday&&!m;let v,x,b=xA(u,c);y?(v=KOe,x=VOe,b=uA(b,a,l)):d?(v=JOe,x=YOe,b=z6(b)):(v=SA,x=RV);let E=!1;for(const L of v){const C=o[L];ot(C)?E?o[L]=x[L]:o[L]=b[L]:E=!0}const S=y?Rwe(o,a,l):d?Cwe(o):qG(o),T=S||BG(o);if(T)return $r.invalid(T);const A=y?$G(o,a,l):d?jG(o):o,[_,O]=bA(A,c,i),R=new $r({ts:_,zone:i,o:O,loc:s});return o.weekday&&m&&e.weekday!==R.weekday?$r.invalid("mismatched weekday",`you can't specify both a weekday of ${o.weekday} and a date of ${R.toISO()}`):R.isValid?R:$r.invalid(R.invalid)}static fromISO(e,r={}){const[i,s]=bOe(e);return Fg(i,s,r,"ISO 8601",e)}static fromRFC2822(e,r={}){const[i,s]=EOe(e);return Fg(i,s,r,"RFC 2822",e)}static fromHTTP(e,r={}){const[i,s]=SOe(e);return Fg(i,s,r,"HTTP",r)}static fromFormat(e,r,i={}){if(ot(e)||ot(r))throw new yi("fromFormat requires an input string and a format");const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0}),[l,u,c,d]=GOe(a,e,r);return d?$r.invalid(d):Fg(l,u,i,`format ${r}`,e,c)}static fromString(e,r,i={}){return $r.fromFormat(e,r,i)}static fromSQL(e,r={}){const[i,s]=COe(e);return Fg(i,s,r,"SQL",e)}static invalid(e,r=null){if(!e)throw new yi("need to specify a reason the DateTime is invalid");const i=e instanceof ya?e:new ya(e,r);if(Yr.throwOnInvalid)throw new rwe(i);return new $r({invalid:i})}static isDateTime(e){return e&&e.isLuxonDateTime||!1}static parseFormatForOpts(e,r={}){const i=TV(e,Or.fromObject(r));return i?i.map(s=>s?s.val:null).join(""):null}static expandFormat(e,r={}){return bV(va.parseFormat(e),Or.fromObject(r)).map(i=>i.val).join("")}static resetCache(){lx=void 0,rk.clear()}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?Z6(this).weekYear:NaN}get weekNumber(){return this.isValid?Z6(this).weekNumber:NaN}get weekday(){return this.isValid?Z6(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?ek(this).weekday:NaN}get localWeekNumber(){return this.isValid?ek(this).weekNumber:NaN}get localWeekYear(){return this.isValid?ek(this).weekYear:NaN}get ordinal(){return this.isValid?z6(this.c).ordinal:NaN}get monthShort(){return this.isValid?yA.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?yA.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?yA.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?yA.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,r=6e4,i=fA(this.c),s=this.zone.offset(i-e),o=this.zone.offset(i+e),a=this.zone.offset(i-s*r),l=this.zone.offset(i-o*r);if(a===l)return[this];const u=i-a*r,c=i-l*r,d=xA(u,a),f=xA(c,l);return d.hour===f.hour&&d.minute===f.minute&&d.second===f.second&&d.millisecond===f.millisecond?[Hh(this,{ts:u}),Hh(this,{ts:c})]:[this]}get isInLeapYear(){return rx(this.year)}get daysInMonth(){return dA(this.year,this.month)}get daysInYear(){return this.isValid?Rg(this.year):NaN}get weeksInWeekYear(){return this.isValid?nx(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?nx(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(e={}){const{locale:r,numberingSystem:i,calendar:s}=va.create(this.loc.clone(e),e).resolvedOptions(this);return{locale:r,numberingSystem:i,outputCalendar:s}}toUTC(e=0,r={}){return this.setZone(Cl.instance(e),r)}toLocal(){return this.setZone(Yr.defaultZone)}setZone(e,{keepLocalTime:r=!1,keepCalendarTime:i=!1}={}){if(e=Dd(e,Yr.defaultZone),e.equals(this.zone))return this;if(e.isValid){let s=this.ts;if(r||i){const o=e.offset(this.ts),a=this.toObject();[s]=bA(a,o,e)}return Hh(this,{ts:s,zone:e})}else return $r.invalid(ax(e))}reconfigure({locale:e,numberingSystem:r,outputCalendar:i}={}){const s=this.loc.clone({locale:e,numberingSystem:r,outputCalendar:i});return Hh(this,{loc:s})}setLocale(e){return this.reconfigure({locale:e})}set(e){if(!this.isValid)return this;const r=pA(e,CV),{minDaysInFirstWeek:i,startOfWeek:s}=UG(r,this.loc),o=!ot(r.weekYear)||!ot(r.weekNumber)||!ot(r.weekday),a=!ot(r.ordinal),l=!ot(r.year),u=!ot(r.month)||!ot(r.day),c=l||u,d=r.weekYear||r.weekNumber;if((c||a)&&d)throw new Ag("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(u&&a)throw new Ag("Can't mix ordinal dates with month/day");let f;o?f=$G({...uA(this.c,i,s),...r},i,s):ot(r.ordinal)?(f={...this.toObject(),...r},ot(r.day)&&(f.day=Math.min(dA(f.year,f.month),f.day))):f=jG({...z6(this.c),...r});const[h,m]=bA(f,this.o,this.zone);return Hh(this,{ts:h,o:m})}plus(e){if(!this.isValid)return this;const r=vi.fromDurationLike(e);return Hh(this,wV(this,r))}minus(e){if(!this.isValid)return this;const r=vi.fromDurationLike(e).negate();return Hh(this,wV(this,r))}startOf(e,{useLocaleWeeks:r=!1}={}){if(!this.isValid)return this;const i={},s=vi.normalizeUnit(e);switch(s){case"years":i.month=1;case"quarters":case"months":i.day=1;case"weeks":case"days":i.hour=0;case"hours":i.minute=0;case"minutes":i.second=0;case"seconds":i.millisecond=0;break}if(s==="weeks")if(r){const o=this.loc.getStartOfWeek(),{weekday:a}=this;a<o&&(i.weekNumber=this.weekNumber-1),i.weekday=o}else i.weekday=1;if(s==="quarters"){const o=Math.ceil(this.month/3);i.month=(o-1)*3+1}return this.set(i)}endOf(e,r){return this.isValid?this.plus({[e]:1}).startOf(e,r).minus(1):this}toFormat(e,r={}){return this.isValid?va.create(this.loc.redefaultToEN(r)).formatDateTimeFromString(this,e):X6}toLocaleString(e=oA,r={}){return this.isValid?va.create(this.loc.clone(r),e).formatDateTime(this):X6}toLocaleParts(e={}){return this.isValid?va.create(this.loc.clone(e),e).formatDateTimeParts(this):[]}toISO({format:e="extended",suppressSeconds:r=!1,suppressMilliseconds:i=!1,includeOffset:s=!0,extendedZone:o=!1,precision:a="milliseconds"}={}){if(!this.isValid)return null;a=TA(a);const l=e==="extended";let u=tk(this,l,a);return SA.indexOf(a)>=3&&(u+="T"),u+=OV(this,l,r,i,s,o,a),u}toISODate({format:e="extended",precision:r="day"}={}){return this.isValid?tk(this,e==="extended",TA(r)):null}toISOWeekDate(){return EA(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:e=!1,suppressSeconds:r=!1,includeOffset:i=!0,includePrefix:s=!1,extendedZone:o=!1,format:a="extended",precision:l="milliseconds"}={}){return this.isValid?(l=TA(l),(s&&SA.indexOf(l)>=3?"T":"")+OV(this,a==="extended",r,e,i,o,l)):null}toRFC2822(){return EA(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return EA(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?tk(this,!0):null}toSQLTime({includeOffset:e=!0,includeZone:r=!1,includeOffsetSpace:i=!0}={}){let s="HH:mm:ss.SSS";return(r||e)&&(i&&(s+=" "),r?s+="z":e&&(s+="ZZ")),EA(this,s,!0)}toSQL(e={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(e)}`:null}toString(){return this.isValid?this.toISO():X6}[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 r={...this.c};return e.includeConfig&&(r.outputCalendar=this.outputCalendar,r.numberingSystem=this.loc.numberingSystem,r.locale=this.loc.locale),r}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(e,r="milliseconds",i={}){if(!this.isValid||!e.isValid)return vi.invalid("created by diffing an invalid DateTime");const s={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=Dwe(r).map(vi.normalizeUnit),a=e.valueOf()>this.valueOf(),l=a?this:e,u=a?e:this,c=MOe(l,u,o,s);return a?c.negate():c}diffNow(e="milliseconds",r={}){return this.diff($r.now(),e,r)}until(e){return this.isValid?gA.fromDateTimes(this,e):this}hasSame(e,r,i){if(!this.isValid)return!1;const s=e.valueOf(),o=this.setZone(e.zone,{keepLocalTime:!0});return o.startOf(r,i)<=s&&s<=o.endOf(r,i)}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 r=e.base||$r.fromObject({},{zone:this.zone}),i=e.padding?this<r?-e.padding:e.padding:0;let s=["years","months","days","hours","minutes","seconds"],o=e.unit;return Array.isArray(e.unit)&&(s=e.unit,o=void 0),LV(r,this.plus(i),{...e,numeric:"always",units:s,unit:o})}toRelativeCalendar(e={}){return this.isValid?LV(e.base||$r.fromObject({},{zone:this.zone}),this,{...e,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...e){if(!e.every($r.isDateTime))throw new yi("min requires all arguments be DateTimes");return HG(e,r=>r.valueOf(),Math.min)}static max(...e){if(!e.every($r.isDateTime))throw new yi("max requires all arguments be DateTimes");return HG(e,r=>r.valueOf(),Math.max)}static fromFormatExplain(e,r,i={}){const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});return SV(a,e,r)}static fromStringExplain(e,r,i={}){return $r.fromFormatExplain(e,r,i)}static buildFormatParser(e,r={}){const{locale:i=null,numberingSystem:s=null}=r,o=Or.fromOpts({locale:i,numberingSystem:s,defaultToEN:!0});return new EV(o,e)}static fromFormatParser(e,r,i={}){if(ot(e)||ot(r))throw new yi("fromFormatParser requires an input string and a format parser");const{locale:s=null,numberingSystem:o=null}=i,a=Or.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});if(!a.equals(r.locale))throw new yi(`fromFormatParser called with a locale of ${a}, but the format parser was created for ${r.locale}`);const{result:l,zone:u,specificOffset:c,invalidReason:d}=r.explainFromTokens(e);return d?$r.invalid(d):Fg(l,u,i,`format ${r.format}`,e,c)}static get DATE_SHORT(){return oA}static get DATE_MED(){return rG}static get DATE_MED_WITH_WEEKDAY(){return swe}static get DATE_FULL(){return nG}static get DATE_HUGE(){return iG}static get TIME_SIMPLE(){return sG}static get TIME_WITH_SECONDS(){return oG}static get TIME_WITH_SHORT_OFFSET(){return aG}static get TIME_WITH_LONG_OFFSET(){return lG}static get TIME_24_SIMPLE(){return uG}static get TIME_24_WITH_SECONDS(){return cG}static get TIME_24_WITH_SHORT_OFFSET(){return dG}static get TIME_24_WITH_LONG_OFFSET(){return fG}static get DATETIME_SHORT(){return hG}static get DATETIME_SHORT_WITH_SECONDS(){return pG}static get DATETIME_MED(){return mG}static get DATETIME_MED_WITH_SECONDS(){return gG}static get DATETIME_MED_WITH_WEEKDAY(){return owe}static get DATETIME_FULL(){return yG}static get DATETIME_FULL_WITH_SECONDS(){return vG}static get DATETIME_HUGE(){return xG}static get DATETIME_HUGE_WITH_SECONDS(){return bG}};function ux(t){if(Ur.isDateTime(t))return t;if(t&&t.valueOf&&kd(t.valueOf()))return Ur.fromJSDate(t);if(t&&typeof t=="object")return Ur.fromObject(t);throw new yi(`Unknown datetime argument: ${t}, of type ${typeof t}`)}function Md(t,e,r=!1){if(t!==void 0)switch(t){case"ordinal":return{range:["#C2D5EE","#1A73E8"]};case"temporal":case"quantitative":return e?r?{range:["#6BA4EE","#EEA361"]}:{range:["#1A73E8","#E8710A"]}:{range:["#C2D5EE","#1A73E8"]};case"nominal":return r?{range:["#6BA4EE","#66CEDC","#EC72B8","#EEA361","#F9C85B","#AACD85","#B87CED","#ACB0B3"]}:{range:["#1A73E8","#12B5CB","#E52592","#E8710A","#F9AB00","#7CB342","#9334E6","#80868B"]}}}function Rr(t,e){return t.toString().padStart(e,"0")}function _A(t,e,r){e||(e="second");const i=Ur.fromJSDate(t,{zone:r??"UTC"});switch(e){case"year":return`${Rr(i.year,4)}`;case"quarter":{const s=Rr(i.year,4),o=Math.floor(i.month/3)+1;return`${s}-Q${o}`}case"month":{const s=Rr(i.year,2),o=Rr(i.month,2);return`${s}-${o}`}case"week":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2);return`${s}-${o}-${a}-WK`}case"day":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2);return`${s}-${o}-${a}`}case"hour":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2);return`${s}-${o}-${a} ${l}`}case"minute":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2),u=Rr(i.minute,2);return`${s}-${o}-${a} ${l}:${u}`}case"second":{const s=Rr(i.year,2),o=Rr(i.month,2),a=Rr(i.day,2),l=Rr(i.hour,2),u=Rr(i.minute,2),c=Rr(i.second,2);return`${s}-${o}-${a} ${l}:${u}:${c}`}default:throw new Error("Unknown timeframe.")}}function ZOe(t,e){const r=Ur.fromJSDate(t,{zone:e??"UTC"});return new Date(r.year,r.month-1,r.day,r.hour,r.minute,r.second,r.millisecond)}let nk;const eRe=100;async function AA(){const t=Date.now();if(!(nk&&t<nk+eRe))return nk=t,new Promise(e=>{setTimeout(e,0)})}function Co(t,e){const r=t.createElement("span");return r.classList.add("error"),r.appendChild(t.createTextNode(typeof e=="string"?e:e.message)),r}function cx(t){const e=t.createElement("span");return e.appendChild(t.createTextNode("∅")),e.classList.add("value-null"),e}function kV(t){const e=t.createElement("div");return e.classList.add("drill-icon"),e.innerHTML=`
|
|
2
2
|
<style>
|
|
3
3
|
.drill-icon:hover .copy-circle {
|
|
4
4
|
fill: #eef7f9;
|