react-msaview 8.2.0 → 8.4.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 (255) hide show
  1. package/bundle/index.js +77 -300
  2. package/bundle/index.js.map +4 -4
  3. package/dist/blockFasta.d.ts +6 -0
  4. package/dist/blockFasta.js +12 -0
  5. package/dist/blockFasta.js.map +1 -0
  6. package/dist/colorSchemes.d.ts +7 -0
  7. package/dist/colorSchemes.js +15 -0
  8. package/dist/colorSchemes.js.map +1 -1
  9. package/dist/columnCounts.d.ts +4 -3
  10. package/dist/columnCounts.js +11 -6
  11. package/dist/columnCounts.js.map +1 -1
  12. package/dist/components/CopyButton.d.ts +1 -1
  13. package/dist/components/CopyButton.js +1 -1
  14. package/dist/components/CopyButton.js.map +1 -1
  15. package/dist/components/DragHandle.js +14 -2
  16. package/dist/components/DragHandle.js.map +1 -1
  17. package/dist/components/Loading.js +10 -11
  18. package/dist/components/Loading.js.map +1 -1
  19. package/dist/components/MSAView.js +15 -9
  20. package/dist/components/MSAView.js.map +1 -1
  21. package/dist/components/MSAViewer.d.ts +39 -7
  22. package/dist/components/MSAViewer.js +72 -22
  23. package/dist/components/MSAViewer.js.map +1 -1
  24. package/dist/components/MetadataTable.d.ts +5 -0
  25. package/dist/components/MetadataTable.js +29 -0
  26. package/dist/components/MetadataTable.js.map +1 -0
  27. package/dist/components/SequenceTextArea.d.ts +11 -0
  28. package/dist/components/SequenceTextArea.js +40 -8
  29. package/dist/components/SequenceTextArea.js.map +1 -1
  30. package/dist/components/StatusMessage.d.ts +12 -0
  31. package/dist/components/StatusMessage.js +43 -0
  32. package/dist/components/StatusMessage.js.map +1 -0
  33. package/dist/components/Track.js +13 -4
  34. package/dist/components/Track.js.map +1 -1
  35. package/dist/components/VerticalScrollbar.js +6 -1
  36. package/dist/components/VerticalScrollbar.js.map +1 -1
  37. package/dist/components/dialogs/ExportSVGDialog.d.ts +3 -2
  38. package/dist/components/dialogs/ExportSVGDialog.js +4 -2
  39. package/dist/components/dialogs/ExportSVGDialog.js.map +1 -1
  40. package/dist/components/dialogs/FeatureDialog.js +15 -10
  41. package/dist/components/dialogs/FeatureDialog.js.map +1 -1
  42. package/dist/components/dialogs/MetadataDialog.js +5 -6
  43. package/dist/components/dialogs/MetadataDialog.js.map +1 -1
  44. package/dist/components/getVisibleLeaves.d.ts +1 -1
  45. package/dist/components/header/ColorSchemeMenu.d.ts +6 -0
  46. package/dist/components/header/ColorSchemeMenu.js +23 -5
  47. package/dist/components/header/ColorSchemeMenu.js.map +1 -1
  48. package/dist/components/header/FileMenu.js +9 -0
  49. package/dist/components/header/FileMenu.js.map +1 -1
  50. package/dist/components/header/GappynessSlider.js +15 -3
  51. package/dist/components/header/GappynessSlider.js.map +1 -1
  52. package/dist/components/header/{HeaderStatusArea.d.ts → GoToBox.d.ts} +2 -2
  53. package/dist/components/header/GoToBox.js +21 -0
  54. package/dist/components/header/GoToBox.js.map +1 -0
  55. package/dist/components/header/Header.js +8 -7
  56. package/dist/components/header/Header.js.map +1 -1
  57. package/dist/components/header/SelectionMenu.d.ts +12 -0
  58. package/dist/components/header/SelectionMenu.js +72 -0
  59. package/dist/components/header/SelectionMenu.js.map +1 -0
  60. package/dist/components/header/goTo.d.ts +20 -0
  61. package/dist/components/header/goTo.js +69 -0
  62. package/dist/components/header/goTo.js.map +1 -0
  63. package/dist/components/header/settingsMenuItems.js +57 -1
  64. package/dist/components/header/settingsMenuItems.js.map +1 -1
  65. package/dist/components/import/ImportForm.js +10 -4
  66. package/dist/components/import/ImportForm.js.map +1 -1
  67. package/dist/components/import/ImportFormExamples.js +19 -27
  68. package/dist/components/import/ImportFormExamples.js.map +1 -1
  69. package/dist/components/minimap/Minimap.js +6 -1
  70. package/dist/components/minimap/Minimap.js.map +1 -1
  71. package/dist/components/msa/AnnotationLegend.js +11 -5
  72. package/dist/components/msa/AnnotationLegend.js.map +1 -1
  73. package/dist/components/msa/MSACanvas.js +17 -1
  74. package/dist/components/msa/MSACanvas.js.map +1 -1
  75. package/dist/components/msa/MSACanvasBlock.js +6 -6
  76. package/dist/components/msa/MSACanvasBlock.js.map +1 -1
  77. package/dist/components/msa/msaKeys.d.ts +5 -0
  78. package/dist/components/msa/msaKeys.js +41 -0
  79. package/dist/components/msa/msaKeys.js.map +1 -0
  80. package/dist/components/msa/msaRaster.js +1 -0
  81. package/dist/components/msa/msaRaster.js.map +1 -1
  82. package/dist/components/msa/renderHighlights.d.ts +14 -3
  83. package/dist/components/msa/renderHighlights.js +29 -4
  84. package/dist/components/msa/renderHighlights.js.map +1 -1
  85. package/dist/components/msa/tileColor.js +9 -8
  86. package/dist/components/msa/tileColor.js.map +1 -1
  87. package/dist/components/msa/useMsaBlockMouse.d.ts +2 -4
  88. package/dist/components/msa/useMsaBlockMouse.js +34 -14
  89. package/dist/components/msa/useMsaBlockMouse.js.map +1 -1
  90. package/dist/components/overlayColors.d.ts +2 -0
  91. package/dist/components/overlayColors.js +3 -0
  92. package/dist/components/overlayColors.js.map +1 -1
  93. package/dist/components/rowpanels/RowPanelBlock.js +10 -14
  94. package/dist/components/rowpanels/RowPanelBlock.js.map +1 -1
  95. package/dist/components/selectionDrag.d.ts +17 -0
  96. package/dist/components/selectionDrag.js +30 -0
  97. package/dist/components/selectionDrag.js.map +1 -0
  98. package/dist/components/tracks/drawTracks.d.ts +1 -0
  99. package/dist/components/tracks/drawTracks.js +14 -2
  100. package/dist/components/tracks/drawTracks.js.map +1 -1
  101. package/dist/components/tracks/useTrackHover.d.ts +4 -6
  102. package/dist/components/tracks/useTrackHover.js +30 -10
  103. package/dist/components/tracks/useTrackHover.js.map +1 -1
  104. package/dist/components/tree/ScaleBarSVG.d.ts +14 -0
  105. package/dist/components/tree/ScaleBarSVG.js +11 -0
  106. package/dist/components/tree/ScaleBarSVG.js.map +1 -0
  107. package/dist/components/tree/TreeCanvas.js +8 -26
  108. package/dist/components/tree/TreeCanvas.js.map +1 -1
  109. package/dist/components/tree/TreeCanvasBlock.js +11 -20
  110. package/dist/components/tree/TreeCanvasBlock.js.map +1 -1
  111. package/dist/components/tree/{TreeBranchMenu.d.ts → TreeMenu.d.ts} +5 -4
  112. package/dist/components/tree/TreeMenu.js +48 -0
  113. package/dist/components/tree/TreeMenu.js.map +1 -0
  114. package/dist/components/tree/TreeRuler.js +3 -3
  115. package/dist/components/tree/TreeRuler.js.map +1 -1
  116. package/dist/components/tree/dialogs/TreeNodeInfoDialog.js +9 -8
  117. package/dist/components/tree/dialogs/TreeNodeInfoDialog.js.map +1 -1
  118. package/dist/components/tree/renderTreeCanvas.js +19 -9
  119. package/dist/components/tree/renderTreeCanvas.js.map +1 -1
  120. package/dist/components/tree/renderTreeMouseover.d.ts +5 -0
  121. package/dist/components/tree/renderTreeMouseover.js +20 -0
  122. package/dist/components/tree/renderTreeMouseover.js.map +1 -0
  123. package/dist/components/tree/useTreeHover.d.ts +3 -8
  124. package/dist/components/tree/useTreeHover.js +8 -10
  125. package/dist/components/tree/useTreeHover.js.map +1 -1
  126. package/dist/components/useHoverAnchor.d.ts +19 -0
  127. package/dist/components/useHoverAnchor.js +18 -0
  128. package/dist/components/useHoverAnchor.js.map +1 -0
  129. package/dist/constants.d.ts +3 -0
  130. package/dist/constants.js +12 -3
  131. package/dist/constants.js.map +1 -1
  132. package/dist/element.d.ts +7 -3
  133. package/dist/element.js +32 -4
  134. package/dist/element.js.map +1 -1
  135. package/dist/expandSpec.js +3 -3
  136. package/dist/expandSpec.js.map +1 -1
  137. package/dist/exportFileName.d.ts +3 -3
  138. package/dist/exportFileName.js +4 -4
  139. package/dist/exportFileName.js.map +1 -1
  140. package/dist/featuresLayer.d.ts +8 -0
  141. package/dist/featuresLayer.js +42 -0
  142. package/dist/featuresLayer.js.map +1 -0
  143. package/dist/hierarchy.d.ts +51 -0
  144. package/dist/hierarchy.js +125 -0
  145. package/dist/hierarchy.js.map +1 -1
  146. package/dist/index.d.ts +2 -2
  147. package/dist/model/DataModel.d.ts +1 -1
  148. package/dist/model/DataModel.js +3 -3
  149. package/dist/model/DataModel.js.map +1 -1
  150. package/dist/model/msaModel.d.ts +14 -1
  151. package/dist/model/msaModel.js +17 -1
  152. package/dist/model/msaModel.js.map +1 -1
  153. package/dist/model/treeModel.d.ts +12 -0
  154. package/dist/model/treeModel.js +14 -1
  155. package/dist/model/treeModel.js.map +1 -1
  156. package/dist/model.d.ts +285 -53
  157. package/dist/model.js +693 -231
  158. package/dist/model.js.map +1 -1
  159. package/dist/renderToSvg.js +2 -4
  160. package/dist/renderToSvg.js.map +1 -1
  161. package/dist/rerootTree.d.ts +33 -0
  162. package/dist/rerootTree.js +144 -0
  163. package/dist/rerootTree.js.map +1 -0
  164. package/dist/svgTestUtil.d.ts +172 -26
  165. package/dist/types.d.ts +75 -12
  166. package/dist/useMsaSvgFigure.d.ts +2 -1
  167. package/dist/useMsaSvgFigure.js +11 -4
  168. package/dist/useMsaSvgFigure.js.map +1 -1
  169. package/dist/version.d.ts +1 -1
  170. package/dist/version.js +1 -1
  171. package/dist/writeNewick.d.ts +8 -0
  172. package/dist/writeNewick.js +34 -0
  173. package/dist/writeNewick.js.map +1 -0
  174. package/package.json +3 -3
  175. package/src/blockFasta.ts +18 -0
  176. package/src/colorSchemes.ts +20 -0
  177. package/src/columnCounts.ts +14 -6
  178. package/src/components/CopyButton.tsx +2 -2
  179. package/src/components/DragHandle.tsx +21 -1
  180. package/src/components/Loading.tsx +14 -30
  181. package/src/components/MSAView.tsx +16 -9
  182. package/src/components/MSAViewer.tsx +121 -26
  183. package/src/components/MetadataTable.tsx +55 -0
  184. package/src/components/SequenceTextArea.tsx +54 -8
  185. package/src/components/StatusMessage.tsx +70 -0
  186. package/src/components/Track.tsx +21 -4
  187. package/src/components/VerticalScrollbar.tsx +7 -0
  188. package/src/components/dialogs/ExportSVGDialog.tsx +5 -2
  189. package/src/components/dialogs/FeatureDialog.tsx +59 -38
  190. package/src/components/dialogs/MetadataDialog.tsx +9 -8
  191. package/src/components/header/ColorSchemeMenu.tsx +31 -12
  192. package/src/components/header/FileMenu.tsx +9 -0
  193. package/src/components/header/GappynessSlider.tsx +17 -4
  194. package/src/components/header/GoToBox.tsx +50 -0
  195. package/src/components/header/Header.tsx +11 -8
  196. package/src/components/header/SelectionMenu.tsx +117 -0
  197. package/src/components/header/goTo.ts +75 -0
  198. package/src/components/header/settingsMenuItems.ts +66 -0
  199. package/src/components/import/ImportForm.tsx +14 -7
  200. package/src/components/import/ImportFormExamples.tsx +20 -28
  201. package/src/components/minimap/Minimap.tsx +7 -0
  202. package/src/components/msa/AnnotationLegend.tsx +12 -6
  203. package/src/components/msa/MSACanvas.tsx +19 -1
  204. package/src/components/msa/MSACanvasBlock.tsx +9 -11
  205. package/src/components/msa/msaKeys.ts +45 -0
  206. package/src/components/msa/msaRaster.ts +1 -0
  207. package/src/components/msa/renderHighlights.ts +46 -4
  208. package/src/components/msa/tileColor.ts +9 -8
  209. package/src/components/msa/useMsaBlockMouse.ts +44 -31
  210. package/src/components/overlayColors.ts +4 -0
  211. package/src/components/rowpanels/RowPanelBlock.tsx +16 -23
  212. package/src/components/selectionDrag.ts +42 -0
  213. package/src/components/tracks/drawTracks.ts +15 -2
  214. package/src/components/tracks/useTrackHover.ts +32 -10
  215. package/src/components/tree/ScaleBarSVG.tsx +30 -0
  216. package/src/components/tree/TreeCanvas.tsx +9 -40
  217. package/src/components/tree/TreeCanvasBlock.tsx +19 -39
  218. package/src/components/tree/TreeMenu.tsx +129 -0
  219. package/src/components/tree/TreeRuler.tsx +7 -13
  220. package/src/components/tree/dialogs/TreeNodeInfoDialog.tsx +14 -16
  221. package/src/components/tree/renderTreeCanvas.ts +20 -8
  222. package/src/components/tree/renderTreeMouseover.ts +41 -0
  223. package/src/components/tree/useTreeHover.ts +8 -17
  224. package/src/components/useHoverAnchor.ts +31 -0
  225. package/src/constants.ts +14 -3
  226. package/src/element.ts +45 -5
  227. package/src/expandSpec.ts +3 -3
  228. package/src/exportFileName.ts +4 -3
  229. package/src/featuresLayer.ts +48 -0
  230. package/src/hierarchy.ts +151 -4
  231. package/src/index.ts +8 -1
  232. package/src/model/DataModel.ts +3 -3
  233. package/src/model/msaModel.ts +19 -1
  234. package/src/model/treeModel.ts +22 -0
  235. package/src/model.ts +841 -272
  236. package/src/renderToSvg.tsx +6 -9
  237. package/src/rerootTree.ts +172 -0
  238. package/src/types.ts +92 -12
  239. package/src/useMsaSvgFigure.ts +11 -4
  240. package/src/version.ts +1 -1
  241. package/src/writeNewick.ts +38 -0
  242. package/dist/components/PortalTooltip.d.ts +0 -11
  243. package/dist/components/PortalTooltip.js +0 -29
  244. package/dist/components/PortalTooltip.js.map +0 -1
  245. package/dist/components/header/HeaderStatusArea.js +0 -21
  246. package/dist/components/header/HeaderStatusArea.js.map +0 -1
  247. package/dist/components/tree/TreeBranchMenu.js +0 -29
  248. package/dist/components/tree/TreeBranchMenu.js.map +0 -1
  249. package/dist/components/tree/TreeNodeMenu.d.ts +0 -13
  250. package/dist/components/tree/TreeNodeMenu.js +0 -41
  251. package/dist/components/tree/TreeNodeMenu.js.map +0 -1
  252. package/src/components/PortalTooltip.tsx +0 -47
  253. package/src/components/header/HeaderStatusArea.tsx +0 -32
  254. package/src/components/tree/TreeBranchMenu.tsx +0 -68
  255. package/src/components/tree/TreeNodeMenu.tsx +0 -95
