@genspectrum/dashboard-components 0.18.5 → 0.19.0
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/README.md +12 -2
- package/custom-elements.json +3 -3
- package/dist/assets/{mutationOverTimeWorker--b8ZHlji.js.map → mutationOverTimeWorker-ChQTFL68.js.map} +1 -1
- package/dist/components.d.ts +15 -14
- package/dist/components.js +1602 -332
- package/dist/components.js.map +1 -1
- package/dist/util.d.ts +14 -14
- package/package.json +3 -4
- package/src/preact/MutationAnnotationsContext.tsx +34 -27
- package/src/preact/components/dropdown.tsx +1 -1
- package/src/preact/components/info.tsx +1 -2
- package/src/preact/components/min-max-range-slider.tsx +0 -2
- package/src/preact/components/mutations-over-time-text-filter.stories.tsx +57 -0
- package/src/preact/components/mutations-over-time-text-filter.tsx +63 -0
- package/src/preact/components/segment-selector.tsx +1 -1
- package/src/preact/components/table.tsx +0 -2
- package/src/preact/dateRangeFilter/date-picker.tsx +15 -10
- package/src/preact/mutationFilter/mutation-filter.stories.tsx +169 -50
- package/src/preact/mutationFilter/mutation-filter.tsx +239 -234
- package/src/preact/mutationFilter/parseAndValidateMutation.ts +62 -10
- package/src/preact/mutationFilter/parseMutation.spec.ts +62 -47
- package/src/preact/mutationsOverTime/getFilteredMutationsOverTime.spec.ts +128 -0
- package/src/preact/mutationsOverTime/getFilteredMutationsOverTimeData.ts +39 -2
- package/src/preact/mutationsOverTime/mutations-over-time-grid.tsx +8 -11
- package/src/preact/mutationsOverTime/mutations-over-time.stories.tsx +27 -0
- package/src/preact/mutationsOverTime/mutations-over-time.tsx +26 -5
- package/src/preact/shared/tanstackTable/pagination-context.tsx +30 -0
- package/src/preact/shared/tanstackTable/pagination.tsx +19 -6
- package/src/preact/shared/tanstackTable/tanstackTable.tsx +17 -3
- package/src/preact/wastewater/mutationsOverTime/wastewater-mutations-over-time.stories.tsx +19 -1
- package/src/preact/wastewater/mutationsOverTime/wastewater-mutations-over-time.tsx +6 -1
- package/src/styles/replaceCssProperties.stories.tsx +49 -0
- package/src/styles/replaceCssProperties.ts +25 -0
- package/src/styles/tailwind.css +1 -0
- package/src/web-components/PreactLitAdapter.tsx +6 -3
- package/src/web-components/PreactLitAdapterWithGridJsStyles.tsx +0 -2
- package/src/web-components/gs-app.stories.ts +6 -2
- package/src/web-components/gs-app.ts +4 -1
- package/src/web-components/input/gs-date-range-filter.tsx +6 -0
- package/src/web-components/input/gs-mutation-filter.stories.ts +4 -4
- package/src/web-components/visualization/gs-prevalence-over-time.stories.ts +1 -1
- package/standalone-bundle/assets/mutationOverTimeWorker-jChgWnwp.js.map +1 -1
- package/standalone-bundle/dashboard-components.js +10836 -11289
- package/standalone-bundle/dashboard-components.js.map +1 -1
- package/dist/style.css +0 -392
- package/standalone-bundle/style.css +0 -1
package/dist/components.js
CHANGED
|
@@ -620,7 +620,9 @@ AppComponent = __decorateClass$g([
|
|
|
620
620
|
t$3("gs-app")
|
|
621
621
|
], AppComponent);
|
|
622
622
|
function GsAppError(error) {
|
|
623
|
-
return html
|
|
623
|
+
return html`<div style="padding: 0.5rem; border: solid red; background-color: lightcoral; border-radius: 0.5rem;">
|
|
624
|
+
Error in gs-app: ${error}
|
|
625
|
+
</div>`;
|
|
624
626
|
}
|
|
625
627
|
var f$1 = 0;
|
|
626
628
|
function u$1(e2, t2, n3, o2, i2, u2) {
|
|
@@ -843,7 +845,7 @@ const InfoHeadline2 = ({ children }) => {
|
|
|
843
845
|
return /* @__PURE__ */ u$1("h2", { className: "text-justify text-base font-bold mt-4", children });
|
|
844
846
|
};
|
|
845
847
|
const InfoParagraph = ({ children }) => {
|
|
846
|
-
return /* @__PURE__ */ u$1("p", { className: "text-justify text-base font-normal my-1", children });
|
|
848
|
+
return /* @__PURE__ */ u$1("p", { className: "text-justify text-base font-normal my-1 text-wrap", children });
|
|
847
849
|
};
|
|
848
850
|
const InfoLink = ({ children, href }) => {
|
|
849
851
|
return /* @__PURE__ */ u$1("a", { className: "text-blue-600 hover:text-blue-800", href, target: "_blank", rel: "noopener noreferrer", children });
|
|
@@ -901,7 +903,6 @@ function generateFullExampleCode(componentCode, componentName) {
|
|
|
901
903
|
return `<html>
|
|
902
904
|
<head>
|
|
903
905
|
<script type="module" src="https://unpkg.com/@genspectrum/dashboard-components@latest/standalone-bundle/dashboard-components.js"><\/script>
|
|
904
|
-
<link rel="stylesheet" href="https://unpkg.com/@genspectrum/dashboard-components@latest/dist/style.css" />
|
|
905
906
|
</head>
|
|
906
907
|
|
|
907
908
|
<body>
|
|
@@ -1069,43 +1070,46 @@ const MutationAnnotationsContextProvider = ({ value, children }) => {
|
|
|
1069
1070
|
if (!parseResult2.success) {
|
|
1070
1071
|
return parseResult2;
|
|
1071
1072
|
}
|
|
1072
|
-
|
|
1073
|
-
const nucleotidePositions = /* @__PURE__ */ new Map();
|
|
1074
|
-
const aminoAcidMap = /* @__PURE__ */ new Map();
|
|
1075
|
-
const aminoAcidPositions = /* @__PURE__ */ new Map();
|
|
1076
|
-
value.forEach((annotation) => {
|
|
1077
|
-
new Set(annotation.nucleotideMutations).forEach((code) => {
|
|
1078
|
-
addAnnotationToMap(nucleotideMap, code, annotation);
|
|
1079
|
-
});
|
|
1080
|
-
new Set(annotation.aminoAcidMutations).forEach((code) => {
|
|
1081
|
-
addAnnotationToMap(aminoAcidMap, code, annotation);
|
|
1082
|
-
});
|
|
1083
|
-
new Set(annotation.nucleotidePositions).forEach((position) => {
|
|
1084
|
-
addAnnotationToMap(nucleotidePositions, position, annotation);
|
|
1085
|
-
});
|
|
1086
|
-
new Set(annotation.aminoAcidPositions).forEach((position) => {
|
|
1087
|
-
addAnnotationToMap(aminoAcidPositions, position, annotation);
|
|
1088
|
-
});
|
|
1089
|
-
});
|
|
1090
|
-
return {
|
|
1091
|
-
success: true,
|
|
1092
|
-
value: {
|
|
1093
|
-
nucleotide: { mutation: nucleotideMap, position: nucleotidePositions },
|
|
1094
|
-
"amino acid": { mutation: aminoAcidMap, position: aminoAcidPositions }
|
|
1095
|
-
}
|
|
1096
|
-
};
|
|
1073
|
+
return { success: true, value: getMutationAnnotationsContext(value) };
|
|
1097
1074
|
}, [value]);
|
|
1098
1075
|
if (!parseResult.success) {
|
|
1099
1076
|
return /* @__PURE__ */ u$1(ResizeContainer, { size: { width: "100%" }, children: /* @__PURE__ */ u$1(ErrorDisplay, { error: parseResult.error, layout: "vertical" }) });
|
|
1100
1077
|
}
|
|
1101
1078
|
return /* @__PURE__ */ u$1(MutationAnnotationsContext.Provider, { value: parseResult.value, children });
|
|
1102
1079
|
};
|
|
1080
|
+
function getMutationAnnotationsContext(value) {
|
|
1081
|
+
const nucleotideMap = /* @__PURE__ */ new Map();
|
|
1082
|
+
const nucleotidePositions = /* @__PURE__ */ new Map();
|
|
1083
|
+
const aminoAcidMap = /* @__PURE__ */ new Map();
|
|
1084
|
+
const aminoAcidPositions = /* @__PURE__ */ new Map();
|
|
1085
|
+
value.forEach((annotation) => {
|
|
1086
|
+
new Set(annotation.nucleotideMutations).forEach((code) => {
|
|
1087
|
+
addAnnotationToMap(nucleotideMap, code, annotation);
|
|
1088
|
+
});
|
|
1089
|
+
new Set(annotation.aminoAcidMutations).forEach((code) => {
|
|
1090
|
+
addAnnotationToMap(aminoAcidMap, code, annotation);
|
|
1091
|
+
});
|
|
1092
|
+
new Set(annotation.nucleotidePositions).forEach((position) => {
|
|
1093
|
+
addAnnotationToMap(nucleotidePositions, position, annotation);
|
|
1094
|
+
});
|
|
1095
|
+
new Set(annotation.aminoAcidPositions).forEach((position) => {
|
|
1096
|
+
addAnnotationToMap(aminoAcidPositions, position, annotation);
|
|
1097
|
+
});
|
|
1098
|
+
});
|
|
1099
|
+
return {
|
|
1100
|
+
nucleotide: { mutation: nucleotideMap, position: nucleotidePositions },
|
|
1101
|
+
"amino acid": { mutation: aminoAcidMap, position: aminoAcidPositions }
|
|
1102
|
+
};
|
|
1103
|
+
}
|
|
1103
1104
|
function addAnnotationToMap(map2, code, annotation) {
|
|
1104
1105
|
const oldAnnotations = map2.get(code.toUpperCase()) ?? [];
|
|
1105
1106
|
map2.set(code.toUpperCase(), [...oldAnnotations, annotation]);
|
|
1106
1107
|
}
|
|
1107
1108
|
function useMutationAnnotationsProvider() {
|
|
1108
1109
|
const mutationAnnotations = x$1(MutationAnnotationsContext);
|
|
1110
|
+
return getMutationAnnotationsProvider(mutationAnnotations);
|
|
1111
|
+
}
|
|
1112
|
+
function getMutationAnnotationsProvider(mutationAnnotations) {
|
|
1109
1113
|
return (mutation, sequenceType) => {
|
|
1110
1114
|
const position = mutation.segment === void 0 ? `${mutation.position}` : `${mutation.segment.toUpperCase()}:${mutation.position}`;
|
|
1111
1115
|
const possiblePositionAnnotations = mutationAnnotations[sequenceType].position.get(position);
|
|
@@ -1912,7 +1916,7 @@ const Dropdown = ({ children, buttonTitle, placement }) => {
|
|
|
1912
1916
|
setShowContent(!showContent);
|
|
1913
1917
|
};
|
|
1914
1918
|
return /* @__PURE__ */ u$1(Fragment, { children: [
|
|
1915
|
-
/* @__PURE__ */ u$1("button", { type: "button", className: "btn btn-xs whitespace-nowrap w-full", onClick: toggle, ref: referenceRef, children: buttonTitle }),
|
|
1919
|
+
/* @__PURE__ */ u$1("button", { type: "button", className: "btn btn-xs whitespace-nowrap w-full", onClick: toggle, ref: referenceRef, children: /* @__PURE__ */ u$1("span", { className: "w-full truncate", children: buttonTitle }) }),
|
|
1916
1920
|
/* @__PURE__ */ u$1("div", { ref: floatingRef, className: `${dropdownClass} ${showContent ? "" : "hidden"}`, children })
|
|
1917
1921
|
] });
|
|
1918
1922
|
};
|
|
@@ -2207,7 +2211,7 @@ const SegmentSelector = ({
|
|
|
2207
2211
|
if (displayedSegments.length <= 1) {
|
|
2208
2212
|
return null;
|
|
2209
2213
|
}
|
|
2210
|
-
return /* @__PURE__ */ u$1("div", { className: "w-
|
|
2214
|
+
return /* @__PURE__ */ u$1("div", { className: "w-24 inline-flex", children: /* @__PURE__ */ u$1(
|
|
2211
2215
|
CheckboxSelector,
|
|
2212
2216
|
{
|
|
2213
2217
|
items: displayedSegments,
|
|
@@ -2461,8 +2465,20 @@ const MutationComparisonInfo = ({ originalComponentProps }) => {
|
|
|
2461
2465
|
};
|
|
2462
2466
|
const gridJsStyle = '.gridjs-head button, .gridjs-footer button {\n cursor: pointer;\n background-color: transparent;\n background-image: none;\n padding: 0;\n margin: 0;\n border: none;\n outline: none;\n}\n\n.gridjs-temp {\n position: relative;\n}\n\n.gridjs-head {\n width: 100%;\n margin-bottom: 5px;\n padding: 5px 1px;\n}\n.gridjs-head::after {\n content: "";\n display: block;\n clear: both;\n}\n.gridjs-head:empty {\n padding: 0;\n border: none;\n}\n\n.gridjs-container {\n overflow: hidden;\n display: inline-block;\n padding: 2px;\n color: #000;\n position: relative;\n z-index: 0;\n}\n\n.gridjs-footer {\n display: block;\n position: relative;\n width: 100%;\n z-index: 5;\n padding: 12px 24px;\n border-top: 1px solid #e5e7eb;\n background-color: #fff;\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.26);\n border-radius: 0 0 8px 8px;\n border-bottom-width: 1px;\n border-color: #e5e7eb;\n}\n.gridjs-footer:empty {\n padding: 0;\n border: none;\n}\n\ninput.gridjs-input {\n outline: none;\n background-color: #fff;\n border: 1px solid #d2d6dc;\n border-radius: 5px;\n padding: 10px 13px;\n font-size: 14px;\n line-height: 1.45;\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n}\ninput.gridjs-input:focus {\n box-shadow: 0 0 0 3px rgba(149, 189, 243, 0.5);\n border-color: #9bc2f7;\n}\n\n.gridjs-pagination {\n color: #3d4044;\n}\n.gridjs-pagination::after {\n content: "";\n display: block;\n clear: both;\n}\n.gridjs-pagination .gridjs-summary {\n float: left;\n margin-top: 5px;\n}\n.gridjs-pagination .gridjs-pages {\n float: right;\n}\n.gridjs-pagination .gridjs-pages button {\n padding: 5px 14px;\n border: 1px solid #d2d6dc;\n background-color: #fff;\n border-right: none;\n outline: none;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n}\n.gridjs-pagination .gridjs-pages button:focus {\n box-shadow: 0 0 0 2px rgba(149, 189, 243, 0.5);\n position: relative;\n margin-right: -1px;\n border-right: 1px solid #d2d6dc;\n}\n.gridjs-pagination .gridjs-pages button:hover {\n background-color: #f7f7f7;\n color: rgb(60, 66, 87);\n outline: none;\n}\n.gridjs-pagination .gridjs-pages button:disabled,\n.gridjs-pagination .gridjs-pages button[disabled],\n.gridjs-pagination .gridjs-pages button:hover:disabled {\n cursor: default;\n background-color: #fff;\n color: #6b7280;\n}\n.gridjs-pagination .gridjs-pages button.gridjs-spread {\n cursor: default;\n box-shadow: none;\n background-color: #fff;\n}\n.gridjs-pagination .gridjs-pages button.gridjs-currentPage {\n background-color: #f7f7f7;\n font-weight: bold;\n}\n.gridjs-pagination .gridjs-pages button:last-child {\n border-bottom-right-radius: 6px;\n border-top-right-radius: 6px;\n border-right: 1px solid #d2d6dc;\n}\n.gridjs-pagination .gridjs-pages button:first-child {\n border-bottom-left-radius: 6px;\n border-top-left-radius: 6px;\n}\n.gridjs-pagination .gridjs-pages button:last-child:focus {\n margin-right: 0;\n}\n\nbutton.gridjs-sort {\n float: right;\n height: 24px;\n width: 13px;\n background-color: transparent;\n background-repeat: no-repeat;\n background-position-x: center;\n cursor: pointer;\n padding: 0;\n margin: 0;\n border: none;\n outline: none;\n background-size: contain;\n}\nbutton.gridjs-sort-neutral {\n opacity: 0.3;\n background-image: url("data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJDYXBhXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHdpZHRoPSI0MDEuOTk4cHgiIGhlaWdodD0iNDAxLjk5OHB4IiB2aWV3Qm94PSIwIDAgNDAxLjk5OCA0MDEuOTk4IiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCA0MDEuOTk4IDQwMS45OTg7IgoJIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8Zz4KCTxnPgoJCTxwYXRoIGQ9Ik03My4wOTIsMTY0LjQ1MmgyNTUuODEzYzQuOTQ5LDAsOS4yMzMtMS44MDcsMTIuODQ4LTUuNDI0YzMuNjEzLTMuNjE2LDUuNDI3LTcuODk4LDUuNDI3LTEyLjg0NwoJCQljMC00Ljk0OS0xLjgxMy05LjIyOS01LjQyNy0xMi44NUwyMTMuODQ2LDUuNDI0QzIxMC4yMzIsMS44MTIsMjA1Ljk1MSwwLDIwMC45OTksMHMtOS4yMzMsMS44MTItMTIuODUsNS40MjRMNjAuMjQyLDEzMy4zMzEKCQkJYy0zLjYxNywzLjYxNy01LjQyNCw3LjkwMS01LjQyNCwxMi44NWMwLDQuOTQ4LDEuODA3LDkuMjMxLDUuNDI0LDEyLjg0N0M2My44NjMsMTYyLjY0NSw2OC4xNDQsMTY0LjQ1Miw3My4wOTIsMTY0LjQ1MnoiLz4KCQk8cGF0aCBkPSJNMzI4LjkwNSwyMzcuNTQ5SDczLjA5MmMtNC45NTIsMC05LjIzMywxLjgwOC0xMi44NSw1LjQyMWMtMy42MTcsMy42MTctNS40MjQsNy44OTgtNS40MjQsMTIuODQ3CgkJCWMwLDQuOTQ5LDEuODA3LDkuMjMzLDUuNDI0LDEyLjg0OEwxODguMTQ5LDM5Ni41N2MzLjYyMSwzLjYxNyw3LjkwMiw1LjQyOCwxMi44NSw1LjQyOHM5LjIzMy0xLjgxMSwxMi44NDctNS40MjhsMTI3LjkwNy0xMjcuOTA2CgkJCWMzLjYxMy0zLjYxNCw1LjQyNy03Ljg5OCw1LjQyNy0xMi44NDhjMC00Ljk0OC0xLjgxMy05LjIyOS01LjQyNy0xMi44NDdDMzM4LjEzOSwyMzkuMzUzLDMzMy44NTQsMjM3LjU0OSwzMjguOTA1LDIzNy41NDl6Ii8+Cgk8L2c+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPC9zdmc+");\n background-position-y: center;\n}\nbutton.gridjs-sort-asc {\n background-image: url("data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJDYXBhXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHdpZHRoPSIyOTIuMzYycHgiIGhlaWdodD0iMjkyLjM2MXB4IiB2aWV3Qm94PSIwIDAgMjkyLjM2MiAyOTIuMzYxIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAyOTIuMzYyIDI5Mi4zNjE7IgoJIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8Zz4KCTxwYXRoIGQ9Ik0yODYuOTM1LDE5Ny4yODdMMTU5LjAyOCw2OS4zODFjLTMuNjEzLTMuNjE3LTcuODk1LTUuNDI0LTEyLjg0Ny01LjQyNHMtOS4yMzMsMS44MDctMTIuODUsNS40MjRMNS40MjQsMTk3LjI4NwoJCUMxLjgwNywyMDAuOTA0LDAsMjA1LjE4NiwwLDIxMC4xMzRzMS44MDcsOS4yMzMsNS40MjQsMTIuODQ3YzMuNjIxLDMuNjE3LDcuOTAyLDUuNDI1LDEyLjg1LDUuNDI1aDI1NS44MTMKCQljNC45NDksMCw5LjIzMy0xLjgwOCwxMi44NDgtNS40MjVjMy42MTMtMy42MTMsNS40MjctNy44OTgsNS40MjctMTIuODQ3UzI5MC41NDgsMjAwLjkwNCwyODYuOTM1LDE5Ny4yODd6Ii8+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPC9zdmc+");\n background-position-y: 35%;\n background-size: 10px;\n}\nbutton.gridjs-sort-desc {\n background-image: url("data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJDYXBhXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHdpZHRoPSIyOTIuMzYycHgiIGhlaWdodD0iMjkyLjM2MnB4IiB2aWV3Qm94PSIwIDAgMjkyLjM2MiAyOTIuMzYyIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAyOTIuMzYyIDI5Mi4zNjI7IgoJIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8Zz4KCTxwYXRoIGQ9Ik0yODYuOTM1LDY5LjM3N2MtMy42MTQtMy42MTctNy44OTgtNS40MjQtMTIuODQ4LTUuNDI0SDE4LjI3NGMtNC45NTIsMC05LjIzMywxLjgwNy0xMi44NSw1LjQyNAoJCUMxLjgwNyw3Mi45OTgsMCw3Ny4yNzksMCw4Mi4yMjhjMCw0Ljk0OCwxLjgwNyw5LjIyOSw1LjQyNCwxMi44NDdsMTI3LjkwNywxMjcuOTA3YzMuNjIxLDMuNjE3LDcuOTAyLDUuNDI4LDEyLjg1LDUuNDI4CgkJczkuMjMzLTEuODExLDEyLjg0Ny01LjQyOEwyODYuOTM1LDk1LjA3NGMzLjYxMy0zLjYxNyw1LjQyNy03Ljg5OCw1LjQyNy0xMi44NDdDMjkyLjM2Miw3Ny4yNzksMjkwLjU0OCw3Mi45OTgsMjg2LjkzNSw2OS4zNzd6Ii8+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPGc+CjwvZz4KPC9zdmc+");\n background-position-y: 65%;\n background-size: 10px;\n}\nbutton.gridjs-sort:focus {\n outline: none;\n}\n\ntable.gridjs-table {\n width: 100%;\n max-width: 100%;\n border-collapse: collapse;\n text-align: left;\n display: table;\n margin: 0;\n padding: 0;\n overflow: auto;\n table-layout: fixed;\n}\n\n.gridjs-tbody {\n background-color: #fff;\n}\n\ntd.gridjs-td {\n border: 1px solid #e5e7eb;\n padding: 12px 24px;\n background-color: #fff;\n box-sizing: content-box;\n}\ntd.gridjs-td:first-child {\n border-left: none;\n}\ntd.gridjs-td:last-child {\n border-right: none;\n}\ntd.gridjs-message {\n text-align: center;\n}\n\nth.gridjs-th {\n position: relative;\n color: #6b7280;\n background-color: #f9fafb;\n border: 1px solid #e5e7eb;\n border-top: none;\n padding: 14px 24px;\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n box-sizing: border-box;\n white-space: nowrap;\n outline: none;\n vertical-align: middle;\n}\nth.gridjs-th .gridjs-th-content {\n text-overflow: ellipsis;\n overflow: hidden;\n width: 100%;\n float: left;\n}\nth.gridjs-th-sort {\n cursor: pointer;\n}\nth.gridjs-th-sort .gridjs-th-content {\n width: calc(100% - 15px);\n}\nth.gridjs-th-sort:hover {\n background-color: #e5e7eb;\n}\nth.gridjs-th-sort:focus {\n background-color: #e5e7eb;\n}\nth.gridjs-th-fixed {\n position: sticky;\n box-shadow: 0 1px 0 0 #e5e7eb;\n}\n@supports (-moz-appearance: none) {\n th.gridjs-th-fixed {\n box-shadow: 0 0 0 1px #e5e7eb;\n }\n}\nth.gridjs-th:first-child {\n border-left: none;\n}\nth.gridjs-th:last-child {\n border-right: none;\n}\n\n.gridjs-tr {\n border: none;\n}\n.gridjs-tr-selected td {\n background-color: #ebf5ff;\n}\n.gridjs-tr:last-child td {\n border-bottom: 0;\n}\n\n.gridjs *,\n.gridjs :after,\n.gridjs :before {\n box-sizing: border-box;\n}\n\n.gridjs-wrapper {\n position: relative;\n z-index: 1;\n overflow: auto;\n width: 100%;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.26);\n border-radius: 8px 8px 0 0;\n display: block;\n border-top-width: 1px;\n border-color: #e5e7eb;\n}\n.gridjs-wrapper:nth-last-of-type(2) {\n border-radius: 8px;\n border-bottom-width: 1px;\n}\n\n.gridjs-search {\n float: left;\n}\n.gridjs-search-input {\n width: 250px;\n}\n\n.gridjs-loading-bar {\n z-index: 10;\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n background-color: #fff;\n opacity: 0.5;\n}\n.gridjs-loading-bar::after {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n transform: translateX(-100%);\n background-image: linear-gradient(90deg, rgba(204, 204, 204, 0) 0, rgba(204, 204, 204, 0.2) 20%, rgba(204, 204, 204, 0.5) 60%, rgba(204, 204, 204, 0));\n animation: shimmer 2s infinite;\n content: "";\n}\n@keyframes shimmer {\n 100% {\n transform: translateX(100%);\n }\n}\n\n.gridjs-td .gridjs-checkbox {\n display: block;\n margin: auto;\n cursor: pointer;\n}\n\n.gridjs-resizable {\n position: absolute;\n top: 0;\n bottom: 0;\n right: 0;\n width: 5px;\n}\n.gridjs-resizable:hover {\n cursor: ew-resize;\n background-color: #9bc2f7;\n}\n/*# sourceMappingURL=mermaid.css?inline.map */';
|
|
2463
2467
|
const minMaxPercentSliderCss = 'input[type=range]::-webkit-slider-thumb {\n -webkit-appearance: none;\n pointer-events: all;\n width: 24px;\n height: 24px;\n background-color: #fff;\n border-radius: 50%;\n box-shadow: 0 0 0 1px #C6C6C6;\n cursor: pointer;\n}\n\ninput[type=range]::-moz-range-thumb {\n -webkit-appearance: none;\n pointer-events: all;\n width: 24px;\n height: 24px;\n background-color: #fff;\n border-radius: 50%;\n box-shadow: 0 0 0 1px #C6C6C6;\n cursor: pointer;\n}\n\ninput[type=range]::-webkit-slider-thumb:hover {\n background: #f7f7f7;\n}\n\ninput[type=range]::-webkit-slider-thumb:active {\n box-shadow: inset 0 0 3px #387bbe, 0 0 9px #387bbe;\n -webkit-box-shadow: inset 0 0 3px #387bbe, 0 0 9px #387bbe;\n}\n\ninput[type="range"] {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n height: 2px;\n width: 100%;\n position: absolute;\n background-color: #C6C6C6;\n pointer-events: none;\n}';
|
|
2464
|
-
|
|
2465
|
-
@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-200:oklch(.885 .062 18.334);--color-red-600:oklch(.577 .245 27.325);--color-red-700:oklch(.505 .213 27.518);--color-blue-300:oklch(.809 .105 251.813);--color-blue-600:oklch(.546 .245 262.881);--color-blue-700:oklch(.488 .243 264.376);--color-blue-800:oklch(.424 .199 265.638);--color-slate-200:oklch(.929 .013 255.508);--color-slate-500:oklch(.554 .046 257.417);--color-gray-100:oklch(.967 .003 264.542);--color-gray-200:oklch(.928 .006 264.531);--color-gray-300:oklch(.872 .01 258.338);--color-gray-400:oklch(.707 .022 261.325);--color-gray-500:oklch(.551 .027 264.364);--color-gray-600:oklch(.446 .03 256.802);--color-gray-700:oklch(.373 .034 259.733);--color-neutral-500:oklch(.556 0 0);--color-black:#000;--color-white:#fff;--spacing:.25rem;--breakpoint-lg:64rem;--container-5xl:64rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5/2.25);--font-weight-normal:400;--font-weight-medium:500;--font-weight-bold:700;--radius-sm:.25rem;--radius-md:.375rem;--radius-lg:.5rem;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-font-feature-settings:var(--font-sans--font-feature-settings);--default-font-variation-settings:var(--font-sans--font-variation-settings);--default-mono-font-family:var(--font-mono);--default-mono-font-feature-settings:var(--font-mono--font-feature-settings);--default-mono-font-variation-settings:var(--font-mono--font-variation-settings)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}body{line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::-moz-placeholder{opacity:1;color:color-mix(in oklab,currentColor 50%,transparent)}::placeholder{opacity:1;color:color-mix(in oklab,currentColor 50%,transparent)}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;-moz-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;-moz-appearance:button;appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}:where(:root),:root:has(input.theme-controller[value=light]:checked),[data-theme=light]{color-scheme:light;--color-base-100:oklch(100% 0 0);--color-base-200:oklch(98% 0 0);--color-base-300:oklch(95% 0 0);--color-base-content:oklch(21% .006 285.885);--color-primary:oklch(45% .24 277.023);--color-primary-content:oklch(93% .034 272.788);--color-secondary:oklch(65% .241 354.308);--color-secondary-content:oklch(94% .028 342.258);--color-accent:oklch(77% .152 181.912);--color-accent-content:oklch(38% .063 188.416);--color-neutral:oklch(14% .005 285.823);--color-neutral-content:oklch(92% .004 286.32);--color-info:oklch(74% .16 232.661);--color-info-content:oklch(29% .066 243.157);--color-success:oklch(76% .177 163.223);--color-success-content:oklch(37% .077 168.94);--color-warning:oklch(82% .189 84.429);--color-warning-content:oklch(41% .112 45.904);--color-error:oklch(71% .194 13.428);--color-error-content:oklch(27% .105 12.094);--radius-selector:.5rem;--radius-field:.25rem;--radius-box:.5rem;--size-selector:.25rem;--size-field:.25rem;--border:1px;--depth:1;--noise:0}@property --radialprogress{syntax: "<percentage>"; inherits: true; initial-value: 0%;}:root{scrollbar-color:color-mix(in oklch,currentColor 35%,#0000)#0000}:root:has(.modal-open,.modal[open],.modal:target,.modal-toggle:checked,.drawer:not([class*=drawer-open])>.drawer-toggle:checked){overflow:hidden}:root,[data-theme]{background-color:var(--root-bg,var(--color-base-100));color:var(--color-base-content)}:root{--fx-noise:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.34' numOctaves='4' stitchTiles='stitch'%3E%3C/feTurbulence%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)' opacity='0.2'%3E%3C/rect%3E%3C/svg%3E")}.chat{--mask-chat:url("data:image/svg+xml,%3csvg width='13' height='13' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill='black' d='M0 11.5004C0 13.0004 2 13.0004 2 13.0004H12H13V0.00036329L12.5 0C12.5 0 11.977 2.09572 11.8581 2.50033C11.6075 3.35237 10.9149 4.22374 9 5.50036C6 7.50036 0 10.0004 0 11.5004Z'/%3e%3c/svg%3e")}:where(:root:has(.modal-open,.modal[open],.modal:target,.modal-toggle:checked,.drawer:not(.drawer-open)>.drawer-toggle:checked)){scrollbar-gutter:stable;background-image:linear-gradient(var(--color-base-100),var(--color-base-100));--root-bg:color-mix(in srgb,var(--color-base-100),oklch(0% 0 0) 40%)}}@layer components;@layer utilities{.diff{webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;direction:ltr;grid-template-columns:auto 1fr;width:100%;display:grid;position:relative;overflow:hidden;container-type:inline-size}.diff:focus-visible,.diff:has(.diff-item-1:focus),.diff:focus-visible{outline-style:var(--tw-outline-style);outline-offset:1px;outline-width:2px;outline-color:var(--color-base-content)}.diff:focus-visible .diff-resizer{min-width:90cqi;max-width:90cqi}.diff:has(.diff-item-2:focus-visible){outline-style:var(--tw-outline-style);outline-offset:1px;outline-width:2px}.diff:has(.diff-item-2:focus-visible) .diff-resizer{min-width:10cqi;max-width:10cqi}@supports (-webkit-overflow-scrolling:touch) and (overflow:-webkit-paged-x){.diff:focus .diff-resizer{min-width:10cqi;max-width:10cqi}.diff:has(.diff-item-1:focus) .diff-resizer{min-width:90cqi;max-width:90cqi}}.\\@container{container-type:inline-size}.modal{pointer-events:none;visibility:hidden;width:100%;max-width:none;height:100%;max-height:none;color:inherit;transition:transform .3s ease-out,visibility .3s allow-discrete,background-color .3s ease-out,opacity .1s ease-out;overscroll-behavior:contain;z-index:999;background-color:#0000;place-items:center;margin:0;padding:0;display:grid;position:fixed;inset:0;overflow:hidden}.modal::backdrop{display:none}.modal.modal-open,.modal[open],.modal:target{pointer-events:auto;visibility:visible;opacity:1;background-color:oklch(0% 0 0/.4);transition:transform .3s ease-out,background-color .3s ease-out,opacity .1s ease-out}:is(.modal.modal-open,.modal[open],.modal:target) .modal-box{opacity:1;translate:0;scale:1}@starting-style{.modal.modal-open,.modal[open],.modal:target{visibility:hidden;opacity:0}}.tooltip{--tt-bg:var(--color-neutral);--tt-off:calc(100% + .5rem);--tt-tail:calc(100% + 1px + .25rem);display:inline-block;position:relative}.tooltip>:where(.tooltip-content),.tooltip[data-tip]:before{border-radius:var(--radius-field);text-align:center;white-space:normal;max-width:20rem;color:var(--color-neutral-content);opacity:0;background-color:var(--tt-bg);pointer-events:none;z-index:1;--tw-content:attr(data-tip);content:var(--tw-content);width:-moz-max-content;width:max-content;padding-block:.25rem;padding-inline:.5rem;font-size:.875rem;line-height:1.25em;transition:opacity .2s cubic-bezier(.4,0,.2,1) 75ms,transform .2s cubic-bezier(.4,0,.2,1) 75ms;position:absolute}.tooltip:after{opacity:0;background-color:var(--tt-bg);content:"";pointer-events:none;--mask-tooltip:url("data:image/svg+xml,%3Csvg width='10' height='4' viewBox='0 0 8 4' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0.500009 1C3.5 1 3.00001 4 5.00001 4C7 4 6.5 1 9.5 1C10 1 10 0.499897 10 0H0C-1.99338e-08 0.5 0 1 0.500009 1Z' fill='black'/%3E%3C/svg%3E%0A");width:.625rem;height:.25rem;-webkit-mask-position:-1px 0;mask-position:-1px 0;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-image:var(--mask-tooltip);-webkit-mask-image:var(--mask-tooltip);mask-image:var(--mask-tooltip);transition:opacity .2s cubic-bezier(.4,0,.2,1) 75ms,transform .2s cubic-bezier(.4,0,.2,1) 75ms;display:block;position:absolute}:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible))>.tooltip-content,:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible))[data-tip]:before,:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible)):after{opacity:1;--tt-pos:0rem;transition:opacity .2s cubic-bezier(.4,0,.2,1),transform .2s cubic-bezier(.4,0,.2,1)}.tooltip>.tooltip-content,.tooltip[data-tip]:before{transform:translateX(-50%)translateY(var(--tt-pos,.25rem));inset:auto auto var(--tt-off)50%}.tooltip:after{transform:translateX(-50%)translateY(var(--tt-pos,.25rem));inset:auto auto var(--tt-tail)50%}.tab{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;text-align:center;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;--tab-p:1rem;--tab-bg:var(--color-base-100);--tab-border-color:var(--color-base-300);--tab-radius-ss:0;--tab-radius-se:0;--tab-radius-es:0;--tab-radius-ee:0;--tab-order:0;--tab-radius-min:calc(.75rem - var(--border));flex-wrap:wrap;order:var(--tab-order);height:calc(var(--size-field,.25rem)*10);border-color:#0000;justify-content:center;align-items:center;padding-inline-start:var(--tab-p);padding-inline-end:var(--tab-p);font-size:.875rem;display:inline-flex;position:relative}@media (hover:hover){.tab:hover{color:var(--color-base-content)}}.tab:is(input[type=radio]){min-width:-moz-fit-content;min-width:fit-content}.tab:is(input[type=radio]):after{content:attr(aria-label)}.tab:is(label){position:relative}.tab:is(label) input{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;opacity:0;position:absolute;inset:0}:is(.tab:checked,.tab:is(label:has(:checked)),.tab:is(.tab-active,[aria-selected=true]))+.tab-content{height:100%;display:block}.tab:not(:checked,label:has(:checked),:hover,.tab-active,[aria-selected=true]){color:color-mix(in oklab,var(--color-base-content)50%,transparent)}.tab:not(input):empty{cursor:default;flex-grow:1}.tab:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.tab:focus{outline-offset:2px;outline:2px solid #0000}}.tab:focus-visible,.tab:is(label:has(:checked:focus-visible)){outline-offset:-5px;outline:2px solid}.tab[disabled]{pointer-events:none;opacity:.4}.menu{--menu-active-fg:var(--color-neutral-content);--menu-active-bg:var(--color-neutral);flex-flow:column wrap;width:-moz-fit-content;width:fit-content;padding:.5rem;font-size:.875rem;display:flex}.menu :where(li ul){white-space:nowrap;margin-inline-start:1rem;padding-inline-start:.5rem;position:relative}.menu :where(li ul):before{background-color:var(--color-base-content);opacity:.1;width:var(--border);content:"";inset-inline-start:0;position:absolute;top:.75rem;bottom:.75rem}.menu :where(li>.menu-dropdown:not(.menu-dropdown-show)){display:none}.menu :where(li:not(.menu-title)>:not(ul,details,.menu-title,.btn)),.menu :where(li:not(.menu-title)>details>summary:not(.menu-title)){border-radius:var(--radius-field);text-align:start;text-wrap:balance;-webkit-user-select:none;-moz-user-select:none;user-select:none;grid-auto-columns:minmax(auto,max-content) auto max-content;grid-auto-flow:column;align-content:flex-start;align-items:center;gap:.5rem;padding-block:.375rem;padding-inline:.75rem;transition-property:color,background-color,box-shadow;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);display:grid}.menu :where(li>details>summary){--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.menu :where(li>details>summary){outline-offset:2px;outline:2px solid #0000}}.menu :where(li>details>summary)::-webkit-details-marker{display:none}:is(.menu :where(li>details>summary),.menu :where(li>.menu-dropdown-toggle)):after{content:"";transform-origin:50%;pointer-events:none;justify-self:flex-end;width:.375rem;height:.375rem;transition-property:rotate,translate;transition-duration:.2s;display:block;translate:0 -1px;rotate:-135deg;box-shadow:inset 2px 2px}.menu :where(li>details[open]>summary):after,.menu :where(li>.menu-dropdown-toggle.menu-dropdown-show):after{translate:0 1px;rotate:45deg}.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn).menu-focus,.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn):focus-visible{cursor:pointer;background-color:color-mix(in oklab,var(--color-base-content)10%,transparent);color:var(--color-base-content);--tw-outline-style:none;outline-style:none}@media (forced-colors:active){:is(.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn).menu-focus,.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn):focus-visible){outline-offset:2px;outline:2px solid #0000}}.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title):not(.menu-active,:active,.btn):hover,li:not(.menu-title,.disabled)>details>summary:not(.menu-title):not(.menu-active,:active,.btn):hover){cursor:pointer;background-color:color-mix(in oklab,var(--color-base-content)10%,transparent);--tw-outline-style:none;outline-style:none;box-shadow:inset 0 1px oklch(0% 0 0/.01),inset 0 -1px oklch(100% 0 0/.01)}@media (forced-colors:active){.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title):not(.menu-active,:active,.btn):hover,li:not(.menu-title,.disabled)>details>summary:not(.menu-title):not(.menu-active,:active,.btn):hover){outline-offset:2px;outline:2px solid #0000}}.menu :where(li:empty){background-color:var(--color-base-content);opacity:.1;height:1px;margin:.5rem 1rem}.menu :where(li){flex-flow:column wrap;flex-shrink:0;align-items:stretch;display:flex;position:relative}.menu :where(li) .badge{justify-self:flex-end}.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active{--tw-outline-style:none;color:var(--menu-active-fg);background-color:var(--menu-active-bg);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);outline-style:none}@media (forced-colors:active){:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active){outline-offset:2px;outline:2px solid #0000}}:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active):not(:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active):active){box-shadow:0 2px calc(var(--depth)*3px)-2px var(--menu-active-bg)}.menu :where(li).menu-disabled{pointer-events:none;color:color-mix(in oklab,var(--color-base-content)20%,transparent)}.menu .dropdown:focus-within .menu-dropdown-toggle:after{translate:0 1px;rotate:45deg}.menu .dropdown-content{margin-top:.5rem;padding:.5rem}.menu .dropdown-content:before{display:none}.dropdown{position-area:var(--anchor-v,bottom)var(--anchor-h,span-right);display:inline-block;position:relative}.dropdown>:not(summary):focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.dropdown>:not(summary):focus{outline-offset:2px;outline:2px solid #0000}}.dropdown .dropdown-content{position:absolute}.dropdown:not(details,.dropdown-open,.dropdown-hover:hover,:focus-within) .dropdown-content{transform-origin:top;opacity:0;display:none;scale:95%}.dropdown[popover],.dropdown .dropdown-content{z-index:999;transition-behavior:allow-discrete;transition-property:opacity,scale,display;transition-duration:.2s;transition-timing-function:cubic-bezier(.4,0,.2,1);animation:.2s dropdown}@starting-style{.dropdown[popover],.dropdown .dropdown-content{opacity:0;scale:95%}}:is(.dropdown.dropdown-open,.dropdown:not(.dropdown-hover):focus,.dropdown:focus-within)>[tabindex]:first-child{pointer-events:none}:is(.dropdown.dropdown-open,.dropdown:not(.dropdown-hover):focus,.dropdown:focus-within) .dropdown-content{opacity:1}.dropdown.dropdown-hover:hover .dropdown-content{opacity:1;scale:100%}.dropdown:is(details) summary::-webkit-details-marker{display:none}:is(.dropdown.dropdown-open,.dropdown:focus,.dropdown:focus-within) .dropdown-content{scale:100%}.dropdown:where([popover]){background:0 0}.dropdown[popover]{color:inherit;position:fixed}@supports not (position-area:bottom){.dropdown[popover]{margin:auto}.dropdown[popover].dropdown-open:not(:popover-open){transform-origin:top;opacity:0;display:none;scale:95%}.dropdown[popover]::backdrop{background-color:oklab(0% none none/.3)}}.dropdown[popover]:not(.dropdown-open,:popover-open){transform-origin:top;opacity:0;display:none;scale:95%}.btn{cursor:pointer;text-align:center;vertical-align:middle;outline-offset:2px;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;padding-inline:var(--btn-p);color:var(--btn-fg);--tw-prose-links:var(--btn-fg);height:var(--size);font-size:var(--fontsize,.875rem);outline-color:var(--btn-color,var(--color-base-content));background-color:var(--btn-bg);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--btn-noise);border-width:var(--border);border-style:solid;border-color:var(--btn-border);text-shadow:0 .5px oklch(100% 0 0/calc(var(--depth)*.15));box-shadow:0 .5px 0 .5px oklch(100% 0 0/calc(var(--depth)*6%))inset,var(--btn-shadow);--size:calc(var(--size-field,.25rem)*10);--btn-bg:var(--btn-color,var(--color-base-200));--btn-fg:var(--color-base-content);--btn-p:1rem;--btn-border:color-mix(in oklab,var(--btn-bg),#000 calc(var(--depth)*5%));--btn-shadow:0 3px 2px -2px color-mix(in oklab,var(--btn-bg)calc(var(--depth)*30%),#0000),0 4px 3px -2px color-mix(in oklab,var(--btn-bg)calc(var(--depth)*30%),#0000);--btn-noise:var(--fx-noise);border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-wrap:nowrap;flex-shrink:0;justify-content:center;align-items:center;gap:.375rem;font-weight:600;transition-property:color,background-color,border-color,box-shadow;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);display:inline-flex}.prose .btn{text-decoration-line:none}@media (hover:hover){.btn:hover{--btn-bg:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 7%)}}.btn:focus-visible{outline-width:2px;outline-style:solid}.btn:active:not(.btn-active){--btn-bg:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 5%);--btn-border:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 7%);--btn-shadow:0 0 0 0 oklch(0% 0 0/0),0 0 0 0 oklch(0% 0 0/0);translate:0 .5px}.btn:is(:disabled,[disabled],.btn-disabled){pointer-events:none;--btn-border:#0000;--btn-noise:none;--btn-fg:color-mix(in oklch,var(--color-base-content)20%,#0000)}.btn:is(:disabled,[disabled],.btn-disabled):not(.btn-link,.btn-ghost){background-color:color-mix(in oklab,var(--color-base-content)10%,transparent);box-shadow:none}@media (hover:hover){.btn:is(:disabled,[disabled],.btn-disabled):hover{pointer-events:none;background-color:color-mix(in oklab,var(--color-neutral)20%,transparent);--btn-border:#0000;--btn-fg:color-mix(in oklch,var(--color-base-content)20%,#0000)}}.btn:is(input[type=checkbox],input[type=radio]){-webkit-appearance:none;-moz-appearance:none;appearance:none}.btn:is(input[type=checkbox],input[type=radio]):after{content:attr(aria-label)}.btn:where(input:checked:not(.filter .btn)){--btn-color:var(--color-primary);--btn-fg:var(--color-primary-content);isolation:isolate}.loading{pointer-events:none;aspect-ratio:1;vertical-align:middle;width:calc(var(--size-selector,.25rem)*6);background-color:currentColor;display:inline-block;-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");-webkit-mask-position:50%;mask-position:50%;-webkit-mask-size:100%;mask-size:100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.invisible{visibility:hidden}.visible{visibility:visible}.list{flex-direction:column;font-size:.875rem;display:flex}.list :where(.list-row){--list-grid-cols:minmax(0,auto)1fr;border-radius:var(--radius-box);word-break:break-word;grid-auto-flow:column;grid-template-columns:var(--list-grid-cols);gap:1rem;padding:1rem;display:grid;position:relative}.list :where(.list-row):has(.list-col-grow:first-child){--list-grid-cols:1fr}.list :where(.list-row):has(.list-col-grow:nth-child(2)){--list-grid-cols:minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(3)){--list-grid-cols:minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(4)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(5)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(6)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row) :not(.list-col-wrap){grid-row-start:1}:is(.list>:not(:last-child).list-row,.list>:not(:last-child) .list-row):after{content:"";border-bottom:var(--border)solid;inset-inline:var(--radius-box);border-color:color-mix(in oklab,var(--color-base-content)5%,transparent);position:absolute;bottom:0}.toggle{border:var(--border)solid currentColor;color:var(--input-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;vertical-align:middle;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;--radius-selector-max:calc(var(--radius-selector) + var(--radius-selector) + var(--radius-selector));border-radius:calc(var(--radius-selector) + min(var(--toggle-p),var(--radius-selector-max)) + min(var(--border),var(--radius-selector-max)));padding:var(--toggle-p);box-shadow:0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000)inset;--input-color:color-mix(in oklab,var(--color-base-content)50%,#0000);--toggle-p:.1875rem;--size:calc(var(--size-selector,.25rem)*6);width:calc((var(--size)*2) - (var(--border) + var(--toggle-p))*2);height:var(--size);flex-shrink:0;grid-template-columns:0fr 1fr 1fr;place-content:center;transition:color .3s,grid-template-columns .2s;display:inline-grid;position:relative}.toggle>*{z-index:1;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;border:none;grid-column:2/span 1;grid-row-start:1;height:100%;padding:.125rem;transition:opacity .2s,rotate .4s}.toggle>:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.toggle>:focus{outline-offset:2px;outline:2px solid #0000}}.toggle>:nth-child(2){color:var(--color-base-100);rotate:none}.toggle>:nth-child(3){color:var(--color-base-100);opacity:0;rotate:-15deg}.toggle:has(:checked)>:nth-child(2){opacity:0;rotate:15deg}.toggle:has(:checked)>:nth-child(3){opacity:1;rotate:none}.toggle:before{aspect-ratio:1;border-radius:var(--radius-selector);--tw-content:"";content:var(--tw-content);height:100%;box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000);background-color:currentColor;background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);grid-row-start:1;grid-column-start:2;transition:background-color .1s,translate .2s,inset-inline-start .2s;position:relative;inset-inline-start:0;translate:0}@media (forced-colors:active){.toggle:before{outline-style:var(--tw-outline-style);outline-offset:calc(1px*-1);outline-width:1px}}@media print{.toggle:before{outline-offset:-1rem;outline:.25rem solid}}.toggle:focus-visible,.toggle:has(:focus-visible){outline-offset:2px;outline:2px solid}.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked){background-color:var(--color-base-100);--input-color:var(--color-base-content);grid-template-columns:1fr 1fr 0fr}:is(.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked)):before{background-color:currentColor}@starting-style{:is(.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked)):before{opacity:0}}.toggle:indeterminate{grid-template-columns:.5fr 1fr .5fr}.toggle:disabled{cursor:not-allowed;opacity:.3}.toggle:disabled:before{border:var(--border)solid currentColor;background-color:#0000}.input{cursor:text;border:var(--border)solid #0000;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--color-base-100);vertical-align:middle;white-space:nowrap;width:clamp(3rem,20rem,100%);height:var(--size);border-color:var(--input-color);box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;--size:calc(var(--size-field,.25rem)*10);--input-color:color-mix(in oklab,var(--color-base-content)20%,#0000);border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-shrink:1;align-items:center;gap:.5rem;padding-inline:.75rem;font-size:.875rem;display:inline-flex;position:relative}.input:where(input){display:inline-flex}.input :where(input){-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;border:none;width:100%;height:100%;display:inline-flex}.input :where(input):focus,.input :where(input):focus-within{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){:is(.input :where(input):focus,.input :where(input):focus-within){outline-offset:2px;outline:2px solid #0000}}.input:focus,.input:focus-within{--input-color:var(--color-base-content);box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000);outline:2px solid var(--input-color);outline-offset:2px;isolation:isolate}.input:has(>input[disabled]),.input:is(:disabled,[disabled]){cursor:not-allowed;border-color:var(--color-base-200);background-color:var(--color-base-200);color:color-mix(in oklab,var(--color-base-content)40%,transparent);box-shadow:none}:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}.input:has(>input[disabled])>input[disabled]{cursor:not-allowed}.input::-webkit-date-and-time-value{text-align:inherit}.input[type=number]::-webkit-inner-spin-button{margin-block:-.75rem;margin-inline-end:-.75rem}.input::-webkit-calendar-picker-indicator{position:absolute;inset-inline-end:.75em}.indicator{width:-moz-max-content;width:max-content;display:inline-flex;position:relative}.indicator :where(.indicator-item){z-index:1;white-space:nowrap;top:var(--inidicator-t,0);bottom:var(--inidicator-b,auto);left:var(--inidicator-s,auto);right:var(--inidicator-e,0);translate:var(--inidicator-x,50%)var(--indicator-y,-50%);position:absolute}.table{border-radius:var(--radius-box);text-align:left;width:100%;font-size:.875rem;position:relative}.table:where(:dir(rtl),[dir=rtl],[dir=rtl] *){text-align:right}@media (hover:hover){:is(.table tr.row-hover,.table tr.row-hover:nth-child(2n)):hover{background-color:var(--color-base-200)}}.table :where(th,td){vertical-align:middle;padding-block:.75rem;padding-inline:1rem}.table :where(thead,tfoot){white-space:nowrap;color:color-mix(in oklab,var(--color-base-content)60%,transparent);font-size:.875rem;font-weight:600}.table :where(tfoot){border-top:var(--border)solid color-mix(in oklch,var(--color-base-content)5%,#0000)}.table :where(.table-pin-rows thead tr){z-index:1;background-color:var(--color-base-100);position:sticky;top:0}.table :where(.table-pin-rows tfoot tr){z-index:1;background-color:var(--color-base-100);position:sticky;bottom:0}.table :where(.table-pin-cols tr th){background-color:var(--color-base-100);position:sticky;left:0;right:0}.table :where(thead tr,tbody tr:not(:last-child)){border-bottom:var(--border)solid color-mix(in oklch,var(--color-base-content)5%,#0000)}.steps{counter-reset:step;grid-auto-columns:1fr;grid-auto-flow:column;display:inline-grid;overflow:auto hidden}.steps .step{text-align:center;--step-bg:var(--color-base-300);--step-fg:var(--color-base-content);grid-template-rows:40px 1fr;grid-template-columns:auto;place-items:center;min-width:4rem;display:grid}.steps .step:before{width:100%;height:.5rem;color:var(--step-bg);background-color:var(--step-bg);--tw-content:"";content:var(--tw-content);border:1px solid;grid-row-start:1;grid-column-start:1;margin-inline-start:-100%;top:0}.steps .step>.step-icon,.steps .step:not(:has(.step-icon)):after{content:counter(step);counter-increment:step;z-index:1;color:var(--step-fg);background-color:var(--step-bg);border:1px solid var(--step-bg);border-radius:3.40282e38px;grid-row-start:1;grid-column-start:1;place-self:center;place-items:center;width:2rem;height:2rem;display:grid;position:relative}.steps .step:first-child:before{content:none}.steps .step[data-content]:after{content:attr(data-content)}.steps .step-neutral+.step-neutral:before,.steps .step-neutral:after,.steps .step-neutral>.step-icon{--step-bg:var(--color-neutral);--step-fg:var(--color-neutral-content)}.steps .step-primary+.step-primary:before,.steps .step-primary:after,.steps .step-primary>.step-icon{--step-bg:var(--color-primary);--step-fg:var(--color-primary-content)}.steps .step-secondary+.step-secondary:before,.steps .step-secondary:after,.steps .step-secondary>.step-icon{--step-bg:var(--color-secondary);--step-fg:var(--color-secondary-content)}.steps .step-accent+.step-accent:before,.steps .step-accent:after,.steps .step-accent>.step-icon{--step-bg:var(--color-accent);--step-fg:var(--color-accent-content)}.steps .step-info+.step-info:before,.steps .step-info:after,.steps .step-info>.step-icon{--step-bg:var(--color-info);--step-fg:var(--color-info-content)}.steps .step-success+.step-success:before,.steps .step-success:after,.steps .step-success>.step-icon{--step-bg:var(--color-success);--step-fg:var(--color-success-content)}.steps .step-warning+.step-warning:before,.steps .step-warning:after,.steps .step-warning>.step-icon{--step-bg:var(--color-warning);--step-fg:var(--color-warning-content)}.steps .step-error+.step-error:before,.steps .step-error:after,.steps .step-error>.step-icon{--step-bg:var(--color-error);--step-fg:var(--color-error-content)}.range{-webkit-appearance:none;-moz-appearance:none;appearance:none;webkit-appearance:none;--range-thumb:var(--color-base-100);--range-thumb-size:calc(var(--size-selector,.25rem)*6);--range-progress:currentColor;--range-fill:1;--range-p:.25rem;--range-bg:color-mix(in oklab,currentColor 10%,#0000);cursor:pointer;vertical-align:middle;--radius-selector-max:calc(var(--radius-selector) + var(--radius-selector) + var(--radius-selector));border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));width:clamp(3rem,20rem,100%);height:var(--range-thumb-size);background-color:#0000;border:none;overflow:hidden}[dir=rtl] .range{--range-dir:-1}.range:focus{outline:none}.range:focus-visible{outline-offset:2px;outline:2px solid}.range::-webkit-slider-runnable-track{background-color:var(--range-bg);border-radius:var(--radius-selector);width:100%;height:calc(var(--range-thumb-size)*.5)}@media (forced-colors:active){.range::-webkit-slider-runnable-track{border:1px solid}.range::-moz-range-track{border:1px solid}}.range::-webkit-slider-thumb{box-sizing:border-box;border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));height:var(--range-thumb-size);width:var(--range-thumb-size);border:var(--range-p)solid;-webkit-appearance:none;appearance:none;webkit-appearance:none;color:var(--range-progress);box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000),0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill));background-color:currentColor;position:relative;top:50%;transform:translateY(-50%)}.range::-moz-range-track{background-color:var(--range-bg);border-radius:var(--radius-selector);width:100%;height:calc(var(--range-thumb-size)*.5)}.range::-moz-range-thumb{box-sizing:border-box;border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));height:var(--range-thumb-size);width:var(--range-thumb-size);border:var(--range-p)solid;color:var(--range-progress);box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000),0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill));background-color:currentColor;position:relative;top:50%}.range:disabled{cursor:not-allowed;opacity:.3}.select{border:var(--border)solid #0000;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--color-base-100);vertical-align:middle;width:clamp(3rem,20rem,100%);height:var(--size);text-overflow:ellipsis;box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;border-color:var(--input-color);--input-color:color-mix(in oklab,var(--color-base-content)20%,#0000);--size:calc(var(--size-field,.25rem)*10);background-image:linear-gradient(45deg,#0000 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,#0000 50%);background-position:calc(100% - 20px) calc(1px + 50%),calc(100% - 16.1px) calc(1px + 50%);background-repeat:no-repeat;background-size:4px 4px,4px 4px;border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-shrink:1;align-items:center;gap:.375rem;padding-inline:1rem 1.75rem;font-size:.875rem;display:inline-flex;position:relative}[dir=rtl] .select{background-position:12px calc(1px + 50%),16px calc(1px + 50%)}.select select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:inherit;border-radius:inherit;border-style:none;width:calc(100% + 2.75rem);height:calc(100% - 2px);margin-inline:-1rem -1.75rem;padding-inline:1rem 1.75rem}.select select:focus,.select select:focus-within{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){:is(.select select:focus,.select select:focus-within){outline-offset:2px;outline:2px solid #0000}}.select select:not(:last-child){background-image:none;margin-inline-end:-1.375rem}.select:focus,.select:focus-within{--input-color:var(--color-base-content);box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000);outline:2px solid var(--input-color);outline-offset:2px}.select:has(>select[disabled]),.select:is(:disabled,[disabled]){cursor:not-allowed;border-color:var(--color-base-200);background-color:var(--color-base-200);color:color-mix(in oklab,var(--color-base-content)40%,transparent)}:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}.select:has(>select[disabled])>select[disabled]{cursor:not-allowed}.checkbox{border:var(--border)solid var(--input-color,color-mix(in oklab,var(--color-base-content)20%,#0000));cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:var(--radius-selector);vertical-align:middle;color:var(--color-base-content);box-shadow:0 1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 0 #0000 inset,0 0 #0000;--size:calc(var(--size-selector,.25rem)*6);width:var(--size);height:var(--size);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);flex-shrink:0;padding:.25rem;transition:background-color .2s,box-shadow .2s;position:relative}.checkbox:before{--tw-content:"";content:var(--tw-content);opacity:0;clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 80%,70% 80%,70% 100%);width:100%;height:100%;box-shadow:0px 3px 0 0px oklch(100% 0 0/calc(var(--depth)*.1))inset;background-color:currentColor;font-size:1rem;line-height:.75;transition:clip-path .3s .1s,opacity .1s .1s,rotate .3s .1s,translate .3s .1s;display:block;rotate:45deg}.checkbox:focus-visible{outline:2px solid var(--input-color,currentColor);outline-offset:2px}.checkbox:checked,.checkbox[aria-checked=true]{background-color:var(--input-color,#0000);box-shadow:0 0 #0000 inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px oklch(0% 0 0/calc(var(--depth)*.1))}:is(.checkbox:checked,.checkbox[aria-checked=true]):before{clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 0%,70% 0%,70% 100%);opacity:1}@media (forced-colors:active){:is(.checkbox:checked,.checkbox[aria-checked=true]):before{--tw-content:"✔︎";clip-path:none;background-color:#0000;rotate:none}}@media print{:is(.checkbox:checked,.checkbox[aria-checked=true]):before{--tw-content:"✔︎";clip-path:none;background-color:#0000;rotate:none}}.checkbox:indeterminate:before{opacity:1;clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 80%,80% 80%,80% 100%);translate:0 -35%;rotate:none}.checkbox:disabled{cursor:not-allowed;opacity:.2}.radio{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;vertical-align:middle;border:var(--border)solid var(--input-color,color-mix(in srgb,currentColor 20%,#0000));box-shadow:0 1px oklch(0% 0 0/calc(var(--depth)*.1))inset;--size:calc(var(--size-selector,.25rem)*6);width:var(--size);height:var(--size);color:var(--input-color,currentColor);border-radius:3.40282e38px;flex-shrink:0;padding:.25rem;position:relative}.radio:before{--tw-content:"";content:var(--tw-content);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);border-radius:3.40282e38px;width:100%;height:100%;display:block}.radio:focus-visible{outline:2px solid}.radio:checked,.radio[aria-checked=true]{background-color:var(--color-base-100);border-color:currentColor;animation:.2s ease-out radio}:is(.radio:checked,.radio[aria-checked=true]):before{box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px oklch(0% 0 0/calc(var(--depth)*.1));background-color:currentColor}@media (forced-colors:active){:is(.radio:checked,.radio[aria-checked=true]):before{outline-style:var(--tw-outline-style);outline-offset:calc(1px*-1);outline-width:1px}}@media print{:is(.radio:checked,.radio[aria-checked=true]):before{outline-offset:-1rem;outline:.25rem solid}}.radio:disabled{cursor:not-allowed;opacity:.2}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.inset-0{inset:calc(var(--spacing)*0)}.-top-3{top:calc(var(--spacing)*-3)}.top-0{top:calc(var(--spacing)*0)}.top-1\\/2{top:50%}.top-2{top:calc(var(--spacing)*2)}.top-full{top:100%}.-right-3{right:calc(var(--spacing)*-3)}.right-0{right:calc(var(--spacing)*0)}.right-2{right:calc(var(--spacing)*2)}.right-10{right:calc(var(--spacing)*10)}.right-full{right:100%}.bottom-0{bottom:calc(var(--spacing)*0)}.bottom-full{bottom:100%}.left-0{left:calc(var(--spacing)*0)}.left-1\\/2{left:50%}.left-full{left:100%}.modal-backdrop{color:#0000;z-index:-1;grid-row-start:1;grid-column-start:1;place-self:stretch stretch;display:grid}.modal-backdrop button{cursor:pointer}.z-10{z-index:10}.z-1001{z-index:1001}.modal-box{background-color:var(--color-base-100);border-top-left-radius:var(--modal-tl,var(--radius-box));border-top-right-radius:var(--modal-tr,var(--radius-box));border-bottom-left-radius:var(--modal-bl,var(--radius-box));border-bottom-right-radius:var(--modal-br,var(--radius-box));opacity:0;overscroll-behavior:contain;grid-row-start:1;grid-column-start:1;width:91.6667%;max-width:32rem;max-height:100vh;padding:1.5rem;transition:translate .3s ease-out,scale .3s ease-out,opacity .2s ease-out 50ms,box-shadow .3s ease-out;overflow-y:auto;scale:95%;box-shadow:0 25px 50px -12px oklch(0% 0 0/.25)}.stat-value{white-space:nowrap;grid-column-start:1;font-size:2rem;font-weight:800}.stat-desc,.stat-title{white-space:nowrap;color:color-mix(in oklab,var(--color-base-content)60%,transparent);grid-column-start:1;font-size:.75rem}.float-right{float:right}.container{width:100%}@media (width>=40rem){.container{max-width:40rem}}@media (width>=48rem){.container{max-width:48rem}}@media (width>=64rem){.container{max-width:64rem}}@media (width>=80rem){.container{max-width:80rem}}@media (width>=96rem){.container{max-width:96rem}}.divider{white-space:nowrap;height:1rem;margin:var(--divider-m,1rem 0);flex-direction:row;align-self:stretch;align-items:center;display:flex}.divider:before,.divider:after{content:"";background-color:color-mix(in oklab,var(--color-base-content)10%,transparent);flex-grow:1;width:100%;height:.125rem}@media print{.divider:before,.divider:after{border:.5px solid}}.divider:not(:empty){gap:1rem}.m-1{margin:calc(var(--spacing)*1)}.m-2{margin:calc(var(--spacing)*2)}.m-4{margin:calc(var(--spacing)*4)}.filter{flex-wrap:wrap;display:flex}.filter input[type=radio]{width:auto}.filter input{opacity:1;transition:margin .1s,opacity .3s,padding .3s,border-width .1s;overflow:hidden;scale:1}.filter input:not(:last-child){margin-inline-end:.25rem}.filter input.filter-reset{aspect-ratio:1}.filter input.filter-reset:after{content:"×"}.filter:not(:has(input:checked:not(.filter-reset))) .filter-reset,.filter:not(:has(input:checked:not(.filter-reset))) input[type=reset],.filter:has(input:checked:not(.filter-reset)) input:not(:checked,.filter-reset,input[type=reset]){opacity:0;border-width:0;width:0;margin-inline:0;padding-inline:0;scale:0}.mx-2{margin-inline:calc(var(--spacing)*2)}.mx-auto{margin-inline:auto}.input-sm{--size:calc(var(--size-field,.25rem)*8);font-size:.75rem}.input-sm[type=number]::-webkit-inner-spin-button{margin-block:-.5rem;margin-inline-end:-.75rem}.my-1{margin-block:calc(var(--spacing)*1)}.my-4{margin-block:calc(var(--spacing)*4)}.label{white-space:nowrap;color:color-mix(in oklab,currentColor 60%,transparent);align-items:center;gap:.375rem;display:inline-flex}.label:has(input){cursor:pointer}.label:is(.input>*,.select>*){white-space:nowrap;height:calc(100% - .5rem);font-size:inherit;align-items:center;padding-inline:.75rem;display:flex}.label:is(.input>*,.select>*):first-child{border-inline-end:var(--border)solid color-mix(in oklab,currentColor 10%,#0000);margin-inline:-.75rem .75rem}.label:is(.input>*,.select>*):last-child{border-inline-start:var(--border)solid color-mix(in oklab,currentColor 10%,#0000);margin-inline:.75rem -.75rem}.join-item:where(:not(:first-child)){margin-block-start:0;margin-inline-start:calc(var(--border,1px)*-1)}.modal-action{justify-content:flex-end;gap:.5rem;margin-top:1.5rem;display:flex}.mt-0{margin-top:calc(var(--spacing)*0)}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-4{margin-top:calc(var(--spacing)*4)}.mr-1{margin-right:calc(var(--spacing)*1)}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-0{margin-bottom:calc(var(--spacing)*0)}.mb-1{margin-bottom:calc(var(--spacing)*1)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.ml-1{margin-left:calc(var(--spacing)*1)}.ml-2{margin-left:calc(var(--spacing)*2)}.ml-2\\.5{margin-left:calc(var(--spacing)*2.5)}.ml-3{margin-left:calc(var(--spacing)*3)}.status{aspect-ratio:1;border-radius:var(--radius-selector);background-color:color-mix(in oklab,var(--color-base-content)20%,transparent);vertical-align:middle;width:.5rem;height:.5rem;color:color-mix(in oklab,var(--color-black)30%,transparent);background-position:50%;background-repeat:no-repeat;background-image:radial-gradient(circle at 35% 30%,oklch(1 0 0/calc(var(--depth)*.5)),#0000);box-shadow:0 2px 3px -1px color-mix(in oklab,currentColor calc(var(--depth)*100%),#0000);display:inline-block}.iconify{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.tabs{--tabs-height:auto;--tabs-direction:row;height:var(--tabs-height);flex-wrap:wrap;flex-direction:var(--tabs-direction);display:flex}.footer{grid-auto-flow:row;place-items:start;gap:2.5rem 1rem;width:100%;font-size:.875rem;line-height:1.25rem;display:grid}.footer>*{place-items:start;gap:.5rem;display:grid}.footer.footer-center{text-align:center;grid-auto-flow:column dense;place-items:center}.footer.footer-center>*{place-items:center}.stat{grid-template-columns:repeat(1,1fr);-moz-column-gap:1rem;column-gap:1rem;width:100%;padding-block:1rem;padding-inline:1.5rem;display:inline-grid}.stat:not(:last-child){border-inline-end:var(--border)dashed color-mix(in oklab,currentColor 10%,#0000);border-block-end:none}.alert{border-radius:var(--radius-box);color:var(--color-base-content);background-color:var(--alert-color,var(--color-base-200));text-align:start;border:var(--border)solid var(--color-base-200);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);box-shadow:0 3px 0 -2px oklch(100% 0 0/calc(var(--depth)*.08))inset,0 1px color-mix(in oklab,color-mix(in oklab,#000 20%,var(--alert-color,var(--color-base-200)))calc(var(--depth)*20%),#0000),0 4px 3px -2px oklch(0% 0 0/calc(var(--depth)*.08));grid-template-columns:auto minmax(auto,1fr);grid-auto-flow:column;justify-content:start;place-items:center start;gap:1rem;padding-block:.75rem;padding-inline:1rem;font-size:.875rem;line-height:1.25rem;display:grid}.alert.alert-outline{color:var(--alert-color);box-shadow:none;background-color:#0000;background-image:none}.alert.alert-dash{color:var(--alert-color);box-shadow:none;background-color:#0000;background-image:none;border-style:dashed}.alert.alert-soft{color:var(--alert-color,var(--color-base-content));background:color-mix(in oklab,var(--alert-color,var(--color-base-content))8%,var(--color-base-100));border-color:color-mix(in oklab,var(--alert-color,var(--color-base-content))10%,var(--color-base-100));box-shadow:none;background-image:none}.join{--join-ss:0;--join-se:0;--join-es:0;--join-ee:0;align-items:stretch;display:inline-flex}.join :where(.join-item){border-start-start-radius:var(--join-ss,0);border-start-end-radius:var(--join-se,0);border-end-end-radius:var(--join-ee,0);border-end-start-radius:var(--join-es,0)}.join :where(.join-item) *{--join-ss:var(--radius-field);--join-se:var(--radius-field);--join-es:var(--radius-field);--join-ee:var(--radius-field)}.join>.join-item:where(:first-child),.join :first-child:not(:last-child) :where(.join-item){--join-ss:var(--radius-field);--join-se:0;--join-es:var(--radius-field);--join-ee:0}.join>.join-item:where(:last-child),.join :last-child:not(:first-child) :where(.join-item){--join-ss:0;--join-se:var(--radius-field);--join-es:0;--join-ee:var(--radius-field)}.join>.join-item:where(:only-child),.join :only-child :where(.join-item){--join-ss:var(--radius-field);--join-se:var(--radius-field);--join-es:var(--radius-field);--join-ee:var(--radius-field)}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.modal-bottom{place-items:end}.modal-bottom :where(.modal-box){--modal-tl:var(--radius-box);--modal-tr:var(--radius-box);--modal-bl:0;--modal-br:0;width:100%;max-width:none;height:auto;max-height:calc(100vh - 5em);translate:0 100%;scale:1}.btn-circle{width:var(--size);height:var(--size);border-radius:3.40282e38px;padding-inline:0}.h-8{height:calc(var(--spacing)*8)}.h-\\[calc\\(var\\(--size\\)\\*0\\.7\\)\\]{height:calc(var(--size)*.7)}.h-full{height:100%}.max-h-80{max-height:calc(var(--spacing)*80)}.loading-md{width:calc(var(--size-selector,.25rem)*6)}.w-10{width:calc(var(--spacing)*10)}.w-12{width:calc(var(--spacing)*12)}.w-20{width:calc(var(--spacing)*20)}.w-32{width:calc(var(--spacing)*32)}.w-64{width:calc(var(--spacing)*64)}.w-\\[6rem\\]{width:6rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.max-w-\\(--breakpoint-lg\\){max-width:var(--breakpoint-lg)}.min-w-24{min-width:calc(var(--spacing)*24)}.min-w-32{min-width:calc(var(--spacing)*32)}.min-w-\\[0\\.05rem\\]{min-width:.05rem}.min-w-\\[7\\.5rem\\]{min-width:7.5rem}.min-w-\\[180px\\]{min-width:180px}.flex-1{flex:1}.grow{flex-grow:1}.translate-x-\\[-50\\%\\]{--tw-translate-x:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\\[-50\\%\\]{--tw-translate-y:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.transform{transform:var(--tw-rotate-x)var(--tw-rotate-y)var(--tw-rotate-z)var(--tw-skew-x)var(--tw-skew-y)}.skeleton{border-radius:var(--radius-box);background-color:var(--color-base-300);will-change:background-position;background-image:linear-gradient(105deg,#0000 0% 40%,var(--color-base-100)50%,#0000 60% 100%);background-position-x:-50%;background-repeat:no-repeat;background-size:200%;animation:1.8s ease-in-out infinite skeleton}@media (prefers-reduced-motion:reduce){.skeleton{transition-duration:15s}}.link{cursor:pointer;text-decoration-line:underline}.link:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.link:focus{outline-offset:2px;outline:2px solid #0000}}.link:focus-visible{outline-offset:2px;outline:2px solid}.cursor-pointer{cursor:pointer}.resize{resize:both}.list-inside{list-style-position:inside}.list-outside{list-style-position:outside}.list-disc{list-style-type:disc}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-end{align-items:flex-end}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.gap-0\\.5{gap:calc(var(--spacing)*.5)}.gap-1{gap:calc(var(--spacing)*1)}.gap-x-6{-moz-column-gap:calc(var(--spacing)*6);column-gap:calc(var(--spacing)*6)}.gap-y-1{row-gap:calc(var(--spacing)*1)}.gap-y-2{row-gap:calc(var(--spacing)*2)}.overflow-scroll{overflow:scroll}.overflow-visible{overflow:visible}.overflow-x-auto{overflow-x:auto}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-none{border-radius:0}.rounded-sm{border-radius:var(--radius-sm)}.rounded-t-md{border-top-left-radius:var(--radius-md);border-top-right-radius:var(--radius-md)}.rounded-t-none{border-top-left-radius:0;border-top-right-radius:0}.rounded-tr-md{border-top-right-radius:var(--radius-md)}.rounded-b-md{border-bottom-right-radius:var(--radius-md);border-bottom-left-radius:var(--radius-md)}.rounded-b-none{border-bottom-right-radius:0;border-bottom-left-radius:0}.border{border-style:var(--tw-border-style);border-width:1px}.border-0{border-style:var(--tw-border-style);border-width:0}.border-1{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.select-ghost{box-shadow:none;background-color:#0000;border-color:#0000;transition:background-color .2s}.select-ghost:focus,.select-ghost:focus-within{background-color:var(--color-base-100);color:var(--color-base-content);box-shadow:none;border-color:#0000}.input-ghost{box-shadow:none;background-color:#0000;border-color:#0000}.input-ghost:focus,.input-ghost:focus-within{background-color:var(--color-base-100);color:var(--color-base-content);box-shadow:none;border-color:#0000}.alert-error{border-color:var(--color-error);color:var(--color-error-content);--alert-color:var(--color-error)}.border-gray-100{border-color:var(--color-gray-100)}.border-gray-200{border-color:var(--color-gray-200)}.border-gray-300{border-color:var(--color-gray-300)}.border-gray-500{border-color:var(--color-gray-500)}.border-slate-500{border-color:var(--color-slate-500)}.bg-blue-300{background-color:var(--color-blue-300)}.bg-red-200{background-color:var(--color-red-200)}.bg-slate-200{background-color:var(--color-slate-200)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.p-1{padding:calc(var(--spacing)*1)}.p-1\\.5{padding:calc(var(--spacing)*1.5)}.p-2{padding:calc(var(--spacing)*2)}.p-4{padding:calc(var(--spacing)*4)}.px-1{padding-inline:calc(var(--spacing)*1)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.py-1{padding-block:calc(var(--spacing)*1)}.py-2{padding-block:calc(var(--spacing)*2)}.py-16{padding-block:calc(var(--spacing)*16)}.pr-14{padding-right:calc(var(--spacing)*14)}.text-center{text-align:center}.text-justify{text-align:justify}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.select-sm{--size:calc(var(--size-field,.25rem)*8);font-size:.75rem}.select-xs{--size:calc(var(--size-field,.25rem)*6);font-size:.6875rem}.leading-5{--tw-leading:calc(var(--spacing)*5);line-height:calc(var(--spacing)*5)}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.text-nowrap{text-wrap:nowrap}.text-wrap{text-wrap:wrap}.break-words{overflow-wrap:break-word}.whitespace-nowrap{white-space:nowrap}.text-\\[\\#606060\\]{color:#606060}.text-black{color:var(--color-black)}.text-blue-600{color:var(--color-blue-600)}.text-gray-500{color:var(--color-gray-500)}.text-gray-600{color:var(--color-gray-600)}.text-neutral-500{color:var(--color-neutral-500)}.text-red-600{color:var(--color-red-600)}.text-red-700{color:var(--color-red-700)}.underline{text-decoration-line:underline}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.btn-ghost:not(.btn-active,:hover,:active:focus,:focus-visible){--btn-shadow:"";--btn-bg:#0000;--btn-border:#0000;--btn-noise:none}.btn-ghost:not(.btn-active,:hover,:active:focus,:focus-visible):not(:disabled,[disabled],.btn-disabled){--btn-fg:currentColor;outline-color:currentColor}.blur{--tw-blur:blur(8px);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150{--tw-duration:.15s;transition-duration:.15s}.btn-outline:not(.btn-active,:hover,:active:focus,:focus-visible,:disabled,[disabled],.btn-disabled,:checked){--btn-shadow:"";--btn-bg:#0000;--btn-fg:var(--btn-color);--btn-border:var(--btn-color);--btn-noise:none}.btn-sm{--fontsize:.75rem;--btn-p:.75rem;--size:calc(var(--size-field,.25rem)*8)}.btn-xs{--fontsize:.6875rem;--btn-p:.5rem;--size:calc(var(--size-field,.25rem)*6)}.select-text{-webkit-user-select:text;-moz-user-select:text;user-select:text}.input-error,.input-error:focus,.input-error:focus-within{--input-color:var(--color-error)}.loading-spinner{-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E")}.mdi--chevron-left{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M15.41 16.58L10.83 12l4.58-4.59L14 6l-6 6l6 6z'/%3E%3C/svg%3E")}.mdi--chevron-left-first{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6l6 6zM6 6h2v12H6z'/%3E%3C/svg%3E")}.mdi--chevron-right{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M8.59 16.58L13.17 12L8.59 7.41L10 6l6 6l-6 6z'/%3E%3C/svg%3E")}.mdi--chevron-right-last{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6l-6-6zM16 6h2v12h-2z'/%3E%3C/svg%3E")}.mdi--fullscreen{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M5 5h5v2H7v3H5zm9 0h5v5h-2V7h-3zm3 9h2v5h-5v-2h3zm-7 3v2H5v-5h2v3z'/%3E%3C/svg%3E")}.mdi--fullscreen-exit{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M14 14h5v2h-3v3h-2zm-9 0h5v5H8v-3H5zm3-9h2v5H5V8h3zm11 3v2h-5V5h2v3z'/%3E%3C/svg%3E")}.mdi--reload{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M2 12a9 9 0 0 0 9 9c2.39 0 4.68-.94 6.4-2.6l-1.5-1.5A6.7 6.7 0 0 1 11 19c-6.24 0-9.36-7.54-4.95-11.95S18 5.77 18 12h-3l4 4h.1l3.9-4h-3a9 9 0 0 0-18 0'/%3E%3C/svg%3E")}@media (hover:hover){.peer-hover\\:visible:is(:where(.peer):hover~*){visibility:visible}.hover\\:scale-90:hover{--tw-scale-x:90%;--tw-scale-y:90%;--tw-scale-z:90%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:bg-gray-100:hover{background-color:var(--color-gray-100)}.hover\\:bg-gray-300:hover{background-color:var(--color-gray-300)}.hover\\:font-bold:hover{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.hover\\:text-blue-700:hover{color:var(--color-blue-700)}.hover\\:text-blue-800:hover{color:var(--color-blue-800)}.hover\\:text-gray-400:hover{color:var(--color-gray-400)}.hover\\:text-gray-700:hover{color:var(--color-gray-700)}}@media (width>=40rem){.sm\\:modal-middle{place-items:center}.sm\\:modal-middle :where(.modal-box){--modal-tl:var(--radius-box);--modal-tr:var(--radius-box);--modal-bl:var(--radius-box);--modal-br:var(--radius-box);width:91.6667%;max-width:32rem;height:auto;max-height:calc(100vh - 5em);translate:0 2%;scale:98%}.sm\\:max-w-5xl{max-width:var(--container-5xl)}.sm\\:flex-row{flex-direction:row}.sm\\:text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}}@container (width>=2rem){.\\@\\[2rem\\]\\:visible{visibility:visible}}@container (width>=6rem){.\\@\\[6rem\\]\\:visible{visibility:visible}}@container (width>=14rem){.\\@4xs\\:flex-row{flex-direction:row}.\\@4xs\\:rounded-l-none{border-top-left-radius:0;border-bottom-left-radius:0}.\\@4xs\\:rounded-tr-none{border-top-right-radius:0}.\\@4xs\\:rounded-bl-md{border-bottom-left-radius:var(--radius-md)}}@container (width>=28rem){.\\@md\\:flex-row{flex-direction:row}.\\@md\\:rounded-l-md{border-top-left-radius:var(--radius-md);border-bottom-left-radius:var(--radius-md)}.\\@md\\:rounded-l-none{border-top-left-radius:0;border-bottom-left-radius:0}.\\@md\\:rounded-r-md{border-top-right-radius:var(--radius-md);border-bottom-right-radius:var(--radius-md)}.\\@md\\:rounded-r-none{border-top-right-radius:0;border-bottom-right-radius:0}}@container (width>=36rem){.\\@xl\\:block{display:block}.\\@xl\\:justify-end{justify-content:flex-end}}}@keyframes skeleton{0%{background-position:150%}to{background-position:-50%}}@keyframes progress{50%{background-position-x:-115%}}@keyframes radio{0%{padding:5px}50%{padding:3px}}@keyframes dropdown{0%{opacity:0}}@keyframes rating{0%,40%{filter:brightness(1.05)contrast(1.05);scale:1.1}}@keyframes toast{0%{opacity:0;scale:.9}to{opacity:1;scale:1}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false;initial-value:rotateX(0)}@property --tw-rotate-y{syntax:"*";inherits:false;initial-value:rotateY(0)}@property --tw-rotate-z{syntax:"*";inherits:false;initial-value:rotateZ(0)}@property --tw-skew-x{syntax:"*";inherits:false;initial-value:skewX(0)}@property --tw-skew-y{syntax:"*";inherits:false;initial-value:skewY(0)}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}
|
|
2468
|
+
function replaceCssProperties(styleSheet2) {
|
|
2469
|
+
const properties = [];
|
|
2470
|
+
[...styleSheet2.cssRules].map((rule, index) => [rule, index]).reverse().forEach(([rule, index]) => {
|
|
2471
|
+
if (rule instanceof CSSPropertyRule && rule.initialValue !== null) {
|
|
2472
|
+
styleSheet2.deleteRule(index);
|
|
2473
|
+
properties.push(`${rule.name}: ${rule.initialValue}`);
|
|
2474
|
+
}
|
|
2475
|
+
});
|
|
2476
|
+
if (properties.length > 0) {
|
|
2477
|
+
styleSheet2.insertRule(`:host { ${properties.join("; ")} }`);
|
|
2478
|
+
}
|
|
2479
|
+
}
|
|
2480
|
+
const tailwindStyle = `/*! tailwindcss v4.1.3 | MIT License | https://tailwindcss.com */
|
|
2481
|
+
@layer properties{@supports ((-webkit-hyphens:none) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:rotateX(0);--tw-rotate-y:rotateY(0);--tw-rotate-z:rotateZ(0);--tw-skew-x:skewX(0);--tw-skew-y:skewY(0);--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-200:oklch(88.5% .062 18.334);--color-red-600:oklch(57.7% .245 27.325);--color-red-700:oklch(50.5% .213 27.518);--color-blue-300:oklch(80.9% .105 251.813);--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-blue-800:oklch(42.4% .199 265.638);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-200:oklch(92.8% .006 264.531);--color-gray-300:oklch(87.2% .01 258.338);--color-gray-400:oklch(70.7% .022 261.325);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-600:oklch(44.6% .03 256.802);--color-gray-700:oklch(37.3% .034 259.733);--color-neutral-500:oklch(55.6% 0 0);--color-black:#000;--color-white:#fff;--spacing:.25rem;--breakpoint-lg:64rem;--container-5xl:64rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5/2.25);--font-weight-normal:400;--font-weight-medium:500;--font-weight-bold:700;--radius-sm:.25rem;--radius-md:.375rem;--radius-lg:.5rem;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::-moz-placeholder{opacity:1}::placeholder{opacity:1}@supports (not (-webkit-appearance:-apple-pay-button)) or (contain-intrinsic-size:1px){::-moz-placeholder{color:currentColor}::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::-moz-placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;-moz-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;-moz-appearance:button;appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}:where(:host),:host:has(input.theme-controller[value=light]:checked),[data-theme=light]{color-scheme:light;--color-base-100:oklch(100% 0 0);--color-base-200:oklch(98% 0 0);--color-base-300:oklch(95% 0 0);--color-base-content:oklch(21% .006 285.885);--color-primary:oklch(45% .24 277.023);--color-primary-content:oklch(93% .034 272.788);--color-secondary:oklch(65% .241 354.308);--color-secondary-content:oklch(94% .028 342.258);--color-accent:oklch(77% .152 181.912);--color-accent-content:oklch(38% .063 188.416);--color-neutral:oklch(14% .005 285.823);--color-neutral-content:oklch(92% .004 286.32);--color-info:oklch(74% .16 232.661);--color-info-content:oklch(29% .066 243.157);--color-success:oklch(76% .177 163.223);--color-success-content:oklch(37% .077 168.94);--color-warning:oklch(82% .189 84.429);--color-warning-content:oklch(41% .112 45.904);--color-error:oklch(71% .194 13.428);--color-error-content:oklch(27% .105 12.094);--radius-selector:.5rem;--radius-field:.25rem;--radius-box:.5rem;--size-selector:.25rem;--size-field:.25rem;--border:1px;--depth:1;--noise:0}@property --radialprogress{syntax: "<percentage>"; inherits: true; initial-value: 0%;}:root{scrollbar-color:currentColor #0000}@supports (color:color-mix(in lab, red, red)){:root{scrollbar-color:color-mix(in oklch,currentColor 35%,#0000)#0000}}:root:has(.modal-open,.modal[open],.modal:target,.modal-toggle:checked,.drawer:not([class*=drawer-open])>.drawer-toggle:checked){overflow:hidden}:root,[data-theme]{background-color:var(--root-bg,var(--color-base-100));color:var(--color-base-content)}:root{--fx-noise:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='a'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.34' numOctaves='4' stitchTiles='stitch'%3E%3C/feTurbulence%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)' opacity='0.2'%3E%3C/rect%3E%3C/svg%3E")}.chat{--mask-chat:url("data:image/svg+xml,%3csvg width='13' height='13' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill='black' d='M0 11.5004C0 13.0004 2 13.0004 2 13.0004H12H13V0.00036329L12.5 0C12.5 0 11.977 2.09572 11.8581 2.50033C11.6075 3.35237 10.9149 4.22374 9 5.50036C6 7.50036 0 10.0004 0 11.5004Z'/%3e%3c/svg%3e")}:where(:root:has(.modal-open,.modal[open],.modal:target,.modal-toggle:checked,.drawer:not(.drawer-open)>.drawer-toggle:checked)){scrollbar-gutter:stable;background-image:linear-gradient(var(--color-base-100),var(--color-base-100));--root-bg:color-mix(in srgb,var(--color-base-100),oklch(0% 0 0) 40%)}@supports (color:color-mix(in lab, red, red)){:where(:root:has(.modal-open,.modal[open],.modal:target,.modal-toggle:checked,.drawer:not(.drawer-open)>.drawer-toggle:checked)){--root-bg:color-mix(in srgb,var(--color-base-100),oklch(0% 0 0) 40%)}}}@layer components;@layer utilities{.diff{webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;direction:ltr;grid-template-columns:auto 1fr;width:100%;display:grid;position:relative;overflow:hidden;container-type:inline-size}.diff:focus-visible,.diff:has(.diff-item-1:focus),.diff:focus-visible{outline-style:var(--tw-outline-style);outline-offset:1px;outline-width:2px;outline-color:var(--color-base-content)}.diff:focus-visible .diff-resizer{min-width:90cqi;max-width:90cqi}.diff:has(.diff-item-2:focus-visible){outline-style:var(--tw-outline-style);outline-offset:1px;outline-width:2px}.diff:has(.diff-item-2:focus-visible) .diff-resizer{min-width:10cqi;max-width:10cqi}@supports (-webkit-overflow-scrolling:touch) and (overflow:-webkit-paged-x){.diff:focus .diff-resizer{min-width:10cqi;max-width:10cqi}.diff:has(.diff-item-1:focus) .diff-resizer{min-width:90cqi;max-width:90cqi}}.\\@container{container-type:inline-size}.modal{pointer-events:none;visibility:hidden;width:100%;max-width:none;height:100%;max-height:none;color:inherit;transition:transform .3s ease-out,visibility .3s allow-discrete,background-color .3s ease-out,opacity .1s ease-out;overscroll-behavior:contain;z-index:999;background-color:#0000;place-items:center;margin:0;padding:0;display:grid;position:fixed;inset:0;overflow:hidden}.modal::backdrop{display:none}.modal.modal-open,.modal[open],.modal:target{pointer-events:auto;visibility:visible;opacity:1;background-color:oklch(0% 0 0/.4);transition:transform .3s ease-out,background-color .3s ease-out,opacity .1s ease-out}:is(.modal.modal-open,.modal[open],.modal:target) .modal-box{opacity:1;translate:0;scale:1}@starting-style{.modal.modal-open,.modal[open],.modal:target{visibility:hidden;opacity:0}}.tooltip{--tt-bg:var(--color-neutral);--tt-off:calc(100% + .5rem);--tt-tail:calc(100% + 1px + .25rem);display:inline-block;position:relative}.tooltip>:where(.tooltip-content),.tooltip[data-tip]:before{border-radius:var(--radius-field);text-align:center;white-space:normal;max-width:20rem;color:var(--color-neutral-content);opacity:0;background-color:var(--tt-bg);pointer-events:none;z-index:1;--tw-content:attr(data-tip);content:var(--tw-content);width:-moz-max-content;width:max-content;padding-block:.25rem;padding-inline:.5rem;font-size:.875rem;line-height:1.25em;transition:opacity .2s cubic-bezier(.4,0,.2,1) 75ms,transform .2s cubic-bezier(.4,0,.2,1) 75ms;position:absolute}.tooltip:after{opacity:0;background-color:var(--tt-bg);content:"";pointer-events:none;--mask-tooltip:url("data:image/svg+xml,%3Csvg width='10' height='4' viewBox='0 0 8 4' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0.500009 1C3.5 1 3.00001 4 5.00001 4C7 4 6.5 1 9.5 1C10 1 10 0.499897 10 0H0C-1.99338e-08 0.5 0 1 0.500009 1Z' fill='black'/%3E%3C/svg%3E%0A");width:.625rem;height:.25rem;-webkit-mask-position:-1px 0;mask-position:-1px 0;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-image:var(--mask-tooltip);-webkit-mask-image:var(--mask-tooltip);mask-image:var(--mask-tooltip);transition:opacity .2s cubic-bezier(.4,0,.2,1) 75ms,transform .2s cubic-bezier(.4,0,.2,1) 75ms;display:block;position:absolute}:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible))>.tooltip-content,:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible))[data-tip]:before,:is(.tooltip.tooltip-open,.tooltip[data-tip]:hover,.tooltip:hover,.tooltip:has(:focus-visible)):after{opacity:1;--tt-pos:0rem;transition:opacity .2s cubic-bezier(.4,0,.2,1),transform .2s cubic-bezier(.4,0,.2,1)}.tooltip>.tooltip-content,.tooltip[data-tip]:before{transform:translateX(-50%)translateY(var(--tt-pos,.25rem));inset:auto auto var(--tt-off)50%}.tooltip:after{transform:translateX(-50%)translateY(var(--tt-pos,.25rem));inset:auto auto var(--tt-tail)50%}.tab{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;text-align:center;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;--tab-p:1rem;--tab-bg:var(--color-base-100);--tab-border-color:var(--color-base-300);--tab-radius-ss:0;--tab-radius-se:0;--tab-radius-es:0;--tab-radius-ee:0;--tab-order:0;--tab-radius-min:calc(.75rem - var(--border));flex-wrap:wrap;order:var(--tab-order);height:calc(var(--size-field,.25rem)*10);border-color:#0000;justify-content:center;align-items:center;padding-inline-start:var(--tab-p);padding-inline-end:var(--tab-p);font-size:.875rem;display:inline-flex;position:relative}@media (hover:hover){.tab:hover{color:var(--color-base-content)}}.tab:is(input[type=radio]){min-width:-moz-fit-content;min-width:fit-content}.tab:is(input[type=radio]):after{content:attr(aria-label)}.tab:is(label){position:relative}.tab:is(label) input{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;opacity:0;position:absolute;inset:0}:is(.tab:checked,.tab:is(label:has(:checked)),.tab:is(.tab-active,[aria-selected=true]))+.tab-content{height:100%;display:block}.tab:not(:checked,label:has(:checked),:hover,.tab-active,[aria-selected=true]){color:color-mix(in srgb,var(--color-base-content)50%,transparent)}@supports (color:color-mix(in lab, red, red)){.tab:not(:checked,label:has(:checked),:hover,.tab-active,[aria-selected=true]){color:color-mix(in oklab,var(--color-base-content)50%,transparent)}}.tab:not(input):empty{cursor:default;flex-grow:1}.tab:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.tab:focus{outline-offset:2px;outline:2px solid #0000}}.tab:focus-visible,.tab:is(label:has(:checked:focus-visible)){outline-offset:-5px;outline:2px solid}.tab[disabled]{pointer-events:none;opacity:.4}.menu{--menu-active-fg:var(--color-neutral-content);--menu-active-bg:var(--color-neutral);flex-flow:column wrap;width:-moz-fit-content;width:fit-content;padding:.5rem;font-size:.875rem;display:flex}.menu :where(li ul){white-space:nowrap;margin-inline-start:1rem;padding-inline-start:.5rem;position:relative}.menu :where(li ul):before{background-color:var(--color-base-content);opacity:.1;width:var(--border);content:"";inset-inline-start:0;position:absolute;top:.75rem;bottom:.75rem}.menu :where(li>.menu-dropdown:not(.menu-dropdown-show)){display:none}.menu :where(li:not(.menu-title)>:not(ul,details,.menu-title,.btn)),.menu :where(li:not(.menu-title)>details>summary:not(.menu-title)){border-radius:var(--radius-field);text-align:start;text-wrap:balance;-webkit-user-select:none;-moz-user-select:none;user-select:none;grid-auto-columns:minmax(auto,max-content) auto max-content;grid-auto-flow:column;align-content:flex-start;align-items:center;gap:.5rem;padding-block:.375rem;padding-inline:.75rem;transition-property:color,background-color,box-shadow;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);display:grid}.menu :where(li>details>summary){--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.menu :where(li>details>summary){outline-offset:2px;outline:2px solid #0000}}.menu :where(li>details>summary)::-webkit-details-marker{display:none}:is(.menu :where(li>details>summary),.menu :where(li>.menu-dropdown-toggle)):after{content:"";transform-origin:50%;pointer-events:none;justify-self:flex-end;width:.375rem;height:.375rem;transition-property:rotate,translate;transition-duration:.2s;display:block;translate:0 -1px;rotate:-135deg;box-shadow:inset 2px 2px}.menu :where(li>details[open]>summary):after,.menu :where(li>.menu-dropdown-toggle.menu-dropdown-show):after{translate:0 1px;rotate:45deg}.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn).menu-focus,.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn):focus-visible{cursor:pointer;background-color:color-mix(in srgb,var(--color-base-content)10%,transparent);color:var(--color-base-content);--tw-outline-style:none;outline-style:none}@supports (color:color-mix(in lab, red, red)){:is(.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn).menu-focus,.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn):focus-visible){background-color:color-mix(in oklab,var(--color-base-content)10%,transparent)}}@media (forced-colors:active){:is(.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn).menu-focus,.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title),li:not(.menu-title,.disabled)>details>summary:not(.menu-title)):not(.menu-active,:active,.btn):focus-visible){outline-offset:2px;outline:2px solid #0000}}.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title):not(.menu-active,:active,.btn):hover,li:not(.menu-title,.disabled)>details>summary:not(.menu-title):not(.menu-active,:active,.btn):hover){cursor:pointer;background-color:color-mix(in srgb,var(--color-base-content)10%,transparent);--tw-outline-style:none;outline-style:none;box-shadow:inset 0 1px oklch(0% 0 0/.01),inset 0 -1px oklch(100% 0 0/.01)}@supports (color:color-mix(in lab, red, red)){.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title):not(.menu-active,:active,.btn):hover,li:not(.menu-title,.disabled)>details>summary:not(.menu-title):not(.menu-active,:active,.btn):hover){background-color:color-mix(in oklab,var(--color-base-content)10%,transparent)}}@media (forced-colors:active){.menu :where(li:not(.menu-title,.disabled)>:not(ul,details,.menu-title):not(.menu-active,:active,.btn):hover,li:not(.menu-title,.disabled)>details>summary:not(.menu-title):not(.menu-active,:active,.btn):hover){outline-offset:2px;outline:2px solid #0000}}.menu :where(li:empty){background-color:var(--color-base-content);opacity:.1;height:1px;margin:.5rem 1rem}.menu :where(li){flex-flow:column wrap;flex-shrink:0;align-items:stretch;display:flex;position:relative}.menu :where(li) .badge{justify-self:flex-end}.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active{--tw-outline-style:none;color:var(--menu-active-fg);background-color:var(--menu-active-bg);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);outline-style:none}@media (forced-colors:active){:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active){outline-offset:2px;outline:2px solid #0000}}:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active):not(:is(.menu :where(li)>:not(ul,.menu-title,details,.btn):active,.menu :where(li)>:not(ul,.menu-title,details,.btn).menu-active,.menu :where(li)>details>summary:active):active){box-shadow:0 2px calc(var(--depth)*3px)-2px var(--menu-active-bg)}.menu :where(li).menu-disabled{pointer-events:none;color:color-mix(in srgb,var(--color-base-content)20%,transparent)}@supports (color:color-mix(in lab, red, red)){.menu :where(li).menu-disabled{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}}.menu .dropdown:focus-within .menu-dropdown-toggle:after{translate:0 1px;rotate:45deg}.menu .dropdown-content{margin-top:.5rem;padding:.5rem}.menu .dropdown-content:before{display:none}.dropdown{position-area:var(--anchor-v,bottom)var(--anchor-h,span-right);display:inline-block;position:relative}.dropdown>:not(summary):focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.dropdown>:not(summary):focus{outline-offset:2px;outline:2px solid #0000}}.dropdown .dropdown-content{position:absolute}.dropdown:not(details,.dropdown-open,.dropdown-hover:hover,:focus-within) .dropdown-content{transform-origin:top;opacity:0;display:none;scale:95%}.dropdown[popover],.dropdown .dropdown-content{z-index:999;transition-behavior:allow-discrete;transition-property:opacity,scale,display;transition-duration:.2s;transition-timing-function:cubic-bezier(.4,0,.2,1);animation:.2s dropdown}@starting-style{.dropdown[popover],.dropdown .dropdown-content{opacity:0;scale:95%}}:is(.dropdown.dropdown-open,.dropdown:not(.dropdown-hover):focus,.dropdown:focus-within)>[tabindex]:first-child{pointer-events:none}:is(.dropdown.dropdown-open,.dropdown:not(.dropdown-hover):focus,.dropdown:focus-within) .dropdown-content{opacity:1}.dropdown.dropdown-hover:hover .dropdown-content{opacity:1;scale:100%}.dropdown:is(details) summary::-webkit-details-marker{display:none}:is(.dropdown.dropdown-open,.dropdown:focus,.dropdown:focus-within) .dropdown-content{scale:100%}.dropdown:where([popover]){background:0 0}.dropdown[popover]{color:inherit;position:fixed}@supports not (position-area:bottom){.dropdown[popover]{margin:auto}.dropdown[popover].dropdown-open:not(:popover-open){transform-origin:top;opacity:0;display:none;scale:95%}.dropdown[popover]::backdrop{background-color:oklab(0% none none/.3)}}.dropdown[popover]:not(.dropdown-open,:popover-open){transform-origin:top;opacity:0;display:none;scale:95%}.btn{cursor:pointer;text-align:center;vertical-align:middle;outline-offset:2px;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;padding-inline:var(--btn-p);color:var(--btn-fg);--tw-prose-links:var(--btn-fg);height:var(--size);font-size:var(--fontsize,.875rem);outline-color:var(--btn-color,var(--color-base-content));background-color:var(--btn-bg);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--btn-noise);border-width:var(--border);border-style:solid;border-color:var(--btn-border);text-shadow:0 .5px oklch(100% 0 0/calc(var(--depth)*.15));box-shadow:0 .5px 0 .5px oklch(100% 0 0/calc(var(--depth)*6%))inset,var(--btn-shadow);--size:calc(var(--size-field,.25rem)*10);--btn-bg:var(--btn-color,var(--color-base-200));--btn-fg:var(--color-base-content);--btn-p:1rem;--btn-border:var(--btn-bg);--btn-shadow:0 3px 2px -2px var(--btn-bg),0 4px 3px -2px var(--btn-bg);--btn-noise:var(--fx-noise);border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-wrap:nowrap;flex-shrink:0;justify-content:center;align-items:center;gap:.375rem;font-weight:600;transition-property:color,background-color,border-color,box-shadow;transition-duration:.2s;transition-timing-function:cubic-bezier(0,0,.2,1);display:inline-flex}:where(.btn){width:unset}@supports (color:color-mix(in lab, red, red)){.btn{--btn-border:color-mix(in oklab,var(--btn-bg),#000 calc(var(--depth)*5%));--btn-shadow:0 3px 2px -2px color-mix(in oklab,var(--btn-bg)calc(var(--depth)*30%),#0000),0 4px 3px -2px color-mix(in oklab,var(--btn-bg)calc(var(--depth)*30%),#0000)}}.prose .btn{text-decoration-line:none}@media (hover:hover){.btn:hover{--btn-bg:var(--btn-color,var(--color-base-200))}@supports (color:color-mix(in lab, red, red)){.btn:hover{--btn-bg:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 7%)}}}.btn:focus-visible{outline-width:2px;outline-style:solid}.btn:active:not(.btn-active){--btn-bg:var(--btn-color,var(--color-base-200));--btn-border:var(--btn-color,var(--color-base-200));--btn-shadow:0 0 0 0 oklch(0% 0 0/0),0 0 0 0 oklch(0% 0 0/0);translate:0 .5px}@supports (color:color-mix(in lab, red, red)){.btn:active:not(.btn-active){--btn-bg:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 5%);--btn-border:color-mix(in oklab,var(--btn-color,var(--color-base-200)),#000 7%)}}.btn:is(:disabled,[disabled],.btn-disabled){pointer-events:none;--btn-border:#0000;--btn-noise:none;--btn-fg:color-mix(in srgb,var(--color-base-content)20%,#0000)}.btn:is(:disabled,[disabled],.btn-disabled):not(.btn-link,.btn-ghost){background-color:color-mix(in srgb,var(--color-base-content)10%,transparent);box-shadow:none}@supports (color:color-mix(in lab, red, red)){.btn:is(:disabled,[disabled],.btn-disabled):not(.btn-link,.btn-ghost){background-color:color-mix(in oklab,var(--color-base-content)10%,transparent)}.btn:is(:disabled,[disabled],.btn-disabled){--btn-fg:color-mix(in oklch,var(--color-base-content)20%,#0000)}}@media (hover:hover){.btn:is(:disabled,[disabled],.btn-disabled):hover{pointer-events:none;background-color:color-mix(in srgb,var(--color-neutral)20%,transparent);--btn-border:#0000;--btn-fg:color-mix(in srgb,var(--color-base-content)20%,#0000)}@supports (color:color-mix(in lab, red, red)){.btn:is(:disabled,[disabled],.btn-disabled):hover{background-color:color-mix(in oklab,var(--color-neutral)20%,transparent);--btn-fg:color-mix(in oklch,var(--color-base-content)20%,#0000)}}}.btn:is(input[type=checkbox],input[type=radio]){-webkit-appearance:none;-moz-appearance:none;appearance:none}.btn:is(input[type=checkbox],input[type=radio]):after{content:attr(aria-label)}.btn:where(input:checked:not(.filter .btn)){--btn-color:var(--color-primary);--btn-fg:var(--color-primary-content);isolation:isolate}.loading{pointer-events:none;aspect-ratio:1;vertical-align:middle;width:calc(var(--size-selector,.25rem)*6);background-color:currentColor;display:inline-block;-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");-webkit-mask-position:50%;mask-position:50%;-webkit-mask-size:100%;mask-size:100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.invisible{visibility:hidden}.visible{visibility:visible}.list{flex-direction:column;font-size:.875rem;display:flex}.list :where(.list-row){--list-grid-cols:minmax(0,auto)1fr;border-radius:var(--radius-box);word-break:break-word;grid-auto-flow:column;grid-template-columns:var(--list-grid-cols);gap:1rem;padding:1rem;display:grid;position:relative}.list :where(.list-row):has(.list-col-grow:first-child){--list-grid-cols:1fr}.list :where(.list-row):has(.list-col-grow:nth-child(2)){--list-grid-cols:minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(3)){--list-grid-cols:minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(4)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(5)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row):has(.list-col-grow:nth-child(6)){--list-grid-cols:minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)minmax(0,auto)1fr}.list :where(.list-row) :not(.list-col-wrap){grid-row-start:1}:is(.list>:not(:last-child).list-row,.list>:not(:last-child) .list-row):after{content:"";border-bottom:var(--border)solid;inset-inline:var(--radius-box);border-color:color-mix(in srgb,var(--color-base-content)5%,transparent);position:absolute;bottom:0}@supports (color:color-mix(in lab, red, red)){:is(.list>:not(:last-child).list-row,.list>:not(:last-child) .list-row):after{border-color:color-mix(in oklab,var(--color-base-content)5%,transparent)}}.toggle{border:var(--border)solid currentColor;color:var(--input-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;vertical-align:middle;webkit-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;--radius-selector-max:calc(var(--radius-selector) + var(--radius-selector) + var(--radius-selector));border-radius:calc(var(--radius-selector) + min(var(--toggle-p),var(--radius-selector-max)) + min(var(--border),var(--radius-selector-max)));padding:var(--toggle-p);--input-color:color-mix(in srgb,var(--color-base-content)50%,#0000);--toggle-p:.1875rem;--size:calc(var(--size-selector,.25rem)*6);width:calc((var(--size)*2) - (var(--border) + var(--toggle-p))*2);height:var(--size);flex-shrink:0;grid-template-columns:0fr 1fr 1fr;place-content:center;transition:color .3s,grid-template-columns .2s;display:inline-grid;position:relative;box-shadow:inset 0 1px}@supports (color:color-mix(in lab, red, red)){.toggle{box-shadow:0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000)inset;--input-color:color-mix(in oklab,var(--color-base-content)50%,#0000)}}.toggle>*{z-index:1;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;border:none;grid-column:2/span 1;grid-row-start:1;height:100%;padding:.125rem;transition:opacity .2s,rotate .4s}.toggle>:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.toggle>:focus{outline-offset:2px;outline:2px solid #0000}}.toggle>:nth-child(2){color:var(--color-base-100);rotate:none}.toggle>:nth-child(3){color:var(--color-base-100);opacity:0;rotate:-15deg}.toggle:has(:checked)>:nth-child(2){opacity:0;rotate:15deg}.toggle:has(:checked)>:nth-child(3){opacity:1;rotate:none}.toggle:before{aspect-ratio:1;border-radius:var(--radius-selector);--tw-content:"";content:var(--tw-content);height:100%;box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px currentColor;background-color:currentColor;background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);grid-row-start:1;grid-column-start:2;transition:background-color .1s,translate .2s,inset-inline-start .2s;position:relative;inset-inline-start:0;translate:0}@supports (color:color-mix(in lab, red, red)){.toggle:before{box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000)}}@media (forced-colors:active){.toggle:before{outline-style:var(--tw-outline-style);outline-offset:calc(1px*-1);outline-width:1px}}@media print{.toggle:before{outline-offset:-1rem;outline:.25rem solid}}.toggle:focus-visible,.toggle:has(:focus-visible){outline-offset:2px;outline:2px solid}.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked){background-color:var(--color-base-100);--input-color:var(--color-base-content);grid-template-columns:1fr 1fr 0fr}:is(.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked)):before{background-color:currentColor}@starting-style{:is(.toggle:checked,.toggle[aria-checked=true],.toggle:has(>input:checked)):before{opacity:0}}.toggle:indeterminate{grid-template-columns:.5fr 1fr .5fr}.toggle:disabled{cursor:not-allowed;opacity:.3}.toggle:disabled:before{border:var(--border)solid currentColor;background-color:#0000}.input{cursor:text;border:var(--border)solid #0000;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--color-base-100);vertical-align:middle;white-space:nowrap;width:clamp(3rem,20rem,100%);height:var(--size);border-color:var(--input-color);box-shadow:0 1px var(--input-color)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;--size:calc(var(--size-field,.25rem)*10);--input-color:color-mix(in srgb,var(--color-base-content)20%,#0000);border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-shrink:1;align-items:center;gap:.5rem;padding-inline:.75rem;font-size:.875rem;display:inline-flex;position:relative}@supports (color:color-mix(in lab, red, red)){.input{box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;--input-color:color-mix(in oklab,var(--color-base-content)20%,#0000)}}.input:where(input){display:inline-flex}.input :where(input){-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;border:none;width:100%;height:100%;display:inline-flex}.input :where(input):focus,.input :where(input):focus-within{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){:is(.input :where(input):focus,.input :where(input):focus-within){outline-offset:2px;outline:2px solid #0000}}.input :where(input[type=date]){display:inline-block}.input:focus,.input:focus-within{--input-color:var(--color-base-content);box-shadow:0 1px var(--input-color);outline:2px solid var(--input-color);outline-offset:2px;isolation:isolate}@supports (color:color-mix(in lab, red, red)){:is(.input:focus,.input:focus-within){box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)}}.input:has(>input[disabled]),.input:is(:disabled,[disabled]){cursor:not-allowed;border-color:var(--color-base-200);background-color:var(--color-base-200);color:color-mix(in srgb,var(--color-base-content)40%,transparent);box-shadow:none}@supports (color:color-mix(in lab, red, red)){:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled])){color:color-mix(in oklab,var(--color-base-content)40%,transparent)}}:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in srgb,var(--color-base-content)20%,transparent)}:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::placeholder{color:color-mix(in srgb,var(--color-base-content)20%,transparent)}@supports (color:color-mix(in lab, red, red)){:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}:is(.input:has(>input[disabled]),.input:is(:disabled,[disabled]))::placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}}.input:has(>input[disabled])>input[disabled]{cursor:not-allowed}.input::-webkit-date-and-time-value{text-align:inherit}.input[type=number]::-webkit-inner-spin-button{margin-block:-.75rem;margin-inline-end:-.75rem}.input::-webkit-calendar-picker-indicator{position:absolute;inset-inline-end:.75em}.indicator{width:-moz-max-content;width:max-content;display:inline-flex;position:relative}.indicator :where(.indicator-item){z-index:1;white-space:nowrap;top:var(--inidicator-t,0);bottom:var(--inidicator-b,auto);left:var(--inidicator-s,auto);right:var(--inidicator-e,0);translate:var(--inidicator-x,50%)var(--indicator-y,-50%);position:absolute}.table{border-radius:var(--radius-box);text-align:left;width:100%;font-size:.875rem;position:relative}.table:where(:dir(rtl),[dir=rtl],[dir=rtl] *){text-align:right}@media (hover:hover){:is(.table tr.row-hover,.table tr.row-hover:nth-child(2n)):hover{background-color:var(--color-base-200)}}.table :where(th,td){vertical-align:middle;padding-block:.75rem;padding-inline:1rem}.table :where(thead,tfoot){white-space:nowrap;color:color-mix(in srgb,var(--color-base-content)60%,transparent);font-size:.875rem;font-weight:600}@supports (color:color-mix(in lab, red, red)){.table :where(thead,tfoot){color:color-mix(in oklab,var(--color-base-content)60%,transparent)}}.table :where(tfoot){border-top:var(--border)solid color-mix(in srgb,var(--color-base-content)5%,#0000)}@supports (color:color-mix(in lab, red, red)){.table :where(tfoot){border-top:var(--border)solid color-mix(in oklch,var(--color-base-content)5%,#0000)}}.table :where(.table-pin-rows thead tr){z-index:1;background-color:var(--color-base-100);position:sticky;top:0}.table :where(.table-pin-rows tfoot tr){z-index:1;background-color:var(--color-base-100);position:sticky;bottom:0}.table :where(.table-pin-cols tr th){background-color:var(--color-base-100);position:sticky;left:0;right:0}.table :where(thead tr,tbody tr:not(:last-child)){border-bottom:var(--border)solid color-mix(in srgb,var(--color-base-content)5%,#0000)}@supports (color:color-mix(in lab, red, red)){.table :where(thead tr,tbody tr:not(:last-child)){border-bottom:var(--border)solid color-mix(in oklch,var(--color-base-content)5%,#0000)}}.steps{counter-reset:step;grid-auto-columns:1fr;grid-auto-flow:column;display:inline-grid;overflow:auto hidden}.steps .step{text-align:center;--step-bg:var(--color-base-300);--step-fg:var(--color-base-content);grid-template-rows:40px 1fr;grid-template-columns:auto;place-items:center;min-width:4rem;display:grid}.steps .step:before{width:100%;height:.5rem;color:var(--step-bg);background-color:var(--step-bg);--tw-content:"";content:var(--tw-content);border:1px solid;grid-row-start:1;grid-column-start:1;margin-inline-start:-100%;top:0}.steps .step>.step-icon,.steps .step:not(:has(.step-icon)):after{content:counter(step);counter-increment:step;z-index:1;color:var(--step-fg);background-color:var(--step-bg);border:1px solid var(--step-bg);border-radius:3.40282e38px;grid-row-start:1;grid-column-start:1;place-self:center;place-items:center;width:2rem;height:2rem;display:grid;position:relative}.steps .step:first-child:before{content:none}.steps .step[data-content]:after{content:attr(data-content)}.steps .step-neutral+.step-neutral:before,.steps .step-neutral:after,.steps .step-neutral>.step-icon{--step-bg:var(--color-neutral);--step-fg:var(--color-neutral-content)}.steps .step-primary+.step-primary:before,.steps .step-primary:after,.steps .step-primary>.step-icon{--step-bg:var(--color-primary);--step-fg:var(--color-primary-content)}.steps .step-secondary+.step-secondary:before,.steps .step-secondary:after,.steps .step-secondary>.step-icon{--step-bg:var(--color-secondary);--step-fg:var(--color-secondary-content)}.steps .step-accent+.step-accent:before,.steps .step-accent:after,.steps .step-accent>.step-icon{--step-bg:var(--color-accent);--step-fg:var(--color-accent-content)}.steps .step-info+.step-info:before,.steps .step-info:after,.steps .step-info>.step-icon{--step-bg:var(--color-info);--step-fg:var(--color-info-content)}.steps .step-success+.step-success:before,.steps .step-success:after,.steps .step-success>.step-icon{--step-bg:var(--color-success);--step-fg:var(--color-success-content)}.steps .step-warning+.step-warning:before,.steps .step-warning:after,.steps .step-warning>.step-icon{--step-bg:var(--color-warning);--step-fg:var(--color-warning-content)}.steps .step-error+.step-error:before,.steps .step-error:after,.steps .step-error>.step-icon{--step-bg:var(--color-error);--step-fg:var(--color-error-content)}.range{-webkit-appearance:none;-moz-appearance:none;appearance:none;webkit-appearance:none;--range-thumb:var(--color-base-100);--range-thumb-size:calc(var(--size-selector,.25rem)*6);--range-progress:currentColor;--range-fill:1;--range-p:.25rem;--range-bg:currentColor;cursor:pointer;vertical-align:middle;--radius-selector-max:calc(var(--radius-selector) + var(--radius-selector) + var(--radius-selector));border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));width:clamp(3rem,20rem,100%);height:var(--range-thumb-size);background-color:#0000;border:none;overflow:hidden}@supports (color:color-mix(in lab, red, red)){.range{--range-bg:color-mix(in oklab,currentColor 10%,#0000)}}[dir=rtl] .range{--range-dir:-1}.range:focus{outline:none}.range:focus-visible{outline-offset:2px;outline:2px solid}.range::-webkit-slider-runnable-track{background-color:var(--range-bg);border-radius:var(--radius-selector);width:100%;height:calc(var(--range-thumb-size)*.5)}@media (forced-colors:active){.range::-webkit-slider-runnable-track{border:1px solid}.range::-moz-range-track{border:1px solid}}.range::-webkit-slider-thumb{box-sizing:border-box;border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));height:var(--range-thumb-size);width:var(--range-thumb-size);border:var(--range-p)solid;-webkit-appearance:none;appearance:none;webkit-appearance:none;color:var(--range-progress);box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px currentColor,0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill));background-color:currentColor;position:relative;top:50%;transform:translateY(-50%)}@supports (color:color-mix(in lab, red, red)){.range::-webkit-slider-thumb{box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000),0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill))}}.range::-moz-range-track{background-color:var(--range-bg);border-radius:var(--radius-selector);width:100%;height:calc(var(--range-thumb-size)*.5)}.range::-moz-range-thumb{box-sizing:border-box;border-radius:calc(var(--radius-selector) + min(var(--range-p),var(--radius-selector-max)));height:var(--range-thumb-size);width:var(--range-thumb-size);border:var(--range-p)solid;color:var(--range-progress);box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px currentColor,0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill));background-color:currentColor;position:relative;top:50%}@supports (color:color-mix(in lab, red, red)){.range::-moz-range-thumb{box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px color-mix(in oklab,currentColor calc(var(--depth)*10%),#0000),0 0 0 2rem var(--range-thumb)inset,calc((var(--range-dir,1)*-100rem) - (var(--range-dir,1)*var(--range-thumb-size)/2))0 0 calc(100rem*var(--range-fill))}}.range:disabled{cursor:not-allowed;opacity:.3}.select{border:var(--border)solid #0000;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--color-base-100);vertical-align:middle;width:clamp(3rem,20rem,100%);height:var(--size);text-overflow:ellipsis;box-shadow:0 1px var(--input-color)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;border-color:var(--input-color);--input-color:color-mix(in srgb,var(--color-base-content)20%,#0000);--size:calc(var(--size-field,.25rem)*10);background-image:linear-gradient(45deg,#0000 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,#0000 50%);background-position:calc(100% - 20px) calc(1px + 50%),calc(100% - 16.1px) calc(1px + 50%);background-repeat:no-repeat;background-size:4px 4px,4px 4px;border-start-start-radius:var(--join-ss,var(--radius-field));border-start-end-radius:var(--join-se,var(--radius-field));border-end-end-radius:var(--join-ee,var(--radius-field));border-end-start-radius:var(--join-es,var(--radius-field));flex-shrink:1;align-items:center;gap:.375rem;padding-inline:1rem 1.75rem;font-size:.875rem;display:inline-flex;position:relative}@supports (color:color-mix(in lab, red, red)){.select{box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)inset,0 -1px oklch(100% 0 0/calc(var(--depth)*.1))inset;--input-color:color-mix(in oklab,var(--color-base-content)20%,#0000)}}[dir=rtl] .select{background-position:12px calc(1px + 50%),16px calc(1px + 50%)}.select select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:inherit;border-radius:inherit;border-style:none;width:calc(100% + 2.75rem);height:calc(100% - 2px);margin-inline:-1rem -1.75rem;padding-inline:1rem 1.75rem}.select select:focus,.select select:focus-within{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){:is(.select select:focus,.select select:focus-within){outline-offset:2px;outline:2px solid #0000}}.select select:not(:last-child){background-image:none;margin-inline-end:-1.375rem}.select:focus,.select:focus-within{--input-color:var(--color-base-content);box-shadow:0 1px var(--input-color);outline:2px solid var(--input-color);outline-offset:2px}@supports (color:color-mix(in lab, red, red)){:is(.select:focus,.select:focus-within){box-shadow:0 1px color-mix(in oklab,var(--input-color)calc(var(--depth)*10%),#0000)}}.select:has(>select[disabled]),.select:is(:disabled,[disabled]){cursor:not-allowed;border-color:var(--color-base-200);background-color:var(--color-base-200);color:color-mix(in srgb,var(--color-base-content)40%,transparent)}@supports (color:color-mix(in lab, red, red)){:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled])){color:color-mix(in oklab,var(--color-base-content)40%,transparent)}}:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in srgb,var(--color-base-content)20%,transparent)}:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::placeholder{color:color-mix(in srgb,var(--color-base-content)20%,transparent)}@supports (color:color-mix(in lab, red, red)){:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::-moz-placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}:is(.select:has(>select[disabled]),.select:is(:disabled,[disabled]))::placeholder{color:color-mix(in oklab,var(--color-base-content)20%,transparent)}}.select:has(>select[disabled])>select[disabled]{cursor:not-allowed}.checkbox{border:var(--border)solid var(--input-color,color-mix(in srgb,var(--color-base-content)20%,#0000));cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:var(--radius-selector);vertical-align:middle;color:var(--color-base-content);box-shadow:0 1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 0 #0000 inset,0 0 #0000;--size:calc(var(--size-selector,.25rem)*6);width:var(--size);height:var(--size);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);flex-shrink:0;padding:.25rem;transition:background-color .2s,box-shadow .2s;position:relative}@supports (color:color-mix(in lab, red, red)){.checkbox{border:var(--border)solid var(--input-color,color-mix(in oklab,var(--color-base-content)20%,#0000))}}.checkbox:before{--tw-content:"";content:var(--tw-content);opacity:0;clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 80%,70% 80%,70% 100%);width:100%;height:100%;box-shadow:0px 3px 0 0px oklch(100% 0 0/calc(var(--depth)*.1))inset;background-color:currentColor;font-size:1rem;line-height:.75;transition:clip-path .3s .1s,opacity .1s .1s,rotate .3s .1s,translate .3s .1s;display:block;rotate:45deg}.checkbox:focus-visible{outline:2px solid var(--input-color,currentColor);outline-offset:2px}.checkbox:checked,.checkbox[aria-checked=true]{background-color:var(--input-color,#0000);box-shadow:0 0 #0000 inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px oklch(0% 0 0/calc(var(--depth)*.1))}:is(.checkbox:checked,.checkbox[aria-checked=true]):before{clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 0%,70% 0%,70% 100%);opacity:1}@media (forced-colors:active){:is(.checkbox:checked,.checkbox[aria-checked=true]):before{--tw-content:"✔︎";clip-path:none;background-color:#0000;rotate:none}}@media print{:is(.checkbox:checked,.checkbox[aria-checked=true]):before{--tw-content:"✔︎";clip-path:none;background-color:#0000;rotate:none}}.checkbox:indeterminate:before{opacity:1;clip-path:polygon(20% 100%,20% 80%,50% 80%,50% 80%,80% 80%,80% 100%);translate:0 -35%;rotate:none}.checkbox:disabled{cursor:not-allowed;opacity:.2}.radio{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;vertical-align:middle;border:var(--border)solid var(--input-color,currentColor);box-shadow:0 1px oklch(0% 0 0/calc(var(--depth)*.1))inset;--size:calc(var(--size-selector,.25rem)*6);width:var(--size);height:var(--size);color:var(--input-color,currentColor);border-radius:3.40282e38px;flex-shrink:0;padding:.25rem;position:relative}@supports (color:color-mix(in lab, red, red)){.radio{border:var(--border)solid var(--input-color,color-mix(in srgb,currentColor 20%,#0000))}}.radio:before{--tw-content:"";content:var(--tw-content);background-size:auto,calc(var(--noise)*100%);background-image:none,var(--fx-noise);border-radius:3.40282e38px;width:100%;height:100%;display:block}.radio:focus-visible{outline:2px solid}.radio:checked,.radio[aria-checked=true]{background-color:var(--color-base-100);border-color:currentColor;animation:.2s ease-out radio}:is(.radio:checked,.radio[aria-checked=true]):before{box-shadow:0 -1px oklch(0% 0 0/calc(var(--depth)*.1))inset,0 8px 0 -4px oklch(100% 0 0/calc(var(--depth)*.1))inset,0 1px oklch(0% 0 0/calc(var(--depth)*.1));background-color:currentColor}@media (forced-colors:active){:is(.radio:checked,.radio[aria-checked=true]):before{outline-style:var(--tw-outline-style);outline-offset:calc(1px*-1);outline-width:1px}}@media print{:is(.radio:checked,.radio[aria-checked=true]):before{outline-offset:-1rem;outline:.25rem solid}}.radio:disabled{cursor:not-allowed;opacity:.2}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.inset-0{inset:calc(var(--spacing)*0)}.top-0{top:calc(var(--spacing)*0)}.top-1\\/2{top:50%}.top-2{top:calc(var(--spacing)*2)}.top-full{top:100%}.right-0{right:calc(var(--spacing)*0)}.right-2{right:calc(var(--spacing)*2)}.right-10{right:calc(var(--spacing)*10)}.right-full{right:100%}.bottom-0{bottom:calc(var(--spacing)*0)}.bottom-full{bottom:100%}.left-0{left:calc(var(--spacing)*0)}.left-1\\/2{left:50%}.left-full{left:100%}.modal-backdrop{color:#0000;z-index:-1;grid-row-start:1;grid-column-start:1;place-self:stretch stretch;display:grid}.modal-backdrop button{cursor:pointer}.z-10{z-index:10}.z-1001{z-index:1001}.modal-box{background-color:var(--color-base-100);border-top-left-radius:var(--modal-tl,var(--radius-box));border-top-right-radius:var(--modal-tr,var(--radius-box));border-bottom-left-radius:var(--modal-bl,var(--radius-box));border-bottom-right-radius:var(--modal-br,var(--radius-box));opacity:0;overscroll-behavior:contain;grid-row-start:1;grid-column-start:1;width:91.6667%;max-width:32rem;max-height:100vh;padding:1.5rem;transition:translate .3s ease-out,scale .3s ease-out,opacity .2s ease-out 50ms,box-shadow .3s ease-out;overflow-y:auto;scale:95%;box-shadow:0 25px 50px -12px oklch(0% 0 0/.25)}.stat-value{white-space:nowrap;grid-column-start:1;font-size:2rem;font-weight:800}.stat-desc{white-space:nowrap;color:color-mix(in srgb,var(--color-base-content)60%,transparent);grid-column-start:1;font-size:.75rem}@supports (color:color-mix(in lab, red, red)){.stat-desc{color:color-mix(in oklab,var(--color-base-content)60%,transparent)}}.stat-title{white-space:nowrap;color:color-mix(in srgb,var(--color-base-content)60%,transparent);grid-column-start:1;font-size:.75rem}@supports (color:color-mix(in lab, red, red)){.stat-title{color:color-mix(in oklab,var(--color-base-content)60%,transparent)}}.float-right{float:right}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.divider{white-space:nowrap;height:1rem;margin:var(--divider-m,1rem 0);--divider-color:color-mix(in srgb,var(--color-base-content)10%,transparent);flex-direction:row;align-self:stretch;align-items:center;display:flex}@supports (color:color-mix(in lab, red, red)){.divider{--divider-color:color-mix(in oklab,var(--color-base-content)10%,transparent)}}.divider:before,.divider:after{content:"";background-color:var(--divider-color);flex-grow:1;width:100%;height:.125rem}@media print{.divider:before,.divider:after{border:.5px solid}}.divider:not(:empty){gap:1rem}.m-2{margin:calc(var(--spacing)*2)}.m-4{margin:calc(var(--spacing)*4)}.filter{flex-wrap:wrap;display:flex}.filter input[type=radio]{width:auto}.filter input{opacity:1;transition:margin .1s,opacity .3s,padding .3s,border-width .1s;overflow:hidden;scale:1}.filter input:not(:last-child){margin-inline-end:.25rem}.filter input.filter-reset{aspect-ratio:1}.filter input.filter-reset:after{content:"×"}.filter:not(:has(input:checked:not(.filter-reset))) .filter-reset,.filter:not(:has(input:checked:not(.filter-reset))) input[type=reset],.filter:has(input:checked:not(.filter-reset)) input:not(:checked,.filter-reset,input[type=reset]){opacity:0;border-width:0;width:0;margin-inline:0;padding-inline:0;scale:0}.mx-2{margin-inline:calc(var(--spacing)*2)}.mx-auto{margin-inline:auto}.input-sm{--size:calc(var(--size-field,.25rem)*8);font-size:.75rem}.input-sm[type=number]::-webkit-inner-spin-button{margin-block:-.5rem;margin-inline-end:-.75rem}.input-xs{--size:calc(var(--size-field,.25rem)*6);font-size:.6875rem}.input-xs[type=number]::-webkit-inner-spin-button{margin-block:-.25rem;margin-inline-end:-.75rem}.my-1{margin-block:calc(var(--spacing)*1)}.my-4{margin-block:calc(var(--spacing)*4)}.label{white-space:nowrap;color:currentColor;align-items:center;gap:.375rem;display:inline-flex}@supports (color:color-mix(in lab, red, red)){.label{color:color-mix(in oklab,currentColor 60%,transparent)}}.label:has(input){cursor:pointer}.label:is(.input>*,.select>*){white-space:nowrap;height:calc(100% - .5rem);font-size:inherit;align-items:center;padding-inline:.75rem;display:flex}.label:is(.input>*,.select>*):first-child{border-inline-end:var(--border)solid currentColor;margin-inline:-.75rem .75rem}@supports (color:color-mix(in lab, red, red)){.label:is(.input>*,.select>*):first-child{border-inline-end:var(--border)solid color-mix(in oklab,currentColor 10%,#0000)}}.label:is(.input>*,.select>*):last-child{border-inline-start:var(--border)solid currentColor;margin-inline:.75rem -.75rem}@supports (color:color-mix(in lab, red, red)){.label:is(.input>*,.select>*):last-child{border-inline-start:var(--border)solid color-mix(in oklab,currentColor 10%,#0000)}}.join-item:where(:not(:first-child)){margin-block-start:0;margin-inline-start:calc(var(--border,1px)*-1)}.modal-action{justify-content:flex-end;gap:.5rem;margin-top:1.5rem;display:flex}.mt-0{margin-top:calc(var(--spacing)*0)}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-4{margin-top:calc(var(--spacing)*4)}.mr-1{margin-right:calc(var(--spacing)*1)}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-0{margin-bottom:calc(var(--spacing)*0)}.mb-1{margin-bottom:calc(var(--spacing)*1)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.ml-1{margin-left:calc(var(--spacing)*1)}.ml-2{margin-left:calc(var(--spacing)*2)}.ml-2\\.5{margin-left:calc(var(--spacing)*2.5)}.ml-3{margin-left:calc(var(--spacing)*3)}.status{aspect-ratio:1;border-radius:var(--radius-selector);background-color:color-mix(in srgb,var(--color-base-content)20%,transparent);vertical-align:middle;color:#0000004d;background-position:50%;background-repeat:no-repeat;background-image:radial-gradient(circle at 35% 30%,oklch(1 0 0/calc(var(--depth)*.5)),#0000);width:.5rem;height:.5rem;display:inline-block;box-shadow:0 2px 3px -1px}@supports (color:color-mix(in lab, red, red)){.status{background-color:color-mix(in oklab,var(--color-base-content)20%,transparent);color:#0000004d}@supports (color:color-mix(in lab, red, red)){.status{color:color-mix(in oklab,var(--color-black)30%,transparent)}}.status{box-shadow:0 2px 3px -1px color-mix(in oklab,currentColor calc(var(--depth)*100%),#0000)}}.iconify{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.tabs{--tabs-height:auto;--tabs-direction:row;height:var(--tabs-height);flex-wrap:wrap;flex-direction:var(--tabs-direction);display:flex}.footer{grid-auto-flow:row;place-items:start;gap:2.5rem 1rem;width:100%;font-size:.875rem;line-height:1.25rem;display:grid}.footer>*{place-items:start;gap:.5rem;display:grid}.footer.footer-center{text-align:center;grid-auto-flow:column dense;place-items:center}.footer.footer-center>*{place-items:center}.stat{grid-template-columns:repeat(1,1fr);-moz-column-gap:1rem;column-gap:1rem;width:100%;padding-block:1rem;padding-inline:1.5rem;display:inline-grid}.stat:not(:last-child){border-inline-end:var(--border)dashed currentColor;border-block-end:none}@supports (color:color-mix(in lab, red, red)){.stat:not(:last-child){border-inline-end:var(--border)dashed color-mix(in oklab,currentColor 10%,#0000)}}.join{--join-ss:0;--join-se:0;--join-es:0;--join-ee:0;align-items:stretch;display:inline-flex}.join :where(.join-item){border-start-start-radius:var(--join-ss,0);border-start-end-radius:var(--join-se,0);border-end-end-radius:var(--join-ee,0);border-end-start-radius:var(--join-es,0)}.join :where(.join-item) *{--join-ss:var(--radius-field);--join-se:var(--radius-field);--join-es:var(--radius-field);--join-ee:var(--radius-field)}.join>.join-item:where(:first-child),.join :first-child:not(:last-child) :where(.join-item){--join-ss:var(--radius-field);--join-se:0;--join-es:var(--radius-field);--join-ee:0}.join>.join-item:where(:last-child),.join :last-child:not(:first-child) :where(.join-item){--join-ss:0;--join-se:var(--radius-field);--join-es:0;--join-ee:var(--radius-field)}.join>.join-item:where(:only-child),.join :only-child :where(.join-item){--join-ss:var(--radius-field);--join-se:var(--radius-field);--join-es:var(--radius-field);--join-ee:var(--radius-field)}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.modal-bottom{place-items:end}.modal-bottom :where(.modal-box){--modal-tl:var(--radius-box);--modal-tr:var(--radius-box);--modal-bl:0;--modal-br:0;width:100%;max-width:none;height:auto;max-height:calc(100vh - 5em);translate:0 100%;scale:1}.btn-circle{width:var(--size);height:var(--size);border-radius:3.40282e38px;padding-inline:0}.h-8{height:calc(var(--spacing)*8)}.h-\\[calc\\(var\\(--size\\)\\*0\\.7\\)\\]{height:calc(var(--size)*.7)}.h-fit{height:-moz-fit-content;height:fit-content}.h-full{height:100%}.max-h-80{max-height:calc(var(--spacing)*80)}.loading-md{width:calc(var(--size-selector,.25rem)*6)}.w-10{width:calc(var(--spacing)*10)}.w-12{width:calc(var(--spacing)*12)}.w-20{width:calc(var(--spacing)*20)}.w-24{width:calc(var(--spacing)*24)}.w-28{width:calc(var(--spacing)*28)}.w-32{width:calc(var(--spacing)*32)}.w-64{width:calc(var(--spacing)*64)}.w-\\[6rem\\]{width:6rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.max-w-\\(--breakpoint-lg\\){max-width:var(--breakpoint-lg)}.min-w-8{min-width:calc(var(--spacing)*8)}.min-w-24{min-width:calc(var(--spacing)*24)}.min-w-32{min-width:calc(var(--spacing)*32)}.min-w-\\[0\\.05rem\\]{min-width:.05rem}.min-w-\\[7\\.5rem\\]{min-width:7.5rem}.min-w-\\[180px\\]{min-width:180px}.flex-1{flex:1}.grow{flex-grow:1}.translate-x-\\[-50\\%\\]{--tw-translate-x:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\\[-50\\%\\]{--tw-translate-y:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.transform{transform:var(--tw-rotate-x)var(--tw-rotate-y)var(--tw-rotate-z)var(--tw-skew-x)var(--tw-skew-y)}.skeleton{border-radius:var(--radius-box);background-color:var(--color-base-300);will-change:background-position;background-image:linear-gradient(105deg,#0000 0% 40%,var(--color-base-100)50%,#0000 60% 100%);background-position-x:-50%;background-repeat:no-repeat;background-size:200%;animation:1.8s ease-in-out infinite skeleton}@media (prefers-reduced-motion:reduce){.skeleton{transition-duration:15s}}.link{cursor:pointer;text-decoration-line:underline}.link:focus{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.link:focus{outline-offset:2px;outline:2px solid #0000}}.link:focus-visible{outline-offset:2px;outline:2px solid}.cursor-pointer{cursor:pointer}.resize{resize:both}.list-inside{list-style-position:inside}.list-outside{list-style-position:outside}.list-disc{list-style-type:disc}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-end{align-items:flex-end}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.gap-0\\.5{gap:calc(var(--spacing)*.5)}.gap-1{gap:calc(var(--spacing)*1)}.gap-x-1{-moz-column-gap:calc(var(--spacing)*1);column-gap:calc(var(--spacing)*1)}.gap-x-6{-moz-column-gap:calc(var(--spacing)*6);column-gap:calc(var(--spacing)*6)}.gap-y-1{row-gap:calc(var(--spacing)*1)}.gap-y-2{row-gap:calc(var(--spacing)*2)}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-visible{overflow:visible}.overflow-x-auto{overflow-x:auto}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-none{border-radius:0}.rounded-sm{border-radius:var(--radius-sm)}.rounded-t-md{border-top-left-radius:var(--radius-md);border-top-right-radius:var(--radius-md)}.rounded-t-none{border-top-left-radius:0;border-top-right-radius:0}.rounded-tr-md{border-top-right-radius:var(--radius-md)}.rounded-b-md{border-bottom-right-radius:var(--radius-md);border-bottom-left-radius:var(--radius-md)}.rounded-b-none{border-bottom-right-radius:0;border-bottom-left-radius:0}.border{border-style:var(--tw-border-style);border-width:1px}.border-0{border-style:var(--tw-border-style);border-width:0}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.select-ghost{box-shadow:none;background-color:#0000;border-color:#0000;transition:background-color .2s}.select-ghost:focus,.select-ghost:focus-within{background-color:var(--color-base-100);color:var(--color-base-content);box-shadow:none;border-color:#0000}.input-ghost{box-shadow:none;background-color:#0000;border-color:#0000}.input-ghost:focus,.input-ghost:focus-within{background-color:var(--color-base-100);color:var(--color-base-content);box-shadow:none;border-color:#0000}.border-gray-100{border-color:var(--color-gray-100)}.border-gray-200{border-color:var(--color-gray-200)}.border-gray-300{border-color:var(--color-gray-300)}.border-gray-500{border-color:var(--color-gray-500)}.bg-blue-300{background-color:var(--color-blue-300)}.bg-red-200{background-color:var(--color-red-200)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.loading-spinner{-webkit-mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg width='24' height='24' stroke='black' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cg transform-origin='center'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-width='3' stroke-linecap='round'%3E%3CanimateTransform attributeName='transform' type='rotate' from='0 12 12' to='360 12 12' dur='2s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dasharray' values='0,150;42,150;42,150' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3Canimate attributeName='stroke-dashoffset' values='0;-16;-59' keyTimes='0;0.475;1' dur='1.5s' repeatCount='indefinite'/%3E%3C/circle%3E%3C/g%3E%3C/svg%3E")}.p-0{padding:calc(var(--spacing)*0)}.p-1{padding:calc(var(--spacing)*1)}.p-1\\.5{padding:calc(var(--spacing)*1.5)}.p-2{padding:calc(var(--spacing)*2)}.p-4{padding:calc(var(--spacing)*4)}.px-1{padding-inline:calc(var(--spacing)*1)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.py-1{padding-block:calc(var(--spacing)*1)}.py-2{padding-block:calc(var(--spacing)*2)}.py-16{padding-block:calc(var(--spacing)*16)}.pr-14{padding-right:calc(var(--spacing)*14)}.text-center{text-align:center}.text-justify{text-align:justify}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.select-sm{--size:calc(var(--size-field,.25rem)*8);font-size:.75rem}.select-xs{--size:calc(var(--size-field,.25rem)*6);font-size:.6875rem}.leading-5{--tw-leading:calc(var(--spacing)*5);line-height:calc(var(--spacing)*5)}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.text-nowrap{text-wrap:nowrap}.text-wrap{text-wrap:wrap}.break-words{overflow-wrap:break-word}.whitespace-nowrap{white-space:nowrap}.text-\\[\\#606060\\]{color:#606060}.text-black{color:var(--color-black)}.text-blue-600{color:var(--color-blue-600)}.text-gray-500{color:var(--color-gray-500)}.text-gray-600{color:var(--color-gray-600)}.text-neutral-500{color:var(--color-neutral-500)}.text-red-600{color:var(--color-red-600)}.text-red-700{color:var(--color-red-700)}.underline{text-decoration-line:underline}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.btn-ghost:not(.btn-active,:hover,:active:focus,:focus-visible){--btn-shadow:"";--btn-bg:#0000;--btn-border:#0000;--btn-noise:none}.btn-ghost:not(.btn-active,:hover,:active:focus,:focus-visible):not(:disabled,[disabled],.btn-disabled){--btn-fg:currentColor;outline-color:currentColor}.blur{--tw-blur:blur(8px);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150{--tw-duration:.15s;transition-duration:.15s}.btn-outline:not(.btn-active,:hover,:active:focus,:focus-visible,:disabled,[disabled],.btn-disabled,:checked){--btn-shadow:"";--btn-bg:#0000;--btn-fg:var(--btn-color);--btn-border:var(--btn-color);--btn-noise:none}.btn-sm{--fontsize:.75rem;--btn-p:.75rem;--size:calc(var(--size-field,.25rem)*8)}.btn-xs{--fontsize:.6875rem;--btn-p:.5rem;--size:calc(var(--size-field,.25rem)*6)}.select-text{-webkit-user-select:text;-moz-user-select:text;user-select:text}.input-error,.input-error:focus,.input-error:focus-within{--input-color:var(--color-error)}.mdi--chevron-left{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M15.41 16.58L10.83 12l4.58-4.59L14 6l-6 6l6 6z'/%3E%3C/svg%3E")}.mdi--chevron-left-first{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6l6 6zM6 6h2v12H6z'/%3E%3C/svg%3E")}.mdi--chevron-right{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M8.59 16.58L13.17 12L8.59 7.41L10 6l6 6l-6 6z'/%3E%3C/svg%3E")}.mdi--chevron-right-last{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6l-6-6zM16 6h2v12h-2z'/%3E%3C/svg%3E")}.mdi--fullscreen{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M5 5h5v2H7v3H5zm9 0h5v5h-2V7h-3zm3 9h2v5h-5v-2h3zm-7 3v2H5v-5h2v3z'/%3E%3C/svg%3E")}.mdi--fullscreen-exit{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M14 14h5v2h-3v3h-2zm-9 0h5v5H8v-3H5zm3-9h2v5H5V8h3zm11 3v2h-5V5h2v3z'/%3E%3C/svg%3E")}.mdi--reload{--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M2 12a9 9 0 0 0 9 9c2.39 0 4.68-.94 6.4-2.6l-1.5-1.5A6.7 6.7 0 0 1 11 19c-6.24 0-9.36-7.54-4.95-11.95S18 5.77 18 12h-3l4 4h.1l3.9-4h-3a9 9 0 0 0-18 0'/%3E%3C/svg%3E")}@media (hover:hover){.peer-hover\\:visible:is(:where(.peer):hover~*){visibility:visible}.hover\\:scale-90:hover{--tw-scale-x:90%;--tw-scale-y:90%;--tw-scale-z:90%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\\:bg-gray-100:hover{background-color:var(--color-gray-100)}.hover\\:font-bold:hover{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.hover\\:text-blue-700:hover{color:var(--color-blue-700)}.hover\\:text-blue-800:hover{color:var(--color-blue-800)}.hover\\:text-gray-400:hover{color:var(--color-gray-400)}.hover\\:text-gray-700:hover{color:var(--color-gray-700)}}.focus\\:outline-none:focus{--tw-outline-style:none;outline-style:none}@media (min-width:40rem){.sm\\:modal-middle{place-items:center}.sm\\:modal-middle :where(.modal-box){--modal-tl:var(--radius-box);--modal-tr:var(--radius-box);--modal-bl:var(--radius-box);--modal-br:var(--radius-box);width:91.6667%;max-width:32rem;height:auto;max-height:calc(100vh - 5em);translate:0 2%;scale:98%}.sm\\:max-w-5xl{max-width:var(--container-5xl)}.sm\\:flex-row{flex-direction:row}.sm\\:text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}}@container (min-width:2rem){.\\@\\[2rem\\]\\:visible{visibility:visible}}@container (min-width:6rem){.\\@\\[6rem\\]\\:visible{visibility:visible}}@container (min-width:14rem){.\\@4xs\\:flex-row{flex-direction:row}.\\@4xs\\:rounded-l-none{border-top-left-radius:0;border-bottom-left-radius:0}.\\@4xs\\:rounded-tr-none{border-top-right-radius:0}.\\@4xs\\:rounded-bl-md{border-bottom-left-radius:var(--radius-md)}}@container (min-width:28rem){.\\@md\\:flex-row{flex-direction:row}.\\@md\\:rounded-l-md{border-top-left-radius:var(--radius-md);border-bottom-left-radius:var(--radius-md)}.\\@md\\:rounded-l-none{border-top-left-radius:0;border-bottom-left-radius:0}.\\@md\\:rounded-r-md{border-top-right-radius:var(--radius-md);border-bottom-right-radius:var(--radius-md)}.\\@md\\:rounded-r-none{border-top-right-radius:0;border-bottom-right-radius:0}}@container (min-width:36rem){.\\@xl\\:block{display:block}.\\@xl\\:justify-end{justify-content:flex-end}}}@keyframes skeleton{0%{background-position:150%}to{background-position:-50%}}@keyframes progress{50%{background-position-x:-115%}}@keyframes radio{0%{padding:5px}50%{padding:3px}}@keyframes dropdown{0%{opacity:0}}@keyframes rating{0%,40%{filter:brightness(1.05)contrast(1.05);scale:1.1}}@keyframes toast{0%{opacity:0;scale:.9}to{opacity:1;scale:1}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false;initial-value:rotateX(0)}@property --tw-rotate-y{syntax:"*";inherits:false;initial-value:rotateY(0)}@property --tw-rotate-z{syntax:"*";inherits:false;initial-value:rotateZ(0)}@property --tw-skew-x{syntax:"*";inherits:false;initial-value:skewX(0)}@property --tw-skew-y{syntax:"*";inherits:false;initial-value:skewY(0)}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}
|
|
2466
2482
|
`;
|
|
2467
2483
|
var __defProp$f = Object.defineProperty;
|
|
2468
2484
|
var __decorateClass$f = (decorators, target, key, kind) => {
|
|
@@ -2475,6 +2491,10 @@ var __decorateClass$f = (decorators, target, key, kind) => {
|
|
|
2475
2491
|
};
|
|
2476
2492
|
const tailwindElementCss = unsafeCSS(tailwindStyle);
|
|
2477
2493
|
const minMaxPercentSliderElementCss = unsafeCSS(minMaxPercentSliderCss);
|
|
2494
|
+
const styleSheet = tailwindElementCss.styleSheet;
|
|
2495
|
+
if (styleSheet !== void 0) {
|
|
2496
|
+
replaceCssProperties(styleSheet);
|
|
2497
|
+
}
|
|
2478
2498
|
const _PreactLitAdapter = class _PreactLitAdapter extends ReactiveElement {
|
|
2479
2499
|
constructor() {
|
|
2480
2500
|
super(...arguments);
|
|
@@ -6254,7 +6274,7 @@ __decorateClass$9([
|
|
|
6254
6274
|
NumberSequencesOverTimeComponent = __decorateClass$9([
|
|
6255
6275
|
t$3("gs-number-sequences-over-time")
|
|
6256
6276
|
], NumberSequencesOverTimeComponent);
|
|
6257
|
-
const jsContent = '(function() {\n "use strict";\n var util;\n (function(util2) {\n util2.assertEqual = (val) => val;\n function assertIs(_arg) {\n }\n util2.assertIs = assertIs;\n function assertNever(_x) {\n throw new Error();\n }\n util2.assertNever = assertNever;\n util2.arrayToEnum = (items) => {\n const obj = {};\n for (const item of items) {\n obj[item] = item;\n }\n return obj;\n };\n util2.getValidEnumValues = (obj) => {\n const validKeys = util2.objectKeys(obj).filter((k2) => typeof obj[obj[k2]] !== "number");\n const filtered = {};\n for (const k2 of validKeys) {\n filtered[k2] = obj[k2];\n }\n return util2.objectValues(filtered);\n };\n util2.objectValues = (obj) => {\n return util2.objectKeys(obj).map(function(e2) {\n return obj[e2];\n });\n };\n util2.objectKeys = typeof Object.keys === "function" ? (obj) => Object.keys(obj) : (object) => {\n const keys = [];\n for (const key in object) {\n if (Object.prototype.hasOwnProperty.call(object, key)) {\n keys.push(key);\n }\n }\n return keys;\n };\n util2.find = (arr, checker) => {\n for (const item of arr) {\n if (checker(item))\n return item;\n }\n return void 0;\n };\n util2.isInteger = typeof Number.isInteger === "function" ? (val) => Number.isInteger(val) : (val) => typeof val === "number" && isFinite(val) && Math.floor(val) === val;\n function joinValues(array, separator = " | ") {\n return array.map((val) => typeof val === "string" ? `\'${val}\'` : val).join(separator);\n }\n util2.joinValues = joinValues;\n util2.jsonStringifyReplacer = (_, value) => {\n if (typeof value === "bigint") {\n return value.toString();\n }\n return value;\n };\n })(util || (util = {}));\n var objectUtil;\n (function(objectUtil2) {\n objectUtil2.mergeShapes = (first, second) => {\n return {\n ...first,\n ...second\n // second overwrites first\n };\n };\n })(objectUtil || (objectUtil = {}));\n const ZodParsedType = util.arrayToEnum([\n "string",\n "nan",\n "number",\n "integer",\n "float",\n "boolean",\n "date",\n "bigint",\n "symbol",\n "function",\n "undefined",\n "null",\n "array",\n "object",\n "unknown",\n "promise",\n "void",\n "never",\n "map",\n "set"\n ]);\n const getParsedType = (data) => {\n const t = typeof data;\n switch (t) {\n case "undefined":\n return ZodParsedType.undefined;\n case "string":\n return ZodParsedType.string;\n case "number":\n return isNaN(data) ? ZodParsedType.nan : ZodParsedType.number;\n case "boolean":\n return ZodParsedType.boolean;\n case "function":\n return ZodParsedType.function;\n case "bigint":\n return ZodParsedType.bigint;\n case "symbol":\n return ZodParsedType.symbol;\n case "object":\n if (Array.isArray(data)) {\n return ZodParsedType.array;\n }\n if (data === null) {\n return ZodParsedType.null;\n }\n if (data.then && typeof data.then === "function" && data.catch && typeof data.catch === "function") {\n return ZodParsedType.promise;\n }\n if (typeof Map !== "undefined" && data instanceof Map) {\n return ZodParsedType.map;\n }\n if (typeof Set !== "undefined" && data instanceof Set) {\n return ZodParsedType.set;\n }\n if (typeof Date !== "undefined" && data instanceof Date) {\n return ZodParsedType.date;\n }\n return ZodParsedType.object;\n default:\n return ZodParsedType.unknown;\n }\n };\n const ZodIssueCode = util.arrayToEnum([\n "invalid_type",\n "invalid_literal",\n "custom",\n "invalid_union",\n "invalid_union_discriminator",\n "invalid_enum_value",\n "unrecognized_keys",\n "invalid_arguments",\n "invalid_return_type",\n "invalid_date",\n "invalid_string",\n "too_small",\n "too_big",\n "invalid_intersection_types",\n "not_multiple_of",\n "not_finite"\n ]);\n const quotelessJson = (obj) => {\n const json = JSON.stringify(obj, null, 2);\n return json.replace(/"([^"]+)":/g, "$1:");\n };\n class ZodError extends Error {\n get errors() {\n return this.issues;\n }\n constructor(issues) {\n super();\n this.issues = [];\n this.addIssue = (sub) => {\n this.issues = [...this.issues, sub];\n };\n this.addIssues = (subs = []) => {\n this.issues = [...this.issues, ...subs];\n };\n const actualProto = new.target.prototype;\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(this, actualProto);\n } else {\n this.__proto__ = actualProto;\n }\n this.name = "ZodError";\n this.issues = issues;\n }\n format(_mapper) {\n const mapper = _mapper || function(issue) {\n return issue.message;\n };\n const fieldErrors = { _errors: [] };\n const processError = (error) => {\n for (const issue of error.issues) {\n if (issue.code === "invalid_union") {\n issue.unionErrors.map(processError);\n } else if (issue.code === "invalid_return_type") {\n processError(issue.returnTypeError);\n } else if (issue.code === "invalid_arguments") {\n processError(issue.argumentsError);\n } else if (issue.path.length === 0) {\n fieldErrors._errors.push(mapper(issue));\n } else {\n let curr = fieldErrors;\n let i2 = 0;\n while (i2 < issue.path.length) {\n const el = issue.path[i2];\n const terminal = i2 === issue.path.length - 1;\n if (!terminal) {\n curr[el] = curr[el] || { _errors: [] };\n } else {\n curr[el] = curr[el] || { _errors: [] };\n curr[el]._errors.push(mapper(issue));\n }\n curr = curr[el];\n i2++;\n }\n }\n }\n };\n processError(this);\n return fieldErrors;\n }\n static assert(value) {\n if (!(value instanceof ZodError)) {\n throw new Error(`Not a ZodError: ${value}`);\n }\n }\n toString() {\n return this.message;\n }\n get message() {\n return JSON.stringify(this.issues, util.jsonStringifyReplacer, 2);\n }\n get isEmpty() {\n return this.issues.length === 0;\n }\n flatten(mapper = (issue) => issue.message) {\n const fieldErrors = {};\n const formErrors = [];\n for (const sub of this.issues) {\n if (sub.path.length > 0) {\n fieldErrors[sub.path[0]] = fieldErrors[sub.path[0]] || [];\n fieldErrors[sub.path[0]].push(mapper(sub));\n } else {\n formErrors.push(mapper(sub));\n }\n }\n return { formErrors, fieldErrors };\n }\n get formErrors() {\n return this.flatten();\n }\n }\n ZodError.create = (issues) => {\n const error = new ZodError(issues);\n return error;\n };\n const errorMap = (issue, _ctx) => {\n let message;\n switch (issue.code) {\n case ZodIssueCode.invalid_type:\n if (issue.received === ZodParsedType.undefined) {\n message = "Required";\n } else {\n message = `Expected ${issue.expected}, received ${issue.received}`;\n }\n break;\n case ZodIssueCode.invalid_literal:\n message = `Invalid literal value, expected ${JSON.stringify(issue.expected, util.jsonStringifyReplacer)}`;\n break;\n case ZodIssueCode.unrecognized_keys:\n message = `Unrecognized key(s) in object: ${util.joinValues(issue.keys, ", ")}`;\n break;\n case ZodIssueCode.invalid_union:\n message = `Invalid input`;\n break;\n case ZodIssueCode.invalid_union_discriminator:\n message = `Invalid discriminator value. Expected ${util.joinValues(issue.options)}`;\n break;\n case ZodIssueCode.invalid_enum_value:\n message = `Invalid enum value. Expected ${util.joinValues(issue.options)}, received \'${issue.received}\'`;\n break;\n case ZodIssueCode.invalid_arguments:\n message = `Invalid function arguments`;\n break;\n case ZodIssueCode.invalid_return_type:\n message = `Invalid function return type`;\n break;\n case ZodIssueCode.invalid_date:\n message = `Invalid date`;\n break;\n case ZodIssueCode.invalid_string:\n if (typeof issue.validation === "object") {\n if ("includes" in issue.validation) {\n message = `Invalid input: must include "${issue.validation.includes}"`;\n if (typeof issue.validation.position === "number") {\n message = `${message} at one or more positions greater than or equal to ${issue.validation.position}`;\n }\n } else if ("startsWith" in issue.validation) {\n message = `Invalid input: must start with "${issue.validation.startsWith}"`;\n } else if ("endsWith" in issue.validation) {\n message = `Invalid input: must end with "${issue.validation.endsWith}"`;\n } else {\n util.assertNever(issue.validation);\n }\n } else if (issue.validation !== "regex") {\n message = `Invalid ${issue.validation}`;\n } else {\n message = "Invalid";\n }\n break;\n case ZodIssueCode.too_small:\n if (issue.type === "array")\n message = `Array must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `more than`} ${issue.minimum} element(s)`;\n else if (issue.type === "string")\n message = `String must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `over`} ${issue.minimum} character(s)`;\n else if (issue.type === "number")\n message = `Number must be ${issue.exact ? `exactly equal to ` : issue.inclusive ? `greater than or equal to ` : `greater than `}${issue.minimum}`;\n else if (issue.type === "date")\n message = `Date must be ${issue.exact ? `exactly equal to ` : issue.inclusive ? `greater than or equal to ` : `greater than `}${new Date(Number(issue.minimum))}`;\n else\n message = "Invalid input";\n break;\n case ZodIssueCode.too_big:\n if (issue.type === "array")\n message = `Array must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `less than`} ${issue.maximum} element(s)`;\n else if (issue.type === "string")\n message = `String must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `under`} ${issue.maximum} character(s)`;\n else if (issue.type === "number")\n message = `Number must be ${issue.exact ? `exactly` : issue.inclusive ? `less than or equal to` : `less than`} ${issue.maximum}`;\n else if (issue.type === "bigint")\n message = `BigInt must be ${issue.exact ? `exactly` : issue.inclusive ? `less than or equal to` : `less than`} ${issue.maximum}`;\n else if (issue.type === "date")\n message = `Date must be ${issue.exact ? `exactly` : issue.inclusive ? `smaller than or equal to` : `smaller than`} ${new Date(Number(issue.maximum))}`;\n else\n message = "Invalid input";\n break;\n case ZodIssueCode.custom:\n message = `Invalid input`;\n break;\n case ZodIssueCode.invalid_intersection_types:\n message = `Intersection results could not be merged`;\n break;\n case ZodIssueCode.not_multiple_of:\n message = `Number must be a multiple of ${issue.multipleOf}`;\n break;\n case ZodIssueCode.not_finite:\n message = "Number must be finite";\n break;\n default:\n message = _ctx.defaultError;\n util.assertNever(issue);\n }\n return { message };\n };\n let overrideErrorMap = errorMap;\n function setErrorMap(map) {\n overrideErrorMap = map;\n }\n function getErrorMap() {\n return overrideErrorMap;\n }\n const makeIssue = (params) => {\n const { data, path, errorMaps, issueData } = params;\n const fullPath = [...path, ...issueData.path || []];\n const fullIssue = {\n ...issueData,\n path: fullPath\n };\n if (issueData.message !== void 0) {\n return {\n ...issueData,\n path: fullPath,\n message: issueData.message\n };\n }\n let errorMessage = "";\n const maps = errorMaps.filter((m2) => !!m2).slice().reverse();\n for (const map of maps) {\n errorMessage = map(fullIssue, { data, defaultError: errorMessage }).message;\n }\n return {\n ...issueData,\n path: fullPath,\n message: errorMessage\n };\n };\n const EMPTY_PATH = [];\n function addIssueToContext(ctx, issueData) {\n const overrideMap = getErrorMap();\n const issue = makeIssue({\n issueData,\n data: ctx.data,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n // contextual error map is first priority\n ctx.schemaErrorMap,\n // then schema-bound map if available\n overrideMap,\n // then global override map\n overrideMap === errorMap ? void 0 : errorMap\n // then global default map\n ].filter((x) => !!x)\n });\n ctx.common.issues.push(issue);\n }\n class ParseStatus {\n constructor() {\n this.value = "valid";\n }\n dirty() {\n if (this.value === "valid")\n this.value = "dirty";\n }\n abort() {\n if (this.value !== "aborted")\n this.value = "aborted";\n }\n static mergeArray(status, results) {\n const arrayValue = [];\n for (const s2 of results) {\n if (s2.status === "aborted")\n return INVALID;\n if (s2.status === "dirty")\n status.dirty();\n arrayValue.push(s2.value);\n }\n return { status: status.value, value: arrayValue };\n }\n static async mergeObjectAsync(status, pairs) {\n const syncPairs = [];\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n syncPairs.push({\n key,\n value\n });\n }\n return ParseStatus.mergeObjectSync(status, syncPairs);\n }\n static mergeObjectSync(status, pairs) {\n const finalObject = {};\n for (const pair of pairs) {\n const { key, value } = pair;\n if (key.status === "aborted")\n return INVALID;\n if (value.status === "aborted")\n return INVALID;\n if (key.status === "dirty")\n status.dirty();\n if (value.status === "dirty")\n status.dirty();\n if (key.value !== "__proto__" && (typeof value.value !== "undefined" || pair.alwaysSet)) {\n finalObject[key.value] = value.value;\n }\n }\n return { status: status.value, value: finalObject };\n }\n }\n const INVALID = Object.freeze({\n status: "aborted"\n });\n const DIRTY = (value) => ({ status: "dirty", value });\n const OK = (value) => ({ status: "valid", value });\n const isAborted = (x) => x.status === "aborted";\n const isDirty = (x) => x.status === "dirty";\n const isValid = (x) => x.status === "valid";\n const isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;\n function __classPrivateFieldGet(receiver, state, kind, f2) {\n if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");\n return state.get(receiver);\n }\n function __classPrivateFieldSet(receiver, state, value, kind, f2) {\n if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");\n return state.set(receiver, value), value;\n }\n typeof SuppressedError === "function" ? SuppressedError : function(error, suppressed, message) {\n var e2 = new Error(message);\n return e2.name = "SuppressedError", e2.error = error, e2.suppressed = suppressed, e2;\n };\n var errorUtil;\n (function(errorUtil2) {\n errorUtil2.errToObj = (message) => typeof message === "string" ? { message } : message || {};\n errorUtil2.toString = (message) => typeof message === "string" ? message : message === null || message === void 0 ? void 0 : message.message;\n })(errorUtil || (errorUtil = {}));\n var _ZodEnum_cache, _ZodNativeEnum_cache;\n class ParseInputLazyPath {\n constructor(parent, value, path, key) {\n this._cachedPath = [];\n this.parent = parent;\n this.data = value;\n this._path = path;\n this._key = key;\n }\n get path() {\n if (!this._cachedPath.length) {\n if (this._key instanceof Array) {\n this._cachedPath.push(...this._path, ...this._key);\n } else {\n this._cachedPath.push(...this._path, this._key);\n }\n }\n return this._cachedPath;\n }\n }\n const handleResult = (ctx, result) => {\n if (isValid(result)) {\n return { success: true, data: result.value };\n } else {\n if (!ctx.common.issues.length) {\n throw new Error("Validation failed but no issues detected.");\n }\n return {\n success: false,\n get error() {\n if (this._error)\n return this._error;\n const error = new ZodError(ctx.common.issues);\n this._error = error;\n return this._error;\n }\n };\n }\n };\n function processCreateParams(params) {\n if (!params)\n return {};\n const { errorMap: errorMap2, invalid_type_error, required_error, description } = params;\n if (errorMap2 && (invalid_type_error || required_error)) {\n throw new Error(`Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.`);\n }\n if (errorMap2)\n return { errorMap: errorMap2, description };\n const customMap = (iss, ctx) => {\n var _a, _b;\n const { message } = params;\n if (iss.code === "invalid_enum_value") {\n return { message: message !== null && message !== void 0 ? message : ctx.defaultError };\n }\n if (typeof ctx.data === "undefined") {\n return { message: (_a = message !== null && message !== void 0 ? message : required_error) !== null && _a !== void 0 ? _a : ctx.defaultError };\n }\n if (iss.code !== "invalid_type")\n return { message: ctx.defaultError };\n return { message: (_b = message !== null && message !== void 0 ? message : invalid_type_error) !== null && _b !== void 0 ? _b : ctx.defaultError };\n };\n return { errorMap: customMap, description };\n }\n class ZodType {\n get description() {\n return this._def.description;\n }\n _getType(input) {\n return getParsedType(input.data);\n }\n _getOrReturnCtx(input, ctx) {\n return ctx || {\n common: input.parent.common,\n data: input.data,\n parsedType: getParsedType(input.data),\n schemaErrorMap: this._def.errorMap,\n path: input.path,\n parent: input.parent\n };\n }\n _processInputParams(input) {\n return {\n status: new ParseStatus(),\n ctx: {\n common: input.parent.common,\n data: input.data,\n parsedType: getParsedType(input.data),\n schemaErrorMap: this._def.errorMap,\n path: input.path,\n parent: input.parent\n }\n };\n }\n _parseSync(input) {\n const result = this._parse(input);\n if (isAsync(result)) {\n throw new Error("Synchronous parse encountered promise.");\n }\n return result;\n }\n _parseAsync(input) {\n const result = this._parse(input);\n return Promise.resolve(result);\n }\n parse(data, params) {\n const result = this.safeParse(data, params);\n if (result.success)\n return result.data;\n throw result.error;\n }\n safeParse(data, params) {\n var _a;\n const ctx = {\n common: {\n issues: [],\n async: (_a = params === null || params === void 0 ? void 0 : params.async) !== null && _a !== void 0 ? _a : false,\n contextualErrorMap: params === null || params === void 0 ? void 0 : params.errorMap\n },\n path: (params === null || params === void 0 ? void 0 : params.path) || [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n const result = this._parseSync({ data, path: ctx.path, parent: ctx });\n return handleResult(ctx, result);\n }\n "~validate"(data) {\n var _a, _b;\n const ctx = {\n common: {\n issues: [],\n async: !!this["~standard"].async\n },\n path: [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n if (!this["~standard"].async) {\n try {\n const result = this._parseSync({ data, path: [], parent: ctx });\n return isValid(result) ? {\n value: result.value\n } : {\n issues: ctx.common.issues\n };\n } catch (err) {\n if ((_b = (_a = err === null || err === void 0 ? void 0 : err.message) === null || _a === void 0 ? void 0 : _a.toLowerCase()) === null || _b === void 0 ? void 0 : _b.includes("encountered")) {\n this["~standard"].async = true;\n }\n ctx.common = {\n issues: [],\n async: true\n };\n }\n }\n return this._parseAsync({ data, path: [], parent: ctx }).then((result) => isValid(result) ? {\n value: result.value\n } : {\n issues: ctx.common.issues\n });\n }\n async parseAsync(data, params) {\n const result = await this.safeParseAsync(data, params);\n if (result.success)\n return result.data;\n throw result.error;\n }\n async safeParseAsync(data, params) {\n const ctx = {\n common: {\n issues: [],\n contextualErrorMap: params === null || params === void 0 ? void 0 : params.errorMap,\n async: true\n },\n path: (params === null || params === void 0 ? void 0 : params.path) || [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n const maybeAsyncResult = this._parse({ data, path: ctx.path, parent: ctx });\n const result = await (isAsync(maybeAsyncResult) ? maybeAsyncResult : Promise.resolve(maybeAsyncResult));\n return handleResult(ctx, result);\n }\n refine(check, message) {\n const getIssueProperties = (val) => {\n if (typeof message === "string" || typeof message === "undefined") {\n return { message };\n } else if (typeof message === "function") {\n return message(val);\n } else {\n return message;\n }\n };\n return this._refinement((val, ctx) => {\n const result = check(val);\n const setError = () => ctx.addIssue({\n code: ZodIssueCode.custom,\n ...getIssueProperties(val)\n });\n if (typeof Promise !== "undefined" && result instanceof Promise) {\n return result.then((data) => {\n if (!data) {\n setError();\n return false;\n } else {\n return true;\n }\n });\n }\n if (!result) {\n setError();\n return false;\n } else {\n return true;\n }\n });\n }\n refinement(check, refinementData) {\n return this._refinement((val, ctx) => {\n if (!check(val)) {\n ctx.addIssue(typeof refinementData === "function" ? refinementData(val, ctx) : refinementData);\n return false;\n } else {\n return true;\n }\n });\n }\n _refinement(refinement) {\n return new ZodEffects({\n schema: this,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect: { type: "refinement", refinement }\n });\n }\n superRefine(refinement) {\n return this._refinement(refinement);\n }\n constructor(def) {\n this.spa = this.safeParseAsync;\n this._def = def;\n this.parse = this.parse.bind(this);\n this.safeParse = this.safeParse.bind(this);\n this.parseAsync = this.parseAsync.bind(this);\n this.safeParseAsync = this.safeParseAsync.bind(this);\n this.spa = this.spa.bind(this);\n this.refine = this.refine.bind(this);\n this.refinement = this.refinement.bind(this);\n this.superRefine = this.superRefine.bind(this);\n this.optional = this.optional.bind(this);\n this.nullable = this.nullable.bind(this);\n this.nullish = this.nullish.bind(this);\n this.array = this.array.bind(this);\n this.promise = this.promise.bind(this);\n this.or = this.or.bind(this);\n this.and = this.and.bind(this);\n this.transform = this.transform.bind(this);\n this.brand = this.brand.bind(this);\n this.default = this.default.bind(this);\n this.catch = this.catch.bind(this);\n this.describe = this.describe.bind(this);\n this.pipe = this.pipe.bind(this);\n this.readonly = this.readonly.bind(this);\n this.isNullable = this.isNullable.bind(this);\n this.isOptional = this.isOptional.bind(this);\n this["~standard"] = {\n version: 1,\n vendor: "zod",\n validate: (data) => this["~validate"](data)\n };\n }\n optional() {\n return ZodOptional.create(this, this._def);\n }\n nullable() {\n return ZodNullable.create(this, this._def);\n }\n nullish() {\n return this.nullable().optional();\n }\n array() {\n return ZodArray.create(this);\n }\n promise() {\n return ZodPromise.create(this, this._def);\n }\n or(option) {\n return ZodUnion.create([this, option], this._def);\n }\n and(incoming) {\n return ZodIntersection.create(this, incoming, this._def);\n }\n transform(transform) {\n return new ZodEffects({\n ...processCreateParams(this._def),\n schema: this,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect: { type: "transform", transform }\n });\n }\n default(def) {\n const defaultValueFunc = typeof def === "function" ? def : () => def;\n return new ZodDefault({\n ...processCreateParams(this._def),\n innerType: this,\n defaultValue: defaultValueFunc,\n typeName: ZodFirstPartyTypeKind.ZodDefault\n });\n }\n brand() {\n return new ZodBranded({\n typeName: ZodFirstPartyTypeKind.ZodBranded,\n type: this,\n ...processCreateParams(this._def)\n });\n }\n catch(def) {\n const catchValueFunc = typeof def === "function" ? def : () => def;\n return new ZodCatch({\n ...processCreateParams(this._def),\n innerType: this,\n catchValue: catchValueFunc,\n typeName: ZodFirstPartyTypeKind.ZodCatch\n });\n }\n describe(description) {\n const This = this.constructor;\n return new This({\n ...this._def,\n description\n });\n }\n pipe(target) {\n return ZodPipeline.create(this, target);\n }\n readonly() {\n return ZodReadonly.create(this);\n }\n isOptional() {\n return this.safeParse(void 0).success;\n }\n isNullable() {\n return this.safeParse(null).success;\n }\n }\n const cuidRegex = /^c[^\\s-]{8,}$/i;\n const cuid2Regex = /^[0-9a-z]+$/;\n const ulidRegex = /^[0-9A-HJKMNP-TV-Z]{26}$/i;\n const uuidRegex = /^[0-9a-fA-F]{8}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{12}$/i;\n const nanoidRegex = /^[a-z0-9_-]{21}$/i;\n const jwtRegex = /^[A-Za-z0-9-_]+\\.[A-Za-z0-9-_]+\\.[A-Za-z0-9-_]*$/;\n const durationRegex = /^[-+]?P(?!$)(?:(?:[-+]?\\d+Y)|(?:[-+]?\\d+[.,]\\d+Y$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:(?:[-+]?\\d+W)|(?:[-+]?\\d+[.,]\\d+W$))?(?:(?:[-+]?\\d+D)|(?:[-+]?\\d+[.,]\\d+D$))?(?:T(?=[\\d+-])(?:(?:[-+]?\\d+H)|(?:[-+]?\\d+[.,]\\d+H$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:[-+]?\\d+(?:[.,]\\d+)?S)?)??$/;\n const emailRegex = /^(?!\\.)(?!.*\\.\\.)([A-Z0-9_\'+\\-\\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\\-]*\\.)+[A-Z]{2,}$/i;\n const _emojiRegex = `^(\\\\p{Extended_Pictographic}|\\\\p{Emoji_Component})+$`;\n let emojiRegex;\n const ipv4Regex = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/;\n const ipv4CidrRegex = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\/(3[0-2]|[12]?[0-9])$/;\n const ipv6Regex = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/;\n const ipv6CidrRegex = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/;\n const base64Regex = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/;\n const base64urlRegex = /^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/;\n const dateRegexSource = `((\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\\\d|30)|(02)-(0[1-9]|1\\\\d|2[0-8])))`;\n const dateRegex = new RegExp(`^${dateRegexSource}$`);\n function timeRegexSource(args) {\n let regex = `([01]\\\\d|2[0-3]):[0-5]\\\\d:[0-5]\\\\d`;\n if (args.precision) {\n regex = `${regex}\\\\.\\\\d{${args.precision}}`;\n } else if (args.precision == null) {\n regex = `${regex}(\\\\.\\\\d+)?`;\n }\n return regex;\n }\n function timeRegex(args) {\n return new RegExp(`^${timeRegexSource(args)}$`);\n }\n function datetimeRegex(args) {\n let regex = `${dateRegexSource}T${timeRegexSource(args)}`;\n const opts = [];\n opts.push(args.local ? `Z?` : `Z`);\n if (args.offset)\n opts.push(`([+-]\\\\d{2}:?\\\\d{2})`);\n regex = `${regex}(${opts.join("|")})`;\n return new RegExp(`^${regex}$`);\n }\n function isValidIP(ip, version) {\n if ((version === "v4" || !version) && ipv4Regex.test(ip)) {\n return true;\n }\n if ((version === "v6" || !version) && ipv6Regex.test(ip)) {\n return true;\n }\n return false;\n }\n function isValidJWT(jwt, alg) {\n if (!jwtRegex.test(jwt))\n return false;\n try {\n const [header] = jwt.split(".");\n const base64 = header.replace(/-/g, "+").replace(/_/g, "/").padEnd(header.length + (4 - header.length % 4) % 4, "=");\n const decoded = JSON.parse(atob(base64));\n if (typeof decoded !== "object" || decoded === null)\n return false;\n if (!decoded.typ || !decoded.alg)\n return false;\n if (alg && decoded.alg !== alg)\n return false;\n return true;\n } catch (_a) {\n return false;\n }\n }\n function isValidCidr(ip, version) {\n if ((version === "v4" || !version) && ipv4CidrRegex.test(ip)) {\n return true;\n }\n if ((version === "v6" || !version) && ipv6CidrRegex.test(ip)) {\n return true;\n }\n return false;\n }\n class ZodString extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = String(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.string) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.string,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n const status = new ParseStatus();\n let ctx = void 0;\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n if (input.data.length < check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "string",\n inclusive: true,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n if (input.data.length > check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "string",\n inclusive: true,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "length") {\n const tooBig = input.data.length > check.value;\n const tooSmall = input.data.length < check.value;\n if (tooBig || tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n if (tooBig) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "string",\n inclusive: true,\n exact: true,\n message: check.message\n });\n } else if (tooSmall) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "string",\n inclusive: true,\n exact: true,\n message: check.message\n });\n }\n status.dirty();\n }\n } else if (check.kind === "email") {\n if (!emailRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "email",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "emoji") {\n if (!emojiRegex) {\n emojiRegex = new RegExp(_emojiRegex, "u");\n }\n if (!emojiRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "emoji",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "uuid") {\n if (!uuidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "uuid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "nanoid") {\n if (!nanoidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "nanoid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cuid") {\n if (!cuidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cuid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cuid2") {\n if (!cuid2Regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cuid2",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "ulid") {\n if (!ulidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "ulid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "url") {\n try {\n new URL(input.data);\n } catch (_a) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "url",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "regex") {\n check.regex.lastIndex = 0;\n const testResult = check.regex.test(input.data);\n if (!testResult) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "regex",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "trim") {\n input.data = input.data.trim();\n } else if (check.kind === "includes") {\n if (!input.data.includes(check.value, check.position)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { includes: check.value, position: check.position },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "toLowerCase") {\n input.data = input.data.toLowerCase();\n } else if (check.kind === "toUpperCase") {\n input.data = input.data.toUpperCase();\n } else if (check.kind === "startsWith") {\n if (!input.data.startsWith(check.value)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { startsWith: check.value },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "endsWith") {\n if (!input.data.endsWith(check.value)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { endsWith: check.value },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "datetime") {\n const regex = datetimeRegex(check);\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "datetime",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "date") {\n const regex = dateRegex;\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "date",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "time") {\n const regex = timeRegex(check);\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "time",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "duration") {\n if (!durationRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "duration",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "ip") {\n if (!isValidIP(input.data, check.version)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "ip",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "jwt") {\n if (!isValidJWT(input.data, check.alg)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "jwt",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cidr") {\n if (!isValidCidr(input.data, check.version)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cidr",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "base64") {\n if (!base64Regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "base64",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "base64url") {\n if (!base64urlRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "base64url",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n _regex(regex, validation, message) {\n return this.refinement((data) => regex.test(data), {\n validation,\n code: ZodIssueCode.invalid_string,\n ...errorUtil.errToObj(message)\n });\n }\n _addCheck(check) {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n email(message) {\n return this._addCheck({ kind: "email", ...errorUtil.errToObj(message) });\n }\n url(message) {\n return this._addCheck({ kind: "url", ...errorUtil.errToObj(message) });\n }\n emoji(message) {\n return this._addCheck({ kind: "emoji", ...errorUtil.errToObj(message) });\n }\n uuid(message) {\n return this._addCheck({ kind: "uuid", ...errorUtil.errToObj(message) });\n }\n nanoid(message) {\n return this._addCheck({ kind: "nanoid", ...errorUtil.errToObj(message) });\n }\n cuid(message) {\n return this._addCheck({ kind: "cuid", ...errorUtil.errToObj(message) });\n }\n cuid2(message) {\n return this._addCheck({ kind: "cuid2", ...errorUtil.errToObj(message) });\n }\n ulid(message) {\n return this._addCheck({ kind: "ulid", ...errorUtil.errToObj(message) });\n }\n base64(message) {\n return this._addCheck({ kind: "base64", ...errorUtil.errToObj(message) });\n }\n base64url(message) {\n return this._addCheck({\n kind: "base64url",\n ...errorUtil.errToObj(message)\n });\n }\n jwt(options) {\n return this._addCheck({ kind: "jwt", ...errorUtil.errToObj(options) });\n }\n ip(options) {\n return this._addCheck({ kind: "ip", ...errorUtil.errToObj(options) });\n }\n cidr(options) {\n return this._addCheck({ kind: "cidr", ...errorUtil.errToObj(options) });\n }\n datetime(options) {\n var _a, _b;\n if (typeof options === "string") {\n return this._addCheck({\n kind: "datetime",\n precision: null,\n offset: false,\n local: false,\n message: options\n });\n }\n return this._addCheck({\n kind: "datetime",\n precision: typeof (options === null || options === void 0 ? void 0 : options.precision) === "undefined" ? null : options === null || options === void 0 ? void 0 : options.precision,\n offset: (_a = options === null || options === void 0 ? void 0 : options.offset) !== null && _a !== void 0 ? _a : false,\n local: (_b = options === null || options === void 0 ? void 0 : options.local) !== null && _b !== void 0 ? _b : false,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n date(message) {\n return this._addCheck({ kind: "date", message });\n }\n time(options) {\n if (typeof options === "string") {\n return this._addCheck({\n kind: "time",\n precision: null,\n message: options\n });\n }\n return this._addCheck({\n kind: "time",\n precision: typeof (options === null || options === void 0 ? void 0 : options.precision) === "undefined" ? null : options === null || options === void 0 ? void 0 : options.precision,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n duration(message) {\n return this._addCheck({ kind: "duration", ...errorUtil.errToObj(message) });\n }\n regex(regex, message) {\n return this._addCheck({\n kind: "regex",\n regex,\n ...errorUtil.errToObj(message)\n });\n }\n includes(value, options) {\n return this._addCheck({\n kind: "includes",\n value,\n position: options === null || options === void 0 ? void 0 : options.position,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n startsWith(value, message) {\n return this._addCheck({\n kind: "startsWith",\n value,\n ...errorUtil.errToObj(message)\n });\n }\n endsWith(value, message) {\n return this._addCheck({\n kind: "endsWith",\n value,\n ...errorUtil.errToObj(message)\n });\n }\n min(minLength, message) {\n return this._addCheck({\n kind: "min",\n value: minLength,\n ...errorUtil.errToObj(message)\n });\n }\n max(maxLength, message) {\n return this._addCheck({\n kind: "max",\n value: maxLength,\n ...errorUtil.errToObj(message)\n });\n }\n length(len, message) {\n return this._addCheck({\n kind: "length",\n value: len,\n ...errorUtil.errToObj(message)\n });\n }\n /**\n * Equivalent to `.min(1)`\n */\n nonempty(message) {\n return this.min(1, errorUtil.errToObj(message));\n }\n trim() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "trim" }]\n });\n }\n toLowerCase() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "toLowerCase" }]\n });\n }\n toUpperCase() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "toUpperCase" }]\n });\n }\n get isDatetime() {\n return !!this._def.checks.find((ch) => ch.kind === "datetime");\n }\n get isDate() {\n return !!this._def.checks.find((ch) => ch.kind === "date");\n }\n get isTime() {\n return !!this._def.checks.find((ch) => ch.kind === "time");\n }\n get isDuration() {\n return !!this._def.checks.find((ch) => ch.kind === "duration");\n }\n get isEmail() {\n return !!this._def.checks.find((ch) => ch.kind === "email");\n }\n get isURL() {\n return !!this._def.checks.find((ch) => ch.kind === "url");\n }\n get isEmoji() {\n return !!this._def.checks.find((ch) => ch.kind === "emoji");\n }\n get isUUID() {\n return !!this._def.checks.find((ch) => ch.kind === "uuid");\n }\n get isNANOID() {\n return !!this._def.checks.find((ch) => ch.kind === "nanoid");\n }\n get isCUID() {\n return !!this._def.checks.find((ch) => ch.kind === "cuid");\n }\n get isCUID2() {\n return !!this._def.checks.find((ch) => ch.kind === "cuid2");\n }\n get isULID() {\n return !!this._def.checks.find((ch) => ch.kind === "ulid");\n }\n get isIP() {\n return !!this._def.checks.find((ch) => ch.kind === "ip");\n }\n get isCIDR() {\n return !!this._def.checks.find((ch) => ch.kind === "cidr");\n }\n get isBase64() {\n return !!this._def.checks.find((ch) => ch.kind === "base64");\n }\n get isBase64url() {\n return !!this._def.checks.find((ch) => ch.kind === "base64url");\n }\n get minLength() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxLength() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n }\n ZodString.create = (params) => {\n var _a;\n return new ZodString({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodString,\n coerce: (_a = params === null || params === void 0 ? void 0 : params.coerce) !== null && _a !== void 0 ? _a : false,\n ...processCreateParams(params)\n });\n };\n function floatSafeRemainder(val, step) {\n const valDecCount = (val.toString().split(".")[1] || "").length;\n const stepDecCount = (step.toString().split(".")[1] || "").length;\n const decCount = valDecCount > stepDecCount ? valDecCount : stepDecCount;\n const valInt = parseInt(val.toFixed(decCount).replace(".", ""));\n const stepInt = parseInt(step.toFixed(decCount).replace(".", ""));\n return valInt % stepInt / Math.pow(10, decCount);\n }\n class ZodNumber extends ZodType {\n constructor() {\n super(...arguments);\n this.min = this.gte;\n this.max = this.lte;\n this.step = this.multipleOf;\n }\n _parse(input) {\n if (this._def.coerce) {\n input.data = Number(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.number) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.number,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n let ctx = void 0;\n const status = new ParseStatus();\n for (const check of this._def.checks) {\n if (check.kind === "int") {\n if (!util.isInteger(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: "integer",\n received: "float",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "min") {\n const tooSmall = check.inclusive ? input.data < check.value : input.data <= check.value;\n if (tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "number",\n inclusive: check.inclusive,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n const tooBig = check.inclusive ? input.data > check.value : input.data >= check.value;\n if (tooBig) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "number",\n inclusive: check.inclusive,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "multipleOf") {\n if (floatSafeRemainder(input.data, check.value) !== 0) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_multiple_of,\n multipleOf: check.value,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "finite") {\n if (!Number.isFinite(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_finite,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n gte(value, message) {\n return this.setLimit("min", value, true, errorUtil.toString(message));\n }\n gt(value, message) {\n return this.setLimit("min", value, false, errorUtil.toString(message));\n }\n lte(value, message) {\n return this.setLimit("max", value, true, errorUtil.toString(message));\n }\n lt(value, message) {\n return this.setLimit("max", value, false, errorUtil.toString(message));\n }\n setLimit(kind, value, inclusive, message) {\n return new ZodNumber({\n ...this._def,\n checks: [\n ...this._def.checks,\n {\n kind,\n value,\n inclusive,\n message: errorUtil.toString(message)\n }\n ]\n });\n }\n _addCheck(check) {\n return new ZodNumber({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n int(message) {\n return this._addCheck({\n kind: "int",\n message: errorUtil.toString(message)\n });\n }\n positive(message) {\n return this._addCheck({\n kind: "min",\n value: 0,\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n negative(message) {\n return this._addCheck({\n kind: "max",\n value: 0,\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n nonpositive(message) {\n return this._addCheck({\n kind: "max",\n value: 0,\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n nonnegative(message) {\n return this._addCheck({\n kind: "min",\n value: 0,\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n multipleOf(value, message) {\n return this._addCheck({\n kind: "multipleOf",\n value,\n message: errorUtil.toString(message)\n });\n }\n finite(message) {\n return this._addCheck({\n kind: "finite",\n message: errorUtil.toString(message)\n });\n }\n safe(message) {\n return this._addCheck({\n kind: "min",\n inclusive: true,\n value: Number.MIN_SAFE_INTEGER,\n message: errorUtil.toString(message)\n })._addCheck({\n kind: "max",\n inclusive: true,\n value: Number.MAX_SAFE_INTEGER,\n message: errorUtil.toString(message)\n });\n }\n get minValue() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxValue() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n get isInt() {\n return !!this._def.checks.find((ch) => ch.kind === "int" || ch.kind === "multipleOf" && util.isInteger(ch.value));\n }\n get isFinite() {\n let max = null, min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "finite" || ch.kind === "int" || ch.kind === "multipleOf") {\n return true;\n } else if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n } else if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return Number.isFinite(min) && Number.isFinite(max);\n }\n }\n ZodNumber.create = (params) => {\n return new ZodNumber({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodNumber,\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n ...processCreateParams(params)\n });\n };\n class ZodBigInt extends ZodType {\n constructor() {\n super(...arguments);\n this.min = this.gte;\n this.max = this.lte;\n }\n _parse(input) {\n if (this._def.coerce) {\n try {\n input.data = BigInt(input.data);\n } catch (_a) {\n return this._getInvalidInput(input);\n }\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.bigint) {\n return this._getInvalidInput(input);\n }\n let ctx = void 0;\n const status = new ParseStatus();\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n const tooSmall = check.inclusive ? input.data < check.value : input.data <= check.value;\n if (tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n type: "bigint",\n minimum: check.value,\n inclusive: check.inclusive,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n const tooBig = check.inclusive ? input.data > check.value : input.data >= check.value;\n if (tooBig) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n type: "bigint",\n maximum: check.value,\n inclusive: check.inclusive,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "multipleOf") {\n if (input.data % check.value !== BigInt(0)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_multiple_of,\n multipleOf: check.value,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n _getInvalidInput(input) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.bigint,\n received: ctx.parsedType\n });\n return INVALID;\n }\n gte(value, message) {\n return this.setLimit("min", value, true, errorUtil.toString(message));\n }\n gt(value, message) {\n return this.setLimit("min", value, false, errorUtil.toString(message));\n }\n lte(value, message) {\n return this.setLimit("max", value, true, errorUtil.toString(message));\n }\n lt(value, message) {\n return this.setLimit("max", value, false, errorUtil.toString(message));\n }\n setLimit(kind, value, inclusive, message) {\n return new ZodBigInt({\n ...this._def,\n checks: [\n ...this._def.checks,\n {\n kind,\n value,\n inclusive,\n message: errorUtil.toString(message)\n }\n ]\n });\n }\n _addCheck(check) {\n return new ZodBigInt({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n positive(message) {\n return this._addCheck({\n kind: "min",\n value: BigInt(0),\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n negative(message) {\n return this._addCheck({\n kind: "max",\n value: BigInt(0),\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n nonpositive(message) {\n return this._addCheck({\n kind: "max",\n value: BigInt(0),\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n nonnegative(message) {\n return this._addCheck({\n kind: "min",\n value: BigInt(0),\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n multipleOf(value, message) {\n return this._addCheck({\n kind: "multipleOf",\n value,\n message: errorUtil.toString(message)\n });\n }\n get minValue() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxValue() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n }\n ZodBigInt.create = (params) => {\n var _a;\n return new ZodBigInt({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodBigInt,\n coerce: (_a = params === null || params === void 0 ? void 0 : params.coerce) !== null && _a !== void 0 ? _a : false,\n ...processCreateParams(params)\n });\n };\n class ZodBoolean extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = Boolean(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.boolean) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.boolean,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodBoolean.create = (params) => {\n return new ZodBoolean({\n typeName: ZodFirstPartyTypeKind.ZodBoolean,\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n ...processCreateParams(params)\n });\n };\n class ZodDate extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = new Date(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.date) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.date,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n if (isNaN(input.data.getTime())) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_date\n });\n return INVALID;\n }\n const status = new ParseStatus();\n let ctx = void 0;\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n if (input.data.getTime() < check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n message: check.message,\n inclusive: true,\n exact: false,\n minimum: check.value,\n type: "date"\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n if (input.data.getTime() > check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n message: check.message,\n inclusive: true,\n exact: false,\n maximum: check.value,\n type: "date"\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return {\n status: status.value,\n value: new Date(input.data.getTime())\n };\n }\n _addCheck(check) {\n return new ZodDate({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n min(minDate, message) {\n return this._addCheck({\n kind: "min",\n value: minDate.getTime(),\n message: errorUtil.toString(message)\n });\n }\n max(maxDate, message) {\n return this._addCheck({\n kind: "max",\n value: maxDate.getTime(),\n message: errorUtil.toString(message)\n });\n }\n get minDate() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min != null ? new Date(min) : null;\n }\n get maxDate() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max != null ? new Date(max) : null;\n }\n }\n ZodDate.create = (params) => {\n return new ZodDate({\n checks: [],\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n typeName: ZodFirstPartyTypeKind.ZodDate,\n ...processCreateParams(params)\n });\n };\n class ZodSymbol extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.symbol) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.symbol,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodSymbol.create = (params) => {\n return new ZodSymbol({\n typeName: ZodFirstPartyTypeKind.ZodSymbol,\n ...processCreateParams(params)\n });\n };\n class ZodUndefined extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.undefined) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.undefined,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodUndefined.create = (params) => {\n return new ZodUndefined({\n typeName: ZodFirstPartyTypeKind.ZodUndefined,\n ...processCreateParams(params)\n });\n };\n class ZodNull extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.null) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.null,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodNull.create = (params) => {\n return new ZodNull({\n typeName: ZodFirstPartyTypeKind.ZodNull,\n ...processCreateParams(params)\n });\n };\n class ZodAny extends ZodType {\n constructor() {\n super(...arguments);\n this._any = true;\n }\n _parse(input) {\n return OK(input.data);\n }\n }\n ZodAny.create = (params) => {\n return new ZodAny({\n typeName: ZodFirstPartyTypeKind.ZodAny,\n ...processCreateParams(params)\n });\n };\n class ZodUnknown extends ZodType {\n constructor() {\n super(...arguments);\n this._unknown = true;\n }\n _parse(input) {\n return OK(input.data);\n }\n }\n ZodUnknown.create = (params) => {\n return new ZodUnknown({\n typeName: ZodFirstPartyTypeKind.ZodUnknown,\n ...processCreateParams(params)\n });\n };\n class ZodNever extends ZodType {\n _parse(input) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.never,\n received: ctx.parsedType\n });\n return INVALID;\n }\n }\n ZodNever.create = (params) => {\n return new ZodNever({\n typeName: ZodFirstPartyTypeKind.ZodNever,\n ...processCreateParams(params)\n });\n };\n class ZodVoid extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.undefined) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.void,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodVoid.create = (params) => {\n return new ZodVoid({\n typeName: ZodFirstPartyTypeKind.ZodVoid,\n ...processCreateParams(params)\n });\n };\n class ZodArray extends ZodType {\n _parse(input) {\n const { ctx, status } = this._processInputParams(input);\n const def = this._def;\n if (ctx.parsedType !== ZodParsedType.array) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.array,\n received: ctx.parsedType\n });\n return INVALID;\n }\n if (def.exactLength !== null) {\n const tooBig = ctx.data.length > def.exactLength.value;\n const tooSmall = ctx.data.length < def.exactLength.value;\n if (tooBig || tooSmall) {\n addIssueToContext(ctx, {\n code: tooBig ? ZodIssueCode.too_big : ZodIssueCode.too_small,\n minimum: tooSmall ? def.exactLength.value : void 0,\n maximum: tooBig ? def.exactLength.value : void 0,\n type: "array",\n inclusive: true,\n exact: true,\n message: def.exactLength.message\n });\n status.dirty();\n }\n }\n if (def.minLength !== null) {\n if (ctx.data.length < def.minLength.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: def.minLength.value,\n type: "array",\n inclusive: true,\n exact: false,\n message: def.minLength.message\n });\n status.dirty();\n }\n }\n if (def.maxLength !== null) {\n if (ctx.data.length > def.maxLength.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: def.maxLength.value,\n type: "array",\n inclusive: true,\n exact: false,\n message: def.maxLength.message\n });\n status.dirty();\n }\n }\n if (ctx.common.async) {\n return Promise.all([...ctx.data].map((item, i2) => {\n return def.type._parseAsync(new ParseInputLazyPath(ctx, item, ctx.path, i2));\n })).then((result2) => {\n return ParseStatus.mergeArray(status, result2);\n });\n }\n const result = [...ctx.data].map((item, i2) => {\n return def.type._parseSync(new ParseInputLazyPath(ctx, item, ctx.path, i2));\n });\n return ParseStatus.mergeArray(status, result);\n }\n get element() {\n return this._def.type;\n }\n min(minLength, message) {\n return new ZodArray({\n ...this._def,\n minLength: { value: minLength, message: errorUtil.toString(message) }\n });\n }\n max(maxLength, message) {\n return new ZodArray({\n ...this._def,\n maxLength: { value: maxLength, message: errorUtil.toString(message) }\n });\n }\n length(len, message) {\n return new ZodArray({\n ...this._def,\n exactLength: { value: len, message: errorUtil.toString(message) }\n });\n }\n nonempty(message) {\n return this.min(1, message);\n }\n }\n ZodArray.create = (schema, params) => {\n return new ZodArray({\n type: schema,\n minLength: null,\n maxLength: null,\n exactLength: null,\n typeName: ZodFirstPartyTypeKind.ZodArray,\n ...processCreateParams(params)\n });\n };\n function deepPartialify(schema) {\n if (schema instanceof ZodObject) {\n const newShape = {};\n for (const key in schema.shape) {\n const fieldSchema = schema.shape[key];\n newShape[key] = ZodOptional.create(deepPartialify(fieldSchema));\n }\n return new ZodObject({\n ...schema._def,\n shape: () => newShape\n });\n } else if (schema instanceof ZodArray) {\n return new ZodArray({\n ...schema._def,\n type: deepPartialify(schema.element)\n });\n } else if (schema instanceof ZodOptional) {\n return ZodOptional.create(deepPartialify(schema.unwrap()));\n } else if (schema instanceof ZodNullable) {\n return ZodNullable.create(deepPartialify(schema.unwrap()));\n } else if (schema instanceof ZodTuple) {\n return ZodTuple.create(schema.items.map((item) => deepPartialify(item)));\n } else {\n return schema;\n }\n }\n class ZodObject extends ZodType {\n constructor() {\n super(...arguments);\n this._cached = null;\n this.nonstrict = this.passthrough;\n this.augment = this.extend;\n }\n _getCached() {\n if (this._cached !== null)\n return this._cached;\n const shape = this._def.shape();\n const keys = util.objectKeys(shape);\n return this._cached = { shape, keys };\n }\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.object) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n const { status, ctx } = this._processInputParams(input);\n const { shape, keys: shapeKeys } = this._getCached();\n const extraKeys = [];\n if (!(this._def.catchall instanceof ZodNever && this._def.unknownKeys === "strip")) {\n for (const key in ctx.data) {\n if (!shapeKeys.includes(key)) {\n extraKeys.push(key);\n }\n }\n }\n const pairs = [];\n for (const key of shapeKeys) {\n const keyValidator = shape[key];\n const value = ctx.data[key];\n pairs.push({\n key: { status: "valid", value: key },\n value: keyValidator._parse(new ParseInputLazyPath(ctx, value, ctx.path, key)),\n alwaysSet: key in ctx.data\n });\n }\n if (this._def.catchall instanceof ZodNever) {\n const unknownKeys = this._def.unknownKeys;\n if (unknownKeys === "passthrough") {\n for (const key of extraKeys) {\n pairs.push({\n key: { status: "valid", value: key },\n value: { status: "valid", value: ctx.data[key] }\n });\n }\n } else if (unknownKeys === "strict") {\n if (extraKeys.length > 0) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.unrecognized_keys,\n keys: extraKeys\n });\n status.dirty();\n }\n } else if (unknownKeys === "strip") ;\n else {\n throw new Error(`Internal ZodObject error: invalid unknownKeys value.`);\n }\n } else {\n const catchall = this._def.catchall;\n for (const key of extraKeys) {\n const value = ctx.data[key];\n pairs.push({\n key: { status: "valid", value: key },\n value: catchall._parse(\n new ParseInputLazyPath(ctx, value, ctx.path, key)\n //, ctx.child(key), value, getParsedType(value)\n ),\n alwaysSet: key in ctx.data\n });\n }\n }\n if (ctx.common.async) {\n return Promise.resolve().then(async () => {\n const syncPairs = [];\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n syncPairs.push({\n key,\n value,\n alwaysSet: pair.alwaysSet\n });\n }\n return syncPairs;\n }).then((syncPairs) => {\n return ParseStatus.mergeObjectSync(status, syncPairs);\n });\n } else {\n return ParseStatus.mergeObjectSync(status, pairs);\n }\n }\n get shape() {\n return this._def.shape();\n }\n strict(message) {\n errorUtil.errToObj;\n return new ZodObject({\n ...this._def,\n unknownKeys: "strict",\n ...message !== void 0 ? {\n errorMap: (issue, ctx) => {\n var _a, _b, _c, _d;\n const defaultError = (_c = (_b = (_a = this._def).errorMap) === null || _b === void 0 ? void 0 : _b.call(_a, issue, ctx).message) !== null && _c !== void 0 ? _c : ctx.defaultError;\n if (issue.code === "unrecognized_keys")\n return {\n message: (_d = errorUtil.errToObj(message).message) !== null && _d !== void 0 ? _d : defaultError\n };\n return {\n message: defaultError\n };\n }\n } : {}\n });\n }\n strip() {\n return new ZodObject({\n ...this._def,\n unknownKeys: "strip"\n });\n }\n passthrough() {\n return new ZodObject({\n ...this._def,\n unknownKeys: "passthrough"\n });\n }\n // const AugmentFactory =\n // <Def extends ZodObjectDef>(def: Def) =>\n // <Augmentation extends ZodRawShape>(\n // augmentation: Augmentation\n // ): ZodObject<\n // extendShape<ReturnType<Def["shape"]>, Augmentation>,\n // Def["unknownKeys"],\n // Def["catchall"]\n // > => {\n // return new ZodObject({\n // ...def,\n // shape: () => ({\n // ...def.shape(),\n // ...augmentation,\n // }),\n // }) as any;\n // };\n extend(augmentation) {\n return new ZodObject({\n ...this._def,\n shape: () => ({\n ...this._def.shape(),\n ...augmentation\n })\n });\n }\n /**\n * Prior to zod@1.0.12 there was a bug in the\n * inferred type of merged objects. Please\n * upgrade if you are experiencing issues.\n */\n merge(merging) {\n const merged = new ZodObject({\n unknownKeys: merging._def.unknownKeys,\n catchall: merging._def.catchall,\n shape: () => ({\n ...this._def.shape(),\n ...merging._def.shape()\n }),\n typeName: ZodFirstPartyTypeKind.ZodObject\n });\n return merged;\n }\n // merge<\n // Incoming extends AnyZodObject,\n // Augmentation extends Incoming["shape"],\n // NewOutput extends {\n // [k in keyof Augmentation | keyof Output]: k extends keyof Augmentation\n // ? Augmentation[k]["_output"]\n // : k extends keyof Output\n // ? Output[k]\n // : never;\n // },\n // NewInput extends {\n // [k in keyof Augmentation | keyof Input]: k extends keyof Augmentation\n // ? Augmentation[k]["_input"]\n // : k extends keyof Input\n // ? Input[k]\n // : never;\n // }\n // >(\n // merging: Incoming\n // ): ZodObject<\n // extendShape<T, ReturnType<Incoming["_def"]["shape"]>>,\n // Incoming["_def"]["unknownKeys"],\n // Incoming["_def"]["catchall"],\n // NewOutput,\n // NewInput\n // > {\n // const merged: any = new ZodObject({\n // unknownKeys: merging._def.unknownKeys,\n // catchall: merging._def.catchall,\n // shape: () =>\n // objectUtil.mergeShapes(this._def.shape(), merging._def.shape()),\n // typeName: ZodFirstPartyTypeKind.ZodObject,\n // }) as any;\n // return merged;\n // }\n setKey(key, schema) {\n return this.augment({ [key]: schema });\n }\n // merge<Incoming extends AnyZodObject>(\n // merging: Incoming\n // ): //ZodObject<T & Incoming["_shape"], UnknownKeys, Catchall> = (merging) => {\n // ZodObject<\n // extendShape<T, ReturnType<Incoming["_def"]["shape"]>>,\n // Incoming["_def"]["unknownKeys"],\n // Incoming["_def"]["catchall"]\n // > {\n // // const mergedShape = objectUtil.mergeShapes(\n // // this._def.shape(),\n // // merging._def.shape()\n // // );\n // const merged: any = new ZodObject({\n // unknownKeys: merging._def.unknownKeys,\n // catchall: merging._def.catchall,\n // shape: () =>\n // objectUtil.mergeShapes(this._def.shape(), merging._def.shape()),\n // typeName: ZodFirstPartyTypeKind.ZodObject,\n // }) as any;\n // return merged;\n // }\n catchall(index) {\n return new ZodObject({\n ...this._def,\n catchall: index\n });\n }\n pick(mask) {\n const shape = {};\n util.objectKeys(mask).forEach((key) => {\n if (mask[key] && this.shape[key]) {\n shape[key] = this.shape[key];\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => shape\n });\n }\n omit(mask) {\n const shape = {};\n util.objectKeys(this.shape).forEach((key) => {\n if (!mask[key]) {\n shape[key] = this.shape[key];\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => shape\n });\n }\n /**\n * @deprecated\n */\n deepPartial() {\n return deepPartialify(this);\n }\n partial(mask) {\n const newShape = {};\n util.objectKeys(this.shape).forEach((key) => {\n const fieldSchema = this.shape[key];\n if (mask && !mask[key]) {\n newShape[key] = fieldSchema;\n } else {\n newShape[key] = fieldSchema.optional();\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => newShape\n });\n }\n required(mask) {\n const newShape = {};\n util.objectKeys(this.shape).forEach((key) => {\n if (mask && !mask[key]) {\n newShape[key] = this.shape[key];\n } else {\n const fieldSchema = this.shape[key];\n let newField = fieldSchema;\n while (newField instanceof ZodOptional) {\n newField = newField._def.innerType;\n }\n newShape[key] = newField;\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => newShape\n });\n }\n keyof() {\n return createZodEnum(util.objectKeys(this.shape));\n }\n }\n ZodObject.create = (shape, params) => {\n return new ZodObject({\n shape: () => shape,\n unknownKeys: "strip",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n ZodObject.strictCreate = (shape, params) => {\n return new ZodObject({\n shape: () => shape,\n unknownKeys: "strict",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n ZodObject.lazycreate = (shape, params) => {\n return new ZodObject({\n shape,\n unknownKeys: "strip",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n class ZodUnion extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const options = this._def.options;\n function handleResults(results) {\n for (const result of results) {\n if (result.result.status === "valid") {\n return result.result;\n }\n }\n for (const result of results) {\n if (result.result.status === "dirty") {\n ctx.common.issues.push(...result.ctx.common.issues);\n return result.result;\n }\n }\n const unionErrors = results.map((result) => new ZodError(result.ctx.common.issues));\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union,\n unionErrors\n });\n return INVALID;\n }\n if (ctx.common.async) {\n return Promise.all(options.map(async (option) => {\n const childCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n },\n parent: null\n };\n return {\n result: await option._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: childCtx\n }),\n ctx: childCtx\n };\n })).then(handleResults);\n } else {\n let dirty = void 0;\n const issues = [];\n for (const option of options) {\n const childCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n },\n parent: null\n };\n const result = option._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: childCtx\n });\n if (result.status === "valid") {\n return result;\n } else if (result.status === "dirty" && !dirty) {\n dirty = { result, ctx: childCtx };\n }\n if (childCtx.common.issues.length) {\n issues.push(childCtx.common.issues);\n }\n }\n if (dirty) {\n ctx.common.issues.push(...dirty.ctx.common.issues);\n return dirty.result;\n }\n const unionErrors = issues.map((issues2) => new ZodError(issues2));\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union,\n unionErrors\n });\n return INVALID;\n }\n }\n get options() {\n return this._def.options;\n }\n }\n ZodUnion.create = (types, params) => {\n return new ZodUnion({\n options: types,\n typeName: ZodFirstPartyTypeKind.ZodUnion,\n ...processCreateParams(params)\n });\n };\n const getDiscriminator = (type) => {\n if (type instanceof ZodLazy) {\n return getDiscriminator(type.schema);\n } else if (type instanceof ZodEffects) {\n return getDiscriminator(type.innerType());\n } else if (type instanceof ZodLiteral) {\n return [type.value];\n } else if (type instanceof ZodEnum) {\n return type.options;\n } else if (type instanceof ZodNativeEnum) {\n return util.objectValues(type.enum);\n } else if (type instanceof ZodDefault) {\n return getDiscriminator(type._def.innerType);\n } else if (type instanceof ZodUndefined) {\n return [void 0];\n } else if (type instanceof ZodNull) {\n return [null];\n } else if (type instanceof ZodOptional) {\n return [void 0, ...getDiscriminator(type.unwrap())];\n } else if (type instanceof ZodNullable) {\n return [null, ...getDiscriminator(type.unwrap())];\n } else if (type instanceof ZodBranded) {\n return getDiscriminator(type.unwrap());\n } else if (type instanceof ZodReadonly) {\n return getDiscriminator(type.unwrap());\n } else if (type instanceof ZodCatch) {\n return getDiscriminator(type._def.innerType);\n } else {\n return [];\n }\n };\n class ZodDiscriminatedUnion extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.object) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const discriminator = this.discriminator;\n const discriminatorValue = ctx.data[discriminator];\n const option = this.optionsMap.get(discriminatorValue);\n if (!option) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union_discriminator,\n options: Array.from(this.optionsMap.keys()),\n path: [discriminator]\n });\n return INVALID;\n }\n if (ctx.common.async) {\n return option._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n } else {\n return option._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n }\n }\n get discriminator() {\n return this._def.discriminator;\n }\n get options() {\n return this._def.options;\n }\n get optionsMap() {\n return this._def.optionsMap;\n }\n /**\n * The constructor of the discriminated union schema. Its behaviour is very similar to that of the normal z.union() constructor.\n * However, it only allows a union of objects, all of which need to share a discriminator property. This property must\n * have a different value for each object in the union.\n * @param discriminator the name of the discriminator property\n * @param types an array of object schemas\n * @param params\n */\n static create(discriminator, options, params) {\n const optionsMap = /* @__PURE__ */ new Map();\n for (const type of options) {\n const discriminatorValues = getDiscriminator(type.shape[discriminator]);\n if (!discriminatorValues.length) {\n throw new Error(`A discriminator value for key \\`${discriminator}\\` could not be extracted from all schema options`);\n }\n for (const value of discriminatorValues) {\n if (optionsMap.has(value)) {\n throw new Error(`Discriminator property ${String(discriminator)} has duplicate value ${String(value)}`);\n }\n optionsMap.set(value, type);\n }\n }\n return new ZodDiscriminatedUnion({\n typeName: ZodFirstPartyTypeKind.ZodDiscriminatedUnion,\n discriminator,\n options,\n optionsMap,\n ...processCreateParams(params)\n });\n }\n }\n function mergeValues(a2, b) {\n const aType = getParsedType(a2);\n const bType = getParsedType(b);\n if (a2 === b) {\n return { valid: true, data: a2 };\n } else if (aType === ZodParsedType.object && bType === ZodParsedType.object) {\n const bKeys = util.objectKeys(b);\n const sharedKeys = util.objectKeys(a2).filter((key) => bKeys.indexOf(key) !== -1);\n const newObj = { ...a2, ...b };\n for (const key of sharedKeys) {\n const sharedValue = mergeValues(a2[key], b[key]);\n if (!sharedValue.valid) {\n return { valid: false };\n }\n newObj[key] = sharedValue.data;\n }\n return { valid: true, data: newObj };\n } else if (aType === ZodParsedType.array && bType === ZodParsedType.array) {\n if (a2.length !== b.length) {\n return { valid: false };\n }\n const newArray = [];\n for (let index = 0; index < a2.length; index++) {\n const itemA = a2[index];\n const itemB = b[index];\n const sharedValue = mergeValues(itemA, itemB);\n if (!sharedValue.valid) {\n return { valid: false };\n }\n newArray.push(sharedValue.data);\n }\n return { valid: true, data: newArray };\n } else if (aType === ZodParsedType.date && bType === ZodParsedType.date && +a2 === +b) {\n return { valid: true, data: a2 };\n } else {\n return { valid: false };\n }\n }\n class ZodIntersection extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n const handleParsed = (parsedLeft, parsedRight) => {\n if (isAborted(parsedLeft) || isAborted(parsedRight)) {\n return INVALID;\n }\n const merged = mergeValues(parsedLeft.value, parsedRight.value);\n if (!merged.valid) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_intersection_types\n });\n return INVALID;\n }\n if (isDirty(parsedLeft) || isDirty(parsedRight)) {\n status.dirty();\n }\n return { status: status.value, value: merged.data };\n };\n if (ctx.common.async) {\n return Promise.all([\n this._def.left._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }),\n this._def.right._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n })\n ]).then(([left, right]) => handleParsed(left, right));\n } else {\n return handleParsed(this._def.left._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }), this._def.right._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }));\n }\n }\n }\n ZodIntersection.create = (left, right, params) => {\n return new ZodIntersection({\n left,\n right,\n typeName: ZodFirstPartyTypeKind.ZodIntersection,\n ...processCreateParams(params)\n });\n };\n class ZodTuple extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.array) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.array,\n received: ctx.parsedType\n });\n return INVALID;\n }\n if (ctx.data.length < this._def.items.length) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: this._def.items.length,\n inclusive: true,\n exact: false,\n type: "array"\n });\n return INVALID;\n }\n const rest = this._def.rest;\n if (!rest && ctx.data.length > this._def.items.length) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: this._def.items.length,\n inclusive: true,\n exact: false,\n type: "array"\n });\n status.dirty();\n }\n const items = [...ctx.data].map((item, itemIndex) => {\n const schema = this._def.items[itemIndex] || this._def.rest;\n if (!schema)\n return null;\n return schema._parse(new ParseInputLazyPath(ctx, item, ctx.path, itemIndex));\n }).filter((x) => !!x);\n if (ctx.common.async) {\n return Promise.all(items).then((results) => {\n return ParseStatus.mergeArray(status, results);\n });\n } else {\n return ParseStatus.mergeArray(status, items);\n }\n }\n get items() {\n return this._def.items;\n }\n rest(rest) {\n return new ZodTuple({\n ...this._def,\n rest\n });\n }\n }\n ZodTuple.create = (schemas, params) => {\n if (!Array.isArray(schemas)) {\n throw new Error("You must pass an array of schemas to z.tuple([ ... ])");\n }\n return new ZodTuple({\n items: schemas,\n typeName: ZodFirstPartyTypeKind.ZodTuple,\n rest: null,\n ...processCreateParams(params)\n });\n };\n class ZodRecord extends ZodType {\n get keySchema() {\n return this._def.keyType;\n }\n get valueSchema() {\n return this._def.valueType;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.object) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const pairs = [];\n const keyType = this._def.keyType;\n const valueType = this._def.valueType;\n for (const key in ctx.data) {\n pairs.push({\n key: keyType._parse(new ParseInputLazyPath(ctx, key, ctx.path, key)),\n value: valueType._parse(new ParseInputLazyPath(ctx, ctx.data[key], ctx.path, key)),\n alwaysSet: key in ctx.data\n });\n }\n if (ctx.common.async) {\n return ParseStatus.mergeObjectAsync(status, pairs);\n } else {\n return ParseStatus.mergeObjectSync(status, pairs);\n }\n }\n get element() {\n return this._def.valueType;\n }\n static create(first, second, third) {\n if (second instanceof ZodType) {\n return new ZodRecord({\n keyType: first,\n valueType: second,\n typeName: ZodFirstPartyTypeKind.ZodRecord,\n ...processCreateParams(third)\n });\n }\n return new ZodRecord({\n keyType: ZodString.create(),\n valueType: first,\n typeName: ZodFirstPartyTypeKind.ZodRecord,\n ...processCreateParams(second)\n });\n }\n }\n class ZodMap extends ZodType {\n get keySchema() {\n return this._def.keyType;\n }\n get valueSchema() {\n return this._def.valueType;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.map) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.map,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const keyType = this._def.keyType;\n const valueType = this._def.valueType;\n const pairs = [...ctx.data.entries()].map(([key, value], index) => {\n return {\n key: keyType._parse(new ParseInputLazyPath(ctx, key, ctx.path, [index, "key"])),\n value: valueType._parse(new ParseInputLazyPath(ctx, value, ctx.path, [index, "value"]))\n };\n });\n if (ctx.common.async) {\n const finalMap = /* @__PURE__ */ new Map();\n return Promise.resolve().then(async () => {\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n if (key.status === "aborted" || value.status === "aborted") {\n return INVALID;\n }\n if (key.status === "dirty" || value.status === "dirty") {\n status.dirty();\n }\n finalMap.set(key.value, value.value);\n }\n return { status: status.value, value: finalMap };\n });\n } else {\n const finalMap = /* @__PURE__ */ new Map();\n for (const pair of pairs) {\n const key = pair.key;\n const value = pair.value;\n if (key.status === "aborted" || value.status === "aborted") {\n return INVALID;\n }\n if (key.status === "dirty" || value.status === "dirty") {\n status.dirty();\n }\n finalMap.set(key.value, value.value);\n }\n return { status: status.value, value: finalMap };\n }\n }\n }\n ZodMap.create = (keyType, valueType, params) => {\n return new ZodMap({\n valueType,\n keyType,\n typeName: ZodFirstPartyTypeKind.ZodMap,\n ...processCreateParams(params)\n });\n };\n class ZodSet extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.set) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.set,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const def = this._def;\n if (def.minSize !== null) {\n if (ctx.data.size < def.minSize.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: def.minSize.value,\n type: "set",\n inclusive: true,\n exact: false,\n message: def.minSize.message\n });\n status.dirty();\n }\n }\n if (def.maxSize !== null) {\n if (ctx.data.size > def.maxSize.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: def.maxSize.value,\n type: "set",\n inclusive: true,\n exact: false,\n message: def.maxSize.message\n });\n status.dirty();\n }\n }\n const valueType = this._def.valueType;\n function finalizeSet(elements2) {\n const parsedSet = /* @__PURE__ */ new Set();\n for (const element of elements2) {\n if (element.status === "aborted")\n return INVALID;\n if (element.status === "dirty")\n status.dirty();\n parsedSet.add(element.value);\n }\n return { status: status.value, value: parsedSet };\n }\n const elements = [...ctx.data.values()].map((item, i2) => valueType._parse(new ParseInputLazyPath(ctx, item, ctx.path, i2)));\n if (ctx.common.async) {\n return Promise.all(elements).then((elements2) => finalizeSet(elements2));\n } else {\n return finalizeSet(elements);\n }\n }\n min(minSize, message) {\n return new ZodSet({\n ...this._def,\n minSize: { value: minSize, message: errorUtil.toString(message) }\n });\n }\n max(maxSize, message) {\n return new ZodSet({\n ...this._def,\n maxSize: { value: maxSize, message: errorUtil.toString(message) }\n });\n }\n size(size, message) {\n return this.min(size, message).max(size, message);\n }\n nonempty(message) {\n return this.min(1, message);\n }\n }\n ZodSet.create = (valueType, params) => {\n return new ZodSet({\n valueType,\n minSize: null,\n maxSize: null,\n typeName: ZodFirstPartyTypeKind.ZodSet,\n ...processCreateParams(params)\n });\n };\n class ZodFunction extends ZodType {\n constructor() {\n super(...arguments);\n this.validate = this.implement;\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.function) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.function,\n received: ctx.parsedType\n });\n return INVALID;\n }\n function makeArgsIssue(args, error) {\n return makeIssue({\n data: args,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n ctx.schemaErrorMap,\n getErrorMap(),\n errorMap\n ].filter((x) => !!x),\n issueData: {\n code: ZodIssueCode.invalid_arguments,\n argumentsError: error\n }\n });\n }\n function makeReturnsIssue(returns, error) {\n return makeIssue({\n data: returns,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n ctx.schemaErrorMap,\n getErrorMap(),\n errorMap\n ].filter((x) => !!x),\n issueData: {\n code: ZodIssueCode.invalid_return_type,\n returnTypeError: error\n }\n });\n }\n const params = { errorMap: ctx.common.contextualErrorMap };\n const fn = ctx.data;\n if (this._def.returns instanceof ZodPromise) {\n const me = this;\n return OK(async function(...args) {\n const error = new ZodError([]);\n const parsedArgs = await me._def.args.parseAsync(args, params).catch((e2) => {\n error.addIssue(makeArgsIssue(args, e2));\n throw error;\n });\n const result = await Reflect.apply(fn, this, parsedArgs);\n const parsedReturns = await me._def.returns._def.type.parseAsync(result, params).catch((e2) => {\n error.addIssue(makeReturnsIssue(result, e2));\n throw error;\n });\n return parsedReturns;\n });\n } else {\n const me = this;\n return OK(function(...args) {\n const parsedArgs = me._def.args.safeParse(args, params);\n if (!parsedArgs.success) {\n throw new ZodError([makeArgsIssue(args, parsedArgs.error)]);\n }\n const result = Reflect.apply(fn, this, parsedArgs.data);\n const parsedReturns = me._def.returns.safeParse(result, params);\n if (!parsedReturns.success) {\n throw new ZodError([makeReturnsIssue(result, parsedReturns.error)]);\n }\n return parsedReturns.data;\n });\n }\n }\n parameters() {\n return this._def.args;\n }\n returnType() {\n return this._def.returns;\n }\n args(...items) {\n return new ZodFunction({\n ...this._def,\n args: ZodTuple.create(items).rest(ZodUnknown.create())\n });\n }\n returns(returnType) {\n return new ZodFunction({\n ...this._def,\n returns: returnType\n });\n }\n implement(func) {\n const validatedFunc = this.parse(func);\n return validatedFunc;\n }\n strictImplement(func) {\n const validatedFunc = this.parse(func);\n return validatedFunc;\n }\n static create(args, returns, params) {\n return new ZodFunction({\n args: args ? args : ZodTuple.create([]).rest(ZodUnknown.create()),\n returns: returns || ZodUnknown.create(),\n typeName: ZodFirstPartyTypeKind.ZodFunction,\n ...processCreateParams(params)\n });\n }\n }\n class ZodLazy extends ZodType {\n get schema() {\n return this._def.getter();\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const lazySchema = this._def.getter();\n return lazySchema._parse({ data: ctx.data, path: ctx.path, parent: ctx });\n }\n }\n ZodLazy.create = (getter, params) => {\n return new ZodLazy({\n getter,\n typeName: ZodFirstPartyTypeKind.ZodLazy,\n ...processCreateParams(params)\n });\n };\n class ZodLiteral extends ZodType {\n _parse(input) {\n if (input.data !== this._def.value) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_literal,\n expected: this._def.value\n });\n return INVALID;\n }\n return { status: "valid", value: input.data };\n }\n get value() {\n return this._def.value;\n }\n }\n ZodLiteral.create = (value, params) => {\n return new ZodLiteral({\n value,\n typeName: ZodFirstPartyTypeKind.ZodLiteral,\n ...processCreateParams(params)\n });\n };\n function createZodEnum(values, params) {\n return new ZodEnum({\n values,\n typeName: ZodFirstPartyTypeKind.ZodEnum,\n ...processCreateParams(params)\n });\n }\n class ZodEnum extends ZodType {\n constructor() {\n super(...arguments);\n _ZodEnum_cache.set(this, void 0);\n }\n _parse(input) {\n if (typeof input.data !== "string") {\n const ctx = this._getOrReturnCtx(input);\n const expectedValues = this._def.values;\n addIssueToContext(ctx, {\n expected: util.joinValues(expectedValues),\n received: ctx.parsedType,\n code: ZodIssueCode.invalid_type\n });\n return INVALID;\n }\n if (!__classPrivateFieldGet(this, _ZodEnum_cache)) {\n __classPrivateFieldSet(this, _ZodEnum_cache, new Set(this._def.values));\n }\n if (!__classPrivateFieldGet(this, _ZodEnum_cache).has(input.data)) {\n const ctx = this._getOrReturnCtx(input);\n const expectedValues = this._def.values;\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_enum_value,\n options: expectedValues\n });\n return INVALID;\n }\n return OK(input.data);\n }\n get options() {\n return this._def.values;\n }\n get enum() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n get Values() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n get Enum() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n extract(values, newDef = this._def) {\n return ZodEnum.create(values, {\n ...this._def,\n ...newDef\n });\n }\n exclude(values, newDef = this._def) {\n return ZodEnum.create(this.options.filter((opt) => !values.includes(opt)), {\n ...this._def,\n ...newDef\n });\n }\n }\n _ZodEnum_cache = /* @__PURE__ */ new WeakMap();\n ZodEnum.create = createZodEnum;\n class ZodNativeEnum extends ZodType {\n constructor() {\n super(...arguments);\n _ZodNativeEnum_cache.set(this, void 0);\n }\n _parse(input) {\n const nativeEnumValues = util.getValidEnumValues(this._def.values);\n const ctx = this._getOrReturnCtx(input);\n if (ctx.parsedType !== ZodParsedType.string && ctx.parsedType !== ZodParsedType.number) {\n const expectedValues = util.objectValues(nativeEnumValues);\n addIssueToContext(ctx, {\n expected: util.joinValues(expectedValues),\n received: ctx.parsedType,\n code: ZodIssueCode.invalid_type\n });\n return INVALID;\n }\n if (!__classPrivateFieldGet(this, _ZodNativeEnum_cache)) {\n __classPrivateFieldSet(this, _ZodNativeEnum_cache, new Set(util.getValidEnumValues(this._def.values)));\n }\n if (!__classPrivateFieldGet(this, _ZodNativeEnum_cache).has(input.data)) {\n const expectedValues = util.objectValues(nativeEnumValues);\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_enum_value,\n options: expectedValues\n });\n return INVALID;\n }\n return OK(input.data);\n }\n get enum() {\n return this._def.values;\n }\n }\n _ZodNativeEnum_cache = /* @__PURE__ */ new WeakMap();\n ZodNativeEnum.create = (values, params) => {\n return new ZodNativeEnum({\n values,\n typeName: ZodFirstPartyTypeKind.ZodNativeEnum,\n ...processCreateParams(params)\n });\n };\n class ZodPromise extends ZodType {\n unwrap() {\n return this._def.type;\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.promise && ctx.common.async === false) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.promise,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const promisified = ctx.parsedType === ZodParsedType.promise ? ctx.data : Promise.resolve(ctx.data);\n return OK(promisified.then((data) => {\n return this._def.type.parseAsync(data, {\n path: ctx.path,\n errorMap: ctx.common.contextualErrorMap\n });\n }));\n }\n }\n ZodPromise.create = (schema, params) => {\n return new ZodPromise({\n type: schema,\n typeName: ZodFirstPartyTypeKind.ZodPromise,\n ...processCreateParams(params)\n });\n };\n class ZodEffects extends ZodType {\n innerType() {\n return this._def.schema;\n }\n sourceType() {\n return this._def.schema._def.typeName === ZodFirstPartyTypeKind.ZodEffects ? this._def.schema.sourceType() : this._def.schema;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n const effect = this._def.effect || null;\n const checkCtx = {\n addIssue: (arg) => {\n addIssueToContext(ctx, arg);\n if (arg.fatal) {\n status.abort();\n } else {\n status.dirty();\n }\n },\n get path() {\n return ctx.path;\n }\n };\n checkCtx.addIssue = checkCtx.addIssue.bind(checkCtx);\n if (effect.type === "preprocess") {\n const processed = effect.transform(ctx.data, checkCtx);\n if (ctx.common.async) {\n return Promise.resolve(processed).then(async (processed2) => {\n if (status.value === "aborted")\n return INVALID;\n const result = await this._def.schema._parseAsync({\n data: processed2,\n path: ctx.path,\n parent: ctx\n });\n if (result.status === "aborted")\n return INVALID;\n if (result.status === "dirty")\n return DIRTY(result.value);\n if (status.value === "dirty")\n return DIRTY(result.value);\n return result;\n });\n } else {\n if (status.value === "aborted")\n return INVALID;\n const result = this._def.schema._parseSync({\n data: processed,\n path: ctx.path,\n parent: ctx\n });\n if (result.status === "aborted")\n return INVALID;\n if (result.status === "dirty")\n return DIRTY(result.value);\n if (status.value === "dirty")\n return DIRTY(result.value);\n return result;\n }\n }\n if (effect.type === "refinement") {\n const executeRefinement = (acc) => {\n const result = effect.refinement(acc, checkCtx);\n if (ctx.common.async) {\n return Promise.resolve(result);\n }\n if (result instanceof Promise) {\n throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");\n }\n return acc;\n };\n if (ctx.common.async === false) {\n const inner = this._def.schema._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inner.status === "aborted")\n return INVALID;\n if (inner.status === "dirty")\n status.dirty();\n executeRefinement(inner.value);\n return { status: status.value, value: inner.value };\n } else {\n return this._def.schema._parseAsync({ data: ctx.data, path: ctx.path, parent: ctx }).then((inner) => {\n if (inner.status === "aborted")\n return INVALID;\n if (inner.status === "dirty")\n status.dirty();\n return executeRefinement(inner.value).then(() => {\n return { status: status.value, value: inner.value };\n });\n });\n }\n }\n if (effect.type === "transform") {\n if (ctx.common.async === false) {\n const base = this._def.schema._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (!isValid(base))\n return base;\n const result = effect.transform(base.value, checkCtx);\n if (result instanceof Promise) {\n throw new Error(`Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.`);\n }\n return { status: status.value, value: result };\n } else {\n return this._def.schema._parseAsync({ data: ctx.data, path: ctx.path, parent: ctx }).then((base) => {\n if (!isValid(base))\n return base;\n return Promise.resolve(effect.transform(base.value, checkCtx)).then((result) => ({ status: status.value, value: result }));\n });\n }\n }\n util.assertNever(effect);\n }\n }\n ZodEffects.create = (schema, effect, params) => {\n return new ZodEffects({\n schema,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect,\n ...processCreateParams(params)\n });\n };\n ZodEffects.createWithPreprocess = (preprocess, schema, params) => {\n return new ZodEffects({\n schema,\n effect: { type: "preprocess", transform: preprocess },\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n ...processCreateParams(params)\n });\n };\n class ZodOptional extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType === ZodParsedType.undefined) {\n return OK(void 0);\n }\n return this._def.innerType._parse(input);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodOptional.create = (type, params) => {\n return new ZodOptional({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodOptional,\n ...processCreateParams(params)\n });\n };\n class ZodNullable extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType === ZodParsedType.null) {\n return OK(null);\n }\n return this._def.innerType._parse(input);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodNullable.create = (type, params) => {\n return new ZodNullable({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodNullable,\n ...processCreateParams(params)\n });\n };\n class ZodDefault extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n let data = ctx.data;\n if (ctx.parsedType === ZodParsedType.undefined) {\n data = this._def.defaultValue();\n }\n return this._def.innerType._parse({\n data,\n path: ctx.path,\n parent: ctx\n });\n }\n removeDefault() {\n return this._def.innerType;\n }\n }\n ZodDefault.create = (type, params) => {\n return new ZodDefault({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodDefault,\n defaultValue: typeof params.default === "function" ? params.default : () => params.default,\n ...processCreateParams(params)\n });\n };\n class ZodCatch extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const newCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n }\n };\n const result = this._def.innerType._parse({\n data: newCtx.data,\n path: newCtx.path,\n parent: {\n ...newCtx\n }\n });\n if (isAsync(result)) {\n return result.then((result2) => {\n return {\n status: "valid",\n value: result2.status === "valid" ? result2.value : this._def.catchValue({\n get error() {\n return new ZodError(newCtx.common.issues);\n },\n input: newCtx.data\n })\n };\n });\n } else {\n return {\n status: "valid",\n value: result.status === "valid" ? result.value : this._def.catchValue({\n get error() {\n return new ZodError(newCtx.common.issues);\n },\n input: newCtx.data\n })\n };\n }\n }\n removeCatch() {\n return this._def.innerType;\n }\n }\n ZodCatch.create = (type, params) => {\n return new ZodCatch({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodCatch,\n catchValue: typeof params.catch === "function" ? params.catch : () => params.catch,\n ...processCreateParams(params)\n });\n };\n class ZodNaN extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.nan) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.nan,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return { status: "valid", value: input.data };\n }\n }\n ZodNaN.create = (params) => {\n return new ZodNaN({\n typeName: ZodFirstPartyTypeKind.ZodNaN,\n ...processCreateParams(params)\n });\n };\n const BRAND = Symbol("zod_brand");\n class ZodBranded extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const data = ctx.data;\n return this._def.type._parse({\n data,\n path: ctx.path,\n parent: ctx\n });\n }\n unwrap() {\n return this._def.type;\n }\n }\n class ZodPipeline extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.common.async) {\n const handleAsync = async () => {\n const inResult = await this._def.in._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inResult.status === "aborted")\n return INVALID;\n if (inResult.status === "dirty") {\n status.dirty();\n return DIRTY(inResult.value);\n } else {\n return this._def.out._parseAsync({\n data: inResult.value,\n path: ctx.path,\n parent: ctx\n });\n }\n };\n return handleAsync();\n } else {\n const inResult = this._def.in._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inResult.status === "aborted")\n return INVALID;\n if (inResult.status === "dirty") {\n status.dirty();\n return {\n status: "dirty",\n value: inResult.value\n };\n } else {\n return this._def.out._parseSync({\n data: inResult.value,\n path: ctx.path,\n parent: ctx\n });\n }\n }\n }\n static create(a2, b) {\n return new ZodPipeline({\n in: a2,\n out: b,\n typeName: ZodFirstPartyTypeKind.ZodPipeline\n });\n }\n }\n class ZodReadonly extends ZodType {\n _parse(input) {\n const result = this._def.innerType._parse(input);\n const freeze = (data) => {\n if (isValid(data)) {\n data.value = Object.freeze(data.value);\n }\n return data;\n };\n return isAsync(result) ? result.then((data) => freeze(data)) : freeze(result);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodReadonly.create = (type, params) => {\n return new ZodReadonly({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodReadonly,\n ...processCreateParams(params)\n });\n };\n function cleanParams(params, data) {\n const p = typeof params === "function" ? params(data) : typeof params === "string" ? { message: params } : params;\n const p2 = typeof p === "string" ? { message: p } : p;\n return p2;\n }\n function custom(check, _params = {}, fatal) {\n if (check)\n return ZodAny.create().superRefine((data, ctx) => {\n var _a, _b;\n const r2 = check(data);\n if (r2 instanceof Promise) {\n return r2.then((r3) => {\n var _a2, _b2;\n if (!r3) {\n const params = cleanParams(_params, data);\n const _fatal = (_b2 = (_a2 = params.fatal) !== null && _a2 !== void 0 ? _a2 : fatal) !== null && _b2 !== void 0 ? _b2 : true;\n ctx.addIssue({ code: "custom", ...params, fatal: _fatal });\n }\n });\n }\n if (!r2) {\n const params = cleanParams(_params, data);\n const _fatal = (_b = (_a = params.fatal) !== null && _a !== void 0 ? _a : fatal) !== null && _b !== void 0 ? _b : true;\n ctx.addIssue({ code: "custom", ...params, fatal: _fatal });\n }\n return;\n });\n return ZodAny.create();\n }\n const late = {\n object: ZodObject.lazycreate\n };\n var ZodFirstPartyTypeKind;\n (function(ZodFirstPartyTypeKind2) {\n ZodFirstPartyTypeKind2["ZodString"] = "ZodString";\n ZodFirstPartyTypeKind2["ZodNumber"] = "ZodNumber";\n ZodFirstPartyTypeKind2["ZodNaN"] = "ZodNaN";\n ZodFirstPartyTypeKind2["ZodBigInt"] = "ZodBigInt";\n ZodFirstPartyTypeKind2["ZodBoolean"] = "ZodBoolean";\n ZodFirstPartyTypeKind2["ZodDate"] = "ZodDate";\n ZodFirstPartyTypeKind2["ZodSymbol"] = "ZodSymbol";\n ZodFirstPartyTypeKind2["ZodUndefined"] = "ZodUndefined";\n ZodFirstPartyTypeKind2["ZodNull"] = "ZodNull";\n ZodFirstPartyTypeKind2["ZodAny"] = "ZodAny";\n ZodFirstPartyTypeKind2["ZodUnknown"] = "ZodUnknown";\n ZodFirstPartyTypeKind2["ZodNever"] = "ZodNever";\n ZodFirstPartyTypeKind2["ZodVoid"] = "ZodVoid";\n ZodFirstPartyTypeKind2["ZodArray"] = "ZodArray";\n ZodFirstPartyTypeKind2["ZodObject"] = "ZodObject";\n ZodFirstPartyTypeKind2["ZodUnion"] = "ZodUnion";\n ZodFirstPartyTypeKind2["ZodDiscriminatedUnion"] = "ZodDiscriminatedUnion";\n ZodFirstPartyTypeKind2["ZodIntersection"] = "ZodIntersection";\n ZodFirstPartyTypeKind2["ZodTuple"] = "ZodTuple";\n ZodFirstPartyTypeKind2["ZodRecord"] = "ZodRecord";\n ZodFirstPartyTypeKind2["ZodMap"] = "ZodMap";\n ZodFirstPartyTypeKind2["ZodSet"] = "ZodSet";\n ZodFirstPartyTypeKind2["ZodFunction"] = "ZodFunction";\n ZodFirstPartyTypeKind2["ZodLazy"] = "ZodLazy";\n ZodFirstPartyTypeKind2["ZodLiteral"] = "ZodLiteral";\n ZodFirstPartyTypeKind2["ZodEnum"] = "ZodEnum";\n ZodFirstPartyTypeKind2["ZodEffects"] = "ZodEffects";\n ZodFirstPartyTypeKind2["ZodNativeEnum"] = "ZodNativeEnum";\n ZodFirstPartyTypeKind2["ZodOptional"] = "ZodOptional";\n ZodFirstPartyTypeKind2["ZodNullable"] = "ZodNullable";\n ZodFirstPartyTypeKind2["ZodDefault"] = "ZodDefault";\n ZodFirstPartyTypeKind2["ZodCatch"] = "ZodCatch";\n ZodFirstPartyTypeKind2["ZodPromise"] = "ZodPromise";\n ZodFirstPartyTypeKind2["ZodBranded"] = "ZodBranded";\n ZodFirstPartyTypeKind2["ZodPipeline"] = "ZodPipeline";\n ZodFirstPartyTypeKind2["ZodReadonly"] = "ZodReadonly";\n })(ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {}));\n const instanceOfType = (cls, params = {\n message: `Input not instance of ${cls.name}`\n }) => custom((data) => data instanceof cls, params);\n const stringType = ZodString.create;\n const numberType = ZodNumber.create;\n const nanType = ZodNaN.create;\n const bigIntType = ZodBigInt.create;\n const booleanType = ZodBoolean.create;\n const dateType = ZodDate.create;\n const symbolType = ZodSymbol.create;\n const undefinedType = ZodUndefined.create;\n const nullType = ZodNull.create;\n const anyType = ZodAny.create;\n const unknownType = ZodUnknown.create;\n const neverType = ZodNever.create;\n const voidType = ZodVoid.create;\n const arrayType = ZodArray.create;\n const objectType = ZodObject.create;\n const strictObjectType = ZodObject.strictCreate;\n const unionType = ZodUnion.create;\n const discriminatedUnionType = ZodDiscriminatedUnion.create;\n const intersectionType = ZodIntersection.create;\n const tupleType = ZodTuple.create;\n const recordType = ZodRecord.create;\n const mapType = ZodMap.create;\n const setType = ZodSet.create;\n const functionType = ZodFunction.create;\n const lazyType = ZodLazy.create;\n const literalType = ZodLiteral.create;\n const enumType = ZodEnum.create;\n const nativeEnumType = ZodNativeEnum.create;\n const promiseType = ZodPromise.create;\n const effectsType = ZodEffects.create;\n const optionalType = ZodOptional.create;\n const nullableType = ZodNullable.create;\n const preprocessType = ZodEffects.createWithPreprocess;\n const pipelineType = ZodPipeline.create;\n const ostring = () => stringType().optional();\n const onumber = () => numberType().optional();\n const oboolean = () => booleanType().optional();\n const coerce = {\n string: (arg) => ZodString.create({ ...arg, coerce: true }),\n number: (arg) => ZodNumber.create({ ...arg, coerce: true }),\n boolean: (arg) => ZodBoolean.create({\n ...arg,\n coerce: true\n }),\n bigint: (arg) => ZodBigInt.create({ ...arg, coerce: true }),\n date: (arg) => ZodDate.create({ ...arg, coerce: true })\n };\n const NEVER = INVALID;\n var z$1 = /* @__PURE__ */ Object.freeze({\n __proto__: null,\n defaultErrorMap: errorMap,\n setErrorMap,\n getErrorMap,\n makeIssue,\n EMPTY_PATH,\n addIssueToContext,\n ParseStatus,\n INVALID,\n DIRTY,\n OK,\n isAborted,\n isDirty,\n isValid,\n isAsync,\n get util() {\n return util;\n },\n get objectUtil() {\n return objectUtil;\n },\n ZodParsedType,\n getParsedType,\n ZodType,\n datetimeRegex,\n ZodString,\n ZodNumber,\n ZodBigInt,\n ZodBoolean,\n ZodDate,\n ZodSymbol,\n ZodUndefined,\n ZodNull,\n ZodAny,\n ZodUnknown,\n ZodNever,\n ZodVoid,\n ZodArray,\n ZodObject,\n ZodUnion,\n ZodDiscriminatedUnion,\n ZodIntersection,\n ZodTuple,\n ZodRecord,\n ZodMap,\n ZodSet,\n ZodFunction,\n ZodLazy,\n ZodLiteral,\n ZodEnum,\n ZodNativeEnum,\n ZodPromise,\n ZodEffects,\n ZodTransformer: ZodEffects,\n ZodOptional,\n ZodNullable,\n ZodDefault,\n ZodCatch,\n ZodNaN,\n BRAND,\n ZodBranded,\n ZodPipeline,\n ZodReadonly,\n custom,\n Schema: ZodType,\n ZodSchema: ZodType,\n late,\n get ZodFirstPartyTypeKind() {\n return ZodFirstPartyTypeKind;\n },\n coerce,\n any: anyType,\n array: arrayType,\n bigint: bigIntType,\n boolean: booleanType,\n date: dateType,\n discriminatedUnion: discriminatedUnionType,\n effect: effectsType,\n "enum": enumType,\n "function": functionType,\n "instanceof": instanceOfType,\n intersection: intersectionType,\n lazy: lazyType,\n literal: literalType,\n map: mapType,\n nan: nanType,\n nativeEnum: nativeEnumType,\n never: neverType,\n "null": nullType,\n nullable: nullableType,\n number: numberType,\n object: objectType,\n oboolean,\n onumber,\n optional: optionalType,\n ostring,\n pipeline: pipelineType,\n preprocess: preprocessType,\n promise: promiseType,\n record: recordType,\n set: setType,\n strictObject: strictObjectType,\n string: stringType,\n symbol: symbolType,\n transformer: effectsType,\n tuple: tupleType,\n "undefined": undefinedType,\n union: unionType,\n unknown: unknownType,\n "void": voidType,\n NEVER,\n ZodIssueCode,\n quotelessJson,\n ZodError\n });\n z$1.object({\n nucleotideSequences: z$1.array(\n z$1.object({\n name: z$1.string(),\n sequence: z$1.string()\n })\n ),\n genes: z$1.array(\n z$1.object({\n name: z$1.string(),\n sequence: z$1.string()\n })\n )\n });\n const orderByType = z$1.enum(["ascending", "descending"]);\n const orderBy = z$1.object({\n field: z$1.string(),\n type: orderByType\n });\n const lapisBaseRequest = z$1.object({\n limit: z$1.number().optional(),\n offset: z$1.number().optional(),\n fields: z$1.array(z$1.string()).optional(),\n orderBy: z$1.array(orderBy).optional()\n }).catchall(z$1.union([z$1.boolean(), z$1.undefined(), z$1.string(), z$1.number(), z$1.null(), z$1.array(z$1.string())]));\n lapisBaseRequest.extend({ minProportion: z$1.number().optional() });\n const mutationProportionCount = z$1.object({\n mutation: z$1.string(),\n proportion: z$1.number(),\n count: z$1.number(),\n sequenceName: z$1.union([z$1.string(), z$1.null()]),\n mutationFrom: z$1.string(),\n mutationTo: z$1.string(),\n position: z$1.number()\n });\n const mutationsResponse = makeLapisResponse(z$1.array(mutationProportionCount));\n const insertionCount = z$1.object({\n insertion: z$1.string(),\n count: z$1.number(),\n insertedSymbols: z$1.string(),\n position: z$1.number(),\n sequenceName: z$1.union([z$1.string(), z$1.null()])\n });\n makeLapisResponse(z$1.array(insertionCount));\n const baseResponseValueSchema = z$1.union([z$1.string(), z$1.number(), z$1.boolean(), z$1.null()]);\n const aggregatedItem = z$1.object({ count: z$1.number() }).catchall(baseResponseValueSchema);\n const aggregatedResponse = makeLapisResponse(z$1.array(aggregatedItem));\n const detailsItem = z$1.object({}).catchall(baseResponseValueSchema);\n makeLapisResponse(z$1.array(detailsItem));\n function makeLapisResponse(data) {\n return z$1.object({\n data\n });\n }\n const problemDetail = z$1.object({\n title: z$1.string().optional(),\n status: z$1.number(),\n detail: z$1.string().optional(),\n type: z$1.string(),\n instance: z$1.string().optional()\n });\n const lapisError = z$1.object({\n error: problemDetail\n });\n class UnknownLapisError extends Error {\n constructor(message, status, requestedData) {\n super(message);\n this.status = status;\n this.requestedData = requestedData;\n this.name = "UnknownLapisError";\n }\n }\n class LapisError extends Error {\n constructor(message, status, problemDetail2, requestedData) {\n super(message);\n this.status = status;\n this.problemDetail = problemDetail2;\n this.requestedData = requestedData;\n this.name = "LapisError";\n }\n }\n async function fetchAggregated(lapisUrl, body, signal) {\n const response = await callLapis(\n aggregatedEndpoint(lapisUrl),\n {\n method: "POST",\n headers: {\n "Content-Type": "application/json"\n },\n body: JSON.stringify(body),\n signal\n },\n "aggregated data"\n );\n return aggregatedResponse.parse(await response.json());\n }\n async function fetchSubstitutionsOrDeletions(lapisUrl, body, sequenceType, signal) {\n const response = await callLapis(\n substitutionsOrDeletionsEndpoint(lapisUrl, sequenceType),\n {\n method: "POST",\n headers: {\n "Content-Type": "application/json"\n },\n body: JSON.stringify(body),\n signal\n },\n `${sequenceType} mutations`\n );\n return mutationsResponse.parse(await response.json());\n }\n async function callLapis(input, init, requestedDataName) {\n try {\n const response = await fetch(input, init);\n await handleErrors(response, requestedDataName);\n return response;\n } catch (error) {\n const message = error instanceof Error ? error.message : `${error}`;\n throw new UnknownLapisError(`Failed to connect to LAPIS: ${message}`, 500, requestedDataName);\n }\n }\n const handleErrors = async (response, requestedData) => {\n if (!response.ok) {\n if (response.status >= 400 && response.status < 500) {\n const json = await response.json();\n const lapisErrorResult = lapisError.safeParse(json);\n if (lapisErrorResult.success) {\n throw new LapisError(\n response.statusText + lapisErrorResult.data.error.detail,\n response.status,\n lapisErrorResult.data.error,\n requestedData\n );\n }\n const problemDetailResult = problemDetail.safeParse(json);\n if (problemDetailResult.success) {\n throw new LapisError(\n response.statusText + problemDetailResult.data.detail,\n response.status,\n problemDetailResult.data,\n requestedData\n );\n }\n throw new UnknownLapisError(\n `${response.statusText}: ${JSON.stringify(json)}`,\n response.status,\n requestedData\n );\n }\n throw new UnknownLapisError(`${response.statusText}: ${response.status}`, response.status, requestedData);\n }\n };\n const aggregatedEndpoint = (lapisUrl) => `${lapisUrl}/sample/aggregated`;\n const substitutionsOrDeletionsEndpoint = (lapisUrl, sequenceType) => {\n return sequenceType === "amino acid" ? `${lapisUrl}/sample/aminoAcidMutations` : `${lapisUrl}/sample/nucleotideMutations`;\n };\n class FetchAggregatedOperator {\n constructor(filter, fields = []) {\n this.filter = filter;\n this.fields = fields;\n }\n async evaluate(lapisUrl, signal) {\n const aggregatedResponse2 = (await fetchAggregated(\n lapisUrl,\n {\n ...this.filter,\n fields: this.fields\n },\n signal\n )).data;\n if (isFieldsArrayWithCount(aggregatedResponse2)) {\n return {\n content: aggregatedResponse2\n };\n }\n throw new Error("Aggregated response does not have count");\n }\n }\n function isFieldsArrayWithCount(data) {\n return data.every((item) => typeof item === "object" && "count" in item && typeof item.count === "number");\n }\n class GroupByOperator {\n constructor(child, field, aggregate) {\n this.child = child;\n this.field = field;\n this.aggregate = aggregate;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n const grouped = /* @__PURE__ */ new Map();\n for (const row of childEvaluated.content) {\n const key = row[this.field];\n if (!grouped.has(key)) {\n grouped.set(key, []);\n }\n grouped.get(key).push(row);\n }\n const result = new Array();\n for (const [, values] of grouped) {\n result.push(this.aggregate(values));\n }\n return {\n content: result\n };\n }\n }\n class GroupByAndSumOperator extends GroupByOperator {\n constructor(child, groupByField, sumField) {\n super(child, groupByField, (values) => {\n let n = 0;\n for (const value of values) {\n n += value[sumField];\n }\n return {\n [groupByField]: values[0][groupByField],\n [sumField]: n\n };\n });\n }\n }\n class MapOperator {\n constructor(child, func) {\n this.child = child;\n this.func = func;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n return {\n content: childEvaluated.content.map(this.func)\n };\n }\n }\n class RenameFieldOperator extends MapOperator {\n constructor(child, oldFieldName, newFieldName) {\n super(\n child,\n (value) => ({\n ...value,\n [newFieldName]: value[oldFieldName]\n })\n );\n }\n }\n class SortOperator {\n constructor(child, compareFn) {\n this.child = child;\n this.compareFn = compareFn;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n return {\n content: childEvaluated.content.sort(this.compareFn)\n };\n }\n }\n var SECONDS_A_MINUTE = 60;\n var SECONDS_A_HOUR = SECONDS_A_MINUTE * 60;\n var SECONDS_A_DAY = SECONDS_A_HOUR * 24;\n var SECONDS_A_WEEK = SECONDS_A_DAY * 7;\n var MILLISECONDS_A_SECOND = 1e3;\n var MILLISECONDS_A_MINUTE = SECONDS_A_MINUTE * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_HOUR = SECONDS_A_HOUR * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_DAY = SECONDS_A_DAY * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_WEEK = SECONDS_A_WEEK * MILLISECONDS_A_SECOND;\n var MS = "millisecond";\n var S = "second";\n var MIN = "minute";\n var H = "hour";\n var D = "day";\n var W = "week";\n var M = "month";\n var Q = "quarter";\n var Y = "year";\n var DATE = "date";\n var FORMAT_DEFAULT = "YYYY-MM-DDTHH:mm:ssZ";\n var INVALID_DATE_STRING = "Invalid Date";\n var REGEX_PARSE = /^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/;\n var REGEX_FORMAT = /\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g;\n var en = {\n name: "en",\n weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),\n months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"),\n ordinal: function ordinal(n) {\n var s2 = ["th", "st", "nd", "rd"];\n var v2 = n % 100;\n return "[" + n + (s2[(v2 - 20) % 10] || s2[v2] || s2[0]) + "]";\n }\n };\n var padStart = function padStart2(string, length, pad) {\n var s2 = String(string);\n if (!s2 || s2.length >= length) return string;\n return "" + Array(length + 1 - s2.length).join(pad) + string;\n };\n var padZoneStr = function padZoneStr2(instance) {\n var negMinutes = -instance.utcOffset();\n var minutes = Math.abs(negMinutes);\n var hourOffset = Math.floor(minutes / 60);\n var minuteOffset = minutes % 60;\n return (negMinutes <= 0 ? "+" : "-") + padStart(hourOffset, 2, "0") + ":" + padStart(minuteOffset, 2, "0");\n };\n var monthDiff = function monthDiff2(a2, b) {\n if (a2.date() < b.date()) return -monthDiff2(b, a2);\n var wholeMonthDiff = (b.year() - a2.year()) * 12 + (b.month() - a2.month());\n var anchor = a2.clone().add(wholeMonthDiff, M);\n var c2 = b - anchor < 0;\n var anchor2 = a2.clone().add(wholeMonthDiff + (c2 ? -1 : 1), M);\n return +(-(wholeMonthDiff + (b - anchor) / (c2 ? anchor - anchor2 : anchor2 - anchor)) || 0);\n };\n var absFloor = function absFloor2(n) {\n return n < 0 ? Math.ceil(n) || 0 : Math.floor(n);\n };\n var prettyUnit = function prettyUnit2(u2) {\n var special = {\n M,\n y: Y,\n w: W,\n d: D,\n D: DATE,\n h: H,\n m: MIN,\n s: S,\n ms: MS,\n Q\n };\n return special[u2] || String(u2 || "").toLowerCase().replace(/s$/, "");\n };\n var isUndefined = function isUndefined2(s2) {\n return s2 === void 0;\n };\n var U = {\n s: padStart,\n z: padZoneStr,\n m: monthDiff,\n a: absFloor,\n p: prettyUnit,\n u: isUndefined\n };\n var L = "en";\n var Ls = {};\n Ls[L] = en;\n var IS_DAYJS = "$isDayjsObject";\n var isDayjs = function isDayjs2(d) {\n return d instanceof Dayjs || !!(d && d[IS_DAYJS]);\n };\n var parseLocale = function parseLocale2(preset, object, isLocal) {\n var l2;\n if (!preset) return L;\n if (typeof preset === "string") {\n var presetLower = preset.toLowerCase();\n if (Ls[presetLower]) {\n l2 = presetLower;\n }\n if (object) {\n Ls[presetLower] = object;\n l2 = presetLower;\n }\n var presetSplit = preset.split("-");\n if (!l2 && presetSplit.length > 1) {\n return parseLocale2(presetSplit[0]);\n }\n } else {\n var name = preset.name;\n Ls[name] = preset;\n l2 = name;\n }\n if (!isLocal && l2) L = l2;\n return l2 || !isLocal && L;\n };\n var dayjs = function dayjs2(date, c2) {\n if (isDayjs(date)) {\n return date.clone();\n }\n var cfg = typeof c2 === "object" ? c2 : {};\n cfg.date = date;\n cfg.args = arguments;\n return new Dayjs(cfg);\n };\n var wrapper = function wrapper2(date, instance) {\n return dayjs(date, {\n locale: instance.$L,\n utc: instance.$u,\n x: instance.$x,\n $offset: instance.$offset\n // todo: refactor; do not use this.$offset in you code\n });\n };\n var Utils = U;\n Utils.l = parseLocale;\n Utils.i = isDayjs;\n Utils.w = wrapper;\n var parseDate = function parseDate2(cfg) {\n var date = cfg.date, utc = cfg.utc;\n if (date === null) return /* @__PURE__ */ new Date(NaN);\n if (Utils.u(date)) return /* @__PURE__ */ new Date();\n if (date instanceof Date) return new Date(date);\n if (typeof date === "string" && !/Z$/i.test(date)) {\n var d = date.match(REGEX_PARSE);\n if (d) {\n var m2 = d[2] - 1 || 0;\n var ms = (d[7] || "0").substring(0, 3);\n if (utc) {\n return new Date(Date.UTC(d[1], m2, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms));\n }\n return new Date(d[1], m2, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms);\n }\n }\n return new Date(date);\n };\n var Dayjs = /* @__PURE__ */ function() {\n function Dayjs2(cfg) {\n this.$L = parseLocale(cfg.locale, null, true);\n this.parse(cfg);\n this.$x = this.$x || cfg.x || {};\n this[IS_DAYJS] = true;\n }\n var _proto = Dayjs2.prototype;\n _proto.parse = function parse(cfg) {\n this.$d = parseDate(cfg);\n this.init();\n };\n _proto.init = function init() {\n var $d = this.$d;\n this.$y = $d.getFullYear();\n this.$M = $d.getMonth();\n this.$D = $d.getDate();\n this.$W = $d.getDay();\n this.$H = $d.getHours();\n this.$m = $d.getMinutes();\n this.$s = $d.getSeconds();\n this.$ms = $d.getMilliseconds();\n };\n _proto.$utils = function $utils() {\n return Utils;\n };\n _proto.isValid = function isValid2() {\n return !(this.$d.toString() === INVALID_DATE_STRING);\n };\n _proto.isSame = function isSame(that, units) {\n var other = dayjs(that);\n return this.startOf(units) <= other && other <= this.endOf(units);\n };\n _proto.isAfter = function isAfter(that, units) {\n return dayjs(that) < this.startOf(units);\n };\n _proto.isBefore = function isBefore(that, units) {\n return this.endOf(units) < dayjs(that);\n };\n _proto.$g = function $g(input, get, set) {\n if (Utils.u(input)) return this[get];\n return this.set(set, input);\n };\n _proto.unix = function unix() {\n return Math.floor(this.valueOf() / 1e3);\n };\n _proto.valueOf = function valueOf() {\n return this.$d.getTime();\n };\n _proto.startOf = function startOf(units, _startOf) {\n var _this = this;\n var isStartOf = !Utils.u(_startOf) ? _startOf : true;\n var unit = Utils.p(units);\n var instanceFactory = function instanceFactory2(d, m2) {\n var ins = Utils.w(_this.$u ? Date.UTC(_this.$y, m2, d) : new Date(_this.$y, m2, d), _this);\n return isStartOf ? ins : ins.endOf(D);\n };\n var instanceFactorySet = function instanceFactorySet2(method, slice) {\n var argumentStart = [0, 0, 0, 0];\n var argumentEnd = [23, 59, 59, 999];\n return Utils.w(_this.toDate()[method].apply(\n // eslint-disable-line prefer-spread\n _this.toDate("s"),\n (isStartOf ? argumentStart : argumentEnd).slice(slice)\n ), _this);\n };\n var $W = this.$W, $M = this.$M, $D = this.$D;\n var utcPad = "set" + (this.$u ? "UTC" : "");\n switch (unit) {\n case Y:\n return isStartOf ? instanceFactory(1, 0) : instanceFactory(31, 11);\n case M:\n return isStartOf ? instanceFactory(1, $M) : instanceFactory(0, $M + 1);\n case W: {\n var weekStart = this.$locale().weekStart || 0;\n var gap = ($W < weekStart ? $W + 7 : $W) - weekStart;\n return instanceFactory(isStartOf ? $D - gap : $D + (6 - gap), $M);\n }\n case D:\n case DATE:\n return instanceFactorySet(utcPad + "Hours", 0);\n case H:\n return instanceFactorySet(utcPad + "Minutes", 1);\n case MIN:\n return instanceFactorySet(utcPad + "Seconds", 2);\n case S:\n return instanceFactorySet(utcPad + "Milliseconds", 3);\n default:\n return this.clone();\n }\n };\n _proto.endOf = function endOf(arg) {\n return this.startOf(arg, false);\n };\n _proto.$set = function $set(units, _int) {\n var _C$D$C$DATE$C$M$C$Y$C;\n var unit = Utils.p(units);\n var utcPad = "set" + (this.$u ? "UTC" : "");\n var name = (_C$D$C$DATE$C$M$C$Y$C = {}, _C$D$C$DATE$C$M$C$Y$C[D] = utcPad + "Date", _C$D$C$DATE$C$M$C$Y$C[DATE] = utcPad + "Date", _C$D$C$DATE$C$M$C$Y$C[M] = utcPad + "Month", _C$D$C$DATE$C$M$C$Y$C[Y] = utcPad + "FullYear", _C$D$C$DATE$C$M$C$Y$C[H] = utcPad + "Hours", _C$D$C$DATE$C$M$C$Y$C[MIN] = utcPad + "Minutes", _C$D$C$DATE$C$M$C$Y$C[S] = utcPad + "Seconds", _C$D$C$DATE$C$M$C$Y$C[MS] = utcPad + "Milliseconds", _C$D$C$DATE$C$M$C$Y$C)[unit];\n var arg = unit === D ? this.$D + (_int - this.$W) : _int;\n if (unit === M || unit === Y) {\n var date = this.clone().set(DATE, 1);\n date.$d[name](arg);\n date.init();\n this.$d = date.set(DATE, Math.min(this.$D, date.daysInMonth())).$d;\n } else if (name) this.$d[name](arg);\n this.init();\n return this;\n };\n _proto.set = function set(string, _int2) {\n return this.clone().$set(string, _int2);\n };\n _proto.get = function get(unit) {\n return this[Utils.p(unit)]();\n };\n _proto.add = function add(number, units) {\n var _this2 = this, _C$MIN$C$H$C$S$unit;\n number = Number(number);\n var unit = Utils.p(units);\n var instanceFactorySet = function instanceFactorySet2(n) {\n var d = dayjs(_this2);\n return Utils.w(d.date(d.date() + Math.round(n * number)), _this2);\n };\n if (unit === M) {\n return this.set(M, this.$M + number);\n }\n if (unit === Y) {\n return this.set(Y, this.$y + number);\n }\n if (unit === D) {\n return instanceFactorySet(1);\n }\n if (unit === W) {\n return instanceFactorySet(7);\n }\n var step = (_C$MIN$C$H$C$S$unit = {}, _C$MIN$C$H$C$S$unit[MIN] = MILLISECONDS_A_MINUTE, _C$MIN$C$H$C$S$unit[H] = MILLISECONDS_A_HOUR, _C$MIN$C$H$C$S$unit[S] = MILLISECONDS_A_SECOND, _C$MIN$C$H$C$S$unit)[unit] || 1;\n var nextTimeStamp = this.$d.getTime() + number * step;\n return Utils.w(nextTimeStamp, this);\n };\n _proto.subtract = function subtract(number, string) {\n return this.add(number * -1, string);\n };\n _proto.format = function format(formatStr) {\n var _this3 = this;\n var locale = this.$locale();\n if (!this.isValid()) return locale.invalidDate || INVALID_DATE_STRING;\n var str = formatStr || FORMAT_DEFAULT;\n var zoneStr = Utils.z(this);\n var $H = this.$H, $m = this.$m, $M = this.$M;\n var weekdays = locale.weekdays, months = locale.months, meridiem = locale.meridiem;\n var getShort = function getShort2(arr, index, full, length) {\n return arr && (arr[index] || arr(_this3, str)) || full[index].slice(0, length);\n };\n var get$H = function get$H2(num) {\n return Utils.s($H % 12 || 12, num, "0");\n };\n var meridiemFunc = meridiem || function(hour, minute, isLowercase) {\n var m2 = hour < 12 ? "AM" : "PM";\n return isLowercase ? m2.toLowerCase() : m2;\n };\n var matches = function matches2(match) {\n switch (match) {\n case "YY":\n return String(_this3.$y).slice(-2);\n case "YYYY":\n return Utils.s(_this3.$y, 4, "0");\n case "M":\n return $M + 1;\n case "MM":\n return Utils.s($M + 1, 2, "0");\n case "MMM":\n return getShort(locale.monthsShort, $M, months, 3);\n case "MMMM":\n return getShort(months, $M);\n case "D":\n return _this3.$D;\n case "DD":\n return Utils.s(_this3.$D, 2, "0");\n case "d":\n return String(_this3.$W);\n case "dd":\n return getShort(locale.weekdaysMin, _this3.$W, weekdays, 2);\n case "ddd":\n return getShort(locale.weekdaysShort, _this3.$W, weekdays, 3);\n case "dddd":\n return weekdays[_this3.$W];\n case "H":\n return String($H);\n case "HH":\n return Utils.s($H, 2, "0");\n case "h":\n return get$H(1);\n case "hh":\n return get$H(2);\n case "a":\n return meridiemFunc($H, $m, true);\n case "A":\n return meridiemFunc($H, $m, false);\n case "m":\n return String($m);\n case "mm":\n return Utils.s($m, 2, "0");\n case "s":\n return String(_this3.$s);\n case "ss":\n return Utils.s(_this3.$s, 2, "0");\n case "SSS":\n return Utils.s(_this3.$ms, 3, "0");\n case "Z":\n return zoneStr;\n }\n return null;\n };\n return str.replace(REGEX_FORMAT, function(match, $1) {\n return $1 || matches(match) || zoneStr.replace(":", "");\n });\n };\n _proto.utcOffset = function utcOffset() {\n return -Math.round(this.$d.getTimezoneOffset() / 15) * 15;\n };\n _proto.diff = function diff(input, units, _float) {\n var _this4 = this;\n var unit = Utils.p(units);\n var that = dayjs(input);\n var zoneDelta = (that.utcOffset() - this.utcOffset()) * MILLISECONDS_A_MINUTE;\n var diff2 = this - that;\n var getMonth = function getMonth2() {\n return Utils.m(_this4, that);\n };\n var result;\n switch (unit) {\n case Y:\n result = getMonth() / 12;\n break;\n case M:\n result = getMonth();\n break;\n case Q:\n result = getMonth() / 3;\n break;\n case W:\n result = (diff2 - zoneDelta) / MILLISECONDS_A_WEEK;\n break;\n case D:\n result = (diff2 - zoneDelta) / MILLISECONDS_A_DAY;\n break;\n case H:\n result = diff2 / MILLISECONDS_A_HOUR;\n break;\n case MIN:\n result = diff2 / MILLISECONDS_A_MINUTE;\n break;\n case S:\n result = diff2 / MILLISECONDS_A_SECOND;\n break;\n default:\n result = diff2;\n break;\n }\n return _float ? result : Utils.a(result);\n };\n _proto.daysInMonth = function daysInMonth() {\n return this.endOf(M).$D;\n };\n _proto.$locale = function $locale() {\n return Ls[this.$L];\n };\n _proto.locale = function locale(preset, object) {\n if (!preset) return this.$L;\n var that = this.clone();\n var nextLocaleName = parseLocale(preset, object, true);\n if (nextLocaleName) that.$L = nextLocaleName;\n return that;\n };\n _proto.clone = function clone() {\n return Utils.w(this.$d, this);\n };\n _proto.toDate = function toDate() {\n return new Date(this.valueOf());\n };\n _proto.toJSON = function toJSON() {\n return this.isValid() ? this.toISOString() : null;\n };\n _proto.toISOString = function toISOString() {\n return this.$d.toISOString();\n };\n _proto.toString = function toString() {\n return this.$d.toUTCString();\n };\n return Dayjs2;\n }();\n var proto = Dayjs.prototype;\n dayjs.prototype = proto;\n [["$ms", MS], ["$s", S], ["$m", MIN], ["$H", H], ["$W", D], ["$M", M], ["$y", Y], ["$D", DATE]].forEach(function(g) {\n proto[g[1]] = function(input) {\n return this.$g(input, g[0], g[1]);\n };\n });\n dayjs.extend = function(plugin, option) {\n if (!plugin.$i) {\n plugin(option, Dayjs, dayjs);\n plugin.$i = true;\n }\n return dayjs;\n };\n dayjs.locale = parseLocale;\n dayjs.isDayjs = isDayjs;\n dayjs.unix = function(timestamp) {\n return dayjs(timestamp * 1e3);\n };\n dayjs.en = Ls[L];\n dayjs.Ls = Ls;\n dayjs.p = {};\n var advancedFormat = function(o, c2) {\n var proto2 = c2.prototype;\n var oldFormat = proto2.format;\n proto2.format = function(formatStr) {\n var _this = this;\n var locale = this.$locale();\n if (!this.isValid()) {\n return oldFormat.bind(this)(formatStr);\n }\n var utils = this.$utils();\n var str = formatStr || FORMAT_DEFAULT;\n var result = str.replace(/\\[([^\\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g, function(match) {\n switch (match) {\n case "Q":\n return Math.ceil((_this.$M + 1) / 3);\n case "Do":\n return locale.ordinal(_this.$D);\n case "gggg":\n return _this.weekYear();\n case "GGGG":\n return _this.isoWeekYear();\n case "wo":\n return locale.ordinal(_this.week(), "W");\n // W for week\n case "w":\n case "ww":\n return utils.s(_this.week(), match === "w" ? 1 : 2, "0");\n case "W":\n case "WW":\n return utils.s(_this.isoWeek(), match === "W" ? 1 : 2, "0");\n case "k":\n case "kk":\n return utils.s(String(_this.$H === 0 ? 24 : _this.$H), match === "k" ? 1 : 2, "0");\n case "X":\n return Math.floor(_this.$d.getTime() / 1e3);\n case "x":\n return _this.$d.getTime();\n case "z":\n return "[" + _this.offsetName() + "]";\n case "zzz":\n return "[" + _this.offsetName("long") + "]";\n default:\n return match;\n }\n });\n return oldFormat.bind(this)(result);\n };\n };\n var isoWeekPrettyUnit = "isoweek";\n var isoWeek = function(o, c2, d) {\n var getYearFirstThursday = function getYearFirstThursday2(year, isUtc) {\n var yearFirstDay = (isUtc ? d.utc : d)().year(year).startOf(Y);\n var addDiffDays = 4 - yearFirstDay.isoWeekday();\n if (yearFirstDay.isoWeekday() > 4) {\n addDiffDays += 7;\n }\n return yearFirstDay.add(addDiffDays, D);\n };\n var getCurrentWeekThursday = function getCurrentWeekThursday2(ins) {\n return ins.add(4 - ins.isoWeekday(), D);\n };\n var proto2 = c2.prototype;\n proto2.isoWeekYear = function() {\n var nowWeekThursday = getCurrentWeekThursday(this);\n return nowWeekThursday.year();\n };\n proto2.isoWeek = function(week) {\n if (!this.$utils().u(week)) {\n return this.add((week - this.isoWeek()) * 7, D);\n }\n var nowWeekThursday = getCurrentWeekThursday(this);\n var diffWeekThursday = getYearFirstThursday(this.isoWeekYear(), this.$u);\n return nowWeekThursday.diff(diffWeekThursday, W) + 1;\n };\n proto2.isoWeekday = function(week) {\n if (!this.$utils().u(week)) {\n return this.day(this.day() % 7 ? week : week - 7);\n }\n return this.day() || 7;\n };\n var oldStartOf = proto2.startOf;\n proto2.startOf = function(units, startOf) {\n var utils = this.$utils();\n var isStartOf = !utils.u(startOf) ? startOf : true;\n var unit = utils.p(units);\n if (unit === isoWeekPrettyUnit) {\n return isStartOf ? this.date(this.date() - (this.isoWeekday() - 1)).startOf("day") : this.date(this.date() - 1 - (this.isoWeekday() - 1) + 7).endOf("day");\n }\n return oldStartOf.bind(this)(units, startOf);\n };\n };\n dayjs.extend(isoWeek);\n dayjs.extend(advancedFormat);\n const FORMAT_ISO_WEEK_YEAR_WEEK = "GGGG-[W]WW";\n const _TemporalCache = class _TemporalCache {\n constructor() {\n this.yearMonthDayCache = /* @__PURE__ */ new Map();\n this.yearWeekCache = /* @__PURE__ */ new Map();\n this.yearMonthCache = /* @__PURE__ */ new Map();\n this.yearCache = /* @__PURE__ */ new Map();\n }\n getYearMonthDay(s2) {\n if (!this.yearMonthDayCache.has(s2)) {\n this.yearMonthDayCache.set(s2, YearMonthDayClass.parse(s2, this));\n }\n return this.yearMonthDayCache.get(s2);\n }\n getYearMonth(s2) {\n if (!this.yearMonthCache.has(s2)) {\n this.yearMonthCache.set(s2, YearMonthClass.parse(s2, this));\n }\n return this.yearMonthCache.get(s2);\n }\n getYearWeek(s2) {\n if (!this.yearWeekCache.has(s2)) {\n this.yearWeekCache.set(s2, YearWeekClass.parse(s2, this));\n }\n return this.yearWeekCache.get(s2);\n }\n getYear(s2) {\n if (!this.yearCache.has(s2)) {\n this.yearCache.set(s2, YearClass.parse(s2, this));\n }\n return this.yearCache.get(s2);\n }\n static getInstance() {\n return this.instance;\n }\n };\n _TemporalCache.instance = new _TemporalCache();\n let TemporalCache = _TemporalCache;\n class YearMonthDayClass {\n constructor(yearNumber, monthNumber, dayNumber, cache) {\n this.yearNumber = yearNumber;\n this.monthNumber = monthNumber;\n this.dayNumber = dayNumber;\n this.cache = cache;\n this.type = "YearMonthDay";\n this.date = new Date(this.yearNumber, this.monthNumber - 1, this.dayNumber);\n this.dayjs = dayjs(this.date);\n this.dateString = this.toString();\n }\n get text() {\n return this.dayjs.format("YYYY-MM-DD");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return this.dayjs.format("dddd, MMMM D, YYYY");\n }\n get firstDay() {\n return this;\n }\n get lastDay() {\n return this;\n }\n get year() {\n return this.cache.getYear(`${this.yearNumber}`);\n }\n get month() {\n return this.cache.getYearMonth(this.dayjs.format("YYYY-MM"));\n }\n get week() {\n return this.cache.getYearWeek(this.dayjs.format(FORMAT_ISO_WEEK_YEAR_WEEK));\n }\n addDays(days) {\n const date = this.dayjs.add(days, "day");\n const s2 = date.format("YYYY-MM-DD");\n return this.cache.getYearMonthDay(s2);\n }\n minus(other) {\n return this.dayjs.diff(other.dayjs, "day");\n }\n static parse(s2, cache) {\n const [year, month, day] = s2.split("-").map((s22) => parseInt(s22, 10));\n return new YearMonthDayClass(year, month, day, cache);\n }\n }\n class YearWeekClass {\n constructor(isoYearNumber, isoWeekNumber, cache) {\n this.isoYearNumber = isoYearNumber;\n this.isoWeekNumber = isoWeekNumber;\n this.cache = cache;\n this.type = "YearWeek";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format(FORMAT_ISO_WEEK_YEAR_WEEK);\n }\n toString() {\n return this.text;\n }\n englishName() {\n return `Week ${this.isoWeekNumber}, ${this.isoYearNumber}`;\n }\n get firstDay() {\n const firstDay = dayjs().year(this.isoYearNumber).month(1).date(4).isoWeek(this.isoWeekNumber).startOf("isoWeek");\n return this.cache.getYearMonthDay(firstDay.format("YYYY-MM-DD"));\n }\n get lastDay() {\n const lastDay = this.firstDay.dayjs.add(6, "days");\n return this.cache.getYearMonthDay(lastDay.format("YYYY-MM-DD"));\n }\n get year() {\n return this.cache.getYear(`${this.isoYearNumber}`);\n }\n addWeeks(weeks) {\n const date = this.firstDay.dayjs.add(weeks, "week");\n const s2 = date.format(FORMAT_ISO_WEEK_YEAR_WEEK);\n return this.cache.getYearWeek(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "week");\n }\n static parse(s2, cache) {\n const [year, week] = s2.split("-W").map((s22) => parseInt(s22, 10));\n return new YearWeekClass(year, week, cache);\n }\n }\n class YearMonthClass {\n constructor(yearNumber, monthNumber, cache) {\n this.yearNumber = yearNumber;\n this.monthNumber = monthNumber;\n this.cache = cache;\n this.type = "YearMonth";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format("YYYY-MM");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return `${monthName(this.monthNumber)} ${this.yearNumber}`;\n }\n get firstDay() {\n return this.cache.getYearMonthDay(dayjs(`${this.yearNumber}-${this.monthNumber}-01`).format("YYYY-MM-DD"));\n }\n get lastDay() {\n return this.cache.getYearMonthDay(\n dayjs(`${this.yearNumber}-${this.monthNumber}-01`).endOf("month").format("YYYY-MM-DD")\n );\n }\n get year() {\n return this.cache.getYear(`${this.yearNumber}`);\n }\n addMonths(months) {\n const date = this.firstDay.dayjs.add(months, "month");\n const s2 = date.format("YYYY-MM");\n return this.cache.getYearMonth(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "month");\n }\n static parse(s2, cache) {\n const [year, month] = s2.split("-").map((s22) => parseInt(s22, 10));\n return new YearMonthClass(year, month, cache);\n }\n }\n class YearClass {\n constructor(year, cache) {\n this.year = year;\n this.cache = cache;\n this.type = "Year";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format("YYYY");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return this.year.toString();\n }\n get firstMonth() {\n return this.cache.getYearMonth(`${this.year}-01`);\n }\n get lastMonth() {\n return this.cache.getYearMonth(`${this.year}-12`);\n }\n get firstDay() {\n return this.firstMonth.firstDay;\n }\n get lastDay() {\n return this.lastMonth.lastDay;\n }\n addYears(years) {\n const date = this.firstDay.dayjs.add(years, "year");\n const s2 = date.format("YYYY");\n return this.cache.getYear(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "year");\n }\n static parse(s2, cache) {\n const year = parseInt(s2, 10);\n return new YearClass(year, cache);\n }\n }\n function monthName(month) {\n return dayjs().month(month - 1).format("MMMM");\n }\n function toTemporal(temporalClass) {\n switch (temporalClass.type) {\n case "YearMonthDay":\n return {\n type: "YearMonthDay",\n yearNumber: temporalClass.yearNumber,\n monthNumber: temporalClass.monthNumber,\n dayNumber: temporalClass.dayNumber,\n dateString: temporalClass.dateString\n };\n case "YearWeek":\n return {\n type: "YearWeek",\n isoYearNumber: temporalClass.isoYearNumber,\n isoWeekNumber: temporalClass.isoWeekNumber,\n dateString: temporalClass.dateString\n };\n case "YearMonth":\n return {\n type: "YearMonth",\n yearNumber: temporalClass.yearNumber,\n monthNumber: temporalClass.monthNumber,\n dateString: temporalClass.dateString\n };\n case "Year":\n return {\n type: "Year",\n year: temporalClass.year,\n dateString: temporalClass.dateString\n };\n }\n }\n function generateAllDaysInRange(start, end) {\n const days = [];\n const daysInBetween = end.minus(start);\n for (let i2 = 0; i2 <= daysInBetween; i2++) {\n days.push(start.addDays(i2));\n }\n return days;\n }\n function generateAllWeeksInRange(start, end) {\n const weeks = [];\n const weeksInBetween = end.minus(start);\n for (let i2 = 0; i2 <= weeksInBetween; i2++) {\n weeks.push(start.addWeeks(i2));\n }\n return weeks;\n }\n function generateAllMonthsInRange(start, end) {\n const months = [];\n const monthsInBetween = end.minus(start);\n for (let i2 = 0; i2 <= monthsInBetween; i2++) {\n months.push(start.addMonths(i2));\n }\n return months;\n }\n function generateAllYearsInRange(start, end) {\n const years = [];\n const yearsInBetween = end.minus(start);\n for (let i2 = 0; i2 <= yearsInBetween; i2++) {\n years.push(start.addYears(i2));\n }\n return years;\n }\n function generateAllInRange(start, end) {\n if (start === null || end === null) {\n return [];\n }\n if (start instanceof YearMonthDayClass && end instanceof YearMonthDayClass) {\n return generateAllDaysInRange(start, end);\n }\n if (start instanceof YearWeekClass && end instanceof YearWeekClass) {\n return generateAllWeeksInRange(start, end);\n }\n if (start instanceof YearMonthClass && end instanceof YearMonthClass) {\n return generateAllMonthsInRange(start, end);\n }\n if (start instanceof YearClass && end instanceof YearClass) {\n return generateAllYearsInRange(start, end);\n }\n throw new Error(`Invalid arguments: start and end must be of the same type: ${start}, ${end}`);\n }\n function minusTemporal(a2, b) {\n if (a2 instanceof YearMonthDayClass && b instanceof YearMonthDayClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearWeekClass && b instanceof YearWeekClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearMonthClass && b instanceof YearMonthClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearClass && b instanceof YearClass) {\n return a2.minus(b);\n }\n throw new Error(`Cannot compare ${a2} and ${b}`);\n }\n function compareTemporal(a2, b) {\n if (a2 === null) {\n return 1;\n }\n if (b === null) {\n return -1;\n }\n const diff = minusTemporal(a2, b);\n if (diff < 0) {\n return -1;\n }\n if (diff > 0) {\n return 1;\n }\n return 0;\n }\n function getMinMaxTemporal(values) {\n let min = null;\n let max = null;\n for (const value of values) {\n if (value === null) {\n continue;\n }\n if (min === null || compareTemporal(value, min) < 0) {\n min = value;\n }\n if (max === null || compareTemporal(value, max) > 0) {\n max = value;\n }\n }\n if (min === null || max === null) {\n return { min: null, max: null };\n }\n return { min, max };\n }\n function parseDateStringToTemporal(date, granularity) {\n const cache = TemporalCache.getInstance();\n const day = cache.getYearMonthDay(date);\n switch (granularity) {\n case "day":\n return day;\n case "week":\n return day.week;\n case "month":\n return day.month;\n case "year":\n return day.year;\n }\n }\n function dateRangeCompare(a2, b) {\n if (a2.dateRange === null) {\n return 1;\n }\n if (b.dateRange === null) {\n return -1;\n }\n return compareTemporal(a2.dateRange, b.dateRange);\n }\n function mapDateToGranularityRange(data, granularity) {\n return {\n dateRange: data.date === null ? null : parseDateStringToTemporal(data.date, granularity),\n count: data.count\n };\n }\n const substitutionRegex = /^((?<segment>[A-Z0-9_-]+)(?=:):)?(?<valueAtReference>[A-Z])?(?<position>\\d+)(?<substitutionValue>[A-Z.*])?$/i;\n class SubstitutionClass {\n constructor(segment, valueAtReference, substitutionValue, position) {\n this.segment = segment;\n this.valueAtReference = valueAtReference;\n this.substitutionValue = substitutionValue;\n this.position = position;\n this.type = "substitution";\n const segmentString = this.segment ? `${this.segment}:` : "";\n const valueAtReferenceString = this.valueAtReference ? `${this.valueAtReference}` : "";\n const substitutionValueString = this.substitutionValue ? `${this.substitutionValue}` : "";\n this.code = `${segmentString}${valueAtReferenceString}${this.position}${substitutionValueString}`;\n }\n equals(other) {\n if (!(other instanceof SubstitutionClass)) {\n return false;\n }\n return this.segment === other.segment && this.valueAtReference === other.valueAtReference && this.substitutionValue === other.substitutionValue && this.position === other.position;\n }\n toString() {\n return this.code;\n }\n static parse(mutationStr) {\n const match = mutationStr.match(substitutionRegex);\n if (match === null || match.groups === void 0) {\n return null;\n }\n return new SubstitutionClass(\n match.groups.segment,\n match.groups.valueAtReference,\n match.groups.substitutionValue,\n parseInt(match.groups.position, 10)\n );\n }\n }\n const deletionRegex = /^((?<segment>[A-Z0-9_-]+)(?=:):)?(?<valueAtReference>[A-Z])?(?<position>\\d+)(-)$/i;\n class DeletionClass {\n constructor(segment, valueAtReference, position) {\n this.segment = segment;\n this.valueAtReference = valueAtReference;\n this.position = position;\n this.type = "deletion";\n const segmentString = this.segment ? `${this.segment}:` : "";\n const valueAtReferenceString = this.valueAtReference ? `${this.valueAtReference}` : "";\n this.code = `${segmentString}${valueAtReferenceString}${this.position}-`;\n }\n equals(other) {\n if (!(other instanceof DeletionClass)) {\n return false;\n }\n return this.segment === other.segment && this.valueAtReference === other.valueAtReference && this.position === other.position;\n }\n toString() {\n return this.code;\n }\n static parse(mutationStr) {\n const match = mutationStr.match(deletionRegex);\n if (match === null || match.groups === void 0) {\n return null;\n }\n return new DeletionClass(\n match.groups.segment,\n match.groups.valueAtReference,\n parseInt(match.groups.position, 10)\n );\n }\n }\n function toSubstitutionOrDeletion(mutation) {\n switch (mutation.type) {\n case "substitution":\n return {\n type: "substitution",\n code: mutation.code,\n segment: mutation.segment,\n position: mutation.position,\n valueAtReference: mutation.valueAtReference,\n substitutionValue: mutation.substitutionValue\n };\n case "deletion":\n return {\n type: "deletion",\n code: mutation.code,\n segment: mutation.segment,\n position: mutation.position,\n valueAtReference: mutation.valueAtReference\n };\n }\n }\n class FetchSubstitutionsOrDeletionsOperator {\n constructor(filter, sequenceType, minProportion) {\n this.filter = filter;\n this.sequenceType = sequenceType;\n this.minProportion = minProportion;\n }\n async evaluate(lapis, signal) {\n const mutations = await this.fetchMutations(lapis, signal);\n const content = mutations.map(\n ({ count, proportion, mutationFrom, mutationTo, position, sequenceName }) => {\n if (mutationTo === "-") {\n return {\n type: "deletion",\n mutation: new DeletionClass(sequenceName ?? void 0, mutationFrom, position),\n count,\n proportion\n };\n }\n return {\n type: "substitution",\n mutation: new SubstitutionClass(sequenceName ?? void 0, mutationFrom, mutationTo, position),\n count,\n proportion\n };\n }\n );\n return { content };\n }\n async fetchMutations(lapis, signal) {\n const filter = {\n ...this.filter,\n minProportion: this.minProportion\n };\n return fetchSubstitutionsOrDeletions(lapis, filter, this.sequenceType, signal).then(\n (response) => response.data\n );\n }\n }\n var l$1;\n l$1 = { __e: function(n, l2, t, u2) {\n for (var i2, r2, o; l2 = l2.__; ) if ((i2 = l2.__c) && !i2.__) try {\n if ((r2 = i2.constructor) && null != r2.getDerivedStateFromError && (i2.setState(r2.getDerivedStateFromError(n)), o = i2.__d), null != i2.componentDidCatch && (i2.componentDidCatch(n, u2 || {}), o = i2.__d), o) return i2.__E = i2;\n } catch (l3) {\n n = l3;\n }\n throw n;\n } }, "function" == typeof Promise ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout;\n var r, u, i, f = [], c = l$1, e = c.__b, a = c.__r, v = c.diffed, l = c.__c, m = c.unmount, s = c.__;\n function j() {\n for (var n; n = f.shift(); ) if (n.__P && n.__H) try {\n n.__H.__h.forEach(z), n.__H.__h.forEach(B), n.__H.__h = [];\n } catch (t) {\n n.__H.__h = [], c.__e(t, n.__v);\n }\n }\n c.__b = function(n) {\n r = null, e && e(n);\n }, c.__ = function(n, t) {\n n && t.__k && t.__k.__m && (n.__m = t.__k.__m), s && s(n, t);\n }, c.__r = function(n) {\n a && a(n);\n var i2 = (r = n.__c).__H;\n i2 && (u === r ? (i2.__h = [], r.__h = [], i2.__.forEach(function(n2) {\n n2.__N && (n2.__ = n2.__N), n2.u = n2.__N = void 0;\n })) : (i2.__h.forEach(z), i2.__h.forEach(B), i2.__h = [], 0)), u = r;\n }, c.diffed = function(n) {\n v && v(n);\n var t = n.__c;\n t && t.__H && (t.__H.__h.length && (1 !== f.push(t) && i === c.requestAnimationFrame || ((i = c.requestAnimationFrame) || w)(j)), t.__H.__.forEach(function(n2) {\n n2.u && (n2.__H = n2.u), n2.u = void 0;\n })), u = r = null;\n }, c.__c = function(n, t) {\n t.some(function(n2) {\n try {\n n2.__h.forEach(z), n2.__h = n2.__h.filter(function(n3) {\n return !n3.__ || B(n3);\n });\n } catch (r2) {\n t.some(function(n3) {\n n3.__h && (n3.__h = []);\n }), t = [], c.__e(r2, n2.__v);\n }\n }), l && l(n, t);\n }, c.unmount = function(n) {\n m && m(n);\n var t, r2 = n.__c;\n r2 && r2.__H && (r2.__H.__.forEach(function(n2) {\n try {\n z(n2);\n } catch (n3) {\n t = n3;\n }\n }), r2.__H = void 0, t && c.__e(t, r2.__v));\n };\n var k = "function" == typeof requestAnimationFrame;\n function w(n) {\n var t, r2 = function() {\n clearTimeout(u2), k && cancelAnimationFrame(t), setTimeout(n);\n }, u2 = setTimeout(r2, 100);\n k && (t = requestAnimationFrame(r2));\n }\n function z(n) {\n var t = r, u2 = n.__c;\n "function" == typeof u2 && (n.__c = void 0, u2()), r = t;\n }\n function B(n) {\n var t = r;\n n.__c = n.__(), r = t;\n }\n class UserFacingError extends Error {\n constructor(headline, message) {\n super(message);\n this.headline = headline;\n this.name = "UserFacingError";\n }\n }\n class Map2dBase {\n constructor(serializeFirstAxis, serializeSecondAxis, initialContent) {\n this.serializeFirstAxis = serializeFirstAxis;\n this.serializeSecondAxis = serializeSecondAxis;\n this.data = /* @__PURE__ */ new Map();\n this.keysFirstAxis = /* @__PURE__ */ new Map();\n this.keysSecondAxis = /* @__PURE__ */ new Map();\n if (initialContent) {\n this.keysFirstAxis = new Map(initialContent.keysFirstAxis);\n this.keysSecondAxis = new Map(initialContent.keysSecondAxis);\n this.data = new Map(initialContent.data);\n }\n }\n get(keyFirstAxis, keySecondAxis) {\n var _a;\n const serializedKeyFirstAxis = this.serializeFirstAxis(keyFirstAxis);\n const serializedKeySecondAxis = this.serializeSecondAxis(keySecondAxis);\n return (_a = this.data.get(serializedKeyFirstAxis)) == null ? void 0 : _a.get(serializedKeySecondAxis);\n }\n getRow(key) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(key);\n const row = this.data.get(serializedKeyFirstAxis);\n if (row === void 0) {\n return [];\n }\n return Array.from(this.keysSecondAxis.keys()).map((key2) => row.get(key2));\n }\n set(keyFirstAxis, keySecondAxis, value) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(keyFirstAxis);\n const serializedKeySecondAxis = this.serializeSecondAxis(keySecondAxis);\n if (!this.data.has(serializedKeyFirstAxis)) {\n this.data.set(serializedKeyFirstAxis, /* @__PURE__ */ new Map());\n }\n this.data.get(serializedKeyFirstAxis).set(serializedKeySecondAxis, value);\n this.keysFirstAxis.set(serializedKeyFirstAxis, keyFirstAxis);\n this.keysSecondAxis.set(serializedKeySecondAxis, keySecondAxis);\n }\n deleteRow(key) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(key);\n this.data.delete(serializedKeyFirstAxis);\n this.keysFirstAxis.delete(serializedKeyFirstAxis);\n }\n getFirstAxisKeys() {\n return Array.from(this.keysFirstAxis.values());\n }\n getSecondAxisKeys() {\n return Array.from(this.keysSecondAxis.values());\n }\n getAsArray() {\n return this.getFirstAxisKeys().map((firstAxisKey) => {\n return this.getSecondAxisKeys().map((secondAxisKey) => {\n return this.get(firstAxisKey, secondAxisKey);\n });\n });\n }\n getContents() {\n return {\n keysFirstAxis: this.keysFirstAxis,\n keysSecondAxis: this.keysSecondAxis,\n data: this.data\n };\n }\n }\n class BaseMutationOverTimeDataMap extends Map2dBase {\n constructor(initialContent) {\n super(serializeSubstitutionOrDeletion, serializeTemporal, initialContent);\n }\n }\n const sortSubstitutionsAndDeletions = (a2, b) => {\n if (a2.segment !== b.segment) {\n return compareSegments(a2.segment, b.segment);\n }\n if (a2.position !== b.position) {\n return comparePositions(a2.position, b.position);\n }\n const aIsDeletion = a2.type === "deletion";\n const bIsDeletion = b.type === "deletion";\n if (aIsDeletion !== bIsDeletion) {\n return aIsDeletion ? 1 : -1;\n }\n if (!aIsDeletion && !bIsDeletion) {\n if (a2.substitutionValue !== b.substitutionValue) {\n return compareSubstitutionValues(a2.substitutionValue, b.substitutionValue);\n }\n }\n return 0;\n };\n const compareSegments = (a2, b) => {\n if (a2 === void 0) {\n return -1;\n }\n if (b === void 0) {\n return 1;\n }\n return a2.localeCompare(b);\n };\n const comparePositions = (a2, b) => {\n return a2 - b;\n };\n const compareSubstitutionValues = (a2, b) => {\n if (a2 === void 0) {\n return -1;\n }\n if (b === void 0) {\n return 1;\n }\n return a2.localeCompare(b);\n };\n const MAX_NUMBER_OF_GRID_COLUMNS = 200;\n const MUTATIONS_OVER_TIME_MIN_PROPORTION = 1e-3;\n async function queryOverallMutationData({\n lapisFilter,\n sequenceType,\n lapis,\n granularity,\n lapisDateField,\n signal\n }) {\n const allDates = await getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal);\n if (allDates.length === 0) {\n return {\n content: []\n };\n }\n const filter = {\n ...lapisFilter,\n [`${lapisDateField}From`]: allDates[0].firstDay.toString(),\n [`${lapisDateField}To`]: allDates[allDates.length - 1].lastDay.toString()\n };\n return fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType).evaluate(lapis, signal);\n }\n async function queryMutationsOverTimeData({\n lapisFilter,\n sequenceType,\n lapis,\n lapisDateField,\n granularity,\n signal\n }) {\n const allDates = await getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal);\n if (allDates.length > MAX_NUMBER_OF_GRID_COLUMNS) {\n throw new UserFacingError(\n "Too many dates",\n `The dataset would contain ${allDates.length} date intervals. Please reduce the number to below ${MAX_NUMBER_OF_GRID_COLUMNS} to display the data. You can achieve this by either narrowing the date range in the provided LAPIS filter or by selecting a larger granularity.`\n );\n }\n const subQueries = allDates.map(async (date) => {\n const dateFrom = date.firstDay.toString();\n const dateTo = date.lastDay.toString();\n const filter = {\n ...lapisFilter,\n [`${lapisDateField}From`]: dateFrom,\n [`${lapisDateField}To`]: dateTo\n };\n const data2 = await fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType).evaluate(lapis, signal);\n const totalCountQuery = await getTotalNumberOfSequencesInDateRange(filter).evaluate(lapis, signal);\n return {\n date,\n mutations: data2.content,\n totalCount: totalCountQuery.content[0].count\n };\n });\n const data = await Promise.all(subQueries);\n const overallMutationsData = (await queryOverallMutationData({\n lapisFilter,\n sequenceType,\n lapis,\n lapisDateField,\n granularity\n })).content;\n return {\n mutationOverTimeData: groupByMutation(data, overallMutationsData),\n overallMutationData: overallMutationsData\n };\n }\n async function getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal) {\n const { content: availableDates } = await queryAvailableDates(\n lapisFilter,\n lapis,\n granularity,\n lapisDateField,\n signal\n );\n const { dateFrom, dateTo } = getDateRangeFromFilter(lapisFilter, lapisDateField, granularity);\n const { min, max } = getMinMaxTemporal(availableDates);\n return generateAllInRange(dateFrom ?? min, dateTo ?? max);\n }\n function getDateRangeFromFilter(lapisFilter, lapisDateField, granularity) {\n const valueFromFilter = lapisFilter[lapisDateField];\n if (valueFromFilter) {\n return {\n dateFrom: parseDateStringToTemporal(valueFromFilter, granularity),\n dateTo: parseDateStringToTemporal(valueFromFilter, granularity)\n };\n }\n const minFromFilter = lapisFilter[`${lapisDateField}From`];\n const maxFromFilter = lapisFilter[`${lapisDateField}To`];\n return {\n dateFrom: minFromFilter ? parseDateStringToTemporal(minFromFilter, granularity) : null,\n dateTo: maxFromFilter ? parseDateStringToTemporal(maxFromFilter, granularity) : null\n };\n }\n function queryAvailableDates(lapisFilter, lapis, granularity, lapisDateField, signal) {\n return fetchAndPrepareDates(lapisFilter, granularity, lapisDateField).evaluate(lapis, signal);\n }\n function fetchAndPrepareDates(filter, granularity, lapisDateField) {\n const fetchData = new FetchAggregatedOperator(filter, [lapisDateField]);\n const dataWithFixedDateKey = new RenameFieldOperator(fetchData, lapisDateField, "date");\n const mapData = new MapOperator(dataWithFixedDateKey, (data) => mapDateToGranularityRange(data, granularity));\n const groupByData = new GroupByAndSumOperator(mapData, "dateRange", "count");\n const sortData = new SortOperator(groupByData, dateRangeCompare);\n return new MapOperator(sortData, (data) => data.dateRange);\n }\n function fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType) {\n return new FetchSubstitutionsOrDeletionsOperator(filter, sequenceType, MUTATIONS_OVER_TIME_MIN_PROPORTION);\n }\n function serializeSubstitutionOrDeletion(mutation) {\n return mutation.code;\n }\n function serializeTemporal(date) {\n return date.dateString;\n }\n function groupByMutation(data, overallMutationData) {\n const dataArray = new BaseMutationOverTimeDataMap();\n const allDates = data.map((mutationData) => mutationData.date);\n const sortedOverallMutationData = overallMutationData.sort((a2, b) => sortSubstitutionsAndDeletions(a2.mutation, b.mutation)).map((entry) => {\n return toSubstitutionOrDeletion(entry.mutation);\n });\n const sortedDates = allDates.sort((a2, b) => compareTemporal(a2, b)).map((date) => toTemporal(date));\n sortedOverallMutationData.forEach((mutationData) => {\n sortedDates.forEach((date) => {\n dataArray.set(mutationData, date, null);\n });\n });\n data.forEach((mutationData) => {\n if (mutationData.totalCount == 0) {\n return;\n }\n const date = toTemporal(mutationData.date);\n mutationData.mutations.forEach((mutationEntry) => {\n const mutation = toSubstitutionOrDeletion(mutationEntry.mutation);\n if (dataArray.get(mutation, date) !== void 0) {\n dataArray.set(mutation, date, {\n type: "value",\n count: mutationEntry.count,\n proportion: mutationEntry.proportion,\n totalCount: mutationData.totalCount\n });\n }\n });\n for (const firstAxisKey of dataArray.getFirstAxisKeys()) {\n if (dataArray.get(firstAxisKey, date) === null) {\n dataArray.set(firstAxisKey, date, {\n type: "belowThreshold",\n totalCount: mutationData.totalCount\n });\n }\n }\n });\n return dataArray;\n }\n function getTotalNumberOfSequencesInDateRange(filter) {\n return new FetchAggregatedOperator(filter);\n }\n async function workerFunction(queryFunction) {\n try {\n postMessage({ status: "loading" });\n const workerResponse = await queryFunction();\n postMessage({\n status: "success",\n data: workerResponse\n });\n } catch (error) {\n postMessage(\n error instanceof UserFacingError ? {\n status: "error",\n userFacing: true,\n headline: error.headline,\n error\n } : {\n status: "error",\n userFacing: false,\n error: error instanceof Error ? error : new Error(`${error}`)\n }\n );\n }\n }\n async function getMutationOverTimeWorkerFunction(event) {\n const mutationOverTimeData = await queryMutationsOverTimeData(event.data);\n const workerResponse = {\n overallMutationData: mutationOverTimeData.overallMutationData,\n mutationOverTimeSerialized: mutationOverTimeData.mutationOverTimeData.getContents()\n };\n return workerResponse;\n }\n self.onmessage = async function(event) {\n await workerFunction(() => getMutationOverTimeWorkerFunction(event));\n };\n})();\n//# sourceMappingURL=mutationOverTimeWorker--b8ZHlji.js.map\n';
|
|
6277
|
+
const jsContent = '(function() {\n "use strict";\n var util;\n (function(util2) {\n util2.assertEqual = (val) => val;\n function assertIs(_arg) {\n }\n util2.assertIs = assertIs;\n function assertNever(_x) {\n throw new Error();\n }\n util2.assertNever = assertNever;\n util2.arrayToEnum = (items) => {\n const obj = {};\n for (const item of items) {\n obj[item] = item;\n }\n return obj;\n };\n util2.getValidEnumValues = (obj) => {\n const validKeys = util2.objectKeys(obj).filter((k2) => typeof obj[obj[k2]] !== "number");\n const filtered = {};\n for (const k2 of validKeys) {\n filtered[k2] = obj[k2];\n }\n return util2.objectValues(filtered);\n };\n util2.objectValues = (obj) => {\n return util2.objectKeys(obj).map(function(e2) {\n return obj[e2];\n });\n };\n util2.objectKeys = typeof Object.keys === "function" ? (obj) => Object.keys(obj) : (object) => {\n const keys = [];\n for (const key in object) {\n if (Object.prototype.hasOwnProperty.call(object, key)) {\n keys.push(key);\n }\n }\n return keys;\n };\n util2.find = (arr, checker) => {\n for (const item of arr) {\n if (checker(item))\n return item;\n }\n return void 0;\n };\n util2.isInteger = typeof Number.isInteger === "function" ? (val) => Number.isInteger(val) : (val) => typeof val === "number" && isFinite(val) && Math.floor(val) === val;\n function joinValues(array, separator = " | ") {\n return array.map((val) => typeof val === "string" ? `\'${val}\'` : val).join(separator);\n }\n util2.joinValues = joinValues;\n util2.jsonStringifyReplacer = (_, value) => {\n if (typeof value === "bigint") {\n return value.toString();\n }\n return value;\n };\n })(util || (util = {}));\n var objectUtil;\n (function(objectUtil2) {\n objectUtil2.mergeShapes = (first, second) => {\n return {\n ...first,\n ...second\n // second overwrites first\n };\n };\n })(objectUtil || (objectUtil = {}));\n const ZodParsedType = util.arrayToEnum([\n "string",\n "nan",\n "number",\n "integer",\n "float",\n "boolean",\n "date",\n "bigint",\n "symbol",\n "function",\n "undefined",\n "null",\n "array",\n "object",\n "unknown",\n "promise",\n "void",\n "never",\n "map",\n "set"\n ]);\n const getParsedType = (data) => {\n const t = typeof data;\n switch (t) {\n case "undefined":\n return ZodParsedType.undefined;\n case "string":\n return ZodParsedType.string;\n case "number":\n return isNaN(data) ? ZodParsedType.nan : ZodParsedType.number;\n case "boolean":\n return ZodParsedType.boolean;\n case "function":\n return ZodParsedType.function;\n case "bigint":\n return ZodParsedType.bigint;\n case "symbol":\n return ZodParsedType.symbol;\n case "object":\n if (Array.isArray(data)) {\n return ZodParsedType.array;\n }\n if (data === null) {\n return ZodParsedType.null;\n }\n if (data.then && typeof data.then === "function" && data.catch && typeof data.catch === "function") {\n return ZodParsedType.promise;\n }\n if (typeof Map !== "undefined" && data instanceof Map) {\n return ZodParsedType.map;\n }\n if (typeof Set !== "undefined" && data instanceof Set) {\n return ZodParsedType.set;\n }\n if (typeof Date !== "undefined" && data instanceof Date) {\n return ZodParsedType.date;\n }\n return ZodParsedType.object;\n default:\n return ZodParsedType.unknown;\n }\n };\n const ZodIssueCode = util.arrayToEnum([\n "invalid_type",\n "invalid_literal",\n "custom",\n "invalid_union",\n "invalid_union_discriminator",\n "invalid_enum_value",\n "unrecognized_keys",\n "invalid_arguments",\n "invalid_return_type",\n "invalid_date",\n "invalid_string",\n "too_small",\n "too_big",\n "invalid_intersection_types",\n "not_multiple_of",\n "not_finite"\n ]);\n const quotelessJson = (obj) => {\n const json = JSON.stringify(obj, null, 2);\n return json.replace(/"([^"]+)":/g, "$1:");\n };\n class ZodError extends Error {\n get errors() {\n return this.issues;\n }\n constructor(issues) {\n super();\n this.issues = [];\n this.addIssue = (sub) => {\n this.issues = [...this.issues, sub];\n };\n this.addIssues = (subs = []) => {\n this.issues = [...this.issues, ...subs];\n };\n const actualProto = new.target.prototype;\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(this, actualProto);\n } else {\n this.__proto__ = actualProto;\n }\n this.name = "ZodError";\n this.issues = issues;\n }\n format(_mapper) {\n const mapper = _mapper || function(issue) {\n return issue.message;\n };\n const fieldErrors = { _errors: [] };\n const processError = (error) => {\n for (const issue of error.issues) {\n if (issue.code === "invalid_union") {\n issue.unionErrors.map(processError);\n } else if (issue.code === "invalid_return_type") {\n processError(issue.returnTypeError);\n } else if (issue.code === "invalid_arguments") {\n processError(issue.argumentsError);\n } else if (issue.path.length === 0) {\n fieldErrors._errors.push(mapper(issue));\n } else {\n let curr = fieldErrors;\n let i2 = 0;\n while (i2 < issue.path.length) {\n const el = issue.path[i2];\n const terminal = i2 === issue.path.length - 1;\n if (!terminal) {\n curr[el] = curr[el] || { _errors: [] };\n } else {\n curr[el] = curr[el] || { _errors: [] };\n curr[el]._errors.push(mapper(issue));\n }\n curr = curr[el];\n i2++;\n }\n }\n }\n };\n processError(this);\n return fieldErrors;\n }\n static assert(value) {\n if (!(value instanceof ZodError)) {\n throw new Error(`Not a ZodError: ${value}`);\n }\n }\n toString() {\n return this.message;\n }\n get message() {\n return JSON.stringify(this.issues, util.jsonStringifyReplacer, 2);\n }\n get isEmpty() {\n return this.issues.length === 0;\n }\n flatten(mapper = (issue) => issue.message) {\n const fieldErrors = {};\n const formErrors = [];\n for (const sub of this.issues) {\n if (sub.path.length > 0) {\n fieldErrors[sub.path[0]] = fieldErrors[sub.path[0]] || [];\n fieldErrors[sub.path[0]].push(mapper(sub));\n } else {\n formErrors.push(mapper(sub));\n }\n }\n return { formErrors, fieldErrors };\n }\n get formErrors() {\n return this.flatten();\n }\n }\n ZodError.create = (issues) => {\n const error = new ZodError(issues);\n return error;\n };\n const errorMap = (issue, _ctx) => {\n let message;\n switch (issue.code) {\n case ZodIssueCode.invalid_type:\n if (issue.received === ZodParsedType.undefined) {\n message = "Required";\n } else {\n message = `Expected ${issue.expected}, received ${issue.received}`;\n }\n break;\n case ZodIssueCode.invalid_literal:\n message = `Invalid literal value, expected ${JSON.stringify(issue.expected, util.jsonStringifyReplacer)}`;\n break;\n case ZodIssueCode.unrecognized_keys:\n message = `Unrecognized key(s) in object: ${util.joinValues(issue.keys, ", ")}`;\n break;\n case ZodIssueCode.invalid_union:\n message = `Invalid input`;\n break;\n case ZodIssueCode.invalid_union_discriminator:\n message = `Invalid discriminator value. Expected ${util.joinValues(issue.options)}`;\n break;\n case ZodIssueCode.invalid_enum_value:\n message = `Invalid enum value. Expected ${util.joinValues(issue.options)}, received \'${issue.received}\'`;\n break;\n case ZodIssueCode.invalid_arguments:\n message = `Invalid function arguments`;\n break;\n case ZodIssueCode.invalid_return_type:\n message = `Invalid function return type`;\n break;\n case ZodIssueCode.invalid_date:\n message = `Invalid date`;\n break;\n case ZodIssueCode.invalid_string:\n if (typeof issue.validation === "object") {\n if ("includes" in issue.validation) {\n message = `Invalid input: must include "${issue.validation.includes}"`;\n if (typeof issue.validation.position === "number") {\n message = `${message} at one or more positions greater than or equal to ${issue.validation.position}`;\n }\n } else if ("startsWith" in issue.validation) {\n message = `Invalid input: must start with "${issue.validation.startsWith}"`;\n } else if ("endsWith" in issue.validation) {\n message = `Invalid input: must end with "${issue.validation.endsWith}"`;\n } else {\n util.assertNever(issue.validation);\n }\n } else if (issue.validation !== "regex") {\n message = `Invalid ${issue.validation}`;\n } else {\n message = "Invalid";\n }\n break;\n case ZodIssueCode.too_small:\n if (issue.type === "array")\n message = `Array must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `more than`} ${issue.minimum} element(s)`;\n else if (issue.type === "string")\n message = `String must contain ${issue.exact ? "exactly" : issue.inclusive ? `at least` : `over`} ${issue.minimum} character(s)`;\n else if (issue.type === "number")\n message = `Number must be ${issue.exact ? `exactly equal to ` : issue.inclusive ? `greater than or equal to ` : `greater than `}${issue.minimum}`;\n else if (issue.type === "date")\n message = `Date must be ${issue.exact ? `exactly equal to ` : issue.inclusive ? `greater than or equal to ` : `greater than `}${new Date(Number(issue.minimum))}`;\n else\n message = "Invalid input";\n break;\n case ZodIssueCode.too_big:\n if (issue.type === "array")\n message = `Array must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `less than`} ${issue.maximum} element(s)`;\n else if (issue.type === "string")\n message = `String must contain ${issue.exact ? `exactly` : issue.inclusive ? `at most` : `under`} ${issue.maximum} character(s)`;\n else if (issue.type === "number")\n message = `Number must be ${issue.exact ? `exactly` : issue.inclusive ? `less than or equal to` : `less than`} ${issue.maximum}`;\n else if (issue.type === "bigint")\n message = `BigInt must be ${issue.exact ? `exactly` : issue.inclusive ? `less than or equal to` : `less than`} ${issue.maximum}`;\n else if (issue.type === "date")\n message = `Date must be ${issue.exact ? `exactly` : issue.inclusive ? `smaller than or equal to` : `smaller than`} ${new Date(Number(issue.maximum))}`;\n else\n message = "Invalid input";\n break;\n case ZodIssueCode.custom:\n message = `Invalid input`;\n break;\n case ZodIssueCode.invalid_intersection_types:\n message = `Intersection results could not be merged`;\n break;\n case ZodIssueCode.not_multiple_of:\n message = `Number must be a multiple of ${issue.multipleOf}`;\n break;\n case ZodIssueCode.not_finite:\n message = "Number must be finite";\n break;\n default:\n message = _ctx.defaultError;\n util.assertNever(issue);\n }\n return { message };\n };\n let overrideErrorMap = errorMap;\n function setErrorMap(map) {\n overrideErrorMap = map;\n }\n function getErrorMap() {\n return overrideErrorMap;\n }\n const makeIssue = (params) => {\n const { data, path, errorMaps, issueData } = params;\n const fullPath = [...path, ...issueData.path || []];\n const fullIssue = {\n ...issueData,\n path: fullPath\n };\n if (issueData.message !== void 0) {\n return {\n ...issueData,\n path: fullPath,\n message: issueData.message\n };\n }\n let errorMessage = "";\n const maps = errorMaps.filter((m2) => !!m2).slice().reverse();\n for (const map of maps) {\n errorMessage = map(fullIssue, { data, defaultError: errorMessage }).message;\n }\n return {\n ...issueData,\n path: fullPath,\n message: errorMessage\n };\n };\n const EMPTY_PATH = [];\n function addIssueToContext(ctx, issueData) {\n const overrideMap = getErrorMap();\n const issue = makeIssue({\n issueData,\n data: ctx.data,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n // contextual error map is first priority\n ctx.schemaErrorMap,\n // then schema-bound map if available\n overrideMap,\n // then global override map\n overrideMap === errorMap ? void 0 : errorMap\n // then global default map\n ].filter((x) => !!x)\n });\n ctx.common.issues.push(issue);\n }\n class ParseStatus {\n constructor() {\n this.value = "valid";\n }\n dirty() {\n if (this.value === "valid")\n this.value = "dirty";\n }\n abort() {\n if (this.value !== "aborted")\n this.value = "aborted";\n }\n static mergeArray(status, results) {\n const arrayValue = [];\n for (const s2 of results) {\n if (s2.status === "aborted")\n return INVALID;\n if (s2.status === "dirty")\n status.dirty();\n arrayValue.push(s2.value);\n }\n return { status: status.value, value: arrayValue };\n }\n static async mergeObjectAsync(status, pairs) {\n const syncPairs = [];\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n syncPairs.push({\n key,\n value\n });\n }\n return ParseStatus.mergeObjectSync(status, syncPairs);\n }\n static mergeObjectSync(status, pairs) {\n const finalObject = {};\n for (const pair of pairs) {\n const { key, value } = pair;\n if (key.status === "aborted")\n return INVALID;\n if (value.status === "aborted")\n return INVALID;\n if (key.status === "dirty")\n status.dirty();\n if (value.status === "dirty")\n status.dirty();\n if (key.value !== "__proto__" && (typeof value.value !== "undefined" || pair.alwaysSet)) {\n finalObject[key.value] = value.value;\n }\n }\n return { status: status.value, value: finalObject };\n }\n }\n const INVALID = Object.freeze({\n status: "aborted"\n });\n const DIRTY = (value) => ({ status: "dirty", value });\n const OK = (value) => ({ status: "valid", value });\n const isAborted = (x) => x.status === "aborted";\n const isDirty = (x) => x.status === "dirty";\n const isValid = (x) => x.status === "valid";\n const isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;\n function __classPrivateFieldGet(receiver, state, kind, f2) {\n if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");\n return state.get(receiver);\n }\n function __classPrivateFieldSet(receiver, state, value, kind, f2) {\n if (typeof state === "function" ? receiver !== state || true : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");\n return state.set(receiver, value), value;\n }\n typeof SuppressedError === "function" ? SuppressedError : function(error, suppressed, message) {\n var e2 = new Error(message);\n return e2.name = "SuppressedError", e2.error = error, e2.suppressed = suppressed, e2;\n };\n var errorUtil;\n (function(errorUtil2) {\n errorUtil2.errToObj = (message) => typeof message === "string" ? { message } : message || {};\n errorUtil2.toString = (message) => typeof message === "string" ? message : message === null || message === void 0 ? void 0 : message.message;\n })(errorUtil || (errorUtil = {}));\n var _ZodEnum_cache, _ZodNativeEnum_cache;\n class ParseInputLazyPath {\n constructor(parent, value, path, key) {\n this._cachedPath = [];\n this.parent = parent;\n this.data = value;\n this._path = path;\n this._key = key;\n }\n get path() {\n if (!this._cachedPath.length) {\n if (this._key instanceof Array) {\n this._cachedPath.push(...this._path, ...this._key);\n } else {\n this._cachedPath.push(...this._path, this._key);\n }\n }\n return this._cachedPath;\n }\n }\n const handleResult = (ctx, result) => {\n if (isValid(result)) {\n return { success: true, data: result.value };\n } else {\n if (!ctx.common.issues.length) {\n throw new Error("Validation failed but no issues detected.");\n }\n return {\n success: false,\n get error() {\n if (this._error)\n return this._error;\n const error = new ZodError(ctx.common.issues);\n this._error = error;\n return this._error;\n }\n };\n }\n };\n function processCreateParams(params) {\n if (!params)\n return {};\n const { errorMap: errorMap2, invalid_type_error, required_error, description } = params;\n if (errorMap2 && (invalid_type_error || required_error)) {\n throw new Error(`Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.`);\n }\n if (errorMap2)\n return { errorMap: errorMap2, description };\n const customMap = (iss, ctx) => {\n var _a, _b;\n const { message } = params;\n if (iss.code === "invalid_enum_value") {\n return { message: message !== null && message !== void 0 ? message : ctx.defaultError };\n }\n if (typeof ctx.data === "undefined") {\n return { message: (_a = message !== null && message !== void 0 ? message : required_error) !== null && _a !== void 0 ? _a : ctx.defaultError };\n }\n if (iss.code !== "invalid_type")\n return { message: ctx.defaultError };\n return { message: (_b = message !== null && message !== void 0 ? message : invalid_type_error) !== null && _b !== void 0 ? _b : ctx.defaultError };\n };\n return { errorMap: customMap, description };\n }\n class ZodType {\n get description() {\n return this._def.description;\n }\n _getType(input) {\n return getParsedType(input.data);\n }\n _getOrReturnCtx(input, ctx) {\n return ctx || {\n common: input.parent.common,\n data: input.data,\n parsedType: getParsedType(input.data),\n schemaErrorMap: this._def.errorMap,\n path: input.path,\n parent: input.parent\n };\n }\n _processInputParams(input) {\n return {\n status: new ParseStatus(),\n ctx: {\n common: input.parent.common,\n data: input.data,\n parsedType: getParsedType(input.data),\n schemaErrorMap: this._def.errorMap,\n path: input.path,\n parent: input.parent\n }\n };\n }\n _parseSync(input) {\n const result = this._parse(input);\n if (isAsync(result)) {\n throw new Error("Synchronous parse encountered promise.");\n }\n return result;\n }\n _parseAsync(input) {\n const result = this._parse(input);\n return Promise.resolve(result);\n }\n parse(data, params) {\n const result = this.safeParse(data, params);\n if (result.success)\n return result.data;\n throw result.error;\n }\n safeParse(data, params) {\n var _a;\n const ctx = {\n common: {\n issues: [],\n async: (_a = params === null || params === void 0 ? void 0 : params.async) !== null && _a !== void 0 ? _a : false,\n contextualErrorMap: params === null || params === void 0 ? void 0 : params.errorMap\n },\n path: (params === null || params === void 0 ? void 0 : params.path) || [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n const result = this._parseSync({ data, path: ctx.path, parent: ctx });\n return handleResult(ctx, result);\n }\n "~validate"(data) {\n var _a, _b;\n const ctx = {\n common: {\n issues: [],\n async: !!this["~standard"].async\n },\n path: [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n if (!this["~standard"].async) {\n try {\n const result = this._parseSync({ data, path: [], parent: ctx });\n return isValid(result) ? {\n value: result.value\n } : {\n issues: ctx.common.issues\n };\n } catch (err) {\n if ((_b = (_a = err === null || err === void 0 ? void 0 : err.message) === null || _a === void 0 ? void 0 : _a.toLowerCase()) === null || _b === void 0 ? void 0 : _b.includes("encountered")) {\n this["~standard"].async = true;\n }\n ctx.common = {\n issues: [],\n async: true\n };\n }\n }\n return this._parseAsync({ data, path: [], parent: ctx }).then((result) => isValid(result) ? {\n value: result.value\n } : {\n issues: ctx.common.issues\n });\n }\n async parseAsync(data, params) {\n const result = await this.safeParseAsync(data, params);\n if (result.success)\n return result.data;\n throw result.error;\n }\n async safeParseAsync(data, params) {\n const ctx = {\n common: {\n issues: [],\n contextualErrorMap: params === null || params === void 0 ? void 0 : params.errorMap,\n async: true\n },\n path: (params === null || params === void 0 ? void 0 : params.path) || [],\n schemaErrorMap: this._def.errorMap,\n parent: null,\n data,\n parsedType: getParsedType(data)\n };\n const maybeAsyncResult = this._parse({ data, path: ctx.path, parent: ctx });\n const result = await (isAsync(maybeAsyncResult) ? maybeAsyncResult : Promise.resolve(maybeAsyncResult));\n return handleResult(ctx, result);\n }\n refine(check, message) {\n const getIssueProperties = (val) => {\n if (typeof message === "string" || typeof message === "undefined") {\n return { message };\n } else if (typeof message === "function") {\n return message(val);\n } else {\n return message;\n }\n };\n return this._refinement((val, ctx) => {\n const result = check(val);\n const setError = () => ctx.addIssue({\n code: ZodIssueCode.custom,\n ...getIssueProperties(val)\n });\n if (typeof Promise !== "undefined" && result instanceof Promise) {\n return result.then((data) => {\n if (!data) {\n setError();\n return false;\n } else {\n return true;\n }\n });\n }\n if (!result) {\n setError();\n return false;\n } else {\n return true;\n }\n });\n }\n refinement(check, refinementData) {\n return this._refinement((val, ctx) => {\n if (!check(val)) {\n ctx.addIssue(typeof refinementData === "function" ? refinementData(val, ctx) : refinementData);\n return false;\n } else {\n return true;\n }\n });\n }\n _refinement(refinement) {\n return new ZodEffects({\n schema: this,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect: { type: "refinement", refinement }\n });\n }\n superRefine(refinement) {\n return this._refinement(refinement);\n }\n constructor(def) {\n this.spa = this.safeParseAsync;\n this._def = def;\n this.parse = this.parse.bind(this);\n this.safeParse = this.safeParse.bind(this);\n this.parseAsync = this.parseAsync.bind(this);\n this.safeParseAsync = this.safeParseAsync.bind(this);\n this.spa = this.spa.bind(this);\n this.refine = this.refine.bind(this);\n this.refinement = this.refinement.bind(this);\n this.superRefine = this.superRefine.bind(this);\n this.optional = this.optional.bind(this);\n this.nullable = this.nullable.bind(this);\n this.nullish = this.nullish.bind(this);\n this.array = this.array.bind(this);\n this.promise = this.promise.bind(this);\n this.or = this.or.bind(this);\n this.and = this.and.bind(this);\n this.transform = this.transform.bind(this);\n this.brand = this.brand.bind(this);\n this.default = this.default.bind(this);\n this.catch = this.catch.bind(this);\n this.describe = this.describe.bind(this);\n this.pipe = this.pipe.bind(this);\n this.readonly = this.readonly.bind(this);\n this.isNullable = this.isNullable.bind(this);\n this.isOptional = this.isOptional.bind(this);\n this["~standard"] = {\n version: 1,\n vendor: "zod",\n validate: (data) => this["~validate"](data)\n };\n }\n optional() {\n return ZodOptional.create(this, this._def);\n }\n nullable() {\n return ZodNullable.create(this, this._def);\n }\n nullish() {\n return this.nullable().optional();\n }\n array() {\n return ZodArray.create(this);\n }\n promise() {\n return ZodPromise.create(this, this._def);\n }\n or(option) {\n return ZodUnion.create([this, option], this._def);\n }\n and(incoming) {\n return ZodIntersection.create(this, incoming, this._def);\n }\n transform(transform) {\n return new ZodEffects({\n ...processCreateParams(this._def),\n schema: this,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect: { type: "transform", transform }\n });\n }\n default(def) {\n const defaultValueFunc = typeof def === "function" ? def : () => def;\n return new ZodDefault({\n ...processCreateParams(this._def),\n innerType: this,\n defaultValue: defaultValueFunc,\n typeName: ZodFirstPartyTypeKind.ZodDefault\n });\n }\n brand() {\n return new ZodBranded({\n typeName: ZodFirstPartyTypeKind.ZodBranded,\n type: this,\n ...processCreateParams(this._def)\n });\n }\n catch(def) {\n const catchValueFunc = typeof def === "function" ? def : () => def;\n return new ZodCatch({\n ...processCreateParams(this._def),\n innerType: this,\n catchValue: catchValueFunc,\n typeName: ZodFirstPartyTypeKind.ZodCatch\n });\n }\n describe(description) {\n const This = this.constructor;\n return new This({\n ...this._def,\n description\n });\n }\n pipe(target) {\n return ZodPipeline.create(this, target);\n }\n readonly() {\n return ZodReadonly.create(this);\n }\n isOptional() {\n return this.safeParse(void 0).success;\n }\n isNullable() {\n return this.safeParse(null).success;\n }\n }\n const cuidRegex = /^c[^\\s-]{8,}$/i;\n const cuid2Regex = /^[0-9a-z]+$/;\n const ulidRegex = /^[0-9A-HJKMNP-TV-Z]{26}$/i;\n const uuidRegex = /^[0-9a-fA-F]{8}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{4}\\b-[0-9a-fA-F]{12}$/i;\n const nanoidRegex = /^[a-z0-9_-]{21}$/i;\n const jwtRegex = /^[A-Za-z0-9-_]+\\.[A-Za-z0-9-_]+\\.[A-Za-z0-9-_]*$/;\n const durationRegex = /^[-+]?P(?!$)(?:(?:[-+]?\\d+Y)|(?:[-+]?\\d+[.,]\\d+Y$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:(?:[-+]?\\d+W)|(?:[-+]?\\d+[.,]\\d+W$))?(?:(?:[-+]?\\d+D)|(?:[-+]?\\d+[.,]\\d+D$))?(?:T(?=[\\d+-])(?:(?:[-+]?\\d+H)|(?:[-+]?\\d+[.,]\\d+H$))?(?:(?:[-+]?\\d+M)|(?:[-+]?\\d+[.,]\\d+M$))?(?:[-+]?\\d+(?:[.,]\\d+)?S)?)??$/;\n const emailRegex = /^(?!\\.)(?!.*\\.\\.)([A-Z0-9_\'+\\-\\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\\-]*\\.)+[A-Z]{2,}$/i;\n const _emojiRegex = `^(\\\\p{Extended_Pictographic}|\\\\p{Emoji_Component})+$`;\n let emojiRegex;\n const ipv4Regex = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/;\n const ipv4CidrRegex = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\/(3[0-2]|[12]?[0-9])$/;\n const ipv6Regex = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/;\n const ipv6CidrRegex = /^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/;\n const base64Regex = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/;\n const base64urlRegex = /^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/;\n const dateRegexSource = `((\\\\d\\\\d[2468][048]|\\\\d\\\\d[13579][26]|\\\\d\\\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\\\d|30)|(02)-(0[1-9]|1\\\\d|2[0-8])))`;\n const dateRegex = new RegExp(`^${dateRegexSource}$`);\n function timeRegexSource(args) {\n let regex = `([01]\\\\d|2[0-3]):[0-5]\\\\d:[0-5]\\\\d`;\n if (args.precision) {\n regex = `${regex}\\\\.\\\\d{${args.precision}}`;\n } else if (args.precision == null) {\n regex = `${regex}(\\\\.\\\\d+)?`;\n }\n return regex;\n }\n function timeRegex(args) {\n return new RegExp(`^${timeRegexSource(args)}$`);\n }\n function datetimeRegex(args) {\n let regex = `${dateRegexSource}T${timeRegexSource(args)}`;\n const opts = [];\n opts.push(args.local ? `Z?` : `Z`);\n if (args.offset)\n opts.push(`([+-]\\\\d{2}:?\\\\d{2})`);\n regex = `${regex}(${opts.join("|")})`;\n return new RegExp(`^${regex}$`);\n }\n function isValidIP(ip, version) {\n if ((version === "v4" || !version) && ipv4Regex.test(ip)) {\n return true;\n }\n if ((version === "v6" || !version) && ipv6Regex.test(ip)) {\n return true;\n }\n return false;\n }\n function isValidJWT(jwt, alg) {\n if (!jwtRegex.test(jwt))\n return false;\n try {\n const [header] = jwt.split(".");\n const base64 = header.replace(/-/g, "+").replace(/_/g, "/").padEnd(header.length + (4 - header.length % 4) % 4, "=");\n const decoded = JSON.parse(atob(base64));\n if (typeof decoded !== "object" || decoded === null)\n return false;\n if (!decoded.typ || !decoded.alg)\n return false;\n if (alg && decoded.alg !== alg)\n return false;\n return true;\n } catch (_a) {\n return false;\n }\n }\n function isValidCidr(ip, version) {\n if ((version === "v4" || !version) && ipv4CidrRegex.test(ip)) {\n return true;\n }\n if ((version === "v6" || !version) && ipv6CidrRegex.test(ip)) {\n return true;\n }\n return false;\n }\n class ZodString extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = String(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.string) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.string,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n const status = new ParseStatus();\n let ctx = void 0;\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n if (input.data.length < check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "string",\n inclusive: true,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n if (input.data.length > check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "string",\n inclusive: true,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "length") {\n const tooBig = input.data.length > check.value;\n const tooSmall = input.data.length < check.value;\n if (tooBig || tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n if (tooBig) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "string",\n inclusive: true,\n exact: true,\n message: check.message\n });\n } else if (tooSmall) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "string",\n inclusive: true,\n exact: true,\n message: check.message\n });\n }\n status.dirty();\n }\n } else if (check.kind === "email") {\n if (!emailRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "email",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "emoji") {\n if (!emojiRegex) {\n emojiRegex = new RegExp(_emojiRegex, "u");\n }\n if (!emojiRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "emoji",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "uuid") {\n if (!uuidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "uuid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "nanoid") {\n if (!nanoidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "nanoid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cuid") {\n if (!cuidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cuid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cuid2") {\n if (!cuid2Regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cuid2",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "ulid") {\n if (!ulidRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "ulid",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "url") {\n try {\n new URL(input.data);\n } catch (_a) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "url",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "regex") {\n check.regex.lastIndex = 0;\n const testResult = check.regex.test(input.data);\n if (!testResult) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "regex",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "trim") {\n input.data = input.data.trim();\n } else if (check.kind === "includes") {\n if (!input.data.includes(check.value, check.position)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { includes: check.value, position: check.position },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "toLowerCase") {\n input.data = input.data.toLowerCase();\n } else if (check.kind === "toUpperCase") {\n input.data = input.data.toUpperCase();\n } else if (check.kind === "startsWith") {\n if (!input.data.startsWith(check.value)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { startsWith: check.value },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "endsWith") {\n if (!input.data.endsWith(check.value)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: { endsWith: check.value },\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "datetime") {\n const regex = datetimeRegex(check);\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "datetime",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "date") {\n const regex = dateRegex;\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "date",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "time") {\n const regex = timeRegex(check);\n if (!regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_string,\n validation: "time",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "duration") {\n if (!durationRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "duration",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "ip") {\n if (!isValidIP(input.data, check.version)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "ip",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "jwt") {\n if (!isValidJWT(input.data, check.alg)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "jwt",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "cidr") {\n if (!isValidCidr(input.data, check.version)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "cidr",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "base64") {\n if (!base64Regex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "base64",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "base64url") {\n if (!base64urlRegex.test(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n validation: "base64url",\n code: ZodIssueCode.invalid_string,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n _regex(regex, validation, message) {\n return this.refinement((data) => regex.test(data), {\n validation,\n code: ZodIssueCode.invalid_string,\n ...errorUtil.errToObj(message)\n });\n }\n _addCheck(check) {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n email(message) {\n return this._addCheck({ kind: "email", ...errorUtil.errToObj(message) });\n }\n url(message) {\n return this._addCheck({ kind: "url", ...errorUtil.errToObj(message) });\n }\n emoji(message) {\n return this._addCheck({ kind: "emoji", ...errorUtil.errToObj(message) });\n }\n uuid(message) {\n return this._addCheck({ kind: "uuid", ...errorUtil.errToObj(message) });\n }\n nanoid(message) {\n return this._addCheck({ kind: "nanoid", ...errorUtil.errToObj(message) });\n }\n cuid(message) {\n return this._addCheck({ kind: "cuid", ...errorUtil.errToObj(message) });\n }\n cuid2(message) {\n return this._addCheck({ kind: "cuid2", ...errorUtil.errToObj(message) });\n }\n ulid(message) {\n return this._addCheck({ kind: "ulid", ...errorUtil.errToObj(message) });\n }\n base64(message) {\n return this._addCheck({ kind: "base64", ...errorUtil.errToObj(message) });\n }\n base64url(message) {\n return this._addCheck({\n kind: "base64url",\n ...errorUtil.errToObj(message)\n });\n }\n jwt(options) {\n return this._addCheck({ kind: "jwt", ...errorUtil.errToObj(options) });\n }\n ip(options) {\n return this._addCheck({ kind: "ip", ...errorUtil.errToObj(options) });\n }\n cidr(options) {\n return this._addCheck({ kind: "cidr", ...errorUtil.errToObj(options) });\n }\n datetime(options) {\n var _a, _b;\n if (typeof options === "string") {\n return this._addCheck({\n kind: "datetime",\n precision: null,\n offset: false,\n local: false,\n message: options\n });\n }\n return this._addCheck({\n kind: "datetime",\n precision: typeof (options === null || options === void 0 ? void 0 : options.precision) === "undefined" ? null : options === null || options === void 0 ? void 0 : options.precision,\n offset: (_a = options === null || options === void 0 ? void 0 : options.offset) !== null && _a !== void 0 ? _a : false,\n local: (_b = options === null || options === void 0 ? void 0 : options.local) !== null && _b !== void 0 ? _b : false,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n date(message) {\n return this._addCheck({ kind: "date", message });\n }\n time(options) {\n if (typeof options === "string") {\n return this._addCheck({\n kind: "time",\n precision: null,\n message: options\n });\n }\n return this._addCheck({\n kind: "time",\n precision: typeof (options === null || options === void 0 ? void 0 : options.precision) === "undefined" ? null : options === null || options === void 0 ? void 0 : options.precision,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n duration(message) {\n return this._addCheck({ kind: "duration", ...errorUtil.errToObj(message) });\n }\n regex(regex, message) {\n return this._addCheck({\n kind: "regex",\n regex,\n ...errorUtil.errToObj(message)\n });\n }\n includes(value, options) {\n return this._addCheck({\n kind: "includes",\n value,\n position: options === null || options === void 0 ? void 0 : options.position,\n ...errorUtil.errToObj(options === null || options === void 0 ? void 0 : options.message)\n });\n }\n startsWith(value, message) {\n return this._addCheck({\n kind: "startsWith",\n value,\n ...errorUtil.errToObj(message)\n });\n }\n endsWith(value, message) {\n return this._addCheck({\n kind: "endsWith",\n value,\n ...errorUtil.errToObj(message)\n });\n }\n min(minLength, message) {\n return this._addCheck({\n kind: "min",\n value: minLength,\n ...errorUtil.errToObj(message)\n });\n }\n max(maxLength, message) {\n return this._addCheck({\n kind: "max",\n value: maxLength,\n ...errorUtil.errToObj(message)\n });\n }\n length(len, message) {\n return this._addCheck({\n kind: "length",\n value: len,\n ...errorUtil.errToObj(message)\n });\n }\n /**\n * Equivalent to `.min(1)`\n */\n nonempty(message) {\n return this.min(1, errorUtil.errToObj(message));\n }\n trim() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "trim" }]\n });\n }\n toLowerCase() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "toLowerCase" }]\n });\n }\n toUpperCase() {\n return new ZodString({\n ...this._def,\n checks: [...this._def.checks, { kind: "toUpperCase" }]\n });\n }\n get isDatetime() {\n return !!this._def.checks.find((ch) => ch.kind === "datetime");\n }\n get isDate() {\n return !!this._def.checks.find((ch) => ch.kind === "date");\n }\n get isTime() {\n return !!this._def.checks.find((ch) => ch.kind === "time");\n }\n get isDuration() {\n return !!this._def.checks.find((ch) => ch.kind === "duration");\n }\n get isEmail() {\n return !!this._def.checks.find((ch) => ch.kind === "email");\n }\n get isURL() {\n return !!this._def.checks.find((ch) => ch.kind === "url");\n }\n get isEmoji() {\n return !!this._def.checks.find((ch) => ch.kind === "emoji");\n }\n get isUUID() {\n return !!this._def.checks.find((ch) => ch.kind === "uuid");\n }\n get isNANOID() {\n return !!this._def.checks.find((ch) => ch.kind === "nanoid");\n }\n get isCUID() {\n return !!this._def.checks.find((ch) => ch.kind === "cuid");\n }\n get isCUID2() {\n return !!this._def.checks.find((ch) => ch.kind === "cuid2");\n }\n get isULID() {\n return !!this._def.checks.find((ch) => ch.kind === "ulid");\n }\n get isIP() {\n return !!this._def.checks.find((ch) => ch.kind === "ip");\n }\n get isCIDR() {\n return !!this._def.checks.find((ch) => ch.kind === "cidr");\n }\n get isBase64() {\n return !!this._def.checks.find((ch) => ch.kind === "base64");\n }\n get isBase64url() {\n return !!this._def.checks.find((ch) => ch.kind === "base64url");\n }\n get minLength() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxLength() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n }\n ZodString.create = (params) => {\n var _a;\n return new ZodString({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodString,\n coerce: (_a = params === null || params === void 0 ? void 0 : params.coerce) !== null && _a !== void 0 ? _a : false,\n ...processCreateParams(params)\n });\n };\n function floatSafeRemainder(val, step) {\n const valDecCount = (val.toString().split(".")[1] || "").length;\n const stepDecCount = (step.toString().split(".")[1] || "").length;\n const decCount = valDecCount > stepDecCount ? valDecCount : stepDecCount;\n const valInt = parseInt(val.toFixed(decCount).replace(".", ""));\n const stepInt = parseInt(step.toFixed(decCount).replace(".", ""));\n return valInt % stepInt / Math.pow(10, decCount);\n }\n class ZodNumber extends ZodType {\n constructor() {\n super(...arguments);\n this.min = this.gte;\n this.max = this.lte;\n this.step = this.multipleOf;\n }\n _parse(input) {\n if (this._def.coerce) {\n input.data = Number(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.number) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.number,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n let ctx = void 0;\n const status = new ParseStatus();\n for (const check of this._def.checks) {\n if (check.kind === "int") {\n if (!util.isInteger(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: "integer",\n received: "float",\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "min") {\n const tooSmall = check.inclusive ? input.data < check.value : input.data <= check.value;\n if (tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: check.value,\n type: "number",\n inclusive: check.inclusive,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n const tooBig = check.inclusive ? input.data > check.value : input.data >= check.value;\n if (tooBig) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: check.value,\n type: "number",\n inclusive: check.inclusive,\n exact: false,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "multipleOf") {\n if (floatSafeRemainder(input.data, check.value) !== 0) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_multiple_of,\n multipleOf: check.value,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "finite") {\n if (!Number.isFinite(input.data)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_finite,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n gte(value, message) {\n return this.setLimit("min", value, true, errorUtil.toString(message));\n }\n gt(value, message) {\n return this.setLimit("min", value, false, errorUtil.toString(message));\n }\n lte(value, message) {\n return this.setLimit("max", value, true, errorUtil.toString(message));\n }\n lt(value, message) {\n return this.setLimit("max", value, false, errorUtil.toString(message));\n }\n setLimit(kind, value, inclusive, message) {\n return new ZodNumber({\n ...this._def,\n checks: [\n ...this._def.checks,\n {\n kind,\n value,\n inclusive,\n message: errorUtil.toString(message)\n }\n ]\n });\n }\n _addCheck(check) {\n return new ZodNumber({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n int(message) {\n return this._addCheck({\n kind: "int",\n message: errorUtil.toString(message)\n });\n }\n positive(message) {\n return this._addCheck({\n kind: "min",\n value: 0,\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n negative(message) {\n return this._addCheck({\n kind: "max",\n value: 0,\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n nonpositive(message) {\n return this._addCheck({\n kind: "max",\n value: 0,\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n nonnegative(message) {\n return this._addCheck({\n kind: "min",\n value: 0,\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n multipleOf(value, message) {\n return this._addCheck({\n kind: "multipleOf",\n value,\n message: errorUtil.toString(message)\n });\n }\n finite(message) {\n return this._addCheck({\n kind: "finite",\n message: errorUtil.toString(message)\n });\n }\n safe(message) {\n return this._addCheck({\n kind: "min",\n inclusive: true,\n value: Number.MIN_SAFE_INTEGER,\n message: errorUtil.toString(message)\n })._addCheck({\n kind: "max",\n inclusive: true,\n value: Number.MAX_SAFE_INTEGER,\n message: errorUtil.toString(message)\n });\n }\n get minValue() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxValue() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n get isInt() {\n return !!this._def.checks.find((ch) => ch.kind === "int" || ch.kind === "multipleOf" && util.isInteger(ch.value));\n }\n get isFinite() {\n let max = null, min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "finite" || ch.kind === "int" || ch.kind === "multipleOf") {\n return true;\n } else if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n } else if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return Number.isFinite(min) && Number.isFinite(max);\n }\n }\n ZodNumber.create = (params) => {\n return new ZodNumber({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodNumber,\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n ...processCreateParams(params)\n });\n };\n class ZodBigInt extends ZodType {\n constructor() {\n super(...arguments);\n this.min = this.gte;\n this.max = this.lte;\n }\n _parse(input) {\n if (this._def.coerce) {\n try {\n input.data = BigInt(input.data);\n } catch (_a) {\n return this._getInvalidInput(input);\n }\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.bigint) {\n return this._getInvalidInput(input);\n }\n let ctx = void 0;\n const status = new ParseStatus();\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n const tooSmall = check.inclusive ? input.data < check.value : input.data <= check.value;\n if (tooSmall) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n type: "bigint",\n minimum: check.value,\n inclusive: check.inclusive,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n const tooBig = check.inclusive ? input.data > check.value : input.data >= check.value;\n if (tooBig) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n type: "bigint",\n maximum: check.value,\n inclusive: check.inclusive,\n message: check.message\n });\n status.dirty();\n }\n } else if (check.kind === "multipleOf") {\n if (input.data % check.value !== BigInt(0)) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.not_multiple_of,\n multipleOf: check.value,\n message: check.message\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return { status: status.value, value: input.data };\n }\n _getInvalidInput(input) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.bigint,\n received: ctx.parsedType\n });\n return INVALID;\n }\n gte(value, message) {\n return this.setLimit("min", value, true, errorUtil.toString(message));\n }\n gt(value, message) {\n return this.setLimit("min", value, false, errorUtil.toString(message));\n }\n lte(value, message) {\n return this.setLimit("max", value, true, errorUtil.toString(message));\n }\n lt(value, message) {\n return this.setLimit("max", value, false, errorUtil.toString(message));\n }\n setLimit(kind, value, inclusive, message) {\n return new ZodBigInt({\n ...this._def,\n checks: [\n ...this._def.checks,\n {\n kind,\n value,\n inclusive,\n message: errorUtil.toString(message)\n }\n ]\n });\n }\n _addCheck(check) {\n return new ZodBigInt({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n positive(message) {\n return this._addCheck({\n kind: "min",\n value: BigInt(0),\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n negative(message) {\n return this._addCheck({\n kind: "max",\n value: BigInt(0),\n inclusive: false,\n message: errorUtil.toString(message)\n });\n }\n nonpositive(message) {\n return this._addCheck({\n kind: "max",\n value: BigInt(0),\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n nonnegative(message) {\n return this._addCheck({\n kind: "min",\n value: BigInt(0),\n inclusive: true,\n message: errorUtil.toString(message)\n });\n }\n multipleOf(value, message) {\n return this._addCheck({\n kind: "multipleOf",\n value,\n message: errorUtil.toString(message)\n });\n }\n get minValue() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min;\n }\n get maxValue() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max;\n }\n }\n ZodBigInt.create = (params) => {\n var _a;\n return new ZodBigInt({\n checks: [],\n typeName: ZodFirstPartyTypeKind.ZodBigInt,\n coerce: (_a = params === null || params === void 0 ? void 0 : params.coerce) !== null && _a !== void 0 ? _a : false,\n ...processCreateParams(params)\n });\n };\n class ZodBoolean extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = Boolean(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.boolean) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.boolean,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodBoolean.create = (params) => {\n return new ZodBoolean({\n typeName: ZodFirstPartyTypeKind.ZodBoolean,\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n ...processCreateParams(params)\n });\n };\n class ZodDate extends ZodType {\n _parse(input) {\n if (this._def.coerce) {\n input.data = new Date(input.data);\n }\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.date) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.date,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n if (isNaN(input.data.getTime())) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_date\n });\n return INVALID;\n }\n const status = new ParseStatus();\n let ctx = void 0;\n for (const check of this._def.checks) {\n if (check.kind === "min") {\n if (input.data.getTime() < check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n message: check.message,\n inclusive: true,\n exact: false,\n minimum: check.value,\n type: "date"\n });\n status.dirty();\n }\n } else if (check.kind === "max") {\n if (input.data.getTime() > check.value) {\n ctx = this._getOrReturnCtx(input, ctx);\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n message: check.message,\n inclusive: true,\n exact: false,\n maximum: check.value,\n type: "date"\n });\n status.dirty();\n }\n } else {\n util.assertNever(check);\n }\n }\n return {\n status: status.value,\n value: new Date(input.data.getTime())\n };\n }\n _addCheck(check) {\n return new ZodDate({\n ...this._def,\n checks: [...this._def.checks, check]\n });\n }\n min(minDate, message) {\n return this._addCheck({\n kind: "min",\n value: minDate.getTime(),\n message: errorUtil.toString(message)\n });\n }\n max(maxDate, message) {\n return this._addCheck({\n kind: "max",\n value: maxDate.getTime(),\n message: errorUtil.toString(message)\n });\n }\n get minDate() {\n let min = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "min") {\n if (min === null || ch.value > min)\n min = ch.value;\n }\n }\n return min != null ? new Date(min) : null;\n }\n get maxDate() {\n let max = null;\n for (const ch of this._def.checks) {\n if (ch.kind === "max") {\n if (max === null || ch.value < max)\n max = ch.value;\n }\n }\n return max != null ? new Date(max) : null;\n }\n }\n ZodDate.create = (params) => {\n return new ZodDate({\n checks: [],\n coerce: (params === null || params === void 0 ? void 0 : params.coerce) || false,\n typeName: ZodFirstPartyTypeKind.ZodDate,\n ...processCreateParams(params)\n });\n };\n class ZodSymbol extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.symbol) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.symbol,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodSymbol.create = (params) => {\n return new ZodSymbol({\n typeName: ZodFirstPartyTypeKind.ZodSymbol,\n ...processCreateParams(params)\n });\n };\n class ZodUndefined extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.undefined) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.undefined,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodUndefined.create = (params) => {\n return new ZodUndefined({\n typeName: ZodFirstPartyTypeKind.ZodUndefined,\n ...processCreateParams(params)\n });\n };\n class ZodNull extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.null) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.null,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodNull.create = (params) => {\n return new ZodNull({\n typeName: ZodFirstPartyTypeKind.ZodNull,\n ...processCreateParams(params)\n });\n };\n class ZodAny extends ZodType {\n constructor() {\n super(...arguments);\n this._any = true;\n }\n _parse(input) {\n return OK(input.data);\n }\n }\n ZodAny.create = (params) => {\n return new ZodAny({\n typeName: ZodFirstPartyTypeKind.ZodAny,\n ...processCreateParams(params)\n });\n };\n class ZodUnknown extends ZodType {\n constructor() {\n super(...arguments);\n this._unknown = true;\n }\n _parse(input) {\n return OK(input.data);\n }\n }\n ZodUnknown.create = (params) => {\n return new ZodUnknown({\n typeName: ZodFirstPartyTypeKind.ZodUnknown,\n ...processCreateParams(params)\n });\n };\n class ZodNever extends ZodType {\n _parse(input) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.never,\n received: ctx.parsedType\n });\n return INVALID;\n }\n }\n ZodNever.create = (params) => {\n return new ZodNever({\n typeName: ZodFirstPartyTypeKind.ZodNever,\n ...processCreateParams(params)\n });\n };\n class ZodVoid extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.undefined) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.void,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return OK(input.data);\n }\n }\n ZodVoid.create = (params) => {\n return new ZodVoid({\n typeName: ZodFirstPartyTypeKind.ZodVoid,\n ...processCreateParams(params)\n });\n };\n class ZodArray extends ZodType {\n _parse(input) {\n const { ctx, status } = this._processInputParams(input);\n const def = this._def;\n if (ctx.parsedType !== ZodParsedType.array) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.array,\n received: ctx.parsedType\n });\n return INVALID;\n }\n if (def.exactLength !== null) {\n const tooBig = ctx.data.length > def.exactLength.value;\n const tooSmall = ctx.data.length < def.exactLength.value;\n if (tooBig || tooSmall) {\n addIssueToContext(ctx, {\n code: tooBig ? ZodIssueCode.too_big : ZodIssueCode.too_small,\n minimum: tooSmall ? def.exactLength.value : void 0,\n maximum: tooBig ? def.exactLength.value : void 0,\n type: "array",\n inclusive: true,\n exact: true,\n message: def.exactLength.message\n });\n status.dirty();\n }\n }\n if (def.minLength !== null) {\n if (ctx.data.length < def.minLength.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: def.minLength.value,\n type: "array",\n inclusive: true,\n exact: false,\n message: def.minLength.message\n });\n status.dirty();\n }\n }\n if (def.maxLength !== null) {\n if (ctx.data.length > def.maxLength.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: def.maxLength.value,\n type: "array",\n inclusive: true,\n exact: false,\n message: def.maxLength.message\n });\n status.dirty();\n }\n }\n if (ctx.common.async) {\n return Promise.all([...ctx.data].map((item, i2) => {\n return def.type._parseAsync(new ParseInputLazyPath(ctx, item, ctx.path, i2));\n })).then((result2) => {\n return ParseStatus.mergeArray(status, result2);\n });\n }\n const result = [...ctx.data].map((item, i2) => {\n return def.type._parseSync(new ParseInputLazyPath(ctx, item, ctx.path, i2));\n });\n return ParseStatus.mergeArray(status, result);\n }\n get element() {\n return this._def.type;\n }\n min(minLength, message) {\n return new ZodArray({\n ...this._def,\n minLength: { value: minLength, message: errorUtil.toString(message) }\n });\n }\n max(maxLength, message) {\n return new ZodArray({\n ...this._def,\n maxLength: { value: maxLength, message: errorUtil.toString(message) }\n });\n }\n length(len, message) {\n return new ZodArray({\n ...this._def,\n exactLength: { value: len, message: errorUtil.toString(message) }\n });\n }\n nonempty(message) {\n return this.min(1, message);\n }\n }\n ZodArray.create = (schema, params) => {\n return new ZodArray({\n type: schema,\n minLength: null,\n maxLength: null,\n exactLength: null,\n typeName: ZodFirstPartyTypeKind.ZodArray,\n ...processCreateParams(params)\n });\n };\n function deepPartialify(schema) {\n if (schema instanceof ZodObject) {\n const newShape = {};\n for (const key in schema.shape) {\n const fieldSchema = schema.shape[key];\n newShape[key] = ZodOptional.create(deepPartialify(fieldSchema));\n }\n return new ZodObject({\n ...schema._def,\n shape: () => newShape\n });\n } else if (schema instanceof ZodArray) {\n return new ZodArray({\n ...schema._def,\n type: deepPartialify(schema.element)\n });\n } else if (schema instanceof ZodOptional) {\n return ZodOptional.create(deepPartialify(schema.unwrap()));\n } else if (schema instanceof ZodNullable) {\n return ZodNullable.create(deepPartialify(schema.unwrap()));\n } else if (schema instanceof ZodTuple) {\n return ZodTuple.create(schema.items.map((item) => deepPartialify(item)));\n } else {\n return schema;\n }\n }\n class ZodObject extends ZodType {\n constructor() {\n super(...arguments);\n this._cached = null;\n this.nonstrict = this.passthrough;\n this.augment = this.extend;\n }\n _getCached() {\n if (this._cached !== null)\n return this._cached;\n const shape = this._def.shape();\n const keys = util.objectKeys(shape);\n return this._cached = { shape, keys };\n }\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.object) {\n const ctx2 = this._getOrReturnCtx(input);\n addIssueToContext(ctx2, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx2.parsedType\n });\n return INVALID;\n }\n const { status, ctx } = this._processInputParams(input);\n const { shape, keys: shapeKeys } = this._getCached();\n const extraKeys = [];\n if (!(this._def.catchall instanceof ZodNever && this._def.unknownKeys === "strip")) {\n for (const key in ctx.data) {\n if (!shapeKeys.includes(key)) {\n extraKeys.push(key);\n }\n }\n }\n const pairs = [];\n for (const key of shapeKeys) {\n const keyValidator = shape[key];\n const value = ctx.data[key];\n pairs.push({\n key: { status: "valid", value: key },\n value: keyValidator._parse(new ParseInputLazyPath(ctx, value, ctx.path, key)),\n alwaysSet: key in ctx.data\n });\n }\n if (this._def.catchall instanceof ZodNever) {\n const unknownKeys = this._def.unknownKeys;\n if (unknownKeys === "passthrough") {\n for (const key of extraKeys) {\n pairs.push({\n key: { status: "valid", value: key },\n value: { status: "valid", value: ctx.data[key] }\n });\n }\n } else if (unknownKeys === "strict") {\n if (extraKeys.length > 0) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.unrecognized_keys,\n keys: extraKeys\n });\n status.dirty();\n }\n } else if (unknownKeys === "strip") ;\n else {\n throw new Error(`Internal ZodObject error: invalid unknownKeys value.`);\n }\n } else {\n const catchall = this._def.catchall;\n for (const key of extraKeys) {\n const value = ctx.data[key];\n pairs.push({\n key: { status: "valid", value: key },\n value: catchall._parse(\n new ParseInputLazyPath(ctx, value, ctx.path, key)\n //, ctx.child(key), value, getParsedType(value)\n ),\n alwaysSet: key in ctx.data\n });\n }\n }\n if (ctx.common.async) {\n return Promise.resolve().then(async () => {\n const syncPairs = [];\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n syncPairs.push({\n key,\n value,\n alwaysSet: pair.alwaysSet\n });\n }\n return syncPairs;\n }).then((syncPairs) => {\n return ParseStatus.mergeObjectSync(status, syncPairs);\n });\n } else {\n return ParseStatus.mergeObjectSync(status, pairs);\n }\n }\n get shape() {\n return this._def.shape();\n }\n strict(message) {\n errorUtil.errToObj;\n return new ZodObject({\n ...this._def,\n unknownKeys: "strict",\n ...message !== void 0 ? {\n errorMap: (issue, ctx) => {\n var _a, _b, _c, _d;\n const defaultError = (_c = (_b = (_a = this._def).errorMap) === null || _b === void 0 ? void 0 : _b.call(_a, issue, ctx).message) !== null && _c !== void 0 ? _c : ctx.defaultError;\n if (issue.code === "unrecognized_keys")\n return {\n message: (_d = errorUtil.errToObj(message).message) !== null && _d !== void 0 ? _d : defaultError\n };\n return {\n message: defaultError\n };\n }\n } : {}\n });\n }\n strip() {\n return new ZodObject({\n ...this._def,\n unknownKeys: "strip"\n });\n }\n passthrough() {\n return new ZodObject({\n ...this._def,\n unknownKeys: "passthrough"\n });\n }\n // const AugmentFactory =\n // <Def extends ZodObjectDef>(def: Def) =>\n // <Augmentation extends ZodRawShape>(\n // augmentation: Augmentation\n // ): ZodObject<\n // extendShape<ReturnType<Def["shape"]>, Augmentation>,\n // Def["unknownKeys"],\n // Def["catchall"]\n // > => {\n // return new ZodObject({\n // ...def,\n // shape: () => ({\n // ...def.shape(),\n // ...augmentation,\n // }),\n // }) as any;\n // };\n extend(augmentation) {\n return new ZodObject({\n ...this._def,\n shape: () => ({\n ...this._def.shape(),\n ...augmentation\n })\n });\n }\n /**\n * Prior to zod@1.0.12 there was a bug in the\n * inferred type of merged objects. Please\n * upgrade if you are experiencing issues.\n */\n merge(merging) {\n const merged = new ZodObject({\n unknownKeys: merging._def.unknownKeys,\n catchall: merging._def.catchall,\n shape: () => ({\n ...this._def.shape(),\n ...merging._def.shape()\n }),\n typeName: ZodFirstPartyTypeKind.ZodObject\n });\n return merged;\n }\n // merge<\n // Incoming extends AnyZodObject,\n // Augmentation extends Incoming["shape"],\n // NewOutput extends {\n // [k in keyof Augmentation | keyof Output]: k extends keyof Augmentation\n // ? Augmentation[k]["_output"]\n // : k extends keyof Output\n // ? Output[k]\n // : never;\n // },\n // NewInput extends {\n // [k in keyof Augmentation | keyof Input]: k extends keyof Augmentation\n // ? Augmentation[k]["_input"]\n // : k extends keyof Input\n // ? Input[k]\n // : never;\n // }\n // >(\n // merging: Incoming\n // ): ZodObject<\n // extendShape<T, ReturnType<Incoming["_def"]["shape"]>>,\n // Incoming["_def"]["unknownKeys"],\n // Incoming["_def"]["catchall"],\n // NewOutput,\n // NewInput\n // > {\n // const merged: any = new ZodObject({\n // unknownKeys: merging._def.unknownKeys,\n // catchall: merging._def.catchall,\n // shape: () =>\n // objectUtil.mergeShapes(this._def.shape(), merging._def.shape()),\n // typeName: ZodFirstPartyTypeKind.ZodObject,\n // }) as any;\n // return merged;\n // }\n setKey(key, schema) {\n return this.augment({ [key]: schema });\n }\n // merge<Incoming extends AnyZodObject>(\n // merging: Incoming\n // ): //ZodObject<T & Incoming["_shape"], UnknownKeys, Catchall> = (merging) => {\n // ZodObject<\n // extendShape<T, ReturnType<Incoming["_def"]["shape"]>>,\n // Incoming["_def"]["unknownKeys"],\n // Incoming["_def"]["catchall"]\n // > {\n // // const mergedShape = objectUtil.mergeShapes(\n // // this._def.shape(),\n // // merging._def.shape()\n // // );\n // const merged: any = new ZodObject({\n // unknownKeys: merging._def.unknownKeys,\n // catchall: merging._def.catchall,\n // shape: () =>\n // objectUtil.mergeShapes(this._def.shape(), merging._def.shape()),\n // typeName: ZodFirstPartyTypeKind.ZodObject,\n // }) as any;\n // return merged;\n // }\n catchall(index) {\n return new ZodObject({\n ...this._def,\n catchall: index\n });\n }\n pick(mask) {\n const shape = {};\n util.objectKeys(mask).forEach((key) => {\n if (mask[key] && this.shape[key]) {\n shape[key] = this.shape[key];\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => shape\n });\n }\n omit(mask) {\n const shape = {};\n util.objectKeys(this.shape).forEach((key) => {\n if (!mask[key]) {\n shape[key] = this.shape[key];\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => shape\n });\n }\n /**\n * @deprecated\n */\n deepPartial() {\n return deepPartialify(this);\n }\n partial(mask) {\n const newShape = {};\n util.objectKeys(this.shape).forEach((key) => {\n const fieldSchema = this.shape[key];\n if (mask && !mask[key]) {\n newShape[key] = fieldSchema;\n } else {\n newShape[key] = fieldSchema.optional();\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => newShape\n });\n }\n required(mask) {\n const newShape = {};\n util.objectKeys(this.shape).forEach((key) => {\n if (mask && !mask[key]) {\n newShape[key] = this.shape[key];\n } else {\n const fieldSchema = this.shape[key];\n let newField = fieldSchema;\n while (newField instanceof ZodOptional) {\n newField = newField._def.innerType;\n }\n newShape[key] = newField;\n }\n });\n return new ZodObject({\n ...this._def,\n shape: () => newShape\n });\n }\n keyof() {\n return createZodEnum(util.objectKeys(this.shape));\n }\n }\n ZodObject.create = (shape, params) => {\n return new ZodObject({\n shape: () => shape,\n unknownKeys: "strip",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n ZodObject.strictCreate = (shape, params) => {\n return new ZodObject({\n shape: () => shape,\n unknownKeys: "strict",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n ZodObject.lazycreate = (shape, params) => {\n return new ZodObject({\n shape,\n unknownKeys: "strip",\n catchall: ZodNever.create(),\n typeName: ZodFirstPartyTypeKind.ZodObject,\n ...processCreateParams(params)\n });\n };\n class ZodUnion extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const options = this._def.options;\n function handleResults(results) {\n for (const result of results) {\n if (result.result.status === "valid") {\n return result.result;\n }\n }\n for (const result of results) {\n if (result.result.status === "dirty") {\n ctx.common.issues.push(...result.ctx.common.issues);\n return result.result;\n }\n }\n const unionErrors = results.map((result) => new ZodError(result.ctx.common.issues));\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union,\n unionErrors\n });\n return INVALID;\n }\n if (ctx.common.async) {\n return Promise.all(options.map(async (option) => {\n const childCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n },\n parent: null\n };\n return {\n result: await option._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: childCtx\n }),\n ctx: childCtx\n };\n })).then(handleResults);\n } else {\n let dirty = void 0;\n const issues = [];\n for (const option of options) {\n const childCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n },\n parent: null\n };\n const result = option._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: childCtx\n });\n if (result.status === "valid") {\n return result;\n } else if (result.status === "dirty" && !dirty) {\n dirty = { result, ctx: childCtx };\n }\n if (childCtx.common.issues.length) {\n issues.push(childCtx.common.issues);\n }\n }\n if (dirty) {\n ctx.common.issues.push(...dirty.ctx.common.issues);\n return dirty.result;\n }\n const unionErrors = issues.map((issues2) => new ZodError(issues2));\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union,\n unionErrors\n });\n return INVALID;\n }\n }\n get options() {\n return this._def.options;\n }\n }\n ZodUnion.create = (types, params) => {\n return new ZodUnion({\n options: types,\n typeName: ZodFirstPartyTypeKind.ZodUnion,\n ...processCreateParams(params)\n });\n };\n const getDiscriminator = (type) => {\n if (type instanceof ZodLazy) {\n return getDiscriminator(type.schema);\n } else if (type instanceof ZodEffects) {\n return getDiscriminator(type.innerType());\n } else if (type instanceof ZodLiteral) {\n return [type.value];\n } else if (type instanceof ZodEnum) {\n return type.options;\n } else if (type instanceof ZodNativeEnum) {\n return util.objectValues(type.enum);\n } else if (type instanceof ZodDefault) {\n return getDiscriminator(type._def.innerType);\n } else if (type instanceof ZodUndefined) {\n return [void 0];\n } else if (type instanceof ZodNull) {\n return [null];\n } else if (type instanceof ZodOptional) {\n return [void 0, ...getDiscriminator(type.unwrap())];\n } else if (type instanceof ZodNullable) {\n return [null, ...getDiscriminator(type.unwrap())];\n } else if (type instanceof ZodBranded) {\n return getDiscriminator(type.unwrap());\n } else if (type instanceof ZodReadonly) {\n return getDiscriminator(type.unwrap());\n } else if (type instanceof ZodCatch) {\n return getDiscriminator(type._def.innerType);\n } else {\n return [];\n }\n };\n class ZodDiscriminatedUnion extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.object) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const discriminator = this.discriminator;\n const discriminatorValue = ctx.data[discriminator];\n const option = this.optionsMap.get(discriminatorValue);\n if (!option) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_union_discriminator,\n options: Array.from(this.optionsMap.keys()),\n path: [discriminator]\n });\n return INVALID;\n }\n if (ctx.common.async) {\n return option._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n } else {\n return option._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n }\n }\n get discriminator() {\n return this._def.discriminator;\n }\n get options() {\n return this._def.options;\n }\n get optionsMap() {\n return this._def.optionsMap;\n }\n /**\n * The constructor of the discriminated union schema. Its behaviour is very similar to that of the normal z.union() constructor.\n * However, it only allows a union of objects, all of which need to share a discriminator property. This property must\n * have a different value for each object in the union.\n * @param discriminator the name of the discriminator property\n * @param types an array of object schemas\n * @param params\n */\n static create(discriminator, options, params) {\n const optionsMap = /* @__PURE__ */ new Map();\n for (const type of options) {\n const discriminatorValues = getDiscriminator(type.shape[discriminator]);\n if (!discriminatorValues.length) {\n throw new Error(`A discriminator value for key \\`${discriminator}\\` could not be extracted from all schema options`);\n }\n for (const value of discriminatorValues) {\n if (optionsMap.has(value)) {\n throw new Error(`Discriminator property ${String(discriminator)} has duplicate value ${String(value)}`);\n }\n optionsMap.set(value, type);\n }\n }\n return new ZodDiscriminatedUnion({\n typeName: ZodFirstPartyTypeKind.ZodDiscriminatedUnion,\n discriminator,\n options,\n optionsMap,\n ...processCreateParams(params)\n });\n }\n }\n function mergeValues(a2, b) {\n const aType = getParsedType(a2);\n const bType = getParsedType(b);\n if (a2 === b) {\n return { valid: true, data: a2 };\n } else if (aType === ZodParsedType.object && bType === ZodParsedType.object) {\n const bKeys = util.objectKeys(b);\n const sharedKeys = util.objectKeys(a2).filter((key) => bKeys.indexOf(key) !== -1);\n const newObj = { ...a2, ...b };\n for (const key of sharedKeys) {\n const sharedValue = mergeValues(a2[key], b[key]);\n if (!sharedValue.valid) {\n return { valid: false };\n }\n newObj[key] = sharedValue.data;\n }\n return { valid: true, data: newObj };\n } else if (aType === ZodParsedType.array && bType === ZodParsedType.array) {\n if (a2.length !== b.length) {\n return { valid: false };\n }\n const newArray = [];\n for (let index = 0; index < a2.length; index++) {\n const itemA = a2[index];\n const itemB = b[index];\n const sharedValue = mergeValues(itemA, itemB);\n if (!sharedValue.valid) {\n return { valid: false };\n }\n newArray.push(sharedValue.data);\n }\n return { valid: true, data: newArray };\n } else if (aType === ZodParsedType.date && bType === ZodParsedType.date && +a2 === +b) {\n return { valid: true, data: a2 };\n } else {\n return { valid: false };\n }\n }\n class ZodIntersection extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n const handleParsed = (parsedLeft, parsedRight) => {\n if (isAborted(parsedLeft) || isAborted(parsedRight)) {\n return INVALID;\n }\n const merged = mergeValues(parsedLeft.value, parsedRight.value);\n if (!merged.valid) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_intersection_types\n });\n return INVALID;\n }\n if (isDirty(parsedLeft) || isDirty(parsedRight)) {\n status.dirty();\n }\n return { status: status.value, value: merged.data };\n };\n if (ctx.common.async) {\n return Promise.all([\n this._def.left._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }),\n this._def.right._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n })\n ]).then(([left, right]) => handleParsed(left, right));\n } else {\n return handleParsed(this._def.left._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }), this._def.right._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n }));\n }\n }\n }\n ZodIntersection.create = (left, right, params) => {\n return new ZodIntersection({\n left,\n right,\n typeName: ZodFirstPartyTypeKind.ZodIntersection,\n ...processCreateParams(params)\n });\n };\n class ZodTuple extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.array) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.array,\n received: ctx.parsedType\n });\n return INVALID;\n }\n if (ctx.data.length < this._def.items.length) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: this._def.items.length,\n inclusive: true,\n exact: false,\n type: "array"\n });\n return INVALID;\n }\n const rest = this._def.rest;\n if (!rest && ctx.data.length > this._def.items.length) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: this._def.items.length,\n inclusive: true,\n exact: false,\n type: "array"\n });\n status.dirty();\n }\n const items = [...ctx.data].map((item, itemIndex) => {\n const schema = this._def.items[itemIndex] || this._def.rest;\n if (!schema)\n return null;\n return schema._parse(new ParseInputLazyPath(ctx, item, ctx.path, itemIndex));\n }).filter((x) => !!x);\n if (ctx.common.async) {\n return Promise.all(items).then((results) => {\n return ParseStatus.mergeArray(status, results);\n });\n } else {\n return ParseStatus.mergeArray(status, items);\n }\n }\n get items() {\n return this._def.items;\n }\n rest(rest) {\n return new ZodTuple({\n ...this._def,\n rest\n });\n }\n }\n ZodTuple.create = (schemas, params) => {\n if (!Array.isArray(schemas)) {\n throw new Error("You must pass an array of schemas to z.tuple([ ... ])");\n }\n return new ZodTuple({\n items: schemas,\n typeName: ZodFirstPartyTypeKind.ZodTuple,\n rest: null,\n ...processCreateParams(params)\n });\n };\n class ZodRecord extends ZodType {\n get keySchema() {\n return this._def.keyType;\n }\n get valueSchema() {\n return this._def.valueType;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.object) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.object,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const pairs = [];\n const keyType = this._def.keyType;\n const valueType = this._def.valueType;\n for (const key in ctx.data) {\n pairs.push({\n key: keyType._parse(new ParseInputLazyPath(ctx, key, ctx.path, key)),\n value: valueType._parse(new ParseInputLazyPath(ctx, ctx.data[key], ctx.path, key)),\n alwaysSet: key in ctx.data\n });\n }\n if (ctx.common.async) {\n return ParseStatus.mergeObjectAsync(status, pairs);\n } else {\n return ParseStatus.mergeObjectSync(status, pairs);\n }\n }\n get element() {\n return this._def.valueType;\n }\n static create(first, second, third) {\n if (second instanceof ZodType) {\n return new ZodRecord({\n keyType: first,\n valueType: second,\n typeName: ZodFirstPartyTypeKind.ZodRecord,\n ...processCreateParams(third)\n });\n }\n return new ZodRecord({\n keyType: ZodString.create(),\n valueType: first,\n typeName: ZodFirstPartyTypeKind.ZodRecord,\n ...processCreateParams(second)\n });\n }\n }\n class ZodMap extends ZodType {\n get keySchema() {\n return this._def.keyType;\n }\n get valueSchema() {\n return this._def.valueType;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.map) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.map,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const keyType = this._def.keyType;\n const valueType = this._def.valueType;\n const pairs = [...ctx.data.entries()].map(([key, value], index) => {\n return {\n key: keyType._parse(new ParseInputLazyPath(ctx, key, ctx.path, [index, "key"])),\n value: valueType._parse(new ParseInputLazyPath(ctx, value, ctx.path, [index, "value"]))\n };\n });\n if (ctx.common.async) {\n const finalMap = /* @__PURE__ */ new Map();\n return Promise.resolve().then(async () => {\n for (const pair of pairs) {\n const key = await pair.key;\n const value = await pair.value;\n if (key.status === "aborted" || value.status === "aborted") {\n return INVALID;\n }\n if (key.status === "dirty" || value.status === "dirty") {\n status.dirty();\n }\n finalMap.set(key.value, value.value);\n }\n return { status: status.value, value: finalMap };\n });\n } else {\n const finalMap = /* @__PURE__ */ new Map();\n for (const pair of pairs) {\n const key = pair.key;\n const value = pair.value;\n if (key.status === "aborted" || value.status === "aborted") {\n return INVALID;\n }\n if (key.status === "dirty" || value.status === "dirty") {\n status.dirty();\n }\n finalMap.set(key.value, value.value);\n }\n return { status: status.value, value: finalMap };\n }\n }\n }\n ZodMap.create = (keyType, valueType, params) => {\n return new ZodMap({\n valueType,\n keyType,\n typeName: ZodFirstPartyTypeKind.ZodMap,\n ...processCreateParams(params)\n });\n };\n class ZodSet extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.set) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.set,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const def = this._def;\n if (def.minSize !== null) {\n if (ctx.data.size < def.minSize.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_small,\n minimum: def.minSize.value,\n type: "set",\n inclusive: true,\n exact: false,\n message: def.minSize.message\n });\n status.dirty();\n }\n }\n if (def.maxSize !== null) {\n if (ctx.data.size > def.maxSize.value) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.too_big,\n maximum: def.maxSize.value,\n type: "set",\n inclusive: true,\n exact: false,\n message: def.maxSize.message\n });\n status.dirty();\n }\n }\n const valueType = this._def.valueType;\n function finalizeSet(elements2) {\n const parsedSet = /* @__PURE__ */ new Set();\n for (const element of elements2) {\n if (element.status === "aborted")\n return INVALID;\n if (element.status === "dirty")\n status.dirty();\n parsedSet.add(element.value);\n }\n return { status: status.value, value: parsedSet };\n }\n const elements = [...ctx.data.values()].map((item, i2) => valueType._parse(new ParseInputLazyPath(ctx, item, ctx.path, i2)));\n if (ctx.common.async) {\n return Promise.all(elements).then((elements2) => finalizeSet(elements2));\n } else {\n return finalizeSet(elements);\n }\n }\n min(minSize, message) {\n return new ZodSet({\n ...this._def,\n minSize: { value: minSize, message: errorUtil.toString(message) }\n });\n }\n max(maxSize, message) {\n return new ZodSet({\n ...this._def,\n maxSize: { value: maxSize, message: errorUtil.toString(message) }\n });\n }\n size(size, message) {\n return this.min(size, message).max(size, message);\n }\n nonempty(message) {\n return this.min(1, message);\n }\n }\n ZodSet.create = (valueType, params) => {\n return new ZodSet({\n valueType,\n minSize: null,\n maxSize: null,\n typeName: ZodFirstPartyTypeKind.ZodSet,\n ...processCreateParams(params)\n });\n };\n class ZodFunction extends ZodType {\n constructor() {\n super(...arguments);\n this.validate = this.implement;\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.function) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.function,\n received: ctx.parsedType\n });\n return INVALID;\n }\n function makeArgsIssue(args, error) {\n return makeIssue({\n data: args,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n ctx.schemaErrorMap,\n getErrorMap(),\n errorMap\n ].filter((x) => !!x),\n issueData: {\n code: ZodIssueCode.invalid_arguments,\n argumentsError: error\n }\n });\n }\n function makeReturnsIssue(returns, error) {\n return makeIssue({\n data: returns,\n path: ctx.path,\n errorMaps: [\n ctx.common.contextualErrorMap,\n ctx.schemaErrorMap,\n getErrorMap(),\n errorMap\n ].filter((x) => !!x),\n issueData: {\n code: ZodIssueCode.invalid_return_type,\n returnTypeError: error\n }\n });\n }\n const params = { errorMap: ctx.common.contextualErrorMap };\n const fn = ctx.data;\n if (this._def.returns instanceof ZodPromise) {\n const me = this;\n return OK(async function(...args) {\n const error = new ZodError([]);\n const parsedArgs = await me._def.args.parseAsync(args, params).catch((e2) => {\n error.addIssue(makeArgsIssue(args, e2));\n throw error;\n });\n const result = await Reflect.apply(fn, this, parsedArgs);\n const parsedReturns = await me._def.returns._def.type.parseAsync(result, params).catch((e2) => {\n error.addIssue(makeReturnsIssue(result, e2));\n throw error;\n });\n return parsedReturns;\n });\n } else {\n const me = this;\n return OK(function(...args) {\n const parsedArgs = me._def.args.safeParse(args, params);\n if (!parsedArgs.success) {\n throw new ZodError([makeArgsIssue(args, parsedArgs.error)]);\n }\n const result = Reflect.apply(fn, this, parsedArgs.data);\n const parsedReturns = me._def.returns.safeParse(result, params);\n if (!parsedReturns.success) {\n throw new ZodError([makeReturnsIssue(result, parsedReturns.error)]);\n }\n return parsedReturns.data;\n });\n }\n }\n parameters() {\n return this._def.args;\n }\n returnType() {\n return this._def.returns;\n }\n args(...items) {\n return new ZodFunction({\n ...this._def,\n args: ZodTuple.create(items).rest(ZodUnknown.create())\n });\n }\n returns(returnType) {\n return new ZodFunction({\n ...this._def,\n returns: returnType\n });\n }\n implement(func) {\n const validatedFunc = this.parse(func);\n return validatedFunc;\n }\n strictImplement(func) {\n const validatedFunc = this.parse(func);\n return validatedFunc;\n }\n static create(args, returns, params) {\n return new ZodFunction({\n args: args ? args : ZodTuple.create([]).rest(ZodUnknown.create()),\n returns: returns || ZodUnknown.create(),\n typeName: ZodFirstPartyTypeKind.ZodFunction,\n ...processCreateParams(params)\n });\n }\n }\n class ZodLazy extends ZodType {\n get schema() {\n return this._def.getter();\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const lazySchema = this._def.getter();\n return lazySchema._parse({ data: ctx.data, path: ctx.path, parent: ctx });\n }\n }\n ZodLazy.create = (getter, params) => {\n return new ZodLazy({\n getter,\n typeName: ZodFirstPartyTypeKind.ZodLazy,\n ...processCreateParams(params)\n });\n };\n class ZodLiteral extends ZodType {\n _parse(input) {\n if (input.data !== this._def.value) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_literal,\n expected: this._def.value\n });\n return INVALID;\n }\n return { status: "valid", value: input.data };\n }\n get value() {\n return this._def.value;\n }\n }\n ZodLiteral.create = (value, params) => {\n return new ZodLiteral({\n value,\n typeName: ZodFirstPartyTypeKind.ZodLiteral,\n ...processCreateParams(params)\n });\n };\n function createZodEnum(values, params) {\n return new ZodEnum({\n values,\n typeName: ZodFirstPartyTypeKind.ZodEnum,\n ...processCreateParams(params)\n });\n }\n class ZodEnum extends ZodType {\n constructor() {\n super(...arguments);\n _ZodEnum_cache.set(this, void 0);\n }\n _parse(input) {\n if (typeof input.data !== "string") {\n const ctx = this._getOrReturnCtx(input);\n const expectedValues = this._def.values;\n addIssueToContext(ctx, {\n expected: util.joinValues(expectedValues),\n received: ctx.parsedType,\n code: ZodIssueCode.invalid_type\n });\n return INVALID;\n }\n if (!__classPrivateFieldGet(this, _ZodEnum_cache)) {\n __classPrivateFieldSet(this, _ZodEnum_cache, new Set(this._def.values));\n }\n if (!__classPrivateFieldGet(this, _ZodEnum_cache).has(input.data)) {\n const ctx = this._getOrReturnCtx(input);\n const expectedValues = this._def.values;\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_enum_value,\n options: expectedValues\n });\n return INVALID;\n }\n return OK(input.data);\n }\n get options() {\n return this._def.values;\n }\n get enum() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n get Values() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n get Enum() {\n const enumValues = {};\n for (const val of this._def.values) {\n enumValues[val] = val;\n }\n return enumValues;\n }\n extract(values, newDef = this._def) {\n return ZodEnum.create(values, {\n ...this._def,\n ...newDef\n });\n }\n exclude(values, newDef = this._def) {\n return ZodEnum.create(this.options.filter((opt) => !values.includes(opt)), {\n ...this._def,\n ...newDef\n });\n }\n }\n _ZodEnum_cache = /* @__PURE__ */ new WeakMap();\n ZodEnum.create = createZodEnum;\n class ZodNativeEnum extends ZodType {\n constructor() {\n super(...arguments);\n _ZodNativeEnum_cache.set(this, void 0);\n }\n _parse(input) {\n const nativeEnumValues = util.getValidEnumValues(this._def.values);\n const ctx = this._getOrReturnCtx(input);\n if (ctx.parsedType !== ZodParsedType.string && ctx.parsedType !== ZodParsedType.number) {\n const expectedValues = util.objectValues(nativeEnumValues);\n addIssueToContext(ctx, {\n expected: util.joinValues(expectedValues),\n received: ctx.parsedType,\n code: ZodIssueCode.invalid_type\n });\n return INVALID;\n }\n if (!__classPrivateFieldGet(this, _ZodNativeEnum_cache)) {\n __classPrivateFieldSet(this, _ZodNativeEnum_cache, new Set(util.getValidEnumValues(this._def.values)));\n }\n if (!__classPrivateFieldGet(this, _ZodNativeEnum_cache).has(input.data)) {\n const expectedValues = util.objectValues(nativeEnumValues);\n addIssueToContext(ctx, {\n received: ctx.data,\n code: ZodIssueCode.invalid_enum_value,\n options: expectedValues\n });\n return INVALID;\n }\n return OK(input.data);\n }\n get enum() {\n return this._def.values;\n }\n }\n _ZodNativeEnum_cache = /* @__PURE__ */ new WeakMap();\n ZodNativeEnum.create = (values, params) => {\n return new ZodNativeEnum({\n values,\n typeName: ZodFirstPartyTypeKind.ZodNativeEnum,\n ...processCreateParams(params)\n });\n };\n class ZodPromise extends ZodType {\n unwrap() {\n return this._def.type;\n }\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n if (ctx.parsedType !== ZodParsedType.promise && ctx.common.async === false) {\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.promise,\n received: ctx.parsedType\n });\n return INVALID;\n }\n const promisified = ctx.parsedType === ZodParsedType.promise ? ctx.data : Promise.resolve(ctx.data);\n return OK(promisified.then((data) => {\n return this._def.type.parseAsync(data, {\n path: ctx.path,\n errorMap: ctx.common.contextualErrorMap\n });\n }));\n }\n }\n ZodPromise.create = (schema, params) => {\n return new ZodPromise({\n type: schema,\n typeName: ZodFirstPartyTypeKind.ZodPromise,\n ...processCreateParams(params)\n });\n };\n class ZodEffects extends ZodType {\n innerType() {\n return this._def.schema;\n }\n sourceType() {\n return this._def.schema._def.typeName === ZodFirstPartyTypeKind.ZodEffects ? this._def.schema.sourceType() : this._def.schema;\n }\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n const effect = this._def.effect || null;\n const checkCtx = {\n addIssue: (arg) => {\n addIssueToContext(ctx, arg);\n if (arg.fatal) {\n status.abort();\n } else {\n status.dirty();\n }\n },\n get path() {\n return ctx.path;\n }\n };\n checkCtx.addIssue = checkCtx.addIssue.bind(checkCtx);\n if (effect.type === "preprocess") {\n const processed = effect.transform(ctx.data, checkCtx);\n if (ctx.common.async) {\n return Promise.resolve(processed).then(async (processed2) => {\n if (status.value === "aborted")\n return INVALID;\n const result = await this._def.schema._parseAsync({\n data: processed2,\n path: ctx.path,\n parent: ctx\n });\n if (result.status === "aborted")\n return INVALID;\n if (result.status === "dirty")\n return DIRTY(result.value);\n if (status.value === "dirty")\n return DIRTY(result.value);\n return result;\n });\n } else {\n if (status.value === "aborted")\n return INVALID;\n const result = this._def.schema._parseSync({\n data: processed,\n path: ctx.path,\n parent: ctx\n });\n if (result.status === "aborted")\n return INVALID;\n if (result.status === "dirty")\n return DIRTY(result.value);\n if (status.value === "dirty")\n return DIRTY(result.value);\n return result;\n }\n }\n if (effect.type === "refinement") {\n const executeRefinement = (acc) => {\n const result = effect.refinement(acc, checkCtx);\n if (ctx.common.async) {\n return Promise.resolve(result);\n }\n if (result instanceof Promise) {\n throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");\n }\n return acc;\n };\n if (ctx.common.async === false) {\n const inner = this._def.schema._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inner.status === "aborted")\n return INVALID;\n if (inner.status === "dirty")\n status.dirty();\n executeRefinement(inner.value);\n return { status: status.value, value: inner.value };\n } else {\n return this._def.schema._parseAsync({ data: ctx.data, path: ctx.path, parent: ctx }).then((inner) => {\n if (inner.status === "aborted")\n return INVALID;\n if (inner.status === "dirty")\n status.dirty();\n return executeRefinement(inner.value).then(() => {\n return { status: status.value, value: inner.value };\n });\n });\n }\n }\n if (effect.type === "transform") {\n if (ctx.common.async === false) {\n const base = this._def.schema._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (!isValid(base))\n return base;\n const result = effect.transform(base.value, checkCtx);\n if (result instanceof Promise) {\n throw new Error(`Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.`);\n }\n return { status: status.value, value: result };\n } else {\n return this._def.schema._parseAsync({ data: ctx.data, path: ctx.path, parent: ctx }).then((base) => {\n if (!isValid(base))\n return base;\n return Promise.resolve(effect.transform(base.value, checkCtx)).then((result) => ({ status: status.value, value: result }));\n });\n }\n }\n util.assertNever(effect);\n }\n }\n ZodEffects.create = (schema, effect, params) => {\n return new ZodEffects({\n schema,\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n effect,\n ...processCreateParams(params)\n });\n };\n ZodEffects.createWithPreprocess = (preprocess, schema, params) => {\n return new ZodEffects({\n schema,\n effect: { type: "preprocess", transform: preprocess },\n typeName: ZodFirstPartyTypeKind.ZodEffects,\n ...processCreateParams(params)\n });\n };\n class ZodOptional extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType === ZodParsedType.undefined) {\n return OK(void 0);\n }\n return this._def.innerType._parse(input);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodOptional.create = (type, params) => {\n return new ZodOptional({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodOptional,\n ...processCreateParams(params)\n });\n };\n class ZodNullable extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType === ZodParsedType.null) {\n return OK(null);\n }\n return this._def.innerType._parse(input);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodNullable.create = (type, params) => {\n return new ZodNullable({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodNullable,\n ...processCreateParams(params)\n });\n };\n class ZodDefault extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n let data = ctx.data;\n if (ctx.parsedType === ZodParsedType.undefined) {\n data = this._def.defaultValue();\n }\n return this._def.innerType._parse({\n data,\n path: ctx.path,\n parent: ctx\n });\n }\n removeDefault() {\n return this._def.innerType;\n }\n }\n ZodDefault.create = (type, params) => {\n return new ZodDefault({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodDefault,\n defaultValue: typeof params.default === "function" ? params.default : () => params.default,\n ...processCreateParams(params)\n });\n };\n class ZodCatch extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const newCtx = {\n ...ctx,\n common: {\n ...ctx.common,\n issues: []\n }\n };\n const result = this._def.innerType._parse({\n data: newCtx.data,\n path: newCtx.path,\n parent: {\n ...newCtx\n }\n });\n if (isAsync(result)) {\n return result.then((result2) => {\n return {\n status: "valid",\n value: result2.status === "valid" ? result2.value : this._def.catchValue({\n get error() {\n return new ZodError(newCtx.common.issues);\n },\n input: newCtx.data\n })\n };\n });\n } else {\n return {\n status: "valid",\n value: result.status === "valid" ? result.value : this._def.catchValue({\n get error() {\n return new ZodError(newCtx.common.issues);\n },\n input: newCtx.data\n })\n };\n }\n }\n removeCatch() {\n return this._def.innerType;\n }\n }\n ZodCatch.create = (type, params) => {\n return new ZodCatch({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodCatch,\n catchValue: typeof params.catch === "function" ? params.catch : () => params.catch,\n ...processCreateParams(params)\n });\n };\n class ZodNaN extends ZodType {\n _parse(input) {\n const parsedType = this._getType(input);\n if (parsedType !== ZodParsedType.nan) {\n const ctx = this._getOrReturnCtx(input);\n addIssueToContext(ctx, {\n code: ZodIssueCode.invalid_type,\n expected: ZodParsedType.nan,\n received: ctx.parsedType\n });\n return INVALID;\n }\n return { status: "valid", value: input.data };\n }\n }\n ZodNaN.create = (params) => {\n return new ZodNaN({\n typeName: ZodFirstPartyTypeKind.ZodNaN,\n ...processCreateParams(params)\n });\n };\n const BRAND = Symbol("zod_brand");\n class ZodBranded extends ZodType {\n _parse(input) {\n const { ctx } = this._processInputParams(input);\n const data = ctx.data;\n return this._def.type._parse({\n data,\n path: ctx.path,\n parent: ctx\n });\n }\n unwrap() {\n return this._def.type;\n }\n }\n class ZodPipeline extends ZodType {\n _parse(input) {\n const { status, ctx } = this._processInputParams(input);\n if (ctx.common.async) {\n const handleAsync = async () => {\n const inResult = await this._def.in._parseAsync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inResult.status === "aborted")\n return INVALID;\n if (inResult.status === "dirty") {\n status.dirty();\n return DIRTY(inResult.value);\n } else {\n return this._def.out._parseAsync({\n data: inResult.value,\n path: ctx.path,\n parent: ctx\n });\n }\n };\n return handleAsync();\n } else {\n const inResult = this._def.in._parseSync({\n data: ctx.data,\n path: ctx.path,\n parent: ctx\n });\n if (inResult.status === "aborted")\n return INVALID;\n if (inResult.status === "dirty") {\n status.dirty();\n return {\n status: "dirty",\n value: inResult.value\n };\n } else {\n return this._def.out._parseSync({\n data: inResult.value,\n path: ctx.path,\n parent: ctx\n });\n }\n }\n }\n static create(a2, b) {\n return new ZodPipeline({\n in: a2,\n out: b,\n typeName: ZodFirstPartyTypeKind.ZodPipeline\n });\n }\n }\n class ZodReadonly extends ZodType {\n _parse(input) {\n const result = this._def.innerType._parse(input);\n const freeze = (data) => {\n if (isValid(data)) {\n data.value = Object.freeze(data.value);\n }\n return data;\n };\n return isAsync(result) ? result.then((data) => freeze(data)) : freeze(result);\n }\n unwrap() {\n return this._def.innerType;\n }\n }\n ZodReadonly.create = (type, params) => {\n return new ZodReadonly({\n innerType: type,\n typeName: ZodFirstPartyTypeKind.ZodReadonly,\n ...processCreateParams(params)\n });\n };\n function cleanParams(params, data) {\n const p = typeof params === "function" ? params(data) : typeof params === "string" ? { message: params } : params;\n const p2 = typeof p === "string" ? { message: p } : p;\n return p2;\n }\n function custom(check, _params = {}, fatal) {\n if (check)\n return ZodAny.create().superRefine((data, ctx) => {\n var _a, _b;\n const r2 = check(data);\n if (r2 instanceof Promise) {\n return r2.then((r3) => {\n var _a2, _b2;\n if (!r3) {\n const params = cleanParams(_params, data);\n const _fatal = (_b2 = (_a2 = params.fatal) !== null && _a2 !== void 0 ? _a2 : fatal) !== null && _b2 !== void 0 ? _b2 : true;\n ctx.addIssue({ code: "custom", ...params, fatal: _fatal });\n }\n });\n }\n if (!r2) {\n const params = cleanParams(_params, data);\n const _fatal = (_b = (_a = params.fatal) !== null && _a !== void 0 ? _a : fatal) !== null && _b !== void 0 ? _b : true;\n ctx.addIssue({ code: "custom", ...params, fatal: _fatal });\n }\n return;\n });\n return ZodAny.create();\n }\n const late = {\n object: ZodObject.lazycreate\n };\n var ZodFirstPartyTypeKind;\n (function(ZodFirstPartyTypeKind2) {\n ZodFirstPartyTypeKind2["ZodString"] = "ZodString";\n ZodFirstPartyTypeKind2["ZodNumber"] = "ZodNumber";\n ZodFirstPartyTypeKind2["ZodNaN"] = "ZodNaN";\n ZodFirstPartyTypeKind2["ZodBigInt"] = "ZodBigInt";\n ZodFirstPartyTypeKind2["ZodBoolean"] = "ZodBoolean";\n ZodFirstPartyTypeKind2["ZodDate"] = "ZodDate";\n ZodFirstPartyTypeKind2["ZodSymbol"] = "ZodSymbol";\n ZodFirstPartyTypeKind2["ZodUndefined"] = "ZodUndefined";\n ZodFirstPartyTypeKind2["ZodNull"] = "ZodNull";\n ZodFirstPartyTypeKind2["ZodAny"] = "ZodAny";\n ZodFirstPartyTypeKind2["ZodUnknown"] = "ZodUnknown";\n ZodFirstPartyTypeKind2["ZodNever"] = "ZodNever";\n ZodFirstPartyTypeKind2["ZodVoid"] = "ZodVoid";\n ZodFirstPartyTypeKind2["ZodArray"] = "ZodArray";\n ZodFirstPartyTypeKind2["ZodObject"] = "ZodObject";\n ZodFirstPartyTypeKind2["ZodUnion"] = "ZodUnion";\n ZodFirstPartyTypeKind2["ZodDiscriminatedUnion"] = "ZodDiscriminatedUnion";\n ZodFirstPartyTypeKind2["ZodIntersection"] = "ZodIntersection";\n ZodFirstPartyTypeKind2["ZodTuple"] = "ZodTuple";\n ZodFirstPartyTypeKind2["ZodRecord"] = "ZodRecord";\n ZodFirstPartyTypeKind2["ZodMap"] = "ZodMap";\n ZodFirstPartyTypeKind2["ZodSet"] = "ZodSet";\n ZodFirstPartyTypeKind2["ZodFunction"] = "ZodFunction";\n ZodFirstPartyTypeKind2["ZodLazy"] = "ZodLazy";\n ZodFirstPartyTypeKind2["ZodLiteral"] = "ZodLiteral";\n ZodFirstPartyTypeKind2["ZodEnum"] = "ZodEnum";\n ZodFirstPartyTypeKind2["ZodEffects"] = "ZodEffects";\n ZodFirstPartyTypeKind2["ZodNativeEnum"] = "ZodNativeEnum";\n ZodFirstPartyTypeKind2["ZodOptional"] = "ZodOptional";\n ZodFirstPartyTypeKind2["ZodNullable"] = "ZodNullable";\n ZodFirstPartyTypeKind2["ZodDefault"] = "ZodDefault";\n ZodFirstPartyTypeKind2["ZodCatch"] = "ZodCatch";\n ZodFirstPartyTypeKind2["ZodPromise"] = "ZodPromise";\n ZodFirstPartyTypeKind2["ZodBranded"] = "ZodBranded";\n ZodFirstPartyTypeKind2["ZodPipeline"] = "ZodPipeline";\n ZodFirstPartyTypeKind2["ZodReadonly"] = "ZodReadonly";\n })(ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {}));\n const instanceOfType = (cls, params = {\n message: `Input not instance of ${cls.name}`\n }) => custom((data) => data instanceof cls, params);\n const stringType = ZodString.create;\n const numberType = ZodNumber.create;\n const nanType = ZodNaN.create;\n const bigIntType = ZodBigInt.create;\n const booleanType = ZodBoolean.create;\n const dateType = ZodDate.create;\n const symbolType = ZodSymbol.create;\n const undefinedType = ZodUndefined.create;\n const nullType = ZodNull.create;\n const anyType = ZodAny.create;\n const unknownType = ZodUnknown.create;\n const neverType = ZodNever.create;\n const voidType = ZodVoid.create;\n const arrayType = ZodArray.create;\n const objectType = ZodObject.create;\n const strictObjectType = ZodObject.strictCreate;\n const unionType = ZodUnion.create;\n const discriminatedUnionType = ZodDiscriminatedUnion.create;\n const intersectionType = ZodIntersection.create;\n const tupleType = ZodTuple.create;\n const recordType = ZodRecord.create;\n const mapType = ZodMap.create;\n const setType = ZodSet.create;\n const functionType = ZodFunction.create;\n const lazyType = ZodLazy.create;\n const literalType = ZodLiteral.create;\n const enumType = ZodEnum.create;\n const nativeEnumType = ZodNativeEnum.create;\n const promiseType = ZodPromise.create;\n const effectsType = ZodEffects.create;\n const optionalType = ZodOptional.create;\n const nullableType = ZodNullable.create;\n const preprocessType = ZodEffects.createWithPreprocess;\n const pipelineType = ZodPipeline.create;\n const ostring = () => stringType().optional();\n const onumber = () => numberType().optional();\n const oboolean = () => booleanType().optional();\n const coerce = {\n string: (arg) => ZodString.create({ ...arg, coerce: true }),\n number: (arg) => ZodNumber.create({ ...arg, coerce: true }),\n boolean: (arg) => ZodBoolean.create({\n ...arg,\n coerce: true\n }),\n bigint: (arg) => ZodBigInt.create({ ...arg, coerce: true }),\n date: (arg) => ZodDate.create({ ...arg, coerce: true })\n };\n const NEVER = INVALID;\n var z$1 = /* @__PURE__ */ Object.freeze({\n __proto__: null,\n defaultErrorMap: errorMap,\n setErrorMap,\n getErrorMap,\n makeIssue,\n EMPTY_PATH,\n addIssueToContext,\n ParseStatus,\n INVALID,\n DIRTY,\n OK,\n isAborted,\n isDirty,\n isValid,\n isAsync,\n get util() {\n return util;\n },\n get objectUtil() {\n return objectUtil;\n },\n ZodParsedType,\n getParsedType,\n ZodType,\n datetimeRegex,\n ZodString,\n ZodNumber,\n ZodBigInt,\n ZodBoolean,\n ZodDate,\n ZodSymbol,\n ZodUndefined,\n ZodNull,\n ZodAny,\n ZodUnknown,\n ZodNever,\n ZodVoid,\n ZodArray,\n ZodObject,\n ZodUnion,\n ZodDiscriminatedUnion,\n ZodIntersection,\n ZodTuple,\n ZodRecord,\n ZodMap,\n ZodSet,\n ZodFunction,\n ZodLazy,\n ZodLiteral,\n ZodEnum,\n ZodNativeEnum,\n ZodPromise,\n ZodEffects,\n ZodTransformer: ZodEffects,\n ZodOptional,\n ZodNullable,\n ZodDefault,\n ZodCatch,\n ZodNaN,\n BRAND,\n ZodBranded,\n ZodPipeline,\n ZodReadonly,\n custom,\n Schema: ZodType,\n ZodSchema: ZodType,\n late,\n get ZodFirstPartyTypeKind() {\n return ZodFirstPartyTypeKind;\n },\n coerce,\n any: anyType,\n array: arrayType,\n bigint: bigIntType,\n boolean: booleanType,\n date: dateType,\n discriminatedUnion: discriminatedUnionType,\n effect: effectsType,\n "enum": enumType,\n "function": functionType,\n "instanceof": instanceOfType,\n intersection: intersectionType,\n lazy: lazyType,\n literal: literalType,\n map: mapType,\n nan: nanType,\n nativeEnum: nativeEnumType,\n never: neverType,\n "null": nullType,\n nullable: nullableType,\n number: numberType,\n object: objectType,\n oboolean,\n onumber,\n optional: optionalType,\n ostring,\n pipeline: pipelineType,\n preprocess: preprocessType,\n promise: promiseType,\n record: recordType,\n set: setType,\n strictObject: strictObjectType,\n string: stringType,\n symbol: symbolType,\n transformer: effectsType,\n tuple: tupleType,\n "undefined": undefinedType,\n union: unionType,\n unknown: unknownType,\n "void": voidType,\n NEVER,\n ZodIssueCode,\n quotelessJson,\n ZodError\n });\n z$1.object({\n nucleotideSequences: z$1.array(\n z$1.object({\n name: z$1.string(),\n sequence: z$1.string()\n })\n ),\n genes: z$1.array(\n z$1.object({\n name: z$1.string(),\n sequence: z$1.string()\n })\n )\n });\n const orderByType = z$1.enum(["ascending", "descending"]);\n const orderBy = z$1.object({\n field: z$1.string(),\n type: orderByType\n });\n const lapisBaseRequest = z$1.object({\n limit: z$1.number().optional(),\n offset: z$1.number().optional(),\n fields: z$1.array(z$1.string()).optional(),\n orderBy: z$1.array(orderBy).optional()\n }).catchall(z$1.union([z$1.boolean(), z$1.undefined(), z$1.string(), z$1.number(), z$1.null(), z$1.array(z$1.string())]));\n lapisBaseRequest.extend({ minProportion: z$1.number().optional() });\n const mutationProportionCount = z$1.object({\n mutation: z$1.string(),\n proportion: z$1.number(),\n count: z$1.number(),\n sequenceName: z$1.union([z$1.string(), z$1.null()]),\n mutationFrom: z$1.string(),\n mutationTo: z$1.string(),\n position: z$1.number()\n });\n const mutationsResponse = makeLapisResponse(z$1.array(mutationProportionCount));\n const insertionCount = z$1.object({\n insertion: z$1.string(),\n count: z$1.number(),\n insertedSymbols: z$1.string(),\n position: z$1.number(),\n sequenceName: z$1.union([z$1.string(), z$1.null()])\n });\n makeLapisResponse(z$1.array(insertionCount));\n const baseResponseValueSchema = z$1.union([z$1.string(), z$1.number(), z$1.boolean(), z$1.null()]);\n const aggregatedItem = z$1.object({ count: z$1.number() }).catchall(baseResponseValueSchema);\n const aggregatedResponse = makeLapisResponse(z$1.array(aggregatedItem));\n const detailsItem = z$1.object({}).catchall(baseResponseValueSchema);\n makeLapisResponse(z$1.array(detailsItem));\n function makeLapisResponse(data) {\n return z$1.object({\n data\n });\n }\n const problemDetail = z$1.object({\n title: z$1.string().optional(),\n status: z$1.number(),\n detail: z$1.string().optional(),\n type: z$1.string(),\n instance: z$1.string().optional()\n });\n const lapisError = z$1.object({\n error: problemDetail\n });\n class UnknownLapisError extends Error {\n constructor(message, status, requestedData) {\n super(message);\n this.status = status;\n this.requestedData = requestedData;\n this.name = "UnknownLapisError";\n }\n }\n class LapisError extends Error {\n constructor(message, status, problemDetail2, requestedData) {\n super(message);\n this.status = status;\n this.problemDetail = problemDetail2;\n this.requestedData = requestedData;\n this.name = "LapisError";\n }\n }\n async function fetchAggregated(lapisUrl, body, signal) {\n const response = await callLapis(\n aggregatedEndpoint(lapisUrl),\n {\n method: "POST",\n headers: {\n "Content-Type": "application/json"\n },\n body: JSON.stringify(body),\n signal\n },\n "aggregated data"\n );\n return aggregatedResponse.parse(await response.json());\n }\n async function fetchSubstitutionsOrDeletions(lapisUrl, body, sequenceType, signal) {\n const response = await callLapis(\n substitutionsOrDeletionsEndpoint(lapisUrl, sequenceType),\n {\n method: "POST",\n headers: {\n "Content-Type": "application/json"\n },\n body: JSON.stringify(body),\n signal\n },\n `${sequenceType} mutations`\n );\n return mutationsResponse.parse(await response.json());\n }\n async function callLapis(input, init, requestedDataName) {\n try {\n const response = await fetch(input, init);\n await handleErrors(response, requestedDataName);\n return response;\n } catch (error) {\n const message = error instanceof Error ? error.message : `${error}`;\n throw new UnknownLapisError(`Failed to connect to LAPIS: ${message}`, 500, requestedDataName);\n }\n }\n const handleErrors = async (response, requestedData) => {\n if (!response.ok) {\n if (response.status >= 400 && response.status < 500) {\n const json = await response.json();\n const lapisErrorResult = lapisError.safeParse(json);\n if (lapisErrorResult.success) {\n throw new LapisError(\n response.statusText + lapisErrorResult.data.error.detail,\n response.status,\n lapisErrorResult.data.error,\n requestedData\n );\n }\n const problemDetailResult = problemDetail.safeParse(json);\n if (problemDetailResult.success) {\n throw new LapisError(\n response.statusText + problemDetailResult.data.detail,\n response.status,\n problemDetailResult.data,\n requestedData\n );\n }\n throw new UnknownLapisError(\n `${response.statusText}: ${JSON.stringify(json)}`,\n response.status,\n requestedData\n );\n }\n throw new UnknownLapisError(`${response.statusText}: ${response.status}`, response.status, requestedData);\n }\n };\n const aggregatedEndpoint = (lapisUrl) => `${lapisUrl}/sample/aggregated`;\n const substitutionsOrDeletionsEndpoint = (lapisUrl, sequenceType) => {\n return sequenceType === "amino acid" ? `${lapisUrl}/sample/aminoAcidMutations` : `${lapisUrl}/sample/nucleotideMutations`;\n };\n class FetchAggregatedOperator {\n constructor(filter, fields = []) {\n this.filter = filter;\n this.fields = fields;\n }\n async evaluate(lapisUrl, signal) {\n const aggregatedResponse2 = (await fetchAggregated(\n lapisUrl,\n {\n ...this.filter,\n fields: this.fields\n },\n signal\n )).data;\n if (isFieldsArrayWithCount(aggregatedResponse2)) {\n return {\n content: aggregatedResponse2\n };\n }\n throw new Error("Aggregated response does not have count");\n }\n }\n function isFieldsArrayWithCount(data) {\n return data.every((item) => typeof item === "object" && "count" in item && typeof item.count === "number");\n }\n class GroupByOperator {\n constructor(child, field, aggregate) {\n this.child = child;\n this.field = field;\n this.aggregate = aggregate;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n const grouped = /* @__PURE__ */ new Map();\n for (const row of childEvaluated.content) {\n const key = row[this.field];\n if (!grouped.has(key)) {\n grouped.set(key, []);\n }\n grouped.get(key).push(row);\n }\n const result = new Array();\n for (const [, values] of grouped) {\n result.push(this.aggregate(values));\n }\n return {\n content: result\n };\n }\n }\n class GroupByAndSumOperator extends GroupByOperator {\n constructor(child, groupByField, sumField) {\n super(child, groupByField, (values) => {\n let n = 0;\n for (const value of values) {\n n += value[sumField];\n }\n return {\n [groupByField]: values[0][groupByField],\n [sumField]: n\n };\n });\n }\n }\n class MapOperator {\n constructor(child, func) {\n this.child = child;\n this.func = func;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n return {\n content: childEvaluated.content.map(this.func)\n };\n }\n }\n class RenameFieldOperator extends MapOperator {\n constructor(child, oldFieldName, newFieldName) {\n super(\n child,\n (value) => ({\n ...value,\n [newFieldName]: value[oldFieldName]\n })\n );\n }\n }\n class SortOperator {\n constructor(child, compareFn) {\n this.child = child;\n this.compareFn = compareFn;\n }\n async evaluate(lapis, signal) {\n const childEvaluated = await this.child.evaluate(lapis, signal);\n return {\n content: childEvaluated.content.sort(this.compareFn)\n };\n }\n }\n var SECONDS_A_MINUTE = 60;\n var SECONDS_A_HOUR = SECONDS_A_MINUTE * 60;\n var SECONDS_A_DAY = SECONDS_A_HOUR * 24;\n var SECONDS_A_WEEK = SECONDS_A_DAY * 7;\n var MILLISECONDS_A_SECOND = 1e3;\n var MILLISECONDS_A_MINUTE = SECONDS_A_MINUTE * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_HOUR = SECONDS_A_HOUR * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_DAY = SECONDS_A_DAY * MILLISECONDS_A_SECOND;\n var MILLISECONDS_A_WEEK = SECONDS_A_WEEK * MILLISECONDS_A_SECOND;\n var MS = "millisecond";\n var S = "second";\n var MIN = "minute";\n var H = "hour";\n var D = "day";\n var W = "week";\n var M = "month";\n var Q = "quarter";\n var Y = "year";\n var DATE = "date";\n var FORMAT_DEFAULT = "YYYY-MM-DDTHH:mm:ssZ";\n var INVALID_DATE_STRING = "Invalid Date";\n var REGEX_PARSE = /^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/;\n var REGEX_FORMAT = /\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g;\n var en = {\n name: "en",\n weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),\n months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"),\n ordinal: function ordinal(n) {\n var s2 = ["th", "st", "nd", "rd"];\n var v2 = n % 100;\n return "[" + n + (s2[(v2 - 20) % 10] || s2[v2] || s2[0]) + "]";\n }\n };\n var padStart = function padStart2(string, length, pad) {\n var s2 = String(string);\n if (!s2 || s2.length >= length) return string;\n return "" + Array(length + 1 - s2.length).join(pad) + string;\n };\n var padZoneStr = function padZoneStr2(instance) {\n var negMinutes = -instance.utcOffset();\n var minutes = Math.abs(negMinutes);\n var hourOffset = Math.floor(minutes / 60);\n var minuteOffset = minutes % 60;\n return (negMinutes <= 0 ? "+" : "-") + padStart(hourOffset, 2, "0") + ":" + padStart(minuteOffset, 2, "0");\n };\n var monthDiff = function monthDiff2(a2, b) {\n if (a2.date() < b.date()) return -monthDiff2(b, a2);\n var wholeMonthDiff = (b.year() - a2.year()) * 12 + (b.month() - a2.month());\n var anchor = a2.clone().add(wholeMonthDiff, M);\n var c2 = b - anchor < 0;\n var anchor2 = a2.clone().add(wholeMonthDiff + (c2 ? -1 : 1), M);\n return +(-(wholeMonthDiff + (b - anchor) / (c2 ? anchor - anchor2 : anchor2 - anchor)) || 0);\n };\n var absFloor = function absFloor2(n) {\n return n < 0 ? Math.ceil(n) || 0 : Math.floor(n);\n };\n var prettyUnit = function prettyUnit2(u2) {\n var special = {\n M,\n y: Y,\n w: W,\n d: D,\n D: DATE,\n h: H,\n m: MIN,\n s: S,\n ms: MS,\n Q\n };\n return special[u2] || String(u2 || "").toLowerCase().replace(/s$/, "");\n };\n var isUndefined = function isUndefined2(s2) {\n return s2 === void 0;\n };\n var U = {\n s: padStart,\n z: padZoneStr,\n m: monthDiff,\n a: absFloor,\n p: prettyUnit,\n u: isUndefined\n };\n var L = "en";\n var Ls = {};\n Ls[L] = en;\n var IS_DAYJS = "$isDayjsObject";\n var isDayjs = function isDayjs2(d) {\n return d instanceof Dayjs || !!(d && d[IS_DAYJS]);\n };\n var parseLocale = function parseLocale2(preset, object, isLocal) {\n var l2;\n if (!preset) return L;\n if (typeof preset === "string") {\n var presetLower = preset.toLowerCase();\n if (Ls[presetLower]) {\n l2 = presetLower;\n }\n if (object) {\n Ls[presetLower] = object;\n l2 = presetLower;\n }\n var presetSplit = preset.split("-");\n if (!l2 && presetSplit.length > 1) {\n return parseLocale2(presetSplit[0]);\n }\n } else {\n var name = preset.name;\n Ls[name] = preset;\n l2 = name;\n }\n if (!isLocal && l2) L = l2;\n return l2 || !isLocal && L;\n };\n var dayjs = function dayjs2(date, c2) {\n if (isDayjs(date)) {\n return date.clone();\n }\n var cfg = typeof c2 === "object" ? c2 : {};\n cfg.date = date;\n cfg.args = arguments;\n return new Dayjs(cfg);\n };\n var wrapper = function wrapper2(date, instance) {\n return dayjs(date, {\n locale: instance.$L,\n utc: instance.$u,\n x: instance.$x,\n $offset: instance.$offset\n // todo: refactor; do not use this.$offset in you code\n });\n };\n var Utils = U;\n Utils.l = parseLocale;\n Utils.i = isDayjs;\n Utils.w = wrapper;\n var parseDate = function parseDate2(cfg) {\n var date = cfg.date, utc = cfg.utc;\n if (date === null) return /* @__PURE__ */ new Date(NaN);\n if (Utils.u(date)) return /* @__PURE__ */ new Date();\n if (date instanceof Date) return new Date(date);\n if (typeof date === "string" && !/Z$/i.test(date)) {\n var d = date.match(REGEX_PARSE);\n if (d) {\n var m2 = d[2] - 1 || 0;\n var ms = (d[7] || "0").substring(0, 3);\n if (utc) {\n return new Date(Date.UTC(d[1], m2, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms));\n }\n return new Date(d[1], m2, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms);\n }\n }\n return new Date(date);\n };\n var Dayjs = /* @__PURE__ */ function() {\n function Dayjs2(cfg) {\n this.$L = parseLocale(cfg.locale, null, true);\n this.parse(cfg);\n this.$x = this.$x || cfg.x || {};\n this[IS_DAYJS] = true;\n }\n var _proto = Dayjs2.prototype;\n _proto.parse = function parse(cfg) {\n this.$d = parseDate(cfg);\n this.init();\n };\n _proto.init = function init() {\n var $d = this.$d;\n this.$y = $d.getFullYear();\n this.$M = $d.getMonth();\n this.$D = $d.getDate();\n this.$W = $d.getDay();\n this.$H = $d.getHours();\n this.$m = $d.getMinutes();\n this.$s = $d.getSeconds();\n this.$ms = $d.getMilliseconds();\n };\n _proto.$utils = function $utils() {\n return Utils;\n };\n _proto.isValid = function isValid2() {\n return !(this.$d.toString() === INVALID_DATE_STRING);\n };\n _proto.isSame = function isSame(that, units) {\n var other = dayjs(that);\n return this.startOf(units) <= other && other <= this.endOf(units);\n };\n _proto.isAfter = function isAfter(that, units) {\n return dayjs(that) < this.startOf(units);\n };\n _proto.isBefore = function isBefore(that, units) {\n return this.endOf(units) < dayjs(that);\n };\n _proto.$g = function $g(input, get, set) {\n if (Utils.u(input)) return this[get];\n return this.set(set, input);\n };\n _proto.unix = function unix() {\n return Math.floor(this.valueOf() / 1e3);\n };\n _proto.valueOf = function valueOf() {\n return this.$d.getTime();\n };\n _proto.startOf = function startOf(units, _startOf) {\n var _this = this;\n var isStartOf = !Utils.u(_startOf) ? _startOf : true;\n var unit = Utils.p(units);\n var instanceFactory = function instanceFactory2(d, m2) {\n var ins = Utils.w(_this.$u ? Date.UTC(_this.$y, m2, d) : new Date(_this.$y, m2, d), _this);\n return isStartOf ? ins : ins.endOf(D);\n };\n var instanceFactorySet = function instanceFactorySet2(method, slice) {\n var argumentStart = [0, 0, 0, 0];\n var argumentEnd = [23, 59, 59, 999];\n return Utils.w(_this.toDate()[method].apply(\n // eslint-disable-line prefer-spread\n _this.toDate("s"),\n (isStartOf ? argumentStart : argumentEnd).slice(slice)\n ), _this);\n };\n var $W = this.$W, $M = this.$M, $D = this.$D;\n var utcPad = "set" + (this.$u ? "UTC" : "");\n switch (unit) {\n case Y:\n return isStartOf ? instanceFactory(1, 0) : instanceFactory(31, 11);\n case M:\n return isStartOf ? instanceFactory(1, $M) : instanceFactory(0, $M + 1);\n case W: {\n var weekStart = this.$locale().weekStart || 0;\n var gap = ($W < weekStart ? $W + 7 : $W) - weekStart;\n return instanceFactory(isStartOf ? $D - gap : $D + (6 - gap), $M);\n }\n case D:\n case DATE:\n return instanceFactorySet(utcPad + "Hours", 0);\n case H:\n return instanceFactorySet(utcPad + "Minutes", 1);\n case MIN:\n return instanceFactorySet(utcPad + "Seconds", 2);\n case S:\n return instanceFactorySet(utcPad + "Milliseconds", 3);\n default:\n return this.clone();\n }\n };\n _proto.endOf = function endOf(arg) {\n return this.startOf(arg, false);\n };\n _proto.$set = function $set(units, _int) {\n var _C$D$C$DATE$C$M$C$Y$C;\n var unit = Utils.p(units);\n var utcPad = "set" + (this.$u ? "UTC" : "");\n var name = (_C$D$C$DATE$C$M$C$Y$C = {}, _C$D$C$DATE$C$M$C$Y$C[D] = utcPad + "Date", _C$D$C$DATE$C$M$C$Y$C[DATE] = utcPad + "Date", _C$D$C$DATE$C$M$C$Y$C[M] = utcPad + "Month", _C$D$C$DATE$C$M$C$Y$C[Y] = utcPad + "FullYear", _C$D$C$DATE$C$M$C$Y$C[H] = utcPad + "Hours", _C$D$C$DATE$C$M$C$Y$C[MIN] = utcPad + "Minutes", _C$D$C$DATE$C$M$C$Y$C[S] = utcPad + "Seconds", _C$D$C$DATE$C$M$C$Y$C[MS] = utcPad + "Milliseconds", _C$D$C$DATE$C$M$C$Y$C)[unit];\n var arg = unit === D ? this.$D + (_int - this.$W) : _int;\n if (unit === M || unit === Y) {\n var date = this.clone().set(DATE, 1);\n date.$d[name](arg);\n date.init();\n this.$d = date.set(DATE, Math.min(this.$D, date.daysInMonth())).$d;\n } else if (name) this.$d[name](arg);\n this.init();\n return this;\n };\n _proto.set = function set(string, _int2) {\n return this.clone().$set(string, _int2);\n };\n _proto.get = function get(unit) {\n return this[Utils.p(unit)]();\n };\n _proto.add = function add(number, units) {\n var _this2 = this, _C$MIN$C$H$C$S$unit;\n number = Number(number);\n var unit = Utils.p(units);\n var instanceFactorySet = function instanceFactorySet2(n) {\n var d = dayjs(_this2);\n return Utils.w(d.date(d.date() + Math.round(n * number)), _this2);\n };\n if (unit === M) {\n return this.set(M, this.$M + number);\n }\n if (unit === Y) {\n return this.set(Y, this.$y + number);\n }\n if (unit === D) {\n return instanceFactorySet(1);\n }\n if (unit === W) {\n return instanceFactorySet(7);\n }\n var step = (_C$MIN$C$H$C$S$unit = {}, _C$MIN$C$H$C$S$unit[MIN] = MILLISECONDS_A_MINUTE, _C$MIN$C$H$C$S$unit[H] = MILLISECONDS_A_HOUR, _C$MIN$C$H$C$S$unit[S] = MILLISECONDS_A_SECOND, _C$MIN$C$H$C$S$unit)[unit] || 1;\n var nextTimeStamp = this.$d.getTime() + number * step;\n return Utils.w(nextTimeStamp, this);\n };\n _proto.subtract = function subtract(number, string) {\n return this.add(number * -1, string);\n };\n _proto.format = function format(formatStr) {\n var _this3 = this;\n var locale = this.$locale();\n if (!this.isValid()) return locale.invalidDate || INVALID_DATE_STRING;\n var str = formatStr || FORMAT_DEFAULT;\n var zoneStr = Utils.z(this);\n var $H = this.$H, $m = this.$m, $M = this.$M;\n var weekdays = locale.weekdays, months = locale.months, meridiem = locale.meridiem;\n var getShort = function getShort2(arr, index, full, length) {\n return arr && (arr[index] || arr(_this3, str)) || full[index].slice(0, length);\n };\n var get$H = function get$H2(num) {\n return Utils.s($H % 12 || 12, num, "0");\n };\n var meridiemFunc = meridiem || function(hour, minute, isLowercase) {\n var m2 = hour < 12 ? "AM" : "PM";\n return isLowercase ? m2.toLowerCase() : m2;\n };\n var matches = function matches2(match) {\n switch (match) {\n case "YY":\n return String(_this3.$y).slice(-2);\n case "YYYY":\n return Utils.s(_this3.$y, 4, "0");\n case "M":\n return $M + 1;\n case "MM":\n return Utils.s($M + 1, 2, "0");\n case "MMM":\n return getShort(locale.monthsShort, $M, months, 3);\n case "MMMM":\n return getShort(months, $M);\n case "D":\n return _this3.$D;\n case "DD":\n return Utils.s(_this3.$D, 2, "0");\n case "d":\n return String(_this3.$W);\n case "dd":\n return getShort(locale.weekdaysMin, _this3.$W, weekdays, 2);\n case "ddd":\n return getShort(locale.weekdaysShort, _this3.$W, weekdays, 3);\n case "dddd":\n return weekdays[_this3.$W];\n case "H":\n return String($H);\n case "HH":\n return Utils.s($H, 2, "0");\n case "h":\n return get$H(1);\n case "hh":\n return get$H(2);\n case "a":\n return meridiemFunc($H, $m, true);\n case "A":\n return meridiemFunc($H, $m, false);\n case "m":\n return String($m);\n case "mm":\n return Utils.s($m, 2, "0");\n case "s":\n return String(_this3.$s);\n case "ss":\n return Utils.s(_this3.$s, 2, "0");\n case "SSS":\n return Utils.s(_this3.$ms, 3, "0");\n case "Z":\n return zoneStr;\n }\n return null;\n };\n return str.replace(REGEX_FORMAT, function(match, $1) {\n return $1 || matches(match) || zoneStr.replace(":", "");\n });\n };\n _proto.utcOffset = function utcOffset() {\n return -Math.round(this.$d.getTimezoneOffset() / 15) * 15;\n };\n _proto.diff = function diff(input, units, _float) {\n var _this4 = this;\n var unit = Utils.p(units);\n var that = dayjs(input);\n var zoneDelta = (that.utcOffset() - this.utcOffset()) * MILLISECONDS_A_MINUTE;\n var diff2 = this - that;\n var getMonth = function getMonth2() {\n return Utils.m(_this4, that);\n };\n var result;\n switch (unit) {\n case Y:\n result = getMonth() / 12;\n break;\n case M:\n result = getMonth();\n break;\n case Q:\n result = getMonth() / 3;\n break;\n case W:\n result = (diff2 - zoneDelta) / MILLISECONDS_A_WEEK;\n break;\n case D:\n result = (diff2 - zoneDelta) / MILLISECONDS_A_DAY;\n break;\n case H:\n result = diff2 / MILLISECONDS_A_HOUR;\n break;\n case MIN:\n result = diff2 / MILLISECONDS_A_MINUTE;\n break;\n case S:\n result = diff2 / MILLISECONDS_A_SECOND;\n break;\n default:\n result = diff2;\n break;\n }\n return _float ? result : Utils.a(result);\n };\n _proto.daysInMonth = function daysInMonth() {\n return this.endOf(M).$D;\n };\n _proto.$locale = function $locale() {\n return Ls[this.$L];\n };\n _proto.locale = function locale(preset, object) {\n if (!preset) return this.$L;\n var that = this.clone();\n var nextLocaleName = parseLocale(preset, object, true);\n if (nextLocaleName) that.$L = nextLocaleName;\n return that;\n };\n _proto.clone = function clone() {\n return Utils.w(this.$d, this);\n };\n _proto.toDate = function toDate() {\n return new Date(this.valueOf());\n };\n _proto.toJSON = function toJSON() {\n return this.isValid() ? this.toISOString() : null;\n };\n _proto.toISOString = function toISOString() {\n return this.$d.toISOString();\n };\n _proto.toString = function toString() {\n return this.$d.toUTCString();\n };\n return Dayjs2;\n }();\n var proto = Dayjs.prototype;\n dayjs.prototype = proto;\n [["$ms", MS], ["$s", S], ["$m", MIN], ["$H", H], ["$W", D], ["$M", M], ["$y", Y], ["$D", DATE]].forEach(function(g) {\n proto[g[1]] = function(input) {\n return this.$g(input, g[0], g[1]);\n };\n });\n dayjs.extend = function(plugin, option) {\n if (!plugin.$i) {\n plugin(option, Dayjs, dayjs);\n plugin.$i = true;\n }\n return dayjs;\n };\n dayjs.locale = parseLocale;\n dayjs.isDayjs = isDayjs;\n dayjs.unix = function(timestamp) {\n return dayjs(timestamp * 1e3);\n };\n dayjs.en = Ls[L];\n dayjs.Ls = Ls;\n dayjs.p = {};\n var advancedFormat = function(o, c2) {\n var proto2 = c2.prototype;\n var oldFormat = proto2.format;\n proto2.format = function(formatStr) {\n var _this = this;\n var locale = this.$locale();\n if (!this.isValid()) {\n return oldFormat.bind(this)(formatStr);\n }\n var utils = this.$utils();\n var str = formatStr || FORMAT_DEFAULT;\n var result = str.replace(/\\[([^\\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g, function(match) {\n switch (match) {\n case "Q":\n return Math.ceil((_this.$M + 1) / 3);\n case "Do":\n return locale.ordinal(_this.$D);\n case "gggg":\n return _this.weekYear();\n case "GGGG":\n return _this.isoWeekYear();\n case "wo":\n return locale.ordinal(_this.week(), "W");\n // W for week\n case "w":\n case "ww":\n return utils.s(_this.week(), match === "w" ? 1 : 2, "0");\n case "W":\n case "WW":\n return utils.s(_this.isoWeek(), match === "W" ? 1 : 2, "0");\n case "k":\n case "kk":\n return utils.s(String(_this.$H === 0 ? 24 : _this.$H), match === "k" ? 1 : 2, "0");\n case "X":\n return Math.floor(_this.$d.getTime() / 1e3);\n case "x":\n return _this.$d.getTime();\n case "z":\n return "[" + _this.offsetName() + "]";\n case "zzz":\n return "[" + _this.offsetName("long") + "]";\n default:\n return match;\n }\n });\n return oldFormat.bind(this)(result);\n };\n };\n var isoWeekPrettyUnit = "isoweek";\n var isoWeek = function(o, c2, d) {\n var getYearFirstThursday = function getYearFirstThursday2(year, isUtc) {\n var yearFirstDay = (isUtc ? d.utc : d)().year(year).startOf(Y);\n var addDiffDays = 4 - yearFirstDay.isoWeekday();\n if (yearFirstDay.isoWeekday() > 4) {\n addDiffDays += 7;\n }\n return yearFirstDay.add(addDiffDays, D);\n };\n var getCurrentWeekThursday = function getCurrentWeekThursday2(ins) {\n return ins.add(4 - ins.isoWeekday(), D);\n };\n var proto2 = c2.prototype;\n proto2.isoWeekYear = function() {\n var nowWeekThursday = getCurrentWeekThursday(this);\n return nowWeekThursday.year();\n };\n proto2.isoWeek = function(week) {\n if (!this.$utils().u(week)) {\n return this.add((week - this.isoWeek()) * 7, D);\n }\n var nowWeekThursday = getCurrentWeekThursday(this);\n var diffWeekThursday = getYearFirstThursday(this.isoWeekYear(), this.$u);\n return nowWeekThursday.diff(diffWeekThursday, W) + 1;\n };\n proto2.isoWeekday = function(week) {\n if (!this.$utils().u(week)) {\n return this.day(this.day() % 7 ? week : week - 7);\n }\n return this.day() || 7;\n };\n var oldStartOf = proto2.startOf;\n proto2.startOf = function(units, startOf) {\n var utils = this.$utils();\n var isStartOf = !utils.u(startOf) ? startOf : true;\n var unit = utils.p(units);\n if (unit === isoWeekPrettyUnit) {\n return isStartOf ? this.date(this.date() - (this.isoWeekday() - 1)).startOf("day") : this.date(this.date() - 1 - (this.isoWeekday() - 1) + 7).endOf("day");\n }\n return oldStartOf.bind(this)(units, startOf);\n };\n };\n dayjs.extend(isoWeek);\n dayjs.extend(advancedFormat);\n const FORMAT_ISO_WEEK_YEAR_WEEK = "GGGG-[W]WW";\n const _TemporalCache = class _TemporalCache {\n constructor() {\n this.yearMonthDayCache = /* @__PURE__ */ new Map();\n this.yearWeekCache = /* @__PURE__ */ new Map();\n this.yearMonthCache = /* @__PURE__ */ new Map();\n this.yearCache = /* @__PURE__ */ new Map();\n }\n getYearMonthDay(s2) {\n if (!this.yearMonthDayCache.has(s2)) {\n this.yearMonthDayCache.set(s2, YearMonthDayClass.parse(s2, this));\n }\n return this.yearMonthDayCache.get(s2);\n }\n getYearMonth(s2) {\n if (!this.yearMonthCache.has(s2)) {\n this.yearMonthCache.set(s2, YearMonthClass.parse(s2, this));\n }\n return this.yearMonthCache.get(s2);\n }\n getYearWeek(s2) {\n if (!this.yearWeekCache.has(s2)) {\n this.yearWeekCache.set(s2, YearWeekClass.parse(s2, this));\n }\n return this.yearWeekCache.get(s2);\n }\n getYear(s2) {\n if (!this.yearCache.has(s2)) {\n this.yearCache.set(s2, YearClass.parse(s2, this));\n }\n return this.yearCache.get(s2);\n }\n static getInstance() {\n return this.instance;\n }\n };\n _TemporalCache.instance = new _TemporalCache();\n let TemporalCache = _TemporalCache;\n class YearMonthDayClass {\n constructor(yearNumber, monthNumber, dayNumber, cache) {\n this.yearNumber = yearNumber;\n this.monthNumber = monthNumber;\n this.dayNumber = dayNumber;\n this.cache = cache;\n this.type = "YearMonthDay";\n this.date = new Date(this.yearNumber, this.monthNumber - 1, this.dayNumber);\n this.dayjs = dayjs(this.date);\n this.dateString = this.toString();\n }\n get text() {\n return this.dayjs.format("YYYY-MM-DD");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return this.dayjs.format("dddd, MMMM D, YYYY");\n }\n get firstDay() {\n return this;\n }\n get lastDay() {\n return this;\n }\n get year() {\n return this.cache.getYear(`${this.yearNumber}`);\n }\n get month() {\n return this.cache.getYearMonth(this.dayjs.format("YYYY-MM"));\n }\n get week() {\n return this.cache.getYearWeek(this.dayjs.format(FORMAT_ISO_WEEK_YEAR_WEEK));\n }\n addDays(days) {\n const date = this.dayjs.add(days, "day");\n const s2 = date.format("YYYY-MM-DD");\n return this.cache.getYearMonthDay(s2);\n }\n minus(other) {\n return this.dayjs.diff(other.dayjs, "day");\n }\n static parse(s2, cache) {\n const [year, month, day] = s2.split("-").map((s22) => parseInt(s22, 10));\n return new YearMonthDayClass(year, month, day, cache);\n }\n }\n class YearWeekClass {\n constructor(isoYearNumber, isoWeekNumber, cache) {\n this.isoYearNumber = isoYearNumber;\n this.isoWeekNumber = isoWeekNumber;\n this.cache = cache;\n this.type = "YearWeek";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format(FORMAT_ISO_WEEK_YEAR_WEEK);\n }\n toString() {\n return this.text;\n }\n englishName() {\n return `Week ${this.isoWeekNumber}, ${this.isoYearNumber}`;\n }\n get firstDay() {\n const firstDay = dayjs().year(this.isoYearNumber).month(1).date(4).isoWeek(this.isoWeekNumber).startOf("isoWeek");\n return this.cache.getYearMonthDay(firstDay.format("YYYY-MM-DD"));\n }\n get lastDay() {\n const lastDay = this.firstDay.dayjs.add(6, "days");\n return this.cache.getYearMonthDay(lastDay.format("YYYY-MM-DD"));\n }\n get year() {\n return this.cache.getYear(`${this.isoYearNumber}`);\n }\n addWeeks(weeks) {\n const date = this.firstDay.dayjs.add(weeks, "week");\n const s2 = date.format(FORMAT_ISO_WEEK_YEAR_WEEK);\n return this.cache.getYearWeek(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "week");\n }\n static parse(s2, cache) {\n const [year, week] = s2.split("-W").map((s22) => parseInt(s22, 10));\n return new YearWeekClass(year, week, cache);\n }\n }\n class YearMonthClass {\n constructor(yearNumber, monthNumber, cache) {\n this.yearNumber = yearNumber;\n this.monthNumber = monthNumber;\n this.cache = cache;\n this.type = "YearMonth";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format("YYYY-MM");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return `${monthName(this.monthNumber)} ${this.yearNumber}`;\n }\n get firstDay() {\n return this.cache.getYearMonthDay(dayjs(`${this.yearNumber}-${this.monthNumber}-01`).format("YYYY-MM-DD"));\n }\n get lastDay() {\n return this.cache.getYearMonthDay(\n dayjs(`${this.yearNumber}-${this.monthNumber}-01`).endOf("month").format("YYYY-MM-DD")\n );\n }\n get year() {\n return this.cache.getYear(`${this.yearNumber}`);\n }\n addMonths(months) {\n const date = this.firstDay.dayjs.add(months, "month");\n const s2 = date.format("YYYY-MM");\n return this.cache.getYearMonth(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "month");\n }\n static parse(s2, cache) {\n const [year, month] = s2.split("-").map((s22) => parseInt(s22, 10));\n return new YearMonthClass(year, month, cache);\n }\n }\n class YearClass {\n constructor(year, cache) {\n this.year = year;\n this.cache = cache;\n this.type = "Year";\n this.dateString = this.toString();\n }\n get text() {\n return this.firstDay.dayjs.format("YYYY");\n }\n toString() {\n return this.text;\n }\n englishName() {\n return this.year.toString();\n }\n get firstMonth() {\n return this.cache.getYearMonth(`${this.year}-01`);\n }\n get lastMonth() {\n return this.cache.getYearMonth(`${this.year}-12`);\n }\n get firstDay() {\n return this.firstMonth.firstDay;\n }\n get lastDay() {\n return this.lastMonth.lastDay;\n }\n addYears(years) {\n const date = this.firstDay.dayjs.add(years, "year");\n const s2 = date.format("YYYY");\n return this.cache.getYear(s2);\n }\n minus(other) {\n return this.firstDay.dayjs.diff(other.firstDay.dayjs, "year");\n }\n static parse(s2, cache) {\n const year = parseInt(s2, 10);\n return new YearClass(year, cache);\n }\n }\n function monthName(month) {\n return dayjs().month(month - 1).format("MMMM");\n }\n function toTemporal(temporalClass) {\n switch (temporalClass.type) {\n case "YearMonthDay":\n return {\n type: "YearMonthDay",\n yearNumber: temporalClass.yearNumber,\n monthNumber: temporalClass.monthNumber,\n dayNumber: temporalClass.dayNumber,\n dateString: temporalClass.dateString\n };\n case "YearWeek":\n return {\n type: "YearWeek",\n isoYearNumber: temporalClass.isoYearNumber,\n isoWeekNumber: temporalClass.isoWeekNumber,\n dateString: temporalClass.dateString\n };\n case "YearMonth":\n return {\n type: "YearMonth",\n yearNumber: temporalClass.yearNumber,\n monthNumber: temporalClass.monthNumber,\n dateString: temporalClass.dateString\n };\n case "Year":\n return {\n type: "Year",\n year: temporalClass.year,\n dateString: temporalClass.dateString\n };\n }\n }\n function generateAllDaysInRange(start, end) {\n const days = [];\n const daysInBetween = end.minus(start);\n for (let i2 = 0; i2 <= daysInBetween; i2++) {\n days.push(start.addDays(i2));\n }\n return days;\n }\n function generateAllWeeksInRange(start, end) {\n const weeks = [];\n const weeksInBetween = end.minus(start);\n for (let i2 = 0; i2 <= weeksInBetween; i2++) {\n weeks.push(start.addWeeks(i2));\n }\n return weeks;\n }\n function generateAllMonthsInRange(start, end) {\n const months = [];\n const monthsInBetween = end.minus(start);\n for (let i2 = 0; i2 <= monthsInBetween; i2++) {\n months.push(start.addMonths(i2));\n }\n return months;\n }\n function generateAllYearsInRange(start, end) {\n const years = [];\n const yearsInBetween = end.minus(start);\n for (let i2 = 0; i2 <= yearsInBetween; i2++) {\n years.push(start.addYears(i2));\n }\n return years;\n }\n function generateAllInRange(start, end) {\n if (start === null || end === null) {\n return [];\n }\n if (start instanceof YearMonthDayClass && end instanceof YearMonthDayClass) {\n return generateAllDaysInRange(start, end);\n }\n if (start instanceof YearWeekClass && end instanceof YearWeekClass) {\n return generateAllWeeksInRange(start, end);\n }\n if (start instanceof YearMonthClass && end instanceof YearMonthClass) {\n return generateAllMonthsInRange(start, end);\n }\n if (start instanceof YearClass && end instanceof YearClass) {\n return generateAllYearsInRange(start, end);\n }\n throw new Error(`Invalid arguments: start and end must be of the same type: ${start}, ${end}`);\n }\n function minusTemporal(a2, b) {\n if (a2 instanceof YearMonthDayClass && b instanceof YearMonthDayClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearWeekClass && b instanceof YearWeekClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearMonthClass && b instanceof YearMonthClass) {\n return a2.minus(b);\n }\n if (a2 instanceof YearClass && b instanceof YearClass) {\n return a2.minus(b);\n }\n throw new Error(`Cannot compare ${a2} and ${b}`);\n }\n function compareTemporal(a2, b) {\n if (a2 === null) {\n return 1;\n }\n if (b === null) {\n return -1;\n }\n const diff = minusTemporal(a2, b);\n if (diff < 0) {\n return -1;\n }\n if (diff > 0) {\n return 1;\n }\n return 0;\n }\n function getMinMaxTemporal(values) {\n let min = null;\n let max = null;\n for (const value of values) {\n if (value === null) {\n continue;\n }\n if (min === null || compareTemporal(value, min) < 0) {\n min = value;\n }\n if (max === null || compareTemporal(value, max) > 0) {\n max = value;\n }\n }\n if (min === null || max === null) {\n return { min: null, max: null };\n }\n return { min, max };\n }\n function parseDateStringToTemporal(date, granularity) {\n const cache = TemporalCache.getInstance();\n const day = cache.getYearMonthDay(date);\n switch (granularity) {\n case "day":\n return day;\n case "week":\n return day.week;\n case "month":\n return day.month;\n case "year":\n return day.year;\n }\n }\n function dateRangeCompare(a2, b) {\n if (a2.dateRange === null) {\n return 1;\n }\n if (b.dateRange === null) {\n return -1;\n }\n return compareTemporal(a2.dateRange, b.dateRange);\n }\n function mapDateToGranularityRange(data, granularity) {\n return {\n dateRange: data.date === null ? null : parseDateStringToTemporal(data.date, granularity),\n count: data.count\n };\n }\n const substitutionRegex = /^((?<segment>[A-Z0-9_-]+)(?=:):)?(?<valueAtReference>[A-Z])?(?<position>\\d+)(?<substitutionValue>[A-Z.*])?$/i;\n class SubstitutionClass {\n constructor(segment, valueAtReference, substitutionValue, position) {\n this.segment = segment;\n this.valueAtReference = valueAtReference;\n this.substitutionValue = substitutionValue;\n this.position = position;\n this.type = "substitution";\n const segmentString = this.segment ? `${this.segment}:` : "";\n const valueAtReferenceString = this.valueAtReference ? `${this.valueAtReference}` : "";\n const substitutionValueString = this.substitutionValue ? `${this.substitutionValue}` : "";\n this.code = `${segmentString}${valueAtReferenceString}${this.position}${substitutionValueString}`;\n }\n equals(other) {\n if (!(other instanceof SubstitutionClass)) {\n return false;\n }\n return this.segment === other.segment && this.valueAtReference === other.valueAtReference && this.substitutionValue === other.substitutionValue && this.position === other.position;\n }\n toString() {\n return this.code;\n }\n static parse(mutationStr) {\n const match = mutationStr.match(substitutionRegex);\n if (match === null || match.groups === void 0) {\n return null;\n }\n return new SubstitutionClass(\n match.groups.segment,\n match.groups.valueAtReference,\n match.groups.substitutionValue,\n parseInt(match.groups.position, 10)\n );\n }\n }\n const deletionRegex = /^((?<segment>[A-Z0-9_-]+)(?=:):)?(?<valueAtReference>[A-Z])?(?<position>\\d+)(-)$/i;\n class DeletionClass {\n constructor(segment, valueAtReference, position) {\n this.segment = segment;\n this.valueAtReference = valueAtReference;\n this.position = position;\n this.type = "deletion";\n const segmentString = this.segment ? `${this.segment}:` : "";\n const valueAtReferenceString = this.valueAtReference ? `${this.valueAtReference}` : "";\n this.code = `${segmentString}${valueAtReferenceString}${this.position}-`;\n }\n equals(other) {\n if (!(other instanceof DeletionClass)) {\n return false;\n }\n return this.segment === other.segment && this.valueAtReference === other.valueAtReference && this.position === other.position;\n }\n toString() {\n return this.code;\n }\n static parse(mutationStr) {\n const match = mutationStr.match(deletionRegex);\n if (match === null || match.groups === void 0) {\n return null;\n }\n return new DeletionClass(\n match.groups.segment,\n match.groups.valueAtReference,\n parseInt(match.groups.position, 10)\n );\n }\n }\n function toSubstitutionOrDeletion(mutation) {\n switch (mutation.type) {\n case "substitution":\n return {\n type: "substitution",\n code: mutation.code,\n segment: mutation.segment,\n position: mutation.position,\n valueAtReference: mutation.valueAtReference,\n substitutionValue: mutation.substitutionValue\n };\n case "deletion":\n return {\n type: "deletion",\n code: mutation.code,\n segment: mutation.segment,\n position: mutation.position,\n valueAtReference: mutation.valueAtReference\n };\n }\n }\n class FetchSubstitutionsOrDeletionsOperator {\n constructor(filter, sequenceType, minProportion) {\n this.filter = filter;\n this.sequenceType = sequenceType;\n this.minProportion = minProportion;\n }\n async evaluate(lapis, signal) {\n const mutations = await this.fetchMutations(lapis, signal);\n const content = mutations.map(\n ({ count, proportion, mutationFrom, mutationTo, position, sequenceName }) => {\n if (mutationTo === "-") {\n return {\n type: "deletion",\n mutation: new DeletionClass(sequenceName ?? void 0, mutationFrom, position),\n count,\n proportion\n };\n }\n return {\n type: "substitution",\n mutation: new SubstitutionClass(sequenceName ?? void 0, mutationFrom, mutationTo, position),\n count,\n proportion\n };\n }\n );\n return { content };\n }\n async fetchMutations(lapis, signal) {\n const filter = {\n ...this.filter,\n minProportion: this.minProportion\n };\n return fetchSubstitutionsOrDeletions(lapis, filter, this.sequenceType, signal).then(\n (response) => response.data\n );\n }\n }\n var l$1;\n l$1 = { __e: function(n, l2, u2, t) {\n for (var i2, r2, o; l2 = l2.__; ) if ((i2 = l2.__c) && !i2.__) try {\n if ((r2 = i2.constructor) && null != r2.getDerivedStateFromError && (i2.setState(r2.getDerivedStateFromError(n)), o = i2.__d), null != i2.componentDidCatch && (i2.componentDidCatch(n, t || {}), o = i2.__d), o) return i2.__E = i2;\n } catch (l3) {\n n = l3;\n }\n throw n;\n } }, "function" == typeof Promise ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout;\n var r, u, i, f = [], c = l$1, e = c.__b, a = c.__r, v = c.diffed, l = c.__c, m = c.unmount, s = c.__;\n function j() {\n for (var n; n = f.shift(); ) if (n.__P && n.__H) try {\n n.__H.__h.forEach(z), n.__H.__h.forEach(B), n.__H.__h = [];\n } catch (t) {\n n.__H.__h = [], c.__e(t, n.__v);\n }\n }\n c.__b = function(n) {\n r = null, e && e(n);\n }, c.__ = function(n, t) {\n n && t.__k && t.__k.__m && (n.__m = t.__k.__m), s && s(n, t);\n }, c.__r = function(n) {\n a && a(n);\n var i2 = (r = n.__c).__H;\n i2 && (u === r ? (i2.__h = [], r.__h = [], i2.__.forEach(function(n2) {\n n2.__N && (n2.__ = n2.__N), n2.u = n2.__N = void 0;\n })) : (i2.__h.forEach(z), i2.__h.forEach(B), i2.__h = [], 0)), u = r;\n }, c.diffed = function(n) {\n v && v(n);\n var t = n.__c;\n t && t.__H && (t.__H.__h.length && (1 !== f.push(t) && i === c.requestAnimationFrame || ((i = c.requestAnimationFrame) || w)(j)), t.__H.__.forEach(function(n2) {\n n2.u && (n2.__H = n2.u), n2.u = void 0;\n })), u = r = null;\n }, c.__c = function(n, t) {\n t.some(function(n2) {\n try {\n n2.__h.forEach(z), n2.__h = n2.__h.filter(function(n3) {\n return !n3.__ || B(n3);\n });\n } catch (r2) {\n t.some(function(n3) {\n n3.__h && (n3.__h = []);\n }), t = [], c.__e(r2, n2.__v);\n }\n }), l && l(n, t);\n }, c.unmount = function(n) {\n m && m(n);\n var t, r2 = n.__c;\n r2 && r2.__H && (r2.__H.__.forEach(function(n2) {\n try {\n z(n2);\n } catch (n3) {\n t = n3;\n }\n }), r2.__H = void 0, t && c.__e(t, r2.__v));\n };\n var k = "function" == typeof requestAnimationFrame;\n function w(n) {\n var t, r2 = function() {\n clearTimeout(u2), k && cancelAnimationFrame(t), setTimeout(n);\n }, u2 = setTimeout(r2, 100);\n k && (t = requestAnimationFrame(r2));\n }\n function z(n) {\n var t = r, u2 = n.__c;\n "function" == typeof u2 && (n.__c = void 0, u2()), r = t;\n }\n function B(n) {\n var t = r;\n n.__c = n.__(), r = t;\n }\n class UserFacingError extends Error {\n constructor(headline, message) {\n super(message);\n this.headline = headline;\n this.name = "UserFacingError";\n }\n }\n class Map2dBase {\n constructor(serializeFirstAxis, serializeSecondAxis, initialContent) {\n this.serializeFirstAxis = serializeFirstAxis;\n this.serializeSecondAxis = serializeSecondAxis;\n this.data = /* @__PURE__ */ new Map();\n this.keysFirstAxis = /* @__PURE__ */ new Map();\n this.keysSecondAxis = /* @__PURE__ */ new Map();\n if (initialContent) {\n this.keysFirstAxis = new Map(initialContent.keysFirstAxis);\n this.keysSecondAxis = new Map(initialContent.keysSecondAxis);\n this.data = new Map(initialContent.data);\n }\n }\n get(keyFirstAxis, keySecondAxis) {\n var _a;\n const serializedKeyFirstAxis = this.serializeFirstAxis(keyFirstAxis);\n const serializedKeySecondAxis = this.serializeSecondAxis(keySecondAxis);\n return (_a = this.data.get(serializedKeyFirstAxis)) == null ? void 0 : _a.get(serializedKeySecondAxis);\n }\n getRow(key) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(key);\n const row = this.data.get(serializedKeyFirstAxis);\n if (row === void 0) {\n return [];\n }\n return Array.from(this.keysSecondAxis.keys()).map((key2) => row.get(key2));\n }\n set(keyFirstAxis, keySecondAxis, value) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(keyFirstAxis);\n const serializedKeySecondAxis = this.serializeSecondAxis(keySecondAxis);\n if (!this.data.has(serializedKeyFirstAxis)) {\n this.data.set(serializedKeyFirstAxis, /* @__PURE__ */ new Map());\n }\n this.data.get(serializedKeyFirstAxis).set(serializedKeySecondAxis, value);\n this.keysFirstAxis.set(serializedKeyFirstAxis, keyFirstAxis);\n this.keysSecondAxis.set(serializedKeySecondAxis, keySecondAxis);\n }\n deleteRow(key) {\n const serializedKeyFirstAxis = this.serializeFirstAxis(key);\n this.data.delete(serializedKeyFirstAxis);\n this.keysFirstAxis.delete(serializedKeyFirstAxis);\n }\n getFirstAxisKeys() {\n return Array.from(this.keysFirstAxis.values());\n }\n getSecondAxisKeys() {\n return Array.from(this.keysSecondAxis.values());\n }\n getAsArray() {\n return this.getFirstAxisKeys().map((firstAxisKey) => {\n return this.getSecondAxisKeys().map((secondAxisKey) => {\n return this.get(firstAxisKey, secondAxisKey);\n });\n });\n }\n getContents() {\n return {\n keysFirstAxis: this.keysFirstAxis,\n keysSecondAxis: this.keysSecondAxis,\n data: this.data\n };\n }\n }\n class BaseMutationOverTimeDataMap extends Map2dBase {\n constructor(initialContent) {\n super(serializeSubstitutionOrDeletion, serializeTemporal, initialContent);\n }\n }\n const sortSubstitutionsAndDeletions = (a2, b) => {\n if (a2.segment !== b.segment) {\n return compareSegments(a2.segment, b.segment);\n }\n if (a2.position !== b.position) {\n return comparePositions(a2.position, b.position);\n }\n const aIsDeletion = a2.type === "deletion";\n const bIsDeletion = b.type === "deletion";\n if (aIsDeletion !== bIsDeletion) {\n return aIsDeletion ? 1 : -1;\n }\n if (!aIsDeletion && !bIsDeletion) {\n if (a2.substitutionValue !== b.substitutionValue) {\n return compareSubstitutionValues(a2.substitutionValue, b.substitutionValue);\n }\n }\n return 0;\n };\n const compareSegments = (a2, b) => {\n if (a2 === void 0) {\n return -1;\n }\n if (b === void 0) {\n return 1;\n }\n return a2.localeCompare(b);\n };\n const comparePositions = (a2, b) => {\n return a2 - b;\n };\n const compareSubstitutionValues = (a2, b) => {\n if (a2 === void 0) {\n return -1;\n }\n if (b === void 0) {\n return 1;\n }\n return a2.localeCompare(b);\n };\n const MAX_NUMBER_OF_GRID_COLUMNS = 200;\n const MUTATIONS_OVER_TIME_MIN_PROPORTION = 1e-3;\n async function queryOverallMutationData({\n lapisFilter,\n sequenceType,\n lapis,\n granularity,\n lapisDateField,\n signal\n }) {\n const allDates = await getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal);\n if (allDates.length === 0) {\n return {\n content: []\n };\n }\n const filter = {\n ...lapisFilter,\n [`${lapisDateField}From`]: allDates[0].firstDay.toString(),\n [`${lapisDateField}To`]: allDates[allDates.length - 1].lastDay.toString()\n };\n return fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType).evaluate(lapis, signal);\n }\n async function queryMutationsOverTimeData({\n lapisFilter,\n sequenceType,\n lapis,\n lapisDateField,\n granularity,\n signal\n }) {\n const allDates = await getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal);\n if (allDates.length > MAX_NUMBER_OF_GRID_COLUMNS) {\n throw new UserFacingError(\n "Too many dates",\n `The dataset would contain ${allDates.length} date intervals. Please reduce the number to below ${MAX_NUMBER_OF_GRID_COLUMNS} to display the data. You can achieve this by either narrowing the date range in the provided LAPIS filter or by selecting a larger granularity.`\n );\n }\n const subQueries = allDates.map(async (date) => {\n const dateFrom = date.firstDay.toString();\n const dateTo = date.lastDay.toString();\n const filter = {\n ...lapisFilter,\n [`${lapisDateField}From`]: dateFrom,\n [`${lapisDateField}To`]: dateTo\n };\n const data2 = await fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType).evaluate(lapis, signal);\n const totalCountQuery = await getTotalNumberOfSequencesInDateRange(filter).evaluate(lapis, signal);\n return {\n date,\n mutations: data2.content,\n totalCount: totalCountQuery.content[0].count\n };\n });\n const data = await Promise.all(subQueries);\n const overallMutationsData = (await queryOverallMutationData({\n lapisFilter,\n sequenceType,\n lapis,\n lapisDateField,\n granularity\n })).content;\n return {\n mutationOverTimeData: groupByMutation(data, overallMutationsData),\n overallMutationData: overallMutationsData\n };\n }\n async function getDatesInDataset(lapisFilter, lapis, granularity, lapisDateField, signal) {\n const { content: availableDates } = await queryAvailableDates(\n lapisFilter,\n lapis,\n granularity,\n lapisDateField,\n signal\n );\n const { dateFrom, dateTo } = getDateRangeFromFilter(lapisFilter, lapisDateField, granularity);\n const { min, max } = getMinMaxTemporal(availableDates);\n return generateAllInRange(dateFrom ?? min, dateTo ?? max);\n }\n function getDateRangeFromFilter(lapisFilter, lapisDateField, granularity) {\n const valueFromFilter = lapisFilter[lapisDateField];\n if (valueFromFilter) {\n return {\n dateFrom: parseDateStringToTemporal(valueFromFilter, granularity),\n dateTo: parseDateStringToTemporal(valueFromFilter, granularity)\n };\n }\n const minFromFilter = lapisFilter[`${lapisDateField}From`];\n const maxFromFilter = lapisFilter[`${lapisDateField}To`];\n return {\n dateFrom: minFromFilter ? parseDateStringToTemporal(minFromFilter, granularity) : null,\n dateTo: maxFromFilter ? parseDateStringToTemporal(maxFromFilter, granularity) : null\n };\n }\n function queryAvailableDates(lapisFilter, lapis, granularity, lapisDateField, signal) {\n return fetchAndPrepareDates(lapisFilter, granularity, lapisDateField).evaluate(lapis, signal);\n }\n function fetchAndPrepareDates(filter, granularity, lapisDateField) {\n const fetchData = new FetchAggregatedOperator(filter, [lapisDateField]);\n const dataWithFixedDateKey = new RenameFieldOperator(fetchData, lapisDateField, "date");\n const mapData = new MapOperator(dataWithFixedDateKey, (data) => mapDateToGranularityRange(data, granularity));\n const groupByData = new GroupByAndSumOperator(mapData, "dateRange", "count");\n const sortData = new SortOperator(groupByData, dateRangeCompare);\n return new MapOperator(sortData, (data) => data.dateRange);\n }\n function fetchAndPrepareSubstitutionsOrDeletions(filter, sequenceType) {\n return new FetchSubstitutionsOrDeletionsOperator(filter, sequenceType, MUTATIONS_OVER_TIME_MIN_PROPORTION);\n }\n function serializeSubstitutionOrDeletion(mutation) {\n return mutation.code;\n }\n function serializeTemporal(date) {\n return date.dateString;\n }\n function groupByMutation(data, overallMutationData) {\n const dataArray = new BaseMutationOverTimeDataMap();\n const allDates = data.map((mutationData) => mutationData.date);\n const sortedOverallMutationData = overallMutationData.sort((a2, b) => sortSubstitutionsAndDeletions(a2.mutation, b.mutation)).map((entry) => {\n return toSubstitutionOrDeletion(entry.mutation);\n });\n const sortedDates = allDates.sort((a2, b) => compareTemporal(a2, b)).map((date) => toTemporal(date));\n sortedOverallMutationData.forEach((mutationData) => {\n sortedDates.forEach((date) => {\n dataArray.set(mutationData, date, null);\n });\n });\n data.forEach((mutationData) => {\n if (mutationData.totalCount == 0) {\n return;\n }\n const date = toTemporal(mutationData.date);\n mutationData.mutations.forEach((mutationEntry) => {\n const mutation = toSubstitutionOrDeletion(mutationEntry.mutation);\n if (dataArray.get(mutation, date) !== void 0) {\n dataArray.set(mutation, date, {\n type: "value",\n count: mutationEntry.count,\n proportion: mutationEntry.proportion,\n totalCount: mutationData.totalCount\n });\n }\n });\n for (const firstAxisKey of dataArray.getFirstAxisKeys()) {\n if (dataArray.get(firstAxisKey, date) === null) {\n dataArray.set(firstAxisKey, date, {\n type: "belowThreshold",\n totalCount: mutationData.totalCount\n });\n }\n }\n });\n return dataArray;\n }\n function getTotalNumberOfSequencesInDateRange(filter) {\n return new FetchAggregatedOperator(filter);\n }\n async function workerFunction(queryFunction) {\n try {\n postMessage({ status: "loading" });\n const workerResponse = await queryFunction();\n postMessage({\n status: "success",\n data: workerResponse\n });\n } catch (error) {\n postMessage(\n error instanceof UserFacingError ? {\n status: "error",\n userFacing: true,\n headline: error.headline,\n error\n } : {\n status: "error",\n userFacing: false,\n error: error instanceof Error ? error : new Error(`${error}`)\n }\n );\n }\n }\n async function getMutationOverTimeWorkerFunction(event) {\n const mutationOverTimeData = await queryMutationsOverTimeData(event.data);\n const workerResponse = {\n overallMutationData: mutationOverTimeData.overallMutationData,\n mutationOverTimeSerialized: mutationOverTimeData.mutationOverTimeData.getContents()\n };\n return workerResponse;\n }\n self.onmessage = async function(event) {\n await workerFunction(() => getMutationOverTimeWorkerFunction(event));\n };\n})();\n//# sourceMappingURL=mutationOverTimeWorker-ChQTFL68.js.map\n';
|
|
6258
6278
|
const blob = typeof self !== "undefined" && self.Blob && new Blob([jsContent], { type: "text/javascript;charset=utf-8" });
|
|
6259
6279
|
function WorkerWrapper(options2) {
|
|
6260
6280
|
let objURL;
|
|
@@ -6438,7 +6458,10 @@ function getFilteredMutationOverTimeData$1({
|
|
|
6438
6458
|
displayedSegments,
|
|
6439
6459
|
displayedMutationTypes,
|
|
6440
6460
|
proportionInterval,
|
|
6441
|
-
displayMutations
|
|
6461
|
+
displayMutations,
|
|
6462
|
+
mutationFilterValue,
|
|
6463
|
+
sequenceType,
|
|
6464
|
+
annotationProvider
|
|
6442
6465
|
}) {
|
|
6443
6466
|
const filteredData = new Map2dView(data);
|
|
6444
6467
|
const displayMutationsSet = displayMutations === void 0 ? null : new Set(displayMutations.map((it) => it.toUpperCase()));
|
|
@@ -6452,6 +6475,9 @@ function getFilteredMutationOverTimeData$1({
|
|
|
6452
6475
|
if (displayMutationsSet !== null && !displayMutationsSet.has(entry.mutation.code)) {
|
|
6453
6476
|
return true;
|
|
6454
6477
|
}
|
|
6478
|
+
if (applySearchFilter(entry.mutation, sequenceType, mutationFilterValue, annotationProvider)) {
|
|
6479
|
+
return true;
|
|
6480
|
+
}
|
|
6455
6481
|
return displayedMutationTypes.some(
|
|
6456
6482
|
(mutationType) => mutationType.type === entry.mutation.type && !mutationType.checked
|
|
6457
6483
|
);
|
|
@@ -6461,6 +6487,21 @@ function getFilteredMutationOverTimeData$1({
|
|
|
6461
6487
|
});
|
|
6462
6488
|
return filteredData;
|
|
6463
6489
|
}
|
|
6490
|
+
function applySearchFilter(mutation, sequenceType, filterValue, annotationProvider) {
|
|
6491
|
+
if (filterValue === "") {
|
|
6492
|
+
return false;
|
|
6493
|
+
}
|
|
6494
|
+
if (mutation.code.includes(filterValue)) {
|
|
6495
|
+
return false;
|
|
6496
|
+
}
|
|
6497
|
+
const mutationAnnotations = annotationProvider(mutation, sequenceType);
|
|
6498
|
+
if (mutationAnnotations === void 0 || mutationAnnotations.length === 0) {
|
|
6499
|
+
return true;
|
|
6500
|
+
}
|
|
6501
|
+
return !mutationAnnotations.some(
|
|
6502
|
+
(annotation) => annotation.description.includes(filterValue) || annotation.name.includes(filterValue) || annotation.symbol.includes(filterValue)
|
|
6503
|
+
);
|
|
6504
|
+
}
|
|
6464
6505
|
const MutationsOverTimeGridTooltip = ({
|
|
6465
6506
|
mutation,
|
|
6466
6507
|
date,
|
|
@@ -6628,6 +6669,19 @@ const Tooltip = ({ children, content, position = "bottom" }) => {
|
|
|
6628
6669
|
)
|
|
6629
6670
|
] });
|
|
6630
6671
|
};
|
|
6672
|
+
const pageSizeContext = createContext$1({
|
|
6673
|
+
pageSize: -1,
|
|
6674
|
+
setPageSize: () => {
|
|
6675
|
+
throw new Error("pageSizeContext not initialized");
|
|
6676
|
+
}
|
|
6677
|
+
});
|
|
6678
|
+
function usePageSizeContext() {
|
|
6679
|
+
return x$1(pageSizeContext);
|
|
6680
|
+
}
|
|
6681
|
+
const PageSizeContextProvider = ({ children, pageSizes }) => {
|
|
6682
|
+
const [pageSize, setPageSize] = d(typeof pageSizes === "number" ? pageSizes : pageSizes.at(0) ?? 10);
|
|
6683
|
+
return /* @__PURE__ */ u$1(pageSizeContext.Provider, { value: { pageSize, setPageSize }, children });
|
|
6684
|
+
};
|
|
6631
6685
|
const pageSizesSchema = z$2.union([z$2.array(z$2.number()), z$2.number()]);
|
|
6632
6686
|
function Pagination({
|
|
6633
6687
|
table,
|
|
@@ -6660,6 +6714,7 @@ function PageSizeSelector({
|
|
|
6660
6714
|
table,
|
|
6661
6715
|
pageSizes
|
|
6662
6716
|
}) {
|
|
6717
|
+
const { pageSize, setPageSize } = usePageSizeContext();
|
|
6663
6718
|
if (typeof pageSizes === "number" || pageSizes.length <= 1) {
|
|
6664
6719
|
return null;
|
|
6665
6720
|
}
|
|
@@ -6669,13 +6724,20 @@ function PageSizeSelector({
|
|
|
6669
6724
|
"select",
|
|
6670
6725
|
{
|
|
6671
6726
|
className: `select select-ghost select-sm ${heightForSmallerLines}`,
|
|
6672
|
-
value:
|
|
6727
|
+
value: pageSize,
|
|
6673
6728
|
onChange: (e2) => {
|
|
6674
|
-
var _a;
|
|
6675
|
-
|
|
6729
|
+
var _a, _b;
|
|
6730
|
+
const pageSize2 = Number((_a = e2.currentTarget) == null ? void 0 : _a.value);
|
|
6731
|
+
if (Number.isNaN(pageSize2)) {
|
|
6732
|
+
throw new Error(
|
|
6733
|
+
`Invalid page size selected: The value ${(_b = e2.currentTarget) == null ? void 0 : _b.value} could not be parsed as a number.`
|
|
6734
|
+
);
|
|
6735
|
+
}
|
|
6736
|
+
setPageSize(pageSize2);
|
|
6737
|
+
table.setPageSize(pageSize2);
|
|
6676
6738
|
},
|
|
6677
6739
|
"aria-label": "Select number of rows per page",
|
|
6678
|
-
children: pageSizes.map((
|
|
6740
|
+
children: pageSizes.map((pageSize2) => /* @__PURE__ */ u$1("option", { value: pageSize2, children: pageSize2 }, pageSize2))
|
|
6679
6741
|
}
|
|
6680
6742
|
)
|
|
6681
6743
|
] });
|
|
@@ -6695,7 +6757,7 @@ function GotoPageSelector({ table }) {
|
|
|
6695
6757
|
defaultValue: table.getState().pagination.pageIndex + 1,
|
|
6696
6758
|
onChange: (e2) => {
|
|
6697
6759
|
const page = e2.currentTarget.value ? Number(e2.currentTarget.value) - 1 : 0;
|
|
6698
|
-
table.setPageIndex(page);
|
|
6760
|
+
table.setPageIndex(Math.min(page, table.getPageCount() - 1));
|
|
6699
6761
|
},
|
|
6700
6762
|
className: `input input-ghost input-sm ${heightForSmallerLines}`,
|
|
6701
6763
|
"aria-label": "Enter page number to go to"
|
|
@@ -6775,6 +6837,14 @@ function usePreactTable(options2) {
|
|
|
6775
6837
|
(_a = options2.onStateChange) == null ? void 0 : _a.call(options2, updater);
|
|
6776
6838
|
}
|
|
6777
6839
|
}));
|
|
6840
|
+
const { pageSize } = usePageSizeContext();
|
|
6841
|
+
y(
|
|
6842
|
+
() => {
|
|
6843
|
+
tableRef.current.setPageSize(pageSize);
|
|
6844
|
+
},
|
|
6845
|
+
[pageSize]
|
|
6846
|
+
// eslint-disable-line react-hooks/exhaustive-deps -- only run this when the pageSize changes
|
|
6847
|
+
);
|
|
6778
6848
|
return tableRef.current;
|
|
6779
6849
|
}
|
|
6780
6850
|
const MutationsOverTimeGrid = ({
|
|
@@ -6789,10 +6859,6 @@ const MutationsOverTimeGrid = ({
|
|
|
6789
6859
|
return { mutation: allMutations[index], values: [...row] };
|
|
6790
6860
|
});
|
|
6791
6861
|
}, [data]);
|
|
6792
|
-
const [pagination, setPagination] = d({
|
|
6793
|
-
pageIndex: 0,
|
|
6794
|
-
pageSize: typeof pageSizes === "number" ? pageSizes : pageSizes.at(0) ?? 10
|
|
6795
|
-
});
|
|
6796
6862
|
const columns = T$1(() => {
|
|
6797
6863
|
const columnHelper = createColumnHelper();
|
|
6798
6864
|
const dates = data.getSecondAxisKeys();
|
|
@@ -6834,15 +6900,17 @@ const MutationsOverTimeGrid = ({
|
|
|
6834
6900
|
});
|
|
6835
6901
|
return [mutationHeader, ...dateHeaders];
|
|
6836
6902
|
}, [colorScale, data, sequenceType]);
|
|
6903
|
+
const { pageSize } = usePageSizeContext();
|
|
6837
6904
|
const table = usePreactTable({
|
|
6838
6905
|
data: tableData,
|
|
6839
6906
|
columns,
|
|
6840
6907
|
getCoreRowModel: getCoreRowModel(),
|
|
6841
6908
|
getPaginationRowModel: getPaginationRowModel(),
|
|
6842
|
-
|
|
6843
|
-
|
|
6844
|
-
|
|
6845
|
-
|
|
6909
|
+
initialState: {
|
|
6910
|
+
pagination: {
|
|
6911
|
+
pageIndex: 0,
|
|
6912
|
+
pageSize
|
|
6913
|
+
}
|
|
6846
6914
|
}
|
|
6847
6915
|
});
|
|
6848
6916
|
return /* @__PURE__ */ u$1("div", { className: "w-full", children: [
|
|
@@ -6897,6 +6965,40 @@ const ColorScaleSelectorDropdown = ({
|
|
|
6897
6965
|
}) => {
|
|
6898
6966
|
return /* @__PURE__ */ u$1("div", { className: "w-20 inline-flex", children: /* @__PURE__ */ u$1(Dropdown, { buttonTitle: `Color scale`, placement: "bottom-start", children: /* @__PURE__ */ u$1(ColorScaleSelector, { colorScale, setColorScale }) }) });
|
|
6899
6967
|
};
|
|
6968
|
+
function DeleteIcon() {
|
|
6969
|
+
return /* @__PURE__ */ u$1(Fragment, { children: "×" });
|
|
6970
|
+
}
|
|
6971
|
+
function MutationsOverTimeTextFilter({ setFilterValue, value }) {
|
|
6972
|
+
const onInput = (newValue) => {
|
|
6973
|
+
setFilterValue(newValue);
|
|
6974
|
+
};
|
|
6975
|
+
const onDeleteClick = () => setFilterValue("");
|
|
6976
|
+
return /* @__PURE__ */ u$1("div", { className: "w-28 inline-flex", children: /* @__PURE__ */ u$1(Dropdown, { buttonTitle: value === "" ? `Filter mutations` : value, placement: "bottom-start", children: /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1("label", { className: "flex gap-1 input input-xs", children: [
|
|
6977
|
+
/* @__PURE__ */ u$1(DebouncedInput, { placeholder: "Filter", onInput, value, type: "text" }),
|
|
6978
|
+
value !== void 0 && value !== "" && /* @__PURE__ */ u$1("button", { className: "cursor-pointer", onClick: onDeleteClick, children: /* @__PURE__ */ u$1(DeleteIcon, {}) })
|
|
6979
|
+
] }) }) }) });
|
|
6980
|
+
}
|
|
6981
|
+
function DebouncedInput({
|
|
6982
|
+
value: initialValue,
|
|
6983
|
+
onInput,
|
|
6984
|
+
debounce: debounce2 = 500,
|
|
6985
|
+
...props
|
|
6986
|
+
}) {
|
|
6987
|
+
const [value, setValue] = d(initialValue);
|
|
6988
|
+
y(() => {
|
|
6989
|
+
setValue(initialValue);
|
|
6990
|
+
}, [initialValue]);
|
|
6991
|
+
y(() => {
|
|
6992
|
+
const timeout = setTimeout(() => {
|
|
6993
|
+
onInput(value ?? "");
|
|
6994
|
+
}, debounce2);
|
|
6995
|
+
return () => clearTimeout(timeout);
|
|
6996
|
+
}, [value, debounce2, onInput]);
|
|
6997
|
+
const onChangeInput = q$1((event) => {
|
|
6998
|
+
setValue(event.currentTarget.value);
|
|
6999
|
+
}, []);
|
|
7000
|
+
return /* @__PURE__ */ u$1("input", { ...props, value, onInput: onChangeInput });
|
|
7001
|
+
}
|
|
6900
7002
|
function useWebWorker(messageToWorker, WorkerConstructor) {
|
|
6901
7003
|
const [data, setData] = d(void 0);
|
|
6902
7004
|
const [error, setError] = d(void 0);
|
|
@@ -6999,6 +7101,8 @@ const MutationsOverTimeTabs$1 = ({
|
|
|
6999
7101
|
originalComponentProps,
|
|
7000
7102
|
overallMutationData
|
|
7001
7103
|
}) => {
|
|
7104
|
+
const [mutationFilterValue, setMutationFilterValue] = d("");
|
|
7105
|
+
const annotationProvider = useMutationAnnotationsProvider();
|
|
7002
7106
|
const [proportionInterval, setProportionInterval] = d(originalComponentProps.initialMeanProportionInterval);
|
|
7003
7107
|
const [colorScale, setColorScale] = d({ min: 0, max: 1, color: "indigo" });
|
|
7004
7108
|
const [displayedSegments, setDisplayedSegments] = useDisplayedSegments$1(originalComponentProps.sequenceType);
|
|
@@ -7006,7 +7110,6 @@ const MutationsOverTimeTabs$1 = ({
|
|
|
7006
7110
|
{ label: "Substitutions", checked: true, type: "substitution" },
|
|
7007
7111
|
{ label: "Deletions", checked: true, type: "deletion" }
|
|
7008
7112
|
]);
|
|
7009
|
-
const displayMutations = originalComponentProps.displayMutations;
|
|
7010
7113
|
const filteredData = T$1(() => {
|
|
7011
7114
|
return getFilteredMutationOverTimeData$1({
|
|
7012
7115
|
data: mutationOverTimeData,
|
|
@@ -7014,7 +7117,10 @@ const MutationsOverTimeTabs$1 = ({
|
|
|
7014
7117
|
displayedSegments,
|
|
7015
7118
|
displayedMutationTypes,
|
|
7016
7119
|
proportionInterval,
|
|
7017
|
-
displayMutations
|
|
7120
|
+
displayMutations: originalComponentProps.displayMutations,
|
|
7121
|
+
mutationFilterValue,
|
|
7122
|
+
sequenceType: originalComponentProps.sequenceType,
|
|
7123
|
+
annotationProvider
|
|
7018
7124
|
});
|
|
7019
7125
|
}, [
|
|
7020
7126
|
mutationOverTimeData,
|
|
@@ -7022,7 +7128,10 @@ const MutationsOverTimeTabs$1 = ({
|
|
|
7022
7128
|
displayedSegments,
|
|
7023
7129
|
displayedMutationTypes,
|
|
7024
7130
|
proportionInterval,
|
|
7025
|
-
displayMutations
|
|
7131
|
+
originalComponentProps.displayMutations,
|
|
7132
|
+
originalComponentProps.sequenceType,
|
|
7133
|
+
mutationFilterValue,
|
|
7134
|
+
annotationProvider
|
|
7026
7135
|
]);
|
|
7027
7136
|
const getTab = (view) => {
|
|
7028
7137
|
if (filteredData === void 0) {
|
|
@@ -7061,10 +7170,12 @@ const MutationsOverTimeTabs$1 = ({
|
|
|
7061
7170
|
filteredData,
|
|
7062
7171
|
colorScale,
|
|
7063
7172
|
setColorScale,
|
|
7064
|
-
originalComponentProps
|
|
7173
|
+
originalComponentProps,
|
|
7174
|
+
setFilterValue: setMutationFilterValue,
|
|
7175
|
+
mutationFilterValue
|
|
7065
7176
|
}
|
|
7066
7177
|
);
|
|
7067
|
-
return /* @__PURE__ */ u$1(Tabs, { tabs, toolbar });
|
|
7178
|
+
return /* @__PURE__ */ u$1(PageSizeContextProvider, { pageSizes: originalComponentProps.pageSizes, children: /* @__PURE__ */ u$1(Tabs, { tabs, toolbar }) });
|
|
7068
7179
|
};
|
|
7069
7180
|
const Toolbar$2 = ({
|
|
7070
7181
|
activeTab,
|
|
@@ -7077,9 +7188,12 @@ const Toolbar$2 = ({
|
|
|
7077
7188
|
filteredData,
|
|
7078
7189
|
colorScale,
|
|
7079
7190
|
setColorScale,
|
|
7080
|
-
originalComponentProps
|
|
7191
|
+
originalComponentProps,
|
|
7192
|
+
setFilterValue,
|
|
7193
|
+
mutationFilterValue
|
|
7081
7194
|
}) => {
|
|
7082
7195
|
return /* @__PURE__ */ u$1(Fragment, { children: [
|
|
7196
|
+
/* @__PURE__ */ u$1(MutationsOverTimeTextFilter, { setFilterValue, value: mutationFilterValue }),
|
|
7083
7197
|
activeTab === "Grid" && /* @__PURE__ */ u$1(ColorScaleSelectorDropdown, { colorScale, setColorScale }),
|
|
7084
7198
|
/* @__PURE__ */ u$1(
|
|
7085
7199
|
SegmentSelector,
|
|
@@ -8647,7 +8761,7 @@ const MutationsOverTimeTabs = ({
|
|
|
8647
8761
|
setDisplayedSegments
|
|
8648
8762
|
}
|
|
8649
8763
|
);
|
|
8650
|
-
return /* @__PURE__ */ u$1(Tabs, { tabs, toolbar });
|
|
8764
|
+
return /* @__PURE__ */ u$1(PageSizeContextProvider, { pageSizes: originalComponentProps.pageSizes, children: /* @__PURE__ */ u$1(Tabs, { tabs, toolbar }) });
|
|
8651
8765
|
};
|
|
8652
8766
|
const Toolbar = ({
|
|
8653
8767
|
colorScale,
|
|
@@ -8741,6 +8855,802 @@ __decorateClass$5([
|
|
|
8741
8855
|
WastewaterMutationsOverTimeComponent = __decorateClass$5([
|
|
8742
8856
|
t$3("gs-wastewater-mutations-over-time")
|
|
8743
8857
|
], WastewaterMutationsOverTimeComponent);
|
|
8858
|
+
const flatpickrStyle = `.flatpickr-calendar {
|
|
8859
|
+
background: transparent;
|
|
8860
|
+
opacity: 0;
|
|
8861
|
+
display: none;
|
|
8862
|
+
text-align: center;
|
|
8863
|
+
visibility: hidden;
|
|
8864
|
+
padding: 0;
|
|
8865
|
+
-webkit-animation: none;
|
|
8866
|
+
animation: none;
|
|
8867
|
+
direction: ltr;
|
|
8868
|
+
border: 0;
|
|
8869
|
+
font-size: 14px;
|
|
8870
|
+
line-height: 24px;
|
|
8871
|
+
border-radius: 5px;
|
|
8872
|
+
position: absolute;
|
|
8873
|
+
width: 307.875px;
|
|
8874
|
+
-webkit-box-sizing: border-box;
|
|
8875
|
+
box-sizing: border-box;
|
|
8876
|
+
-ms-touch-action: manipulation;
|
|
8877
|
+
touch-action: manipulation;
|
|
8878
|
+
background: #fff;
|
|
8879
|
+
-webkit-box-shadow: 1px 0 0 #e6e6e6, -1px 0 0 #e6e6e6, 0 1px 0 #e6e6e6, 0 -1px 0 #e6e6e6, 0 3px 13px rgba(0,0,0,0.08);
|
|
8880
|
+
box-shadow: 1px 0 0 #e6e6e6, -1px 0 0 #e6e6e6, 0 1px 0 #e6e6e6, 0 -1px 0 #e6e6e6, 0 3px 13px rgba(0,0,0,0.08);
|
|
8881
|
+
}
|
|
8882
|
+
.flatpickr-calendar.open,
|
|
8883
|
+
.flatpickr-calendar.inline {
|
|
8884
|
+
opacity: 1;
|
|
8885
|
+
max-height: 640px;
|
|
8886
|
+
visibility: visible;
|
|
8887
|
+
}
|
|
8888
|
+
.flatpickr-calendar.open {
|
|
8889
|
+
display: inline-block;
|
|
8890
|
+
z-index: 99999;
|
|
8891
|
+
}
|
|
8892
|
+
.flatpickr-calendar.animate.open {
|
|
8893
|
+
-webkit-animation: fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);
|
|
8894
|
+
animation: fpFadeInDown 300ms cubic-bezier(0.23, 1, 0.32, 1);
|
|
8895
|
+
}
|
|
8896
|
+
.flatpickr-calendar.inline {
|
|
8897
|
+
display: block;
|
|
8898
|
+
position: relative;
|
|
8899
|
+
top: 2px;
|
|
8900
|
+
}
|
|
8901
|
+
.flatpickr-calendar.static {
|
|
8902
|
+
position: absolute;
|
|
8903
|
+
top: calc(100% + 2px);
|
|
8904
|
+
}
|
|
8905
|
+
.flatpickr-calendar.static.open {
|
|
8906
|
+
z-index: 999;
|
|
8907
|
+
display: block;
|
|
8908
|
+
}
|
|
8909
|
+
.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+1) .flatpickr-day.inRange:nth-child(7n+7) {
|
|
8910
|
+
-webkit-box-shadow: none !important;
|
|
8911
|
+
box-shadow: none !important;
|
|
8912
|
+
}
|
|
8913
|
+
.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+2) .flatpickr-day.inRange:nth-child(7n+1) {
|
|
8914
|
+
-webkit-box-shadow: -2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;
|
|
8915
|
+
box-shadow: -2px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;
|
|
8916
|
+
}
|
|
8917
|
+
.flatpickr-calendar .hasWeeks .dayContainer,
|
|
8918
|
+
.flatpickr-calendar .hasTime .dayContainer {
|
|
8919
|
+
border-bottom: 0;
|
|
8920
|
+
border-bottom-right-radius: 0;
|
|
8921
|
+
border-bottom-left-radius: 0;
|
|
8922
|
+
}
|
|
8923
|
+
.flatpickr-calendar .hasWeeks .dayContainer {
|
|
8924
|
+
border-left: 0;
|
|
8925
|
+
}
|
|
8926
|
+
.flatpickr-calendar.hasTime .flatpickr-time {
|
|
8927
|
+
height: 40px;
|
|
8928
|
+
border-top: 1px solid #e6e6e6;
|
|
8929
|
+
}
|
|
8930
|
+
.flatpickr-calendar.noCalendar.hasTime .flatpickr-time {
|
|
8931
|
+
height: auto;
|
|
8932
|
+
}
|
|
8933
|
+
.flatpickr-calendar:before,
|
|
8934
|
+
.flatpickr-calendar:after {
|
|
8935
|
+
position: absolute;
|
|
8936
|
+
display: block;
|
|
8937
|
+
pointer-events: none;
|
|
8938
|
+
border: solid transparent;
|
|
8939
|
+
content: '';
|
|
8940
|
+
height: 0;
|
|
8941
|
+
width: 0;
|
|
8942
|
+
left: 22px;
|
|
8943
|
+
}
|
|
8944
|
+
.flatpickr-calendar.rightMost:before,
|
|
8945
|
+
.flatpickr-calendar.arrowRight:before,
|
|
8946
|
+
.flatpickr-calendar.rightMost:after,
|
|
8947
|
+
.flatpickr-calendar.arrowRight:after {
|
|
8948
|
+
left: auto;
|
|
8949
|
+
right: 22px;
|
|
8950
|
+
}
|
|
8951
|
+
.flatpickr-calendar.arrowCenter:before,
|
|
8952
|
+
.flatpickr-calendar.arrowCenter:after {
|
|
8953
|
+
left: 50%;
|
|
8954
|
+
right: 50%;
|
|
8955
|
+
}
|
|
8956
|
+
.flatpickr-calendar:before {
|
|
8957
|
+
border-width: 5px;
|
|
8958
|
+
margin: 0 -5px;
|
|
8959
|
+
}
|
|
8960
|
+
.flatpickr-calendar:after {
|
|
8961
|
+
border-width: 4px;
|
|
8962
|
+
margin: 0 -4px;
|
|
8963
|
+
}
|
|
8964
|
+
.flatpickr-calendar.arrowTop:before,
|
|
8965
|
+
.flatpickr-calendar.arrowTop:after {
|
|
8966
|
+
bottom: 100%;
|
|
8967
|
+
}
|
|
8968
|
+
.flatpickr-calendar.arrowTop:before {
|
|
8969
|
+
border-bottom-color: #e6e6e6;
|
|
8970
|
+
}
|
|
8971
|
+
.flatpickr-calendar.arrowTop:after {
|
|
8972
|
+
border-bottom-color: #fff;
|
|
8973
|
+
}
|
|
8974
|
+
.flatpickr-calendar.arrowBottom:before,
|
|
8975
|
+
.flatpickr-calendar.arrowBottom:after {
|
|
8976
|
+
top: 100%;
|
|
8977
|
+
}
|
|
8978
|
+
.flatpickr-calendar.arrowBottom:before {
|
|
8979
|
+
border-top-color: #e6e6e6;
|
|
8980
|
+
}
|
|
8981
|
+
.flatpickr-calendar.arrowBottom:after {
|
|
8982
|
+
border-top-color: #fff;
|
|
8983
|
+
}
|
|
8984
|
+
.flatpickr-calendar:focus {
|
|
8985
|
+
outline: 0;
|
|
8986
|
+
}
|
|
8987
|
+
.flatpickr-wrapper {
|
|
8988
|
+
position: relative;
|
|
8989
|
+
display: inline-block;
|
|
8990
|
+
}
|
|
8991
|
+
.flatpickr-months {
|
|
8992
|
+
display: -webkit-box;
|
|
8993
|
+
display: -webkit-flex;
|
|
8994
|
+
display: -ms-flexbox;
|
|
8995
|
+
display: flex;
|
|
8996
|
+
}
|
|
8997
|
+
.flatpickr-months .flatpickr-month {
|
|
8998
|
+
background: transparent;
|
|
8999
|
+
color: rgba(0,0,0,0.9);
|
|
9000
|
+
fill: rgba(0,0,0,0.9);
|
|
9001
|
+
height: 34px;
|
|
9002
|
+
line-height: 1;
|
|
9003
|
+
text-align: center;
|
|
9004
|
+
position: relative;
|
|
9005
|
+
-webkit-user-select: none;
|
|
9006
|
+
-moz-user-select: none;
|
|
9007
|
+
-ms-user-select: none;
|
|
9008
|
+
user-select: none;
|
|
9009
|
+
overflow: hidden;
|
|
9010
|
+
-webkit-box-flex: 1;
|
|
9011
|
+
-webkit-flex: 1;
|
|
9012
|
+
-ms-flex: 1;
|
|
9013
|
+
flex: 1;
|
|
9014
|
+
}
|
|
9015
|
+
.flatpickr-months .flatpickr-prev-month,
|
|
9016
|
+
.flatpickr-months .flatpickr-next-month {
|
|
9017
|
+
-webkit-user-select: none;
|
|
9018
|
+
-moz-user-select: none;
|
|
9019
|
+
-ms-user-select: none;
|
|
9020
|
+
user-select: none;
|
|
9021
|
+
text-decoration: none;
|
|
9022
|
+
cursor: pointer;
|
|
9023
|
+
position: absolute;
|
|
9024
|
+
top: 0;
|
|
9025
|
+
height: 34px;
|
|
9026
|
+
padding: 10px;
|
|
9027
|
+
z-index: 3;
|
|
9028
|
+
color: rgba(0,0,0,0.9);
|
|
9029
|
+
fill: rgba(0,0,0,0.9);
|
|
9030
|
+
}
|
|
9031
|
+
.flatpickr-months .flatpickr-prev-month.flatpickr-disabled,
|
|
9032
|
+
.flatpickr-months .flatpickr-next-month.flatpickr-disabled {
|
|
9033
|
+
display: none;
|
|
9034
|
+
}
|
|
9035
|
+
.flatpickr-months .flatpickr-prev-month i,
|
|
9036
|
+
.flatpickr-months .flatpickr-next-month i {
|
|
9037
|
+
position: relative;
|
|
9038
|
+
}
|
|
9039
|
+
.flatpickr-months .flatpickr-prev-month.flatpickr-prev-month,
|
|
9040
|
+
.flatpickr-months .flatpickr-next-month.flatpickr-prev-month {
|
|
9041
|
+
/*
|
|
9042
|
+
/*rtl:begin:ignore*/
|
|
9043
|
+
/*
|
|
9044
|
+
*/
|
|
9045
|
+
left: 0;
|
|
9046
|
+
/*
|
|
9047
|
+
/*rtl:end:ignore*/
|
|
9048
|
+
/*
|
|
9049
|
+
*/
|
|
9050
|
+
}
|
|
9051
|
+
/*
|
|
9052
|
+
/*rtl:begin:ignore*/
|
|
9053
|
+
/*
|
|
9054
|
+
/*rtl:end:ignore*/
|
|
9055
|
+
.flatpickr-months .flatpickr-prev-month.flatpickr-next-month,
|
|
9056
|
+
.flatpickr-months .flatpickr-next-month.flatpickr-next-month {
|
|
9057
|
+
/*
|
|
9058
|
+
/*rtl:begin:ignore*/
|
|
9059
|
+
/*
|
|
9060
|
+
*/
|
|
9061
|
+
right: 0;
|
|
9062
|
+
/*
|
|
9063
|
+
/*rtl:end:ignore*/
|
|
9064
|
+
/*
|
|
9065
|
+
*/
|
|
9066
|
+
}
|
|
9067
|
+
/*
|
|
9068
|
+
/*rtl:begin:ignore*/
|
|
9069
|
+
/*
|
|
9070
|
+
/*rtl:end:ignore*/
|
|
9071
|
+
.flatpickr-months .flatpickr-prev-month:hover,
|
|
9072
|
+
.flatpickr-months .flatpickr-next-month:hover {
|
|
9073
|
+
color: #959ea9;
|
|
9074
|
+
}
|
|
9075
|
+
.flatpickr-months .flatpickr-prev-month:hover svg,
|
|
9076
|
+
.flatpickr-months .flatpickr-next-month:hover svg {
|
|
9077
|
+
fill: #f64747;
|
|
9078
|
+
}
|
|
9079
|
+
.flatpickr-months .flatpickr-prev-month svg,
|
|
9080
|
+
.flatpickr-months .flatpickr-next-month svg {
|
|
9081
|
+
width: 14px;
|
|
9082
|
+
height: 14px;
|
|
9083
|
+
}
|
|
9084
|
+
.flatpickr-months .flatpickr-prev-month svg path,
|
|
9085
|
+
.flatpickr-months .flatpickr-next-month svg path {
|
|
9086
|
+
-webkit-transition: fill 0.1s;
|
|
9087
|
+
transition: fill 0.1s;
|
|
9088
|
+
fill: inherit;
|
|
9089
|
+
}
|
|
9090
|
+
.numInputWrapper {
|
|
9091
|
+
position: relative;
|
|
9092
|
+
height: auto;
|
|
9093
|
+
}
|
|
9094
|
+
.numInputWrapper input,
|
|
9095
|
+
.numInputWrapper span {
|
|
9096
|
+
display: inline-block;
|
|
9097
|
+
}
|
|
9098
|
+
.numInputWrapper input {
|
|
9099
|
+
width: 100%;
|
|
9100
|
+
}
|
|
9101
|
+
.numInputWrapper input::-ms-clear {
|
|
9102
|
+
display: none;
|
|
9103
|
+
}
|
|
9104
|
+
.numInputWrapper input::-webkit-outer-spin-button,
|
|
9105
|
+
.numInputWrapper input::-webkit-inner-spin-button {
|
|
9106
|
+
margin: 0;
|
|
9107
|
+
-webkit-appearance: none;
|
|
9108
|
+
}
|
|
9109
|
+
.numInputWrapper span {
|
|
9110
|
+
position: absolute;
|
|
9111
|
+
right: 0;
|
|
9112
|
+
width: 14px;
|
|
9113
|
+
padding: 0 4px 0 2px;
|
|
9114
|
+
height: 50%;
|
|
9115
|
+
line-height: 50%;
|
|
9116
|
+
opacity: 0;
|
|
9117
|
+
cursor: pointer;
|
|
9118
|
+
border: 1px solid rgba(57,57,57,0.15);
|
|
9119
|
+
-webkit-box-sizing: border-box;
|
|
9120
|
+
box-sizing: border-box;
|
|
9121
|
+
}
|
|
9122
|
+
.numInputWrapper span:hover {
|
|
9123
|
+
background: rgba(0,0,0,0.1);
|
|
9124
|
+
}
|
|
9125
|
+
.numInputWrapper span:active {
|
|
9126
|
+
background: rgba(0,0,0,0.2);
|
|
9127
|
+
}
|
|
9128
|
+
.numInputWrapper span:after {
|
|
9129
|
+
display: block;
|
|
9130
|
+
content: "";
|
|
9131
|
+
position: absolute;
|
|
9132
|
+
}
|
|
9133
|
+
.numInputWrapper span.arrowUp {
|
|
9134
|
+
top: 0;
|
|
9135
|
+
border-bottom: 0;
|
|
9136
|
+
}
|
|
9137
|
+
.numInputWrapper span.arrowUp:after {
|
|
9138
|
+
border-left: 4px solid transparent;
|
|
9139
|
+
border-right: 4px solid transparent;
|
|
9140
|
+
border-bottom: 4px solid rgba(57,57,57,0.6);
|
|
9141
|
+
top: 26%;
|
|
9142
|
+
}
|
|
9143
|
+
.numInputWrapper span.arrowDown {
|
|
9144
|
+
top: 50%;
|
|
9145
|
+
}
|
|
9146
|
+
.numInputWrapper span.arrowDown:after {
|
|
9147
|
+
border-left: 4px solid transparent;
|
|
9148
|
+
border-right: 4px solid transparent;
|
|
9149
|
+
border-top: 4px solid rgba(57,57,57,0.6);
|
|
9150
|
+
top: 40%;
|
|
9151
|
+
}
|
|
9152
|
+
.numInputWrapper span svg {
|
|
9153
|
+
width: inherit;
|
|
9154
|
+
height: auto;
|
|
9155
|
+
}
|
|
9156
|
+
.numInputWrapper span svg path {
|
|
9157
|
+
fill: rgba(0,0,0,0.5);
|
|
9158
|
+
}
|
|
9159
|
+
.numInputWrapper:hover {
|
|
9160
|
+
background: rgba(0,0,0,0.05);
|
|
9161
|
+
}
|
|
9162
|
+
.numInputWrapper:hover span {
|
|
9163
|
+
opacity: 1;
|
|
9164
|
+
}
|
|
9165
|
+
.flatpickr-current-month {
|
|
9166
|
+
font-size: 135%;
|
|
9167
|
+
line-height: inherit;
|
|
9168
|
+
font-weight: 300;
|
|
9169
|
+
color: inherit;
|
|
9170
|
+
position: absolute;
|
|
9171
|
+
width: 75%;
|
|
9172
|
+
left: 12.5%;
|
|
9173
|
+
padding: 7.48px 0 0 0;
|
|
9174
|
+
line-height: 1;
|
|
9175
|
+
height: 34px;
|
|
9176
|
+
display: inline-block;
|
|
9177
|
+
text-align: center;
|
|
9178
|
+
-webkit-transform: translate3d(0px, 0px, 0px);
|
|
9179
|
+
transform: translate3d(0px, 0px, 0px);
|
|
9180
|
+
}
|
|
9181
|
+
.flatpickr-current-month span.cur-month {
|
|
9182
|
+
font-family: inherit;
|
|
9183
|
+
font-weight: 700;
|
|
9184
|
+
color: inherit;
|
|
9185
|
+
display: inline-block;
|
|
9186
|
+
margin-left: 0.5ch;
|
|
9187
|
+
padding: 0;
|
|
9188
|
+
}
|
|
9189
|
+
.flatpickr-current-month span.cur-month:hover {
|
|
9190
|
+
background: rgba(0,0,0,0.05);
|
|
9191
|
+
}
|
|
9192
|
+
.flatpickr-current-month .numInputWrapper {
|
|
9193
|
+
width: 6ch;
|
|
9194
|
+
width: 7ch\\0;
|
|
9195
|
+
display: inline-block;
|
|
9196
|
+
}
|
|
9197
|
+
.flatpickr-current-month .numInputWrapper span.arrowUp:after {
|
|
9198
|
+
border-bottom-color: rgba(0,0,0,0.9);
|
|
9199
|
+
}
|
|
9200
|
+
.flatpickr-current-month .numInputWrapper span.arrowDown:after {
|
|
9201
|
+
border-top-color: rgba(0,0,0,0.9);
|
|
9202
|
+
}
|
|
9203
|
+
.flatpickr-current-month input.cur-year {
|
|
9204
|
+
background: transparent;
|
|
9205
|
+
-webkit-box-sizing: border-box;
|
|
9206
|
+
box-sizing: border-box;
|
|
9207
|
+
color: inherit;
|
|
9208
|
+
cursor: text;
|
|
9209
|
+
padding: 0 0 0 0.5ch;
|
|
9210
|
+
margin: 0;
|
|
9211
|
+
display: inline-block;
|
|
9212
|
+
font-size: inherit;
|
|
9213
|
+
font-family: inherit;
|
|
9214
|
+
font-weight: 300;
|
|
9215
|
+
line-height: inherit;
|
|
9216
|
+
height: auto;
|
|
9217
|
+
border: 0;
|
|
9218
|
+
border-radius: 0;
|
|
9219
|
+
vertical-align: initial;
|
|
9220
|
+
-webkit-appearance: textfield;
|
|
9221
|
+
-moz-appearance: textfield;
|
|
9222
|
+
appearance: textfield;
|
|
9223
|
+
}
|
|
9224
|
+
.flatpickr-current-month input.cur-year:focus {
|
|
9225
|
+
outline: 0;
|
|
9226
|
+
}
|
|
9227
|
+
.flatpickr-current-month input.cur-year[disabled],
|
|
9228
|
+
.flatpickr-current-month input.cur-year[disabled]:hover {
|
|
9229
|
+
font-size: 100%;
|
|
9230
|
+
color: rgba(0,0,0,0.5);
|
|
9231
|
+
background: transparent;
|
|
9232
|
+
pointer-events: none;
|
|
9233
|
+
}
|
|
9234
|
+
.flatpickr-current-month .flatpickr-monthDropdown-months {
|
|
9235
|
+
appearance: menulist;
|
|
9236
|
+
background: transparent;
|
|
9237
|
+
border: none;
|
|
9238
|
+
border-radius: 0;
|
|
9239
|
+
box-sizing: border-box;
|
|
9240
|
+
color: inherit;
|
|
9241
|
+
cursor: pointer;
|
|
9242
|
+
font-size: inherit;
|
|
9243
|
+
font-family: inherit;
|
|
9244
|
+
font-weight: 300;
|
|
9245
|
+
height: auto;
|
|
9246
|
+
line-height: inherit;
|
|
9247
|
+
margin: -1px 0 0 0;
|
|
9248
|
+
outline: none;
|
|
9249
|
+
padding: 0 0 0 0.5ch;
|
|
9250
|
+
position: relative;
|
|
9251
|
+
vertical-align: initial;
|
|
9252
|
+
-webkit-box-sizing: border-box;
|
|
9253
|
+
-webkit-appearance: menulist;
|
|
9254
|
+
-moz-appearance: menulist;
|
|
9255
|
+
width: auto;
|
|
9256
|
+
}
|
|
9257
|
+
.flatpickr-current-month .flatpickr-monthDropdown-months:focus,
|
|
9258
|
+
.flatpickr-current-month .flatpickr-monthDropdown-months:active {
|
|
9259
|
+
outline: none;
|
|
9260
|
+
}
|
|
9261
|
+
.flatpickr-current-month .flatpickr-monthDropdown-months:hover {
|
|
9262
|
+
background: rgba(0,0,0,0.05);
|
|
9263
|
+
}
|
|
9264
|
+
.flatpickr-current-month .flatpickr-monthDropdown-months .flatpickr-monthDropdown-month {
|
|
9265
|
+
background-color: transparent;
|
|
9266
|
+
outline: none;
|
|
9267
|
+
padding: 0;
|
|
9268
|
+
}
|
|
9269
|
+
.flatpickr-weekdays {
|
|
9270
|
+
background: transparent;
|
|
9271
|
+
text-align: center;
|
|
9272
|
+
overflow: hidden;
|
|
9273
|
+
width: 100%;
|
|
9274
|
+
display: -webkit-box;
|
|
9275
|
+
display: -webkit-flex;
|
|
9276
|
+
display: -ms-flexbox;
|
|
9277
|
+
display: flex;
|
|
9278
|
+
-webkit-box-align: center;
|
|
9279
|
+
-webkit-align-items: center;
|
|
9280
|
+
-ms-flex-align: center;
|
|
9281
|
+
align-items: center;
|
|
9282
|
+
height: 28px;
|
|
9283
|
+
}
|
|
9284
|
+
.flatpickr-weekdays .flatpickr-weekdaycontainer {
|
|
9285
|
+
display: -webkit-box;
|
|
9286
|
+
display: -webkit-flex;
|
|
9287
|
+
display: -ms-flexbox;
|
|
9288
|
+
display: flex;
|
|
9289
|
+
-webkit-box-flex: 1;
|
|
9290
|
+
-webkit-flex: 1;
|
|
9291
|
+
-ms-flex: 1;
|
|
9292
|
+
flex: 1;
|
|
9293
|
+
}
|
|
9294
|
+
span.flatpickr-weekday {
|
|
9295
|
+
cursor: default;
|
|
9296
|
+
font-size: 90%;
|
|
9297
|
+
background: transparent;
|
|
9298
|
+
color: rgba(0,0,0,0.54);
|
|
9299
|
+
line-height: 1;
|
|
9300
|
+
margin: 0;
|
|
9301
|
+
text-align: center;
|
|
9302
|
+
display: block;
|
|
9303
|
+
-webkit-box-flex: 1;
|
|
9304
|
+
-webkit-flex: 1;
|
|
9305
|
+
-ms-flex: 1;
|
|
9306
|
+
flex: 1;
|
|
9307
|
+
font-weight: bolder;
|
|
9308
|
+
}
|
|
9309
|
+
.dayContainer,
|
|
9310
|
+
.flatpickr-weeks {
|
|
9311
|
+
padding: 1px 0 0 0;
|
|
9312
|
+
}
|
|
9313
|
+
.flatpickr-days {
|
|
9314
|
+
position: relative;
|
|
9315
|
+
overflow: hidden;
|
|
9316
|
+
display: -webkit-box;
|
|
9317
|
+
display: -webkit-flex;
|
|
9318
|
+
display: -ms-flexbox;
|
|
9319
|
+
display: flex;
|
|
9320
|
+
-webkit-box-align: start;
|
|
9321
|
+
-webkit-align-items: flex-start;
|
|
9322
|
+
-ms-flex-align: start;
|
|
9323
|
+
align-items: flex-start;
|
|
9324
|
+
width: 307.875px;
|
|
9325
|
+
}
|
|
9326
|
+
.flatpickr-days:focus {
|
|
9327
|
+
outline: 0;
|
|
9328
|
+
}
|
|
9329
|
+
.dayContainer {
|
|
9330
|
+
padding: 0;
|
|
9331
|
+
outline: 0;
|
|
9332
|
+
text-align: left;
|
|
9333
|
+
width: 307.875px;
|
|
9334
|
+
min-width: 307.875px;
|
|
9335
|
+
max-width: 307.875px;
|
|
9336
|
+
-webkit-box-sizing: border-box;
|
|
9337
|
+
box-sizing: border-box;
|
|
9338
|
+
display: inline-block;
|
|
9339
|
+
display: -ms-flexbox;
|
|
9340
|
+
display: -webkit-box;
|
|
9341
|
+
display: -webkit-flex;
|
|
9342
|
+
display: flex;
|
|
9343
|
+
-webkit-flex-wrap: wrap;
|
|
9344
|
+
flex-wrap: wrap;
|
|
9345
|
+
-ms-flex-wrap: wrap;
|
|
9346
|
+
-ms-flex-pack: justify;
|
|
9347
|
+
-webkit-justify-content: space-around;
|
|
9348
|
+
justify-content: space-around;
|
|
9349
|
+
-webkit-transform: translate3d(0px, 0px, 0px);
|
|
9350
|
+
transform: translate3d(0px, 0px, 0px);
|
|
9351
|
+
opacity: 1;
|
|
9352
|
+
}
|
|
9353
|
+
.dayContainer + .dayContainer {
|
|
9354
|
+
-webkit-box-shadow: -1px 0 0 #e6e6e6;
|
|
9355
|
+
box-shadow: -1px 0 0 #e6e6e6;
|
|
9356
|
+
}
|
|
9357
|
+
.flatpickr-day {
|
|
9358
|
+
background: none;
|
|
9359
|
+
border: 1px solid transparent;
|
|
9360
|
+
border-radius: 150px;
|
|
9361
|
+
-webkit-box-sizing: border-box;
|
|
9362
|
+
box-sizing: border-box;
|
|
9363
|
+
color: #393939;
|
|
9364
|
+
cursor: pointer;
|
|
9365
|
+
font-weight: 400;
|
|
9366
|
+
width: 14.2857143%;
|
|
9367
|
+
-webkit-flex-basis: 14.2857143%;
|
|
9368
|
+
-ms-flex-preferred-size: 14.2857143%;
|
|
9369
|
+
flex-basis: 14.2857143%;
|
|
9370
|
+
max-width: 39px;
|
|
9371
|
+
height: 39px;
|
|
9372
|
+
line-height: 39px;
|
|
9373
|
+
margin: 0;
|
|
9374
|
+
display: inline-block;
|
|
9375
|
+
position: relative;
|
|
9376
|
+
-webkit-box-pack: center;
|
|
9377
|
+
-webkit-justify-content: center;
|
|
9378
|
+
-ms-flex-pack: center;
|
|
9379
|
+
justify-content: center;
|
|
9380
|
+
text-align: center;
|
|
9381
|
+
}
|
|
9382
|
+
.flatpickr-day.inRange,
|
|
9383
|
+
.flatpickr-day.prevMonthDay.inRange,
|
|
9384
|
+
.flatpickr-day.nextMonthDay.inRange,
|
|
9385
|
+
.flatpickr-day.today.inRange,
|
|
9386
|
+
.flatpickr-day.prevMonthDay.today.inRange,
|
|
9387
|
+
.flatpickr-day.nextMonthDay.today.inRange,
|
|
9388
|
+
.flatpickr-day:hover,
|
|
9389
|
+
.flatpickr-day.prevMonthDay:hover,
|
|
9390
|
+
.flatpickr-day.nextMonthDay:hover,
|
|
9391
|
+
.flatpickr-day:focus,
|
|
9392
|
+
.flatpickr-day.prevMonthDay:focus,
|
|
9393
|
+
.flatpickr-day.nextMonthDay:focus {
|
|
9394
|
+
cursor: pointer;
|
|
9395
|
+
outline: 0;
|
|
9396
|
+
background: #e6e6e6;
|
|
9397
|
+
border-color: #e6e6e6;
|
|
9398
|
+
}
|
|
9399
|
+
.flatpickr-day.today {
|
|
9400
|
+
border-color: #959ea9;
|
|
9401
|
+
}
|
|
9402
|
+
.flatpickr-day.today:hover,
|
|
9403
|
+
.flatpickr-day.today:focus {
|
|
9404
|
+
border-color: #959ea9;
|
|
9405
|
+
background: #959ea9;
|
|
9406
|
+
color: #fff;
|
|
9407
|
+
}
|
|
9408
|
+
.flatpickr-day.selected,
|
|
9409
|
+
.flatpickr-day.startRange,
|
|
9410
|
+
.flatpickr-day.endRange,
|
|
9411
|
+
.flatpickr-day.selected.inRange,
|
|
9412
|
+
.flatpickr-day.startRange.inRange,
|
|
9413
|
+
.flatpickr-day.endRange.inRange,
|
|
9414
|
+
.flatpickr-day.selected:focus,
|
|
9415
|
+
.flatpickr-day.startRange:focus,
|
|
9416
|
+
.flatpickr-day.endRange:focus,
|
|
9417
|
+
.flatpickr-day.selected:hover,
|
|
9418
|
+
.flatpickr-day.startRange:hover,
|
|
9419
|
+
.flatpickr-day.endRange:hover,
|
|
9420
|
+
.flatpickr-day.selected.prevMonthDay,
|
|
9421
|
+
.flatpickr-day.startRange.prevMonthDay,
|
|
9422
|
+
.flatpickr-day.endRange.prevMonthDay,
|
|
9423
|
+
.flatpickr-day.selected.nextMonthDay,
|
|
9424
|
+
.flatpickr-day.startRange.nextMonthDay,
|
|
9425
|
+
.flatpickr-day.endRange.nextMonthDay {
|
|
9426
|
+
background: #569ff7;
|
|
9427
|
+
-webkit-box-shadow: none;
|
|
9428
|
+
box-shadow: none;
|
|
9429
|
+
color: #fff;
|
|
9430
|
+
border-color: #569ff7;
|
|
9431
|
+
}
|
|
9432
|
+
.flatpickr-day.selected.startRange,
|
|
9433
|
+
.flatpickr-day.startRange.startRange,
|
|
9434
|
+
.flatpickr-day.endRange.startRange {
|
|
9435
|
+
border-radius: 50px 0 0 50px;
|
|
9436
|
+
}
|
|
9437
|
+
.flatpickr-day.selected.endRange,
|
|
9438
|
+
.flatpickr-day.startRange.endRange,
|
|
9439
|
+
.flatpickr-day.endRange.endRange {
|
|
9440
|
+
border-radius: 0 50px 50px 0;
|
|
9441
|
+
}
|
|
9442
|
+
.flatpickr-day.selected.startRange + .endRange:not(:nth-child(7n+1)),
|
|
9443
|
+
.flatpickr-day.startRange.startRange + .endRange:not(:nth-child(7n+1)),
|
|
9444
|
+
.flatpickr-day.endRange.startRange + .endRange:not(:nth-child(7n+1)) {
|
|
9445
|
+
-webkit-box-shadow: -10px 0 0 #569ff7;
|
|
9446
|
+
box-shadow: -10px 0 0 #569ff7;
|
|
9447
|
+
}
|
|
9448
|
+
.flatpickr-day.selected.startRange.endRange,
|
|
9449
|
+
.flatpickr-day.startRange.startRange.endRange,
|
|
9450
|
+
.flatpickr-day.endRange.startRange.endRange {
|
|
9451
|
+
border-radius: 50px;
|
|
9452
|
+
}
|
|
9453
|
+
.flatpickr-day.inRange {
|
|
9454
|
+
border-radius: 0;
|
|
9455
|
+
-webkit-box-shadow: -5px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;
|
|
9456
|
+
box-shadow: -5px 0 0 #e6e6e6, 5px 0 0 #e6e6e6;
|
|
9457
|
+
}
|
|
9458
|
+
.flatpickr-day.flatpickr-disabled,
|
|
9459
|
+
.flatpickr-day.flatpickr-disabled:hover,
|
|
9460
|
+
.flatpickr-day.prevMonthDay,
|
|
9461
|
+
.flatpickr-day.nextMonthDay,
|
|
9462
|
+
.flatpickr-day.notAllowed,
|
|
9463
|
+
.flatpickr-day.notAllowed.prevMonthDay,
|
|
9464
|
+
.flatpickr-day.notAllowed.nextMonthDay {
|
|
9465
|
+
color: rgba(57,57,57,0.3);
|
|
9466
|
+
background: transparent;
|
|
9467
|
+
border-color: transparent;
|
|
9468
|
+
cursor: default;
|
|
9469
|
+
}
|
|
9470
|
+
.flatpickr-day.flatpickr-disabled,
|
|
9471
|
+
.flatpickr-day.flatpickr-disabled:hover {
|
|
9472
|
+
cursor: not-allowed;
|
|
9473
|
+
color: rgba(57,57,57,0.1);
|
|
9474
|
+
}
|
|
9475
|
+
.flatpickr-day.week.selected {
|
|
9476
|
+
border-radius: 0;
|
|
9477
|
+
-webkit-box-shadow: -5px 0 0 #569ff7, 5px 0 0 #569ff7;
|
|
9478
|
+
box-shadow: -5px 0 0 #569ff7, 5px 0 0 #569ff7;
|
|
9479
|
+
}
|
|
9480
|
+
.flatpickr-day.hidden {
|
|
9481
|
+
visibility: hidden;
|
|
9482
|
+
}
|
|
9483
|
+
.rangeMode .flatpickr-day {
|
|
9484
|
+
margin-top: 1px;
|
|
9485
|
+
}
|
|
9486
|
+
.flatpickr-weekwrapper {
|
|
9487
|
+
float: left;
|
|
9488
|
+
}
|
|
9489
|
+
.flatpickr-weekwrapper .flatpickr-weeks {
|
|
9490
|
+
padding: 0 12px;
|
|
9491
|
+
-webkit-box-shadow: 1px 0 0 #e6e6e6;
|
|
9492
|
+
box-shadow: 1px 0 0 #e6e6e6;
|
|
9493
|
+
}
|
|
9494
|
+
.flatpickr-weekwrapper .flatpickr-weekday {
|
|
9495
|
+
float: none;
|
|
9496
|
+
width: 100%;
|
|
9497
|
+
line-height: 28px;
|
|
9498
|
+
}
|
|
9499
|
+
.flatpickr-weekwrapper span.flatpickr-day,
|
|
9500
|
+
.flatpickr-weekwrapper span.flatpickr-day:hover {
|
|
9501
|
+
display: block;
|
|
9502
|
+
width: 100%;
|
|
9503
|
+
max-width: none;
|
|
9504
|
+
color: rgba(57,57,57,0.3);
|
|
9505
|
+
background: transparent;
|
|
9506
|
+
cursor: default;
|
|
9507
|
+
border: none;
|
|
9508
|
+
}
|
|
9509
|
+
.flatpickr-innerContainer {
|
|
9510
|
+
display: block;
|
|
9511
|
+
display: -webkit-box;
|
|
9512
|
+
display: -webkit-flex;
|
|
9513
|
+
display: -ms-flexbox;
|
|
9514
|
+
display: flex;
|
|
9515
|
+
-webkit-box-sizing: border-box;
|
|
9516
|
+
box-sizing: border-box;
|
|
9517
|
+
overflow: hidden;
|
|
9518
|
+
}
|
|
9519
|
+
.flatpickr-rContainer {
|
|
9520
|
+
display: inline-block;
|
|
9521
|
+
padding: 0;
|
|
9522
|
+
-webkit-box-sizing: border-box;
|
|
9523
|
+
box-sizing: border-box;
|
|
9524
|
+
}
|
|
9525
|
+
.flatpickr-time {
|
|
9526
|
+
text-align: center;
|
|
9527
|
+
outline: 0;
|
|
9528
|
+
display: block;
|
|
9529
|
+
height: 0;
|
|
9530
|
+
line-height: 40px;
|
|
9531
|
+
max-height: 40px;
|
|
9532
|
+
-webkit-box-sizing: border-box;
|
|
9533
|
+
box-sizing: border-box;
|
|
9534
|
+
overflow: hidden;
|
|
9535
|
+
display: -webkit-box;
|
|
9536
|
+
display: -webkit-flex;
|
|
9537
|
+
display: -ms-flexbox;
|
|
9538
|
+
display: flex;
|
|
9539
|
+
}
|
|
9540
|
+
.flatpickr-time:after {
|
|
9541
|
+
content: "";
|
|
9542
|
+
display: table;
|
|
9543
|
+
clear: both;
|
|
9544
|
+
}
|
|
9545
|
+
.flatpickr-time .numInputWrapper {
|
|
9546
|
+
-webkit-box-flex: 1;
|
|
9547
|
+
-webkit-flex: 1;
|
|
9548
|
+
-ms-flex: 1;
|
|
9549
|
+
flex: 1;
|
|
9550
|
+
width: 40%;
|
|
9551
|
+
height: 40px;
|
|
9552
|
+
float: left;
|
|
9553
|
+
}
|
|
9554
|
+
.flatpickr-time .numInputWrapper span.arrowUp:after {
|
|
9555
|
+
border-bottom-color: #393939;
|
|
9556
|
+
}
|
|
9557
|
+
.flatpickr-time .numInputWrapper span.arrowDown:after {
|
|
9558
|
+
border-top-color: #393939;
|
|
9559
|
+
}
|
|
9560
|
+
.flatpickr-time.hasSeconds .numInputWrapper {
|
|
9561
|
+
width: 26%;
|
|
9562
|
+
}
|
|
9563
|
+
.flatpickr-time.time24hr .numInputWrapper {
|
|
9564
|
+
width: 49%;
|
|
9565
|
+
}
|
|
9566
|
+
.flatpickr-time input {
|
|
9567
|
+
background: transparent;
|
|
9568
|
+
-webkit-box-shadow: none;
|
|
9569
|
+
box-shadow: none;
|
|
9570
|
+
border: 0;
|
|
9571
|
+
border-radius: 0;
|
|
9572
|
+
text-align: center;
|
|
9573
|
+
margin: 0;
|
|
9574
|
+
padding: 0;
|
|
9575
|
+
height: inherit;
|
|
9576
|
+
line-height: inherit;
|
|
9577
|
+
color: #393939;
|
|
9578
|
+
font-size: 14px;
|
|
9579
|
+
position: relative;
|
|
9580
|
+
-webkit-box-sizing: border-box;
|
|
9581
|
+
box-sizing: border-box;
|
|
9582
|
+
-webkit-appearance: textfield;
|
|
9583
|
+
-moz-appearance: textfield;
|
|
9584
|
+
appearance: textfield;
|
|
9585
|
+
}
|
|
9586
|
+
.flatpickr-time input.flatpickr-hour {
|
|
9587
|
+
font-weight: bold;
|
|
9588
|
+
}
|
|
9589
|
+
.flatpickr-time input.flatpickr-minute,
|
|
9590
|
+
.flatpickr-time input.flatpickr-second {
|
|
9591
|
+
font-weight: 400;
|
|
9592
|
+
}
|
|
9593
|
+
.flatpickr-time input:focus {
|
|
9594
|
+
outline: 0;
|
|
9595
|
+
border: 0;
|
|
9596
|
+
}
|
|
9597
|
+
.flatpickr-time .flatpickr-time-separator,
|
|
9598
|
+
.flatpickr-time .flatpickr-am-pm {
|
|
9599
|
+
height: inherit;
|
|
9600
|
+
float: left;
|
|
9601
|
+
line-height: inherit;
|
|
9602
|
+
color: #393939;
|
|
9603
|
+
font-weight: bold;
|
|
9604
|
+
width: 2%;
|
|
9605
|
+
-webkit-user-select: none;
|
|
9606
|
+
-moz-user-select: none;
|
|
9607
|
+
-ms-user-select: none;
|
|
9608
|
+
user-select: none;
|
|
9609
|
+
-webkit-align-self: center;
|
|
9610
|
+
-ms-flex-item-align: center;
|
|
9611
|
+
align-self: center;
|
|
9612
|
+
}
|
|
9613
|
+
.flatpickr-time .flatpickr-am-pm {
|
|
9614
|
+
outline: 0;
|
|
9615
|
+
width: 18%;
|
|
9616
|
+
cursor: pointer;
|
|
9617
|
+
text-align: center;
|
|
9618
|
+
font-weight: 400;
|
|
9619
|
+
}
|
|
9620
|
+
.flatpickr-time input:hover,
|
|
9621
|
+
.flatpickr-time .flatpickr-am-pm:hover,
|
|
9622
|
+
.flatpickr-time input:focus,
|
|
9623
|
+
.flatpickr-time .flatpickr-am-pm:focus {
|
|
9624
|
+
background: #eee;
|
|
9625
|
+
}
|
|
9626
|
+
.flatpickr-input[readonly] {
|
|
9627
|
+
cursor: pointer;
|
|
9628
|
+
}
|
|
9629
|
+
@-webkit-keyframes fpFadeInDown {
|
|
9630
|
+
from {
|
|
9631
|
+
opacity: 0;
|
|
9632
|
+
-webkit-transform: translate3d(0, -20px, 0);
|
|
9633
|
+
transform: translate3d(0, -20px, 0);
|
|
9634
|
+
}
|
|
9635
|
+
to {
|
|
9636
|
+
opacity: 1;
|
|
9637
|
+
-webkit-transform: translate3d(0, 0, 0);
|
|
9638
|
+
transform: translate3d(0, 0, 0);
|
|
9639
|
+
}
|
|
9640
|
+
}
|
|
9641
|
+
@keyframes fpFadeInDown {
|
|
9642
|
+
from {
|
|
9643
|
+
opacity: 0;
|
|
9644
|
+
-webkit-transform: translate3d(0, -20px, 0);
|
|
9645
|
+
transform: translate3d(0, -20px, 0);
|
|
9646
|
+
}
|
|
9647
|
+
to {
|
|
9648
|
+
opacity: 1;
|
|
9649
|
+
-webkit-transform: translate3d(0, 0, 0);
|
|
9650
|
+
transform: translate3d(0, 0, 0);
|
|
9651
|
+
}
|
|
9652
|
+
}
|
|
9653
|
+
`;
|
|
8744
9654
|
const getSelectableOptions = (dateRangeOptions) => {
|
|
8745
9655
|
return dateRangeOptions.map((customSelectOption) => {
|
|
8746
9656
|
return { label: customSelectOption.label, value: customSelectOption.label };
|
|
@@ -8822,8 +9732,9 @@ function DatePicker({
|
|
|
8822
9732
|
}) {
|
|
8823
9733
|
const inputRef = A$1(null);
|
|
8824
9734
|
const [datePicker, setDatePicker] = d(null);
|
|
9735
|
+
const calendarRef = A$1(null);
|
|
8825
9736
|
y(() => {
|
|
8826
|
-
if (!inputRef.current) {
|
|
9737
|
+
if (!inputRef.current || !calendarRef.current) {
|
|
8827
9738
|
return;
|
|
8828
9739
|
}
|
|
8829
9740
|
const instance = flatpickr(inputRef.current, {
|
|
@@ -8831,7 +9742,8 @@ function DatePicker({
|
|
|
8831
9742
|
dateFormat: "Y-m-d",
|
|
8832
9743
|
defaultDate: value,
|
|
8833
9744
|
minDate,
|
|
8834
|
-
maxDate
|
|
9745
|
+
maxDate,
|
|
9746
|
+
appendTo: calendarRef.current
|
|
8835
9747
|
});
|
|
8836
9748
|
setDatePicker(instance);
|
|
8837
9749
|
return () => {
|
|
@@ -8847,20 +9759,20 @@ function DatePicker({
|
|
|
8847
9759
|
onChange(newValue);
|
|
8848
9760
|
}
|
|
8849
9761
|
};
|
|
8850
|
-
return /* @__PURE__ */ u$1(
|
|
8851
|
-
|
|
8852
|
-
|
|
8853
|
-
|
|
8854
|
-
|
|
8855
|
-
|
|
8856
|
-
|
|
8857
|
-
|
|
8858
|
-
|
|
8859
|
-
|
|
8860
|
-
|
|
8861
|
-
|
|
8862
|
-
|
|
8863
|
-
|
|
9762
|
+
return /* @__PURE__ */ u$1("div", { className: "w-full", children: [
|
|
9763
|
+
/* @__PURE__ */ u$1(
|
|
9764
|
+
"input",
|
|
9765
|
+
{
|
|
9766
|
+
className: `input w-full ${className}`,
|
|
9767
|
+
type: "text",
|
|
9768
|
+
placeholder: placeholderText,
|
|
9769
|
+
ref: inputRef,
|
|
9770
|
+
onChange: handleChange,
|
|
9771
|
+
onBlur: handleChange
|
|
9772
|
+
}
|
|
9773
|
+
),
|
|
9774
|
+
/* @__PURE__ */ u$1("div", { ref: calendarRef })
|
|
9775
|
+
] });
|
|
8864
9776
|
}
|
|
8865
9777
|
const undefinedValue = "__undefined__";
|
|
8866
9778
|
function ClearableSelect({
|
|
@@ -9103,6 +10015,7 @@ var __decorateClass$4 = (decorators, target, key, kind) => {
|
|
|
9103
10015
|
if (kind && result) __defProp$4(target, key, result);
|
|
9104
10016
|
return result;
|
|
9105
10017
|
};
|
|
10018
|
+
const flatpickrCss = unsafeCSS(flatpickrStyle);
|
|
9106
10019
|
let DateRangeFilterComponent = class extends PreactLitAdapter {
|
|
9107
10020
|
constructor() {
|
|
9108
10021
|
super(...arguments);
|
|
@@ -9127,6 +10040,7 @@ let DateRangeFilterComponent = class extends PreactLitAdapter {
|
|
|
9127
10040
|
);
|
|
9128
10041
|
}
|
|
9129
10042
|
};
|
|
10043
|
+
DateRangeFilterComponent.styles = [...PreactLitAdapter.styles, flatpickrCss];
|
|
9130
10044
|
__decorateClass$4([
|
|
9131
10045
|
n$1({ type: Array })
|
|
9132
10046
|
], DateRangeFilterComponent.prototype, "dateRangeOptions", 2);
|
|
@@ -9326,7 +10240,7 @@ var U = options.unmount;
|
|
|
9326
10240
|
function V(n3, t2, e2) {
|
|
9327
10241
|
return n3 && (n3.__c && n3.__c.__H && (n3.__c.__H.__.forEach(function(n4) {
|
|
9328
10242
|
"function" == typeof n4.__c && n4.__c();
|
|
9329
|
-
}), n3.__c.__H = null), null != (n3 = g({}, n3)).__c && (n3.__c.__P === e2 && (n3.__c.__P = t2), n3.__c = null), n3.__k = n3.__k && n3.__k.map(function(n4) {
|
|
10243
|
+
}), n3.__c.__H = null), null != (n3 = g({}, n3)).__c && (n3.__c.__P === e2 && (n3.__c.__P = t2), n3.__c.__e = true, n3.__c = null), n3.__k = n3.__k && n3.__k.map(function(n4) {
|
|
9330
10244
|
return V(n4, t2, e2);
|
|
9331
10245
|
})), n3;
|
|
9332
10246
|
}
|
|
@@ -9896,7 +10810,7 @@ const t = (t2) => "object" == typeof t2 && null != t2 && 1 === t2.nodeType, e =
|
|
|
9896
10810
|
}
|
|
9897
10811
|
return L2;
|
|
9898
10812
|
};
|
|
9899
|
-
var propTypes = { exports: {} };
|
|
10813
|
+
var propTypes$2 = { exports: {} };
|
|
9900
10814
|
var reactIs = { exports: {} };
|
|
9901
10815
|
var reactIs_production_min = {};
|
|
9902
10816
|
/** @license React v16.13.1
|
|
@@ -10828,16 +11742,16 @@ function requireFactoryWithThrowingShims() {
|
|
|
10828
11742
|
}
|
|
10829
11743
|
var hasRequiredPropTypes;
|
|
10830
11744
|
function requirePropTypes() {
|
|
10831
|
-
if (hasRequiredPropTypes) return propTypes.exports;
|
|
11745
|
+
if (hasRequiredPropTypes) return propTypes$2.exports;
|
|
10832
11746
|
hasRequiredPropTypes = 1;
|
|
10833
11747
|
if (process.env.NODE_ENV !== "production") {
|
|
10834
11748
|
var ReactIs = requireReactIs();
|
|
10835
11749
|
var throwOnDirectAccess = true;
|
|
10836
|
-
propTypes.exports = /* @__PURE__ */ requireFactoryWithTypeCheckers()(ReactIs.isElement, throwOnDirectAccess);
|
|
11750
|
+
propTypes$2.exports = /* @__PURE__ */ requireFactoryWithTypeCheckers()(ReactIs.isElement, throwOnDirectAccess);
|
|
10837
11751
|
} else {
|
|
10838
|
-
propTypes.exports = /* @__PURE__ */ requireFactoryWithThrowingShims()();
|
|
11752
|
+
propTypes$2.exports = /* @__PURE__ */ requireFactoryWithThrowingShims()();
|
|
10839
11753
|
}
|
|
10840
|
-
return propTypes.exports;
|
|
11754
|
+
return propTypes$2.exports;
|
|
10841
11755
|
}
|
|
10842
11756
|
var propTypesExports = /* @__PURE__ */ requirePropTypes();
|
|
10843
11757
|
const PropTypes = /* @__PURE__ */ getDefaultExportFromCjs(propTypesExports);
|
|
@@ -11157,7 +12071,7 @@ function useLatestRef(val) {
|
|
|
11157
12071
|
ref.current = val;
|
|
11158
12072
|
return ref;
|
|
11159
12073
|
}
|
|
11160
|
-
function useEnhancedReducer(reducer, props, createInitialState,
|
|
12074
|
+
function useEnhancedReducer(reducer, props, createInitialState, isStateEqual2) {
|
|
11161
12075
|
var prevStateRef = A$1();
|
|
11162
12076
|
var actionRef = A$1();
|
|
11163
12077
|
var enhancedReducer = q$1(function(state2, action2) {
|
|
@@ -11179,14 +12093,18 @@ function useEnhancedReducer(reducer, props, createInitialState, isStateEqual) {
|
|
|
11179
12093
|
var action = actionRef.current;
|
|
11180
12094
|
y(function() {
|
|
11181
12095
|
var prevState = getState(prevStateRef.current, action == null ? void 0 : action.props);
|
|
11182
|
-
var shouldCallOnChangeProps = action && prevStateRef.current && !
|
|
12096
|
+
var shouldCallOnChangeProps = action && prevStateRef.current && !isStateEqual2(prevState, state);
|
|
11183
12097
|
if (shouldCallOnChangeProps) {
|
|
11184
12098
|
callOnChangeProps(action, prevState, state);
|
|
11185
12099
|
}
|
|
11186
12100
|
prevStateRef.current = state;
|
|
11187
|
-
}, [state, action,
|
|
12101
|
+
}, [state, action, isStateEqual2]);
|
|
11188
12102
|
return [state, dispatchWithProps];
|
|
11189
12103
|
}
|
|
12104
|
+
function useControlledReducer$1(reducer, props, createInitialState, isStateEqual2) {
|
|
12105
|
+
var _useEnhancedReducer = useEnhancedReducer(reducer, props, createInitialState, isStateEqual2), state = _useEnhancedReducer[0], dispatch = _useEnhancedReducer[1];
|
|
12106
|
+
return [getState(state, props), dispatch];
|
|
12107
|
+
}
|
|
11190
12108
|
var defaultProps$3 = {
|
|
11191
12109
|
itemToString: function itemToString(item) {
|
|
11192
12110
|
return item ? String(item) : "";
|
|
@@ -11201,19 +12119,19 @@ var defaultProps$3 = {
|
|
|
11201
12119
|
typeof window === "undefined" || false ? void 0 : window
|
|
11202
12120
|
)
|
|
11203
12121
|
};
|
|
11204
|
-
function getDefaultValue$1(props, propKey,
|
|
11205
|
-
if (
|
|
11206
|
-
|
|
12122
|
+
function getDefaultValue$1(props, propKey, defaultStateValues2) {
|
|
12123
|
+
if (defaultStateValues2 === void 0) {
|
|
12124
|
+
defaultStateValues2 = dropdownDefaultStateValues;
|
|
11207
12125
|
}
|
|
11208
12126
|
var defaultValue = props["default" + capitalizeString(propKey)];
|
|
11209
12127
|
if (defaultValue !== void 0) {
|
|
11210
12128
|
return defaultValue;
|
|
11211
12129
|
}
|
|
11212
|
-
return
|
|
12130
|
+
return defaultStateValues2[propKey];
|
|
11213
12131
|
}
|
|
11214
|
-
function getInitialValue$1(props, propKey,
|
|
11215
|
-
if (
|
|
11216
|
-
|
|
12132
|
+
function getInitialValue$1(props, propKey, defaultStateValues2) {
|
|
12133
|
+
if (defaultStateValues2 === void 0) {
|
|
12134
|
+
defaultStateValues2 = dropdownDefaultStateValues;
|
|
11217
12135
|
}
|
|
11218
12136
|
var value = props[propKey];
|
|
11219
12137
|
if (value !== void 0) {
|
|
@@ -11223,7 +12141,7 @@ function getInitialValue$1(props, propKey, defaultStateValues) {
|
|
|
11223
12141
|
if (initialValue !== void 0) {
|
|
11224
12142
|
return initialValue;
|
|
11225
12143
|
}
|
|
11226
|
-
return getDefaultValue$1(props, propKey,
|
|
12144
|
+
return getDefaultValue$1(props, propKey, defaultStateValues2);
|
|
11227
12145
|
}
|
|
11228
12146
|
function getInitialState$2(props) {
|
|
11229
12147
|
var selectedItem = getInitialValue$1(props, "selectedItem");
|
|
@@ -11485,49 +12403,49 @@ var commonDropdownPropTypes = _extends({}, commonPropTypes, {
|
|
|
11485
12403
|
onIsOpenChange: PropTypes.func,
|
|
11486
12404
|
scrollIntoView: PropTypes.func
|
|
11487
12405
|
});
|
|
11488
|
-
function downshiftCommonReducer(state, action,
|
|
12406
|
+
function downshiftCommonReducer(state, action, stateChangeTypes2) {
|
|
11489
12407
|
var type = action.type, props = action.props;
|
|
11490
12408
|
var changes;
|
|
11491
12409
|
switch (type) {
|
|
11492
|
-
case
|
|
12410
|
+
case stateChangeTypes2.ItemMouseMove:
|
|
11493
12411
|
changes = {
|
|
11494
12412
|
highlightedIndex: action.disabled ? -1 : action.index
|
|
11495
12413
|
};
|
|
11496
12414
|
break;
|
|
11497
|
-
case
|
|
12415
|
+
case stateChangeTypes2.MenuMouseLeave:
|
|
11498
12416
|
changes = {
|
|
11499
12417
|
highlightedIndex: -1
|
|
11500
12418
|
};
|
|
11501
12419
|
break;
|
|
11502
|
-
case
|
|
11503
|
-
case
|
|
12420
|
+
case stateChangeTypes2.ToggleButtonClick:
|
|
12421
|
+
case stateChangeTypes2.FunctionToggleMenu:
|
|
11504
12422
|
changes = {
|
|
11505
12423
|
isOpen: !state.isOpen,
|
|
11506
12424
|
highlightedIndex: state.isOpen ? -1 : getHighlightedIndexOnOpen(props, state, 0)
|
|
11507
12425
|
};
|
|
11508
12426
|
break;
|
|
11509
|
-
case
|
|
12427
|
+
case stateChangeTypes2.FunctionOpenMenu:
|
|
11510
12428
|
changes = {
|
|
11511
12429
|
isOpen: true,
|
|
11512
12430
|
highlightedIndex: getHighlightedIndexOnOpen(props, state, 0)
|
|
11513
12431
|
};
|
|
11514
12432
|
break;
|
|
11515
|
-
case
|
|
12433
|
+
case stateChangeTypes2.FunctionCloseMenu:
|
|
11516
12434
|
changes = {
|
|
11517
12435
|
isOpen: false
|
|
11518
12436
|
};
|
|
11519
12437
|
break;
|
|
11520
|
-
case
|
|
12438
|
+
case stateChangeTypes2.FunctionSetHighlightedIndex:
|
|
11521
12439
|
changes = {
|
|
11522
12440
|
highlightedIndex: props.isItemDisabled(props.items[action.highlightedIndex], action.highlightedIndex) ? -1 : action.highlightedIndex
|
|
11523
12441
|
};
|
|
11524
12442
|
break;
|
|
11525
|
-
case
|
|
12443
|
+
case stateChangeTypes2.FunctionSetInputValue:
|
|
11526
12444
|
changes = {
|
|
11527
12445
|
inputValue: action.inputValue
|
|
11528
12446
|
};
|
|
11529
12447
|
break;
|
|
11530
|
-
case
|
|
12448
|
+
case stateChangeTypes2.FunctionReset:
|
|
11531
12449
|
changes = {
|
|
11532
12450
|
highlightedIndex: getDefaultHighlightedIndex(props),
|
|
11533
12451
|
isOpen: getDefaultValue$1(props, "isOpen"),
|
|
@@ -11636,9 +12554,9 @@ var propTypes$1 = _extends({}, commonDropdownPropTypes, {
|
|
|
11636
12554
|
inputId: PropTypes.string,
|
|
11637
12555
|
onInputValueChange: PropTypes.func
|
|
11638
12556
|
});
|
|
11639
|
-
function useControlledReducer(reducer, props, createInitialState,
|
|
12557
|
+
function useControlledReducer(reducer, props, createInitialState, isStateEqual2) {
|
|
11640
12558
|
var previousSelectedItemRef = A$1();
|
|
11641
|
-
var _useEnhancedReducer = useEnhancedReducer(reducer, props, createInitialState,
|
|
12559
|
+
var _useEnhancedReducer = useEnhancedReducer(reducer, props, createInitialState, isStateEqual2), state = _useEnhancedReducer[0], dispatch = _useEnhancedReducer[1];
|
|
11642
12560
|
var isInitialMount = useIsInitialMount();
|
|
11643
12561
|
y(function() {
|
|
11644
12562
|
if (!isControlledProp(props, "selectedItem")) {
|
|
@@ -11659,7 +12577,7 @@ function useControlledReducer(reducer, props, createInitialState, isStateEqual)
|
|
|
11659
12577
|
}
|
|
11660
12578
|
var validatePropTypes$1 = noop;
|
|
11661
12579
|
if (process.env.NODE_ENV !== "production") {
|
|
11662
|
-
validatePropTypes$1 = function
|
|
12580
|
+
validatePropTypes$1 = function validatePropTypes2(options2, caller) {
|
|
11663
12581
|
PropTypes.checkPropTypes(propTypes$1, options2, "prop", caller.name);
|
|
11664
12582
|
};
|
|
11665
12583
|
}
|
|
@@ -12106,7 +13024,41 @@ function useCombobox(userProps) {
|
|
|
12106
13024
|
inputValue
|
|
12107
13025
|
};
|
|
12108
13026
|
}
|
|
12109
|
-
|
|
13027
|
+
var defaultStateValues = {
|
|
13028
|
+
activeIndex: -1,
|
|
13029
|
+
selectedItems: []
|
|
13030
|
+
};
|
|
13031
|
+
function getInitialValue(props, propKey) {
|
|
13032
|
+
return getInitialValue$1(props, propKey, defaultStateValues);
|
|
13033
|
+
}
|
|
13034
|
+
function getDefaultValue(props, propKey) {
|
|
13035
|
+
return getDefaultValue$1(props, propKey, defaultStateValues);
|
|
13036
|
+
}
|
|
13037
|
+
function getInitialState$3(props) {
|
|
13038
|
+
var activeIndex = getInitialValue(props, "activeIndex");
|
|
13039
|
+
var selectedItems = getInitialValue(props, "selectedItems");
|
|
13040
|
+
return {
|
|
13041
|
+
activeIndex,
|
|
13042
|
+
selectedItems
|
|
13043
|
+
};
|
|
13044
|
+
}
|
|
13045
|
+
function isKeyDownOperationPermitted(event) {
|
|
13046
|
+
if (event.shiftKey || event.metaKey || event.ctrlKey || event.altKey) {
|
|
13047
|
+
return false;
|
|
13048
|
+
}
|
|
13049
|
+
var element = event.target;
|
|
13050
|
+
if (element instanceof HTMLInputElement && // if element is a text input
|
|
13051
|
+
element.value !== "" && // and we have text in it
|
|
13052
|
+
// and cursor is either not at the start or is currently highlighting text.
|
|
13053
|
+
(element.selectionStart !== 0 || element.selectionEnd !== 0)) {
|
|
13054
|
+
return false;
|
|
13055
|
+
}
|
|
13056
|
+
return true;
|
|
13057
|
+
}
|
|
13058
|
+
function isStateEqual(prevState, newState) {
|
|
13059
|
+
return prevState.selectedItems === newState.selectedItems && prevState.activeIndex === newState.activeIndex;
|
|
13060
|
+
}
|
|
13061
|
+
var propTypes = {
|
|
12110
13062
|
stateReducer: commonPropTypes.stateReducer,
|
|
12111
13063
|
itemToKey: commonPropTypes.itemToKey,
|
|
12112
13064
|
environment: commonPropTypes.environment,
|
|
@@ -12121,26 +13073,312 @@ function useCombobox(userProps) {
|
|
|
12121
13073
|
onSelectedItemsChange: PropTypes.func,
|
|
12122
13074
|
keyNavigationNext: PropTypes.string,
|
|
12123
13075
|
keyNavigationPrevious: PropTypes.string
|
|
12124
|
-
}
|
|
12125
|
-
|
|
13076
|
+
};
|
|
13077
|
+
var defaultProps = {
|
|
12126
13078
|
itemToKey: defaultProps$3.itemToKey,
|
|
12127
13079
|
stateReducer: defaultProps$3.stateReducer,
|
|
12128
|
-
environment: defaultProps$3.environment
|
|
13080
|
+
environment: defaultProps$3.environment,
|
|
13081
|
+
keyNavigationNext: "ArrowRight",
|
|
13082
|
+
keyNavigationPrevious: "ArrowLeft"
|
|
13083
|
+
};
|
|
13084
|
+
var validatePropTypes = noop;
|
|
13085
|
+
if (process.env.NODE_ENV !== "production") {
|
|
13086
|
+
validatePropTypes = function validatePropTypes2(options2, caller) {
|
|
13087
|
+
PropTypes.checkPropTypes(propTypes, options2, "prop", caller.name);
|
|
13088
|
+
};
|
|
13089
|
+
}
|
|
13090
|
+
var SelectedItemClick = process.env.NODE_ENV !== "production" ? "__selected_item_click__" : 0;
|
|
13091
|
+
var SelectedItemKeyDownDelete = process.env.NODE_ENV !== "production" ? "__selected_item_keydown_delete__" : 1;
|
|
13092
|
+
var SelectedItemKeyDownBackspace = process.env.NODE_ENV !== "production" ? "__selected_item_keydown_backspace__" : 2;
|
|
13093
|
+
var SelectedItemKeyDownNavigationNext = process.env.NODE_ENV !== "production" ? "__selected_item_keydown_navigation_next__" : 3;
|
|
13094
|
+
var SelectedItemKeyDownNavigationPrevious = process.env.NODE_ENV !== "production" ? "__selected_item_keydown_navigation_previous__" : 4;
|
|
13095
|
+
var DropdownKeyDownNavigationPrevious = process.env.NODE_ENV !== "production" ? "__dropdown_keydown_navigation_previous__" : 5;
|
|
13096
|
+
var DropdownKeyDownBackspace = process.env.NODE_ENV !== "production" ? "__dropdown_keydown_backspace__" : 6;
|
|
13097
|
+
var DropdownClick = process.env.NODE_ENV !== "production" ? "__dropdown_click__" : 7;
|
|
13098
|
+
var FunctionAddSelectedItem = process.env.NODE_ENV !== "production" ? "__function_add_selected_item__" : 8;
|
|
13099
|
+
var FunctionRemoveSelectedItem = process.env.NODE_ENV !== "production" ? "__function_remove_selected_item__" : 9;
|
|
13100
|
+
var FunctionSetSelectedItems = process.env.NODE_ENV !== "production" ? "__function_set_selected_items__" : 10;
|
|
13101
|
+
var FunctionSetActiveIndex = process.env.NODE_ENV !== "production" ? "__function_set_active_index__" : 11;
|
|
13102
|
+
var FunctionReset = process.env.NODE_ENV !== "production" ? "__function_reset__" : 12;
|
|
13103
|
+
var stateChangeTypes = /* @__PURE__ */ Object.freeze({
|
|
13104
|
+
__proto__: null,
|
|
13105
|
+
DropdownClick,
|
|
13106
|
+
DropdownKeyDownBackspace,
|
|
13107
|
+
DropdownKeyDownNavigationPrevious,
|
|
13108
|
+
FunctionAddSelectedItem,
|
|
13109
|
+
FunctionRemoveSelectedItem,
|
|
13110
|
+
FunctionReset,
|
|
13111
|
+
FunctionSetActiveIndex,
|
|
13112
|
+
FunctionSetSelectedItems,
|
|
13113
|
+
SelectedItemClick,
|
|
13114
|
+
SelectedItemKeyDownBackspace,
|
|
13115
|
+
SelectedItemKeyDownDelete,
|
|
13116
|
+
SelectedItemKeyDownNavigationNext,
|
|
13117
|
+
SelectedItemKeyDownNavigationPrevious
|
|
12129
13118
|
});
|
|
12130
|
-
|
|
12131
|
-
|
|
12132
|
-
|
|
12133
|
-
|
|
12134
|
-
|
|
12135
|
-
|
|
12136
|
-
|
|
12137
|
-
|
|
12138
|
-
|
|
12139
|
-
|
|
12140
|
-
|
|
12141
|
-
|
|
12142
|
-
|
|
12143
|
-
|
|
13119
|
+
function downshiftMultipleSelectionReducer(state, action) {
|
|
13120
|
+
var type = action.type, index = action.index, props = action.props, selectedItem = action.selectedItem;
|
|
13121
|
+
var activeIndex = state.activeIndex, selectedItems = state.selectedItems;
|
|
13122
|
+
var changes;
|
|
13123
|
+
switch (type) {
|
|
13124
|
+
case SelectedItemClick:
|
|
13125
|
+
changes = {
|
|
13126
|
+
activeIndex: index
|
|
13127
|
+
};
|
|
13128
|
+
break;
|
|
13129
|
+
case SelectedItemKeyDownNavigationPrevious:
|
|
13130
|
+
changes = {
|
|
13131
|
+
activeIndex: activeIndex - 1 < 0 ? 0 : activeIndex - 1
|
|
13132
|
+
};
|
|
13133
|
+
break;
|
|
13134
|
+
case SelectedItemKeyDownNavigationNext:
|
|
13135
|
+
changes = {
|
|
13136
|
+
activeIndex: activeIndex + 1 >= selectedItems.length ? -1 : activeIndex + 1
|
|
13137
|
+
};
|
|
13138
|
+
break;
|
|
13139
|
+
case SelectedItemKeyDownBackspace:
|
|
13140
|
+
case SelectedItemKeyDownDelete: {
|
|
13141
|
+
if (activeIndex < 0) {
|
|
13142
|
+
break;
|
|
13143
|
+
}
|
|
13144
|
+
var newActiveIndex = activeIndex;
|
|
13145
|
+
if (selectedItems.length === 1) {
|
|
13146
|
+
newActiveIndex = -1;
|
|
13147
|
+
} else if (activeIndex === selectedItems.length - 1) {
|
|
13148
|
+
newActiveIndex = selectedItems.length - 2;
|
|
13149
|
+
}
|
|
13150
|
+
changes = _extends({
|
|
13151
|
+
selectedItems: [].concat(selectedItems.slice(0, activeIndex), selectedItems.slice(activeIndex + 1))
|
|
13152
|
+
}, {
|
|
13153
|
+
activeIndex: newActiveIndex
|
|
13154
|
+
});
|
|
13155
|
+
break;
|
|
13156
|
+
}
|
|
13157
|
+
case DropdownKeyDownNavigationPrevious:
|
|
13158
|
+
changes = {
|
|
13159
|
+
activeIndex: selectedItems.length - 1
|
|
13160
|
+
};
|
|
13161
|
+
break;
|
|
13162
|
+
case DropdownKeyDownBackspace:
|
|
13163
|
+
changes = {
|
|
13164
|
+
selectedItems: selectedItems.slice(0, selectedItems.length - 1)
|
|
13165
|
+
};
|
|
13166
|
+
break;
|
|
13167
|
+
case FunctionAddSelectedItem:
|
|
13168
|
+
changes = {
|
|
13169
|
+
selectedItems: [].concat(selectedItems, [selectedItem])
|
|
13170
|
+
};
|
|
13171
|
+
break;
|
|
13172
|
+
case DropdownClick:
|
|
13173
|
+
changes = {
|
|
13174
|
+
activeIndex: -1
|
|
13175
|
+
};
|
|
13176
|
+
break;
|
|
13177
|
+
case FunctionRemoveSelectedItem: {
|
|
13178
|
+
var _newActiveIndex = activeIndex;
|
|
13179
|
+
var selectedItemIndex = selectedItems.findIndex(function(item) {
|
|
13180
|
+
return props.itemToKey(item) === props.itemToKey(selectedItem);
|
|
13181
|
+
});
|
|
13182
|
+
if (selectedItemIndex < 0) {
|
|
13183
|
+
break;
|
|
13184
|
+
}
|
|
13185
|
+
if (selectedItems.length === 1) {
|
|
13186
|
+
_newActiveIndex = -1;
|
|
13187
|
+
} else if (selectedItemIndex === selectedItems.length - 1) {
|
|
13188
|
+
_newActiveIndex = selectedItems.length - 2;
|
|
13189
|
+
}
|
|
13190
|
+
changes = {
|
|
13191
|
+
selectedItems: [].concat(selectedItems.slice(0, selectedItemIndex), selectedItems.slice(selectedItemIndex + 1)),
|
|
13192
|
+
activeIndex: _newActiveIndex
|
|
13193
|
+
};
|
|
13194
|
+
break;
|
|
13195
|
+
}
|
|
13196
|
+
case FunctionSetSelectedItems: {
|
|
13197
|
+
var newSelectedItems = action.selectedItems;
|
|
13198
|
+
changes = {
|
|
13199
|
+
selectedItems: newSelectedItems
|
|
13200
|
+
};
|
|
13201
|
+
break;
|
|
13202
|
+
}
|
|
13203
|
+
case FunctionSetActiveIndex: {
|
|
13204
|
+
var _newActiveIndex2 = action.activeIndex;
|
|
13205
|
+
changes = {
|
|
13206
|
+
activeIndex: _newActiveIndex2
|
|
13207
|
+
};
|
|
13208
|
+
break;
|
|
13209
|
+
}
|
|
13210
|
+
case FunctionReset:
|
|
13211
|
+
changes = {
|
|
13212
|
+
activeIndex: getDefaultValue(props, "activeIndex"),
|
|
13213
|
+
selectedItems: getDefaultValue(props, "selectedItems")
|
|
13214
|
+
};
|
|
13215
|
+
break;
|
|
13216
|
+
default:
|
|
13217
|
+
throw new Error("Reducer called without proper action type.");
|
|
13218
|
+
}
|
|
13219
|
+
return _extends({}, state, changes);
|
|
13220
|
+
}
|
|
13221
|
+
var _excluded = ["refKey", "ref", "onClick", "onKeyDown", "selectedItem", "index"], _excluded2 = ["refKey", "ref", "onKeyDown", "onClick", "preventKeyAction"];
|
|
13222
|
+
useMultipleSelection.stateChangeTypes = stateChangeTypes;
|
|
13223
|
+
function useMultipleSelection(userProps) {
|
|
13224
|
+
if (userProps === void 0) {
|
|
13225
|
+
userProps = {};
|
|
13226
|
+
}
|
|
13227
|
+
validatePropTypes(userProps, useMultipleSelection);
|
|
13228
|
+
var props = _extends({}, defaultProps, userProps);
|
|
13229
|
+
var getA11yStatusMessage = props.getA11yStatusMessage, environment = props.environment, keyNavigationNext = props.keyNavigationNext, keyNavigationPrevious = props.keyNavigationPrevious;
|
|
13230
|
+
var _useControlledReducer = useControlledReducer$1(downshiftMultipleSelectionReducer, props, getInitialState$3, isStateEqual), state = _useControlledReducer[0], dispatch = _useControlledReducer[1];
|
|
13231
|
+
var activeIndex = state.activeIndex, selectedItems = state.selectedItems;
|
|
13232
|
+
var isInitialMount = useIsInitialMount();
|
|
13233
|
+
var dropdownRef = A$1(null);
|
|
13234
|
+
var selectedItemRefs = A$1();
|
|
13235
|
+
selectedItemRefs.current = [];
|
|
13236
|
+
var latest = useLatestRef({
|
|
13237
|
+
state,
|
|
13238
|
+
props
|
|
13239
|
+
});
|
|
13240
|
+
useA11yMessageStatus(getA11yStatusMessage, state, [activeIndex, selectedItems], environment);
|
|
13241
|
+
y(function() {
|
|
13242
|
+
if (isInitialMount) {
|
|
13243
|
+
return;
|
|
13244
|
+
}
|
|
13245
|
+
if (activeIndex === -1 && dropdownRef.current) {
|
|
13246
|
+
dropdownRef.current.focus();
|
|
13247
|
+
} else if (selectedItemRefs.current[activeIndex]) {
|
|
13248
|
+
selectedItemRefs.current[activeIndex].focus();
|
|
13249
|
+
}
|
|
13250
|
+
}, [activeIndex]);
|
|
13251
|
+
useControlPropsValidator({
|
|
13252
|
+
props,
|
|
13253
|
+
state
|
|
13254
|
+
});
|
|
13255
|
+
var setGetterPropCallInfo = useGetterPropsCalledChecker("getDropdownProps");
|
|
13256
|
+
var selectedItemKeyDownHandlers = T$1(function() {
|
|
13257
|
+
var _ref;
|
|
13258
|
+
return _ref = {}, _ref[keyNavigationPrevious] = function() {
|
|
13259
|
+
dispatch({
|
|
13260
|
+
type: SelectedItemKeyDownNavigationPrevious
|
|
13261
|
+
});
|
|
13262
|
+
}, _ref[keyNavigationNext] = function() {
|
|
13263
|
+
dispatch({
|
|
13264
|
+
type: SelectedItemKeyDownNavigationNext
|
|
13265
|
+
});
|
|
13266
|
+
}, _ref.Delete = function Delete() {
|
|
13267
|
+
dispatch({
|
|
13268
|
+
type: SelectedItemKeyDownDelete
|
|
13269
|
+
});
|
|
13270
|
+
}, _ref.Backspace = function Backspace() {
|
|
13271
|
+
dispatch({
|
|
13272
|
+
type: SelectedItemKeyDownBackspace
|
|
13273
|
+
});
|
|
13274
|
+
}, _ref;
|
|
13275
|
+
}, [dispatch, keyNavigationNext, keyNavigationPrevious]);
|
|
13276
|
+
var dropdownKeyDownHandlers = T$1(function() {
|
|
13277
|
+
var _ref2;
|
|
13278
|
+
return _ref2 = {}, _ref2[keyNavigationPrevious] = function(event) {
|
|
13279
|
+
if (isKeyDownOperationPermitted(event)) {
|
|
13280
|
+
dispatch({
|
|
13281
|
+
type: DropdownKeyDownNavigationPrevious
|
|
13282
|
+
});
|
|
13283
|
+
}
|
|
13284
|
+
}, _ref2.Backspace = function Backspace(event) {
|
|
13285
|
+
if (isKeyDownOperationPermitted(event)) {
|
|
13286
|
+
dispatch({
|
|
13287
|
+
type: DropdownKeyDownBackspace
|
|
13288
|
+
});
|
|
13289
|
+
}
|
|
13290
|
+
}, _ref2;
|
|
13291
|
+
}, [dispatch, keyNavigationPrevious]);
|
|
13292
|
+
var getSelectedItemProps = q$1(function(_temp) {
|
|
13293
|
+
var _extends2;
|
|
13294
|
+
var _ref3 = _temp === void 0 ? {} : _temp, _ref3$refKey = _ref3.refKey, refKey = _ref3$refKey === void 0 ? "ref" : _ref3$refKey, ref = _ref3.ref, onClick = _ref3.onClick, onKeyDown = _ref3.onKeyDown, selectedItemProp = _ref3.selectedItem, indexProp = _ref3.index, rest = _objectWithoutPropertiesLoose(_ref3, _excluded);
|
|
13295
|
+
var latestState = latest.current.state;
|
|
13296
|
+
var _getItemAndIndex = getItemAndIndex(selectedItemProp, indexProp, latestState.selectedItems, "Pass either item or index to getSelectedItemProps!"), index = _getItemAndIndex[1];
|
|
13297
|
+
var isFocusable = index > -1 && index === latestState.activeIndex;
|
|
13298
|
+
var selectedItemHandleClick = function selectedItemHandleClick2() {
|
|
13299
|
+
dispatch({
|
|
13300
|
+
type: SelectedItemClick,
|
|
13301
|
+
index
|
|
13302
|
+
});
|
|
13303
|
+
};
|
|
13304
|
+
var selectedItemHandleKeyDown = function selectedItemHandleKeyDown2(event) {
|
|
13305
|
+
var key = normalizeArrowKey(event);
|
|
13306
|
+
if (key && selectedItemKeyDownHandlers[key]) {
|
|
13307
|
+
selectedItemKeyDownHandlers[key](event);
|
|
13308
|
+
}
|
|
13309
|
+
};
|
|
13310
|
+
return _extends((_extends2 = {}, _extends2[refKey] = handleRefs(ref, function(selectedItemNode) {
|
|
13311
|
+
if (selectedItemNode) {
|
|
13312
|
+
selectedItemRefs.current.push(selectedItemNode);
|
|
13313
|
+
}
|
|
13314
|
+
}), _extends2.tabIndex = isFocusable ? 0 : -1, _extends2.onClick = callAllEventHandlers(onClick, selectedItemHandleClick), _extends2.onKeyDown = callAllEventHandlers(onKeyDown, selectedItemHandleKeyDown), _extends2), rest);
|
|
13315
|
+
}, [dispatch, latest, selectedItemKeyDownHandlers]);
|
|
13316
|
+
var getDropdownProps = q$1(function(_temp2, _temp3) {
|
|
13317
|
+
var _extends3;
|
|
13318
|
+
var _ref4 = _temp2 === void 0 ? {} : _temp2, _ref4$refKey = _ref4.refKey, refKey = _ref4$refKey === void 0 ? "ref" : _ref4$refKey, ref = _ref4.ref, onKeyDown = _ref4.onKeyDown, onClick = _ref4.onClick, _ref4$preventKeyActio = _ref4.preventKeyAction, preventKeyAction = _ref4$preventKeyActio === void 0 ? false : _ref4$preventKeyActio, rest = _objectWithoutPropertiesLoose(_ref4, _excluded2);
|
|
13319
|
+
var _ref5 = _temp3 === void 0 ? {} : _temp3, _ref5$suppressRefErro = _ref5.suppressRefError, suppressRefError = _ref5$suppressRefErro === void 0 ? false : _ref5$suppressRefErro;
|
|
13320
|
+
setGetterPropCallInfo("getDropdownProps", suppressRefError, refKey, dropdownRef);
|
|
13321
|
+
var dropdownHandleKeyDown = function dropdownHandleKeyDown2(event) {
|
|
13322
|
+
var key = normalizeArrowKey(event);
|
|
13323
|
+
if (key && dropdownKeyDownHandlers[key]) {
|
|
13324
|
+
dropdownKeyDownHandlers[key](event);
|
|
13325
|
+
}
|
|
13326
|
+
};
|
|
13327
|
+
var dropdownHandleClick = function dropdownHandleClick2() {
|
|
13328
|
+
dispatch({
|
|
13329
|
+
type: DropdownClick
|
|
13330
|
+
});
|
|
13331
|
+
};
|
|
13332
|
+
return _extends((_extends3 = {}, _extends3[refKey] = handleRefs(ref, function(dropdownNode) {
|
|
13333
|
+
if (dropdownNode) {
|
|
13334
|
+
dropdownRef.current = dropdownNode;
|
|
13335
|
+
}
|
|
13336
|
+
}), _extends3), !preventKeyAction && {
|
|
13337
|
+
onKeyDown: callAllEventHandlers(onKeyDown, dropdownHandleKeyDown),
|
|
13338
|
+
onClick: callAllEventHandlers(onClick, dropdownHandleClick)
|
|
13339
|
+
}, rest);
|
|
13340
|
+
}, [dispatch, dropdownKeyDownHandlers, setGetterPropCallInfo]);
|
|
13341
|
+
var addSelectedItem = q$1(function(selectedItem) {
|
|
13342
|
+
dispatch({
|
|
13343
|
+
type: FunctionAddSelectedItem,
|
|
13344
|
+
selectedItem
|
|
13345
|
+
});
|
|
13346
|
+
}, [dispatch]);
|
|
13347
|
+
var removeSelectedItem = q$1(function(selectedItem) {
|
|
13348
|
+
dispatch({
|
|
13349
|
+
type: FunctionRemoveSelectedItem,
|
|
13350
|
+
selectedItem
|
|
13351
|
+
});
|
|
13352
|
+
}, [dispatch]);
|
|
13353
|
+
var setSelectedItems = q$1(function(newSelectedItems) {
|
|
13354
|
+
dispatch({
|
|
13355
|
+
type: FunctionSetSelectedItems,
|
|
13356
|
+
selectedItems: newSelectedItems
|
|
13357
|
+
});
|
|
13358
|
+
}, [dispatch]);
|
|
13359
|
+
var setActiveIndex = q$1(function(newActiveIndex) {
|
|
13360
|
+
dispatch({
|
|
13361
|
+
type: FunctionSetActiveIndex,
|
|
13362
|
+
activeIndex: newActiveIndex
|
|
13363
|
+
});
|
|
13364
|
+
}, [dispatch]);
|
|
13365
|
+
var reset = q$1(function() {
|
|
13366
|
+
dispatch({
|
|
13367
|
+
type: FunctionReset
|
|
13368
|
+
});
|
|
13369
|
+
}, [dispatch]);
|
|
13370
|
+
return {
|
|
13371
|
+
getSelectedItemProps,
|
|
13372
|
+
getDropdownProps,
|
|
13373
|
+
addSelectedItem,
|
|
13374
|
+
removeSelectedItem,
|
|
13375
|
+
setSelectedItems,
|
|
13376
|
+
setActiveIndex,
|
|
13377
|
+
reset,
|
|
13378
|
+
selectedItems,
|
|
13379
|
+
activeIndex
|
|
13380
|
+
};
|
|
13381
|
+
}
|
|
12144
13382
|
function DownshiftCombobox({
|
|
12145
13383
|
allItems,
|
|
12146
13384
|
value,
|
|
@@ -12934,12 +14172,35 @@ const sequenceTypeFromSegment = (possibleSegment, referenceGenome) => {
|
|
|
12934
14172
|
return void 0;
|
|
12935
14173
|
};
|
|
12936
14174
|
const parseAndValidateMutation = (value, referenceGenome) => {
|
|
14175
|
+
const possibleMutation = parseMutation(value, referenceGenome);
|
|
14176
|
+
if (possibleMutation === null) {
|
|
14177
|
+
return null;
|
|
14178
|
+
}
|
|
14179
|
+
const sequenceType = getSequenceType(possibleMutation.type);
|
|
14180
|
+
const isOutside = isOutsideReferenceGenome(possibleMutation.value, referenceGenome, sequenceType);
|
|
14181
|
+
if (isOutside) {
|
|
14182
|
+
return null;
|
|
14183
|
+
}
|
|
14184
|
+
return possibleMutation;
|
|
14185
|
+
};
|
|
14186
|
+
const getSequenceType = (type) => {
|
|
14187
|
+
switch (type) {
|
|
14188
|
+
case "nucleotideInsertions":
|
|
14189
|
+
case "nucleotideMutations":
|
|
14190
|
+
return "nucleotide";
|
|
14191
|
+
case "aminoAcidInsertions":
|
|
14192
|
+
case "aminoAcidMutations":
|
|
14193
|
+
return "amino acid";
|
|
14194
|
+
}
|
|
14195
|
+
};
|
|
14196
|
+
const parseMutation = (value, referenceGenome) => {
|
|
12937
14197
|
const possibleInsertion = InsertionClass.parse(value);
|
|
12938
14198
|
if (possibleInsertion !== null) {
|
|
12939
14199
|
const sequenceType = sequenceTypeFromSegment(possibleInsertion.segment, referenceGenome);
|
|
12940
14200
|
switch (sequenceType) {
|
|
12941
|
-
case "nucleotide":
|
|
14201
|
+
case "nucleotide": {
|
|
12942
14202
|
return { type: "nucleotideInsertions", value: possibleInsertion };
|
|
14203
|
+
}
|
|
12943
14204
|
case "amino acid":
|
|
12944
14205
|
return { type: "aminoAcidInsertions", value: possibleInsertion };
|
|
12945
14206
|
case void 0:
|
|
@@ -12962,16 +14223,41 @@ const parseAndValidateMutation = (value, referenceGenome) => {
|
|
|
12962
14223
|
if (possibleSubstitution !== null) {
|
|
12963
14224
|
const sequenceType = sequenceTypeFromSegment(possibleSubstitution.segment, referenceGenome);
|
|
12964
14225
|
switch (sequenceType) {
|
|
12965
|
-
case "nucleotide":
|
|
14226
|
+
case "nucleotide": {
|
|
12966
14227
|
return { type: "nucleotideMutations", value: possibleSubstitution };
|
|
12967
|
-
|
|
14228
|
+
}
|
|
14229
|
+
case "amino acid": {
|
|
12968
14230
|
return { type: "aminoAcidMutations", value: possibleSubstitution };
|
|
14231
|
+
}
|
|
12969
14232
|
case void 0:
|
|
12970
14233
|
return null;
|
|
12971
14234
|
}
|
|
12972
14235
|
}
|
|
12973
14236
|
return null;
|
|
12974
14237
|
};
|
|
14238
|
+
function isOutsideReferenceGenome(mutation, referenceGenome, sequenceType) {
|
|
14239
|
+
const lengthOfSegment = getLengthOfSegment(mutation.segment, referenceGenome, sequenceType);
|
|
14240
|
+
if (lengthOfSegment === void 0) {
|
|
14241
|
+
return true;
|
|
14242
|
+
}
|
|
14243
|
+
return mutation.position >= lengthOfSegment;
|
|
14244
|
+
}
|
|
14245
|
+
function getLengthOfSegment(segment, referenceGenome, sequenceType) {
|
|
14246
|
+
var _a, _b, _c;
|
|
14247
|
+
switch (sequenceType) {
|
|
14248
|
+
case "nucleotide": {
|
|
14249
|
+
if (referenceGenome.nucleotideSequences.length === 1) {
|
|
14250
|
+
return (_a = referenceGenome.nucleotideSequences.at(0)) == null ? void 0 : _a.sequence.length;
|
|
14251
|
+
}
|
|
14252
|
+
return (_b = referenceGenome.nucleotideSequences.find(
|
|
14253
|
+
(sequence) => sequence.name.toUpperCase() === (segment == null ? void 0 : segment.toUpperCase())
|
|
14254
|
+
)) == null ? void 0 : _b.sequence.length;
|
|
14255
|
+
}
|
|
14256
|
+
case "amino acid": {
|
|
14257
|
+
return (_c = referenceGenome.genes.find((gene) => gene.name.toUpperCase() === (segment == null ? void 0 : segment.toUpperCase()))) == null ? void 0 : _c.sequence.length;
|
|
14258
|
+
}
|
|
14259
|
+
}
|
|
14260
|
+
}
|
|
12975
14261
|
const mutationFilterInnerPropsSchema = z$2.object({
|
|
12976
14262
|
initialValue: z$2.union([mutationsFilterSchema.optional(), z$2.array(z$2.string()), z$2.undefined()])
|
|
12977
14263
|
});
|
|
@@ -12983,38 +14269,30 @@ const MutationFilter = (props) => {
|
|
|
12983
14269
|
return /* @__PURE__ */ u$1(
|
|
12984
14270
|
ErrorBoundary,
|
|
12985
14271
|
{
|
|
12986
|
-
size: { height: "
|
|
14272
|
+
size: { height: "40px", width },
|
|
12987
14273
|
layout: "horizontal",
|
|
12988
14274
|
schema: mutationFilterPropsSchema,
|
|
12989
14275
|
componentProps: props,
|
|
12990
|
-
children: /* @__PURE__ */ u$1("div", { style: width, children: /* @__PURE__ */ u$1(MutationFilterInner, { initialValue }) })
|
|
14276
|
+
children: /* @__PURE__ */ u$1("div", { style: { width }, children: /* @__PURE__ */ u$1(MutationFilterInner, { initialValue }) })
|
|
12991
14277
|
}
|
|
12992
14278
|
);
|
|
12993
14279
|
};
|
|
12994
|
-
|
|
14280
|
+
function MutationFilterInner({ initialValue }) {
|
|
14281
|
+
var _a;
|
|
12995
14282
|
const referenceGenome = x$1(ReferenceGenomeContext);
|
|
12996
|
-
const [selectedFilters, setSelectedFilters] = d(
|
|
12997
|
-
getInitialState(initialValue, referenceGenome)
|
|
12998
|
-
);
|
|
12999
14283
|
const filterRef = A$1(null);
|
|
13000
|
-
|
|
13001
|
-
|
|
13002
|
-
|
|
13003
|
-
|
|
13004
|
-
|
|
13005
|
-
|
|
13006
|
-
const
|
|
13007
|
-
|
|
13008
|
-
|
|
13009
|
-
|
|
13010
|
-
|
|
13011
|
-
|
|
13012
|
-
fireChangeEvent(newSelectedFilters);
|
|
13013
|
-
};
|
|
13014
|
-
const fireChangeEvent = (selectedFilters2) => {
|
|
13015
|
-
var _a;
|
|
13016
|
-
const detail = mapToMutationFilterStrings(selectedFilters2);
|
|
13017
|
-
(_a = filterRef.current) == null ? void 0 : _a.dispatchEvent(
|
|
14284
|
+
const [inputValue, setInputValue] = d("");
|
|
14285
|
+
const initialState = T$1(() => {
|
|
14286
|
+
return getInitialState(initialValue, referenceGenome);
|
|
14287
|
+
}, [initialValue, referenceGenome]);
|
|
14288
|
+
const [selectedItems, setSelectedItems] = d(initialState);
|
|
14289
|
+
const [itemCandidate, setItemCandidate] = d(null);
|
|
14290
|
+
const [showErrorIndicator, setShowErrorIndicator] = d(false);
|
|
14291
|
+
const items = itemCandidate ? [itemCandidate] : [];
|
|
14292
|
+
const fireChangeEvent = (selectedFilters) => {
|
|
14293
|
+
var _a2;
|
|
14294
|
+
const detail = mapToMutationFilterStrings(selectedFilters);
|
|
14295
|
+
(_a2 = filterRef.current) == null ? void 0 : _a2.dispatchEvent(
|
|
13018
14296
|
new CustomEvent("gs-mutation-filter-changed", {
|
|
13019
14297
|
detail,
|
|
13020
14298
|
bubbles: true,
|
|
@@ -13022,152 +14300,155 @@ const MutationFilterInner = ({ initialValue }) => {
|
|
|
13022
14300
|
})
|
|
13023
14301
|
);
|
|
13024
14302
|
};
|
|
13025
|
-
|
|
13026
|
-
|
|
13027
|
-
|
|
13028
|
-
|
|
13029
|
-
|
|
13030
|
-
|
|
13031
|
-
|
|
13032
|
-
|
|
13033
|
-
|
|
13034
|
-
|
|
13035
|
-
},
|
|
13036
|
-
selectedFilters
|
|
13037
|
-
}
|
|
13038
|
-
),
|
|
13039
|
-
/* @__PURE__ */ u$1(
|
|
13040
|
-
SelectedMutationFilterDisplay,
|
|
13041
|
-
{
|
|
13042
|
-
selectedFilters,
|
|
13043
|
-
handleRemoveValue
|
|
13044
|
-
}
|
|
13045
|
-
)
|
|
13046
|
-
] })
|
|
13047
|
-
] });
|
|
13048
|
-
};
|
|
13049
|
-
function getInitialState(initialValue, referenceGenome) {
|
|
13050
|
-
if (initialValue === void 0) {
|
|
13051
|
-
return {
|
|
13052
|
-
nucleotideMutations: [],
|
|
13053
|
-
aminoAcidMutations: [],
|
|
13054
|
-
nucleotideInsertions: [],
|
|
13055
|
-
aminoAcidInsertions: []
|
|
13056
|
-
};
|
|
13057
|
-
}
|
|
13058
|
-
const values = Array.isArray(initialValue) ? initialValue : Object.values(initialValue).flatMap((it) => it);
|
|
13059
|
-
return values.reduce(
|
|
13060
|
-
(selectedFilters, value) => {
|
|
13061
|
-
const parsedMutation = parseAndValidateMutation(value, referenceGenome);
|
|
13062
|
-
if (parsedMutation === null) {
|
|
13063
|
-
return selectedFilters;
|
|
13064
|
-
}
|
|
13065
|
-
return {
|
|
13066
|
-
...selectedFilters,
|
|
13067
|
-
[parsedMutation.type]: [...selectedFilters[parsedMutation.type], parsedMutation.value]
|
|
13068
|
-
};
|
|
13069
|
-
},
|
|
13070
|
-
{
|
|
13071
|
-
nucleotideMutations: [],
|
|
13072
|
-
aminoAcidMutations: [],
|
|
13073
|
-
nucleotideInsertions: [],
|
|
13074
|
-
aminoAcidInsertions: []
|
|
14303
|
+
const handleSelectedItemsChanged = (newSelectedItems) => {
|
|
14304
|
+
fireChangeEvent(newSelectedItems);
|
|
14305
|
+
setSelectedItems(newSelectedItems);
|
|
14306
|
+
};
|
|
14307
|
+
const handleNewSelectedItem = (selectedItem2) => {
|
|
14308
|
+
if (selectedItem2) {
|
|
14309
|
+
handleSelectedItemsChanged([...selectedItems, selectedItem2]);
|
|
14310
|
+
setInputValue("");
|
|
14311
|
+
setItemCandidate(null);
|
|
14312
|
+
setShowErrorIndicator(false);
|
|
13075
14313
|
}
|
|
13076
|
-
|
|
13077
|
-
|
|
13078
|
-
|
|
13079
|
-
|
|
13080
|
-
|
|
13081
|
-
|
|
13082
|
-
|
|
13083
|
-
|
|
13084
|
-
|
|
14314
|
+
};
|
|
14315
|
+
const handleInputChange = (newInputValue) => {
|
|
14316
|
+
setShowErrorIndicator(false);
|
|
14317
|
+
if (newInputValue == null ? void 0 : newInputValue.includes(",")) {
|
|
14318
|
+
const values = newInputValue == null ? void 0 : newInputValue.split(",").map((value) => {
|
|
14319
|
+
return { value, parsedValue: parseAndValidateMutation(value.trim(), referenceGenome) };
|
|
14320
|
+
});
|
|
14321
|
+
const validEntries = values.map((value) => value.parsedValue).filter((value) => value !== null);
|
|
14322
|
+
const invalidInput = values.filter((value) => value.parsedValue === null).map((value) => value.value.trim()).join(",");
|
|
14323
|
+
const selectedItemCandidates = [...selectedItems, ...validEntries];
|
|
14324
|
+
handleSelectedItemsChanged(extractUniqueValues(selectedItemCandidates));
|
|
14325
|
+
setInputValue(invalidInput);
|
|
14326
|
+
setItemCandidate(null);
|
|
13085
14327
|
} else {
|
|
13086
|
-
setInputValue(
|
|
13087
|
-
|
|
13088
|
-
|
|
13089
|
-
|
|
13090
|
-
|
|
13091
|
-
|
|
13092
|
-
|
|
13093
|
-
|
|
13094
|
-
let updated = false;
|
|
13095
|
-
const invalidQueries = [];
|
|
13096
|
-
for (const value of inputValues) {
|
|
13097
|
-
const trimmedValue = value.trim();
|
|
13098
|
-
const parsedMutation = parseAndValidateMutation(trimmedValue, referenceGenome);
|
|
13099
|
-
if (parsedMutation) {
|
|
13100
|
-
const type = parsedMutation.type;
|
|
13101
|
-
if (!selectedFilters[type].some((i2) => parsedMutation.value.toString() === i2.toString())) {
|
|
13102
|
-
newSelectedOptions = {
|
|
13103
|
-
...newSelectedOptions,
|
|
13104
|
-
[parsedMutation.type]: [...newSelectedOptions[parsedMutation.type], parsedMutation.value]
|
|
13105
|
-
};
|
|
13106
|
-
updated = true;
|
|
14328
|
+
setInputValue(newInputValue ?? "");
|
|
14329
|
+
if (newInputValue !== void 0) {
|
|
14330
|
+
const candidate = parseAndValidateMutation(newInputValue, referenceGenome);
|
|
14331
|
+
const alreadyExists = selectedItems.find(
|
|
14332
|
+
(selectedItem2) => selectedItem2.value.code === (candidate == null ? void 0 : candidate.value.code)
|
|
14333
|
+
);
|
|
14334
|
+
if (!alreadyExists) {
|
|
14335
|
+
setItemCandidate(candidate);
|
|
13107
14336
|
}
|
|
13108
|
-
} else {
|
|
13109
|
-
invalidQueries.push(trimmedValue);
|
|
13110
14337
|
}
|
|
13111
14338
|
}
|
|
13112
|
-
setInputValue(invalidQueries.join(","));
|
|
13113
|
-
if (updated) {
|
|
13114
|
-
setSelectedFilters(newSelectedOptions);
|
|
13115
|
-
setOption(null);
|
|
13116
|
-
}
|
|
13117
|
-
};
|
|
13118
|
-
const handleOptionClick = () => {
|
|
13119
|
-
if (option === null) {
|
|
13120
|
-
return;
|
|
13121
|
-
}
|
|
13122
|
-
const type = option.type;
|
|
13123
|
-
if (!selectedFilters[type].some((i2) => option.value.toString() === i2.toString())) {
|
|
13124
|
-
const newSelectedValues = {
|
|
13125
|
-
...selectedFilters,
|
|
13126
|
-
[option == null ? void 0 : option.type]: [...selectedFilters[option == null ? void 0 : option.type], option == null ? void 0 : option.value]
|
|
13127
|
-
};
|
|
13128
|
-
setSelectedFilters(newSelectedValues);
|
|
13129
|
-
}
|
|
13130
|
-
setInputValue("");
|
|
13131
|
-
setOption(null);
|
|
13132
|
-
};
|
|
13133
|
-
const handleEnterPress = (event) => {
|
|
13134
|
-
if (event.key === "Enter" && option !== null) {
|
|
13135
|
-
handleOptionClick();
|
|
13136
|
-
}
|
|
13137
|
-
};
|
|
13138
|
-
const handleBlur = (event) => {
|
|
13139
|
-
var _a;
|
|
13140
|
-
if (!((_a = selectorRef.current) == null ? void 0 : _a.contains(event.relatedTarget))) {
|
|
13141
|
-
setOption(null);
|
|
13142
|
-
}
|
|
13143
14339
|
};
|
|
13144
|
-
|
|
13145
|
-
|
|
13146
|
-
|
|
13147
|
-
|
|
13148
|
-
|
|
13149
|
-
|
|
13150
|
-
|
|
13151
|
-
|
|
13152
|
-
|
|
13153
|
-
|
|
13154
|
-
|
|
13155
|
-
|
|
13156
|
-
|
|
13157
|
-
|
|
14340
|
+
const shadowRoot = ((_a = filterRef.current) == null ? void 0 : _a.shadowRoot) ?? void 0;
|
|
14341
|
+
const environment = shadowRoot !== void 0 ? {
|
|
14342
|
+
addEventListener: window.addEventListener.bind(window),
|
|
14343
|
+
removeEventListener: window.removeEventListener.bind(window),
|
|
14344
|
+
document: shadowRoot.ownerDocument,
|
|
14345
|
+
Node: window.Node
|
|
14346
|
+
} : void 0;
|
|
14347
|
+
const { getDropdownProps, removeSelectedItem } = useMultipleSelection({
|
|
14348
|
+
selectedItems,
|
|
14349
|
+
onStateChange({ selectedItems: newSelectedItems, type }) {
|
|
14350
|
+
switch (type) {
|
|
14351
|
+
case useMultipleSelection.stateChangeTypes.FunctionRemoveSelectedItem:
|
|
14352
|
+
handleSelectedItemsChanged(newSelectedItems ?? []);
|
|
14353
|
+
break;
|
|
13158
14354
|
}
|
|
13159
|
-
|
|
13160
|
-
|
|
13161
|
-
|
|
14355
|
+
},
|
|
14356
|
+
environment
|
|
14357
|
+
});
|
|
14358
|
+
const { isOpen, getMenuProps, getInputProps, highlightedIndex, getItemProps, selectedItem } = useCombobox({
|
|
14359
|
+
items,
|
|
14360
|
+
itemToString(item) {
|
|
14361
|
+
return item ? item.value.code : "";
|
|
14362
|
+
},
|
|
14363
|
+
defaultHighlightedIndex: 0,
|
|
14364
|
+
inputValue,
|
|
14365
|
+
onStateChange({ inputValue: newInputValue, type, selectedItem: newSelectedItem }) {
|
|
14366
|
+
switch (type) {
|
|
14367
|
+
case useCombobox.stateChangeTypes.InputKeyDownEnter:
|
|
14368
|
+
case useCombobox.stateChangeTypes.ItemClick:
|
|
14369
|
+
case useCombobox.stateChangeTypes.InputBlur:
|
|
14370
|
+
handleNewSelectedItem(newSelectedItem);
|
|
14371
|
+
break;
|
|
14372
|
+
case useCombobox.stateChangeTypes.InputChange: {
|
|
14373
|
+
handleInputChange(newInputValue);
|
|
14374
|
+
break;
|
|
14375
|
+
}
|
|
14376
|
+
}
|
|
14377
|
+
},
|
|
14378
|
+
environment
|
|
14379
|
+
});
|
|
14380
|
+
if (referenceGenome.nucleotideSequences.length === 0 && referenceGenome.genes.length === 0) {
|
|
14381
|
+
throw new UserFacingError(
|
|
14382
|
+
"No reference sequences available",
|
|
14383
|
+
"This organism has neither nucleotide nor amino acid sequences configured in its reference genome. You cannot filter by mutations."
|
|
14384
|
+
);
|
|
14385
|
+
}
|
|
14386
|
+
return /* @__PURE__ */ u$1("div", { className: "w-full", ref: filterRef, children: [
|
|
14387
|
+
/* @__PURE__ */ u$1("div", { className: `flex gap-x-1 flex-wrap p-1 input h-fit w-full ${showErrorIndicator ? "input-error" : ""}`, children: [
|
|
14388
|
+
selectedItems.map((selectedItemForRender, index) => {
|
|
14389
|
+
return /* @__PURE__ */ u$1("div", { className: "my-1", children: /* @__PURE__ */ u$1(
|
|
14390
|
+
SelectedFilter,
|
|
14391
|
+
{
|
|
14392
|
+
handleRemoveValue: () => {
|
|
14393
|
+
removeSelectedItem(selectedItemForRender);
|
|
14394
|
+
},
|
|
14395
|
+
mutationFilter: selectedItemForRender
|
|
14396
|
+
}
|
|
14397
|
+
) }, `selected-item-${index}`);
|
|
14398
|
+
}),
|
|
14399
|
+
/* @__PURE__ */ u$1("div", { className: "flex gap-0.5 grow p-1", children: [
|
|
14400
|
+
/* @__PURE__ */ u$1(
|
|
14401
|
+
"input",
|
|
14402
|
+
{
|
|
14403
|
+
placeholder: getPlaceholder(referenceGenome),
|
|
14404
|
+
className: "w-full focus:outline-none min-w-8",
|
|
14405
|
+
...getInputProps(getDropdownProps({ preventKeyAction: isOpen })),
|
|
14406
|
+
onBlur: () => {
|
|
14407
|
+
setShowErrorIndicator(inputValue !== "");
|
|
14408
|
+
},
|
|
14409
|
+
size: 10
|
|
14410
|
+
}
|
|
14411
|
+
),
|
|
14412
|
+
/* @__PURE__ */ u$1(MutationFilterInfo, {})
|
|
14413
|
+
] })
|
|
14414
|
+
] }),
|
|
14415
|
+
/* @__PURE__ */ u$1(
|
|
14416
|
+
"ul",
|
|
13162
14417
|
{
|
|
13163
|
-
|
|
13164
|
-
|
|
13165
|
-
|
|
13166
|
-
|
|
14418
|
+
className: `absolute w-inherit bg-white mt-1 shadow-md max-h-80 overflow-scroll p-0 z-10 ${!isOpen && "hidden"}`,
|
|
14419
|
+
...getMenuProps(),
|
|
14420
|
+
children: items.map((item, index) => /* @__PURE__ */ u$1(
|
|
14421
|
+
"li",
|
|
14422
|
+
{
|
|
14423
|
+
className: `${highlightedIndex === index && "bg-blue-300"} ${selectedItem === item && "font-bold"} py-2 px-3 shadow-sm flex flex-col cursor-pointer`,
|
|
14424
|
+
...getItemProps({ item, index }),
|
|
14425
|
+
style: {
|
|
14426
|
+
backgroundColor: backgroundColorMap(item, highlightedIndex === index ? 0.4 : 0.2)
|
|
14427
|
+
},
|
|
14428
|
+
children: /* @__PURE__ */ u$1("span", { children: item.value.code })
|
|
14429
|
+
},
|
|
14430
|
+
`${item.value.code}${index}`
|
|
14431
|
+
))
|
|
13167
14432
|
}
|
|
13168
14433
|
)
|
|
13169
14434
|
] });
|
|
13170
|
-
}
|
|
14435
|
+
}
|
|
14436
|
+
function extractUniqueValues(newSelectedItems) {
|
|
14437
|
+
const uniqueMutationsMap = /* @__PURE__ */ new Map();
|
|
14438
|
+
for (const mutation of newSelectedItems) {
|
|
14439
|
+
if (!uniqueMutationsMap.has(mutation.value.code)) {
|
|
14440
|
+
uniqueMutationsMap.set(mutation.value.code, mutation);
|
|
14441
|
+
}
|
|
14442
|
+
}
|
|
14443
|
+
return Array.from(uniqueMutationsMap.values());
|
|
14444
|
+
}
|
|
14445
|
+
function getInitialState(initialValue, referenceGenome) {
|
|
14446
|
+
if (initialValue === void 0) {
|
|
14447
|
+
return [];
|
|
14448
|
+
}
|
|
14449
|
+
const values = Array.isArray(initialValue) ? initialValue : Object.values(initialValue).flatMap((it) => it);
|
|
14450
|
+
return values.map((value) => parseAndValidateMutation(value, referenceGenome)).filter((parsedMutation) => parsedMutation !== null);
|
|
14451
|
+
}
|
|
13171
14452
|
function getPlaceholder(referenceGenome) {
|
|
13172
14453
|
const nucleotideSubstitution = getExampleMutation(referenceGenome, "nucleotide", "substitution");
|
|
13173
14454
|
const nucleotideInsertion = getExampleMutation(referenceGenome, "nucleotide", "insertion");
|
|
@@ -13176,74 +14457,63 @@ function getPlaceholder(referenceGenome) {
|
|
|
13176
14457
|
const exampleMutations = [nucleotideSubstitution, nucleotideInsertion, aminoAcidSubstitution, aminoAcidInsertion].filter((example) => example !== "").join(", ");
|
|
13177
14458
|
return `Enter a mutation (e.g. ${exampleMutations})`;
|
|
13178
14459
|
}
|
|
13179
|
-
const
|
|
13180
|
-
|
|
13181
|
-
|
|
13182
|
-
|
|
13183
|
-
|
|
13184
|
-
|
|
13185
|
-
|
|
13186
|
-
|
|
13187
|
-
|
|
13188
|
-
|
|
13189
|
-
|
|
13190
|
-
selectedFilters.nucleotideMutations.map((mutation) => /* @__PURE__ */ u$1(
|
|
13191
|
-
SelectedFilter,
|
|
13192
|
-
{
|
|
13193
|
-
handleRemoveValue,
|
|
13194
|
-
mutationFilter: { type: "nucleotideMutations", value: mutation }
|
|
13195
|
-
},
|
|
13196
|
-
mutation.toString()
|
|
13197
|
-
)),
|
|
13198
|
-
selectedFilters.aminoAcidMutations.map((mutation) => /* @__PURE__ */ u$1(
|
|
13199
|
-
SelectedFilter,
|
|
13200
|
-
{
|
|
13201
|
-
handleRemoveValue,
|
|
13202
|
-
mutationFilter: { type: "aminoAcidMutations", value: mutation }
|
|
13203
|
-
},
|
|
13204
|
-
mutation.toString()
|
|
13205
|
-
)),
|
|
13206
|
-
selectedFilters.nucleotideInsertions.map((mutation) => /* @__PURE__ */ u$1(
|
|
13207
|
-
SelectedFilter,
|
|
13208
|
-
{
|
|
13209
|
-
handleRemoveValue,
|
|
13210
|
-
mutationFilter: { type: "nucleotideInsertions", value: mutation }
|
|
13211
|
-
},
|
|
13212
|
-
mutation.toString()
|
|
13213
|
-
)),
|
|
13214
|
-
selectedFilters.aminoAcidInsertions.map((mutation) => /* @__PURE__ */ u$1(
|
|
13215
|
-
SelectedFilter,
|
|
13216
|
-
{
|
|
13217
|
-
handleRemoveValue,
|
|
13218
|
-
mutationFilter: { type: "aminoAcidInsertions", value: mutation }
|
|
13219
|
-
},
|
|
13220
|
-
mutation.toString()
|
|
13221
|
-
))
|
|
13222
|
-
] });
|
|
14460
|
+
const backgroundColorMap = (data, alpha = 0.4) => {
|
|
14461
|
+
switch (data.type) {
|
|
14462
|
+
case "nucleotideMutations":
|
|
14463
|
+
return singleGraphColorRGBByName("green", alpha);
|
|
14464
|
+
case "aminoAcidMutations":
|
|
14465
|
+
return singleGraphColorRGBByName("teal", alpha);
|
|
14466
|
+
case "nucleotideInsertions":
|
|
14467
|
+
return singleGraphColorRGBByName("indigo", alpha);
|
|
14468
|
+
case "aminoAcidInsertions":
|
|
14469
|
+
return singleGraphColorRGBByName("purple", alpha);
|
|
14470
|
+
}
|
|
13223
14471
|
};
|
|
13224
14472
|
const SelectedFilter = ({ handleRemoveValue, mutationFilter }) => {
|
|
13225
14473
|
return /* @__PURE__ */ u$1(
|
|
13226
14474
|
"span",
|
|
13227
14475
|
{
|
|
13228
|
-
className: "center
|
|
14476
|
+
className: "center px-2 py-1 inline-flex text-black rounded-md",
|
|
13229
14477
|
style: {
|
|
13230
14478
|
backgroundColor: backgroundColorMap(mutationFilter)
|
|
13231
14479
|
},
|
|
13232
14480
|
children: [
|
|
13233
14481
|
mutationFilter.value.toString(),
|
|
13234
|
-
/* @__PURE__ */ u$1(
|
|
14482
|
+
/* @__PURE__ */ u$1(
|
|
14483
|
+
"button",
|
|
14484
|
+
{
|
|
14485
|
+
className: "ml-1 cursor-pointer",
|
|
14486
|
+
"aria-label": `remove mutation filter ${mutationFilter.value.code}`,
|
|
14487
|
+
onClick: () => handleRemoveValue(mutationFilter),
|
|
14488
|
+
children: "×"
|
|
14489
|
+
}
|
|
14490
|
+
)
|
|
13235
14491
|
]
|
|
13236
14492
|
},
|
|
13237
14493
|
mutationFilter.value.toString()
|
|
13238
14494
|
);
|
|
13239
14495
|
};
|
|
13240
14496
|
function mapToMutationFilterStrings(selectedFilters) {
|
|
13241
|
-
return
|
|
13242
|
-
|
|
13243
|
-
|
|
13244
|
-
|
|
13245
|
-
|
|
13246
|
-
|
|
14497
|
+
return selectedFilters.reduce(
|
|
14498
|
+
(acc, filter) => {
|
|
14499
|
+
switch (filter.type) {
|
|
14500
|
+
case "nucleotideMutations":
|
|
14501
|
+
return { ...acc, nucleotideMutations: [...acc.nucleotideMutations, filter.value.toString()] };
|
|
14502
|
+
case "aminoAcidMutations":
|
|
14503
|
+
return { ...acc, aminoAcidMutations: [...acc.aminoAcidMutations, filter.value.toString()] };
|
|
14504
|
+
case "nucleotideInsertions":
|
|
14505
|
+
return { ...acc, nucleotideInsertions: [...acc.nucleotideInsertions, filter.value.toString()] };
|
|
14506
|
+
case "aminoAcidInsertions":
|
|
14507
|
+
return { ...acc, aminoAcidInsertions: [...acc.aminoAcidInsertions, filter.value.toString()] };
|
|
14508
|
+
}
|
|
14509
|
+
},
|
|
14510
|
+
{
|
|
14511
|
+
aminoAcidMutations: [],
|
|
14512
|
+
nucleotideMutations: [],
|
|
14513
|
+
aminoAcidInsertions: [],
|
|
14514
|
+
nucleotideInsertions: []
|
|
14515
|
+
}
|
|
14516
|
+
);
|
|
13247
14517
|
}
|
|
13248
14518
|
var __defProp$1 = Object.defineProperty;
|
|
13249
14519
|
var __getOwnPropDesc$1 = Object.getOwnPropertyDescriptor;
|