@jbrowse/plugin-data-management 2.16.1 → 2.18.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/AddConnectionWidget/components/AddConnectionWidget.js +3 -5
- package/dist/AddConnectionWidget/components/ConfigureConnection.d.ts +3 -3
- package/dist/AddConnectionWidget/components/ConfigureConnection.js +2 -2
- package/dist/AddConnectionWidget/components/ConnectionTypeSelect.d.ts +1 -1
- package/dist/AddConnectionWidget/components/ConnectionTypeSelect.js +1 -2
- package/dist/AddConnectionWidget/index.d.ts +1 -1
- package/dist/AddConnectionWidget/index.js +1 -1
- package/dist/AddConnectionWidget/model.js +1 -1
- package/dist/AddTrackWidget/components/AddTrackWidget.d.ts +1 -1
- package/dist/AddTrackWidget/components/AddTrackWidget.js +2 -3
- package/dist/AddTrackWidget/components/ConfirmTrack.d.ts +1 -1
- package/dist/AddTrackWidget/components/ConfirmTrack.js +8 -7
- package/dist/AddTrackWidget/components/DefaultAddTrackWorkflow.d.ts +1 -1
- package/dist/AddTrackWidget/components/DefaultAddTrackWorkflow.js +4 -5
- package/dist/AddTrackWidget/components/PasteConfigWorkflow.d.ts +1 -1
- package/dist/AddTrackWidget/components/PasteConfigWorkflow.js +2 -2
- package/dist/AddTrackWidget/components/TextIndexingConfig.d.ts +1 -1
- package/dist/AddTrackWidget/components/TextIndexingConfig.js +33 -32
- package/dist/AddTrackWidget/components/TrackAdapterSelector.d.ts +1 -1
- package/dist/AddTrackWidget/components/TrackAdapterSelector.js +6 -10
- package/dist/AddTrackWidget/components/TrackSourceSelect.d.ts +1 -1
- package/dist/AddTrackWidget/components/TrackSourceSelect.js +2 -2
- package/dist/AddTrackWidget/components/TrackTypeSelector.d.ts +1 -1
- package/dist/AddTrackWidget/components/TrackTypeSelector.js +5 -4
- package/dist/AddTrackWidget/index.d.ts +1 -1
- package/dist/AddTrackWidget/index.js +1 -1
- package/dist/AddTrackWidget/model.d.ts +3 -84
- package/dist/AddTrackWidget/model.js +3 -91
- package/dist/AssemblyManager/AssemblyAddForm.d.ts +4 -4
- package/dist/AssemblyManager/AssemblyAddForm.js +104 -99
- package/dist/AssemblyManager/AssemblyEditor.d.ts +3 -2
- package/dist/AssemblyManager/AssemblyEditor.js +10 -3
- package/dist/AssemblyManager/AssemblyManager.d.ts +4 -3
- package/dist/AssemblyManager/AssemblyManager.js +17 -31
- package/dist/AssemblyManager/AssemblyTable.d.ts +7 -10
- package/dist/AssemblyManager/AssemblyTable.js +53 -34
- package/dist/HierarchicalTrackSelectorWidget/components/HierarchicalFab.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/HierarchicalFab.js +3 -4
- package/dist/HierarchicalTrackSelectorWidget/components/HierarchicalTrackSelector.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/HierarchicalTrackSelector.js +1 -3
- package/dist/HierarchicalTrackSelectorWidget/components/ShoppingCart.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/ShoppingCart.js +3 -4
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/CloseConnectionDialog.js +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/DeleteConnectionDialog.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/DeleteConnectionDialog.js +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.js +4 -5
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/ToggleConnectionsDialog.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/dialogs/ToggleConnectionsDialog.js +3 -3
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetFilter.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetFilter.js +5 -8
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetFilters.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetFilters.js +0 -6
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedDialog.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedDialog.js +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedHeader.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedHeader.js +9 -9
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedSelector.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/faceted/FacetedSelector.js +5 -8
- package/dist/HierarchicalTrackSelectorWidget/components/tree/DropdownTrackSelector.d.ts +3 -3
- package/dist/HierarchicalTrackSelectorWidget/components/tree/DropdownTrackSelector.js +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/tree/FavoriteTracks.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/FavoriteTracks.js +1 -2
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.js +2 -5
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HierarchicalHeader.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HierarchicalHeader.js +10 -9
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HierarchicalTree.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HierarchicalTree.js +2 -14
- package/dist/HierarchicalTrackSelectorWidget/components/tree/RecentlyUsedTracks.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/RecentlyUsedTracks.js +2 -3
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackCategory.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackCategory.js +2 -6
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackLabel.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackLabel.js +2 -4
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackLabelMenu.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackLabelMenu.js +3 -4
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackListNode.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/components/tree/TrackListNode.js +1 -11
- package/dist/HierarchicalTrackSelectorWidget/components/util.d.ts +4 -4
- package/dist/HierarchicalTrackSelectorWidget/components/util.js +0 -1
- package/dist/HierarchicalTrackSelectorWidget/facetedModel.d.ts +1 -61
- package/dist/HierarchicalTrackSelectorWidget/facetedModel.js +12 -74
- package/dist/HierarchicalTrackSelectorWidget/filterTracks.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/generateHierarchy.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/generateHierarchy.js +0 -13
- package/dist/HierarchicalTrackSelectorWidget/index.d.ts +1 -1
- package/dist/HierarchicalTrackSelectorWidget/index.js +3 -3
- package/dist/HierarchicalTrackSelectorWidget/model.d.ts +3 -177
- package/dist/HierarchicalTrackSelectorWidget/model.js +3 -183
- package/dist/HierarchicalTrackSelectorWidget/util.d.ts +2 -2
- package/dist/HierarchicalTrackSelectorWidget/util.js +0 -3
- package/dist/PluginStoreWidget/components/AddCustomPluginDialog.d.ts +1 -1
- package/dist/PluginStoreWidget/components/AddCustomPluginDialog.js +4 -5
- package/dist/PluginStoreWidget/components/DeletePluginDialog.js +1 -2
- package/dist/PluginStoreWidget/components/InstalledPlugin.d.ts +2 -2
- package/dist/PluginStoreWidget/components/InstalledPlugin.js +28 -27
- package/dist/PluginStoreWidget/components/InstalledPluginsList.d.ts +2 -2
- package/dist/PluginStoreWidget/components/InstalledPluginsList.js +1 -1
- package/dist/PluginStoreWidget/components/PluginCard.d.ts +3 -4
- package/dist/PluginStoreWidget/components/PluginCard.js +20 -18
- package/dist/PluginStoreWidget/components/PluginStoreWidget.d.ts +1 -1
- package/dist/PluginStoreWidget/components/PluginStoreWidget.js +32 -26
- package/dist/PluginStoreWidget/components/util.d.ts +1 -1
- package/dist/PluginStoreWidget/components/util.js +0 -1
- package/dist/PluginStoreWidget/index.d.ts +1 -1
- package/dist/PluginStoreWidget/index.js +1 -1
- package/dist/PluginStoreWidget/model.d.ts +2 -8
- package/dist/PluginStoreWidget/model.js +1 -19
- package/dist/{ucsc-trackhub → UCSCTrackHub}/configSchema.d.ts +0 -6
- package/dist/{ucsc-trackhub → UCSCTrackHub}/configSchema.js +2 -14
- package/{esm/ucsc-trackhub → dist/UCSCTrackHub}/doConnect.d.ts +1 -1
- package/dist/{ucsc-trackhub → UCSCTrackHub}/doConnect.js +1 -5
- package/dist/{ucsc-trackhub → UCSCTrackHub}/index.d.ts +1 -1
- package/dist/{ucsc-trackhub → UCSCTrackHub}/index.js +11 -9
- package/dist/{ucsc-trackhub → UCSCTrackHub}/model.d.ts +1 -14
- package/dist/{ucsc-trackhub → UCSCTrackHub}/model.js +1 -16
- package/dist/{ucsc-trackhub → UCSCTrackHub}/ucscAssemblies.js +0 -3
- package/dist/{ucsc-trackhub → UCSCTrackHub}/ucscTrackHub.d.ts +1 -1
- package/dist/{ucsc-trackhub → UCSCTrackHub}/ucscTrackHub.js +1 -15
- package/dist/index.d.ts +9 -9
- package/dist/index.js +4 -4
- package/esm/AddConnectionWidget/components/AddConnectionWidget.js +3 -5
- package/esm/AddConnectionWidget/components/ConfigureConnection.d.ts +3 -3
- package/esm/AddConnectionWidget/components/ConfigureConnection.js +2 -2
- package/esm/AddConnectionWidget/components/ConnectionTypeSelect.d.ts +1 -1
- package/esm/AddConnectionWidget/components/ConnectionTypeSelect.js +1 -2
- package/esm/AddConnectionWidget/index.d.ts +1 -1
- package/esm/AddConnectionWidget/index.js +1 -1
- package/esm/AddConnectionWidget/model.js +1 -1
- package/esm/AddTrackWidget/components/AddTrackWidget.d.ts +1 -1
- package/esm/AddTrackWidget/components/AddTrackWidget.js +2 -3
- package/esm/AddTrackWidget/components/ConfirmTrack.d.ts +1 -1
- package/esm/AddTrackWidget/components/ConfirmTrack.js +8 -7
- package/esm/AddTrackWidget/components/DefaultAddTrackWorkflow.d.ts +1 -1
- package/esm/AddTrackWidget/components/DefaultAddTrackWorkflow.js +4 -5
- package/esm/AddTrackWidget/components/PasteConfigWorkflow.d.ts +1 -1
- package/esm/AddTrackWidget/components/PasteConfigWorkflow.js +2 -2
- package/esm/AddTrackWidget/components/TextIndexingConfig.d.ts +1 -1
- package/esm/AddTrackWidget/components/TextIndexingConfig.js +34 -33
- package/esm/AddTrackWidget/components/TrackAdapterSelector.d.ts +1 -1
- package/esm/AddTrackWidget/components/TrackAdapterSelector.js +6 -10
- package/esm/AddTrackWidget/components/TrackSourceSelect.d.ts +1 -1
- package/esm/AddTrackWidget/components/TrackSourceSelect.js +2 -2
- package/esm/AddTrackWidget/components/TrackTypeSelector.d.ts +1 -1
- package/esm/AddTrackWidget/components/TrackTypeSelector.js +5 -4
- package/esm/AddTrackWidget/index.d.ts +1 -1
- package/esm/AddTrackWidget/index.js +1 -1
- package/esm/AddTrackWidget/model.d.ts +3 -84
- package/esm/AddTrackWidget/model.js +3 -91
- package/esm/AssemblyManager/AssemblyAddForm.d.ts +4 -4
- package/esm/AssemblyManager/AssemblyAddForm.js +104 -96
- package/esm/AssemblyManager/AssemblyEditor.d.ts +3 -2
- package/esm/AssemblyManager/AssemblyEditor.js +10 -3
- package/esm/AssemblyManager/AssemblyManager.d.ts +4 -3
- package/esm/AssemblyManager/AssemblyManager.js +17 -31
- package/esm/AssemblyManager/AssemblyTable.d.ts +7 -10
- package/esm/AssemblyManager/AssemblyTable.js +54 -35
- package/esm/HierarchicalTrackSelectorWidget/components/HierarchicalFab.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/HierarchicalFab.js +3 -4
- package/esm/HierarchicalTrackSelectorWidget/components/HierarchicalTrackSelector.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/HierarchicalTrackSelector.js +1 -3
- package/esm/HierarchicalTrackSelectorWidget/components/ShoppingCart.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/ShoppingCart.js +3 -4
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/CloseConnectionDialog.js +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/DeleteConnectionDialog.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/DeleteConnectionDialog.js +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.js +4 -5
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/ToggleConnectionsDialog.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/ToggleConnectionsDialog.js +3 -3
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetFilter.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetFilter.js +5 -8
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetFilters.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetFilters.js +0 -6
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedDialog.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedDialog.js +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedHeader.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedHeader.js +9 -9
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedSelector.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/faceted/FacetedSelector.js +5 -8
- package/esm/HierarchicalTrackSelectorWidget/components/tree/DropdownTrackSelector.d.ts +3 -3
- package/esm/HierarchicalTrackSelectorWidget/components/tree/DropdownTrackSelector.js +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/tree/FavoriteTracks.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/FavoriteTracks.js +1 -2
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.js +3 -6
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HierarchicalHeader.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HierarchicalHeader.js +10 -9
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HierarchicalTree.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HierarchicalTree.js +3 -15
- package/esm/HierarchicalTrackSelectorWidget/components/tree/RecentlyUsedTracks.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/RecentlyUsedTracks.js +2 -3
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackCategory.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackCategory.js +2 -6
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackLabel.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackLabel.js +2 -4
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackLabelMenu.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackLabelMenu.js +3 -4
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackListNode.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/tree/TrackListNode.js +1 -11
- package/esm/HierarchicalTrackSelectorWidget/components/util.d.ts +4 -4
- package/esm/HierarchicalTrackSelectorWidget/components/util.js +0 -1
- package/esm/HierarchicalTrackSelectorWidget/facetedModel.d.ts +1 -61
- package/esm/HierarchicalTrackSelectorWidget/facetedModel.js +6 -68
- package/esm/HierarchicalTrackSelectorWidget/filterTracks.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/filterTracks.js +1 -1
- package/esm/HierarchicalTrackSelectorWidget/generateHierarchy.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/generateHierarchy.js +1 -14
- package/esm/HierarchicalTrackSelectorWidget/index.d.ts +1 -1
- package/esm/HierarchicalTrackSelectorWidget/index.js +3 -3
- package/esm/HierarchicalTrackSelectorWidget/model.d.ts +3 -177
- package/esm/HierarchicalTrackSelectorWidget/model.js +4 -184
- package/esm/HierarchicalTrackSelectorWidget/util.d.ts +2 -2
- package/esm/HierarchicalTrackSelectorWidget/util.js +1 -4
- package/esm/PluginStoreWidget/components/AddCustomPluginDialog.d.ts +1 -1
- package/esm/PluginStoreWidget/components/AddCustomPluginDialog.js +4 -5
- package/esm/PluginStoreWidget/components/DeletePluginDialog.js +1 -2
- package/esm/PluginStoreWidget/components/InstalledPlugin.d.ts +2 -2
- package/esm/PluginStoreWidget/components/InstalledPlugin.js +29 -28
- package/esm/PluginStoreWidget/components/InstalledPluginsList.d.ts +2 -2
- package/esm/PluginStoreWidget/components/InstalledPluginsList.js +1 -1
- package/esm/PluginStoreWidget/components/PluginCard.d.ts +3 -4
- package/esm/PluginStoreWidget/components/PluginCard.js +22 -20
- package/esm/PluginStoreWidget/components/PluginStoreWidget.d.ts +1 -1
- package/esm/PluginStoreWidget/components/PluginStoreWidget.js +33 -27
- package/esm/PluginStoreWidget/components/util.d.ts +1 -1
- package/esm/PluginStoreWidget/components/util.js +1 -2
- package/esm/PluginStoreWidget/index.d.ts +1 -1
- package/esm/PluginStoreWidget/index.js +1 -1
- package/esm/PluginStoreWidget/model.d.ts +2 -8
- package/esm/PluginStoreWidget/model.js +1 -19
- package/esm/{ucsc-trackhub → UCSCTrackHub}/configSchema.d.ts +0 -6
- package/esm/{ucsc-trackhub → UCSCTrackHub}/configSchema.js +2 -14
- package/{dist/ucsc-trackhub → esm/UCSCTrackHub}/doConnect.d.ts +1 -1
- package/esm/{ucsc-trackhub → UCSCTrackHub}/doConnect.js +1 -5
- package/esm/{ucsc-trackhub → UCSCTrackHub}/index.d.ts +1 -1
- package/esm/UCSCTrackHub/index.js +15 -0
- package/esm/{ucsc-trackhub → UCSCTrackHub}/model.d.ts +1 -14
- package/esm/{ucsc-trackhub → UCSCTrackHub}/model.js +1 -16
- package/esm/{ucsc-trackhub → UCSCTrackHub}/ucscAssemblies.js +0 -3
- package/esm/{ucsc-trackhub → UCSCTrackHub}/ucscTrackHub.d.ts +1 -1
- package/esm/{ucsc-trackhub → UCSCTrackHub}/ucscTrackHub.js +2 -16
- package/esm/index.d.ts +9 -9
- package/esm/index.js +3 -3
- package/package.json +2 -2
- package/esm/ucsc-trackhub/index.js +0 -13
- /package/dist/{ucsc-trackhub → UCSCTrackHub}/ucscAssemblies.d.ts +0 -0
- /package/esm/{ucsc-trackhub → UCSCTrackHub}/ucscAssemblies.d.ts +0 -0
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import ClearIcon from '@mui/icons-material/Clear';
|
|
2
3
|
import { IconButton, InputAdornment, TextField } from '@mui/material';
|
|
3
|
-
import { makeStyles } from 'tss-react/mui';
|
|
4
4
|
import { observer } from 'mobx-react';
|
|
5
|
-
|
|
6
|
-
import ClearIcon from '@mui/icons-material/Clear';
|
|
5
|
+
import { makeStyles } from 'tss-react/mui';
|
|
7
6
|
import HamburgerMenu from './HamburgerMenu';
|
|
8
7
|
import ShoppingCart from '../ShoppingCart';
|
|
9
8
|
import FavoriteTracks from './FavoriteTracks';
|
|
@@ -18,12 +17,14 @@ const SearchTracksTextField = observer(function ({ model, }) {
|
|
|
18
17
|
const { classes } = useStyles();
|
|
19
18
|
return (React.createElement(TextField, { className: classes.searchBox, label: "Filter tracks", value: filterText, onChange: event => {
|
|
20
19
|
model.setFilterText(event.target.value);
|
|
21
|
-
}, fullWidth: true,
|
|
22
|
-
|
|
23
|
-
React.createElement(
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
20
|
+
}, fullWidth: true, slotProps: {
|
|
21
|
+
input: {
|
|
22
|
+
endAdornment: (React.createElement(InputAdornment, { position: "end" },
|
|
23
|
+
React.createElement(IconButton, { onClick: () => {
|
|
24
|
+
model.clearFilterText();
|
|
25
|
+
} },
|
|
26
|
+
React.createElement(ClearIcon, null)))),
|
|
27
|
+
},
|
|
27
28
|
} }));
|
|
28
29
|
});
|
|
29
30
|
const HierarchicalTrackSelectorHeader = observer(function ({ model, setHeaderHeight, }) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { TreeNode } from '../../generateHierarchy';
|
|
3
|
-
import { HierarchicalTrackSelectorModel } from '../../model';
|
|
2
|
+
import type { TreeNode } from '../../generateHierarchy';
|
|
3
|
+
import type { HierarchicalTrackSelectorModel } from '../../model';
|
|
4
4
|
declare const HierarchicalTree: ({ height, tree, model, }: {
|
|
5
5
|
height: number;
|
|
6
6
|
tree: TreeNode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React, { useCallback, useMemo, useRef
|
|
1
|
+
import React, { useCallback, useEffect, useMemo, useRef } from 'react';
|
|
2
|
+
import { getSession } from '@jbrowse/core/util';
|
|
2
3
|
import { observer } from 'mobx-react';
|
|
3
4
|
import { VariableSizeTree } from 'react-vtree';
|
|
4
|
-
import { getSession } from '@jbrowse/core/util';
|
|
5
5
|
import Node from './TrackListNode';
|
|
6
6
|
function getNodeData(node, nestingLevel, extra, selection) {
|
|
7
7
|
const isLeaf = node.type === 'track';
|
|
@@ -20,9 +20,6 @@ function getNodeData(node, nestingLevel, extra, selection) {
|
|
|
20
20
|
node,
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
|
-
// this is the main tree component for the hierarchical track selector in note:
|
|
24
|
-
// in jbrowse-web the toolbar is position="sticky" which means the autosizer
|
|
25
|
-
// includes the height of the toolbar, so we subtract the given offsets
|
|
26
23
|
const HierarchicalTree = observer(function HierarchicalTree({ height, tree, model, }) {
|
|
27
24
|
const { filterText, selection, view } = model;
|
|
28
25
|
const treeRef = useRef(null);
|
|
@@ -43,27 +40,18 @@ const HierarchicalTree = observer(function HierarchicalTree({ height, tree, mode
|
|
|
43
40
|
model,
|
|
44
41
|
drawerPosition,
|
|
45
42
|
}), [view, model, drawerPosition, tree]);
|
|
46
|
-
|
|
47
|
-
// some typescript examples that could help
|
|
48
|
-
const treeWalker = useCallback(
|
|
49
|
-
// @ts-expect-error
|
|
50
|
-
function* treeWalker() {
|
|
43
|
+
const treeWalker = useCallback(function* treeWalker() {
|
|
51
44
|
for (const child of tree.children) {
|
|
52
45
|
yield getNodeData(child, 0, extra, obj);
|
|
53
46
|
}
|
|
54
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
55
47
|
while (true) {
|
|
56
|
-
// @ts-expect-error
|
|
57
48
|
const parentMeta = yield;
|
|
58
|
-
// @ts-expect-error
|
|
59
49
|
for (const curr of parentMeta.node.children) {
|
|
60
50
|
yield getNodeData(curr, parentMeta.nestingLevel + 1, extra, obj);
|
|
61
51
|
}
|
|
62
52
|
}
|
|
63
53
|
}, [tree, extra, obj]);
|
|
64
|
-
/* biome-ignore lint/correctness/useExhaustiveDependencies: */
|
|
65
54
|
useEffect(() => {
|
|
66
|
-
// @ts-expect-error
|
|
67
55
|
treeRef.current.recomputeTree({
|
|
68
56
|
refreshNodes: true,
|
|
69
57
|
useDefaultHeight: true,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { HierarchicalTrackSelectorModel } from '../../model';
|
|
2
|
+
import type { HierarchicalTrackSelectorModel } from '../../model';
|
|
3
3
|
declare const RecentlyUsedTracks: ({ model, }: {
|
|
4
4
|
model: HierarchicalTrackSelectorModel;
|
|
5
5
|
}) => React.JSX.Element | null;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import HistoryIcon from '@mui/icons-material/History';
|
|
2
3
|
import { Badge, Tooltip } from '@mui/material';
|
|
3
4
|
import { observer } from 'mobx-react';
|
|
4
|
-
// icons
|
|
5
|
-
import HistoryIcon from '@mui/icons-material/History';
|
|
6
|
-
import DropdownTrackSelector from './DropdownTrackSelector';
|
|
7
5
|
import { makeStyles } from 'tss-react/mui';
|
|
6
|
+
import DropdownTrackSelector from './DropdownTrackSelector';
|
|
8
7
|
const useStyles = makeStyles()({
|
|
9
8
|
smallBadge: {
|
|
10
9
|
height: 14,
|
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
-
import { IconButton, Typography } from '@mui/material';
|
|
3
|
-
import { makeStyles } from 'tss-react/mui';
|
|
4
2
|
import JBrowseMenu from '@jbrowse/core/ui/Menu';
|
|
5
|
-
// icons
|
|
6
3
|
import ArrowDropDownIcon from '@mui/icons-material/ArrowDropDown';
|
|
7
4
|
import ArrowRightIcon from '@mui/icons-material/ArrowRight';
|
|
8
5
|
import MoreHorizIcon from '@mui/icons-material/MoreHoriz';
|
|
9
|
-
|
|
6
|
+
import { IconButton, Typography } from '@mui/material';
|
|
7
|
+
import { makeStyles } from 'tss-react/mui';
|
|
10
8
|
import { getAllChildren, treeToMap } from '../util';
|
|
11
9
|
const useStyles = makeStyles()(theme => ({
|
|
12
10
|
contrastColor: {
|
|
13
11
|
color: theme.palette.tertiary.contrastText,
|
|
14
12
|
},
|
|
15
|
-
// margin:auto 0 to center text vertically
|
|
16
13
|
accordionText: {
|
|
17
14
|
margin: 'auto 0',
|
|
18
|
-
// width 100 so you can click anywhere on the category bar
|
|
19
15
|
width: '100%',
|
|
20
16
|
},
|
|
21
17
|
}));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { NodeData } from '../util';
|
|
3
|
+
import type { AnyConfigurationModel } from '@jbrowse/core/configuration';
|
|
4
4
|
export interface InfoArgs {
|
|
5
5
|
target: HTMLElement;
|
|
6
6
|
id: string;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { readConfObject } from '@jbrowse/core/configuration';
|
|
3
|
+
import SanitizedHTML from '@jbrowse/core/ui/SanitizedHTML';
|
|
2
4
|
import { Checkbox, FormControlLabel, Tooltip } from '@mui/material';
|
|
3
5
|
import { makeStyles } from 'tss-react/mui';
|
|
4
|
-
import SanitizedHTML from '@jbrowse/core/ui/SanitizedHTML';
|
|
5
|
-
import { readConfObject, } from '@jbrowse/core/configuration';
|
|
6
|
-
// locals
|
|
7
6
|
import { isUnsupported } from '../util';
|
|
8
7
|
import TrackLabelMenu from './TrackLabelMenu';
|
|
9
8
|
const useStyles = makeStyles()(theme => ({
|
|
@@ -29,7 +28,6 @@ export default function TrackLabel({ data }) {
|
|
|
29
28
|
React.createElement(FormControlLabel, { className: classes.checkboxLabel, control: React.createElement(Checkbox, { className: classes.compactCheckbox, checked: checked, onChange: () => {
|
|
30
29
|
onChange(trackId);
|
|
31
30
|
}, disabled: isUnsupported(name), inputProps: {
|
|
32
|
-
// @ts-expect-error
|
|
33
31
|
'data-testid': `htsTrackEntry-${id}`,
|
|
34
32
|
} }), label: React.createElement("div", { "data-testid": `htsTrackLabel-${id}`, style: { background: selected ? '#cccc' : undefined } },
|
|
35
33
|
React.createElement(SanitizedHTML, { html: name })) })),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import type { HierarchicalTrackSelectorModel } from '../../model';
|
|
3
|
+
import type { AnyConfigurationModel } from '@jbrowse/core/configuration';
|
|
4
4
|
declare const TrackLabelMenu: ({ id, trackId, stopPropagation, model, setOpen, conf, }: {
|
|
5
5
|
id: string;
|
|
6
6
|
trackId: string;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { makeStyles } from 'tss-react/mui';
|
|
3
|
-
import { getSession } from '@jbrowse/core/util';
|
|
4
2
|
import CascadingMenuButton from '@jbrowse/core/ui/CascadingMenuButton';
|
|
5
|
-
|
|
3
|
+
import { getSession } from '@jbrowse/core/util';
|
|
6
4
|
import MoreHorizIcon from '@mui/icons-material/MoreHoriz';
|
|
7
|
-
import StarIcon from '@mui/icons-material/StarBorderOutlined';
|
|
8
5
|
import FilledStarIcon from '@mui/icons-material/Star';
|
|
6
|
+
import StarIcon from '@mui/icons-material/StarBorderOutlined';
|
|
7
|
+
import { makeStyles } from 'tss-react/mui';
|
|
9
8
|
const useStyles = makeStyles()({
|
|
10
9
|
cascadingStyle: {
|
|
11
10
|
padding: 0,
|
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { makeStyles } from 'tss-react/mui';
|
|
3
|
-
// locals
|
|
4
3
|
import Category from './TrackCategory';
|
|
5
4
|
import TrackLabel from './TrackLabel';
|
|
6
5
|
const useStyles = makeStyles()(theme => ({
|
|
7
|
-
// this accordionBase element's small padding is used to give a margin to
|
|
8
|
-
// accordionColor it a "margin" because the virtualized elements can't really
|
|
9
|
-
// use margin in a conventional way (it doesn't affect layout)
|
|
10
6
|
accordionBase: {
|
|
11
7
|
display: 'flex',
|
|
12
8
|
},
|
|
@@ -19,8 +15,6 @@ const useStyles = makeStyles()(theme => ({
|
|
|
19
15
|
position: 'absolute',
|
|
20
16
|
borderLeft: '1.5px solid #555',
|
|
21
17
|
},
|
|
22
|
-
// accordionColor set's display:flex so that the child accordionText use
|
|
23
|
-
// vertically centered text
|
|
24
18
|
accordionColor: {
|
|
25
19
|
background: theme.palette.tertiary.main,
|
|
26
20
|
color: theme.palette.tertiary.contrastText,
|
|
@@ -29,17 +23,13 @@ const useStyles = makeStyles()(theme => ({
|
|
|
29
23
|
paddingLeft: 5,
|
|
30
24
|
},
|
|
31
25
|
}));
|
|
32
|
-
// An individual node in the track selector. Note: manually sets cursor:
|
|
33
|
-
// pointer improves usability for what can be clicked
|
|
34
26
|
export default function Node({ data, isOpen, style, setOpen, }) {
|
|
35
27
|
const { isLeaf, nestingLevel } = data;
|
|
36
28
|
const { classes } = useStyles();
|
|
37
29
|
const width = 10;
|
|
38
30
|
const marginLeft = nestingLevel * width + (isLeaf ? width : 0);
|
|
39
31
|
return (React.createElement("div", { style: style, className: !isLeaf ? classes.accordionBase : undefined },
|
|
40
|
-
new Array(nestingLevel).fill(0).map((_, idx) => (React.createElement("div", {
|
|
41
|
-
/* biome-ignore lint/suspicious/noArrayIndexKey: */
|
|
42
|
-
key: `mark-${idx}`, style: { left: idx * width + 4, height: style === null || style === void 0 ? void 0 : style.height }, className: classes.nestingLevelMarker }))),
|
|
32
|
+
new Array(nestingLevel).fill(0).map((_, idx) => (React.createElement("div", { key: `mark-${idx}`, style: { left: idx * width + 4, height: style === null || style === void 0 ? void 0 : style.height }, className: classes.nestingLevelMarker }))),
|
|
43
33
|
React.createElement("div", { className: !isLeaf ? classes.accordionCard : undefined, style: {
|
|
44
34
|
marginLeft,
|
|
45
35
|
whiteSpace: 'nowrap',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { HierarchicalTrackSelectorModel } from '../model';
|
|
3
|
-
import {
|
|
4
|
-
import { MenuItem } from '@jbrowse/core/ui';
|
|
1
|
+
import type { TreeNode } from '../generateHierarchy';
|
|
2
|
+
import type { HierarchicalTrackSelectorModel } from '../model';
|
|
3
|
+
import type { AnyConfigurationModel } from '@jbrowse/core/configuration';
|
|
4
|
+
import type { MenuItem } from '@jbrowse/core/ui';
|
|
5
5
|
export interface NodeData {
|
|
6
6
|
nestingLevel: number;
|
|
7
7
|
checked: boolean;
|
|
@@ -1,65 +1,23 @@
|
|
|
1
|
-
import { Instance } from 'mobx-state-tree';
|
|
2
|
-
/**
|
|
3
|
-
* #stateModel FacetedModel
|
|
4
|
-
*/
|
|
1
|
+
import type { Instance } from 'mobx-state-tree';
|
|
5
2
|
export declare function facetedStateTreeF(): import("mobx-state-tree").IModelType<{
|
|
6
|
-
/**
|
|
7
|
-
* #property
|
|
8
|
-
*/
|
|
9
3
|
filterText: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
10
|
-
/**
|
|
11
|
-
* #property
|
|
12
|
-
*/
|
|
13
4
|
showSparse: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
14
|
-
/**
|
|
15
|
-
* #property
|
|
16
|
-
*/
|
|
17
5
|
showFilters: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
18
|
-
/**
|
|
19
|
-
* #property
|
|
20
|
-
*/
|
|
21
6
|
showOptions: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
22
|
-
/**
|
|
23
|
-
* #property
|
|
24
|
-
*/
|
|
25
7
|
panelWidth: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
26
8
|
}, {
|
|
27
9
|
visible: Record<string, boolean>;
|
|
28
10
|
useShoppingCart: boolean;
|
|
29
11
|
filters: import("mobx").ObservableMap<string, string[]>;
|
|
30
12
|
} & {
|
|
31
|
-
/**
|
|
32
|
-
* #action
|
|
33
|
-
*/
|
|
34
13
|
setFilter(key: string, value: string[]): void;
|
|
35
|
-
/**
|
|
36
|
-
* #action
|
|
37
|
-
*/
|
|
38
14
|
setPanelWidth(width: number): number;
|
|
39
|
-
/**
|
|
40
|
-
* #action
|
|
41
|
-
*/
|
|
42
15
|
setUseShoppingCart(f: boolean): void;
|
|
43
|
-
/**
|
|
44
|
-
* #action
|
|
45
|
-
*/
|
|
46
16
|
setFilterText(str: string): void;
|
|
47
|
-
/**
|
|
48
|
-
* #action
|
|
49
|
-
*/
|
|
50
17
|
setShowSparse(f: boolean): void;
|
|
51
|
-
/**
|
|
52
|
-
* #action
|
|
53
|
-
*/
|
|
54
18
|
setShowOptions(f: boolean): void;
|
|
55
|
-
/**
|
|
56
|
-
* #action
|
|
57
|
-
*/
|
|
58
19
|
setShowFilters(f: boolean): void;
|
|
59
20
|
} & {
|
|
60
|
-
/**
|
|
61
|
-
* #getter
|
|
62
|
-
*/
|
|
63
21
|
readonly allTrackConfigurations: ({
|
|
64
22
|
[x: string]: any;
|
|
65
23
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
@@ -72,9 +30,6 @@ export declare function facetedStateTreeF(): import("mobx-state-tree").IModelTyp
|
|
|
72
30
|
} & import("mobx-state-tree").IStateTreeNode<import("@jbrowse/core/configuration").AnyConfigurationSchemaType>);
|
|
73
31
|
} & import("mobx-state-tree").IStateTreeNode<import("@jbrowse/core/configuration").AnyConfigurationSchemaType>)[];
|
|
74
32
|
} & {
|
|
75
|
-
/**
|
|
76
|
-
* #getter
|
|
77
|
-
*/
|
|
78
33
|
readonly rows: {
|
|
79
34
|
readonly id: string;
|
|
80
35
|
readonly conf: {
|
|
@@ -95,22 +50,10 @@ export declare function facetedStateTreeF(): import("mobx-state-tree").IModelTyp
|
|
|
95
50
|
readonly metadata: Record<string, unknown>;
|
|
96
51
|
}[];
|
|
97
52
|
} & {
|
|
98
|
-
/**
|
|
99
|
-
* #getter
|
|
100
|
-
*/
|
|
101
53
|
readonly filteredNonMetadataKeys: string[] | readonly ["category", "adapter", "description"];
|
|
102
|
-
/**
|
|
103
|
-
* #getter
|
|
104
|
-
*/
|
|
105
54
|
readonly metadataKeys: string[];
|
|
106
55
|
readonly filteredMetadataKeys: string[];
|
|
107
|
-
/**
|
|
108
|
-
* #getter
|
|
109
|
-
*/
|
|
110
56
|
readonly fields: string[];
|
|
111
|
-
/**
|
|
112
|
-
* #getter
|
|
113
|
-
*/
|
|
114
57
|
readonly filteredRows: {
|
|
115
58
|
readonly id: string;
|
|
116
59
|
readonly conf: {
|
|
@@ -131,9 +74,6 @@ export declare function facetedStateTreeF(): import("mobx-state-tree").IModelTyp
|
|
|
131
74
|
readonly metadata: Record<string, unknown>;
|
|
132
75
|
}[];
|
|
133
76
|
} & {
|
|
134
|
-
/**
|
|
135
|
-
* #action
|
|
136
|
-
*/
|
|
137
77
|
setVisible(args: Record<string, boolean>): void;
|
|
138
78
|
afterAttach(): void;
|
|
139
79
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>;
|
|
@@ -1,37 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { matches } from './util';
|
|
3
|
-
import { readConfObject, } from '@jbrowse/core/configuration';
|
|
4
|
-
import { getTrackName } from '@jbrowse/core/util/tracks';
|
|
1
|
+
import { readConfObject } from '@jbrowse/core/configuration';
|
|
5
2
|
import { getSession, localStorageGetItem } from '@jbrowse/core/util';
|
|
3
|
+
import { getTrackName } from '@jbrowse/core/util/tracks';
|
|
6
4
|
import { autorun, observable } from 'mobx';
|
|
7
|
-
import {
|
|
5
|
+
import { addDisposer, getParent, types } from 'mobx-state-tree';
|
|
8
6
|
import { getRowStr } from './components/faceted/util';
|
|
7
|
+
import { findNonSparseKeys, getRootKeys } from './facetedUtil';
|
|
8
|
+
import { matches } from './util';
|
|
9
9
|
const nonMetadataKeys = ['category', 'adapter', 'description'];
|
|
10
|
-
/**
|
|
11
|
-
* #stateModel FacetedModel
|
|
12
|
-
*/
|
|
13
10
|
export function facetedStateTreeF() {
|
|
14
11
|
return types
|
|
15
12
|
.model('FacetedModel', {
|
|
16
|
-
/**
|
|
17
|
-
* #property
|
|
18
|
-
*/
|
|
19
13
|
filterText: types.optional(types.string, ''),
|
|
20
|
-
/**
|
|
21
|
-
* #property
|
|
22
|
-
*/
|
|
23
14
|
showSparse: types.optional(types.boolean, () => JSON.parse(localStorageGetItem('facet-showSparse') || 'false')),
|
|
24
|
-
/**
|
|
25
|
-
* #property
|
|
26
|
-
*/
|
|
27
15
|
showFilters: types.optional(types.boolean, () => JSON.parse(localStorageGetItem('facet-showFilters') || 'true')),
|
|
28
|
-
/**
|
|
29
|
-
* #property
|
|
30
|
-
*/
|
|
31
16
|
showOptions: types.optional(types.boolean, () => JSON.parse(localStorageGetItem('facet-showTableOptions') || 'false')),
|
|
32
|
-
/**
|
|
33
|
-
* #property
|
|
34
|
-
*/
|
|
35
17
|
panelWidth: types.optional(types.number, () => JSON.parse(localStorageGetItem('facet-panelWidth') || '400')),
|
|
36
18
|
})
|
|
37
19
|
.volatile(() => ({
|
|
@@ -40,62 +22,35 @@ export function facetedStateTreeF() {
|
|
|
40
22
|
filters: observable.map(),
|
|
41
23
|
}))
|
|
42
24
|
.actions(self => ({
|
|
43
|
-
/**
|
|
44
|
-
* #action
|
|
45
|
-
*/
|
|
46
25
|
setFilter(key, value) {
|
|
47
26
|
self.filters.set(key, value);
|
|
48
27
|
},
|
|
49
|
-
/**
|
|
50
|
-
* #action
|
|
51
|
-
*/
|
|
52
28
|
setPanelWidth(width) {
|
|
53
29
|
self.panelWidth = width;
|
|
54
30
|
return self.panelWidth;
|
|
55
31
|
},
|
|
56
|
-
/**
|
|
57
|
-
* #action
|
|
58
|
-
*/
|
|
59
32
|
setUseShoppingCart(f) {
|
|
60
33
|
self.useShoppingCart = f;
|
|
61
34
|
},
|
|
62
|
-
/**
|
|
63
|
-
* #action
|
|
64
|
-
*/
|
|
65
35
|
setFilterText(str) {
|
|
66
36
|
self.filterText = str;
|
|
67
37
|
},
|
|
68
|
-
/**
|
|
69
|
-
* #action
|
|
70
|
-
*/
|
|
71
38
|
setShowSparse(f) {
|
|
72
39
|
self.showSparse = f;
|
|
73
40
|
},
|
|
74
|
-
/**
|
|
75
|
-
* #action
|
|
76
|
-
*/
|
|
77
41
|
setShowOptions(f) {
|
|
78
42
|
self.showOptions = f;
|
|
79
43
|
},
|
|
80
|
-
/**
|
|
81
|
-
* #action
|
|
82
|
-
*/
|
|
83
44
|
setShowFilters(f) {
|
|
84
45
|
self.showFilters = f;
|
|
85
46
|
},
|
|
86
47
|
}))
|
|
87
48
|
.views(self => ({
|
|
88
|
-
/**
|
|
89
|
-
* #getter
|
|
90
|
-
*/
|
|
91
49
|
get allTrackConfigurations() {
|
|
92
50
|
return getParent(self).allTrackConfigurations;
|
|
93
51
|
},
|
|
94
52
|
}))
|
|
95
53
|
.views(self => ({
|
|
96
|
-
/**
|
|
97
|
-
* #getter
|
|
98
|
-
*/
|
|
99
54
|
get rows() {
|
|
100
55
|
const session = getSession(self);
|
|
101
56
|
const { allTrackConfigurations, filterText } = self;
|
|
@@ -116,30 +71,19 @@ export function facetedStateTreeF() {
|
|
|
116
71
|
},
|
|
117
72
|
}))
|
|
118
73
|
.views(self => ({
|
|
119
|
-
/**
|
|
120
|
-
* #getter
|
|
121
|
-
*/
|
|
122
74
|
get filteredNonMetadataKeys() {
|
|
123
75
|
return self.showSparse
|
|
124
76
|
? nonMetadataKeys
|
|
125
77
|
: findNonSparseKeys(nonMetadataKeys, self.rows, (r, f) => r[f]);
|
|
126
78
|
},
|
|
127
|
-
/**
|
|
128
|
-
* #getter
|
|
129
|
-
*/
|
|
130
79
|
get metadataKeys() {
|
|
131
80
|
return [...new Set(self.rows.flatMap(row => getRootKeys(row.metadata)))];
|
|
132
81
|
},
|
|
133
82
|
get filteredMetadataKeys() {
|
|
134
83
|
return self.showSparse
|
|
135
84
|
? this.metadataKeys
|
|
136
|
-
: findNonSparseKeys(this.metadataKeys, self.rows,
|
|
137
|
-
// @ts-expect-error
|
|
138
|
-
(r, f) => r.metadata[f]);
|
|
85
|
+
: findNonSparseKeys(this.metadataKeys, self.rows, (r, f) => r.metadata[f]);
|
|
139
86
|
},
|
|
140
|
-
/**
|
|
141
|
-
* #getter
|
|
142
|
-
*/
|
|
143
87
|
get fields() {
|
|
144
88
|
return [
|
|
145
89
|
'name',
|
|
@@ -147,9 +91,6 @@ export function facetedStateTreeF() {
|
|
|
147
91
|
...this.filteredMetadataKeys.map(m => `metadata.${m}`),
|
|
148
92
|
];
|
|
149
93
|
},
|
|
150
|
-
/**
|
|
151
|
-
* #getter
|
|
152
|
-
*/
|
|
153
94
|
get filteredRows() {
|
|
154
95
|
const arrFilters = [...self.filters.entries()]
|
|
155
96
|
.filter(f => f[1].length > 0)
|
|
@@ -158,9 +99,6 @@ export function facetedStateTreeF() {
|
|
|
158
99
|
},
|
|
159
100
|
}))
|
|
160
101
|
.actions(self => ({
|
|
161
|
-
/**
|
|
162
|
-
* #action
|
|
163
|
-
*/
|
|
164
102
|
setVisible(args) {
|
|
165
103
|
self.visible = args;
|
|
166
104
|
},
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { readConfObject
|
|
1
|
+
import { readConfObject } from '@jbrowse/core/configuration';
|
|
2
2
|
import { getEnv, getSession, notEmpty } from '@jbrowse/core/util';
|
|
3
3
|
import { hasAllOverlap, hasAnyOverlap } from './util';
|
|
4
4
|
export function filterTracks(tracks, self) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AnyConfigurationModel } from '@jbrowse/core/configuration';
|
|
2
|
-
import { MenuItem } from '@jbrowse/core/ui';
|
|
1
|
+
import type { AnyConfigurationModel } from '@jbrowse/core/configuration';
|
|
2
|
+
import type { MenuItem } from '@jbrowse/core/ui';
|
|
3
3
|
export interface TreeTrackNode {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
import { readConfObject
|
|
1
|
+
import { readConfObject } from '@jbrowse/core/configuration';
|
|
2
2
|
import { getSession } from '@jbrowse/core/util';
|
|
3
3
|
import { getTrackName } from '@jbrowse/core/util/tracks';
|
|
4
|
-
// locals
|
|
5
4
|
import { matches } from './util';
|
|
6
5
|
function sortConfs(confs, sortNames, sortCategories) {
|
|
7
|
-
// uses readConfObject instead of getTrackName so that the undefined
|
|
8
|
-
// reference sequence track is sorted to the top
|
|
9
6
|
const ret = confs.map(c => {
|
|
10
7
|
var _a, _b, _c;
|
|
11
8
|
return [
|
|
@@ -20,8 +17,6 @@ function sortConfs(confs, sortNames, sortCategories) {
|
|
|
20
17
|
ret.sort((a, b) => a[1].localeCompare(b[1]));
|
|
21
18
|
}
|
|
22
19
|
if (sortCategories) {
|
|
23
|
-
// sort up to three sub-category levels, harder to code it to go deeper
|
|
24
|
-
// than this and likely rarely used
|
|
25
20
|
ret.sort((a, b) => {
|
|
26
21
|
if (a[2] !== b[2]) {
|
|
27
22
|
return a[2].localeCompare(b[2]);
|
|
@@ -46,18 +41,13 @@ export function generateHierarchy({ model, trackConfs, extra, noCategories, menu
|
|
|
46
41
|
const session = getSession(model);
|
|
47
42
|
const viewTracks = view.tracks;
|
|
48
43
|
const confs = trackConfs.filter(conf => matches(filterText, conf, session));
|
|
49
|
-
// uses getConf
|
|
50
44
|
for (const conf of sortConfs(confs, activeSortTrackNames, activeSortCategories)) {
|
|
51
|
-
// copy the categories since this array can be mutated downstream
|
|
52
45
|
const categories = [...(readConfObject(conf, 'category') || [])];
|
|
53
|
-
// hack where if trackId ends with sessionTrack, then push it to a
|
|
54
|
-
// category that starts with a space to force sort to the top
|
|
55
46
|
if (conf.trackId.endsWith('sessionTrack')) {
|
|
56
47
|
categories.unshift(' Session tracks');
|
|
57
48
|
}
|
|
58
49
|
let currLevel = hierarchy;
|
|
59
50
|
if (!noCategories) {
|
|
60
|
-
// find existing category to put track into or create it
|
|
61
51
|
for (let i = 0; i < categories.length; i++) {
|
|
62
52
|
const category = categories[i];
|
|
63
53
|
const ret = currLevel.children.find(c => c.name === category);
|
|
@@ -81,9 +71,6 @@ export function generateHierarchy({ model, trackConfs, extra, noCategories, menu
|
|
|
81
71
|
}
|
|
82
72
|
}
|
|
83
73
|
}
|
|
84
|
-
// uses splice to try to put all leaf nodes above "category nodes" if you
|
|
85
|
-
// change the splice to a simple push and open
|
|
86
|
-
// test_data/test_order/config.json you will see the weirdness
|
|
87
74
|
const r = currLevel.children.findIndex(elt => elt.children.length);
|
|
88
75
|
const idx = r === -1 ? currLevel.children.length : r;
|
|
89
76
|
currLevel.children.splice(idx, 0, {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import PluginManager from '@jbrowse/core/PluginManager';
|
|
1
|
+
import type PluginManager from '@jbrowse/core/PluginManager';
|
|
2
2
|
export default function HierarchicalTrackSelectorWidgetF(pluginManager: PluginManager): void;
|
|
3
3
|
export { type HierarchicalTrackSelectorModel, default as stateModelFactory, } from './model';
|
|
4
4
|
export { default as configSchema } from './configSchema';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import stateModelFactory from './model';
|
|
2
|
-
import configSchema from './configSchema';
|
|
3
|
-
import { WidgetType } from '@jbrowse/core/pluggableElementTypes';
|
|
4
1
|
import { lazy } from 'react';
|
|
2
|
+
import { WidgetType } from '@jbrowse/core/pluggableElementTypes';
|
|
3
|
+
import configSchema from './configSchema';
|
|
4
|
+
import stateModelFactory from './model';
|
|
5
5
|
export default function HierarchicalTrackSelectorWidgetF(pluginManager) {
|
|
6
6
|
pluginManager.addWidgetType(() => {
|
|
7
7
|
return new WidgetType({
|