@jbrowse/plugin-circular-view 1.7.11 → 2.1.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/BaseChordDisplay/components/BaseChordDisplay.d.ts +2 -7
- package/dist/BaseChordDisplay/components/BaseChordDisplay.js +18 -48
- package/dist/BaseChordDisplay/components/BaseChordDisplay.js.map +1 -0
- package/dist/BaseChordDisplay/components/DisplayError.d.ts +9 -4
- package/dist/BaseChordDisplay/components/DisplayError.js +24 -67
- package/dist/BaseChordDisplay/components/DisplayError.js.map +1 -0
- package/dist/BaseChordDisplay/components/Loading.d.ts +2 -3
- package/dist/BaseChordDisplay/components/Loading.js +98 -112
- package/dist/BaseChordDisplay/components/Loading.js.map +1 -0
- package/dist/BaseChordDisplay/components/RpcRenderedSvgGroup.d.ts +3 -3
- package/dist/BaseChordDisplay/components/RpcRenderedSvgGroup.js +80 -91
- package/dist/BaseChordDisplay/components/RpcRenderedSvgGroup.js.map +1 -0
- package/dist/BaseChordDisplay/index.d.ts +1 -1
- package/dist/BaseChordDisplay/index.js +12 -30
- package/dist/BaseChordDisplay/index.js.map +1 -0
- package/dist/BaseChordDisplay/models/BaseChordDisplayModel.d.ts +10 -10
- package/dist/BaseChordDisplay/models/BaseChordDisplayModel.js +204 -232
- package/dist/BaseChordDisplay/models/BaseChordDisplayModel.js.map +1 -0
- package/dist/BaseChordDisplay/models/baseChordDisplayConfig.js +12 -18
- package/dist/BaseChordDisplay/models/baseChordDisplayConfig.js.map +1 -0
- package/dist/BaseChordDisplay/models/renderReaction.js +115 -138
- package/dist/BaseChordDisplay/models/renderReaction.js.map +1 -0
- package/dist/CircularView/components/CircularView.js +111 -185
- package/dist/CircularView/components/CircularView.js.map +1 -0
- package/dist/CircularView/components/ImportForm.js +77 -92
- package/dist/CircularView/components/ImportForm.js.map +1 -0
- package/dist/CircularView/components/Ruler.js +148 -194
- package/dist/CircularView/components/Ruler.js.map +1 -0
- package/dist/CircularView/models/CircularView.d.ts +3 -3
- package/dist/CircularView/models/CircularView.js +346 -409
- package/dist/CircularView/models/CircularView.js.map +1 -0
- package/dist/CircularView/models/slices.js +90 -104
- package/dist/CircularView/models/slices.js.map +1 -0
- package/dist/CircularView/models/viewportVisibleRegion.js +229 -264
- package/dist/CircularView/models/viewportVisibleRegion.js.map +1 -0
- package/dist/index.d.ts +3 -1
- package/dist/index.js +147 -176
- package/dist/index.js.map +1 -0
- package/esm/BaseChordDisplay/components/BaseChordDisplay.d.ts +4 -0
- package/esm/BaseChordDisplay/components/BaseChordDisplay.js +17 -0
- package/esm/BaseChordDisplay/components/BaseChordDisplay.js.map +1 -0
- package/esm/BaseChordDisplay/components/DisplayError.d.ts +9 -0
- package/esm/BaseChordDisplay/components/DisplayError.js +21 -0
- package/esm/BaseChordDisplay/components/DisplayError.js.map +1 -0
- package/esm/BaseChordDisplay/components/Loading.d.ts +9 -0
- package/esm/BaseChordDisplay/components/Loading.js +66 -0
- package/esm/BaseChordDisplay/components/Loading.js.map +1 -0
- package/esm/BaseChordDisplay/components/RpcRenderedSvgGroup.d.ts +4 -0
- package/esm/BaseChordDisplay/components/RpcRenderedSvgGroup.js +48 -0
- package/esm/BaseChordDisplay/components/RpcRenderedSvgGroup.js.map +1 -0
- package/esm/BaseChordDisplay/index.d.ts +3 -0
- package/esm/BaseChordDisplay/index.js +4 -0
- package/esm/BaseChordDisplay/index.js.map +1 -0
- package/esm/BaseChordDisplay/models/BaseChordDisplayModel.d.ts +99 -0
- package/esm/BaseChordDisplay/models/BaseChordDisplayModel.js +181 -0
- package/esm/BaseChordDisplay/models/BaseChordDisplayModel.js.map +1 -0
- package/esm/BaseChordDisplay/models/baseChordDisplayConfig.d.ts +2 -0
- package/esm/BaseChordDisplay/models/baseChordDisplayConfig.js +11 -0
- package/esm/BaseChordDisplay/models/baseChordDisplayConfig.js.map +1 -0
- package/esm/BaseChordDisplay/models/renderReaction.d.ts +30 -0
- package/esm/BaseChordDisplay/models/renderReaction.js +52 -0
- package/esm/BaseChordDisplay/models/renderReaction.js.map +1 -0
- package/esm/CircularView/components/CircularView.d.ts +4 -0
- package/esm/CircularView/components/CircularView.js +121 -0
- package/esm/CircularView/components/CircularView.js.map +1 -0
- package/esm/CircularView/components/ImportForm.d.ts +5 -0
- package/esm/CircularView/components/ImportForm.js +40 -0
- package/esm/CircularView/components/ImportForm.js.map +1 -0
- package/esm/CircularView/components/Ruler.d.ts +5 -0
- package/esm/CircularView/components/Ruler.js +126 -0
- package/esm/CircularView/components/Ruler.js.map +1 -0
- package/esm/CircularView/models/CircularView.d.ts +97 -0
- package/esm/CircularView/models/CircularView.js +317 -0
- package/esm/CircularView/models/CircularView.js.map +1 -0
- package/esm/CircularView/models/slices.d.ts +27 -0
- package/esm/CircularView/models/slices.js +53 -0
- package/esm/CircularView/models/slices.js.map +1 -0
- package/esm/CircularView/models/viewportVisibleRegion.d.ts +6 -0
- package/esm/CircularView/models/viewportVisibleRegion.js +223 -0
- package/esm/CircularView/models/viewportVisibleRegion.js.map +1 -0
- package/esm/index.d.ts +10 -0
- package/esm/index.js +49 -0
- package/esm/index.js.map +1 -0
- package/package.json +20 -12
- package/src/BaseChordDisplay/components/BaseChordDisplay.tsx +13 -25
- package/src/BaseChordDisplay/components/DisplayError.js +64 -66
- package/src/BaseChordDisplay/components/Loading.tsx +104 -107
- package/src/BaseChordDisplay/components/RpcRenderedSvgGroup.js +44 -51
- package/src/BaseChordDisplay/index.ts +1 -1
- package/src/BaseChordDisplay/models/BaseChordDisplayModel.ts +2 -1
- package/src/CircularView/components/CircularView.js +17 -16
- package/src/CircularView/components/ImportForm.tsx +5 -5
- package/src/CircularView/components/Ruler.js +4 -3
- package/src/CircularView/models/CircularView.ts +29 -42
- package/src/CircularView/models/slices.ts +2 -7
- package/src/index.ts +5 -2
- package/dist/CircularView/models/slices.test.js +0 -83
- package/dist/CircularView/models/viewportVisibleRegion.test.js +0 -130
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { default as
|
|
1
|
+
export { default as BaseChordDisplayComponent } from './components/BaseChordDisplay';
|
|
2
2
|
export { BaseChordDisplayModel } from './models/BaseChordDisplayModel';
|
|
3
3
|
export { baseChordDisplayConfig } from './models/baseChordDisplayConfig';
|
|
@@ -1,31 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
Object.defineProperty(exports, "
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Object.defineProperty(exports, "BaseChordDisplayModel", {
|
|
15
|
-
enumerable: true,
|
|
16
|
-
get: function get() {
|
|
17
|
-
return _BaseChordDisplayModel.BaseChordDisplayModel;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
Object.defineProperty(exports, "baseChordDisplayConfig", {
|
|
21
|
-
enumerable: true,
|
|
22
|
-
get: function get() {
|
|
23
|
-
return _baseChordDisplayConfig.baseChordDisplayConfig;
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _BaseChordDisplay = _interopRequireDefault(require("./components/BaseChordDisplay"));
|
|
28
|
-
|
|
29
|
-
var _BaseChordDisplayModel = require("./models/BaseChordDisplayModel");
|
|
30
|
-
|
|
31
|
-
var _baseChordDisplayConfig = require("./models/baseChordDisplayConfig");
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.baseChordDisplayConfig = exports.BaseChordDisplayModel = exports.BaseChordDisplayComponent = void 0;
|
|
7
|
+
var BaseChordDisplay_1 = require("./components/BaseChordDisplay");
|
|
8
|
+
Object.defineProperty(exports, "BaseChordDisplayComponent", { enumerable: true, get: function () { return __importDefault(BaseChordDisplay_1).default; } });
|
|
9
|
+
var BaseChordDisplayModel_1 = require("./models/BaseChordDisplayModel");
|
|
10
|
+
Object.defineProperty(exports, "BaseChordDisplayModel", { enumerable: true, get: function () { return BaseChordDisplayModel_1.BaseChordDisplayModel; } });
|
|
11
|
+
var baseChordDisplayConfig_1 = require("./models/baseChordDisplayConfig");
|
|
12
|
+
Object.defineProperty(exports, "baseChordDisplayConfig", { enumerable: true, get: function () { return baseChordDisplayConfig_1.baseChordDisplayConfig; } });
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/BaseChordDisplay/index.ts"],"names":[],"mappings":";;;;;;AAAA,kEAAoF;AAA3E,8IAAA,OAAO,OAA6B;AAC7C,wEAAsE;AAA7D,8HAAA,qBAAqB,OAAA;AAC9B,0EAAwE;AAA/D,gIAAA,sBAAsB,OAAA"}
|
|
@@ -14,11 +14,11 @@ export declare const BaseChordDisplayModel: import("mobx-state-tree").IModelType
|
|
|
14
14
|
error: unknown;
|
|
15
15
|
} & {
|
|
16
16
|
readonly RenderingComponent: React.FC<{
|
|
17
|
-
model:
|
|
18
|
-
id:
|
|
19
|
-
type:
|
|
20
|
-
rpcDriverName:
|
|
21
|
-
}
|
|
17
|
+
model: {
|
|
18
|
+
id: string;
|
|
19
|
+
type: string;
|
|
20
|
+
rpcDriverName: string | undefined;
|
|
21
|
+
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
22
22
|
rendererTypeName: string;
|
|
23
23
|
error: unknown;
|
|
24
24
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
@@ -33,11 +33,11 @@ export declare const BaseChordDisplayModel: import("mobx-state-tree").IModelType
|
|
|
33
33
|
blockState?: Record<string, any> | undefined;
|
|
34
34
|
}>;
|
|
35
35
|
readonly DisplayBlurb: React.FC<{
|
|
36
|
-
model:
|
|
37
|
-
id:
|
|
38
|
-
type:
|
|
39
|
-
rpcDriverName:
|
|
40
|
-
}
|
|
36
|
+
model: {
|
|
37
|
+
id: string;
|
|
38
|
+
type: string;
|
|
39
|
+
rpcDriverName: string | undefined;
|
|
40
|
+
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
41
41
|
rendererTypeName: string;
|
|
42
42
|
error: unknown;
|
|
43
43
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
@@ -1,261 +1,233 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
var
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
renderingComponent: undefined,
|
|
48
|
-
refNameMap: undefined
|
|
49
|
-
};
|
|
50
|
-
}).actions(function (self) {
|
|
51
|
-
var _getEnv = (0, _mobxStateTree.getEnv)(self),
|
|
52
|
-
pluginManager = _getEnv.pluginManager;
|
|
53
|
-
|
|
54
|
-
var track = self;
|
|
55
|
-
return {
|
|
56
|
-
onChordClick: function onChordClick(feature) {
|
|
57
|
-
(0, _configuration.getConf)(self, 'onChordClick', {
|
|
58
|
-
feature: feature,
|
|
59
|
-
track: track,
|
|
60
|
-
pluginManager: pluginManager
|
|
61
|
-
});
|
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
|
3
|
+
__assign = Object.assign || function(t) {
|
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
+
s = arguments[i];
|
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
+
t[p] = s[p];
|
|
8
|
+
}
|
|
9
|
+
return t;
|
|
10
|
+
};
|
|
11
|
+
return __assign.apply(this, arguments);
|
|
12
|
+
};
|
|
13
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
14
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
15
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
16
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
17
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
18
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
19
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
23
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
24
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
25
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
26
|
+
function step(op) {
|
|
27
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
28
|
+
while (_) try {
|
|
29
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
30
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
31
|
+
switch (op[0]) {
|
|
32
|
+
case 0: case 1: t = op; break;
|
|
33
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
34
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
35
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
36
|
+
default:
|
|
37
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
38
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
39
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
40
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
41
|
+
if (t[2]) _.ops.pop();
|
|
42
|
+
_.trys.pop(); continue;
|
|
43
|
+
}
|
|
44
|
+
op = body.call(thisArg, _);
|
|
45
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
46
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
62
47
|
}
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
48
|
+
};
|
|
49
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
50
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
51
|
+
};
|
|
52
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53
|
+
exports.BaseChordDisplayModel = void 0;
|
|
54
|
+
var configuration_1 = require("@jbrowse/core/configuration");
|
|
55
|
+
var models_1 = require("@jbrowse/core/pluggableElementTypes/models");
|
|
56
|
+
var CircularChordRendererType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/renderers/CircularChordRendererType"));
|
|
57
|
+
var util_1 = require("@jbrowse/core/util");
|
|
58
|
+
var simpleFeature_1 = require("@jbrowse/core/util/simpleFeature");
|
|
59
|
+
var tracks_1 = require("@jbrowse/core/util/tracks");
|
|
60
|
+
var mobx_state_tree_1 = require("mobx-state-tree");
|
|
61
|
+
var renderReaction_1 = __importDefault(require("./renderReaction"));
|
|
62
|
+
exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
63
|
+
.compose('BaseChordDisplay', models_1.BaseDisplay, mobx_state_tree_1.types.model({
|
|
64
|
+
bezierRadiusRatio: 0.1,
|
|
65
|
+
assemblyName: mobx_state_tree_1.types.maybe(mobx_state_tree_1.types.string),
|
|
66
|
+
}))
|
|
67
|
+
.volatile(function () {
|
|
68
|
+
return {
|
|
69
|
+
// NOTE: all this volatile stuff has to be filled in at once
|
|
70
|
+
// so that it stays consistent
|
|
71
|
+
filled: false,
|
|
72
|
+
reactElement: undefined,
|
|
73
|
+
data: undefined,
|
|
74
|
+
message: '',
|
|
75
|
+
renderingComponent: undefined,
|
|
76
|
+
refNameMap: undefined,
|
|
77
|
+
};
|
|
78
|
+
})
|
|
79
|
+
.actions(function (self) {
|
|
80
|
+
var pluginManager = (0, mobx_state_tree_1.getEnv)(self).pluginManager;
|
|
81
|
+
var track = self;
|
|
82
|
+
return {
|
|
83
|
+
onChordClick: function (feature) {
|
|
84
|
+
(0, configuration_1.getConf)(self, 'onChordClick', { feature: feature, track: track, pluginManager: pluginManager });
|
|
85
|
+
},
|
|
86
|
+
};
|
|
87
|
+
})
|
|
88
|
+
.views(function (self) { return ({
|
|
66
89
|
get blockDefinitions() {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
90
|
+
var origSlices = (0, util_1.getContainingView)(self)
|
|
91
|
+
.staticSlices;
|
|
92
|
+
if (!self.refNameMap) {
|
|
93
|
+
return origSlices;
|
|
94
|
+
}
|
|
95
|
+
var slices = JSON.parse(JSON.stringify(origSlices));
|
|
96
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
97
|
+
slices.forEach(function (slice) {
|
|
98
|
+
var regions = slice.region.elided
|
|
99
|
+
? slice.region.regions
|
|
100
|
+
: [slice.region];
|
|
101
|
+
regions.forEach(function (region) {
|
|
102
|
+
var _a;
|
|
103
|
+
var renamed = (_a = self.refNameMap) === null || _a === void 0 ? void 0 : _a[region.refName];
|
|
104
|
+
if (renamed && region.refName !== renamed) {
|
|
105
|
+
region.refName = renamed;
|
|
106
|
+
}
|
|
107
|
+
});
|
|
85
108
|
});
|
|
86
|
-
|
|
87
|
-
return slices;
|
|
109
|
+
return slices;
|
|
88
110
|
},
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
return _objectSpread(_objectSpread({}, (0, _tracks.getParentRenderProps)(self)), {}, {
|
|
93
|
-
rpcDriverName: self.rpcDriverName,
|
|
94
|
-
displayModel: self,
|
|
95
|
-
bezierRadius: view.radiusPx * self.bezierRadiusRatio,
|
|
96
|
-
radius: view.radiusPx,
|
|
97
|
-
blockDefinitions: this.blockDefinitions,
|
|
98
|
-
onChordClick: self.onChordClick
|
|
99
|
-
});
|
|
111
|
+
renderProps: function () {
|
|
112
|
+
var view = (0, util_1.getContainingView)(self);
|
|
113
|
+
return __assign(__assign({}, (0, tracks_1.getParentRenderProps)(self)), { rpcDriverName: self.rpcDriverName, displayModel: self, bezierRadius: view.radiusPx * self.bezierRadiusRatio, radius: view.radiusPx, blockDefinitions: this.blockDefinitions, onChordClick: self.onChordClick });
|
|
100
114
|
},
|
|
101
|
-
|
|
102
115
|
/**
|
|
103
116
|
* the pluggable element type object for this diplay's
|
|
104
117
|
* renderer
|
|
105
118
|
*/
|
|
106
119
|
get rendererType() {
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
if (!ThisRendererType.ReactComponent) {
|
|
119
|
-
throw new Error("renderer ".concat(display.rendererTypeName, " has no ReactComponent, it may not be completely implemented yet"));
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
return ThisRendererType;
|
|
120
|
+
var display = self;
|
|
121
|
+
var pluginManager = (0, mobx_state_tree_1.getEnv)(self).pluginManager;
|
|
122
|
+
var ThisRendererType = pluginManager.getRendererType(self.rendererTypeName);
|
|
123
|
+
if (!ThisRendererType) {
|
|
124
|
+
throw new Error("renderer \"".concat(display.rendererTypeName, "\" not found"));
|
|
125
|
+
}
|
|
126
|
+
if (!ThisRendererType.ReactComponent) {
|
|
127
|
+
throw new Error("renderer ".concat(display.rendererTypeName, " has no ReactComponent, it may not be completely implemented yet"));
|
|
128
|
+
}
|
|
129
|
+
return ThisRendererType;
|
|
123
130
|
},
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
return !!(renderer instanceof _CircularChordRendererType.default);
|
|
131
|
+
isCompatibleWithRenderer: function (renderer) {
|
|
132
|
+
return !!(renderer instanceof CircularChordRendererType_1.default);
|
|
127
133
|
},
|
|
128
|
-
|
|
129
134
|
/**
|
|
130
135
|
* returns a string feature ID if the globally-selected object
|
|
131
136
|
* is probably a feature
|
|
132
137
|
*/
|
|
133
138
|
get selectedFeatureId() {
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
139
|
+
if (!(0, mobx_state_tree_1.isAlive)(self)) {
|
|
140
|
+
return undefined;
|
|
141
|
+
}
|
|
142
|
+
var session = (0, util_1.getSession)(self);
|
|
143
|
+
if (!session) {
|
|
144
|
+
return undefined;
|
|
145
|
+
}
|
|
146
|
+
var selection = session.selection;
|
|
147
|
+
// does it quack like a feature?
|
|
148
|
+
if ((0, simpleFeature_1.isFeature)(selection)) {
|
|
149
|
+
return selection.id();
|
|
150
|
+
}
|
|
141
151
|
return undefined;
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
var selection = session.selection; // does it quack like a feature?
|
|
145
|
-
|
|
146
|
-
if ((0, _simpleFeature.isFeature)(selection)) {
|
|
147
|
-
return selection.id();
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
return undefined;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
};
|
|
154
|
-
}).actions(function (self) {
|
|
155
|
-
return {
|
|
156
|
-
renderStarted: function renderStarted() {
|
|
157
|
-
self.filled = false;
|
|
158
|
-
self.message = '';
|
|
159
|
-
self.reactElement = undefined;
|
|
160
|
-
self.data = undefined;
|
|
161
|
-
self.error = undefined;
|
|
162
|
-
self.renderingComponent = undefined;
|
|
163
152
|
},
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
reactElement = _ref.reactElement,
|
|
168
|
-
renderingComponent = _ref.renderingComponent;
|
|
169
|
-
|
|
170
|
-
if (message) {
|
|
153
|
+
}); })
|
|
154
|
+
.actions(function (self) { return ({
|
|
155
|
+
renderStarted: function () {
|
|
171
156
|
self.filled = false;
|
|
172
|
-
self.message =
|
|
157
|
+
self.message = '';
|
|
173
158
|
self.reactElement = undefined;
|
|
174
159
|
self.data = undefined;
|
|
175
160
|
self.error = undefined;
|
|
176
161
|
self.renderingComponent = undefined;
|
|
177
|
-
} else {
|
|
178
|
-
self.filled = true;
|
|
179
|
-
self.message = '';
|
|
180
|
-
self.reactElement = reactElement;
|
|
181
|
-
self.data = data;
|
|
182
|
-
self.error = undefined;
|
|
183
|
-
self.renderingComponent = renderingComponent;
|
|
184
|
-
}
|
|
185
162
|
},
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
163
|
+
renderSuccess: function (_a) {
|
|
164
|
+
var message = _a.message, data = _a.data, reactElement = _a.reactElement, renderingComponent = _a.renderingComponent;
|
|
165
|
+
if (message) {
|
|
166
|
+
self.filled = false;
|
|
167
|
+
self.message = message;
|
|
168
|
+
self.reactElement = undefined;
|
|
169
|
+
self.data = undefined;
|
|
170
|
+
self.error = undefined;
|
|
171
|
+
self.renderingComponent = undefined;
|
|
172
|
+
}
|
|
173
|
+
else {
|
|
174
|
+
self.filled = true;
|
|
175
|
+
self.message = '';
|
|
176
|
+
self.reactElement = reactElement;
|
|
177
|
+
self.data = data;
|
|
178
|
+
self.error = undefined;
|
|
179
|
+
self.renderingComponent = renderingComponent;
|
|
180
|
+
}
|
|
195
181
|
},
|
|
196
|
-
|
|
197
|
-
self.refNameMap = refNameMap;
|
|
198
|
-
}
|
|
199
|
-
};
|
|
200
|
-
}).actions(function (self) {
|
|
201
|
-
var _getEnv3 = (0, _mobxStateTree.getEnv)(self),
|
|
202
|
-
pluginManager = _getEnv3.pluginManager;
|
|
203
|
-
|
|
204
|
-
var _pluginManager$jbrequ = pluginManager.jbrequire(_renderReaction.default),
|
|
205
|
-
renderReactionData = _pluginManager$jbrequ.renderReactionData,
|
|
206
|
-
renderReactionEffect = _pluginManager$jbrequ.renderReactionEffect;
|
|
207
|
-
|
|
208
|
-
return {
|
|
209
|
-
afterAttach: function afterAttach() {
|
|
210
|
-
(0, _util.makeAbortableReaction)(self, renderReactionData, renderReactionEffect, {
|
|
211
|
-
name: "".concat(self.type, " ").concat(self.id, " rendering"),
|
|
212
|
-
// delay: self.renderDelay || 300,
|
|
213
|
-
fireImmediately: true
|
|
214
|
-
}, self.renderStarted, self.renderSuccess, self.renderError);
|
|
215
|
-
(0, _util.makeAbortableReaction)(self, function () {
|
|
216
|
-
return {
|
|
217
|
-
assemblyNames: (0, _tracks.getTrackAssemblyNames)(self.parentTrack),
|
|
218
|
-
adapter: (0, _configuration.getConf)((0, _mobxStateTree.getParent)(self, 2), 'adapter'),
|
|
219
|
-
assemblyManager: (0, _util.getSession)(self).assemblyManager
|
|
220
|
-
};
|
|
221
|
-
},
|
|
222
|
-
/*#__PURE__*/
|
|
223
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
224
|
-
function () {
|
|
225
|
-
var _ref3 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(_ref2, signal) {
|
|
226
|
-
var assemblyNames, adapter, assemblyManager;
|
|
227
|
-
return _regenerator.default.wrap(function _callee$(_context) {
|
|
228
|
-
while (1) {
|
|
229
|
-
switch (_context.prev = _context.next) {
|
|
230
|
-
case 0:
|
|
231
|
-
assemblyNames = _ref2.assemblyNames, adapter = _ref2.adapter, assemblyManager = _ref2.assemblyManager;
|
|
232
|
-
return _context.abrupt("return", assemblyManager.getRefNameMapForAdapter(adapter, assemblyNames[0], {
|
|
233
|
-
signal: signal,
|
|
234
|
-
sessionId: (0, _tracks.getRpcSessionId)(self)
|
|
235
|
-
}));
|
|
236
|
-
|
|
237
|
-
case 2:
|
|
238
|
-
case "end":
|
|
239
|
-
return _context.stop();
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
}, _callee);
|
|
243
|
-
}));
|
|
244
|
-
|
|
245
|
-
return function (_x, _x2) {
|
|
246
|
-
return _ref3.apply(this, arguments);
|
|
247
|
-
};
|
|
248
|
-
}(), {
|
|
249
|
-
name: "".concat(self.type, " ").concat(self.id, " getting refNames"),
|
|
250
|
-
fireImmediately: true
|
|
251
|
-
}, function () {}, function (refNameMap) {
|
|
252
|
-
self.setRefNameMap(refNameMap);
|
|
253
|
-
}, function (error) {
|
|
182
|
+
renderError: function (error) {
|
|
254
183
|
console.error(error);
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
184
|
+
// the rendering failed for some reason
|
|
185
|
+
self.filled = false;
|
|
186
|
+
self.message = '';
|
|
187
|
+
self.reactElement = undefined;
|
|
188
|
+
self.data = undefined;
|
|
189
|
+
self.error = error;
|
|
190
|
+
self.renderingComponent = undefined;
|
|
191
|
+
},
|
|
192
|
+
setRefNameMap: function (refNameMap) {
|
|
193
|
+
self.refNameMap = refNameMap;
|
|
194
|
+
},
|
|
195
|
+
}); })
|
|
196
|
+
.actions(function (self) {
|
|
197
|
+
var pluginManager = (0, mobx_state_tree_1.getEnv)(self).pluginManager;
|
|
198
|
+
var _a = pluginManager.jbrequire(renderReaction_1.default), renderReactionData = _a.renderReactionData, renderReactionEffect = _a.renderReactionEffect;
|
|
199
|
+
return {
|
|
200
|
+
afterAttach: function () {
|
|
201
|
+
var _this = this;
|
|
202
|
+
(0, util_1.makeAbortableReaction)(self, renderReactionData, renderReactionEffect, {
|
|
203
|
+
name: "".concat(self.type, " ").concat(self.id, " rendering"),
|
|
204
|
+
// delay: self.renderDelay || 300,
|
|
205
|
+
fireImmediately: true,
|
|
206
|
+
}, self.renderStarted, self.renderSuccess, self.renderError);
|
|
207
|
+
(0, util_1.makeAbortableReaction)(self, function () { return ({
|
|
208
|
+
assemblyNames: (0, tracks_1.getTrackAssemblyNames)(self.parentTrack),
|
|
209
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
210
|
+
adapter: (0, configuration_1.getConf)((0, mobx_state_tree_1.getParent)(self, 2), 'adapter'),
|
|
211
|
+
assemblyManager: (0, util_1.getSession)(self).assemblyManager,
|
|
212
|
+
}); },
|
|
213
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
214
|
+
function (_a, signal) {
|
|
215
|
+
var assemblyNames = _a.assemblyNames, adapter = _a.adapter, assemblyManager = _a.assemblyManager;
|
|
216
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
217
|
+
return __generator(this, function (_b) {
|
|
218
|
+
return [2 /*return*/, assemblyManager.getRefNameMapForAdapter(adapter, assemblyNames[0], { signal: signal, sessionId: (0, tracks_1.getRpcSessionId)(self) })];
|
|
219
|
+
});
|
|
220
|
+
});
|
|
221
|
+
}, {
|
|
222
|
+
name: "".concat(self.type, " ").concat(self.id, " getting refNames"),
|
|
223
|
+
fireImmediately: true,
|
|
224
|
+
}, function () { }, function (refNameMap) {
|
|
225
|
+
self.setRefNameMap(refNameMap);
|
|
226
|
+
}, function (error) {
|
|
227
|
+
console.error(error);
|
|
228
|
+
self.setError(error);
|
|
229
|
+
});
|
|
230
|
+
},
|
|
231
|
+
};
|
|
259
232
|
});
|
|
260
|
-
|
|
261
|
-
exports.BaseChordDisplayModel = BaseChordDisplayModel;
|
|
233
|
+
//# sourceMappingURL=BaseChordDisplayModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseChordDisplayModel.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/BaseChordDisplayModel.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6DAAqD;AACrD,qEAAwE;AACxE,sIAA+G;AAE/G,2CAK2B;AAC3B,kEAAqE;AACrE,oDAIkC;AAElC,mDAAmE;AAEnE,oEAAoD;AAGvC,QAAA,qBAAqB,GAAG,uBAAK;KACvC,OAAO,CACN,kBAAkB,EAClB,oBAAW,EACX,uBAAK,CAAC,KAAK,CAAC;IACV,iBAAiB,EAAE,GAAG;IACtB,YAAY,EAAE,uBAAK,CAAC,KAAK,CAAC,uBAAK,CAAC,MAAM,CAAC;CACxC,CAAC,CACH;KACA,QAAQ,CAAC;IACR,OAAO;QACL,4DAA4D;QAC5D,8BAA8B;QAC9B,MAAM,EAAE,KAAK;QACb,YAAY,EAAE,SAA2C;QACzD,IAAI,EAAE,SAAS;QACf,OAAO,EAAE,EAAE;QACX,kBAAkB,EAAE,SAA8C;QAClE,UAAU,EAAE,SAA+C;KAC5D,CAAA;AACH,CAAC,CAAC;KACD,OAAO,CAAC,UAAA,IAAI;IACH,IAAA,aAAa,GAAK,IAAA,wBAAM,EAAC,IAAI,CAAC,cAAjB,CAAiB;IACtC,IAAM,KAAK,GAAG,IAAI,CAAA;IAClB,OAAO;QACL,YAAY,EAAZ,UAAa,OAAgB;YAC3B,IAAA,uBAAO,EAAC,IAAI,EAAE,cAAc,EAAE,EAAE,OAAO,SA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EAAE,IAAA,wBAAe,EAAC,IAAI,CAAC,EAAE,CAC7C,EAAA;;;aACF,EACD;gBACE,IAAI,EAAE,UAAG,IAAI,CAAC,IAAI,cAAI,IAAI,CAAC,EAAE,sBAAmB;gBAChD,eAAe,EAAE,IAAI;aACtB,EACD,cAAO,CAAC,EACR,UAAA,UAAU;gBACR,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,CAAA;YAChC,CAAC,EACD,UAAA,KAAK;gBACH,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAA;gBACpB,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;YACtB,CAAC,CACF,CAAA;QACH,CAAC;KACF,CAAA;AACH,CAAC,CAAC,CAAA"}
|
|
@@ -1,20 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.baseChordDisplayConfig = void 0;
|
|
7
|
-
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
explicitIdentifier: 'displayId'
|
|
19
|
-
});
|
|
20
|
-
exports.baseChordDisplayConfig = baseChordDisplayConfig;
|
|
4
|
+
var configuration_1 = require("@jbrowse/core/configuration");
|
|
5
|
+
var baseChordDisplayConfig = (0, configuration_1.ConfigurationSchema)('BaseChordDisplay', {
|
|
6
|
+
onChordClick: {
|
|
7
|
+
type: 'boolean',
|
|
8
|
+
description: 'callback that should be run when a chord in the track is clicked',
|
|
9
|
+
defaultValue: false,
|
|
10
|
+
contextVariable: ['feature', 'track', 'pluginManager'],
|
|
11
|
+
},
|
|
12
|
+
}, { explicitIdentifier: 'displayId' });
|
|
13
|
+
exports.baseChordDisplayConfig = baseChordDisplayConfig;
|
|
14
|
+
//# sourceMappingURL=baseChordDisplayConfig.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"baseChordDisplayConfig.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/baseChordDisplayConfig.ts"],"names":[],"mappings":";;;AAAA,6DAAiE;AAEjE,IAAM,sBAAsB,GAAG,IAAA,mCAAmB,EAChD,kBAAkB,EAClB;IACE,YAAY,EAAE;QACZ,IAAI,EAAE,SAAS;QACf,WAAW,EACT,kEAAkE;QACpE,YAAY,EAAE,KAAK;QACnB,eAAe,EAAE,CAAC,SAAS,EAAE,OAAO,EAAE,eAAe,CAAC;KACvD;CACF,EACD,EAAE,kBAAkB,EAAE,WAAW,EAAE,CACpC,CAAA;AAEQ,wDAAsB"}
|