@jbrowse/plugin-linear-comparative-view 2.16.1 → 2.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (184) hide show
  1. package/dist/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.d.ts +1 -1
  2. package/dist/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.js +0 -2
  3. package/dist/LGVSyntenyDisplay/components/util.d.ts +3 -3
  4. package/dist/LGVSyntenyDisplay/components/util.js +0 -1
  5. package/dist/LGVSyntenyDisplay/configSchemaF.d.ts +19 -10
  6. package/dist/LGVSyntenyDisplay/configSchemaF.js +12 -9
  7. package/dist/LGVSyntenyDisplay/index.d.ts +1 -1
  8. package/dist/LGVSyntenyDisplay/index.js +1 -1
  9. package/dist/LGVSyntenyDisplay/model.d.ts +104 -81
  10. package/dist/LGVSyntenyDisplay/model.js +1 -29
  11. package/dist/LaunchLinearSyntenyView.d.ts +1 -1
  12. package/dist/LaunchLinearSyntenyView.js +1 -3
  13. package/dist/LinearComparativeDisplay/configSchemaF.d.ts +0 -3
  14. package/dist/LinearComparativeDisplay/configSchemaF.js +0 -6
  15. package/dist/LinearComparativeDisplay/index.d.ts +1 -1
  16. package/dist/LinearComparativeDisplay/stateModelFactory.d.ts +12 -69
  17. package/dist/LinearComparativeDisplay/stateModelFactory.js +13 -57
  18. package/dist/LinearComparativeView/components/Header.d.ts +1 -1
  19. package/dist/LinearComparativeView/components/Header.js +4 -5
  20. package/dist/LinearComparativeView/components/HeaderSearchBoxes.d.ts +1 -1
  21. package/dist/LinearComparativeView/components/HeaderSearchBoxes.js +3 -4
  22. package/dist/LinearComparativeView/components/LinearComparativeRenderArea.d.ts +1 -1
  23. package/dist/LinearComparativeView/components/LinearComparativeRenderArea.js +8 -15
  24. package/dist/LinearComparativeView/components/LinearComparativeView.d.ts +1 -1
  25. package/dist/LinearComparativeView/components/LinearComparativeView.js +2 -4
  26. package/dist/LinearComparativeView/components/Rubberband.d.ts +1 -1
  27. package/dist/LinearComparativeView/components/Rubberband.js +17 -19
  28. package/dist/LinearComparativeView/components/VerticalGuide.d.ts +1 -1
  29. package/dist/LinearComparativeView/components/VerticalGuide.js +1 -1
  30. package/dist/LinearComparativeView/index.d.ts +1 -1
  31. package/dist/LinearComparativeView/model.d.ts +6 -62
  32. package/dist/LinearComparativeView/model.js +3 -99
  33. package/dist/LinearReadVsRef/LinearReadVsRef.d.ts +1 -1
  34. package/dist/LinearReadVsRef/LinearReadVsRef.js +5 -19
  35. package/dist/LinearReadVsRef/index.d.ts +1 -1
  36. package/dist/LinearReadVsRef/index.js +0 -2
  37. package/dist/LinearSyntenyDisplay/afterAttach.d.ts +1 -1
  38. package/dist/LinearSyntenyDisplay/afterAttach.js +2 -9
  39. package/dist/LinearSyntenyDisplay/components/Component.d.ts +1 -1
  40. package/dist/LinearSyntenyDisplay/components/Component.js +2 -4
  41. package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.d.ts +1 -1
  42. package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +6 -23
  43. package/dist/LinearSyntenyDisplay/components/SyntenyContextMenu.d.ts +2 -2
  44. package/dist/LinearSyntenyDisplay/components/SyntenyContextMenu.js +1 -1
  45. package/dist/LinearSyntenyDisplay/components/SyntenyTooltip.js +1 -1
  46. package/dist/LinearSyntenyDisplay/components/util.d.ts +3 -3
  47. package/dist/LinearSyntenyDisplay/components/util.js +0 -9
  48. package/dist/LinearSyntenyDisplay/configSchemaF.d.ts +1 -12
  49. package/dist/LinearSyntenyDisplay/configSchemaF.js +0 -15
  50. package/dist/LinearSyntenyDisplay/drawSynteny.d.ts +1 -1
  51. package/dist/LinearSyntenyDisplay/drawSynteny.js +1 -23
  52. package/dist/LinearSyntenyDisplay/index.d.ts +1 -1
  53. package/dist/LinearSyntenyDisplay/index.js +1 -2
  54. package/dist/LinearSyntenyDisplay/model.d.ts +8 -102
  55. package/dist/LinearSyntenyDisplay/model.js +1 -92
  56. package/dist/LinearSyntenyView/components/ExportSvgDialog.d.ts +1 -1
  57. package/dist/LinearSyntenyView/components/ExportSvgDialog.js +2 -4
  58. package/dist/LinearSyntenyView/components/Icons.d.ts +1 -1
  59. package/dist/LinearSyntenyView/components/ImportForm/AddCustomTrack.d.ts +2 -2
  60. package/dist/LinearSyntenyView/components/ImportForm/AddCustomTrack.js +1 -1
  61. package/dist/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.d.ts +1 -1
  62. package/dist/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.js +6 -8
  63. package/dist/LinearSyntenyView/components/ImportForm/TrackSelector.d.ts +1 -1
  64. package/dist/LinearSyntenyView/components/ImportForm/TrackSelector.js +3 -5
  65. package/dist/LinearSyntenyView/components/ImportForm/TrackSelectorUtil.d.ts +3 -3
  66. package/dist/LinearSyntenyView/components/ImportForm/util.js +1 -3
  67. package/dist/LinearSyntenyView/components/LinearSyntenyView.d.ts +1 -1
  68. package/dist/LinearSyntenyView/components/LinearSyntenyView.js +0 -1
  69. package/dist/LinearSyntenyView/index.d.ts +1 -1
  70. package/dist/LinearSyntenyView/model.d.ts +5 -28
  71. package/dist/LinearSyntenyView/model.js +4 -41
  72. package/dist/LinearSyntenyView/svgcomponents/SVGBackground.js +1 -1
  73. package/dist/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.d.ts +1 -1
  74. package/dist/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.js +1 -1
  75. package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.d.ts +1 -1
  76. package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +5 -10
  77. package/dist/LinearSyntenyViewHelper/index.d.ts +1 -1
  78. package/dist/LinearSyntenyViewHelper/stateModelFactory.d.ts +2 -14
  79. package/dist/LinearSyntenyViewHelper/stateModelFactory.js +2 -29
  80. package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.d.ts +1 -1
  81. package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.js +4 -13
  82. package/dist/SyntenyFeatureDetail/index.d.ts +1 -1
  83. package/dist/SyntenyFeatureDetail/index.js +1 -7
  84. package/dist/SyntenyTrack/configSchema.d.ts +1 -1
  85. package/dist/SyntenyTrack/configSchema.js +1 -9
  86. package/dist/SyntenyTrack/index.d.ts +1 -1
  87. package/dist/SyntenyTrack/index.js +1 -1
  88. package/dist/index.d.ts +1 -1
  89. package/dist/index.js +4 -4
  90. package/dist/util.d.ts +2 -2
  91. package/dist/util.js +1 -11
  92. package/esm/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.d.ts +1 -1
  93. package/esm/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.js +0 -2
  94. package/esm/LGVSyntenyDisplay/components/util.d.ts +3 -3
  95. package/esm/LGVSyntenyDisplay/components/util.js +0 -1
  96. package/esm/LGVSyntenyDisplay/configSchemaF.d.ts +19 -10
  97. package/esm/LGVSyntenyDisplay/configSchemaF.js +12 -9
  98. package/esm/LGVSyntenyDisplay/index.d.ts +1 -1
  99. package/esm/LGVSyntenyDisplay/index.js +1 -1
  100. package/esm/LGVSyntenyDisplay/model.d.ts +104 -81
  101. package/esm/LGVSyntenyDisplay/model.js +2 -30
  102. package/esm/LaunchLinearSyntenyView.d.ts +1 -1
  103. package/esm/LaunchLinearSyntenyView.js +1 -3
  104. package/esm/LinearComparativeDisplay/configSchemaF.d.ts +0 -3
  105. package/esm/LinearComparativeDisplay/configSchemaF.js +0 -6
  106. package/esm/LinearComparativeDisplay/index.d.ts +1 -1
  107. package/esm/LinearComparativeDisplay/stateModelFactory.d.ts +12 -69
  108. package/esm/LinearComparativeDisplay/stateModelFactory.js +14 -58
  109. package/esm/LinearComparativeView/components/Header.d.ts +1 -1
  110. package/esm/LinearComparativeView/components/Header.js +4 -5
  111. package/esm/LinearComparativeView/components/HeaderSearchBoxes.d.ts +1 -1
  112. package/esm/LinearComparativeView/components/HeaderSearchBoxes.js +3 -4
  113. package/esm/LinearComparativeView/components/LinearComparativeRenderArea.d.ts +1 -1
  114. package/esm/LinearComparativeView/components/LinearComparativeRenderArea.js +8 -15
  115. package/esm/LinearComparativeView/components/LinearComparativeView.d.ts +1 -1
  116. package/esm/LinearComparativeView/components/LinearComparativeView.js +2 -4
  117. package/esm/LinearComparativeView/components/Rubberband.d.ts +1 -1
  118. package/esm/LinearComparativeView/components/Rubberband.js +18 -20
  119. package/esm/LinearComparativeView/components/VerticalGuide.d.ts +1 -1
  120. package/esm/LinearComparativeView/components/VerticalGuide.js +1 -1
  121. package/esm/LinearComparativeView/index.d.ts +1 -1
  122. package/esm/LinearComparativeView/model.d.ts +6 -62
  123. package/esm/LinearComparativeView/model.js +4 -100
  124. package/esm/LinearReadVsRef/LinearReadVsRef.d.ts +1 -1
  125. package/esm/LinearReadVsRef/LinearReadVsRef.js +5 -19
  126. package/esm/LinearReadVsRef/index.d.ts +1 -1
  127. package/esm/LinearReadVsRef/index.js +1 -3
  128. package/esm/LinearSyntenyDisplay/afterAttach.d.ts +1 -1
  129. package/esm/LinearSyntenyDisplay/afterAttach.js +2 -9
  130. package/esm/LinearSyntenyDisplay/components/Component.d.ts +1 -1
  131. package/esm/LinearSyntenyDisplay/components/Component.js +2 -4
  132. package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.d.ts +1 -1
  133. package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +8 -25
  134. package/esm/LinearSyntenyDisplay/components/SyntenyContextMenu.d.ts +2 -2
  135. package/esm/LinearSyntenyDisplay/components/SyntenyContextMenu.js +1 -1
  136. package/esm/LinearSyntenyDisplay/components/SyntenyTooltip.js +1 -1
  137. package/esm/LinearSyntenyDisplay/components/util.d.ts +3 -3
  138. package/esm/LinearSyntenyDisplay/components/util.js +2 -11
  139. package/esm/LinearSyntenyDisplay/configSchemaF.d.ts +1 -12
  140. package/esm/LinearSyntenyDisplay/configSchemaF.js +0 -15
  141. package/esm/LinearSyntenyDisplay/drawSynteny.d.ts +1 -1
  142. package/esm/LinearSyntenyDisplay/drawSynteny.js +1 -23
  143. package/esm/LinearSyntenyDisplay/index.d.ts +1 -1
  144. package/esm/LinearSyntenyDisplay/index.js +1 -2
  145. package/esm/LinearSyntenyDisplay/model.d.ts +8 -102
  146. package/esm/LinearSyntenyDisplay/model.js +1 -92
  147. package/esm/LinearSyntenyView/components/ExportSvgDialog.d.ts +1 -1
  148. package/esm/LinearSyntenyView/components/ExportSvgDialog.js +2 -4
  149. package/esm/LinearSyntenyView/components/Icons.d.ts +1 -1
  150. package/esm/LinearSyntenyView/components/ImportForm/AddCustomTrack.d.ts +2 -2
  151. package/esm/LinearSyntenyView/components/ImportForm/AddCustomTrack.js +2 -2
  152. package/esm/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.d.ts +1 -1
  153. package/esm/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.js +6 -8
  154. package/esm/LinearSyntenyView/components/ImportForm/TrackSelector.d.ts +1 -1
  155. package/esm/LinearSyntenyView/components/ImportForm/TrackSelector.js +4 -6
  156. package/esm/LinearSyntenyView/components/ImportForm/TrackSelectorUtil.d.ts +3 -3
  157. package/esm/LinearSyntenyView/components/ImportForm/TrackSelectorUtil.js +1 -1
  158. package/esm/LinearSyntenyView/components/ImportForm/util.js +1 -3
  159. package/esm/LinearSyntenyView/components/LinearSyntenyView.d.ts +1 -1
  160. package/esm/LinearSyntenyView/components/LinearSyntenyView.js +0 -1
  161. package/esm/LinearSyntenyView/index.d.ts +1 -1
  162. package/esm/LinearSyntenyView/model.d.ts +5 -28
  163. package/esm/LinearSyntenyView/model.js +4 -41
  164. package/esm/LinearSyntenyView/svgcomponents/SVGBackground.js +1 -1
  165. package/esm/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.d.ts +1 -1
  166. package/esm/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.js +2 -2
  167. package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.d.ts +1 -1
  168. package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +6 -11
  169. package/esm/LinearSyntenyViewHelper/index.d.ts +1 -1
  170. package/esm/LinearSyntenyViewHelper/stateModelFactory.d.ts +2 -14
  171. package/esm/LinearSyntenyViewHelper/stateModelFactory.js +2 -29
  172. package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.d.ts +1 -1
  173. package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.js +4 -13
  174. package/esm/SyntenyFeatureDetail/index.d.ts +1 -1
  175. package/esm/SyntenyFeatureDetail/index.js +1 -7
  176. package/esm/SyntenyTrack/configSchema.d.ts +1 -1
  177. package/esm/SyntenyTrack/configSchema.js +1 -9
  178. package/esm/SyntenyTrack/index.d.ts +1 -1
  179. package/esm/SyntenyTrack/index.js +1 -1
  180. package/esm/index.d.ts +1 -1
  181. package/esm/index.js +4 -4
  182. package/esm/util.d.ts +2 -2
  183. package/esm/util.js +1 -11
  184. package/package.json +2 -4