package/dist/model.d.ts CHANGED
@@ -2,11 +2,13 @@ import type { ColumnStats } from './columnStats.ts';
2
2
  import type { ScrollZoomAxis } from './constants.ts';
3
3
  import type { HierarchyNode } from './hierarchy.ts';
4
4
  import type { ExportSvgOptions } from './renderToSvg.tsx';
5
- import type { Annotation, Arc, BasicTrack, Cell, Clade, ResidueMappingProblem, ColumnTrackSpec, DomainBand, Encoding, Highlight, Legend, NodeWithIds, NodeWithIdsAndLength, Region, ResidueMapping, ResolvedClade, ResolvedEncoding, ResolvedHighlight, ResolvedRowPanel, RowPanelSpec, RowResidue, StructureResidue, TrackKind, UnshareableData, Viewport } from './types.ts';
5
+ import type { Annotation, Arc, BasicTrack, Cell, Clade, ResidueMappingProblem, ColumnTrackSpec, DomainBand, Encoding, Feature, Highlight, Legend, MsaSelection, NodeWithIds, Region, ResidueMapping, ResolvedClade, ResolvedEncoding, ResolvedFeaturePanel, ResolvedHighlight, ResolvedSelection, TreeOrder, TreeRoot, ResolvedRowPanel, ResolvedStripPanel, RowDataInput, RowPanelSpec, RowResidue, StructureResidue, TrackKind, UnshareableData, Viewport } from './types.ts';
6
6
  import type { FileLocation as FileLocationType } from '@jbrowse/core/util/types';
