@vitessce/vit-s 3.5.7 → 3.5.8

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/src/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  export { VitS } from './VitS.js';
2
+ export { VitSContainer } from './VitSContainer.js';
2
3
  export { TitleInfo } from './TitleInfo.js';
3
4
  export { PopperMenu } from './shared-mui/components.js';
4
5
  // For plugin view types:
@@ -16,6 +17,7 @@ export {
16
17
  useWindowDimensions,
17
18
  useGridItemSize,
18
19
  useExpandedFeatureLabelsMap,
20
+ useColumnNameMapping,
19
21
  } from './hooks.js';
20
22
  export {
21
23
  useCoordinationScopes,
@@ -76,6 +78,11 @@ export {
76
78
  useObsFeatureMatrixData,
77
79
  useFeatureLabelsData,
78
80
  useGenomicProfilesData,
81
+
82
+ useComparisonMetadata,
83
+ useFeatureStatsData,
84
+ useFeatureSetStatsData,
85
+ useObsSetStatsData,
79
86
  } from './data-hooks.js';
80
87
  export {
81
88
  usePointMultiObsLabels,
@@ -1,8 +1,10 @@
1
1
  import React, { useState, useMemo, useCallback } from 'react';
2
2
  import { Responsive, WidthProvider } from 'react-grid-layout-with-lodash';
3
3
  import { isEqual } from 'lodash-es';
4
+ import { ErrorBoundary } from 'react-error-boundary';
4
5
  import { getMaxRows, resolveLayout } from './layout-utils.js';
5
6
  import { PageModeViewContext } from '../contexts.js';
7
+ import { FallbackForView } from '../FallbackForView.js';
6
8
 
7
9
  const ResponsiveGridLayout = WidthProvider(Responsive);
8
10
 
@@ -131,19 +133,21 @@ export function VitessceGridLayout(props) {
131
133
  const Component = getComponent(v.component);
132
134
  return [v.uid, () => (
133
135
  <div key={v.uid} style={{ display: 'flex', flexDirection: 'column', height: '100%' }}>
134
- <Component
135
- {... v.props}
136
- uuid={v.uid}
137
- coordinationScopes={v.coordinationScopes}
138
- coordinationScopesBy={v.coordinationScopesBy}
139
- theme={theme}
140
- removeGridComponent={null}
141
- // Props used by LinkControllerSubscriber:
142
- viewTypes={viewTypes}
143
- fileTypes={fileTypes}
144
- coordinationTypes={coordinationTypes}
145
- stores={stores}
146
- />
136
+ <ErrorBoundary FallbackComponent={FallbackForView}>
137
+ <Component
138
+ {... v.props}
139
+ uuid={v.uid}
140
+ coordinationScopes={v.coordinationScopes}
141
+ coordinationScopesBy={v.coordinationScopesBy}
142
+ theme={theme}
143
+ removeGridComponent={null}
144
+ // Props used by LinkControllerSubscriber:
145
+ viewTypes={viewTypes}
146
+ fileTypes={fileTypes}
147
+ coordinationTypes={coordinationTypes}
148
+ stores={stores}
149
+ />
150
+ </ErrorBoundary>
147
151
  </div>
148
152
  )];
149
153
  }));
@@ -157,19 +161,21 @@ export function VitessceGridLayout(props) {
157
161
  };
158
162
  return (
159
163
  <div key={v.uid}>
160
- <Component
161
- {...v.props}
162
- uuid={v.uid}
163
- coordinationScopes={v.coordinationScopes}
164
- coordinationScopesBy={v.coordinationScopesBy}
165
- theme={theme}
166
- removeGridComponent={removeGridComponent}
167
- // Props used by LinkControllerSubscriber:
168
- viewTypes={viewTypes}
169
- fileTypes={fileTypes}
170
- coordinationTypes={coordinationTypes}
171
- stores={stores}
172
- />
164
+ <ErrorBoundary FallbackComponent={FallbackForView}>
165
+ <Component
166
+ {...v.props}
167
+ uuid={v.uid}
168
+ coordinationScopes={v.coordinationScopes}
169
+ coordinationScopesBy={v.coordinationScopesBy}
170
+ theme={theme}
171
+ removeGridComponent={removeGridComponent}
172
+ // Props used by LinkControllerSubscriber:
173
+ viewTypes={viewTypes}
174
+ fileTypes={fileTypes}
175
+ coordinationTypes={coordinationTypes}
176
+ stores={stores}
177
+ />
178
+ </ErrorBoundary>
173
179
  </div>
174
180
  );
175
181
  }), contextValue];