@@ -1,23 +1,12 @@
1
- import { AnyConfigurationSchemaType } from '@jbrowse/core/configuration';
2
- import { Instance } from 'mobx-state-tree';
3
- import { Feature } from '@jbrowse/core/util';
4
- /**
5
- * #stateModel LinearComparativeDisplay
6
- * extends
7
- * - [BaseDisplay](../basedisplay)
8
- */
1
+ import type { AnyConfigurationSchemaType } from '@jbrowse/core/configuration';
2
+ import type { Feature } from '@jbrowse/core/util';
3
+ import type { Instance } from 'mobx-state-tree';
9
4
  declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): import("mobx-state-tree").IModelType<{
10
5
  id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
11
6
  type: import("mobx-state-tree").ISimpleType<string>;
12
7
  rpcDriverName: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
13
8
  } & {
14
- /**
15
- * #property
16
- */
17
9
  type: import("mobx-state-tree").ISimpleType<"LinearComparativeDisplay">;
18
- /**
19
- * #property
20
- */
21
10
  configuration: AnyConfigurationSchemaType;
22
11
  }, {
23
12
  rendererTypeName: string;
@@ -43,10 +32,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
43
32
  message: string | undefined;
44
33
  }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
45
34
  onHorizontalScroll?: () => void;
