SvInspectorView
Auto-generated @jbrowse/mobx-state-tree API for the current JBrowse release — see pluggable elements for concepts. Provided by the sv-inspector plugin. View source.
Example usage
{
type: 'SvInspectorView',
assembly: 'hg38',
uri: 'https://example.com/sv.vcf.gz',
fileType: 'VCF',
}does not extend, but is a combination of a
Members a composed model contributes are listed here too, so these tables are the whole surface.
Properties
| Member | Description | Defined by |
|---|---|---|
idid: ElementId | SvInspectorView | |
typetype: types.literal('SvInspectorView') | SvInspectorView | |
heightheight: types.stripDefault(types.number, defaultHeight) | height of the whole view in pixels | SvInspectorView |
| onlyDisplayRelevantRegionsInCircularView | draw only the chromosomes the visible rows touch | SvInspectorView |
spreadsheetWidthFractionspreadsheetWidthFraction: types.stripDefault(types.number, 0.66) | share of the view's width given to the spreadsheet | SvInspectorView |
| spreadsheetView | SvInspectorView | |
| circularView | SvInspectorView | |
| launch | transient launch keys, forwarded to the sheet on attach and cleared; author them directly on the view | SvInspectorView |
displayNamedisplayName: types.maybe(types.string) | displayName is displayed in the header of the view, or assembly names being used if none is specified | BaseViewModel |
minimizedminimized: types.stripDefault(types.boolean, false) | collapse the view to its header bar, keeping it in the session rather than closing it | BaseViewModel |
Volatiles
| Member | Description | Defined by |
|---|---|---|
| SpreadsheetViewReactComponent | SvInspectorView | |
CircularViewReactComponentCircularViewReactComponent: CircularViewType.ReactComponent | SvInspectorView | |
widthwidth: 800 | BaseViewModel | |
bodyMountedbodyMounted: true | Whether the container has this view's body in the DOM.ViewContainer mounts a view's body only while an IntersectionObserver says it is on screen, to hold the app under the WebGL2 context ceiling (reference/GPU_PORTABILITY.md). A view below the fold therefore has no canvas, so nothing ever calls markCanvasDrawn and the pre-first-paint term of displayPhase pins every display in it at loading with nothing left to resolve it — which parks [data-app-phase="ready"] for the whole app on a view the user cannot see.Defaults true so the containers that always mount a body — embedded views, workspace panels, and any test rendering a display directly — are unaffected and need not set it. The raw flag, written by this view's own container. A display asks effectiveBodyMounted instead, because a nested view has no container of its own. | BaseViewModel |
Getters
| Member | Description | Defined by |
|---|---|---|
| pendingLaunch | SvInspectorView | |
| currentAssembly | SvInspectorView | |
assemblyNamestring | undefined | SvInspectorView | |
showCircularViewboolean | false while the sheet shows its import form | SvInspectorView |
showLoadingboolean | both halves' loading state; the circle counts only while shown | SvInspectorView |
| ownViews | an unshown circle never initializes, so it would read as loading forever | SvInspectorView |
featuresSimpleFeatureSerialized[] | the records of the rows the sheet's filters leave | SvInspectorView |
allFeaturesSimpleFeatureSerialized[] | every record of the sheet, which the chord track holds; filters narrow it through visibleChordIds rather than rebuilding the track | SvInspectorView |
visibleChordIdsstring[] | undefined | undefined while no filter narrows the sheet | SvInspectorView |
canonicalFeatureRefNameSetSet<string> | every canonical refName the visible features' chords land on, both ends included | SvInspectorView |
circularDisplayedRegionsBasicRegion[] | undefined | never narrowed to nothing, which would draw an empty circle | SvInspectorView |
effectiveSpreadsheetWidthFractionnumber | SvInspectorView | |
subviewWidths{ spreadsheet: number; circular: number; } | SvInspectorView | |
highlightedChordIdsstring[] | undefined | the records of the selected record's event, which the circle keeps at full strength while it dims the rest | SvInspectorView |
variantTrackIdstring | SvInspectorView | |
| featuresCircularTrackConfiguration | SvInspectorView | |
rendersDisplaysboolean | Overridable hook (default true): whether this view's mounted body renders its own displays. A linear genome view collapsed to its ruler mounts the scalebar and none of its tracks, so a display in it can no more paint than one in a view scrolled off screen. Views nested in this one are unaffected: they paint wherever their own body is. | BaseViewModel |
effectiveBodyMountedboolean | Whether this view's displays have a canvas to paint into: its body is in the DOM, counting the views it is nested inside, and the body renders them (rendersDisplays). This is the question a display's phase asks.bodyMounted alone answers the DOM half only for a view a container renders directly. A view nested in another view (a synteny row, a breakpoint panel) has no container writing its flag, so it reads true forever while its whole subtree is out of the DOM, and every display in it waits for a first paint that nothing will make — the hang this flag exists to prevent, one level down.An ancestor that does not carry the flag at all leaves the answer alone rather than excusing the paint: only an explicit false unmounts, so a duck-typed stand-in that forgot it keeps waiting, which is the failure that shows up as a slow test rather than as a picture of an empty view. | BaseViewModel |
ownTracksAbstractTrackModel[] | The tracks this view puts in the census — its own, not a nested view's. Empty here, and overridden by the views that have any: the base cannot read self.tracks for them, because what a view keeps under that name is the view's business. react-msaview's holds its MSA annotation rows — {ReactComponent, model} objects with no configuration and no displays — and a base that helped itself to them handed them to the readiness marker as tracks, which error-paged every session holding an MSA view. | BaseViewModel |
Methods
| Member | Description |
|---|---|
Actions
| Member | Description | Defined by |
|---|---|---|
setHeight(newHeight: number) => number | SvInspectorView | |
setOnlyDisplayRelevantRegionsInCircularView(val: boolean) => void | SvInspectorView | |
resizeSpreadsheetWidth(distance: number) => void | accumulates onto the fraction, not the rounded spreadsheetView.width, so the divider doesn't creep a pixel per drag frame | SvInspectorView |
| setLaunch | SvInspectorView | |
resizeHeight(distance: number) => number | SvInspectorView | |
setDisplayName(name: string) => void | BaseViewModel | |
setWidth(newWidth: number) => void | width is an important attribute of the view model, when it becomes set, it often indicates when the app can start drawing to it. certain views like lgv are strict about this because if it tries to draw before it knows the width it should draw to, it may start fetching data for regions it doesn't need to setWidth is updated by a ResizeObserver generally, the views often need to know how wide they are to properly draw genomic regions | BaseViewModel |
setBodyMounted(flag: boolean) => void | See bodyMounted. Written by the view's container, which is the only thing that knows whether it rendered the body. | BaseViewModel |
setMinimized(flag: boolean) => void | BaseViewModel |
Related links
- Guide: URL query parameter API