@jbrowse/core 1.4.1 → 1.5.2
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.d.ts +4 -4
- package/BaseFeatureWidget/BaseFeatureDetail.js +27 -8
- package/BaseFeatureWidget/SequenceFeatureDetails.js +10 -10
- package/BaseFeatureWidget/index.js +1 -1
- package/BaseFeatureWidget/types.d.ts +1 -1
- package/BaseFeatureWidget/util.js +3 -3
- package/CorePlugin.d.ts +0 -1
- package/CorePlugin.js +13 -1
- package/PluginLoader.d.ts +26 -4
- package/PluginLoader.js +337 -51
- package/PluginManager.d.ts +18 -11
- package/PluginManager.js +53 -31
- package/ReExports/list.js +1 -1
- package/ReExports/material-ui-colors.js +38 -38
- package/ReExports/modules.d.ts +19 -20
- package/ReExports/modules.js +10 -3
- package/TextSearch/BaseResults.d.ts +5 -14
- package/TextSearch/BaseResults.js +16 -58
- package/TextSearch/BaseResults.test.js +1 -11
- package/TextSearch/TextSearchManager.d.ts +3 -3
- package/TextSearch/TextSearchManager.js +1 -1
- package/assemblyManager/assembly.d.ts +21 -8
- package/assemblyManager/assembly.js +163 -120
- package/assemblyManager/assemblyConfigSchema.d.ts +3 -0
- package/assemblyManager/{assemblyConfigSchemas.js → assemblyConfigSchema.js} +35 -27
- package/assemblyManager/assemblyManager.d.ts +169 -60
- package/assemblyManager/index.d.ts +1 -1
- package/assemblyManager/index.js +5 -5
- package/configuration/configurationSchema.d.ts +3 -2
- package/configuration/configurationSchema.js +7 -10
- package/configuration/configurationSchema.test.js +4 -2
- package/configuration/configurationSlot.js +5 -4
- package/configuration/index.js +4 -4
- package/configuration/util.js +5 -5
- package/data_adapters/BaseAdapter.d.ts +5 -3
- package/data_adapters/BaseAdapter.js +7 -4
- package/data_adapters/BaseAdapter.test.js +4 -2
- package/data_adapters/CytobandAdapter.d.ts +8 -0
- package/data_adapters/CytobandAdapter.js +128 -0
- package/data_adapters/dataAdapterCache.js +3 -3
- package/package.json +7 -6
- package/pluggableElementTypes/AdapterType.d.ts +9 -1
- package/pluggableElementTypes/AdapterType.js +20 -0
- package/pluggableElementTypes/InternetAccountType.d.ts +12 -0
- package/pluggableElementTypes/InternetAccountType.js +64 -0
- package/pluggableElementTypes/PluggableElementBase.d.ts +1 -2
- package/pluggableElementTypes/PluggableElementBase.js +2 -3
- package/pluggableElementTypes/RpcMethodType.d.ts +3 -0
- package/pluggableElementTypes/RpcMethodType.js +269 -26
- package/pluggableElementTypes/RpcMethodType.test.d.ts +4 -0
- package/pluggableElementTypes/RpcMethodType.test.js +118 -0
- package/pluggableElementTypes/ViewType.d.ts +1 -1
- package/pluggableElementTypes/WidgetType.d.ts +1 -0
- package/pluggableElementTypes/index.d.ts +7 -3
- package/pluggableElementTypes/index.js +127 -1
- package/pluggableElementTypes/models/BaseDisplayModel.d.ts +6 -6
- package/pluggableElementTypes/models/BaseDisplayModel.js +1 -3
- package/pluggableElementTypes/models/BaseViewModel.js +13 -15
- package/pluggableElementTypes/models/InternetAccountModel.d.ts +24 -0
- package/pluggableElementTypes/models/InternetAccountModel.js +85 -0
- package/pluggableElementTypes/models/baseInternetAccountConfig.d.ts +4 -0
- package/pluggableElementTypes/models/baseInternetAccountConfig.js +25 -0
- package/pluggableElementTypes/models/index.d.ts +3 -0
- package/pluggableElementTypes/models/index.js +24 -8
- package/pluggableElementTypes/renderers/BoxRendererType.js +1 -1
- package/pluggableElementTypes/renderers/ComparativeServerSideRendererType.d.ts +1 -1
- package/pluggableElementTypes/renderers/ComparativeServerSideRendererType.js +15 -6
- package/pluggableElementTypes/renderers/FeatureRendererType.d.ts +3 -3
- package/pluggableElementTypes/renderers/FeatureRendererType.js +17 -8
- package/pluggableElementTypes/renderers/RendererType.d.ts +1 -0
- package/pluggableElementTypes/renderers/RendererType.js +4 -1
- package/pluggableElementTypes/renderers/ServerSideRenderedContent.js +1 -1
- package/pluggableElementTypes/renderers/index.d.ts +9 -0
- package/pluggableElementTypes/renderers/index.js +63 -0
- package/rpc/BaseRpcDriver.js +5 -9
- package/rpc/BaseRpcDriver.test.js +6 -6
- package/rpc/RpcManager.d.ts +1 -1
- package/rpc/RpcManager.js +44 -16
- package/rpc/WebWorkerRpcDriver.js +3 -3
- package/rpc/coreRpcMethods.d.ts +2 -1
- package/rpc/coreRpcMethods.js +109 -75
- package/rpc/remoteAbortSignals.js +2 -2
- package/ui/App.d.ts +17 -4
- package/ui/App.js +55 -41
- package/ui/Drawer.d.ts +6 -14
- package/ui/Drawer.js +11 -12
- package/ui/DrawerWidget.d.ts +5 -3
- package/ui/DrawerWidget.js +100 -61
- package/ui/ErrorMessage.d.ts +5 -0
- package/ui/ErrorMessage.js +54 -0
- package/ui/FileSelector/FileSelector.d.ts +11 -0
- package/ui/FileSelector/FileSelector.js +198 -0
- package/ui/FileSelector/LocalFileChooser.d.ts +7 -0
- package/ui/FileSelector/LocalFileChooser.js +79 -0
- package/ui/FileSelector/UrlChooser.d.ts +9 -0
- package/ui/FileSelector/UrlChooser.js +41 -0
- package/ui/FileSelector/index.d.ts +2 -0
- package/ui/FileSelector/index.js +13 -0
- package/ui/Icons.d.ts +4 -0
- package/ui/Icons.js +34 -0
- package/ui/Logo.js +1 -1
- package/ui/PrerenderedCanvas.d.ts +1 -0
- package/ui/PrerenderedCanvas.js +4 -1
- package/ui/ResizeHandle.d.ts +2 -3
- package/ui/ResizeHandle.js +6 -7
- package/ui/SanitizedHTML.js +1 -1
- package/ui/Snackbar.js +4 -6
- package/ui/SnackbarModel.d.ts +16 -0
- package/ui/SnackbarModel.js +56 -0
- package/ui/Tooltip.d.ts +1 -1
- package/ui/index.js +24 -24
- package/ui/theme.js +5 -5
- package/util/QuickLRU.d.ts +1 -1
- package/util/QuickLRU.js +3 -3
- package/util/aborting.d.ts +1 -1
- package/util/aborting.js +10 -11
- package/util/analytics.d.ts +2 -2
- package/util/analytics.js +20 -7
- package/util/blockTypes.d.ts +11 -6
- package/util/blockTypes.js +7 -1
- package/util/color/cssColorsLevel4.js +1 -1
- package/util/color/index.js +5 -5
- package/util/compositeMap.js +3 -3
- package/util/index.d.ts +6 -16
- package/util/index.js +76 -100
- package/util/io/RemoteFileWithRangeCache.d.ts +17 -0
- package/util/io/RemoteFileWithRangeCache.js +266 -0
- package/util/io/index.d.ts +4 -2
- package/util/io/index.js +134 -25
- package/util/jexl.js +4 -1
- package/util/layouts/BaseLayout.d.ts +3 -0
- package/util/layouts/GranularRectLayout.d.ts +19 -10
- package/util/layouts/GranularRectLayout.js +459 -100
- package/util/layouts/GranularRectLayout.test.js +57 -10
- package/util/layouts/PrecomputedLayout.js +2 -1
- package/util/layouts/index.d.ts +7 -0
- package/util/layouts/index.js +68 -0
- package/util/mst-reflection.js +3 -3
- package/util/offscreenCanvasPonyfill.js +1 -1
- package/util/range.js +1 -1
- package/util/simpleFeature.js +1 -1
- package/util/stats.js +2 -2
- package/util/tracks.d.ts +31 -362
- package/util/tracks.js +74 -190
- package/util/types/index.d.ts +54 -10
- package/util/types/index.js +110 -8
- package/util/types/mst.d.ts +46 -2
- package/util/types/mst.js +56 -8
- package/util/types/util.d.ts +1 -1
- package/util/when.js +1 -1
- package/assemblyManager/assemblyConfigSchemas.d.ts +0 -7
- package/ui/FileSelector.d.ts +0 -9
- package/ui/FileSelector.js +0 -150
- package/util/io/LocalFile.d.ts +0 -18
- package/util/io/LocalFile.js +0 -220
- package/util/io/rangeFetcher.d.ts +0 -3
- package/util/io/rangeFetcher.js +0 -236
- package/value.d.ts +0 -1
- package/value.js +0 -10
|
@@ -8,7 +8,10 @@ var _GranularRectLayout = _interopRequireDefault(require("./GranularRectLayout")
|
|
|
8
8
|
|
|
9
9
|
describe('GranularRectLayout', function () {
|
|
10
10
|
it('lays out non-overlapping features end to end', function () {
|
|
11
|
-
var l = new _GranularRectLayout.default(
|
|
11
|
+
var l = new _GranularRectLayout.default({
|
|
12
|
+
pitchX: 10,
|
|
13
|
+
pitchY: 4
|
|
14
|
+
});
|
|
12
15
|
var testRects = [['1,0', 4133, 5923, 16], ['1,1', 11299, 12389, 16], ['1,2', 21050, 22778, 16], ['1,3', 41125, 47459, 16], ['1,4', 47926, 49272, 16], ['1,5', 50240, 52495, 16], ['1,6', 53329, 56283, 16], ['1,7', 59309, 79441, 16], ['1,8', 80359, 83196, 16], ['1,9', 92147, 94188, 16], ['1,10', 96241, 103626, 16], ['1,11', 104396, 108110, 16], ['1,12', 111878, 125251, 16], ['1,13', 125747, 128085, 16], ['1,14', 131492, 132641, 16], ['1,15', 133857, 134931, 16], ['1,16', 137023, 138220, 16], ['1,17', 140703, 145668, 16], ['1,18', 146045, 147059, 16], ['1,19', 162296, 165395, 16], ['1,20', 168531, 170795, 16], ['1,21', 174812, 180475, 16], ['1,22', 184302, 188826, 16], ['1,23', 189609, 191141, 16], ['1,24', 199799, 201389, 16], ['1,25', 203436, 211345, 16], ['1,26', 212100, 212379, 16], ['1,27', 213418, 214627, 16], ['1,28', 215115, 219344, 16], ['1,29', 220067, 222525, 16], ['1,30', 223308, 228141, 16], ['1,31', 234473, 236768, 16], ['1,32', 239691, 245015, 16]];
|
|
13
16
|
|
|
14
17
|
for (var i = 0; i < testRects.length; i += 1) {
|
|
@@ -17,7 +20,10 @@ describe('GranularRectLayout', function () {
|
|
|
17
20
|
}
|
|
18
21
|
});
|
|
19
22
|
it('stacks up overlapping features', function () {
|
|
20
|
-
var l = new _GranularRectLayout.default(
|
|
23
|
+
var l = new _GranularRectLayout.default({
|
|
24
|
+
pitchX: 10,
|
|
25
|
+
pitchY: 4
|
|
26
|
+
});
|
|
21
27
|
var testRects = [];
|
|
22
28
|
|
|
23
29
|
for (var i = 1; i <= 20; i += 1) {
|
|
@@ -26,35 +32,76 @@ describe('GranularRectLayout', function () {
|
|
|
26
32
|
|
|
27
33
|
for (var _i = 0; _i < testRects.length; _i += 1) {
|
|
28
34
|
var top = l.addRect.apply(l, (0, _toConsumableArray2.default)(testRects[_i]));
|
|
29
|
-
expect(top).toEqual(_i % 2 *
|
|
35
|
+
expect(top).toEqual(_i % 2 * 4);
|
|
30
36
|
}
|
|
31
37
|
});
|
|
32
38
|
it('discards regions', function () {
|
|
33
|
-
var l = new _GranularRectLayout.default(
|
|
39
|
+
var l = new _GranularRectLayout.default({
|
|
40
|
+
pitchX: 10,
|
|
41
|
+
pitchY: 4
|
|
42
|
+
});
|
|
34
43
|
|
|
35
44
|
for (var i = 0; i < 20; i += 1) {
|
|
36
45
|
var top = l.addRect("feature-".concat(i), 10000 * i + 4000, 10000 * i + 16000, 1);
|
|
37
|
-
expect(top).toEqual(i % 2 *
|
|
46
|
+
expect(top).toEqual(i % 2 * 4);
|
|
38
47
|
}
|
|
48
|
+
|
|
49
|
+
expect(l.bitmap[0].rowState.bits.length).toBe(34812);
|
|
50
|
+
expect(l.bitmap[1].rowState.bits.length).toBe(34812);
|
|
51
|
+
l.discardRange(190000, 220000);
|
|
52
|
+
expect(l.bitmap[0].rowState.bits.length).toBe(24802);
|
|
53
|
+
expect(l.bitmap[1].rowState.bits.length).toBe(23802);
|
|
54
|
+
l.discardRange(0, 100000);
|
|
55
|
+
expect(l.bitmap[0].rowState.bits.length).toBe(19001);
|
|
56
|
+
expect(l.bitmap[1].rowState.bits.length).toBe(23802);
|
|
57
|
+
l.discardRange(0, 220000);
|
|
58
|
+
expect(l.bitmap[0].rowState).toBeUndefined();
|
|
39
59
|
}); // see issue #486
|
|
40
60
|
|
|
41
61
|
it('tests that adding +/- pitchX fixes resolution causing errors', function () {
|
|
42
|
-
var l = new _GranularRectLayout.default(
|
|
62
|
+
var l = new _GranularRectLayout.default({
|
|
63
|
+
pitchX: 91.21851599727707,
|
|
64
|
+
pitchY: 3
|
|
65
|
+
});
|
|
43
66
|
l.addRect('test', 2581541, 2581542, 1);
|
|
44
67
|
expect(l.serializeRegion({
|
|
45
68
|
start: 2581491,
|
|
46
69
|
end: 2818659
|
|
47
70
|
}).rectangles.test).toBeTruthy();
|
|
48
71
|
});
|
|
72
|
+
it('tests reinitializing layout due to throwing away old one', function () {
|
|
73
|
+
var spy = jest.spyOn(console, 'warn').mockImplementation(function () {});
|
|
74
|
+
var l = new _GranularRectLayout.default({
|
|
75
|
+
pitchX: 1,
|
|
76
|
+
pitchY: 1,
|
|
77
|
+
maxHeight: 600
|
|
78
|
+
});
|
|
79
|
+
l.addRect('test1', 0, 10000, 1);
|
|
80
|
+
l.addRect('test2', 1000000, 1000100, 1);
|
|
81
|
+
l.addRect('test3', 0, 10000, 1);
|
|
82
|
+
expect(l.rectangles.size).toBe(3);
|
|
83
|
+
expect(spy).toHaveBeenCalled();
|
|
84
|
+
spy.mockRestore();
|
|
85
|
+
});
|
|
49
86
|
it('tests adding a gigantic feature that fills entire row with another smaller added on top', function () {
|
|
50
87
|
var l = new _GranularRectLayout.default({
|
|
88
|
+
pitchX: 100,
|
|
89
|
+
pitchY: 1,
|
|
51
90
|
maxHeight: 600
|
|
52
91
|
});
|
|
53
92
|
expect(l.getByCoord(50000, 0)).toEqual(undefined);
|
|
54
|
-
l.addRect('test1', 0,
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
expect(l.getByCoord(
|
|
93
|
+
l.addRect('test1', 0, 100000000, 1, {
|
|
94
|
+
id: 'feat1'
|
|
95
|
+
});
|
|
96
|
+
expect(l.getByCoord(50000, 0)).toEqual({
|
|
97
|
+
id: 'feat1'
|
|
98
|
+
});
|
|
99
|
+
l.addRect('test2', 0, 1000, 1, {
|
|
100
|
+
id: 'feat2'
|
|
101
|
+
});
|
|
102
|
+
expect(l.getByCoord(500, 1)).toEqual({
|
|
103
|
+
id: 'feat2'
|
|
104
|
+
});
|
|
58
105
|
expect(l.rectangles.size).toBe(2);
|
|
59
106
|
});
|
|
60
107
|
});
|
|
@@ -29,7 +29,8 @@ var PrecomputedLayout = /*#__PURE__*/function () {
|
|
|
29
29
|
(0, _defineProperty2.default)(this, "totalHeight", void 0);
|
|
30
30
|
(0, _defineProperty2.default)(this, "maxHeightReached", void 0);
|
|
31
31
|
(0, _defineProperty2.default)(this, "rbush", void 0);
|
|
32
|
-
this.rectangles = new Map(Object.entries(rectangles));
|
|
32
|
+
this.rectangles = new Map(Object.entries(rectangles)); // rectangles is of the form "featureId": [leftPx, topPx, rightPx, bottomPx]
|
|
33
|
+
|
|
33
34
|
this.totalHeight = totalHeight;
|
|
34
35
|
this.maxHeightReached = maxHeightReached;
|
|
35
36
|
this.rbush = new _rbush.default();
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './BaseLayout';
|
|
2
|
+
export { default as GranularRectLayout } from './GranularRectLayout';
|
|
3
|
+
export { default as MultiLayout } from './MultiLayout';
|
|
4
|
+
export { default as PrecomputedLayout } from './PrecomputedLayout';
|
|
5
|
+
export type { Layout } from './PrecomputedLayout';
|
|
6
|
+
export { default as PrecomputedMultiLayout } from './PrecomputedMultiLayout';
|
|
7
|
+
export { default as SceneGraph } from './SceneGraph';
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
var _exportNames = {
|
|
9
|
+
GranularRectLayout: true,
|
|
10
|
+
MultiLayout: true,
|
|
11
|
+
PrecomputedLayout: true,
|
|
12
|
+
PrecomputedMultiLayout: true,
|
|
13
|
+
SceneGraph: true
|
|
14
|
+
};
|
|
15
|
+
Object.defineProperty(exports, "GranularRectLayout", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function get() {
|
|
18
|
+
return _GranularRectLayout.default;
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
Object.defineProperty(exports, "MultiLayout", {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function get() {
|
|
24
|
+
return _MultiLayout.default;
|
|
25
|
+
}
|
|
26
|
+
});
|
|
27
|
+
Object.defineProperty(exports, "PrecomputedLayout", {
|
|
28
|
+
enumerable: true,
|
|
29
|
+
get: function get() {
|
|
30
|
+
return _PrecomputedLayout.default;
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
Object.defineProperty(exports, "PrecomputedMultiLayout", {
|
|
34
|
+
enumerable: true,
|
|
35
|
+
get: function get() {
|
|
36
|
+
return _PrecomputedMultiLayout.default;
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
Object.defineProperty(exports, "SceneGraph", {
|
|
40
|
+
enumerable: true,
|
|
41
|
+
get: function get() {
|
|
42
|
+
return _SceneGraph.default;
|
|
43
|
+
}
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
var _BaseLayout = require("./BaseLayout");
|
|
47
|
+
|
|
48
|
+
Object.keys(_BaseLayout).forEach(function (key) {
|
|
49
|
+
if (key === "default" || key === "__esModule") return;
|
|
50
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
51
|
+
if (key in exports && exports[key] === _BaseLayout[key]) return;
|
|
52
|
+
Object.defineProperty(exports, key, {
|
|
53
|
+
enumerable: true,
|
|
54
|
+
get: function get() {
|
|
55
|
+
return _BaseLayout[key];
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
});
|
|
59
|
+
|
|
60
|
+
var _GranularRectLayout = _interopRequireDefault(require("./GranularRectLayout"));
|
|
61
|
+
|
|
62
|
+
var _MultiLayout = _interopRequireDefault(require("./MultiLayout"));
|
|
63
|
+
|
|
64
|
+
var _PrecomputedLayout = _interopRequireDefault(require("./PrecomputedLayout"));
|
|
65
|
+
|
|
66
|
+
var _PrecomputedMultiLayout = _interopRequireDefault(require("./PrecomputedMultiLayout"));
|
|
67
|
+
|
|
68
|
+
var _SceneGraph = _interopRequireDefault(require("./SceneGraph"));
|
package/util/mst-reflection.js
CHANGED
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.getSubType = getSubType;
|
|
7
|
-
exports.getUnionSubTypes = getUnionSubTypes;
|
|
8
|
-
exports.getPropertyType = getPropertyType;
|
|
9
6
|
exports.getDefaultValue = getDefaultValue;
|
|
10
7
|
exports.getEnumerationValues = getEnumerationValues;
|
|
8
|
+
exports.getPropertyType = getPropertyType;
|
|
9
|
+
exports.getSubType = getSubType;
|
|
10
|
+
exports.getUnionSubTypes = getUnionSubTypes;
|
|
11
11
|
exports.resolveLateType = resolveLateType;
|
|
12
12
|
|
|
13
13
|
var _mobxStateTree = require("mobx-state-tree");
|
|
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.
|
|
8
|
+
exports.createImageBitmap = exports.createCanvas = exports.PonyfillOffscreenContext = exports.PonyfillOffscreenCanvas = exports.ImageBitmapType = void 0;
|
|
9
9
|
|
|
10
10
|
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
11
11
|
|
package/util/range.js
CHANGED
package/util/simpleFeature.js
CHANGED
|
@@ -5,8 +5,8 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.isFeature = isFeature;
|
|
9
8
|
exports.default = void 0;
|
|
9
|
+
exports.isFeature = isFeature;
|
|
10
10
|
|
|
11
11
|
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
12
12
|
|
package/util/stats.js
CHANGED
|
@@ -5,11 +5,11 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
+
exports.blankStats = blankStats;
|
|
9
|
+
exports.calcPerBaseStats = calcPerBaseStats;
|
|
8
10
|
exports.calcStdFromSums = calcStdFromSums;
|
|
9
11
|
exports.rectifyStats = rectifyStats;
|
|
10
|
-
exports.calcPerBaseStats = calcPerBaseStats;
|
|
11
12
|
exports.scoresToStats = scoresToStats;
|
|
12
|
-
exports.blankStats = blankStats;
|
|
13
13
|
|
|
14
14
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
15
15
|
|
package/util/tracks.d.ts
CHANGED
|
@@ -25,371 +25,40 @@ export declare function setBlobMap(map: {
|
|
|
25
25
|
export declare function storeBlobLocation(location: PreFileLocation): import("./types").PreUriLocation | import("./types").PreLocalPathLocation | {
|
|
26
26
|
name: string;
|
|
27
27
|
blobId: string;
|
|
28
|
+
locationType: string;
|
|
28
29
|
};
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
cramLocation?: undefined;
|
|
40
|
-
craiLocation?: undefined;
|
|
41
|
-
gffGzLocation?: undefined;
|
|
42
|
-
vcfLocation?: undefined;
|
|
43
|
-
vcfGzLocation?: undefined;
|
|
44
|
-
bedGzLocation?: undefined;
|
|
45
|
-
bigBedLocation?: undefined;
|
|
46
|
-
bigWigLocation?: undefined;
|
|
47
|
-
fastaLocation?: undefined;
|
|
48
|
-
faiLocation?: undefined;
|
|
49
|
-
gziLocation?: undefined;
|
|
50
|
-
twoBitLocation?: undefined;
|
|
51
|
-
rootUrlTemplate?: undefined;
|
|
52
|
-
endpoint?: undefined;
|
|
53
|
-
hicLocation?: undefined;
|
|
54
|
-
pafLocation?: undefined;
|
|
55
|
-
} | {
|
|
56
|
-
type: string;
|
|
57
|
-
cramLocation: FileLocation;
|
|
58
|
-
craiLocation: import("./types").LocalPathLocation | import("./types").UriLocation | import("./types").BlobLocation | {
|
|
59
|
-
uri: string;
|
|
60
|
-
localPath?: undefined;
|
|
61
|
-
};
|
|
62
|
-
bamLocation?: undefined;
|
|
63
|
-
index?: undefined;
|
|
64
|
-
gffGzLocation?: undefined;
|
|
65
|
-
vcfLocation?: undefined;
|
|
66
|
-
vcfGzLocation?: undefined;
|
|
67
|
-
bedGzLocation?: undefined;
|
|
68
|
-
bigBedLocation?: undefined;
|
|
69
|
-
bigWigLocation?: undefined;
|
|
70
|
-
fastaLocation?: undefined;
|
|
71
|
-
faiLocation?: undefined;
|
|
72
|
-
gziLocation?: undefined;
|
|
73
|
-
twoBitLocation?: undefined;
|
|
74
|
-
rootUrlTemplate?: undefined;
|
|
75
|
-
endpoint?: undefined;
|
|
76
|
-
hicLocation?: undefined;
|
|
77
|
-
pafLocation?: undefined;
|
|
78
|
-
} | {
|
|
79
|
-
type: string;
|
|
80
|
-
bamLocation?: undefined;
|
|
81
|
-
index?: undefined;
|
|
82
|
-
cramLocation?: undefined;
|
|
83
|
-
craiLocation?: undefined;
|
|
84
|
-
gffGzLocation?: undefined;
|
|
85
|
-
vcfLocation?: undefined;
|
|
86
|
-
vcfGzLocation?: undefined;
|
|
87
|
-
bedGzLocation?: undefined;
|
|
88
|
-
bigBedLocation?: undefined;
|
|
89
|
-
bigWigLocation?: undefined;
|
|
90
|
-
fastaLocation?: undefined;
|
|
91
|
-
faiLocation?: undefined;
|
|
92
|
-
gziLocation?: undefined;
|
|
93
|
-
twoBitLocation?: undefined;
|
|
94
|
-
rootUrlTemplate?: undefined;
|
|
95
|
-
endpoint?: undefined;
|
|
96
|
-
hicLocation?: undefined;
|
|
97
|
-
pafLocation?: undefined;
|
|
98
|
-
} | {
|
|
99
|
-
type: string;
|
|
100
|
-
gffGzLocation: FileLocation;
|
|
101
|
-
index: {
|
|
102
|
-
location: import("./types").LocalPathLocation | import("./types").UriLocation | import("./types").BlobLocation | {
|
|
103
|
-
uri: string;
|
|
104
|
-
localPath?: undefined;
|
|
105
|
-
};
|
|
106
|
-
indexType: string;
|
|
107
|
-
};
|
|
108
|
-
bamLocation?: undefined;
|
|
109
|
-
cramLocation?: undefined;
|
|
110
|
-
craiLocation?: undefined;
|
|
111
|
-
vcfLocation?: undefined;
|
|
112
|
-
vcfGzLocation?: undefined;
|
|
113
|
-
bedGzLocation?: undefined;
|
|
114
|
-
bigBedLocation?: undefined;
|
|
115
|
-
bigWigLocation?: undefined;
|
|
116
|
-
fastaLocation?: undefined;
|
|
117
|
-
faiLocation?: undefined;
|
|
118
|
-
gziLocation?: undefined;
|
|
119
|
-
twoBitLocation?: undefined;
|
|
120
|
-
rootUrlTemplate?: undefined;
|
|
121
|
-
endpoint?: undefined;
|
|
122
|
-
hicLocation?: undefined;
|
|
123
|
-
pafLocation?: undefined;
|
|
124
|
-
} | {
|
|
125
|
-
type: string;
|
|
126
|
-
vcfLocation: FileLocation;
|
|
127
|
-
bamLocation?: undefined;
|
|
128
|
-
index?: undefined;
|
|
129
|
-
cramLocation?: undefined;
|
|
130
|
-
craiLocation?: undefined;
|
|
131
|
-
gffGzLocation?: undefined;
|
|
132
|
-
vcfGzLocation?: undefined;
|
|
133
|
-
bedGzLocation?: undefined;
|
|
134
|
-
bigBedLocation?: undefined;
|
|
135
|
-
bigWigLocation?: undefined;
|
|
136
|
-
fastaLocation?: undefined;
|
|
137
|
-
faiLocation?: undefined;
|
|
138
|
-
gziLocation?: undefined;
|
|
139
|
-
twoBitLocation?: undefined;
|
|
140
|
-
rootUrlTemplate?: undefined;
|
|
141
|
-
endpoint?: undefined;
|
|
142
|
-
hicLocation?: undefined;
|
|
143
|
-
pafLocation?: undefined;
|
|
144
|
-
} | {
|
|
145
|
-
type: string;
|
|
146
|
-
vcfGzLocation: FileLocation;
|
|
147
|
-
index: {
|
|
148
|
-
location: import("./types").LocalPathLocation | import("./types").UriLocation | import("./types").BlobLocation | {
|
|
149
|
-
uri: string;
|
|
150
|
-
localPath?: undefined;
|
|
151
|
-
};
|
|
152
|
-
indexType: string;
|
|
153
|
-
};
|
|
154
|
-
bamLocation?: undefined;
|
|
155
|
-
cramLocation?: undefined;
|
|
156
|
-
craiLocation?: undefined;
|
|
157
|
-
gffGzLocation?: undefined;
|
|
158
|
-
vcfLocation?: undefined;
|
|
159
|
-
bedGzLocation?: undefined;
|
|
160
|
-
bigBedLocation?: undefined;
|
|
161
|
-
bigWigLocation?: undefined;
|
|
162
|
-
fastaLocation?: undefined;
|
|
163
|
-
faiLocation?: undefined;
|
|
164
|
-
gziLocation?: undefined;
|
|
165
|
-
twoBitLocation?: undefined;
|
|
166
|
-
rootUrlTemplate?: undefined;
|
|
167
|
-
endpoint?: undefined;
|
|
168
|
-
hicLocation?: undefined;
|
|
169
|
-
pafLocation?: undefined;
|
|
170
|
-
} | {
|
|
171
|
-
type: string;
|
|
172
|
-
bedGzLocation: FileLocation;
|
|
173
|
-
index: {
|
|
174
|
-
location: import("./types").LocalPathLocation | import("./types").UriLocation | import("./types").BlobLocation | {
|
|
175
|
-
uri: string;
|
|
176
|
-
localPath?: undefined;
|
|
177
|
-
};
|
|
178
|
-
indexType: string;
|
|
179
|
-
};
|
|
180
|
-
bamLocation?: undefined;
|
|
181
|
-
cramLocation?: undefined;
|
|
182
|
-
craiLocation?: undefined;
|
|
183
|
-
gffGzLocation?: undefined;
|
|
184
|
-
vcfLocation?: undefined;
|
|
185
|
-
vcfGzLocation?: undefined;
|
|
186
|
-
bigBedLocation?: undefined;
|
|
187
|
-
bigWigLocation?: undefined;
|
|
188
|
-
fastaLocation?: undefined;
|
|
189
|
-
faiLocation?: undefined;
|
|
190
|
-
gziLocation?: undefined;
|
|
191
|
-
twoBitLocation?: undefined;
|
|
192
|
-
rootUrlTemplate?: undefined;
|
|
193
|
-
endpoint?: undefined;
|
|
194
|
-
hicLocation?: undefined;
|
|
195
|
-
pafLocation?: undefined;
|
|
196
|
-
} | {
|
|
197
|
-
type: string;
|
|
198
|
-
bigBedLocation: FileLocation;
|
|
199
|
-
bamLocation?: undefined;
|
|
200
|
-
index?: undefined;
|
|
201
|
-
cramLocation?: undefined;
|
|
202
|
-
craiLocation?: undefined;
|
|
203
|
-
gffGzLocation?: undefined;
|
|
204
|
-
vcfLocation?: undefined;
|
|
205
|
-
vcfGzLocation?: undefined;
|
|
206
|
-
bedGzLocation?: undefined;
|
|
207
|
-
bigWigLocation?: undefined;
|
|
208
|
-
fastaLocation?: undefined;
|
|
209
|
-
faiLocation?: undefined;
|
|
210
|
-
gziLocation?: undefined;
|
|
211
|
-
twoBitLocation?: undefined;
|
|
212
|
-
rootUrlTemplate?: undefined;
|
|
213
|
-
endpoint?: undefined;
|
|
214
|
-
hicLocation?: undefined;
|
|
215
|
-
pafLocation?: undefined;
|
|
216
|
-
} | {
|
|
217
|
-
type: string;
|
|
218
|
-
bigWigLocation: FileLocation;
|
|
219
|
-
bamLocation?: undefined;
|
|
220
|
-
index?: undefined;
|
|
221
|
-
cramLocation?: undefined;
|
|
222
|
-
craiLocation?: undefined;
|
|
223
|
-
gffGzLocation?: undefined;
|
|
224
|
-
vcfLocation?: undefined;
|
|
225
|
-
vcfGzLocation?: undefined;
|
|
226
|
-
bedGzLocation?: undefined;
|
|
227
|
-
bigBedLocation?: undefined;
|
|
228
|
-
fastaLocation?: undefined;
|
|
229
|
-
faiLocation?: undefined;
|
|
230
|
-
gziLocation?: undefined;
|
|
231
|
-
twoBitLocation?: undefined;
|
|
232
|
-
rootUrlTemplate?: undefined;
|
|
233
|
-
endpoint?: undefined;
|
|
234
|
-
hicLocation?: undefined;
|
|
235
|
-
pafLocation?: undefined;
|
|
236
|
-
} | {
|
|
237
|
-
type: string;
|
|
238
|
-
fastaLocation: FileLocation;
|
|
239
|
-
faiLocation: import("./types").LocalPathLocation | import("./types").UriLocation | import("./types").BlobLocation | {
|
|
240
|
-
uri: string;
|
|
241
|
-
localPath?: undefined;
|
|
242
|
-
};
|
|
243
|
-
bamLocation?: undefined;
|
|
244
|
-
index?: undefined;
|
|
245
|
-
cramLocation?: undefined;
|
|
246
|
-
craiLocation?: undefined;
|
|
247
|
-
gffGzLocation?: undefined;
|
|
248
|
-
vcfLocation?: undefined;
|
|
249
|
-
vcfGzLocation?: undefined;
|
|
250
|
-
bedGzLocation?: undefined;
|
|
251
|
-
bigBedLocation?: undefined;
|
|
252
|
-
bigWigLocation?: undefined;
|
|
253
|
-
gziLocation?: undefined;
|
|
254
|
-
twoBitLocation?: undefined;
|
|
255
|
-
rootUrlTemplate?: undefined;
|
|
256
|
-
endpoint?: undefined;
|
|
257
|
-
hicLocation?: undefined;
|
|
258
|
-
pafLocation?: undefined;
|
|
259
|
-
} | {
|
|
260
|
-
type: string;
|
|
261
|
-
fastaLocation: FileLocation;
|
|
262
|
-
faiLocation: import("./types").BlobLocation | {
|
|
263
|
-
uri: string;
|
|
264
|
-
localPath?: undefined;
|
|
265
|
-
} | {
|
|
266
|
-
localPath: string;
|
|
267
|
-
uri?: undefined;
|
|
268
|
-
};
|
|
269
|
-
gziLocation: import("./types").BlobLocation | {
|
|
270
|
-
uri: string;
|
|
271
|
-
localPath?: undefined;
|
|
272
|
-
} | {
|
|
273
|
-
localPath: string;
|
|
274
|
-
uri?: undefined;
|
|
275
|
-
};
|
|
276
|
-
bamLocation?: undefined;
|
|
277
|
-
index?: undefined;
|
|
278
|
-
cramLocation?: undefined;
|
|
279
|
-
craiLocation?: undefined;
|
|
280
|
-
gffGzLocation?: undefined;
|
|
281
|
-
vcfLocation?: undefined;
|
|
282
|
-
vcfGzLocation?: undefined;
|
|
283
|
-
bedGzLocation?: undefined;
|
|
284
|
-
bigBedLocation?: undefined;
|
|
285
|
-
bigWigLocation?: undefined;
|
|
286
|
-
twoBitLocation?: undefined;
|
|
287
|
-
rootUrlTemplate?: undefined;
|
|
288
|
-
endpoint?: undefined;
|
|
289
|
-
hicLocation?: undefined;
|
|
290
|
-
pafLocation?: undefined;
|
|
291
|
-
} | {
|
|
292
|
-
type: string;
|
|
293
|
-
twoBitLocation: FileLocation;
|
|
294
|
-
bamLocation?: undefined;
|
|
295
|
-
index?: undefined;
|
|
296
|
-
cramLocation?: undefined;
|
|
297
|
-
craiLocation?: undefined;
|
|
298
|
-
gffGzLocation?: undefined;
|
|
299
|
-
vcfLocation?: undefined;
|
|
300
|
-
vcfGzLocation?: undefined;
|
|
301
|
-
bedGzLocation?: undefined;
|
|
302
|
-
bigBedLocation?: undefined;
|
|
303
|
-
bigWigLocation?: undefined;
|
|
304
|
-
fastaLocation?: undefined;
|
|
305
|
-
faiLocation?: undefined;
|
|
306
|
-
gziLocation?: undefined;
|
|
307
|
-
rootUrlTemplate?: undefined;
|
|
308
|
-
endpoint?: undefined;
|
|
309
|
-
hicLocation?: undefined;
|
|
310
|
-
pafLocation?: undefined;
|
|
311
|
-
} | {
|
|
312
|
-
type: string;
|
|
313
|
-
rootUrlTemplate: FileLocation;
|
|
314
|
-
bamLocation?: undefined;
|
|
315
|
-
index?: undefined;
|
|
316
|
-
cramLocation?: undefined;
|
|
317
|
-
craiLocation?: undefined;
|
|
318
|
-
gffGzLocation?: undefined;
|
|
319
|
-
vcfLocation?: undefined;
|
|
320
|
-
vcfGzLocation?: undefined;
|
|
321
|
-
bedGzLocation?: undefined;
|
|
322
|
-
bigBedLocation?: undefined;
|
|
323
|
-
bigWigLocation?: undefined;
|
|
324
|
-
fastaLocation?: undefined;
|
|
325
|
-
faiLocation?: undefined;
|
|
326
|
-
gziLocation?: undefined;
|
|
327
|
-
twoBitLocation?: undefined;
|
|
328
|
-
endpoint?: undefined;
|
|
329
|
-
hicLocation?: undefined;
|
|
330
|
-
pafLocation?: undefined;
|
|
331
|
-
} | {
|
|
332
|
-
type: string;
|
|
333
|
-
endpoint: FileLocation;
|
|
334
|
-
bamLocation?: undefined;
|
|
335
|
-
index?: undefined;
|
|
336
|
-
cramLocation?: undefined;
|
|
337
|
-
craiLocation?: undefined;
|
|
338
|
-
gffGzLocation?: undefined;
|
|
339
|
-
vcfLocation?: undefined;
|
|
340
|
-
vcfGzLocation?: undefined;
|
|
341
|
-
bedGzLocation?: undefined;
|
|
342
|
-
bigBedLocation?: undefined;
|
|
343
|
-
bigWigLocation?: undefined;
|
|
344
|
-
fastaLocation?: undefined;
|
|
345
|
-
faiLocation?: undefined;
|
|
346
|
-
gziLocation?: undefined;
|
|
347
|
-
twoBitLocation?: undefined;
|
|
348
|
-
rootUrlTemplate?: undefined;
|
|
349
|
-
hicLocation?: undefined;
|
|
350
|
-
pafLocation?: undefined;
|
|
351
|
-
} | {
|
|
352
|
-
type: string;
|
|
353
|
-
hicLocation: FileLocation;
|
|
354
|
-
bamLocation?: undefined;
|
|
355
|
-
index?: undefined;
|
|
356
|
-
cramLocation?: undefined;
|
|
357
|
-
craiLocation?: undefined;
|
|
358
|
-
gffGzLocation?: undefined;
|
|
359
|
-
vcfLocation?: undefined;
|
|
360
|
-
vcfGzLocation?: undefined;
|
|
361
|
-
bedGzLocation?: undefined;
|
|
362
|
-
bigBedLocation?: undefined;
|
|
363
|
-
bigWigLocation?: undefined;
|
|
364
|
-
fastaLocation?: undefined;
|
|
365
|
-
faiLocation?: undefined;
|
|
366
|
-
gziLocation?: undefined;
|
|
367
|
-
twoBitLocation?: undefined;
|
|
368
|
-
rootUrlTemplate?: undefined;
|
|
369
|
-
endpoint?: undefined;
|
|
370
|
-
pafLocation?: undefined;
|
|
30
|
+
/**
|
|
31
|
+
* creates a new location from the provided location including the appropriate suffix and location type
|
|
32
|
+
* @param location - the FileLocation
|
|
33
|
+
* @param suffix - the file suffix (e.g. .bam)
|
|
34
|
+
* @returns the constructed location object from the provided prameters
|
|
35
|
+
*/
|
|
36
|
+
export declare function makeIndex(location: FileLocation, suffix: string): import("./types").BlobLocation | {
|
|
37
|
+
uri: string;
|
|
38
|
+
locationType: string;
|
|
39
|
+
localPath?: undefined;
|
|
371
40
|
} | {
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
index?: undefined;
|
|
376
|
-
cramLocation?: undefined;
|
|
377
|
-
craiLocation?: undefined;
|
|
378
|
-
gffGzLocation?: undefined;
|
|
379
|
-
vcfLocation?: undefined;
|
|
380
|
-
vcfGzLocation?: undefined;
|
|
381
|
-
bedGzLocation?: undefined;
|
|
382
|
-
bigBedLocation?: undefined;
|
|
383
|
-
bigWigLocation?: undefined;
|
|
384
|
-
fastaLocation?: undefined;
|
|
385
|
-
faiLocation?: undefined;
|
|
386
|
-
gziLocation?: undefined;
|
|
387
|
-
twoBitLocation?: undefined;
|
|
388
|
-
rootUrlTemplate?: undefined;
|
|
389
|
-
endpoint?: undefined;
|
|
390
|
-
hicLocation?: undefined;
|
|
41
|
+
localPath: string;
|
|
42
|
+
locationType: string;
|
|
43
|
+
uri?: undefined;
|
|
391
44
|
};
|
|
392
|
-
|
|
45
|
+
/**
|
|
46
|
+
* constructs a potential index file (with suffix) from the provided file name
|
|
47
|
+
* @param name - the name of the index file
|
|
48
|
+
* @param typeA - one option of a potential two file suffix (e.g. CSI, BAI)
|
|
49
|
+
* @param typeB - the second option of a potential two file suffix (e.g. CSI, BAI)
|
|
50
|
+
* @returns a likely name of the index file for a given filename
|
|
51
|
+
*/
|
|
52
|
+
export declare function makeIndexType(name: string | undefined, typeA: string, typeB: string): string;
|
|
53
|
+
export interface AdapterConfig {
|
|
54
|
+
type: string;
|
|
55
|
+
[key: string]: unknown;
|
|
56
|
+
}
|
|
57
|
+
export declare type AdapterGuesser = (file: FileLocation, index?: FileLocation, adapterHint?: string) => AdapterConfig | undefined;
|
|
58
|
+
export declare type TrackTypeGuesser = (adapterName: string) => string | undefined;
|
|
59
|
+
export declare function getFileName(track: FileLocation): string;
|
|
60
|
+
export declare function guessAdapter(file: FileLocation, index: FileLocation | undefined, adapterHint?: string, model?: IAnyStateTreeNode): AdapterConfig;
|
|
61
|
+
export declare function guessTrackType(adapterType: string, model?: IAnyStateTreeNode): string;
|
|
393
62
|
export declare function generateUnsupportedTrackConf(trackName: string, trackUrl: string, categories: string[] | undefined): {
|
|
394
63
|
type: string;
|
|
395
64
|
name: string;
|