46
- blockState? /**
47
- * #action
48
- * controlled by a reaction
49
- */: Record<string, any>;
35
+ blockState?: Record<string, any>;
50
36
  }>;
51
37
  readonly DisplayBlurb: React.FC<{
52
38
  model: {
@@ -58,10 +44,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
58
44
  error: unknown;
59
45
  message: string | undefined;
60
46
  } & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
61
- id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree" /**
62
- * #action
63
- * controlled by a reaction
64
- */).ISimpleType<string>, [undefined]>;
47
+ id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
65
48
  type: import("mobx-state-tree").ISimpleType<string>;
66
49
  rpcDriverName: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
67
50
  }, {
@@ -84,21 +67,12 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
84
67
  setRpcDriverName(rpcDriverName: string): void;
85
68
  reload(): void;
86
69
  } & {
87
- renderInProgress: AbortController | undefined;
70
+ renderInProgress: string | undefined;
88
71
  features: Feature[] | undefined;
89
72
  message: string | undefined;
90
73
  } & {
91
- /**
92
- * #getter
93
- */
94
74
  readonly level: number;
95
- /**
96
- * #getter
97
- */
98
75
  readonly height: number;
99
- /**
100
- * #getter
101
- */
102
76
  renderProps(): {
103
77
  rpcDriverName: string | undefined;
104
78
  displayModel: {
@@ -140,10 +114,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
140
114
  message: string | undefined;
141
115
  }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
142
116
  onHorizontalScroll?: () => void;
143
- blockState? /**
144
- * #action
145
- * controlled by a reaction
146
- */: Record<string, any>;
117
+ blockState?: Record<string, any>;
147
118
  }>;
148
119
  readonly DisplayBlurb: React.FC<{
149
120
  model: {
@@ -155,10 +126,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
155
126
  error: unknown;
156
127
  message: string | undefined;
157
128
  } & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
158
- id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree" /**
159
- * #action
160
- * controlled by a reaction
161
- */).ISimpleType<string>, [undefined]>;
129
+ id: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
162
130
  type: import("mobx-state-tree").ISimpleType<string>;
163
131
  rpcDriverName: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
164
132
  }, {
@@ -181,7 +149,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
181
149
  setRpcDriverName(rpcDriverName: string): void;
182
150
  reload(): void;
183
151
  } & {
184
- renderInProgress: AbortController | undefined;
152
+ renderInProgress: string | undefined;
185
153
  features: Feature[] | undefined;
186
154
  message: string | undefined;
187
155
  } & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