7
7
  import type { Instance } from '@jbrowse/mobx-state-tree';
8
8
  import type { InterProScanResults } from 'msa-parsers';
9
9
  export declare const defaultTrackHeights: Partial<Record<TrackKind, number>>;
10
+ type StripPanelScale = Omit<ResolvedStripPanel, 'id' | 'width' | 'offsetX'>;
11
+ type FeaturePanelScale = Omit<ResolvedFeaturePanel, 'id' | 'width' | 'offsetX' | 'spans'>;
10
12
  /**
11
13
  * The snapshot properties reset() carries across a return to the import form:
12
14
  * display preferences and layout, nothing derived from the loaded file.
@@ -39,25 +41,34 @@ export declare const preservedOnReset: Set<string>;
39
41
  * const root = RootModel.create({})
40
42
  * root.view.setData({ msa: '>seq1\nACGT\n>seq2\nACGT' })
41
43
  * ```
44
+ *
45
+ * `maxInlineSnapshotBytes` is the largest pasted or local document, and the
46
+ * largest data track, the snapshot keeps; a larger one stays in the live model
47
+ * and `unshareableData` names it. The standalone app, whose links carry the
48
+ * snapshot in the URL fragment, raises it.
42
49
  */
43
- declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelType<Omit<Omit<Omit<{}, "autoTreeAreaWidth" | "drawLabels" | "drawNodeBubbles" | "drawNodeLabels" | "drawTree" | "labelsAlignRight" | "overviewHeight" | "showBranchLen" | "showTreeOverview" | "treeAreaWidth" | "treeWidth"> & {
50
+ declare function stateModelFactory({ maxInlineSnapshotBytes, }?: {
51
+ maxInlineSnapshotBytes?: number;
52
+ }): import("@jbrowse/mobx-state-tree").IModelType<Omit<Omit<Omit<{}, "autoTreeAreaWidth" | "drawLabels" | "drawNodeBubbles" | "drawNodeLabels" | "drawTree" | "labelsAlignRight" | "overviewHeight" | "showBranchLen" | "showTreeOverview" | "treeAreaWidth" | "treeOrder" | "treeWidth"> & {
44
53
  drawLabels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
45
54
  labelsAlignRight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
46
55
  treeAreaWidth: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
47
56
  treeWidth: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
48
57
  showBranchLen: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
58
+ treeOrder: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<TreeOrder>, [undefined]>;
49
59
  drawTree: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
50
60
  drawNodeBubbles: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
51
61
  drawNodeLabels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
52
62
  showTreeOverview: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
53
63
  overviewHeight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
54
64
  autoTreeAreaWidth: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
55
- }, "bgColor" | "colorSchemeName" | "msaFormat" | "showColumnStats"> & {
65
+ }, "bgColor" | "colorSchemeName" | "customColorScheme" | "msaFormat" | "showColumnStats"> & {
56
66
  bgColor: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
57
67
  colorSchemeName: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
68
+ customColorScheme: import("@jbrowse/mobx-state-tree").IType<Record<string, string> | undefined, Record<string, string> | undefined, Record<string, string> | undefined>;
58
69
  showColumnStats: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
59
70
  msaFormat: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<import("msa-parsers").MSAFormat>>;
60
- }, "allowedGappyness" | "clades" | "colWidth" | "collapsed" | "columnTracks" | "currentAlignment" | "data" | "drawMsaLetters" | "encodings" | "gffFilehandle" | "height" | "hideGaps" | "highlightColumns" | "highlights" | "id" | "msaFilehandle" | "region" | "relativeTo" | "residueMappings" | "rowHeight" | "rowPanels" | "scrollX" | "scrollY" | "scrollZoom" | "scrollZoomAxis" | "showDomainLegend" | "showDomains" | "showOnly" | "subFeatureRows" | "trackHeights" | "treeFilehandle" | "treeMetadataFilehandle" | "turnedOffFeatures" | "turnedOffTracks" | "type"> & {
71
+ }, "allowedGappyness" | "clades" | "colWidth" | "collapsed" | "columnTracks" | "currentAlignment" | "data" | "drawMsaLetters" | "encodings" | "features" | "gffFilehandle" | "height" | "hideGaps" | "highlightColumns" | "highlights" | "id" | "msaFilehandle" | "region" | "relativeTo" | "residueMappings" | "rotated" | "rowHeight" | "rowPanels" | "scrollX" | "scrollY" | "scrollZoom" | "scrollZoomAxis" | "selection" | "showDomainLegend" | "showDomains" | "showOnly" | "subFeatureRows" | "trackHeights" | "treeFilehandle" | "treeMetadataFilehandle" | "treeRoot" | "turnedOffFeatures" | "turnedOffTracks" | "type"> & {
61
72
  /**
62
73
  * #property
63
74
  * id of view, randomly generated if not provided
@@ -533,6 +544,20 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
533
544
  * hidden)
534
545
  */
535
546
  collapsed: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").ISimpleType<string>>, [undefined]>;
547
+ /**
548
+ * #property
549
+ * tree nodes whose children draw in reverse order, which is ggtree's
550
+ * `rotate`: the same tree, with the clades on either side of the node
551
+ * swapped
552
+ */
553
+ rotated: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").ISimpleType<string>>, [undefined]>;
554
+ /**
555
+ * #property
556
+ * where the tree is rooted: `midpoint` roots it halfway along the
557
+ * longest path between two tips, `{outgroup}` on the branch above
558
+ * the tips named, and undefined keeps the file's root
559
+ */
560
+ treeRoot: import("@jbrowse/mobx-state-tree").IType<TreeRoot | undefined, TreeRoot | undefined, TreeRoot | undefined>;
536
561
  /**
537
562
  * #property
538
563
  * focus on particular subtree
@@ -616,6 +641,21 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
616
641
  * Persists in the snapshot and the URL.
617
642
  */
618
643
  highlights: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<Highlight, Highlight, Highlight>>, [undefined]>;
644
+ /**
645
+ * #property
646
+ * features on the rows as data, `{row, start, end, name, ...}` in
647
+ * residues of each row, drawn with the GFF's annotations. Persists in
648
+ * the snapshot and the URL.
649
+ */
650
+ features: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<Feature, Feature, Feature>>, [undefined]>;
651
+ /**
652
+ * #property
653
+ * the block the reader selected: `{start, end}` columns of the file,
654
+ * 1-based inclusive like a column highlight, and `rows` by name, every
655
+ * row where absent. Undefined until something is selected, so a view
656
+ * without one adds nothing to the shared URL.
657
+ */
658
+ selection: import("@jbrowse/mobx-state-tree").IType<MsaSelection | undefined, MsaSelection | undefined, MsaSelection | undefined>;
619
659
  /**
620
660
  * #property
621
661
  * where the view opens, in `highlights` coordinates: `{row, start,
@@ -629,7 +669,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
629
669
  * clades of the tree with a mark drawn over them. `mrca` names tips
630
670
  * whose common ancestor is the clade, or `range` its first and last
631
671
  * tip in display order, and `tips` is the leaf count the producer
632
- * measured. `mark` is `highlight`, `bracket`, `collapse` or `focus`.
672
+ * measured. `mark` is `highlight`, `bracket`, `collapse`, `focus` or
673
+ * `rotate`.
633
674
  * See docs/layers.md
634
675
  */
635
676
  clades: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<Clade, Clade, Clade>>, [undefined]>;
@@ -664,6 +705,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
664
705
  setDrawTree(arg: boolean): void;
665
706
  setAutoTreeAreaWidth(arg: boolean): void;
666
707
  setShowBranchLen(arg: boolean): void;
708
+ setTreeOrder(order: TreeOrder): void;
667
709
  setDrawNodeBubbles(arg: boolean): void;
668
710
  setDrawNodeLabels(arg: boolean): void;
669
711
  setShowTreeOverview(arg: boolean): void;
@@ -671,6 +713,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
671
713
  setDrawLabels(arg: boolean): void;
672
714
  } & {
673
715
  setColorSchemeName(name: string): void;
716
+ setCustomColorScheme(map?: Record<string, string>): void;
674
717
  setBgColor(arg: boolean): void;
675
718
  setShowColumnStats(arg: boolean): void;
676
719
  setMSAFormat(arg?: import("msa-parsers").MSAFormat): void;
@@ -774,9 +817,15 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
774
817
  * #volatile
775
818
  * non-fatal load problems: an optional layer that failed to load, an
776
819
  * overlay that failed to parse. `error` replaces the view and is for the
777
- * alignment itself
820
+ * alignment itself. `warnings` adds the ones derived from the data
778
821
  */
779
- warnings: string[];
822
+ loadWarnings: string[];
823
+ /**
824
+ * #volatile
825
+ * derived warnings the user dismissed, which stay hidden while the data
826
+ * behind them holds
827
+ */
828
+ dismissedWarnings: string[];
780
829
  /**
781
830
  * #volatile
782
831
  * bumped by reset(). The error boundary above the view uses it as its key,
@@ -846,10 +895,6 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
846
895
  * that failed to parse. A message already on the list is not added again
847
896
  */
848
897
  addWarning(warning: string): void;
849
- /**
850
- * #action
851
- */
852
- clearWarnings(): void;
853
898
  /**
854
899
  * #action
855
900
  * declare that this host restores the loaded documents itself, which
@@ -882,6 +927,20 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
882
927
  * #action
883
928
  */
884
929
  setHighlights(highlights: Highlight[]): void;
930
+ /**
931
+ * #action
932
+ */
933
+ setFeatures(features: Feature[]): void;
934
+ /**
935
+ * #action
936
+ * select a block, in `selection` coordinates. `start` and `end` may come
937
+ * in either order.
938
+ */
939
+ setSelection(selection?: MsaSelection): void;
940
+ /**
941
+ * #action
942
+ */
943
+ clearSelection(): void;
885
944
  /**
886
945
  * #action
887
946
  * replace the clades the viewer marks (see docs/layers.md)
@@ -930,8 +989,9 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
930
989
  /**
931
990
  * #action
932
991
  * switch to another alignment of a multi-alignment file (Stockholm).
933
- * Clears the collapsed node ids, the subtree in focus, the reference row
934
- * and the scroll position, which all refer to the previous alignment
992
+ * Clears the collapsed and rotated node ids, the subtree in focus, the
993
+ * reference row and the scroll position, which all refer to the
994
+ * previous alignment
935
995
  */
936
996
  setCurrentAlignment(n: number): void;
937
997
  /**
@@ -939,6 +999,21 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
939
999
  * collapse or un-collapse the subtree rooted at the given tree node id
940
1000
  */
941
1001
  toggleCollapsed(node: string): void;
1002
+ /**
1003
+ * #action
1004
+ * reverse the order of the given node's children, or restore it
1005
+ */
1006
+ toggleRotated(node: string): void;
1007
+ /**
1008
+ * #action
1009
+ */
1010
+ clearRotated(): void;
1011
+ /**
1012
+ * #action
1013
+ * reroot the tree. Clears `collapsed`, `rotated` and `showOnly`, whose
1014
+ * path-derived node ids name other nodes in the rerooted tree
1015
+ */
1016
+ setTreeRoot(treeRoot?: TreeRoot): void;
942
1017
  /**
943
1018
  * #action
944
1019
  * show only the subtree rooted at the given node id (pass undefined to
@@ -989,9 +1064,9 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
989
1064
  * store the GFF text in the snapshot like the alignment and tree. The
990
1065
  * parsed annotations are volatile and a blob filehandle is cleared once
991
1066
  * read, so the text is the only persisted copy. An autorun parses it
992
- * into annotations.
1067
+ * into annotations, and clears the ones it drew when the text goes.
993
1068
  */
994
- setGFF(result: string): void;
1069
+ setGFF(result?: string): void;
995
1070
  } & {
996
1071
  /**
997
1072
  * #getter
@@ -1002,6 +1077,12 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1002
1077
  * #getter
1003
1078
  */
1004
1079
  readonly realAllowedGappyness: number;
1080
+ /**
1081
+ * #getter
1082
+ * the annotations the overlay, the legend and the encodings draw: the
1083
+ * GFF's, then the `features` layer's
1084
+ */
1085
+ readonly allAnnotations: Annotation[];
1005
1086
  /**
1006
1087
  * #getter
1007
1088
  */
@@ -1028,6 +1109,13 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1028
1109
  * #getter
1029
1110
  */
1030
1111
  readonly colorScheme: Record<string, string>;
1112
+ /**
1113
+ * #getter
1114
+ * the scheme coloring each cell from its column's statistics, or
1115
+ * undefined while the cells take a fixed color per letter, from the
1116
+ * built-in table or from `customColorScheme`
1117
+ */
1118
+ readonly dynamicColorSchemeName: string | undefined;
1031
1119
  /**
1032
1120
  * #getter
1033
1121
  */
@@ -1058,12 +1146,13 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1058
1146
  * from disk or pasted in becomes inline text, and DataModel drops an
1059
1147
  * inline document past `maxInlineSnapshotBytes`.
1060
1148
  *
1061
- * The header lists these, and the standalone app stops rewriting the
1062
- * address bar while the list is non-empty, so a copied link does not
1063
- * open an empty viewer unannounced. A document fetched from a URL never
1064
- * appears here, since the snapshot keeps its filehandle.
1149
+ * The header lists these, and the standalone app drops `#data=` from
1150
+ * the address bar while the list is non-empty or the encoded link would
1151
+ * pass its `maxLinkLength`, so a copied link never opens an empty viewer
1152
+ * unannounced. A document fetched from a URL never appears here, since
1153
+ * the snapshot keeps its filehandle.
1065
1154
  *
1066
- * Empty when `hostRestoresData` is true.
1155
+ * Empty when `hostCarriesData` is true.
1067
1156
  */
1068
1157
  readonly unshareableData: UnshareableData[];
1069
1158
  menuItems(): never[];
@@ -1074,7 +1163,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1074
1163
  * `data.treeMetadata`, the name that travels in existing links, so the
1075
1164
  * inline size limit and `treeMetadataFilehandle` cover it. labelWidthMap
1076
1165
  * reads it on every layout, so a malformed user-supplied file returns {}
1077
- * instead of throwing out of rendering.
1166
+ * instead of throwing out of rendering, and every field is a string by
1167
+ * the time a scale sorts it.
1078
1168
  */
1079
1169
  readonly rowData: Record<string, Record<string, string> | undefined>;
1080
1170
  /**
@@ -1098,6 +1188,14 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1098
1188
  readonly numColumns: number;
1099
1189
  /**
1100
1190
  * #getter
1191
+ * the tree the file or the alignment gives, before `treeRoot`
1192
+ */
1193
+ readonly inputTree: NodeWithIds;
1194
+ /**
1195
+ * #getter
1196
+ * the tree as the file or the alignment gives it, rerooted where
1197
+ * `treeRoot` asks. Every node id, and so `collapsed`, `rotated` and
1198
+ * `showOnly`, refers to this tree.
1101
1199
  */
1102
1200
  readonly tree: NodeWithIds;
1103
1201
  /**
@@ -1115,8 +1213,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1115
1213
  * `clades` resolved to the rows each one covers. The tip names resolve
1116
1214
  * against `tree` rather than `root`, so a clade whose ancestor the user
1117
1215
  * collapsed keeps its rows. One leaf pass over the tree serves every
1118
- * clade. A `range` record names no node, so `collapse` and `focus`, which
1119
- * need one, drop it.
1216
+ * clade. A `range` record names no node, so `collapse`, `focus` and
1217
+ * `rotate`, which need one, drop it.
1120
1218
  */
1121
1219
  readonly resolvedClades: ResolvedClade[];
1122
1220
  /**
@@ -1143,6 +1241,12 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1143
1241
  * #getter
1144
1242
  */
1145
1243
  readonly root: HierarchyNode<NodeWithIds>;
1244
+ /**
1245
+ * #getter
1246
+ * the tree as Newick in the order and with the root it is drawn, with
1247
+ * every clade, collapsed or out of focus
1248
+ */
1249
+ readonly treeNewick: string;
1146
1250
  /**
1147
1251
  * #getter
1148
1252
  * height of the band the tree overview draws in, zero when it is off
@@ -1308,9 +1412,21 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1308
1412
  readonly propertyConservation: number[];
1309
1413
  /**
1310
1414
  * #getter
1311
- * generates a new tree that is clustered with x,y positions
1415
+ * `root` laid out on new nodes in row and branch-length units, read in
1416
+ * pixels through `rowHeight` and `treeWidth`. A zoom leaves it and every
1417
+ * node in it as they are, and an observer reading a node's `x` or `len`
1418
+ * observes the size it scales by.
1312
1419
  */
1313
- readonly hierarchy: HierarchyNode<NodeWithIdsAndLength>;
1420
+ readonly treeLayout: {
1421
+ root: import("./hierarchy.ts").LaidOutNode<NodeWithIds>;
1422
+ leaves: import("./hierarchy.ts").LaidOutNode<NodeWithIds>[];
1423
+ rootToTipLength: number;
1424
+ };
1425
+ /**
1426
+ * #getter
1427
+ * the laid-out tree, with pixel positions on every node
1428
+ */
1429
+ readonly hierarchy: HierarchyNode<NodeWithIds>;
1314
1430
  /**
1315
1431
  * #getter
1316
1432
  */
@@ -1318,7 +1434,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1318
1434
  /**
1319
1435
  * #getter
1320
1436
  */
1321
- readonly leaves: HierarchyNode<NodeWithIdsAndLength>[];
1437
+ readonly leaves: HierarchyNode<NodeWithIds>[];
1322
1438
  /**
1323
1439
  * #getter
1324
1440
  * branch-length extent of the displayed tree, root to farthest tip, in
@@ -1411,10 +1527,6 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1411
1527
  * #getter
1412
1528
  */
1413
1529
  readonly secondaryStructureConsensus: string | undefined;
1414
- /**
1415
- * #getter
1416
- */
1417
- readonly seqConsensus: string | undefined;
1418
1530
  /**
1419
1531
  * #getter
1420
1532
  * the base pairs of the consensus secondary structure, as arcs, in
@@ -1449,11 +1561,13 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1449
1561
  readonly showHorizontalScrollbar: boolean;
1450
1562
  /**
1451
1563
  * #method
1452
- * Return a row-specific letter at a visible column, or undefined if gap.
1564
+ * Return the character a row holds at a visible column: a residue, or
1565
+ * the gap character (`-` or `.`) on a gap. Undefined for a row name the
1566
+ * alignment does not have or a column past the row's end.
1453
1567
  *
1454
1568
  * @param rowName - The name of the row
1455
1569
  * @param visibleCol - The visible column index (what the user sees on screen)
1456
- * @returns The letter at that position, or undefined if it's a gap
1570
+ * @returns The character at that position
1457
1571
  */
1458
1572
  visibleColToRowLetter(rowName: string, visibleCol: number): string | undefined;
1459
1573
  /**
@@ -1511,6 +1625,16 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1511
1625
  * @returns The global column index in the full MSA, or undefined
1512
1626
  */
1513
1627
  seqPosToGlobalCol(rowName: string, seqPos: number): number | undefined;
1628
+ /**
1629
+ * #method
1630
+ * the global column of a span's last residue, clamping a position past
1631
+ * the end of the row to its last residue. Undefined for a row name the
1632
+ * alignment does not have, or a row with no residues.
1633
+ *
1634
+ * @param rowName - The name of the row
1635
+ * @param seqPos - The sequence position (0-based, ungapped)
1636
+ */
1637
+ seqEndToGlobalCol(rowName: string, seqPos: number): number | undefined;
1514
1638
  /**
1515
1639
  * #method
1516
1640
  * Convert a sequence position (ungapped) directly to a visible column index.
@@ -1636,6 +1760,22 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1636
1760
  */
1637
1761
  readonly blocksY: number[];
1638
1762
  } & {
1763
+ /**
1764
+ * #getter
1765
+ */
1766
+ readonly verticalScrollbarWidth: 0 | 20;
1767
+ /**
1768
+ * #getter
1769
+ * width of the alignment canvas: the msa area less the vertical
1770
+ * scrollbar. showHorizontalScrollbar must not read it, since that feeds
1771
+ * msaAreaHeight -> showVerticalScrollbar and would form a cycle
1772
+ */
1773
+ readonly msaCanvasWidth: number;
1774
+ /**
1775
+ * #getter
1776
+ * most-negative allowed scrollX, which keeps the last column in view
1777
+ */
1778
+ readonly maxScrollX: number;
1639
1779
  /**
1640
1780
  * #getter
1641
1781
  */
@@ -1646,8 +1786,16 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1646
1786
  readonly isLoading: boolean;
1647
1787
  /**
1648
1788
  * #getter
1789
+ * warnings that follow from the loaded data and clear when it changes. A
1790
+ * GFF whose first column names rows of some other alignment parses
1791
+ * without error and draws nothing
1649
1792
  */
1650
- readonly maxScrollX: number;
1793
+ readonly dataWarnings: string[];
1794
+ /**
1795
+ * #getter
1796
+ * the load warnings and the undismissed data warnings, for the header
1797
+ */
1798
+ readonly warnings: string[];
1651
1799
  /**
1652
1800
  * #getter
1653
1801
  * most-negative allowed scrollY, which keeps the last row in view
@@ -1665,6 +1813,10 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1665
1813
  * #action
1666
1814
  */
1667
1815
  setDrawMsaLetters(arg: boolean): void;
1816
+ /**
1817
+ * #action
1818
+ */
1819
+ clearWarnings(): void;
1668
1820
  /**
1669
1821
  * #action
1670
1822
  */
@@ -1688,8 +1840,16 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1688
1840
  calculateNeighborJoiningTreeFromMSA(): void;
1689
1841
  /**
1690
1842
  * #action
1691
- * swap in a different tree over the same alignment. Clears `collapsed`
1692
- * and `showOnly`, since path-derived node ids (node-0-0-1) from the old
1843
+ * root the tree on the branch above the given node. The node's tips are
1844
+ * a split of the unrooted tree, and the side of it that is a clade in
1845
+ * the tree as written stands for it as an outgroup, by its first and
1846
+ * last tip, so the root survives the path ids changing under it
1847
+ */
1848
+ rerootAt(nodeId: string): void;
1849
+ /**
1850
+ * #action
1851
+ * swap in a different tree over the same alignment. Clears `collapsed`,
1852
+ * `rotated` and `showOnly`, since path-derived node ids (node-0-0-1) from the old
1693
1853
  * tree would match unrelated nodes in the new one.
1694
1854
  */
1695
1855
  replaceTree(newick: string): void;
@@ -1698,6 +1858,11 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1698
1858
  * restore the default column width and row height
1699
1859
  */
1700
1860
  resetZoom(): void;
1861
+ /**
1862
+ * #action
1863
+ * zoom by `scaleFactor` about the center of the alignment area
1864
+ */
1865
+ zoomAtCenter(scaleFactor: number, axis?: ScrollZoomAxis): void;
1701
1866
  /**
1702
1867
  * #action
1703
1868
  */
@@ -1777,7 +1942,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1777
1942
  * replace the row table, which the model keeps as the JSON string
1778
1943
  * `data.treeMetadata` (see docs/layers.md)
1779
1944
  */
1780
- setRowData(rowData: Record<string, Record<string, string>>): void;
1945
+ setRowData(rowData: RowDataInput): void;
1781
1946
  /**
1782
1947
  * #action
1783
1948
  * replace what the viewer's marks read from the row table
@@ -1805,21 +1970,11 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1805
1970
  onCancel?: () => void;
1806
1971
  }): void;
1807
1972
  } & {
1808
- /**
1809
- * #getter
1810
- */
1811
- readonly verticalScrollbarWidth: 0 | 20;
1812
- /**
1813
- * #getter
1814
- * width of the alignment canvas: the msa area less the vertical
1815
- * scrollbar. showHorizontalScrollbar must not read it, since that feeds
1816
- * msaAreaHeight -> showVerticalScrollbar and would form a cycle
1817
- */
1818
- readonly msaCanvasWidth: number;
1819
1973
  /**
1820
1974
  * #method
1821
1975
  * the cell at a visible column and row index, in the coordinates a host
1822
- * writes highlights in
1976
+ * writes highlights in. On a gap `residue` is undefined and `letter` is
1977
+ * the gap character
1823
1978
  */
1824
1979
  cellAt(visibleCol: number, rowIndex?: number): Cell;
1825
1980
  /**
@@ -1972,6 +2127,39 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1972
2127
  * is dropped. Row names that match no row are ignored.
1973
2128
  */
1974
2129
  readonly resolvedHighlights: ResolvedHighlight[];
2130
+ /**
2131
+ * #getter
2132
+ * `selection` projected onto what is on screen, the way
2133
+ * `resolvedHighlights` projects a column span and a row set. A
2134
+ * selection whose columns are all hidden, or whose rows are all
2135
+ * collapsed away or unknown, resolves to undefined.
2136
+ */
2137
+ readonly resolvedSelection: ResolvedSelection | undefined;
2138
+ /**
2139
+ * #getter
2140
+ * the columns and rows the selection covers, for the header's readout.
2141
+ * Columns count the file's columns from `start` to `end`, hidden ones
2142
+ * included, as `selectionFasta` copies them.
2143
+ */
2144
+ readonly selectionSize: {
2145
+ columns: number;
2146
+ rows: number;
2147
+ } | undefined;
2148
+ /**
2149
+ * #getter
2150
+ * `selection`'s columns clamped to the file's
2151
+ */
2152
+ readonly selectionFileSpan: {
2153
+ start: number;
2154
+ end: number;
2155
+ } | undefined;
2156
+ /**
2157
+ * #getter
2158
+ * the selected block as FASTA: the selected rows on screen, top to
2159
+ * bottom, each with its letters across the file's columns from `start`
2160
+ * to `end`, gaps included
2161
+ */
2162
+ readonly selectionFasta: string;
1975
2163
  /**
1976
2164
  * #method
1977
2165
  * per-column summary statistics: consensus residue and its identity
@@ -1994,17 +2182,24 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
1994
2182
  /**
1995
2183
  * #getter
1996
2184
  * each encoding with its scale resolved against the values its field
1997
- * takes: a feature channel reads them across the features drawn, every
2185
+ * takes: a feature channel reads them across every feature loaded, every
1998
2186
  * other channel across the row table. Resolved once per change of that
1999
2187
  * table or the encodings, never per row per frame.
2000
2188
  */
2001
2189
  readonly resolvedEncodings: ResolvedEncoding[];
2002
2190
  /**
2003
2191
  * #getter
2004
- * each row panel with its scale resolved against the values its field
2005
- * takes across the row table, giving the color per row name, the pixel
2006
- * column it draws in, and the entries its legend lists. Resolved once
2007
- * per change of that table or the panels, never per block per frame.
2192
+ * each row panel's scale resolved against the values its field takes,
2193
+ * giving the colors, labels and legend entries. Reads no cell size, so
2194
+ * a zoom reuses it and the legends built from it.
2195
+ */
2196
+ readonly rowPanelScales: (StripPanelScale | FeaturePanelScale)[];
2197
+ /**
2198
+ * #getter
2199
+ * each row panel with its scale from `rowPanelScales` and its geometry:
2200
+ * the pixel column it draws in and, for a features panel, the spans per
2201
+ * row. Resolved once per change of those inputs, never per block per
2202
+ * frame.
2008
2203
  */
2009
2204
  readonly resolvedRowPanels: ResolvedRowPanel[];
2010
2205
  /**
@@ -2073,6 +2268,11 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2073
2268
  * #action
2074
2269
  */
2075
2270
  exportSVG(opts: ExportSvgOptions): Promise<void>;
2271
+ /**
2272
+ * #action
2273
+ * save `treeNewick` as a file
2274
+ */
2275
+ exportNewick(): void;
2076
2276
  /**
2077
2277
  * #action
2078
2278
  * show or hide an annotation type. Only hidden types are recorded; see
@@ -2094,6 +2294,26 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2094
2294
  * its width, or for a span that resolves to no visible column.
2095
2295
  */
2096
2296
  zoomToRegion(region: Region): void;
2297
+ /**
2298
+ * #action
2299
+ * zoom and scroll so the selected columns fill the alignment's width,
2300
+ * and, where the selection names its rows, so those rows fill its height
2301
+ */
2302
+ zoomToSelection(): void;
2303
+ /**
2304
+ * #action
2305
+ * select the block between two cells given as visible column and row
2306
+ * indices, the coordinates a drag reports, clamped to the alignment. A
2307
+ * cell with no `row` selects the columns across every row, and so does a
2308
+ * block spanning every row on screen.
2309
+ */
2310
+ selectBlock(anchor: {
2311
+ col: number;
2312
+ row?: number;
2313
+ }, head: {
2314
+ col: number;
2315
+ row?: number;
2316
+ }): void;
2097
2317
  /**
2098
2318
  * #action
2099
2319
  */
@@ -2102,6 +2322,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2102
2322
  }, import("@jbrowse/mobx-state-tree")._NotCustomized, {
2103
2323
  bgColor: boolean;
2104
2324
  colorSchemeName: string;
2325
+ customColorScheme: Record<string, string> | undefined;
2105
2326
  showColumnStats: boolean;
2106
2327
  msaFormat: import("msa-parsers").MSAFormat | undefined;
2107
2328
  drawLabels: boolean;
@@ -2109,6 +2330,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2109
2330
  treeAreaWidth: number;
2110
2331
  treeWidth: number;
2111
2332
  showBranchLen: boolean;
2333
+ treeOrder: TreeOrder;
2112
2334
  drawTree: boolean;
2113
2335
  drawNodeBubbles: boolean;
2114
2336
  drawNodeLabels: boolean;
@@ -2213,6 +2435,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2213
2435
  } | undefined;
2214
2436
  currentAlignment: number;
2215
2437
  collapsed: string[];
2438
+ rotated: string[];
2439
+ treeRoot: TreeRoot | undefined;
2216
2440
  showOnly: string | undefined;
2217
2441
  turnedOffTracks: import("mobx").IKeyValueMap<boolean>;
2218
2442
  trackHeights: import("mobx").IKeyValueMap<number>;
@@ -2221,6 +2445,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2221
2445
  relativeTo: string | undefined;
2222
2446
  highlightColumns: number[] | undefined;
2223
2447
  highlights: Highlight[];
2448
+ features: Feature[];
2449
+ selection: MsaSelection | undefined;
2224
2450
  region: Region | undefined;
2225
2451
  clades: Clade[];
2226
2452
  encodings: Encoding[];
@@ -2234,6 +2460,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2234
2460
  } | {
2235
2461
  bgColor: boolean;
2236
2462
  colorSchemeName: string;
2463
+ customColorScheme: Record<string, string> | undefined;
2237
2464
  showColumnStats: boolean;
2238
2465
  msaFormat: import("msa-parsers").MSAFormat | undefined;
2239
2466
  drawLabels: boolean;
@@ -2241,6 +2468,7 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2241
2468
  treeAreaWidth: number;
2242
2469
  treeWidth: number;
2243
2470
  showBranchLen: boolean;
2471
+ treeOrder: TreeOrder;
2244
2472
  drawTree: boolean;
2245
2473
  drawNodeBubbles: boolean;
2246
2474
  drawNodeLabels: boolean;
@@ -2345,6 +2573,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2345
2573
  } | undefined;
2346
2574
  currentAlignment: number;
2347
2575
  collapsed: string[];
2576
+ rotated: string[];
2577
+ treeRoot: TreeRoot | undefined;
2348
2578
  showOnly: string | undefined;
2349
2579
  turnedOffTracks: import("mobx").IKeyValueMap<boolean>;
2350
2580
  trackHeights: import("mobx").IKeyValueMap<number>;
@@ -2353,6 +2583,8 @@ declare function stateModelFactory(): import("@jbrowse/mobx-state-tree").IModelT
2353
2583
  relativeTo: string | undefined;
2354
2584
  highlightColumns: number[] | undefined;
2355
2585
  highlights: Highlight[];
2586
+ features: Feature[];
2587
+ selection: MsaSelection | undefined;
2356
2588
  region: Region | undefined;
2357
2589
  clades: Clade[];
2358
2590
  encodings: Encoding[];