@jbrowse/plugin-circular-view 2.0.0 → 2.1.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/dist/BaseChordDisplay/components/BaseChordDisplay.js +6 -7
- package/dist/BaseChordDisplay/components/BaseChordDisplay.js.map +1 -1
- package/dist/BaseChordDisplay/components/DisplayError.js +6 -7
- package/dist/BaseChordDisplay/components/DisplayError.js.map +1 -1
- package/dist/BaseChordDisplay/components/Loading.js +14 -32
- package/dist/BaseChordDisplay/components/Loading.js.map +1 -1
- package/dist/BaseChordDisplay/components/RpcRenderedSvgGroup.js +14 -26
- package/dist/BaseChordDisplay/components/RpcRenderedSvgGroup.js.map +1 -1
- package/dist/BaseChordDisplay/models/BaseChordDisplayModel.js +59 -105
- package/dist/BaseChordDisplay/models/BaseChordDisplayModel.js.map +1 -1
- package/dist/BaseChordDisplay/models/baseChordDisplayConfig.js +2 -2
- package/dist/BaseChordDisplay/models/baseChordDisplayConfig.js.map +1 -1
- package/dist/BaseChordDisplay/models/renderReaction.js +34 -99
- package/dist/BaseChordDisplay/models/renderReaction.js.map +1 -1
- package/dist/CircularView/components/CircularView.js +34 -37
- package/dist/CircularView/components/CircularView.js.map +1 -1
- package/dist/CircularView/components/ImportForm.js +21 -38
- package/dist/CircularView/components/ImportForm.js.map +1 -1
- package/dist/CircularView/components/Ruler.js +53 -81
- package/dist/CircularView/components/Ruler.js.map +1 -1
- package/dist/CircularView/models/CircularView.js +104 -143
- package/dist/CircularView/models/CircularView.js.map +1 -1
- package/dist/CircularView/models/slices.js +20 -59
- package/dist/CircularView/models/slices.js.map +1 -1
- package/dist/CircularView/models/viewportVisibleRegion.js +25 -41
- package/dist/CircularView/models/viewportVisibleRegion.js.map +1 -1
- package/dist/index.js +35 -106
- package/dist/index.js.map +1 -1
- package/esm/BaseChordDisplay/components/Loading.js +0 -1
- package/esm/BaseChordDisplay/components/Loading.js.map +1 -1
- package/package.json +3 -4
- package/src/BaseChordDisplay/components/Loading.tsx +0 -1
|
@@ -3,14 +3,13 @@ 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
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const mobx_react_1 = require("mobx-react");
|
|
8
|
+
const Loading_1 = __importDefault(require("./Loading"));
|
|
9
|
+
const DisplayError_1 = __importDefault(require("./DisplayError"));
|
|
10
|
+
const RpcRenderedSvgGroup_1 = __importDefault(require("./RpcRenderedSvgGroup"));
|
|
11
11
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
12
|
-
function BaseChordDisplay(
|
|
13
|
-
var display = _a.display;
|
|
12
|
+
function BaseChordDisplay({ display }) {
|
|
14
13
|
if (display.error) {
|
|
15
14
|
return react_1.default.createElement(DisplayError_1.default, { model: display });
|
|
16
15
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseChordDisplay.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/BaseChordDisplay.tsx"],"names":[],"mappings":";;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"BaseChordDisplay.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/BaseChordDisplay.tsx"],"names":[],"mappings":";;;;;AAAA,kDAAyB;AACzB,2CAAqC;AACrC,wDAA+B;AAC/B,kEAAyC;AACzC,gFAAuD;AACvD,8DAA8D;AAC9D,SAAS,gBAAgB,CAAC,EAAE,OAAO,EAAO;IACxC,IAAI,OAAO,CAAC,KAAK,EAAE;QACjB,OAAO,8BAAC,sBAAY,IAAC,KAAK,EAAE,OAAO,GAAI,CAAA;KACxC;IACD,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE;QACnB,OAAO,8BAAC,iBAAO,IAAC,KAAK,EAAE,OAAO,GAAI,CAAA;KACnC;IACD,OAAO,8BAAC,6BAAmB,IAAC,KAAK,EAAE,OAAO,GAAI,CAAA;AAChD,CAAC;AACD,kBAAe,IAAA,qBAAQ,EAAC,gBAAgB,CAAC,CAAA"}
|
|
@@ -3,18 +3,17 @@ 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
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const mobx_react_1 = require("mobx-react");
|
|
8
|
+
const mui_1 = require("tss-react/mui");
|
|
9
|
+
const useStyles = (0, mui_1.makeStyles)()({
|
|
10
10
|
errorMessage: {},
|
|
11
11
|
errorBackground: {},
|
|
12
12
|
errorText: {},
|
|
13
13
|
});
|
|
14
14
|
// 'repeating-linear-gradient(45deg, transparent, transparent 5px, rgba(255,255,255,.5) 5px, rgba(255,255,255,.5) 10px)',
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
var classes = useStyles().classes;
|
|
15
|
+
const DisplayError = (0, mobx_react_1.observer)(({ model: { renderProps: { radius }, error, }, }) => {
|
|
16
|
+
const { classes } = useStyles();
|
|
18
17
|
return (react_1.default.createElement("g", { className: classes.errorMessage },
|
|
19
18
|
react_1.default.createElement("defs", null,
|
|
20
19
|
react_1.default.createElement("pattern", { id: "diagonalHatch", width: "10", height: "10", patternTransform: "rotate(45 0 0)", patternUnits: "userSpaceOnUse" },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DisplayError.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/DisplayError.js"],"names":[],"mappings":";;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"DisplayError.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/DisplayError.js"],"names":[],"mappings":";;;;;AAAA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C,KAAK,CAAC,CACT,CACL,CACL,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,YAAY,CAAA"}
|
|
@@ -22,36 +22,19 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
22
22
|
__setModuleDefault(result, mod);
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
|
-
var __read = (this && this.__read) || function (o, n) {
|
|
26
|
-
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
27
|
-
if (!m) return o;
|
|
28
|
-
var i = m.call(o), r, ar = [], e;
|
|
29
|
-
try {
|
|
30
|
-
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
31
|
-
}
|
|
32
|
-
catch (error) { e = { error: error }; }
|
|
33
|
-
finally {
|
|
34
|
-
try {
|
|
35
|
-
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
36
|
-
}
|
|
37
|
-
finally { if (e) throw e.error; }
|
|
38
|
-
}
|
|
39
|
-
return ar;
|
|
40
|
-
};
|
|
41
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
var _a = theme.palette, primary = _a.primary, secondary = _a.secondary, tertiary = _a.tertiary, quaternary = _a.quaternary;
|
|
26
|
+
const react_1 = __importStar(require("react"));
|
|
27
|
+
const mui_1 = require("tss-react/mui");
|
|
28
|
+
const mobx_react_1 = require("mobx-react");
|
|
29
|
+
const useStyles = (0, mui_1.makeStyles)()(theme => {
|
|
30
|
+
const offset = 2;
|
|
31
|
+
const duration = 1.4;
|
|
32
|
+
const { primary, secondary, tertiary, quaternary } = theme.palette;
|
|
50
33
|
return {
|
|
51
34
|
path: {
|
|
52
35
|
strokeDasharray: 187,
|
|
53
36
|
strokeDashoffset: 50,
|
|
54
|
-
animation:
|
|
37
|
+
animation: `$dash ${duration}s ease-in-out infinite, $colors ${duration * 4}s ease-in-out infinite`,
|
|
55
38
|
},
|
|
56
39
|
'@keyframes colors': {
|
|
57
40
|
'0%': {
|
|
@@ -86,14 +69,13 @@ var useStyles = (0, mui_1.makeStyles)()(function (theme) {
|
|
|
86
69
|
};
|
|
87
70
|
});
|
|
88
71
|
// 'repeating-linear-gradient(45deg, transparent, transparent 5px, rgba(255,255,255,.5) 5px, rgba(255,255,255,.5) 10px)',
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
var classes = useStyles().classes;
|
|
72
|
+
const Loading = (0, mobx_react_1.observer)(({ model: { renderProps: { radius }, }, }) => {
|
|
73
|
+
const { classes } = useStyles();
|
|
92
74
|
// only show the loading message after 400ms to prevent excessive flickering
|
|
93
|
-
|
|
94
|
-
(0, react_1.useEffect)(
|
|
95
|
-
|
|
96
|
-
return
|
|
75
|
+
const [shown, setShown] = (0, react_1.useState)(false);
|
|
76
|
+
(0, react_1.useEffect)(() => {
|
|
77
|
+
const timeout = setTimeout(() => setShown(true), 400);
|
|
78
|
+
return () => clearTimeout(timeout);
|
|
97
79
|
});
|
|
98
80
|
return !shown ? null : (react_1.default.createElement("g", null,
|
|
99
81
|
react_1.default.createElement("defs", null,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Loading.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/Loading.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Loading.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/Loading.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAAkD;AAClD,uCAA0C;AAC1C,2CAAqC;AAErC,MAAM,SAAS,GAAG,IAAA,gBAAU,GAAE,CAAC,KAAK,CAAC,EAAE;IACrC,MAAM,MAAM,GAAG,CAAC,CAAA;IAChB,MAAM,QAAQ,GAAG,GAAG,CAAA;IAEpB,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,KAAK,CAAC,O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YAAY,CAAC,OAAO,CAAC,CAAA;IACpC,CAAC,CAAC,CAAA;IAEF,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CACrB;QACE;YACE,2CACE,EAAE,EAAC,eAAe,EAClB,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,gBAAgB,EAAC,gBAAgB,EACjC,YAAY,EAAC,gBAAgB;gBAE7B,wCACE,EAAE,EAAC,GAAG,EACN,EAAE,EAAC,GAAG,EACN,EAAE,EAAC,GAAG,EACN,EAAE,EAAC,IAAI,EACP,KAAK,EAAE,EAAE,MAAM,EAAE,uBAAuB,EAAE,WAAW,EAAE,EAAE,EAAE,GAC3D,CACM,CACL;QACP,0CAAQ,EAAE,EAAC,GAAG,EAAC,EAAE,EAAC,GAAG,EAAC,CAAC,EAAE,MAAM,EAAE,IAAI,EAAC,SAAS,GAAG;QAClD,0CAAQ,EAAE,EAAC,GAAG,EAAC,EAAE,EAAC,GAAG,EAAC,CAAC,EAAE,MAAM,EAAE,IAAI,EAAC,qBAAqB,GAAG;QAC9D,wCACE,CAAC,EAAC,GAAG,EACL,CAAC,EAAC,GAAG,EACL,SAAS,EAAC,gBAAgB,EAC1B,gBAAgB,EAAC,QAAQ,EACzB,UAAU,EAAC,QAAQ,oBAGd;QACP,0CACE,SAAS,EAAE,OAAO,CAAC,IAAI,EACvB,IAAI,EAAC,MAAM,EACX,WAAW,EAAC,GAAG,EACf,aAAa,EAAC,OAAO,EACrB,EAAE,EAAC,GAAG,EACN,EAAE,EAAC,GAAG,EACN,CAAC,EAAC,IAAI,GACN,CACA,CACL,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,OAAO,CAAA"}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
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
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
14
3
|
if (k2 === undefined) k2 = k;
|
|
15
4
|
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
@@ -34,17 +23,16 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
34
23
|
return result;
|
|
35
24
|
};
|
|
36
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
function RpcRenderedSvgGroup(
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
var domNode = ssrContainerNode.current;
|
|
26
|
+
const react_1 = __importStar(require("react"));
|
|
27
|
+
const mobx_state_tree_1 = require("mobx-state-tree");
|
|
28
|
+
const mobx_react_1 = require("mobx-react");
|
|
29
|
+
const react_dom_1 = require("react-dom");
|
|
30
|
+
const util_1 = require("@jbrowse/core/util");
|
|
31
|
+
function RpcRenderedSvgGroup({ model }) {
|
|
32
|
+
const { data, html, filled, renderingComponent } = model;
|
|
33
|
+
const ssrContainerNode = (0, react_1.useRef)(null);
|
|
34
|
+
(0, react_1.useEffect)(() => {
|
|
35
|
+
const domNode = ssrContainerNode.current;
|
|
48
36
|
function doHydrate() {
|
|
49
37
|
if (domNode && filled) {
|
|
50
38
|
if (domNode.innerHTML) {
|
|
@@ -58,12 +46,12 @@ function RpcRenderedSvgGroup(_a) {
|
|
|
58
46
|
// use requestIdleCallback to defer main-thread rendering
|
|
59
47
|
// and hydration for when we have some free time. helps
|
|
60
48
|
// keep the framerate up.
|
|
61
|
-
(0, util_1.rIC)(
|
|
49
|
+
(0, util_1.rIC)(() => {
|
|
62
50
|
if (!(0, mobx_state_tree_1.isAlive)(model)) {
|
|
63
51
|
return;
|
|
64
52
|
}
|
|
65
|
-
|
|
66
|
-
(0, util_1.rIC)(
|
|
53
|
+
const mainThreadRendering = react_1.default.createElement(renderingComponent, { ...data, ...model.renderProps() }, null);
|
|
54
|
+
(0, util_1.rIC)(() => {
|
|
67
55
|
if (!(0, mobx_state_tree_1.isAlive)(model)) {
|
|
68
56
|
return;
|
|
69
57
|
}
|
|
@@ -73,7 +61,7 @@ function RpcRenderedSvgGroup(_a) {
|
|
|
73
61
|
}
|
|
74
62
|
}
|
|
75
63
|
doHydrate();
|
|
76
|
-
return
|
|
64
|
+
return () => {
|
|
77
65
|
if (domNode) {
|
|
78
66
|
(0, react_dom_1.unmountComponentAtNode)(domNode);
|
|
79
67
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RpcRenderedSvgGroup.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/RpcRenderedSvgGroup.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RpcRenderedSvgGroup.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/components/RpcRenderedSvgGroup.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAAgD;AAChD,qDAAyC;AACzC,2CAAqC;AACrC,yCAA2D;AAC3D,6CAAwC;AAExC,SAAS,mBAAmB,CAAC,EAAE,KAAK,EAAE;IACpC,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,kBAAkB,EAAE,GAAG,KAAK,CAAA;IAExD,MAAM,gBAAgB,GAAG,IAAA,cAAM,EAAC,IAAI,CAAC,CAAA;IAErC,IAAA,iBAAS,EAAC,GAAG,EAAE;QACb,MAAM,OAAO,GAAG,gBAAgB,CAAC,OAAO,CAAA;QACxC,SAAS,SAAS;YAChB,IAAI,OAAO,IAAI,MAAM,EAAE;gBACrB,IAAI,OAAO,CAAC,SAAS,EAAE;oBACrB,OAAO,CAAC,KAAK,CAAC,OAAO,GAAG,MAAM,CAAA;oBAC9B,IAAA,kCAAsB,EAAC,OAAO,CAAC,CAAA;iBAChC;gBAED,kEAAkE;gBAClE,yDAAyD;gBACzD,OAAO,CAAC,KAAK,CAAC,OAAO,GAAG,MAAM,CAAA;gBAC9B,OAAO,CAAC,SAAS,GAAG,IAAI,CAAA;gBACxB,yDAAyD;gBACzD,uDAAuD;gBACvD,yBAAyB;gBACzB,IAAA,UAAG,EAAC,GAAG,EAAE;oBACP,IAAI,CAAC,IAAA,yBAAO,EAAC,KAAK,CAAC,EAAE;wBACnB,OAAM;qBACP;oBACD,MAAM,mBAAmB,GAAG,eAAK,CAAC,aAAa,CAC7C,kBAAkB,EAClB,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,CAAC,WAAW,EAAE,EAAE,EACnC,IAAI,CACL,CAAA;oBACD,IAAA,UAAG,EAAC,GAAG,EAAE;wBACP,IAAI,CAAC,IAAA,yBAAO,EAAC,KAAK,CAAC,EAAE;4BACnB,OAAM;yBACP;wBACD,IAAA,mBAAO,EAAC,mBAAmB,EAAE,OAAO,CAAC,CAAA;oBACvC,CAAC,CAAC,CAAA;gBACJ,CAAC,CAAC,CAAA;aACH;QACH,CAAC;QACD,SAAS,EAAE,CAAA;QACX,OAAO,GAAG,EAAE;YACV,IAAI,OAAO,EAAE;gBACX,IAAA,kCAAsB,EAAC,OAAO,CAAC,CAAA;aAChC;QACH,CAAC,CAAA;IACH,CAAC,CAAC,CAAA;IAEF,OAAO,qCAAG,GAAG,EAAE,gBAAgB,GAAI,CAAA;AACrC,CAAC;AAED,kBAAe,IAAA,qBAAQ,EAAC,mBAAmB,CAAC,CAAA"}
|
|
@@ -1,70 +1,23 @@
|
|
|
1
1
|
"use strict";
|
|
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 };
|
|
47
|
-
}
|
|
48
|
-
};
|
|
49
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
50
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
51
4
|
};
|
|
52
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53
6
|
exports.BaseChordDisplayModel = void 0;
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
7
|
+
const configuration_1 = require("@jbrowse/core/configuration");
|
|
8
|
+
const models_1 = require("@jbrowse/core/pluggableElementTypes/models");
|
|
9
|
+
const CircularChordRendererType_1 = __importDefault(require("@jbrowse/core/pluggableElementTypes/renderers/CircularChordRendererType"));
|
|
10
|
+
const util_1 = require("@jbrowse/core/util");
|
|
11
|
+
const simpleFeature_1 = require("@jbrowse/core/util/simpleFeature");
|
|
12
|
+
const tracks_1 = require("@jbrowse/core/util/tracks");
|
|
13
|
+
const mobx_state_tree_1 = require("mobx-state-tree");
|
|
14
|
+
const renderReaction_1 = __importDefault(require("./renderReaction"));
|
|
62
15
|
exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
63
16
|
.compose('BaseChordDisplay', models_1.BaseDisplay, mobx_state_tree_1.types.model({
|
|
64
17
|
bezierRadiusRatio: 0.1,
|
|
65
18
|
assemblyName: mobx_state_tree_1.types.maybe(mobx_state_tree_1.types.string),
|
|
66
19
|
}))
|
|
67
|
-
.volatile(
|
|
20
|
+
.volatile(() => {
|
|
68
21
|
return {
|
|
69
22
|
// NOTE: all this volatile stuff has to be filled in at once
|
|
70
23
|
// so that it stays consistent
|
|
@@ -76,31 +29,31 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
76
29
|
refNameMap: undefined,
|
|
77
30
|
};
|
|
78
31
|
})
|
|
79
|
-
.actions(
|
|
80
|
-
|
|
81
|
-
|
|
32
|
+
.actions(self => {
|
|
33
|
+
const { pluginManager } = (0, mobx_state_tree_1.getEnv)(self);
|
|
34
|
+
const track = self;
|
|
82
35
|
return {
|
|
83
|
-
onChordClick
|
|
84
|
-
(0, configuration_1.getConf)(self, 'onChordClick', { feature
|
|
36
|
+
onChordClick(feature) {
|
|
37
|
+
(0, configuration_1.getConf)(self, 'onChordClick', { feature, track, pluginManager });
|
|
85
38
|
},
|
|
86
39
|
};
|
|
87
40
|
})
|
|
88
|
-
.views(
|
|
41
|
+
.views(self => ({
|
|
89
42
|
get blockDefinitions() {
|
|
90
|
-
|
|
43
|
+
const origSlices = (0, util_1.getContainingView)(self)
|
|
91
44
|
.staticSlices;
|
|
92
45
|
if (!self.refNameMap) {
|
|
93
46
|
return origSlices;
|
|
94
47
|
}
|
|
95
|
-
|
|
48
|
+
const slices = JSON.parse(JSON.stringify(origSlices));
|
|
96
49
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
97
|
-
slices.forEach(
|
|
98
|
-
|
|
50
|
+
slices.forEach((slice) => {
|
|
51
|
+
const regions = slice.region.elided
|
|
99
52
|
? slice.region.regions
|
|
100
53
|
: [slice.region];
|
|
101
|
-
regions.forEach(
|
|
54
|
+
regions.forEach((region) => {
|
|
102
55
|
var _a;
|
|
103
|
-
|
|
56
|
+
const renamed = (_a = self.refNameMap) === null || _a === void 0 ? void 0 : _a[region.refName];
|
|
104
57
|
if (renamed && region.refName !== renamed) {
|
|
105
58
|
region.refName = renamed;
|
|
106
59
|
}
|
|
@@ -108,27 +61,35 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
108
61
|
});
|
|
109
62
|
return slices;
|
|
110
63
|
},
|
|
111
|
-
renderProps
|
|
112
|
-
|
|
113
|
-
return
|
|
64
|
+
renderProps() {
|
|
65
|
+
const view = (0, util_1.getContainingView)(self);
|
|
66
|
+
return {
|
|
67
|
+
...(0, tracks_1.getParentRenderProps)(self),
|
|
68
|
+
rpcDriverName: self.rpcDriverName,
|
|
69
|
+
displayModel: self,
|
|
70
|
+
bezierRadius: view.radiusPx * self.bezierRadiusRatio,
|
|
71
|
+
radius: view.radiusPx,
|
|
72
|
+
blockDefinitions: this.blockDefinitions,
|
|
73
|
+
onChordClick: self.onChordClick,
|
|
74
|
+
};
|
|
114
75
|
},
|
|
115
76
|
/**
|
|
116
77
|
* the pluggable element type object for this diplay's
|
|
117
78
|
* renderer
|
|
118
79
|
*/
|
|
119
80
|
get rendererType() {
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
81
|
+
const display = self;
|
|
82
|
+
const { pluginManager } = (0, mobx_state_tree_1.getEnv)(self);
|
|
83
|
+
const ThisRendererType = pluginManager.getRendererType(self.rendererTypeName);
|
|
123
84
|
if (!ThisRendererType) {
|
|
124
|
-
throw new Error(
|
|
85
|
+
throw new Error(`renderer "${display.rendererTypeName}" not found`);
|
|
125
86
|
}
|
|
126
87
|
if (!ThisRendererType.ReactComponent) {
|
|
127
|
-
throw new Error(
|
|
88
|
+
throw new Error(`renderer ${display.rendererTypeName} has no ReactComponent, it may not be completely implemented yet`);
|
|
128
89
|
}
|
|
129
90
|
return ThisRendererType;
|
|
130
91
|
},
|
|
131
|
-
isCompatibleWithRenderer
|
|
92
|
+
isCompatibleWithRenderer(renderer) {
|
|
132
93
|
return !!(renderer instanceof CircularChordRendererType_1.default);
|
|
133
94
|
},
|
|
134
95
|
/**
|
|
@@ -139,20 +100,20 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
139
100
|
if (!(0, mobx_state_tree_1.isAlive)(self)) {
|
|
140
101
|
return undefined;
|
|
141
102
|
}
|
|
142
|
-
|
|
103
|
+
const session = (0, util_1.getSession)(self);
|
|
143
104
|
if (!session) {
|
|
144
105
|
return undefined;
|
|
145
106
|
}
|
|
146
|
-
|
|
107
|
+
const { selection } = session;
|
|
147
108
|
// does it quack like a feature?
|
|
148
109
|
if ((0, simpleFeature_1.isFeature)(selection)) {
|
|
149
110
|
return selection.id();
|
|
150
111
|
}
|
|
151
112
|
return undefined;
|
|
152
113
|
},
|
|
153
|
-
})
|
|
154
|
-
.actions(
|
|
155
|
-
renderStarted
|
|
114
|
+
}))
|
|
115
|
+
.actions(self => ({
|
|
116
|
+
renderStarted() {
|
|
156
117
|
self.filled = false;
|
|
157
118
|
self.message = '';
|
|
158
119
|
self.reactElement = undefined;
|
|
@@ -160,8 +121,7 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
160
121
|
self.error = undefined;
|
|
161
122
|
self.renderingComponent = undefined;
|
|
162
123
|
},
|
|
163
|
-
renderSuccess
|
|
164
|
-
var message = _a.message, data = _a.data, reactElement = _a.reactElement, renderingComponent = _a.renderingComponent;
|
|
124
|
+
renderSuccess({ message, data, reactElement, renderingComponent, }) {
|
|
165
125
|
if (message) {
|
|
166
126
|
self.filled = false;
|
|
167
127
|
self.message = message;
|
|
@@ -179,7 +139,7 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
179
139
|
self.renderingComponent = renderingComponent;
|
|
180
140
|
}
|
|
181
141
|
},
|
|
182
|
-
renderError
|
|
142
|
+
renderError(error) {
|
|
183
143
|
console.error(error);
|
|
184
144
|
// the rendering failed for some reason
|
|
185
145
|
self.filled = false;
|
|
@@ -189,41 +149,35 @@ exports.BaseChordDisplayModel = mobx_state_tree_1.types
|
|
|
189
149
|
self.error = error;
|
|
190
150
|
self.renderingComponent = undefined;
|
|
191
151
|
},
|
|
192
|
-
setRefNameMap
|
|
152
|
+
setRefNameMap(refNameMap) {
|
|
193
153
|
self.refNameMap = refNameMap;
|
|
194
154
|
},
|
|
195
|
-
})
|
|
196
|
-
.actions(
|
|
197
|
-
|
|
198
|
-
|
|
155
|
+
}))
|
|
156
|
+
.actions(self => {
|
|
157
|
+
const { pluginManager } = (0, mobx_state_tree_1.getEnv)(self);
|
|
158
|
+
const { renderReactionData, renderReactionEffect } = pluginManager.jbrequire(renderReaction_1.default);
|
|
199
159
|
return {
|
|
200
|
-
afterAttach
|
|
201
|
-
var _this = this;
|
|
160
|
+
afterAttach() {
|
|
202
161
|
(0, util_1.makeAbortableReaction)(self, renderReactionData, renderReactionEffect, {
|
|
203
|
-
name:
|
|
162
|
+
name: `${self.type} ${self.id} rendering`,
|
|
204
163
|
// delay: self.renderDelay || 300,
|
|
205
164
|
fireImmediately: true,
|
|
206
165
|
}, self.renderStarted, self.renderSuccess, self.renderError);
|
|
207
|
-
(0, util_1.makeAbortableReaction)(self,
|
|
166
|
+
(0, util_1.makeAbortableReaction)(self, () => ({
|
|
208
167
|
assemblyNames: (0, tracks_1.getTrackAssemblyNames)(self.parentTrack),
|
|
209
168
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
210
169
|
adapter: (0, configuration_1.getConf)((0, mobx_state_tree_1.getParent)(self, 2), 'adapter'),
|
|
211
170
|
assemblyManager: (0, util_1.getSession)(self).assemblyManager,
|
|
212
|
-
})
|
|
171
|
+
}),
|
|
213
172
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
214
|
-
|
|
215
|
-
|
|
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
|
-
});
|
|
173
|
+
async ({ assemblyNames, adapter, assemblyManager }, signal) => {
|
|
174
|
+
return assemblyManager.getRefNameMapForAdapter(adapter, assemblyNames[0], { signal, sessionId: (0, tracks_1.getRpcSessionId)(self) });
|
|
221
175
|
}, {
|
|
222
|
-
name:
|
|
176
|
+
name: `${self.type} ${self.id} getting refNames`,
|
|
223
177
|
fireImmediately: true,
|
|
224
|
-
},
|
|
178
|
+
}, () => { }, refNameMap => {
|
|
225
179
|
self.setRefNameMap(refNameMap);
|
|
226
|
-
},
|
|
180
|
+
}, error => {
|
|
227
181
|
console.error(error);
|
|
228
182
|
self.setError(error);
|
|
229
183
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseChordDisplayModel.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/BaseChordDisplayModel.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BaseChordDisplayModel.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/BaseChordDisplayModel.ts"],"names":[],"mappings":";;;;;;AAAA,+DAAqD;AACrD,uEAAwE;AACxE,wIAA+G;AAE/G,6CAK2B;AAC3B,oEAAqE;AACrE,sDAIkC;AAElC,qDAAmE;AAEnE,sEAAoD;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,GAAG,EAAE;IACb,OAAO;QACL,4DAA4D;QAC5D,8BAA8B;QAC9B,MAAM,EAAE,KAAK;QACb,YAAY,EAAE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ACpD,eAAe,EAAE,IAAA,iBAAU,EAAC,IAAI,CAAC,CAAC,eAAe;aAClD,CAAC;YACF,8DAA8D;YAC9D,KAAK,EAAE,EAAE,aAAa,EAAE,OAAO,EAAE,eAAe,EAAO,EAAE,MAAM,EAAE,EAAE;gBACjE,OAAO,eAAe,CAAC,uBAAuB,CAC5C,OAAO,EACP,aAAa,CAAC,CAAC,CAAC,EAChB,EAAE,MAAM,EAAE,SAAS,EAAE,IAAA,wBAAe,EAAC,IAAI,CAAC,EAAE,CAC7C,CAAA;YACH,CAAC,EACD;gBACE,IAAI,EAAE,GAAG,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,EAAE,mBAAmB;gBAChD,eAAe,EAAE,IAAI;aACtB,EACD,GAAG,EAAE,GAAE,CAAC,EACR,UAAU,CAAC,EAAE;gBACX,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,CAAA;YAChC,CAAC,EACD,KAAK,CAAC,EAAE;gBACN,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,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.baseChordDisplayConfig = void 0;
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
const configuration_1 = require("@jbrowse/core/configuration");
|
|
5
|
+
const baseChordDisplayConfig = (0, configuration_1.ConfigurationSchema)('BaseChordDisplay', {
|
|
6
6
|
onChordClick: {
|
|
7
7
|
type: 'boolean',
|
|
8
8
|
description: 'callback that should be run when a chord in the track is clicked',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"baseChordDisplayConfig.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/baseChordDisplayConfig.ts"],"names":[],"mappings":";;;AAAA
|
|
1
|
+
{"version":3,"file":"baseChordDisplayConfig.js","sourceRoot":"","sources":["../../../src/BaseChordDisplay/models/baseChordDisplayConfig.ts"],"names":[],"mappings":";;;AAAA,+DAAiE;AAEjE,MAAM,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"}
|