@@ -189,13 +157,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
189
157
  type: import("mobx-state-tree").ISimpleType<string>;
190
158
  rpcDriverName: import("mobx-state-tree").IMaybe<import("mobx-state-tree").ISimpleType<string>>;
191
159
  } & {
192
- /**
193
- * #property
194
- */
195
160
  type: import("mobx-state-tree").ISimpleType<"LinearComparativeDisplay">;
196
- /**
197
- * #property
198
- */
199
161
  configuration: AnyConfigurationSchemaType;
200
162
  }, {
201
163
  rendererTypeName: string;
@@ -221,10 +183,7 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
221
183
  message: string | undefined;
222
184
  }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
223
185
  onHorizontalScroll?: () => void;
224
- blockState? /**
225
- * #action
226
- * controlled by a reaction
227
- */: Record<string, any>;
186
+ blockState?: Record<string, any>;
228
187
  }>;
229
188
  readonly DisplayBlurb: React.FC<{
230
189
  model: {
@@ -259,34 +218,18 @@ declare function stateModelFactory(configSchema: AnyConfigurationSchemaType): im
259
218
  setRpcDriverName(rpcDriverName: string): void;
260
219
  reload(): void;
261
220
  } & {
262
- renderInProgress: AbortController | undefined;
221
+ renderInProgress: string | undefined;
263
222
  features: Feature[] | undefined;
264
223
  message: string | undefined;
265
224
  }, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
266
225
  highResolutionScaling: number;
267
226
  };
