@vitessce/all 3.3.5 → 3.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/blosc-537fd004.js +891 -0
- package/dist/browser-122c4c35.js +786 -0
- package/dist/chunk-INHXZS53-bee20a28.js +19 -0
- package/dist/{deflate-9dafbbdd.js → deflate-aae0b27f.js} +1 -1
- package/dist/gzip-6a24f0fe.js +30 -0
- package/dist/{hglib-9856f827.js → hglib-bd5b112f.js} +1 -1
- package/dist/{index-69ad551a.js → index-0aa2b092.js} +1361 -212
- package/dist/index.js +3 -2
- package/dist/{jpeg-486c496f.js → jpeg-913b4a29.js} +1 -1
- package/dist/{lerc-d44258ea.js → lerc-c5d4fc8f.js} +1 -1
- package/dist/lz4-bbd18009.js +808 -0
- package/dist/{lzw-bec7c4c2.js → lzw-e6575211.js} +1 -1
- package/dist/{packbits-fb191a07.js → packbits-d3d3e4e9.js} +1 -1
- package/dist/{raw-344c6603.js → raw-6a5ee9b6.js} +1 -1
- package/dist/{webimage-ca45fc32.js → webimage-6e4a32e0.js} +1 -1
- package/dist/zlib-175cd38d.js +30 -0
- package/dist/zstd-ec5a40b8.js +808 -0
- package/dist-tsc/Vitessce.d.ts.map +1 -1
- package/dist-tsc/Vitessce.js +1 -1
- package/dist-tsc/base-plugins.d.ts.map +1 -1
- package/dist-tsc/base-plugins.js +28 -14
- package/dist-tsc/index.d.ts +1 -0
- package/dist-tsc/index.d.ts.map +1 -1
- package/dist-tsc/index.js +1 -0
- package/dist-tsc/joint-file-types.d.ts.map +1 -1
- package/dist-tsc/joint-file-types.js +23 -13
- package/package.json +22 -22
- package/src/Vitessce.tsx +0 -1
- package/src/base-plugins.ts +29 -10
- package/src/index.ts +1 -0
- package/src/joint-file-types.ts +25 -13
- package/dist/blosc-0acfcf7e.js +0 -975
- package/dist/gzip-dd5ab7c8.js +0 -28
- package/dist/lz4-abb4416a.js +0 -919
- package/dist/pako.esm-856454b6-c5c8cd15.js +0 -4066
- package/dist/zlib-cd823c38.js +0 -28
- package/dist/zstd-4072ca78.js +0 -919
@@ -26,10 +26,10 @@ var __privateMethod = (obj, member, method2) => {
|
|
26
26
|
__accessCheck(obj, member, "access private method");
|
27
27
|
return method2;
|
28
28
|
};
|
29
|
-
var _bytes, _encoder, _encode_buffer, _strides, _TypedArray, _BYTES_PER_ELEMENT, _shape, _endian, _shape2, _strides2, _metadata, _a2, _metadata2, _b, _c, _overrides, _use_suffix_request, _merge_init, merge_init_fn;
|
29
|
+
var _bytes, _encoder, _data, _encode_buffer, _strides, _TypedArray, _BYTES_PER_ELEMENT, _shape, _endian, _shape2, _strides2, _encoder_config, _decoder_config, _metadata, _a2, _metadata2, _b, _c, _overrides, _use_suffix_request, _merge_init, merge_init_fn, _overrides2;
|
30
30
|
import * as React from "react";
|
31
31
|
import React__default, { Children, isValidElement, cloneElement, useMemo, forwardRef, useRef, useImperativeHandle, useEffect, useLayoutEffect as useLayoutEffect$1, useState, PureComponent, Component as Component$1, useCallback, createElement, useContext, useReducer, Suspense } from "react";
|
32
|
-
import { useLoaders, useCoordination, useDescription, useImageData, useReady, TitleInfo, useVitessceContainer, useSetWarning, useObsSetsData, useUrls, usePlotOptionsStyles, OptionsContainer, CellColorEncodingOption, OptionSelect, useComponentHover, useComponentViewInfo, useSetComponentHover, useSetComponentViewInfo, useInitialCoordination, useDeckCanvasSize, useMultiObsLabels, useObsEmbeddingData, useFeatureSelection, useObsFeatureMatrixIndices, useFeatureLabelsData, useGetObsInfo, useUint8FeatureSelection, useExpressionValueGetter, useAuxiliaryCoordination, useHasLoader, useObsLocationsData, useObsLabelsData, useObsSegmentationsData, useNeighborhoodsData, useMergeCoordination, useCoordinationScopes, useCoordinationScopesBy, useMultiCoordinationScopesSecondaryNonNull, useMultiCoordinationScopesNonNull, useComplexCoordination, useComplexCoordinationSecondary, useMultiObsPoints, usePointMultiObsLabels, useMultiObsSpots, useSpotMultiObsSets, useSpotMultiFeatureSelection, useSpotMultiObsFeatureMatrixIndices, useSegmentationMultiObsLocations, useMultiObsSegmentations, useSegmentationMultiObsSets, useSegmentationMultiFeatureSelection, useSegmentationMultiObsFeatureMatrixIndices, useMultiImages, useObsFeatureMatrixData, useUint8ObsFeatureMatrix, useGetObsMembership, PopperMenu, useComponentLayout, useClosestVitessceContainerSize, useWindowDimensions, useRemoveImageChannelInMetaCoordinationScopes, useAddImageChannelInMetaCoordinationScopes, useWarning, useGridItemSize, useGenomicProfilesData, DataSourceFetchError, AbstractLoaderError, AbstractTwoStepLoader, LoaderResult, LoaderValidationError, logConfig, VitS } from "@vitessce/vit-s";
|
32
|
+
import { useLoaders, useCoordination, useDescription, useImageData, useReady, TitleInfo, useVitessceContainer, useSetWarning, useObsSetsData, useUrls, usePlotOptionsStyles, OptionsContainer, CellColorEncodingOption, OptionSelect, useComponentHover, useComponentViewInfo, useSetComponentHover, useSetComponentViewInfo, useInitialCoordination, useDeckCanvasSize, useMultiObsLabels, useObsEmbeddingData, useFeatureSelection, useObsFeatureMatrixIndices, useFeatureLabelsData, useGetObsInfo, useUint8FeatureSelection, useExpressionValueGetter, useAuxiliaryCoordination, useHasLoader, useObsLocationsData, useObsLabelsData, useObsSegmentationsData, useNeighborhoodsData, useMergeCoordination, useCoordinationScopes, useCoordinationScopesBy, useMultiCoordinationScopesSecondaryNonNull, useMultiCoordinationScopesNonNull, useComplexCoordination, useComplexCoordinationSecondary, useMultiObsPoints, usePointMultiObsLabels, useMultiObsSpots, useSpotMultiObsSets, useSpotMultiFeatureLabels, useSpotMultiFeatureSelection, useSpotMultiObsFeatureMatrixIndices, useSegmentationMultiObsLocations, useMultiObsSegmentations, useSegmentationMultiObsSets, useSegmentationMultiFeatureSelection, useSegmentationMultiObsFeatureMatrixIndices, useMultiImages, useObsFeatureMatrixData, useUint8ObsFeatureMatrix, useGetObsMembership, PopperMenu, useComponentLayout, useClosestVitessceContainerSize, useWindowDimensions, useRemoveImageChannelInMetaCoordinationScopes, useAddImageChannelInMetaCoordinationScopes, useWarning, useGridItemSize, useGenomicProfilesData, useSampleSetsData, useSampleEdgesData, DataSourceFetchError, AbstractLoaderError, AbstractTwoStepLoader, LoaderResult, LoaderValidationError, logConfig, VitS } from "@vitessce/vit-s";
|
33
33
|
import * as ReactDOM from "react-dom";
|
34
34
|
import ReactDOM__default from "react-dom";
|
35
35
|
function _mergeNamespaces(n3, m2) {
|
@@ -7081,8 +7081,9 @@ function getNextScope(prevScopes) {
|
|
7081
7081
|
}
|
7082
7082
|
const DEFAULT_DARK_COLOR = [50, 50, 50];
|
7083
7083
|
const DEFAULT_LIGHT_COLOR$3 = [200, 200, 200];
|
7084
|
+
const DEFAULT_LIGHT2_COLOR = [235, 235, 235];
|
7084
7085
|
function getDefaultColor(theme) {
|
7085
|
-
return theme === "dark" ? DEFAULT_DARK_COLOR : DEFAULT_LIGHT_COLOR$3;
|
7086
|
+
return theme === "dark" ? DEFAULT_DARK_COLOR : theme === "light" ? DEFAULT_LIGHT_COLOR$3 : DEFAULT_LIGHT2_COLOR;
|
7086
7087
|
}
|
7087
7088
|
const PALETTE = [
|
7088
7089
|
[68, 119, 170],
|
@@ -9848,11 +9849,14 @@ const DataType$2 = {
|
|
9848
9849
|
GENOMIC_PROFILES: "genomic-profiles",
|
9849
9850
|
OBS_SPOTS: "obsSpots",
|
9850
9851
|
OBS_POINTS: "obsPoints",
|
9851
|
-
OBS_LOCATIONS: "obsLocations"
|
9852
|
+
OBS_LOCATIONS: "obsLocations",
|
9853
|
+
SAMPLE_SETS: "sampleSets",
|
9854
|
+
SAMPLE_EDGES: "sampleEdges"
|
9852
9855
|
};
|
9853
9856
|
const FileType$1 = {
|
9854
9857
|
// Joint file types
|
9855
9858
|
ANNDATA_ZARR: "anndata.zarr",
|
9859
|
+
ANNDATA_ZARR_ZIP: "anndata.zarr.zip",
|
9856
9860
|
SPATIALDATA_ZARR: "spatialdata.zarr",
|
9857
9861
|
// Atomic file types
|
9858
9862
|
OBS_EMBEDDING_CSV: "obsEmbedding.csv",
|
@@ -9865,6 +9869,7 @@ const FileType$1 = {
|
|
9865
9869
|
OBS_SEGMENTATIONS_JSON: "obsSegmentations.json",
|
9866
9870
|
OBS_SETS_CSV: "obsSets.csv",
|
9867
9871
|
OBS_SETS_JSON: "obsSets.json",
|
9872
|
+
SAMPLE_SETS_CSV: "sampleSets.csv",
|
9868
9873
|
// OME-Zarr
|
9869
9874
|
IMAGE_OME_ZARR: "image.ome-zarr",
|
9870
9875
|
OBS_SEGMENTATIONS_OME_ZARR: "obsSegmentations.ome-zarr",
|
@@ -9879,6 +9884,19 @@ const FileType$1 = {
|
|
9879
9884
|
OBS_SEGMENTATIONS_ANNDATA_ZARR: "obsSegmentations.anndata.zarr",
|
9880
9885
|
OBS_LABELS_ANNDATA_ZARR: "obsLabels.anndata.zarr",
|
9881
9886
|
FEATURE_LABELS_ANNDATA_ZARR: "featureLabels.anndata.zarr",
|
9887
|
+
SAMPLE_EDGES_ANNDATA_ZARR: "sampleEdges.anndata.zarr",
|
9888
|
+
// AnnData - zipped
|
9889
|
+
OBS_FEATURE_MATRIX_ANNDATA_ZARR_ZIP: "obsFeatureMatrix.anndata.zarr.zip",
|
9890
|
+
OBS_FEATURE_COLUMNS_ANNDATA_ZARR_ZIP: "obsFeatureColumns.anndata.zarr.zip",
|
9891
|
+
OBS_SETS_ANNDATA_ZARR_ZIP: "obsSets.anndata.zarr.zip",
|
9892
|
+
OBS_EMBEDDING_ANNDATA_ZARR_ZIP: "obsEmbedding.anndata.zarr.zip",
|
9893
|
+
OBS_SPOTS_ANNDATA_ZARR_ZIP: "obsSpots.anndata.zarr.zip",
|
9894
|
+
OBS_POINTS_ANNDATA_ZARR_ZIP: "obsPoints.anndata.zarr.zip",
|
9895
|
+
OBS_LOCATIONS_ANNDATA_ZARR_ZIP: "obsLocations.anndata.zarr.zip",
|
9896
|
+
OBS_SEGMENTATIONS_ANNDATA_ZARR_ZIP: "obsSegmentations.anndata.zarr.zip",
|
9897
|
+
OBS_LABELS_ANNDATA_ZARR_ZIP: "obsLabels.anndata.zarr.zip",
|
9898
|
+
FEATURE_LABELS_ANNDATA_ZARR_ZIP: "featureLabels.anndata.zarr.zip",
|
9899
|
+
SAMPLE_EDGES_ANNDATA_ZARR_ZIP: "sampleEdges.anndata.zarr.zip",
|
9882
9900
|
// SpatialData
|
9883
9901
|
IMAGE_SPATIALDATA_ZARR: "image.spatialdata.zarr",
|
9884
9902
|
LABELS_SPATIALDATA_ZARR: "labels.spatialdata.zarr",
|
@@ -9886,6 +9904,7 @@ const FileType$1 = {
|
|
9886
9904
|
OBS_FEATURE_MATRIX_SPATIALDATA_ZARR: "obsFeatureMatrix.spatialdata.zarr",
|
9887
9905
|
OBS_SETS_SPATIALDATA_ZARR: "obsSets.spatialdata.zarr",
|
9888
9906
|
OBS_SPOTS_SPATIALDATA_ZARR: "obsSpots.spatialdata.zarr",
|
9907
|
+
FEATURE_LABELS_SPATIALDATA_ZARR: "featureLabels.spatialdata.zarr",
|
9889
9908
|
// TODO:
|
9890
9909
|
// OBS_POINTS_SPATIALDATA_ZARR: 'obsPoints.spatialdata.zarr',
|
9891
9910
|
// OBS_LOCATIONS_SPATIALDATA_ZARR: 'obsLocations.spatialdata.zarr',
|
@@ -10042,13 +10061,51 @@ const CoordinationType$1 = {
|
|
10042
10061
|
LEGEND_VISIBLE: "legendVisible",
|
10043
10062
|
SPATIAL_CHANNEL_LABELS_VISIBLE: "spatialChannelLabelsVisible",
|
10044
10063
|
SPATIAL_CHANNEL_LABELS_ORIENTATION: "spatialChannelLabelsOrientation",
|
10045
|
-
SPATIAL_CHANNEL_LABEL_SIZE: "spatialChannelLabelSize"
|
10064
|
+
SPATIAL_CHANNEL_LABEL_SIZE: "spatialChannelLabelSize",
|
10065
|
+
// Multi-sample / comparative
|
10066
|
+
SAMPLE_TYPE: "sampleType",
|
10067
|
+
SAMPLE_SET_SELECTION: "sampleSetSelection"
|
10046
10068
|
};
|
10047
10069
|
const STATUS$1 = {
|
10048
10070
|
LOADING: "loading",
|
10049
10071
|
SUCCESS: "success",
|
10050
10072
|
ERROR: "error"
|
10051
10073
|
};
|
10074
|
+
const ALT_ZARR_STORE_TYPES = {
|
10075
|
+
[FileType$1.OBS_FEATURE_MATRIX_ANNDATA_ZARR]: {
|
10076
|
+
zip: FileType$1.OBS_FEATURE_MATRIX_ANNDATA_ZARR_ZIP
|
10077
|
+
},
|
10078
|
+
[FileType$1.OBS_FEATURE_COLUMNS_ANNDATA_ZARR]: {
|
10079
|
+
zip: FileType$1.OBS_FEATURE_COLUMNS_ANNDATA_ZARR_ZIP
|
10080
|
+
},
|
10081
|
+
[FileType$1.OBS_SETS_ANNDATA_ZARR]: {
|
10082
|
+
zip: FileType$1.OBS_SETS_ANNDATA_ZARR_ZIP
|
10083
|
+
},
|
10084
|
+
[FileType$1.OBS_EMBEDDING_ANNDATA_ZARR]: {
|
10085
|
+
zip: FileType$1.OBS_EMBEDDING_ANNDATA_ZARR_ZIP
|
10086
|
+
},
|
10087
|
+
[FileType$1.OBS_SPOTS_ANNDATA_ZARR]: {
|
10088
|
+
zip: FileType$1.OBS_SPOTS_ANNDATA_ZARR_ZIP
|
10089
|
+
},
|
10090
|
+
[FileType$1.OBS_POINTS_ANNDATA_ZARR]: {
|
10091
|
+
zip: FileType$1.OBS_POINTS_ANNDATA_ZARR_ZIP
|
10092
|
+
},
|
10093
|
+
[FileType$1.OBS_LOCATIONS_ANNDATA_ZARR]: {
|
10094
|
+
zip: FileType$1.OBS_LOCATIONS_ANNDATA_ZARR_ZIP
|
10095
|
+
},
|
10096
|
+
[FileType$1.OBS_SEGMENTATIONS_ANNDATA_ZARR]: {
|
10097
|
+
zip: FileType$1.OBS_SEGMENTATIONS_ANNDATA_ZARR_ZIP
|
10098
|
+
},
|
10099
|
+
[FileType$1.OBS_LABELS_ANNDATA_ZARR]: {
|
10100
|
+
zip: FileType$1.OBS_LABELS_ANNDATA_ZARR_ZIP
|
10101
|
+
},
|
10102
|
+
[FileType$1.FEATURE_LABELS_ANNDATA_ZARR]: {
|
10103
|
+
zip: FileType$1.FEATURE_LABELS_ANNDATA_ZARR_ZIP
|
10104
|
+
},
|
10105
|
+
[FileType$1.SAMPLE_EDGES_ANNDATA_ZARR]: {
|
10106
|
+
zip: FileType$1.SAMPLE_EDGES_ANNDATA_ZARR_ZIP
|
10107
|
+
}
|
10108
|
+
};
|
10052
10109
|
const COMPONENT_COORDINATION_TYPES = {
|
10053
10110
|
[ViewType$1.SCATTERPLOT]: [
|
10054
10111
|
CoordinationType$1.DATASET,
|
@@ -10295,7 +10352,9 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
10295
10352
|
CoordinationType$1.OBS_SET_SELECTION,
|
10296
10353
|
CoordinationType$1.OBS_SET_HIGHLIGHT,
|
10297
10354
|
CoordinationType$1.OBS_SET_COLOR,
|
10298
|
-
CoordinationType$1.ADDITIONAL_OBS_SETS
|
10355
|
+
CoordinationType$1.ADDITIONAL_OBS_SETS,
|
10356
|
+
CoordinationType$1.SAMPLE_TYPE,
|
10357
|
+
CoordinationType$1.SAMPLE_SET_SELECTION
|
10299
10358
|
],
|
10300
10359
|
[ViewType$1.FEATURE_VALUE_HISTOGRAM]: [
|
10301
10360
|
CoordinationType$1.DATASET,
|
@@ -10707,6 +10766,7 @@ const annDataConvenienceObsEmbeddingItem = z.object({
|
|
10707
10766
|
});
|
10708
10767
|
const annDataObsLabels = annDataObs;
|
10709
10768
|
const annDataFeatureLabels = annDataObs;
|
10769
|
+
const annDataSampleEdges = annDataObs;
|
10710
10770
|
const annDataObsFeatureMatrix = z.object({
|
10711
10771
|
path: z.string(),
|
10712
10772
|
featureFilterPath: z.string().optional().describe("If the feature index should be filtered, put a boolean column here (analogous to the previous geneFilter option). e.g., var/in_obsm_X_small_matrix"),
|
@@ -10788,6 +10848,7 @@ const obsFeatureMatrixAnndataSchema = annDataObsFeatureMatrix;
|
|
10788
10848
|
const obsLabelsAnndataSchema = annDataObsLabels;
|
10789
10849
|
const featureLabelsAnndataSchema = annDataFeatureLabels;
|
10790
10850
|
const obsFeatureColumnsAnndataSchema = annDataObsFeatureColumns;
|
10851
|
+
const sampleEdgesAnndataSchema = annDataSampleEdges;
|
10791
10852
|
const obsEmbeddingCsvSchema = z.object({
|
10792
10853
|
obsIndex: z.string(),
|
10793
10854
|
obsEmbedding: z.array(z.string()).length(2)
|
@@ -10826,6 +10887,17 @@ const obsSetsCsvSchema = z.object({
|
|
10826
10887
|
scoreColumn: z.string().optional()
|
10827
10888
|
}))
|
10828
10889
|
});
|
10890
|
+
const sampleSetsCsvSchema = z.object({
|
10891
|
+
sampleIndex: z.string(),
|
10892
|
+
sampleSets: z.array(z.object({
|
10893
|
+
name: z.string(),
|
10894
|
+
column: z.union([
|
10895
|
+
z.string(),
|
10896
|
+
z.array(z.string())
|
10897
|
+
]),
|
10898
|
+
scoreColumn: z.string().optional()
|
10899
|
+
}))
|
10900
|
+
});
|
10829
10901
|
const anndataZarrSchema = z.object({
|
10830
10902
|
obsLabels: z.union([
|
10831
10903
|
annDataObsLabels,
|
@@ -16593,7 +16665,7 @@ function useIsFocusVisible() {
|
|
16593
16665
|
function _toArray(arr) {
|
16594
16666
|
return _arrayWithHoles$7(arr) || _iterableToArray$j(arr) || _unsupportedIterableToArray$m(arr) || _nonIterableRest$7();
|
16595
16667
|
}
|
16596
|
-
const config$
|
16668
|
+
const config$4 = {
|
16597
16669
|
disabled: false
|
16598
16670
|
};
|
16599
16671
|
var timeoutsShape = _pt.oneOfType([_pt.number, _pt.shape({
|
@@ -16727,7 +16799,7 @@ var Transition$1 = /* @__PURE__ */ function(_React$Component) {
|
|
16727
16799
|
var _ref22 = this.props.nodeRef ? [appearing] : [ReactDOM__default.findDOMNode(this), appearing], maybeNode = _ref22[0], maybeAppearing = _ref22[1];
|
16728
16800
|
var timeouts = this.getTimeouts();
|
16729
16801
|
var enterTimeout = appearing ? timeouts.appear : timeouts.enter;
|
16730
|
-
if (!mounting && !enter || config$
|
16802
|
+
if (!mounting && !enter || config$4.disabled) {
|
16731
16803
|
this.safeSetState({
|
16732
16804
|
status: ENTERED
|
16733
16805
|
}, function() {
|
@@ -16754,7 +16826,7 @@ var Transition$1 = /* @__PURE__ */ function(_React$Component) {
|
|
16754
16826
|
var exit = this.props.exit;
|
16755
16827
|
var timeouts = this.getTimeouts();
|
16756
16828
|
var maybeNode = this.props.nodeRef ? void 0 : ReactDOM__default.findDOMNode(this);
|
16757
|
-
if (!exit || config$
|
16829
|
+
if (!exit || config$4.disabled) {
|
16758
16830
|
this.safeSetState({
|
16759
16831
|
status: EXITED
|
16760
16832
|
}, function() {
|
@@ -54739,7 +54811,7 @@ const isPureObject = (x2) => isObject$4(x2) && x2.constructor === {}.constructor
|
|
54739
54811
|
const isIterable$1 = (x2) => x2 && typeof x2[Symbol.iterator] === "function";
|
54740
54812
|
const isAsyncIterable$1 = (x2) => x2 && typeof x2[Symbol.asyncIterator] === "function";
|
54741
54813
|
const isResponse = (x2) => typeof Response !== "undefined" && x2 instanceof Response || x2 && x2.arrayBuffer && x2.text && x2.json;
|
54742
|
-
const isBlob = (x2) => typeof Blob !== "undefined" && x2 instanceof Blob;
|
54814
|
+
const isBlob$1 = (x2) => typeof Blob !== "undefined" && x2 instanceof Blob;
|
54743
54815
|
const isBuffer$2 = (x2) => x2 && typeof x2 === "object" && x2.isBuffer;
|
54744
54816
|
const isReadableDOMStream = (x2) => typeof ReadableStream !== "undefined" && x2 instanceof ReadableStream || isObject$4(x2) && isFunction$4(x2.tee) && isFunction$4(x2.cancel) && isFunction$4(x2.getReader);
|
54745
54817
|
const isReadableNodeStream = (x2) => isObject$4(x2) && isFunction$4(x2.read) && isFunction$4(x2.pipe) && isBoolean$4(x2.readable);
|
@@ -54770,7 +54842,7 @@ function getResourceUrlAndType(resource) {
|
|
54770
54842
|
type: parseMIMEType(contentTypeHeader) || parseMIMETypeFromURL(url)
|
54771
54843
|
};
|
54772
54844
|
}
|
54773
|
-
if (isBlob(resource)) {
|
54845
|
+
if (isBlob$1(resource)) {
|
54774
54846
|
return {
|
54775
54847
|
url: stripQueryString(resource.name || ""),
|
54776
54848
|
type: resource.type || ""
|
@@ -54791,7 +54863,7 @@ function getResourceContentLength(resource) {
|
|
54791
54863
|
if (isResponse(resource)) {
|
54792
54864
|
return resource.headers["content-length"] || -1;
|
54793
54865
|
}
|
54794
|
-
if (isBlob(resource)) {
|
54866
|
+
if (isBlob$1(resource)) {
|
54795
54867
|
return resource.size;
|
54796
54868
|
}
|
54797
54869
|
if (typeof resource === "string") {
|
@@ -55694,7 +55766,7 @@ async function selectLoader(data2, loaders = [], options, context2) {
|
|
55694
55766
|
if (loader2) {
|
55695
55767
|
return loader2;
|
55696
55768
|
}
|
55697
|
-
if (isBlob(data2)) {
|
55769
|
+
if (isBlob$1(data2)) {
|
55698
55770
|
data2 = await data2.slice(0, 10).arrayBuffer();
|
55699
55771
|
loader2 = selectLoaderSync(data2, loaders, options, context2);
|
55700
55772
|
}
|
@@ -55948,7 +56020,7 @@ function makeIterator(data2, options) {
|
|
55948
56020
|
if (data2 instanceof ArrayBuffer) {
|
55949
56021
|
return makeArrayBufferIterator(data2, options);
|
55950
56022
|
}
|
55951
|
-
if (isBlob(data2)) {
|
56023
|
+
if (isBlob$1(data2)) {
|
55952
56024
|
return makeBlobIterator(data2, options);
|
55953
56025
|
}
|
55954
56026
|
if (isReadableStream(data2)) {
|
@@ -55995,7 +56067,7 @@ async function getArrayBufferOrStringFromData(data2, loader2, options) {
|
|
55995
56067
|
if (typeof data2 === "string" || isArrayBuffer) {
|
55996
56068
|
return getArrayBufferOrStringFromDataSync(data2, loader2);
|
55997
56069
|
}
|
55998
|
-
if (isBlob(data2)) {
|
56070
|
+
if (isBlob$1(data2)) {
|
55999
56071
|
data2 = await makeResponse(data2);
|
56000
56072
|
}
|
56001
56073
|
if (isResponse(data2)) {
|
@@ -56114,7 +56186,7 @@ async function load$2(url, loaders, options, context2) {
|
|
56114
56186
|
if (typeof url === "string") {
|
56115
56187
|
data2 = await fetch2(url);
|
56116
56188
|
}
|
56117
|
-
if (isBlob(url)) {
|
56189
|
+
if (isBlob$1(url)) {
|
56118
56190
|
data2 = await fetch2(url);
|
56119
56191
|
}
|
56120
56192
|
return await parse$b(data2, loaders, options);
|
@@ -64339,7 +64411,7 @@ function assert$7(condition, message) {
|
|
64339
64411
|
}
|
64340
64412
|
const RADIANS_TO_DEGREES$2 = 1 / Math.PI * 180;
|
64341
64413
|
const DEGREES_TO_RADIANS$7 = 1 / 180 * Math.PI;
|
64342
|
-
const config$
|
64414
|
+
const config$3 = {
|
64343
64415
|
EPSILON: 1e-12,
|
64344
64416
|
debug: false,
|
64345
64417
|
precision: 4,
|
@@ -64349,13 +64421,13 @@ const config$2 = {
|
|
64349
64421
|
};
|
64350
64422
|
function configure(options) {
|
64351
64423
|
for (const key2 in options) {
|
64352
|
-
assert$7(key2 in config$
|
64353
|
-
config$
|
64424
|
+
assert$7(key2 in config$3);
|
64425
|
+
config$3[key2] = options[key2];
|
64354
64426
|
}
|
64355
|
-
return config$
|
64427
|
+
return config$3;
|
64356
64428
|
}
|
64357
64429
|
function formatValue$4(value2, {
|
64358
|
-
precision = config$
|
64430
|
+
precision = config$3.precision
|
64359
64431
|
} = {}) {
|
64360
64432
|
value2 = round$3(value2);
|
64361
64433
|
return "".concat(parseFloat(value2.toPrecision(precision)));
|
@@ -64406,9 +64478,9 @@ function lerp$7(a2, b2, t4) {
|
|
64406
64478
|
return t4 * b2 + (1 - t4) * a2;
|
64407
64479
|
}
|
64408
64480
|
function equals$3(a2, b2, epsilon3) {
|
64409
|
-
const oldEpsilon = config$
|
64481
|
+
const oldEpsilon = config$3.EPSILON;
|
64410
64482
|
if (epsilon3) {
|
64411
|
-
config$
|
64483
|
+
config$3.EPSILON = epsilon3;
|
64412
64484
|
}
|
64413
64485
|
try {
|
64414
64486
|
if (a2 === b2) {
|
@@ -64432,11 +64504,11 @@ function equals$3(a2, b2, epsilon3) {
|
|
64432
64504
|
return b2.equals(a2);
|
64433
64505
|
}
|
64434
64506
|
if (typeof a2 === "number" && typeof b2 === "number") {
|
64435
|
-
return Math.abs(a2 - b2) <= config$
|
64507
|
+
return Math.abs(a2 - b2) <= config$3.EPSILON * Math.max(1, Math.abs(a2), Math.abs(b2));
|
64436
64508
|
}
|
64437
64509
|
return false;
|
64438
64510
|
} finally {
|
64439
|
-
config$
|
64511
|
+
config$3.EPSILON = oldEpsilon;
|
64440
64512
|
}
|
64441
64513
|
}
|
64442
64514
|
function exactEquals(a2, b2) {
|
@@ -64465,18 +64537,18 @@ function exactEquals(a2, b2) {
|
|
64465
64537
|
return false;
|
64466
64538
|
}
|
64467
64539
|
function withEpsilon(epsilon3, func) {
|
64468
|
-
const oldPrecision = config$
|
64469
|
-
config$
|
64540
|
+
const oldPrecision = config$3.EPSILON;
|
64541
|
+
config$3.EPSILON = epsilon3;
|
64470
64542
|
let value2;
|
64471
64543
|
try {
|
64472
64544
|
value2 = func();
|
64473
64545
|
} finally {
|
64474
|
-
config$
|
64546
|
+
config$3.EPSILON = oldPrecision;
|
64475
64547
|
}
|
64476
64548
|
return value2;
|
64477
64549
|
}
|
64478
64550
|
function round$3(value2) {
|
64479
|
-
return Math.round(value2 / config$
|
64551
|
+
return Math.round(value2 / config$3.EPSILON) * config$3.EPSILON;
|
64480
64552
|
}
|
64481
64553
|
function duplicateArray(array2) {
|
64482
64554
|
return array2.clone ? array2.clone() : new Array(array2.length);
|
@@ -64545,7 +64617,7 @@ class MathArray extends _extendableBuiltin(Array) {
|
|
64545
64617
|
return new Float32Array(this);
|
64546
64618
|
}
|
64547
64619
|
toString() {
|
64548
|
-
return this.formatString(config$
|
64620
|
+
return this.formatString(config$3);
|
64549
64621
|
}
|
64550
64622
|
formatString(opts2) {
|
64551
64623
|
let string2 = "";
|
@@ -64645,7 +64717,7 @@ class MathArray extends _extendableBuiltin(Array) {
|
|
64645
64717
|
return this.check();
|
64646
64718
|
}
|
64647
64719
|
check() {
|
64648
|
-
if (config$
|
64720
|
+
if (config$3.debug && !this.validate()) {
|
64649
64721
|
throw new Error("math.gl: ".concat(this.constructor.name, " some fields set to invalid numbers'"));
|
64650
64722
|
}
|
64651
64723
|
return this;
|
@@ -64712,7 +64784,7 @@ function checkNumber(value2) {
|
|
64712
64784
|
return value2;
|
64713
64785
|
}
|
64714
64786
|
function checkVector(v, length2, callerName = "") {
|
64715
|
-
if (config$
|
64787
|
+
if (config$3.debug && !validateVector(v, length2)) {
|
64716
64788
|
throw new Error("math.gl: ".concat(callerName, " some fields set to invalid numbers'"));
|
64717
64789
|
}
|
64718
64790
|
return v;
|
@@ -64970,7 +65042,7 @@ class Vector2 extends Vector {
|
|
64970
65042
|
if (isArray$3(x2) && arguments.length === 1) {
|
64971
65043
|
this.copy(x2);
|
64972
65044
|
} else {
|
64973
|
-
if (config$
|
65045
|
+
if (config$3.debug) {
|
64974
65046
|
checkNumber(x2);
|
64975
65047
|
checkNumber(y2);
|
64976
65048
|
}
|
@@ -64989,7 +65061,7 @@ class Vector2 extends Vector {
|
|
64989
65061
|
return this.check();
|
64990
65062
|
}
|
64991
65063
|
fromObject(object2) {
|
64992
|
-
if (config$
|
65064
|
+
if (config$3.debug) {
|
64993
65065
|
checkNumber(object2.x);
|
64994
65066
|
checkNumber(object2.y);
|
64995
65067
|
}
|
@@ -65242,7 +65314,7 @@ class Vector3 extends Vector {
|
|
65242
65314
|
if (arguments.length === 1 && isArray$3(x2)) {
|
65243
65315
|
this.copy(x2);
|
65244
65316
|
} else {
|
65245
|
-
if (config$
|
65317
|
+
if (config$3.debug) {
|
65246
65318
|
checkNumber(x2);
|
65247
65319
|
checkNumber(y2);
|
65248
65320
|
checkNumber(z2);
|
@@ -65265,7 +65337,7 @@ class Vector3 extends Vector {
|
|
65265
65337
|
return this.check();
|
65266
65338
|
}
|
65267
65339
|
fromObject(object2) {
|
65268
|
-
if (config$
|
65340
|
+
if (config$3.debug) {
|
65269
65341
|
checkNumber(object2.x);
|
65270
65342
|
checkNumber(object2.y);
|
65271
65343
|
checkNumber(object2.z);
|
@@ -65356,7 +65428,7 @@ class Vector4 extends Vector {
|
|
65356
65428
|
if (isArray$3(x2) && arguments.length === 1) {
|
65357
65429
|
this.copy(x2);
|
65358
65430
|
} else {
|
65359
|
-
if (config$
|
65431
|
+
if (config$3.debug) {
|
65360
65432
|
checkNumber(x2);
|
65361
65433
|
checkNumber(y2);
|
65362
65434
|
checkNumber(z2);
|
@@ -65383,7 +65455,7 @@ class Vector4 extends Vector {
|
|
65383
65455
|
return this.check();
|
65384
65456
|
}
|
65385
65457
|
fromObject(object2) {
|
65386
|
-
if (config$
|
65458
|
+
if (config$3.debug) {
|
65387
65459
|
checkNumber(object2.x);
|
65388
65460
|
checkNumber(object2.y);
|
65389
65461
|
checkNumber(object2.z);
|
@@ -65441,7 +65513,7 @@ class Vector4 extends Vector {
|
|
65441
65513
|
let Matrix$1 = class Matrix extends MathArray {
|
65442
65514
|
toString() {
|
65443
65515
|
let string2 = "[";
|
65444
|
-
if (config$
|
65516
|
+
if (config$3.printRowMajor) {
|
65445
65517
|
string2 += "row-major:";
|
65446
65518
|
for (let row = 0; row < this.RANK; ++row) {
|
65447
65519
|
for (let col = 0; col < this.RANK; ++col) {
|
@@ -67304,7 +67376,7 @@ class SphericalCoordinates {
|
|
67304
67376
|
this.check();
|
67305
67377
|
}
|
67306
67378
|
toString() {
|
67307
|
-
return this.formatString(config$
|
67379
|
+
return this.formatString(config$3);
|
67308
67380
|
}
|
67309
67381
|
formatString({
|
67310
67382
|
printTypes = false
|
@@ -110879,7 +110951,7 @@ function fromCartographic(cartographic, result = [], map2 = identity$f) {
|
|
110879
110951
|
return result;
|
110880
110952
|
}
|
110881
110953
|
function fromCartographicToRadians(cartographic, vector = []) {
|
110882
|
-
return fromCartographic(cartographic, vector, config$
|
110954
|
+
return fromCartographic(cartographic, vector, config$3._cartographicRadians ? identity$f : toRadians);
|
110883
110955
|
}
|
110884
110956
|
function toCartographic(vector, cartographic, map2 = identity$f) {
|
110885
110957
|
if ("longitude" in cartographic) {
|
@@ -110898,7 +110970,7 @@ function toCartographic(vector, cartographic, map2 = identity$f) {
|
|
110898
110970
|
return cartographic;
|
110899
110971
|
}
|
110900
110972
|
function toCartographicFromRadians(vector, cartographic) {
|
110901
|
-
return toCartographic(vector, cartographic, config$
|
110973
|
+
return toCartographic(vector, cartographic, config$3._cartographicRadians ? identity$f : toDegrees);
|
110902
110974
|
}
|
110903
110975
|
const scratchVector$4 = new Vector3();
|
110904
110976
|
const scaleToGeodeticSurfaceIntersection = new Vector3();
|
@@ -123453,14 +123525,14 @@ var jsts_min = { exports: {} };
|
|
123453
123525
|
return 1e-15;
|
123454
123526
|
}, Object.defineProperties(q, B2);
|
123455
123527
|
var V = function() {
|
123456
|
-
},
|
123457
|
-
|
123528
|
+
}, U2 = { X: { configurable: true }, Y: { configurable: true }, Z: { configurable: true }, M: { configurable: true } };
|
123529
|
+
U2.X.get = function() {
|
123458
123530
|
return 0;
|
123459
|
-
},
|
123531
|
+
}, U2.Y.get = function() {
|
123460
123532
|
return 1;
|
123461
|
-
},
|
123533
|
+
}, U2.Z.get = function() {
|
123462
123534
|
return 2;
|
123463
|
-
},
|
123535
|
+
}, U2.M.get = function() {
|
123464
123536
|
return 3;
|
123465
123537
|
}, V.prototype.setOrdinate = function(t5, e4, n4) {
|
123466
123538
|
}, V.prototype.size = function() {
|
@@ -123478,7 +123550,7 @@ var jsts_min = { exports: {} };
|
|
123478
123550
|
return [x2];
|
123479
123551
|
}, V.prototype.getClass = function() {
|
123480
123552
|
return V;
|
123481
|
-
}, Object.defineProperties(V,
|
123553
|
+
}, Object.defineProperties(V, U2);
|
123482
123554
|
var z2 = function() {
|
123483
123555
|
}, X3 = function(t5) {
|
123484
123556
|
function e4() {
|
@@ -151888,7 +151960,7 @@ const esm = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty(
|
|
151888
151960
|
atan: atan$3,
|
151889
151961
|
clamp: clamp$3,
|
151890
151962
|
clone: clone$9,
|
151891
|
-
config: config$
|
151963
|
+
config: config$3,
|
151892
151964
|
configure,
|
151893
151965
|
cos: cos$5,
|
151894
151966
|
degrees: degrees$5,
|
@@ -156325,16 +156397,16 @@ async function getDecoder(fileDirectory) {
|
|
156325
156397
|
const Decoder = await importFn();
|
156326
156398
|
return new Decoder(fileDirectory);
|
156327
156399
|
}
|
156328
|
-
addDecoder([void 0, 1], () => import("./raw-
|
156329
|
-
addDecoder(5, () => import("./lzw-
|
156400
|
+
addDecoder([void 0, 1], () => import("./raw-6a5ee9b6.js").then((m2) => m2.default));
|
156401
|
+
addDecoder(5, () => import("./lzw-e6575211.js").then((m2) => m2.default));
|
156330
156402
|
addDecoder(6, () => {
|
156331
156403
|
throw new Error("old style JPEG compression is not supported.");
|
156332
156404
|
});
|
156333
|
-
addDecoder(7, () => import("./jpeg-
|
156334
|
-
addDecoder([8, 32946], () => import("./deflate-
|
156335
|
-
addDecoder(32773, () => import("./packbits-
|
156336
|
-
addDecoder(34887, () => import("./lerc-
|
156337
|
-
addDecoder(50001, () => import("./webimage-
|
156405
|
+
addDecoder(7, () => import("./jpeg-913b4a29.js").then((m2) => m2.default));
|
156406
|
+
addDecoder([8, 32946], () => import("./deflate-aae0b27f.js").then((m2) => m2.default));
|
156407
|
+
addDecoder(32773, () => import("./packbits-d3d3e4e9.js").then((m2) => m2.default));
|
156408
|
+
addDecoder(34887, () => import("./lerc-c5d4fc8f.js").then((m2) => m2.default));
|
156409
|
+
addDecoder(50001, () => import("./webimage-6e4a32e0.js").then((m2) => m2.default));
|
156338
156410
|
function copyNewSize(array2, width2, height2, samplesPerPixel = 1) {
|
156339
156411
|
return new (Object.getPrototypeOf(array2)).constructor(width2 * height2 * samplesPerPixel);
|
156340
156412
|
}
|
@@ -161339,14 +161411,14 @@ const makeTable = () => {
|
|
161339
161411
|
return table;
|
161340
161412
|
};
|
161341
161413
|
const crcTable = new Uint32Array(makeTable());
|
161342
|
-
const crc32 = (
|
161414
|
+
const crc32 = (crc2, buf, len2, pos) => {
|
161343
161415
|
const t4 = crcTable;
|
161344
161416
|
const end = pos + len2;
|
161345
|
-
|
161417
|
+
crc2 ^= -1;
|
161346
161418
|
for (let i2 = pos; i2 < end; i2++) {
|
161347
|
-
|
161419
|
+
crc2 = crc2 >>> 8 ^ t4[(crc2 ^ buf[i2]) & 255];
|
161348
161420
|
}
|
161349
|
-
return
|
161421
|
+
return crc2 ^ -1;
|
161350
161422
|
};
|
161351
161423
|
var crc32_1 = crc32;
|
161352
161424
|
var messages = {
|
@@ -163548,7 +163620,7 @@ const updatewindow = (strm, src2, end, copy2) => {
|
|
163548
163620
|
}
|
163549
163621
|
return 0;
|
163550
163622
|
};
|
163551
|
-
const inflate = (strm, flush2) => {
|
163623
|
+
const inflate$1 = (strm, flush2) => {
|
163552
163624
|
let state;
|
163553
163625
|
let input, output2;
|
163554
163626
|
let next3;
|
@@ -164505,7 +164577,7 @@ var inflateReset2_1 = inflateReset2;
|
|
164505
164577
|
var inflateResetKeep_1 = inflateResetKeep;
|
164506
164578
|
var inflateInit_1 = inflateInit;
|
164507
164579
|
var inflateInit2_1 = inflateInit2;
|
164508
|
-
var inflate_2 = inflate;
|
164580
|
+
var inflate_2 = inflate$1;
|
164509
164581
|
var inflateEnd_1 = inflateEnd;
|
164510
164582
|
var inflateGetHeader_1 = inflateGetHeader;
|
164511
164583
|
var inflateSetDictionary_1 = inflateSetDictionary;
|
@@ -164687,22 +164759,22 @@ Inflate.prototype.onEnd = function(status) {
|
|
164687
164759
|
this.err = status;
|
164688
164760
|
this.msg = this.strm.msg;
|
164689
164761
|
};
|
164690
|
-
function inflate$1(input, options) {
|
164762
|
+
function inflate$1$1(input, options) {
|
164691
164763
|
const inflator = new Inflate(options);
|
164692
164764
|
inflator.push(input);
|
164693
164765
|
if (inflator.err)
|
164694
164766
|
throw inflator.msg || messages[inflator.err];
|
164695
164767
|
return inflator.result;
|
164696
164768
|
}
|
164697
|
-
function inflateRaw(input, options) {
|
164769
|
+
function inflateRaw$1(input, options) {
|
164698
164770
|
options = options || {};
|
164699
164771
|
options.raw = true;
|
164700
|
-
return inflate$1(input, options);
|
164772
|
+
return inflate$1$1(input, options);
|
164701
164773
|
}
|
164702
164774
|
var Inflate_1 = Inflate;
|
164703
|
-
var inflate_2$1 = inflate$1;
|
164704
|
-
var inflateRaw_1 = inflateRaw;
|
164705
|
-
var ungzip = inflate$1;
|
164775
|
+
var inflate_2$1 = inflate$1$1;
|
164776
|
+
var inflateRaw_1 = inflateRaw$1;
|
164777
|
+
var ungzip = inflate$1$1;
|
164706
164778
|
var constants$2$1 = constants$3;
|
164707
164779
|
var inflate_1$1 = {
|
164708
164780
|
Inflate: Inflate_1,
|
@@ -164712,14 +164784,14 @@ var inflate_1$1 = {
|
|
164712
164784
|
constants: constants$2$1
|
164713
164785
|
};
|
164714
164786
|
const { Deflate: Deflate$1, deflate: deflate$2, deflateRaw: deflateRaw$1, gzip: gzip$1 } = deflate_1$1;
|
164715
|
-
const { Inflate: Inflate$1, inflate: inflate$2, inflateRaw: inflateRaw$1, ungzip: ungzip$1 } = inflate_1$1;
|
164787
|
+
const { Inflate: Inflate$1, inflate: inflate$2, inflateRaw: inflateRaw$1$1, ungzip: ungzip$1 } = inflate_1$1;
|
164716
164788
|
var Deflate_1$1 = Deflate$1;
|
164717
164789
|
var deflate_1$2 = deflate$2;
|
164718
164790
|
var deflateRaw_1$1 = deflateRaw$1;
|
164719
164791
|
var gzip_1$1 = gzip$1;
|
164720
164792
|
var Inflate_1$1 = Inflate$1;
|
164721
164793
|
var inflate_1$2 = inflate$2;
|
164722
|
-
var inflateRaw_1$1 = inflateRaw$1;
|
164794
|
+
var inflateRaw_1$1 = inflateRaw$1$1;
|
164723
164795
|
var ungzip_1 = ungzip$1;
|
164724
164796
|
var constants_1 = constants$3;
|
164725
164797
|
var pako = {
|
@@ -165105,7 +165177,7 @@ var blosc_codec = function() {
|
|
165105
165177
|
if (h2.length !== d.length)
|
165106
165178
|
throw new La("Mismatched type converter count");
|
165107
165179
|
for (var l2 = 0; l2 < d.length; ++l2)
|
165108
|
-
|
165180
|
+
U2(d[l2], h2[l2]);
|
165109
165181
|
}
|
165110
165182
|
var d = [];
|
165111
165183
|
d.forEach(function(h2) {
|
@@ -165121,7 +165193,7 @@ var blosc_codec = function() {
|
|
165121
165193
|
});
|
165122
165194
|
0 === g2.length && c2(e3);
|
165123
165195
|
}
|
165124
|
-
function
|
165196
|
+
function U2(a2, b2, c2) {
|
165125
165197
|
c2 = c2 || {};
|
165126
165198
|
if (!("argPackAdvance" in b2))
|
165127
165199
|
throw new TypeError("registerType registeredInstance requires argPackAdvance");
|
@@ -165316,7 +165388,7 @@ var blosc_codec = function() {
|
|
165316
165388
|
}, z: function(a2, b2, c2, d, e3) {
|
165317
165389
|
var g2 = Fa(c2);
|
165318
165390
|
b2 = P2(b2);
|
165319
|
-
|
165391
|
+
U2(a2, { name: b2, fromWireType: function(k) {
|
165320
165392
|
return !!k;
|
165321
165393
|
}, toWireType: function(k, h2) {
|
165322
165394
|
return h2 ? d : e3;
|
@@ -165333,7 +165405,7 @@ var blosc_codec = function() {
|
|
165333
165405
|
}, M: null });
|
165334
165406
|
}, y: function(a2, b2) {
|
165335
165407
|
b2 = P2(b2);
|
165336
|
-
|
165408
|
+
U2(a2, { name: b2, fromWireType: function(c2) {
|
165337
165409
|
var d = V[c2].value;
|
165338
165410
|
Qa(c2);
|
165339
165411
|
return d;
|
@@ -165343,7 +165415,7 @@ var blosc_codec = function() {
|
|
165343
165415
|
}, h: function(a2, b2, c2) {
|
165344
165416
|
c2 = Fa(c2);
|
165345
165417
|
b2 = P2(b2);
|
165346
|
-
|
165418
|
+
U2(a2, { name: b2, fromWireType: function(d) {
|
165347
165419
|
return d;
|
165348
165420
|
}, toWireType: function(d, e3) {
|
165349
165421
|
if ("number" !== typeof e3 && "boolean" !== typeof e3)
|
@@ -165411,7 +165483,7 @@ var blosc_codec = function() {
|
|
165411
165483
|
};
|
165412
165484
|
}
|
165413
165485
|
var l2 = -1 != b2.indexOf("unsigned");
|
165414
|
-
|
165486
|
+
U2(a2, { name: b2, fromWireType: g2, toWireType: function(n3, p) {
|
165415
165487
|
if ("number" !== typeof p && "boolean" !== typeof p)
|
165416
165488
|
throw new TypeError('Cannot convert "' + Ta(p) + '" to ' + this.name);
|
165417
165489
|
if (p < d || p > e3)
|
@@ -165430,11 +165502,11 @@ var blosc_codec = function() {
|
|
165430
165502
|
}
|
165431
165503
|
var e3 = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array][b2];
|
165432
165504
|
c2 = P2(c2);
|
165433
|
-
|
165505
|
+
U2(a2, { name: c2, fromWireType: d, argPackAdvance: 8, readValueFromPointer: d }, { U: true });
|
165434
165506
|
}, i: function(a2, b2) {
|
165435
165507
|
b2 = P2(b2);
|
165436
165508
|
var c2 = "std::string" === b2;
|
165437
|
-
|
165509
|
+
U2(a2, { name: b2, fromWireType: function(d) {
|
165438
165510
|
var e3 = G2[d >> 2];
|
165439
165511
|
if (c2)
|
165440
165512
|
for (var g2 = d + 4, k = 0; k <= e3; ++k) {
|
@@ -165501,7 +165573,7 @@ var blosc_codec = function() {
|
|
165501
165573
|
4 === b2 && (d = na, e3 = oa, g2 = pa2, k = function() {
|
165502
165574
|
return G2;
|
165503
165575
|
}, h2 = 2);
|
165504
|
-
|
165576
|
+
U2(a2, { name: c2, fromWireType: function(l2) {
|
165505
165577
|
for (var n3 = G2[l2 >> 2], p = k(), q, x2 = l2 + 4, B2 = 0; B2 <= n3; ++B2) {
|
165506
165578
|
var m2 = l2 + 4 + B2 * b2;
|
165507
165579
|
if (B2 == n3 || 0 == p[m2 >> h2])
|
@@ -165521,7 +165593,7 @@ var blosc_codec = function() {
|
|
165521
165593
|
} });
|
165522
165594
|
}, A: function(a2, b2) {
|
165523
165595
|
b2 = P2(b2);
|
165524
|
-
|
165596
|
+
U2(a2, {
|
165525
165597
|
aa: true,
|
165526
165598
|
name: b2,
|
165527
165599
|
argPackAdvance: 0,
|
@@ -171820,10 +171892,10 @@ const $f0a04ccd8dbdd83b$export$e5c5a5f917a5871c = typeof document !== "undefined
|
|
171820
171892
|
let $bdb11010cef70236$var$idsUpdaterMap = /* @__PURE__ */ new Map();
|
171821
171893
|
function $bdb11010cef70236$export$f680877a34711e37(defaultId2) {
|
171822
171894
|
let [value2, setValue] = useState(defaultId2);
|
171823
|
-
let
|
171895
|
+
let nextId2 = useRef(null);
|
171824
171896
|
let res = $b5e257d569688ac6$export$619500959fc48b26(value2);
|
171825
171897
|
let updateValue = useCallback((val) => {
|
171826
|
-
|
171898
|
+
nextId2.current = val;
|
171827
171899
|
}, []);
|
171828
171900
|
$bdb11010cef70236$var$idsUpdaterMap.set(res, updateValue);
|
171829
171901
|
$f0a04ccd8dbdd83b$export$e5c5a5f917a5871c(() => {
|
@@ -171835,9 +171907,9 @@ function $bdb11010cef70236$export$f680877a34711e37(defaultId2) {
|
|
171835
171907
|
res
|
171836
171908
|
]);
|
171837
171909
|
useEffect(() => {
|
171838
|
-
let newId =
|
171910
|
+
let newId = nextId2.current;
|
171839
171911
|
if (newId) {
|
171840
|
-
|
171912
|
+
nextId2.current = null;
|
171841
171913
|
setValue(newId);
|
171842
171914
|
}
|
171843
171915
|
});
|
@@ -175784,6 +175856,7 @@ function MultiLegend(props2) {
|
|
175784
175856
|
spotLayerScopes,
|
175785
175857
|
spotLayerCoordination,
|
175786
175858
|
spotMultiExpressionExtents,
|
175859
|
+
spotMultiFeatureLabels,
|
175787
175860
|
// Points
|
175788
175861
|
pointLayerScopes,
|
175789
175862
|
pointLayerCoordination
|
@@ -175816,32 +175889,15 @@ function MultiLegend(props2) {
|
|
175816
175889
|
height: height2
|
175817
175890
|
}, layerScope) : null;
|
175818
175891
|
}) : null, spotLayerScopes ? reversedSpotLayerScopes.flatMap((layerScope) => {
|
175892
|
+
var _a3;
|
175819
175893
|
const layerCoordination = spotLayerCoordination[0][layerScope];
|
175820
175894
|
const { spatialLayerVisible, obsColorEncoding, featureValueColormap, featureValueColormapRange, obsType, featureType, featureValueType, featureSelection, spatialLayerColor, legendVisible, obsSetSelection, obsSetColor } = layerCoordination;
|
175821
175895
|
const expressionExtents = spotMultiExpressionExtents == null ? void 0 : spotMultiExpressionExtents[layerScope];
|
175822
175896
|
const firstExpressionExtent = expressionExtents == null ? void 0 : expressionExtents[0];
|
175823
175897
|
const isStaticColor = obsColorEncoding === "spatialLayerColor";
|
175824
175898
|
const height2 = isStaticColor ? 20 : 36;
|
175825
|
-
|
175826
|
-
|
175827
|
-
highContrast: true,
|
175828
|
-
showObsLabel: true,
|
175829
|
-
visible: spatialLayerVisible,
|
175830
|
-
theme,
|
175831
|
-
obsType,
|
175832
|
-
featureType,
|
175833
|
-
featureValueType,
|
175834
|
-
obsColorEncoding,
|
175835
|
-
spatialLayerColor,
|
175836
|
-
featureSelection,
|
175837
|
-
// featureLabelsMap={featureLabelsMap} // TODO
|
175838
|
-
featureValueColormap,
|
175839
|
-
featureValueColormapRange,
|
175840
|
-
extent: firstExpressionExtent,
|
175841
|
-
height: height2,
|
175842
|
-
obsSetSelection,
|
175843
|
-
obsSetColor
|
175844
|
-
}, layerScope) : null;
|
175899
|
+
const featureLabelsMap = (_a3 = spotMultiFeatureLabels == null ? void 0 : spotMultiFeatureLabels[layerScope]) == null ? void 0 : _a3.featureLabelsMap;
|
175900
|
+
return spatialLayerVisible && legendVisible ? jsxRuntimeExports.jsx(Legend, { positionRelative: true, highContrast: true, showObsLabel: true, visible: spatialLayerVisible, theme, obsType, featureType, featureValueType, obsColorEncoding, spatialLayerColor, featureSelection, featureLabelsMap, featureValueColormap, featureValueColormapRange, extent: firstExpressionExtent, height: height2, obsSetSelection, obsSetColor }, layerScope) : null;
|
175845
175901
|
}) : null, segmentationLayerScopes ? reversedSegmentationLayerScopes.flatMap((layerScope) => {
|
175846
175902
|
const layerCoordination = segmentationLayerCoordination[0][layerScope];
|
175847
175903
|
const channelScopes = segmentationChannelScopesByLayer[layerScope];
|
@@ -176468,7 +176524,7 @@ function isFunctionNode(x2) {
|
|
176468
176524
|
function isIndexNode(x2) {
|
176469
176525
|
return x2 && x2.isIndexNode === true && x2.constructor.prototype.isNode === true || false;
|
176470
176526
|
}
|
176471
|
-
function isNode(x2) {
|
176527
|
+
function isNode$1(x2) {
|
176472
176528
|
return x2 && x2.isNode === true && x2.constructor.prototype.isNode === true || false;
|
176473
176529
|
}
|
176474
176530
|
function isObjectNode(x2) {
|
@@ -176516,7 +176572,7 @@ function typeOf(x2) {
|
|
176516
176572
|
return "Range";
|
176517
176573
|
if (isResultSet(x2))
|
176518
176574
|
return "ResultSet";
|
176519
|
-
if (isNode(x2))
|
176575
|
+
if (isNode$1(x2))
|
176520
176576
|
return x2.type;
|
176521
176577
|
if (isChain(x2))
|
176522
176578
|
return "Chain";
|
@@ -176618,13 +176674,13 @@ function pickShallow(object2, properties) {
|
|
176618
176674
|
}
|
176619
176675
|
var MATRIX_OPTIONS = ["Matrix", "Array"];
|
176620
176676
|
var NUMBER_OPTIONS = ["number", "BigNumber", "Fraction"];
|
176621
|
-
var config$
|
176677
|
+
var config$2 = function config(options) {
|
176622
176678
|
if (options) {
|
176623
176679
|
throw new Error("The global config is readonly. \nPlease create a mathjs instance if you want to change the default configuration. \nExample:\n\n import { create, all } from 'mathjs';\n const mathjs = create(all);\n mathjs.config({ number: 'BigNumber' });\n");
|
176624
176680
|
}
|
176625
176681
|
return Object.freeze(DEFAULT_CONFIG);
|
176626
176682
|
};
|
176627
|
-
_extends$6(config$
|
176683
|
+
_extends$6(config$2, DEFAULT_CONFIG, {
|
176628
176684
|
MATRIX_OPTIONS,
|
176629
176685
|
NUMBER_OPTIONS
|
176630
176686
|
});
|
@@ -178390,7 +178446,7 @@ var createTyped = /* @__PURE__ */ factory("typed", dependencies$R, function crea
|
|
178390
178446
|
},
|
178391
178447
|
{
|
178392
178448
|
name: "Node",
|
178393
|
-
test: isNode
|
178449
|
+
test: isNode$1
|
178394
178450
|
},
|
178395
178451
|
{
|
178396
178452
|
name: "ObjectNode",
|
@@ -180567,7 +180623,7 @@ function ceil$2(x2) {
|
|
180567
180623
|
function clamp$1(x2, min2, max2) {
|
180568
180624
|
return new this(x2).clamp(min2, max2);
|
180569
180625
|
}
|
180570
|
-
function
|
180626
|
+
function config$1(obj) {
|
180571
180627
|
if (!obj || typeof obj !== "object")
|
180572
180628
|
throw Error(decimalError + "Object expected");
|
180573
180629
|
var i2, p, v, useDefaults = obj.defaults === true, ps = [
|
@@ -180719,7 +180775,7 @@ function clone$1(obj) {
|
|
180719
180775
|
Decimal2.ROUND_HALF_CEIL = 7;
|
180720
180776
|
Decimal2.ROUND_HALF_FLOOR = 8;
|
180721
180777
|
Decimal2.EUCLID = 9;
|
180722
|
-
Decimal2.config = Decimal2.set =
|
180778
|
+
Decimal2.config = Decimal2.set = config$1;
|
180723
180779
|
Decimal2.clone = clone$1;
|
180724
180780
|
Decimal2.isDecimal = isDecimalInstance;
|
180725
180781
|
Decimal2.abs = abs$4;
|
@@ -191120,7 +191176,7 @@ var createDivide = /* @__PURE__ */ factory(name$2, dependencies$1, (_ref3) => {
|
|
191120
191176
|
});
|
191121
191177
|
var Complex = /* @__PURE__ */ createComplexClass({});
|
191122
191178
|
var BigNumber = /* @__PURE__ */ createBigNumberClass({
|
191123
|
-
config: config$
|
191179
|
+
config: config$2
|
191124
191180
|
});
|
191125
191181
|
var Matrix2 = /* @__PURE__ */ createMatrixClass({});
|
191126
191182
|
var Fraction = /* @__PURE__ */ createFractionClass({});
|
@@ -191137,7 +191193,7 @@ var isNumeric$1 = /* @__PURE__ */ createIsNumeric({
|
|
191137
191193
|
typed
|
191138
191194
|
});
|
191139
191195
|
var equalScalar = /* @__PURE__ */ createEqualScalar({
|
191140
|
-
config: config$
|
191196
|
+
config: config$2,
|
191141
191197
|
typed
|
191142
191198
|
});
|
191143
191199
|
var number$9 = /* @__PURE__ */ createNumber({
|
@@ -191180,18 +191236,18 @@ var identity$8 = /* @__PURE__ */ createIdentity({
|
|
191180
191236
|
BigNumber,
|
191181
191237
|
DenseMatrix,
|
191182
191238
|
SparseMatrix,
|
191183
|
-
config: config$
|
191239
|
+
config: config$2,
|
191184
191240
|
matrix,
|
191185
191241
|
typed
|
191186
191242
|
});
|
191187
191243
|
var size$1 = /* @__PURE__ */ createSize({
|
191188
191244
|
matrix,
|
191189
|
-
config: config$
|
191245
|
+
config: config$2,
|
191190
191246
|
typed
|
191191
191247
|
});
|
191192
191248
|
var zeros = /* @__PURE__ */ createZeros({
|
191193
191249
|
BigNumber,
|
191194
|
-
config: config$
|
191250
|
+
config: config$2,
|
191195
191251
|
matrix,
|
191196
191252
|
typed
|
191197
191253
|
});
|
@@ -191207,20 +191263,20 @@ var compare$a = /* @__PURE__ */ createCompare({
|
|
191207
191263
|
BigNumber,
|
191208
191264
|
DenseMatrix,
|
191209
191265
|
Fraction,
|
191210
|
-
config: config$
|
191266
|
+
config: config$2,
|
191211
191267
|
equalScalar,
|
191212
191268
|
matrix,
|
191213
191269
|
typed
|
191214
191270
|
});
|
191215
191271
|
var smaller = /* @__PURE__ */ createSmaller({
|
191216
191272
|
DenseMatrix,
|
191217
|
-
config: config$
|
191273
|
+
config: config$2,
|
191218
191274
|
matrix,
|
191219
191275
|
typed
|
191220
191276
|
});
|
191221
191277
|
var larger = /* @__PURE__ */ createLarger({
|
191222
191278
|
DenseMatrix,
|
191223
|
-
config: config$
|
191279
|
+
config: config$2,
|
191224
191280
|
matrix,
|
191225
191281
|
typed
|
191226
191282
|
});
|
@@ -191236,7 +191292,7 @@ var dot = /* @__PURE__ */ createDot({
|
|
191236
191292
|
typed
|
191237
191293
|
});
|
191238
191294
|
var floor$1 = /* @__PURE__ */ createFloor({
|
191239
|
-
config: config$
|
191295
|
+
config: config$2,
|
191240
191296
|
equalScalar,
|
191241
191297
|
matrix,
|
191242
191298
|
round: round$1,
|
@@ -191252,7 +191308,7 @@ var multiply = /* @__PURE__ */ createMultiply({
|
|
191252
191308
|
});
|
191253
191309
|
var pow$5 = /* @__PURE__ */ createPow({
|
191254
191310
|
Complex,
|
191255
|
-
config: config$
|
191311
|
+
config: config$2,
|
191256
191312
|
fraction,
|
191257
191313
|
identity: identity$8,
|
191258
191314
|
matrix,
|
@@ -191284,7 +191340,7 @@ var equal$1 = /* @__PURE__ */ createEqual({
|
|
191284
191340
|
typed
|
191285
191341
|
});
|
191286
191342
|
var ceil$1 = /* @__PURE__ */ createCeil({
|
191287
|
-
config: config$
|
191343
|
+
config: config$2,
|
191288
191344
|
equalScalar,
|
191289
191345
|
matrix,
|
191290
191346
|
round: round$1,
|
@@ -191354,7 +191410,7 @@ var Unit = /* @__PURE__ */ createUnitClass({
|
|
191354
191410
|
Fraction,
|
191355
191411
|
abs: abs$3,
|
191356
191412
|
addScalar,
|
191357
|
-
config: config$
|
191413
|
+
config: config$2,
|
191358
191414
|
divideScalar,
|
191359
191415
|
equal: equal$1,
|
191360
191416
|
fix,
|
@@ -191829,14 +191885,14 @@ function normalizeCoordinateTransformations(coordinateTransformations, datasets)
|
|
191829
191885
|
return result;
|
191830
191886
|
}
|
191831
191887
|
class NodeNotFoundError extends Error {
|
191832
|
-
constructor(
|
191833
|
-
super(
|
191888
|
+
constructor(context2, options = {}) {
|
191889
|
+
super(`Node not found: ${context2}`, options);
|
191834
191890
|
this.name = "NodeNotFoundError";
|
191835
191891
|
}
|
191836
191892
|
}
|
191837
191893
|
class KeyError extends Error {
|
191838
|
-
constructor(
|
191839
|
-
super(
|
191894
|
+
constructor(path2) {
|
191895
|
+
super(`Missing key: ${path2}`);
|
191840
191896
|
this.name = "KeyError";
|
191841
191897
|
}
|
191842
191898
|
}
|
@@ -191947,56 +192003,56 @@ class ByteStringArray {
|
|
191947
192003
|
_encoder = new WeakMap();
|
191948
192004
|
const _UnicodeStringArray = class {
|
191949
192005
|
constructor(chars, x2, byteOffset, length2) {
|
191950
|
-
|
192006
|
+
__privateAdd(this, _data, void 0);
|
191951
192007
|
__publicField(this, "chars");
|
191952
192008
|
__privateAdd(this, _encode_buffer, void 0);
|
191953
192009
|
this.chars = chars;
|
191954
192010
|
if (typeof x2 === "number") {
|
191955
|
-
this
|
192011
|
+
__privateSet(this, _data, new Int32Array(x2 * chars));
|
191956
192012
|
} else if (x2 instanceof ArrayBuffer) {
|
191957
192013
|
if (length2)
|
191958
192014
|
length2 *= chars;
|
191959
|
-
this
|
192015
|
+
__privateSet(this, _data, new Int32Array(x2, byteOffset, length2));
|
191960
192016
|
} else {
|
191961
192017
|
const values3 = x2;
|
191962
192018
|
const d = new _UnicodeStringArray(chars, 1);
|
191963
|
-
this
|
192019
|
+
__privateSet(this, _data, new Int32Array(function* () {
|
191964
192020
|
for (let str of values3) {
|
191965
192021
|
d.set(0, str);
|
191966
|
-
yield* d
|
192022
|
+
yield* __privateGet(d, _data);
|
191967
192023
|
}
|
191968
|
-
}());
|
192024
|
+
}()));
|
191969
192025
|
}
|
191970
192026
|
__privateSet(this, _encode_buffer, new Int32Array(chars));
|
191971
192027
|
}
|
191972
192028
|
get BYTES_PER_ELEMENT() {
|
191973
|
-
return this
|
192029
|
+
return __privateGet(this, _data).BYTES_PER_ELEMENT * this.chars;
|
191974
192030
|
}
|
191975
192031
|
get byteLength() {
|
191976
|
-
return this
|
192032
|
+
return __privateGet(this, _data).byteLength;
|
191977
192033
|
}
|
191978
192034
|
get byteOffset() {
|
191979
|
-
return this
|
192035
|
+
return __privateGet(this, _data).byteOffset;
|
191980
192036
|
}
|
191981
192037
|
/** @type {ArrayBuffer} */
|
191982
192038
|
get buffer() {
|
191983
|
-
return this
|
192039
|
+
return __privateGet(this, _data).buffer;
|
191984
192040
|
}
|
191985
192041
|
/** @type {number} */
|
191986
192042
|
get length() {
|
191987
|
-
return this
|
192043
|
+
return __privateGet(this, _data).length / this.chars;
|
191988
192044
|
}
|
191989
192045
|
get(idx) {
|
191990
192046
|
const offset6 = this.chars * idx;
|
191991
192047
|
let result = "";
|
191992
192048
|
for (let i2 = 0; i2 < this.chars; i2++) {
|
191993
|
-
result += String.fromCodePoint(this
|
192049
|
+
result += String.fromCodePoint(__privateGet(this, _data)[offset6 + i2]);
|
191994
192050
|
}
|
191995
192051
|
return result.replace(/\u0000/g, "");
|
191996
192052
|
}
|
191997
192053
|
set(idx, value2) {
|
191998
192054
|
const offset6 = this.chars * idx;
|
191999
|
-
const view = this
|
192055
|
+
const view = __privateGet(this, _data).subarray(offset6, offset6 + this.chars);
|
192000
192056
|
view.fill(0);
|
192001
192057
|
for (let i2 = 0; i2 < this.chars; i2++) {
|
192002
192058
|
view[i2] = value2.codePointAt(i2) ?? 0;
|
@@ -192004,9 +192060,9 @@ const _UnicodeStringArray = class {
|
|
192004
192060
|
}
|
192005
192061
|
fill(value2) {
|
192006
192062
|
this.set(0, value2);
|
192007
|
-
let encoded = this
|
192063
|
+
let encoded = __privateGet(this, _data).subarray(0, this.chars);
|
192008
192064
|
for (let i2 = 1; i2 < this.length; i2++) {
|
192009
|
-
this
|
192065
|
+
__privateGet(this, _data).set(encoded, i2 * this.chars);
|
192010
192066
|
}
|
192011
192067
|
}
|
192012
192068
|
*[Symbol.iterator]() {
|
@@ -192016,6 +192072,7 @@ const _UnicodeStringArray = class {
|
|
192016
192072
|
}
|
192017
192073
|
};
|
192018
192074
|
let UnicodeStringArray = _UnicodeStringArray;
|
192075
|
+
_data = new WeakMap();
|
192019
192076
|
_encode_buffer = new WeakMap();
|
192020
192077
|
function json_decode_object(bytes) {
|
192021
192078
|
const str = new TextDecoder().decode(bytes);
|
@@ -192381,8 +192438,115 @@ const _VLenUTF8 = class {
|
|
192381
192438
|
let VLenUTF8 = _VLenUTF8;
|
192382
192439
|
_shape2 = new WeakMap();
|
192383
192440
|
_strides2 = new WeakMap();
|
192441
|
+
function throw_on_nan_replacer(_key, value2) {
|
192442
|
+
if (value2 !== value2) {
|
192443
|
+
throw new Error("JsonCodec allow_nan is false but NaN was encountered during encoding.");
|
192444
|
+
}
|
192445
|
+
if (value2 === Infinity) {
|
192446
|
+
throw new Error("JsonCodec allow_nan is false but Infinity was encountered during encoding.");
|
192447
|
+
}
|
192448
|
+
if (value2 === -Infinity) {
|
192449
|
+
throw new Error("JsonCodec allow_nan is false but -Infinity was encountered during encoding.");
|
192450
|
+
}
|
192451
|
+
return value2;
|
192452
|
+
}
|
192453
|
+
function sort_keys_replacer(_key, value2) {
|
192454
|
+
return value2 instanceof Object && !(value2 instanceof Array) ? Object.keys(value2).sort().reduce((sorted, key2) => {
|
192455
|
+
sorted[key2] = value2[key2];
|
192456
|
+
return sorted;
|
192457
|
+
}, {}) : value2;
|
192458
|
+
}
|
192459
|
+
const _JsonCodec = class {
|
192460
|
+
constructor(configuration) {
|
192461
|
+
__publicField(this, "configuration");
|
192462
|
+
__publicField(this, "kind", "array_to_bytes");
|
192463
|
+
__privateAdd(this, _encoder_config, void 0);
|
192464
|
+
__privateAdd(this, _decoder_config, void 0);
|
192465
|
+
this.configuration = configuration;
|
192466
|
+
const { encoding = "utf-8", skipkeys = false, ensure_ascii = true, check_circular = true, allow_nan = true, sort_keys = true, indent, strict = true } = configuration;
|
192467
|
+
let separators = configuration.separators;
|
192468
|
+
if (!separators) {
|
192469
|
+
if (!indent) {
|
192470
|
+
separators = [",", ":"];
|
192471
|
+
} else {
|
192472
|
+
separators = [", ", ": "];
|
192473
|
+
}
|
192474
|
+
}
|
192475
|
+
__privateSet(this, _encoder_config, {
|
192476
|
+
encoding,
|
192477
|
+
skipkeys,
|
192478
|
+
ensure_ascii,
|
192479
|
+
check_circular,
|
192480
|
+
allow_nan,
|
192481
|
+
indent,
|
192482
|
+
separators,
|
192483
|
+
sort_keys
|
192484
|
+
});
|
192485
|
+
__privateSet(this, _decoder_config, { strict });
|
192486
|
+
}
|
192487
|
+
static fromConfig(configuration) {
|
192488
|
+
return new _JsonCodec(configuration);
|
192489
|
+
}
|
192490
|
+
encode(buf) {
|
192491
|
+
const { indent, encoding, ensure_ascii, check_circular, allow_nan, sort_keys } = __privateGet(this, _encoder_config);
|
192492
|
+
if (encoding !== "utf-8") {
|
192493
|
+
throw new Error("JsonCodec does not yet support non-utf-8 encoding.");
|
192494
|
+
}
|
192495
|
+
const replacer_functions = [];
|
192496
|
+
if (!check_circular) {
|
192497
|
+
throw new Error("JsonCodec does not yet support skipping the check for circular references during encoding.");
|
192498
|
+
}
|
192499
|
+
if (!allow_nan) {
|
192500
|
+
replacer_functions.push(throw_on_nan_replacer);
|
192501
|
+
}
|
192502
|
+
if (sort_keys) {
|
192503
|
+
replacer_functions.push(sort_keys_replacer);
|
192504
|
+
}
|
192505
|
+
const items = Array.from(buf.data);
|
192506
|
+
items.push("|O");
|
192507
|
+
items.push(buf.shape);
|
192508
|
+
let replacer2 = void 0;
|
192509
|
+
if (replacer_functions.length) {
|
192510
|
+
replacer2 = function(key2, value2) {
|
192511
|
+
let new_value = value2;
|
192512
|
+
replacer_functions.forEach((sub_replacer) => {
|
192513
|
+
new_value = sub_replacer(key2, new_value);
|
192514
|
+
});
|
192515
|
+
return new_value;
|
192516
|
+
};
|
192517
|
+
}
|
192518
|
+
let json_str = JSON.stringify(items, replacer2, indent);
|
192519
|
+
if (ensure_ascii) {
|
192520
|
+
json_str = json_str.replace(/[\u007F-\uFFFF]/g, function(chr) {
|
192521
|
+
const full_str = "0000" + chr.charCodeAt(0).toString(16);
|
192522
|
+
const sub_str = full_str.substring(full_str.length - 4);
|
192523
|
+
return "\\u" + sub_str;
|
192524
|
+
});
|
192525
|
+
}
|
192526
|
+
return new TextEncoder().encode(json_str);
|
192527
|
+
}
|
192528
|
+
decode(bytes) {
|
192529
|
+
const { strict } = __privateGet(this, _decoder_config);
|
192530
|
+
if (!strict) {
|
192531
|
+
throw new Error("JsonCodec does not yet support non-strict decoding.");
|
192532
|
+
}
|
192533
|
+
const items = json_decode_object(bytes);
|
192534
|
+
const shape2 = items.pop();
|
192535
|
+
items.pop();
|
192536
|
+
if (!shape2) {
|
192537
|
+
throw new Error("0D not implemented for JsonCodec.");
|
192538
|
+
} else {
|
192539
|
+
const stride = get_strides(shape2, "C");
|
192540
|
+
const data2 = items;
|
192541
|
+
return { data: data2, shape: shape2, stride };
|
192542
|
+
}
|
192543
|
+
}
|
192544
|
+
};
|
192545
|
+
let JsonCodec = _JsonCodec;
|
192546
|
+
_encoder_config = new WeakMap();
|
192547
|
+
_decoder_config = new WeakMap();
|
192384
192548
|
function create_default_registry() {
|
192385
|
-
return (/* @__PURE__ */ new Map()).set("blosc", () => import("./blosc-
|
192549
|
+
return (/* @__PURE__ */ new Map()).set("blosc", () => import("./blosc-537fd004.js").then((m2) => m2.default)).set("gzip", () => import("./gzip-6a24f0fe.js").then((m2) => m2.default)).set("lz4", () => import("./lz4-bbd18009.js").then((m2) => m2.default)).set("zlib", () => import("./zlib-175cd38d.js").then((m2) => m2.default)).set("zstd", () => import("./zstd-ec5a40b8.js").then((m2) => m2.default)).set("transpose", () => TransposeCodec).set("bytes", () => BytesCodec).set("crc32c", () => Crc32cCodec).set("vlen-utf8", () => VLenUTF8).set("json2", () => JsonCodec);
|
192386
192550
|
}
|
192387
192551
|
const registry = create_default_registry();
|
192388
192552
|
function create_codec_pipeline(chunk_metadata) {
|
@@ -192627,6 +192791,7 @@ let Array$1 = (_c = class extends Location {
|
|
192627
192791
|
return is_dtype(this.dtype, query);
|
192628
192792
|
}
|
192629
192793
|
}, _b = CONTEXT_MARKER, _metadata2 = new WeakMap(), _c);
|
192794
|
+
let VERSION_COUNTER = create_version_counter();
|
192630
192795
|
function create_version_counter() {
|
192631
192796
|
let version_counts = /* @__PURE__ */ new WeakMap();
|
192632
192797
|
function get_counts(store2) {
|
@@ -192644,7 +192809,6 @@ function create_version_counter() {
|
|
192644
192809
|
}
|
192645
192810
|
};
|
192646
192811
|
}
|
192647
|
-
let VERSION_COUNTER = create_version_counter();
|
192648
192812
|
async function load_attrs(location) {
|
192649
192813
|
let meta_bytes = await location.store.get(location.resolve(".zattrs").path);
|
192650
192814
|
if (!meta_bytes)
|
@@ -192670,7 +192834,9 @@ async function open_array_v2(location, attrs) {
|
|
192670
192834
|
let { path: path2 } = location.resolve(".zarray");
|
192671
192835
|
let meta2 = await location.store.get(path2);
|
192672
192836
|
if (!meta2) {
|
192673
|
-
throw new NodeNotFoundError(
|
192837
|
+
throw new NodeNotFoundError("v2 array", {
|
192838
|
+
cause: new KeyError(path2)
|
192839
|
+
});
|
192674
192840
|
}
|
192675
192841
|
VERSION_COUNTER.increment(location.store, "v2");
|
192676
192842
|
return new Array$1(location.store, location.path, v2_to_v3_array_metadata(json_decode_object(meta2), attrs));
|
@@ -192679,7 +192845,9 @@ async function open_group_v2(location, attrs) {
|
|
192679
192845
|
let { path: path2 } = location.resolve(".zgroup");
|
192680
192846
|
let meta2 = await location.store.get(path2);
|
192681
192847
|
if (!meta2) {
|
192682
|
-
throw new NodeNotFoundError(
|
192848
|
+
throw new NodeNotFoundError("v2 group", {
|
192849
|
+
cause: new KeyError(path2)
|
192850
|
+
});
|
192683
192851
|
}
|
192684
192852
|
VERSION_COUNTER.increment(location.store, "v2");
|
192685
192853
|
return new Group$1(location.store, location.path, v2_to_v3_group_metadata(json_decode_object(meta2), attrs));
|
@@ -192688,7 +192856,9 @@ async function _open_v3(location) {
|
|
192688
192856
|
let { store: store2, path: path2 } = location.resolve("zarr.json");
|
192689
192857
|
let meta2 = await location.store.get(path2);
|
192690
192858
|
if (!meta2) {
|
192691
|
-
throw new NodeNotFoundError(
|
192859
|
+
throw new NodeNotFoundError("v3 array or group", {
|
192860
|
+
cause: new KeyError(path2)
|
192861
|
+
});
|
192692
192862
|
}
|
192693
192863
|
let meta_doc = json_decode_object(meta2);
|
192694
192864
|
if (meta_doc.node_type === "array" && (meta_doc.data_type === "uint64" || meta_doc.data_type === "int64") && meta_doc.fill_value != void 0) {
|
@@ -192710,8 +192880,8 @@ async function open_v3(location, options = {}) {
|
|
192710
192880
|
throw new Error(`Expected node of kind ${options.kind}, found ${kind}.`);
|
192711
192881
|
}
|
192712
192882
|
async function open(location, options = {}) {
|
192713
|
-
|
192714
|
-
|
192883
|
+
let store2 = "store" in location ? location.store : location;
|
192884
|
+
let version_max = VERSION_COUNTER.version_max(store2);
|
192715
192885
|
let open_primary = version_max === "v2" ? open.v2 : open.v3;
|
192716
192886
|
let open_secondary = version_max === "v2" ? open.v3 : open.v2;
|
192717
192887
|
return open_primary(location, options).catch((err2) => {
|
@@ -192755,7 +192925,7 @@ function* product(...iterables) {
|
|
192755
192925
|
results[i2] = iterators[i2].next();
|
192756
192926
|
}
|
192757
192927
|
}
|
192758
|
-
function slice_indices(start, stop3, step2, length2) {
|
192928
|
+
function slice_indices({ start, stop: stop3, step: step2 }, length2) {
|
192759
192929
|
if (step2 === 0) {
|
192760
192930
|
throw new Error("slice step cannot be zero");
|
192761
192931
|
}
|
@@ -192796,10 +192966,7 @@ function slice$4(start, stop3, step2 = null) {
|
|
192796
192966
|
return {
|
192797
192967
|
start,
|
192798
192968
|
stop: stop3,
|
192799
|
-
step: step2
|
192800
|
-
indices(length2) {
|
192801
|
-
return slice_indices(this.start, this.stop, this.step, length2);
|
192802
|
-
}
|
192969
|
+
step: step2
|
192803
192970
|
};
|
192804
192971
|
}
|
192805
192972
|
function create_queue() {
|
@@ -192867,7 +193034,7 @@ class SliceDimIndexer {
|
|
192867
193034
|
__publicField(this, "dim_chunk_len");
|
192868
193035
|
__publicField(this, "nitems");
|
192869
193036
|
__publicField(this, "nchunks");
|
192870
|
-
const [start, stop3, step2] = dim_sel
|
193037
|
+
const [start, stop3, step2] = slice_indices(dim_sel, dim_len);
|
192871
193038
|
this.start = start;
|
192872
193039
|
this.stop = stop3;
|
192873
193040
|
this.step = step2;
|
@@ -192953,25 +193120,20 @@ function unwrap(arr, idx) {
|
|
192953
193120
|
}
|
192954
193121
|
async function get$7(arr, selection, opts2, setter2) {
|
192955
193122
|
var _a3;
|
192956
|
-
|
192957
|
-
|
193123
|
+
let context2 = get_context(arr);
|
193124
|
+
let indexer = new BasicIndexer({
|
192958
193125
|
selection,
|
192959
193126
|
shape: arr.shape,
|
192960
193127
|
chunk_shape: arr.chunks
|
192961
193128
|
});
|
192962
|
-
|
192963
|
-
|
193129
|
+
let out = setter2.prepare(new context2.TypedArray(indexer.shape.reduce((a2, b2) => a2 * b2, 1)), indexer.shape, context2.get_strides(indexer.shape, opts2.order));
|
193130
|
+
let queue = ((_a3 = opts2.create_queue) == null ? void 0 : _a3.call(opts2)) ?? create_queue();
|
192964
193131
|
for (const { chunk_coords, mapping } of indexer) {
|
192965
|
-
queue.add(
|
192966
|
-
|
193132
|
+
queue.add(async () => {
|
193133
|
+
let { data: data2, shape: shape2, stride } = await arr.getChunk(chunk_coords, opts2.opts);
|
193134
|
+
let chunk = setter2.prepare(data2, shape2, stride);
|
192967
193135
|
setter2.set_from_chunk(out, chunk, mapping);
|
192968
|
-
})
|
192969
|
-
if (!(err2 instanceof KeyError))
|
192970
|
-
throw err2;
|
192971
|
-
if (context2.fill_value) {
|
192972
|
-
setter2.set_scalar(out, mapping.map((m2) => m2.to).filter((s2) => s2 !== null), context2.fill_value);
|
192973
|
-
}
|
192974
|
-
}));
|
193136
|
+
});
|
192975
193137
|
}
|
192976
193138
|
await queue.onIdle();
|
192977
193139
|
return indexer.shape.length === 0 ? unwrap(out.data, 0) : out;
|
@@ -193124,6 +193286,9 @@ function set_from_chunk_binary(dest, src2, bytes_per_element2, projections2) {
|
|
193124
193286
|
}, bytes_per_element2, projs);
|
193125
193287
|
}
|
193126
193288
|
}
|
193289
|
+
function strip_prefix(path2) {
|
193290
|
+
return path2.slice(1);
|
193291
|
+
}
|
193127
193292
|
function fetch_range(url, offset6, length2, opts2 = {}) {
|
193128
193293
|
if (offset6 !== void 0 && length2 !== void 0) {
|
193129
193294
|
opts2 = {
|
@@ -193136,6 +193301,16 @@ function fetch_range(url, offset6, length2, opts2 = {}) {
|
|
193136
193301
|
}
|
193137
193302
|
return fetch(url, opts2);
|
193138
193303
|
}
|
193304
|
+
function merge_init(storeOverrides, requestOverrides) {
|
193305
|
+
return {
|
193306
|
+
...storeOverrides,
|
193307
|
+
...requestOverrides,
|
193308
|
+
headers: {
|
193309
|
+
...storeOverrides.headers,
|
193310
|
+
...requestOverrides.headers
|
193311
|
+
}
|
193312
|
+
};
|
193313
|
+
}
|
193139
193314
|
function resolve$1(root2, path2) {
|
193140
193315
|
const base2 = typeof root2 === "string" ? new URL(root2) : root2;
|
193141
193316
|
if (!base2.pathname.endsWith("/")) {
|
@@ -193200,14 +193375,7 @@ _overrides = new WeakMap();
|
|
193200
193375
|
_use_suffix_request = new WeakMap();
|
193201
193376
|
_merge_init = new WeakSet();
|
193202
193377
|
merge_init_fn = function(overrides) {
|
193203
|
-
return
|
193204
|
-
...__privateGet(this, _overrides),
|
193205
|
-
...overrides,
|
193206
|
-
headers: {
|
193207
|
-
...__privateGet(this, _overrides).headers,
|
193208
|
-
...overrides.headers
|
193209
|
-
}
|
193210
|
-
};
|
193378
|
+
return merge_init(__privateGet(this, _overrides), overrides);
|
193211
193379
|
};
|
193212
193380
|
const FetchStore$1 = FetchStore;
|
193213
193381
|
function getV2DataType(dtype) {
|
@@ -193249,8 +193417,896 @@ function createZarrArrayAdapter(arr) {
|
|
193249
193417
|
}
|
193250
193418
|
});
|
193251
193419
|
}
|
193252
|
-
function
|
193253
|
-
|
193420
|
+
function readBlobAsArrayBuffer(blob) {
|
193421
|
+
if (blob.arrayBuffer) {
|
193422
|
+
return blob.arrayBuffer();
|
193423
|
+
}
|
193424
|
+
return new Promise((resolve2, reject) => {
|
193425
|
+
const reader = new FileReader();
|
193426
|
+
reader.addEventListener("loadend", () => {
|
193427
|
+
resolve2(reader.result);
|
193428
|
+
});
|
193429
|
+
reader.addEventListener("error", reject);
|
193430
|
+
reader.readAsArrayBuffer(blob);
|
193431
|
+
});
|
193432
|
+
}
|
193433
|
+
async function readBlobAsUint8Array(blob) {
|
193434
|
+
const arrayBuffer2 = await readBlobAsArrayBuffer(blob);
|
193435
|
+
return new Uint8Array(arrayBuffer2);
|
193436
|
+
}
|
193437
|
+
function isBlob(v) {
|
193438
|
+
return typeof Blob !== "undefined" && v instanceof Blob;
|
193439
|
+
}
|
193440
|
+
function isSharedArrayBuffer(b2) {
|
193441
|
+
return typeof SharedArrayBuffer !== "undefined" && b2 instanceof SharedArrayBuffer;
|
193442
|
+
}
|
193443
|
+
const isNode = typeof process !== "undefined" && process.versions && typeof process.versions.node !== "undefined" && typeof process.versions.electron === "undefined";
|
193444
|
+
function isTypedArraySameAsArrayBuffer(typedArray) {
|
193445
|
+
return typedArray.byteOffset === 0 && typedArray.byteLength === typedArray.buffer.byteLength;
|
193446
|
+
}
|
193447
|
+
class ArrayBufferReader {
|
193448
|
+
constructor(arrayBufferOrView) {
|
193449
|
+
this.typedArray = arrayBufferOrView instanceof ArrayBuffer || isSharedArrayBuffer(arrayBufferOrView) ? new Uint8Array(arrayBufferOrView) : new Uint8Array(arrayBufferOrView.buffer, arrayBufferOrView.byteOffset, arrayBufferOrView.byteLength);
|
193450
|
+
}
|
193451
|
+
async getLength() {
|
193452
|
+
return this.typedArray.byteLength;
|
193453
|
+
}
|
193454
|
+
async read(offset6, length2) {
|
193455
|
+
return new Uint8Array(this.typedArray.buffer, this.typedArray.byteOffset + offset6, length2);
|
193456
|
+
}
|
193457
|
+
}
|
193458
|
+
let BlobReader$1 = class BlobReader {
|
193459
|
+
constructor(blob) {
|
193460
|
+
this.blob = blob;
|
193461
|
+
}
|
193462
|
+
async getLength() {
|
193463
|
+
return this.blob.size;
|
193464
|
+
}
|
193465
|
+
async read(offset6, length2) {
|
193466
|
+
const blob = this.blob.slice(offset6, offset6 + length2);
|
193467
|
+
const arrayBuffer2 = await readBlobAsArrayBuffer(blob);
|
193468
|
+
return new Uint8Array(arrayBuffer2);
|
193469
|
+
}
|
193470
|
+
async sliceAsBlob(offset6, length2, type2 = "") {
|
193471
|
+
return this.blob.slice(offset6, offset6 + length2, type2);
|
193472
|
+
}
|
193473
|
+
};
|
193474
|
+
function inflate(data2, buf) {
|
193475
|
+
var u8 = Uint8Array;
|
193476
|
+
if (data2[0] == 3 && data2[1] == 0)
|
193477
|
+
return buf ? buf : new u8(0);
|
193478
|
+
var bitsF = _bitsF, bitsE = _bitsE, decodeTiny = _decodeTiny, get17 = _get17;
|
193479
|
+
var noBuf = buf == null;
|
193480
|
+
if (noBuf)
|
193481
|
+
buf = new u8(data2.length >>> 2 << 3);
|
193482
|
+
var BFINAL = 0, BTYPE = 0, HLIT = 0, HDIST = 0, HCLEN = 0, ML = 0, MD = 0;
|
193483
|
+
var off = 0, pos = 0;
|
193484
|
+
var lmap, dmap;
|
193485
|
+
while (BFINAL == 0) {
|
193486
|
+
BFINAL = bitsF(data2, pos, 1);
|
193487
|
+
BTYPE = bitsF(data2, pos + 1, 2);
|
193488
|
+
pos += 3;
|
193489
|
+
if (BTYPE == 0) {
|
193490
|
+
if ((pos & 7) != 0)
|
193491
|
+
pos += 8 - (pos & 7);
|
193492
|
+
var p8 = (pos >>> 3) + 4, len2 = data2[p8 - 4] | data2[p8 - 3] << 8;
|
193493
|
+
if (noBuf)
|
193494
|
+
buf = _check(buf, off + len2);
|
193495
|
+
buf.set(new u8(data2.buffer, data2.byteOffset + p8, len2), off);
|
193496
|
+
pos = p8 + len2 << 3;
|
193497
|
+
off += len2;
|
193498
|
+
continue;
|
193499
|
+
}
|
193500
|
+
if (noBuf)
|
193501
|
+
buf = _check(buf, off + (1 << 17));
|
193502
|
+
if (BTYPE == 1) {
|
193503
|
+
lmap = U.flmap;
|
193504
|
+
dmap = U.fdmap;
|
193505
|
+
ML = (1 << 9) - 1;
|
193506
|
+
MD = (1 << 5) - 1;
|
193507
|
+
}
|
193508
|
+
if (BTYPE == 2) {
|
193509
|
+
HLIT = bitsE(data2, pos, 5) + 257;
|
193510
|
+
HDIST = bitsE(data2, pos + 5, 5) + 1;
|
193511
|
+
HCLEN = bitsE(data2, pos + 10, 4) + 4;
|
193512
|
+
pos += 14;
|
193513
|
+
for (var i2 = 0; i2 < 38; i2 += 2) {
|
193514
|
+
U.itree[i2] = 0;
|
193515
|
+
U.itree[i2 + 1] = 0;
|
193516
|
+
}
|
193517
|
+
var tl2 = 1;
|
193518
|
+
for (var i2 = 0; i2 < HCLEN; i2++) {
|
193519
|
+
var l2 = bitsE(data2, pos + i2 * 3, 3);
|
193520
|
+
U.itree[(U.ordr[i2] << 1) + 1] = l2;
|
193521
|
+
if (l2 > tl2)
|
193522
|
+
tl2 = l2;
|
193523
|
+
}
|
193524
|
+
pos += 3 * HCLEN;
|
193525
|
+
makeCodes(U.itree, tl2);
|
193526
|
+
codes2map(U.itree, tl2, U.imap);
|
193527
|
+
lmap = U.lmap;
|
193528
|
+
dmap = U.dmap;
|
193529
|
+
pos = decodeTiny(U.imap, (1 << tl2) - 1, HLIT + HDIST, data2, pos, U.ttree);
|
193530
|
+
var mx0 = _copyOut(U.ttree, 0, HLIT, U.ltree);
|
193531
|
+
ML = (1 << mx0) - 1;
|
193532
|
+
var mx1 = _copyOut(U.ttree, HLIT, HDIST, U.dtree);
|
193533
|
+
MD = (1 << mx1) - 1;
|
193534
|
+
makeCodes(U.ltree, mx0);
|
193535
|
+
codes2map(U.ltree, mx0, lmap);
|
193536
|
+
makeCodes(U.dtree, mx1);
|
193537
|
+
codes2map(U.dtree, mx1, dmap);
|
193538
|
+
}
|
193539
|
+
while (true) {
|
193540
|
+
var code = lmap[get17(data2, pos) & ML];
|
193541
|
+
pos += code & 15;
|
193542
|
+
var lit = code >>> 4;
|
193543
|
+
if (lit >>> 8 == 0) {
|
193544
|
+
buf[off++] = lit;
|
193545
|
+
} else if (lit == 256) {
|
193546
|
+
break;
|
193547
|
+
} else {
|
193548
|
+
var end = off + lit - 254;
|
193549
|
+
if (lit > 264) {
|
193550
|
+
var ebs = U.ldef[lit - 257];
|
193551
|
+
end = off + (ebs >>> 3) + bitsE(data2, pos, ebs & 7);
|
193552
|
+
pos += ebs & 7;
|
193553
|
+
}
|
193554
|
+
var dcode = dmap[get17(data2, pos) & MD];
|
193555
|
+
pos += dcode & 15;
|
193556
|
+
var dlit = dcode >>> 4;
|
193557
|
+
var dbs = U.ddef[dlit], dst = (dbs >>> 4) + bitsF(data2, pos, dbs & 15);
|
193558
|
+
pos += dbs & 15;
|
193559
|
+
if (noBuf)
|
193560
|
+
buf = _check(buf, off + (1 << 17));
|
193561
|
+
while (off < end) {
|
193562
|
+
buf[off] = buf[off++ - dst];
|
193563
|
+
buf[off] = buf[off++ - dst];
|
193564
|
+
buf[off] = buf[off++ - dst];
|
193565
|
+
buf[off] = buf[off++ - dst];
|
193566
|
+
}
|
193567
|
+
off = end;
|
193568
|
+
}
|
193569
|
+
}
|
193570
|
+
}
|
193571
|
+
return buf.length == off ? buf : buf.slice(0, off);
|
193572
|
+
}
|
193573
|
+
function _check(buf, len2) {
|
193574
|
+
var bl2 = buf.length;
|
193575
|
+
if (len2 <= bl2)
|
193576
|
+
return buf;
|
193577
|
+
var nbuf = new Uint8Array(Math.max(bl2 << 1, len2));
|
193578
|
+
nbuf.set(buf, 0);
|
193579
|
+
return nbuf;
|
193580
|
+
}
|
193581
|
+
function _decodeTiny(lmap, LL, len2, data2, pos, tree2) {
|
193582
|
+
var bitsE = _bitsE, get17 = _get17;
|
193583
|
+
var i2 = 0;
|
193584
|
+
while (i2 < len2) {
|
193585
|
+
var code = lmap[get17(data2, pos) & LL];
|
193586
|
+
pos += code & 15;
|
193587
|
+
var lit = code >>> 4;
|
193588
|
+
if (lit <= 15) {
|
193589
|
+
tree2[i2] = lit;
|
193590
|
+
i2++;
|
193591
|
+
} else {
|
193592
|
+
var ll = 0, n3 = 0;
|
193593
|
+
if (lit == 16) {
|
193594
|
+
n3 = 3 + bitsE(data2, pos, 2);
|
193595
|
+
pos += 2;
|
193596
|
+
ll = tree2[i2 - 1];
|
193597
|
+
} else if (lit == 17) {
|
193598
|
+
n3 = 3 + bitsE(data2, pos, 3);
|
193599
|
+
pos += 3;
|
193600
|
+
} else if (lit == 18) {
|
193601
|
+
n3 = 11 + bitsE(data2, pos, 7);
|
193602
|
+
pos += 7;
|
193603
|
+
}
|
193604
|
+
var ni = i2 + n3;
|
193605
|
+
while (i2 < ni) {
|
193606
|
+
tree2[i2] = ll;
|
193607
|
+
i2++;
|
193608
|
+
}
|
193609
|
+
}
|
193610
|
+
}
|
193611
|
+
return pos;
|
193612
|
+
}
|
193613
|
+
function _copyOut(src2, off, len2, tree2) {
|
193614
|
+
var mx = 0, i2 = 0, tl2 = tree2.length >>> 1;
|
193615
|
+
while (i2 < len2) {
|
193616
|
+
var v = src2[i2 + off];
|
193617
|
+
tree2[i2 << 1] = 0;
|
193618
|
+
tree2[(i2 << 1) + 1] = v;
|
193619
|
+
if (v > mx)
|
193620
|
+
mx = v;
|
193621
|
+
i2++;
|
193622
|
+
}
|
193623
|
+
while (i2 < tl2) {
|
193624
|
+
tree2[i2 << 1] = 0;
|
193625
|
+
tree2[(i2 << 1) + 1] = 0;
|
193626
|
+
i2++;
|
193627
|
+
}
|
193628
|
+
return mx;
|
193629
|
+
}
|
193630
|
+
function makeCodes(tree2, MAX_BITS2) {
|
193631
|
+
var max_code = tree2.length;
|
193632
|
+
var code, bits, n3, i2, len2;
|
193633
|
+
var bl_count = U.bl_count;
|
193634
|
+
for (var i2 = 0; i2 <= MAX_BITS2; i2++)
|
193635
|
+
bl_count[i2] = 0;
|
193636
|
+
for (i2 = 1; i2 < max_code; i2 += 2)
|
193637
|
+
bl_count[tree2[i2]]++;
|
193638
|
+
var next_code = U.next_code;
|
193639
|
+
code = 0;
|
193640
|
+
bl_count[0] = 0;
|
193641
|
+
for (bits = 1; bits <= MAX_BITS2; bits++) {
|
193642
|
+
code = code + bl_count[bits - 1] << 1;
|
193643
|
+
next_code[bits] = code;
|
193644
|
+
}
|
193645
|
+
for (n3 = 0; n3 < max_code; n3 += 2) {
|
193646
|
+
len2 = tree2[n3 + 1];
|
193647
|
+
if (len2 != 0) {
|
193648
|
+
tree2[n3] = next_code[len2];
|
193649
|
+
next_code[len2]++;
|
193650
|
+
}
|
193651
|
+
}
|
193652
|
+
}
|
193653
|
+
function codes2map(tree2, MAX_BITS2, map2) {
|
193654
|
+
var max_code = tree2.length;
|
193655
|
+
var r15 = U.rev15;
|
193656
|
+
for (var i2 = 0; i2 < max_code; i2 += 2)
|
193657
|
+
if (tree2[i2 + 1] != 0) {
|
193658
|
+
var lit = i2 >> 1;
|
193659
|
+
var cl = tree2[i2 + 1], val = lit << 4 | cl;
|
193660
|
+
var rest = MAX_BITS2 - cl, i0 = tree2[i2] << rest, i1 = i0 + (1 << rest);
|
193661
|
+
while (i0 != i1) {
|
193662
|
+
var p02 = r15[i0] >>> 15 - MAX_BITS2;
|
193663
|
+
map2[p02] = val;
|
193664
|
+
i0++;
|
193665
|
+
}
|
193666
|
+
}
|
193667
|
+
}
|
193668
|
+
function revCodes(tree2, MAX_BITS2) {
|
193669
|
+
var r15 = U.rev15, imb = 15 - MAX_BITS2;
|
193670
|
+
for (var i2 = 0; i2 < tree2.length; i2 += 2) {
|
193671
|
+
var i0 = tree2[i2] << MAX_BITS2 - tree2[i2 + 1];
|
193672
|
+
tree2[i2] = r15[i0] >>> imb;
|
193673
|
+
}
|
193674
|
+
}
|
193675
|
+
function _bitsE(dt, pos, length2) {
|
193676
|
+
return (dt[pos >>> 3] | dt[(pos >>> 3) + 1] << 8) >>> (pos & 7) & (1 << length2) - 1;
|
193677
|
+
}
|
193678
|
+
function _bitsF(dt, pos, length2) {
|
193679
|
+
return (dt[pos >>> 3] | dt[(pos >>> 3) + 1] << 8 | dt[(pos >>> 3) + 2] << 16) >>> (pos & 7) & (1 << length2) - 1;
|
193680
|
+
}
|
193681
|
+
function _get17(dt, pos) {
|
193682
|
+
return (dt[pos >>> 3] | dt[(pos >>> 3) + 1] << 8 | dt[(pos >>> 3) + 2] << 16) >>> (pos & 7);
|
193683
|
+
}
|
193684
|
+
const U = function() {
|
193685
|
+
var u16 = Uint16Array, u32 = Uint32Array;
|
193686
|
+
return {
|
193687
|
+
next_code: new u16(16),
|
193688
|
+
bl_count: new u16(16),
|
193689
|
+
ordr: [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15],
|
193690
|
+
of0: [3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 999, 999, 999],
|
193691
|
+
exb: [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0, 0, 0, 0],
|
193692
|
+
ldef: new u16(32),
|
193693
|
+
df0: [1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577, 65535, 65535],
|
193694
|
+
dxb: [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 0, 0],
|
193695
|
+
ddef: new u32(32),
|
193696
|
+
flmap: new u16(512),
|
193697
|
+
fltree: [],
|
193698
|
+
fdmap: new u16(32),
|
193699
|
+
fdtree: [],
|
193700
|
+
lmap: new u16(32768),
|
193701
|
+
ltree: [],
|
193702
|
+
ttree: [],
|
193703
|
+
dmap: new u16(32768),
|
193704
|
+
dtree: [],
|
193705
|
+
imap: new u16(512),
|
193706
|
+
itree: [],
|
193707
|
+
//rev9 : new u16( 512)
|
193708
|
+
rev15: new u16(1 << 15),
|
193709
|
+
lhst: new u32(286),
|
193710
|
+
dhst: new u32(30),
|
193711
|
+
ihst: new u32(19),
|
193712
|
+
lits: new u32(15e3),
|
193713
|
+
strt: new u16(1 << 16),
|
193714
|
+
prev: new u16(1 << 15)
|
193715
|
+
};
|
193716
|
+
}();
|
193717
|
+
(function() {
|
193718
|
+
var len2 = 1 << 15;
|
193719
|
+
for (var i2 = 0; i2 < len2; i2++) {
|
193720
|
+
var x2 = i2;
|
193721
|
+
x2 = (x2 & 2863311530) >>> 1 | (x2 & 1431655765) << 1;
|
193722
|
+
x2 = (x2 & 3435973836) >>> 2 | (x2 & 858993459) << 2;
|
193723
|
+
x2 = (x2 & 4042322160) >>> 4 | (x2 & 252645135) << 4;
|
193724
|
+
x2 = (x2 & 4278255360) >>> 8 | (x2 & 16711935) << 8;
|
193725
|
+
U.rev15[i2] = (x2 >>> 16 | x2 << 16) >>> 17;
|
193726
|
+
}
|
193727
|
+
function pushV(tgt, n3, sv) {
|
193728
|
+
while (n3-- != 0)
|
193729
|
+
tgt.push(0, sv);
|
193730
|
+
}
|
193731
|
+
for (var i2 = 0; i2 < 32; i2++) {
|
193732
|
+
U.ldef[i2] = U.of0[i2] << 3 | U.exb[i2];
|
193733
|
+
U.ddef[i2] = U.df0[i2] << 4 | U.dxb[i2];
|
193734
|
+
}
|
193735
|
+
pushV(U.fltree, 144, 8);
|
193736
|
+
pushV(U.fltree, 255 - 143, 9);
|
193737
|
+
pushV(U.fltree, 279 - 255, 7);
|
193738
|
+
pushV(U.fltree, 287 - 279, 8);
|
193739
|
+
makeCodes(U.fltree, 9);
|
193740
|
+
codes2map(U.fltree, 9, U.flmap);
|
193741
|
+
revCodes(U.fltree, 9);
|
193742
|
+
pushV(U.fdtree, 32, 5);
|
193743
|
+
makeCodes(U.fdtree, 5);
|
193744
|
+
codes2map(U.fdtree, 5, U.fdmap);
|
193745
|
+
revCodes(U.fdtree, 5);
|
193746
|
+
pushV(U.itree, 19, 0);
|
193747
|
+
pushV(U.ltree, 286, 0);
|
193748
|
+
pushV(U.dtree, 30, 0);
|
193749
|
+
pushV(U.ttree, 320, 0);
|
193750
|
+
})();
|
193751
|
+
const crc = {
|
193752
|
+
table: function() {
|
193753
|
+
var tab = new Uint32Array(256);
|
193754
|
+
for (var n3 = 0; n3 < 256; n3++) {
|
193755
|
+
var c2 = n3;
|
193756
|
+
for (var k = 0; k < 8; k++) {
|
193757
|
+
if (c2 & 1)
|
193758
|
+
c2 = 3988292384 ^ c2 >>> 1;
|
193759
|
+
else
|
193760
|
+
c2 = c2 >>> 1;
|
193761
|
+
}
|
193762
|
+
tab[n3] = c2;
|
193763
|
+
}
|
193764
|
+
return tab;
|
193765
|
+
}(),
|
193766
|
+
update: function(c2, buf, off, len2) {
|
193767
|
+
for (var i2 = 0; i2 < len2; i2++)
|
193768
|
+
c2 = crc.table[(c2 ^ buf[off + i2]) & 255] ^ c2 >>> 8;
|
193769
|
+
return c2;
|
193770
|
+
},
|
193771
|
+
crc: function(b2, o2, l2) {
|
193772
|
+
return crc.update(4294967295, b2, o2, l2) ^ 4294967295;
|
193773
|
+
}
|
193774
|
+
};
|
193775
|
+
function inflateRaw(file, buf) {
|
193776
|
+
return inflate(file, buf);
|
193777
|
+
}
|
193778
|
+
const config2 = {
|
193779
|
+
numWorkers: 1,
|
193780
|
+
workerURL: "",
|
193781
|
+
useWorkers: false
|
193782
|
+
};
|
193783
|
+
let nextId = 0;
|
193784
|
+
const waitingForWorkerQueue = [];
|
193785
|
+
function startWorker(url) {
|
193786
|
+
return new Promise((resolve2, reject) => {
|
193787
|
+
const worker = new Worker(url);
|
193788
|
+
worker.onmessage = (e3) => {
|
193789
|
+
if (e3.data === "start") {
|
193790
|
+
worker.onerror = void 0;
|
193791
|
+
worker.onmessage = void 0;
|
193792
|
+
resolve2(worker);
|
193793
|
+
} else {
|
193794
|
+
reject(new Error(`unexpected message: ${e3.data}`));
|
193795
|
+
}
|
193796
|
+
};
|
193797
|
+
worker.onerror = reject;
|
193798
|
+
});
|
193799
|
+
}
|
193800
|
+
function dynamicRequire(mod2, request2) {
|
193801
|
+
return mod2.require ? mod2.require(request2) : {};
|
193802
|
+
}
|
193803
|
+
(function() {
|
193804
|
+
if (isNode) {
|
193805
|
+
const { Worker: Worker3 } = dynamicRequire(module, "worker_threads");
|
193806
|
+
return {
|
193807
|
+
async createWorker(url) {
|
193808
|
+
return new Worker3(url);
|
193809
|
+
},
|
193810
|
+
addEventListener(worker, fn) {
|
193811
|
+
worker.on("message", (data2) => {
|
193812
|
+
fn({ target: worker, data: data2 });
|
193813
|
+
});
|
193814
|
+
},
|
193815
|
+
async terminate(worker) {
|
193816
|
+
await worker.terminate();
|
193817
|
+
}
|
193818
|
+
};
|
193819
|
+
} else {
|
193820
|
+
return {
|
193821
|
+
async createWorker(url) {
|
193822
|
+
try {
|
193823
|
+
const worker = await startWorker(url);
|
193824
|
+
return worker;
|
193825
|
+
} catch (e3) {
|
193826
|
+
console.warn("could not load worker:", url);
|
193827
|
+
}
|
193828
|
+
let text2;
|
193829
|
+
try {
|
193830
|
+
const req = await fetch(url, { mode: "cors" });
|
193831
|
+
if (!req.ok) {
|
193832
|
+
throw new Error(`could not load: ${url}`);
|
193833
|
+
}
|
193834
|
+
text2 = await req.text();
|
193835
|
+
url = URL.createObjectURL(new Blob([text2], { type: "application/javascript" }));
|
193836
|
+
const worker = await startWorker(url);
|
193837
|
+
config2.workerURL = url;
|
193838
|
+
return worker;
|
193839
|
+
} catch (e3) {
|
193840
|
+
console.warn("could not load worker via fetch:", url);
|
193841
|
+
}
|
193842
|
+
if (text2 !== void 0) {
|
193843
|
+
try {
|
193844
|
+
url = `data:application/javascript;base64,${btoa(text2)}`;
|
193845
|
+
const worker = await startWorker(url);
|
193846
|
+
config2.workerURL = url;
|
193847
|
+
return worker;
|
193848
|
+
} catch (e3) {
|
193849
|
+
console.warn("could not load worker via dataURI");
|
193850
|
+
}
|
193851
|
+
}
|
193852
|
+
console.warn("workers will not be used");
|
193853
|
+
throw new Error("can not start workers");
|
193854
|
+
},
|
193855
|
+
addEventListener(worker, fn) {
|
193856
|
+
worker.addEventListener("message", fn);
|
193857
|
+
},
|
193858
|
+
async terminate(worker) {
|
193859
|
+
worker.terminate();
|
193860
|
+
}
|
193861
|
+
};
|
193862
|
+
}
|
193863
|
+
})();
|
193864
|
+
function inflateRawLocal(src2, uncompressedSize, type2, resolve2) {
|
193865
|
+
const dst = new Uint8Array(uncompressedSize);
|
193866
|
+
inflateRaw(src2, dst);
|
193867
|
+
resolve2(type2 ? new Blob([dst], { type: type2 }) : dst.buffer);
|
193868
|
+
}
|
193869
|
+
async function processWaitingForWorkerQueue() {
|
193870
|
+
if (waitingForWorkerQueue.length === 0) {
|
193871
|
+
return;
|
193872
|
+
}
|
193873
|
+
while (waitingForWorkerQueue.length) {
|
193874
|
+
const { src: src2, uncompressedSize, type: type2, resolve: resolve2 } = waitingForWorkerQueue.shift();
|
193875
|
+
let data2 = src2;
|
193876
|
+
if (isBlob(src2)) {
|
193877
|
+
data2 = await readBlobAsUint8Array(src2);
|
193878
|
+
}
|
193879
|
+
inflateRawLocal(data2, uncompressedSize, type2, resolve2);
|
193880
|
+
}
|
193881
|
+
}
|
193882
|
+
function inflateRawAsync(src2, uncompressedSize, type2) {
|
193883
|
+
return new Promise((resolve2, reject) => {
|
193884
|
+
waitingForWorkerQueue.push({ src: src2, uncompressedSize, type: type2, resolve: resolve2, reject, id: nextId++ });
|
193885
|
+
processWaitingForWorkerQueue();
|
193886
|
+
});
|
193887
|
+
}
|
193888
|
+
function dosDateTimeToDate(date2, time2) {
|
193889
|
+
const day2 = date2 & 31;
|
193890
|
+
const month2 = (date2 >> 5 & 15) - 1;
|
193891
|
+
const year2 = (date2 >> 9 & 127) + 1980;
|
193892
|
+
const millisecond2 = 0;
|
193893
|
+
const second2 = (time2 & 31) * 2;
|
193894
|
+
const minute2 = time2 >> 5 & 63;
|
193895
|
+
const hour2 = time2 >> 11 & 31;
|
193896
|
+
return new Date(year2, month2, day2, hour2, minute2, second2, millisecond2);
|
193897
|
+
}
|
193898
|
+
class ZipEntry {
|
193899
|
+
constructor(reader, rawEntry) {
|
193900
|
+
this._reader = reader;
|
193901
|
+
this._rawEntry = rawEntry;
|
193902
|
+
this.name = rawEntry.name;
|
193903
|
+
this.nameBytes = rawEntry.nameBytes;
|
193904
|
+
this.size = rawEntry.uncompressedSize;
|
193905
|
+
this.compressedSize = rawEntry.compressedSize;
|
193906
|
+
this.comment = rawEntry.comment;
|
193907
|
+
this.commentBytes = rawEntry.commentBytes;
|
193908
|
+
this.compressionMethod = rawEntry.compressionMethod;
|
193909
|
+
this.lastModDate = dosDateTimeToDate(rawEntry.lastModFileDate, rawEntry.lastModFileTime);
|
193910
|
+
this.isDirectory = rawEntry.uncompressedSize === 0 && rawEntry.name.endsWith("/");
|
193911
|
+
this.encrypted = !!(rawEntry.generalPurposeBitFlag & 1);
|
193912
|
+
this.externalFileAttributes = rawEntry.externalFileAttributes;
|
193913
|
+
this.versionMadeBy = rawEntry.versionMadeBy;
|
193914
|
+
}
|
193915
|
+
// returns a promise that returns a Blob for this entry
|
193916
|
+
async blob(type2 = "application/octet-stream") {
|
193917
|
+
return await readEntryDataAsBlob(this._reader, this._rawEntry, type2);
|
193918
|
+
}
|
193919
|
+
// returns a promise that returns an ArrayBuffer for this entry
|
193920
|
+
async arrayBuffer() {
|
193921
|
+
return await readEntryDataAsArrayBuffer(this._reader, this._rawEntry);
|
193922
|
+
}
|
193923
|
+
// returns text, assumes the text is valid utf8. If you want more options decode arrayBuffer yourself
|
193924
|
+
async text() {
|
193925
|
+
const buffer2 = await this.arrayBuffer();
|
193926
|
+
return decodeBuffer(new Uint8Array(buffer2));
|
193927
|
+
}
|
193928
|
+
// returns text with JSON.parse called on it. If you want more options decode arrayBuffer yourself
|
193929
|
+
async json() {
|
193930
|
+
const text2 = await this.text();
|
193931
|
+
return JSON.parse(text2);
|
193932
|
+
}
|
193933
|
+
}
|
193934
|
+
const EOCDR_WITHOUT_COMMENT_SIZE = 22;
|
193935
|
+
const MAX_COMMENT_SIZE = 65535;
|
193936
|
+
const EOCDR_SIGNATURE = 101010256;
|
193937
|
+
const ZIP64_EOCDR_SIGNATURE = 101075792;
|
193938
|
+
async function readAs(reader, offset6, length2) {
|
193939
|
+
return await reader.read(offset6, length2);
|
193940
|
+
}
|
193941
|
+
async function readAsBlobOrTypedArray(reader, offset6, length2, type2) {
|
193942
|
+
if (reader.sliceAsBlob) {
|
193943
|
+
return await reader.sliceAsBlob(offset6, length2, type2);
|
193944
|
+
}
|
193945
|
+
return await reader.read(offset6, length2);
|
193946
|
+
}
|
193947
|
+
const crc$1 = {
|
193948
|
+
unsigned() {
|
193949
|
+
return 0;
|
193950
|
+
}
|
193951
|
+
};
|
193952
|
+
function getUint16LE(uint8View, offset6) {
|
193953
|
+
return uint8View[offset6] + uint8View[offset6 + 1] * 256;
|
193954
|
+
}
|
193955
|
+
function getUint32LE(uint8View, offset6) {
|
193956
|
+
return uint8View[offset6] + uint8View[offset6 + 1] * 256 + uint8View[offset6 + 2] * 65536 + uint8View[offset6 + 3] * 16777216;
|
193957
|
+
}
|
193958
|
+
function getUint64LE(uint8View, offset6) {
|
193959
|
+
return getUint32LE(uint8View, offset6) + getUint32LE(uint8View, offset6 + 4) * 4294967296;
|
193960
|
+
}
|
193961
|
+
const utf8Decoder = new TextDecoder();
|
193962
|
+
function decodeBuffer(uint8View, isUTF8) {
|
193963
|
+
if (isSharedArrayBuffer(uint8View.buffer)) {
|
193964
|
+
uint8View = new Uint8Array(uint8View);
|
193965
|
+
}
|
193966
|
+
return utf8Decoder.decode(uint8View);
|
193967
|
+
}
|
193968
|
+
async function findEndOfCentralDirector(reader, totalLength) {
|
193969
|
+
const size2 = Math.min(EOCDR_WITHOUT_COMMENT_SIZE + MAX_COMMENT_SIZE, totalLength);
|
193970
|
+
const readStart = totalLength - size2;
|
193971
|
+
const data2 = await readAs(reader, readStart, size2);
|
193972
|
+
for (let i2 = size2 - EOCDR_WITHOUT_COMMENT_SIZE; i2 >= 0; --i2) {
|
193973
|
+
if (getUint32LE(data2, i2) !== EOCDR_SIGNATURE) {
|
193974
|
+
continue;
|
193975
|
+
}
|
193976
|
+
const eocdr = new Uint8Array(data2.buffer, data2.byteOffset + i2, data2.byteLength - i2);
|
193977
|
+
const diskNumber = getUint16LE(eocdr, 4);
|
193978
|
+
if (diskNumber !== 0) {
|
193979
|
+
throw new Error(`multi-volume zip files are not supported. This is volume: ${diskNumber}`);
|
193980
|
+
}
|
193981
|
+
const entryCount = getUint16LE(eocdr, 10);
|
193982
|
+
const centralDirectorySize = getUint32LE(eocdr, 12);
|
193983
|
+
const centralDirectoryOffset = getUint32LE(eocdr, 16);
|
193984
|
+
const commentLength = getUint16LE(eocdr, 20);
|
193985
|
+
const expectedCommentLength = eocdr.length - EOCDR_WITHOUT_COMMENT_SIZE;
|
193986
|
+
if (commentLength !== expectedCommentLength) {
|
193987
|
+
throw new Error(`invalid comment length. expected: ${expectedCommentLength}, actual: ${commentLength}`);
|
193988
|
+
}
|
193989
|
+
const commentBytes = new Uint8Array(eocdr.buffer, eocdr.byteOffset + 22, commentLength);
|
193990
|
+
const comment = decodeBuffer(commentBytes);
|
193991
|
+
if (entryCount === 65535 || centralDirectoryOffset === 4294967295) {
|
193992
|
+
return await readZip64CentralDirectory(reader, readStart + i2, comment, commentBytes);
|
193993
|
+
} else {
|
193994
|
+
return await readEntries(reader, centralDirectoryOffset, centralDirectorySize, entryCount, comment, commentBytes);
|
193995
|
+
}
|
193996
|
+
}
|
193997
|
+
throw new Error("could not find end of central directory. maybe not zip file");
|
193998
|
+
}
|
193999
|
+
const END_OF_CENTRAL_DIRECTORY_LOCATOR_SIGNATURE = 117853008;
|
194000
|
+
async function readZip64CentralDirectory(reader, offset6, comment, commentBytes) {
|
194001
|
+
const zip64EocdlOffset = offset6 - 20;
|
194002
|
+
const eocdl = await readAs(reader, zip64EocdlOffset, 20);
|
194003
|
+
if (getUint32LE(eocdl, 0) !== END_OF_CENTRAL_DIRECTORY_LOCATOR_SIGNATURE) {
|
194004
|
+
throw new Error("invalid zip64 end of central directory locator signature");
|
194005
|
+
}
|
194006
|
+
const zip64EocdrOffset = getUint64LE(eocdl, 8);
|
194007
|
+
const zip64Eocdr = await readAs(reader, zip64EocdrOffset, 56);
|
194008
|
+
if (getUint32LE(zip64Eocdr, 0) !== ZIP64_EOCDR_SIGNATURE) {
|
194009
|
+
throw new Error("invalid zip64 end of central directory record signature");
|
194010
|
+
}
|
194011
|
+
const entryCount = getUint64LE(zip64Eocdr, 32);
|
194012
|
+
const centralDirectorySize = getUint64LE(zip64Eocdr, 40);
|
194013
|
+
const centralDirectoryOffset = getUint64LE(zip64Eocdr, 48);
|
194014
|
+
return readEntries(reader, centralDirectoryOffset, centralDirectorySize, entryCount, comment, commentBytes);
|
194015
|
+
}
|
194016
|
+
const CENTRAL_DIRECTORY_FILE_HEADER_SIGNATURE = 33639248;
|
194017
|
+
async function readEntries(reader, centralDirectoryOffset, centralDirectorySize, rawEntryCount, comment, commentBytes) {
|
194018
|
+
let readEntryCursor = 0;
|
194019
|
+
const allEntriesBuffer = await readAs(reader, centralDirectoryOffset, centralDirectorySize);
|
194020
|
+
const rawEntries = [];
|
194021
|
+
for (let e3 = 0; e3 < rawEntryCount; ++e3) {
|
194022
|
+
const buffer2 = allEntriesBuffer.subarray(readEntryCursor, readEntryCursor + 46);
|
194023
|
+
const signature = getUint32LE(buffer2, 0);
|
194024
|
+
if (signature !== CENTRAL_DIRECTORY_FILE_HEADER_SIGNATURE) {
|
194025
|
+
throw new Error(`invalid central directory file header signature: 0x${signature.toString(16)}`);
|
194026
|
+
}
|
194027
|
+
const rawEntry = {
|
194028
|
+
// 4 - Version made by
|
194029
|
+
versionMadeBy: getUint16LE(buffer2, 4),
|
194030
|
+
// 6 - Version needed to extract (minimum)
|
194031
|
+
versionNeededToExtract: getUint16LE(buffer2, 6),
|
194032
|
+
// 8 - General purpose bit flag
|
194033
|
+
generalPurposeBitFlag: getUint16LE(buffer2, 8),
|
194034
|
+
// 10 - Compression method
|
194035
|
+
compressionMethod: getUint16LE(buffer2, 10),
|
194036
|
+
// 12 - File last modification time
|
194037
|
+
lastModFileTime: getUint16LE(buffer2, 12),
|
194038
|
+
// 14 - File last modification date
|
194039
|
+
lastModFileDate: getUint16LE(buffer2, 14),
|
194040
|
+
// 16 - CRC-32
|
194041
|
+
crc32: getUint32LE(buffer2, 16),
|
194042
|
+
// 20 - Compressed size
|
194043
|
+
compressedSize: getUint32LE(buffer2, 20),
|
194044
|
+
// 24 - Uncompressed size
|
194045
|
+
uncompressedSize: getUint32LE(buffer2, 24),
|
194046
|
+
// 28 - File name length (n)
|
194047
|
+
fileNameLength: getUint16LE(buffer2, 28),
|
194048
|
+
// 30 - Extra field length (m)
|
194049
|
+
extraFieldLength: getUint16LE(buffer2, 30),
|
194050
|
+
// 32 - File comment length (k)
|
194051
|
+
fileCommentLength: getUint16LE(buffer2, 32),
|
194052
|
+
// 34 - Disk number where file starts
|
194053
|
+
// 36 - Internal file attributes
|
194054
|
+
internalFileAttributes: getUint16LE(buffer2, 36),
|
194055
|
+
// 38 - External file attributes
|
194056
|
+
externalFileAttributes: getUint32LE(buffer2, 38),
|
194057
|
+
// 42 - Relative offset of local file header
|
194058
|
+
relativeOffsetOfLocalHeader: getUint32LE(buffer2, 42)
|
194059
|
+
};
|
194060
|
+
if (rawEntry.generalPurposeBitFlag & 64) {
|
194061
|
+
throw new Error("strong encryption is not supported");
|
194062
|
+
}
|
194063
|
+
readEntryCursor += 46;
|
194064
|
+
const data2 = allEntriesBuffer.subarray(readEntryCursor, readEntryCursor + rawEntry.fileNameLength + rawEntry.extraFieldLength + rawEntry.fileCommentLength);
|
194065
|
+
rawEntry.nameBytes = data2.slice(0, rawEntry.fileNameLength);
|
194066
|
+
rawEntry.name = decodeBuffer(rawEntry.nameBytes);
|
194067
|
+
const fileCommentStart = rawEntry.fileNameLength + rawEntry.extraFieldLength;
|
194068
|
+
const extraFieldBuffer = data2.slice(rawEntry.fileNameLength, fileCommentStart);
|
194069
|
+
rawEntry.extraFields = [];
|
194070
|
+
let i2 = 0;
|
194071
|
+
while (i2 < extraFieldBuffer.length - 3) {
|
194072
|
+
const headerId = getUint16LE(extraFieldBuffer, i2 + 0);
|
194073
|
+
const dataSize = getUint16LE(extraFieldBuffer, i2 + 2);
|
194074
|
+
const dataStart = i2 + 4;
|
194075
|
+
const dataEnd = dataStart + dataSize;
|
194076
|
+
if (dataEnd > extraFieldBuffer.length) {
|
194077
|
+
throw new Error("extra field length exceeds extra field buffer size");
|
194078
|
+
}
|
194079
|
+
rawEntry.extraFields.push({
|
194080
|
+
id: headerId,
|
194081
|
+
data: extraFieldBuffer.slice(dataStart, dataEnd)
|
194082
|
+
});
|
194083
|
+
i2 = dataEnd;
|
194084
|
+
}
|
194085
|
+
rawEntry.commentBytes = data2.slice(fileCommentStart, fileCommentStart + rawEntry.fileCommentLength);
|
194086
|
+
rawEntry.comment = decodeBuffer(rawEntry.commentBytes);
|
194087
|
+
readEntryCursor += data2.length;
|
194088
|
+
if (rawEntry.uncompressedSize === 4294967295 || rawEntry.compressedSize === 4294967295 || rawEntry.relativeOffsetOfLocalHeader === 4294967295) {
|
194089
|
+
const zip64ExtraField = rawEntry.extraFields.find((e4) => e4.id === 1);
|
194090
|
+
if (!zip64ExtraField) {
|
194091
|
+
throw new Error("expected zip64 extended information extra field");
|
194092
|
+
}
|
194093
|
+
const zip64EiefBuffer = zip64ExtraField.data;
|
194094
|
+
let index2 = 0;
|
194095
|
+
if (rawEntry.uncompressedSize === 4294967295) {
|
194096
|
+
if (index2 + 8 > zip64EiefBuffer.length) {
|
194097
|
+
throw new Error("zip64 extended information extra field does not include uncompressed size");
|
194098
|
+
}
|
194099
|
+
rawEntry.uncompressedSize = getUint64LE(zip64EiefBuffer, index2);
|
194100
|
+
index2 += 8;
|
194101
|
+
}
|
194102
|
+
if (rawEntry.compressedSize === 4294967295) {
|
194103
|
+
if (index2 + 8 > zip64EiefBuffer.length) {
|
194104
|
+
throw new Error("zip64 extended information extra field does not include compressed size");
|
194105
|
+
}
|
194106
|
+
rawEntry.compressedSize = getUint64LE(zip64EiefBuffer, index2);
|
194107
|
+
index2 += 8;
|
194108
|
+
}
|
194109
|
+
if (rawEntry.relativeOffsetOfLocalHeader === 4294967295) {
|
194110
|
+
if (index2 + 8 > zip64EiefBuffer.length) {
|
194111
|
+
throw new Error("zip64 extended information extra field does not include relative header offset");
|
194112
|
+
}
|
194113
|
+
rawEntry.relativeOffsetOfLocalHeader = getUint64LE(zip64EiefBuffer, index2);
|
194114
|
+
index2 += 8;
|
194115
|
+
}
|
194116
|
+
}
|
194117
|
+
const nameField = rawEntry.extraFields.find((e4) => e4.id === 28789 && e4.data.length >= 6 && // too short to be meaningful
|
194118
|
+
e4.data[0] === 1 && // Version 1 byte version of this extra field, currently 1
|
194119
|
+
getUint32LE(e4.data, 1), crc$1.unsigned(rawEntry.nameBytes));
|
194120
|
+
if (nameField) {
|
194121
|
+
rawEntry.fileName = decodeBuffer(nameField.data.slice(5));
|
194122
|
+
}
|
194123
|
+
if (rawEntry.compressionMethod === 0) {
|
194124
|
+
let expectedCompressedSize = rawEntry.uncompressedSize;
|
194125
|
+
if ((rawEntry.generalPurposeBitFlag & 1) !== 0) {
|
194126
|
+
expectedCompressedSize += 12;
|
194127
|
+
}
|
194128
|
+
if (rawEntry.compressedSize !== expectedCompressedSize) {
|
194129
|
+
throw new Error(`compressed size mismatch for stored file: ${rawEntry.compressedSize} != ${expectedCompressedSize}`);
|
194130
|
+
}
|
194131
|
+
}
|
194132
|
+
rawEntries.push(rawEntry);
|
194133
|
+
}
|
194134
|
+
const zip2 = {
|
194135
|
+
comment,
|
194136
|
+
commentBytes
|
194137
|
+
};
|
194138
|
+
return {
|
194139
|
+
zip: zip2,
|
194140
|
+
entries: rawEntries.map((e3) => new ZipEntry(reader, e3))
|
194141
|
+
};
|
194142
|
+
}
|
194143
|
+
async function readEntryDataHeader(reader, rawEntry) {
|
194144
|
+
if (rawEntry.generalPurposeBitFlag & 1) {
|
194145
|
+
throw new Error("encrypted entries not supported");
|
194146
|
+
}
|
194147
|
+
const buffer2 = await readAs(reader, rawEntry.relativeOffsetOfLocalHeader, 30);
|
194148
|
+
const totalLength = await reader.getLength();
|
194149
|
+
const signature = getUint32LE(buffer2, 0);
|
194150
|
+
if (signature !== 67324752) {
|
194151
|
+
throw new Error(`invalid local file header signature: 0x${signature.toString(16)}`);
|
194152
|
+
}
|
194153
|
+
const fileNameLength = getUint16LE(buffer2, 26);
|
194154
|
+
const extraFieldLength = getUint16LE(buffer2, 28);
|
194155
|
+
const localFileHeaderEnd = rawEntry.relativeOffsetOfLocalHeader + buffer2.length + fileNameLength + extraFieldLength;
|
194156
|
+
let decompress;
|
194157
|
+
if (rawEntry.compressionMethod === 0) {
|
194158
|
+
decompress = false;
|
194159
|
+
} else if (rawEntry.compressionMethod === 8) {
|
194160
|
+
decompress = true;
|
194161
|
+
} else {
|
194162
|
+
throw new Error(`unsupported compression method: ${rawEntry.compressionMethod}`);
|
194163
|
+
}
|
194164
|
+
const fileDataStart = localFileHeaderEnd;
|
194165
|
+
const fileDataEnd = fileDataStart + rawEntry.compressedSize;
|
194166
|
+
if (rawEntry.compressedSize !== 0) {
|
194167
|
+
if (fileDataEnd > totalLength) {
|
194168
|
+
throw new Error(`file data overflows file bounds: ${fileDataStart} + ${rawEntry.compressedSize} > ${totalLength}`);
|
194169
|
+
}
|
194170
|
+
}
|
194171
|
+
return {
|
194172
|
+
decompress,
|
194173
|
+
fileDataStart
|
194174
|
+
};
|
194175
|
+
}
|
194176
|
+
async function readEntryDataAsArrayBuffer(reader, rawEntry) {
|
194177
|
+
const { decompress, fileDataStart } = await readEntryDataHeader(reader, rawEntry);
|
194178
|
+
if (!decompress) {
|
194179
|
+
const dataView = await readAs(reader, fileDataStart, rawEntry.compressedSize);
|
194180
|
+
return isTypedArraySameAsArrayBuffer(dataView) ? dataView.buffer : dataView.slice().buffer;
|
194181
|
+
}
|
194182
|
+
const typedArrayOrBlob = await readAsBlobOrTypedArray(reader, fileDataStart, rawEntry.compressedSize);
|
194183
|
+
const result = await inflateRawAsync(typedArrayOrBlob, rawEntry.uncompressedSize);
|
194184
|
+
return result;
|
194185
|
+
}
|
194186
|
+
async function readEntryDataAsBlob(reader, rawEntry, type2) {
|
194187
|
+
const { decompress, fileDataStart } = await readEntryDataHeader(reader, rawEntry);
|
194188
|
+
if (!decompress) {
|
194189
|
+
const typedArrayOrBlob2 = await readAsBlobOrTypedArray(reader, fileDataStart, rawEntry.compressedSize, type2);
|
194190
|
+
if (isBlob(typedArrayOrBlob2)) {
|
194191
|
+
return typedArrayOrBlob2;
|
194192
|
+
}
|
194193
|
+
return new Blob([isSharedArrayBuffer(typedArrayOrBlob2.buffer) ? new Uint8Array(typedArrayOrBlob2) : typedArrayOrBlob2], { type: type2 });
|
194194
|
+
}
|
194195
|
+
const typedArrayOrBlob = await readAsBlobOrTypedArray(reader, fileDataStart, rawEntry.compressedSize);
|
194196
|
+
const result = await inflateRawAsync(typedArrayOrBlob, rawEntry.uncompressedSize, type2);
|
194197
|
+
return result;
|
194198
|
+
}
|
194199
|
+
async function unzipRaw(source2) {
|
194200
|
+
let reader;
|
194201
|
+
if (typeof Blob !== "undefined" && source2 instanceof Blob) {
|
194202
|
+
reader = new BlobReader$1(source2);
|
194203
|
+
} else if (source2 instanceof ArrayBuffer || source2 && source2.buffer && source2.buffer instanceof ArrayBuffer) {
|
194204
|
+
reader = new ArrayBufferReader(source2);
|
194205
|
+
} else if (isSharedArrayBuffer(source2) || isSharedArrayBuffer(source2.buffer)) {
|
194206
|
+
reader = new ArrayBufferReader(source2);
|
194207
|
+
} else if (typeof source2 === "string") {
|
194208
|
+
const req = await fetch(source2);
|
194209
|
+
if (!req.ok) {
|
194210
|
+
throw new Error(`failed http request ${source2}, status: ${req.status}: ${req.statusText}`);
|
194211
|
+
}
|
194212
|
+
const blob = await req.blob();
|
194213
|
+
reader = new BlobReader$1(blob);
|
194214
|
+
} else if (typeof source2.getLength === "function" && typeof source2.read === "function") {
|
194215
|
+
reader = source2;
|
194216
|
+
} else {
|
194217
|
+
throw new Error("unsupported source type");
|
194218
|
+
}
|
194219
|
+
const totalLength = await reader.getLength();
|
194220
|
+
if (totalLength > Number.MAX_SAFE_INTEGER) {
|
194221
|
+
throw new Error(`file too large. size: ${totalLength}. Only file sizes up 4503599627370496 bytes are supported`);
|
194222
|
+
}
|
194223
|
+
return await findEndOfCentralDirector(reader, totalLength);
|
194224
|
+
}
|
194225
|
+
async function unzip(source2) {
|
194226
|
+
const { zip: zip2, entries: entries2 } = await unzipRaw(source2);
|
194227
|
+
return {
|
194228
|
+
zip: zip2,
|
194229
|
+
entries: Object.fromEntries(entries2.map((v) => [v.name, v]))
|
194230
|
+
};
|
194231
|
+
}
|
194232
|
+
class BlobReader2 {
|
194233
|
+
constructor(blob) {
|
194234
|
+
__publicField(this, "blob");
|
194235
|
+
this.blob = blob;
|
194236
|
+
}
|
194237
|
+
async getLength() {
|
194238
|
+
return this.blob.size;
|
194239
|
+
}
|
194240
|
+
async read(offset6, length2) {
|
194241
|
+
const blob = this.blob.slice(offset6, offset6 + length2);
|
194242
|
+
return new Uint8Array(await blob.arrayBuffer());
|
194243
|
+
}
|
194244
|
+
}
|
194245
|
+
class HTTPRangeReader {
|
194246
|
+
constructor(url, opts2 = {}) {
|
194247
|
+
__publicField(this, "url");
|
194248
|
+
__publicField(this, "length");
|
194249
|
+
__privateAdd(this, _overrides2, void 0);
|
194250
|
+
this.url = url;
|
194251
|
+
__privateSet(this, _overrides2, opts2.overrides ?? {});
|
194252
|
+
}
|
194253
|
+
async getLength() {
|
194254
|
+
if (this.length === void 0) {
|
194255
|
+
const req = await fetch(this.url, {
|
194256
|
+
...__privateGet(this, _overrides2),
|
194257
|
+
method: "HEAD"
|
194258
|
+
});
|
194259
|
+
if (!req.ok) {
|
194260
|
+
throw new Error(`failed http request ${this.url}, status: ${req.status}: ${req.statusText}`);
|
194261
|
+
}
|
194262
|
+
this.length = parseInt(req.headers.get("content-length"));
|
194263
|
+
if (Number.isNaN(this.length)) {
|
194264
|
+
throw Error("could not get length");
|
194265
|
+
}
|
194266
|
+
}
|
194267
|
+
return this.length;
|
194268
|
+
}
|
194269
|
+
async read(offset6, size2) {
|
194270
|
+
if (size2 === 0) {
|
194271
|
+
return new Uint8Array(0);
|
194272
|
+
}
|
194273
|
+
const req = await fetch_range(this.url, offset6, size2, __privateGet(this, _overrides2));
|
194274
|
+
if (!req.ok) {
|
194275
|
+
throw new Error(`failed http request ${this.url}, status: ${req.status} offset: ${offset6} size: ${size2}: ${req.statusText}`);
|
194276
|
+
}
|
194277
|
+
return new Uint8Array(await req.arrayBuffer());
|
194278
|
+
}
|
194279
|
+
}
|
194280
|
+
_overrides2 = new WeakMap();
|
194281
|
+
class ZipFileStore {
|
194282
|
+
constructor(reader) {
|
194283
|
+
__publicField(this, "info");
|
194284
|
+
this.info = unzip(reader);
|
194285
|
+
}
|
194286
|
+
async get(key2) {
|
194287
|
+
let entry2 = (await this.info).entries[strip_prefix(key2)];
|
194288
|
+
if (!entry2)
|
194289
|
+
return;
|
194290
|
+
return new Uint8Array(await entry2.arrayBuffer());
|
194291
|
+
}
|
194292
|
+
async has(key2) {
|
194293
|
+
return strip_prefix(key2) in (await this.info).entries;
|
194294
|
+
}
|
194295
|
+
static fromUrl(href2, opts2 = {}) {
|
194296
|
+
return new ZipFileStore(new HTTPRangeReader(href2, opts2));
|
194297
|
+
}
|
194298
|
+
static fromBlob(blob) {
|
194299
|
+
return new ZipFileStore(new BlobReader2(blob));
|
194300
|
+
}
|
194301
|
+
}
|
194302
|
+
const ZipFileStore$1 = ZipFileStore;
|
194303
|
+
function zarrOpenRoot(url, fileType, requestInit2) {
|
194304
|
+
let store2;
|
194305
|
+
if (fileType && fileType.endsWith(".zip")) {
|
194306
|
+
store2 = ZipFileStore$1.fromUrl(url, { overrides: requestInit2 });
|
194307
|
+
} else {
|
194308
|
+
store2 = new FetchStore$1(url, { overrides: requestInit2 });
|
194309
|
+
}
|
193254
194310
|
return root(store2);
|
193255
194311
|
}
|
193256
194312
|
function prevPowerOf2(x2) {
|
@@ -195925,6 +196981,7 @@ function SpatialSubscriber(props2) {
|
|
195925
196981
|
const [pointMultiObsLabelsData, pointMultiObsLabelsDataStatus] = usePointMultiObsLabels(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
195926
196982
|
const [obsSpotsData, obsSpotsDataStatus, obsSpotsUrls] = useMultiObsSpots(coordinationScopes, coordinationScopesBy, loaders, dataset, mergeCoordination, uuid);
|
195927
196983
|
const [obsSpotsSetsData, obsSpotsSetsDataStatus] = useSpotMultiObsSets(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
196984
|
+
const [obsSpotsFeatureLabelsData, obsSpotsFeatureLabelsDataStatus] = useSpotMultiFeatureLabels(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
195928
196985
|
const [spotMultiExpressionData, spotMultiLoadedFeatureSelection, spotMultiExpressionExtents, spotMultiExpressionNormData, spotMultiFeatureSelectionStatus] = useSpotMultiFeatureSelection(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
195929
196986
|
const [spotMultiIndicesData, spotMultiIndicesDataStatus] = useSpotMultiObsFeatureMatrixIndices(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
195930
196987
|
const [obsSegmentationsLocationsData, obsSegmentationsLocationsDataStatus] = useSegmentationMultiObsLocations(coordinationScopes, coordinationScopesBy, loaders, dataset);
|
@@ -196259,6 +197316,7 @@ function SpatialSubscriber(props2) {
|
|
196259
197316
|
spotLayerScopes,
|
196260
197317
|
spotLayerCoordination,
|
196261
197318
|
spotMultiExpressionExtents,
|
197319
|
+
spotMultiFeatureLabels: obsSpotsFeatureLabelsData,
|
196262
197320
|
// Points
|
196263
197321
|
pointLayerScopes,
|
196264
197322
|
pointLayerCoordination
|
@@ -204688,7 +205746,7 @@ const HIGLASS_BUNDLE_VERSION = "1.11.13";
|
|
204688
205746
|
const HIGLASS_CSS_URL = `https://unpkg.com/${HIGLASS_PKG_NAME}@${HIGLASS_BUNDLE_VERSION}/dist/hglib.css`;
|
204689
205747
|
register({ dataFetcher: ZarrMultivecDataFetcher_default, config: ZarrMultivecDataFetcher_default.config }, { pluginType: "dataFetcher" });
|
204690
205748
|
const LazyHiGlassComponent = React__default.lazy(async () => {
|
204691
|
-
const { HiGlassComponent } = await import("./hglib-
|
205749
|
+
const { HiGlassComponent } = await import("./hglib-bd5b112f.js").then((n3) => n3.h);
|
204692
205750
|
return { default: HiGlassComponent };
|
204693
205751
|
});
|
204694
205752
|
const HG_SIZE = 800;
|
@@ -209797,23 +210855,29 @@ function CellSetExpressionPlotSubscriber(props2) {
|
|
209797
210855
|
const { coordinationScopes, closeButtonVisible, downloadButtonVisible, removeGridComponent, theme, jitter: jitter2 = false, yMin = null, yUnits = null } = props2;
|
209798
210856
|
const classes = useStyles$1();
|
209799
210857
|
const loaders = useLoaders();
|
209800
|
-
const [{ dataset, obsType, featureType, featureValueType, featureSelection: geneSelection, featureValueTransform, featureValueTransformCoefficient, obsSetSelection: cellSetSelection, obsSetColor: cellSetColor, additionalObsSets: additionalCellSets }, { setFeatureValueTransform, setFeatureValueTransformCoefficient }] = useCoordination(COMPONENT_COORDINATION_TYPES[ViewType$1.OBS_SET_FEATURE_VALUE_DISTRIBUTION], coordinationScopes);
|
210858
|
+
const [{ dataset, obsType, featureType, featureValueType, featureSelection: geneSelection, featureValueTransform, featureValueTransformCoefficient, obsSetSelection: cellSetSelection, obsSetColor: cellSetColor, additionalObsSets: additionalCellSets, sampleType }, { setFeatureValueTransform, setFeatureValueTransformCoefficient }] = useCoordination(COMPONENT_COORDINATION_TYPES[ViewType$1.OBS_SET_FEATURE_VALUE_DISTRIBUTION], coordinationScopes);
|
209801
210859
|
const [width2, height2, containerRef] = useGridItemSize();
|
209802
210860
|
const transformOptions = VALUE_TRANSFORM_OPTIONS;
|
209803
210861
|
const [expressionData, loadedFeatureSelection, featureSelectionStatus] = useFeatureSelection(loaders, dataset, false, geneSelection, { obsType, featureType, featureValueType });
|
209804
210862
|
const [{ featureLabelsMap }, featureLabelsStatus, featureLabelsUrls] = useFeatureLabelsData(loaders, dataset, false, {}, {}, { featureType });
|
209805
210863
|
const [{ obsIndex }, matrixIndicesStatus, matrixIndicesUrls] = useObsFeatureMatrixIndices(loaders, dataset, false, { obsType, featureType, featureValueType });
|
209806
210864
|
const [{ obsSets: cellSets }, obsSetsStatus, obsSetsUrls] = useObsSetsData(loaders, dataset, true, {}, {}, { obsType });
|
210865
|
+
const [{ sampleSets }, sampleSetsStatus, sampleSetsUrls] = useSampleSetsData(loaders, dataset, false, {}, {}, { sampleType });
|
210866
|
+
const [{ sampleEdges }, sampleEdgesStatus, sampleEdgesUrls] = useSampleEdgesData(loaders, dataset, false, {}, {}, { obsType, sampleType });
|
209807
210867
|
const isReady = useReady([
|
209808
210868
|
featureSelectionStatus,
|
209809
210869
|
matrixIndicesStatus,
|
209810
210870
|
obsSetsStatus,
|
209811
|
-
featureLabelsStatus
|
210871
|
+
featureLabelsStatus,
|
210872
|
+
sampleSetsStatus,
|
210873
|
+
sampleEdgesStatus
|
209812
210874
|
]);
|
209813
210875
|
const urls2 = useUrls([
|
209814
210876
|
featureLabelsUrls,
|
209815
210877
|
matrixIndicesUrls,
|
209816
|
-
obsSetsUrls
|
210878
|
+
obsSetsUrls,
|
210879
|
+
sampleSetsUrls,
|
210880
|
+
sampleEdgesUrls
|
209817
210881
|
]);
|
209818
210882
|
const [expressionArr, setArr] = useExpressionByCellSet(expressionData, obsIndex, cellSets, additionalCellSets, geneSelection, cellSetSelection, cellSetColor, featureValueTransform, featureValueTransformCoefficient, theme);
|
209819
210883
|
const firstGeneSelected = geneSelection && geneSelection.length >= 1 ? (featureLabelsMap == null ? void 0 : featureLabelsMap.get(geneSelection[0])) || geneSelection[0] : null;
|
@@ -262949,6 +264013,40 @@ class ObsSetsCsvLoader extends CsvLoader {
|
|
262949
264013
|
}, url, coordinationValues));
|
262950
264014
|
}
|
262951
264015
|
}
|
264016
|
+
class SampleSetsCsvLoader extends CsvLoader {
|
264017
|
+
loadFromCache(data2) {
|
264018
|
+
if (this.cachedResult) {
|
264019
|
+
return this.cachedResult;
|
264020
|
+
}
|
264021
|
+
const { sampleIndex: indexCol, sampleSets: setsArr } = this.options;
|
264022
|
+
const obsIndex = data2.map((d) => String(d[indexCol]));
|
264023
|
+
const setsCols = setsArr.map(({ column }) => column);
|
264024
|
+
const cellSetIds = setsCols.map((setCol) => Array.isArray(setCol) ? setCol.map((subCol) => data2.map((d) => d[subCol])) : data2.map((d) => d[setCol]));
|
264025
|
+
const scoresCols = setsArr.map((option) => option.scorePath || void 0);
|
264026
|
+
const cellSetScores = scoresCols.map((scoreCol) => scoreCol ? data2.map((d) => d[scoreCol]) : void 0);
|
264027
|
+
const obsIndices = cellSetIds.map(() => obsIndex);
|
264028
|
+
const cellSetsTree = dataToCellSetsTree([
|
264029
|
+
obsIndices,
|
264030
|
+
cellSetIds,
|
264031
|
+
cellSetScores
|
264032
|
+
], setsArr);
|
264033
|
+
const obsSetsMembership = treeToMembershipMap(cellSetsTree);
|
264034
|
+
return [obsIndex, cellSetsTree, obsSetsMembership];
|
264035
|
+
}
|
264036
|
+
async load() {
|
264037
|
+
const payload = await this.getSourceData().catch((reason) => Promise.resolve(reason));
|
264038
|
+
if (payload instanceof AbstractLoaderError) {
|
264039
|
+
return Promise.reject(payload);
|
264040
|
+
}
|
264041
|
+
const { data: data2, url } = payload;
|
264042
|
+
const [obsIndex, cellSetsTree, obsSetsMembership] = this.loadFromCache(data2);
|
264043
|
+
return Promise.resolve(new LoaderResult({
|
264044
|
+
sampleIndex: obsIndex,
|
264045
|
+
sampleSets: cellSetsTree,
|
264046
|
+
sampleSetsMembership: obsSetsMembership
|
264047
|
+
}, url));
|
264048
|
+
}
|
264049
|
+
}
|
262952
264050
|
class JsonSource {
|
262953
264051
|
constructor({ url, requestInit: requestInit2 }) {
|
262954
264052
|
this.url = url;
|
@@ -263404,7 +264502,7 @@ async function initLoader(imageData) {
|
|
263404
264502
|
const { dimensions, isPyramid, transform: transform3 } = metadata2 || {};
|
263405
264503
|
const labels2 = dimensions.map((d) => d.field);
|
263406
264504
|
let source2;
|
263407
|
-
const root2 = await zarrOpenRoot(url, requestInit2);
|
264505
|
+
const root2 = await zarrOpenRoot(url, null, requestInit2);
|
263408
264506
|
if (isPyramid) {
|
263409
264507
|
const metadataUrl = `${url}${url.slice(-1) === "/" ? "" : "/"}.zmetadata`;
|
263410
264508
|
const response = await fetch(metadataUrl);
|
@@ -263442,7 +264540,7 @@ async function initLoader(imageData) {
|
|
263442
264540
|
}
|
263443
264541
|
case "ome-zarr": {
|
263444
264542
|
const { coordinateTransformations: coordinateTransformationsFromOptions } = metadata2 || {};
|
263445
|
-
const root2 = await zarrOpenRoot(url, requestInit2);
|
264543
|
+
const root2 = await zarrOpenRoot(url, null, requestInit2);
|
263446
264544
|
const loader2 = await loadOmeZarr(root2);
|
263447
264545
|
const { metadata: loaderMetadata } = loader2;
|
263448
264546
|
const { omero, multiscales } = loaderMetadata;
|
@@ -263572,11 +264670,11 @@ class RasterJsonAsObsSegmentationsLoader extends RasterLoader {
|
|
263572
264670
|
}
|
263573
264671
|
}
|
263574
264672
|
class ZarrDataSource {
|
263575
|
-
constructor({ url, requestInit: requestInit2, store: store2 }) {
|
264673
|
+
constructor({ url, requestInit: requestInit2, store: store2, fileType }) {
|
263576
264674
|
if (store2) {
|
263577
264675
|
this.storeRoot = root(store2);
|
263578
264676
|
} else {
|
263579
|
-
this.storeRoot = zarrOpenRoot(url, requestInit2);
|
264677
|
+
this.storeRoot = zarrOpenRoot(url, fileType, requestInit2);
|
263580
264678
|
}
|
263581
264679
|
}
|
263582
264680
|
getStoreRoot(path2) {
|
@@ -264747,6 +265845,35 @@ class ObsFeatureColumnsAnndataLoader extends AbstractTwoStepLoader {
|
|
264747
265845
|
]).then(([{ obsIndex, obsFeatureMatrix, featureIndex }]) => Promise.resolve(new LoaderResult({ obsIndex, obsFeatureMatrix, featureIndex }, null)));
|
264748
265846
|
}
|
264749
265847
|
}
|
265848
|
+
class SampleEdgesAnndataLoader extends AbstractTwoStepLoader {
|
265849
|
+
/**
|
265850
|
+
* Class method for loading observation string labels.
|
265851
|
+
* @returns {Promise} A promise for the array.
|
265852
|
+
*/
|
265853
|
+
loadLabels() {
|
265854
|
+
const { path: path2 } = this.options;
|
265855
|
+
if (this.labels) {
|
265856
|
+
return this.labels;
|
265857
|
+
}
|
265858
|
+
if (!this.labels) {
|
265859
|
+
this.labels = this.dataSource._loadColumn(path2);
|
265860
|
+
return this.labels;
|
265861
|
+
}
|
265862
|
+
this.labels = Promise.resolve(null);
|
265863
|
+
return this.labels;
|
265864
|
+
}
|
265865
|
+
async load() {
|
265866
|
+
const { path: path2 } = this.options;
|
265867
|
+
const superResult = await super.load().catch((reason) => Promise.resolve(reason));
|
265868
|
+
if (superResult instanceof AbstractLoaderError) {
|
265869
|
+
return Promise.reject(superResult);
|
265870
|
+
}
|
265871
|
+
return Promise.all([
|
265872
|
+
this.dataSource.loadObsIndex(path2),
|
265873
|
+
this.loadLabels()
|
265874
|
+
]).then(([obsIndex, sampleIds]) => Promise.resolve(new LoaderResult({ obsIndex, sampleIds }, null)));
|
265875
|
+
}
|
265876
|
+
}
|
264750
265877
|
class ImageWrapper {
|
264751
265878
|
constructor(vivLoader, options) {
|
264752
265879
|
__publicField(this, "vivLoader");
|
@@ -265200,7 +266327,7 @@ class SpatialDataLabelsLoader extends SpatialDataImageLoader {
|
|
265200
266327
|
};
|
265201
266328
|
const imageWrapper = result.data.obsSegmentations.instance;
|
265202
266329
|
const channelObjects = imageWrapper.getChannelObjects();
|
265203
|
-
const channelCoordination = channelObjects.slice(0,
|
266330
|
+
const channelCoordination = channelObjects.slice(0, 7).map((channelObj, i2) => ({
|
265204
266331
|
spatialTargetC: i2,
|
265205
266332
|
// obsType: channelObj.name,
|
265206
266333
|
spatialChannelColor: (channelObj.defaultColor || channelObj.autoDefaultColor).slice(0, 3),
|
@@ -265505,8 +266632,18 @@ const expectedCoordinationTypes = [
|
|
265505
266632
|
"obsLabelsType",
|
265506
266633
|
"embeddingType"
|
265507
266634
|
];
|
266635
|
+
function createGetFileType(jointFileType) {
|
266636
|
+
return (fileType) => {
|
266637
|
+
var _a3;
|
266638
|
+
if (jointFileType.endsWith(".zip") && ((_a3 = ALT_ZARR_STORE_TYPES[fileType]) == null ? void 0 : _a3.zip)) {
|
266639
|
+
return ALT_ZARR_STORE_TYPES[fileType].zip;
|
266640
|
+
}
|
266641
|
+
return fileType;
|
266642
|
+
};
|
266643
|
+
}
|
265508
266644
|
function expandAnndataZarr(fileDef) {
|
265509
266645
|
var _a3, _b2, _c2;
|
266646
|
+
const getFileType = createGetFileType(fileDef.fileType);
|
265510
266647
|
const baseFileDef = {
|
265511
266648
|
url: fileDef.url,
|
265512
266649
|
requestInit: fileDef.requestInit,
|
@@ -265528,7 +266665,7 @@ function expandAnndataZarr(fileDef) {
|
|
265528
266665
|
// obsFeatureMatrix
|
265529
266666
|
...options.obsFeatureMatrix ? [{
|
265530
266667
|
...baseFileDef,
|
265531
|
-
fileType: FileType$1.OBS_FEATURE_MATRIX_ANNDATA_ZARR,
|
266668
|
+
fileType: getFileType(FileType$1.OBS_FEATURE_MATRIX_ANNDATA_ZARR),
|
265532
266669
|
options: options.obsFeatureMatrix,
|
265533
266670
|
coordinationValues: {
|
265534
266671
|
...extraCoordinationValues,
|
@@ -265540,7 +266677,7 @@ function expandAnndataZarr(fileDef) {
|
|
265540
266677
|
// obsSets
|
265541
266678
|
...options.obsSets ? [{
|
265542
266679
|
...baseFileDef,
|
265543
|
-
fileType: FileType$1.OBS_SETS_ANNDATA_ZARR,
|
266680
|
+
fileType: getFileType(FileType$1.OBS_SETS_ANNDATA_ZARR),
|
265544
266681
|
options: options.obsSets,
|
265545
266682
|
coordinationValues: {
|
265546
266683
|
...extraCoordinationValues,
|
@@ -265550,7 +266687,7 @@ function expandAnndataZarr(fileDef) {
|
|
265550
266687
|
// obsSpots
|
265551
266688
|
...options.obsSpots ? [{
|
265552
266689
|
...baseFileDef,
|
265553
|
-
fileType: FileType$1.OBS_SPOTS_ANNDATA_ZARR,
|
266690
|
+
fileType: getFileType(FileType$1.OBS_SPOTS_ANNDATA_ZARR),
|
265554
266691
|
options: options.obsSpots,
|
265555
266692
|
coordinationValues: {
|
265556
266693
|
...extraCoordinationValues,
|
@@ -265560,7 +266697,7 @@ function expandAnndataZarr(fileDef) {
|
|
265560
266697
|
// obsPoints
|
265561
266698
|
...options.obsPoints ? [{
|
265562
266699
|
...baseFileDef,
|
265563
|
-
fileType: FileType$1.OBS_POINTS_ANNDATA_ZARR,
|
266700
|
+
fileType: getFileType(FileType$1.OBS_POINTS_ANNDATA_ZARR),
|
265564
266701
|
options: options.obsPoints,
|
265565
266702
|
coordinationValues: {
|
265566
266703
|
...extraCoordinationValues,
|
@@ -265570,7 +266707,7 @@ function expandAnndataZarr(fileDef) {
|
|
265570
266707
|
// obsLocations
|
265571
266708
|
...options.obsLocations ? [{
|
265572
266709
|
...baseFileDef,
|
265573
|
-
fileType: FileType$1.OBS_LOCATIONS_ANNDATA_ZARR,
|
266710
|
+
fileType: getFileType(FileType$1.OBS_LOCATIONS_ANNDATA_ZARR),
|
265574
266711
|
options: options.obsLocations,
|
265575
266712
|
coordinationValues: {
|
265576
266713
|
...extraCoordinationValues,
|
@@ -265580,7 +266717,7 @@ function expandAnndataZarr(fileDef) {
|
|
265580
266717
|
// obsSegmentations
|
265581
266718
|
...options.obsSegmentations ? [{
|
265582
266719
|
...baseFileDef,
|
265583
|
-
fileType: FileType$1.OBS_SEGMENTATIONS_ANNDATA_ZARR,
|
266720
|
+
fileType: getFileType(FileType$1.OBS_SEGMENTATIONS_ANNDATA_ZARR),
|
265584
266721
|
options: options.obsSegmentations,
|
265585
266722
|
coordinationValues: {
|
265586
266723
|
...extraCoordinationValues,
|
@@ -265592,7 +266729,7 @@ function expandAnndataZarr(fileDef) {
|
|
265592
266729
|
...options.obsEmbedding ? Array.isArray(options.obsEmbedding) ? options.obsEmbedding.map((oe) => ({
|
265593
266730
|
// obsEmbedding was an array, process each element.
|
265594
266731
|
...baseFileDef,
|
265595
|
-
fileType: FileType$1.OBS_EMBEDDING_ANNDATA_ZARR,
|
266732
|
+
fileType: getFileType(FileType$1.OBS_EMBEDDING_ANNDATA_ZARR),
|
265596
266733
|
options: {
|
265597
266734
|
path: oe.path,
|
265598
266735
|
dims: oe.dims
|
@@ -265606,7 +266743,7 @@ function expandAnndataZarr(fileDef) {
|
|
265606
266743
|
})) : [{
|
265607
266744
|
// obsEmbedding was an object.
|
265608
266745
|
...baseFileDef,
|
265609
|
-
fileType: FileType$1.OBS_EMBEDDING_ANNDATA_ZARR,
|
266746
|
+
fileType: getFileType(FileType$1.OBS_EMBEDDING_ANNDATA_ZARR),
|
265610
266747
|
options: options.obsEmbedding,
|
265611
266748
|
coordinationValues: {
|
265612
266749
|
...extraCoordinationValues,
|
@@ -265619,7 +266756,7 @@ function expandAnndataZarr(fileDef) {
|
|
265619
266756
|
...options.obsLabels ? Array.isArray(options.obsLabels) ? options.obsLabels.map((ol) => ({
|
265620
266757
|
// obsLabels was an array, process each element.
|
265621
266758
|
...baseFileDef,
|
265622
|
-
fileType: FileType$1.OBS_LABELS_ANNDATA_ZARR,
|
266759
|
+
fileType: getFileType(FileType$1.OBS_LABELS_ANNDATA_ZARR),
|
265623
266760
|
options: {
|
265624
266761
|
path: ol.path
|
265625
266762
|
},
|
@@ -265632,7 +266769,7 @@ function expandAnndataZarr(fileDef) {
|
|
265632
266769
|
})) : [{
|
265633
266770
|
// obsLabels was an object.
|
265634
266771
|
...baseFileDef,
|
265635
|
-
fileType: FileType$1.OBS_LABELS_ANNDATA_ZARR,
|
266772
|
+
fileType: getFileType(FileType$1.OBS_LABELS_ANNDATA_ZARR),
|
265636
266773
|
options: options.obsLabels,
|
265637
266774
|
coordinationValues: {
|
265638
266775
|
...extraCoordinationValues,
|
@@ -265645,7 +266782,7 @@ function expandAnndataZarr(fileDef) {
|
|
265645
266782
|
...options.featureLabels ? Array.isArray(options.featureLabels) ? options.featureLabels.map((fl) => ({
|
265646
266783
|
// featureLabels was an array, process each element.
|
265647
266784
|
...baseFileDef,
|
265648
|
-
fileType: FileType$1.FEATURE_LABELS_ANNDATA_ZARR,
|
266785
|
+
fileType: getFileType(FileType$1.FEATURE_LABELS_ANNDATA_ZARR),
|
265649
266786
|
options: {
|
265650
266787
|
path: fl.path
|
265651
266788
|
},
|
@@ -265658,7 +266795,7 @@ function expandAnndataZarr(fileDef) {
|
|
265658
266795
|
})) : [{
|
265659
266796
|
// featureLabels was an object.
|
265660
266797
|
...baseFileDef,
|
265661
|
-
fileType: FileType$1.FEATURE_LABELS_ANNDATA_ZARR,
|
266798
|
+
fileType: getFileType(FileType$1.FEATURE_LABELS_ANNDATA_ZARR),
|
265662
266799
|
options: options.featureLabels,
|
265663
266800
|
coordinationValues: {
|
265664
266801
|
...extraCoordinationValues,
|
@@ -266024,6 +267161,13 @@ function makeViewType(name2, component) {
|
|
266024
267161
|
function makeFileType(name2, dataType, dataLoaderClass, dataSourceClass, optionsSchema) {
|
266025
267162
|
return new PluginFileType(name2, dataType, dataLoaderClass, dataSourceClass, optionsSchema);
|
266026
267163
|
}
|
267164
|
+
function makeZarrFileTypes(name2, dataType, dataLoaderClass, dataSourceClass, optionsSchema) {
|
267165
|
+
const altFileTypes = Object.values(ALT_ZARR_STORE_TYPES[name2]);
|
267166
|
+
return [
|
267167
|
+
new PluginFileType(name2, dataType, dataLoaderClass, dataSourceClass, optionsSchema),
|
267168
|
+
...altFileTypes.map((n3) => new PluginFileType(n3, dataType, dataLoaderClass, dataSourceClass, optionsSchema))
|
267169
|
+
];
|
267170
|
+
}
|
266027
267171
|
const baseViewTypes = [
|
266028
267172
|
makeViewType(ViewType$1.DESCRIPTION, DescriptionSubscriber),
|
266029
267173
|
makeViewType(ViewType$1.OBS_SETS, ObsSetsManagerSubscriber),
|
@@ -266052,20 +267196,22 @@ const baseFileTypes = [
|
|
266052
267196
|
makeFileType(FileType$1.OBS_LABELS_CSV, DataType$2.OBS_LABELS, ObsLabelsCsvLoader, CsvSource, obsLabelsCsvSchema),
|
266053
267197
|
makeFileType(FileType$1.OBS_FEATURE_MATRIX_CSV, DataType$2.OBS_FEATURE_MATRIX, ObsFeatureMatrixCsvLoader, CsvSource, z.null()),
|
266054
267198
|
makeFileType(FileType$1.FEATURE_LABELS_CSV, DataType$2.FEATURE_LABELS, FeatureLabelsCsvLoader, CsvSource, featureLabelsCsvSchema),
|
267199
|
+
makeFileType(FileType$1.SAMPLE_SETS_CSV, DataType$2.SAMPLE_SETS, SampleSetsCsvLoader, CsvSource, sampleSetsCsvSchema),
|
266055
267200
|
// All JSON file types
|
266056
267201
|
makeFileType(FileType$1.OBS_SEGMENTATIONS_JSON, DataType$2.OBS_SEGMENTATIONS, ObsSegmentationsJsonLoader, JsonSource, z.null()),
|
266057
267202
|
makeFileType(FileType$1.OBS_SETS_JSON, DataType$2.OBS_SETS, ObsSetsJsonLoader, JsonSource, z.null()),
|
266058
267203
|
// All AnnData file types
|
266059
|
-
|
266060
|
-
|
266061
|
-
|
266062
|
-
|
266063
|
-
|
266064
|
-
|
266065
|
-
|
266066
|
-
|
266067
|
-
|
266068
|
-
|
267204
|
+
...makeZarrFileTypes(FileType$1.OBS_SETS_ANNDATA_ZARR, DataType$2.OBS_SETS, ObsSetsAnndataLoader, AnnDataSource, obsSetsAnndataSchema),
|
267205
|
+
...makeZarrFileTypes(FileType$1.OBS_EMBEDDING_ANNDATA_ZARR, DataType$2.OBS_EMBEDDING, ObsEmbeddingAnndataLoader, AnnDataSource, obsEmbeddingAnndataSchema),
|
267206
|
+
...makeZarrFileTypes(FileType$1.OBS_SPOTS_ANNDATA_ZARR, DataType$2.OBS_SPOTS, ObsSpotsAnndataLoader, AnnDataSource, obsSpotsAnndataSchema),
|
267207
|
+
...makeZarrFileTypes(FileType$1.OBS_POINTS_ANNDATA_ZARR, DataType$2.OBS_POINTS, ObsPointsAnndataLoader, AnnDataSource, obsPointsAnndataSchema),
|
267208
|
+
...makeZarrFileTypes(FileType$1.OBS_LOCATIONS_ANNDATA_ZARR, DataType$2.OBS_LOCATIONS, ObsLocationsAnndataLoader, AnnDataSource, obsLocationsAnndataSchema),
|
267209
|
+
...makeZarrFileTypes(FileType$1.OBS_LABELS_ANNDATA_ZARR, DataType$2.OBS_LABELS, ObsLabelsAnndataLoader, AnnDataSource, obsLabelsAnndataSchema),
|
267210
|
+
...makeZarrFileTypes(FileType$1.OBS_FEATURE_MATRIX_ANNDATA_ZARR, DataType$2.OBS_FEATURE_MATRIX, ObsFeatureMatrixAnndataLoader, AnnDataSource, obsFeatureMatrixAnndataSchema),
|
267211
|
+
...makeZarrFileTypes(FileType$1.OBS_FEATURE_COLUMNS_ANNDATA_ZARR, DataType$2.OBS_FEATURE_MATRIX, ObsFeatureColumnsAnndataLoader, AnnDataSource, obsFeatureColumnsAnndataSchema),
|
267212
|
+
...makeZarrFileTypes(FileType$1.OBS_SEGMENTATIONS_ANNDATA_ZARR, DataType$2.OBS_SEGMENTATIONS, ObsSegmentationsAnndataLoader, AnnDataSource, obsSegmentationsAnndataSchema),
|
267213
|
+
...makeZarrFileTypes(FileType$1.FEATURE_LABELS_ANNDATA_ZARR, DataType$2.FEATURE_LABELS, FeatureLabelsAnndataLoader, AnnDataSource, featureLabelsAnndataSchema),
|
267214
|
+
...makeZarrFileTypes(FileType$1.SAMPLE_EDGES_ANNDATA_ZARR, DataType$2.SAMPLE_EDGES, SampleEdgesAnndataLoader, AnnDataSource, sampleEdgesAnndataSchema),
|
266069
267215
|
// All MuData file types
|
266070
267216
|
makeFileType(FileType$1.OBS_SETS_MUDATA_ZARR, DataType$2.OBS_SETS, ObsSetsAnndataLoader, MuDataSource, obsSetsAnndataSchema),
|
266071
267217
|
makeFileType(FileType$1.OBS_EMBEDDING_MUDATA_ZARR, DataType$2.OBS_EMBEDDING, ObsEmbeddingAnndataLoader, MuDataSource, obsEmbeddingAnndataSchema),
|
@@ -266091,6 +267237,7 @@ const baseFileTypes = [
|
|
266091
267237
|
makeFileType(FileType$1.OBS_SPOTS_SPATIALDATA_ZARR, DataType$2.OBS_SPOTS, SpatialDataObsSpotsLoader, SpatialDataShapesSource, obsSpotsSpatialdataSchema),
|
266092
267238
|
makeFileType(FileType$1.OBS_FEATURE_MATRIX_SPATIALDATA_ZARR, DataType$2.OBS_FEATURE_MATRIX, ObsFeatureMatrixAnndataLoader, SpatialDataTableSource, obsFeatureMatrixSpatialdataSchema),
|
266093
267239
|
makeFileType(FileType$1.OBS_SETS_SPATIALDATA_ZARR, DataType$2.OBS_SETS, SpatialDataObsSetsLoader, SpatialDataTableSource, obsSetsSpatialdataSchema),
|
267240
|
+
makeFileType(FileType$1.FEATURE_LABELS_SPATIALDATA_ZARR, DataType$2.FEATURE_LABELS, FeatureLabelsAnndataLoader, SpatialDataTableSource, featureLabelsAnndataSchema),
|
266094
267241
|
// All legacy file types
|
266095
267242
|
makeFileType(FileType$1.OBS_FEATURE_MATRIX_EXPRESSION_MATRIX_ZARR, DataType$2.OBS_FEATURE_MATRIX, MatrixZarrAsObsFeatureMatrixLoader, ZarrDataSource, z.null()),
|
266096
267243
|
makeFileType(FileType$1.IMAGE_RASTER_JSON, DataType$2.IMAGE, RasterJsonAsImageLoader, JsonSource, rasterJsonSchema),
|
@@ -266109,6 +267256,7 @@ const baseFileTypes = [
|
|
266109
267256
|
];
|
266110
267257
|
const baseJointFileTypes = [
|
266111
267258
|
new PluginJointFileType(FileType$1.ANNDATA_ZARR, expandAnndataZarr, anndataZarrSchema),
|
267259
|
+
new PluginJointFileType(FileType$1.ANNDATA_ZARR_ZIP, expandAnndataZarr, anndataZarrSchema),
|
266112
267260
|
new PluginJointFileType(FileType$1.SPATIALDATA_ZARR, expandSpatialdataZarr, spatialdataZarrSchema),
|
266113
267261
|
// For legacy file types:
|
266114
267262
|
new PluginJointFileType(FileType$1.ANNDATA_CELLS_ZARR, expandAnndataCellsZarr, anndataCellsZarrSchema),
|
@@ -266303,7 +267451,9 @@ const baseCoordinationTypes = [
|
|
266303
267451
|
new PluginCoordinationType(CoordinationType$1.LEGEND_VISIBLE, true, z.boolean()),
|
266304
267452
|
new PluginCoordinationType(CoordinationType$1.SPATIAL_CHANNEL_LABELS_VISIBLE, true, z.boolean()),
|
266305
267453
|
new PluginCoordinationType(CoordinationType$1.SPATIAL_CHANNEL_LABELS_ORIENTATION, "vertical", z.enum(["vertical", "horizontal"])),
|
266306
|
-
new PluginCoordinationType(CoordinationType$1.SPATIAL_CHANNEL_LABEL_SIZE, 14, z.number())
|
267454
|
+
new PluginCoordinationType(CoordinationType$1.SPATIAL_CHANNEL_LABEL_SIZE, 14, z.number()),
|
267455
|
+
new PluginCoordinationType(CoordinationType$1.SAMPLE_TYPE, null, z.string().nullable()),
|
267456
|
+
new PluginCoordinationType(CoordinationType$1.SAMPLE_SET_SELECTION, null, z.array(z.string()).nullable())
|
266307
267457
|
];
|
266308
267458
|
function Vitessce(props2) {
|
266309
267459
|
const {
|
@@ -266312,8 +267462,7 @@ function Vitessce(props2) {
|
|
266312
267462
|
pluginViewTypes: pluginViewTypesProp,
|
266313
267463
|
pluginFileTypes: pluginFileTypesProp,
|
266314
267464
|
pluginCoordinationTypes: pluginCoordinationTypesProp,
|
266315
|
-
pluginJointFileTypes: pluginJointFileTypesProp
|
266316
|
-
stores
|
267465
|
+
pluginJointFileTypes: pluginJointFileTypesProp
|
266317
267466
|
} = props2;
|
266318
267467
|
const configKey = (config3 == null ? void 0 : config3.uid) || config3;
|
266319
267468
|
const configVersion = config3 == null ? void 0 : config3.version;
|