@jbrowse/plugin-linear-comparative-view 3.7.0 → 4.0.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 (266) hide show
  1. package/esm/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.js +3 -3
  2. package/esm/LGVSyntenyDisplay/configSchemaF.d.ts +9 -9
  3. package/esm/LGVSyntenyDisplay/configSchemaF.js +1 -1
  4. package/esm/LGVSyntenyDisplay/index.js +2 -2
  5. package/esm/LGVSyntenyDisplay/model.d.ts +1179 -133
  6. package/esm/LGVSyntenyDisplay/model.js +2 -2
  7. package/esm/LaunchLinearSyntenyView.js +13 -86
  8. package/esm/LinearComparativeDisplay/configSchemaF.d.ts +1 -1
  9. package/esm/LinearComparativeDisplay/index.js +2 -2
  10. package/esm/LinearComparativeDisplay/stateModelFactory.d.ts +95 -135
  11. package/esm/LinearComparativeDisplay/stateModelFactory.js +18 -17
  12. package/esm/LinearComparativeView/components/ColorBySelector.d.ts +1 -1
  13. package/esm/LinearComparativeView/components/ColorBySelector.js +3 -4
  14. package/esm/LinearComparativeView/components/Header.d.ts +1 -1
  15. package/esm/LinearComparativeView/components/Header.js +8 -9
  16. package/esm/LinearComparativeView/components/HeaderSearchBoxes.js +2 -2
  17. package/esm/LinearComparativeView/components/LinearComparativeRenderArea.d.ts +1 -1
  18. package/esm/LinearComparativeView/components/LinearComparativeRenderArea.js +9 -8
  19. package/esm/LinearComparativeView/components/LinearComparativeView.d.ts +1 -1
  20. package/esm/LinearComparativeView/components/LinearComparativeView.js +5 -5
  21. package/esm/LinearComparativeView/components/MinLengthSlider.d.ts +1 -1
  22. package/esm/LinearComparativeView/components/MinLengthSlider.js +7 -7
  23. package/esm/LinearComparativeView/components/OpacitySlider.d.ts +1 -1
  24. package/esm/LinearComparativeView/components/OpacitySlider.js +5 -6
  25. package/esm/LinearComparativeView/components/Rubberband.d.ts +1 -1
  26. package/esm/LinearComparativeView/components/Rubberband.js +5 -5
  27. package/esm/LinearComparativeView/components/RubberbandSpan.js +3 -5
  28. package/esm/LinearComparativeView/components/VerticalGuide.d.ts +1 -1
  29. package/esm/LinearComparativeView/components/VerticalGuide.js +2 -2
  30. package/esm/LinearComparativeView/components/useRangeSelect.d.ts +1 -1
  31. package/esm/LinearComparativeView/components/useRangeSelect.js +1 -1
  32. package/esm/LinearComparativeView/components/util.js +1 -1
  33. package/esm/LinearComparativeView/index.js +2 -2
  34. package/esm/LinearComparativeView/model.d.ts +474 -222
  35. package/esm/LinearComparativeView/model.js +50 -29
  36. package/esm/LinearReadVsRef/LinearReadVsRef.js +8 -9
  37. package/esm/LinearReadVsRef/index.js +1 -1
  38. package/esm/LinearSyntenyDisplay/afterAttach.d.ts +1 -1
  39. package/esm/LinearSyntenyDisplay/afterAttach.js +10 -11
  40. package/esm/LinearSyntenyDisplay/components/BlockError.js +1 -1
  41. package/esm/LinearSyntenyDisplay/components/BlockMessage.js +6 -15
  42. package/esm/LinearSyntenyDisplay/components/Component.d.ts +1 -1
  43. package/esm/LinearSyntenyDisplay/components/Component.js +5 -5
  44. package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.d.ts +1 -1
  45. package/esm/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +10 -14
  46. package/esm/LinearSyntenyDisplay/components/LoadingMessage.js +1 -1
  47. package/esm/LinearSyntenyDisplay/components/SyntenyContextMenu.d.ts +1 -1
  48. package/esm/LinearSyntenyDisplay/components/SyntenyContextMenu.js +8 -33
  49. package/esm/LinearSyntenyDisplay/components/SyntenyTooltip.d.ts +1 -1
  50. package/esm/LinearSyntenyDisplay/components/SyntenyTooltip.js +1 -1
  51. package/esm/LinearSyntenyDisplay/components/util.d.ts +2 -2
  52. package/esm/LinearSyntenyDisplay/components/util.js +3 -3
  53. package/esm/LinearSyntenyDisplay/configSchemaF.d.ts +2 -2
  54. package/esm/LinearSyntenyDisplay/configSchemaF.js +1 -1
  55. package/esm/LinearSyntenyDisplay/drawMouseoverClickMap.d.ts +2 -0
  56. package/esm/LinearSyntenyDisplay/drawMouseoverClickMap.js +53 -0
  57. package/esm/LinearSyntenyDisplay/drawSynteny.d.ts +1 -1
  58. package/esm/LinearSyntenyDisplay/drawSynteny.js +3 -5
  59. package/esm/LinearSyntenyDisplay/index.js +3 -3
  60. package/esm/LinearSyntenyDisplay/model.d.ts +97 -137
  61. package/esm/LinearSyntenyDisplay/model.js +3 -3
  62. package/esm/LinearSyntenyView/components/DiagonalizationProgressDialog.d.ts +1 -1
  63. package/esm/LinearSyntenyView/components/DiagonalizationProgressDialog.js +2 -2
  64. package/esm/LinearSyntenyView/components/ExportSvgDialog.d.ts +1 -1
  65. package/esm/LinearSyntenyView/components/ExportSvgDialog.js +6 -2
  66. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyOpenCustomTrack.d.ts +1 -1
  67. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyOpenCustomTrack.js +4 -4
  68. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyPreConfigured.d.ts +1 -1
  69. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyPreConfigured.js +4 -5
  70. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyTrackSelectorArea.d.ts +11 -1
  71. package/esm/LinearSyntenyView/components/ImportForm/ImportSyntenyTrackSelectorArea.js +8 -4
  72. package/esm/LinearSyntenyView/components/ImportForm/LeftPanel.d.ts +1 -1
  73. package/esm/LinearSyntenyView/components/ImportForm/LeftPanel.js +26 -9
  74. package/esm/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.d.ts +1 -1
  75. package/esm/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.js +5 -5
  76. package/esm/LinearSyntenyView/components/ImportForm/doSubmit.d.ts +1 -1
  77. package/esm/LinearSyntenyView/components/ImportForm/doSubmit.js +1 -2
  78. package/esm/LinearSyntenyView/components/ImportForm/selectors/AnchorsSelector.d.ts +1 -1
  79. package/esm/LinearSyntenyView/components/ImportForm/selectors/AnchorsSelector.js +2 -2
  80. package/esm/LinearSyntenyView/components/ImportForm/selectors/PifGzSelector.d.ts +1 -1
  81. package/esm/LinearSyntenyView/components/ImportForm/selectors/PifGzSelector.js +2 -2
  82. package/esm/LinearSyntenyView/components/ImportForm/selectors/StandardFormatSelector.d.ts +1 -1
  83. package/esm/LinearSyntenyView/components/ImportForm/selectors/StandardFormatSelector.js +3 -3
  84. package/esm/LinearSyntenyView/components/ImportForm/selectors/SwapAssemblies.js +3 -3
  85. package/esm/LinearSyntenyView/components/ImportForm/selectors/index.d.ts +4 -4
  86. package/esm/LinearSyntenyView/components/ImportForm/selectors/index.js +4 -4
  87. package/esm/LinearSyntenyView/components/LinearSyntenyView.d.ts +1 -1
  88. package/esm/LinearSyntenyView/components/LinearSyntenyView.js +14 -4
  89. package/esm/LinearSyntenyView/index.js +2 -2
  90. package/esm/LinearSyntenyView/model.d.ts +522 -254
  91. package/esm/LinearSyntenyView/model.js +99 -15
  92. package/esm/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.d.ts +3 -1
  93. package/esm/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.js +3 -3
  94. package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.d.ts +2 -2
  95. package/esm/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +34 -31
  96. package/esm/LinearSyntenyView/types.d.ts +10 -1
  97. package/esm/LinearSyntenyViewHelper/index.js +1 -1
  98. package/esm/LinearSyntenyViewHelper/stateModelFactory.d.ts +11 -11
  99. package/esm/LinearSyntenyViewHelper/stateModelFactory.js +5 -43
  100. package/esm/SyntenyFeatureDetail/Formatter.js +2 -2
  101. package/esm/SyntenyFeatureDetail/LinkToSyntenyView.d.ts +1 -1
  102. package/esm/SyntenyFeatureDetail/LinkToSyntenyView.js +6 -7
  103. package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.d.ts +1 -1
  104. package/esm/SyntenyFeatureDetail/SyntenyFeatureDetail.js +3 -3
  105. package/esm/SyntenyFeatureDetail/index.js +2 -2
  106. package/esm/SyntenyTrack/configSchema.d.ts +16 -11
  107. package/esm/SyntenyTrack/index.js +1 -1
  108. package/esm/index.d.ts +2 -0
  109. package/esm/index.js +11 -14
  110. package/esm/util.d.ts +1 -1
  111. package/esm/util.js +4 -8
  112. package/package.json +29 -35
  113. package/dist/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.d.ts +0 -9
  114. package/dist/LGVSyntenyDisplay/components/LaunchSyntenyViewDialog.js +0 -53
  115. package/dist/LGVSyntenyDisplay/components/util.d.ts +0 -14
  116. package/dist/LGVSyntenyDisplay/components/util.js +0 -100
  117. package/dist/LGVSyntenyDisplay/configSchemaF.d.ts +0 -66
  118. package/dist/LGVSyntenyDisplay/configSchemaF.js +0 -38
  119. package/dist/LGVSyntenyDisplay/index.d.ts +0 -2
  120. package/dist/LGVSyntenyDisplay/index.js +0 -24
  121. package/dist/LGVSyntenyDisplay/model.d.ts +0 -418
  122. package/dist/LGVSyntenyDisplay/model.js +0 -118
  123. package/dist/LaunchLinearSyntenyView.d.ts +0 -2
  124. package/dist/LaunchLinearSyntenyView.js +0 -93
  125. package/dist/LinearComparativeDisplay/configSchemaF.d.ts +0 -2
  126. package/dist/LinearComparativeDisplay/configSchemaF.js +0 -10
  127. package/dist/LinearComparativeDisplay/index.d.ts +0 -2
  128. package/dist/LinearComparativeDisplay/index.js +0 -24
  129. package/dist/LinearComparativeDisplay/stateModelFactory.d.ts +0 -243
  130. package/dist/LinearComparativeDisplay/stateModelFactory.js +0 -146
  131. package/dist/LinearComparativeView/components/ColorBySelector.d.ts +0 -5
  132. package/dist/LinearComparativeView/components/ColorBySelector.js +0 -54
  133. package/dist/LinearComparativeView/components/Header.d.ts +0 -5
  134. package/dist/LinearComparativeView/components/Header.js +0 -87
  135. package/dist/LinearComparativeView/components/HeaderSearchBoxes.d.ts +0 -5
  136. package/dist/LinearComparativeView/components/HeaderSearchBoxes.js +0 -24
  137. package/dist/LinearComparativeView/components/LinearComparativeRenderArea.d.ts +0 -5
  138. package/dist/LinearComparativeView/components/LinearComparativeRenderArea.js +0 -46
  139. package/dist/LinearComparativeView/components/LinearComparativeView.d.ts +0 -5
  140. package/dist/LinearComparativeView/components/LinearComparativeView.js +0 -30
  141. package/dist/LinearComparativeView/components/MinLengthSlider.d.ts +0 -5
  142. package/dist/LinearComparativeView/components/MinLengthSlider.js +0 -47
  143. package/dist/LinearComparativeView/components/OpacitySlider.d.ts +0 -5
  144. package/dist/LinearComparativeView/components/OpacitySlider.js +0 -46
  145. package/dist/LinearComparativeView/components/Rubberband.d.ts +0 -7
  146. package/dist/LinearComparativeView/components/Rubberband.js +0 -32
  147. package/dist/LinearComparativeView/components/RubberbandSpan.d.ts +0 -15
  148. package/dist/LinearComparativeView/components/RubberbandSpan.js +0 -38
  149. package/dist/LinearComparativeView/components/RubberbandTooltip.d.ts +0 -5
  150. package/dist/LinearComparativeView/components/RubberbandTooltip.js +0 -20
  151. package/dist/LinearComparativeView/components/SliderTooltip.d.ts +0 -2
  152. package/dist/LinearComparativeView/components/SliderTooltip.js +0 -9
  153. package/dist/LinearComparativeView/components/VerticalGuide.d.ts +0 -7
  154. package/dist/LinearComparativeView/components/VerticalGuide.js +0 -26
  155. package/dist/LinearComparativeView/components/useRangeSelect.d.ts +0 -59
  156. package/dist/LinearComparativeView/components/useRangeSelect.js +0 -124
  157. package/dist/LinearComparativeView/components/util.d.ts +0 -4
  158. package/dist/LinearComparativeView/components/util.js +0 -6
  159. package/dist/LinearComparativeView/index.d.ts +0 -2
  160. package/dist/LinearComparativeView/index.js +0 -55
  161. package/dist/LinearComparativeView/model.d.ts +0 -606
  162. package/dist/LinearComparativeView/model.js +0 -238
  163. package/dist/LinearReadVsRef/LinearReadVsRef.d.ts +0 -6
  164. package/dist/LinearReadVsRef/LinearReadVsRef.js +0 -241
  165. package/dist/LinearReadVsRef/index.d.ts +0 -2
  166. package/dist/LinearReadVsRef/index.js +0 -86
  167. package/dist/LinearSyntenyDisplay/afterAttach.d.ts +0 -2
  168. package/dist/LinearSyntenyDisplay/afterAttach.js +0 -104
  169. package/dist/LinearSyntenyDisplay/components/BlockError.d.ts +0 -3
  170. package/dist/LinearSyntenyDisplay/components/BlockError.js +0 -16
  171. package/dist/LinearSyntenyDisplay/components/BlockMessage.d.ts +0 -3
  172. package/dist/LinearSyntenyDisplay/components/BlockMessage.js +0 -24
  173. package/dist/LinearSyntenyDisplay/components/Component.d.ts +0 -5
  174. package/dist/LinearSyntenyDisplay/components/Component.js +0 -26
  175. package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.d.ts +0 -5
  176. package/dist/LinearSyntenyDisplay/components/LinearSyntenyRendering.js +0 -223
  177. package/dist/LinearSyntenyDisplay/components/LoadingMessage.d.ts +0 -3
  178. package/dist/LinearSyntenyDisplay/components/LoadingMessage.js +0 -21
  179. package/dist/LinearSyntenyDisplay/components/SyntenyContextMenu.d.ts +0 -15
  180. package/dist/LinearSyntenyDisplay/components/SyntenyContextMenu.js +0 -56
  181. package/dist/LinearSyntenyDisplay/components/SyntenyTooltip.d.ts +0 -4
  182. package/dist/LinearSyntenyDisplay/components/SyntenyTooltip.js +0 -13
  183. package/dist/LinearSyntenyDisplay/components/util.d.ts +0 -45
  184. package/dist/LinearSyntenyDisplay/components/util.js +0 -199
  185. package/dist/LinearSyntenyDisplay/configSchemaF.d.ts +0 -12
  186. package/dist/LinearSyntenyDisplay/configSchemaF.js +0 -23
  187. package/dist/LinearSyntenyDisplay/drawSynteny.d.ts +0 -6
  188. package/dist/LinearSyntenyDisplay/drawSynteny.js +0 -470
  189. package/dist/LinearSyntenyDisplay/index.d.ts +0 -2
  190. package/dist/LinearSyntenyDisplay/index.js +0 -56
  191. package/dist/LinearSyntenyDisplay/model.d.ts +0 -291
  192. package/dist/LinearSyntenyDisplay/model.js +0 -133
  193. package/dist/LinearSyntenyView/components/DiagonalizationProgressDialog.d.ts +0 -6
  194. package/dist/LinearSyntenyView/components/DiagonalizationProgressDialog.js +0 -87
  195. package/dist/LinearSyntenyView/components/ExportSvgDialog.d.ts +0 -7
  196. package/dist/LinearSyntenyView/components/ExportSvgDialog.js +0 -58
  197. package/dist/LinearSyntenyView/components/Icons.d.ts +0 -3
  198. package/dist/LinearSyntenyView/components/Icons.js +0 -12
  199. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyOpenCustomTrack.d.ts +0 -8
  200. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyOpenCustomTrack.js +0 -81
  201. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyPreConfigured.d.ts +0 -8
  202. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyPreConfigured.js +0 -39
  203. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyTrackSelectorArea.d.ts +0 -7
  204. package/dist/LinearSyntenyView/components/ImportForm/ImportSyntenyTrackSelectorArea.js +0 -22
  205. package/dist/LinearSyntenyView/components/ImportForm/LeftPanel.d.ts +0 -11
  206. package/dist/LinearSyntenyView/components/ImportForm/LeftPanel.js +0 -58
  207. package/dist/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.d.ts +0 -5
  208. package/dist/LinearSyntenyView/components/ImportForm/LinearSyntenyImportForm.js +0 -60
  209. package/dist/LinearSyntenyView/components/ImportForm/doSubmit.d.ts +0 -5
  210. package/dist/LinearSyntenyView/components/ImportForm/doSubmit.js +0 -43
  211. package/dist/LinearSyntenyView/components/ImportForm/getAdapter.d.ts +0 -117
  212. package/dist/LinearSyntenyView/components/ImportForm/getAdapter.js +0 -68
  213. package/dist/LinearSyntenyView/components/ImportForm/selectors/AnchorsSelector.d.ts +0 -3
  214. package/dist/LinearSyntenyView/components/ImportForm/selectors/AnchorsSelector.js +0 -13
  215. package/dist/LinearSyntenyView/components/ImportForm/selectors/PifGzSelector.d.ts +0 -3
  216. package/dist/LinearSyntenyView/components/ImportForm/selectors/PifGzSelector.js +0 -13
  217. package/dist/LinearSyntenyView/components/ImportForm/selectors/SelectorTypes.d.ts +0 -19
  218. package/dist/LinearSyntenyView/components/ImportForm/selectors/SelectorTypes.js +0 -10
  219. package/dist/LinearSyntenyView/components/ImportForm/selectors/StandardFormatSelector.d.ts +0 -3
  220. package/dist/LinearSyntenyView/components/ImportForm/selectors/StandardFormatSelector.js +0 -20
  221. package/dist/LinearSyntenyView/components/ImportForm/selectors/SwapAssemblies.d.ts +0 -13
  222. package/dist/LinearSyntenyView/components/ImportForm/selectors/SwapAssemblies.js +0 -32
  223. package/dist/LinearSyntenyView/components/ImportForm/selectors/index.d.ts +0 -4
  224. package/dist/LinearSyntenyView/components/ImportForm/selectors/index.js +0 -27
  225. package/dist/LinearSyntenyView/components/ImportForm/util.d.ts +0 -10
  226. package/dist/LinearSyntenyView/components/ImportForm/util.js +0 -24
  227. package/dist/LinearSyntenyView/components/LinearSyntenyView.d.ts +0 -5
  228. package/dist/LinearSyntenyView/components/LinearSyntenyView.js +0 -47
  229. package/dist/LinearSyntenyView/components/TextField2.d.ts +0 -2
  230. package/dist/LinearSyntenyView/components/TextField2.js +0 -8
  231. package/dist/LinearSyntenyView/index.d.ts +0 -2
  232. package/dist/LinearSyntenyView/index.js +0 -52
  233. package/dist/LinearSyntenyView/model.d.ts +0 -702
  234. package/dist/LinearSyntenyView/model.js +0 -240
  235. package/dist/LinearSyntenyView/svgcomponents/SVGBackground.d.ts +0 -5
  236. package/dist/LinearSyntenyView/svgcomponents/SVGBackground.js +0 -10
  237. package/dist/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.d.ts +0 -11
  238. package/dist/LinearSyntenyView/svgcomponents/SVGLinearGenomeView.js +0 -11
  239. package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.d.ts +0 -3
  240. package/dist/LinearSyntenyView/svgcomponents/SVGLinearSyntenyView.js +0 -80
  241. package/dist/LinearSyntenyView/types.d.ts +0 -29
  242. package/dist/LinearSyntenyView/types.js +0 -2
  243. package/dist/LinearSyntenyView/util/diagonalize.d.ts +0 -27
  244. package/dist/LinearSyntenyView/util/diagonalize.js +0 -91
  245. package/dist/LinearSyntenyViewHelper/index.d.ts +0 -2
  246. package/dist/LinearSyntenyViewHelper/index.js +0 -25
  247. package/dist/LinearSyntenyViewHelper/stateModelFactory.d.ts +0 -18
  248. package/dist/LinearSyntenyViewHelper/stateModelFactory.js +0 -78
  249. package/dist/SyntenyFeatureDetail/Formatter.d.ts +0 -3
  250. package/dist/SyntenyFeatureDetail/Formatter.js +0 -23
  251. package/dist/SyntenyFeatureDetail/LinkToSyntenyView.d.ts +0 -7
  252. package/dist/SyntenyFeatureDetail/LinkToSyntenyView.js +0 -87
  253. package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.d.ts +0 -5
  254. package/dist/SyntenyFeatureDetail/SyntenyFeatureDetail.js +0 -19
  255. package/dist/SyntenyFeatureDetail/index.d.ts +0 -2
  256. package/dist/SyntenyFeatureDetail/index.js +0 -60
  257. package/dist/SyntenyFeatureDetail/types.d.ts +0 -9
  258. package/dist/SyntenyFeatureDetail/types.js +0 -2
  259. package/dist/SyntenyTrack/configSchema.d.ts +0 -80
  260. package/dist/SyntenyTrack/configSchema.js +0 -9
  261. package/dist/SyntenyTrack/index.d.ts +0 -2
  262. package/dist/SyntenyTrack/index.js +0 -19
  263. package/dist/index.d.ts +0 -7
  264. package/dist/index.js +0 -48
  265. package/dist/util.d.ts +0 -25
  266. package/dist/util.js +0 -67
