@jbrowse/plugin-linear-genome-view 5.0.0-beta.7 → 5.0.0-beta.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/FeatureTrack/configSchema.d.ts +140 -48
- package/esm/LinearGenomeView/afterAttach.d.ts +5 -5
- package/esm/LinearGenomeView/afterAttach.js +18 -24
- package/esm/LinearGenomeView/closeUps.d.ts +83 -0
- package/esm/LinearGenomeView/closeUps.js +211 -0
- package/esm/LinearGenomeView/components/AddCloseUpDialog.d.ts +19 -0
- package/esm/LinearGenomeView/components/AddCloseUpDialog.js +29 -0
- package/esm/LinearGenomeView/components/CloseUps.d.ts +5 -0
- package/esm/LinearGenomeView/components/CloseUps.js +75 -0
- package/esm/LinearGenomeView/components/ExportSvgDialog.d.ts +2 -1
- package/esm/LinearGenomeView/components/ExportSvgDialog.js +6 -2
- package/esm/LinearGenomeView/components/GetSequenceDialog.js +2 -2
- package/esm/LinearGenomeView/components/Header.js +6 -1
- package/esm/LinearGenomeView/components/HeaderZoomControls.js +4 -34
- package/esm/LinearGenomeView/components/Highlight.js +2 -4
- package/esm/LinearGenomeView/components/HighlightBand.js +2 -2
- package/esm/LinearGenomeView/components/HighlightChip.d.ts +1 -2
- package/esm/LinearGenomeView/components/HighlightChip.js +5 -7
- package/esm/LinearGenomeView/components/ImportForm.js +2 -2
- package/esm/LinearGenomeView/components/LinearGenomeView.js +3 -3
- package/esm/LinearGenomeView/components/LinearGenomeViewContainer.js +3 -2
- package/esm/LinearGenomeView/components/OverviewHighlight.js +1 -1
- package/esm/LinearGenomeView/components/OverviewHighlightBand.js +2 -3
- package/esm/LinearGenomeView/components/OverviewScalebarPolygon.d.ts +7 -1
- package/esm/LinearGenomeView/components/OverviewScalebarPolygon.js +22 -7
- package/esm/LinearGenomeView/components/SVGHighlightBand.js +2 -3
- package/esm/LinearGenomeView/components/ScalebarRefNameLabels.js +6 -21
- package/esm/LinearGenomeView/components/SearchBox.js +2 -2
- package/esm/LinearGenomeView/components/TrackContainer.js +12 -5
- package/esm/LinearGenomeView/components/TrackLabel.js +1 -1
- package/esm/LinearGenomeView/components/TrackRenderingContainer.d.ts +3 -1
- package/esm/LinearGenomeView/components/TrackRenderingContainer.js +3 -7
- package/esm/LinearGenomeView/components/TracksContainer.js +7 -15
- package/esm/LinearGenomeView/components/fetchSequence.d.ts +1 -2
- package/esm/LinearGenomeView/components/useSideScroll.js +1 -1
- package/esm/LinearGenomeView/consts.d.ts +2 -0
- package/esm/LinearGenomeView/consts.js +5 -0
- package/esm/LinearGenomeView/headerFit.d.ts +2 -1
- package/esm/LinearGenomeView/headerFit.js +7 -2
- package/esm/LinearGenomeView/index.d.ts +1 -1
- package/esm/LinearGenomeView/keyboardHandler.d.ts +2 -0
- package/esm/LinearGenomeView/keyboardHandler.js +11 -0
- package/esm/LinearGenomeView/launchKeys.d.ts +1 -1
- package/esm/LinearGenomeView/launchKeys.js +15 -5
- package/esm/LinearGenomeView/lazyDialogs.d.ts +7 -0
- package/esm/LinearGenomeView/lazyDialogs.js +2 -0
- package/esm/LinearGenomeView/menuItems.d.ts +28 -16
- package/esm/LinearGenomeView/menuItems.js +213 -85
- package/esm/LinearGenomeView/model.d.ts +367 -199
- package/esm/LinearGenomeView/model.js +302 -143
- package/esm/LinearGenomeView/sharedScaleContainer.d.ts +1 -1
- package/esm/LinearGenomeView/showRegionsWithUndo.js +7 -1
- package/esm/LinearGenomeView/svgcomponents/SVGCloseUpFrame.d.ts +5 -0
- package/esm/LinearGenomeView/svgcomponents/SVGCloseUpFrame.js +8 -0
- package/esm/LinearGenomeView/svgcomponents/SVGHighlights.js +3 -4
- package/esm/LinearGenomeView/svgcomponents/SVGHighlightsOverlay.js +3 -3
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js +95 -24
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.js +4 -5
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.js +13 -4
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.js +4 -4
- package/esm/LinearGenomeView/svgcomponents/renderViewTracks.js +1 -1
- package/esm/LinearGenomeView/svgcomponents/useViewSvgFigure.js +52 -63
- package/esm/LinearGenomeView/svgcomponents/util.d.ts +8 -6
- package/esm/LinearGenomeView/svgcomponents/util.js +37 -16
- package/esm/LinearGenomeView/types.d.ts +5 -4
- package/esm/LinearGenomeView/util.d.ts +20 -37
- package/esm/LinearGenomeView/util.js +58 -141
- package/esm/displayKitTests/perRegionTestEnv.d.ts +64 -45
- package/esm/displayKitTests/perRegionTestEnv.js +6 -6
- package/esm/index.d.ts +9 -67
- package/esm/index.js +6 -22
- package/esm/searchUtils.d.ts +2 -3
- package/esm/searchUtils.js +2 -2
- package/package.json +7 -7
- package/esm/lazyPluginExports.d.ts +0 -23
- package/esm/lazyPluginExports.js +0 -36
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { CloseUp } from './closeUps.ts';
|
|
2
|
+
import type { BpOffset, ExportSvgOptions, HighlightType, InitState, NavLocation, ViewTrackLabelMode, VolatileGuide } from './types.ts';
|
|
2
3
|
import type PluginManager from '@jbrowse/core/PluginManager';
|
|
3
4
|
import type BaseResult from '@jbrowse/core/TextSearch/BaseResults';
|
|
4
5
|
import type { MenuItem } from '@jbrowse/core/ui';
|
|
@@ -40,9 +41,8 @@ export interface PaddingSpan {
|
|
|
40
41
|
* ```
|
|
41
42
|
* `assembly`, `loc`, `tracks`, `tracklist`, `nav` and `highlight` need
|
|
42
43
|
* on-attach resolution and are captured into the `launch` property below;
|
|
43
|
-
* `colorByCDS`, `showAminoAcids`, `showCenterLine
|
|
44
|
-
*
|
|
45
|
-
* written the same way.
|
|
44
|
+
* `colorByCDS`, `showAminoAcids`, `showCenterLine` and `trackLabels` are plain
|
|
45
|
+
* view props MST restores natively. Both are written the same way.
|
|
46
46
|
* At runtime the same model is driven imperatively — every property and action
|
|
47
47
|
* below is reachable on `viewState.session.views[0]`:
|
|
48
48
|
* ```js
|
|
@@ -52,14 +52,11 @@ export interface PaddingSpan {
|
|
|
52
52
|
* view.zoomTo(view.bpPerPx * 2) // zoom out 2x
|
|
53
53
|
* ```
|
|
54
54
|
*/
|
|
55
|
-
export declare function stateModelFactory(pluginManager: PluginManager): import("@jbrowse/mobx-state-tree").IModelType<Omit<
|
|
55
|
+
export declare function stateModelFactory(pluginManager: PluginManager): import("@jbrowse/mobx-state-tree").IModelType<Omit<{
|
|
56
56
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
57
57
|
displayName: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
58
58
|
minimized: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
59
|
-
}, "
|
|
60
|
-
highlight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<HighlightType, HighlightType, HighlightType>>, [undefined]>;
|
|
61
|
-
showHighlightChips: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
62
|
-
}, "colorByCDS" | "displayedRegions" | "hideHeader" | "hideHeaderOverview" | "hideNoTracksActive" | "id" | "labelsVisible" | "launch" | "legacyBpPerPx" | "scalebarOnly" | "showAminoAcids" | "showCenterLine" | "showCytobands" | "showGridlines" | "showTrackOutlines" | "trackLabels" | "trackSelectorType" | "tracks" | "type" | "windowStartBp" | "windowWidthBp"> & {
|
|
59
|
+
}, "closeUpConnectorHeight" | "closeUps" | "colorByCDS" | "displayedRegions" | "hideHeader" | "hideHeaderOverview" | "hideNoTracksActive" | "id" | "labelsVisible" | "launch" | "legacyBpPerPx" | "scalebarOnly" | "showAminoAcids" | "showCenterLine" | "showCytobands" | "showGridlines" | "showTrackOutlines" | "trackLabels" | "trackSelectorType" | "tracks" | "type" | "windowStartBp" | "windowWidthBp"> & {
|
|
63
60
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
64
61
|
type: import("@jbrowse/mobx-state-tree").IType<string | undefined, string, string>;
|
|
65
62
|
windowStartBp: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
@@ -69,6 +66,8 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
69
66
|
tracks: import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyType>;
|
|
70
67
|
hideHeader: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
71
68
|
hideHeaderOverview: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
69
|
+
closeUps: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyModelType>, [undefined]>;
|
|
70
|
+
closeUpConnectorHeight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
72
71
|
hideNoTracksActive: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
73
72
|
trackSelectorType: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
74
73
|
showCenterLine: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
@@ -85,6 +84,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
85
84
|
width: number;
|
|
86
85
|
bodyMounted: boolean;
|
|
87
86
|
} & {
|
|
87
|
+
readonly rendersDisplays: boolean;
|
|
88
88
|
readonly effectiveBodyMounted: boolean;
|
|
89
89
|
menuItems(): MenuItem[];
|
|
90
90
|
readonly ownTracks: import("@jbrowse/core/util").AbstractTrackModel[];
|
|
@@ -94,14 +94,6 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
94
94
|
setWidth(newWidth: number): void;
|
|
95
95
|
setBodyMounted(flag: boolean): void;
|
|
96
96
|
setMinimized(flag: boolean): void;
|
|
97
|
-
} & {
|
|
98
|
-
addToHighlights(highlight: HighlightType): void;
|
|
99
|
-
setHighlight(highlight?: HighlightType[]): void;
|
|
100
|
-
removeHighlight(highlight: HighlightType): void;
|
|
101
|
-
updateHighlight(old: HighlightType, updates: Partial<HighlightType>): void;
|
|
102
|
-
setShowHighlightChips(arg: boolean): void;
|
|
103
|
-
} & {
|
|
104
|
-
afterAttach(): void;
|
|
105
97
|
} & {
|
|
106
98
|
/**
|
|
107
99
|
* #volatile
|
|
@@ -211,7 +203,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
211
203
|
* the effective track labels setting, resolving the stored `trackLabels`
|
|
212
204
|
* against the LinearGenomeViewPlugin config default
|
|
213
205
|
*/
|
|
214
|
-
readonly effectiveTrackLabels:
|
|
206
|
+
readonly effectiveTrackLabels: ViewTrackLabelMode;
|
|
215
207
|
/**
|
|
216
208
|
* #getter
|
|
217
209
|
*/
|
|
@@ -229,6 +221,11 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
229
221
|
* #getter
|
|
230
222
|
*/
|
|
231
223
|
readonly assemblyDisplayNames: string[];
|
|
224
|
+
/**
|
|
225
|
+
* #getter
|
|
226
|
+
* the session's highlights on this view's assemblies
|
|
227
|
+
*/
|
|
228
|
+
readonly highlights: HighlightType[];
|
|
232
229
|
/**
|
|
233
230
|
* #getter
|
|
234
231
|
* checking if lgv is a 'top-level' view is used for toggling pin track
|
|
@@ -250,8 +247,30 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
250
247
|
readonly ownTracks: any[];
|
|
251
248
|
/**
|
|
252
249
|
* #getter
|
|
253
|
-
*
|
|
254
|
-
*
|
|
250
|
+
* The census entry for this view's close-ups, which are views in
|
|
251
|
+
* their own right.
|
|
252
|
+
*/
|
|
253
|
+
readonly ownViews: any[];
|
|
254
|
+
/**
|
|
255
|
+
* #getter
|
|
256
|
+
* The close-ups as what the host reads off them. The array element
|
|
257
|
+
* is a late type back onto this view, so this is where it gets a shape.
|
|
258
|
+
*/
|
|
259
|
+
readonly closeUpViews: CloseUp[];
|
|
260
|
+
/**
|
|
261
|
+
* #getter
|
|
262
|
+
* Whether this view is itself a close-up of another
|
|
263
|
+
*/
|
|
264
|
+
readonly isCloseUp: boolean;
|
|
265
|
+
/**
|
|
266
|
+
* #getter
|
|
267
|
+
* See `BaseViewModel.rendersDisplays`.
|
|
268
|
+
*/
|
|
269
|
+
readonly rendersDisplays: boolean;
|
|
270
|
+
/**
|
|
271
|
+
* #getter
|
|
272
|
+
* Assembly name captioning the scalebar ahead of its refName labels, or
|
|
273
|
+
* undefined for none. A container view (e.g. LinearSyntenyView) opts its sub-views in by
|
|
255
274
|
* exposing showAssemblyNameInSubviewScalebar; duck-typed rather than
|
|
256
275
|
* matching a concrete view type so no upward plugin dependency is needed
|
|
257
276
|
* and any container can opt in. A wrong nesting depth simply yields no
|
|
@@ -413,6 +432,16 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
413
432
|
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
414
433
|
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
415
434
|
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
435
|
+
/**
|
|
436
|
+
* #getter
|
|
437
|
+
* The assembly a pending launch is for: the one it names, else the one
|
|
438
|
+
* the view already shows. A re-launch of a materialized view (a
|
|
439
|
+
* `jb.setSession` document writing `loc` beside the built state) need
|
|
440
|
+
* not restate it; without the default the readiness gate waited on
|
|
441
|
+
* `assemblyManager.get(undefined)` for good. Undefined on a fresh view
|
|
442
|
+
* whose blob names none, which `error` reports.
|
|
443
|
+
*/
|
|
444
|
+
readonly launchAssemblyName: string | undefined;
|
|
416
445
|
/**
|
|
417
446
|
* #getter
|
|
418
447
|
*/
|
|
@@ -564,26 +593,10 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
564
593
|
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
565
594
|
/**
|
|
566
595
|
* #getter
|
|
567
|
-
* What the
|
|
568
|
-
*
|
|
569
|
-
* "Loading" for the part of startup that actually takes time. Falls back
|
|
570
|
-
* once the assembly is loaded and the remaining wait is the init autorun's
|
|
571
|
-
* own navigation, which is local.
|
|
572
|
-
*/
|
|
573
|
-
readonly loadingMessage: string | undefined;
|
|
574
|
-
/**
|
|
575
|
-
* #getter
|
|
576
|
-
* Determinate fraction for the spinner's bar, when the assembly load
|
|
577
|
-
* reports one (a whole-file download with a Content-Length)
|
|
578
|
-
*/
|
|
579
|
-
readonly loadingProgress: number | undefined;
|
|
580
|
-
/**
|
|
581
|
-
* #getter
|
|
582
|
-
* The URL the assembly load is currently fetching, when the phase named
|
|
583
|
-
* one. Only the stalled-load notice reads it — see
|
|
584
|
-
* {@link ViewLoadingScreen}.
|
|
596
|
+
* What the loading screen says while `showLoading`, read off the
|
|
597
|
+
* assembly whose load is the wait; undefined otherwise.
|
|
585
598
|
*/
|
|
586
|
-
readonly
|
|
599
|
+
readonly loading: import("@jbrowse/core/util/viewStatus").ViewLoading | undefined;
|
|
587
600
|
/**
|
|
588
601
|
* #getter
|
|
589
602
|
*/
|
|
@@ -679,10 +692,11 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
679
692
|
/**
|
|
680
693
|
* #getter
|
|
681
694
|
* Where the scalebar pins when the view's chrome is sticky: everything
|
|
682
|
-
* stacked above it, which is the view's own title bar
|
|
683
|
-
* header. Expressed from `headerHeight`
|
|
684
|
-
* constants — the two are the same box, and a
|
|
685
|
-
* is free to drift from the first while both
|
|
695
|
+
* stacked above it, which is the view's own title bar, where the session
|
|
696
|
+
* draws one, plus this view's header. Expressed from `headerHeight`
|
|
697
|
+
* rather than re-summing its constants — the two are the same box, and a
|
|
698
|
+
* second spelling of the sum is free to drift from the first while both
|
|
699
|
+
* typecheck.
|
|
686
700
|
*/
|
|
687
701
|
readonly rubberbandTop: number;
|
|
688
702
|
/**
|
|
@@ -746,16 +760,16 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
746
760
|
readonly fitBpPerPx: number;
|
|
747
761
|
/**
|
|
748
762
|
* #getter
|
|
749
|
-
* The zoom-out limit.
|
|
750
|
-
* it on a shared scale
|
|
751
|
-
* one, drawn short so the two compare by length.
|
|
763
|
+
* The zoom-out limit. Equal to the fit for this view's regions, except
|
|
764
|
+
* while a container holds it on a coarser shared scale, such as a small
|
|
765
|
+
* genome next to a large one, drawn short so the two compare by length.
|
|
752
766
|
*
|
|
753
|
-
*
|
|
754
|
-
*
|
|
755
|
-
*
|
|
756
|
-
*
|
|
757
|
-
*
|
|
758
|
-
*
|
|
767
|
+
* The shared scale raises the limit. A bpPerPx written past the limit
|
|
768
|
+
* would be undone by the first operation that clamps (a wheel tick, a
|
|
769
|
+
* rubberband, a `setDisplayedRegions`), as with the dotplot's locked
|
|
770
|
+
* aspect ratio turning "zoom out" into a zoom in (`axisMaxBpPerPx`).
|
|
771
|
+
* Every zoom clamps against the same ceiling, so full zoom-out stops at
|
|
772
|
+
* the shared scale.
|
|
759
773
|
*/
|
|
760
774
|
readonly maxBpPerPx: number;
|
|
761
775
|
/**
|
|
@@ -860,6 +874,31 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
860
874
|
* #action
|
|
861
875
|
*/
|
|
862
876
|
setHideHeaderOverview(b: boolean): void;
|
|
877
|
+
/**
|
|
878
|
+
* #action
|
|
879
|
+
* Add a close-up showing `trackIds`, spanning `windowWidthBp` bases or a
|
|
880
|
+
* tenth of the closest close-up there is. The stack stays widest first,
|
|
881
|
+
* so a span between two existing close-ups lands between them, and one
|
|
882
|
+
* wider than this view is pulled back in to it by the sync.
|
|
883
|
+
*
|
|
884
|
+
* Answers the close-up, which is a LinearGenomeView: its own actions
|
|
885
|
+
* navigate it, name its tracks and take it away again.
|
|
886
|
+
*/
|
|
887
|
+
addCloseUp({ windowWidthBp, trackIds, }?: {
|
|
888
|
+
windowWidthBp?: number;
|
|
889
|
+
trackIds?: string[];
|
|
890
|
+
}): CloseUp;
|
|
891
|
+
/**
|
|
892
|
+
* #action
|
|
893
|
+
*/
|
|
894
|
+
removeCloseUp(closeUp: CloseUp): void;
|
|
895
|
+
/**
|
|
896
|
+
* #action
|
|
897
|
+
* Set the height of every band between this view's close-ups.
|
|
898
|
+
* Floored at the drag surface's own height rather than at 0: the band IS
|
|
899
|
+
* the handle, so a band dragged shut could never be dragged open again.
|
|
900
|
+
*/
|
|
901
|
+
setCloseUpConnectorHeight(height: number): void;
|
|
863
902
|
/**
|
|
864
903
|
* #action
|
|
865
904
|
*/
|
|
@@ -921,33 +960,59 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
921
960
|
*/
|
|
922
961
|
hideTrack(trackId: string): boolean;
|
|
923
962
|
} & {
|
|
963
|
+
/**
|
|
964
|
+
* #action
|
|
965
|
+
* Open a close-up over a rubberband selection, showing this view's
|
|
966
|
+
* tracks. The view recentres on the span first, because every close-up
|
|
967
|
+
* shares its host's centre — a close-up is a closer look at the middle of
|
|
968
|
+
* this view, and a selection off to one side would otherwise open
|
|
969
|
+
* somewhere else.
|
|
970
|
+
*
|
|
971
|
+
* The span is `computeMoveToLayout`'s, the pure half of the `moveTo` the
|
|
972
|
+
* same selection's "Zoom to region" runs, so the close-up covers exactly
|
|
973
|
+
* what zooming would have navigated to.
|
|
974
|
+
*/
|
|
975
|
+
addCloseUpForSpan(start?: BpOffset, end?: BpOffset, { trackIds }?: {
|
|
976
|
+
trackIds?: string[];
|
|
977
|
+
}): CloseUp | undefined;
|
|
924
978
|
/**
|
|
925
979
|
* #action
|
|
926
980
|
* showTrack for a track whose display state model may be lazily
|
|
927
981
|
* loaded: loads it, then shows
|
|
928
982
|
*/
|
|
929
983
|
launchTrack(trackId: string, initialSnapshot?: any, displayInitialSnapshot?: any, inlineConf?: Record<string, unknown>): Promise<any>;
|
|
984
|
+
} & {
|
|
985
|
+
/**
|
|
986
|
+
* #method
|
|
987
|
+
* The shown track a move action means: the menu passes a track model's
|
|
988
|
+
* own `id`, an agent passes the `trackId` it knows the track by, and
|
|
989
|
+
* both name one shown track. Answers the model id, or the argument
|
|
990
|
+
* unchanged when nothing shown matches, so the move reports it.
|
|
991
|
+
*/
|
|
992
|
+
trackModelId(idOrTrackId: string): any;
|
|
930
993
|
} & {
|
|
931
994
|
/**
|
|
932
995
|
* #action
|
|
933
996
|
*/
|
|
934
|
-
moveTrackDown(
|
|
997
|
+
moveTrackDown(idOrTrackId: string): void;
|
|
935
998
|
/**
|
|
936
999
|
* #action
|
|
937
1000
|
*/
|
|
938
|
-
moveTrackUp(
|
|
1001
|
+
moveTrackUp(idOrTrackId: string): void;
|
|
939
1002
|
/**
|
|
940
1003
|
* #action
|
|
941
1004
|
*/
|
|
942
|
-
moveTrackToTop(
|
|
1005
|
+
moveTrackToTop(idOrTrackId: string): void;
|
|
943
1006
|
/**
|
|
944
1007
|
* #action
|
|
945
1008
|
*/
|
|
946
|
-
moveTrackToBottom(
|
|
1009
|
+
moveTrackToBottom(idOrTrackId: string): void;
|
|
947
1010
|
/**
|
|
948
1011
|
* #action
|
|
1012
|
+
* Move one shown track to another's position; each is a track model id
|
|
1013
|
+
* or a trackId.
|
|
949
1014
|
*/
|
|
950
|
-
moveTrack(
|
|
1015
|
+
moveTrack(moving: string, target: string): void;
|
|
951
1016
|
/**
|
|
952
1017
|
* #action
|
|
953
1018
|
*/
|
|
@@ -960,7 +1025,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
960
1025
|
/**
|
|
961
1026
|
* #action
|
|
962
1027
|
*/
|
|
963
|
-
setTrackLabels(setting:
|
|
1028
|
+
setTrackLabels(setting: ViewTrackLabelMode): void;
|
|
964
1029
|
/**
|
|
965
1030
|
* #action
|
|
966
1031
|
*/
|
|
@@ -1222,8 +1287,9 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1222
1287
|
* into that through `scalebarDisplayPrefix`) and whether it is flipped.
|
|
1223
1288
|
* A ` [rev]` there is a fact about the ROW; the same marker on a
|
|
1224
1289
|
* chromosome name means that one region, which only happens under mixed
|
|
1225
|
-
* orientation. `captionSpanPx` is the width it takes
|
|
1226
|
-
*
|
|
1290
|
+
* orientation. `captionSpanPx` is the width it takes: the sticky label
|
|
1291
|
+
* pins to its right edge rather than the viewport's, and the coordinate
|
|
1292
|
+
* numbers stay out from under it. The SVG export deliberately
|
|
1227
1293
|
* calls `getScalebarRefNameLabels` itself with no prefix rather than
|
|
1228
1294
|
* reading this, since it draws its own assembly name above the ruler.
|
|
1229
1295
|
*/
|
|
@@ -1237,36 +1303,36 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1237
1303
|
* Every span along the row that is not track data, as plain geometry in
|
|
1238
1304
|
* the staticBlocks frame — the same frame as gridlineTicks and
|
|
1239
1305
|
* scalebarLabels, so one `translateX(staticBlocksTranslateX)` places all
|
|
1240
|
-
* three.
|
|
1241
|
-
* them:
|
|
1306
|
+
* three. A host drawing its own chrome needs all three kinds:
|
|
1242
1307
|
*
|
|
1243
1308
|
* - `seam`: the 3px bar at a region's right edge. Displayed regions are
|
|
1244
|
-
* laid out **contiguously**
|
|
1245
|
-
* padding only before the first region and after the last
|
|
1309
|
+
* laid out **contiguously** (calculateStaticBlocks emits boundary
|
|
1310
|
+
* padding only before the first region and after the last), so this
|
|
1246
1311
|
* bar is the only thing separating two of them. Without it a
|
|
1247
|
-
* two-region view
|
|
1248
|
-
*
|
|
1249
|
-
*
|
|
1250
|
-
*
|
|
1312
|
+
* two-region view looks like a single region.
|
|
1313
|
+
* `isRightEndOfDisplayedRegion` marks it; the right edge of the
|
|
1314
|
+
* currently *loaded* blocks, which block geometry gives you, is a
|
|
1315
|
+
* different set.
|
|
1251
1316
|
* - `elided`: a region too narrow to draw at this zoom. Whole-genome on
|
|
1252
|
-
* a real assembly is mostly these
|
|
1253
|
-
* but the 24 chromosomes
|
|
1254
|
-
*
|
|
1317
|
+
* a real assembly is mostly these (hg38 has 455 sequences, and all
|
|
1318
|
+
* but the 24 chromosomes are under a pixel wide), so a host that
|
|
1319
|
+
* skips them leaves that part of the row empty.
|
|
1255
1320
|
* - `boundary`: past the start of the first region or the end of the
|
|
1256
|
-
* last. Greying it
|
|
1257
|
-
*
|
|
1321
|
+
* last. Greying it shows the last region's seam as the edge of a
|
|
1322
|
+
* filled area, where it would otherwise look like a line in the
|
|
1323
|
+
* middle of the track.
|
|
1258
1324
|
*
|
|
1259
1325
|
* Elided blocks get no seam even though they carry the flag: at the
|
|
1260
|
-
* zoom where regions elide, one bar per region
|
|
1326
|
+
* zoom where regions elide, one bar per region would fill the row solid
|
|
1327
|
+
* grey.
|
|
1261
1328
|
*
|
|
1262
|
-
* PaddingBlocks is the in-tree consumer. The SVG export
|
|
1263
|
-
*
|
|
1264
|
-
*
|
|
1265
|
-
* interactive row
|
|
1266
|
-
*
|
|
1267
|
-
*
|
|
1268
|
-
*
|
|
1269
|
-
* so it is all that separates two of them.
|
|
1329
|
+
* PaddingBlocks is the in-tree consumer. The SVG export does not use
|
|
1330
|
+
* it: `SVGRegionSeparators` walks dynamicBlocks itself and draws only
|
|
1331
|
+
* the seam, because `elided` and `boundary` mark state for an
|
|
1332
|
+
* interactive row. In a static figure the striped grey would cover most
|
|
1333
|
+
* of the row at whole-genome zoom. The export keeps the seam because
|
|
1334
|
+
* regions lay out contiguously and the seam is all that separates two
|
|
1335
|
+
* of them.
|
|
1270
1336
|
*/
|
|
1271
1337
|
readonly paddingSpans: readonly {
|
|
1272
1338
|
key: string;
|
|
@@ -1298,8 +1364,8 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1298
1364
|
* viewport. False both when the view holds no regions at all and when
|
|
1299
1365
|
* it holds some but is scrolled entirely off them; either way there is
|
|
1300
1366
|
* no visible span for the scalebar, ruler and refName labels to
|
|
1301
|
-
* describe
|
|
1302
|
-
*
|
|
1367
|
+
* describe. The SVG export checks it before drawing its header.
|
|
1368
|
+
* Distinct from `hasDisplayedRegions`, which only asks whether the
|
|
1303
1369
|
* view has been given regions, not whether any are on screen.
|
|
1304
1370
|
*/
|
|
1305
1371
|
readonly hasVisibleContent: boolean;
|
|
@@ -1375,23 +1441,22 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1375
1441
|
readonly visibleLocStrings: string;
|
|
1376
1442
|
/**
|
|
1377
1443
|
* #getter
|
|
1378
|
-
* **
|
|
1379
|
-
* view has settled at least once, the live ones before that.
|
|
1444
|
+
* **The blocks a debounced consumer clips to**: the coarse blocks once
|
|
1445
|
+
* the view has settled at least once, the live ones before that.
|
|
1380
1446
|
*
|
|
1381
|
-
* The coarse blocks
|
|
1382
|
-
* animation frame during a pan or zoom
|
|
1383
|
-
* alignments coverage scale and MAF's coverage band
|
|
1384
|
-
*
|
|
1385
|
-
*
|
|
1386
|
-
*
|
|
1387
|
-
*
|
|
1388
|
-
*
|
|
1389
|
-
*
|
|
1390
|
-
*
|
|
1391
|
-
* fetch used to be trailing-edge at 600ms, so it never did.
|
|
1447
|
+
* The coarse blocks stop a per-bp scan from recomputing on every
|
|
1448
|
+
* animation frame during a pan or zoom. Wiggle's autoscale domain, the
|
|
1449
|
+
* alignments coverage scale and MAF's coverage band use them. While the
|
|
1450
|
+
* coarse blocks are stale the result is a frame or two old, as the
|
|
1451
|
+
* debounce intends. **Empty coarse blocks are a different case.** A scan
|
|
1452
|
+
* over no blocks yields no entries, and the consumer falls back to the
|
|
1453
|
+
* domain `[0,1]`, which draws a line plot blank and a density plot
|
|
1454
|
+
* saturated. The coarse blocks are empty for the 500ms between a view
|
|
1455
|
+
* initializing and the coarse autorun's first run, and data can load
|
|
1456
|
+
* within that window.
|
|
1392
1457
|
*
|
|
1393
|
-
*
|
|
1394
|
-
*
|
|
1458
|
+
* Falling back to the live blocks costs one extra recompute at that
|
|
1459
|
+
* transition, compared with N per frame without the debounce.
|
|
1395
1460
|
*/
|
|
1396
1461
|
readonly settledDynamicBlocks: ContentBlock[];
|
|
1397
1462
|
/**
|
|
@@ -1637,6 +1702,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1637
1702
|
* adds 20% padding on each side)
|
|
1638
1703
|
*/
|
|
1639
1704
|
navToLocation(parsedLocString: ParsedLocString, assemblyName?: string, grow?: number): Promise<void>;
|
|
1705
|
+
/**
|
|
1706
|
+
* #action
|
|
1707
|
+
* adds the region in view to the session's highlights
|
|
1708
|
+
*/
|
|
1709
|
+
highlightCurrentRegion(): void;
|
|
1710
|
+
/**
|
|
1711
|
+
* #action
|
|
1712
|
+
* navigates to the most recently added highlight on this view's
|
|
1713
|
+
* assemblies, zoomed out a little for context
|
|
1714
|
+
*/
|
|
1715
|
+
navigateNewestHighlight(): Promise<void>;
|
|
1640
1716
|
} & {
|
|
1641
1717
|
/**
|
|
1642
1718
|
* #method
|
|
@@ -1655,7 +1731,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1655
1731
|
} | undefined;
|
|
1656
1732
|
/**
|
|
1657
1733
|
* #method
|
|
1658
|
-
* Map a highlight
|
|
1734
|
+
* Map a highlight region to its pixel position+width inside
|
|
1659
1735
|
* the tracks container. Falls back to the raw refName if the region's
|
|
1660
1736
|
* assemblyName is missing or unknown so highlights authored without an
|
|
1661
1737
|
* assembly still render in single-assembly views.
|
|
@@ -1720,17 +1796,22 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1720
1796
|
* arc instead of jumped to, at the zoom the view is already on.
|
|
1721
1797
|
*/
|
|
1722
1798
|
flyToCenter(coord: number, refName: string, displayedRegionIndex?: number): void;
|
|
1799
|
+
/**
|
|
1800
|
+
* #action
|
|
1801
|
+
* A flight to a linear bp centre at the zoom the view is on, or is
|
|
1802
|
+
* already flying to, widened where that is narrower than `fitWidthBp`.
|
|
1803
|
+
* The current width mid-flight is a point on the arc, so a second
|
|
1804
|
+
* flight read from it would land pulled back.
|
|
1805
|
+
*/
|
|
1806
|
+
flyToFit(centerBp: number, fitWidthBp: number): void;
|
|
1723
1807
|
} & {
|
|
1724
1808
|
afterCreate(): void;
|
|
1725
1809
|
afterAttach(): void;
|
|
1726
|
-
}, import("@jbrowse/core/util/withLaunchInput").LaunchSnapshotIn<import("@jbrowse/mobx-state-tree").IModelType<Omit<
|
|
1810
|
+
}, import("@jbrowse/core/util/withLaunchInput").LaunchSnapshotIn<import("@jbrowse/mobx-state-tree").IModelType<Omit<{
|
|
1727
1811
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
1728
1812
|
displayName: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
1729
1813
|
minimized: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1730
|
-
}, "
|
|
1731
|
-
highlight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<HighlightType, HighlightType, HighlightType>>, [undefined]>;
|
|
1732
|
-
showHighlightChips: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1733
|
-
}, "colorByCDS" | "displayedRegions" | "hideHeader" | "hideHeaderOverview" | "hideNoTracksActive" | "id" | "labelsVisible" | "launch" | "legacyBpPerPx" | "scalebarOnly" | "showAminoAcids" | "showCenterLine" | "showCytobands" | "showGridlines" | "showTrackOutlines" | "trackLabels" | "trackSelectorType" | "tracks" | "type" | "windowStartBp" | "windowWidthBp"> & {
|
|
1814
|
+
}, "closeUpConnectorHeight" | "closeUps" | "colorByCDS" | "displayedRegions" | "hideHeader" | "hideHeaderOverview" | "hideNoTracksActive" | "id" | "labelsVisible" | "launch" | "legacyBpPerPx" | "scalebarOnly" | "showAminoAcids" | "showCenterLine" | "showCytobands" | "showGridlines" | "showTrackOutlines" | "trackLabels" | "trackSelectorType" | "tracks" | "type" | "windowStartBp" | "windowWidthBp"> & {
|
|
1734
1815
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
1735
1816
|
type: import("@jbrowse/mobx-state-tree").IType<string | undefined, string, string>;
|
|
1736
1817
|
windowStartBp: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
@@ -1740,6 +1821,8 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1740
1821
|
tracks: import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyType>;
|
|
1741
1822
|
hideHeader: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1742
1823
|
hideHeaderOverview: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1824
|
+
closeUps: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyModelType>, [undefined]>;
|
|
1825
|
+
closeUpConnectorHeight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
1743
1826
|
hideNoTracksActive: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
1744
1827
|
trackSelectorType: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
1745
1828
|
showCenterLine: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
@@ -1756,6 +1839,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1756
1839
|
width: number;
|
|
1757
1840
|
bodyMounted: boolean;
|
|
1758
1841
|
} & {
|
|
1842
|
+
readonly rendersDisplays: boolean;
|
|
1759
1843
|
readonly effectiveBodyMounted: boolean;
|
|
1760
1844
|
menuItems(): MenuItem[];
|
|
1761
1845
|
readonly ownTracks: import("@jbrowse/core/util").AbstractTrackModel[];
|
|
@@ -1765,14 +1849,6 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1765
1849
|
setWidth(newWidth: number): void;
|
|
1766
1850
|
setBodyMounted(flag: boolean): void;
|
|
1767
1851
|
setMinimized(flag: boolean): void;
|
|
1768
|
-
} & {
|
|
1769
|
-
addToHighlights(highlight: HighlightType): void;
|
|
1770
|
-
setHighlight(highlight?: HighlightType[]): void;
|
|
1771
|
-
removeHighlight(highlight: HighlightType): void;
|
|
1772
|
-
updateHighlight(old: HighlightType, updates: Partial<HighlightType>): void;
|
|
1773
|
-
setShowHighlightChips(arg: boolean): void;
|
|
1774
|
-
} & {
|
|
1775
|
-
afterAttach(): void;
|
|
1776
1852
|
} & {
|
|
1777
1853
|
/**
|
|
1778
1854
|
* #volatile
|
|
@@ -1882,7 +1958,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1882
1958
|
* the effective track labels setting, resolving the stored `trackLabels`
|
|
1883
1959
|
* against the LinearGenomeViewPlugin config default
|
|
1884
1960
|
*/
|
|
1885
|
-
readonly effectiveTrackLabels:
|
|
1961
|
+
readonly effectiveTrackLabels: ViewTrackLabelMode;
|
|
1886
1962
|
/**
|
|
1887
1963
|
* #getter
|
|
1888
1964
|
*/
|
|
@@ -1900,6 +1976,11 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1900
1976
|
* #getter
|
|
1901
1977
|
*/
|
|
1902
1978
|
readonly assemblyDisplayNames: string[];
|
|
1979
|
+
/**
|
|
1980
|
+
* #getter
|
|
1981
|
+
* the session's highlights on this view's assemblies
|
|
1982
|
+
*/
|
|
1983
|
+
readonly highlights: HighlightType[];
|
|
1903
1984
|
/**
|
|
1904
1985
|
* #getter
|
|
1905
1986
|
* checking if lgv is a 'top-level' view is used for toggling pin track
|
|
@@ -1921,8 +2002,30 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
1921
2002
|
readonly ownTracks: any[];
|
|
1922
2003
|
/**
|
|
1923
2004
|
* #getter
|
|
1924
|
-
*
|
|
1925
|
-
*
|
|
2005
|
+
* The census entry for this view's close-ups, which are views in
|
|
2006
|
+
* their own right.
|
|
2007
|
+
*/
|
|
2008
|
+
readonly ownViews: any[];
|
|
2009
|
+
/**
|
|
2010
|
+
* #getter
|
|
2011
|
+
* The close-ups as what the host reads off them. The array element
|
|
2012
|
+
* is a late type back onto this view, so this is where it gets a shape.
|
|
2013
|
+
*/
|
|
2014
|
+
readonly closeUpViews: CloseUp[];
|
|
2015
|
+
/**
|
|
2016
|
+
* #getter
|
|
2017
|
+
* Whether this view is itself a close-up of another
|
|
2018
|
+
*/
|
|
2019
|
+
readonly isCloseUp: boolean;
|
|
2020
|
+
/**
|
|
2021
|
+
* #getter
|
|
2022
|
+
* See `BaseViewModel.rendersDisplays`.
|
|
2023
|
+
*/
|
|
2024
|
+
readonly rendersDisplays: boolean;
|
|
2025
|
+
/**
|
|
2026
|
+
* #getter
|
|
2027
|
+
* Assembly name captioning the scalebar ahead of its refName labels, or
|
|
2028
|
+
* undefined for none. A container view (e.g. LinearSyntenyView) opts its sub-views in by
|
|
1926
2029
|
* exposing showAssemblyNameInSubviewScalebar; duck-typed rather than
|
|
1927
2030
|
* matching a concrete view type so no upward plugin dependency is needed
|
|
1928
2031
|
* and any container can opt in. A wrong nesting depth simply yields no
|
|
@@ -2084,6 +2187,16 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2084
2187
|
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
2085
2188
|
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
2086
2189
|
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
2190
|
+
/**
|
|
2191
|
+
* #getter
|
|
2192
|
+
* The assembly a pending launch is for: the one it names, else the one
|
|
2193
|
+
* the view already shows. A re-launch of a materialized view (a
|
|
2194
|
+
* `jb.setSession` document writing `loc` beside the built state) need
|
|
2195
|
+
* not restate it; without the default the readiness gate waited on
|
|
2196
|
+
* `assemblyManager.get(undefined)` for good. Undefined on a fresh view
|
|
2197
|
+
* whose blob names none, which `error` reports.
|
|
2198
|
+
*/
|
|
2199
|
+
readonly launchAssemblyName: string | undefined;
|
|
2087
2200
|
/**
|
|
2088
2201
|
* #getter
|
|
2089
2202
|
*/
|
|
@@ -2235,26 +2348,10 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2235
2348
|
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
2236
2349
|
/**
|
|
2237
2350
|
* #getter
|
|
2238
|
-
* What the
|
|
2239
|
-
*
|
|
2240
|
-
* "Loading" for the part of startup that actually takes time. Falls back
|
|
2241
|
-
* once the assembly is loaded and the remaining wait is the init autorun's
|
|
2242
|
-
* own navigation, which is local.
|
|
2243
|
-
*/
|
|
2244
|
-
readonly loadingMessage: string | undefined;
|
|
2245
|
-
/**
|
|
2246
|
-
* #getter
|
|
2247
|
-
* Determinate fraction for the spinner's bar, when the assembly load
|
|
2248
|
-
* reports one (a whole-file download with a Content-Length)
|
|
2249
|
-
*/
|
|
2250
|
-
readonly loadingProgress: number | undefined;
|
|
2251
|
-
/**
|
|
2252
|
-
* #getter
|
|
2253
|
-
* The URL the assembly load is currently fetching, when the phase named
|
|
2254
|
-
* one. Only the stalled-load notice reads it — see
|
|
2255
|
-
* {@link ViewLoadingScreen}.
|
|
2351
|
+
* What the loading screen says while `showLoading`, read off the
|
|
2352
|
+
* assembly whose load is the wait; undefined otherwise.
|
|
2256
2353
|
*/
|
|
2257
|
-
readonly
|
|
2354
|
+
readonly loading: import("@jbrowse/core/util/viewStatus").ViewLoading | undefined;
|
|
2258
2355
|
/**
|
|
2259
2356
|
* #getter
|
|
2260
2357
|
*/
|
|
@@ -2350,10 +2447,11 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2350
2447
|
/**
|
|
2351
2448
|
* #getter
|
|
2352
2449
|
* Where the scalebar pins when the view's chrome is sticky: everything
|
|
2353
|
-
* stacked above it, which is the view's own title bar
|
|
2354
|
-
* header. Expressed from `headerHeight`
|
|
2355
|
-
* constants — the two are the same box, and a
|
|
2356
|
-
* is free to drift from the first while both
|
|
2450
|
+
* stacked above it, which is the view's own title bar, where the session
|
|
2451
|
+
* draws one, plus this view's header. Expressed from `headerHeight`
|
|
2452
|
+
* rather than re-summing its constants — the two are the same box, and a
|
|
2453
|
+
* second spelling of the sum is free to drift from the first while both
|
|
2454
|
+
* typecheck.
|
|
2357
2455
|
*/
|
|
2358
2456
|
readonly rubberbandTop: number;
|
|
2359
2457
|
/**
|
|
@@ -2417,16 +2515,16 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2417
2515
|
readonly fitBpPerPx: number;
|
|
2418
2516
|
/**
|
|
2419
2517
|
* #getter
|
|
2420
|
-
* The zoom-out limit.
|
|
2421
|
-
* it on a shared scale
|
|
2422
|
-
* one, drawn short so the two compare by length.
|
|
2518
|
+
* The zoom-out limit. Equal to the fit for this view's regions, except
|
|
2519
|
+
* while a container holds it on a coarser shared scale, such as a small
|
|
2520
|
+
* genome next to a large one, drawn short so the two compare by length.
|
|
2423
2521
|
*
|
|
2424
|
-
*
|
|
2425
|
-
*
|
|
2426
|
-
*
|
|
2427
|
-
*
|
|
2428
|
-
*
|
|
2429
|
-
*
|
|
2522
|
+
* The shared scale raises the limit. A bpPerPx written past the limit
|
|
2523
|
+
* would be undone by the first operation that clamps (a wheel tick, a
|
|
2524
|
+
* rubberband, a `setDisplayedRegions`), as with the dotplot's locked
|
|
2525
|
+
* aspect ratio turning "zoom out" into a zoom in (`axisMaxBpPerPx`).
|
|
2526
|
+
* Every zoom clamps against the same ceiling, so full zoom-out stops at
|
|
2527
|
+
* the shared scale.
|
|
2430
2528
|
*/
|
|
2431
2529
|
readonly maxBpPerPx: number;
|
|
2432
2530
|
/**
|
|
@@ -2531,6 +2629,31 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2531
2629
|
* #action
|
|
2532
2630
|
*/
|
|
2533
2631
|
setHideHeaderOverview(b: boolean): void;
|
|
2632
|
+
/**
|
|
2633
|
+
* #action
|
|
2634
|
+
* Add a close-up showing `trackIds`, spanning `windowWidthBp` bases or a
|
|
2635
|
+
* tenth of the closest close-up there is. The stack stays widest first,
|
|
2636
|
+
* so a span between two existing close-ups lands between them, and one
|
|
2637
|
+
* wider than this view is pulled back in to it by the sync.
|
|
2638
|
+
*
|
|
2639
|
+
* Answers the close-up, which is a LinearGenomeView: its own actions
|
|
2640
|
+
* navigate it, name its tracks and take it away again.
|
|
2641
|
+
*/
|
|
2642
|
+
addCloseUp({ windowWidthBp, trackIds, }?: {
|
|
2643
|
+
windowWidthBp?: number;
|
|
2644
|
+
trackIds?: string[];
|
|
2645
|
+
}): CloseUp;
|
|
2646
|
+
/**
|
|
2647
|
+
* #action
|
|
2648
|
+
*/
|
|
2649
|
+
removeCloseUp(closeUp: CloseUp): void;
|
|
2650
|
+
/**
|
|
2651
|
+
* #action
|
|
2652
|
+
* Set the height of every band between this view's close-ups.
|
|
2653
|
+
* Floored at the drag surface's own height rather than at 0: the band IS
|
|
2654
|
+
* the handle, so a band dragged shut could never be dragged open again.
|
|
2655
|
+
*/
|
|
2656
|
+
setCloseUpConnectorHeight(height: number): void;
|
|
2534
2657
|
/**
|
|
2535
2658
|
* #action
|
|
2536
2659
|
*/
|
|
@@ -2592,33 +2715,59 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2592
2715
|
*/
|
|
2593
2716
|
hideTrack(trackId: string): boolean;
|
|
2594
2717
|
} & {
|
|
2718
|
+
/**
|
|
2719
|
+
* #action
|
|
2720
|
+
* Open a close-up over a rubberband selection, showing this view's
|
|
2721
|
+
* tracks. The view recentres on the span first, because every close-up
|
|
2722
|
+
* shares its host's centre — a close-up is a closer look at the middle of
|
|
2723
|
+
* this view, and a selection off to one side would otherwise open
|
|
2724
|
+
* somewhere else.
|
|
2725
|
+
*
|
|
2726
|
+
* The span is `computeMoveToLayout`'s, the pure half of the `moveTo` the
|
|
2727
|
+
* same selection's "Zoom to region" runs, so the close-up covers exactly
|
|
2728
|
+
* what zooming would have navigated to.
|
|
2729
|
+
*/
|
|
2730
|
+
addCloseUpForSpan(start?: BpOffset, end?: BpOffset, { trackIds }?: {
|
|
2731
|
+
trackIds?: string[];
|
|
2732
|
+
}): CloseUp | undefined;
|
|
2595
2733
|
/**
|
|
2596
2734
|
* #action
|
|
2597
2735
|
* showTrack for a track whose display state model may be lazily
|
|
2598
2736
|
* loaded: loads it, then shows
|
|
2599
2737
|
*/
|
|
2600
2738
|
launchTrack(trackId: string, initialSnapshot?: any, displayInitialSnapshot?: any, inlineConf?: Record<string, unknown>): Promise<any>;
|
|
2739
|
+
} & {
|
|
2740
|
+
/**
|
|
2741
|
+
* #method
|
|
2742
|
+
* The shown track a move action means: the menu passes a track model's
|
|
2743
|
+
* own `id`, an agent passes the `trackId` it knows the track by, and
|
|
2744
|
+
* both name one shown track. Answers the model id, or the argument
|
|
2745
|
+
* unchanged when nothing shown matches, so the move reports it.
|
|
2746
|
+
*/
|
|
2747
|
+
trackModelId(idOrTrackId: string): any;
|
|
2601
2748
|
} & {
|
|
2602
2749
|
/**
|
|
2603
2750
|
* #action
|
|
2604
2751
|
*/
|
|
2605
|
-
moveTrackDown(
|
|
2752
|
+
moveTrackDown(idOrTrackId: string): void;
|
|
2606
2753
|
/**
|
|
2607
2754
|
* #action
|
|
2608
2755
|
*/
|
|
2609
|
-
moveTrackUp(
|
|
2756
|
+
moveTrackUp(idOrTrackId: string): void;
|
|
2610
2757
|
/**
|
|
2611
2758
|
* #action
|
|
2612
2759
|
*/
|
|
2613
|
-
moveTrackToTop(
|
|
2760
|
+
moveTrackToTop(idOrTrackId: string): void;
|
|
2614
2761
|
/**
|
|
2615
2762
|
* #action
|
|
2616
2763
|
*/
|
|
2617
|
-
moveTrackToBottom(
|
|
2764
|
+
moveTrackToBottom(idOrTrackId: string): void;
|
|
2618
2765
|
/**
|
|
2619
2766
|
* #action
|
|
2767
|
+
* Move one shown track to another's position; each is a track model id
|
|
2768
|
+
* or a trackId.
|
|
2620
2769
|
*/
|
|
2621
|
-
moveTrack(
|
|
2770
|
+
moveTrack(moving: string, target: string): void;
|
|
2622
2771
|
/**
|
|
2623
2772
|
* #action
|
|
2624
2773
|
*/
|
|
@@ -2631,7 +2780,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2631
2780
|
/**
|
|
2632
2781
|
* #action
|
|
2633
2782
|
*/
|
|
2634
|
-
setTrackLabels(setting:
|
|
2783
|
+
setTrackLabels(setting: ViewTrackLabelMode): void;
|
|
2635
2784
|
/**
|
|
2636
2785
|
* #action
|
|
2637
2786
|
*/
|
|
@@ -2893,8 +3042,9 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2893
3042
|
* into that through `scalebarDisplayPrefix`) and whether it is flipped.
|
|
2894
3043
|
* A ` [rev]` there is a fact about the ROW; the same marker on a
|
|
2895
3044
|
* chromosome name means that one region, which only happens under mixed
|
|
2896
|
-
* orientation. `captionSpanPx` is the width it takes
|
|
2897
|
-
*
|
|
3045
|
+
* orientation. `captionSpanPx` is the width it takes: the sticky label
|
|
3046
|
+
* pins to its right edge rather than the viewport's, and the coordinate
|
|
3047
|
+
* numbers stay out from under it. The SVG export deliberately
|
|
2898
3048
|
* calls `getScalebarRefNameLabels` itself with no prefix rather than
|
|
2899
3049
|
* reading this, since it draws its own assembly name above the ruler.
|
|
2900
3050
|
*/
|
|
@@ -2908,36 +3058,36 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2908
3058
|
* Every span along the row that is not track data, as plain geometry in
|
|
2909
3059
|
* the staticBlocks frame — the same frame as gridlineTicks and
|
|
2910
3060
|
* scalebarLabels, so one `translateX(staticBlocksTranslateX)` places all
|
|
2911
|
-
* three.
|
|
2912
|
-
* them:
|
|
3061
|
+
* three. A host drawing its own chrome needs all three kinds:
|
|
2913
3062
|
*
|
|
2914
3063
|
* - `seam`: the 3px bar at a region's right edge. Displayed regions are
|
|
2915
|
-
* laid out **contiguously**
|
|
2916
|
-
* padding only before the first region and after the last
|
|
3064
|
+
* laid out **contiguously** (calculateStaticBlocks emits boundary
|
|
3065
|
+
* padding only before the first region and after the last), so this
|
|
2917
3066
|
* bar is the only thing separating two of them. Without it a
|
|
2918
|
-
* two-region view
|
|
2919
|
-
*
|
|
2920
|
-
*
|
|
2921
|
-
*
|
|
3067
|
+
* two-region view looks like a single region.
|
|
3068
|
+
* `isRightEndOfDisplayedRegion` marks it; the right edge of the
|
|
3069
|
+
* currently *loaded* blocks, which block geometry gives you, is a
|
|
3070
|
+
* different set.
|
|
2922
3071
|
* - `elided`: a region too narrow to draw at this zoom. Whole-genome on
|
|
2923
|
-
* a real assembly is mostly these
|
|
2924
|
-
* but the 24 chromosomes
|
|
2925
|
-
*
|
|
3072
|
+
* a real assembly is mostly these (hg38 has 455 sequences, and all
|
|
3073
|
+
* but the 24 chromosomes are under a pixel wide), so a host that
|
|
3074
|
+
* skips them leaves that part of the row empty.
|
|
2926
3075
|
* - `boundary`: past the start of the first region or the end of the
|
|
2927
|
-
* last. Greying it
|
|
2928
|
-
*
|
|
3076
|
+
* last. Greying it shows the last region's seam as the edge of a
|
|
3077
|
+
* filled area, where it would otherwise look like a line in the
|
|
3078
|
+
* middle of the track.
|
|
2929
3079
|
*
|
|
2930
3080
|
* Elided blocks get no seam even though they carry the flag: at the
|
|
2931
|
-
* zoom where regions elide, one bar per region
|
|
3081
|
+
* zoom where regions elide, one bar per region would fill the row solid
|
|
3082
|
+
* grey.
|
|
2932
3083
|
*
|
|
2933
|
-
* PaddingBlocks is the in-tree consumer. The SVG export
|
|
2934
|
-
*
|
|
2935
|
-
*
|
|
2936
|
-
* interactive row
|
|
2937
|
-
*
|
|
2938
|
-
*
|
|
2939
|
-
*
|
|
2940
|
-
* so it is all that separates two of them.
|
|
3084
|
+
* PaddingBlocks is the in-tree consumer. The SVG export does not use
|
|
3085
|
+
* it: `SVGRegionSeparators` walks dynamicBlocks itself and draws only
|
|
3086
|
+
* the seam, because `elided` and `boundary` mark state for an
|
|
3087
|
+
* interactive row. In a static figure the striped grey would cover most
|
|
3088
|
+
* of the row at whole-genome zoom. The export keeps the seam because
|
|
3089
|
+
* regions lay out contiguously and the seam is all that separates two
|
|
3090
|
+
* of them.
|
|
2941
3091
|
*/
|
|
2942
3092
|
readonly paddingSpans: readonly {
|
|
2943
3093
|
key: string;
|
|
@@ -2969,8 +3119,8 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
2969
3119
|
* viewport. False both when the view holds no regions at all and when
|
|
2970
3120
|
* it holds some but is scrolled entirely off them; either way there is
|
|
2971
3121
|
* no visible span for the scalebar, ruler and refName labels to
|
|
2972
|
-
* describe
|
|
2973
|
-
*
|
|
3122
|
+
* describe. The SVG export checks it before drawing its header.
|
|
3123
|
+
* Distinct from `hasDisplayedRegions`, which only asks whether the
|
|
2974
3124
|
* view has been given regions, not whether any are on screen.
|
|
2975
3125
|
*/
|
|
2976
3126
|
readonly hasVisibleContent: boolean;
|
|
@@ -3046,23 +3196,22 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
3046
3196
|
readonly visibleLocStrings: string;
|
|
3047
3197
|
/**
|
|
3048
3198
|
* #getter
|
|
3049
|
-
* **
|
|
3050
|
-
* view has settled at least once, the live ones before that.
|
|
3199
|
+
* **The blocks a debounced consumer clips to**: the coarse blocks once
|
|
3200
|
+
* the view has settled at least once, the live ones before that.
|
|
3051
3201
|
*
|
|
3052
|
-
* The coarse blocks
|
|
3053
|
-
* animation frame during a pan or zoom
|
|
3054
|
-
* alignments coverage scale and MAF's coverage band
|
|
3055
|
-
*
|
|
3056
|
-
*
|
|
3057
|
-
*
|
|
3058
|
-
*
|
|
3059
|
-
*
|
|
3060
|
-
*
|
|
3061
|
-
*
|
|
3062
|
-
* fetch used to be trailing-edge at 600ms, so it never did.
|
|
3202
|
+
* The coarse blocks stop a per-bp scan from recomputing on every
|
|
3203
|
+
* animation frame during a pan or zoom. Wiggle's autoscale domain, the
|
|
3204
|
+
* alignments coverage scale and MAF's coverage band use them. While the
|
|
3205
|
+
* coarse blocks are stale the result is a frame or two old, as the
|
|
3206
|
+
* debounce intends. **Empty coarse blocks are a different case.** A scan
|
|
3207
|
+
* over no blocks yields no entries, and the consumer falls back to the
|
|
3208
|
+
* domain `[0,1]`, which draws a line plot blank and a density plot
|
|
3209
|
+
* saturated. The coarse blocks are empty for the 500ms between a view
|
|
3210
|
+
* initializing and the coarse autorun's first run, and data can load
|
|
3211
|
+
* within that window.
|
|
3063
3212
|
*
|
|
3064
|
-
*
|
|
3065
|
-
*
|
|
3213
|
+
* Falling back to the live blocks costs one extra recompute at that
|
|
3214
|
+
* transition, compared with N per frame without the debounce.
|
|
3066
3215
|
*/
|
|
3067
3216
|
readonly settledDynamicBlocks: ContentBlock[];
|
|
3068
3217
|
/**
|
|
@@ -3308,6 +3457,17 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
3308
3457
|
* adds 20% padding on each side)
|
|
3309
3458
|
*/
|
|
3310
3459
|
navToLocation(parsedLocString: ParsedLocString, assemblyName?: string, grow?: number): Promise<void>;
|
|
3460
|
+
/**
|
|
3461
|
+
* #action
|
|
3462
|
+
* adds the region in view to the session's highlights
|
|
3463
|
+
*/
|
|
3464
|
+
highlightCurrentRegion(): void;
|
|
3465
|
+
/**
|
|
3466
|
+
* #action
|
|
3467
|
+
* navigates to the most recently added highlight on this view's
|
|
3468
|
+
* assemblies, zoomed out a little for context
|
|
3469
|
+
*/
|
|
3470
|
+
navigateNewestHighlight(): Promise<void>;
|
|
3311
3471
|
} & {
|
|
3312
3472
|
/**
|
|
3313
3473
|
* #method
|
|
@@ -3326,7 +3486,7 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
3326
3486
|
} | undefined;
|
|
3327
3487
|
/**
|
|
3328
3488
|
* #method
|
|
3329
|
-
* Map a highlight
|
|
3489
|
+
* Map a highlight region to its pixel position+width inside
|
|
3330
3490
|
* the tracks container. Falls back to the raw refName if the region's
|
|
3331
3491
|
* assemblyName is missing or unknown so highlights authored without an
|
|
3332
3492
|
* assembly still render in single-assembly views.
|
|
@@ -3391,14 +3551,20 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
3391
3551
|
* arc instead of jumped to, at the zoom the view is already on.
|
|
3392
3552
|
*/
|
|
3393
3553
|
flyToCenter(coord: number, refName: string, displayedRegionIndex?: number): void;
|
|
3554
|
+
/**
|
|
3555
|
+
* #action
|
|
3556
|
+
* A flight to a linear bp centre at the zoom the view is on, or is
|
|
3557
|
+
* already flying to, widened where that is narrower than `fitWidthBp`.
|
|
3558
|
+
* The current width mid-flight is a point on the arc, so a second
|
|
3559
|
+
* flight read from it would land pulled back.
|
|
3560
|
+
*/
|
|
3561
|
+
flyToFit(centerBp: number, fitWidthBp: number): void;
|
|
3394
3562
|
} & {
|
|
3395
3563
|
afterCreate(): void;
|
|
3396
3564
|
afterAttach(): void;
|
|
3397
|
-
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>, InitState, "bpPerPx" | "offsetPx">, {
|
|
3565
|
+
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>, InitState, "bpPerPx" | "cytobandsVisible" | "offsetPx" | "showCytobandsSetting">, {
|
|
3398
3566
|
displayName: string | undefined;
|
|
3399
3567
|
minimized: boolean;
|
|
3400
|
-
highlight: HighlightType[];
|
|
3401
|
-
showHighlightChips: boolean;
|
|
3402
3568
|
id: string;
|
|
3403
3569
|
type: string;
|
|
3404
3570
|
windowStartBp: number;
|
|
@@ -3408,6 +3574,8 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
3408
3574
|
tracks: any[];
|
|
3409
3575
|
hideHeader: boolean;
|
|
3410
3576
|
hideHeaderOverview: boolean;
|
|
3577
|
+
closeUps: any[];
|
|
3578
|
+
closeUpConnectorHeight: number;
|
|
3411
3579
|
hideNoTracksActive: boolean;
|
|
3412
3580
|
trackSelectorType: string;
|
|
3413
3581
|
showGridlines: boolean;
|