higlass 1.13.5 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -54
- package/app/globals.d.ts +1 -1
- package/app/missing-types.d.ts +4 -1
- package/app/scripts/AddTrackDialog.jsx +11 -4
- package/app/scripts/AddTrackPositionMenu.jsx +28 -7
- package/app/scripts/Annotations1dTrack.js +90 -251
- package/app/scripts/Annotations2dTrack.js +12 -7
- package/app/scripts/Autocomplete.jsx +13 -28
- package/app/scripts/AxisPixi.js +6 -10
- package/app/scripts/BarTrack.js +3 -3
- package/app/scripts/BedLikeTrack.js +556 -449
- package/app/scripts/Button.jsx +1 -1
- package/app/scripts/CNVIntervalTrack.js +1 -1
- package/app/scripts/CenterTrack.jsx +8 -7
- package/app/scripts/Chromosome2DAnnotations.js +1 -1
- package/app/scripts/Chromosome2DLabels.js +1 -1
- package/app/scripts/ChromosomeGrid.js +49 -38
- package/app/scripts/ChromosomeInfo.js +1 -1
- package/app/scripts/CombinedTrack.js +3 -1
- package/app/scripts/ConfigTrackMenu.jsx +1 -1
- package/app/scripts/ConfigViewMenu.jsx +2 -2
- package/app/scripts/ContextMenuContainer.jsx +4 -2
- package/app/scripts/ContextMenuItem.jsx +14 -2
- package/app/scripts/CrossRule.js +1 -1
- package/app/scripts/CustomTrackDialog.jsx +2 -2
- package/app/scripts/Dialog.jsx +2 -2
- package/app/scripts/DragListeningDiv.jsx +1 -1
- package/app/scripts/DraggableDiv.jsx +2 -3
- package/app/scripts/ExportLinkDialog.jsx +1 -1
- package/app/scripts/FilledLine.js +349 -0
- package/app/scripts/GalleryTracks.jsx +77 -78
- package/app/scripts/GenomePositionSearchBox.jsx +184 -482
- package/app/scripts/HeatmapOptions.jsx +4 -2
- package/app/scripts/HeatmapTiledPixiTrack.js +23 -32
- package/app/scripts/HiGlassComponent.jsx +515 -444
- package/app/scripts/HiGlassComponentContext.js +5 -0
- package/app/scripts/Horizontal1dHeatmapTrack.js +1 -1
- package/app/scripts/Horizontal2DDomainsTrack.js +1 -1
- package/app/scripts/HorizontalChromosomeLabels.js +28 -22
- package/app/scripts/HorizontalGeneAnnotationsTrack.js +1 -1
- package/app/scripts/HorizontalHeatmapTrack.js +2 -2
- package/app/scripts/HorizontalMultivecTrack.js +6 -7
- package/app/scripts/HorizontalRule.js +1 -2
- package/app/scripts/HorizontalTiled1DPixiTrack.js +4 -4
- package/app/scripts/HorizontalTiledPlot.jsx +9 -9
- package/app/scripts/LeftTrackModifier.js +4 -0
- package/app/scripts/ListWrapper.jsx +1 -2
- package/app/scripts/MapboxTilesTrack.js +1 -2
- package/app/scripts/Modal.jsx +2 -2
- package/app/scripts/MoveableTrack.jsx +10 -12
- package/app/scripts/NestedContextMenu.jsx +2 -1
- package/app/scripts/OSMTileIdsTrack.js +1 -1
- package/app/scripts/OverlayTrack.js +4 -4
- package/app/scripts/PixiTrack.js +27 -13
- package/app/scripts/PlotTypeChooser.jsx +3 -4
- package/app/scripts/SearchField.js +5 -5
- package/app/scripts/SeriesListItems.jsx +3 -4
- package/app/scripts/SeriesListMenu.jsx +95 -53
- package/app/scripts/SeriesListSubmenuMixin.jsx +2 -1
- package/app/scripts/SketchInlinePicker.jsx +2 -2
- package/app/scripts/SortableList.jsx +1 -1
- package/app/scripts/Tiled1DPixiTrack.js +4 -1
- package/app/scripts/TiledPixiTrack.js +244 -102
- package/app/scripts/TiledPlot.jsx +565 -118
- package/app/scripts/TilesetFinder.jsx +12 -4
- package/app/scripts/Track.js +1 -1
- package/app/scripts/TrackArea.jsx +4 -0
- package/app/scripts/TrackControl.jsx +2 -2
- package/app/scripts/TrackRenderer.jsx +32 -33
- package/app/scripts/ValueIntervalTrack.js +1 -1
- package/app/scripts/VerticalRule.js +2 -2
- package/app/scripts/VerticalTiledPlot.jsx +7 -7
- package/app/scripts/ViewConfigEditor.jsx +1 -1
- package/app/scripts/ViewContextMenu.jsx +53 -5
- package/app/scripts/ViewHeader.jsx +9 -9
- package/app/scripts/ViewportTracker2D.js +1 -1
- package/app/scripts/api.js +92 -12
- package/app/scripts/configs/available-track-types.js +1 -1
- package/app/scripts/configs/index.js +6 -1
- package/app/scripts/configs/positions-by-datatype.js +2 -2
- package/app/scripts/configs/primitives.js +2 -0
- package/app/scripts/configs/themes.js +0 -1
- package/app/scripts/configs/tracks-info-by-type.js +11 -8
- package/app/scripts/configs/tracks-info.js +3 -2
- package/app/scripts/d3-context-menu.js +3 -4
- package/app/scripts/data-fetchers/DataFetcher.js +35 -36
- package/app/scripts/data-fetchers/genbank-fetcher.js +13 -22
- package/app/scripts/data-fetchers/local-tile-fetcher.js +10 -8
- package/app/scripts/hglib.jsx +62 -71
- package/app/scripts/hocs/with-modal.jsx +32 -10
- package/app/scripts/hocs/with-pub-sub.js +12 -3
- package/app/scripts/hocs/with-theme.jsx +21 -14
- package/app/scripts/icons.jsx +3 -2
- package/app/scripts/mixwith.js +2 -2
- package/app/scripts/options-info.js +49 -11
- package/app/scripts/plugins/get-data-fetcher.js +2 -3
- package/app/scripts/services/chrom-info.js +32 -4
- package/app/scripts/services/element-resize-listener.js +2 -2
- package/app/scripts/services/index.js +0 -1
- package/app/scripts/services/tile-proxy.js +368 -285
- package/app/scripts/services/worker.js +31 -28
- package/app/scripts/test-helpers/index.js +2 -1
- package/app/scripts/test-helpers/test-helpers.jsx +157 -69
- package/app/scripts/types.ts +118 -47
- package/app/scripts/utils/LruCache.js +3 -2
- package/app/scripts/utils/assert.js +19 -0
- package/app/scripts/utils/background-task-scheduler.js +2 -0
- package/app/scripts/utils/color-domain-to-rgba-array.js +13 -3
- package/app/scripts/utils/copy-text-to-clipboard.js +36 -0
- package/app/scripts/utils/decompress.js +33 -0
- package/app/scripts/utils/default-tracks.js +46 -0
- package/app/scripts/utils/dict-items.js +1 -0
- package/app/scripts/utils/dict-keys.js +1 -0
- package/app/scripts/utils/dict-values.js +1 -0
- package/app/scripts/utils/expand-combined-tracks.js +11 -7
- package/app/scripts/utils/fill-in-min-widths.js +47 -21
- package/app/scripts/utils/flatten.js +0 -1
- package/app/scripts/utils/get-aggregation-function.js +1 -1
- package/app/scripts/utils/get-default-track-for-datatype.js +37 -10
- package/app/scripts/utils/get-default-tracks-for-datatype.ts +46 -0
- package/app/scripts/utils/get-higlass-components.js +27 -3
- package/app/scripts/utils/get-track-position-by-uid.js +8 -1
- package/app/scripts/utils/get-xylofon.js +12 -9
- package/app/scripts/utils/has-parent.js +5 -5
- package/app/scripts/utils/hex-string-to-int.js +1 -1
- package/app/scripts/utils/index.js +1 -0
- package/app/scripts/utils/interval-tree.js +222 -177
- package/app/scripts/utils/load-chrom-infos.js +4 -1
- package/app/scripts/utils/pixi-text-to-svg.js +5 -9
- package/app/scripts/utils/positioned-tracks-to-all-tracks.js +55 -0
- package/app/scripts/utils/range-query-2d.js +3 -3
- package/app/scripts/utils/reduce.js +12 -5
- package/app/scripts/utils/segments-to-rows.js +14 -11
- package/app/scripts/utils/svg-line.js +7 -8
- package/app/scripts/utils/type-guards.js +16 -7
- package/app/scripts/utils/visit-positioned-tracks.js +9 -4
- package/app/styles/AddTrackPositionMenu.module.scss +37 -0
- package/app/styles/HiGlass.module.scss +3 -1
- package/app/styles/d3-context-menu.css +0 -1
- package/app/styles/prism.css +1 -0
- package/dist/app/schema.json +525 -0
- package/dist/app/scripts/AddTrackDialog.d.ts +64 -0
- package/dist/app/scripts/AddTrackPositionMenu.d.ts +5 -0
- package/dist/app/scripts/Annotations1dTrack.d.ts +15 -0
- package/dist/app/scripts/Annotations2dTrack.d.ts +95 -0
- package/dist/app/scripts/ArrowheadDomainsTrack.d.ts +36 -0
- package/dist/app/scripts/Autocomplete.d.ts +102 -0
- package/dist/app/scripts/AxisPixi.d.ts +25 -0
- package/dist/app/scripts/BarTrack.d.ts +28 -0
- package/dist/app/scripts/BedLikeTrack.d.ts +84 -0
- package/dist/app/scripts/Button.d.ts +3 -0
- package/dist/app/scripts/CNVIntervalTrack.d.ts +12 -0
- package/dist/app/scripts/CenterTiledPlot.d.ts +3 -0
- package/dist/app/scripts/CenterTrack.d.ts +92 -0
- package/dist/app/scripts/Chromosome2DAnnotations.d.ts +10 -0
- package/dist/app/scripts/Chromosome2DLabels.d.ts +13 -0
- package/dist/app/scripts/ChromosomeGrid.d.ts +24 -0
- package/dist/app/scripts/ChromosomeInfo.d.ts +14 -0
- package/dist/app/scripts/CloseTrackMenu.d.ts +10 -0
- package/dist/app/scripts/CombinedTrack.d.ts +32 -0
- package/dist/app/scripts/ConfigTrackMenu.d.ts +10 -0
- package/dist/app/scripts/ConfigViewMenu.d.ts +34 -0
- package/dist/app/scripts/ConfigureSeriesMenu.d.ts +3 -0
- package/dist/app/scripts/ContextMenuContainer.d.ts +36 -0
- package/dist/app/scripts/ContextMenuItem.d.ts +34 -0
- package/dist/app/scripts/Cross.d.ts +3 -0
- package/dist/app/scripts/CrossRule.d.ts +24 -0
- package/dist/app/scripts/CustomTrackDialog.d.ts +17 -0
- package/dist/app/scripts/Dialog.d.ts +5 -0
- package/dist/app/scripts/DivergentBarTrack.d.ts +4 -0
- package/dist/app/scripts/DragListeningDiv.d.ts +32 -0
- package/dist/app/scripts/DraggableDiv.d.ts +63 -0
- package/dist/app/scripts/ExportLinkDialog.d.ts +21 -0
- package/dist/app/scripts/FilledLine.d.ts +5 -0
- package/dist/app/scripts/FixedTrack.d.ts +5 -0
- package/dist/app/scripts/GalleryTracks.d.ts +20 -0
- package/dist/app/scripts/GenomePositionSearchBox.d.ts +95 -0
- package/dist/app/scripts/HeatmapOptions.d.ts +30 -0
- package/dist/app/scripts/HeatmapTiledPixiTrack.d.ts +184 -0
- package/dist/app/scripts/HiGlassComponent.d.ts +762 -0
- package/dist/app/scripts/HiGlassComponentContext.d.ts +3 -0
- package/dist/app/scripts/HiGlassTrackComponent.d.ts +37 -0
- package/dist/app/scripts/Horizontal1dHeatmapTrack.d.ts +9 -0
- package/dist/app/scripts/Horizontal2DDomainsTrack.d.ts +21 -0
- package/dist/app/scripts/HorizontalChromosomeLabels.d.ts +47 -0
- package/dist/app/scripts/HorizontalGeneAnnotationsTrack.d.ts +25 -0
- package/dist/app/scripts/HorizontalHeatmapTrack.d.ts +12 -0
- package/dist/app/scripts/HorizontalItem.d.ts +3 -0
- package/dist/app/scripts/HorizontalLine1DPixiTrack.d.ts +23 -0
- package/dist/app/scripts/HorizontalMultivecTrack.d.ts +50 -0
- package/dist/app/scripts/HorizontalPoint1DPixiTrack.d.ts +5 -0
- package/dist/app/scripts/HorizontalRule.d.ts +22 -0
- package/dist/app/scripts/HorizontalTiled1DPixiTrack.d.ts +26 -0
- package/dist/app/scripts/HorizontalTiledPlot.d.ts +49 -0
- package/dist/app/scripts/HorizontalTrack.d.ts +6 -0
- package/dist/app/scripts/Id2DTiledPixiTrack.d.ts +10 -0
- package/dist/app/scripts/IdHorizontal1DTiledPixiTrack.d.ts +6 -0
- package/dist/app/scripts/IdVertical1DTiledPixiTrack.d.ts +7 -0
- package/dist/app/scripts/LeftAxisTrack.d.ts +9 -0
- package/dist/app/scripts/LeftTrackModifier.d.ts +29 -0
- package/dist/app/scripts/ListWrapper.d.ts +64 -0
- package/dist/app/scripts/MapboxTilesTrack.d.ts +9 -0
- package/dist/app/scripts/Modal.d.ts +5 -0
- package/dist/app/scripts/MoveableTrack.d.ts +18 -0
- package/dist/app/scripts/NestedContextMenu.d.ts +7 -0
- package/dist/app/scripts/OSMTileIdsTrack.d.ts +5 -0
- package/dist/app/scripts/OSMTilesTrack.d.ts +129 -0
- package/dist/app/scripts/OverlayTrack.d.ts +13 -0
- package/dist/app/scripts/PixiTrack.d.ts +174 -0
- package/dist/app/scripts/PlotTypeChooser.d.ts +25 -0
- package/dist/app/scripts/PopupMenu.d.ts +28 -0
- package/dist/app/scripts/RasterTilesTrack.d.ts +9 -0
- package/dist/app/scripts/RuleMixin.d.ts +2 -0
- package/dist/app/scripts/SVGTrack.d.ts +15 -0
- package/dist/app/scripts/SearchField.d.ts +13 -0
- package/dist/app/scripts/SeriesListItems.d.ts +2 -0
- package/dist/app/scripts/SeriesListMenu.d.ts +51 -0
- package/dist/app/scripts/SeriesListSubmenuMixin.d.ts +2 -0
- package/dist/app/scripts/SketchInlinePicker.d.ts +25 -0
- package/dist/app/scripts/SortableList.d.ts +22 -0
- package/dist/app/scripts/SquareMarkersTrack.d.ts +22 -0
- package/dist/app/scripts/Tiled1DPixiTrack.d.ts +60 -0
- package/dist/app/scripts/TiledPixiTrack.d.ts +369 -0
- package/dist/app/scripts/TiledPlot.d.ts +313 -0
- package/dist/app/scripts/TilesetFinder.d.ts +65 -0
- package/dist/app/scripts/TopAxisTrack.d.ts +9 -0
- package/dist/app/scripts/Track.d.ts +196 -0
- package/dist/app/scripts/TrackArea.d.ts +26 -0
- package/dist/app/scripts/TrackControl.d.ts +5 -0
- package/dist/app/scripts/TrackRenderer.d.ts +724 -0
- package/dist/app/scripts/UnknownPixiTrack.d.ts +7 -0
- package/dist/app/scripts/ValueIntervalTrack.d.ts +6 -0
- package/dist/app/scripts/VerticalItem.d.ts +3 -0
- package/dist/app/scripts/VerticalRule.d.ts +21 -0
- package/dist/app/scripts/VerticalTiled1DPixiTrack.d.ts +6 -0
- package/dist/app/scripts/VerticalTiledPlot.d.ts +50 -0
- package/dist/app/scripts/VerticalTrack.d.ts +6 -0
- package/dist/app/scripts/ViewConfigEditor.d.ts +53 -0
- package/dist/app/scripts/ViewContextMenu.d.ts +17 -0
- package/dist/app/scripts/ViewHeader.d.ts +75 -0
- package/dist/app/scripts/ViewportTracker2D.d.ts +17 -0
- package/dist/app/scripts/ViewportTracker2DPixi.d.ts +11 -0
- package/dist/app/scripts/ViewportTrackerHorizontal.d.ts +17 -0
- package/dist/app/scripts/ViewportTrackerVertical.d.ts +17 -0
- package/dist/app/scripts/api.d.ts +640 -0
- package/dist/app/scripts/configs/available-track-types.d.ts +2 -0
- package/dist/app/scripts/configs/colormaps.d.ts +2 -0
- package/dist/app/scripts/configs/datatype-to-track-type.d.ts +4 -0
- package/dist/app/scripts/configs/default-tracks-for-datatype.d.ts +38 -0
- package/dist/app/scripts/configs/dense-data-extrema-config.d.ts +2 -0
- package/dist/app/scripts/configs/globals.d.ts +5 -0
- package/dist/app/scripts/configs/index.d.ts +16 -0
- package/dist/app/scripts/configs/positions-by-datatype.d.ts +2 -0
- package/dist/app/scripts/configs/primitives.d.ts +20 -0
- package/dist/app/scripts/configs/themes.d.ts +3 -0
- package/dist/app/scripts/configs/tracks-info-by-type.d.ts +4 -0
- package/dist/app/scripts/configs/tracks-info.d.ts +24 -0
- package/dist/app/scripts/d3-context-menu.d.ts +2 -0
- package/dist/app/scripts/data-fetchers/DataFetcher.d.ts +151 -0
- package/dist/app/scripts/data-fetchers/genbank-fetcher.d.ts +86 -0
- package/dist/app/scripts/data-fetchers/index.d.ts +3 -0
- package/dist/app/scripts/data-fetchers/local-tile-fetcher.d.ts +47 -0
- package/dist/app/scripts/gosling-exports.d.ts +17 -0
- package/dist/app/scripts/hglib.d.ts +24 -0
- package/dist/app/scripts/hocs/with-modal.d.ts +19 -0
- package/dist/app/scripts/hocs/with-pub-sub.d.ts +22 -0
- package/dist/app/scripts/hocs/with-theme.d.ts +13 -0
- package/dist/app/scripts/icons.d.ts +161 -0
- package/dist/app/scripts/mixwith.d.ts +27 -0
- package/dist/app/scripts/options-info.d.ts +1355 -0
- package/dist/app/scripts/plugins/available-for-plugins.d.ts +2338 -0
- package/dist/app/scripts/plugins/get-data-fetcher.d.ts +2 -0
- package/dist/app/scripts/plugins/index.d.ts +2 -0
- package/dist/app/scripts/services/chrom-info.d.ts +10 -0
- package/dist/app/scripts/services/dom-event.d.ts +7 -0
- package/dist/app/scripts/services/element-resize-listener.d.ts +5 -0
- package/dist/app/scripts/services/index.d.ts +5 -0
- package/dist/app/scripts/services/tile-proxy.d.ts +180 -0
- package/dist/app/scripts/services/worker.d.ts +157 -0
- package/dist/app/scripts/symbol.d.ts +13 -0
- package/dist/app/scripts/test-helpers/index.d.ts +1 -0
- package/dist/app/scripts/test-helpers/test-helpers.d.ts +33 -0
- package/dist/app/scripts/track-utils.d.ts +73 -0
- package/dist/app/scripts/types.d.ts +199 -0
- package/dist/app/scripts/utils/DenseDataExtrema1D.d.ts +88 -0
- package/dist/app/scripts/utils/DenseDataExtrema2D.d.ts +97 -0
- package/dist/app/scripts/utils/LruCache.d.ts +44 -0
- package/dist/app/scripts/utils/abs-to-chr.d.ts +14 -0
- package/dist/app/scripts/utils/accessor-transposition.d.ts +14 -0
- package/dist/app/scripts/utils/add-arrays.d.ts +18 -0
- package/dist/app/scripts/utils/add-class.d.ts +8 -0
- package/dist/app/scripts/utils/add-event-listener-once.d.ts +11 -0
- package/dist/app/scripts/utils/assert.d.ts +17 -0
- package/dist/app/scripts/utils/background-task-scheduler.d.ts +47 -0
- package/dist/app/scripts/utils/base64-to-canvas.d.ts +9 -0
- package/dist/app/scripts/utils/chr-to-abs.d.ts +10 -0
- package/dist/app/scripts/utils/chrom-info-bisector.d.ts +4 -0
- package/dist/app/scripts/utils/clone-event.d.ts +12 -0
- package/dist/app/scripts/utils/color-domain-to-rgba-array.d.ts +13 -0
- package/dist/app/scripts/utils/color-to-hex.d.ts +9 -0
- package/dist/app/scripts/utils/color-to-rgba.d.ts +9 -0
- package/dist/app/scripts/utils/copy-text-to-clipboard.d.ts +2 -0
- package/dist/app/scripts/utils/data-to-genomic-loci.d.ts +11 -0
- package/dist/app/scripts/utils/debounce.d.ts +5 -0
- package/dist/app/scripts/utils/dec-to-hex-str.d.ts +8 -0
- package/dist/app/scripts/utils/decompress.d.ts +27 -0
- package/dist/app/scripts/utils/default-tracks.d.ts +3 -0
- package/dist/app/scripts/utils/dict-from-tuples.d.ts +11 -0
- package/dist/app/scripts/utils/dict-items.d.ts +18 -0
- package/dist/app/scripts/utils/dict-keys.d.ts +10 -0
- package/dist/app/scripts/utils/dict-values.d.ts +8 -0
- package/dist/app/scripts/utils/download.d.ts +7 -0
- package/dist/app/scripts/utils/expand-combined-tracks.d.ts +11 -0
- package/dist/app/scripts/utils/fake-pub-sub.d.ts +11 -0
- package/dist/app/scripts/utils/fill-in-min-widths.d.ts +44 -0
- package/dist/app/scripts/utils/flatten.d.ts +9 -0
- package/dist/app/scripts/utils/for-each.d.ts +9 -0
- package/dist/app/scripts/utils/forward-event.d.ts +7 -0
- package/dist/app/scripts/utils/genome-loci-to-pixels.d.ts +9 -0
- package/dist/app/scripts/utils/genomic-range-to-chromosome-chunks.d.ts +21 -0
- package/dist/app/scripts/utils/get-aggregation-function.d.ts +10 -0
- package/dist/app/scripts/utils/get-default-track-for-datatype.d.ts +21 -0
- package/dist/app/scripts/utils/get-default-tracks-for-datatype.d.ts +3 -0
- package/dist/app/scripts/utils/get-element-dim.d.ts +7 -0
- package/dist/app/scripts/utils/get-higlass-components.d.ts +7 -0
- package/dist/app/scripts/utils/get-track-by-uid.d.ts +7 -0
- package/dist/app/scripts/utils/get-track-conf-from-hgc.d.ts +10 -0
- package/dist/app/scripts/utils/get-track-obj-by-id.d.ts +2 -0
- package/dist/app/scripts/utils/get-track-position-by-uid.d.ts +13 -0
- package/dist/app/scripts/utils/get-xylofon.d.ts +2 -0
- package/dist/app/scripts/utils/gradient.d.ts +14 -0
- package/dist/app/scripts/utils/has-class.d.ts +8 -0
- package/dist/app/scripts/utils/has-parent.d.ts +9 -0
- package/dist/app/scripts/utils/hex-string-to-int.d.ts +14 -0
- package/dist/app/scripts/utils/index.d.ts +89 -0
- package/dist/app/scripts/utils/interval-tree.d.ts +109 -0
- package/dist/app/scripts/utils/into-the-void.d.ts +6 -0
- package/dist/app/scripts/utils/is-track-or-child-track.d.ts +7 -0
- package/dist/app/scripts/utils/is-track-range-selectable.d.ts +2 -0
- package/dist/app/scripts/utils/is-within.d.ts +12 -0
- package/dist/app/scripts/utils/lat-to-y.d.ts +9 -0
- package/dist/app/scripts/utils/lng-to-x.d.ts +8 -0
- package/dist/app/scripts/utils/load-chrom-infos.d.ts +8 -0
- package/dist/app/scripts/utils/map.d.ts +13 -0
- package/dist/app/scripts/utils/max-non-zero.d.ts +6 -0
- package/dist/app/scripts/utils/max.d.ts +10 -0
- package/dist/app/scripts/utils/min-non-zero.d.ts +6 -0
- package/dist/app/scripts/utils/min.d.ts +10 -0
- package/dist/app/scripts/utils/mod.d.ts +9 -0
- package/dist/app/scripts/utils/ndarray-assign.d.ts +2 -0
- package/dist/app/scripts/utils/ndarray-flatten.d.ts +2 -0
- package/dist/app/scripts/utils/ndarray-to-list.d.ts +2 -0
- package/dist/app/scripts/utils/numericify-version.d.ts +6 -0
- package/dist/app/scripts/utils/obj-vals.d.ts +8 -0
- package/dist/app/scripts/utils/or.d.ts +8 -0
- package/dist/app/scripts/utils/parse-chromsizes-rows.d.ts +34 -0
- package/dist/app/scripts/utils/pixi-text-to-svg.d.ts +2 -0
- package/dist/app/scripts/utils/positioned-tracks-to-all-tracks.d.ts +26 -0
- package/dist/app/scripts/utils/q.d.ts +18 -0
- package/dist/app/scripts/utils/rad-to-deg.d.ts +7 -0
- package/dist/app/scripts/utils/range-query-2d.d.ts +17 -0
- package/dist/app/scripts/utils/reduce.d.ts +14 -0
- package/dist/app/scripts/utils/rel-to-abs-chrom-pos.d.ts +10 -0
- package/dist/app/scripts/utils/remove-class.d.ts +7 -0
- package/dist/app/scripts/utils/reset-d3-brush-style.d.ts +10 -0
- package/dist/app/scripts/utils/rgb-to-hex.d.ts +8 -0
- package/dist/app/scripts/utils/scales-center-and-k.d.ts +12 -0
- package/dist/app/scripts/utils/scales-to-genome-loci.d.ts +3 -0
- package/dist/app/scripts/utils/segments-to-rows.d.ts +15 -0
- package/dist/app/scripts/utils/selected-items-to-cum-weights.d.ts +12 -0
- package/dist/app/scripts/utils/selected-items-to-size.d.ts +13 -0
- package/dist/app/scripts/utils/show-mouse-position.d.ts +54 -0
- package/dist/app/scripts/utils/some.d.ts +10 -0
- package/dist/app/scripts/utils/sum.d.ts +8 -0
- package/dist/app/scripts/utils/svg-line.d.ts +2 -0
- package/dist/app/scripts/utils/throttle-and-debounce.d.ts +33 -0
- package/dist/app/scripts/utils/tile-to-canvas.d.ts +9 -0
- package/dist/app/scripts/utils/timeout.d.ts +3 -0
- package/dist/app/scripts/utils/to-void.d.ts +3 -0
- package/dist/app/scripts/utils/total-track-pixel-height.d.ts +27 -0
- package/dist/app/scripts/utils/trim-trailing-slash.d.ts +7 -0
- package/dist/app/scripts/utils/type-guards.d.ts +36 -0
- package/dist/app/scripts/utils/value-to-color.d.ts +12 -0
- package/dist/app/scripts/utils/visit-positioned-tracks.d.ts +18 -0
- package/dist/app/scripts/utils/visit-tracks.d.ts +9 -0
- package/dist/esm.html +1 -3
- package/dist/hglib.js +86315 -100592
- package/dist/hglib.min.js +123 -131
- package/dist/higlass.mjs +88861 -103138
- package/dist/index.html +1 -3
- package/dist/package.json +134 -0
- package/package.json +25 -27
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * from "./primitives";
|
|
2
|
+
export { default as GLOBALS } from "./globals";
|
|
3
|
+
export { default as DATATYPE_TO_TRACK_TYPE } from "./datatype-to-track-type";
|
|
4
|
+
export { default as HEATED_OBJECT_MAP } from "./colormaps";
|
|
5
|
+
export { default as TRACKS_INFO } from "./tracks-info";
|
|
6
|
+
export { default as TRACKS_INFO_BY_TYPE } from "./tracks-info-by-type";
|
|
7
|
+
export { default as POSITIONS_BY_DATATYPE } from "./positions-by-datatype";
|
|
8
|
+
export { default as DEFAULT_TRACKS_FOR_DATATYPE } from "./default-tracks-for-datatype";
|
|
9
|
+
export { default as AVAILABLE_TRACK_TYPES } from "./available-track-types";
|
|
10
|
+
export const SIZE_MODE_DEFAULT: "default";
|
|
11
|
+
export const SIZE_MODE_BOUNDED: "bounded";
|
|
12
|
+
export const SIZE_MODE_OVERFLOW: "overflow";
|
|
13
|
+
export const SIZE_MODE_BOUNDED_OVERFLOW: "bounded-overflow";
|
|
14
|
+
export const SIZE_MODE_SCROLL: "scroll";
|
|
15
|
+
export { THEME_LIGHT, THEME_DARK, THEME_DEFAULT } from "./themes";
|
|
16
|
+
export { NUM_PRECOMP_SUBSETS_PER_1D_TTILE, NUM_PRECOMP_SUBSETS_PER_2D_TTILE } from "./dense-data-extrema-config";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const DEFAULT_VIEW_MARGIN: 0;
|
|
2
|
+
export const DEFAULT_VIEW_PADDING: 5;
|
|
3
|
+
export const DEFAULT_CONTAINER_PADDING_X: 10;
|
|
4
|
+
export const DEFAULT_CONTAINER_PADDING_Y: 10;
|
|
5
|
+
export const MAX_CLICK_DELAY: 300;
|
|
6
|
+
export const MOUSE_TOOL_MOVE: "move";
|
|
7
|
+
export const MOUSE_TOOL_SELECT: "select";
|
|
8
|
+
export const MOUSE_TOOL_TRACK_SELECT: "track-select";
|
|
9
|
+
export const TILE_FETCH_DEBOUNCE: 100;
|
|
10
|
+
export const ZOOM_DEBOUNCE: 10;
|
|
11
|
+
export const SHORT_DRAG_TIMEOUT: 110;
|
|
12
|
+
export const LONG_DRAG_TIMEOUT: 3000;
|
|
13
|
+
export const LOCATION_LISTENER_PREFIX: "locationListenerPrefix";
|
|
14
|
+
export const ZOOM_TRANSITION_DURATION: 1000;
|
|
15
|
+
export const DEFAULT_SERVER: "http://higlass.io/api/v1";
|
|
16
|
+
export const VIEW_HEADER_MED_WIDTH_SEARCH_BAR: 400;
|
|
17
|
+
export const VIEW_HEADER_MIN_WIDTH_SEARCH_BAR: 300;
|
|
18
|
+
export const TRACK_LOCATIONS: readonly ["top", "left", "right", "bottom", "center", "whole", "gallery"];
|
|
19
|
+
export const MIN_HORIZONTAL_HEIGHT: 20;
|
|
20
|
+
export const MIN_VERTICAL_WIDTH: 20;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/** @type {TrackInfo[]} */
|
|
2
|
+
export const TRACKS_INFO: TrackInfo[];
|
|
3
|
+
export default TRACKS_INFO;
|
|
4
|
+
export type TrackInfo = {
|
|
5
|
+
type: string;
|
|
6
|
+
datatype: string | string[];
|
|
7
|
+
orientation: string;
|
|
8
|
+
aliases?: string[] | undefined;
|
|
9
|
+
local?: boolean | undefined;
|
|
10
|
+
rotatable?: boolean | undefined;
|
|
11
|
+
hidden?: boolean | undefined;
|
|
12
|
+
name?: string | undefined;
|
|
13
|
+
thumbnail?: (HTMLElement | null | string) | undefined;
|
|
14
|
+
availableOptions?: string[] | undefined;
|
|
15
|
+
defaultOptions?: Record<string, unknown> | undefined;
|
|
16
|
+
exportable?: boolean | undefined;
|
|
17
|
+
defaultOptionsByTheme?: Record<string, Record<string, unknown>> | undefined;
|
|
18
|
+
minHeight?: number | undefined;
|
|
19
|
+
defaultHeight?: number | undefined;
|
|
20
|
+
defaultWidth?: number | undefined;
|
|
21
|
+
chromInfoPath?: string | undefined;
|
|
22
|
+
projection?: boolean | undefined;
|
|
23
|
+
optionsInfo?: Record<string, unknown> | undefined;
|
|
24
|
+
};
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
/** @implements {AbstractDataFetcher<Tile | DividedTile, ResolvedDataConfig>} */
|
|
2
|
+
export default class DataFetcher implements AbstractDataFetcher {
|
|
3
|
+
/**
|
|
4
|
+
* @param {DataConfig} dataConfig
|
|
5
|
+
* @param {PubSub} pubSub
|
|
6
|
+
* @param {TileSource<Tile>} [tileSource]
|
|
7
|
+
*/
|
|
8
|
+
constructor(dataConfig: DataConfig, pubSub: PubSub, tileSource?: TileSource<Tile>);
|
|
9
|
+
_tileSource: TileSource<Tile>;
|
|
10
|
+
/** @type {boolean} */
|
|
11
|
+
tilesetInfoLoading: boolean;
|
|
12
|
+
/** @type {ResolvedDataConfig} */
|
|
13
|
+
dataConfig: ResolvedDataConfig;
|
|
14
|
+
/** @type {string} */
|
|
15
|
+
uuid: string;
|
|
16
|
+
/** @type {PubSub} */
|
|
17
|
+
pubSub: PubSub;
|
|
18
|
+
/**
|
|
19
|
+
* We don't a have a tilesetUid for this track. But we do have a url, filetype
|
|
20
|
+
* and server. Using these, we can use the server to fullfill tile requests
|
|
21
|
+
* from this dataset.
|
|
22
|
+
*
|
|
23
|
+
* @param {object} opts
|
|
24
|
+
* @param {string} opts.server - The server api location (e.g. 'localhost:8000/api/v1')
|
|
25
|
+
* @param {string} opts.url - The location of the data file (e.g. 'encode.org/my.file.bigwig')
|
|
26
|
+
* @param {string} opts.filetype - The type of file being served (e.g. 'bigwig')
|
|
27
|
+
* @param {string=} opts.coordSystem - The coordinate system being served (e.g. 'hg38')
|
|
28
|
+
*/
|
|
29
|
+
registerFileUrl({ server, url, filetype, coordSystem }: {
|
|
30
|
+
server: string;
|
|
31
|
+
url: string;
|
|
32
|
+
filetype: string;
|
|
33
|
+
coordSystem?: string | undefined;
|
|
34
|
+
}): Promise<Response>;
|
|
35
|
+
/**
|
|
36
|
+
* Obtain tileset infos for all of the tilesets listed
|
|
37
|
+
* @param {HandleTilesetInfoFinished} finished - A callback that will be called
|
|
38
|
+
*/
|
|
39
|
+
tilesetInfo(finished: HandleTilesetInfoFinished): Promise<any>;
|
|
40
|
+
/**
|
|
41
|
+
* Obtain tileset infos for all of the tilesets listed
|
|
42
|
+
*
|
|
43
|
+
* If there is more than one tileset info, this function
|
|
44
|
+
* should (not currently implemented) check if the tileset
|
|
45
|
+
* infos have the same dimensions and then return a common
|
|
46
|
+
* one.
|
|
47
|
+
*
|
|
48
|
+
* @param {HandleTilesetInfoFinished} finished - A callback that will be called
|
|
49
|
+
* when all tileset infos are loaded
|
|
50
|
+
*/
|
|
51
|
+
tilesetInfoAfterRegister(finished: HandleTilesetInfoFinished): void;
|
|
52
|
+
/**
|
|
53
|
+
* @param {string} tilesetUid - Uid of the tileset on the server
|
|
54
|
+
* @param {string} tileId - The tileId of the tile
|
|
55
|
+
* @returns {string} The full tile id that the server will parse.
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* ```javascript
|
|
59
|
+
* // returns 'xyxx.0.0.0'
|
|
60
|
+
* fullTileId('xyxx', '0.0.0');
|
|
61
|
+
* ```
|
|
62
|
+
*/
|
|
63
|
+
fullTileId(tilesetUid: string, tileId: string): string;
|
|
64
|
+
/**
|
|
65
|
+
* Fetch a set of tiles.
|
|
66
|
+
*
|
|
67
|
+
* Because the track shouldn't care about tileset ids, the tile ids
|
|
68
|
+
* should just include positions and any necessary transforms.
|
|
69
|
+
*
|
|
70
|
+
* @param {(tiles: Record<string, DividedTile | Tile>) => void} receivedTiles - A function to call once the tiles have been fetched
|
|
71
|
+
* @param {string[]} tileIds - The tile ids to fetch
|
|
72
|
+
* @returns {Promise<Record<string, DividedTile | Tile>>}
|
|
73
|
+
*/
|
|
74
|
+
fetchTilesDebounced(receivedTiles: (tiles: Record<string, DividedTile | Tile>) => void, tileIds: string[]): Promise<Record<string, DividedTile | Tile>>;
|
|
75
|
+
/**
|
|
76
|
+
* Return an array consisting of the division of the numerator
|
|
77
|
+
* array by the denominator array
|
|
78
|
+
*
|
|
79
|
+
* @param {ArrayLike<number>} numeratorData - An array of numerical values
|
|
80
|
+
* @param {ArrayLike<number>} denominatorData - An array of numerical values
|
|
81
|
+
*
|
|
82
|
+
* @returns {Float32Array} An array consisting of the division of the numerator by the denominator
|
|
83
|
+
*/
|
|
84
|
+
divideData(numeratorData: ArrayLike<number>, denominatorData: ArrayLike<number>): Float32Array;
|
|
85
|
+
horizontalSlice(): null;
|
|
86
|
+
/**
|
|
87
|
+
* Extract a slice from a matrix at a given position.
|
|
88
|
+
*
|
|
89
|
+
* @param {Array<number> | Float32Array} inputData - An array containing a matrix stored row-wise
|
|
90
|
+
* @param {Array<number>} arrayShape - The shape of the array, should be a
|
|
91
|
+
* two element array e.g. [256,256].
|
|
92
|
+
* @param {number} sliceIndex - The index across which to take the slice
|
|
93
|
+
* @param {number=} axis - The axis along which to take the slice
|
|
94
|
+
* @returns {Array<number> | Float32Array} an array corresponding to a slice of this matrix
|
|
95
|
+
*/
|
|
96
|
+
extractDataSlice(inputData: Array<number> | Float32Array, arrayShape: Array<number>, sliceIndex: number, axis?: number | undefined): Array<number> | Float32Array;
|
|
97
|
+
/**
|
|
98
|
+
* Fetch a horizontal section of a 2D dataset
|
|
99
|
+
* @param {(tiles: Record<string, Tile>) => void} receivedTiles - A function to call once the tiles have been fetched
|
|
100
|
+
* @param {string[]} tileIds - The tile ids to fetch
|
|
101
|
+
* @param {boolean=} vertical - Whether to fetch a vertical section
|
|
102
|
+
* @returns {Promise<Record<string, Tile>>}
|
|
103
|
+
*/
|
|
104
|
+
fetchHorizontalSection(receivedTiles: (tiles: Record<string, Tile>) => void, tileIds: string[], vertical?: boolean | undefined): Promise<Record<string, Tile>>;
|
|
105
|
+
/**
|
|
106
|
+
* @typedef {{ zoomLevel: number, tilePos: number[], dense?: ArrayLike<number> }} Dividable
|
|
107
|
+
* @param {[Record<string, Dividable>, Record<string, Dividable>]} returnedTiles
|
|
108
|
+
* @param {string[]} tileIds
|
|
109
|
+
* @returns {Record<string, DividedTile>}
|
|
110
|
+
*/
|
|
111
|
+
makeDivided(returnedTiles: [Record<string, {
|
|
112
|
+
zoomLevel: number;
|
|
113
|
+
tilePos: number[];
|
|
114
|
+
dense?: ArrayLike<number>;
|
|
115
|
+
}>, Record<string, {
|
|
116
|
+
zoomLevel: number;
|
|
117
|
+
tilePos: number[];
|
|
118
|
+
dense?: ArrayLike<number>;
|
|
119
|
+
}>], tileIds: string[]): Record<string, DividedTile>;
|
|
120
|
+
}
|
|
121
|
+
export type Tile = {
|
|
122
|
+
min_value: number;
|
|
123
|
+
max_value: number;
|
|
124
|
+
denseDataExtrema: DenseDataExtrema1D | DenseDataExtrema2D;
|
|
125
|
+
minNonZero: number;
|
|
126
|
+
maxNonZero: number;
|
|
127
|
+
dense: Array<number> | Float32Array;
|
|
128
|
+
dtype: string;
|
|
129
|
+
server: string;
|
|
130
|
+
tilePos: number[];
|
|
131
|
+
tilePositionId: string;
|
|
132
|
+
tilesetUid: string;
|
|
133
|
+
zoomLevel: number;
|
|
134
|
+
};
|
|
135
|
+
export type DividedTileA = Pick<Tile, "zoomLevel" | "tilePos" | "tilePositionId">;
|
|
136
|
+
export type DividedTileB = Pick<Tile, "zoomLevel" | "tilePos" | "tilePositionId" | "dense" | "denseDataExtrema" | "minNonZero" | "maxNonZero">;
|
|
137
|
+
export type DividedTile = DividedTileA | DividedTileB;
|
|
138
|
+
export type ResolvedDataConfig = Omit<DataConfig, "children"> & {
|
|
139
|
+
children?: DataFetcher[];
|
|
140
|
+
tilesetUid?: string;
|
|
141
|
+
tilesetInfo: TilesetInfo;
|
|
142
|
+
};
|
|
143
|
+
import type { AbstractDataFetcher } from '../types';
|
|
144
|
+
import type { TileSource } from '../types';
|
|
145
|
+
import type { PubSub } from 'pub-sub-es';
|
|
146
|
+
import type { HandleTilesetInfoFinished } from '../types';
|
|
147
|
+
import type { DataConfig } from '../types';
|
|
148
|
+
import DenseDataExtrema1D from '../utils/DenseDataExtrema1D';
|
|
149
|
+
import DenseDataExtrema2D from '../utils/DenseDataExtrema2D';
|
|
150
|
+
import type { DataConfig as DataConfig_1 } from '../types';
|
|
151
|
+
import type { TilesetInfo } from '../types';
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
export default GBKDataFetcher;
|
|
2
|
+
export type FillerSegment = {
|
|
3
|
+
start: number;
|
|
4
|
+
end: number;
|
|
5
|
+
type: "filler";
|
|
6
|
+
strand: "+" | "-";
|
|
7
|
+
};
|
|
8
|
+
export type GenbankFeature = import("genbank-parser").ParsedGenbank["features"][number];
|
|
9
|
+
export type FillerGeneAnnotation = {
|
|
10
|
+
xStart: number;
|
|
11
|
+
xEnd: number;
|
|
12
|
+
strand: "+" | "-";
|
|
13
|
+
uid: string;
|
|
14
|
+
type: "filler";
|
|
15
|
+
fields: [];
|
|
16
|
+
};
|
|
17
|
+
export type CompleteGeneAnnotation = {
|
|
18
|
+
xStart: number;
|
|
19
|
+
xEnd: number;
|
|
20
|
+
strand: "+" | "-";
|
|
21
|
+
chrOffset: number;
|
|
22
|
+
importance: number;
|
|
23
|
+
uid: string;
|
|
24
|
+
type?: string | undefined;
|
|
25
|
+
fields: [chr: "chrom", start: number, end: number, name: string, importance: number, strand: "+" | "-", _unknown0: string, _unknown1: string, type: string, name: string, start: string, end: string, start: string, end: string];
|
|
26
|
+
};
|
|
27
|
+
export type GeneAnnotation = CompleteGeneAnnotation | FillerGeneAnnotation;
|
|
28
|
+
export type GenbankDataConfig = {
|
|
29
|
+
url?: string | undefined;
|
|
30
|
+
text?: string | undefined;
|
|
31
|
+
};
|
|
32
|
+
export type GenbankTile = Array<GeneAnnotation> & {
|
|
33
|
+
tilePositionId?: string;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* @typedef GenbankDataConfig
|
|
37
|
+
* @prop {string=} url
|
|
38
|
+
* @prop {string=} text
|
|
39
|
+
*/
|
|
40
|
+
/**
|
|
41
|
+
* @typedef {Array<GeneAnnotation> & { tilePositionId?: string }} GenbankTile
|
|
42
|
+
*/
|
|
43
|
+
/** @implements {AbstractDataFetcher<GenbankTile, GenbankDataConfig>} */
|
|
44
|
+
declare class GBKDataFetcher implements AbstractDataFetcher {
|
|
45
|
+
/** @param {GenbankDataConfig} dataConfig */
|
|
46
|
+
constructor(dataConfig: GenbankDataConfig);
|
|
47
|
+
/** @type {GenbankDataConfig} */
|
|
48
|
+
dataConfig: GenbankDataConfig;
|
|
49
|
+
/** @type {string} */
|
|
50
|
+
trackUid: string;
|
|
51
|
+
/** @type {string} */
|
|
52
|
+
errorTxt: string;
|
|
53
|
+
/** @type {Promise<ReturnType<typeof gbToJsonAndFeatures>>} */
|
|
54
|
+
gbDataPromise: Promise<ReturnType<typeof gbToJsonAndFeatures>>;
|
|
55
|
+
/**
|
|
56
|
+
* @param {import('../types').HandleTilesetInfoFinished} [callback]
|
|
57
|
+
* @returns {Promise<import('../types').LegacyTilesetInfo | undefined>}
|
|
58
|
+
*/
|
|
59
|
+
tilesetInfo(callback?: import("../types").HandleTilesetInfoFinished): Promise<import("../types").LegacyTilesetInfo | undefined>;
|
|
60
|
+
tilesetInfoLoading: boolean | undefined;
|
|
61
|
+
/**
|
|
62
|
+
* @param {(tiles: Record<string, GenbankTile>) => void} receivedTiles
|
|
63
|
+
* @param {string[]} tileIds
|
|
64
|
+
* @returns {Promise<Record<string, GenbankTile>>}
|
|
65
|
+
*/
|
|
66
|
+
fetchTilesDebounced(receivedTiles: (tiles: Record<string, GenbankTile>) => void, tileIds: string[]): Promise<Record<string, GenbankTile>>;
|
|
67
|
+
/**
|
|
68
|
+
* @param {number} z
|
|
69
|
+
* @param {number} x
|
|
70
|
+
* @returns {Promise<GeneAnnotation[]>}
|
|
71
|
+
*/
|
|
72
|
+
tile(z: number, x: number): Promise<GeneAnnotation[]>;
|
|
73
|
+
}
|
|
74
|
+
import type { AbstractDataFetcher } from '../types';
|
|
75
|
+
/**
|
|
76
|
+
* Convert genbank text to a JSON representation and extract features
|
|
77
|
+
* @param {string} gbText
|
|
78
|
+
* @returns {{
|
|
79
|
+
* json: import('genbank-parser').ParsedGenbank[],
|
|
80
|
+
* features: GenbankFeature[],
|
|
81
|
+
* }}
|
|
82
|
+
*/
|
|
83
|
+
declare function gbToJsonAndFeatures(gbText: string): {
|
|
84
|
+
json: import("genbank-parser").ParsedGenbank[];
|
|
85
|
+
features: GenbankFeature[];
|
|
86
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
export default LocalTileDataFetcher;
|
|
2
|
+
export type LocalTile = {
|
|
3
|
+
tilePositionId?: string;
|
|
4
|
+
};
|
|
5
|
+
export type LocalTileDataConfig = {
|
|
6
|
+
tiles: Record<string, LocalTile>;
|
|
7
|
+
tilesetInfo: Record<string, TilesetInfo>;
|
|
8
|
+
};
|
|
9
|
+
/** @import { AbstractDataFetcher, TilesetInfo } from '../types' */
|
|
10
|
+
/** @typedef {{tilePositionId?: string}} LocalTile */
|
|
11
|
+
/**
|
|
12
|
+
* @typedef LocalTileDataConfig
|
|
13
|
+
* @property {Record<string, LocalTile>} tiles
|
|
14
|
+
* @property {Record<string, TilesetInfo>} tilesetInfo
|
|
15
|
+
*/
|
|
16
|
+
/** @implements {AbstractDataFetcher<LocalTile, LocalTileDataConfig>} */
|
|
17
|
+
declare class LocalTileDataFetcher implements AbstractDataFetcher {
|
|
18
|
+
/** @param {LocalTileDataConfig} dataConfig */
|
|
19
|
+
constructor(dataConfig: LocalTileDataConfig);
|
|
20
|
+
/** @type {LocalTileDataConfig} */
|
|
21
|
+
dataConfig: LocalTileDataConfig;
|
|
22
|
+
/** @type {TilesetInfo} */
|
|
23
|
+
tilesetInfoData: TilesetInfo;
|
|
24
|
+
/** @type {Record<string, LocalTile>} */
|
|
25
|
+
tilesData: Record<string, LocalTile>;
|
|
26
|
+
/** @type {boolean} */
|
|
27
|
+
tilesetInfoLoading: boolean;
|
|
28
|
+
/** @param {import('../types').HandleTilesetInfoFinished} callback */
|
|
29
|
+
tilesetInfo(callback: import("../types").HandleTilesetInfoFinished): Promise<TilesetInfo>;
|
|
30
|
+
/** We expect there to be a tilesetUid in the provided tilesetInfo
|
|
31
|
+
* and tiles data since tileResponseToData needs it
|
|
32
|
+
*
|
|
33
|
+
* It is also easier for users to paste in request responses for debugging.
|
|
34
|
+
*
|
|
35
|
+
* @param {(tiles: Record<string, LocalTile>) => void} receivedTiles
|
|
36
|
+
* @param {string[]} tileIds
|
|
37
|
+
*/
|
|
38
|
+
fetchTilesDebounced(receivedTiles: (tiles: Record<string, LocalTile>) => void, tileIds: string[]): Promise<Record<string, LocalTile>>;
|
|
39
|
+
/**
|
|
40
|
+
* @param {number} z
|
|
41
|
+
* @param {number} x
|
|
42
|
+
* @returns {void}
|
|
43
|
+
*/
|
|
44
|
+
tile(z: number, x: number): void;
|
|
45
|
+
}
|
|
46
|
+
import type { TilesetInfo } from '../types';
|
|
47
|
+
import type { AbstractDataFetcher } from '../types';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export { default as Track } from "./Track";
|
|
2
|
+
export { default as PixiTrack } from "./PixiTrack";
|
|
3
|
+
export { default as TiledPixiTrack } from "./TiledPixiTrack";
|
|
4
|
+
export { default as SVGTrack } from "./SVGTrack";
|
|
5
|
+
export { default as ViewportTrackerHorizontal } from "./ViewportTrackerHorizontal";
|
|
6
|
+
export { default as HeatmapTiledPixiTrack } from "./HeatmapTiledPixiTrack";
|
|
7
|
+
export { default as DataFetcher } from "./data-fetchers/DataFetcher";
|
|
8
|
+
export { default as tileProxy } from "./services/tile-proxy";
|
|
9
|
+
export { default as fakePubSub } from "./utils/fake-pub-sub";
|
|
10
|
+
export { default as DenseDataExtrema1D } from "./utils/DenseDataExtrema1D";
|
|
11
|
+
export { default as absToChr } from "./utils/abs-to-chr";
|
|
12
|
+
export { default as chrToAbs } from "./utils/chr-to-abs";
|
|
13
|
+
export { default as colorToHex } from "./utils/color-to-hex";
|
|
14
|
+
export { default as chromInfoBisector } from "./utils/chrom-info-bisector";
|
|
15
|
+
export { default as pixiTextToSvg } from "./utils/pixi-text-to-svg";
|
|
16
|
+
export { default as svgLine } from "./utils/svg-line";
|
|
17
|
+
export { default as showMousePosition } from "./utils/show-mouse-position";
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export { default as ChromosomeInfo } from "./ChromosomeInfo";
|
|
2
|
+
export { default as HiGlassComponent } from "./HiGlassComponent";
|
|
3
|
+
export namespace tracks {
|
|
4
|
+
export { SVGTrack };
|
|
5
|
+
export { TiledPixiTrack };
|
|
6
|
+
export { HorizontalGeneAnnotationsTrack };
|
|
7
|
+
}
|
|
8
|
+
export { default as schema } from "../schema.json";
|
|
9
|
+
export { version } from "../../package.json";
|
|
10
|
+
export { TRACKS_INFO_BY_TYPE } from "./configs";
|
|
11
|
+
export { OPTIONS_INFO } from "./options-info";
|
|
12
|
+
export function viewer(element: HTMLElement, viewConfig: HiGlassViewConfig | string, options?: HiGlassOptions): Promise<HiGlassApi>;
|
|
13
|
+
export * as hggos from "./gosling-exports";
|
|
14
|
+
export type HiGlassApi = api.HiGlassApi["public"];
|
|
15
|
+
export type HiGlassOptions = types.HiGlassOptions;
|
|
16
|
+
export type HiGlassViewConfig = types.HiGlassViewConfig;
|
|
17
|
+
import SVGTrack from './SVGTrack';
|
|
18
|
+
import TiledPixiTrack from './TiledPixiTrack';
|
|
19
|
+
import HorizontalGeneAnnotationsTrack from './HorizontalGeneAnnotationsTrack';
|
|
20
|
+
import type * as api from './api';
|
|
21
|
+
import type * as types from './types';
|
|
22
|
+
export { default as HiGlassTrackComponent, trackViewer } from "./HiGlassTrackComponent";
|
|
23
|
+
export { waitForJsonComplete, waitForTilesLoaded, waitForTransitionsFinished, mountHGComponent } from "./test-helpers";
|
|
24
|
+
export { debounce, getDefaultTracksForDatatype, getTrackByUid, getTrackObjectFromHGC } from "./utils";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export default withModal;
|
|
2
|
+
export type Modal = {
|
|
3
|
+
open: () => void;
|
|
4
|
+
close: () => void;
|
|
5
|
+
};
|
|
6
|
+
/** @typedef {{ open: () => void, close: () => void }} Modal */
|
|
7
|
+
/**
|
|
8
|
+
* @template {typeof React.Component<{ modal?: Modal }>} T
|
|
9
|
+
* @param {T} Component
|
|
10
|
+
* @returns {T}
|
|
11
|
+
*/
|
|
12
|
+
declare function withModal<T extends typeof React.Component<{
|
|
13
|
+
modal?: Modal;
|
|
14
|
+
}>>(Component: T): T;
|
|
15
|
+
export const Provider: React.Provider<{
|
|
16
|
+
close: (...args: any[]) => void;
|
|
17
|
+
open: (...args: any[]) => void;
|
|
18
|
+
}>;
|
|
19
|
+
import React from 'react';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export default withPubSub;
|
|
2
|
+
/** @import { PubSub } from 'pub-sub-es' */
|
|
3
|
+
/**
|
|
4
|
+
* @template {typeof React.Component<{ pubSub?: PubSub }>} T
|
|
5
|
+
* @param {T} Component
|
|
6
|
+
* @returns {T}
|
|
7
|
+
*/
|
|
8
|
+
declare function withPubSub<T extends typeof React.Component<{
|
|
9
|
+
pubSub?: PubSub;
|
|
10
|
+
}>>(Component: T): T;
|
|
11
|
+
export const Provider: React.Provider<{
|
|
12
|
+
__fake__: boolean;
|
|
13
|
+
publish: () => void;
|
|
14
|
+
subscribe: () => {
|
|
15
|
+
event: string;
|
|
16
|
+
handler: () => void;
|
|
17
|
+
};
|
|
18
|
+
unsubscribe: () => void;
|
|
19
|
+
clear: () => void;
|
|
20
|
+
}>;
|
|
21
|
+
import React from 'react';
|
|
22
|
+
import type { PubSub } from 'pub-sub-es';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export default withTheme;
|
|
2
|
+
export type Theme = typeof themes.THEME_LIGHT | typeof themes.THEME_DARK;
|
|
3
|
+
/**
|
|
4
|
+
* @template {typeof React.Component<{ theme?: Theme }>} T
|
|
5
|
+
* @param {T} Component
|
|
6
|
+
* @returns {T}
|
|
7
|
+
*/
|
|
8
|
+
declare function withTheme<T extends typeof React.Component<{
|
|
9
|
+
theme?: Theme;
|
|
10
|
+
}>>(Component: T): T;
|
|
11
|
+
export const Provider: React.Provider<Theme>;
|
|
12
|
+
import * as themes from '../configs/themes';
|
|
13
|
+
import React from 'react';
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
export function SearchIcon({ theStyle, onClick }: {
|
|
2
|
+
theStyle: any;
|
|
3
|
+
onClick: any;
|
|
4
|
+
}): React.JSX.Element;
|
|
5
|
+
export namespace SearchIcon {
|
|
6
|
+
namespace propTypes {
|
|
7
|
+
let theStyle: PropTypes.Requireable<string>;
|
|
8
|
+
let onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
export namespace COG {
|
|
12
|
+
let id: string;
|
|
13
|
+
let paths: string[];
|
|
14
|
+
let viewBox: string;
|
|
15
|
+
}
|
|
16
|
+
export namespace CROSS {
|
|
17
|
+
let id_1: string;
|
|
18
|
+
export { id_1 as id };
|
|
19
|
+
let paths_1: string[];
|
|
20
|
+
export { paths_1 as paths };
|
|
21
|
+
let viewBox_1: string;
|
|
22
|
+
export { viewBox_1 as viewBox };
|
|
23
|
+
}
|
|
24
|
+
export namespace ENLARGE {
|
|
25
|
+
let id_2: string;
|
|
26
|
+
export { id_2 as id };
|
|
27
|
+
let paths_2: string[];
|
|
28
|
+
export { paths_2 as paths };
|
|
29
|
+
let viewBox_2: string;
|
|
30
|
+
export { viewBox_2 as viewBox };
|
|
31
|
+
}
|
|
32
|
+
export namespace MINUS {
|
|
33
|
+
let id_3: string;
|
|
34
|
+
export { id_3 as id };
|
|
35
|
+
let paths_3: string[];
|
|
36
|
+
export { paths_3 as paths };
|
|
37
|
+
let viewBox_3: string;
|
|
38
|
+
export { viewBox_3 as viewBox };
|
|
39
|
+
}
|
|
40
|
+
export namespace MOVE {
|
|
41
|
+
let id_4: string;
|
|
42
|
+
export { id_4 as id };
|
|
43
|
+
let paths_4: string[];
|
|
44
|
+
export { paths_4 as paths };
|
|
45
|
+
let viewBox_4: string;
|
|
46
|
+
export { viewBox_4 as viewBox };
|
|
47
|
+
}
|
|
48
|
+
export namespace PLAY {
|
|
49
|
+
let id_5: string;
|
|
50
|
+
export { id_5 as id };
|
|
51
|
+
let paths_5: string[];
|
|
52
|
+
export { paths_5 as paths };
|
|
53
|
+
let viewBox_5: string;
|
|
54
|
+
export { viewBox_5 as viewBox };
|
|
55
|
+
}
|
|
56
|
+
export namespace PLUS {
|
|
57
|
+
let id_6: string;
|
|
58
|
+
export { id_6 as id };
|
|
59
|
+
let paths_6: string[];
|
|
60
|
+
export { paths_6 as paths };
|
|
61
|
+
let viewBox_6: string;
|
|
62
|
+
export { viewBox_6 as viewBox };
|
|
63
|
+
}
|
|
64
|
+
export namespace CONTENT_COPY {
|
|
65
|
+
let id_7: string;
|
|
66
|
+
export { id_7 as id };
|
|
67
|
+
let paths_7: string[];
|
|
68
|
+
export { paths_7 as paths };
|
|
69
|
+
let viewBox_7: string;
|
|
70
|
+
export { viewBox_7 as viewBox };
|
|
71
|
+
}
|
|
72
|
+
export namespace TRACK_LINE {
|
|
73
|
+
let id_8: string;
|
|
74
|
+
export { id_8 as id };
|
|
75
|
+
let paths_8: string[];
|
|
76
|
+
export { paths_8 as paths };
|
|
77
|
+
let viewBox_8: string;
|
|
78
|
+
export { viewBox_8 as viewBox };
|
|
79
|
+
}
|
|
80
|
+
export namespace SELECT {
|
|
81
|
+
let id_9: string;
|
|
82
|
+
export { id_9 as id };
|
|
83
|
+
let viewBox_9: string;
|
|
84
|
+
export { viewBox_9 as viewBox };
|
|
85
|
+
let paths_9: string[];
|
|
86
|
+
export { paths_9 as paths };
|
|
87
|
+
}
|
|
88
|
+
export namespace CHECK_SQUARE_O {
|
|
89
|
+
let id_10: string;
|
|
90
|
+
export { id_10 as id };
|
|
91
|
+
let viewBox_10: string;
|
|
92
|
+
export { viewBox_10 as viewBox };
|
|
93
|
+
let paths_10: string[];
|
|
94
|
+
export { paths_10 as paths };
|
|
95
|
+
}
|
|
96
|
+
export namespace SQUARE_O {
|
|
97
|
+
let id_11: string;
|
|
98
|
+
export { id_11 as id };
|
|
99
|
+
let viewBox_11: string;
|
|
100
|
+
export { viewBox_11 as viewBox };
|
|
101
|
+
let paths_11: string[];
|
|
102
|
+
export { paths_11 as paths };
|
|
103
|
+
}
|
|
104
|
+
export namespace FILE_O {
|
|
105
|
+
let id_12: string;
|
|
106
|
+
export { id_12 as id };
|
|
107
|
+
let viewBox_12: string;
|
|
108
|
+
export { viewBox_12 as viewBox };
|
|
109
|
+
let paths_12: string[];
|
|
110
|
+
export { paths_12 as paths };
|
|
111
|
+
}
|
|
112
|
+
export namespace CHEVRON_RIGHT {
|
|
113
|
+
let id_13: string;
|
|
114
|
+
export { id_13 as id };
|
|
115
|
+
let viewBox_13: string;
|
|
116
|
+
export { viewBox_13 as viewBox };
|
|
117
|
+
let paths_13: string[];
|
|
118
|
+
export { paths_13 as paths };
|
|
119
|
+
}
|
|
120
|
+
export namespace CHEVRON_DOWN {
|
|
121
|
+
let id_14: string;
|
|
122
|
+
export { id_14 as id };
|
|
123
|
+
let viewBox_14: string;
|
|
124
|
+
export { viewBox_14 as viewBox };
|
|
125
|
+
let paths_14: string[];
|
|
126
|
+
export { paths_14 as paths };
|
|
127
|
+
}
|
|
128
|
+
export namespace FOLDER_O {
|
|
129
|
+
let id_15: string;
|
|
130
|
+
export { id_15 as id };
|
|
131
|
+
let viewBox_15: string;
|
|
132
|
+
export { viewBox_15 as viewBox };
|
|
133
|
+
let paths_15: string[];
|
|
134
|
+
export { paths_15 as paths };
|
|
135
|
+
}
|
|
136
|
+
export namespace FOLDER_OPEN_O {
|
|
137
|
+
let id_16: string;
|
|
138
|
+
export { id_16 as id };
|
|
139
|
+
let viewBox_16: string;
|
|
140
|
+
export { viewBox_16 as viewBox };
|
|
141
|
+
let paths_16: string[];
|
|
142
|
+
export { paths_16 as paths };
|
|
143
|
+
}
|
|
144
|
+
export const all: {
|
|
145
|
+
id: string;
|
|
146
|
+
paths: string[];
|
|
147
|
+
viewBox: string;
|
|
148
|
+
}[];
|
|
149
|
+
export const svgGeoMapIcon: HTMLElement;
|
|
150
|
+
export const svgHorizontal1dHeatmap: HTMLElement;
|
|
151
|
+
export const svgHorizontalLineIcon: HTMLElement;
|
|
152
|
+
export const svg2DTilesIcon: HTMLElement;
|
|
153
|
+
export const svg2DHeatmapIcon: HTMLElement;
|
|
154
|
+
export const svg1DAxisIcon: HTMLElement;
|
|
155
|
+
export const svgVertical1DAxisIcon: HTMLElement | null;
|
|
156
|
+
export const svgGeneAnnotationsIcon: HTMLElement;
|
|
157
|
+
export const svg1DTilesIcon: HTMLElement;
|
|
158
|
+
export const svgVertical1DTilesIcon: HTMLElement | null;
|
|
159
|
+
export const svgArrowheadDomainsIcon: HTMLElement;
|
|
160
|
+
import React from 'react';
|
|
161
|
+
import PropTypes from 'prop-types';
|