@vitessce/dev 3.7.1 → 3.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{index-ChoWl6hO.js → OrbitControls-CgWXKP0s.js} +270 -10111
- package/dist/{ReactNeuroglancer-Bsuj_rfq.js → ReactNeuroglancer-CmQ5YZjK.js} +1 -1
- package/dist/{deflate-n-DtstV2.js → deflate-ChkKM_te.js} +1 -1
- package/dist/{higlass-ZUQODbTU.js → higlass-DhNUWZfQ.js} +1 -1
- package/dist/index-BOwhqbYq.js +9854 -0
- package/dist/{index-CWNhvpQm.js → index-C9I_zc0N.js} +314 -484
- package/dist/index-CNEgNHGE.js +3524 -0
- package/dist/index.js +35 -35
- package/dist/{jpeg-BxkriCm0.js → jpeg-6gnBw8GQ.js} +1 -1
- package/dist/{lerc-DRsDr7p1.js → lerc-DDqrobwW.js} +1 -1
- package/dist/{lzw-BElCYn2X.js → lzw-BORr6VT_.js} +1 -1
- package/dist/{packbits-JP_x4J9d.js → packbits-DWgerUGv.js} +1 -1
- package/dist/{raw-Dx0RfNJQ.js → raw-t8QoMNca.js} +1 -1
- package/dist/{troika-three-text.esm-T8BkUA2e.js → troika-three-text.esm-NFPARvmE.js} +1 -1
- package/dist/{webimage-kq1LVhhR.js → webimage-DIKPtAuC.js} +1 -1
- package/package.json +5 -5
|
@@ -47,6 +47,7 @@ const ViewType$2 = {
|
|
|
47
47
|
SCATTERPLOT: "scatterplot",
|
|
48
48
|
SPATIAL: "spatial",
|
|
49
49
|
SPATIAL_BETA: "spatialBeta",
|
|
50
|
+
SPATIAL_ACCELERATED: "spatialAccelerated",
|
|
50
51
|
HEATMAP: "heatmap",
|
|
51
52
|
LAYER_CONTROLLER: "layerController",
|
|
52
53
|
LAYER_CONTROLLER_BETA: "layerControllerBeta",
|
|
@@ -350,6 +351,8 @@ const CoordinationType$2 = {
|
|
|
350
351
|
// Could be per-image-layer
|
|
351
352
|
SPATIAL_TARGET_RESOLUTION: "spatialTargetResolution",
|
|
352
353
|
// Per-spatial-layer
|
|
354
|
+
SPATIAL_MAX_RESOLUTION: "spatialMaxResolution",
|
|
355
|
+
// Per-image-channel (for spatial-accelerated)
|
|
353
356
|
// For clipping plane sliders
|
|
354
357
|
SPATIAL_SLICE_X: "spatialSliceX",
|
|
355
358
|
SPATIAL_SLICE_Y: "spatialSliceY",
|
|
@@ -927,6 +930,7 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
|
927
930
|
CoordinationType$2.SPATIAL_RENDERING_MODE,
|
|
928
931
|
CoordinationType$2.VOLUMETRIC_RENDERING_ALGORITHM,
|
|
929
932
|
CoordinationType$2.SPATIAL_TARGET_RESOLUTION,
|
|
933
|
+
CoordinationType$2.SPATIAL_MAX_RESOLUTION,
|
|
930
934
|
CoordinationType$2.SPATIAL_SLICE_X,
|
|
931
935
|
CoordinationType$2.SPATIAL_SLICE_Y,
|
|
932
936
|
CoordinationType$2.SPATIAL_SLICE_Z,
|
|
@@ -1100,6 +1104,7 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
|
1100
1104
|
CoordinationType$2.SPATIAL_RENDERING_MODE,
|
|
1101
1105
|
CoordinationType$2.VOLUMETRIC_RENDERING_ALGORITHM,
|
|
1102
1106
|
CoordinationType$2.SPATIAL_TARGET_RESOLUTION,
|
|
1107
|
+
CoordinationType$2.SPATIAL_MAX_RESOLUTION,
|
|
1103
1108
|
CoordinationType$2.SPATIAL_SLICE_X,
|
|
1104
1109
|
CoordinationType$2.SPATIAL_SLICE_Y,
|
|
1105
1110
|
CoordinationType$2.SPATIAL_SLICE_Z,
|
|
@@ -1328,7 +1333,7 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
|
1328
1333
|
CoordinationType$2.HIERARCHY_LEVELS
|
|
1329
1334
|
]
|
|
1330
1335
|
};
|
|
1331
|
-
const version$6 = "3.
|
|
1336
|
+
const version$6 = "3.8.0";
|
|
1332
1337
|
const META_VERSION = {
|
|
1333
1338
|
version: version$6
|
|
1334
1339
|
};
|
|
@@ -1656,7 +1661,7 @@ const OrderedLogLevels = [
|
|
|
1656
1661
|
LogLevel.ERROR
|
|
1657
1662
|
];
|
|
1658
1663
|
const DEFAULT_DEBUG_MODE = false;
|
|
1659
|
-
const DEFAULT_LOG_LEVEL = LogLevel.
|
|
1664
|
+
const DEFAULT_LOG_LEVEL = LogLevel.INFO;
|
|
1660
1665
|
let GLOBAL_DEBUG_MODE = DEFAULT_DEBUG_MODE;
|
|
1661
1666
|
function getDebugMode() {
|
|
1662
1667
|
return GLOBAL_DEBUG_MODE;
|
|
@@ -79295,6 +79300,7 @@ function addImageChannelInMetaCoordinationScopesHelper(coordinationScopesRaw, la
|
|
|
79295
79300
|
const nextWindowScope = getNextScope(Object.keys(coordinationSpace[CoordinationType$2.SPATIAL_CHANNEL_WINDOW] || {}));
|
|
79296
79301
|
const nextVisibleScope = getNextScope(Object.keys(coordinationSpace[CoordinationType$2.SPATIAL_CHANNEL_VISIBLE] || {}));
|
|
79297
79302
|
const nextOpacityScope = getNextScope(Object.keys(coordinationSpace[CoordinationType$2.SPATIAL_CHANNEL_OPACITY] || {}));
|
|
79303
|
+
const nextMaxResolutionScope = getNextScope(Object.keys(coordinationSpace[CoordinationType$2.SPATIAL_MAX_RESOLUTION] || {}));
|
|
79298
79304
|
newCoordinationSpace = {
|
|
79299
79305
|
...coordinationSpace,
|
|
79300
79306
|
[CoordinationType$2.IMAGE_CHANNEL]: {
|
|
@@ -79321,6 +79327,10 @@ function addImageChannelInMetaCoordinationScopesHelper(coordinationScopesRaw, la
|
|
|
79321
79327
|
[CoordinationType$2.SPATIAL_CHANNEL_OPACITY]: {
|
|
79322
79328
|
...coordinationSpace[CoordinationType$2.SPATIAL_CHANNEL_OPACITY],
|
|
79323
79329
|
[nextOpacityScope]: 1
|
|
79330
|
+
},
|
|
79331
|
+
[CoordinationType$2.SPATIAL_MAX_RESOLUTION]: {
|
|
79332
|
+
...coordinationSpace[CoordinationType$2.SPATIAL_MAX_RESOLUTION],
|
|
79333
|
+
[nextOpacityScope]: 1
|
|
79324
79334
|
}
|
|
79325
79335
|
};
|
|
79326
79336
|
if (hasPerLayerChannels) {
|
|
@@ -79356,6 +79366,10 @@ function addImageChannelInMetaCoordinationScopesHelper(coordinationScopesRaw, la
|
|
|
79356
79366
|
[CoordinationType$2.SPATIAL_CHANNEL_OPACITY]: {
|
|
79357
79367
|
...metaCoordinationScopesBy?.[channelMetaScopeBy]?.[CoordinationType$2.IMAGE_CHANNEL]?.[CoordinationType$2.SPATIAL_CHANNEL_OPACITY],
|
|
79358
79368
|
[nextChannelScope]: nextOpacityScope
|
|
79369
|
+
},
|
|
79370
|
+
[CoordinationType$2.SPATIAL_MAX_RESOLUTION]: {
|
|
79371
|
+
...metaCoordinationScopesBy?.[channelMetaScopeBy]?.[CoordinationType$2.IMAGE_CHANNEL]?.[CoordinationType$2.SPATIAL_MAX_RESOLUTION],
|
|
79372
|
+
[nextChannelScope]: nextMaxResolutionScope
|
|
79359
79373
|
}
|
|
79360
79374
|
}
|
|
79361
79375
|
}
|
|
@@ -79393,6 +79407,10 @@ function addImageChannelInMetaCoordinationScopesHelper(coordinationScopesRaw, la
|
|
|
79393
79407
|
[CoordinationType$2.SPATIAL_CHANNEL_OPACITY]: {
|
|
79394
79408
|
...metaCoordinationScopesBy?.[channelMetaScope]?.[CoordinationType$2.IMAGE_CHANNEL]?.[CoordinationType$2.SPATIAL_CHANNEL_OPACITY],
|
|
79395
79409
|
[nextChannelScope]: nextOpacityScope
|
|
79410
|
+
},
|
|
79411
|
+
[CoordinationType$2.SPATIAL_MAX_RESOLUTION]: {
|
|
79412
|
+
...metaCoordinationScopesBy?.[channelMetaScope]?.[CoordinationType$2.IMAGE_CHANNEL]?.[CoordinationType$2.SPATIAL_MAX_RESOLUTION],
|
|
79413
|
+
[nextChannelScope]: nextMaxResolutionScope
|
|
79396
79414
|
}
|
|
79397
79415
|
}
|
|
79398
79416
|
}
|
|
@@ -225685,22 +225703,22 @@ async function getDecoder(fileDirectory) {
|
|
|
225685
225703
|
const Decoder = await importFn();
|
|
225686
225704
|
return new Decoder(fileDirectory);
|
|
225687
225705
|
}
|
|
225688
|
-
addDecoder([void 0, 1], () => import("./raw-
|
|
225689
|
-
addDecoder(5, () => import("./lzw-
|
|
225706
|
+
addDecoder([void 0, 1], () => import("./raw-t8QoMNca.js").then((m2) => m2.default));
|
|
225707
|
+
addDecoder(5, () => import("./lzw-BORr6VT_.js").then((m2) => m2.default));
|
|
225690
225708
|
addDecoder(6, () => {
|
|
225691
225709
|
throw new Error("old style JPEG compression is not supported.");
|
|
225692
225710
|
});
|
|
225693
|
-
addDecoder(7, () => import("./jpeg-
|
|
225694
|
-
addDecoder([8, 32946], () => import("./deflate-
|
|
225695
|
-
addDecoder(32773, () => import("./packbits-
|
|
225711
|
+
addDecoder(7, () => import("./jpeg-6gnBw8GQ.js").then((m2) => m2.default));
|
|
225712
|
+
addDecoder([8, 32946], () => import("./deflate-ChkKM_te.js").then((m2) => m2.default));
|
|
225713
|
+
addDecoder(32773, () => import("./packbits-DWgerUGv.js").then((m2) => m2.default));
|
|
225696
225714
|
addDecoder(
|
|
225697
225715
|
34887,
|
|
225698
|
-
() => import("./lerc-
|
|
225716
|
+
() => import("./lerc-DDqrobwW.js").then(async (m2) => {
|
|
225699
225717
|
await m2.zstd.init();
|
|
225700
225718
|
return m2;
|
|
225701
225719
|
}).then((m2) => m2.default)
|
|
225702
225720
|
);
|
|
225703
|
-
addDecoder(50001, () => import("./webimage-
|
|
225721
|
+
addDecoder(50001, () => import("./webimage-DIKPtAuC.js").then((m2) => m2.default));
|
|
225704
225722
|
function copyNewSize(array2, width2, height2, samplesPerPixel = 1) {
|
|
225705
225723
|
return new (Object.getPrototypeOf(array2)).constructor(width2 * height2 * samplesPerPixel);
|
|
225706
225724
|
}
|
|
@@ -243593,11 +243611,11 @@ function TooltipContent(props) {
|
|
|
243593
243611
|
return jsxRuntimeExports.jsx("table", { children: jsxRuntimeExports.jsx("tbody", { children: Object.entries(mappedInfo).map(([key2, value2]) => jsxRuntimeExports.jsxs("tr", { children: [jsxRuntimeExports.jsx("th", { children: key2 }), jsxRuntimeExports.jsx("td", { children: value2 })] }, key2)) }) });
|
|
243594
243612
|
}
|
|
243595
243613
|
function ScatterplotTooltipSubscriber(props) {
|
|
243596
|
-
const { parentUuid, obsHighlight, width: width2, height: height2, getObsInfo
|
|
243614
|
+
const { parentUuid, obsHighlight, width: width2, height: height2, getObsInfo, featureType, featureLabelsMap } = props;
|
|
243597
243615
|
const sourceUuid = useComponentHover();
|
|
243598
243616
|
const viewInfo = useComponentViewInfo(parentUuid);
|
|
243599
|
-
const [cellInfo, x2, y2] = obsHighlight &&
|
|
243600
|
-
|
|
243617
|
+
const [cellInfo, x2, y2] = obsHighlight && getObsInfo ? [
|
|
243618
|
+
getObsInfo(obsHighlight),
|
|
243601
243619
|
...viewInfo && viewInfo.projectFromId ? viewInfo.projectFromId(obsHighlight) : [null, null]
|
|
243602
243620
|
] : [null, null, null];
|
|
243603
243621
|
return cellInfo ? jsxRuntimeExports.jsx(Tooltip2D, { x: x2, y: y2, parentUuid, sourceUuid, parentWidth: width2, parentHeight: height2, children: jsxRuntimeExports.jsx(TooltipContent, { info: cellInfo, featureType, featureLabelsMap }) }) : null;
|
|
@@ -248007,7 +248025,7 @@ function EmbeddingScatterplotSubscriber(props) {
|
|
|
248007
248025
|
initialTargetY,
|
|
248008
248026
|
averageFillDensity
|
|
248009
248027
|
]);
|
|
248010
|
-
const
|
|
248028
|
+
const getObsInfo = useGetObsInfo(observationsLabel, obsLabelsTypes, obsLabelsData, obsSetsMembership);
|
|
248011
248029
|
const cellSelectionSet = useMemo$1(() => new Set(cellSelection), [cellSelection]);
|
|
248012
248030
|
const getCellIsSelected = useCallback((object2, { index: index2 }) => (cellSelectionSet || /* @__PURE__ */ new Set([])).has(obsEmbeddingIndex[index2]) ? 1 : 0, [cellSelectionSet, obsEmbeddingIndex]);
|
|
248013
248031
|
const cellRadius = cellRadiusMode === "manual" ? cellRadiusFixed : dynamicCellRadius;
|
|
@@ -248164,7 +248182,7 @@ function EmbeddingScatterplotSubscriber(props) {
|
|
|
248164
248182
|
embeddingContoursVisible,
|
|
248165
248183
|
circleInfo,
|
|
248166
248184
|
featureSelection: geneSelection
|
|
248167
|
-
}), tooltipsVisible && width2 && height2 ? jsxRuntimeExports.jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid2, obsHighlight: cellHighlight, width: width2, height: height2, getObsInfo
|
|
248185
|
+
}), tooltipsVisible && width2 && height2 ? jsxRuntimeExports.jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid2, obsHighlight: cellHighlight, width: width2, height: height2, getObsInfo, featureType, featureLabelsMap }) : null, jsxRuntimeExports.jsx(Legend, {
|
|
248168
248186
|
visible: true,
|
|
248169
248187
|
theme,
|
|
248170
248188
|
featureType,
|
|
@@ -248438,7 +248456,7 @@ function GatingSubscriber(props) {
|
|
|
248438
248456
|
matrixObsIndex: obsIndex,
|
|
248439
248457
|
expressionData: uint8ExpressionData
|
|
248440
248458
|
});
|
|
248441
|
-
const
|
|
248459
|
+
const getObsInfo = useCallback((obsId) => {
|
|
248442
248460
|
const selectedTransformName = VALUE_TRANSFORM_OPTIONS.find((o2) => o2.value === featureValueTransform)?.name;
|
|
248443
248461
|
const genePrefix = featureValueTransform ? `${selectedTransformName} ` : "";
|
|
248444
248462
|
const obsIdx = obsIndex?.indexOf(obsId);
|
|
@@ -248468,7 +248486,7 @@ function GatingSubscriber(props) {
|
|
|
248468
248486
|
setTargetZ(target2[2] || 0);
|
|
248469
248487
|
}, obsEmbeddingIndex: obsIndex, obsEmbedding: obsXY, cellFilter, cellSelection, cellHighlight, cellColors, cellSetPolygons, cellSetLabelSize, cellSetLabelsVisible, cellSetPolygonsVisible, setCellFilter, setCellSelection: setCellSelectionProp, setCellHighlight, cellRadius, cellOpacity, cellColorEncoding, geneExpressionColormap, geneExpressionColormapRange, setComponentHover: () => {
|
|
248470
248488
|
setComponentHover(uuid2);
|
|
248471
|
-
}, updateViewInfo: setComponentViewInfo, getExpressionValue, getCellIsSelected }), !disableTooltip && jsxRuntimeExports.jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid2, obsHighlight: cellHighlight, width: width2, height: height2, getObsInfo
|
|
248489
|
+
}, updateViewInfo: setComponentViewInfo, getExpressionValue, getCellIsSelected }), !disableTooltip && jsxRuntimeExports.jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid2, obsHighlight: cellHighlight, width: width2, height: height2, getObsInfo })] });
|
|
248472
248490
|
}
|
|
248473
248491
|
var DEFAULT_CONFIG = {
|
|
248474
248492
|
// minimum relative difference between two compared values,
|
|
@@ -263451,13 +263469,16 @@ const getStatsForResolution = (loader2, resolution) => {
|
|
|
263451
263469
|
const height2 = shape2[labels2.indexOf("y")];
|
|
263452
263470
|
const width2 = shape2[labels2.indexOf("x")];
|
|
263453
263471
|
const depth = shape2[labels2.indexOf("z")];
|
|
263472
|
+
const dims = Object.fromEntries(labels2.map((label2, i2) => [label2, shape2[i2]]));
|
|
263454
263473
|
const depthDownsampled = Math.max(1, depth >> resolution);
|
|
263455
263474
|
const totalBytes = 4 * height2 * width2 * depthDownsampled;
|
|
263456
263475
|
return {
|
|
263457
263476
|
height: height2,
|
|
263458
263477
|
width: width2,
|
|
263478
|
+
depth,
|
|
263459
263479
|
depthDownsampled,
|
|
263460
|
-
totalBytes
|
|
263480
|
+
totalBytes,
|
|
263481
|
+
dims
|
|
263461
263482
|
};
|
|
263462
263483
|
};
|
|
263463
263484
|
const canLoadResolution = (loader2, resolution) => {
|
|
@@ -267531,8 +267552,8 @@ function SpatialOptions(props) {
|
|
|
267531
267552
|
return `${labelPrefix} for spatial gene expression colormap range`;
|
|
267532
267553
|
}, id: `gene-expression-colormap-range-${spatialOptionsId}`, valueLabelDisplay: "auto", step: 5e-3, min: 0, max: 1 }) })] })] }) : null] });
|
|
267533
267554
|
}
|
|
267534
|
-
function SpatialTooltipSubscriber
|
|
267535
|
-
const { parentUuid, obsHighlight, width: width2, height: height2, getObsInfo
|
|
267555
|
+
function SpatialTooltipSubscriber(props) {
|
|
267556
|
+
const { parentUuid, obsHighlight, width: width2, height: height2, getObsInfo, hoverData, hoverCoord, hoverMode, useHoverInfoForTooltip, getObsIdFromHoverData, featureType, featureLabelsMap } = props;
|
|
267536
267557
|
const sourceUuid = useComponentHover();
|
|
267537
267558
|
const viewInfo = useComponentViewInfo(parentUuid);
|
|
267538
267559
|
let [cellInfo, x2, y2] = [null, null, null];
|
|
@@ -267540,7 +267561,7 @@ function SpatialTooltipSubscriber$1(props) {
|
|
|
267540
267561
|
const obsId = getObsIdFromHoverData(hoverData);
|
|
267541
267562
|
if (obsId) {
|
|
267542
267563
|
[cellInfo, x2, y2] = [
|
|
267543
|
-
|
|
267564
|
+
getObsInfo(obsId, hoverMode),
|
|
267544
267565
|
...hoverCoord || [null, null]
|
|
267545
267566
|
];
|
|
267546
267567
|
}
|
|
@@ -267548,14 +267569,14 @@ function SpatialTooltipSubscriber$1(props) {
|
|
|
267548
267569
|
const obsId = getObsIdFromHoverData(hoverData);
|
|
267549
267570
|
if (obsId) {
|
|
267550
267571
|
[cellInfo, x2, y2] = [
|
|
267551
|
-
|
|
267572
|
+
getObsInfo(obsId, hoverMode),
|
|
267552
267573
|
...hoverCoord || [null, null]
|
|
267553
267574
|
];
|
|
267554
267575
|
}
|
|
267555
|
-
} else if (!useHoverInfoForTooltip &&
|
|
267576
|
+
} else if (!useHoverInfoForTooltip && getObsInfo && obsHighlight) {
|
|
267556
267577
|
const obsId = obsHighlight;
|
|
267557
267578
|
[cellInfo, x2, y2] = [
|
|
267558
|
-
|
|
267579
|
+
getObsInfo(obsId, hoverMode),
|
|
267559
267580
|
...viewInfo && viewInfo.projectFromId ? viewInfo.projectFromId(obsId) : [null, null]
|
|
267560
267581
|
];
|
|
267561
267582
|
}
|
|
@@ -267729,7 +267750,7 @@ function SpatialSubscriber$1(props) {
|
|
|
267729
267750
|
matrixObsIndex
|
|
267730
267751
|
]);
|
|
267731
267752
|
const cellSelection = useMemo$1(() => Array.from(cellColors.keys()), [cellColors]);
|
|
267732
|
-
const
|
|
267753
|
+
const getObsInfo = useGetObsInfo(observationsLabel, obsLabelsTypes, obsLabelsData, obsSetsMembership);
|
|
267733
267754
|
const getTooltipObsInfo = useCallback((tooltipObsId, tooltipObsType) => {
|
|
267734
267755
|
if (tooltipObsType === HOVER_MODE.MOLECULE_LAYER) {
|
|
267735
267756
|
return {
|
|
@@ -267737,8 +267758,8 @@ function SpatialSubscriber$1(props) {
|
|
|
267737
267758
|
"Molecule Name": obsLocationsLabels[tooltipObsId]
|
|
267738
267759
|
};
|
|
267739
267760
|
}
|
|
267740
|
-
return
|
|
267741
|
-
}, [
|
|
267761
|
+
return getObsInfo(tooltipObsId);
|
|
267762
|
+
}, [getObsInfo, obsLocationsLabels]);
|
|
267742
267763
|
const [hoverData, setHoverData] = useState(null);
|
|
267743
267764
|
const [hoverCoord, setHoverCoord] = useState(null);
|
|
267744
267765
|
const [hoverMode, setHoverMode] = useState(null);
|
|
@@ -267866,7 +267887,7 @@ function SpatialSubscriber$1(props) {
|
|
|
267866
267887
|
orbitAxis
|
|
267867
267888
|
}, setViewState, originalViewState, imageLayerDefs: imageLayers, obsSegmentationsLayerDefs: cellsLayer, obsLocationsLayerDefs: moleculesLayer, neighborhoodLayerDefs: neighborhoodsLayer, obsLocationsIndex, obsSegmentationsIndex, obsLocations, obsLocationsLabels, obsLocationsFeatureIndex, hasSegmentations: hasSegmentationsData, obsSegmentations, obsSegmentationsType, obsCentroids, obsCentroidsIndex, cellFilter, cellSelection, cellHighlight, cellColors, neighborhoods, imageLayerLoaders: resolutionFilteredImageLayerLoaders, setCellFilter, setCellSelection: setCellSelectionProp, setCellHighlight, setHoverInfo, setMoleculeHighlight, setComponentHover: () => {
|
|
267868
267889
|
setComponentHover(uuid2);
|
|
267869
|
-
}, updateViewInfo: setComponentViewInfo, imageLayerCallbacks, segmentationLayerCallbacks, spatialAxisFixed, geneExpressionColormap, geneExpressionColormapRange, expressionData: shiftedExpressionDataForBitmask, cellColorEncoding, getExpressionValue, theme, useFullResolutionImage, photometricInterpretation }), tooltipsVisible && jsxRuntimeExports.jsx(SpatialTooltipSubscriber
|
|
267890
|
+
}, updateViewInfo: setComponentViewInfo, imageLayerCallbacks, segmentationLayerCallbacks, spatialAxisFixed, geneExpressionColormap, geneExpressionColormapRange, expressionData: shiftedExpressionDataForBitmask, cellColorEncoding, getExpressionValue, theme, useFullResolutionImage, photometricInterpretation }), tooltipsVisible && jsxRuntimeExports.jsx(SpatialTooltipSubscriber, { parentUuid: uuid2, obsHighlight: cellHighlight || moleculeHighlight, width: width2, height: height2, getObsInfo: getTooltipObsInfo, useHoverInfoForTooltip, hoverData, hoverCoord, hoverMode, getObsIdFromHoverData, featureType, featureLabelsMap }), jsxRuntimeExports.jsx(Legend, {
|
|
267870
267891
|
visible: true,
|
|
267871
267892
|
// Fix to dark theme due to black background of spatial plot.
|
|
267872
267893
|
theme: "dark",
|
|
@@ -269127,117 +269148,6 @@ class Spatial2 extends AbstractSpatialOrScatterplot {
|
|
|
269127
269148
|
}
|
|
269128
269149
|
}
|
|
269129
269150
|
const SpatialWrapper = forwardRef$1((props, deckRef) => jsxRuntimeExports.jsx(Spatial2, { ...props, deckRef }));
|
|
269130
|
-
function TooltipChild(props) {
|
|
269131
|
-
const { x: x2, y: y2, parentUuid, sourceUuid, width: width2, height: height2, info: info2, tooltipsVisible, tooltipCrosshairsVisible, featureType, featureLabelsMap } = props;
|
|
269132
|
-
const visible = parentUuid === sourceUuid ? tooltipsVisible : tooltipCrosshairsVisible;
|
|
269133
|
-
return visible ? jsxRuntimeExports.jsx(Tooltip2D, { x: x2, y: y2, parentUuid, sourceUuid, parentWidth: width2, parentHeight: height2, children: jsxRuntimeExports.jsx(TooltipContent, { info: info2, featureType, featureLabelsMap }) }) : null;
|
|
269134
|
-
}
|
|
269135
|
-
function getXY(obsHighlight, viewInfo, obsIndex, obsLocations, useHoverInfoForTooltip, projectedHoverCoord) {
|
|
269136
|
-
const hasObsCoordinates = useHoverInfoForTooltip ? true : obsIndex && obsLocations;
|
|
269137
|
-
if (!hasObsCoordinates)
|
|
269138
|
-
return null;
|
|
269139
|
-
const obsI = obsIndex?.indexOf(obsHighlight);
|
|
269140
|
-
if (obsI < 0)
|
|
269141
|
-
return null;
|
|
269142
|
-
if (useHoverInfoForTooltip) {
|
|
269143
|
-
return [projectedHoverCoord?.[0], projectedHoverCoord?.[1]];
|
|
269144
|
-
}
|
|
269145
|
-
const obsCoord = [obsLocations?.data[0][obsI] || 0, obsLocations?.data[1][obsI] || 0, 0];
|
|
269146
|
-
const projectedObsCoord = viewInfo?.project(obsCoord);
|
|
269147
|
-
return [projectedObsCoord?.[0], projectedObsCoord?.[1]];
|
|
269148
|
-
}
|
|
269149
|
-
function getObsInfo(obsSetsData, obsType, obsId) {
|
|
269150
|
-
let result = {
|
|
269151
|
-
[`${capitalize$3(obsType)} ID`]: obsId
|
|
269152
|
-
};
|
|
269153
|
-
if (obsSetsData?.obsSetsMembership) {
|
|
269154
|
-
const obsMembership = obsSetsData.obsSetsMembership.get(obsId) || [];
|
|
269155
|
-
if (obsMembership) {
|
|
269156
|
-
result = {
|
|
269157
|
-
...result,
|
|
269158
|
-
...Object.fromEntries(obsMembership.flatMap((path2) => path2.slice(1).map((pathEl, elLevel) => [
|
|
269159
|
-
`${path2[0]}${path2.length > 2 ? ` L${elLevel + 1}` : ""}`,
|
|
269160
|
-
pathEl
|
|
269161
|
-
])))
|
|
269162
|
-
};
|
|
269163
|
-
}
|
|
269164
|
-
}
|
|
269165
|
-
return result;
|
|
269166
|
-
}
|
|
269167
|
-
function SpatialTooltipSubscriber(props) {
|
|
269168
|
-
const {
|
|
269169
|
-
parentUuid,
|
|
269170
|
-
width: width2,
|
|
269171
|
-
height: height2,
|
|
269172
|
-
hoverCoord,
|
|
269173
|
-
featureType,
|
|
269174
|
-
featureLabelsMap,
|
|
269175
|
-
// Points
|
|
269176
|
-
obsPoints,
|
|
269177
|
-
pointLayerScopes,
|
|
269178
|
-
pointLayerCoordination,
|
|
269179
|
-
// Spots
|
|
269180
|
-
obsSpots,
|
|
269181
|
-
spotLayerScopes,
|
|
269182
|
-
spotLayerCoordination,
|
|
269183
|
-
// Segmentations
|
|
269184
|
-
obsSegmentationsLocations,
|
|
269185
|
-
segmentationLayerScopes,
|
|
269186
|
-
segmentationChannelScopesByLayer,
|
|
269187
|
-
segmentationChannelCoordination,
|
|
269188
|
-
obsSegmentationsSetsData,
|
|
269189
|
-
// Images
|
|
269190
|
-
imageLayerScopes,
|
|
269191
|
-
imageLayerCoordination
|
|
269192
|
-
} = props;
|
|
269193
|
-
const sourceUuid = useComponentHover();
|
|
269194
|
-
const viewInfo = useComponentViewInfo(parentUuid);
|
|
269195
|
-
const useHoverInfoForTooltip = sourceUuid === parentUuid && hoverCoord;
|
|
269196
|
-
const projectedHoverCoord = useHoverInfoForTooltip ? viewInfo?.project(hoverCoord) : null;
|
|
269197
|
-
let yOffset = -30;
|
|
269198
|
-
return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [projectedHoverCoord && imageLayerScopes?.map((layerScope) => {
|
|
269199
|
-
const { pixelHighlight, tooltipsVisible, spatialLayerVisible } = imageLayerCoordination?.[0]?.[layerScope] || {};
|
|
269200
|
-
return tooltipsVisible && pixelHighlight && spatialLayerVisible ? jsxRuntimeExports.jsx(TooltipChild, { parentUuid, sourceUuid, width: width2, height: height2, info: {
|
|
269201
|
-
"Pixel Value": JSON.stringify(pixelHighlight)
|
|
269202
|
-
}, x: projectedHoverCoord?.[0], y: projectedHoverCoord?.[1] + (yOffset += 30), featureType, featureLabelsMap }, layerScope) : null;
|
|
269203
|
-
}), segmentationLayerScopes?.flatMap((layerScope) => segmentationChannelScopesByLayer?.[layerScope]?.map((channelScope) => {
|
|
269204
|
-
const { obsType, obsHighlight, tooltipsVisible, tooltipCrosshairsVisible, spatialChannelVisible } = segmentationChannelCoordination?.[0]?.[layerScope]?.[channelScope] || {};
|
|
269205
|
-
const obsSetsData = obsSegmentationsSetsData?.[layerScope]?.[channelScope];
|
|
269206
|
-
const obsInfo = getObsInfo(obsSetsData, obsType, obsHighlight);
|
|
269207
|
-
if (!obsHighlight || !spatialChannelVisible || !tooltipsVisible && !tooltipCrosshairsVisible)
|
|
269208
|
-
return null;
|
|
269209
|
-
const { obsIndex, obsLocations } = obsSegmentationsLocations?.[layerScope]?.[channelScope] || {};
|
|
269210
|
-
const xy = getXY(obsHighlight, viewInfo, obsIndex, obsLocations, useHoverInfoForTooltip, projectedHoverCoord);
|
|
269211
|
-
if (!xy)
|
|
269212
|
-
return null;
|
|
269213
|
-
const [x2, y2] = xy;
|
|
269214
|
-
return jsxRuntimeExports.jsx(TooltipChild, { parentUuid, sourceUuid, tooltipsVisible, tooltipCrosshairsVisible, width: width2, height: height2, info: obsInfo, x: x2, y: y2 + (yOffset += 20 + 15 * Object.keys(obsInfo).length), featureType, featureLabelsMap }, `${layerScope}-${channelScope}`);
|
|
269215
|
-
})), spotLayerScopes?.map((layerScope) => {
|
|
269216
|
-
const { obsType, obsHighlight, tooltipsVisible, tooltipCrosshairsVisible, spatialLayerVisible } = spotLayerCoordination?.[0]?.[layerScope] || {};
|
|
269217
|
-
if (!obsHighlight || !spatialLayerVisible || !tooltipsVisible && !tooltipCrosshairsVisible)
|
|
269218
|
-
return null;
|
|
269219
|
-
const { obsIndex, obsSpots: obsLocations } = obsSpots?.[layerScope] || {};
|
|
269220
|
-
const xy = getXY(obsHighlight, viewInfo, obsIndex, obsLocations, useHoverInfoForTooltip, projectedHoverCoord);
|
|
269221
|
-
if (!xy)
|
|
269222
|
-
return null;
|
|
269223
|
-
const [x2, y2] = xy;
|
|
269224
|
-
return jsxRuntimeExports.jsx(TooltipChild, { parentUuid, sourceUuid, tooltipsVisible, tooltipCrosshairsVisible, width: width2, height: height2, info: {
|
|
269225
|
-
[`${capitalize$3(obsType)} ID`]: obsHighlight
|
|
269226
|
-
}, x: x2, y: y2 + (yOffset += 30), featureType, featureLabelsMap }, layerScope);
|
|
269227
|
-
}), pointLayerScopes?.map((layerScope) => {
|
|
269228
|
-
const { obsType, obsHighlight, tooltipsVisible, tooltipCrosshairsVisible, spatialLayerVisible } = pointLayerCoordination?.[0]?.[layerScope] || {};
|
|
269229
|
-
if (!obsHighlight || !spatialLayerVisible || !tooltipsVisible && !tooltipCrosshairsVisible)
|
|
269230
|
-
return null;
|
|
269231
|
-
const { obsIndex, obsPoints: obsLocations } = obsPoints?.[layerScope] || {};
|
|
269232
|
-
const xy = getXY(obsHighlight, viewInfo, obsIndex, obsLocations, useHoverInfoForTooltip, projectedHoverCoord);
|
|
269233
|
-
if (!xy)
|
|
269234
|
-
return null;
|
|
269235
|
-
const [x2, y2] = xy;
|
|
269236
|
-
return jsxRuntimeExports.jsx(TooltipChild, { parentUuid, sourceUuid, tooltipsVisible, tooltipCrosshairsVisible, width: width2, height: height2, info: {
|
|
269237
|
-
[`${capitalize$3(obsType)} ID`]: obsHighlight
|
|
269238
|
-
}, x: x2, y: y2 + (yOffset += 30), featureType, featureLabelsMap }, layerScope);
|
|
269239
|
-
})] });
|
|
269240
|
-
}
|
|
269241
269151
|
class ErrorBoundary2 extends React__default.Component {
|
|
269242
269152
|
constructor(props) {
|
|
269243
269153
|
super(props);
|
|
@@ -269256,10 +269166,15 @@ class ErrorBoundary2 extends React__default.Component {
|
|
|
269256
269166
|
}
|
|
269257
269167
|
}
|
|
269258
269168
|
const LazySpatialThree = React__default.lazy(async () => {
|
|
269259
|
-
const { SpatialWrapper: SpatialWrapper2 } = await import("./index-
|
|
269169
|
+
const { SpatialWrapper: SpatialWrapper2 } = await import("./index-BOwhqbYq.js");
|
|
269260
269170
|
return { default: SpatialWrapper2 };
|
|
269261
269171
|
});
|
|
269262
269172
|
const SpatialThreeAdapter = React__default.forwardRef((props, ref2) => jsxRuntimeExports.jsx("div", { ref: ref2, style: { width: "100%", height: "100%" }, children: jsxRuntimeExports.jsx(ErrorBoundary2, { children: jsxRuntimeExports.jsx(Suspense, { fallback: jsxRuntimeExports.jsx("div", { children: "Loading..." }), children: jsxRuntimeExports.jsx(LazySpatialThree, { ...props }) }) }) }));
|
|
269173
|
+
const LazySpatialAccelerated = React__default.lazy(async () => {
|
|
269174
|
+
const { SpatialWrapper: SpatialWrapper2 } = await import("./index-CNEgNHGE.js");
|
|
269175
|
+
return { default: SpatialWrapper2 };
|
|
269176
|
+
});
|
|
269177
|
+
const SpatialAcceleratedAdapter = React__default.forwardRef((props, ref2) => jsxRuntimeExports.jsx("div", { ref: ref2, style: { width: "100%", height: "100%" }, children: jsxRuntimeExports.jsx(ErrorBoundary2, { children: jsxRuntimeExports.jsx(Suspense, { fallback: jsxRuntimeExports.jsx("div", { children: "Loading..." }), children: jsxRuntimeExports.jsx(LazySpatialAccelerated, { ...props }) }) }) }));
|
|
269263
269178
|
const DEFAULT_VIEW_STATE = {
|
|
269264
269179
|
zoom: 0,
|
|
269265
269180
|
target: [0, 0, 0],
|
|
@@ -269320,7 +269235,8 @@ function SpatialSubscriber(props) {
|
|
|
269320
269235
|
title: title2 = "Spatial",
|
|
269321
269236
|
bitmaskValueIsIndex = false,
|
|
269322
269237
|
// TODO: move to coordination type
|
|
269323
|
-
three: threeFor3d = false
|
|
269238
|
+
three: threeFor3d = false,
|
|
269239
|
+
accelerated: acceleratedFor3d = false
|
|
269324
269240
|
} = props;
|
|
269325
269241
|
const loaders = useLoaders();
|
|
269326
269242
|
const setComponentHover = useSetComponentHover();
|
|
@@ -269421,7 +269337,8 @@ function SpatialSubscriber(props) {
|
|
|
269421
269337
|
CoordinationType$2.SPATIAL_TARGET_C,
|
|
269422
269338
|
CoordinationType$2.SPATIAL_CHANNEL_VISIBLE,
|
|
269423
269339
|
CoordinationType$2.SPATIAL_CHANNEL_COLOR,
|
|
269424
|
-
CoordinationType$2.SPATIAL_CHANNEL_WINDOW
|
|
269340
|
+
CoordinationType$2.SPATIAL_CHANNEL_WINDOW,
|
|
269341
|
+
CoordinationType$2.SPATIAL_MAX_RESOLUTION
|
|
269425
269342
|
], coordinationScopes, coordinationScopesBy, CoordinationType$2.IMAGE_LAYER, CoordinationType$2.IMAGE_CHANNEL);
|
|
269426
269343
|
const spotLayerCoordination = useComplexCoordination([
|
|
269427
269344
|
CoordinationType$2.OBS_TYPE,
|
|
@@ -269459,7 +269376,6 @@ function SpatialSubscriber(props) {
|
|
|
269459
269376
|
CoordinationType$2.LEGEND_VISIBLE
|
|
269460
269377
|
], coordinationScopes, coordinationScopesBy, CoordinationType$2.POINT_LAYER);
|
|
269461
269378
|
const is3dMode = spatialRenderingMode === "3D";
|
|
269462
|
-
const shouldUseThree = threeFor3d && is3dMode;
|
|
269463
269379
|
const [deckWidth, deckHeight, deckRef] = useDeckCanvasSize();
|
|
269464
269380
|
const [threeWidth, threeHeight, threeRef] = useGridItemSize();
|
|
269465
269381
|
const width2 = threeFor3d && deckWidth === void 0 ? threeWidth : deckWidth;
|
|
@@ -269728,138 +269644,22 @@ function SpatialSubscriber(props) {
|
|
|
269728
269644
|
}
|
|
269729
269645
|
}
|
|
269730
269646
|
};
|
|
269731
|
-
return jsxRuntimeExports.jsxs(TitleInfo, { title: title2, info: subtitle, isSpatial: true, urls: urls2, theme, closeButtonVisible, downloadButtonVisible, removeGridComponent, isReady, errors, children: [
|
|
269732
|
-
|
|
269733
|
-
|
|
269734
|
-
|
|
269735
|
-
|
|
269736
|
-
|
|
269737
|
-
|
|
269738
|
-
|
|
269739
|
-
|
|
269740
|
-
|
|
269741
|
-
|
|
269742
|
-
|
|
269743
|
-
|
|
269744
|
-
|
|
269745
|
-
|
|
269746
|
-
|
|
269747
|
-
target: [targetX2, targetY2, targetZ],
|
|
269748
|
-
rotationX,
|
|
269749
|
-
rotationOrbit
|
|
269750
|
-
} : DEFAULT_VIEW_STATE,
|
|
269751
|
-
orbitAxis,
|
|
269752
|
-
spatialAxisFixed,
|
|
269753
|
-
setViewState: isValidViewState ? setViewState : SET_VIEW_STATE_NOOP,
|
|
269754
|
-
originalViewState,
|
|
269755
|
-
spatialRenderingMode,
|
|
269756
|
-
updateViewInfo: setComponentViewInfo,
|
|
269757
|
-
delegateHover,
|
|
269758
|
-
onEntitySelected,
|
|
269759
|
-
// Points
|
|
269760
|
-
obsPoints: obsPointsData,
|
|
269761
|
-
pointLayerScopes,
|
|
269762
|
-
pointLayerCoordination,
|
|
269763
|
-
pointMultiObsLabels: pointMultiObsLabelsData,
|
|
269764
|
-
// Spots
|
|
269765
|
-
obsSpots: obsSpotsData,
|
|
269766
|
-
spotLayerScopes,
|
|
269767
|
-
spotLayerCoordination,
|
|
269768
|
-
obsSpotsSets: obsSpotsSetsData,
|
|
269769
|
-
spotMatrixIndices: spotMultiIndicesData,
|
|
269770
|
-
spotMultiExpressionData: spotMultiExpressionNormData,
|
|
269771
|
-
// Segmentations
|
|
269772
|
-
segmentationLayerScopes,
|
|
269773
|
-
segmentationLayerCoordination,
|
|
269774
|
-
segmentationChannelScopesByLayer,
|
|
269775
|
-
segmentationChannelCoordination,
|
|
269776
|
-
obsSegmentations: obsSegmentationsData,
|
|
269777
|
-
obsSegmentationsLocations: obsSegmentationsLocationsData,
|
|
269778
|
-
obsSegmentationsSets: obsSegmentationsSetsData,
|
|
269779
|
-
segmentationMatrixIndices: segmentationMultiIndicesData,
|
|
269780
|
-
segmentationMultiExpressionData: segmentationMultiExpressionNormData,
|
|
269781
|
-
bitmaskValueIsIndex,
|
|
269782
|
-
// Images
|
|
269783
|
-
images: imageData,
|
|
269784
|
-
imageLayerScopes,
|
|
269785
|
-
imageLayerCoordination,
|
|
269786
|
-
imageChannelScopesByLayer,
|
|
269787
|
-
imageChannelCoordination
|
|
269788
|
-
}) : jsxRuntimeExports.jsx(SpatialWrapper, {
|
|
269789
|
-
ref: deckRef,
|
|
269790
|
-
uuid: uuid2,
|
|
269791
|
-
width: width2,
|
|
269792
|
-
height: height2,
|
|
269793
|
-
theme,
|
|
269794
|
-
hideTools: !isSelectable,
|
|
269795
|
-
// Global view state
|
|
269796
|
-
targetT,
|
|
269797
|
-
targetZ,
|
|
269798
|
-
viewState: isValidViewState ? {
|
|
269799
|
-
zoom: zoom2,
|
|
269800
|
-
target: [targetX2, targetY2, targetZ],
|
|
269801
|
-
rotationX,
|
|
269802
|
-
rotationOrbit
|
|
269803
|
-
} : DEFAULT_VIEW_STATE,
|
|
269804
|
-
orbitAxis,
|
|
269805
|
-
spatialAxisFixed,
|
|
269806
|
-
setViewState: isValidViewState ? setViewState : SET_VIEW_STATE_NOOP,
|
|
269807
|
-
originalViewState,
|
|
269808
|
-
spatialRenderingMode,
|
|
269809
|
-
updateViewInfo: setComponentViewInfo,
|
|
269810
|
-
delegateHover,
|
|
269811
|
-
// Points
|
|
269812
|
-
obsPoints: obsPointsData,
|
|
269813
|
-
pointLayerScopes,
|
|
269814
|
-
pointLayerCoordination,
|
|
269815
|
-
pointMultiObsLabels: pointMultiObsLabelsData,
|
|
269816
|
-
// Spots
|
|
269817
|
-
obsSpots: obsSpotsData,
|
|
269818
|
-
spotLayerScopes,
|
|
269819
|
-
spotLayerCoordination,
|
|
269820
|
-
obsSpotsSets: obsSpotsSetsData,
|
|
269821
|
-
spotMatrixIndices: spotMultiIndicesData,
|
|
269822
|
-
spotMultiExpressionData: spotMultiExpressionNormData,
|
|
269823
|
-
// Segmentations
|
|
269824
|
-
segmentationLayerScopes,
|
|
269825
|
-
segmentationLayerCoordination,
|
|
269826
|
-
segmentationChannelScopesByLayer,
|
|
269827
|
-
segmentationChannelCoordination,
|
|
269828
|
-
obsSegmentations: obsSegmentationsData,
|
|
269829
|
-
obsSegmentationsLocations: obsSegmentationsLocationsData,
|
|
269830
|
-
obsSegmentationsSets: obsSegmentationsSetsData,
|
|
269831
|
-
segmentationMatrixIndices: segmentationMultiIndicesData,
|
|
269832
|
-
segmentationMultiExpressionData: segmentationMultiExpressionNormData,
|
|
269833
|
-
bitmaskValueIsIndex,
|
|
269834
|
-
// Images
|
|
269835
|
-
images: imageData,
|
|
269836
|
-
imageLayerScopes,
|
|
269837
|
-
imageLayerCoordination,
|
|
269838
|
-
imageChannelScopesByLayer,
|
|
269839
|
-
imageChannelCoordination
|
|
269840
|
-
}), !disableTooltip && jsxRuntimeExports.jsx(SpatialTooltipSubscriber, {
|
|
269841
|
-
parentUuid: uuid2,
|
|
269842
|
-
width: width2,
|
|
269843
|
-
height: height2,
|
|
269844
|
-
hoverCoord,
|
|
269845
|
-
// Points
|
|
269846
|
-
obsPoints: obsPointsData,
|
|
269847
|
-
pointLayerScopes,
|
|
269848
|
-
pointLayerCoordination,
|
|
269849
|
-
// Spots
|
|
269850
|
-
obsSpots: obsSpotsData,
|
|
269851
|
-
spotLayerScopes,
|
|
269852
|
-
spotLayerCoordination,
|
|
269853
|
-
// Segmentations
|
|
269854
|
-
obsSegmentationsLocations: obsSegmentationsLocationsData,
|
|
269855
|
-
segmentationLayerScopes,
|
|
269856
|
-
segmentationChannelScopesByLayer,
|
|
269857
|
-
segmentationChannelCoordination,
|
|
269858
|
-
obsSegmentationsSetsData,
|
|
269859
|
-
// Images
|
|
269860
|
-
imageLayerScopes,
|
|
269861
|
-
imageLayerCoordination
|
|
269862
|
-
}), jsxRuntimeExports.jsx(
|
|
269647
|
+
return jsxRuntimeExports.jsxs(TitleInfo, { title: title2, info: subtitle, isSpatial: true, urls: urls2, theme, closeButtonVisible, downloadButtonVisible, removeGridComponent, isReady, errors, children: [is3dMode ? acceleratedFor3d ? jsxRuntimeExports.jsx(SpatialAcceleratedAdapter, { ref: threeRef, uuid: uuid2, width: width2, height: height2, theme, hideTools: !isSelectable, rotation: [rotationX, rotationY, rotationZ], setRotationX, setRotationY, setRotationZ, targetT, targetZ, viewState: isValidViewState ? {
|
|
269648
|
+
zoom: zoom2,
|
|
269649
|
+
target: [targetX2, targetY2, targetZ],
|
|
269650
|
+
rotationX,
|
|
269651
|
+
rotationOrbit
|
|
269652
|
+
} : DEFAULT_VIEW_STATE, orbitAxis, spatialAxisFixed, setViewState: isValidViewState ? setViewState : SET_VIEW_STATE_NOOP, originalViewState, spatialRenderingMode, updateViewInfo: setComponentViewInfo, delegateHover, onEntitySelected, obsPoints: obsPointsData, pointLayerScopes, pointLayerCoordination, pointMultiObsLabels: pointMultiObsLabelsData, obsSpots: obsSpotsData, spotLayerScopes, spotLayerCoordination, obsSpotsSets: obsSpotsSetsData, spotMatrixIndices: spotMultiIndicesData, spotMultiExpressionData: spotMultiExpressionNormData, segmentationLayerScopes, segmentationLayerCoordination, segmentationChannelScopesByLayer, segmentationChannelCoordination, obsSegmentations: obsSegmentationsData, obsSegmentationsLocations: obsSegmentationsLocationsData, obsSegmentationsSets: obsSegmentationsSetsData, segmentationMatrixIndices: segmentationMultiIndicesData, segmentationMultiExpressionData: segmentationMultiExpressionNormData, bitmaskValueIsIndex, images: imageData, imageLayerScopes, imageLayerCoordination, imageChannelScopesByLayer, imageChannelCoordination }) : jsxRuntimeExports.jsx(SpatialThreeAdapter, { ref: threeRef, uuid: uuid2, width: width2, height: height2, theme, hideTools: !isSelectable, rotation: [rotationX, rotationY, rotationZ], setRotationX, setRotationY, setRotationZ, targetT, targetZ, viewState: isValidViewState ? {
|
|
269653
|
+
zoom: zoom2,
|
|
269654
|
+
target: [targetX2, targetY2, targetZ],
|
|
269655
|
+
rotationX,
|
|
269656
|
+
rotationOrbit
|
|
269657
|
+
} : DEFAULT_VIEW_STATE, orbitAxis, spatialAxisFixed, setViewState: isValidViewState ? setViewState : SET_VIEW_STATE_NOOP, originalViewState, spatialRenderingMode, updateViewInfo: setComponentViewInfo, delegateHover, onEntitySelected, obsPoints: obsPointsData, pointLayerScopes, pointLayerCoordination, pointMultiObsLabels: pointMultiObsLabelsData, obsSpots: obsSpotsData, spotLayerScopes, spotLayerCoordination, obsSpotsSets: obsSpotsSetsData, spotMatrixIndices: spotMultiIndicesData, spotMultiExpressionData: spotMultiExpressionNormData, segmentationLayerScopes, segmentationLayerCoordination, segmentationChannelScopesByLayer, segmentationChannelCoordination, obsSegmentations: obsSegmentationsData, obsSegmentationsLocations: obsSegmentationsLocationsData, obsSegmentationsSets: obsSegmentationsSetsData, segmentationMatrixIndices: segmentationMultiIndicesData, segmentationMultiExpressionData: segmentationMultiExpressionNormData, bitmaskValueIsIndex, images: imageData, imageLayerScopes, imageLayerCoordination, imageChannelScopesByLayer, imageChannelCoordination }) : jsxRuntimeExports.jsx(SpatialWrapper, { ref: deckRef, uuid: uuid2, width: width2, height: height2, theme, hideTools: !isSelectable, targetT, targetZ, viewState: isValidViewState ? {
|
|
269658
|
+
zoom: zoom2,
|
|
269659
|
+
target: [targetX2, targetY2, targetZ],
|
|
269660
|
+
rotationX,
|
|
269661
|
+
rotationOrbit
|
|
269662
|
+
} : DEFAULT_VIEW_STATE, orbitAxis, spatialAxisFixed, setViewState: isValidViewState ? setViewState : SET_VIEW_STATE_NOOP, originalViewState, spatialRenderingMode, updateViewInfo: setComponentViewInfo, delegateHover, obsPoints: obsPointsData, pointLayerScopes, pointLayerCoordination, pointMultiObsLabels: pointMultiObsLabelsData, obsSpots: obsSpotsData, spotLayerScopes, spotLayerCoordination, obsSpotsSets: obsSpotsSetsData, spotMatrixIndices: spotMultiIndicesData, spotMultiExpressionData: spotMultiExpressionNormData, segmentationLayerScopes, segmentationLayerCoordination, segmentationChannelScopesByLayer, segmentationChannelCoordination, obsSegmentations: obsSegmentationsData, obsSegmentationsLocations: obsSegmentationsLocationsData, obsSegmentationsSets: obsSegmentationsSetsData, segmentationMatrixIndices: segmentationMultiIndicesData, segmentationMultiExpressionData: segmentationMultiExpressionNormData, bitmaskValueIsIndex, images: imageData, imageLayerScopes, imageLayerCoordination, imageChannelScopesByLayer, imageChannelCoordination }), jsxRuntimeExports.jsx(
|
|
269863
269663
|
MultiLegend,
|
|
269864
269664
|
{
|
|
269865
269665
|
// Fix to dark theme due to black background of spatial plot.
|
|
@@ -270694,11 +270494,11 @@ const Heatmap$1 = forwardRef$1((props, deckRef) => {
|
|
|
270694
270494
|
});
|
|
270695
270495
|
Heatmap$1.displayName = "Heatmap";
|
|
270696
270496
|
function HeatmapTooltipSubscriber(props) {
|
|
270697
|
-
const { parentUuid, width: width2, height: height2, transpose: transpose2, getObsInfo
|
|
270497
|
+
const { parentUuid, width: width2, height: height2, transpose: transpose2, getObsInfo, getFeatureInfo, obsHighlight, featureHighlight, featureType, featureLabelsMap } = props;
|
|
270698
270498
|
const sourceUuid = useComponentHover();
|
|
270699
270499
|
const viewInfo = useComponentViewInfo(parentUuid);
|
|
270700
|
-
const [cellInfo, cellCoord] = obsHighlight &&
|
|
270701
|
-
|
|
270500
|
+
const [cellInfo, cellCoord] = obsHighlight && getObsInfo ? [
|
|
270501
|
+
getObsInfo(obsHighlight),
|
|
270702
270502
|
viewInfo && viewInfo.projectFromId ? viewInfo.projectFromId(obsHighlight, null)[transpose2 ? 0 : 1] : null
|
|
270703
270503
|
] : [null, null];
|
|
270704
270504
|
const [geneInfo, geneCoord] = featureHighlight && getFeatureInfo ? [
|
|
@@ -270806,7 +270606,7 @@ function HeatmapSubscriber(props) {
|
|
|
270806
270606
|
cellSetSelection,
|
|
270807
270607
|
obsIndex
|
|
270808
270608
|
]);
|
|
270809
|
-
const
|
|
270609
|
+
const getObsInfo = useGetObsInfo(observationsLabel, obsLabelsTypes, obsLabelsData, obsSetsMembership);
|
|
270810
270610
|
const getObsMembership = useGetObsMembership(obsSetsMembership);
|
|
270811
270611
|
const getFeatureInfo = useCallback((featureId2) => {
|
|
270812
270612
|
if (featureId2) {
|
|
@@ -270846,7 +270646,7 @@ function HeatmapSubscriber(props) {
|
|
|
270846
270646
|
setTargetY(target2[1]);
|
|
270847
270647
|
}, colormapRange: geneExpressionColormapRange, setColormapRange: setGeneExpressionColormapRange, height: height2, width: width2, theme, uuid: uuid2, uint8ObsFeatureMatrix: uint8ObsFeatureMatrix?.data, cellColors, colormap: geneExpressionColormap, setIsRendering, setCellHighlight, setGeneHighlight, featureLabelsMap, obsIndex, featureIndex, setTrackHighlight, setComponentHover: () => {
|
|
270848
270648
|
setComponentHover(uuid2);
|
|
270849
|
-
}, updateViewInfo: setComponentViewInfo, observationsTitle, variablesTitle, variablesDashes: false, observationsDashes: false, cellColorLabels, useDevicePixels: true, onHeatmapClick, setColorEncoding: setHoveredColorEncoding }), tooltipsVisible && jsxRuntimeExports.jsx(HeatmapTooltipSubscriber, { parentUuid: uuid2, width: width2, height: height2, transpose: transpose2, getObsInfo
|
|
270649
|
+
}, updateViewInfo: setComponentViewInfo, observationsTitle, variablesTitle, variablesDashes: false, observationsDashes: false, cellColorLabels, useDevicePixels: true, onHeatmapClick, setColorEncoding: setHoveredColorEncoding }), tooltipsVisible && jsxRuntimeExports.jsx(HeatmapTooltipSubscriber, { parentUuid: uuid2, width: width2, height: height2, transpose: transpose2, getObsInfo, getFeatureInfo, obsHighlight: cellHighlight, featureHighlight: geneHighlight, featureType, featureLabelsMap }), jsxRuntimeExports.jsx(Legend, { visible: true, theme, featureType, featureValueType, obsColorEncoding: "geneExpression", considerSelections: false, featureSelection: geneSelection, obsSetSelection: cellSetSelection, featureValueColormap: geneExpressionColormap, featureValueColormapRange: geneExpressionColormapRange, extent: obsFeatureMatrixExtent })] });
|
|
270850
270650
|
}
|
|
270851
270651
|
function _classCallCheck(a2, n3) {
|
|
270852
270652
|
if (!(a2 instanceof n3)) throw new TypeError("Cannot call a class as a function");
|
|
@@ -278949,7 +278749,7 @@ const useStyles$c = makeStyles()(() => ({
|
|
|
278949
278749
|
}
|
|
278950
278750
|
}));
|
|
278951
278751
|
function ChannelOptions(props) {
|
|
278952
|
-
const { onRemove: onRemove2, onResetWindowUsingIQR, showValueExtent, setShowValueExtent } = props;
|
|
278752
|
+
const { onRemove: onRemove2, onResetWindowUsingIQR, showValueExtent, setShowValueExtent, numResolutions, spatialMaxResolution, setSpatialMaxResolution } = props;
|
|
278953
278753
|
const [open2, setOpen] = useState(false);
|
|
278954
278754
|
const { classes: classes2 } = useStyles$c();
|
|
278955
278755
|
const { classes: selectClasses2 } = useSelectStyles();
|
|
@@ -278962,7 +278762,7 @@ function ChannelOptions(props) {
|
|
|
278962
278762
|
setShowValueExtent(event2.target.value === "Value Min/Max");
|
|
278963
278763
|
}
|
|
278964
278764
|
const domainTypeId = $bdb11010cef70236$export$f680877a34711e37();
|
|
278965
|
-
return jsxRuntimeExports.jsxs(PopperMenu, { open: open2, setOpen, buttonIcon: jsxRuntimeExports.jsx(MoreVertIcon, { fontSize: "small" }), buttonClassName: classes2.channelMenuButton, containerClassName: menuClasses.imageLayerPopperContainer, placement: "bottom-end", withPaper: true, "aria-label": "Open channel options menu", children: [jsxRuntimeExports.jsxs(MenuItem, { dense: true, disableGutters: true, children: [jsxRuntimeExports.jsx("label", { className: menuClasses.imageLayerMenuLabel, htmlFor: domainTypeId, children: "Slider Extent: " }), jsxRuntimeExports.jsxs(NativeSelect, { onChange: handleDomainTypeChange, value: showValueExtent ? "Value Min/Max" : "Dtype Min/Max", inputProps: { id: domainTypeId, "aria-label": "Slider extent selector" }, classes: { root: selectClasses2.selectRoot }, children: [jsxRuntimeExports.jsx("option", { value: "Value Min/Max", children: "Value Min/Max" }), jsxRuntimeExports.jsx("option", { value: "Dtype Min/Max", children: "Dtype Min/Max" })] })] }), jsxRuntimeExports.jsx(MenuItem, { dense: true, disableGutters: true, component: "button", onClick: onResetWindowUsingIQR, className: classes2.menuItemButton, "aria-label": "Click to use IQR for channel", children: "Reset window using IQR" }), jsxRuntimeExports.jsx(MenuItem, { dense: true, disableGutters: true, component: "button", onClick: handleRemove, className: classes2.menuItemButton, "aria-label": "Click to remove channel", children: "Remove channel" })] });
|
|
278765
|
+
return jsxRuntimeExports.jsxs(PopperMenu, { open: open2, setOpen, buttonIcon: jsxRuntimeExports.jsx(MoreVertIcon, { fontSize: "small" }), buttonClassName: classes2.channelMenuButton, containerClassName: menuClasses.imageLayerPopperContainer, placement: "bottom-end", withPaper: true, "aria-label": "Open channel options menu", children: [jsxRuntimeExports.jsxs(MenuItem, { dense: true, disableGutters: true, children: [jsxRuntimeExports.jsx("label", { className: menuClasses.imageLayerMenuLabel, htmlFor: domainTypeId, children: "Best Resolution: " }), jsxRuntimeExports.jsx(Slider, { value: spatialMaxResolution || 1, valueLabelDisplay: "auto", onChange: (e3, v) => setSpatialMaxResolution(v), min: 1, max: numResolutions - 1, step: 1, orientation: "horizontal" })] }), jsxRuntimeExports.jsxs(MenuItem, { dense: true, disableGutters: true, children: [jsxRuntimeExports.jsx("label", { className: menuClasses.imageLayerMenuLabel, htmlFor: domainTypeId, children: "Slider Extent: " }), jsxRuntimeExports.jsxs(NativeSelect, { onChange: handleDomainTypeChange, value: showValueExtent ? "Value Min/Max" : "Dtype Min/Max", inputProps: { id: domainTypeId, "aria-label": "Slider extent selector" }, classes: { root: selectClasses2.selectRoot }, children: [jsxRuntimeExports.jsx("option", { value: "Value Min/Max", children: "Value Min/Max" }), jsxRuntimeExports.jsx("option", { value: "Dtype Min/Max", children: "Dtype Min/Max" })] })] }), jsxRuntimeExports.jsx(MenuItem, { dense: true, disableGutters: true, component: "button", onClick: onResetWindowUsingIQR, className: classes2.menuItemButton, "aria-label": "Click to use IQR for channel", children: "Reset window using IQR" }), jsxRuntimeExports.jsx(MenuItem, { dense: true, disableGutters: true, component: "button", onClick: handleRemove, className: classes2.menuItemButton, "aria-label": "Click to remove channel", children: "Remove channel" })] });
|
|
278966
278766
|
}
|
|
278967
278767
|
const useStyles$b = makeStyles()(() => ({
|
|
278968
278768
|
channelSlider: {
|
|
@@ -279049,7 +278849,10 @@ function ImageChannelController(props) {
|
|
|
279049
278849
|
// The channel names.
|
|
279050
278850
|
image: image2,
|
|
279051
278851
|
// To get the channel window extent using image metadata.
|
|
279052
|
-
spatialRenderingMode
|
|
278852
|
+
spatialRenderingMode,
|
|
278853
|
+
numResolutions,
|
|
278854
|
+
spatialMaxResolution,
|
|
278855
|
+
setSpatialMaxResolution
|
|
279053
278856
|
} = props;
|
|
279054
278857
|
const removeChannel = useRemoveImageChannelInMetaCoordinationScopes();
|
|
279055
278858
|
const [showValueExtent, setShowValueExtent] = useState(true);
|
|
@@ -279086,7 +278889,7 @@ function ImageChannelController(props) {
|
|
|
279086
278889
|
setWindow2(minMaxDomain);
|
|
279087
278890
|
}
|
|
279088
278891
|
}
|
|
279089
|
-
return jsxRuntimeExports.jsxs(Grid$1, { container: true, direction: "row", justifyContent: "space-between", children: [jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelVisibilityCheckbox, { color: color2, setColor: setColor2, visible, setVisible, disabled: isLoading, theme, colormapOn }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelColorPickerMenu, { color: color2, setColor: setColor2, visible, setVisible, disabled: isLoading, theme, isStaticColor: !colormapOn, palette: VIEWER_PALETTE }) }), jsxRuntimeExports.jsx(Grid$1, { size: 6, children: jsxRuntimeExports.jsx(ChannelSelectionDropdown, { featureIndex, targetC, setTargetC, setWindow: setWindow2, disabled: isLoading }) }), jsxRuntimeExports.jsx(Grid$1, { size: 3, children: jsxRuntimeExports.jsx(ChannelSlider, { image: image2, targetT, targetZ, targetC, window: window2, setWindow: setWindow2, disabled, color: color2, theme, colormapOn, showValueExtent, minMaxDomain }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelOptions, { onRemove: onRemove2, showValueExtent, setShowValueExtent, onResetWindowUsingIQR: handleResetWindowUsingIQR }) })] });
|
|
278892
|
+
return jsxRuntimeExports.jsxs(Grid$1, { container: true, direction: "row", justifyContent: "space-between", children: [jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelVisibilityCheckbox, { color: color2, setColor: setColor2, visible, setVisible, disabled: isLoading, theme, colormapOn }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelColorPickerMenu, { color: color2, setColor: setColor2, visible, setVisible, disabled: isLoading, theme, isStaticColor: !colormapOn, palette: VIEWER_PALETTE }) }), jsxRuntimeExports.jsx(Grid$1, { size: 6, children: jsxRuntimeExports.jsx(ChannelSelectionDropdown, { featureIndex, targetC, setTargetC, setWindow: setWindow2, disabled: isLoading }) }), jsxRuntimeExports.jsx(Grid$1, { size: 3, children: jsxRuntimeExports.jsx(ChannelSlider, { image: image2, targetT, targetZ, targetC, window: window2, setWindow: setWindow2, disabled, color: color2, theme, colormapOn, showValueExtent, minMaxDomain }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ChannelOptions, { onRemove: onRemove2, showValueExtent, setShowValueExtent, onResetWindowUsingIQR: handleResetWindowUsingIQR, numResolutions, spatialMaxResolution, setSpatialMaxResolution }) })] });
|
|
279090
278893
|
}
|
|
279091
278894
|
function DimensionSlider(props) {
|
|
279092
278895
|
const { boundingSlice, sliceValue, setSliceValue, label: label2 } = props;
|
|
@@ -279189,10 +278992,11 @@ function ImageLayerController(props) {
|
|
|
279189
278992
|
const { classes: controllerSectionClasses } = useControllerSectionStyles();
|
|
279190
278993
|
const isMultiChannel = photometricInterpretation !== "RGB";
|
|
279191
278994
|
return jsxRuntimeExports.jsx(Grid$1, { className: controllerSectionClasses.layerControllerGrid, children: jsxRuntimeExports.jsxs(Paper, { elevation: 4, className: controllerSectionClasses.layerControllerRoot, children: [jsxRuntimeExports.jsxs(Grid$1, { container: true, direction: "row", justifyContent: "space-between", children: [jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(Button, { className: menuClasses.imageLayerVisibleButton, onClick: handleVisibleChange, "aria-label": "Toggle layer visibility", children: jsxRuntimeExports.jsx(Visibility, {}) }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1 }), jsxRuntimeExports.jsx(Grid$1, { size: 6, children: jsxRuntimeExports.jsx(Typography, { className: menuClasses.imageLayerName, children: label2 }) }), jsxRuntimeExports.jsx(Grid$1, { size: 2, children: jsxRuntimeExports.jsx(Slider, { value: opacity2, min: 0, max: 1, step: 1e-3, onChange: handleOpacityChange, className: menuClasses.imageLayerOpacitySlider, orientation: "horizontal", "aria-label": `Adjust opacity for layer ${label2}` }) }), jsxRuntimeExports.jsx(Grid$1, { size: 1, children: jsxRuntimeExports.jsx(ImageLayerEllipsisMenu, { colormap, setColormap, photometricInterpretation, setPhotometricInterpretation, spatialTargetResolution, setSpatialTargetResolution, volumetricRenderingAlgorithm, setVolumetricRenderingAlgorithm, spatialLayerTransparentColor, setSpatialLayerTransparentColor, spatialRenderingMode, image: image2, channelScopes, tooltipsVisible, setTooltipsVisible, channelLabelsVisible, setChannelLabelsVisible, channelLabelsOrientation, setChannelLabelsOrientation, channelLabelSize, setChannelLabelSize }) }), jsxRuntimeExports.jsxs(Grid$1, { size: 1, container: true, direction: "row", children: [jsxRuntimeExports.jsx(ImageIcon, { className: classes2.layerTypeImageIcon }), isMultiChannel ? jsxRuntimeExports.jsx(Button, { onClick: handleOpenChange, className: classes2.channelExpansionButton, "aria-label": "Expand or collapse channel controls", children: open2 ? jsxRuntimeExports.jsx(ExpandLess, {}) : jsxRuntimeExports.jsx(ExpandMoreIcon, {}) }) : null] })] }), isMultiChannel && open2 ? jsxRuntimeExports.jsxs(Grid$1, { container: true, direction: "column", justifyContent: "space-between", className: classes2.imageChannelControllerGrid, children: [channelScopes.map((cScope) => {
|
|
279192
|
-
const { spatialTargetC, spatialChannelVisible, spatialChannelOpacity, spatialChannelColor, spatialChannelWindow } = channelCoordination[cScope];
|
|
279193
|
-
const { setSpatialTargetC, setSpatialChannelVisible, setSpatialChannelOpacity, setSpatialChannelColor, setSpatialChannelWindow } = setChannelCoordination[cScope];
|
|
278995
|
+
const { spatialTargetC, spatialChannelVisible, spatialChannelOpacity, spatialChannelColor, spatialChannelWindow, spatialMaxResolution } = channelCoordination[cScope];
|
|
278996
|
+
const { setSpatialTargetC, setSpatialChannelVisible, setSpatialChannelOpacity, setSpatialChannelColor, setSpatialChannelWindow, setSpatialMaxResolution } = setChannelCoordination[cScope];
|
|
279194
278997
|
const channelIndex = image2?.getChannelIndex(spatialTargetC);
|
|
279195
|
-
|
|
278998
|
+
const numResolutions = image2?.getNumResolutions();
|
|
278999
|
+
return jsxRuntimeExports.jsx(ImageChannelController, { theme, coordinationScopesRaw, layerScope, channelScope: cScope, targetT, targetZ, targetC: channelIndex, setTargetC: setSpatialTargetC, visible: spatialChannelVisible, setVisible: setSpatialChannelVisible, opacity: spatialChannelOpacity, setOpacity: setSpatialChannelOpacity, color: spatialChannelColor, setColor: setSpatialChannelColor, window: spatialChannelWindow, setWindow: setSpatialChannelWindow, colormapOn: colormap !== null, featureIndex, image: image2, spatialRenderingMode, numResolutions, spatialMaxResolution, setSpatialMaxResolution }, cScope);
|
|
279196
279000
|
}), jsxRuntimeExports.jsx(Button, { disabled: channelScopes.length === MAX_CHANNELS$1 || channelScopes.length === imageNumChannels, onClick: handleChannelAdd, fullWidth: true, variant: "outlined", className: classes2.imageLayerButton, startIcon: jsxRuntimeExports.jsx(AddIcon, {}), size: "small", "aria-label": "Add a channel to this layer", children: "Add Channel" })] }) : null, is3dMode && image2 ? jsxRuntimeExports.jsxs(Grid$1, { container: true, direction: "column", justifyContent: "space-between", className: classes2.imageChannelControllerGrid, children: [jsxRuntimeExports.jsx(Typography, { className: classes2.clippingPanesLabel, children: "Clipping planes:" }), jsxRuntimeExports.jsx(Grid$1, { size: 12, className: classes2.clippingSliders, children: jsxRuntimeExports.jsx(ClippingSliders, { image: image2, spatialSliceX, spatialSliceY, spatialSliceZ, setSpatialSliceX, setSpatialSliceY, setSpatialSliceZ }) })] }) : null] }) });
|
|
279197
279001
|
}
|
|
279198
279002
|
const useStyles$7 = makeStyles()((theme) => ({
|
|
@@ -279297,7 +279101,8 @@ function LayerControllerSubscriber(props) {
|
|
|
279297
279101
|
CoordinationType$2.SPATIAL_TARGET_C,
|
|
279298
279102
|
CoordinationType$2.SPATIAL_CHANNEL_VISIBLE,
|
|
279299
279103
|
CoordinationType$2.SPATIAL_CHANNEL_COLOR,
|
|
279300
|
-
CoordinationType$2.SPATIAL_CHANNEL_WINDOW
|
|
279104
|
+
CoordinationType$2.SPATIAL_CHANNEL_WINDOW,
|
|
279105
|
+
CoordinationType$2.SPATIAL_MAX_RESOLUTION
|
|
279301
279106
|
], coordinationScopes, coordinationScopesBy, CoordinationType$2.IMAGE_LAYER, CoordinationType$2.IMAGE_CHANNEL);
|
|
279302
279107
|
const spotLayerCoordination = useComplexCoordination([
|
|
279303
279108
|
CoordinationType$2.OBS_TYPE,
|
|
@@ -281337,7 +281142,7 @@ function HiglassGlobalStyles(props) {
|
|
|
281337
281142
|
}
|
|
281338
281143
|
register({ dataFetcher: ZarrMultivecDataFetcher_default, config: ZarrMultivecDataFetcher_default.config }, { pluginType: "dataFetcher" });
|
|
281339
281144
|
const LazyHiGlassComponent = React__default.lazy(async () => {
|
|
281340
|
-
const { HiGlassComponent } = await import("./higlass-
|
|
281145
|
+
const { HiGlassComponent } = await import("./higlass-DhNUWZfQ.js");
|
|
281341
281146
|
return { default: HiGlassComponent };
|
|
281342
281147
|
});
|
|
281343
281148
|
const HG_SIZE = 800;
|
|
@@ -284284,7 +284089,7 @@ function NeuroglancerGlobalStyles(props) {
|
|
|
284284
284089
|
const { classes: classes2 } = props;
|
|
284285
284090
|
return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [jsxRuntimeExports.jsx(GlobalStyles$3, { styles: globalNeuroglancerCss }), jsxRuntimeExports.jsx(ScopedGlobalStyles, { styles: globalNeuroglancerStyles, parentClassName: classes2.neuroglancerWrapper })] });
|
|
284286
284091
|
}
|
|
284287
|
-
const LazyReactNeuroglancer = React__default.lazy(() => import("./ReactNeuroglancer-
|
|
284092
|
+
const LazyReactNeuroglancer = React__default.lazy(() => import("./ReactNeuroglancer-CmQ5YZjK.js"));
|
|
284288
284093
|
function createWorker() {
|
|
284289
284094
|
return new WorkerFactory();
|
|
284290
284095
|
}
|
|
@@ -371775,6 +371580,10 @@ class ImageWrapper {
|
|
|
371775
371580
|
const { labels: labels2, shape: shape2 } = Array.isArray(loader2.data) ? loader2.data[0] : loader2.data;
|
|
371776
371581
|
return shape2[labels2.indexOf("c")];
|
|
371777
371582
|
}
|
|
371583
|
+
getNumResolutions() {
|
|
371584
|
+
const loader2 = this.vivLoader;
|
|
371585
|
+
return Array.isArray(loader2.data) ? loader2.data.length : 1;
|
|
371586
|
+
}
|
|
371778
371587
|
isMultiResolution() {
|
|
371779
371588
|
const loader2 = this.vivLoader;
|
|
371780
371589
|
const hasViewableResolutions = Boolean(Array.from({
|
|
@@ -371785,13 +371594,21 @@ class ImageWrapper {
|
|
|
371785
371594
|
getMultiResolutionStats() {
|
|
371786
371595
|
const loader2 = this.vivLoader;
|
|
371787
371596
|
return Array.from({ length: loader2.data.length }).fill(0).map((_, resolution) => {
|
|
371788
|
-
const { height: height2, width: width2, depthDownsampled, totalBytes } = getStatsForResolution(loader2.data, resolution);
|
|
371597
|
+
const { height: height2, width: width2, depth, depthDownsampled, totalBytes, dims } = getStatsForResolution(loader2.data, resolution);
|
|
371789
371598
|
return {
|
|
371790
371599
|
canLoad: canLoadResolution(loader2.data, resolution),
|
|
371791
371600
|
height: height2,
|
|
371792
371601
|
width: width2,
|
|
371602
|
+
depth,
|
|
371793
371603
|
depthDownsampled,
|
|
371794
|
-
totalBytes
|
|
371604
|
+
totalBytes,
|
|
371605
|
+
dims
|
|
371606
|
+
// chunkHeight
|
|
371607
|
+
// chunkWidth
|
|
371608
|
+
// chunkDepth
|
|
371609
|
+
// physicalSizeVoxel
|
|
371610
|
+
// eslint-disable-next-line max-len
|
|
371611
|
+
// physicalSizeTotal (physicalSizeVoxel * highest-resolution numPixels, for each dimension)
|
|
371795
371612
|
};
|
|
371796
371613
|
});
|
|
371797
371614
|
}
|
|
@@ -387989,7 +387806,11 @@ class SpatialDataShapesSource extends SpatialDataTableSource {
|
|
|
387989
387806
|
*/
|
|
387990
387807
|
// eslint-disable-next-line class-methods-use-this
|
|
387991
387808
|
_isWkbColumn(arrowTable, columnName) {
|
|
387992
|
-
|
|
387809
|
+
const geometryEncodingValue = arrowTable.schema.fields.find((field2) => field2.name === columnName)?.metadata?.get("ARROW:extension:name");
|
|
387810
|
+
if (!geometryEncodingValue) {
|
|
387811
|
+
return true;
|
|
387812
|
+
}
|
|
387813
|
+
return geometryEncodingValue === "geoarrow.wkb";
|
|
387993
387814
|
}
|
|
387994
387815
|
/**
|
|
387995
387816
|
* Helper to decode WKB geometry column as flat coordinates (for points).
|
|
@@ -394338,6 +394159,7 @@ const baseCoordinationTypes = [
|
|
|
394338
394159
|
new PluginCoordinationType(CoordinationType$2.SPATIAL_RENDERING_MODE, "2D", z.enum(["2D", "3D"]).nullable()),
|
|
394339
394160
|
new PluginCoordinationType(CoordinationType$2.VOLUMETRIC_RENDERING_ALGORITHM, "additive", z.enum(["maximumIntensityProjection", "additive"])),
|
|
394340
394161
|
new PluginCoordinationType(CoordinationType$2.SPATIAL_TARGET_RESOLUTION, 0, z.number().nullable()),
|
|
394162
|
+
new PluginCoordinationType(CoordinationType$2.SPATIAL_MAX_RESOLUTION, null, z.number().nullable()),
|
|
394341
394163
|
new PluginCoordinationType(CoordinationType$2.SPATIAL_SLICE_X, null, z.array(z.number()).length(2).nullable()),
|
|
394342
394164
|
new PluginCoordinationType(CoordinationType$2.SPATIAL_SLICE_Y, null, z.array(z.number()).length(2).nullable()),
|
|
394343
394165
|
new PluginCoordinationType(CoordinationType$2.SPATIAL_SLICE_Z, null, z.array(z.number()).length(2).nullable()),
|
|
@@ -396856,201 +396678,209 @@ function decodeURLParamsToConf(queryString) {
|
|
|
396856
396678
|
throw new Error("Unrecognized URL Param Version");
|
|
396857
396679
|
}
|
|
396858
396680
|
export {
|
|
396859
|
-
|
|
396860
|
-
|
|
396861
|
-
|
|
396862
|
-
|
|
396681
|
+
Bone as $,
|
|
396682
|
+
LineSegments as A,
|
|
396683
|
+
BufferAttribute as B,
|
|
396684
|
+
Color as C,
|
|
396863
396685
|
DirectionalLight2 as D,
|
|
396864
|
-
|
|
396686
|
+
Line as E,
|
|
396865
396687
|
FileLoader as F,
|
|
396866
396688
|
Group$1 as G,
|
|
396867
|
-
|
|
396689
|
+
LineLoop as H,
|
|
396868
396690
|
InstancedMesh as I,
|
|
396869
|
-
|
|
396870
|
-
|
|
396871
|
-
|
|
396872
|
-
|
|
396873
|
-
|
|
396874
|
-
|
|
396875
|
-
|
|
396691
|
+
Points as J,
|
|
396692
|
+
PerspectiveCamera as K,
|
|
396693
|
+
Loader as L,
|
|
396694
|
+
Matrix42 as M,
|
|
396695
|
+
NearestMipmapLinearFilter as N,
|
|
396696
|
+
Object3D as O,
|
|
396697
|
+
PointLight2 as P,
|
|
396876
396698
|
Quaternion2 as Q,
|
|
396877
|
-
|
|
396878
|
-
|
|
396879
|
-
|
|
396880
|
-
|
|
396881
|
-
|
|
396882
|
-
|
|
396883
|
-
|
|
396884
|
-
|
|
396885
|
-
|
|
396886
|
-
|
|
396887
|
-
|
|
396888
|
-
|
|
396889
|
-
|
|
396890
|
-
|
|
396891
|
-
|
|
396892
|
-
|
|
396893
|
-
|
|
396894
|
-
|
|
396895
|
-
|
|
396896
|
-
|
|
396897
|
-
|
|
396898
|
-
|
|
396899
|
-
|
|
396900
|
-
|
|
396901
|
-
|
|
396902
|
-
|
|
396903
|
-
|
|
396904
|
-
|
|
396905
|
-
|
|
396906
|
-
|
|
396907
|
-
|
|
396908
|
-
|
|
396909
|
-
|
|
396910
|
-
|
|
396911
|
-
|
|
396912
|
-
|
|
396913
|
-
|
|
396914
|
-
|
|
396915
|
-
|
|
396916
|
-
|
|
396917
|
-
|
|
396918
|
-
|
|
396919
|
-
|
|
396920
|
-
|
|
396921
|
-
|
|
396922
|
-
|
|
396923
|
-
|
|
396924
|
-
|
|
396925
|
-
|
|
396926
|
-
|
|
396927
|
-
|
|
396928
|
-
|
|
396929
|
-
|
|
396930
|
-
|
|
396931
|
-
|
|
396932
|
-
|
|
396933
|
-
|
|
396934
|
-
|
|
396935
|
-
|
|
396936
|
-
|
|
396937
|
-
|
|
396938
|
-
|
|
396939
|
-
|
|
396940
|
-
|
|
396941
|
-
|
|
396942
|
-
|
|
396943
|
-
|
|
396944
|
-
|
|
396945
|
-
|
|
396946
|
-
|
|
396947
|
-
|
|
396948
|
-
|
|
396949
|
-
|
|
396950
|
-
|
|
396951
|
-
|
|
396952
|
-
|
|
396953
|
-
|
|
396954
|
-
|
|
396955
|
-
|
|
396956
|
-
|
|
396957
|
-
|
|
396958
|
-
|
|
396959
|
-
|
|
396960
|
-
|
|
396961
|
-
|
|
396962
|
-
|
|
396963
|
-
|
|
396964
|
-
|
|
396965
|
-
|
|
396966
|
-
|
|
396967
|
-
|
|
396968
|
-
|
|
396969
|
-
|
|
396970
|
-
|
|
396971
|
-
|
|
396972
|
-
|
|
396973
|
-
|
|
396974
|
-
|
|
396975
|
-
|
|
396976
|
-
|
|
396977
|
-
|
|
396978
|
-
|
|
396979
|
-
|
|
396980
|
-
|
|
396981
|
-
|
|
396982
|
-
|
|
396983
|
-
|
|
396984
|
-
|
|
396985
|
-
|
|
396986
|
-
|
|
396987
|
-
|
|
396988
|
-
|
|
396989
|
-
|
|
396990
|
-
|
|
396991
|
-
|
|
396992
|
-
|
|
396993
|
-
|
|
396994
|
-
|
|
396995
|
-
|
|
396996
|
-
|
|
396997
|
-
|
|
396998
|
-
|
|
396999
|
-
|
|
397000
|
-
|
|
397001
|
-
|
|
397002
|
-
|
|
397003
|
-
|
|
397004
|
-
|
|
397005
|
-
|
|
397006
|
-
|
|
397007
|
-
|
|
397008
|
-
|
|
397009
|
-
|
|
397010
|
-
|
|
397011
|
-
|
|
397012
|
-
|
|
397013
|
-
|
|
397014
|
-
|
|
397015
|
-
|
|
397016
|
-
|
|
397017
|
-
|
|
397018
|
-
|
|
397019
|
-
|
|
397020
|
-
|
|
397021
|
-
|
|
397022
|
-
|
|
397023
|
-
|
|
397024
|
-
|
|
397025
|
-
|
|
397026
|
-
|
|
397027
|
-
|
|
397028
|
-
|
|
397029
|
-
|
|
397030
|
-
|
|
397031
|
-
|
|
397032
|
-
|
|
397033
|
-
|
|
397034
|
-
|
|
397035
|
-
|
|
397036
|
-
|
|
397037
|
-
|
|
397038
|
-
|
|
397039
|
-
|
|
397040
|
-
|
|
397041
|
-
|
|
397042
|
-
|
|
397043
|
-
|
|
397044
|
-
|
|
397045
|
-
|
|
397046
|
-
|
|
397047
|
-
|
|
397048
|
-
|
|
397049
|
-
|
|
397050
|
-
|
|
397051
|
-
|
|
397052
|
-
|
|
397053
|
-
|
|
397054
|
-
|
|
397055
|
-
|
|
396699
|
+
REVISION as R,
|
|
396700
|
+
SpotLight as S,
|
|
396701
|
+
TrianglesDrawMode as T,
|
|
396702
|
+
MathUtils as U,
|
|
396703
|
+
Vector22 as V,
|
|
396704
|
+
OrthographicCamera as W,
|
|
396705
|
+
Skeleton as X,
|
|
396706
|
+
InterpolateDiscrete as Y,
|
|
396707
|
+
InterpolateLinear as Z,
|
|
396708
|
+
AnimationClip as _,
|
|
396709
|
+
TriangleFanDrawMode as a,
|
|
396710
|
+
commonjsGlobal$1 as a$,
|
|
396711
|
+
InterleavedBufferAttribute as a0,
|
|
396712
|
+
Texture2 as a1,
|
|
396713
|
+
VectorKeyframeTrack as a2,
|
|
396714
|
+
QuaternionKeyframeTrack as a3,
|
|
396715
|
+
NumberKeyframeTrack as a4,
|
|
396716
|
+
FrontSide as a5,
|
|
396717
|
+
Interpolant as a6,
|
|
396718
|
+
Box3 as a7,
|
|
396719
|
+
Sphere as a8,
|
|
396720
|
+
InstancedBufferGeometry as a9,
|
|
396721
|
+
RedIntegerFormat as aA,
|
|
396722
|
+
UnsignedIntType as aB,
|
|
396723
|
+
LogLevel as aC,
|
|
396724
|
+
WebGLMultipleRenderTargets as aD,
|
|
396725
|
+
RGBAFormat as aE,
|
|
396726
|
+
PlaneGeometry2 as aF,
|
|
396727
|
+
GLSL3 as aG,
|
|
396728
|
+
getDefaultExportFromCjs$1 as aH,
|
|
396729
|
+
Raycaster as aI,
|
|
396730
|
+
PCFSoftShadowMap as aJ,
|
|
396731
|
+
VSMShadowMap as aK,
|
|
396732
|
+
PCFShadowMap as aL,
|
|
396733
|
+
BasicShadowMap as aM,
|
|
396734
|
+
NoToneMapping as aN,
|
|
396735
|
+
ACESFilmicToneMapping as aO,
|
|
396736
|
+
Clock as aP,
|
|
396737
|
+
WebGLRenderer as aQ,
|
|
396738
|
+
Camera as aR,
|
|
396739
|
+
Layers as aS,
|
|
396740
|
+
THREE as aT,
|
|
396741
|
+
EventDispatcher as aU,
|
|
396742
|
+
MOUSE as aV,
|
|
396743
|
+
TOUCH as aW,
|
|
396744
|
+
Spherical as aX,
|
|
396745
|
+
BaseDecoder as aY,
|
|
396746
|
+
LercParameters as aZ,
|
|
396747
|
+
LercAddCompression as a_,
|
|
396748
|
+
Float32BufferAttribute as aa,
|
|
396749
|
+
InstancedInterleavedBuffer as ab,
|
|
396750
|
+
WireframeGeometry as ac,
|
|
396751
|
+
ShaderMaterial as ad,
|
|
396752
|
+
UniformsUtils as ae,
|
|
396753
|
+
UniformsLib as af,
|
|
396754
|
+
Vector42 as ag,
|
|
396755
|
+
Line3 as ah,
|
|
396756
|
+
SphereGeometry2 as ai,
|
|
396757
|
+
_extends$c as aj,
|
|
396758
|
+
Plane2 as ak,
|
|
396759
|
+
Triangle as al,
|
|
396760
|
+
BackSide as am,
|
|
396761
|
+
Ray as an,
|
|
396762
|
+
jsxRuntimeExports as ao,
|
|
396763
|
+
Matrix32 as ap,
|
|
396764
|
+
CoordinationType$2 as aq,
|
|
396765
|
+
Data3DTexture as ar,
|
|
396766
|
+
RedFormat as as,
|
|
396767
|
+
FloatType as at,
|
|
396768
|
+
getImageSize as au,
|
|
396769
|
+
Scene as av,
|
|
396770
|
+
log$c as aw,
|
|
396771
|
+
isEqual$3 as ax,
|
|
396772
|
+
atLeastLogLevel as ay,
|
|
396773
|
+
UnsignedByteType as az,
|
|
396774
|
+
TriangleStripDrawMode as b,
|
|
396775
|
+
CL as b$,
|
|
396776
|
+
requireObjectAssign$1 as b0,
|
|
396777
|
+
earcut as b1,
|
|
396778
|
+
requireAssign as b2,
|
|
396779
|
+
require_export as b3,
|
|
396780
|
+
require_core as b4,
|
|
396781
|
+
require_fails as b5,
|
|
396782
|
+
require_toObject as b6,
|
|
396783
|
+
require_objectKeys as b7,
|
|
396784
|
+
require_cof as b8,
|
|
396785
|
+
require_wks as b9,
|
|
396786
|
+
requireDefineProperty$1 as bA,
|
|
396787
|
+
require_toIobject as bB,
|
|
396788
|
+
require_objectGopd as bC,
|
|
396789
|
+
require_html as bD,
|
|
396790
|
+
require_domCreate as bE,
|
|
396791
|
+
require_library as bF,
|
|
396792
|
+
requireSymbol as bG,
|
|
396793
|
+
require_objectPie as bH,
|
|
396794
|
+
require_has as bI,
|
|
396795
|
+
require_redefine as bJ,
|
|
396796
|
+
require_objectAssign as bK,
|
|
396797
|
+
diffCameraState as bL,
|
|
396798
|
+
MeshDistanceMaterial as bM,
|
|
396799
|
+
MeshDepthMaterial as bN,
|
|
396800
|
+
RGBADepthPacking as bO,
|
|
396801
|
+
ShaderChunk as bP,
|
|
396802
|
+
InstancedBufferAttribute as bQ,
|
|
396803
|
+
encodeConfInUrl as bR,
|
|
396804
|
+
decodeURLParamsToConf as bS,
|
|
396805
|
+
ViewType as bT,
|
|
396806
|
+
DataType$2 as bU,
|
|
396807
|
+
FileType as bV,
|
|
396808
|
+
CoordinationType as bW,
|
|
396809
|
+
CoordinationType$1 as bX,
|
|
396810
|
+
VitessceConfig as bY,
|
|
396811
|
+
vconcat as bZ,
|
|
396812
|
+
hconcat as b_,
|
|
396813
|
+
require_iterators as ba,
|
|
396814
|
+
requireWeb_dom_iterable as bb,
|
|
396815
|
+
requireEs6_string_iterator as bc,
|
|
396816
|
+
require_anObject as bd,
|
|
396817
|
+
require_hide as be,
|
|
396818
|
+
require_ctx as bf,
|
|
396819
|
+
require_toLength as bg,
|
|
396820
|
+
require_global as bh,
|
|
396821
|
+
require_objectDp as bi,
|
|
396822
|
+
require_descriptors as bj,
|
|
396823
|
+
require_isObject as bk,
|
|
396824
|
+
require_objectCreate as bl,
|
|
396825
|
+
require_iterDefine as bm,
|
|
396826
|
+
require_iterStep as bn,
|
|
396827
|
+
require_meta as bo,
|
|
396828
|
+
require_isArray as bp,
|
|
396829
|
+
require_iobject as bq,
|
|
396830
|
+
require_setToStringTag as br,
|
|
396831
|
+
require_aFunction as bs,
|
|
396832
|
+
requireIterator as bt,
|
|
396833
|
+
require_propertyDesc as bu,
|
|
396834
|
+
require_root as bv,
|
|
396835
|
+
require_baseGetTag as bw,
|
|
396836
|
+
requireIsObjectLike as bx,
|
|
396837
|
+
requireIsObject as by,
|
|
396838
|
+
requireEs6_symbol as bz,
|
|
396839
|
+
LoaderUtils as c,
|
|
396840
|
+
getCoordinationSpaceAndScopes as c0,
|
|
396841
|
+
generateConfig as c1,
|
|
396842
|
+
getHintOptions as c2,
|
|
396843
|
+
HINTS_CONFIG as c3,
|
|
396844
|
+
HINT_TYPE_TO_FILE_TYPE_MAP as c4,
|
|
396845
|
+
getInitialCoordinationScopePrefix as c5,
|
|
396846
|
+
getInitialCoordinationScopeName as c6,
|
|
396847
|
+
Vitessce as c7,
|
|
396848
|
+
PluginFileType as c8,
|
|
396849
|
+
PluginViewType as c9,
|
|
396850
|
+
PluginCoordinationType as ca,
|
|
396851
|
+
PluginJointFileType as cb,
|
|
396852
|
+
PluginAsyncFunction as cc,
|
|
396853
|
+
z as cd,
|
|
396854
|
+
useCoordination as ce,
|
|
396855
|
+
useGridItemSize as cf,
|
|
396856
|
+
usePageModeView as cg,
|
|
396857
|
+
useComplexCoordination as ch,
|
|
396858
|
+
useMultiCoordinationScopesNonNull as ci,
|
|
396859
|
+
useMultiCoordinationScopesSecondaryNonNull as cj,
|
|
396860
|
+
useComplexCoordinationSecondary as ck,
|
|
396861
|
+
useCoordinationScopes as cl,
|
|
396862
|
+
useCoordinationScopesBy as cm,
|
|
396863
|
+
MeshPhysicalMaterial as d,
|
|
396864
|
+
Vector32 as e,
|
|
396865
|
+
TextureLoader as f,
|
|
396866
|
+
ImageBitmapLoader as g,
|
|
396867
|
+
InterleavedBuffer as h,
|
|
396868
|
+
LinearMipmapLinearFilter as i,
|
|
396869
|
+
LinearMipmapNearestFilter as j,
|
|
396870
|
+
NearestMipmapNearestFilter as k,
|
|
396871
|
+
LinearFilter as l,
|
|
396872
|
+
NearestFilter as m,
|
|
396873
|
+
RepeatWrapping as n,
|
|
396874
|
+
MirroredRepeatWrapping as o,
|
|
396875
|
+
ClampToEdgeWrapping as p,
|
|
396876
|
+
PointsMaterial as q,
|
|
396877
|
+
Material as r,
|
|
396878
|
+
LineBasicMaterial as s,
|
|
396879
|
+
MeshStandardMaterial as t,
|
|
396880
|
+
DoubleSide as u,
|
|
396881
|
+
MeshBasicMaterial as v,
|
|
396882
|
+
PropertyBinding as w,
|
|
396883
|
+
BufferGeometry as x,
|
|
396884
|
+
SkinnedMesh as y,
|
|
396885
|
+
Mesh as z
|
|
397056
396886
|
};
|