268
227
  } & {
269
- /**
270
- * #action
271
- * controlled by a reaction
272
- */
273
- setLoading(abortController: AbortController): void;
274
- /**
275
- * #action
276
- * controlled by a reaction
277
- */
228
+ setLoading(newStopToken: string): void;
278
229
  setMessage(messageText: string): void;
279
- /**
280
- * #action
281
- * controlled by a reaction
282
- */
283
230
  setRendered(args?: {
284
231
  features: Feature[];
285
232
  }): void;
286
- /**
287
- * #action
288
- * controlled by a reaction
289
- */
290
233
  setError(error: unknown): void;
291
234
  } & {
292
235
  afterAttach(): void;
@@ -1,48 +1,29 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const configuration_1 = require("@jbrowse/core/configuration");
4
- const mobx_state_tree_1 = require("mobx-state-tree");
4
+ const models_1 = require("@jbrowse/core/pluggableElementTypes/models");
5
5
  const util_1 = require("@jbrowse/core/util");
6
+ const stopToken_1 = require("@jbrowse/core/util/stopToken");
6
7
  const tracks_1 = require("@jbrowse/core/util/tracks");
7
- const models_1 = require("@jbrowse/core/pluggableElementTypes/models");
8
- /**
9
- * #stateModel LinearComparativeDisplay
10
- * extends
11
- * - [BaseDisplay](../basedisplay)
12
- */
8
+ const mobx_state_tree_1 = require("mobx-state-tree");
13
9
  function stateModelFactory(configSchema) {
14
10
  return mobx_state_tree_1.types
15
11
  .compose('LinearComparativeDisplay', models_1.BaseDisplay, mobx_state_tree_1.types.model({
16
- /**
17
- * #property
18
- */
19
12
  type: mobx_state_tree_1.types.literal('LinearComparativeDisplay'),
20
- /**
21
- * #property
22
- */
23
13
  configuration: (0, configuration_1.ConfigurationReference)(configSchema),
24
14
  }))
25
- .volatile(( /* self */) => ({
15
+ .volatile(() => ({
26
16
  renderInProgress: undefined,
27
17
  features: undefined,
28
18
  message: undefined,
29
19
  }))
30
20
  .views(self => ({
31
- /**
32
- * #getter
33
- */
34
21
  get level() {
35
22
  return (0, mobx_state_tree_1.getParent)(self, 4).level;
36
23
  },
37
- /**
38
- * #getter
39
- */
40
24
  get height() {
41
25
  return (0, mobx_state_tree_1.getParent)(self, 4).height;
42
26
  },
43
- /**
44
- * #getter
45
- */
46
27
  renderProps() {
47
28
  return {
48
29
  rpcDriverName: self.rpcDriverName,
@@ -52,33 +33,18 @@ function stateModelFactory(configSchema) {
52
33
  },
53
34
  }))
54
35
  .actions(self => {
55
- let renderInProgress;
36
+ let stopToken;
56
37
  return {
57
- /**
58
- * #action
59
- * controlled by a reaction
60
- */
61
- setLoading(abortController) {
38
+ setLoading(newStopToken) {
62
39
  self.message = undefined;
63
40
  self.error = undefined;
64
- renderInProgress = abortController;
41
+ stopToken = newStopToken;
65
42
  },
66
- /**
67
- * #action
68
- * controlled by a reaction
69
- */
70
43
  setMessage(messageText) {
71
- if (renderInProgress && !renderInProgress.signal.aborted) {
72
- renderInProgress.abort();
73
- }
74
44
  self.message = messageText;
75
45
  self.error = undefined;
76
- renderInProgress = undefined;
46
+ stopToken = undefined;
77
47
  },
78
- /**
79
- * #action
80
- * controlled by a reaction
81
- */
82
48
  setRendered(args) {
83
49
  if (!args) {
84
50
  return;
@@ -103,34 +69,27 @@ function stateModelFactory(configSchema) {
103
69
  }
104
70
  self.message = undefined;
105
71
  self.error = undefined;
106
- renderInProgress = undefined;
72
+ stopToken = undefined;
107
73
  if (foundNewFeatureNotInExistingMap ||
108
74
  foundExistingFeatureNotInNewMap ||
109
75
  !self.features) {
110
76
  self.features = features;
111
77
  }
112
78
  },
113
- /**
114
- * #action
115
- * controlled by a reaction
116
- */
117
79
  setError(error) {
118
80
  console.error(error);
119
- if (renderInProgress && !renderInProgress.signal.aborted) {
120
- renderInProgress.abort();
81
+ if (stopToken !== undefined) {
82
+ (0, stopToken_1.stopStopToken)(stopToken);
121
83
  }
122
- // the rendering failed for some reason
123
84
  self.message = undefined;
124
85
  self.error = error;
125
- renderInProgress = undefined;
86
+ stopToken = undefined;
126
87
  },
127
88
  };
128
89
  })
129
90
  .actions(self => ({
130
91
  afterAttach() {
131
- (0, util_1.makeAbortableReaction)(
132
- // @ts-expect-error
133
- self, renderBlockData, renderBlockEffect, {
92
+ (0, util_1.makeAbortableReaction)(self, renderBlockData, renderBlockEffect, {
134
93
  name: `${self.type} ${self.id} rendering`,
135
94
  delay: 1000,
136
95
  fireImmediately: true,
@@ -141,9 +100,6 @@ function stateModelFactory(configSchema) {
141
100
  function renderBlockData(self) {
142
101
  const { rpcManager } = (0, util_1.getSession)(self);
143
102
  const display = self;
144
- // Alternative to readConfObject(config) is below used because
145
- // renderProps is something under our control. Compare to
146
- // serverSideRenderedBlock
147
103
  (0, configuration_1.readConfObject)(self.configuration);
148
104
  const { level, adapterConfig } = self;
149
105
  const parent = (0, util_1.getContainingView)(self);
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearComparativeViewModel } from '../model';
2
+ import type { LinearComparativeViewModel } from '../model';
3
3
  declare const Header: ({ model, }: {
4
4
  model: LinearComparativeViewModel;
5
5
  }) => React.JSX.Element;
@@ -27,14 +27,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
29
  const react_1 = __importStar(require("react"));
30
- const mobx_react_1 = require("mobx-react");
31
- const material_1 = require("@mui/material");
32
- const mui_1 = require("tss-react/mui");
33
30
  const CascadingMenuButton_1 = __importDefault(require("@jbrowse/core/ui/CascadingMenuButton"));
34
- // icons
31
+ const Icons_1 = require("@jbrowse/core/ui/Icons");
35
32
  const MoreVert_1 = __importDefault(require("@mui/icons-material/MoreVert"));
36
33
  const Search_1 = __importDefault(require("@mui/icons-material/Search"));
37
- const Icons_1 = require("@jbrowse/core/ui/Icons");
34
+ const material_1 = require("@mui/material");
35
+ const mobx_react_1 = require("mobx-react");
36
+ const mui_1 = require("tss-react/mui");
38
37
  const HeaderSearchBoxes_1 = __importDefault(require("./HeaderSearchBoxes"));
39
38
  const useStyles = (0, mui_1.makeStyles)()({
40
39
  inline: {
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearGenomeViewModel } from '@jbrowse/plugin-linear-genome-view';
2
+ import type { LinearGenomeViewModel } from '@jbrowse/plugin-linear-genome-view';
3
3
  declare const HeaderSearchBoxes: ({ view, }: {
4
4
  view: LinearGenomeViewModel;
5
5
  }) => React.JSX.Element;
@@ -4,12 +4,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const react_1 = __importDefault(require("react"));
7
- const mobx_react_1 = require("mobx-react");
7
+ const util_1 = require("@jbrowse/core/util");
8
+ const plugin_linear_genome_view_1 = require("@jbrowse/plugin-linear-genome-view");
8
9
  const material_1 = require("@mui/material");
10
+ const mobx_react_1 = require("mobx-react");
9
11
  const mui_1 = require("tss-react/mui");
10
- // jbrowse
11
- const plugin_linear_genome_view_1 = require("@jbrowse/plugin-linear-genome-view");
12
- const util_1 = require("@jbrowse/core/util");
13
12
  const useStyles = (0, mui_1.makeStyles)()(() => ({
14
13
  bp: {
15
14
  display: 'flex',
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearComparativeViewModel } from '../model';
2
+ import type { LinearComparativeViewModel } from '../model';
3
3
  declare const LinearComparativeRenderArea: ({ model, }: {
4
4
  model: LinearComparativeViewModel;
5
5
  }) => React.JSX.Element;
@@ -4,11 +4,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const react_1 = __importDefault(require("react"));
7
- const mui_1 = require("tss-react/mui");
8
- const mobx_react_1 = require("mobx-react");
9
- const util_1 = require("@jbrowse/core/util");
10
- const ui_1 = require("@jbrowse/core/ui");
11
7
  const configuration_1 = require("@jbrowse/core/configuration");
8
+ const ui_1 = require("@jbrowse/core/ui");
9
+ const util_1 = require("@jbrowse/core/util");
10
+ const mobx_react_1 = require("mobx-react");
11
+ const mui_1 = require("tss-react/mui");
12
12
  const useStyles = (0, mui_1.makeStyles)()({
13
13
  container: {
14
14
  display: 'grid',
@@ -30,19 +30,12 @@ function View({ view }) {
30
30
  const LinearComparativeRenderArea = (0, mobx_react_1.observer)(function ({ model, }) {
31
31
  const { classes } = useStyles();
32
32
  const { views, levels } = model;
33
- const RenderList = [
34
- react_1.default.createElement(View, { key: views[0].id, view: views[0] }),
35
- ];
36
- for (let i = 1; i < views.length; i++) {
37
- const view = views[i];
38
- const level = levels[i - 1];
39
- RenderList.push(react_1.default.createElement(react_1.default.Fragment, { key: view.id },
33
+ return (react_1.default.createElement("div", { className: classes.container }, views.map((view, i) => (react_1.default.createElement(react_1.default.Fragment, { key: view.id },
34
+ i > 0 ? (react_1.default.createElement(react_1.default.Fragment, null,
40
35
  react_1.default.createElement("div", { className: classes.container },
41
36
  react_1.default.createElement(Overlays, { model: model, level: i - 1 })),
42
- react_1.default.createElement(ui_1.ResizeHandle, { onDrag: n => level === null || level === void 0 ? void 0 : level.setHeight(level.height + n), className: classes.resizeHandle }),
43
- react_1.default.createElement(View, { view: view })));
44
- }
45
- return react_1.default.createElement("div", { className: classes.container }, RenderList);
37
+ react_1.default.createElement(ui_1.ResizeHandle, { onDrag: n => { var _a, _b; return (_a = levels[i - 1]) === null || _a === void 0 ? void 0 : _a.setHeight((((_b = levels[i - 1]) === null || _b === void 0 ? void 0 : _b.height) || 0) + n); }, className: classes.resizeHandle }))) : null,
38
+ react_1.default.createElement(View, { view: view }))))));
46
39
  });
47
40
  const Overlays = (0, mobx_react_1.observer)(function ({ model, level, }) {
48
41
  var _a;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearComparativeViewModel } from '../model';
2
+ import type { LinearComparativeViewModel } from '../model';
3
3
  declare const LinearComparativeView: ({ model, }: {
4
4
  model: LinearComparativeViewModel;
5
5
  }) => React.JSX.Element;
@@ -4,14 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const react_1 = __importDefault(require("react"));
7
- const mui_1 = require("tss-react/mui");
8
7
  const mobx_react_1 = require("mobx-react");
9
- const Rubberband_1 = __importDefault(require("./Rubberband"));
8
+ const mui_1 = require("tss-react/mui");
10
9
  const Header_1 = __importDefault(require("./Header"));
11
10
  const LinearComparativeRenderArea_1 = __importDefault(require("./LinearComparativeRenderArea"));
11
+ const Rubberband_1 = __importDefault(require("./Rubberband"));
12
12
  const useStyles = (0, mui_1.makeStyles)()(theme => ({
13
- // this helps keep the vertical guide inside the parent view container,
14
- // similar style exists in the single LGV's trackscontainer
15
13
  rubberbandContainer: {
16
14
  position: 'relative',
17
15
  overflow: 'hidden',
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearComparativeViewModel } from '../model';
2
+ import type { LinearComparativeViewModel } from '../model';
3
3
  type LCV = LinearComparativeViewModel;
4
4
  declare const LinearComparativeRubberband: ({ model, ControlComponent, }: {
5
5
  model: LCV;
@@ -27,11 +27,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
29
  const react_1 = __importStar(require("react"));
30
- const mobx_react_1 = require("mobx-react");
30
+ const ui_1 = require("@jbrowse/core/ui");
31
+ const util_1 = require("@jbrowse/core/util");
31
32
  const material_1 = require("@mui/material");
33
+ const mobx_1 = require("mobx");
34
+ const mobx_react_1 = require("mobx-react");
32
35
  const mui_1 = require("tss-react/mui");
33
- const util_1 = require("@jbrowse/core/util");
34
- const ui_1 = require("@jbrowse/core/ui");
35
36
  const VerticalGuide_1 = __importDefault(require("./VerticalGuide"));
36
37
  const useStyles = (0, mui_1.makeStyles)()(theme => {
37
38
  return {
@@ -64,8 +65,6 @@ const useStyles = (0, mui_1.makeStyles)()(theme => {
64
65
  const LinearComparativeRubberband = (0, mobx_react_1.observer)(function Rubberband({ model, ControlComponent = react_1.default.createElement("div", null), }) {
65
66
  const [startX, setStartX] = (0, react_1.useState)();
66
67
  const [currentX, setCurrentX] = (0, react_1.useState)();
67
- // clientX and clientY used for anchorPosition for menu
68
- // offsetX used for calculations about width of selection
69
68
  const [anchorPosition, setAnchorPosition] = (0, react_1.useState)();
70
69
  const [guideX, setGuideX] = (0, react_1.useState)();
71
70
  const controlsRef = (0, react_1.useRef)(null);
@@ -79,7 +78,6 @@ const LinearComparativeRubberband = (0, mobx_react_1.observer)(function Rubberba
79
78
  }
80
79
  let leftPx = startX;
81
80
  let rightPx = offsetX;
82
- // handles clicking and dragging to the left
83
81
  if (rightPx < leftPx) {
84
82
  ;
85
83
  [leftPx, rightPx] = [rightPx, leftPx];
@@ -99,19 +97,19 @@ const LinearComparativeRubberband = (0, mobx_react_1.observer)(function Rubberba
99
97
  const { clientX, clientY } = event;
100
98
  const ref = controlsRef.current;
101
99
  const offsetX = clientX - ref.getBoundingClientRect().left;
102
- // as stated above, store both clientX/Y and offsetX for different
103
- // purposes
104
100
  setAnchorPosition({
105
101
  offsetX,
106
102
  clientX,
107
103
  clientY,
108
104
  });
109
- model.views.forEach(view => {
110
- const args = computeOffsets(offsetX, view);
111
- if (args) {
112
- const { leftOffset, rightOffset } = args;
113
- view.setOffsets(leftOffset, rightOffset);
114
- }
105
+ (0, mobx_1.transaction)(() => {
106
+ model.views.forEach(view => {
107
+ const args = computeOffsets(offsetX, view);
108
+ if (args) {
109
+ const { leftOffset, rightOffset } = args;
110
+ view.setOffsets(leftOffset, rightOffset);
111
+ }
112
+ });
115
113
  });
116
114
  setGuideX(undefined);
117
115
  }
@@ -148,8 +146,10 @@ const LinearComparativeRubberband = (0, mobx_react_1.observer)(function Rubberba
148
146
  }
149
147
  function mouseOut() {
150
148
  setGuideX(undefined);
151
- model.views.forEach(view => {
152
- view.setOffsets(undefined, undefined);
149
+ (0, mobx_1.transaction)(() => {
150
+ model.views.forEach(view => {
151
+ view.setOffsets(undefined, undefined);
152
+ });
153
153
  });
154
154
  }
155
155
  function handleClose() {
@@ -191,9 +191,7 @@ const LinearComparativeRubberband = (0, mobx_react_1.observer)(function Rubberba
191
191
  horizontal: 'left',
192
192
  }, keepMounted: true, disableRestoreFocus: true }, rightBpOffset.map((l, idx) => (react_1.default.createElement(material_1.Typography, { key: [JSON.stringify(l), idx, 'right'].join('-') }, (0, util_1.stringify)(l, true))))))) : null,
193
193
  react_1.default.createElement("div", { ref: rubberbandRef, className: classes.rubberband, style: { left, width } },
194
- react_1.default.createElement(material_1.Typography, { variant: "h6", className: classes.rubberbandText }, numOfBpSelected.map((n, i) => (
195
- /* biome-ignore lint/suspicious/noArrayIndexKey: */
196
- react_1.default.createElement(material_1.Typography, { key: `${n}_${i}` }, `${n.toLocaleString('en-US')}bp`))))),
194
+ react_1.default.createElement(material_1.Typography, { variant: "h6", className: classes.rubberbandText }, numOfBpSelected.map((n, i) => (react_1.default.createElement(material_1.Typography, { key: `${n}_${i}` }, `${n.toLocaleString('en-US')}bp`))))),
197
195
  react_1.default.createElement("div", { className: classes.rubberbandControl, ref: controlsRef, onMouseDown: mouseDown, onMouseOut: mouseOut, onMouseMove: mouseMove }, ControlComponent),
198
196
  anchorPosition ? (react_1.default.createElement(ui_1.Menu, { anchorReference: "anchorPosition", anchorPosition: {
199
197
  left: anchorPosition.clientX,
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { LinearComparativeViewModel } from '../model';
2
+ import type { LinearComparativeViewModel } from '../model';
3
3
  type LCV = LinearComparativeViewModel;
4
4
  declare const VerticalGuide: ({ model, coordX, }: {
5
5
  model: LCV;
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const react_1 = __importDefault(require("react"));
7
+ const util_1 = require("@jbrowse/core/util");
7
8
  const material_1 = require("@mui/material");
8
9
  const mobx_react_1 = require("mobx-react");
9
- const util_1 = require("@jbrowse/core/util");
10
10
  const mui_1 = require("tss-react/mui");
11
11
  const useStyles = (0, mui_1.makeStyles)()({
12
12
  guide: {
@@ -1,2 +1,2 @@
1
- import PluginManager from '@jbrowse/core/PluginManager';
1
+ import type PluginManager from '@jbrowse/core/PluginManager';
2
2
  export default function LinearComparativeViewF(pluginManager: PluginManager): void;