@jbrowse/plugin-linear-genome-view 4.3.0 → 5.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/FeatureTrack/configSchema.d.ts +104 -65
- package/esm/FeatureTrack/configSchema.js +47 -1
- package/esm/FeatureTrack/index.js +1 -1
- package/esm/LaunchLinearGenomeView/index.d.ts +14 -0
- package/esm/LaunchLinearGenomeView/index.js +17 -12
- package/esm/LinearGenomeView/FloatingSvgOverlay.d.ts +5 -0
- package/esm/LinearGenomeView/FloatingSvgOverlay.js +25 -0
- package/esm/LinearGenomeView/afterAttach.d.ts +20 -2
- package/esm/LinearGenomeView/afterAttach.js +253 -122
- package/esm/LinearGenomeView/components/CenterLine.d.ts +1 -1
- package/esm/LinearGenomeView/components/CenterLine.js +16 -7
- package/esm/LinearGenomeView/components/ConnectedHoverHighlight.d.ts +7 -0
- package/esm/LinearGenomeView/components/ConnectedHoverHighlight.js +22 -0
- package/esm/LinearGenomeView/components/CrisprGuidePanel.d.ts +3 -0
- package/esm/LinearGenomeView/components/CrisprGuidePanel.js +144 -0
- package/esm/LinearGenomeView/components/Cytobands.d.ts +6 -6
- package/esm/LinearGenomeView/components/Cytobands.js +76 -53
- package/esm/LinearGenomeView/components/ExportSvgDialog.d.ts +7 -3
- package/esm/LinearGenomeView/components/ExportSvgDialog.js +11 -67
- package/esm/LinearGenomeView/components/GetSequenceDialog.d.ts +5 -9
- package/esm/LinearGenomeView/components/GetSequenceDialog.js +84 -88
- package/esm/LinearGenomeView/components/Gridlines.d.ts +1 -1
- package/esm/LinearGenomeView/components/Gridlines.js +29 -58
- package/esm/LinearGenomeView/components/Header.d.ts +1 -1
- package/esm/LinearGenomeView/components/Header.js +32 -16
- package/esm/LinearGenomeView/components/HeaderClearHighlightButton.d.ts +21 -0
- package/esm/LinearGenomeView/components/HeaderClearHighlightButton.js +35 -0
- package/esm/LinearGenomeView/components/HeaderPanControls.d.ts +3 -2
- package/esm/LinearGenomeView/components/HeaderPanControls.js +16 -7
- package/esm/LinearGenomeView/components/HeaderRegionWidth.d.ts +1 -1
- package/esm/LinearGenomeView/components/HeaderRegionWidth.js +9 -6
- package/esm/LinearGenomeView/components/HeaderSearchBoxRow.d.ts +6 -0
- package/esm/LinearGenomeView/components/HeaderSearchBoxRow.js +27 -0
- package/esm/LinearGenomeView/components/HeaderSearchBoxes.d.ts +5 -0
- package/esm/LinearGenomeView/components/HeaderSearchBoxes.js +28 -0
- package/esm/LinearGenomeView/components/HeaderTrackSelectorButton.d.ts +3 -2
- package/esm/LinearGenomeView/components/HeaderTrackSelectorButton.js +11 -4
- package/esm/LinearGenomeView/components/HeaderZoomControls.d.ts +3 -2
- package/esm/LinearGenomeView/components/HeaderZoomControls.js +67 -51
- package/esm/LinearGenomeView/components/Highlight.d.ts +1 -1
- package/esm/LinearGenomeView/components/Highlight.js +19 -23
- package/esm/LinearGenomeView/components/HighlightBand.d.ts +3 -2
- package/esm/LinearGenomeView/components/HighlightBand.js +25 -8
- package/esm/LinearGenomeView/components/HighlightChip.d.ts +9 -0
- package/esm/LinearGenomeView/components/HighlightChip.js +15 -0
- package/esm/LinearGenomeView/components/HoverPositionHighlight.d.ts +12 -0
- package/esm/LinearGenomeView/components/HoverPositionHighlight.js +25 -0
- package/esm/LinearGenomeView/components/ImportForm.d.ts +3 -4
- package/esm/LinearGenomeView/components/ImportForm.js +95 -61
- package/esm/LinearGenomeView/components/LinearGenomeView.d.ts +1 -1
- package/esm/LinearGenomeView/components/LinearGenomeView.js +6 -5
- package/esm/LinearGenomeView/components/LinearGenomeViewContainer.d.ts +1 -1
- package/esm/LinearGenomeView/components/LinearGenomeViewContainer.js +89 -30
- package/esm/LinearGenomeView/components/MiniControls.d.ts +1 -1
- package/esm/LinearGenomeView/components/MiniControls.js +13 -10
- package/esm/LinearGenomeView/components/MotifListPanel.d.ts +3 -0
- package/esm/LinearGenomeView/components/MotifListPanel.js +59 -0
- package/esm/LinearGenomeView/components/NavigationAnnouncer.d.ts +32 -0
- package/esm/LinearGenomeView/components/NavigationAnnouncer.js +51 -0
- package/esm/LinearGenomeView/components/NoTracksActiveButton.d.ts +1 -1
- package/esm/LinearGenomeView/components/NoTracksActiveButton.js +1 -1
- package/esm/LinearGenomeView/components/OverviewHighlight.d.ts +2 -4
- package/esm/LinearGenomeView/components/OverviewHighlight.js +23 -44
- package/esm/LinearGenomeView/components/OverviewHighlightBand.d.ts +9 -0
- package/esm/LinearGenomeView/components/OverviewHighlightBand.js +26 -0
- package/esm/LinearGenomeView/components/OverviewRubberband.d.ts +3 -3
- package/esm/LinearGenomeView/components/OverviewRubberband.js +44 -57
- package/esm/LinearGenomeView/components/OverviewRubberbandHoverTooltip.d.ts +4 -5
- package/esm/LinearGenomeView/components/OverviewRubberbandHoverTooltip.js +13 -20
- package/esm/LinearGenomeView/components/OverviewScalebar.d.ts +3 -2
- package/esm/LinearGenomeView/components/OverviewScalebar.js +84 -79
- package/esm/LinearGenomeView/components/OverviewScalebarPolygon.d.ts +19 -5
- package/esm/LinearGenomeView/components/OverviewScalebarPolygon.js +55 -32
- package/esm/LinearGenomeView/components/OverviewScalebarTickLabels.d.ts +4 -5
- package/esm/LinearGenomeView/components/OverviewScalebarTickLabels.js +16 -18
- package/esm/LinearGenomeView/components/PaddingBlocks.d.ts +7 -0
- package/esm/LinearGenomeView/components/PaddingBlocks.js +51 -0
- package/esm/LinearGenomeView/components/RangeSelectOverlay.d.ts +9 -0
- package/esm/LinearGenomeView/components/RangeSelectOverlay.js +20 -0
- package/esm/LinearGenomeView/components/RegionWidthEditorDialog.d.ts +2 -3
- package/esm/LinearGenomeView/components/RegionWidthEditorDialog.js +19 -26
- package/esm/LinearGenomeView/components/Rubberband.d.ts +1 -1
- package/esm/LinearGenomeView/components/Rubberband.js +13 -16
- package/esm/LinearGenomeView/components/SVGHighlightBand.d.ts +10 -0
- package/esm/LinearGenomeView/components/SVGHighlightBand.js +9 -0
- package/esm/LinearGenomeView/components/Scalebar.d.ts +2 -2
- package/esm/LinearGenomeView/components/Scalebar.js +16 -21
- package/esm/LinearGenomeView/components/ScalebarCoordinateLabels.d.ts +1 -1
- package/esm/LinearGenomeView/components/ScalebarCoordinateLabels.js +54 -35
- package/esm/LinearGenomeView/components/ScalebarRefNameLabels.d.ts +1 -1
- package/esm/LinearGenomeView/components/ScalebarRefNameLabels.js +142 -126
- package/esm/LinearGenomeView/components/SearchBox.d.ts +22 -2
- package/esm/LinearGenomeView/components/SearchBox.js +58 -66
- package/esm/LinearGenomeView/components/SearchPanelForm.d.ts +9 -0
- package/esm/LinearGenomeView/components/SearchPanelForm.js +18 -0
- package/esm/LinearGenomeView/components/SearchResultsDialog.d.ts +3 -3
- package/esm/LinearGenomeView/components/SearchResultsDialog.js +5 -7
- package/esm/LinearGenomeView/components/SearchResultsTable.d.ts +4 -3
- package/esm/LinearGenomeView/components/SearchResultsTable.js +45 -53
- package/esm/LinearGenomeView/components/SequenceFeatureHoverHighlight.d.ts +5 -0
- package/esm/LinearGenomeView/components/SequenceFeatureHoverHighlight.js +37 -0
- package/esm/LinearGenomeView/components/SequenceFeatureHoverHighlightExtension.d.ts +2 -0
- package/esm/LinearGenomeView/components/SequenceFeatureHoverHighlightExtension.js +5 -0
- package/esm/LinearGenomeView/components/SequencePatternPanel.d.ts +3 -0
- package/esm/LinearGenomeView/components/SequencePatternPanel.js +42 -0
- package/esm/LinearGenomeView/components/SequenceSearchDialog.d.ts +1 -1
- package/esm/LinearGenomeView/components/SequenceSearchDialog.js +31 -53
- package/esm/LinearGenomeView/components/StrandCheckboxes.d.ts +8 -0
- package/esm/LinearGenomeView/components/StrandCheckboxes.js +13 -0
- package/esm/LinearGenomeView/components/TrackContainer.d.ts +1 -1
- package/esm/LinearGenomeView/components/TrackContainer.js +83 -39
- package/esm/LinearGenomeView/components/TrackLabel.d.ts +2 -3
- package/esm/LinearGenomeView/components/TrackLabel.js +11 -24
- package/esm/LinearGenomeView/components/TrackLabelButtons.d.ts +7 -0
- package/esm/LinearGenomeView/components/TrackLabelButtons.js +33 -0
- package/esm/LinearGenomeView/components/TrackLabelDragHandle.d.ts +2 -5
- package/esm/LinearGenomeView/components/TrackLabelDragHandle.js +6 -2
- package/esm/LinearGenomeView/components/TrackLabelMenu.d.ts +1 -1
- package/esm/LinearGenomeView/components/TrackLabelMenu.js +32 -85
- package/esm/LinearGenomeView/components/TrackLabelRefNameWarning.d.ts +22 -0
- package/esm/LinearGenomeView/components/TrackLabelRefNameWarning.js +46 -0
- package/esm/LinearGenomeView/components/TrackRenderingContainer.d.ts +1 -1
- package/esm/LinearGenomeView/components/TrackRenderingContainer.js +72 -18
- package/esm/LinearGenomeView/components/TracksContainer.d.ts +1 -1
- package/esm/LinearGenomeView/components/TracksContainer.js +65 -32
- package/esm/LinearGenomeView/components/VerticalGuide.d.ts +1 -1
- package/esm/LinearGenomeView/components/VerticalGuide.js +6 -13
- package/esm/LinearGenomeView/components/ZoomButton.d.ts +7 -0
- package/esm/LinearGenomeView/components/ZoomButton.js +22 -0
- package/esm/LinearGenomeView/components/ZoomTransform.d.ts +9 -0
- package/esm/LinearGenomeView/components/ZoomTransform.js +33 -0
- package/esm/LinearGenomeView/components/defaultMotifs.d.ts +1 -0
- package/esm/LinearGenomeView/components/defaultMotifs.js +22 -0
- package/esm/LinearGenomeView/components/fetchSequence.d.ts +7 -8
- package/esm/LinearGenomeView/components/fetchSequence.js +17 -9
- package/esm/LinearGenomeView/components/recentLocationsMenu.d.ts +15 -0
- package/esm/LinearGenomeView/components/recentLocationsMenu.js +36 -0
- package/esm/LinearGenomeView/components/searchModes.d.ts +13 -0
- package/esm/LinearGenomeView/components/searchModes.js +22 -0
- package/esm/LinearGenomeView/components/trackLabelMenuItems.d.ts +7 -0
- package/esm/LinearGenomeView/components/trackLabelMenuItems.js +67 -0
- package/esm/LinearGenomeView/components/useRangeSelect.d.ts +11 -66
- package/esm/LinearGenomeView/components/useRangeSelect.js +82 -91
- package/esm/LinearGenomeView/components/useSearchBoxPrefs.d.ts +26 -0
- package/esm/LinearGenomeView/components/useSearchBoxPrefs.js +58 -0
- package/esm/LinearGenomeView/components/useSideScroll.d.ts +1 -1
- package/esm/LinearGenomeView/components/useSideScroll.js +87 -19
- package/esm/LinearGenomeView/components/util.d.ts +20 -6
- package/esm/LinearGenomeView/components/util.js +27 -6
- package/esm/LinearGenomeView/consts.d.ts +7 -2
- package/esm/LinearGenomeView/consts.js +18 -2
- package/esm/LinearGenomeView/flyTo.d.ts +38 -0
- package/esm/LinearGenomeView/flyTo.js +135 -0
- package/esm/LinearGenomeView/headerFit.d.ts +27 -0
- package/esm/LinearGenomeView/headerFit.js +59 -0
- package/esm/LinearGenomeView/index.d.ts +31 -2
- package/esm/LinearGenomeView/index.js +8 -5
- package/esm/LinearGenomeView/initKeys.d.ts +13 -0
- package/esm/LinearGenomeView/initKeys.js +104 -0
- package/esm/LinearGenomeView/keyboardHandler.d.ts +7 -0
- package/esm/LinearGenomeView/keyboardHandler.js +10 -0
- package/esm/LinearGenomeView/lazyDialogs.d.ts +6 -10
- package/esm/LinearGenomeView/lazyDialogs.js +3 -3
- package/esm/LinearGenomeView/linkedViewSync.d.ts +20 -0
- package/esm/LinearGenomeView/linkedViewSync.js +52 -0
- package/esm/LinearGenomeView/menuItems.d.ts +27 -2
- package/esm/LinearGenomeView/menuItems.js +137 -101
- package/esm/LinearGenomeView/model.d.ts +1536 -146
- package/esm/LinearGenomeView/model.js +2348 -515
- package/esm/LinearGenomeView/sharedScaleContainer.d.ts +18 -0
- package/esm/LinearGenomeView/sharedScaleContainer.js +17 -0
- package/esm/LinearGenomeView/showRegionsWithUndo.d.ts +35 -0
- package/esm/LinearGenomeView/showRegionsWithUndo.js +44 -0
- package/esm/LinearGenomeView/stickyChrome.d.ts +19 -0
- package/esm/LinearGenomeView/stickyChrome.js +30 -0
- package/esm/LinearGenomeView/svgcomponents/SVGGridlines.d.ts +1 -1
- package/esm/LinearGenomeView/svgcomponents/SVGGridlines.js +15 -16
- package/esm/LinearGenomeView/svgcomponents/SVGHeader.d.ts +2 -3
- package/esm/LinearGenomeView/svgcomponents/SVGHeader.js +45 -33
- package/esm/LinearGenomeView/svgcomponents/SVGHighlights.d.ts +5 -0
- package/esm/LinearGenomeView/svgcomponents/SVGHighlights.js +26 -0
- package/esm/LinearGenomeView/svgcomponents/SVGHighlightsOverlay.d.ts +5 -0
- package/esm/LinearGenomeView/svgcomponents/SVGHighlightsOverlay.js +13 -0
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.d.ts +1 -3
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js +77 -41
- package/esm/LinearGenomeView/svgcomponents/SVGRegionSeparators.d.ts +1 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRegionSeparators.js +23 -3
- package/esm/LinearGenomeView/svgcomponents/SVGRowHeader.d.ts +8 -0
- package/esm/LinearGenomeView/svgcomponents/SVGRowHeader.js +37 -0
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.d.ts +3 -3
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.js +64 -36
- package/esm/LinearGenomeView/svgcomponents/SVGScalebar.d.ts +1 -1
- package/esm/LinearGenomeView/svgcomponents/SVGScalebar.js +7 -5
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.d.ts +5 -3
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.js +43 -7
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.d.ts +8 -14
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.js +16 -21
- package/esm/LinearGenomeView/svgcomponents/SVGView.d.ts +18 -0
- package/esm/LinearGenomeView/svgcomponents/SVGView.js +13 -0
- package/esm/LinearGenomeView/svgcomponents/figureContract.d.ts +45 -0
- package/esm/LinearGenomeView/svgcomponents/figureContract.js +130 -0
- package/esm/LinearGenomeView/svgcomponents/renderViewTracks.d.ts +76 -0
- package/esm/LinearGenomeView/svgcomponents/renderViewTracks.js +66 -0
- package/esm/LinearGenomeView/svgcomponents/useViewSvgFigure.d.ts +70 -0
- package/esm/LinearGenomeView/svgcomponents/useViewSvgFigure.js +263 -0
- package/esm/LinearGenomeView/svgcomponents/util.d.ts +92 -5
- package/esm/LinearGenomeView/svgcomponents/util.js +236 -3
- package/esm/LinearGenomeView/types.d.ts +17 -31
- package/esm/LinearGenomeView/types.js +1 -0
- package/esm/LinearGenomeView/util.d.ts +332 -12
- package/esm/LinearGenomeView/util.js +606 -62
- package/esm/MultiLevelRubberband/MultiLevelRubberband.d.ts +6 -0
- package/esm/MultiLevelRubberband/MultiLevelRubberband.js +37 -0
- package/esm/MultiLevelRubberband/VerticalGuide.d.ts +6 -0
- package/esm/MultiLevelRubberband/VerticalGuide.js +21 -0
- package/esm/MultiLevelRubberband/index.d.ts +2 -0
- package/esm/MultiLevelRubberband/index.js +1 -0
- package/esm/MultiLevelRubberband/types.d.ts +6 -0
- package/esm/MultiLevelRubberband/useRangeSelect.d.ts +24 -0
- package/esm/MultiLevelRubberband/useRangeSelect.js +136 -0
- package/esm/displayKitTests/perRegionTestEnv.d.ts +1263 -0
- package/esm/displayKitTests/perRegionTestEnv.js +141 -0
- package/esm/index.d.ts +112 -1237
- package/esm/index.js +102 -24
- package/esm/lazyPluginExports.d.ts +23 -0
- package/esm/lazyPluginExports.js +36 -0
- package/esm/searchUtils.d.ts +52 -11
- package/esm/searchUtils.js +317 -46
- package/esm/shared/RubberbandSpan.d.ts +15 -0
- package/esm/shared/RubberbandSpan.js +33 -0
- package/esm/shared/coordLabels.d.ts +40 -0
- package/esm/shared/coordLabels.js +119 -0
- package/package.json +18 -19
- package/esm/BaseLinearDisplay/SVGLegend.d.ts +0 -6
- package/esm/BaseLinearDisplay/SVGLegend.js +0 -17
- package/esm/BaseLinearDisplay/calculateSvgLegendWidth.d.ts +0 -2
- package/esm/BaseLinearDisplay/calculateSvgLegendWidth.js +0 -11
- package/esm/BaseLinearDisplay/components/BaseLinearDisplay.d.ts +0 -8
- package/esm/BaseLinearDisplay/components/BaseLinearDisplay.js +0 -53
- package/esm/BaseLinearDisplay/components/Block.d.ts +0 -14
- package/esm/BaseLinearDisplay/components/Block.js +0 -45
- package/esm/BaseLinearDisplay/components/BlockErrorMessage.d.ts +0 -7
- package/esm/BaseLinearDisplay/components/BlockErrorMessage.js +0 -22
- package/esm/BaseLinearDisplay/components/BlockMsg.d.ts +0 -6
- package/esm/BaseLinearDisplay/components/BlockMsg.js +0 -26
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/CollapseIntronsDialog.d.ts +0 -9
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/CollapseIntronsDialog.js +0 -42
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/TranscriptTable.d.ts +0 -11
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/TranscriptTable.js +0 -40
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/util.d.ts +0 -19
- package/esm/BaseLinearDisplay/components/CollapseIntronsDialog/util.js +0 -45
- package/esm/BaseLinearDisplay/components/FloatingLabels.d.ts +0 -5
- package/esm/BaseLinearDisplay/components/FloatingLabels.js +0 -75
- package/esm/BaseLinearDisplay/components/FloatingLegend.d.ts +0 -8
- package/esm/BaseLinearDisplay/components/FloatingLegend.js +0 -43
- package/esm/BaseLinearDisplay/components/LinearBlocks.d.ts +0 -5
- package/esm/BaseLinearDisplay/components/LinearBlocks.js +0 -23
- package/esm/BaseLinearDisplay/components/LoadingOverlay.d.ts +0 -5
- package/esm/BaseLinearDisplay/components/LoadingOverlay.js +0 -49
- package/esm/BaseLinearDisplay/components/MaxHeightReachedIndicator.d.ts +0 -4
- package/esm/BaseLinearDisplay/components/MaxHeightReachedIndicator.js +0 -26
- package/esm/BaseLinearDisplay/components/MenuPage.d.ts +0 -8
- package/esm/BaseLinearDisplay/components/MenuPage.js +0 -24
- package/esm/BaseLinearDisplay/components/NonBlockCanvasDisplayComponent.d.ts +0 -21
- package/esm/BaseLinearDisplay/components/NonBlockCanvasDisplayComponent.js +0 -52
- package/esm/BaseLinearDisplay/components/RenderedBlocks.d.ts +0 -12
- package/esm/BaseLinearDisplay/components/RenderedBlocks.js +0 -22
- package/esm/BaseLinearDisplay/components/ServerSideRenderedBlockContent.d.ts +0 -12
- package/esm/BaseLinearDisplay/components/ServerSideRenderedBlockContent.js +0 -18
- package/esm/BaseLinearDisplay/components/TooLargeMessage.d.ts +0 -10
- package/esm/BaseLinearDisplay/components/TooLargeMessage.js +0 -20
- package/esm/BaseLinearDisplay/components/Tooltip.d.ts +0 -13
- package/esm/BaseLinearDisplay/components/Tooltip.js +0 -22
- package/esm/BaseLinearDisplay/components/types.d.ts +0 -1
- package/esm/BaseLinearDisplay/components/util.d.ts +0 -21
- package/esm/BaseLinearDisplay/components/util.js +0 -107
- package/esm/BaseLinearDisplay/index.d.ts +0 -17
- package/esm/BaseLinearDisplay/index.js +0 -13
- package/esm/BaseLinearDisplay/model.d.ts +0 -1197
- package/esm/BaseLinearDisplay/model.js +0 -432
- package/esm/BaseLinearDisplay/models/FeatureDensityMixin.d.ts +0 -32
- package/esm/BaseLinearDisplay/models/FeatureDensityMixin.js +0 -113
- package/esm/BaseLinearDisplay/models/NonBlockCanvasDisplayMixin.d.ts +0 -26
- package/esm/BaseLinearDisplay/models/NonBlockCanvasDisplayMixin.js +0 -57
- package/esm/BaseLinearDisplay/models/SvgFloatingLabels.d.ts +0 -8
- package/esm/BaseLinearDisplay/models/SvgFloatingLabels.js +0 -19
- package/esm/BaseLinearDisplay/models/TrackHeightMixin.d.ts +0 -11
- package/esm/BaseLinearDisplay/models/TrackHeightMixin.js +0 -31
- package/esm/BaseLinearDisplay/models/autorunFeatureDensityStats.d.ts +0 -2
- package/esm/BaseLinearDisplay/models/autorunFeatureDensityStats.js +0 -29
- package/esm/BaseLinearDisplay/models/configSchema.d.ts +0 -29
- package/esm/BaseLinearDisplay/models/configSchema.js +0 -33
- package/esm/BaseLinearDisplay/models/serverSideRenderedBlock.d.ts +0 -98
- package/esm/BaseLinearDisplay/models/serverSideRenderedBlock.js +0 -242
- package/esm/BaseLinearDisplay/models/util.d.ts +0 -9
- package/esm/BaseLinearDisplay/models/util.js +0 -43
- package/esm/BaseLinearDisplay/renderSvg.d.ts +0 -3
- package/esm/BaseLinearDisplay/renderSvg.js +0 -63
- package/esm/BaseLinearDisplay/types.d.ts +0 -43
- package/esm/BaseLinearDisplay/types.js +0 -3
- package/esm/BaseLinearDisplay/util.d.ts +0 -16
- package/esm/BaseLinearDisplay/util.js +0 -71
- package/esm/BasicTrack/configSchema.d.ts +0 -85
- package/esm/BasicTrack/configSchema.js +0 -8
- package/esm/BasicTrack/index.d.ts +0 -2
- package/esm/BasicTrack/index.js +0 -12
- package/esm/LinearBareDisplay/configSchema.d.ts +0 -32
- package/esm/LinearBareDisplay/configSchema.js +0 -11
- package/esm/LinearBareDisplay/index.d.ts +0 -4
- package/esm/LinearBareDisplay/index.js +0 -20
- package/esm/LinearBareDisplay/model.d.ts +0 -1196
- package/esm/LinearBareDisplay/model.js +0 -32
- package/esm/LinearBasicDisplay/components/LinearBasicDisplayComponent.d.ts +0 -5
- package/esm/LinearBasicDisplay/components/LinearBasicDisplayComponent.js +0 -9
- package/esm/LinearBasicDisplay/configSchema.d.ts +0 -32
- package/esm/LinearBasicDisplay/configSchema.js +0 -11
- package/esm/LinearBasicDisplay/index.d.ts +0 -4
- package/esm/LinearBasicDisplay/index.js +0 -20
- package/esm/LinearBasicDisplay/model.d.ts +0 -1391
- package/esm/LinearBasicDisplay/model.js +0 -158
- package/esm/LinearFeatureDisplay/components/AddFiltersDialog.d.ts +0 -9
- package/esm/LinearFeatureDisplay/components/AddFiltersDialog.js +0 -58
- package/esm/LinearFeatureDisplay/components/SetMaxHeightDialog.d.ts +0 -8
- package/esm/LinearFeatureDisplay/components/SetMaxHeightDialog.js +0 -26
- package/esm/LinearFeatureDisplay/configSchema.d.ts +0 -32
- package/esm/LinearFeatureDisplay/configSchema.js +0 -11
- package/esm/LinearFeatureDisplay/index.d.ts +0 -3
- package/esm/LinearFeatureDisplay/index.js +0 -2
- package/esm/LinearFeatureDisplay/model.d.ts +0 -1443
- package/esm/LinearFeatureDisplay/model.js +0 -305
- package/esm/LinearGenomeView/SVGErrorBox.d.ts +0 -5
- package/esm/LinearGenomeView/SVGErrorBox.js +0 -4
- package/esm/LinearGenomeView/components/ImportFormRefNameAutocomplete.d.ts +0 -11
- package/esm/LinearGenomeView/components/ImportFormRefNameAutocomplete.js +0 -27
- package/esm/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.d.ts +0 -5
- package/esm/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.js +0 -13
- package/esm/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.d.ts +0 -3
- package/esm/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.js +0 -17
- package/esm/LinearGenomeView/components/RefNameAutocomplete/HelpDialog.d.ts +0 -3
- package/esm/LinearGenomeView/components/RefNameAutocomplete/HelpDialog.js +0 -8
- package/esm/LinearGenomeView/components/RefNameAutocomplete/index.d.ts +0 -16
- package/esm/LinearGenomeView/components/RefNameAutocomplete/index.js +0 -101
- package/esm/LinearGenomeView/components/RefNameAutocomplete/util.d.ts +0 -10
- package/esm/LinearGenomeView/components/RefNameAutocomplete/util.js +0 -45
- package/esm/LinearGenomeView/components/RubberbandSpan.d.ts +0 -15
- package/esm/LinearGenomeView/components/RubberbandSpan.js +0 -32
- package/esm/LinearGenomeView/components/RubberbandTooltip.d.ts +0 -5
- package/esm/LinearGenomeView/components/RubberbandTooltip.js +0 -17
- package/esm/LinearGenomeView/components/TrackLabelContainer.d.ts +0 -8
- package/esm/LinearGenomeView/components/TrackLabelContainer.js +0 -25
- package/esm/LinearGenomeView/components/useWheelScroll.d.ts +0 -7
- package/esm/LinearGenomeView/components/useWheelScroll.js +0 -69
- package/esm/LinearGenomeView/svgExportUtil.d.ts +0 -9
- package/esm/LinearGenomeView/svgExportUtil.js +0 -6
- package/esm/LinearGenomeView/svgcomponents/SVGBackground.d.ts +0 -5
- package/esm/LinearGenomeView/svgcomponents/SVGBackground.js +0 -7
- /package/esm/{BaseLinearDisplay/components → MultiLevelRubberband}/types.js +0 -0
|
@@ -1,209 +1,1598 @@
|
|
|
1
|
-
import type React from 'react';
|
|
2
1
|
import type { BpOffset, ExportSvgOptions, HighlightType, InitState, NavLocation, VolatileGuide } from './types.ts';
|
|
3
2
|
import type PluginManager from '@jbrowse/core/PluginManager';
|
|
4
3
|
import type BaseResult from '@jbrowse/core/TextSearch/BaseResults';
|
|
5
|
-
import type { Assembly } from '@jbrowse/core/assemblyManager/assembly';
|
|
6
4
|
import type { MenuItem } from '@jbrowse/core/ui';
|
|
7
5
|
import type { ParsedLocString } from '@jbrowse/core/util';
|
|
8
|
-
import type {
|
|
6
|
+
import type { ViewLayout } from '@jbrowse/core/util/Base1DUtils';
|
|
7
|
+
import type { BlockSet, ContentBlock } from '@jbrowse/core/util/blockTypes';
|
|
9
8
|
import type { Region } from '@jbrowse/core/util/types';
|
|
9
|
+
import type { ViewStatus } from '@jbrowse/core/util/viewStatus';
|
|
10
10
|
import type { Instance } from '@jbrowse/mobx-state-tree';
|
|
11
|
-
|
|
11
|
+
/**
|
|
12
|
+
* #stateModel LinearGenomeView
|
|
13
|
+
* #category view
|
|
14
|
+
*
|
|
15
|
+
* #example
|
|
16
|
+
* A `LinearGenomeView` is what you hand-author under `defaultSession.views`. The
|
|
17
|
+
* `init` shorthand fills in `displayedRegions`/`bpPerPx`/`offsetPx` for you:
|
|
18
|
+
* ```js
|
|
19
|
+
* defaultSession: {
|
|
20
|
+
* name: 'My session',
|
|
21
|
+
* views: [
|
|
22
|
+
* {
|
|
23
|
+
* type: 'LinearGenomeView',
|
|
24
|
+
* // plain persisted props sit alongside init, not inside it
|
|
25
|
+
* colorByCDS: true,
|
|
26
|
+
* init: {
|
|
27
|
+
* assembly: 'hg38',
|
|
28
|
+
* loc: 'chr1:1,000,000-1,100,000',
|
|
29
|
+
* tracks: ['genes', 'alignments'],
|
|
30
|
+
* },
|
|
31
|
+
* },
|
|
32
|
+
* ],
|
|
33
|
+
* }
|
|
34
|
+
* ```
|
|
35
|
+
* `init` holds only keys that need on-attach resolution — also `tracklist`,
|
|
36
|
+
* `nav`, `highlight` (see the `init` property below). Plain view props like
|
|
37
|
+
* `colorByCDS`, `showAminoAcids`, `showCenterLine`, `trackLabels`,
|
|
38
|
+
* `showHighlightChips` are set
|
|
39
|
+
* directly on the view (MST restores them natively).
|
|
40
|
+
* At runtime the same model is driven imperatively — every property and action
|
|
41
|
+
* below is reachable on `viewState.session.views[0]`:
|
|
42
|
+
* ```js
|
|
43
|
+
* const view = viewState.session.views[0]
|
|
44
|
+
* await view.navToLocString('chr1:2,000,000-2,100,000')
|
|
45
|
+
* view.showTrack('alignments')
|
|
46
|
+
* view.zoomTo(view.bpPerPx * 2) // zoom out 2x
|
|
47
|
+
* ```
|
|
48
|
+
*/
|
|
49
|
+
export declare function stateModelFactory(pluginManager: PluginManager): import("@jbrowse/mobx-state-tree").IModelType<Omit<Omit<{
|
|
12
50
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
13
51
|
displayName: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
14
|
-
minimized: import("@jbrowse/mobx-state-tree").
|
|
15
|
-
} & {
|
|
52
|
+
minimized: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
53
|
+
}, "highlight" | "showHighlightChips"> & {
|
|
54
|
+
highlight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<HighlightType, HighlightType, HighlightType>>, [undefined]>;
|
|
55
|
+
showHighlightChips: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
56
|
+
}, "colorByCDS" | "displayedRegions" | "hideHeader" | "hideHeaderOverview" | "hideNoTracksActive" | "id" | "init" | "labelsVisible" | "legacyBpPerPx" | "scalebarOnly" | "showAminoAcids" | "showCenterLine" | "showCytobands" | "showGridlines" | "showTrackOutlines" | "trackLabels" | "trackSelectorType" | "tracks" | "type" | "windowStartBp" | "windowWidthBp"> & {
|
|
16
57
|
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
17
58
|
type: import("@jbrowse/mobx-state-tree").IType<string | undefined, string, string>;
|
|
18
|
-
|
|
19
|
-
|
|
59
|
+
windowStartBp: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
60
|
+
windowWidthBp: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
61
|
+
legacyBpPerPx: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<number>, [undefined]>;
|
|
20
62
|
displayedRegions: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IType<Region[], Region[], Region[]>, [undefined]>;
|
|
21
63
|
tracks: import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyType>;
|
|
22
|
-
hideHeader: import("@jbrowse/mobx-state-tree").
|
|
23
|
-
hideHeaderOverview: import("@jbrowse/mobx-state-tree").
|
|
24
|
-
hideNoTracksActive: import("@jbrowse/mobx-state-tree").
|
|
64
|
+
hideHeader: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
65
|
+
hideHeaderOverview: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
66
|
+
hideNoTracksActive: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
25
67
|
trackSelectorType: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
26
68
|
showCenterLine: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
27
|
-
|
|
69
|
+
showCytobands: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
28
70
|
trackLabels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
29
|
-
showGridlines: import("@jbrowse/mobx-state-tree").
|
|
30
|
-
highlight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<HighlightType, HighlightType, HighlightType>>, [undefined]>;
|
|
31
|
-
highlightsVisible: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
71
|
+
showGridlines: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
32
72
|
labelsVisible: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
33
73
|
colorByCDS: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
74
|
+
showAminoAcids: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
34
75
|
showTrackOutlines: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
76
|
+
scalebarOnly: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
35
77
|
init: import("@jbrowse/mobx-state-tree").IType<InitState | undefined, InitState | undefined, InitState | undefined>;
|
|
36
78
|
}, {
|
|
37
79
|
width: number;
|
|
80
|
+
bodyMounted: boolean;
|
|
38
81
|
} & {
|
|
82
|
+
readonly effectiveBodyMounted: boolean;
|
|
39
83
|
menuItems(): MenuItem[];
|
|
40
84
|
} & {
|
|
41
85
|
setDisplayName(name: string): void;
|
|
42
86
|
setWidth(newWidth: number): void;
|
|
87
|
+
setBodyMounted(flag: boolean): void;
|
|
43
88
|
setMinimized(flag: boolean): void;
|
|
44
89
|
} & {
|
|
90
|
+
addToHighlights(highlight: HighlightType): void;
|
|
91
|
+
setHighlight(highlight?: HighlightType[]): void;
|
|
92
|
+
removeHighlight(highlight: HighlightType): void;
|
|
93
|
+
updateHighlight(old: HighlightType, updates: Partial<HighlightType>): void;
|
|
94
|
+
setShowHighlightChips(arg: boolean): void;
|
|
95
|
+
} & {
|
|
96
|
+
afterAttach(): void;
|
|
97
|
+
} & {
|
|
98
|
+
/**
|
|
99
|
+
* #volatile
|
|
100
|
+
*/
|
|
45
101
|
volatileWidth: number | undefined;
|
|
102
|
+
/**
|
|
103
|
+
* #volatile
|
|
104
|
+
*/
|
|
46
105
|
minimumBlockWidth: number;
|
|
106
|
+
/**
|
|
107
|
+
* #volatile
|
|
108
|
+
*/
|
|
47
109
|
draggingTrackId: undefined | string;
|
|
110
|
+
/**
|
|
111
|
+
* #volatile
|
|
112
|
+
*/
|
|
48
113
|
lastTrackDragY: undefined | number;
|
|
114
|
+
/**
|
|
115
|
+
* #volatile
|
|
116
|
+
*/
|
|
49
117
|
volatileError: unknown;
|
|
50
|
-
|
|
51
|
-
|
|
118
|
+
/**
|
|
119
|
+
* #volatile
|
|
120
|
+
*/
|
|
52
121
|
trackRefs: Record<string, HTMLDivElement>;
|
|
53
|
-
|
|
122
|
+
/**
|
|
123
|
+
* #volatile
|
|
124
|
+
*/
|
|
125
|
+
coarseDynamicBlocks: ContentBlock[];
|
|
126
|
+
/**
|
|
127
|
+
* #volatile
|
|
128
|
+
*/
|
|
54
129
|
coarseTotalBp: number;
|
|
130
|
+
/**
|
|
131
|
+
* #volatile
|
|
132
|
+
*/
|
|
133
|
+
coarseBpPerPx: number;
|
|
134
|
+
/**
|
|
135
|
+
* #volatile
|
|
136
|
+
*/
|
|
55
137
|
leftOffset: undefined | BpOffset;
|
|
138
|
+
/**
|
|
139
|
+
* #volatile
|
|
140
|
+
*/
|
|
56
141
|
rightOffset: undefined | BpOffset;
|
|
142
|
+
/**
|
|
143
|
+
* #volatile
|
|
144
|
+
*/
|
|
57
145
|
isScalebarRefNameMenuOpen: boolean;
|
|
146
|
+
/**
|
|
147
|
+
* #volatile
|
|
148
|
+
*/
|
|
58
149
|
scalebarRefNameClickPending: boolean;
|
|
150
|
+
/**
|
|
151
|
+
* #volatile
|
|
152
|
+
* temporary vertical guides that can be set by displays (e.g., LD display hover)
|
|
153
|
+
*/
|
|
59
154
|
volatileGuides: VolatileGuide[];
|
|
60
155
|
} & {
|
|
156
|
+
/**
|
|
157
|
+
* #getter
|
|
158
|
+
* corresponds roughly to the zoom level, base-pairs per pixel.
|
|
159
|
+
*
|
|
160
|
+
* Zero before a width is measured, which is the same not-yet-measured
|
|
161
|
+
* sentinel `Base1DView` uses and which `displayedRegionsTotalPx` and the
|
|
162
|
+
* offset getters already guard for. Reads `volatileWidth` rather than the
|
|
163
|
+
* `width` getter on purpose: that one throws when unmeasured, and these
|
|
164
|
+
* are read from the first render.
|
|
165
|
+
*/
|
|
166
|
+
readonly bpPerPx: number;
|
|
167
|
+
/**
|
|
168
|
+
* #getter
|
|
169
|
+
* corresponds roughly to the horizontal scroll of the LGV
|
|
170
|
+
*/
|
|
171
|
+
readonly offsetPx: number;
|
|
172
|
+
/**
|
|
173
|
+
* #getter
|
|
174
|
+
* scroll-to-zoom is a global, personal preference resolved from the
|
|
175
|
+
* session; toggling it in any view applies everywhere
|
|
176
|
+
*/
|
|
177
|
+
readonly scrollZoom: boolean;
|
|
178
|
+
/**
|
|
179
|
+
* #getter
|
|
180
|
+
*/
|
|
61
181
|
readonly pinnedTracks: any[];
|
|
182
|
+
/**
|
|
183
|
+
* #getter
|
|
184
|
+
*/
|
|
62
185
|
readonly unpinnedTracks: any[];
|
|
63
|
-
|
|
186
|
+
/**
|
|
187
|
+
* #getter
|
|
188
|
+
* the effective track labels setting, resolving the stored `trackLabels`
|
|
189
|
+
* against the LinearGenomeViewPlugin config default
|
|
190
|
+
*/
|
|
191
|
+
readonly effectiveTrackLabels: any;
|
|
192
|
+
/**
|
|
193
|
+
* #getter
|
|
194
|
+
*/
|
|
64
195
|
readonly width: number;
|
|
65
|
-
|
|
196
|
+
/**
|
|
197
|
+
* #getter
|
|
198
|
+
* width minus track outline borders (1px each side when shown)
|
|
199
|
+
*/
|
|
200
|
+
readonly trackWidthPx: number;
|
|
201
|
+
/**
|
|
202
|
+
* #getter
|
|
203
|
+
*/
|
|
66
204
|
readonly assemblyNames: string[];
|
|
205
|
+
/**
|
|
206
|
+
* #getter
|
|
207
|
+
*/
|
|
67
208
|
readonly assemblyDisplayNames: string[];
|
|
209
|
+
/**
|
|
210
|
+
* #getter
|
|
211
|
+
* checking if lgv is a 'top-level' view is used for toggling pin track
|
|
212
|
+
* capability, sticky positioning
|
|
213
|
+
*/
|
|
68
214
|
readonly isTopLevelView: boolean;
|
|
215
|
+
/**
|
|
216
|
+
* #getter
|
|
217
|
+
* only uses sticky view headers when it is a 'top-level' view and
|
|
218
|
+
* session allows it
|
|
219
|
+
*/
|
|
69
220
|
readonly stickyViewHeaders: boolean;
|
|
70
|
-
readonly rubberbandTop: number;
|
|
71
|
-
readonly pinnedTracksTop: number;
|
|
72
221
|
} & {
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
222
|
+
/**
|
|
223
|
+
* #getter
|
|
224
|
+
* Assembly-name prefix for the scalebar refName labels, or undefined for
|
|
225
|
+
* none. A container view (e.g. LinearSyntenyView) opts its sub-views in by
|
|
226
|
+
* exposing showAssemblyNameInSubviewScalebar; duck-typed rather than
|
|
227
|
+
* matching a concrete view type so no upward plugin dependency is needed
|
|
228
|
+
* and any container can opt in. A wrong nesting depth simply yields no
|
|
229
|
+
* prefix — hence the hasParent guard, since getParent throws (rather than
|
|
230
|
+
* returning undefined) when the view sits shallower than depth 2.
|
|
231
|
+
*/
|
|
232
|
+
readonly scalebarDisplayPrefix: string | undefined;
|
|
233
|
+
/**
|
|
234
|
+
* #getter
|
|
235
|
+
*/
|
|
76
236
|
readonly assembliesNotFound: string | undefined;
|
|
237
|
+
/**
|
|
238
|
+
* #getter
|
|
239
|
+
*/
|
|
77
240
|
readonly assemblyErrors: string;
|
|
241
|
+
/**
|
|
242
|
+
* #getter
|
|
243
|
+
*/
|
|
78
244
|
readonly assembliesInitialized: boolean;
|
|
245
|
+
/**
|
|
246
|
+
* #getter
|
|
247
|
+
* the assembly named by a pending `init`, or undefined when no init is
|
|
248
|
+
* set. `init`'s assembly isn't in `assemblyNames` yet (that derives from
|
|
249
|
+
* displayedRegions, still empty pre-navigation), so init-phase readiness
|
|
250
|
+
* and error checks resolve it directly through here.
|
|
251
|
+
*/
|
|
252
|
+
readonly initAssembly: (import("@jbrowse/mobx-state-tree").ModelInstanceTypeProps<{
|
|
253
|
+
configuration: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").IReferenceType<import("@jbrowse/mobx-state-tree").IAnyType>>;
|
|
254
|
+
}> & {
|
|
255
|
+
error: unknown;
|
|
256
|
+
loadingP: Promise<void> | undefined;
|
|
257
|
+
adapterLoads: import("@jbrowse/quick-lru").default<string, Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>>;
|
|
258
|
+
volatileRegions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
259
|
+
refNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
260
|
+
canonicalToSeqAdapterRefNames: Record<string, string> | undefined;
|
|
261
|
+
cytobands: import("@jbrowse/core/util").Feature[] | undefined;
|
|
262
|
+
loadedGeneticCodes: Record<string, number> | undefined;
|
|
263
|
+
lowerCaseRefNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
264
|
+
statusMessage: string | undefined;
|
|
265
|
+
statusProgress: number | undefined;
|
|
266
|
+
statusSource: string | undefined;
|
|
267
|
+
refNameMismatches: Map<string, import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch>;
|
|
268
|
+
} & {
|
|
269
|
+
getConf(arg: string): any;
|
|
270
|
+
} & {
|
|
271
|
+
readonly name: string;
|
|
272
|
+
readonly aliases: string[];
|
|
273
|
+
readonly displayName: string;
|
|
274
|
+
readonly refNameColors: string[];
|
|
275
|
+
} & {
|
|
276
|
+
readonly allAliases: string[];
|
|
277
|
+
hasName(name: string): boolean;
|
|
278
|
+
} & {
|
|
279
|
+
setStatus(status?: import("@jbrowse/core/util").RpcStatus): void;
|
|
280
|
+
setRefNameMismatch(adapterCacheKey: string, mismatch: import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch): void;
|
|
281
|
+
} & {
|
|
282
|
+
setLoaded({ regions, refNameAliases, lowerCaseRefNameAliases, canonicalToSeqAdapterRefNames, cytobands, geneticCodes, }: import("@jbrowse/core/assemblyManager/assembly").RefNameMaps & {
|
|
283
|
+
regions: import("@jbrowse/core/util").Region[];
|
|
284
|
+
cytobands: import("@jbrowse/core/util").Feature[];
|
|
285
|
+
geneticCodes: Record<string, number>;
|
|
286
|
+
}): void;
|
|
287
|
+
setError(e: unknown): void;
|
|
288
|
+
setLoadingP(p?: Promise<void>): void;
|
|
289
|
+
loadPre(): Promise<void>;
|
|
290
|
+
} & {
|
|
291
|
+
load(): Promise<void>;
|
|
292
|
+
} & {
|
|
293
|
+
afterAttach(): void;
|
|
294
|
+
} & {
|
|
295
|
+
readonly initialized: boolean;
|
|
296
|
+
readonly regions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
297
|
+
readonly allRefNames: string[] | undefined;
|
|
298
|
+
readonly namesByCanonicalRefName: Map<string, string[]> | undefined;
|
|
299
|
+
readonly rpcManager: import("@jbrowse/core/rpc/RpcManager").default;
|
|
300
|
+
} & {
|
|
301
|
+
readonly refNames: string[] | undefined;
|
|
302
|
+
} & {
|
|
303
|
+
readonly refNameToIndex: Map<string, number> | undefined;
|
|
304
|
+
} & {
|
|
305
|
+
getCanonicalRefName(refName: string): string | undefined;
|
|
306
|
+
getRefNameColor(refName: string): string | undefined;
|
|
307
|
+
getRegionForRefName(refName: string): import("@jbrowse/core/assemblyManager/assembly").BasicRegion | undefined;
|
|
308
|
+
getGeneticCodeId(refName: string): number;
|
|
309
|
+
getSeqAdapterRefName(canonicalRefName: string): string;
|
|
310
|
+
} & {
|
|
311
|
+
getCanonicalRefName2(refName: string): string;
|
|
312
|
+
isValidRefName(refName: string): boolean;
|
|
313
|
+
} & {
|
|
314
|
+
getAliasesForRefName(refName: string): string[];
|
|
315
|
+
getRefNameMapForAdapter(adapterConf: {
|
|
316
|
+
[x: string]: unknown;
|
|
317
|
+
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
318
|
+
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
319
|
+
} & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("@jbrowse/mobx-state-tree").IModelType<{
|
|
320
|
+
configuration: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").IReferenceType<import("@jbrowse/mobx-state-tree").IAnyType>>;
|
|
321
|
+
}, {
|
|
322
|
+
error: unknown;
|
|
323
|
+
loadingP: Promise<void> | undefined;
|
|
324
|
+
adapterLoads: import("@jbrowse/quick-lru").default<string, Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>>;
|
|
325
|
+
volatileRegions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
326
|
+
refNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
327
|
+
canonicalToSeqAdapterRefNames: Record<string, string> | undefined;
|
|
328
|
+
cytobands: import("@jbrowse/core/util").Feature[] | undefined;
|
|
329
|
+
loadedGeneticCodes: Record<string, number> | undefined;
|
|
330
|
+
lowerCaseRefNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
331
|
+
statusMessage: string | undefined;
|
|
332
|
+
statusProgress: number | undefined;
|
|
333
|
+
statusSource: string | undefined;
|
|
334
|
+
refNameMismatches: Map<string, import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch>;
|
|
335
|
+
} & {
|
|
336
|
+
getConf(arg: string): any;
|
|
337
|
+
} & {
|
|
338
|
+
readonly name: string;
|
|
339
|
+
readonly aliases: string[];
|
|
340
|
+
readonly displayName: string;
|
|
341
|
+
readonly refNameColors: string[];
|
|
342
|
+
} & {
|
|
343
|
+
readonly allAliases: string[];
|
|
344
|
+
hasName(name: string): boolean;
|
|
345
|
+
} & {
|
|
346
|
+
setStatus(status?: import("@jbrowse/core/util").RpcStatus): void;
|
|
347
|
+
setRefNameMismatch(adapterCacheKey: string, mismatch: import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch): void;
|
|
348
|
+
} & {
|
|
349
|
+
setLoaded({ regions, refNameAliases, lowerCaseRefNameAliases, canonicalToSeqAdapterRefNames, cytobands, geneticCodes, }: import("@jbrowse/core/assemblyManager/assembly").RefNameMaps & {
|
|
350
|
+
regions: import("@jbrowse/core/util").Region[];
|
|
351
|
+
cytobands: import("@jbrowse/core/util").Feature[];
|
|
352
|
+
geneticCodes: Record<string, number>;
|
|
353
|
+
}): void;
|
|
354
|
+
setError(e: unknown): void;
|
|
355
|
+
setLoadingP(p?: Promise<void>): void;
|
|
356
|
+
loadPre(): Promise<void>;
|
|
357
|
+
} & {
|
|
358
|
+
load(): Promise<void>;
|
|
359
|
+
} & {
|
|
360
|
+
afterAttach(): void;
|
|
361
|
+
} & {
|
|
362
|
+
readonly initialized: boolean;
|
|
363
|
+
readonly regions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
364
|
+
readonly allRefNames: string[] | undefined;
|
|
365
|
+
readonly namesByCanonicalRefName: Map<string, string[]> | undefined;
|
|
366
|
+
readonly rpcManager: import("@jbrowse/core/rpc/RpcManager").default;
|
|
367
|
+
} & {
|
|
368
|
+
readonly refNames: string[] | undefined;
|
|
369
|
+
} & {
|
|
370
|
+
readonly refNameToIndex: Map<string, number> | undefined;
|
|
371
|
+
} & {
|
|
372
|
+
getCanonicalRefName(refName: string): string | undefined;
|
|
373
|
+
getRefNameColor(refName: string): string | undefined;
|
|
374
|
+
getRegionForRefName(refName: string): import("@jbrowse/core/assemblyManager/assembly").BasicRegion | undefined;
|
|
375
|
+
getGeneticCodeId(refName: string): number;
|
|
376
|
+
getSeqAdapterRefName(canonicalRefName: string): string;
|
|
377
|
+
} & {
|
|
378
|
+
getCanonicalRefName2(refName: string): string;
|
|
379
|
+
isValidRefName(refName: string): boolean;
|
|
380
|
+
} & {
|
|
381
|
+
getAliasesForRefName(refName: string): string[];
|
|
382
|
+
getRefNameMapForAdapter(adapterConf: {
|
|
383
|
+
[x: string]: unknown;
|
|
384
|
+
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
385
|
+
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
386
|
+
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
387
|
+
/**
|
|
388
|
+
* #getter
|
|
389
|
+
*/
|
|
79
390
|
readonly initialized: boolean;
|
|
391
|
+
/**
|
|
392
|
+
* #getter
|
|
393
|
+
*/
|
|
80
394
|
readonly hasDisplayedRegions: boolean;
|
|
81
|
-
|
|
395
|
+
/**
|
|
396
|
+
* #getter
|
|
397
|
+
* The assembly whose load the spinner is waiting on: the one `init` names
|
|
398
|
+
* before navigation (it isn't in assemblyNames yet), else the first of the
|
|
399
|
+
* displayed assemblies that hasn't finished loading.
|
|
400
|
+
*/
|
|
401
|
+
readonly loadingAssembly: (import("@jbrowse/mobx-state-tree").ModelInstanceTypeProps<{
|
|
402
|
+
configuration: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").IReferenceType<import("@jbrowse/mobx-state-tree").IAnyType>>;
|
|
403
|
+
}> & {
|
|
404
|
+
error: unknown;
|
|
405
|
+
loadingP: Promise<void> | undefined;
|
|
406
|
+
adapterLoads: import("@jbrowse/quick-lru").default<string, Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>>;
|
|
407
|
+
volatileRegions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
408
|
+
refNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
409
|
+
canonicalToSeqAdapterRefNames: Record<string, string> | undefined;
|
|
410
|
+
cytobands: import("@jbrowse/core/util").Feature[] | undefined;
|
|
411
|
+
loadedGeneticCodes: Record<string, number> | undefined;
|
|
412
|
+
lowerCaseRefNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
413
|
+
statusMessage: string | undefined;
|
|
414
|
+
statusProgress: number | undefined;
|
|
415
|
+
statusSource: string | undefined;
|
|
416
|
+
refNameMismatches: Map<string, import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch>;
|
|
417
|
+
} & {
|
|
418
|
+
getConf(arg: string): any;
|
|
419
|
+
} & {
|
|
420
|
+
readonly name: string;
|
|
421
|
+
readonly aliases: string[];
|
|
422
|
+
readonly displayName: string;
|
|
423
|
+
readonly refNameColors: string[];
|
|
424
|
+
} & {
|
|
425
|
+
readonly allAliases: string[];
|
|
426
|
+
hasName(name: string): boolean;
|
|
427
|
+
} & {
|
|
428
|
+
setStatus(status?: import("@jbrowse/core/util").RpcStatus): void;
|
|
429
|
+
setRefNameMismatch(adapterCacheKey: string, mismatch: import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch): void;
|
|
430
|
+
} & {
|
|
431
|
+
setLoaded({ regions, refNameAliases, lowerCaseRefNameAliases, canonicalToSeqAdapterRefNames, cytobands, geneticCodes, }: import("@jbrowse/core/assemblyManager/assembly").RefNameMaps & {
|
|
432
|
+
regions: import("@jbrowse/core/util").Region[];
|
|
433
|
+
cytobands: import("@jbrowse/core/util").Feature[];
|
|
434
|
+
geneticCodes: Record<string, number>;
|
|
435
|
+
}): void;
|
|
436
|
+
setError(e: unknown): void;
|
|
437
|
+
setLoadingP(p?: Promise<void>): void;
|
|
438
|
+
loadPre(): Promise<void>;
|
|
439
|
+
} & {
|
|
440
|
+
load(): Promise<void>;
|
|
441
|
+
} & {
|
|
442
|
+
afterAttach(): void;
|
|
443
|
+
} & {
|
|
444
|
+
readonly initialized: boolean;
|
|
445
|
+
readonly regions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
446
|
+
readonly allRefNames: string[] | undefined;
|
|
447
|
+
readonly namesByCanonicalRefName: Map<string, string[]> | undefined;
|
|
448
|
+
readonly rpcManager: import("@jbrowse/core/rpc/RpcManager").default;
|
|
449
|
+
} & {
|
|
450
|
+
readonly refNames: string[] | undefined;
|
|
451
|
+
} & {
|
|
452
|
+
readonly refNameToIndex: Map<string, number> | undefined;
|
|
453
|
+
} & {
|
|
454
|
+
getCanonicalRefName(refName: string): string | undefined;
|
|
455
|
+
getRefNameColor(refName: string): string | undefined;
|
|
456
|
+
getRegionForRefName(refName: string): import("@jbrowse/core/assemblyManager/assembly").BasicRegion | undefined;
|
|
457
|
+
getGeneticCodeId(refName: string): number;
|
|
458
|
+
getSeqAdapterRefName(canonicalRefName: string): string;
|
|
459
|
+
} & {
|
|
460
|
+
getCanonicalRefName2(refName: string): string;
|
|
461
|
+
isValidRefName(refName: string): boolean;
|
|
462
|
+
} & {
|
|
463
|
+
getAliasesForRefName(refName: string): string[];
|
|
464
|
+
getRefNameMapForAdapter(adapterConf: {
|
|
465
|
+
[x: string]: unknown;
|
|
466
|
+
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
467
|
+
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
468
|
+
} & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("@jbrowse/mobx-state-tree").IModelType<{
|
|
469
|
+
configuration: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").IReferenceType<import("@jbrowse/mobx-state-tree").IAnyType>>;
|
|
470
|
+
}, {
|
|
471
|
+
error: unknown;
|
|
472
|
+
loadingP: Promise<void> | undefined;
|
|
473
|
+
adapterLoads: import("@jbrowse/quick-lru").default<string, Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>>;
|
|
474
|
+
volatileRegions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
475
|
+
refNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
476
|
+
canonicalToSeqAdapterRefNames: Record<string, string> | undefined;
|
|
477
|
+
cytobands: import("@jbrowse/core/util").Feature[] | undefined;
|
|
478
|
+
loadedGeneticCodes: Record<string, number> | undefined;
|
|
479
|
+
lowerCaseRefNameAliases: import("@jbrowse/core/assemblyManager/assembly").RefNameAliases | undefined;
|
|
480
|
+
statusMessage: string | undefined;
|
|
481
|
+
statusProgress: number | undefined;
|
|
482
|
+
statusSource: string | undefined;
|
|
483
|
+
refNameMismatches: Map<string, import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch>;
|
|
484
|
+
} & {
|
|
485
|
+
getConf(arg: string): any;
|
|
486
|
+
} & {
|
|
487
|
+
readonly name: string;
|
|
488
|
+
readonly aliases: string[];
|
|
489
|
+
readonly displayName: string;
|
|
490
|
+
readonly refNameColors: string[];
|
|
491
|
+
} & {
|
|
492
|
+
readonly allAliases: string[];
|
|
493
|
+
hasName(name: string): boolean;
|
|
494
|
+
} & {
|
|
495
|
+
setStatus(status?: import("@jbrowse/core/util").RpcStatus): void;
|
|
496
|
+
setRefNameMismatch(adapterCacheKey: string, mismatch: import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch): void;
|
|
497
|
+
} & {
|
|
498
|
+
setLoaded({ regions, refNameAliases, lowerCaseRefNameAliases, canonicalToSeqAdapterRefNames, cytobands, geneticCodes, }: import("@jbrowse/core/assemblyManager/assembly").RefNameMaps & {
|
|
499
|
+
regions: import("@jbrowse/core/util").Region[];
|
|
500
|
+
cytobands: import("@jbrowse/core/util").Feature[];
|
|
501
|
+
geneticCodes: Record<string, number>;
|
|
502
|
+
}): void;
|
|
503
|
+
setError(e: unknown): void;
|
|
504
|
+
setLoadingP(p?: Promise<void>): void;
|
|
505
|
+
loadPre(): Promise<void>;
|
|
506
|
+
} & {
|
|
507
|
+
load(): Promise<void>;
|
|
508
|
+
} & {
|
|
509
|
+
afterAttach(): void;
|
|
510
|
+
} & {
|
|
511
|
+
readonly initialized: boolean;
|
|
512
|
+
readonly regions: import("@jbrowse/core/assemblyManager/assembly").BasicRegion[] | undefined;
|
|
513
|
+
readonly allRefNames: string[] | undefined;
|
|
514
|
+
readonly namesByCanonicalRefName: Map<string, string[]> | undefined;
|
|
515
|
+
readonly rpcManager: import("@jbrowse/core/rpc/RpcManager").default;
|
|
516
|
+
} & {
|
|
517
|
+
readonly refNames: string[] | undefined;
|
|
518
|
+
} & {
|
|
519
|
+
readonly refNameToIndex: Map<string, number> | undefined;
|
|
520
|
+
} & {
|
|
521
|
+
getCanonicalRefName(refName: string): string | undefined;
|
|
522
|
+
getRefNameColor(refName: string): string | undefined;
|
|
523
|
+
getRegionForRefName(refName: string): import("@jbrowse/core/assemblyManager/assembly").BasicRegion | undefined;
|
|
524
|
+
getGeneticCodeId(refName: string): number;
|
|
525
|
+
getSeqAdapterRefName(canonicalRefName: string): string;
|
|
526
|
+
} & {
|
|
527
|
+
getCanonicalRefName2(refName: string): string;
|
|
528
|
+
isValidRefName(refName: string): boolean;
|
|
529
|
+
} & {
|
|
530
|
+
getAliasesForRefName(refName: string): string[];
|
|
531
|
+
getRefNameMapForAdapter(adapterConf: {
|
|
532
|
+
[x: string]: unknown;
|
|
533
|
+
}, options: import("@jbrowse/core/data_adapters/BaseAdapter").BaseOptions): Promise<import("@jbrowse/core/assemblyManager/assembly").RefNameAliases>;
|
|
534
|
+
getRefNameMismatch(adapterCacheKey: string): import("@jbrowse/core/assemblyManager/assembly").RefNameMismatch | undefined;
|
|
535
|
+
}, import("@jbrowse/mobx-state-tree")._NotCustomized, import("@jbrowse/mobx-state-tree")._NotCustomized>>) | undefined;
|
|
536
|
+
/**
|
|
537
|
+
* #getter
|
|
538
|
+
* What the spinner says. The assembly reports which of its files it is
|
|
539
|
+
* downloading, so this is "Downloading chromosome aliases" rather than a bare
|
|
540
|
+
* "Loading" for the part of startup that actually takes time. Falls back
|
|
541
|
+
* once the assembly is loaded and the remaining wait is the init autorun's
|
|
542
|
+
* own navigation, which is local.
|
|
543
|
+
*/
|
|
544
|
+
readonly loadingMessage: string | undefined;
|
|
545
|
+
/**
|
|
546
|
+
* #getter
|
|
547
|
+
* Determinate fraction for the spinner's bar, when the assembly load
|
|
548
|
+
* reports one (a whole-file download with a Content-Length)
|
|
549
|
+
*/
|
|
550
|
+
readonly loadingProgress: number | undefined;
|
|
551
|
+
/**
|
|
552
|
+
* #getter
|
|
553
|
+
* The URL the assembly load is currently fetching, when the phase named
|
|
554
|
+
* one. Only the stalled-load notice reads it — see
|
|
555
|
+
* {@link ViewLoadingScreen}.
|
|
556
|
+
*/
|
|
557
|
+
readonly loadingSource: string | undefined;
|
|
558
|
+
/**
|
|
559
|
+
* #getter
|
|
560
|
+
*/
|
|
82
561
|
readonly hasSomethingToShow: boolean;
|
|
562
|
+
/**
|
|
563
|
+
* #getter
|
|
564
|
+
* init is set but its async navigation (the afterAttach autorun) hasn't
|
|
565
|
+
* populated displayedRegions yet. `initialized` can already be true here
|
|
566
|
+
* (it only tracks assembly readiness), so without this the container
|
|
567
|
+
* would mount over empty regions and pxToBp/hover would throw.
|
|
568
|
+
*
|
|
569
|
+
* **Not dotplot's or synteny's `initPending`**, which is the bare
|
|
570
|
+
* `!!self.init` — "an init blob has not been applied" — and which those
|
|
571
|
+
* views read from their `settled` gate rather than from `showLoading`.
|
|
572
|
+
* This one is narrower on purpose: it closes only the window where there
|
|
573
|
+
* is nothing on screen. Once navigation has produced regions the view is
|
|
574
|
+
* usable and gets shown, even though `init` is still set while the tracks
|
|
575
|
+
* and highlights land. Renamed away from the shared spelling because the
|
|
576
|
+
* two predicates disagree exactly there, and the bare name reads as
|
|
577
|
+
* theirs.
|
|
578
|
+
*/
|
|
579
|
+
readonly awaitingInitNavigation: boolean;
|
|
580
|
+
/**
|
|
581
|
+
* #getter
|
|
582
|
+
* Whether to show a loading indicator instead of the import form or view
|
|
583
|
+
*/
|
|
83
584
|
readonly showLoading: boolean;
|
|
585
|
+
/**
|
|
586
|
+
* #getter
|
|
587
|
+
* Whether to show the import form
|
|
588
|
+
*/
|
|
84
589
|
readonly showImportForm: boolean;
|
|
590
|
+
/**
|
|
591
|
+
* #getter
|
|
592
|
+
* Is there anything to draw yet? The gate anything reading block geometry
|
|
593
|
+
* — a ruler, a scalebar, a display — has to pass first, because
|
|
594
|
+
* `width`/`staticBlocks` throw by design before the view has been
|
|
595
|
+
* measured and navigated.
|
|
596
|
+
*
|
|
597
|
+
* **Not `initialized`**, which is the trap this getter exists to close.
|
|
598
|
+
* That one answers "have the assembly's regions loaded", which is only
|
|
599
|
+
* the first of two async steps: navigating then populates
|
|
600
|
+
* `displayedRegions`, and in the window between the two `initialized` is
|
|
601
|
+
* already true while there is still nothing on screen. `showLoading`
|
|
602
|
+
* folds in `awaitingInitNavigation`, the getter that exists for exactly
|
|
603
|
+
* that gap.
|
|
604
|
+
*
|
|
605
|
+
* `error` is the third outcome and is why this is not a bare
|
|
606
|
+
* `!showLoading`: a failed assembly load also ends the loading state, so
|
|
607
|
+
* that alone would mount over the wreckage. Read `error` yourself if you
|
|
608
|
+
* want to draw it.
|
|
609
|
+
*/
|
|
610
|
+
readonly ready: boolean;
|
|
611
|
+
/**
|
|
612
|
+
* #getter
|
|
613
|
+
* The same question as `ready` with the other three outcomes named, for a
|
|
614
|
+
* host that draws its own chrome and has to render all four. See
|
|
615
|
+
* `computeViewStatus`, whose precedence this defers to — and note its
|
|
616
|
+
* `ready` is narrower than the getter above, which is true when nothing
|
|
617
|
+
* has told the view where to look.
|
|
618
|
+
*/
|
|
619
|
+
readonly status: ViewStatus;
|
|
620
|
+
/**
|
|
621
|
+
* #getter
|
|
622
|
+
*/
|
|
85
623
|
readonly scalebarHeight: number;
|
|
624
|
+
/**
|
|
625
|
+
* #getter
|
|
626
|
+
* What TrackContainer puts *above* a track's rendering container: the gap
|
|
627
|
+
* over its Paper, and the Paper's own top border when outlines are on.
|
|
628
|
+
*/
|
|
629
|
+
readonly trackLeadingChrome: number;
|
|
630
|
+
/**
|
|
631
|
+
* #getter
|
|
632
|
+
* ...and what it puts below: the resize divider, plus the matching bottom
|
|
633
|
+
* border.
|
|
634
|
+
*/
|
|
635
|
+
readonly trackTrailingChrome: number;
|
|
636
|
+
/**
|
|
637
|
+
* #getter
|
|
638
|
+
* A track's full cost beyond its display height.
|
|
639
|
+
*
|
|
640
|
+
* The track *label* is not counted, and cannot be: an offset label is an
|
|
641
|
+
* in-flow box whose height is whatever the theme renders a Paper of icon
|
|
642
|
+
* buttons at — 31.140625px on the stock theme, and not a number this file
|
|
643
|
+
* can derive. So these getters are exact while labels are hidden or
|
|
644
|
+
* overlapping, and short by one label box per labelled track otherwise.
|
|
645
|
+
* Anything needing the offset to the pixel with labels showing measures
|
|
646
|
+
* the DOM; `BreakpointSplitViewOverlay` does, and falls back to this
|
|
647
|
+
* arithmetic only for a track with no mounted div.
|
|
648
|
+
*/
|
|
649
|
+
readonly trackChromeHeight: number;
|
|
650
|
+
/**
|
|
651
|
+
* #getter
|
|
652
|
+
*/
|
|
86
653
|
readonly headerHeight: number;
|
|
654
|
+
/**
|
|
655
|
+
* #getter
|
|
656
|
+
* Where the scalebar pins when the view's chrome is sticky: everything
|
|
657
|
+
* stacked above it, which is the view's own title bar plus this view's
|
|
658
|
+
* header. Expressed from `headerHeight` rather than re-summing its
|
|
659
|
+
* constants — the two are the same box, and a second spelling of the sum
|
|
660
|
+
* is free to drift from the first while both typecheck.
|
|
661
|
+
*/
|
|
662
|
+
readonly rubberbandTop: number;
|
|
663
|
+
/**
|
|
664
|
+
* #getter
|
|
665
|
+
*/
|
|
666
|
+
readonly pinnedTracksTop: number;
|
|
667
|
+
/**
|
|
668
|
+
* #method
|
|
669
|
+
* rendered height of a single track, collapsing to a fixed height when
|
|
670
|
+
* minimized. Shared by trackHeights and getTrackYOffset so the two can't
|
|
671
|
+
* disagree. Reads `activeDisplay` — the display TrackContainer actually
|
|
672
|
+
* mounts — rather than re-picking `displays[0]`, so the view's height math
|
|
673
|
+
* can't diverge from what is on screen.
|
|
674
|
+
*/
|
|
675
|
+
trackHeight(track: (import("@jbrowse/mobx-state-tree").IMSTArray<import("@jbrowse/mobx-state-tree").IAnyType> & import("@jbrowse/mobx-state-tree").IStateTreeNode<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyType>>)[number]): any;
|
|
676
|
+
/**
|
|
677
|
+
* #getter
|
|
678
|
+
*/
|
|
87
679
|
readonly trackHeights: number;
|
|
88
|
-
|
|
680
|
+
/**
|
|
681
|
+
* #getter
|
|
682
|
+
*/
|
|
683
|
+
readonly trackHeightsWithChrome: number;
|
|
684
|
+
/**
|
|
685
|
+
* #getter
|
|
686
|
+
*/
|
|
89
687
|
readonly height: number;
|
|
688
|
+
/**
|
|
689
|
+
* #method
|
|
690
|
+
* Y offset (in pixels, from the top of the view) where a track's
|
|
691
|
+
* rendering container starts. Walks tracks in DOM render order (pinned
|
|
692
|
+
* first, then unpinned), from the same constants TrackContainer lays its
|
|
693
|
+
* Paper out with. Returns `undefined` if the track is not present.
|
|
694
|
+
*
|
|
695
|
+
* Exact while track labels are hidden or overlapping. With an offset
|
|
696
|
+
* label the answer is short by one label box per labelled track above
|
|
697
|
+
* this one — see `trackChromeHeight` for why that box is not derivable
|
|
698
|
+
* here.
|
|
699
|
+
*/
|
|
700
|
+
getTrackYOffset(trackId: string): number | undefined;
|
|
701
|
+
/**
|
|
702
|
+
* #method
|
|
703
|
+
* the pinned or unpinned sibling list a track renders within; move
|
|
704
|
+
* up/down/top/bottom reorder inside this section rather than the full
|
|
705
|
+
* `tracks` array, since the two sections lay out independently
|
|
706
|
+
*/
|
|
707
|
+
trackSection(id: string): any[];
|
|
708
|
+
/**
|
|
709
|
+
* #getter
|
|
710
|
+
*/
|
|
90
711
|
readonly totalBp: number;
|
|
91
|
-
|
|
92
|
-
|
|
712
|
+
/**
|
|
713
|
+
* #getter
|
|
714
|
+
*/
|
|
715
|
+
readonly fitBpPerPx: number;
|
|
716
|
+
/**
|
|
717
|
+
* #getter
|
|
718
|
+
* The zoom-out limit. This view's own fit, except while a container holds
|
|
719
|
+
* it on a shared scale coarser than that — a small genome next to a large
|
|
720
|
+
* one, drawn short so the two compare by length.
|
|
721
|
+
*
|
|
722
|
+
* Raising the LIMIT is what makes such a scale survive: written past the
|
|
723
|
+
* limit instead, it is undone by the first thing that clamps — a wheel
|
|
724
|
+
* tick, a rubberband, a `setDisplayedRegions` — which is how the dotplot's
|
|
725
|
+
* locked aspect ratio once turned "zoom out" into a zoom in
|
|
726
|
+
* (`axisMaxBpPerPx`). Here every route to a zoom clamps against the same
|
|
727
|
+
* ceiling, so full zoom-out LANDS on the shared scale.
|
|
728
|
+
*/
|
|
93
729
|
readonly maxBpPerPx: number;
|
|
730
|
+
/**
|
|
731
|
+
* #getter
|
|
732
|
+
* The zoom-out ceiling a containing comparative view holds this row to,
|
|
733
|
+
* or 0 for a standalone view, a mode that is off, and a stack that cannot
|
|
734
|
+
* answer yet.
|
|
735
|
+
*
|
|
736
|
+
* Pulled rather than pushed down into a volatile: the number is a
|
|
737
|
+
* function of every row's fit, all of which move on a resize, and a
|
|
738
|
+
* stored copy would be stale by the next layout.
|
|
739
|
+
*/
|
|
740
|
+
readonly sharedFitBpPerPx: number;
|
|
741
|
+
/**
|
|
742
|
+
* #getter
|
|
743
|
+
*/
|
|
94
744
|
readonly minBpPerPx: number;
|
|
745
|
+
/**
|
|
746
|
+
* #getter
|
|
747
|
+
*/
|
|
95
748
|
readonly error: unknown;
|
|
749
|
+
/**
|
|
750
|
+
* #getter
|
|
751
|
+
*/
|
|
96
752
|
readonly maxOffset: number;
|
|
753
|
+
/**
|
|
754
|
+
* #getter
|
|
755
|
+
*/
|
|
97
756
|
readonly minOffset: number;
|
|
757
|
+
/**
|
|
758
|
+
* #getter
|
|
759
|
+
* Whether the displayed regions read left-to-right, right-to-left, or
|
|
760
|
+
* some of each. `horizontallyFlip` reverses the order and flips every
|
|
761
|
+
* region at once, so a flipped row is uniformly `reversed` and `mixed`
|
|
762
|
+
* takes going out of your way — the scalebar label menu's per-region
|
|
763
|
+
* "Reverse region". Read off `displayedRegions` rather than off blocks
|
|
764
|
+
* because blocks cover the window and this is a fact about the row.
|
|
765
|
+
*/
|
|
766
|
+
readonly displayedRegionsOrientation: import("./util.ts").RegionsOrientation;
|
|
767
|
+
/**
|
|
768
|
+
* #getter
|
|
769
|
+
*/
|
|
98
770
|
readonly displayedRegionsTotalPx: number;
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
771
|
+
/**
|
|
772
|
+
* #getter
|
|
773
|
+
*/
|
|
774
|
+
readonly trackMap: Map<string, any>;
|
|
775
|
+
/**
|
|
776
|
+
* #method
|
|
777
|
+
*/
|
|
106
778
|
getTrack(id: string): any;
|
|
107
|
-
|
|
108
|
-
|
|
779
|
+
/**
|
|
780
|
+
* #method
|
|
781
|
+
* displayId of the active (shown) display for a track in this view, used
|
|
782
|
+
* by the config editor to expand the relevant display and collapse the
|
|
783
|
+
* track's other displays
|
|
784
|
+
*/
|
|
785
|
+
getActiveDisplayId(trackId: string): string | undefined;
|
|
109
786
|
} & {
|
|
787
|
+
/**
|
|
788
|
+
* #action
|
|
789
|
+
*/
|
|
110
790
|
setShowTrackOutlines(arg: boolean): void;
|
|
791
|
+
/**
|
|
792
|
+
* #action
|
|
793
|
+
*/
|
|
794
|
+
setScrollZoom(flag: boolean): void;
|
|
795
|
+
/**
|
|
796
|
+
* #action
|
|
797
|
+
*/
|
|
111
798
|
setColorByCDS(flag: boolean): void;
|
|
799
|
+
/**
|
|
800
|
+
* #action
|
|
801
|
+
*/
|
|
802
|
+
setShowAminoAcids(flag: boolean): void;
|
|
803
|
+
/**
|
|
804
|
+
* #action
|
|
805
|
+
*/
|
|
112
806
|
setShowCytobands(flag: boolean): void;
|
|
807
|
+
/**
|
|
808
|
+
* #action
|
|
809
|
+
*/
|
|
113
810
|
setWidth(newWidth: number): void;
|
|
811
|
+
/**
|
|
812
|
+
* #action
|
|
813
|
+
*/
|
|
114
814
|
setError(error: unknown): void;
|
|
815
|
+
/**
|
|
816
|
+
* #action
|
|
817
|
+
*/
|
|
115
818
|
setIsScalebarRefNameMenuOpen(isOpen: boolean): void;
|
|
819
|
+
/**
|
|
820
|
+
* #action
|
|
821
|
+
*/
|
|
116
822
|
setScalebarRefNameClickPending(pending: boolean): void;
|
|
823
|
+
/**
|
|
824
|
+
* #action
|
|
825
|
+
*/
|
|
117
826
|
setHideHeader(b: boolean): void;
|
|
827
|
+
/**
|
|
828
|
+
* #action
|
|
829
|
+
*/
|
|
118
830
|
setHideHeaderOverview(b: boolean): void;
|
|
831
|
+
/**
|
|
832
|
+
* #action
|
|
833
|
+
*/
|
|
834
|
+
setScalebarOnly(b: boolean): void;
|
|
835
|
+
/**
|
|
836
|
+
* #action
|
|
837
|
+
*/
|
|
119
838
|
setHideNoTracksActive(b: boolean): void;
|
|
839
|
+
/**
|
|
840
|
+
* #action
|
|
841
|
+
*/
|
|
120
842
|
setShowGridlines(b: boolean): void;
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
updateHighlight(old: HighlightType, updates: Partial<HighlightType>): void;
|
|
125
|
-
setHighlightsVisible(arg: boolean): void;
|
|
843
|
+
/**
|
|
844
|
+
* #action
|
|
845
|
+
*/
|
|
126
846
|
setLabelsVisible(arg: boolean): void;
|
|
847
|
+
/**
|
|
848
|
+
* #action
|
|
849
|
+
* set temporary vertical guides (e.g., for LD display hover)
|
|
850
|
+
*/
|
|
127
851
|
setVolatileGuides(guides: VolatileGuide[]): void;
|
|
852
|
+
/**
|
|
853
|
+
* #action
|
|
854
|
+
*/
|
|
128
855
|
scrollTo(offsetPx: number): number;
|
|
129
|
-
|
|
856
|
+
/**
|
|
857
|
+
* #action
|
|
858
|
+
* `scrollTo`'s bp-space twin: place the window's left edge at a
|
|
859
|
+
* linearized bp coordinate, clamped to the same scroll limits.
|
|
860
|
+
*
|
|
861
|
+
* It exists so a caller that already knows where it wants to be in bp —
|
|
862
|
+
* zoomTo, anchoring the base under the cursor — does not have to convert
|
|
863
|
+
* to pixels and let this convert back. That round trip is lossy once per
|
|
864
|
+
* frame, and a scroll-zoom burst is a few dozen frames, which is enough
|
|
865
|
+
* to walk the base out from under the cursor.
|
|
866
|
+
*/
|
|
867
|
+
scrollToBp(startBp: number): number;
|
|
868
|
+
/**
|
|
869
|
+
* #action
|
|
870
|
+
*/
|
|
871
|
+
zoomTo(bpPerPx: number, offset?: any): number;
|
|
872
|
+
/**
|
|
873
|
+
* #action
|
|
874
|
+
* sets offsets of rubberband, used in the get sequence dialog can call
|
|
875
|
+
* view.getSelectedRegions(view.leftOffset,view.rightOffset) to compute
|
|
876
|
+
* the selected regions from the offsets
|
|
877
|
+
*/
|
|
130
878
|
setOffsets(left?: BpOffset, right?: BpOffset): void;
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
879
|
+
/**
|
|
880
|
+
* #action
|
|
881
|
+
*/
|
|
882
|
+
setSearchResults(searchResults: BaseResult[], searchQuery: string, assemblyName: string): void;
|
|
883
|
+
/**
|
|
884
|
+
* #action
|
|
885
|
+
*/
|
|
886
|
+
showTrack(trackId: string, initialSnapshot?: any, displayInitialSnapshot?: any, inlineConf?: Record<string, unknown>): any;
|
|
887
|
+
/**
|
|
888
|
+
* #action
|
|
889
|
+
*/
|
|
890
|
+
hideTrack(trackId: string): boolean;
|
|
136
891
|
} & {
|
|
892
|
+
/**
|
|
893
|
+
* #action
|
|
894
|
+
*/
|
|
137
895
|
moveTrackDown(id: string): void;
|
|
896
|
+
/**
|
|
897
|
+
* #action
|
|
898
|
+
*/
|
|
138
899
|
moveTrackUp(id: string): void;
|
|
900
|
+
/**
|
|
901
|
+
* #action
|
|
902
|
+
*/
|
|
139
903
|
moveTrackToTop(id: string): void;
|
|
904
|
+
/**
|
|
905
|
+
* #action
|
|
906
|
+
*/
|
|
140
907
|
moveTrackToBottom(id: string): void;
|
|
908
|
+
/**
|
|
909
|
+
* #action
|
|
910
|
+
*/
|
|
141
911
|
moveTrack(movingId: string, targetId: string): void;
|
|
142
|
-
|
|
143
|
-
|
|
912
|
+
/**
|
|
913
|
+
* #action
|
|
914
|
+
*/
|
|
915
|
+
toggleTrack(trackId: string): boolean;
|
|
916
|
+
/**
|
|
917
|
+
* #action
|
|
918
|
+
*/
|
|
919
|
+
setTrackLabels(setting: 'overlapping' | 'offset' | 'hidden'): void;
|
|
920
|
+
/**
|
|
921
|
+
* #action
|
|
922
|
+
*/
|
|
144
923
|
setShowCenterLine(b: boolean): void;
|
|
145
|
-
|
|
924
|
+
/**
|
|
925
|
+
* #action
|
|
926
|
+
*/
|
|
146
927
|
activateTrackSelector(): import("@jbrowse/core/util").Widget;
|
|
928
|
+
/**
|
|
929
|
+
* #action
|
|
930
|
+
*/
|
|
931
|
+
toggleTrackSelector(): import("@jbrowse/core/util").Widget;
|
|
932
|
+
/**
|
|
933
|
+
* #method
|
|
934
|
+
* Helper method for the fetchSequence.
|
|
935
|
+
* Retrieves the corresponding regions that were selected by the
|
|
936
|
+
* rubberband
|
|
937
|
+
*
|
|
938
|
+
* @param leftOffset - `object as {start, end, index, offset}`, offset = start
|
|
939
|
+
* of user drag
|
|
940
|
+
* @param rightOffset - `object as {start, end, index, offset}`,
|
|
941
|
+
* offset = end of user drag
|
|
942
|
+
* @returns array of Region[]
|
|
943
|
+
*/
|
|
147
944
|
getSelectedRegions(leftOffset?: BpOffset, rightOffset?: BpOffset): {
|
|
148
945
|
assemblyName: string;
|
|
149
946
|
refName: string;
|
|
150
947
|
start: number;
|
|
151
948
|
end: number;
|
|
152
949
|
}[];
|
|
950
|
+
/**
|
|
951
|
+
* #action
|
|
952
|
+
*/
|
|
153
953
|
horizontalScroll(distance: number): number;
|
|
154
|
-
|
|
155
|
-
|
|
954
|
+
/**
|
|
955
|
+
* #action
|
|
956
|
+
*/
|
|
156
957
|
setDraggingTrackId(idx?: string): void;
|
|
958
|
+
/**
|
|
959
|
+
* #action
|
|
960
|
+
*/
|
|
157
961
|
setLastTrackDragY(y: number): void;
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
962
|
+
/**
|
|
963
|
+
* #action
|
|
964
|
+
* called while dragging a track over the track at `targetId`; reorders
|
|
965
|
+
* once the cursor has moved far enough (see shouldSwapTracks) to avoid
|
|
966
|
+
* jitter when a short track is dragged over a tall one
|
|
967
|
+
*/
|
|
968
|
+
onTrackDragOver(targetId: string, currentY: number): void;
|
|
969
|
+
/**
|
|
970
|
+
* #action
|
|
971
|
+
*/
|
|
161
972
|
setInit(arg?: InitState): void;
|
|
973
|
+
/**
|
|
974
|
+
* #method
|
|
975
|
+
* creates an svg export and save using FileSaver
|
|
976
|
+
*/
|
|
162
977
|
exportSvg(opts?: ExportSvgOptions): Promise<void>;
|
|
163
978
|
} & {
|
|
164
979
|
slide: (viewWidths: number) => void;
|
|
165
|
-
} & {
|
|
166
980
|
zoom: (targetBpPerPx: number) => void;
|
|
981
|
+
cancelZoomAnimation: () => void;
|
|
167
982
|
} & {
|
|
983
|
+
/**
|
|
984
|
+
* #getter
|
|
985
|
+
*/
|
|
986
|
+
readonly showsWholeChromosome: boolean;
|
|
987
|
+
/**
|
|
988
|
+
* #getter
|
|
989
|
+
* an ideogram only reads correctly against an entire chromosome: on a
|
|
990
|
+
* sub-region it is a meaningless slice of bands, and the centromere shows
|
|
991
|
+
* up as a lone half-triangle
|
|
992
|
+
*/
|
|
168
993
|
readonly canShowCytobands: boolean;
|
|
169
|
-
|
|
994
|
+
/**
|
|
995
|
+
* #getter
|
|
996
|
+
* the `showCytobands` setting gated by whether cytobands can be shown at
|
|
997
|
+
* all (whole chromosome + data present) — i.e. actually on screen
|
|
998
|
+
*/
|
|
999
|
+
readonly effectiveShowCytobands: boolean;
|
|
1000
|
+
/**
|
|
1001
|
+
* #getter
|
|
1002
|
+
*/
|
|
170
1003
|
readonly anyCytobandsExist: boolean;
|
|
1004
|
+
/**
|
|
1005
|
+
* #getter
|
|
1006
|
+
* the cytoband is displayed to the right of the chromosome name, and
|
|
1007
|
+
* that offset is calculated manually with this method
|
|
1008
|
+
*/
|
|
171
1009
|
readonly cytobandOffset: number;
|
|
1010
|
+
/**
|
|
1011
|
+
* #getter
|
|
1012
|
+
*/
|
|
1013
|
+
readonly isTrackSelectorOpen: boolean;
|
|
172
1014
|
} & {
|
|
1015
|
+
/**
|
|
1016
|
+
* #method
|
|
1017
|
+
* return the view menu items
|
|
1018
|
+
*/
|
|
173
1019
|
menuItems(): MenuItem[];
|
|
1020
|
+
/**
|
|
1021
|
+
* #method
|
|
1022
|
+
* what a plugin can start from the selected region — a synteny view, a
|
|
1023
|
+
* consensus call. Extend this rather than `rubberBandMenuItems` so the
|
|
1024
|
+
* entries collect under the menu's "Launch" submenu; that grouping is
|
|
1025
|
+
* decided once here rather than by whichever contributor runs first, and
|
|
1026
|
+
* keeps the rubberband menu itself short as plugins pile on.
|
|
1027
|
+
*/
|
|
1028
|
+
rubberBandLaunchMenuItems(): MenuItem[];
|
|
1029
|
+
/**
|
|
1030
|
+
* #getter
|
|
1031
|
+
* geometry of the overview scalebar — derived from displayedRegions,
|
|
1032
|
+
* width, and cytobandOffset so it stays cached by MobX
|
|
1033
|
+
*/
|
|
1034
|
+
readonly overviewLayout: ViewLayout;
|
|
174
1035
|
} & {
|
|
1036
|
+
/**
|
|
1037
|
+
* #getter
|
|
1038
|
+
* static blocks are an important concept jbrowse uses to avoid
|
|
1039
|
+
* re-rendering when you scroll to the side. when you horizontally
|
|
1040
|
+
* scroll to the right, old blocks to the left may be removed, and new
|
|
1041
|
+
* blocks may be instantiated on the right. tracks may use the static
|
|
1042
|
+
* blocks to render their data for the region represented by the block
|
|
1043
|
+
*/
|
|
175
1044
|
readonly staticBlocks: BlockSet;
|
|
1045
|
+
/**
|
|
1046
|
+
* #getter
|
|
1047
|
+
* dynamic blocks represent the exact coordinates of the currently
|
|
1048
|
+
* visible genome regions on the screen. they are similar to static
|
|
1049
|
+
* blocks, but static blocks can go offscreen while dynamic blocks
|
|
1050
|
+
* represent exactly what is on screen
|
|
1051
|
+
*/
|
|
176
1052
|
readonly dynamicBlocks: BlockSet;
|
|
177
|
-
|
|
1053
|
+
/**
|
|
1054
|
+
* #getter
|
|
1055
|
+
* all overview scalebar blocks (content + elided), laid out on the
|
|
1056
|
+
* overviewLayout. memoized so the scalebar doesn't recompute it per
|
|
1057
|
+
* render
|
|
1058
|
+
*/
|
|
1059
|
+
readonly overviewBlocks: import("@jbrowse/core/util/blockTypes").BaseBlock[];
|
|
1060
|
+
/**
|
|
1061
|
+
* #getter
|
|
1062
|
+
* leading/trailing pixel span of the visible regions projected onto the
|
|
1063
|
+
* overviewLayout — the geometry of the overview's "you are here"
|
|
1064
|
+
* rectangle, and of the top edge of the polygon drawn under it. Elided
|
|
1065
|
+
* regions count: at whole-genome zoom the tail of an assembly is all
|
|
1066
|
+
* coalesced tiny contigs, and stopping at the last *content* block left
|
|
1067
|
+
* the rectangle short of (or, scrolled onto that tail, absent from) the
|
|
1068
|
+
* polygon it sits on.
|
|
1069
|
+
*/
|
|
1070
|
+
readonly overviewRegionPxSpan: import("@jbrowse/core/util/Base1DUtils").PxSpan | undefined;
|
|
1071
|
+
/**
|
|
1072
|
+
* #getter
|
|
1073
|
+
* The x shift that maps the **staticBlocks frame** onto the viewport:
|
|
1074
|
+
* `translateX(view.staticBlocksTranslateX)` on one container places
|
|
1075
|
+
* every `gridlineTicks`, `scalebarLabels` and `paddingSpans` entry at
|
|
1076
|
+
* once, and a pan then moves that single transform rather than each
|
|
1077
|
+
* child.
|
|
1078
|
+
*
|
|
1079
|
+
* The frame exists because those three are laid out across every
|
|
1080
|
+
* displayed region rather than across the viewport — it overhangs on
|
|
1081
|
+
* both sides — so their `x` values are stable under a scroll and only
|
|
1082
|
+
* this number moves. `scalebarRefNameLabels` is the exception and says
|
|
1083
|
+
* so: its `transform` is already a screen x, because a sticky label's
|
|
1084
|
+
* position is a function of the scroll rather than of block geometry.
|
|
1085
|
+
*
|
|
1086
|
+
* **The subtraction must happen here, in float64, and that is the
|
|
1087
|
+
* load-bearing part.** `offsetPx` is a whole-genome pixel coordinate —
|
|
1088
|
+
* hg38 chr1 at base resolution is already past 1e10 — and a length that
|
|
1089
|
+
* size does not survive the trip through CSS: the transform matrix is
|
|
1090
|
+
* float32 by the time it reaches the compositor, where consecutive
|
|
1091
|
+
* representable values at 1e10 are ~1024px apart, and layout saturates
|
|
1092
|
+
* sooner still (Blink's `LayoutUnit` is int32 at 1/64px, so ±33.5M px).
|
|
1093
|
+
* So the shape that looks obvious — lay an overlay out in absolute
|
|
1094
|
+
* genome pixels, write `translateX(-view.offsetPx)` — does not lose a
|
|
1095
|
+
* subpixel, it puts the row somewhere else entirely, and only on large
|
|
1096
|
+
* assemblies at high zoom, which is not where anyone tests. Both
|
|
1097
|
+
* operands here are large and their difference is bounded by the
|
|
1098
|
+
* overhang (a block or two), so what reaches CSS is small and exact.
|
|
1099
|
+
* Same rule as the GPU side, one layer up —
|
|
1100
|
+
* `agent-docs/reference/BP_PRECISION.md`.
|
|
1101
|
+
*
|
|
1102
|
+
* Published because it is the one piece of coordinate arithmetic a host
|
|
1103
|
+
* drawing its own chrome would otherwise have to know, and because
|
|
1104
|
+
* having it written out at each call site is how the two in-tree copies
|
|
1105
|
+
* came to disagree about rounding. Round it where the content is text
|
|
1106
|
+
* (a fractional offset blurs a label); leave it alone for paths and
|
|
1107
|
+
* boxes.
|
|
1108
|
+
*/
|
|
1109
|
+
readonly staticBlocksTranslateX: number;
|
|
1110
|
+
/**
|
|
1111
|
+
* #getter
|
|
1112
|
+
* Gridline tick positions (x relative to the staticBlocks frame),
|
|
1113
|
+
* derived from staticBlocks + bpPerPx. Computed once and shared by every
|
|
1114
|
+
* Gridlines instance (scalebar, main view, each pinned track) rather
|
|
1115
|
+
* than recomputing the makeTicks loop per component.
|
|
1116
|
+
*/
|
|
1117
|
+
readonly gridlineTicks: {
|
|
1118
|
+
x: number;
|
|
1119
|
+
major: boolean;
|
|
1120
|
+
}[];
|
|
1121
|
+
/**
|
|
1122
|
+
* #getter
|
|
1123
|
+
* Scalebar coordinate labels (x in the staticBlocks frame + display
|
|
1124
|
+
* text). Sibling of gridlineTicks sharing the same makeBlockTicks
|
|
1125
|
+
* formula, so labels line up exactly with their gridlines. staticBlocks
|
|
1126
|
+
* chop a region into ~800px chunks; groupContiguousBlocks merges them
|
|
1127
|
+
* back per region so a label on an internal chunk boundary isn't clipped
|
|
1128
|
+
* away by both neighbors — only genuine region edges clip a label.
|
|
1129
|
+
*
|
|
1130
|
+
* A run that can hold too few labels to make a ruler goes unnumbered
|
|
1131
|
+
* (`tickLabelsWorthDrawing`), the same rule the overview scalebar and
|
|
1132
|
+
* the dotplot axes apply: with a whole genome displayed each chromosome
|
|
1133
|
+
* catches one lone coordinate, which conveys no scale by itself and
|
|
1134
|
+
* reads as the same number repeated across the row.
|
|
1135
|
+
*/
|
|
1136
|
+
readonly scalebarLabels: {
|
|
1137
|
+
x: number;
|
|
1138
|
+
label: string;
|
|
1139
|
+
key: string;
|
|
1140
|
+
}[];
|
|
1141
|
+
/**
|
|
1142
|
+
* #getter
|
|
1143
|
+
* The bold refName labels drawn along the scalebar, as plain data:
|
|
1144
|
+
* `{key, refName, displayedRegionIndex, lastDisplayedRegionIndex,
|
|
1145
|
+
* sticky, transform, maxWidth, paddingLeft, text}` each. One per run of
|
|
1146
|
+
* same-refName regions, plus a "sticky" one pinned to the viewport's
|
|
1147
|
+
* left edge naming the refName under it, so panning into a chromosome
|
|
1148
|
+
* does not scroll its own name off the screen.
|
|
1149
|
+
*
|
|
1150
|
+
* Three rules live in here that a host drawing region names will
|
|
1151
|
+
* otherwise rediscover the hard way, and two of them are invisible until
|
|
1152
|
+
* the data is awkward:
|
|
1153
|
+
*
|
|
1154
|
+
* - the sticky label rides the rightmost run that has scrolled off the
|
|
1155
|
+
* left, not the region's first block — that one is gone from
|
|
1156
|
+
* staticBlocks entirely once you zoom into a region's interior, taking
|
|
1157
|
+
* the chromosome name off screen at exactly the zoom where nothing
|
|
1158
|
+
* else names it.
|
|
1159
|
+
* - adjacent regions of the same refName (collapsed introns) get one
|
|
1160
|
+
* label between them, not one each. That label names the whole run and
|
|
1161
|
+
* is fitted to the whole run, and `displayedRegionIndex` /
|
|
1162
|
+
* `lastDisplayedRegionIndex` bracket what it stands for.
|
|
1163
|
+
* - a name is drawn whole or not at all, measured against the space its
|
|
1164
|
+
* run leaves. Clipped to its own width, `chr16` reads as `chr1` —
|
|
1165
|
+
* a different chromosome rather than a shortened name, which is why
|
|
1166
|
+
* this is a fit test rather than an ellipsis.
|
|
1167
|
+
*
|
|
1168
|
+
* **Viewport frame, unlike its siblings.** `transform` is a screen x,
|
|
1169
|
+
* already net of `offsetPx`, where gridlineTicks / scalebarLabels /
|
|
1170
|
+
* paddingSpans are all in the staticBlocks frame. The sticky label's
|
|
1171
|
+
* position is a function of `offsetPx` rather than of block geometry, so
|
|
1172
|
+
* it has no fixed position in that frame — and for the same reason this
|
|
1173
|
+
* getter recomputes on every scroll frame where those three do not.
|
|
1174
|
+
*
|
|
1175
|
+
* `caption` accompanies the labels: the chip at the row's left edge,
|
|
1176
|
+
* saying which assembly the row is (a container view — synteny — opts
|
|
1177
|
+
* into that through `scalebarDisplayPrefix`) and whether it is flipped.
|
|
1178
|
+
* A ` [rev]` there is a fact about the ROW; the same marker on a
|
|
1179
|
+
* chromosome name means that one region, which only happens under mixed
|
|
1180
|
+
* orientation. `captionSpanPx` is the width it takes, which the
|
|
1181
|
+
* coordinate numbers stay out from under. The SVG export deliberately
|
|
1182
|
+
* calls `getScalebarRefNameLabels` itself with no prefix rather than
|
|
1183
|
+
* reading this, since it draws its own assembly name above the ruler.
|
|
1184
|
+
*/
|
|
1185
|
+
readonly scalebarRefNameLabels: {
|
|
1186
|
+
labels: import("./util.ts").ScalebarRefNameLabel[];
|
|
1187
|
+
caption: string | undefined;
|
|
1188
|
+
captionSpanPx: number;
|
|
1189
|
+
};
|
|
1190
|
+
/**
|
|
1191
|
+
* #getter
|
|
1192
|
+
* Every span along the row that is not track data, as plain geometry in
|
|
1193
|
+
* the staticBlocks frame — the same frame as gridlineTicks and
|
|
1194
|
+
* scalebarLabels, so one `translateX(staticBlocksTranslateX)` places all
|
|
1195
|
+
* three. Three kinds, and a host drawing its own chrome needs all of
|
|
1196
|
+
* them:
|
|
1197
|
+
*
|
|
1198
|
+
* - `seam`: the 3px bar at a region's right edge. Displayed regions are
|
|
1199
|
+
* laid out **contiguously** — calculateStaticBlocks emits boundary
|
|
1200
|
+
* padding only before the first region and after the last — so this
|
|
1201
|
+
* bar is the only thing separating two of them. Without it a
|
|
1202
|
+
* two-region view reads as a one-region view scrolled somewhere
|
|
1203
|
+
* strange. `isRightEndOfDisplayedRegion` is what marks it, and the
|
|
1204
|
+
* right edge of the blocks currently *loaded* — which is what block
|
|
1205
|
+
* geometry hands you — is not the same filter.
|
|
1206
|
+
* - `elided`: a region too narrow to draw at this zoom. Whole-genome on
|
|
1207
|
+
* a real assembly is mostly these — hg38 has 455 sequences and all
|
|
1208
|
+
* but the 24 chromosomes land sub-pixel — so a host that skips them
|
|
1209
|
+
* renders that tail as nothing at all.
|
|
1210
|
+
* - `boundary`: past the start of the first region or the end of the
|
|
1211
|
+
* last. Greying it is what makes the last region's seam read as the
|
|
1212
|
+
* edge of a filled area rather than a rule floating in the track.
|
|
1213
|
+
*
|
|
1214
|
+
* Elided blocks get no seam even though they carry the flag: at the
|
|
1215
|
+
* zoom where regions elide, one bar per region is a solid grey wall.
|
|
1216
|
+
*
|
|
1217
|
+
* PaddingBlocks is the in-tree consumer. The SVG export is deliberately
|
|
1218
|
+
* NOT one: `SVGRegionSeparators` walks dynamicBlocks itself and draws
|
|
1219
|
+
* only the seam, because `elided` and `boundary` are chrome for an
|
|
1220
|
+
* interactive row rather than information a figure carries — striped
|
|
1221
|
+
* grey saying "regions here are too narrow to draw" is noise in a
|
|
1222
|
+
* static image, and at whole-genome zoom it would be most of the row.
|
|
1223
|
+
* The seam is the one that must survive: regions lay out contiguously,
|
|
1224
|
+
* so it is all that separates two of them.
|
|
1225
|
+
*/
|
|
1226
|
+
readonly paddingSpans: {
|
|
1227
|
+
key: string;
|
|
1228
|
+
x: number;
|
|
1229
|
+
width: number;
|
|
1230
|
+
kind: 'seam' | 'elided' | 'boundary';
|
|
1231
|
+
}[];
|
|
1232
|
+
/**
|
|
1233
|
+
* #getter
|
|
1234
|
+
* Integer-rounded sum of all visible block widths. Slightly less than
|
|
1235
|
+
* view.width when the genome ends before the right edge; use view.width
|
|
1236
|
+
* for SVG clip rects (display boundary) and this for paint canvas sizing
|
|
1237
|
+
* (actual content width).
|
|
1238
|
+
*/
|
|
1239
|
+
readonly totalWidthPx: number;
|
|
1240
|
+
/**
|
|
1241
|
+
* #getter
|
|
1242
|
+
* Like totalWidthPx but excluding inter-region boundary blocks. Used
|
|
1243
|
+
* when column layout divides the canvas width by feature count.
|
|
1244
|
+
*/
|
|
1245
|
+
readonly totalWidthPxWithoutBorders: number;
|
|
1246
|
+
/**
|
|
1247
|
+
* #getter
|
|
1248
|
+
*/
|
|
1249
|
+
readonly visibleBp: number;
|
|
1250
|
+
/**
|
|
1251
|
+
* #getter
|
|
1252
|
+
* Whether any part of a displayed region actually falls inside the
|
|
1253
|
+
* viewport. False both when the view holds no regions at all and when
|
|
1254
|
+
* it holds some but is scrolled entirely off them; either way there is
|
|
1255
|
+
* no visible span for the scalebar, ruler and refName labels to
|
|
1256
|
+
* describe, which is what the SVG export's header checks before drawing
|
|
1257
|
+
* one. Distinct from `hasDisplayedRegions`, which only asks whether the
|
|
1258
|
+
* view has been given regions, not whether any are on screen.
|
|
1259
|
+
*/
|
|
1260
|
+
readonly hasVisibleContent: boolean;
|
|
1261
|
+
/**
|
|
1262
|
+
* #getter
|
|
1263
|
+
* What is on screen, as regions that address whole bases — what a
|
|
1264
|
+
* reader means by "the visible region" when they ask to fetch it,
|
|
1265
|
+
* bookmark it or read it back in a locString field. `visibleRegions`
|
|
1266
|
+
* below is the other half: pixels, and fractional by design.
|
|
1267
|
+
*/
|
|
1268
|
+
readonly visibleWholeBaseRegions: {
|
|
1269
|
+
assemblyName: string;
|
|
1270
|
+
refName: string;
|
|
1271
|
+
start: number;
|
|
1272
|
+
end: number;
|
|
1273
|
+
}[];
|
|
1274
|
+
/**
|
|
1275
|
+
* #getter
|
|
1276
|
+
* Returns the currently visible content blocks with screen pixel
|
|
1277
|
+
* positions and displayedRegionIndex guaranteed.
|
|
1278
|
+
* Used by WebGL displays for per-region data fetching and rendering.
|
|
1279
|
+
*/
|
|
1280
|
+
readonly visibleRegions: {
|
|
1281
|
+
refName: string;
|
|
1282
|
+
start: number;
|
|
1283
|
+
end: number;
|
|
1284
|
+
assemblyName: string;
|
|
1285
|
+
reversed: boolean | undefined;
|
|
1286
|
+
displayedRegionIndex: number;
|
|
1287
|
+
screenStartPx: number;
|
|
1288
|
+
screenEndPx: number;
|
|
1289
|
+
}[];
|
|
1290
|
+
/**
|
|
1291
|
+
* #getter
|
|
1292
|
+
* visibleRegions expanded by a half-screen buffer on each side,
|
|
1293
|
+
* clamped to displayedRegion bounds, with integer-rounded coordinates.
|
|
1294
|
+
* Use this when fetching data that should extend slightly beyond the
|
|
1295
|
+
* viewport for smooth scrolling.
|
|
1296
|
+
*/
|
|
1297
|
+
readonly bufferedVisibleRegions: {
|
|
1298
|
+
region: {
|
|
1299
|
+
refName: string;
|
|
1300
|
+
start: number;
|
|
1301
|
+
end: number;
|
|
1302
|
+
assemblyName: string;
|
|
1303
|
+
reversed: boolean | undefined;
|
|
1304
|
+
};
|
|
1305
|
+
displayedRegionIndex: number;
|
|
1306
|
+
}[];
|
|
1307
|
+
/**
|
|
1308
|
+
* #getter
|
|
1309
|
+
* a single "combo-locstring" representing all the regions visible on
|
|
1310
|
+
* the screen
|
|
1311
|
+
*/
|
|
178
1312
|
readonly visibleLocStrings: string;
|
|
1313
|
+
/**
|
|
1314
|
+
* #getter
|
|
1315
|
+
* **What a debounced consumer clips to**: the coarse blocks once the
|
|
1316
|
+
* view has settled at least once, the live ones before that.
|
|
1317
|
+
*
|
|
1318
|
+
* The coarse blocks exist so a per-bp scan does not recompute on every
|
|
1319
|
+
* animation frame during a pan or zoom — wiggle's autoscale domain, the
|
|
1320
|
+
* alignments coverage scale and MAF's coverage band are the three — and
|
|
1321
|
+
* while they are stale
|
|
1322
|
+
* the answer is merely a frame or two old, which is what the debounce
|
|
1323
|
+
* means. **Empty is different in kind.** A scan over no blocks yields no
|
|
1324
|
+
* entries, and no entries is not a stale domain, it is the fallback one:
|
|
1325
|
+
* `[0,1]`, which draws a line plot blank and a density plot saturated.
|
|
1326
|
+
* That window is the 500ms between a view initializing and the coarse
|
|
1327
|
+
* autorun's first run, and data can now land inside it — the per-region
|
|
1328
|
+
* fetch used to be trailing-edge at 600ms, so it never did.
|
|
1329
|
+
*
|
|
1330
|
+
* One recompute at that transition, against N per frame, which is the
|
|
1331
|
+
* trade the guard was making anyway.
|
|
1332
|
+
*/
|
|
1333
|
+
readonly settledDynamicBlocks: ContentBlock[];
|
|
1334
|
+
/**
|
|
1335
|
+
* #getter
|
|
1336
|
+
* same as visibleLocStrings, but only updated every 500ms
|
|
1337
|
+
*/
|
|
179
1338
|
readonly coarseVisibleLocStrings: string;
|
|
1339
|
+
/**
|
|
1340
|
+
* #getter
|
|
1341
|
+
*/
|
|
180
1342
|
readonly coarseTotalBpDisplayStr: string;
|
|
181
|
-
|
|
1343
|
+
/**
|
|
1344
|
+
* #getter
|
|
1345
|
+
*/
|
|
182
1346
|
readonly effectiveTotalBp: number;
|
|
1347
|
+
/**
|
|
1348
|
+
* #getter
|
|
1349
|
+
*/
|
|
183
1350
|
readonly effectiveTotalBpDisplayStr: string;
|
|
184
1351
|
} & {
|
|
185
|
-
|
|
1352
|
+
/**
|
|
1353
|
+
* #action
|
|
1354
|
+
*/
|
|
1355
|
+
setCoarseDynamicBlocks(blocks: BlockSet, bpPerPx: number): void;
|
|
186
1356
|
} & {
|
|
1357
|
+
/**
|
|
1358
|
+
* #action
|
|
1359
|
+
* Bring the coarse blocks to the viewport as it stands now, for a
|
|
1360
|
+
* placement that JUMPED rather than travelled.
|
|
1361
|
+
*
|
|
1362
|
+
* The coarse blocks are a 500ms throttle, and every consumer trades
|
|
1363
|
+
* freshness for not recomputing per animation frame — the location box,
|
|
1364
|
+
* canvas's on-screen feature set, and the two per-bp scans behind
|
|
1365
|
+
* `settledDynamicBlocks`. That trade is only sound while the answer is a
|
|
1366
|
+
* few frames old. **A jump makes it unrelated instead**, because there is
|
|
1367
|
+
* nothing to coalesce: the viewport left behind is not an approximation of
|
|
1368
|
+
* the new one, it is a different place. Unsettled, the location box reads
|
|
1369
|
+
* as a navigation that didn't happen, and wiggle's autoscale domain is
|
|
1370
|
+
* computed over the window the user just left — measured at `[0,200]`
|
|
1371
|
+
* against a correct `[0,300]` when a 40bp coarse window survived a jump to
|
|
1372
|
+
* 4040bp on screen. Only the per-region fetch moving to the leading edge
|
|
1373
|
+
* made that reachable: at 600ms the data never landed inside the hole.
|
|
1374
|
+
*
|
|
1375
|
+
* **The continuous paths deliberately do not come through here.** The
|
|
1376
|
+
* spring zoom writes through `zoomTo` per frame and a drag through
|
|
1377
|
+
* `scrollTo`, so this adds no per-frame work; the settle is idempotent
|
|
1378
|
+
* (`setCoarseDynamicBlocks` compares block keys), so the debounced
|
|
1379
|
+
* autorun's own follow-up run costs nothing.
|
|
1380
|
+
*
|
|
1381
|
+
* Every placer calls it, and `placersSettleCoarseBlocks.test.ts` is what
|
|
1382
|
+
* makes that true of the next one — it scans this file for the writes and
|
|
1383
|
+
* fails on a placer that reaches neither the settle nor its named list of
|
|
1384
|
+
* continuous paths. Two passes by hand missed four.
|
|
1385
|
+
*/
|
|
1386
|
+
settleCoarseBlocks(): void;
|
|
1387
|
+
} & {
|
|
1388
|
+
/**
|
|
1389
|
+
* #action
|
|
1390
|
+
* offset is the base-pair-offset in the displayed region, index is the
|
|
1391
|
+
* index of the displayed region in the linear genome view
|
|
1392
|
+
*
|
|
1393
|
+
* @param start - object as `{start, end, offset, index}`
|
|
1394
|
+
* @param end - object as `{start, end, offset, index}`
|
|
1395
|
+
*/
|
|
187
1396
|
moveTo(start?: BpOffset, end?: BpOffset): void;
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
1397
|
+
/**
|
|
1398
|
+
* #action
|
|
1399
|
+
* Place the viewport by the pair of PIXEL quantities it used to be stored
|
|
1400
|
+
* as. Prefer `setWindow`: pixels mean nothing without the width they were
|
|
1401
|
+
* measured at, so a round trip through here is only exact while the width
|
|
1402
|
+
* holds still. Kept for callers that genuinely have pixels — a wheel
|
|
1403
|
+
* gesture, a rubberband — and for reading old snapshots.
|
|
1404
|
+
*/
|
|
1405
|
+
setNewView(bpPerPx: number, offsetPx: number): void;
|
|
1406
|
+
/**
|
|
1407
|
+
* #action
|
|
1408
|
+
* Place the viewport by the pair it is actually STORED as: the window's
|
|
1409
|
+
* width and left edge, both in bp. `setNewView`'s bp-space twin, and the
|
|
1410
|
+
* right one for anything that captures a viewport and puts it back later
|
|
1411
|
+
* (an Undo, a saved location) — those two moments can be a window resize
|
|
1412
|
+
* apart, and this pair survives one where a pixel pair does not.
|
|
1413
|
+
*
|
|
1414
|
+
* Still clamped, by the same zoom and scroll limits as every other mover:
|
|
1415
|
+
* the regions may have changed under it, and a window the new set can't
|
|
1416
|
+
* hold is not restorable however it was spelled.
|
|
1417
|
+
*/
|
|
1418
|
+
setWindow(windowWidthBp: number, windowStartBp: number): void;
|
|
1419
|
+
/**
|
|
1420
|
+
* #action
|
|
1421
|
+
* `setWindow` without the settle, for a writer that runs per animation
|
|
1422
|
+
* frame. Flushing the coarse blocks sixty times a second is the one thing
|
|
1423
|
+
* such a writer must not do: they are a 500ms throttle that a synteny
|
|
1424
|
+
* follow pass and two autoscale domains hang off, and settling each frame
|
|
1425
|
+
* turns each of those into per-frame work — `positionViewOnSpans` states
|
|
1426
|
+
* the same rule for the same reason.
|
|
1427
|
+
*/
|
|
1428
|
+
setWindowFrame(windowWidthBp: number, windowStartBp: number): void;
|
|
1429
|
+
/**
|
|
1430
|
+
* #action
|
|
1431
|
+
* The worst jump of them to leave unsettled: the coarse blocks are keyed
|
|
1432
|
+
* by `displayedRegionIndex`, so a set that outlives the region list has a
|
|
1433
|
+
* consumer reading one contig's data against another's blocks.
|
|
1434
|
+
*/
|
|
1435
|
+
setDisplayedRegions(regions: Region[]): void;
|
|
1436
|
+
/**
|
|
1437
|
+
* #action
|
|
1438
|
+
* Re-assert `maxBpPerPx` over the current zoom, for a container whose
|
|
1439
|
+
* shared ceiling just fell — otherwise the view is stranded above it with
|
|
1440
|
+
* zoom-out disabled and the slider's min past its value. Goes through
|
|
1441
|
+
* `zoomTo` so the clamp keeps one definition, and settles because a
|
|
1442
|
+
* ceiling drop moves the window in one step.
|
|
1443
|
+
*
|
|
1444
|
+
* Requires an `initialized` view; the caller checks, since an MST action
|
|
1445
|
+
* reads untracked and a guard here would never re-run once the row
|
|
1446
|
+
* arrived.
|
|
1447
|
+
*/
|
|
1448
|
+
clampZoomToCeiling(): void;
|
|
1449
|
+
/**
|
|
1450
|
+
* #action
|
|
1451
|
+
*/
|
|
1452
|
+
showAllRegions(): void;
|
|
1453
|
+
/**
|
|
1454
|
+
* #action
|
|
1455
|
+
* Fit the displayed regions to the width exactly, edge to edge.
|
|
1456
|
+
*
|
|
1457
|
+
* Not the same as `showAllRegions`, which goes to `maxBpPerPx` — the
|
|
1458
|
+
* zoom-out LIMIT, where `SHOW_ALL_REGIONS_FILL` deliberately keeps a 10%
|
|
1459
|
+
* margin so the whole genome doesn't sit flush against both edges. That
|
|
1460
|
+
* margin is right for "show me everything" and wrong for a caller that
|
|
1461
|
+
* named the regions it wants: it draws them at 1/0.9 of fit-to-width,
|
|
1462
|
+
* centered, which is a silent 11% scale difference from the
|
|
1463
|
+
* single-region path (`moveTo`, span/width) reached through the same
|
|
1464
|
+
* location box.
|
|
1465
|
+
*
|
|
1466
|
+
* The scale comes from `fitAllRegionsWindow`, which is where the rule is
|
|
1467
|
+
* written — a snapshot builder that cannot call an action needs the same
|
|
1468
|
+
* answer, and the two agreeing matters more than either being local. Where
|
|
1469
|
+
* it clamps up to `minBpPerPx` the content is narrower than the view, and
|
|
1470
|
+
* the centering is what frames it.
|
|
1471
|
+
*/
|
|
1472
|
+
fitAllRegions(): void;
|
|
1473
|
+
/**
|
|
1474
|
+
* #action
|
|
1475
|
+
*/
|
|
1476
|
+
horizontallyFlip(): void;
|
|
1477
|
+
} & {
|
|
1478
|
+
/**
|
|
1479
|
+
* #action
|
|
1480
|
+
*/
|
|
1481
|
+
showAllRegionsInAssembly(assemblyName?: string): void;
|
|
1482
|
+
/**
|
|
1483
|
+
* #action
|
|
1484
|
+
* this "clears the view" and makes the view return to the import form
|
|
1485
|
+
*/
|
|
1486
|
+
clearView(): void;
|
|
1487
|
+
/**
|
|
1488
|
+
* #action
|
|
1489
|
+
* Navigate to a location based on its refName and optionally start, end,
|
|
1490
|
+
* and assemblyName. Will not try to change displayed regions, use
|
|
1491
|
+
* `navToLocations` instead. Only navigates to a location if it is
|
|
1492
|
+
* entirely within a displayedRegion. Navigates to the first matching
|
|
1493
|
+
* location encountered.
|
|
1494
|
+
*
|
|
1495
|
+
* Throws an error if navigation was unsuccessful
|
|
1496
|
+
*
|
|
1497
|
+
* @param query - a proposed location to navigate to
|
|
1498
|
+
* @param grow - optional multiplier to expand the region by (e.g., 0.2
|
|
1499
|
+
* adds 20% padding on each side)
|
|
1500
|
+
*/
|
|
195
1501
|
navTo(query: NavLocation, grow?: number): void;
|
|
1502
|
+
/**
|
|
1503
|
+
* #action
|
|
1504
|
+
* Navigate to a location based on its refName and optionally start, end,
|
|
1505
|
+
* and assemblyName. Will not try to change displayed regions, use
|
|
1506
|
+
* navToLocations instead. Only navigates to a location if it is entirely
|
|
1507
|
+
* within a displayedRegion. Navigates to the first matching location
|
|
1508
|
+
* encountered.
|
|
1509
|
+
*
|
|
1510
|
+
* Throws an error if navigation was unsuccessful
|
|
1511
|
+
*
|
|
1512
|
+
* @param locations - proposed location to navigate to
|
|
1513
|
+
* @param grow - optional multiplier to expand the region by (e.g., 0.2
|
|
1514
|
+
* adds 20% padding on each side)
|
|
1515
|
+
*/
|
|
196
1516
|
navToMultiple(locations: NavLocation[], grow?: number): void;
|
|
197
1517
|
} & {
|
|
1518
|
+
/**
|
|
1519
|
+
* #action
|
|
1520
|
+
* Replace the region list and place the viewport in one step. The pair is
|
|
1521
|
+
* the unit a coarse-block consumer can act on: called separately they
|
|
1522
|
+
* publish the viewport in between, and post-await in `navToLocations`
|
|
1523
|
+
* they are two transactions, so a per-bp scan runs over a window that was
|
|
1524
|
+
* never on screen.
|
|
1525
|
+
*
|
|
1526
|
+
* With no location named it fits the regions rather than going through
|
|
1527
|
+
* `showAllRegions`: the caller named the regions it wants, so it gets the
|
|
1528
|
+
* width, where showAllRegions goes to the zoom-out LIMIT and its 10%
|
|
1529
|
+
* margin is dead frame for a named subset.
|
|
1530
|
+
*/
|
|
1531
|
+
showRegions(regions: Region[], location?: NavLocation): void;
|
|
1532
|
+
} & {
|
|
1533
|
+
/**
|
|
1534
|
+
* #action
|
|
1535
|
+
* Navigate to the given locstring, will change displayed regions if
|
|
1536
|
+
* needed, and wait for assemblies to be initialized
|
|
1537
|
+
*
|
|
1538
|
+
* @param input - e.g. "chr1:1-100", "chr1:1-100 chr2:1-100", "chr 1 100"
|
|
1539
|
+
* @param optAssemblyName - (optional) the assembly name to use when
|
|
1540
|
+
* navigating to the locstring
|
|
1541
|
+
* @param grow - optional multiplier to expand the region by (e.g., 0.2
|
|
1542
|
+
* adds 20% padding on each side)
|
|
1543
|
+
* @returns whether the view moved. A multi-hit search raises the picker
|
|
1544
|
+
* instead of navigating, and both resolve — see `handleSelectedRegion`.
|
|
1545
|
+
*/
|
|
1546
|
+
navToLocString(input: string, optAssemblyName?: string, grow?: number): Promise<boolean>;
|
|
1547
|
+
/**
|
|
1548
|
+
* #action
|
|
1549
|
+
* Similar to `navToLocString`, but accepts a list of parsed location
|
|
1550
|
+
* objects instead of a locstring. Will try to perform
|
|
1551
|
+
* `setDisplayedRegions` if changing regions
|
|
1552
|
+
*
|
|
1553
|
+
* @param regions - array of parsed location objects
|
|
1554
|
+
* @param assemblyName - optional assembly name
|
|
1555
|
+
* @param grow - optional multiplier to expand the region by (e.g., 0.2
|
|
1556
|
+
* adds 20% padding on each side)
|
|
1557
|
+
*/
|
|
1558
|
+
navToLocations(regions: ParsedLocString[], assemblyName?: string, grow?: number): Promise<void>;
|
|
1559
|
+
} & {
|
|
1560
|
+
/**
|
|
1561
|
+
* #action
|
|
1562
|
+
* Similar to `navToLocString`, but accepts a parsed location object
|
|
1563
|
+
* instead of a locstring. Will try to perform `setDisplayedRegions` if
|
|
1564
|
+
* changing regions
|
|
1565
|
+
*
|
|
1566
|
+
* @param parsedLocString - a parsed location object with refName, start,
|
|
1567
|
+
* end, etc.
|
|
1568
|
+
* @param assemblyName - optional assembly name
|
|
1569
|
+
* @param grow - optional multiplier to expand the region by (e.g., 0.2
|
|
1570
|
+
* adds 20% padding on each side)
|
|
1571
|
+
*/
|
|
1572
|
+
navToLocation(parsedLocString: ParsedLocString, assemblyName?: string, grow?: number): Promise<void>;
|
|
1573
|
+
} & {
|
|
1574
|
+
/**
|
|
1575
|
+
* #method
|
|
1576
|
+
*/
|
|
198
1577
|
rubberBandMenuItems(): MenuItem[];
|
|
199
|
-
|
|
1578
|
+
/**
|
|
1579
|
+
* #method
|
|
1580
|
+
*/
|
|
1581
|
+
bpToPx({ refName, coord, displayedRegionIndex, }: {
|
|
200
1582
|
refName: string;
|
|
201
1583
|
coord: number;
|
|
202
|
-
|
|
1584
|
+
displayedRegionIndex?: number;
|
|
203
1585
|
}): {
|
|
204
1586
|
index: number;
|
|
205
1587
|
offsetPx: number;
|
|
206
1588
|
} | undefined;
|
|
1589
|
+
/**
|
|
1590
|
+
* #method
|
|
1591
|
+
* Map a highlight or bookmark region to its pixel position+width inside
|
|
1592
|
+
* the tracks container. Falls back to the raw refName if the region's
|
|
1593
|
+
* assemblyName is missing or unknown so highlights authored without an
|
|
1594
|
+
* assembly still render in single-assembly views.
|
|
1595
|
+
*/
|
|
207
1596
|
getHighlightCoords(region: {
|
|
208
1597
|
assemblyName?: string;
|
|
209
1598
|
refName: string;
|
|
@@ -213,89 +1602,90 @@ export declare function stateModelFactory(pluginManager: PluginManager): import(
|
|
|
213
1602
|
width: number;
|
|
214
1603
|
left: number;
|
|
215
1604
|
} | undefined;
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
assemblyName
|
|
223
|
-
offset: number;
|
|
224
|
-
start: number;
|
|
225
|
-
end: number;
|
|
226
|
-
reversed?: boolean;
|
|
227
|
-
};
|
|
228
|
-
readonly centerLineInfo: {
|
|
229
|
-
coord: number;
|
|
230
|
-
index: number;
|
|
1605
|
+
/**
|
|
1606
|
+
* #method
|
|
1607
|
+
* like getHighlightCoords but laid out against the overview scalebar and
|
|
1608
|
+
* shifted by the cytoband offset
|
|
1609
|
+
*/
|
|
1610
|
+
getOverviewHighlightCoords(region: {
|
|
1611
|
+
assemblyName?: string;
|
|
231
1612
|
refName: string;
|
|
232
|
-
oob: boolean;
|
|
233
|
-
assemblyName: string;
|
|
234
|
-
offset: number;
|
|
235
1613
|
start: number;
|
|
236
1614
|
end: number;
|
|
237
|
-
|
|
1615
|
+
}): {
|
|
1616
|
+
width: number;
|
|
1617
|
+
left: number;
|
|
238
1618
|
} | undefined;
|
|
239
|
-
|
|
1619
|
+
/**
|
|
1620
|
+
* #method
|
|
1621
|
+
* scrolls the view to center on the given bp. if that is not in any of
|
|
1622
|
+
* the displayed regions, does nothing
|
|
1623
|
+
*
|
|
1624
|
+
* @param coord - basepair at which you want to center the view
|
|
1625
|
+
* @param refName - refName of the displayedRegion you are centering at
|
|
1626
|
+
* @param displayedRegionIndex - index of the displayedRegion
|
|
1627
|
+
*/
|
|
1628
|
+
centerAt(coord: number, refName: string, displayedRegionIndex?: number): void;
|
|
1629
|
+
/**
|
|
1630
|
+
* #method
|
|
1631
|
+
*/
|
|
1632
|
+
pxToBp(px: number): import("@jbrowse/core/util/Base1DUtils").PxToBpResult;
|
|
1633
|
+
/**
|
|
1634
|
+
* #getter
|
|
1635
|
+
*/
|
|
1636
|
+
readonly centerLineInfo: import("@jbrowse/core/util/Base1DUtils").PxToBpResult | undefined;
|
|
240
1637
|
} & {
|
|
1638
|
+
/**
|
|
1639
|
+
* #method
|
|
1640
|
+
*/
|
|
241
1641
|
rubberbandClickMenuItems(clickOffset: BpOffset): MenuItem[];
|
|
1642
|
+
/**
|
|
1643
|
+
* #method
|
|
1644
|
+
* returns menu items for a highlight context menu. plugins can extend
|
|
1645
|
+
* this via Core-extendPluggableElement to add their own items
|
|
1646
|
+
*/
|
|
1647
|
+
highlightMenuItems(_highlight: HighlightType): MenuItem[];
|
|
1648
|
+
} & {
|
|
1649
|
+
flyTo: (centerBp: number, windowWidthBp: number) => void;
|
|
1650
|
+
/**
|
|
1651
|
+
* #action
|
|
1652
|
+
* `centerAt`'s animated twin: the same destination, reached along the
|
|
1653
|
+
* arc instead of jumped to, at the zoom the view is already on.
|
|
1654
|
+
*/
|
|
1655
|
+
flyToCenter(coord: number, refName: string): void;
|
|
242
1656
|
} & {
|
|
243
1657
|
afterCreate(): void;
|
|
244
1658
|
afterAttach(): void;
|
|
245
|
-
}, import("@jbrowse/mobx-state-tree").
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
id:
|
|
251
|
-
type:
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
colorByCDS
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
}
|
|
271
|
-
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
272
|
-
displayName: import("@jbrowse/mobx-state-tree").IMaybe<import("@jbrowse/mobx-state-tree").ISimpleType<string>>;
|
|
273
|
-
minimized: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
274
|
-
} & {
|
|
275
|
-
id: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
276
|
-
type: import("@jbrowse/mobx-state-tree").IType<string | undefined, string, string>;
|
|
277
|
-
offsetPx: import("@jbrowse/mobx-state-tree").IType<number | undefined, number, number>;
|
|
278
|
-
bpPerPx: import("@jbrowse/mobx-state-tree").IType<number | undefined, number, number>;
|
|
279
|
-
displayedRegions: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IType<Region[], Region[], Region[]>, [undefined]>;
|
|
280
|
-
tracks: import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IAnyType>;
|
|
281
|
-
hideHeader: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
282
|
-
hideHeaderOverview: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
283
|
-
hideNoTracksActive: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
284
|
-
trackSelectorType: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
285
|
-
showCenterLine: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
286
|
-
showCytobandsSetting: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
287
|
-
trackLabels: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
288
|
-
showGridlines: import("@jbrowse/mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
289
|
-
highlight: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").IArrayType<import("@jbrowse/mobx-state-tree").IType<HighlightType, HighlightType, HighlightType>>, [undefined]>;
|
|
290
|
-
highlightsVisible: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
291
|
-
labelsVisible: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
292
|
-
colorByCDS: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
293
|
-
showTrackOutlines: import("@jbrowse/mobx-state-tree").IOptionalIType<import("@jbrowse/mobx-state-tree").ISimpleType<boolean>, [undefined]>;
|
|
294
|
-
init: import("@jbrowse/mobx-state-tree").IType<InitState | undefined, InitState | undefined, InitState | undefined>;
|
|
295
|
-
}>>;
|
|
1659
|
+
}, import("@jbrowse/mobx-state-tree")._NotCustomized, {
|
|
1660
|
+
displayName: string | undefined;
|
|
1661
|
+
minimized: boolean;
|
|
1662
|
+
highlight: HighlightType[];
|
|
1663
|
+
showHighlightChips: boolean;
|
|
1664
|
+
id: string;
|
|
1665
|
+
type: string;
|
|
1666
|
+
windowStartBp: number;
|
|
1667
|
+
windowWidthBp: number;
|
|
1668
|
+
legacyBpPerPx: number;
|
|
1669
|
+
displayedRegions: Region[];
|
|
1670
|
+
tracks: any[];
|
|
1671
|
+
hideHeader: boolean;
|
|
1672
|
+
hideHeaderOverview: boolean;
|
|
1673
|
+
hideNoTracksActive: boolean;
|
|
1674
|
+
trackSelectorType: string;
|
|
1675
|
+
showGridlines: boolean;
|
|
1676
|
+
labelsVisible: boolean;
|
|
1677
|
+
scalebarOnly: boolean;
|
|
1678
|
+
init?: InitState | undefined;
|
|
1679
|
+
showCytobands?: false | undefined;
|
|
1680
|
+
trackLabels?: string | undefined;
|
|
1681
|
+
colorByCDS?: true | undefined;
|
|
1682
|
+
showAminoAcids?: false | undefined;
|
|
1683
|
+
showTrackOutlines?: false | undefined;
|
|
1684
|
+
}>;
|
|
296
1685
|
export type LinearGenomeViewStateModel = ReturnType<typeof stateModelFactory>;
|
|
297
1686
|
export type LinearGenomeViewModel = Instance<LinearGenomeViewStateModel>;
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
1687
|
+
declare module '@jbrowse/core/PluginManager' {
|
|
1688
|
+
interface ViewTypeRegistry {
|
|
1689
|
+
LinearGenomeView: LinearGenomeViewStateModel;
|
|
1690
|
+
}
|
|
1691
|
+
}
|