@jbrowse/plugin-linear-genome-view 2.5.0 → 2.6.2
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/dist/BaseLinearDisplay/components/BaseLinearDisplay.d.ts +1 -1
- package/dist/BaseLinearDisplay/components/BaseLinearDisplay.js +0 -1
- package/dist/BaseLinearDisplay/components/Block.d.ts +3 -3
- package/dist/BaseLinearDisplay/components/Block.js +0 -1
- package/dist/BaseLinearDisplay/components/BlockMsg.d.ts +1 -1
- package/dist/BaseLinearDisplay/components/BlockMsg.js +0 -1
- package/dist/BaseLinearDisplay/components/LinearBlocks.d.ts +3 -2
- package/dist/BaseLinearDisplay/components/LinearBlocks.js +0 -1
- package/dist/BaseLinearDisplay/components/ServerSideRenderedBlockContent.js +0 -1
- package/dist/BaseLinearDisplay/components/TooLargeMessage.d.ts +2 -1
- package/dist/BaseLinearDisplay/components/TooLargeMessage.js +0 -1
- package/dist/BaseLinearDisplay/components/Tooltip.d.ts +2 -1
- package/dist/BaseLinearDisplay/components/Tooltip.js +0 -1
- package/dist/BaseLinearDisplay/index.d.ts +5 -2
- package/dist/BaseLinearDisplay/index.js +7 -2
- package/dist/BaseLinearDisplay/models/BaseLinearDisplayModel.d.ts +62 -142
- package/dist/BaseLinearDisplay/models/BaseLinearDisplayModel.js +34 -356
- package/dist/BaseLinearDisplay/models/FeatureDensityMixin.d.ts +99 -0
- package/dist/BaseLinearDisplay/models/FeatureDensityMixin.js +189 -0
- package/dist/BaseLinearDisplay/models/TrackHeightMixin.d.ts +30 -0
- package/dist/BaseLinearDisplay/models/TrackHeightMixin.js +55 -0
- package/dist/BaseLinearDisplay/models/autorunFeatureDensityStats.d.ts +2 -0
- package/dist/BaseLinearDisplay/models/autorunFeatureDensityStats.js +41 -0
- package/dist/BaseLinearDisplay/models/configSchema.js +1 -1
- package/dist/BaseLinearDisplay/models/renderSvg.d.ts +8 -0
- package/dist/BaseLinearDisplay/models/renderSvg.js +82 -0
- package/dist/BaseLinearDisplay/models/serverSideRenderedBlock.js +20 -17
- package/dist/BaseLinearDisplay/models/util.js +0 -1
- package/dist/BasicTrack/configSchema.js +1 -1
- package/dist/BasicTrack/index.js +0 -1
- package/dist/FeatureTrack/configSchema.d.ts +1 -3
- package/dist/FeatureTrack/configSchema.js +1 -1
- package/dist/FeatureTrack/index.js +0 -1
- package/dist/LaunchLinearGenomeView/index.js +0 -1
- package/dist/LinearBareDisplay/configSchema.d.ts +1 -0
- package/dist/LinearBareDisplay/configSchema.js +1 -1
- package/dist/LinearBareDisplay/index.js +0 -1
- package/dist/LinearBareDisplay/model.d.ts +52 -39
- package/dist/LinearBareDisplay/model.js +1 -1
- package/dist/LinearBasicDisplay/components/SetMaxHeight.d.ts +2 -1
- package/dist/LinearBasicDisplay/components/SetMaxHeight.js +0 -1
- package/dist/LinearBasicDisplay/configSchema.d.ts +1 -0
- package/dist/LinearBasicDisplay/configSchema.js +1 -1
- package/dist/LinearBasicDisplay/index.js +0 -1
- package/dist/LinearBasicDisplay/model.d.ts +67 -66
- package/dist/LinearBasicDisplay/model.js +1 -1
- package/dist/LinearGenomeView/components/CenterLine.d.ts +2 -1
- package/dist/LinearGenomeView/components/CenterLine.js +0 -1
- package/dist/LinearGenomeView/components/Cytobands.d.ts +2 -1
- package/dist/LinearGenomeView/components/Cytobands.js +0 -1
- package/dist/LinearGenomeView/components/ExportSvgDialog.d.ts +2 -1
- package/dist/LinearGenomeView/components/ExportSvgDialog.js +0 -1
- package/dist/LinearGenomeView/components/GetSequenceDialog.d.ts +2 -1
- package/dist/LinearGenomeView/components/GetSequenceDialog.js +0 -1
- package/dist/LinearGenomeView/components/Gridlines.d.ts +2 -1
- package/dist/LinearGenomeView/components/Gridlines.js +0 -1
- package/dist/LinearGenomeView/components/Header.d.ts +2 -1
- package/dist/LinearGenomeView/components/Header.js +0 -1
- package/dist/LinearGenomeView/components/ImportForm.d.ts +2 -1
- package/dist/LinearGenomeView/components/ImportForm.js +0 -1
- package/dist/LinearGenomeView/components/LinearGenomeView.d.ts +2 -1
- package/dist/LinearGenomeView/components/LinearGenomeView.js +28 -5
- package/dist/LinearGenomeView/components/MiniControls.d.ts +3 -2
- package/dist/LinearGenomeView/components/MiniControls.js +20 -41
- package/dist/LinearGenomeView/components/OverviewRubberband.d.ts +1 -1
- package/dist/LinearGenomeView/components/OverviewRubberband.js +0 -1
- package/dist/LinearGenomeView/components/OverviewScalebar.d.ts +2 -2
- package/dist/LinearGenomeView/components/OverviewScalebar.js +10 -5
- package/dist/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.d.ts +10 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.js +21 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.d.ts +5 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.js +51 -0
- package/dist/LinearGenomeView/components/{HelpDialog.d.ts → RefNameAutocomplete/HelpDialog.d.ts} +2 -1
- package/dist/LinearGenomeView/components/{HelpDialog.js → RefNameAutocomplete/HelpDialog.js} +0 -1
- package/dist/LinearGenomeView/components/RefNameAutocomplete/index.d.ts +18 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/index.js +110 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/util.d.ts +12 -0
- package/dist/LinearGenomeView/components/RefNameAutocomplete/util.js +58 -0
- package/dist/LinearGenomeView/components/Rubberband.d.ts +1 -1
- package/dist/LinearGenomeView/components/Rubberband.js +0 -1
- package/dist/LinearGenomeView/components/RubberbandSpan.d.ts +2 -1
- package/dist/LinearGenomeView/components/RubberbandSpan.js +0 -1
- package/dist/LinearGenomeView/components/Scalebar.js +0 -1
- package/dist/LinearGenomeView/components/SearchBox.d.ts +2 -1
- package/dist/LinearGenomeView/components/SearchBox.js +0 -1
- package/dist/LinearGenomeView/components/SearchResultsDialog.d.ts +2 -1
- package/dist/LinearGenomeView/components/SearchResultsDialog.js +0 -1
- package/dist/LinearGenomeView/components/SearchResultsTable.d.ts +2 -1
- package/dist/LinearGenomeView/components/SearchResultsTable.js +0 -1
- package/dist/LinearGenomeView/components/SequenceSearchDialog.d.ts +2 -1
- package/dist/LinearGenomeView/components/SequenceSearchDialog.js +0 -1
- package/dist/LinearGenomeView/components/TrackContainer.d.ts +3 -3
- package/dist/LinearGenomeView/components/TrackContainer.js +12 -69
- package/dist/LinearGenomeView/components/TrackLabel.js +7 -12
- package/dist/LinearGenomeView/components/TrackLabelContainer.d.ts +9 -0
- package/dist/LinearGenomeView/components/TrackLabelContainer.js +31 -0
- package/dist/LinearGenomeView/components/TrackRenderingContainer.d.ts +10 -0
- package/dist/LinearGenomeView/components/TrackRenderingContainer.js +73 -0
- package/dist/LinearGenomeView/components/TracksContainer.d.ts +1 -1
- package/dist/LinearGenomeView/components/TracksContainer.js +2 -3
- package/dist/LinearGenomeView/components/VerticalGuide.d.ts +2 -1
- package/dist/LinearGenomeView/components/VerticalGuide.js +0 -1
- package/dist/LinearGenomeView/components/ZoomControls.d.ts +2 -1
- package/dist/LinearGenomeView/components/ZoomControls.js +0 -1
- package/dist/LinearGenomeView/components/hooks.js +0 -1
- package/dist/LinearGenomeView/components/util.js +0 -1
- package/dist/LinearGenomeView/index.js +0 -1
- package/dist/LinearGenomeView/model.d.ts +13 -12
- package/dist/LinearGenomeView/model.js +25 -26
- package/dist/LinearGenomeView/svgcomponents/SVGBackground.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGBackground.js +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGHeader.d.ts +3 -4
- package/dist/LinearGenomeView/svgcomponents/SVGHeader.js +7 -3
- package/dist/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js +1 -2
- package/dist/LinearGenomeView/svgcomponents/SVGRegionSeparators.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGRegionSeparators.js +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGRuler.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGRuler.js +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGScalebar.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGScalebar.js +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTrackLabel.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTrackLabel.js +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTracks.d.ts +2 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTracks.js +0 -1
- package/dist/LinearGenomeView/util.d.ts +2 -2
- package/dist/LinearGenomeView/util.js +0 -1
- package/dist/index.d.ts +160 -134
- package/dist/index.js +6 -4
- package/esm/BaseLinearDisplay/components/BaseLinearDisplay.d.ts +1 -1
- package/esm/BaseLinearDisplay/components/BaseLinearDisplay.js +0 -1
- package/esm/BaseLinearDisplay/components/Block.d.ts +3 -3
- package/esm/BaseLinearDisplay/components/Block.js +0 -1
- package/esm/BaseLinearDisplay/components/BlockMsg.d.ts +1 -1
- package/esm/BaseLinearDisplay/components/BlockMsg.js +0 -1
- package/esm/BaseLinearDisplay/components/LinearBlocks.d.ts +3 -2
- package/esm/BaseLinearDisplay/components/LinearBlocks.js +0 -1
- package/esm/BaseLinearDisplay/components/ServerSideRenderedBlockContent.js +0 -1
- package/esm/BaseLinearDisplay/components/TooLargeMessage.d.ts +2 -1
- package/esm/BaseLinearDisplay/components/TooLargeMessage.js +0 -1
- package/esm/BaseLinearDisplay/components/Tooltip.d.ts +2 -1
- package/esm/BaseLinearDisplay/components/Tooltip.js +0 -1
- package/esm/BaseLinearDisplay/index.d.ts +5 -2
- package/esm/BaseLinearDisplay/index.js +3 -1
- package/esm/BaseLinearDisplay/models/BaseLinearDisplayModel.d.ts +62 -142
- package/esm/BaseLinearDisplay/models/BaseLinearDisplayModel.js +36 -335
- package/esm/BaseLinearDisplay/models/FeatureDensityMixin.d.ts +99 -0
- package/esm/BaseLinearDisplay/models/FeatureDensityMixin.js +183 -0
- package/esm/BaseLinearDisplay/models/TrackHeightMixin.d.ts +30 -0
- package/esm/BaseLinearDisplay/models/TrackHeightMixin.js +52 -0
- package/esm/BaseLinearDisplay/models/autorunFeatureDensityStats.d.ts +2 -0
- package/esm/BaseLinearDisplay/models/autorunFeatureDensityStats.js +38 -0
- package/esm/BaseLinearDisplay/models/configSchema.js +1 -1
- package/esm/BaseLinearDisplay/models/renderSvg.d.ts +8 -0
- package/esm/BaseLinearDisplay/models/renderSvg.js +53 -0
- package/esm/BaseLinearDisplay/models/serverSideRenderedBlock.js +20 -17
- package/esm/BaseLinearDisplay/models/util.js +0 -1
- package/esm/BasicTrack/configSchema.js +1 -1
- package/esm/BasicTrack/index.js +0 -1
- package/esm/FeatureTrack/configSchema.d.ts +1 -3
- package/esm/FeatureTrack/configSchema.js +1 -1
- package/esm/FeatureTrack/index.js +0 -1
- package/esm/LaunchLinearGenomeView/index.js +0 -1
- package/esm/LinearBareDisplay/configSchema.d.ts +1 -0
- package/esm/LinearBareDisplay/configSchema.js +1 -1
- package/esm/LinearBareDisplay/index.js +0 -1
- package/esm/LinearBareDisplay/model.d.ts +52 -39
- package/esm/LinearBareDisplay/model.js +1 -1
- package/esm/LinearBasicDisplay/components/SetMaxHeight.d.ts +2 -1
- package/esm/LinearBasicDisplay/components/SetMaxHeight.js +0 -1
- package/esm/LinearBasicDisplay/configSchema.d.ts +1 -0
- package/esm/LinearBasicDisplay/configSchema.js +1 -1
- package/esm/LinearBasicDisplay/index.js +0 -1
- package/esm/LinearBasicDisplay/model.d.ts +67 -66
- package/esm/LinearBasicDisplay/model.js +1 -1
- package/esm/LinearGenomeView/components/CenterLine.d.ts +2 -1
- package/esm/LinearGenomeView/components/CenterLine.js +0 -1
- package/esm/LinearGenomeView/components/Cytobands.d.ts +2 -1
- package/esm/LinearGenomeView/components/Cytobands.js +0 -1
- package/esm/LinearGenomeView/components/ExportSvgDialog.d.ts +2 -1
- package/esm/LinearGenomeView/components/ExportSvgDialog.js +0 -1
- package/esm/LinearGenomeView/components/GetSequenceDialog.d.ts +2 -1
- package/esm/LinearGenomeView/components/GetSequenceDialog.js +0 -1
- package/esm/LinearGenomeView/components/Gridlines.d.ts +2 -1
- package/esm/LinearGenomeView/components/Gridlines.js +0 -1
- package/esm/LinearGenomeView/components/Header.d.ts +2 -1
- package/esm/LinearGenomeView/components/Header.js +0 -1
- package/esm/LinearGenomeView/components/ImportForm.d.ts +2 -1
- package/esm/LinearGenomeView/components/ImportForm.js +0 -1
- package/esm/LinearGenomeView/components/LinearGenomeView.d.ts +2 -1
- package/esm/LinearGenomeView/components/LinearGenomeView.js +4 -4
- package/esm/LinearGenomeView/components/MiniControls.d.ts +3 -2
- package/esm/LinearGenomeView/components/MiniControls.js +20 -18
- package/esm/LinearGenomeView/components/OverviewRubberband.d.ts +1 -1
- package/esm/LinearGenomeView/components/OverviewRubberband.js +0 -1
- package/esm/LinearGenomeView/components/OverviewScalebar.d.ts +2 -2
- package/esm/LinearGenomeView/components/OverviewScalebar.js +10 -5
- package/esm/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.d.ts +10 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/AutocompleteTextField.js +15 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.d.ts +5 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/EndAdornment.js +22 -0
- package/esm/LinearGenomeView/components/{HelpDialog.d.ts → RefNameAutocomplete/HelpDialog.d.ts} +2 -1
- package/esm/LinearGenomeView/components/{HelpDialog.js → RefNameAutocomplete/HelpDialog.js} +0 -1
- package/esm/LinearGenomeView/components/RefNameAutocomplete/index.d.ts +18 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/index.js +82 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/util.d.ts +12 -0
- package/esm/LinearGenomeView/components/RefNameAutocomplete/util.js +49 -0
- package/esm/LinearGenomeView/components/Rubberband.d.ts +1 -1
- package/esm/LinearGenomeView/components/Rubberband.js +0 -1
- package/esm/LinearGenomeView/components/RubberbandSpan.d.ts +2 -1
- package/esm/LinearGenomeView/components/RubberbandSpan.js +0 -1
- package/esm/LinearGenomeView/components/Scalebar.js +0 -1
- package/esm/LinearGenomeView/components/SearchBox.d.ts +2 -1
- package/esm/LinearGenomeView/components/SearchBox.js +0 -1
- package/esm/LinearGenomeView/components/SearchResultsDialog.d.ts +2 -1
- package/esm/LinearGenomeView/components/SearchResultsDialog.js +0 -1
- package/esm/LinearGenomeView/components/SearchResultsTable.d.ts +2 -1
- package/esm/LinearGenomeView/components/SearchResultsTable.js +0 -1
- package/esm/LinearGenomeView/components/SequenceSearchDialog.d.ts +2 -1
- package/esm/LinearGenomeView/components/SequenceSearchDialog.js +0 -1
- package/esm/LinearGenomeView/components/TrackContainer.d.ts +3 -3
- package/esm/LinearGenomeView/components/TrackContainer.js +13 -70
- package/esm/LinearGenomeView/components/TrackLabel.js +7 -12
- package/esm/LinearGenomeView/components/TrackLabelContainer.d.ts +9 -0
- package/esm/LinearGenomeView/components/TrackLabelContainer.js +26 -0
- package/esm/LinearGenomeView/components/TrackRenderingContainer.d.ts +10 -0
- package/esm/LinearGenomeView/components/TrackRenderingContainer.js +48 -0
- package/esm/LinearGenomeView/components/TracksContainer.d.ts +1 -1
- package/esm/LinearGenomeView/components/TracksContainer.js +2 -3
- package/esm/LinearGenomeView/components/VerticalGuide.d.ts +2 -1
- package/esm/LinearGenomeView/components/VerticalGuide.js +0 -1
- package/esm/LinearGenomeView/components/ZoomControls.d.ts +2 -1
- package/esm/LinearGenomeView/components/ZoomControls.js +0 -1
- package/esm/LinearGenomeView/components/hooks.js +0 -1
- package/esm/LinearGenomeView/components/util.js +0 -1
- package/esm/LinearGenomeView/index.js +0 -1
- package/esm/LinearGenomeView/model.d.ts +13 -12
- package/esm/LinearGenomeView/model.js +21 -22
- package/esm/LinearGenomeView/svgcomponents/SVGBackground.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGBackground.js +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGHeader.d.ts +3 -4
- package/esm/LinearGenomeView/svgcomponents/SVGHeader.js +7 -3
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js +1 -2
- package/esm/LinearGenomeView/svgcomponents/SVGRegionSeparators.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRegionSeparators.js +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.js +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGScalebar.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGScalebar.js +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.js +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.d.ts +2 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.js +0 -1
- package/esm/LinearGenomeView/util.d.ts +2 -2
- package/esm/LinearGenomeView/util.js +0 -1
- package/esm/index.d.ts +160 -134
- package/esm/index.js +1 -2
- package/package.json +3 -4
- package/dist/BaseLinearDisplay/components/BaseLinearDisplay.js.map +0 -1
- package/dist/BaseLinearDisplay/components/Block.js.map +0 -1
- package/dist/BaseLinearDisplay/components/BlockMsg.js.map +0 -1
- package/dist/BaseLinearDisplay/components/LinearBlocks.js.map +0 -1
- package/dist/BaseLinearDisplay/components/ServerSideRenderedBlockContent.js.map +0 -1
- package/dist/BaseLinearDisplay/components/TooLargeMessage.js.map +0 -1
- package/dist/BaseLinearDisplay/components/Tooltip.js.map +0 -1
- package/dist/BaseLinearDisplay/index.js.map +0 -1
- package/dist/BaseLinearDisplay/models/BaseLinearDisplayModel.js.map +0 -1
- package/dist/BaseLinearDisplay/models/configSchema.js.map +0 -1
- package/dist/BaseLinearDisplay/models/serverSideRenderedBlock.js.map +0 -1
- package/dist/BaseLinearDisplay/models/util.js.map +0 -1
- package/dist/BasicTrack/configSchema.js.map +0 -1
- package/dist/BasicTrack/index.js.map +0 -1
- package/dist/FeatureTrack/configSchema.js.map +0 -1
- package/dist/FeatureTrack/index.js.map +0 -1
- package/dist/LaunchLinearGenomeView/index.js.map +0 -1
- package/dist/LinearBareDisplay/configSchema.js.map +0 -1
- package/dist/LinearBareDisplay/index.js.map +0 -1
- package/dist/LinearBareDisplay/model.js.map +0 -1
- package/dist/LinearBasicDisplay/components/SetMaxHeight.js.map +0 -1
- package/dist/LinearBasicDisplay/configSchema.js.map +0 -1
- package/dist/LinearBasicDisplay/index.js.map +0 -1
- package/dist/LinearBasicDisplay/model.js.map +0 -1
- package/dist/LinearGenomeView/components/CenterLine.js.map +0 -1
- package/dist/LinearGenomeView/components/Cytobands.js.map +0 -1
- package/dist/LinearGenomeView/components/ExportSvgDialog.js.map +0 -1
- package/dist/LinearGenomeView/components/GetSequenceDialog.js.map +0 -1
- package/dist/LinearGenomeView/components/Gridlines.js.map +0 -1
- package/dist/LinearGenomeView/components/Header.js.map +0 -1
- package/dist/LinearGenomeView/components/HelpDialog.js.map +0 -1
- package/dist/LinearGenomeView/components/ImportForm.js.map +0 -1
- package/dist/LinearGenomeView/components/LinearGenomeView.js.map +0 -1
- package/dist/LinearGenomeView/components/MiniControls.js.map +0 -1
- package/dist/LinearGenomeView/components/OverviewRubberband.js.map +0 -1
- package/dist/LinearGenomeView/components/OverviewScalebar.js.map +0 -1
- package/dist/LinearGenomeView/components/RefNameAutocomplete.d.ts +0 -23
- package/dist/LinearGenomeView/components/RefNameAutocomplete.js +0 -189
- package/dist/LinearGenomeView/components/RefNameAutocomplete.js.map +0 -1
- package/dist/LinearGenomeView/components/Rubberband.js.map +0 -1
- package/dist/LinearGenomeView/components/RubberbandSpan.js.map +0 -1
- package/dist/LinearGenomeView/components/Scalebar.js.map +0 -1
- package/dist/LinearGenomeView/components/SearchBox.js.map +0 -1
- package/dist/LinearGenomeView/components/SearchResultsDialog.js.map +0 -1
- package/dist/LinearGenomeView/components/SearchResultsTable.js.map +0 -1
- package/dist/LinearGenomeView/components/SequenceSearchDialog.js.map +0 -1
- package/dist/LinearGenomeView/components/TrackContainer.js.map +0 -1
- package/dist/LinearGenomeView/components/TrackLabel.js.map +0 -1
- package/dist/LinearGenomeView/components/TracksContainer.js.map +0 -1
- package/dist/LinearGenomeView/components/VerticalGuide.js.map +0 -1
- package/dist/LinearGenomeView/components/ZoomControls.js.map +0 -1
- package/dist/LinearGenomeView/components/hooks.js.map +0 -1
- package/dist/LinearGenomeView/components/util.js.map +0 -1
- package/dist/LinearGenomeView/index.js.map +0 -1
- package/dist/LinearGenomeView/model.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGBackground.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGHeader.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGRegionSeparators.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGRuler.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGScalebar.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTrackLabel.js.map +0 -1
- package/dist/LinearGenomeView/svgcomponents/SVGTracks.js.map +0 -1
- package/dist/LinearGenomeView/util.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/esm/BaseLinearDisplay/components/BaseLinearDisplay.js.map +0 -1
- package/esm/BaseLinearDisplay/components/Block.js.map +0 -1
- package/esm/BaseLinearDisplay/components/BlockMsg.js.map +0 -1
- package/esm/BaseLinearDisplay/components/LinearBlocks.js.map +0 -1
- package/esm/BaseLinearDisplay/components/ServerSideRenderedBlockContent.js.map +0 -1
- package/esm/BaseLinearDisplay/components/TooLargeMessage.js.map +0 -1
- package/esm/BaseLinearDisplay/components/Tooltip.js.map +0 -1
- package/esm/BaseLinearDisplay/index.js.map +0 -1
- package/esm/BaseLinearDisplay/models/BaseLinearDisplayModel.js.map +0 -1
- package/esm/BaseLinearDisplay/models/configSchema.js.map +0 -1
- package/esm/BaseLinearDisplay/models/serverSideRenderedBlock.js.map +0 -1
- package/esm/BaseLinearDisplay/models/util.js.map +0 -1
- package/esm/BasicTrack/configSchema.js.map +0 -1
- package/esm/BasicTrack/index.js.map +0 -1
- package/esm/FeatureTrack/configSchema.js.map +0 -1
- package/esm/FeatureTrack/index.js.map +0 -1
- package/esm/LaunchLinearGenomeView/index.js.map +0 -1
- package/esm/LinearBareDisplay/configSchema.js.map +0 -1
- package/esm/LinearBareDisplay/index.js.map +0 -1
- package/esm/LinearBareDisplay/model.js.map +0 -1
- package/esm/LinearBasicDisplay/components/SetMaxHeight.js.map +0 -1
- package/esm/LinearBasicDisplay/configSchema.js.map +0 -1
- package/esm/LinearBasicDisplay/index.js.map +0 -1
- package/esm/LinearBasicDisplay/model.js.map +0 -1
- package/esm/LinearGenomeView/components/CenterLine.js.map +0 -1
- package/esm/LinearGenomeView/components/Cytobands.js.map +0 -1
- package/esm/LinearGenomeView/components/ExportSvgDialog.js.map +0 -1
- package/esm/LinearGenomeView/components/GetSequenceDialog.js.map +0 -1
- package/esm/LinearGenomeView/components/Gridlines.js.map +0 -1
- package/esm/LinearGenomeView/components/Header.js.map +0 -1
- package/esm/LinearGenomeView/components/HelpDialog.js.map +0 -1
- package/esm/LinearGenomeView/components/ImportForm.js.map +0 -1
- package/esm/LinearGenomeView/components/LinearGenomeView.js.map +0 -1
- package/esm/LinearGenomeView/components/MiniControls.js.map +0 -1
- package/esm/LinearGenomeView/components/OverviewRubberband.js.map +0 -1
- package/esm/LinearGenomeView/components/OverviewScalebar.js.map +0 -1
- package/esm/LinearGenomeView/components/RefNameAutocomplete.d.ts +0 -23
- package/esm/LinearGenomeView/components/RefNameAutocomplete.js +0 -161
- package/esm/LinearGenomeView/components/RefNameAutocomplete.js.map +0 -1
- package/esm/LinearGenomeView/components/Rubberband.js.map +0 -1
- package/esm/LinearGenomeView/components/RubberbandSpan.js.map +0 -1
- package/esm/LinearGenomeView/components/Scalebar.js.map +0 -1
- package/esm/LinearGenomeView/components/SearchBox.js.map +0 -1
- package/esm/LinearGenomeView/components/SearchResultsDialog.js.map +0 -1
- package/esm/LinearGenomeView/components/SearchResultsTable.js.map +0 -1
- package/esm/LinearGenomeView/components/SequenceSearchDialog.js.map +0 -1
- package/esm/LinearGenomeView/components/TrackContainer.js.map +0 -1
- package/esm/LinearGenomeView/components/TrackLabel.js.map +0 -1
- package/esm/LinearGenomeView/components/TracksContainer.js.map +0 -1
- package/esm/LinearGenomeView/components/VerticalGuide.js.map +0 -1
- package/esm/LinearGenomeView/components/ZoomControls.js.map +0 -1
- package/esm/LinearGenomeView/components/hooks.js.map +0 -1
- package/esm/LinearGenomeView/components/util.js.map +0 -1
- package/esm/LinearGenomeView/index.js.map +0 -1
- package/esm/LinearGenomeView/model.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGBackground.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGHeader.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGLinearGenomeView.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRegionSeparators.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGRuler.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGScalebar.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTrackLabel.js.map +0 -1
- package/esm/LinearGenomeView/svgcomponents/SVGTracks.js.map +0 -1
- package/esm/LinearGenomeView/util.js.map +0 -1
- package/esm/index.js.map +0 -1
- package/src/BaseLinearDisplay/components/BaseLinearDisplay.tsx +0 -117
- package/src/BaseLinearDisplay/components/Block.tsx +0 -77
- package/src/BaseLinearDisplay/components/BlockMsg.tsx +0 -42
- package/src/BaseLinearDisplay/components/LinearBlocks.tsx +0 -119
- package/src/BaseLinearDisplay/components/ServerSideRenderedBlockContent.tsx +0 -69
- package/src/BaseLinearDisplay/components/TooLargeMessage.tsx +0 -36
- package/src/BaseLinearDisplay/components/Tooltip.tsx +0 -107
- package/src/BaseLinearDisplay/index.ts +0 -12
- package/src/BaseLinearDisplay/models/BaseLinearDisplayModel.tsx +0 -768
- package/src/BaseLinearDisplay/models/configSchema.ts +0 -59
- package/src/BaseLinearDisplay/models/serverSideRenderedBlock.ts +0 -318
- package/src/BaseLinearDisplay/models/util.ts +0 -67
- package/src/BasicTrack/configSchema.ts +0 -23
- package/src/BasicTrack/index.ts +0 -18
- package/src/FeatureTrack/configSchema.ts +0 -27
- package/src/FeatureTrack/index.ts +0 -18
- package/src/LaunchLinearGenomeView/index.ts +0 -66
- package/src/LinearBareDisplay/configSchema.ts +0 -27
- package/src/LinearBareDisplay/index.test.js +0 -34
- package/src/LinearBareDisplay/index.ts +0 -25
- package/src/LinearBareDisplay/model.ts +0 -53
- package/src/LinearBasicDisplay/components/SetMaxHeight.tsx +0 -73
- package/src/LinearBasicDisplay/configSchema.ts +0 -27
- package/src/LinearBasicDisplay/index.ts +0 -25
- package/src/LinearBasicDisplay/model.ts +0 -214
- package/src/LinearGenomeView/README.md +0 -9
- package/src/LinearGenomeView/components/CenterLine.tsx +0 -65
- package/src/LinearGenomeView/components/Cytobands.tsx +0 -154
- package/src/LinearGenomeView/components/ExportSvgDialog.tsx +0 -149
- package/src/LinearGenomeView/components/GetSequenceDialog.tsx +0 -269
- package/src/LinearGenomeView/components/Gridlines.tsx +0 -119
- package/src/LinearGenomeView/components/Header.tsx +0 -126
- package/src/LinearGenomeView/components/HelpDialog.tsx +0 -69
- package/src/LinearGenomeView/components/ImportForm.tsx +0 -217
- package/src/LinearGenomeView/components/LinearGenomeView.test.tsx +0 -167
- package/src/LinearGenomeView/components/LinearGenomeView.tsx +0 -72
- package/src/LinearGenomeView/components/MiniControls.tsx +0 -55
- package/src/LinearGenomeView/components/OverviewRubberband.tsx +0 -219
- package/src/LinearGenomeView/components/OverviewScalebar.tsx +0 -345
- package/src/LinearGenomeView/components/RefNameAutocomplete.tsx +0 -321
- package/src/LinearGenomeView/components/Rubberband.tsx +0 -89
- package/src/LinearGenomeView/components/RubberbandSpan.tsx +0 -99
- package/src/LinearGenomeView/components/Scalebar.test.tsx +0 -145
- package/src/LinearGenomeView/components/Scalebar.tsx +0 -199
- package/src/LinearGenomeView/components/SearchBox.tsx +0 -123
- package/src/LinearGenomeView/components/SearchResultsDialog.tsx +0 -57
- package/src/LinearGenomeView/components/SearchResultsTable.tsx +0 -121
- package/src/LinearGenomeView/components/SequenceSearchDialog.tsx +0 -136
- package/src/LinearGenomeView/components/TrackContainer.tsx +0 -180
- package/src/LinearGenomeView/components/TrackLabel.tsx +0 -143
- package/src/LinearGenomeView/components/TracksContainer.tsx +0 -114
- package/src/LinearGenomeView/components/VerticalGuide.tsx +0 -37
- package/src/LinearGenomeView/components/ZoomControls.tsx +0 -62
- package/src/LinearGenomeView/components/__snapshots__/LinearGenomeView.test.tsx.snap +0 -1520
- package/src/LinearGenomeView/components/hooks.ts +0 -306
- package/src/LinearGenomeView/components/util.ts +0 -76
- package/src/LinearGenomeView/hg38DisplayedRegions.json +0 -3187
- package/src/LinearGenomeView/index.test.ts +0 -993
- package/src/LinearGenomeView/index.ts +0 -17
- package/src/LinearGenomeView/model.ts +0 -1532
- package/src/LinearGenomeView/svgcomponents/SVGBackground.tsx +0 -21
- package/src/LinearGenomeView/svgcomponents/SVGHeader.tsx +0 -93
- package/src/LinearGenomeView/svgcomponents/SVGLinearGenomeView.tsx +0 -114
- package/src/LinearGenomeView/svgcomponents/SVGRegionSeparators.tsx +0 -31
- package/src/LinearGenomeView/svgcomponents/SVGRuler.tsx +0 -125
- package/src/LinearGenomeView/svgcomponents/SVGScalebar.tsx +0 -57
- package/src/LinearGenomeView/svgcomponents/SVGTrackLabel.tsx +0 -47
- package/src/LinearGenomeView/svgcomponents/SVGTracks.tsx +0 -67
- package/src/LinearGenomeView/util.test.ts +0 -33
- package/src/LinearGenomeView/util.ts +0 -182
- package/src/LinearGenomeView/volvoxDisplayedRegions.json +0 -16
- package/src/index.ts +0 -85
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import { Button, DialogActions, DialogContent, Divider } from '@mui/material'
|
|
3
|
-
import { Dialog } from '@jbrowse/core/ui'
|
|
4
|
-
|
|
5
|
-
export default function HelpDialog({
|
|
6
|
-
handleClose,
|
|
7
|
-
}: {
|
|
8
|
-
handleClose: () => void
|
|
9
|
-
}) {
|
|
10
|
-
return (
|
|
11
|
-
<Dialog
|
|
12
|
-
open
|
|
13
|
-
maxWidth="xl"
|
|
14
|
-
onClose={handleClose}
|
|
15
|
-
title="Using the search box"
|
|
16
|
-
>
|
|
17
|
-
<DialogContent>
|
|
18
|
-
<h3>Searching</h3>
|
|
19
|
-
<ul>
|
|
20
|
-
<li>
|
|
21
|
-
Jump to a feature or reference sequence by typing its name in the
|
|
22
|
-
location box and pressing Enter.
|
|
23
|
-
</li>
|
|
24
|
-
<li>
|
|
25
|
-
Jump to a specific region by typing the region into the location box
|
|
26
|
-
as: <code>ref:start..end</code> or <code>ref:start-end</code>.
|
|
27
|
-
Commas are allowed in the start and end coordinates. A
|
|
28
|
-
space-separated list of locstrings can be used to open up multiple
|
|
29
|
-
chromosomes at a time
|
|
30
|
-
</li>
|
|
31
|
-
</ul>
|
|
32
|
-
<h3>Example Searches</h3>
|
|
33
|
-
<ul>
|
|
34
|
-
<li>
|
|
35
|
-
<code>BRCA</code> - searches for the feature named BRCA
|
|
36
|
-
</li>
|
|
37
|
-
<li>
|
|
38
|
-
<code>chr4</code> - jumps to chromosome 4
|
|
39
|
-
</li>
|
|
40
|
-
<li>
|
|
41
|
-
<code>chr4:79,500,000..80,000,000</code> - jumps the region on
|
|
42
|
-
chromosome 4 between 79.5Mb and 80Mb.
|
|
43
|
-
</li>
|
|
44
|
-
<li>
|
|
45
|
-
<code>chr1:1-100 chr2:1-100</code> - create a split view of
|
|
46
|
-
chr1:1-100 and chr2:1-100
|
|
47
|
-
</li>
|
|
48
|
-
<li>
|
|
49
|
-
<code>chr1 chr2 chr3</code> - open up multiple chromosomes at once
|
|
50
|
-
</li>
|
|
51
|
-
<li>
|
|
52
|
-
<code>chr1:1-100[rev] chr2:1-100</code> - open up the first region
|
|
53
|
-
in the horizontally flipped orientation
|
|
54
|
-
</li>
|
|
55
|
-
<li>
|
|
56
|
-
<code>chr1 100 200</code> - use whitespace separated refname, start,
|
|
57
|
-
end
|
|
58
|
-
</li>
|
|
59
|
-
</ul>
|
|
60
|
-
</DialogContent>
|
|
61
|
-
<Divider />
|
|
62
|
-
<DialogActions>
|
|
63
|
-
<Button onClick={() => handleClose()} color="primary">
|
|
64
|
-
Close
|
|
65
|
-
</Button>
|
|
66
|
-
</DialogActions>
|
|
67
|
-
</Dialog>
|
|
68
|
-
)
|
|
69
|
-
}
|
|
@@ -1,217 +0,0 @@
|
|
|
1
|
-
import React, { useState, useEffect } from 'react'
|
|
2
|
-
import { makeStyles } from 'tss-react/mui'
|
|
3
|
-
import { observer } from 'mobx-react'
|
|
4
|
-
import { getSession } from '@jbrowse/core/util'
|
|
5
|
-
import {
|
|
6
|
-
Button,
|
|
7
|
-
FormControl,
|
|
8
|
-
Container,
|
|
9
|
-
Grid,
|
|
10
|
-
CircularProgress,
|
|
11
|
-
} from '@mui/material'
|
|
12
|
-
import { ErrorMessage, AssemblySelector } from '@jbrowse/core/ui'
|
|
13
|
-
import BaseResult from '@jbrowse/core/TextSearch/BaseResults'
|
|
14
|
-
|
|
15
|
-
// icons
|
|
16
|
-
import CloseIcon from '@mui/icons-material/Close'
|
|
17
|
-
|
|
18
|
-
// locals
|
|
19
|
-
import RefNameAutocomplete from './RefNameAutocomplete'
|
|
20
|
-
import { fetchResults, splitLast } from './util'
|
|
21
|
-
import { LinearGenomeViewModel } from '..'
|
|
22
|
-
|
|
23
|
-
const useStyles = makeStyles()(theme => ({
|
|
24
|
-
importFormContainer: {
|
|
25
|
-
padding: theme.spacing(2),
|
|
26
|
-
},
|
|
27
|
-
button: {
|
|
28
|
-
margin: theme.spacing(2),
|
|
29
|
-
},
|
|
30
|
-
container: {
|
|
31
|
-
padding: theme.spacing(4),
|
|
32
|
-
},
|
|
33
|
-
}))
|
|
34
|
-
|
|
35
|
-
type LGV = LinearGenomeViewModel
|
|
36
|
-
|
|
37
|
-
export default observer(function ({ model }: { model: LGV }) {
|
|
38
|
-
const { classes } = useStyles()
|
|
39
|
-
const session = getSession(model)
|
|
40
|
-
const { assemblyNames, assemblyManager, textSearchManager } = session
|
|
41
|
-
const { rankSearchResults, error } = model
|
|
42
|
-
const [selectedAsm, setSelectedAsm] = useState(assemblyNames[0])
|
|
43
|
-
const [option, setOption] = useState<BaseResult>()
|
|
44
|
-
const searchScope = model.searchScope(selectedAsm)
|
|
45
|
-
const assembly = assemblyManager.get(selectedAsm)
|
|
46
|
-
const assemblyError = assemblyNames.length
|
|
47
|
-
? assembly?.error
|
|
48
|
-
: 'No configured assemblies'
|
|
49
|
-
const displayError = assemblyError || error
|
|
50
|
-
const [value, setValue] = useState('')
|
|
51
|
-
const regions = assembly?.regions
|
|
52
|
-
const assemblyLoaded = !!regions
|
|
53
|
-
const r0 = regions ? regions[0]?.refName : ''
|
|
54
|
-
|
|
55
|
-
// useEffect resets to an "initial state" of displaying first region from
|
|
56
|
-
// assembly after assembly change. needs to react to selectedAsm as well as
|
|
57
|
-
// r0 because changing assembly will run setValue('') and then r0 may not
|
|
58
|
-
// change if assembly names are the same across assemblies, but it still
|
|
59
|
-
// needs to be reset
|
|
60
|
-
useEffect(() => {
|
|
61
|
-
setValue(r0)
|
|
62
|
-
}, [r0, selectedAsm])
|
|
63
|
-
|
|
64
|
-
async function navToOption(option: BaseResult) {
|
|
65
|
-
const location = option.getLocation()
|
|
66
|
-
const trackId = option.getTrackId()
|
|
67
|
-
if (location) {
|
|
68
|
-
await model.navToLocString(location, selectedAsm)
|
|
69
|
-
if (trackId) {
|
|
70
|
-
model.showTrack(trackId)
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
// gets a string as input, or use stored option results from previous query,
|
|
76
|
-
// then re-query and
|
|
77
|
-
// 1) if it has multiple results: pop a dialog
|
|
78
|
-
// 2) if it's a single result navigate to it
|
|
79
|
-
// 3) else assume it's a locstring and navigate to it
|
|
80
|
-
async function handleSelectedRegion(input: string) {
|
|
81
|
-
try {
|
|
82
|
-
if (option?.getDisplayString() === input && option.hasLocation()) {
|
|
83
|
-
await navToOption(option)
|
|
84
|
-
} else if (option?.results?.length) {
|
|
85
|
-
model.setSearchResults(option.results, option.getLabel(), selectedAsm)
|
|
86
|
-
} else {
|
|
87
|
-
const [ref, rest] = splitLast(input, ':')
|
|
88
|
-
const allRefs = assembly?.allRefNamesWithLowerCase || []
|
|
89
|
-
if (
|
|
90
|
-
allRefs.includes(input) ||
|
|
91
|
-
(allRefs.includes(ref) && !Number.isNaN(Number.parseInt(rest, 10)))
|
|
92
|
-
) {
|
|
93
|
-
await model.navToLocString(input, selectedAsm)
|
|
94
|
-
} else {
|
|
95
|
-
const results = await fetchResults({
|
|
96
|
-
queryString: input,
|
|
97
|
-
searchType: 'exact',
|
|
98
|
-
searchScope,
|
|
99
|
-
rankSearchResults,
|
|
100
|
-
textSearchManager,
|
|
101
|
-
assembly,
|
|
102
|
-
})
|
|
103
|
-
|
|
104
|
-
if (results.length > 1) {
|
|
105
|
-
model.setSearchResults(results, input.toLowerCase(), selectedAsm)
|
|
106
|
-
} else if (results.length === 1) {
|
|
107
|
-
await navToOption(results[0])
|
|
108
|
-
} else {
|
|
109
|
-
await model.navToLocString(input, selectedAsm)
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
} catch (e) {
|
|
114
|
-
console.error(e)
|
|
115
|
-
session.notify(`${e}`, 'warning')
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
// implementation notes:
|
|
120
|
-
// having this wrapped in a form allows intuitive use of enter key to submit
|
|
121
|
-
return (
|
|
122
|
-
<div className={classes.container}>
|
|
123
|
-
{displayError ? <ErrorMessage error={displayError} /> : null}
|
|
124
|
-
<Container className={classes.importFormContainer}>
|
|
125
|
-
<form
|
|
126
|
-
onSubmit={async event => {
|
|
127
|
-
event.preventDefault()
|
|
128
|
-
model.setError(undefined)
|
|
129
|
-
if (value) {
|
|
130
|
-
// has it's own error handling
|
|
131
|
-
await handleSelectedRegion(value)
|
|
132
|
-
}
|
|
133
|
-
}}
|
|
134
|
-
>
|
|
135
|
-
<Grid
|
|
136
|
-
container
|
|
137
|
-
spacing={1}
|
|
138
|
-
justifyContent="center"
|
|
139
|
-
alignItems="center"
|
|
140
|
-
>
|
|
141
|
-
<Grid item>
|
|
142
|
-
<FormControl>
|
|
143
|
-
<AssemblySelector
|
|
144
|
-
onChange={val => setSelectedAsm(val)}
|
|
145
|
-
localStorageKey="lgv"
|
|
146
|
-
session={session}
|
|
147
|
-
selected={selectedAsm}
|
|
148
|
-
/>
|
|
149
|
-
</FormControl>
|
|
150
|
-
</Grid>
|
|
151
|
-
<Grid item>
|
|
152
|
-
{selectedAsm ? (
|
|
153
|
-
assemblyError ? (
|
|
154
|
-
<CloseIcon style={{ color: 'red' }} />
|
|
155
|
-
) : assemblyLoaded ? (
|
|
156
|
-
<FormControl>
|
|
157
|
-
<RefNameAutocomplete
|
|
158
|
-
fetchResults={queryString =>
|
|
159
|
-
fetchResults({
|
|
160
|
-
queryString,
|
|
161
|
-
assembly,
|
|
162
|
-
textSearchManager,
|
|
163
|
-
rankSearchResults,
|
|
164
|
-
searchScope,
|
|
165
|
-
})
|
|
166
|
-
}
|
|
167
|
-
model={model}
|
|
168
|
-
assemblyName={selectedAsm}
|
|
169
|
-
value={value}
|
|
170
|
-
minWidth={270}
|
|
171
|
-
onChange={str => setValue(str)}
|
|
172
|
-
onSelect={val => setOption(val)}
|
|
173
|
-
TextFieldProps={{
|
|
174
|
-
variant: 'outlined',
|
|
175
|
-
helperText:
|
|
176
|
-
'Enter sequence name, feature name, or location',
|
|
177
|
-
}}
|
|
178
|
-
/>
|
|
179
|
-
</FormControl>
|
|
180
|
-
) : (
|
|
181
|
-
<CircularProgress size={20} disableShrink />
|
|
182
|
-
)
|
|
183
|
-
) : null}
|
|
184
|
-
</Grid>
|
|
185
|
-
<Grid item>
|
|
186
|
-
<FormControl>
|
|
187
|
-
<Button
|
|
188
|
-
type="submit"
|
|
189
|
-
disabled={!value}
|
|
190
|
-
className={classes.button}
|
|
191
|
-
variant="contained"
|
|
192
|
-
color="primary"
|
|
193
|
-
>
|
|
194
|
-
Open
|
|
195
|
-
</Button>
|
|
196
|
-
</FormControl>
|
|
197
|
-
<FormControl>
|
|
198
|
-
<Button
|
|
199
|
-
disabled={!value}
|
|
200
|
-
className={classes.button}
|
|
201
|
-
onClick={() => {
|
|
202
|
-
model.setError(undefined)
|
|
203
|
-
model.showAllRegionsInAssembly(selectedAsm)
|
|
204
|
-
}}
|
|
205
|
-
variant="contained"
|
|
206
|
-
color="secondary"
|
|
207
|
-
>
|
|
208
|
-
Show all regions in assembly
|
|
209
|
-
</Button>
|
|
210
|
-
</FormControl>
|
|
211
|
-
</Grid>
|
|
212
|
-
</Grid>
|
|
213
|
-
</form>
|
|
214
|
-
</Container>
|
|
215
|
-
</div>
|
|
216
|
-
)
|
|
217
|
-
})
|
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import { fireEvent, render, waitFor } from '@testing-library/react'
|
|
3
|
-
import { createTestSession } from '@jbrowse/web/src/rootModel'
|
|
4
|
-
import 'requestidlecallback-polyfill'
|
|
5
|
-
|
|
6
|
-
// locals
|
|
7
|
-
import LinearGenomeView from './LinearGenomeView'
|
|
8
|
-
|
|
9
|
-
// mock
|
|
10
|
-
jest.mock('@jbrowse/web/src/makeWorkerInstance', () => () => {})
|
|
11
|
-
|
|
12
|
-
const assemblyConf = {
|
|
13
|
-
name: 'volMyt1',
|
|
14
|
-
sequence: {
|
|
15
|
-
trackId: 'sequenceConfigId',
|
|
16
|
-
type: 'ReferenceSequenceTrack',
|
|
17
|
-
adapter: {
|
|
18
|
-
type: 'FromConfigSequenceAdapter',
|
|
19
|
-
features: [
|
|
20
|
-
{
|
|
21
|
-
refName: 'ctgA',
|
|
22
|
-
uniqueId: 'firstId',
|
|
23
|
-
start: 0,
|
|
24
|
-
end: 10,
|
|
25
|
-
seq: 'cattgttgcg',
|
|
26
|
-
},
|
|
27
|
-
],
|
|
28
|
-
},
|
|
29
|
-
},
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
test('renders setup wizard', async () => {
|
|
33
|
-
const session = createTestSession()
|
|
34
|
-
session.addAssemblyConf(assemblyConf)
|
|
35
|
-
session.addView('LinearGenomeView', { id: 'lgv' })
|
|
36
|
-
const model = session.views[0]
|
|
37
|
-
model.setWidth(800)
|
|
38
|
-
const { findByText } = render(<LinearGenomeView model={model} />)
|
|
39
|
-
expect(model.displayedRegions.length).toEqual(0)
|
|
40
|
-
const elt = await findByText('Open')
|
|
41
|
-
await waitFor(() => expect(elt.getAttribute('disabled')).toBe(null))
|
|
42
|
-
fireEvent.click(elt)
|
|
43
|
-
await waitFor(() => expect(model.displayedRegions.length).toEqual(1), {
|
|
44
|
-
timeout: 15000,
|
|
45
|
-
})
|
|
46
|
-
}, 15000)
|
|
47
|
-
|
|
48
|
-
test('renders one track, one region', async () => {
|
|
49
|
-
const session = createTestSession()
|
|
50
|
-
session.addAssemblyConf(assemblyConf)
|
|
51
|
-
session.addTrackConf({
|
|
52
|
-
trackId: 'testConfig',
|
|
53
|
-
assemblyNames: ['volMyt1'],
|
|
54
|
-
name: 'Foo Track',
|
|
55
|
-
type: 'BasicTrack',
|
|
56
|
-
adapter: { type: 'FromConfigAdapter', features: [] },
|
|
57
|
-
})
|
|
58
|
-
session.addView('LinearGenomeView', {
|
|
59
|
-
type: 'LinearGenomeView',
|
|
60
|
-
id: 'lgv',
|
|
61
|
-
offsetPx: 0,
|
|
62
|
-
bpPerPx: 1,
|
|
63
|
-
tracks: [
|
|
64
|
-
{
|
|
65
|
-
id: 'foo',
|
|
66
|
-
type: 'BasicTrack',
|
|
67
|
-
height: 20,
|
|
68
|
-
configuration: 'testConfig',
|
|
69
|
-
displays: [
|
|
70
|
-
{
|
|
71
|
-
type: 'LinearBareDisplay',
|
|
72
|
-
configuration: 'testConfig-LinearBareDisplay',
|
|
73
|
-
},
|
|
74
|
-
],
|
|
75
|
-
},
|
|
76
|
-
],
|
|
77
|
-
displayedRegions: [
|
|
78
|
-
{ assemblyName: 'volMyt1', refName: 'ctgA', start: 0, end: 100 },
|
|
79
|
-
],
|
|
80
|
-
})
|
|
81
|
-
const model = session.views[0]
|
|
82
|
-
model.setWidth(800)
|
|
83
|
-
const { container, queryAllByTestId, getByPlaceholderText, findByText } =
|
|
84
|
-
render(<LinearGenomeView model={model} />)
|
|
85
|
-
await findByText('Foo Track')
|
|
86
|
-
// test needs to wait until it's updated to display 100 bp in the header to
|
|
87
|
-
// make snapshot pass
|
|
88
|
-
await findByText('100bp')
|
|
89
|
-
|
|
90
|
-
await waitFor(() => {
|
|
91
|
-
expect(
|
|
92
|
-
(getByPlaceholderText('Search for location') as HTMLInputElement).value,
|
|
93
|
-
).toEqual('ctgA:1..100')
|
|
94
|
-
})
|
|
95
|
-
await waitFor(() => expect(queryAllByTestId('svgfeatures').length).toBe(1))
|
|
96
|
-
// snapshot has no features rendered
|
|
97
|
-
expect(container).toMatchSnapshot()
|
|
98
|
-
})
|
|
99
|
-
|
|
100
|
-
test('renders two tracks, two regions', async () => {
|
|
101
|
-
const session = createTestSession()
|
|
102
|
-
session.addAssemblyConf(assemblyConf)
|
|
103
|
-
session.addTrackConf({
|
|
104
|
-
trackId: 'testConfig',
|
|
105
|
-
name: 'Foo Track',
|
|
106
|
-
assemblyNames: ['volMyt1'],
|
|
107
|
-
type: 'BasicTrack',
|
|
108
|
-
adapter: { type: 'FromConfigAdapter', features: [] },
|
|
109
|
-
})
|
|
110
|
-
|
|
111
|
-
session.addTrackConf({
|
|
112
|
-
trackId: 'testConfig2',
|
|
113
|
-
name: 'Bar Track',
|
|
114
|
-
assemblyNames: ['volMyt1'],
|
|
115
|
-
type: 'BasicTrack',
|
|
116
|
-
adapter: { type: 'FromConfigAdapter', features: [] },
|
|
117
|
-
})
|
|
118
|
-
session.addView('LinearGenomeView', {
|
|
119
|
-
id: 'lgv',
|
|
120
|
-
offsetPx: 0,
|
|
121
|
-
bpPerPx: 1,
|
|
122
|
-
displayedRegions: [
|
|
123
|
-
{ assemblyName: 'volMyt1', refName: 'ctgA', start: 0, end: 100 },
|
|
124
|
-
{
|
|
125
|
-
assemblyName: 'volMyt1',
|
|
126
|
-
refName: 'ctgB',
|
|
127
|
-
start: 1000,
|
|
128
|
-
end: 2000,
|
|
129
|
-
},
|
|
130
|
-
],
|
|
131
|
-
tracks: [
|
|
132
|
-
{
|
|
133
|
-
id: 'foo',
|
|
134
|
-
type: 'BasicTrack',
|
|
135
|
-
height: 20,
|
|
136
|
-
configuration: 'testConfig',
|
|
137
|
-
displays: [
|
|
138
|
-
{
|
|
139
|
-
type: 'LinearBareDisplay',
|
|
140
|
-
configuration: 'testConfig-LinearBareDisplay',
|
|
141
|
-
},
|
|
142
|
-
],
|
|
143
|
-
},
|
|
144
|
-
{
|
|
145
|
-
id: 'bar',
|
|
146
|
-
type: 'BasicTrack',
|
|
147
|
-
height: 20,
|
|
148
|
-
configuration: 'testConfig2',
|
|
149
|
-
displays: [
|
|
150
|
-
{
|
|
151
|
-
type: 'LinearBareDisplay',
|
|
152
|
-
configuration: 'testConfig2-LinearBareDisplay',
|
|
153
|
-
},
|
|
154
|
-
],
|
|
155
|
-
},
|
|
156
|
-
],
|
|
157
|
-
})
|
|
158
|
-
const model = session.views[0]
|
|
159
|
-
model.setWidth(800)
|
|
160
|
-
const { container, findByText, queryAllByTestId } = render(
|
|
161
|
-
<LinearGenomeView model={model} />,
|
|
162
|
-
)
|
|
163
|
-
await findByText('Foo Track')
|
|
164
|
-
await findByText('798bp')
|
|
165
|
-
await waitFor(() => expect(queryAllByTestId('svgfeatures').length).toBe(4))
|
|
166
|
-
expect(container).toMatchSnapshot()
|
|
167
|
-
}, 15000)
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
import { Button, Paper, Typography } from '@mui/material'
|
|
3
|
-
import { makeStyles } from 'tss-react/mui'
|
|
4
|
-
import { TrackSelector as TrackSelectorIcon } from '@jbrowse/core/ui/Icons'
|
|
5
|
-
import { LoadingEllipses } from '@jbrowse/core/ui'
|
|
6
|
-
import { observer } from 'mobx-react'
|
|
7
|
-
|
|
8
|
-
// locals
|
|
9
|
-
import { LinearGenomeViewModel } from '..'
|
|
10
|
-
import TrackContainer from './TrackContainer'
|
|
11
|
-
import TracksContainer from './TracksContainer'
|
|
12
|
-
import ImportForm from './ImportForm'
|
|
13
|
-
|
|
14
|
-
type LGV = LinearGenomeViewModel
|
|
15
|
-
|
|
16
|
-
const useStyles = makeStyles()(theme => ({
|
|
17
|
-
note: {
|
|
18
|
-
textAlign: 'center',
|
|
19
|
-
paddingTop: theme.spacing(1),
|
|
20
|
-
paddingBottom: theme.spacing(1),
|
|
21
|
-
},
|
|
22
|
-
}))
|
|
23
|
-
|
|
24
|
-
const LinearGenomeView = observer(({ model }: { model: LGV }) => {
|
|
25
|
-
const { tracks, error, initialized, hasDisplayedRegions } = model
|
|
26
|
-
const { classes } = useStyles()
|
|
27
|
-
|
|
28
|
-
if (!initialized && !error) {
|
|
29
|
-
return <LoadingEllipses variant="h6" />
|
|
30
|
-
}
|
|
31
|
-
if (!hasDisplayedRegions || error) {
|
|
32
|
-
return <ImportForm model={model} />
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
const MiniControlsComponent = model.MiniControlsComponent()
|
|
36
|
-
const HeaderComponent = model.HeaderComponent()
|
|
37
|
-
|
|
38
|
-
return (
|
|
39
|
-
<div style={{ position: 'relative' }}>
|
|
40
|
-
<HeaderComponent model={model} />
|
|
41
|
-
<MiniControlsComponent model={model} />
|
|
42
|
-
<TracksContainer model={model}>
|
|
43
|
-
{!tracks.length ? (
|
|
44
|
-
<Paper variant="outlined" className={classes.note}>
|
|
45
|
-
{!model.hideNoTracksActive ? (
|
|
46
|
-
<>
|
|
47
|
-
<Typography>No tracks active.</Typography>
|
|
48
|
-
<Button
|
|
49
|
-
variant="contained"
|
|
50
|
-
color="primary"
|
|
51
|
-
onClick={model.activateTrackSelector}
|
|
52
|
-
style={{ zIndex: 1000 }}
|
|
53
|
-
startIcon={<TrackSelectorIcon />}
|
|
54
|
-
>
|
|
55
|
-
Open track selector
|
|
56
|
-
</Button>
|
|
57
|
-
</>
|
|
58
|
-
) : (
|
|
59
|
-
<div style={{ height: '48px' }}></div>
|
|
60
|
-
)}
|
|
61
|
-
</Paper>
|
|
62
|
-
) : (
|
|
63
|
-
tracks.map(track => (
|
|
64
|
-
<TrackContainer key={track.id} model={model} track={track} />
|
|
65
|
-
))
|
|
66
|
-
)}
|
|
67
|
-
</TracksContainer>
|
|
68
|
-
</div>
|
|
69
|
-
)
|
|
70
|
-
})
|
|
71
|
-
|
|
72
|
-
export default LinearGenomeView
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react'
|
|
2
|
-
import { observer } from 'mobx-react'
|
|
3
|
-
import { IconButton, Paper } from '@mui/material'
|
|
4
|
-
import Menu from '@jbrowse/core/ui/Menu'
|
|
5
|
-
|
|
6
|
-
// icons
|
|
7
|
-
import ZoomIn from '@mui/icons-material/ZoomIn'
|
|
8
|
-
import ZoomOut from '@mui/icons-material/ZoomOut'
|
|
9
|
-
import ArrowDown from '@mui/icons-material/KeyboardArrowDown'
|
|
10
|
-
|
|
11
|
-
// locals
|
|
12
|
-
import { LinearGenomeViewModel } from '..'
|
|
13
|
-
|
|
14
|
-
const MiniControls = observer((props: { model: LinearGenomeViewModel }) => {
|
|
15
|
-
const { model } = props
|
|
16
|
-
const { bpPerPx, maxBpPerPx, minBpPerPx, scaleFactor, hideHeader } = model
|
|
17
|
-
const [anchorEl, setAnchorEl] = useState<HTMLElement>()
|
|
18
|
-
|
|
19
|
-
return hideHeader ? (
|
|
20
|
-
<div style={{ position: 'absolute', right: '0px', zIndex: '1001' }}>
|
|
21
|
-
<Paper style={{ background: '#aaa7' }}>
|
|
22
|
-
<IconButton onClick={event => setAnchorEl(event.currentTarget)}>
|
|
23
|
-
<ArrowDown fontSize="small" />
|
|
24
|
-
</IconButton>
|
|
25
|
-
|
|
26
|
-
<IconButton
|
|
27
|
-
data-testid="zoom_out"
|
|
28
|
-
onClick={() => model.zoom(bpPerPx * 2)}
|
|
29
|
-
disabled={bpPerPx >= maxBpPerPx - 0.0001 || scaleFactor !== 1}
|
|
30
|
-
>
|
|
31
|
-
<ZoomOut fontSize="small" />
|
|
32
|
-
</IconButton>
|
|
33
|
-
<IconButton
|
|
34
|
-
data-testid="zoom_in"
|
|
35
|
-
onClick={() => model.zoom(model.bpPerPx / 2)}
|
|
36
|
-
disabled={bpPerPx <= minBpPerPx + 0.0001 || scaleFactor !== 1}
|
|
37
|
-
>
|
|
38
|
-
<ZoomIn fontSize="small" />
|
|
39
|
-
</IconButton>
|
|
40
|
-
<Menu
|
|
41
|
-
anchorEl={anchorEl}
|
|
42
|
-
open={Boolean(anchorEl)}
|
|
43
|
-
onMenuItemClick={(_, callback) => {
|
|
44
|
-
callback()
|
|
45
|
-
setAnchorEl(undefined)
|
|
46
|
-
}}
|
|
47
|
-
onClose={() => setAnchorEl(undefined)}
|
|
48
|
-
menuItems={model.menuItems()}
|
|
49
|
-
/>
|
|
50
|
-
</Paper>
|
|
51
|
-
</div>
|
|
52
|
-
) : null
|
|
53
|
-
})
|
|
54
|
-
|
|
55
|
-
export default MiniControls
|