@jbrowse/core 2.17.0 → 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/BaseFeatureWidget/BaseFeatureDetail/ArrayValue.js +1 -2
- package/BaseFeatureWidget/BaseFeatureDetail/Attributes.js +4 -8
- package/BaseFeatureWidget/BaseFeatureDetail/BaseCard.d.ts +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/BaseCard.js +1 -2
- package/BaseFeatureWidget/BaseFeatureDetail/BasicValue.js +2 -3
- package/BaseFeatureWidget/BaseFeatureDetail/CoreDetails.d.ts +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/CoreDetails.js +2 -3
- package/BaseFeatureWidget/BaseFeatureDetail/DataGridDetails.js +22 -25
- package/BaseFeatureWidget/BaseFeatureDetail/FeatureDetails.d.ts +2 -2
- package/BaseFeatureWidget/BaseFeatureDetail/FeatureDetails.js +6 -8
- package/BaseFeatureWidget/BaseFeatureDetail/Position.d.ts +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/SimpleField.js +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/UriField.js +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/index.d.ts +1 -1
- package/BaseFeatureWidget/BaseFeatureDetail/index.js +1 -7
- package/BaseFeatureWidget/BaseFeatureDetail/util.js +0 -5
- package/BaseFeatureWidget/SequenceFeatureDetails/SequenceFeatureDetails.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/SequenceFeatureDetails.js +0 -7
- package/BaseFeatureWidget/SequenceFeatureDetails/SequenceFeaturePanel.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/SequenceFeaturePanel.js +1 -7
- package/BaseFeatureWidget/SequenceFeatureDetails/SequencePanel.d.ts +3 -3
- package/BaseFeatureWidget/SequenceFeatureDetails/SequencePanel.js +24 -33
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/HelpDialog.js +1 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SequenceDialog.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SequenceDialog.js +3 -4
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SequenceFeatureMenu.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SequenceFeatureMenu.js +3 -6
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SequenceTypeSelector.d.ts +1 -1
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SettingsDialog.d.ts +1 -1
- package/BaseFeatureWidget/SequenceFeatureDetails/dialogs/SettingsDialog.js +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/hooks.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/hooks.js +1 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/model.d.ts +2 -56
- package/BaseFeatureWidget/SequenceFeatureDetails/model.js +1 -56
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/CDNASequence.d.ts +3 -3
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/CDSSequence.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/CDSSequence.js +5 -6
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/GenomicSequence.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/GenomicSequence.js +0 -1
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/ProteinSequence.d.ts +2 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/ProteinSequence.js +0 -2
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/SequenceDisplay.d.ts +1 -1
- package/BaseFeatureWidget/SequenceFeatureDetails/seqtypes/SequenceDisplay.js +1 -3
- package/BaseFeatureWidget/SequenceFeatureDetails/util.js +1 -5
- package/BaseFeatureWidget/stateModelFactory.d.ts +2 -93
- package/BaseFeatureWidget/stateModelFactory.js +3 -73
- package/BaseFeatureWidget/types.d.ts +3 -3
- package/BaseFeatureWidget/util.js +0 -4
- package/CorePlugin.d.ts +1 -1
- package/CorePlugin.js +2 -5
- package/Plugin.d.ts +2 -5
- package/Plugin.js +0 -3
- package/PluginLoader.d.ts +1 -1
- package/PluginLoader.js +2 -19
- package/PluginManager.d.ts +15 -31
- package/PluginManager.js +11 -39
- package/ReExports/DataGrid.js +0 -1
- package/ReExports/list.d.ts +0 -5
- package/ReExports/list.js +0 -5
- package/ReExports/modules.d.ts +22 -20
- package/ReExports/modules.js +16 -25
- package/TextSearch/BaseResults.d.ts +3 -3
- package/TextSearch/TextSearchManager.d.ts +4 -16
- package/TextSearch/TextSearchManager.js +1 -13
- package/assemblyManager/assembly.d.ts +5 -100
- package/assemblyManager/assembly.js +27 -143
- package/assemblyManager/assemblyConfigSchema.d.ts +1 -34
- package/assemblyManager/assemblyConfigSchema.js +12 -46
- package/assemblyManager/assemblyManager.d.ts +7 -57
- package/assemblyManager/assemblyManager.js +2 -57
- package/configuration/configurationSchema.d.ts +4 -4
- package/configuration/configurationSchema.js +2 -14
- package/configuration/configurationSlot.d.ts +1 -12
- package/configuration/configurationSlot.js +2 -32
- package/configuration/index.d.ts +2 -2
- package/configuration/index.js +2 -2
- package/configuration/types.d.ts +2 -3
- package/configuration/util.d.ts +1 -25
- package/configuration/util.js +19 -56
- package/data_adapters/BaseAdapter/BaseAdapter.d.ts +4 -14
- package/data_adapters/BaseAdapter/BaseAdapter.js +1 -10
- package/data_adapters/BaseAdapter/BaseFeatureDataAdapter.d.ts +5 -114
- package/data_adapters/BaseAdapter/BaseFeatureDataAdapter.js +3 -79
- package/data_adapters/BaseAdapter/BaseOptions.d.ts +2 -2
- package/data_adapters/BaseAdapter/BaseRefNameAliasAdapter.d.ts +2 -2
- package/data_adapters/BaseAdapter/BaseSequenceAdapter.d.ts +3 -6
- package/data_adapters/BaseAdapter/BaseTextSearchAdapter.d.ts +3 -3
- package/data_adapters/BaseAdapter/RegionsAdapter.d.ts +3 -3
- package/data_adapters/BaseAdapter/index.d.ts +4 -4
- package/data_adapters/BaseAdapter/types.d.ts +2 -2
- package/data_adapters/BaseAdapter/util.d.ts +6 -6
- package/data_adapters/CytobandAdapter/CytobandAdapter.d.ts +1 -1
- package/data_adapters/CytobandAdapter/CytobandAdapter.js +1 -2
- package/data_adapters/CytobandAdapter/configSchema.d.ts +0 -3
- package/data_adapters/CytobandAdapter/configSchema.js +1 -7
- package/data_adapters/CytobandAdapter/index.d.ts +1 -1
- package/data_adapters/CytobandAdapter/index.js +1 -1
- package/data_adapters/dataAdapterCache.d.ts +4 -21
- package/data_adapters/dataAdapterCache.js +0 -19
- package/package.json +3 -4
- package/pluggableElementTypes/AdapterType.d.ts +2 -2
- package/pluggableElementTypes/AddTrackWorkflowType.d.ts +2 -2
- package/pluggableElementTypes/ConnectionType.d.ts +3 -3
- package/pluggableElementTypes/DisplayType.d.ts +3 -9
- package/pluggableElementTypes/InternetAccountType.d.ts +2 -2
- package/pluggableElementTypes/PluggableElementBase.d.ts +1 -1
- package/pluggableElementTypes/PluggableElementBase.js +2 -2
- package/pluggableElementTypes/RpcMethodType.d.ts +5 -11
- package/pluggableElementTypes/RpcMethodType.js +7 -19
- package/pluggableElementTypes/RpcMethodTypeWithFiltersAndRenameRegions.d.ts +9 -0
- package/pluggableElementTypes/RpcMethodTypeWithFiltersAndRenameRegions.js +35 -0
- package/pluggableElementTypes/TextSearchAdapterType.d.ts +2 -2
- package/pluggableElementTypes/TrackType.d.ts +3 -3
- package/pluggableElementTypes/ViewType.d.ts +3 -3
- package/pluggableElementTypes/WidgetType.d.ts +4 -3
- package/pluggableElementTypes/index.d.ts +11 -11
- package/pluggableElementTypes/models/BaseConnectionModelFactory.d.ts +2 -29
- package/pluggableElementTypes/models/BaseConnectionModelFactory.js +1 -28
- package/pluggableElementTypes/models/BaseDisplayModel.d.ts +3 -83
- package/pluggableElementTypes/models/BaseDisplayModel.js +2 -69
- package/pluggableElementTypes/models/BaseTrackModel.d.ts +4 -46
- package/pluggableElementTypes/models/BaseTrackModel.js +0 -58
- package/pluggableElementTypes/models/BaseViewModel.d.ts +2 -42
- package/pluggableElementTypes/models/BaseViewModel.js +2 -38
- package/pluggableElementTypes/models/InternetAccountModel.d.ts +3 -119
- package/pluggableElementTypes/models/InternetAccountModel.js +3 -123
- package/pluggableElementTypes/models/baseConnectionConfig.d.ts +0 -6
- package/pluggableElementTypes/models/baseConnectionConfig.js +1 -13
- package/pluggableElementTypes/models/baseInternetAccountConfig.d.ts +0 -15
- package/pluggableElementTypes/models/baseInternetAccountConfig.js +1 -23
- package/pluggableElementTypes/models/baseTrackConfig.d.ts +2 -53
- package/pluggableElementTypes/models/baseTrackConfig.js +1 -58
- package/pluggableElementTypes/renderers/BoxRendererType.d.ts +7 -15
- package/pluggableElementTypes/renderers/BoxRendererType.js +3 -14
- package/pluggableElementTypes/renderers/CircularChordRendererType.d.ts +3 -2
- package/pluggableElementTypes/renderers/CircularChordRendererType.js +1 -6
- package/pluggableElementTypes/renderers/ComparativeServerSideRendererType.d.ts +6 -21
- package/pluggableElementTypes/renderers/ComparativeServerSideRendererType.js +2 -25
- package/pluggableElementTypes/renderers/FeatureRendererType.d.ts +5 -47
- package/pluggableElementTypes/renderers/FeatureRendererType.js +15 -68
- package/pluggableElementTypes/renderers/RendererType.d.ts +4 -8
- package/pluggableElementTypes/renderers/RendererType.js +1 -5
- package/pluggableElementTypes/renderers/RpcRenderedSvgGroup.d.ts +2 -2
- package/pluggableElementTypes/renderers/RpcRenderedSvgGroup.js +3 -12
- package/pluggableElementTypes/renderers/ServerSideRenderedContent.d.ts +1 -1
- package/pluggableElementTypes/renderers/ServerSideRenderedContent.js +6 -14
- package/pluggableElementTypes/renderers/ServerSideRendererType.d.ts +9 -49
- package/pluggableElementTypes/renderers/ServerSideRendererType.js +7 -57
- package/pluggableElementTypes/renderers/index.d.ts +1 -1
- package/pluggableElementTypes/renderers/util/serializableFilterChain.js +1 -3
- package/rpc/BaseRpcDriver.d.ts +3 -4
- package/rpc/BaseRpcDriver.js +20 -80
- package/rpc/MainThreadRpcDriver.d.ts +3 -7
- package/rpc/MainThreadRpcDriver.js +0 -5
- package/rpc/RpcManager.d.ts +3 -3
- package/rpc/RpcManager.js +2 -4
- package/rpc/WebWorkerRpcDriver.d.ts +3 -2
- package/rpc/WebWorkerRpcDriver.js +2 -13
- package/rpc/baseRpcConfig.d.ts +0 -3
- package/rpc/baseRpcConfig.js +1 -7
- package/rpc/configSchema.d.ts +0 -6
- package/rpc/configSchema.js +2 -11
- package/rpc/mainThreadRpcConfig.js +1 -7
- package/rpc/methods/CoreFreeResources.d.ts +0 -6
- package/rpc/methods/CoreFreeResources.js +2 -9
- package/rpc/methods/CoreGetFeatureDensityStats.d.ts +4 -5
- package/rpc/methods/CoreGetFeatureDensityStats.js +1 -1
- package/rpc/methods/CoreGetFeatureDetails.d.ts +2 -7
- package/rpc/methods/CoreGetFeatureDetails.js +0 -5
- package/rpc/methods/CoreGetFeatures.d.ts +5 -5
- package/rpc/methods/CoreGetFeatures.js +4 -5
- package/rpc/methods/CoreGetFileInfo.d.ts +1 -2
- package/rpc/methods/CoreGetFileInfo.js +1 -1
- package/rpc/methods/CoreGetMetadata.d.ts +1 -2
- package/rpc/methods/CoreGetMetadata.js +1 -1
- package/rpc/methods/CoreGetRefNames.d.ts +1 -2
- package/rpc/methods/CoreGetRefNames.js +1 -1
- package/rpc/methods/CoreRender.d.ts +2 -6
- package/rpc/methods/CoreRender.js +5 -7
- package/rpc/methods/util.d.ts +3 -3
- package/rpc/methods/util.js +0 -1
- package/rpc/webWorkerRpcConfig.js +1 -7
- package/stories/JBrowseCore.stories.d.ts +1 -1
- package/stories/JBrowseCore.stories.js +3 -3
- package/stories/examples/WithSequencePanel.d.ts +1 -1
- package/stories/examples/WithSequencePanel.js +3 -3
- package/tsconfig.build.tsbuildinfo +1 -1
- package/ui/AppLogo.d.ts +1 -1
- package/ui/AppLogo.js +0 -2
- package/ui/AssemblySelector.d.ts +2 -2
- package/ui/AssemblySelector.js +0 -3
- package/ui/BaseTooltip.js +2 -6
- package/ui/CascadingMenu.d.ts +2 -2
- package/ui/CascadingMenu.js +3 -4
- package/ui/CascadingMenuButton.d.ts +1 -1
- package/ui/CascadingMenuButton.js +1 -1
- package/ui/ColorPicker.js +1 -7
- package/ui/Dialog.d.ts +1 -1
- package/ui/Dialog.js +2 -6
- package/ui/DropDownMenu.d.ts +1 -1
- package/ui/DropDownMenu.js +2 -2
- package/ui/EditableTypography.d.ts +1 -1
- package/ui/EditableTypography.js +1 -5
- package/ui/ErrorBoundary.d.ts +2 -1
- package/ui/ErrorMessage.js +2 -9
- package/ui/ErrorMessageStackTraceDialog.js +2 -10
- package/ui/FactoryResetDialog.js +1 -1
- package/ui/FatalErrorDialog.js +1 -1
- package/ui/FileSelector/FileSelector.d.ts +4 -3
- package/ui/FileSelector/FileSelector.js +40 -40
- package/ui/FileSelector/LocalFileChooser.d.ts +1 -1
- package/ui/FileSelector/LocalFileChooser.js +0 -1
- package/ui/FileSelector/UrlChooser.d.ts +4 -3
- package/ui/FileSelector/UrlChooser.js +5 -3
- package/ui/Icons.d.ts +1 -1
- package/ui/Icons.js +1 -7
- package/ui/LoadingEllipses.d.ts +1 -1
- package/ui/LoadingEllipses.js +3 -3
- package/ui/Menu.d.ts +1 -1
- package/ui/Menu.js +3 -10
- package/ui/MenuButton.d.ts +1 -1
- package/ui/ResizeHandle.js +2 -2
- package/ui/ReturnToImportFormDialog.js +1 -1
- package/ui/SanitizedHTML.js +1 -21
- package/ui/Snackbar.d.ts +2 -2
- package/ui/Snackbar.js +1 -2
- package/ui/SnackbarModel.d.ts +1 -26
- package/ui/SnackbarModel.js +2 -30
- package/ui/colors.d.ts +1 -1
- package/ui/colors.js +1 -1
- package/ui/react-colorful.js +0 -3
- package/ui/theme.d.ts +1 -1
- package/ui/theme.js +0 -40
- package/util/Base1DUtils.d.ts +1 -1
- package/util/Base1DUtils.js +0 -12
- package/util/Base1DViewModel.d.ts +4 -81
- package/util/Base1DViewModel.js +4 -108
- package/util/QuickLRU.js +0 -9
- package/util/TimeTraveller.js +0 -4
- package/util/aborting.d.ts +0 -20
- package/util/aborting.js +0 -31
- package/util/analytics.js +1 -12
- package/util/blockTypes.d.ts +0 -11
- package/util/blockTypes.js +0 -13
- package/util/calculateDynamicBlocks.d.ts +1 -20
- package/util/calculateDynamicBlocks.js +1 -22
- package/util/calculateStaticBlocks.d.ts +2 -2
- package/util/calculateStaticBlocks.js +0 -2
- package/util/color/cssColorsLevel4.js +0 -1
- package/util/color/index.d.ts +0 -19
- package/util/color/index.js +0 -30
- package/util/compositeMap.js +0 -2
- package/util/dedupe.js +0 -1
- package/util/formatFastaStrings.d.ts +0 -13
- package/util/formatFastaStrings.js +0 -13
- package/util/idMaker.d.ts +1 -1
- package/util/idMaker.js +16 -12
- package/util/index.d.ts +16 -164
- package/util/index.js +22 -282
- package/util/io/RemoteFileWithRangeCache.d.ts +3 -2
- package/util/io/RemoteFileWithRangeCache.js +6 -10
- package/util/io/index.d.ts +3 -4
- package/util/io/index.js +3 -17
- package/util/jexl.js +3 -13
- package/util/jexlStrings.d.ts +0 -6
- package/util/jexlStrings.js +0 -8
- package/util/layouts/BaseLayout.d.ts +1 -1
- package/util/layouts/GranularRectLayout.d.ts +1 -17
- package/util/layouts/GranularRectLayout.js +4 -81
- package/util/layouts/MultiLayout.d.ts +1 -6
- package/util/layouts/MultiLayout.js +0 -6
- package/util/layouts/PrecomputedLayout.d.ts +1 -4
- package/util/layouts/PrecomputedLayout.js +0 -5
- package/util/layouts/PrecomputedMultiLayout.js +0 -2
- package/util/layouts/SceneGraph.d.ts +0 -12
- package/util/layouts/SceneGraph.js +0 -13
- package/util/makeAbortableReaction.d.ts +2 -0
- package/util/makeAbortableReaction.js +50 -0
- package/util/map-obj.js +0 -4
- package/util/mst-reflection.d.ts +1 -14
- package/util/mst-reflection.js +1 -28
- package/util/nanoid.js +0 -31
- package/util/nextTick.d.ts +1 -0
- package/util/nextTick.js +6 -0
- package/util/offscreenCanvasPonyfill.d.ts +0 -1
- package/util/offscreenCanvasPonyfill.js +1 -9
- package/util/offscreenCanvasUtils.js +1 -8
- package/util/range.d.ts +0 -25
- package/util/range.js +0 -34
- package/util/rxjs.d.ts +3 -7
- package/util/rxjs.js +2 -9
- package/util/simpleFeature.d.ts +0 -50
- package/util/simpleFeature.js +0 -35
- package/util/stats.d.ts +3 -26
- package/util/stats.js +0 -25
- package/util/stopToken.d.ts +3 -0
- package/util/stopToken.js +29 -0
- package/util/tracks.d.ts +3 -25
- package/util/tracks.js +0 -30
- package/util/types/index.d.ts +14 -30
- package/util/types/index.js +5 -14
- package/util/types/mst.js +0 -9
- package/util/types/util.d.ts +2 -9
- package/util/useMeasure.js +0 -1
- package/util/when.d.ts +1 -15
- package/util/when.js +3 -70
- package/rpc/remoteAbortSignals.d.ts +0 -36
- package/rpc/remoteAbortSignals.js +0 -79
|
@@ -10,11 +10,9 @@ exports.replaceUndefinedWithNull = replaceUndefinedWithNull;
|
|
|
10
10
|
function stitch(subfeats, sequence) {
|
|
11
11
|
return subfeats.map(sub => sequence.slice(sub.start, sub.end)).join('');
|
|
12
12
|
}
|
|
13
|
-
// filter items if they have the same "ID" or location
|
|
14
13
|
function getItemId(feat) {
|
|
15
14
|
return `${feat.start}-${feat.end}`;
|
|
16
15
|
}
|
|
17
|
-
// filters if successive elements share same start/end
|
|
18
16
|
function dedupe(list) {
|
|
19
17
|
return list.filter((item, pos, ary) => !pos || getItemId(item) !== getItemId(ary[pos - 1]));
|
|
20
18
|
}
|
|
@@ -28,7 +26,6 @@ function revlist(list, seqlen) {
|
|
|
28
26
|
.sort((a, b) => a.start - b.start);
|
|
29
27
|
}
|
|
30
28
|
function calculateUTRs(cds, exons) {
|
|
31
|
-
// checking length ensures the .at below are valid
|
|
32
29
|
if (!cds.length) {
|
|
33
30
|
return [];
|
|
34
31
|
}
|
|
@@ -48,7 +45,6 @@ function calculateUTRs(cds, exons) {
|
|
|
48
45
|
].map(elt => ({ ...elt, type: 'three_prime_UTR' }));
|
|
49
46
|
return [...fiveUTRs, ...threeUTRs];
|
|
50
47
|
}
|
|
51
|
-
// calculates UTRs using impliedUTRs logic, but there are no exon subfeatures
|
|
52
48
|
function calculateUTRs2(cds, parentFeat) {
|
|
53
49
|
if (!cds.length) {
|
|
54
50
|
return [];
|
package/CorePlugin.d.ts
CHANGED
package/CorePlugin.js
CHANGED
|
@@ -29,18 +29,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
29
29
|
const react_1 = require("react");
|
|
30
30
|
const BaseFeatureWidget_1 = require("./BaseFeatureWidget");
|
|
31
31
|
const Plugin_1 = __importDefault(require("./Plugin"));
|
|
32
|
-
const coreRpcMethods = __importStar(require("./rpc/coreRpcMethods"));
|
|
33
|
-
const WidgetType_1 = __importDefault(require("./pluggableElementTypes/WidgetType"));
|
|
34
32
|
const CytobandAdapter_1 = __importDefault(require("./data_adapters/CytobandAdapter"));
|
|
35
|
-
|
|
36
|
-
|
|
33
|
+
const WidgetType_1 = __importDefault(require("./pluggableElementTypes/WidgetType"));
|
|
34
|
+
const coreRpcMethods = __importStar(require("./rpc/coreRpcMethods"));
|
|
37
35
|
class CorePlugin extends Plugin_1.default {
|
|
38
36
|
constructor() {
|
|
39
37
|
super(...arguments);
|
|
40
38
|
this.name = 'CorePlugin';
|
|
41
39
|
}
|
|
42
40
|
install(pluginManager) {
|
|
43
|
-
// register all our core rpc methods
|
|
44
41
|
Object.values(coreRpcMethods).forEach(RpcMethod => {
|
|
45
42
|
pluginManager.addRpcMethod(() => new RpcMethod(pluginManager));
|
|
46
43
|
});
|
package/Plugin.d.ts
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
import PluginManager from './PluginManager';
|
|
2
|
-
import { AnyConfigurationSchemaType } from './configuration';
|
|
3
|
-
/**
|
|
4
|
-
* base class for a JBrowse plugin
|
|
5
|
-
*/
|
|
1
|
+
import type PluginManager from './PluginManager';
|
|
2
|
+
import type { AnyConfigurationSchemaType } from './configuration';
|
|
6
3
|
export default abstract class Plugin {
|
|
7
4
|
abstract name: string;
|
|
8
5
|
url?: string;
|
package/Plugin.js
CHANGED
package/PluginLoader.d.ts
CHANGED
package/PluginLoader.js
CHANGED
|
@@ -8,26 +8,17 @@ exports.isESMPluginDefinition = isESMPluginDefinition;
|
|
|
8
8
|
exports.isCJSPluginDefinition = isCJSPluginDefinition;
|
|
9
9
|
exports.pluginDescriptionString = pluginDescriptionString;
|
|
10
10
|
const load_script_1 = __importDefault(require("load-script"));
|
|
11
|
-
// locals
|
|
12
11
|
const Plugin_1 = __importDefault(require("./Plugin"));
|
|
13
12
|
const ReExports_1 = __importDefault(require("./ReExports"));
|
|
14
13
|
const util_1 = require("./util");
|
|
15
14
|
function isUMDPluginDefinition(def) {
|
|
16
|
-
return (
|
|
17
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
18
|
-
(def.umdUrl !== undefined ||
|
|
19
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
15
|
+
return ((def.umdUrl !== undefined ||
|
|
20
16
|
def.url !== undefined ||
|
|
21
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
22
17
|
def.umdLoc !== undefined) &&
|
|
23
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
24
18
|
def.name !== undefined);
|
|
25
19
|
}
|
|
26
20
|
function isESMPluginDefinition(def) {
|
|
27
|
-
return (
|
|
28
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
29
|
-
def.esmUrl !== undefined ||
|
|
30
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
21
|
+
return (def.esmUrl !== undefined ||
|
|
31
22
|
def.esmLoc !== undefined);
|
|
32
23
|
}
|
|
33
24
|
function promisifiedLoadScript(src) {
|
|
@@ -46,16 +37,13 @@ async function loadScript(scriptUrl) {
|
|
|
46
37
|
if (!isInWebWorker()) {
|
|
47
38
|
return promisifiedLoadScript(scriptUrl);
|
|
48
39
|
}
|
|
49
|
-
// @ts-expect-error
|
|
50
40
|
if (globalThis.importScripts) {
|
|
51
|
-
// @ts-expect-error
|
|
52
41
|
await globalThis.importScripts(scriptUrl);
|
|
53
42
|
return;
|
|
54
43
|
}
|
|
55
44
|
throw new Error('cannot figure out how to load external JS scripts in this environment');
|
|
56
45
|
}
|
|
57
46
|
function isCJSPluginDefinition(def) {
|
|
58
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
59
47
|
return def.cjsUrl !== undefined;
|
|
60
48
|
}
|
|
61
49
|
function pluginDescriptionString(pluginDefinition) {
|
|
@@ -102,7 +90,6 @@ class PluginLoader {
|
|
|
102
90
|
throw new Error('No ESM fetcher installed');
|
|
103
91
|
}
|
|
104
92
|
const plugin = await this.fetchESM(parsedUrl.href);
|
|
105
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
106
93
|
if (!plugin) {
|
|
107
94
|
throw new Error(`Could not load ESM plugin: ${parsedUrl}`);
|
|
108
95
|
}
|
|
@@ -123,10 +110,8 @@ class PluginLoader {
|
|
|
123
110
|
await loadScript(parsedUrl.href);
|
|
124
111
|
}
|
|
125
112
|
else {
|
|
126
|
-
// @ts-expect-error
|
|
127
113
|
globalThis[umdName] = { default: Plugin_1.default };
|
|
128
114
|
}
|
|
129
|
-
// @ts-expect-error
|
|
130
115
|
const plugin = globalThis[umdName];
|
|
131
116
|
if (!plugin) {
|
|
132
117
|
throw new Error(`Failed to load UMD bundle for ${moduleName}, ${umdName} is undefined`);
|
|
@@ -150,14 +135,12 @@ class PluginLoader {
|
|
|
150
135
|
else {
|
|
151
136
|
throw new Error(`Could not determine plugin type: ${JSON.stringify(def)}`);
|
|
152
137
|
}
|
|
153
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
154
138
|
if (!plugin.default) {
|
|
155
139
|
throw new Error(`${pluginDescriptionString(def)} does not have a default export, cannot load`);
|
|
156
140
|
}
|
|
157
141
|
return plugin.default;
|
|
158
142
|
}
|
|
159
143
|
installGlobalReExports(target) {
|
|
160
|
-
// @ts-expect-error
|
|
161
144
|
target.JBrowseExports = Object.fromEntries(Object.entries(ReExports_1.default).map(([moduleName, module]) => {
|
|
162
145
|
return [moduleName, module];
|
|
163
146
|
}));
|
package/PluginManager.d.ts
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import
|
|
2
|
-
import PluggableElementBase from './pluggableElementTypes/PluggableElementBase';
|
|
3
|
-
import RendererType from './pluggableElementTypes/renderers/RendererType';
|
|
1
|
+
import ReExports from './ReExports';
|
|
4
2
|
import AdapterType from './pluggableElementTypes/AdapterType';
|
|
5
|
-
import
|
|
6
|
-
import DisplayType from './pluggableElementTypes/DisplayType';
|
|
7
|
-
import ViewType from './pluggableElementTypes/ViewType';
|
|
8
|
-
import WidgetType from './pluggableElementTypes/WidgetType';
|
|
3
|
+
import AddTrackWorkflowType from './pluggableElementTypes/AddTrackWorkflowType';
|
|
9
4
|
import ConnectionType from './pluggableElementTypes/ConnectionType';
|
|
10
|
-
import
|
|
5
|
+
import DisplayType from './pluggableElementTypes/DisplayType';
|
|
11
6
|
import InternetAccountType from './pluggableElementTypes/InternetAccountType';
|
|
7
|
+
import RpcMethodType from './pluggableElementTypes/RpcMethodType';
|
|
12
8
|
import TextSearchAdapterType from './pluggableElementTypes/TextSearchAdapterType';
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import { PluginDefinition } from './PluginLoader';
|
|
9
|
+
import TrackType from './pluggableElementTypes/TrackType';
|
|
10
|
+
import ViewType from './pluggableElementTypes/ViewType';
|
|
11
|
+
import WidgetType from './pluggableElementTypes/WidgetType';
|
|
12
|
+
import RendererType from './pluggableElementTypes/renderers/RendererType';
|
|
13
|
+
import type Plugin from './Plugin';
|
|
14
|
+
import type { PluginDefinition } from './PluginLoader';
|
|
15
|
+
import type { PluggableElementMember, PluggableElementType } from './pluggableElementTypes';
|
|
16
|
+
import type PluggableElementBase from './pluggableElementTypes/PluggableElementBase';
|
|
17
|
+
import type { AbstractRootModel } from './util';
|
|
18
|
+
import type { IAnyModelType, IAnyType } from 'mobx-state-tree';
|
|
19
19
|
declare class PhasedScheduler<PhaseName extends string> {
|
|
20
20
|
phaseCallbacks: Map<PhaseName, Function[]>;
|
|
21
21
|
phaseOrder: PhaseName[];
|
|
@@ -24,7 +24,6 @@ declare class PhasedScheduler<PhaseName extends string> {
|
|
|
24
24
|
run(): void;
|
|
25
25
|
}
|
|
26
26
|
type PluggableElementTypeGroup = 'renderer' | 'adapter' | 'display' | 'track' | 'connection' | 'view' | 'widget' | 'rpc method' | 'internet account' | 'text search adapter' | 'add track workflow';
|
|
27
|
-
/** internal class that holds the info for a certain element type */
|
|
28
27
|
declare class TypeRecord<ElementClass extends PluggableElementBase> {
|
|
29
28
|
typeName: string;
|
|
30
29
|
baseClass: (new (...args: unknown[]) => ElementClass) | (Function & {
|
|
@@ -40,13 +39,6 @@ declare class TypeRecord<ElementClass extends PluggableElementBase> {
|
|
|
40
39
|
all(): ElementClass[];
|
|
41
40
|
}
|
|
42
41
|
type AnyFunction = (...args: any) => any;
|
|
43
|
-
/**
|
|
44
|
-
* free-form string-to-unknown mapping of metadata related to the instance of
|
|
45
|
-
* this plugin. `isCore` is typically set to `Boolean(true)` if the plugin was
|
|
46
|
-
* loaded as part of the "core" set of plugins for this application. Can also
|
|
47
|
-
* use this metadata to stash other things about why the plugin is loaded, such
|
|
48
|
-
* as where it came from, what plugin depends on it, etc.
|
|
49
|
-
*/
|
|
50
42
|
export type PluginMetadata = Record<string, unknown>;
|
|
51
43
|
export interface PluginLoadRecord {
|
|
52
44
|
metadata?: PluginMetadata;
|
|
@@ -100,7 +92,7 @@ export default class PluginManager {
|
|
|
100
92
|
getPlugin(name: string): Plugin | undefined;
|
|
101
93
|
hasPlugin(name: string): boolean;
|
|
102
94
|
createPluggableElements(): this;
|
|
103
|
-
setRootModel(rootModel: AbstractRootModel):
|
|
95
|
+
setRootModel(rootModel: AbstractRootModel): this;
|
|
104
96
|
configure(): this;
|
|
105
97
|
getElementTypeRecord(groupName: PluggableElementTypeGroup): TypeRecord<PluggableElementBase>;
|
|
106
98
|
addElementType(groupName: PluggableElementTypeGroup, creationCallback: (pluginManager: PluginManager) => PluggableElementType): this;
|
|
@@ -113,9 +105,7 @@ export default class PluginManager {
|
|
|
113
105
|
getRpcElements(): RpcMethodType[];
|
|
114
106
|
getDisplayElements(): DisplayType[];
|
|
115
107
|
getAdapterElements(): AdapterType[];
|
|
116
|
-
/** get a MST type for the union of all specified pluggable MST types */
|
|
117
108
|
pluggableMstType(groupName: PluggableElementTypeGroup, fieldName: PluggableElementMember, fallback?: IAnyType): IAnyType;
|
|
118
|
-
/** get a MST type for the union of all specified pluggable config schemas */
|
|
119
109
|
pluggableConfigSchemaType(typeGroup: PluggableElementTypeGroup, fieldName?: PluggableElementMember): IAnyModelType;
|
|
120
110
|
jbrequireCache: Map<any, any>;
|
|
121
111
|
lib: {
|
|
@@ -258,12 +248,6 @@ export default class PluginManager {
|
|
|
258
248
|
};
|
|
259
249
|
};
|
|
260
250
|
load: <FTYPE extends AnyFunction>(lib: FTYPE) => ReturnType<FTYPE>;
|
|
261
|
-
/**
|
|
262
|
-
* Get the re-exported version of the given package name.
|
|
263
|
-
* Throws an error if the package is not re-exported by the plugin manager.
|
|
264
|
-
*
|
|
265
|
-
* @returns the library's default export
|
|
266
|
-
*/
|
|
267
251
|
jbrequire: (lib: keyof typeof ReExports | AnyFunction | {
|
|
268
252
|
default: AnyFunction;
|
|
269
253
|
}) => any;
|
package/PluginManager.js
CHANGED
|
@@ -3,25 +3,22 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
/* eslint-disable @typescript-eslint/no-unsafe-function-type */
|
|
7
6
|
const mobx_state_tree_1 = require("mobx-state-tree");
|
|
8
|
-
const
|
|
7
|
+
const CorePlugin_1 = __importDefault(require("./CorePlugin"));
|
|
8
|
+
const ReExports_1 = __importDefault(require("./ReExports"));
|
|
9
|
+
const configuration_1 = require("./configuration");
|
|
9
10
|
const AdapterType_1 = __importDefault(require("./pluggableElementTypes/AdapterType"));
|
|
10
|
-
const
|
|
11
|
-
const DisplayType_1 = __importDefault(require("./pluggableElementTypes/DisplayType"));
|
|
12
|
-
const ViewType_1 = __importDefault(require("./pluggableElementTypes/ViewType"));
|
|
13
|
-
const WidgetType_1 = __importDefault(require("./pluggableElementTypes/WidgetType"));
|
|
11
|
+
const AddTrackWorkflowType_1 = __importDefault(require("./pluggableElementTypes/AddTrackWorkflowType"));
|
|
14
12
|
const ConnectionType_1 = __importDefault(require("./pluggableElementTypes/ConnectionType"));
|
|
15
|
-
const
|
|
13
|
+
const DisplayType_1 = __importDefault(require("./pluggableElementTypes/DisplayType"));
|
|
16
14
|
const InternetAccountType_1 = __importDefault(require("./pluggableElementTypes/InternetAccountType"));
|
|
15
|
+
const RpcMethodType_1 = __importDefault(require("./pluggableElementTypes/RpcMethodType"));
|
|
17
16
|
const TextSearchAdapterType_1 = __importDefault(require("./pluggableElementTypes/TextSearchAdapterType"));
|
|
18
|
-
const
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
const
|
|
17
|
+
const TrackType_1 = __importDefault(require("./pluggableElementTypes/TrackType"));
|
|
18
|
+
const ViewType_1 = __importDefault(require("./pluggableElementTypes/ViewType"));
|
|
19
|
+
const WidgetType_1 = __importDefault(require("./pluggableElementTypes/WidgetType"));
|
|
20
|
+
const RendererType_1 = __importDefault(require("./pluggableElementTypes/renderers/RendererType"));
|
|
22
21
|
const jexl_1 = __importDefault(require("./util/jexl"));
|
|
23
|
-
// helper class that keeps groups of callbacks that are then run in a specified
|
|
24
|
-
// order by group
|
|
25
22
|
class PhasedScheduler {
|
|
26
23
|
constructor(...phaseOrder) {
|
|
27
24
|
this.phaseCallbacks = new Map();
|
|
@@ -46,7 +43,6 @@ class PhasedScheduler {
|
|
|
46
43
|
});
|
|
47
44
|
}
|
|
48
45
|
}
|
|
49
|
-
/** internal class that holds the info for a certain element type */
|
|
50
46
|
class TypeRecord {
|
|
51
47
|
constructor(typeName, baseClass) {
|
|
52
48
|
this.typeName = typeName;
|
|
@@ -97,16 +93,9 @@ class PluginManager {
|
|
|
97
93
|
}
|
|
98
94
|
return this.jbrequireCache.get(lib);
|
|
99
95
|
};
|
|
100
|
-
/**
|
|
101
|
-
* Get the re-exported version of the given package name.
|
|
102
|
-
* Throws an error if the package is not re-exported by the plugin manager.
|
|
103
|
-
*
|
|
104
|
-
* @returns the library's default export
|
|
105
|
-
*/
|
|
106
96
|
this.jbrequire = (lib) => {
|
|
107
97
|
if (typeof lib === 'string') {
|
|
108
98
|
const pack = this.lib[lib];
|
|
109
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
110
99
|
if (!pack) {
|
|
111
100
|
throw new TypeError(`No jbrequire re-export defined for package '${lib}'. If this package must be shared between plugins, add it to ReExports.js. If it does not need to be shared, just import it normally.`);
|
|
112
101
|
}
|
|
@@ -115,20 +104,17 @@ class PluginManager {
|
|
|
115
104
|
if (typeof lib === 'function') {
|
|
116
105
|
return this.load(lib);
|
|
117
106
|
}
|
|
118
|
-
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
119
107
|
if (lib.default) {
|
|
120
108
|
return this.jbrequire(lib.default);
|
|
121
109
|
}
|
|
122
110
|
throw new TypeError('lib passed to jbrequire must be either a string or a function');
|
|
123
111
|
};
|
|
124
|
-
// add the core plugin
|
|
125
112
|
this.addPlugin({
|
|
126
113
|
plugin: new CorePlugin_1.default(),
|
|
127
114
|
metadata: {
|
|
128
115
|
isCore: true,
|
|
129
116
|
},
|
|
130
117
|
});
|
|
131
|
-
// add all the initial plugins
|
|
132
118
|
initialPlugins.forEach(plugin => {
|
|
133
119
|
this.addPlugin(plugin);
|
|
134
120
|
});
|
|
@@ -146,8 +132,6 @@ class PluginManager {
|
|
|
146
132
|
if (this.configured) {
|
|
147
133
|
throw new Error('JBrowse already configured, cannot add plugins');
|
|
148
134
|
}
|
|
149
|
-
// check for availability of 'install' and 'configure' as a proxy for being
|
|
150
|
-
// an 'instanceof Plugin'
|
|
151
135
|
const [plugin, metadata = {}] = 'install' in load && 'configure' in load
|
|
152
136
|
? [load, {}]
|
|
153
137
|
: [load.plugin, load.metadata];
|
|
@@ -169,8 +153,6 @@ class PluginManager {
|
|
|
169
153
|
return this.getPlugin(name) !== undefined;
|
|
170
154
|
}
|
|
171
155
|
createPluggableElements() {
|
|
172
|
-
// run the creation callbacks for each element type in order.
|
|
173
|
-
// see elementCreationSchedule above for the creation order
|
|
174
156
|
if (this.elementCreationSchedule) {
|
|
175
157
|
this.elementCreationSchedule.run();
|
|
176
158
|
this.elementCreationSchedule = undefined;
|
|
@@ -179,6 +161,7 @@ class PluginManager {
|
|
|
179
161
|
}
|
|
180
162
|
setRootModel(rootModel) {
|
|
181
163
|
this.rootModel = rootModel;
|
|
164
|
+
return this;
|
|
182
165
|
}
|
|
183
166
|
configure() {
|
|
184
167
|
if (this.configured) {
|
|
@@ -263,26 +246,20 @@ class PluginManager {
|
|
|
263
246
|
getAdapterElements() {
|
|
264
247
|
return this.getElementTypesInGroup('adapter');
|
|
265
248
|
}
|
|
266
|
-
/** get a MST type for the union of all specified pluggable MST types */
|
|
267
249
|
pluggableMstType(groupName, fieldName, fallback = mobx_state_tree_1.types.maybe(mobx_state_tree_1.types.null)) {
|
|
268
250
|
const pluggableTypes = this.getElementTypeRecord(groupName)
|
|
269
251
|
.all()
|
|
270
|
-
// @ts-expect-error
|
|
271
252
|
.map(t => t[fieldName])
|
|
272
253
|
.filter(t => (0, mobx_state_tree_1.isType)(t) && (0, mobx_state_tree_1.isModelType)(t));
|
|
273
|
-
// try to smooth over the case when no types are registered, mostly
|
|
274
|
-
// encountered in tests
|
|
275
254
|
if (pluggableTypes.length === 0 && typeof jest === 'undefined') {
|
|
276
255
|
console.warn(`No pluggable types found matching ('${groupName}','${fieldName}')`);
|
|
277
256
|
return fallback;
|
|
278
257
|
}
|
|
279
258
|
return mobx_state_tree_1.types.union(...pluggableTypes);
|
|
280
259
|
}
|
|
281
|
-
/** get a MST type for the union of all specified pluggable config schemas */
|
|
282
260
|
pluggableConfigSchemaType(typeGroup, fieldName = 'configSchema') {
|
|
283
261
|
const pluggableTypes = this.getElementTypeRecord(typeGroup)
|
|
284
262
|
.all()
|
|
285
|
-
// @ts-expect-error
|
|
286
263
|
.map(t => t[fieldName])
|
|
287
264
|
.filter(t => (0, configuration_1.isBareConfigurationSchemaType)(t));
|
|
288
265
|
if (pluggableTypes.length === 0) {
|
|
@@ -336,13 +313,10 @@ class PluginManager {
|
|
|
336
313
|
return this.addElementType('text search adapter', cb);
|
|
337
314
|
}
|
|
338
315
|
addTrackType(cb) {
|
|
339
|
-
// Goes through the already-created displays and registers the ones that
|
|
340
|
-
// specify this track type
|
|
341
316
|
const callback = () => {
|
|
342
317
|
const track = cb(this);
|
|
343
318
|
const displays = this.getElementTypesInGroup('display');
|
|
344
319
|
displays.forEach(display => {
|
|
345
|
-
// track may have already added the displayType in its cb
|
|
346
320
|
if (display.trackType === track.name &&
|
|
347
321
|
!track.displayTypes.includes(display)) {
|
|
348
322
|
track.addDisplayType(display);
|
|
@@ -360,8 +334,6 @@ class PluginManager {
|
|
|
360
334
|
const newView = cb(this);
|
|
361
335
|
const displays = this.getElementTypesInGroup('display');
|
|
362
336
|
displays.forEach(display => {
|
|
363
|
-
// view may have already added the displayType in its callback
|
|
364
|
-
// see ViewType for description of extendedName
|
|
365
337
|
if ((display.viewType === newView.name ||
|
|
366
338
|
display.viewType === newView.extendedName) &&
|
|
367
339
|
!newView.displayTypes.includes(display)) {
|
package/ReExports/DataGrid.js
CHANGED
package/ReExports/list.d.ts
CHANGED
|
@@ -1,7 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Used by plugin build systems to determine if a module is provided by JBrowse
|
|
3
|
-
* globally and thus doesn't need to be bundled. A check in ./modules.tsx makes
|
|
4
|
-
* sure this is in sync with the re-exported modules.
|
|
5
|
-
*/
|
|
6
1
|
declare const _default: string[];
|
|
7
2
|
export default _default;
|
package/ReExports/list.js
CHANGED
|
@@ -1,10 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
/**
|
|
4
|
-
* Used by plugin build systems to determine if a module is provided by JBrowse
|
|
5
|
-
* globally and thus doesn't need to be bundled. A check in ./modules.tsx makes
|
|
6
|
-
* sure this is in sync with the re-exported modules.
|
|
7
|
-
*/
|
|
8
3
|
exports.default = [
|
|
9
4
|
'mobx',
|
|
10
5
|
'mobx-state-tree',
|
package/ReExports/modules.d.ts
CHANGED
|
@@ -1,40 +1,42 @@
|
|
|
1
|
+
import type { LazyExoticComponent } from 'react';
|
|
1
2
|
import React from 'react';
|
|
2
|
-
import
|
|
3
|
-
import * as ReactDom from 'react-dom';
|
|
4
|
-
import * as mobx from 'mobx';
|
|
5
|
-
import * as mst from 'mobx-state-tree';
|
|
6
|
-
import * as mxreact from 'mobx-react';
|
|
3
|
+
import { useTheme } from '@mui/material';
|
|
7
4
|
import * as MUIStyles from '@mui/material/styles';
|
|
8
5
|
import * as MUIUtils from '@mui/material/utils';
|
|
9
6
|
import { useGridApiContext } from '@mui/x-data-grid';
|
|
7
|
+
import * as mobx from 'mobx';
|
|
8
|
+
import * as mxreact from 'mobx-react';
|
|
9
|
+
import * as mst from 'mobx-state-tree';
|
|
10
|
+
import * as ReactJSXRuntime from 'react/jsx-runtime';
|
|
11
|
+
import * as ReactDom from 'react-dom';
|
|
12
|
+
import Plugin from '../Plugin';
|
|
13
|
+
import * as Configuration from '../configuration';
|
|
10
14
|
import * as BaseAdapterExports from '../data_adapters/BaseAdapter';
|
|
11
15
|
import * as pluggableElementTypes from '../pluggableElementTypes';
|
|
12
16
|
import * as pluggableElementTypeModels from '../pluggableElementTypes/models';
|
|
13
|
-
import * as ServerSideRendererType from '../pluggableElementTypes/renderers/ServerSideRendererType';
|
|
14
17
|
import * as BoxRendererType from '../pluggableElementTypes/renderers/BoxRendererType';
|
|
15
18
|
import * as FeatureRendererType from '../pluggableElementTypes/renderers/FeatureRendererType';
|
|
16
19
|
import * as RendererType from '../pluggableElementTypes/renderers/RendererType';
|
|
17
|
-
import * as
|
|
18
|
-
import Plugin from '../Plugin';
|
|
20
|
+
import * as ServerSideRendererType from '../pluggableElementTypes/renderers/ServerSideRendererType';
|
|
19
21
|
import * as coreUi from '../ui';
|
|
20
22
|
import * as coreUtil from '../util';
|
|
21
23
|
import * as coreColor from '../util/color';
|
|
22
|
-
import * as coreLayouts from '../util/layouts';
|
|
23
|
-
import * as trackUtils from '../util/tracks';
|
|
24
24
|
import * as coreIo from '../util/io';
|
|
25
|
+
import * as coreLayouts from '../util/layouts';
|
|
25
26
|
import * as coreMstReflection from '../util/mst-reflection';
|
|
26
27
|
import * as rxjs from '../util/rxjs';
|
|
28
|
+
import * as trackUtils from '../util/tracks';
|
|
27
29
|
import * as mstTypes from '../util/types/mst';
|
|
28
30
|
declare const libs: {
|
|
29
|
-
'@material-ui/lab/ToggleButton':
|
|
30
|
-
'@material-ui/lab/ToggleButtonGroup':
|
|
31
|
-
'@material-ui/lab/Autocomplete':
|
|
32
|
-
'@material-ui/lab/Alert':
|
|
31
|
+
'@material-ui/lab/ToggleButton': LazyExoticComponent<import("@mui/material").ExtendButtonBase<import("@mui/material").ToggleButtonTypeMap<{}, "button">>>;
|
|
32
|
+
'@material-ui/lab/ToggleButtonGroup': LazyExoticComponent<typeof import("@mui/material").ToggleButtonGroup>;
|
|
33
|
+
'@material-ui/lab/Autocomplete': LazyExoticComponent<typeof import("@mui/material").Autocomplete>;
|
|
34
|
+
'@material-ui/lab/Alert': LazyExoticComponent<typeof import("@mui/material").Alert>;
|
|
33
35
|
'@material-ui/lab': {
|
|
34
|
-
Alert:
|
|
35
|
-
Autocomplete:
|
|
36
|
-
ToggleButton:
|
|
37
|
-
ToggleButtonGroup:
|
|
36
|
+
Alert: LazyExoticComponent<typeof import("@mui/material").Alert>;
|
|
37
|
+
Autocomplete: LazyExoticComponent<typeof import("@mui/material").Autocomplete>;
|
|
38
|
+
ToggleButton: LazyExoticComponent<import("@mui/material").ExtendButtonBase<import("@mui/material").ToggleButtonTypeMap<{}, "button">>>;
|
|
39
|
+
ToggleButtonGroup: LazyExoticComponent<typeof import("@mui/material").ToggleButtonGroup>;
|
|
38
40
|
};
|
|
39
41
|
'@jbrowse/core/Plugin': typeof Plugin;
|
|
40
42
|
'@jbrowse/core/pluggableElementTypes': typeof pluggableElementTypes;
|
|
@@ -147,13 +149,13 @@ declare const libs: {
|
|
|
147
149
|
};
|
|
148
150
|
};
|
|
149
151
|
'@material-ui/core': {
|
|
150
|
-
useTheme: typeof
|
|
152
|
+
useTheme: typeof useTheme;
|
|
151
153
|
alpha: typeof MUIStyles.alpha;
|
|
152
154
|
makeStyles: (args: any) => () => Record<string, string>;
|
|
153
155
|
};
|
|
154
156
|
'@mui/material': {
|
|
155
157
|
alpha: typeof MUIStyles.alpha;
|
|
156
|
-
useTheme: typeof
|
|
158
|
+
useTheme: typeof useTheme;
|
|
157
159
|
};
|
|
158
160
|
'@mui/material/styles': {
|
|
159
161
|
MUIStyles: typeof MUIStyles;
|
package/ReExports/modules.js
CHANGED
|
@@ -26,46 +26,43 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
26
26
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
/* eslint-disable react-refresh/only-export-components */
|
|
30
|
-
// this is all the stuff that the pluginManager re-exports for plugins to use
|
|
31
29
|
const react_1 = __importStar(require("react"));
|
|
32
|
-
const
|
|
33
|
-
const ReactDom = __importStar(require("react-dom"));
|
|
34
|
-
const mobx = __importStar(require("mobx"));
|
|
35
|
-
const mst = __importStar(require("mobx-state-tree"));
|
|
36
|
-
const mxreact = __importStar(require("mobx-react"));
|
|
37
|
-
const mui_1 = require("tss-react/mui");
|
|
30
|
+
const material_1 = require("@mui/material");
|
|
38
31
|
const MUIStyles = __importStar(require("@mui/material/styles"));
|
|
39
32
|
const MUIUtils = __importStar(require("@mui/material/utils"));
|
|
40
|
-
const material_1 = require("@mui/material");
|
|
41
33
|
const x_data_grid_1 = require("@mui/x-data-grid");
|
|
42
|
-
|
|
34
|
+
const mobx = __importStar(require("mobx"));
|
|
35
|
+
const mxreact = __importStar(require("mobx-react"));
|
|
36
|
+
const mst = __importStar(require("mobx-state-tree"));
|
|
37
|
+
const ReactJSXRuntime = __importStar(require("react/jsx-runtime"));
|
|
38
|
+
const ReactDom = __importStar(require("react-dom"));
|
|
39
|
+
const mui_1 = require("tss-react/mui");
|
|
40
|
+
const Plugin_1 = __importDefault(require("../Plugin"));
|
|
41
|
+
const Configuration = __importStar(require("../configuration"));
|
|
43
42
|
const BaseAdapterExports = __importStar(require("../data_adapters/BaseAdapter"));
|
|
44
|
-
const Base1DViewModel_1 = __importDefault(require("../util/Base1DViewModel"));
|
|
45
43
|
const pluggableElementTypes = __importStar(require("../pluggableElementTypes"));
|
|
46
|
-
const
|
|
44
|
+
const list_1 = __importDefault(require("./list"));
|
|
47
45
|
const AdapterType_1 = __importDefault(require("../pluggableElementTypes/AdapterType"));
|
|
48
46
|
const DisplayType_1 = __importDefault(require("../pluggableElementTypes/DisplayType"));
|
|
49
47
|
const TrackType_1 = __importDefault(require("../pluggableElementTypes/TrackType"));
|
|
48
|
+
const ViewType_1 = __importDefault(require("../pluggableElementTypes/ViewType"));
|
|
50
49
|
const WidgetType_1 = __importDefault(require("../pluggableElementTypes/WidgetType"));
|
|
51
50
|
const pluggableElementTypeModels = __importStar(require("../pluggableElementTypes/models"));
|
|
52
|
-
const ServerSideRendererType = __importStar(require("../pluggableElementTypes/renderers/ServerSideRendererType"));
|
|
53
|
-
const CircularChordRendererType_1 = __importDefault(require("../pluggableElementTypes/renderers/CircularChordRendererType"));
|
|
54
51
|
const BoxRendererType = __importStar(require("../pluggableElementTypes/renderers/BoxRendererType"));
|
|
52
|
+
const CircularChordRendererType_1 = __importDefault(require("../pluggableElementTypes/renderers/CircularChordRendererType"));
|
|
55
53
|
const FeatureRendererType = __importStar(require("../pluggableElementTypes/renderers/FeatureRendererType"));
|
|
56
54
|
const RendererType = __importStar(require("../pluggableElementTypes/renderers/RendererType"));
|
|
57
|
-
const
|
|
58
|
-
const Plugin_1 = __importDefault(require("../Plugin"));
|
|
55
|
+
const ServerSideRendererType = __importStar(require("../pluggableElementTypes/renderers/ServerSideRendererType"));
|
|
59
56
|
const coreUi = __importStar(require("../ui"));
|
|
60
57
|
const coreUtil = __importStar(require("../util"));
|
|
58
|
+
const Base1DViewModel_1 = __importDefault(require("../util/Base1DViewModel"));
|
|
61
59
|
const coreColor = __importStar(require("../util/color"));
|
|
62
|
-
const coreLayouts = __importStar(require("../util/layouts"));
|
|
63
|
-
const trackUtils = __importStar(require("../util/tracks"));
|
|
64
60
|
const coreIo = __importStar(require("../util/io"));
|
|
61
|
+
const coreLayouts = __importStar(require("../util/layouts"));
|
|
65
62
|
const coreMstReflection = __importStar(require("../util/mst-reflection"));
|
|
66
63
|
const rxjs = __importStar(require("../util/rxjs"));
|
|
64
|
+
const trackUtils = __importStar(require("../util/tracks"));
|
|
67
65
|
const mstTypes = __importStar(require("../util/types/mst"));
|
|
68
|
-
const list_1 = __importDefault(require("./list"));
|
|
69
66
|
const Entries = {
|
|
70
67
|
Accordion: (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('@mui/material/Accordion')))),
|
|
71
68
|
AccordionActions: (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('@mui/material/AccordionActions')))),
|
|
@@ -373,7 +370,6 @@ const libs = {
|
|
|
373
370
|
useGridRootProps: x_data_grid_1.useGridRootProps,
|
|
374
371
|
...LazyDataGridComponents,
|
|
375
372
|
},
|
|
376
|
-
// special case so plugins can easily use @mui/icons-material; don't remove
|
|
377
373
|
'@mui/material/utils': MUIUtils,
|
|
378
374
|
'@material-ui/core/utils': MUIUtils,
|
|
379
375
|
'tss-react/mui': { makeStyles: mui_1.makeStyles },
|
|
@@ -391,8 +387,6 @@ const libs = {
|
|
|
391
387
|
alpha: MUIStyles.alpha,
|
|
392
388
|
useTheme: MUIStyles.useTheme,
|
|
393
389
|
},
|
|
394
|
-
// end special case
|
|
395
|
-
// material-ui subcomponents, should get rid of these
|
|
396
390
|
'@mui/material/styles': {
|
|
397
391
|
MUIStyles,
|
|
398
392
|
makeStyles: (args) => {
|
|
@@ -409,7 +403,6 @@ const libs = {
|
|
|
409
403
|
},
|
|
410
404
|
...MaterialPrefixMUI,
|
|
411
405
|
...MuiPrefixMUI,
|
|
412
|
-
// these are core in @mui/material, but used to be in @material-ui/lab
|
|
413
406
|
'@material-ui/lab/ToggleButton': Entries.ToggleButton,
|
|
414
407
|
'@material-ui/lab/ToggleButtonGroup': Entries.ToggleButtonGroup,
|
|
415
408
|
'@material-ui/lab/Autocomplete': Entries.Autocomplete,
|
|
@@ -452,8 +445,6 @@ const libs = {
|
|
|
452
445
|
'@jbrowse/core/data_adapters/BaseAdapter': BaseAdapterExports,
|
|
453
446
|
};
|
|
454
447
|
const libsList = Object.keys(libs);
|
|
455
|
-
// make sure that all the items in the ReExports/list array (used by build
|
|
456
|
-
// systems and such) are included here, and vice versa
|
|
457
448
|
const inLibsOnly = libsList.filter(mod => !list_1.default.includes(mod));
|
|
458
449
|
if (inLibsOnly.length > 0) {
|
|
459
450
|
throw new Error(`The following modules are in the modules libs, but not the re-exports list: ${inLibsOnly.join(', ')}`);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { SearchType } from '../data_adapters/BaseAdapter';
|
|
3
|
+
import type TextSearchAdapterType from '../pluggableElementTypes/TextSearchAdapterType';
|
|
4
4
|
export interface BaseResultArgs {
|
|
5
5
|
label: string;
|
|
6
6
|
displayString?: string;
|