@@ -1,81 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const jsx_runtime_1 = require("react/jsx-runtime");
4
- const react_1 = require("react");
5
- const ui_1 = require("@jbrowse/core/ui");
6
- const material_1 = require("@mui/material");
7
- const mobx_react_1 = require("mobx-react");
8
- const getAdapter_1 = require("./getAdapter");
9
- const selectors_1 = require("./selectors");
10
- const util_1 = require("./util");
11
- const ImportSyntenyOpenCustomTrack = (0, mobx_react_1.observer)(function ({ model, assembly1, assembly2, selectedRow, }) {
12
- const [swap, setSwap] = (0, react_1.useState)(false);
13
- const [bed2Location, setBed2Location] = (0, react_1.useState)();
14
- const [bed1Location, setBed1Location] = (0, react_1.useState)();
15
- const [fileLocation, setFileLocation] = (0, react_1.useState)();
16
- const [indexFileLocation, setIndexFileLocation] = (0, react_1.useState)();
17
- const [value, setValue] = (0, react_1.useState)('');
18
- const [error, setError] = (0, react_1.useState)();
19
- const fileName = (0, util_1.getName)(fileLocation);
20
- const radioOption = value || (fileName ? (0, util_1.extName)((0, util_1.stripGz)(fileName)) : '');
21
- (0, react_1.useEffect)(() => {
22
- try {
23
- if (fileLocation) {
24
- const fn = fileName ? (0, util_1.basename)(fileName) : 'MyTrack';
25
- const trackId = `${fn}-${Date.now()}-sessionTrack`;
26
- setError(undefined);
27
- model.setImportFormSyntenyTrack(selectedRow, {
28
- type: 'userOpened',
29
- value: {
30
- trackId,
31
- name: fn,
32
- assemblyNames: [assembly2, assembly1],
33
- type: 'SyntenyTrack',
34
- adapter: (0, getAdapter_1.getAdapter)({
35
- radioOption,
36
- assembly1: swap ? assembly2 : assembly1,
37
- assembly2: swap ? assembly1 : assembly2,
38
- fileLocation,
39
- indexFileLocation,
40
- bed1Location,
41
- bed2Location,
42
- }),
43
- },
44
- });
45
- }
46
- }
47
- catch (e) {
48
- console.error(e);
49
- setError(e);
50
- }
51
- }, [
52
- swap,
53
- model,
54
- selectedRow,
55
- fileName,
56
- assembly1,
57
- assembly2,
58
- bed1Location,
59
- bed2Location,
60
- fileLocation,
61
- indexFileLocation,
62
- radioOption,
63
- ]);
64
- return ((0, jsx_runtime_1.jsxs)(material_1.Paper, { style: { padding: 12 }, children: [error ? (0, jsx_runtime_1.jsx)(ui_1.ErrorMessage, { error: error }) : null, (0, jsx_runtime_1.jsx)(material_1.Typography, { style: { textAlign: 'center' }, children: "Add a .paf (minimap2), .delta (Mummer), .chain (UCSC liftover), .anchors or .anchors.simple (MCScan), or .pif.gz (jbrowse CLI make-pif) file to view. These file types can also be gzipped." }), (0, jsx_runtime_1.jsx)(material_1.RadioGroup, { value: radioOption, onChange: event => {
65
- setValue(event.target.value);
66
- }, children: (0, jsx_runtime_1.jsx)(material_1.Grid, { container: true, justifyContent: "center", children: [
67
- '.paf',
68
- '.delta',
69
- '.out',
70
- '.chain',
71
- '.anchors',
72
- '.anchors.simple',
73
- '.pif.gz',
74
- ].map(extension => ((0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { value: extension, control: (0, jsx_runtime_1.jsx)(material_1.Radio, {}), label: extension }, extension))) }) }), (0, jsx_runtime_1.jsx)(material_1.Grid, { container: true, justifyContent: "center", children: radioOption === '.paf' ||
75
- radioOption === '.out' ||
76
- radioOption === '.delta' ||
77
- radioOption === '.chain' ? ((0, jsx_runtime_1.jsx)(selectors_1.StandardFormatSelector, { assembly1: assembly1, assembly2: assembly2, swap: swap, setSwap: setSwap, fileLocation: fileLocation, setFileLocation: setFileLocation, radioOption: radioOption })) : radioOption === '.pif.gz' ? ((0, jsx_runtime_1.jsx)(selectors_1.PifGzSelector, { assembly1: assembly1, assembly2: assembly2, swap: swap, setSwap: setSwap, fileLocation: fileLocation, setFileLocation: setFileLocation, indexFileLocation: indexFileLocation, setIndexFileLocation: setIndexFileLocation, radioOption: radioOption })) : value === '.anchors' || value === '.anchors.simple' ? ((0, jsx_runtime_1.jsx)(selectors_1.AnchorsSelector, { assembly1: assembly1, assembly2: assembly2, swap: swap, setSwap: setSwap, fileLocation: fileLocation, setFileLocation: setFileLocation, bed1Location: bed1Location, setBed1Location: setBed1Location, bed2Location: bed2Location, setBed2Location: setBed2Location, radioOption: value })) : ((0, jsx_runtime_1.jsx)(ui_1.FileSelector, { name: value ? `${value} location` : '', description: "", location: fileLocation, setLocation: loc => {
78
- setFileLocation(loc);
79
- } })) })] }));
80
- });
81
- exports.default = ImportSyntenyOpenCustomTrack;
@@ -1,8 +0,0 @@
1
- import type { LinearSyntenyViewModel } from '../../model';
2
- declare const ImportSyntenyTrackSelector: ({ model, selectedRow, assembly1, assembly2, }: {
3
- model: LinearSyntenyViewModel;
4
- selectedRow: number;
5
- assembly1: string;
6
- assembly2: string;
7
- }) => import("react/jsx-runtime").JSX.Element;
8
- export default ImportSyntenyTrackSelector;
@@ -1,39 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const jsx_runtime_1 = require("react/jsx-runtime");
4
- const react_1 = require("react");
5
- const configuration_1 = require("@jbrowse/core/configuration");
6
- const ui_1 = require("@jbrowse/core/ui");
7
- const util_1 = require("@jbrowse/core/util");
8
- const tracks_1 = require("@jbrowse/core/util/tracks");
9
- const material_1 = require("@mui/material");
10
- const mobx_react_1 = require("mobx-react");
11
- const ImportSyntenyTrackSelector = (0, mobx_react_1.observer)(function ({ model, selectedRow, assembly1, assembly2, }) {
12
- var _a;
13
- const session = (0, util_1.getSession)(model);
14
- const { importFormSyntenyTrackSelections } = model;
15
- const { tracks = [], sessionTracks = [] } = session;
16
- const allTracks = [...tracks, ...sessionTracks];
17
- const filteredTracks = allTracks.filter(track => {
18
- const assemblyNames = (0, configuration_1.readConfObject)(track, 'assemblyNames');
19
- return (assemblyNames.includes(assembly1) &&
20
- assemblyNames.includes(assembly2) &&
21
- track.type.includes('Synteny'));
22
- });
23
- const resetTrack = ((_a = filteredTracks[0]) === null || _a === void 0 ? void 0 : _a.trackId) || '';
24
- const r = importFormSyntenyTrackSelections[selectedRow];
25
- const value = (r === null || r === void 0 ? void 0 : r.type) === 'preConfigured' ? r.value : undefined;
26
- (0, react_1.useEffect)(() => {
27
- model.setImportFormSyntenyTrack(selectedRow, {
28
- type: 'preConfigured',
29
- value: resetTrack,
30
- });
31
- }, [assembly2, assembly1, resetTrack, selectedRow, model]);
32
- return ((0, jsx_runtime_1.jsxs)(material_1.Paper, { style: { padding: 12 }, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { children: "Select a track from the select box below, the track will be shown when you hit \"Launch\"." }), value && filteredTracks.map(r => r.trackId).includes(value) ? ((0, jsx_runtime_1.jsx)(material_1.Select, { value: value, onChange: event => {
33
- model.setImportFormSyntenyTrack(selectedRow, {
34
- type: 'preConfigured',
35
- value: event.target.value,
36
- });
37
- }, children: filteredTracks.map(track => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: track.trackId, children: (0, tracks_1.getTrackName)(track, session) }, track.trackId))) })) : ((0, jsx_runtime_1.jsx)(ui_1.ErrorMessage, { error: `No synteny tracks found for ${assembly1},${assembly2}` }))] }));
38
- });
39
- exports.default = ImportSyntenyTrackSelector;
@@ -1,7 +0,0 @@
1
- import type { LinearSyntenyViewModel } from '../../model';
2
- export default function ImportSyntenyTrackSelectorArea({ model, assembly1, assembly2, selectedRow, }: {
3
- model: LinearSyntenyViewModel;
4
- assembly1: string;
5
- assembly2: string;
6
- selectedRow: number;
7
- }): import("react/jsx-runtime").JSX.Element;
@@ -1,22 +0,0 @@
1
- "use strict";
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.default = ImportSyntenyTrackSelectorArea;
7
- const jsx_runtime_1 = require("react/jsx-runtime");
8
- const react_1 = require("react");
9
- const material_1 = require("@mui/material");
10
- const ImportSyntenyOpenCustomTrack_1 = __importDefault(require("./ImportSyntenyOpenCustomTrack"));
11
- const ImportSyntenyPreConfigured_1 = __importDefault(require("./ImportSyntenyPreConfigured"));
12
- function ImportSyntenyTrackSelectorArea({ model, assembly1, assembly2, selectedRow, }) {
13
- const [choice, setChoice] = (0, react_1.useState)('tracklist');
14
- (0, react_1.useEffect)(() => {
15
- if (choice === 'none') {
16
- model.setImportFormSyntenyTrack(selectedRow, { type: 'none' });
17
- }
18
- }, [choice, model, selectedRow]);
19
- return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(material_1.FormControl, { children: (0, jsx_runtime_1.jsxs)(material_1.RadioGroup, { row: true, value: choice, "aria-labelledby": "group-label", onChange: event => {
20
- setChoice(event.target.value);
21
- }, children: [(0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { value: "none", control: (0, jsx_runtime_1.jsx)(material_1.Radio, {}), label: "None" }), (0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { value: "tracklist", control: (0, jsx_runtime_1.jsx)(material_1.Radio, {}), label: "Existing track" }), (0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { value: "custom", control: (0, jsx_runtime_1.jsx)(material_1.Radio, {}), label: "New track" })] }) }), choice === 'custom' ? ((0, jsx_runtime_1.jsx)(ImportSyntenyOpenCustomTrack_1.default, { model: model, selectedRow: selectedRow, assembly2: assembly2, assembly1: assembly1 })) : null, choice === 'tracklist' ? ((0, jsx_runtime_1.jsx)(ImportSyntenyPreConfigured_1.default, { model: model, selectedRow: selectedRow, assembly1: assembly1, assembly2: assembly2 })) : null] }));
22
- }
@@ -1,11 +0,0 @@
1
- import type { LinearSyntenyViewModel } from '../../model';
2
- declare const LeftPanel: ({ model, selectedAssemblyNames, setSelectedAssemblyNames, selectedRow, setSelectedRow, defaultAssemblyName, onLaunch, }: {
3
- model: LinearSyntenyViewModel;
4
- selectedAssemblyNames: string[];
5
- setSelectedAssemblyNames: (names: string[]) => void;
6
- selectedRow: number;
7
- setSelectedRow: (row: number) => void;
8
- defaultAssemblyName: string;
9
- onLaunch: () => void;
10
- }) => import("react/jsx-runtime").JSX.Element;
11
- export default LeftPanel;
@@ -1,58 +0,0 @@
1
- "use strict";
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
- const jsx_runtime_1 = require("react/jsx-runtime");
7
- const ui_1 = require("@jbrowse/core/ui");
8
- const util_1 = require("@jbrowse/core/util");
9
- const ArrowForwardIos_1 = __importDefault(require("@mui/icons-material/ArrowForwardIos"));
10
- const Close_1 = __importDefault(require("@mui/icons-material/Close"));
11
- const material_1 = require("@mui/material");
12
- const mobx_react_1 = require("mobx-react");
13
- const mui_1 = require("tss-react/mui");
14
- const useStyles = (0, mui_1.makeStyles)()(theme => ({
15
- mb: {
16
- marginBottom: 10,
17
- },
18
- button: {
19
- margin: theme.spacing(2),
20
- },
21
- rel: {
22
- position: 'relative',
23
- },
24
- synbutton: {
25
- position: 'absolute',
26
- top: 30,
27
- },
28
- bg: {
29
- background: theme.palette.divider,
30
- },
31
- }));
32
- const AssemblyRows = (0, mobx_react_1.observer)(function ({ selectedRow, selectedAssemblyNames, setSelectedRow, setSelectedAssemblyNames, model, }) {
33
- const { classes, cx } = useStyles();
34
- const session = (0, util_1.getSession)(model);
35
- return selectedAssemblyNames.map((assemblyName, idx) => ((0, jsx_runtime_1.jsxs)("div", { className: classes.rel, children: [(0, jsx_runtime_1.jsxs)("span", { children: ["Row ", idx + 1, ": "] }), (0, jsx_runtime_1.jsx)(material_1.IconButton, { disabled: selectedAssemblyNames.length <= 2, onClick: () => {
36
- model.importFormRemoveRow(idx);
37
- setSelectedAssemblyNames(selectedAssemblyNames
38
- .map((asm, idx2) => (idx2 === idx ? undefined : asm))
39
- .filter(util_1.notEmpty));
40
- if (selectedRow >= selectedAssemblyNames.length - 2) {
41
- setSelectedRow(0);
42
- }
43
- }, children: (0, jsx_runtime_1.jsx)(Close_1.default, {}) }), (0, jsx_runtime_1.jsx)(ui_1.AssemblySelector, { helperText: "", selected: assemblyName, onChange: newAssembly => {
44
- setSelectedAssemblyNames(selectedAssemblyNames.map((asm, idx2) => idx2 === idx ? newAssembly : asm));
45
- }, session: session }), idx !== selectedAssemblyNames.length - 1 ? ((0, jsx_runtime_1.jsx)(material_1.IconButton, { "data-testid": "synbutton", className: cx(classes.synbutton, idx === selectedRow ? classes.bg : undefined), onClick: () => {
46
- setSelectedRow(idx);
47
- }, children: (0, jsx_runtime_1.jsx)(ArrowForwardIos_1.default, {}) })) : null] }, `${assemblyName}-${idx}`)));
48
- });
49
- const LeftPanel = (0, mobx_react_1.observer)(function ({ model, selectedAssemblyNames, setSelectedAssemblyNames, selectedRow, setSelectedRow, defaultAssemblyName, onLaunch, }) {
50
- const { classes } = useStyles();
51
- return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)("div", { className: classes.mb, children: "Select assemblies for linear synteny view" }), (0, jsx_runtime_1.jsx)(AssemblyRows, { model: model, selectedAssemblyNames: selectedAssemblyNames, setSelectedAssemblyNames: setSelectedAssemblyNames, selectedRow: selectedRow, setSelectedRow: setSelectedRow }), (0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(material_1.Button, { className: classes.button, variant: "contained", color: "secondary", onClick: () => {
52
- setSelectedAssemblyNames([
53
- ...selectedAssemblyNames,
54
- defaultAssemblyName,
55
- ]);
56
- }, children: "Add row" }), (0, jsx_runtime_1.jsx)(material_1.Button, { className: classes.button, onClick: onLaunch, variant: "contained", color: "primary", children: "Launch" })] })] }));
57
- });
58
- exports.default = LeftPanel;
@@ -1,5 +0,0 @@
1
- import type { LinearSyntenyViewModel } from '../../model';
2
- declare const LinearSyntenyViewImportForm: ({ model, }: {
3
- model: LinearSyntenyViewModel;
4
- }) => import("react/jsx-runtime").JSX.Element;
5
- export default LinearSyntenyViewImportForm;
@@ -1,60 +0,0 @@
1
- "use strict";
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
- const jsx_runtime_1 = require("react/jsx-runtime");
7
- const react_1 = require("react");
8
- const ui_1 = require("@jbrowse/core/ui");
9
- const util_1 = require("@jbrowse/core/util");
10
- const material_1 = require("@mui/material");
11
- const mobx_react_1 = require("mobx-react");
12
- const mui_1 = require("tss-react/mui");
13
- const ImportSyntenyTrackSelectorArea_1 = __importDefault(require("./ImportSyntenyTrackSelectorArea"));
14
- const LeftPanel_1 = __importDefault(require("./LeftPanel"));
15
- const doSubmit_1 = require("./doSubmit");
16
- const useStyles = (0, mui_1.makeStyles)()(theme => ({
17
- importFormContainer: {
18
- padding: theme.spacing(4),
19
- },
20
- flex: {
21
- display: 'flex',
22
- gap: 90,
23
- },
24
- rightPanel: {
25
- flexGrow: 11,
26
- },
27
- leftPanel: {
28
- flexGrow: 4,
29
- flexShrink: 0,
30
- },
31
- }));
32
- const LinearSyntenyViewImportForm = (0, mobx_react_1.observer)(function ({ model, }) {
33
- const { classes } = useStyles();
34
- const session = (0, util_1.getSession)(model);
35
- const { assemblyNames } = session;
36
- const defaultAssemblyName = assemblyNames[0] || '';
37
- const [selectedRow, setSelectedRow] = (0, react_1.useState)(0);
38
- const [selectedAssemblyNames, setSelectedAssemblyNames] = (0, react_1.useState)([
39
- defaultAssemblyName,
40
- defaultAssemblyName,
41
- ]);
42
- const [error, setError] = (0, react_1.useState)();
43
- const handleLaunch = async () => {
44
- try {
45
- setError(undefined);
46
- await (0, doSubmit_1.doSubmit)({
47
- selectedAssemblyNames,
48
- model,
49
- });
50
- }
51
- catch (e) {
52
- console.error(e);
53
- setError(e);
54
- }
55
- };
56
- return ((0, jsx_runtime_1.jsxs)(material_1.Container, { className: classes.importFormContainer, children: [error ? (0, jsx_runtime_1.jsx)(ui_1.ErrorMessage, { error: error }) : null, (0, jsx_runtime_1.jsxs)("div", { className: classes.flex, children: [(0, jsx_runtime_1.jsx)("div", { className: classes.leftPanel, children: (0, jsx_runtime_1.jsx)(LeftPanel_1.default, { model: model, selectedAssemblyNames: selectedAssemblyNames, setSelectedAssemblyNames: setSelectedAssemblyNames, selectedRow: selectedRow, setSelectedRow: setSelectedRow, defaultAssemblyName: defaultAssemblyName, onLaunch: () => {
57
- handleLaunch();
58
- } }) }), (0, jsx_runtime_1.jsxs)("div", { className: classes.rightPanel, children: [(0, jsx_runtime_1.jsxs)("div", { children: ["Synteny dataset to display between row ", selectedRow + 1, " and", ' ', selectedRow + 2] }), (0, jsx_runtime_1.jsx)(ImportSyntenyTrackSelectorArea_1.default, { model: model, selectedRow: selectedRow, assembly1: selectedAssemblyNames[selectedRow], assembly2: selectedAssemblyNames[selectedRow + 1] })] })] })] }));
59
- });
60
- exports.default = LinearSyntenyViewImportForm;
@@ -1,5 +0,0 @@
1
- import type { LinearSyntenyViewModel } from '../../model';
2
- export declare function doSubmit({ selectedAssemblyNames, model, }: {
3
- selectedAssemblyNames: string[];
4
- model: LinearSyntenyViewModel;
5
- }): Promise<void>;
@@ -1,43 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.doSubmit = doSubmit;
4
- const util_1 = require("@jbrowse/core/util");
5
- const mobx_1 = require("mobx");
6
- async function doSubmit({ selectedAssemblyNames, model, }) {
7
- const session = (0, util_1.getSession)(model);
8
- const { assemblyManager } = session;
9
- const { importFormSyntenyTrackSelections } = model;
10
- model.setViews(await Promise.all(selectedAssemblyNames.map(async (assemblyName) => {
11
- const asm = await assemblyManager.waitForAssembly(assemblyName);
12
- if (!asm) {
13
- throw new Error(`Assembly "${assemblyName}" failed to load`);
14
- }
15
- return {
16
- type: 'LinearGenomeView',
17
- bpPerPx: 1,
18
- offsetPx: 0,
19
- hideHeader: true,
20
- displayedRegions: asm.regions,
21
- };
22
- })));
23
- for (const view of model.views) {
24
- view.setWidth(model.width);
25
- view.showAllRegions();
26
- }
27
- if (!(0, util_1.isSessionWithAddTracks)(session)) {
28
- session.notify("Can't add tracks", 'warning');
29
- }
30
- else {
31
- (0, mobx_1.toJS)(importFormSyntenyTrackSelections).map((f, idx) => {
32
- var _a;
33
- if (f.type === 'userOpened') {
34
- session.addTrackConf(f.value);
35
- model.toggleTrack((_a = f.value) === null || _a === void 0 ? void 0 : _a.trackId, idx);
36
- }
37
- else if (f.type === 'preConfigured') {
38
- model.showTrack(f.value, idx);
39
- }
40
- });
41
- }
42
- model.clearImportFormSyntenyTracks();
43
- }
@@ -1,117 +0,0 @@
1
- import type { FileLocation } from '@jbrowse/core/util';
2
- export declare function getAdapter({ radioOption, assembly1, assembly2, fileLocation, indexFileLocation, bed1Location, bed2Location, }: {
3
- radioOption: string;
4
- assembly1: string;
5
- assembly2: string;
6
- fileLocation?: FileLocation;
7
- indexFileLocation?: FileLocation;
8
- bed1Location?: FileLocation;
9
- bed2Location?: FileLocation;
10
- }): {
11
- type: string;
12
- pafLocation: FileLocation | undefined;
13
- queryAssembly: string;
14
- targetAssembly: string;
15
- outLocation?: undefined;
16
- deltaLocation?: undefined;
17
- chainLocation?: undefined;
18
- mcscanAnchorsLocation?: undefined;
19
- bed1Location?: undefined;
20
- bed2Location?: undefined;
21
- assemblyNames?: undefined;
22
- mcscanSimpleAnchorsLocation?: undefined;
23
- pifGzLocation?: undefined;
24
- index?: undefined;
25
- } | {
26
- type: string;
27
- outLocation: FileLocation | undefined;
28
- queryAssembly: string;
29
- targetAssembly: string;
30
- pafLocation?: undefined;
31
- deltaLocation?: undefined;
32
- chainLocation?: undefined;
33
- mcscanAnchorsLocation?: undefined;
34
- bed1Location?: undefined;
35
- bed2Location?: undefined;
36
- assemblyNames?: undefined;
37
- mcscanSimpleAnchorsLocation?: undefined;
38
- pifGzLocation?: undefined;
39
- index?: undefined;
40
- } | {
41
- type: string;
42
- deltaLocation: FileLocation | undefined;
43
- queryAssembly: string;
44
- targetAssembly: string;
45
- pafLocation?: undefined;
46
- outLocation?: undefined;
47
- chainLocation?: undefined;
48
- mcscanAnchorsLocation?: undefined;
49
- bed1Location?: undefined;
50
- bed2Location?: undefined;
51
- assemblyNames?: undefined;
52
- mcscanSimpleAnchorsLocation?: undefined;
53
- pifGzLocation?: undefined;
54
- index?: undefined;
55
- } | {
56
- type: string;
57
- chainLocation: FileLocation | undefined;
58
- queryAssembly: string;
59
- targetAssembly: string;
60
- pafLocation?: undefined;
61
- outLocation?: undefined;
62
- deltaLocation?: undefined;
63
- mcscanAnchorsLocation?: undefined;
64
- bed1Location?: undefined;
65
- bed2Location?: undefined;
66
- assemblyNames?: undefined;
67
- mcscanSimpleAnchorsLocation?: undefined;
68
- pifGzLocation?: undefined;
69
- index?: undefined;
70
- } | {
71
- type: string;
72
- mcscanAnchorsLocation: FileLocation | undefined;
73
- bed1Location: FileLocation | undefined;
74
- bed2Location: FileLocation | undefined;
75
- assemblyNames: string[];
76
- pafLocation?: undefined;
77
- queryAssembly?: undefined;
78
- targetAssembly?: undefined;
79
- outLocation?: undefined;
80
- deltaLocation?: undefined;
81
- chainLocation?: undefined;
82
- mcscanSimpleAnchorsLocation?: undefined;
83
- pifGzLocation?: undefined;
84
- index?: undefined;
85
- } | {
86
- type: string;
87
- mcscanSimpleAnchorsLocation: FileLocation | undefined;
88
- bed1Location: FileLocation | undefined;
89
- bed2Location: FileLocation | undefined;
90
- assemblyNames: string[];
91
- pafLocation?: undefined;
92
- queryAssembly?: undefined;
93
- targetAssembly?: undefined;
94
- outLocation?: undefined;
95
- deltaLocation?: undefined;
96
- chainLocation?: undefined;
97
- mcscanAnchorsLocation?: undefined;
98
- pifGzLocation?: undefined;
99
- index?: undefined;
100
- } | {
101
- type: string;
102
- pifGzLocation: FileLocation | undefined;
103
- index: {
104
- location: FileLocation | undefined;
105
- };
106
- assemblyNames: string[];
107
- pafLocation?: undefined;
108
- queryAssembly?: undefined;
109
- targetAssembly?: undefined;
110
- outLocation?: undefined;
111
- deltaLocation?: undefined;
112
- chainLocation?: undefined;
113
- mcscanAnchorsLocation?: undefined;
114
- bed1Location?: undefined;
115
- bed2Location?: undefined;
116
- mcscanSimpleAnchorsLocation?: undefined;
117
- };
@@ -1,68 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getAdapter = getAdapter;
4
- function getAdapter({ radioOption, assembly1, assembly2, fileLocation, indexFileLocation, bed1Location, bed2Location, }) {
5
- if (radioOption === '.paf') {
6
- return {
7
- type: 'PAFAdapter',
8
- pafLocation: fileLocation,
9
- queryAssembly: assembly1,
10
- targetAssembly: assembly2,
11
- };
12
- }
13
- else if (radioOption === '.out') {
14
- return {
15
- type: 'MashMapAdapter',
16
- outLocation: fileLocation,
17
- queryAssembly: assembly1,
18
- targetAssembly: assembly2,
19
- };
20
- }
21
- else if (radioOption === '.delta') {
22
- return {
23
- type: 'DeltaAdapter',
24
- deltaLocation: fileLocation,
25
- queryAssembly: assembly1,
26
- targetAssembly: assembly2,
27
- };
28
- }
29
- else if (radioOption === '.chain') {
30
- return {
31
- type: 'ChainAdapter',
32
- chainLocation: fileLocation,
33
- queryAssembly: assembly1,
34
- targetAssembly: assembly2,
35
- };
36
- }
37
- else if (radioOption === '.anchors') {
38
- return {
39
- type: 'MCScanAnchorsAdapter',
40
- mcscanAnchorsLocation: fileLocation,
41
- bed1Location,
42
- bed2Location,
43
- assemblyNames: [assembly1, assembly2],
44
- };
45
- }
46
- else if (radioOption === '.anchors.simple') {
47
- return {
48
- type: 'MCScanSimpleAnchorsAdapter',
49
- mcscanSimpleAnchorsLocation: fileLocation,
50
- bed1Location,
51
- bed2Location,
52
- assemblyNames: [assembly1, assembly2],
53
- };
54
- }
55
- else if (radioOption === '.pif.gz') {
56
- return {
57
- type: 'PairwiseIndexedPAFAdapter',
58
- pifGzLocation: fileLocation,
59
- index: {
60
- location: indexFileLocation,
61
- },
62
- assemblyNames: [assembly1, assembly2],
63
- };
64
- }
65
- else {
66
- throw new Error(`Unknown to detect type ${radioOption} from filename (select radio button to clarify)`);
67
- }
68
- }
@@ -1,3 +0,0 @@
1
- import type { SelectorProps } from './SelectorTypes';
2
- declare const AnchorsSelector: ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, bed1Location, setBed1Location, bed2Location, setBed2Location, radioOption, }: SelectorProps) => import("react/jsx-runtime").JSX.Element;
3
- export default AnchorsSelector;
@@ -1,13 +0,0 @@
1
- "use strict";
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
- const jsx_runtime_1 = require("react/jsx-runtime");
7
- const ui_1 = require("@jbrowse/core/ui");
8
- const mobx_react_1 = require("mobx-react");
9
- const SwapAssemblies_1 = __importDefault(require("./SwapAssemblies"));
10
- const AnchorsSelector = (0, mobx_react_1.observer)(function ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, bed1Location = undefined, setBed1Location = () => { }, bed2Location = undefined, setBed2Location = () => { }, radioOption, }) {
11
- return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: { margin: 20 }, children: ["Open the ", radioOption, " and .bed files for both genome assemblies from the MCScan (Python version) pipeline", ' ', (0, jsx_runtime_1.jsx)("a", { href: "https://github.com/tanghaibao/jcvi/wiki/MCscan-(Python-version)", children: "(more info)" })] }), (0, jsx_runtime_1.jsxs)("div", { style: { maxWidth: 400, margin: '0 auto' }, children: [(0, jsx_runtime_1.jsx)(ui_1.FileSelector, { inline: true, name: radioOption, location: fileLocation, setLocation: setFileLocation }), (0, jsx_runtime_1.jsx)(ui_1.FileSelector, { inline: true, name: "genome 1 .bed (left column of anchors file)", description: "", location: bed1Location, setLocation: setBed1Location }), (0, jsx_runtime_1.jsx)(ui_1.FileSelector, { inline: true, name: "genome 2 .bed (right column of anchors file)", description: "", location: bed2Location, setLocation: setBed2Location }), (0, jsx_runtime_1.jsx)(SwapAssemblies_1.default, { swap: swap, radioOption: radioOption, assembly1: assembly1, assembly2: assembly2, setSwap: setSwap, text1: "bed 1 assembly", text2: "bed 2 assembly" })] })] }));
12
- });
13
- exports.default = AnchorsSelector;
@@ -1,3 +0,0 @@
1
- import type { SelectorProps } from './SelectorTypes';
2
- declare const PifGzSelector: ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, indexFileLocation, setIndexFileLocation, radioOption, }: SelectorProps) => import("react/jsx-runtime").JSX.Element;
3
- export default PifGzSelector;
@@ -1,13 +0,0 @@
1
- "use strict";
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
- const jsx_runtime_1 = require("react/jsx-runtime");
7
- const ui_1 = require("@jbrowse/core/ui");
8
- const mobx_react_1 = require("mobx-react");
9
- const SwapAssemblies_1 = __importDefault(require("./SwapAssemblies"));
10
- const PifGzSelector = (0, mobx_react_1.observer)(function ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, indexFileLocation = undefined, setIndexFileLocation = () => { }, radioOption, }) {
11
- return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: { margin: 20 }, children: ["Open the ", radioOption, " and .pif.gz and index file (.pif.gz.tbi or .pif.gz.csi) files for created by `jbrowse make-pif`"] }), (0, jsx_runtime_1.jsxs)("div", { style: { maxWidth: 400, margin: '0 auto' }, children: [(0, jsx_runtime_1.jsx)(ui_1.FileSelector, { name: `${radioOption} location`, inline: true, description: "", location: fileLocation, setLocation: setFileLocation }), (0, jsx_runtime_1.jsx)(ui_1.FileSelector, { name: `${radioOption} index location`, inline: true, description: "", location: indexFileLocation, setLocation: setIndexFileLocation }), (0, jsx_runtime_1.jsx)(SwapAssemblies_1.default, { swap: swap, radioOption: radioOption, assembly1: assembly1, assembly2: assembly2, setSwap: setSwap, text1: "query assembly", text2: "target assembly" })] })] }));
12
- });
13
- exports.default = PifGzSelector;
@@ -1,19 +0,0 @@
1
- import type { FileLocation } from '@jbrowse/core/util/types';
2
- export interface SelectorProps {
3
- assembly1: string;
4
- assembly2: string;
5
- swap: boolean;
6
- setSwap?: (swap: boolean) => void;
7
- fileLocation: FileLocation | undefined;
8
- setFileLocation: (location: FileLocation | undefined) => void;
9
- indexFileLocation?: FileLocation | undefined;
10
- setIndexFileLocation?: (location: FileLocation | undefined) => void;
11
- bed1Location?: FileLocation | undefined;
12
- setBed1Location?: (location: FileLocation | undefined) => void;
13
- bed2Location?: FileLocation | undefined;
14
- setBed2Location?: (location: FileLocation | undefined) => void;
15
- radioOption: string;
16
- }
17
- export type SetLocationFunction = (location: FileLocation | undefined) => void;
18
- export type HelpStrings = Record<string, string>;
19
- export declare const helpStrings: HelpStrings;
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.helpStrings = void 0;
4
- exports.helpStrings = {
5
- '.paf': 'minimap2 target.fa query.fa',
6
- '.pif.gz': 'minimap2 target.fa query.fa',
7
- '.out': 'mashmap target.fa query.fa',
8
- '.delta': 'mummer target.fa query.fa',
9
- '.chain': 'e.g. queryToTarget.chain',
10
- };
@@ -1,3 +0,0 @@
1
- import type { SelectorProps } from './SelectorTypes';
2
- declare const StandardFormatSelector: ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, radioOption, }: SelectorProps) => import("react/jsx-runtime").JSX.Element;
3
- export default StandardFormatSelector;
@@ -1,20 +0,0 @@
1
- "use strict";
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
- const jsx_runtime_1 = require("react/jsx-runtime");
7
- const ui_1 = require("@jbrowse/core/ui");
8
- const Help_1 = __importDefault(require("@mui/icons-material/Help"));
9
- const material_1 = require("@mui/material");
10
- const mobx_react_1 = require("mobx-react");
11
- const SelectorTypes_1 = require("./SelectorTypes");
12
- const SwapAssemblies_1 = __importDefault(require("./SwapAssemblies"));
13
- const StandardFormatSelector = (0, mobx_react_1.observer)(function ({ assembly1, assembly2, swap, setSwap, fileLocation, setFileLocation, radioOption, }) {
14
- return ((0, jsx_runtime_1.jsxs)("div", { style: {
15
- display: 'flex',
16
- flexDirection: 'column',
17
- gap: 10,
18
- }, children: [(0, jsx_runtime_1.jsx)(ui_1.FileSelector, { name: `${radioOption} location`, inline: true, description: "", location: fileLocation, setLocation: setFileLocation }), (0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { children: ["Verify or click swap", (0, jsx_runtime_1.jsx)(material_1.Tooltip, { title: (0, jsx_runtime_1.jsx)("code", { children: SelectorTypes_1.helpStrings[radioOption] }), children: (0, jsx_runtime_1.jsx)(Help_1.default, {}) })] }), (0, jsx_runtime_1.jsx)(SwapAssemblies_1.default, { swap: swap, radioOption: radioOption, assembly1: assembly1, assembly2: assembly2, setSwap: setSwap, text1: "query assembly", text2: "target assembly" })] })] }));
19
- });
20
- exports.default = StandardFormatSelector;