@jbrowse/plugin-variants 2.1.7 → 2.2.1
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/ChordVariantDisplay/index.d.ts +1 -2
- package/dist/ChordVariantDisplay/index.js +13 -10
- package/dist/ChordVariantDisplay/index.js.map +1 -1
- package/dist/ChordVariantDisplay/models/ChordVariantDisplay.d.ts +19 -1
- package/dist/ChordVariantDisplay/models/ChordVariantDisplay.js +22 -3
- package/dist/ChordVariantDisplay/models/ChordVariantDisplay.js.map +1 -1
- package/dist/ChordVariantDisplay/models/configSchema.d.ts +3 -0
- package/dist/ChordVariantDisplay/models/configSchema.js +25 -0
- package/dist/ChordVariantDisplay/models/configSchema.js.map +1 -0
- package/dist/ChordVariantDisplay/models/stateModelFactory.d.ts +112 -0
- package/dist/ChordVariantDisplay/models/stateModelFactory.js +55 -0
- package/dist/ChordVariantDisplay/models/stateModelFactory.js.map +1 -0
- package/dist/LinearVariantDisplay/configSchema.d.ts +3 -3
- package/dist/LinearVariantDisplay/configSchema.js +16 -5
- package/dist/LinearVariantDisplay/configSchema.js.map +1 -1
- package/dist/LinearVariantDisplay/index.js +2 -2
- package/dist/LinearVariantDisplay/index.js.map +1 -1
- package/dist/LinearVariantDisplay/model.d.ts +21 -3
- package/dist/LinearVariantDisplay/model.js +16 -2
- package/dist/LinearVariantDisplay/model.js.map +1 -1
- package/dist/StructuralVariantChordRenderer/ReactComponent.d.ts +1 -1
- package/dist/StructuralVariantChordRenderer/configSchema.d.ts +2 -0
- package/dist/StructuralVariantChordRenderer/configSchema.js +38 -0
- package/dist/StructuralVariantChordRenderer/configSchema.js.map +1 -0
- package/dist/StructuralVariantChordRenderer/index.d.ts +1 -2
- package/dist/StructuralVariantChordRenderer/index.js +4 -24
- package/dist/StructuralVariantChordRenderer/index.js.map +1 -1
- package/dist/VariantTrack/configSchema.d.ts +3 -0
- package/dist/VariantTrack/configSchema.js +18 -0
- package/dist/VariantTrack/configSchema.js.map +1 -0
- package/dist/VariantTrack/index.d.ts +1 -1
- package/dist/VariantTrack/index.js +5 -5
- package/dist/VariantTrack/index.js.map +1 -1
- package/dist/VcfAdapter/configSchema.d.ts +2 -2
- package/dist/VcfAdapter/configSchema.js +9 -1
- package/dist/VcfAdapter/configSchema.js.map +1 -1
- package/dist/VcfTabixAdapter/configSchema.d.ts +2 -2
- package/dist/VcfTabixAdapter/configSchema.js +15 -1
- package/dist/VcfTabixAdapter/configSchema.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/esm/ChordVariantDisplay/index.d.ts +1 -2
- package/esm/ChordVariantDisplay/index.js +13 -10
- package/esm/ChordVariantDisplay/index.js.map +1 -1
- package/esm/ChordVariantDisplay/models/ChordVariantDisplay.d.ts +19 -1
- package/esm/ChordVariantDisplay/models/ChordVariantDisplay.js +21 -5
- package/esm/ChordVariantDisplay/models/ChordVariantDisplay.js.map +1 -1
- package/esm/ChordVariantDisplay/models/configSchema.d.ts +3 -0
- package/esm/ChordVariantDisplay/models/configSchema.js +23 -0
- package/esm/ChordVariantDisplay/models/configSchema.js.map +1 -0
- package/esm/ChordVariantDisplay/models/stateModelFactory.d.ts +112 -0
- package/esm/ChordVariantDisplay/models/stateModelFactory.js +53 -0
- package/esm/ChordVariantDisplay/models/stateModelFactory.js.map +1 -0
- package/esm/LinearVariantDisplay/configSchema.d.ts +3 -3
- package/esm/LinearVariantDisplay/configSchema.js +15 -3
- package/esm/LinearVariantDisplay/configSchema.js.map +1 -1
- package/esm/LinearVariantDisplay/index.js +2 -2
- package/esm/LinearVariantDisplay/index.js.map +1 -1
- package/esm/LinearVariantDisplay/model.d.ts +21 -3
- package/esm/LinearVariantDisplay/model.js +15 -1
- package/esm/LinearVariantDisplay/model.js.map +1 -1
- package/esm/StructuralVariantChordRenderer/ReactComponent.d.ts +1 -1
- package/esm/StructuralVariantChordRenderer/configSchema.d.ts +2 -0
- package/esm/StructuralVariantChordRenderer/configSchema.js +36 -0
- package/esm/StructuralVariantChordRenderer/configSchema.js.map +1 -0
- package/esm/StructuralVariantChordRenderer/index.d.ts +1 -2
- package/esm/StructuralVariantChordRenderer/index.js +3 -23
- package/esm/StructuralVariantChordRenderer/index.js.map +1 -1
- package/esm/VariantTrack/configSchema.d.ts +3 -0
- package/esm/VariantTrack/configSchema.js +16 -0
- package/esm/VariantTrack/configSchema.js.map +1 -0
- package/esm/VariantTrack/index.d.ts +1 -1
- package/esm/VariantTrack/index.js +6 -6
- package/esm/VariantTrack/index.js.map +1 -1
- package/esm/VcfAdapter/configSchema.d.ts +2 -2
- package/esm/VcfAdapter/configSchema.js +9 -1
- package/esm/VcfAdapter/configSchema.js.map +1 -1
- package/esm/VcfTabixAdapter/configSchema.d.ts +2 -2
- package/esm/VcfTabixAdapter/configSchema.js +15 -1
- package/esm/VcfTabixAdapter/configSchema.js.map +1 -1
- package/esm/index.js +4 -4
- package/esm/index.js.map +1 -1
- package/package.json +2 -2
- package/src/ChordVariantDisplay/index.ts +13 -12
- package/src/ChordVariantDisplay/models/ChordVariantDisplay.ts +22 -19
- package/src/ChordVariantDisplay/models/configSchema.ts +33 -0
- package/src/ChordVariantDisplay/models/stateModelFactory.ts +65 -0
- package/src/LinearVariantDisplay/configSchema.test.js +1 -1
- package/src/LinearVariantDisplay/configSchema.ts +16 -8
- package/src/LinearVariantDisplay/index.ts +2 -2
- package/src/LinearVariantDisplay/model.ts +17 -1
- package/src/StructuralVariantChordRenderer/configSchema.ts +42 -0
- package/src/StructuralVariantChordRenderer/index.ts +9 -32
- package/src/VariantFeatureWidget/VariantFeatureWidget.test.js +6 -4
- package/src/VariantFeatureWidget/__snapshots__/VariantFeatureWidget.test.js.snap +26 -28
- package/src/VariantTrack/configSchema.ts +24 -0
- package/src/VariantTrack/index.ts +6 -17
- package/src/VcfAdapter/__snapshots__/VcfAdapter.test.ts.snap +79 -79
- package/src/VcfAdapter/configSchema.ts +11 -1
- package/src/VcfTabixAdapter/__snapshots__/VcfTabixAdapter.test.ts.snap +79 -79
- package/src/VcfTabixAdapter/configSchema.ts +17 -1
- package/src/__snapshots__/index.test.js.snap +5 -5
- package/src/index.ts +4 -10
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import PluginManager from '@jbrowse/core/PluginManager'
|
|
2
|
-
import { LinearVariantDisplayConfigFactory } from './configSchema'
|
|
3
2
|
import { BaseLinearDisplayComponent } from '@jbrowse/plugin-linear-genome-view'
|
|
4
3
|
import DisplayType from '@jbrowse/core/pluggableElementTypes/DisplayType'
|
|
5
4
|
import stateModelFactory from './model'
|
|
5
|
+
import configSchemaF from './configSchema'
|
|
6
6
|
|
|
7
7
|
export default (pluginManager: PluginManager) => {
|
|
8
8
|
pluginManager.addDisplayType(() => {
|
|
9
|
-
const configSchema =
|
|
9
|
+
const configSchema = configSchemaF(pluginManager)
|
|
10
10
|
return new DisplayType({
|
|
11
11
|
name: 'LinearVariantDisplay',
|
|
12
12
|
configSchema,
|
|
@@ -12,17 +12,33 @@ import { linearBasicDisplayModelFactory } from '@jbrowse/plugin-linear-genome-vi
|
|
|
12
12
|
import { types } from 'mobx-state-tree'
|
|
13
13
|
import { LinearVariantDisplayConfigModel } from './configSchema'
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
/**
|
|
16
|
+
* #stateModel LinearVariantDisplay
|
|
17
|
+
* extends `LinearBasicDisplay`
|
|
18
|
+
* very similar to basic display, but provides custom widget on feature click
|
|
19
|
+
*/
|
|
20
|
+
export default function stateModelFactory(
|
|
21
|
+
configSchema: LinearVariantDisplayConfigModel,
|
|
22
|
+
) {
|
|
16
23
|
return types
|
|
17
24
|
.compose(
|
|
18
25
|
'LinearVariantDisplay',
|
|
19
26
|
linearBasicDisplayModelFactory(configSchema),
|
|
20
27
|
types.model({
|
|
28
|
+
/**
|
|
29
|
+
* #property
|
|
30
|
+
*/
|
|
21
31
|
type: types.literal('LinearVariantDisplay'),
|
|
32
|
+
/**
|
|
33
|
+
* #property
|
|
34
|
+
*/
|
|
22
35
|
configuration: ConfigurationReference(configSchema),
|
|
23
36
|
}),
|
|
24
37
|
)
|
|
25
38
|
.actions(self => ({
|
|
39
|
+
/**
|
|
40
|
+
* #action
|
|
41
|
+
*/
|
|
26
42
|
async selectFeature(feature: Feature) {
|
|
27
43
|
const session = getSession(self)
|
|
28
44
|
if (isSessionModelWithWidgets(session)) {
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ConfigurationSchema } from '@jbrowse/core/configuration'
|
|
2
|
+
/**
|
|
3
|
+
* #config StructuralVariantChordRenderer
|
|
4
|
+
*/
|
|
5
|
+
function x() {} // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
6
|
+
|
|
7
|
+
const configSchema = ConfigurationSchema(
|
|
8
|
+
'StructuralVariantChordRenderer',
|
|
9
|
+
{
|
|
10
|
+
/**
|
|
11
|
+
* #slot
|
|
12
|
+
*/
|
|
13
|
+
strokeColor: {
|
|
14
|
+
type: 'color',
|
|
15
|
+
description: 'the line color of each arc',
|
|
16
|
+
defaultValue: 'rgba(255,133,0,0.32)',
|
|
17
|
+
contextVariable: ['feature'],
|
|
18
|
+
},
|
|
19
|
+
/**
|
|
20
|
+
* #slot
|
|
21
|
+
*/
|
|
22
|
+
strokeColorSelected: {
|
|
23
|
+
type: 'color',
|
|
24
|
+
description: 'the line color of an arc that has been selected',
|
|
25
|
+
defaultValue: 'black',
|
|
26
|
+
contextVariable: ['feature'],
|
|
27
|
+
},
|
|
28
|
+
/**
|
|
29
|
+
* #slot
|
|
30
|
+
*/
|
|
31
|
+
strokeColorHover: {
|
|
32
|
+
type: 'color',
|
|
33
|
+
description:
|
|
34
|
+
'the line color of an arc that is being hovered over with the mouse',
|
|
35
|
+
defaultValue: '#555',
|
|
36
|
+
contextVariable: ['feature'],
|
|
37
|
+
},
|
|
38
|
+
},
|
|
39
|
+
{ explicitlyTyped: true },
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
export default configSchema
|
|
@@ -1,41 +1,18 @@
|
|
|
1
1
|
import ChordRendererType from '@jbrowse/core/pluggableElementTypes/renderers/CircularChordRendererType'
|
|
2
|
-
import { ConfigurationSchema } from '@jbrowse/core/configuration'
|
|
3
2
|
import PluginManager from '@jbrowse/core/PluginManager'
|
|
4
|
-
|
|
3
|
+
import configSchema from './configSchema'
|
|
5
4
|
import ReactComponent from './ReactComponent'
|
|
6
5
|
|
|
7
6
|
const ChordRendererConfigF = (pluginManager: PluginManager) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
},
|
|
17
|
-
strokeColorSelected: {
|
|
18
|
-
type: 'color',
|
|
19
|
-
description: 'the line color of an arc that has been selected',
|
|
20
|
-
defaultValue: 'black',
|
|
21
|
-
contextVariable: ['feature'],
|
|
22
|
-
},
|
|
23
|
-
strokeColorHover: {
|
|
24
|
-
type: 'color',
|
|
25
|
-
description:
|
|
26
|
-
'the line color of an arc that is being hovered over with the mouse',
|
|
27
|
-
defaultValue: '#555',
|
|
28
|
-
contextVariable: ['feature'],
|
|
29
|
-
},
|
|
30
|
-
},
|
|
31
|
-
{ explicitlyTyped: true },
|
|
7
|
+
pluginManager.addRendererType(
|
|
8
|
+
() =>
|
|
9
|
+
new ChordRendererType({
|
|
10
|
+
name: 'StructuralVariantChordRenderer',
|
|
11
|
+
ReactComponent,
|
|
12
|
+
configSchema,
|
|
13
|
+
pluginManager,
|
|
14
|
+
}),
|
|
32
15
|
)
|
|
33
|
-
return new ChordRendererType({
|
|
34
|
-
name: 'StructuralVariantChordRenderer',
|
|
35
|
-
ReactComponent,
|
|
36
|
-
configSchema,
|
|
37
|
-
pluginManager,
|
|
38
|
-
})
|
|
39
16
|
}
|
|
40
17
|
|
|
41
18
|
export default ChordRendererConfigF
|
|
@@ -13,13 +13,15 @@ describe('VariantTrack widget', () => {
|
|
|
13
13
|
const pluginManager = new PluginManager([])
|
|
14
14
|
const Session = types.model({
|
|
15
15
|
rpcManager: types.optional(types.frozen(), {}),
|
|
16
|
-
pluginManager: types.optional(types.frozen(), {}),
|
|
17
16
|
configuration: ConfigurationSchema('test', {}),
|
|
18
17
|
widget: stateModelFactory(pluginManager),
|
|
19
18
|
})
|
|
20
|
-
const model = Session.create(
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
const model = Session.create(
|
|
20
|
+
{
|
|
21
|
+
widget: { type: 'VariantFeatureWidget' },
|
|
22
|
+
},
|
|
23
|
+
{ pluginManager },
|
|
24
|
+
)
|
|
23
25
|
model.widget.setFeatureData({
|
|
24
26
|
refName: 'ctgA',
|
|
25
27
|
start: 176,
|
|
@@ -29,7 +29,7 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
29
29
|
>
|
|
30
30
|
<svg
|
|
31
31
|
aria-hidden="true"
|
|
32
|
-
class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium
|
|
32
|
+
class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-125qixp-MuiSvgIcon-root-expandIcon"
|
|
33
33
|
data-testid="ExpandMoreIcon"
|
|
34
34
|
focusable="false"
|
|
35
35
|
viewBox="0 0 24 24"
|
|
@@ -55,7 +55,7 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
55
55
|
role="region"
|
|
56
56
|
>
|
|
57
57
|
<div
|
|
58
|
-
class="MuiAccordionDetails-root
|
|
58
|
+
class="MuiAccordionDetails-root css-rqrb7m-MuiAccordionDetails-root-expansionPanelDetails"
|
|
59
59
|
>
|
|
60
60
|
<p
|
|
61
61
|
class="MuiTypography-root MuiTypography-body1 css-ahj2mt-MuiTypography-root"
|
|
@@ -63,31 +63,29 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
63
63
|
Core details
|
|
64
64
|
</p>
|
|
65
65
|
<div
|
|
66
|
-
class="
|
|
66
|
+
class="css-1m8nxnb-field"
|
|
67
67
|
>
|
|
68
68
|
<div
|
|
69
|
-
class="
|
|
69
|
+
class="css-1y9c7n2-fieldName"
|
|
70
70
|
>
|
|
71
71
|
Position
|
|
72
72
|
</div>
|
|
73
73
|
<div
|
|
74
|
-
class="
|
|
74
|
+
class="css-1omt041-fieldValue"
|
|
75
75
|
>
|
|
76
|
-
|
|
77
|
-
ctgA:177..177
|
|
78
|
-
</div>
|
|
76
|
+
ctgA:177
|
|
79
77
|
</div>
|
|
80
78
|
</div>
|
|
81
79
|
<div
|
|
82
|
-
class="
|
|
80
|
+
class="css-1m8nxnb-field"
|
|
83
81
|
>
|
|
84
82
|
<div
|
|
85
|
-
class="
|
|
83
|
+
class="css-1y9c7n2-fieldName"
|
|
86
84
|
>
|
|
87
85
|
Name
|
|
88
86
|
</div>
|
|
89
87
|
<div
|
|
90
|
-
class="
|
|
88
|
+
class="css-1omt041-fieldValue"
|
|
91
89
|
>
|
|
92
90
|
<div>
|
|
93
91
|
rs123
|
|
@@ -95,15 +93,15 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
95
93
|
</div>
|
|
96
94
|
</div>
|
|
97
95
|
<div
|
|
98
|
-
class="
|
|
96
|
+
class="css-1m8nxnb-field"
|
|
99
97
|
>
|
|
100
98
|
<div
|
|
101
|
-
class="
|
|
99
|
+
class="css-1y9c7n2-fieldName"
|
|
102
100
|
>
|
|
103
101
|
Length
|
|
104
102
|
</div>
|
|
105
103
|
<div
|
|
106
|
-
class="
|
|
104
|
+
class="css-1omt041-fieldValue"
|
|
107
105
|
>
|
|
108
106
|
<div>
|
|
109
107
|
1
|
|
@@ -119,17 +117,17 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
119
117
|
Attributes
|
|
120
118
|
</p>
|
|
121
119
|
<div
|
|
122
|
-
class="
|
|
120
|
+
class="css-1m8nxnb-field"
|
|
123
121
|
>
|
|
124
122
|
<div
|
|
125
123
|
aria-label="reference base(s): Each base must be one of A,C,G,T,N (case insensitive)."
|
|
126
|
-
class="
|
|
124
|
+
class="css-1qe2j6j-fieldDescription-fieldName"
|
|
127
125
|
data-mui-internal-clone-element="true"
|
|
128
126
|
>
|
|
129
127
|
REF
|
|
130
128
|
</div>
|
|
131
129
|
<div
|
|
132
|
-
class="
|
|
130
|
+
class="css-1omt041-fieldValue"
|
|
133
131
|
>
|
|
134
132
|
<div>
|
|
135
133
|
A
|
|
@@ -137,17 +135,17 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
137
135
|
</div>
|
|
138
136
|
</div>
|
|
139
137
|
<div
|
|
140
|
-
class="
|
|
138
|
+
class="css-1m8nxnb-field"
|
|
141
139
|
>
|
|
142
140
|
<div
|
|
143
141
|
aria-label="alternate base(s): Comma-separated list of alternate non-reference alleles"
|
|
144
|
-
class="
|
|
142
|
+
class="css-1qe2j6j-fieldDescription-fieldName"
|
|
145
143
|
data-mui-internal-clone-element="true"
|
|
146
144
|
>
|
|
147
145
|
ALT
|
|
148
146
|
</div>
|
|
149
147
|
<div
|
|
150
|
-
class="
|
|
148
|
+
class="css-1omt041-fieldValue"
|
|
151
149
|
>
|
|
152
150
|
<div>
|
|
153
151
|
<TRA>
|
|
@@ -155,17 +153,17 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
155
153
|
</div>
|
|
156
154
|
</div>
|
|
157
155
|
<div
|
|
158
|
-
class="
|
|
156
|
+
class="css-1m8nxnb-field"
|
|
159
157
|
>
|
|
160
158
|
<div
|
|
161
159
|
aria-label="quality: Phred-scaled quality score for the assertion made in ALT"
|
|
162
|
-
class="
|
|
160
|
+
class="css-1qe2j6j-fieldDescription-fieldName"
|
|
163
161
|
data-mui-internal-clone-element="true"
|
|
164
162
|
>
|
|
165
163
|
QUAL
|
|
166
164
|
</div>
|
|
167
165
|
<div
|
|
168
|
-
class="
|
|
166
|
+
class="css-1omt041-fieldValue"
|
|
169
167
|
>
|
|
170
168
|
<div>
|
|
171
169
|
10.4
|
|
@@ -173,16 +171,16 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
173
171
|
</div>
|
|
174
172
|
</div>
|
|
175
173
|
<div
|
|
176
|
-
class="
|
|
174
|
+
class="css-1m8nxnb-field"
|
|
177
175
|
>
|
|
178
176
|
<div
|
|
179
|
-
class="
|
|
177
|
+
class="css-1y9c7n2-fieldName"
|
|
180
178
|
style="width: 62px;"
|
|
181
179
|
>
|
|
182
180
|
INFO.MQ
|
|
183
181
|
</div>
|
|
184
182
|
<div
|
|
185
|
-
class="
|
|
183
|
+
class="css-1omt041-fieldValue"
|
|
186
184
|
>
|
|
187
185
|
<div>
|
|
188
186
|
5
|
|
@@ -190,7 +188,7 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
190
188
|
</div>
|
|
191
189
|
</div>
|
|
192
190
|
<div
|
|
193
|
-
class="
|
|
191
|
+
class="css-1upvn7b-container2"
|
|
194
192
|
>
|
|
195
193
|
<button
|
|
196
194
|
class="MuiButtonBase-root MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium MuiButton-root MuiButton-contained MuiButton-containedPrimary MuiButton-sizeMedium MuiButton-containedSizeMedium css-sghohy-MuiButtonBase-root-MuiButton-root"
|
|
@@ -203,7 +201,7 @@ exports[`VariantTrack widget renders with just the required model elements 1`] =
|
|
|
203
201
|
/>
|
|
204
202
|
</button>
|
|
205
203
|
<div
|
|
206
|
-
class="MuiFormControl-root
|
|
204
|
+
class="MuiFormControl-root css-147opmv-MuiFormControl-root-formControl"
|
|
207
205
|
>
|
|
208
206
|
<button
|
|
209
207
|
class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-78trlr-MuiButtonBase-root-MuiIconButton-root"
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ConfigurationSchema } from '@jbrowse/core/configuration'
|
|
2
|
+
import { createBaseTrackConfig } from '@jbrowse/core/pluggableElementTypes'
|
|
3
|
+
import PluginManager from '@jbrowse/core/PluginManager'
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* #config VariantTrack
|
|
7
|
+
* Mostly similar to feature track, but has `ChordDisplayType` registered to it,
|
|
8
|
+
* and custom feature details in `LinearVariantDisplay`
|
|
9
|
+
*/
|
|
10
|
+
function x() {} // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
11
|
+
|
|
12
|
+
const configSchema = (pluginManager: PluginManager) =>
|
|
13
|
+
ConfigurationSchema(
|
|
14
|
+
'VariantTrack',
|
|
15
|
+
{},
|
|
16
|
+
{
|
|
17
|
+
/**
|
|
18
|
+
* #baseConfiguration
|
|
19
|
+
*/
|
|
20
|
+
baseConfiguration: createBaseTrackConfig(pluginManager),
|
|
21
|
+
},
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
export default configSchema
|
|
@@ -1,26 +1,15 @@
|
|
|
1
1
|
import PluginManager from '@jbrowse/core/PluginManager'
|
|
2
|
-
import { ConfigurationSchema } from '@jbrowse/core/configuration'
|
|
3
2
|
import TrackType from '@jbrowse/core/pluggableElementTypes/TrackType'
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
createBaseTrackModel,
|
|
7
|
-
} from '@jbrowse/core/pluggableElementTypes/models'
|
|
3
|
+
import { createBaseTrackModel } from '@jbrowse/core/pluggableElementTypes/models'
|
|
4
|
+
import configSchemaF from './configSchema'
|
|
8
5
|
|
|
9
|
-
export default (
|
|
10
|
-
|
|
11
|
-
const configSchema =
|
|
12
|
-
'VariantTrack',
|
|
13
|
-
{},
|
|
14
|
-
{ baseConfiguration: createBaseTrackConfig(pluginManager) },
|
|
15
|
-
)
|
|
6
|
+
export default (pm: PluginManager) => {
|
|
7
|
+
pm.addTrackType(() => {
|
|
8
|
+
const configSchema = configSchemaF(pm)
|
|
16
9
|
return new TrackType({
|
|
17
10
|
name: 'VariantTrack',
|
|
18
11
|
configSchema,
|
|
19
|
-
stateModel: createBaseTrackModel(
|
|
20
|
-
pluginManager,
|
|
21
|
-
'VariantTrack',
|
|
22
|
-
configSchema,
|
|
23
|
-
),
|
|
12
|
+
stateModel: createBaseTrackModel(pm, 'VariantTrack', configSchema),
|
|
24
13
|
})
|
|
25
14
|
})
|
|
26
15
|
}
|