LinearVariantDisplay
Auto-generated @jbrowse/mobx-state-tree API for the current JBrowse release — see pluggable elements for concepts. Provided by the variants plugin. View source.
Example usage
A complete VariantTrack config to paste into tracks:
{
type: 'VariantTrack',
trackId: 'variants',
name: 'Variants',
assemblyNames: ['hg38'],
adapter: {
type: 'VcfTabixAdapter',
uri: 'https://example.com/variants.vcf.gz',
},
displays: [
{
type: 'LinearVariantDisplay',
displayId: 'variants-LinearVariantDisplay',
height: 150,
},
],
}
GPU-accelerated variant display with custom feature widget on click.
The configuration slots for this model are documented on its config schema page.
Members a composed model contributes are listed here too, so these tables are the whole surface.
Properties
| Member | Description | Defined by |
|---|---|---|
typetype: types.literal('LinearVariantDisplay') | LinearVariantDisplay | |
configurationconfiguration: ConfigurationReference(configSchema) | LinearCanvasBaseDisplay | |
jexlFiltersSettingjexlFiltersSetting: types.maybe(types.array(types.string)) | Runtime "Filter by..." override. | LinearCanvasBaseDisplay |
| pinnedFeatureIds | Feature ids the user pinned to the top of the layout via the feature right-click menu. | LinearCanvasBaseDisplay |
| soloFeatureIds | "Show only these features": the collected set the user builds by ctrl+clicking features (or via the right-click menu). | LinearCanvasBaseDisplay |
soloAppliedsoloApplied: types.stripDefault(types.boolean, false) | Whether the collected soloFeatureIds set is actually isolating the view (worker drops non-members). | LinearCanvasBaseDisplay |
| "Hide this feature" exclusion set (inverse of solo): the worker drops these from layout/drawing. | LinearCanvasBaseDisplay | |
| expandedGeneIds | Genes the user opened from the isoform badge on their own label: these draw every isoform whatever geneGlyphMode or the fit ladder's isoform rung would otherwise collapse them to. | LinearCanvasBaseDisplay |
| featureHighlights | Declarative feature highlights, typically seeded by a text search (highlight the gene you searched for). | LinearCanvasBaseDisplay |
idid: ElementId | BaseDisplay |
Volatiles
| Member | Description | Defined by |
|---|---|---|
featureIdUnderMousefeatureIdUnderMouse: undefined as string | undefined | LinearCanvasBaseDisplay | |
subfeatureIdUnderMousesubfeatureIdUnderMouse: undefined as string | undefined | LinearCanvasBaseDisplay | |
mouseoverExtraInformationmouseoverExtraInformation: undefined as string[] | undefined | the hover tooltip's rows, each rendered as its own element — see hoverTooltipRows for why this is a list and not one HTML string | LinearCanvasBaseDisplay |
| sequenceHoverPosition | genomic base currently hovered in a feature sequence dialog opened from this display, read by the LGV crosshair overlay | LinearCanvasBaseDisplay |
incrementalLayoutincrementalLayout: createIncrementalLayout() | LinearCanvasBaseDisplay | |
incrementalLayoutLabelsOnlyincrementalLayoutLabelsOnly: createIncrementalLayout() | LinearCanvasBaseDisplay | |
incrementalLayoutBodiesOnlyincrementalLayoutBodiesOnly: createIncrementalLayout() | LinearCanvasBaseDisplay | |
| incrementalLayoutDecimated | LinearCanvasBaseDisplay | |
| incrementalLayoutIsoforms | LinearCanvasBaseDisplay | |
incrementalLayoutBareincrementalLayoutBare: createIncrementalLayout() | LinearCanvasBaseDisplay | |
morphFromTopsmorphFromTops: undefined as Map<string, number> | undefined | LinearCanvasBaseDisplay | |
morphProgressmorphProgress: 1 | LinearCanvasBaseDisplay | |
morphStartMsmorphStartMs: 0 | LinearCanvasBaseDisplay | |
morphFromMaxYmorphFromMaxY: 0 | LinearCanvasBaseDisplay | |
errorerror: undefined as unknown | BaseDisplay | |
statusMessagestatusMessage: undefined as string | undefined | BaseDisplay | |
statusProgressstatusProgress: undefined as number | undefined | determinate progress fraction [0,1] for the current status, or undefined when the in-flight phase is indeterminate. Set alongside statusMessage by setStatusMessage; a display that never shows a bar simply leaves it undefined. | BaseDisplay |
scrollTopscrollTop: 0 | TrackHeightMixin | |
loadedRegionsloadedRegions: regionDataMap<LoadedRegion>('loadedRegions') | The per-region store, keyed by displayedRegionIndex: what a fetch asked for (the span), what it was issued under (fetchInputs) and what it brought back (payload), written as one record by ctx.commitRegion.A display's own rpcDataMap was the payload column of this map held separately, and every hook that existed to keep the two in step — clearDisplaySpecificData, a regionHasData that answered rpcDataMap.has(idx), a hand-rolled prune — was that separation's cost. A display reads the payload back through regionPayloads. | MultiRegionDisplayMixin |
forceLoadTrackforceLoadTrack: false | The force-load button's track-wide approval. Volatile so it never reaches a saved session; the forceLoad config slot is the durable form. | RegionTooLargeMixin |
byteEstimatebyteEstimate: undefined as ByteEstimate | undefined | The last byte measurement: bytes, the span they were taken at, and whether zooming has been shown not to shrink them. Survives clearAllRpcData; dropped on chromosome navigation and on a tier swap. | RegionTooLargeMixin |
gateMeasuredViewportKeygateMeasuredViewportKey: undefined as string | undefined | The gateViewport key the gate last asked the adapter about, on either axis — the viewport AND the settings it asked under. Separate from byteEstimate because a density refusal measures no bytes. | RegionTooLargeMixin |
canvasDrawncanvasDrawn: false | flips true on first paint; read by test selectors to detect render | RenderLifecycleMixin |
currentRenderingBackendcurrentRenderingBackend: undefined | current backend reference, updated on context-loss recovery. Typed unknown (not generic B) on purpose: this mixin is composed by every display via a non-generic factory, so the per-display backend type B isn't known here — it's supplied at attachRenderingBackend<B> and narrowed with as B inside the autoruns. Don't "fix" the cast. | RenderLifecycleMixin |
renderTickrenderTick: 0 | counter the render autorun observes; bumped to force a re-render | RenderLifecycleMixin |
autorunsInstalledautorunsInstalled: false | guards attachRenderingBackend so the autorun pair spawns once per instance | RenderLifecycleMixin |
renderErrorrenderError: undefined | the render-backend (GPU/Canvas2D init or context-loss) error, or undefined. Single source of truth for the render-error terminal state: useRenderingBackend writes it from the canvas-init mechanism so the model — not React-local hook state — owns every terminal state. Read by displayPhase (whose renderError term outranks loading, suppressing the scrim) and by DisplayChrome (shows the retry overlay). | RenderLifecycleMixin |
activeStopTokenactiveStopToken: undefined as StopToken | undefined | stop token of the in-flight fetch, or undefined when idle | FetchMixin |
fetchGenerationfetchGeneration: 0 | bumps at every fetch end; autoruns read it to re-evaluate, and it doubles as the staleness epoch inside runFetch | FetchMixin |
reloadCounterreloadCounter: 0 | Bumped by reload() and read unconditionally by the fetch autoruns, so a user retry re-runs the body even where nothing else moved — after an error every other fetch input is unchanged. It is also the half that survives a reload() override that forgets to invalidate, which is the dead Retry button makeRetryContractCheck reports. Declared here because this is the one mixin every fetch foundation composes, the same argument that put fetchInert below; the comparative family carried its own until ADR-105. | FetchMixin |
statusWindowstatusWindow: createStatusWindow(writeStatus(self)) | This display's status field, and the only thing that writes it: one throttle window, one slot per concurrent operation, so N parallel per-region fetches thin to one stream between them rather than N and a second operation cannot end the first one's label (ADR-081). Lent whole to createStopTokenRotation by a display that also runs a bare-autorun fetch — see StatusReporter. | FetchMixin |
fetchCanceledfetchCanceled: false | true after the user explicitly cancels a load (the loading overlay's cancel button → cancelFetchByUser). A durable, blocking state — unlike cancelFetch, it does not retrigger the fetch autoruns — so the load stays stopped until the user retries (reload) or the viewport changes. Any new fetch clears it (runFetch resets it at the start). | FetchMixin |
| fetchRotation | The latest-wins machine this mixin is a wrapper around, and not a second one: createStopTokenRotation owns token rotation, the isCurrent guard, the status slot and the supersede-versus-end rule (ADR-080, ADR-081), for every fetch in the codebase that has one. runFetch adds the observable bookkeeping a display needs on top — isLoading, error, fetchGeneration, fetchCanceled — and nothing else.It was two implementations of that machine until 2026-08-20, which is how they came to disagree about whether a completed fetch releases its token. A display's primary fetch is this wrapper; a second concurrent fetch on the same node holds a rotation of its own, which is why the primitive is the thing that exists and this is the thing built on it (ADR-054 §1, the one section ADR-105 keeps). It is lent this display's statusWindow, so the fetch takes a slot on the one field rather than opening a second window over it — the whole point of StatusReporter. | FetchMixin |
| densityStatsPerRegion | Per-region feature counts, so the verdict is a live max at the current bpPerPx. | CanvasFeatureGateMixin |
densityHoverPxdensityHoverPx: undefined as number | undefined | The cursor's view px, not the bp under it: a wheel zoom under a stationary cursor fires no mousemove, and the px stays true through it. | DensityBandMixin |
coarseTiercoarseTier: regionDataMap<P>('coarseTier') | The coarse payload by displayedRegionIndex, over the regions the last read was issued for. Cleared on chromosome navigation. | CoarseTierMixin |
coarseTierReadcoarseTierRead: undefined as CoarseTierRead | undefined | What the held payloads were read over — the buffered regions and the read key — so a pan or a zoom inside them re-reads nothing. Undefined until a read lands. | CoarseTierMixin |
coarseTierLoadingcoarseTierLoading: false | CoarseTierMixin | |
contextMenuInfo: undefined as Info | undefined | ContextMenuMixin |
Getters
| Member | Description | Defined by |
|---|---|---|
featureNounstring | Renames the shared canvas vocabulary for this display: every menu row, chip and indicator that names what the track holds reads this, so a variant track says "Variant height", "Hide this variant", "Showing 3 variants" instead of inheriting the gene-oriented "feature". The per-hit noun in the context menu still comes from the annotation's own type where it has one. | LinearVariantDisplay |
featureWidgetType{ type: string; id: string; } | LinearVariantDisplay | |
colorsByConsequenceImpactboolean | LinearVariantDisplay | |
colorsBySvTypeboolean | LinearVariantDisplay | |
colorLegendLegendItem[] | This display's answer to the base's colorLegend chrome hook: the rows for whichever preset color key is active (impact tiers or SV classes), or none. SV-type shows the fixed class key; copy-number and unrecognized tokens aren't listed (the pure jexl has no present-set). The shared canvas body draws the key, so this display needs no component of its own. | LinearVariantDisplay |
rpcDataMapReadonlyMap<number, LoadedFeatureData> | The fetched features, keyed by displayedRegionIndex — the foundation's per-region store, narrowed. | LinearCanvasBaseDisplay |
| conf | the config typed off the concrete schema; ConfigurationReference erases self.configuration to any, so direct reads route through this to stay typed (same move as BaseAdapter<CONF>). | LinearCanvasBaseDisplay |
showOutlineboolean | LinearCanvasBaseDisplay | |
featureColorany | LinearCanvasBaseDisplay | |
utrColorstring | LinearCanvasBaseDisplay | |
colorByMode"attribute" | "default" | "solid" | "strand" | LinearCanvasBaseDisplay | |
colorByAttributestring | LinearCanvasBaseDisplay | |
geneGlyphNoticeGeneGlyphNotice | undefined | Overridable hook (default absent): the isoform-collapse control the shared canvas body draws in its bottom-right chip stack, or nothing when the display has no gene glyphs. | LinearCanvasBaseDisplay |
layoutReadyboolean | Whether features can be laid out: data is fetched, in-bounds, and the view is measured. | LinearCanvasBaseDisplay |
onScreenFeatureIdsReadonlySet<string> | undefined | The features whose bp span touches the viewport. | LinearCanvasBaseDisplay |
labelDensityPerPxnumber | Features per pixel of what is actually ON SCREEN — the density the auto label modes gate on (ADR-093). | LinearCanvasBaseDisplay |
renderState{ scrollY: number; canvasWidth: number; canvasHeight: number; } | LinearCanvasBaseDisplay | |
labelScrollBucketnumber | LinearCanvasBaseDisplay | |
displayMode"collapsed" | "compact" | "normal" | "superCompact" | LinearCanvasBaseDisplay | |
effectiveSubfeatureLabels"below" | "none" | "overlay" | The subfeature-label mode the worker bakes. | LinearCanvasBaseDisplay |
labelFontSizenumber | LinearCanvasBaseDisplay | |
showLabelsMode"auto" | "description" | "name" | "nameAndDescription" | "none" | LinearCanvasBaseDisplay | |
showLabelsboolean | LinearCanvasBaseDisplay | |
showDescriptionsboolean | LinearCanvasBaseDisplay | |
effectiveShowDescriptionsboolean | LinearCanvasBaseDisplay | |
selectedFeatureIdstring | undefined | LinearCanvasBaseDisplay | |
colorByCDSboolean | LinearCanvasBaseDisplay | |
showAminoAcidsboolean | LinearCanvasBaseDisplay | |
reversedRegionsSet<number> | LinearCanvasBaseDisplay | |
pinnedFeatureIdSetReadonlySet<string> | LinearCanvasBaseDisplay | |
expandedGeneIdSetReadonlySet<string> | LinearCanvasBaseDisplay | |
soloFeatureIdSetReadonlySet<string> | LinearCanvasBaseDisplay | |
number | LinearCanvasBaseDisplay | |
soloFeatureCountnumber | LinearCanvasBaseDisplay | |
pinnedFeatureCountnumber | LinearCanvasBaseDisplay | |
canonicalFeatureHighlightsFeatureHighlight[] | LinearCanvasBaseDisplay | |
resolvedHighlightsResolvedHighlights | LinearCanvasBaseDisplay | |
highlightedFeatureIdSetReadonlySet<string> | LinearCanvasBaseDisplay | |
layoutPinnedFeatureIdSetReadonlySet<string> | LinearCanvasBaseDisplay | |
featureHighlightCountnumber | LinearCanvasBaseDisplay | |
| layoutInputs | Layout inputs shared by the base layout and every fit rung, expandedGeneIds included: a rung inheriting them without the exemption re-collapses the gene the user just opened. | LinearCanvasBaseDisplay |
fitMeasureFeatureIdsReadonlySet<string> | undefined | The features the ladder measures its rungs and its isoform solve against: the on-screen set in fit and fixed, undefined in grow (which measures the whole stack). | LinearCanvasBaseDisplay |
showsEveryIsoformboolean | Overridable hook (default false): the display's transcript setting names every isoform, so the fit ladder's isoforms rung may not trim — the surplus scrolls instead. | LinearCanvasBaseDisplay |
effectiveGeneGlyphMode"all" | "auto" | "longestCoding" | Overridable hook: the gene-glyph mode the worker collapses under. | LinearCanvasBaseDisplay |
reservesBelowLabelRowsboolean | Whether the settings reserve below subfeature-label rows, which is what earns the fit ladder its bare rung — with nothing reserved the rung would repack an identical stack. | LinearCanvasBaseDisplay |
fullReservationLabelReservation | What the full rung reserves: the names and descriptions the settings ask for. | LinearCanvasBaseDisplay |
labelsReservationLabelReservation | The labels and decimated rungs' reservation: names kept, descriptions dropped. | LinearCanvasBaseDisplay |
isoformsReservationLabelReservation | The isoforms rung's reservation. | LinearCanvasBaseDisplay |
decimatedBaseInputsLabelRoomFactorFreeInputs | The decimated rung's layout inputs minus the whitespace factor. | LinearCanvasBaseDisplay |
decimatedHeightProbe(labelRoomFactor: number) => number | Measures the decimated rung's stack height at any whitespace factor, against the features the ladder measures its rungs with — so the factor the solve picks is judged on the same stack the rung is then kept or rejected on. | LinearCanvasBaseDisplay |
isoformsBaseInputsIsoformCountFreeInputs | The isoforms rung's layout inputs minus the count itself, typed without it so the solve's shared preparation provably cannot depend on it. | LinearCanvasBaseDisplay |
isoformsHeightProbe(maxIsoforms: number) => number | Measures the isoforms rung's stack height at any isoform count, against the features the ladder measures its rungs with. | LinearCanvasBaseDisplay |
maxIsoformsOnScreennumber | The most isoforms any trimmable gene ON SCREEN has — the top of the solve's bracket, and the count above which a trim can take nothing away. | LinearCanvasBaseDisplay |
fitIsoformCountnumber | undefined | The isoform count the isoforms rung commits at: the largest whose names-kept stack fits fitTargetHeight, so the most transcripts are kept without giving up a name. | LinearCanvasBaseDisplay |
fitIsoformsSolvedMap<number, FeatureDataResult> | The isoforms stack: every gene trimmed to fitIsoformCount transcripts, names intact. | LinearCanvasBaseDisplay |
baseLaidOutDataMapMap<number, FeatureDataResult> | Full reservation (names + descriptions): rendered at fit stage full and in non-fit modes, and the first stack fitStage probes. | LinearCanvasBaseDisplay |
fitLabelsOnlyLayoutMap<number, FeatureDataResult> | Names reserved, descriptions dropped — the labels stage's stack. | LinearCanvasBaseDisplay |
fitDecimatedFactornumber | undefined | The whitespace factor the decimated rung commits at: the smallest one whose packed stack fits fitTargetHeight, so the most names are kept. | LinearCanvasBaseDisplay |
fitDecimatedSolvedMap<number, FeatureDataResult> | The decimated stack: names kept only on features with at least fitDecimatedFactor × their label width in neighbour whitespace (plus pinned/highlighted, always). | LinearCanvasBaseDisplay |
fitBodiesOnlyLayoutMap<number, FeatureDataResult> | LinearCanvasBaseDisplay | |
fitBareLayoutMap<number, FeatureDataResult> | The bare stack: bodies with the below subfeature-label rows spent at zero height, so the last reduction before a squeeze gives back rows whose text the squeeze was about to hide anyway. | LinearCanvasBaseDisplay |
fitSmallestBoxPxnumber | The shortest box the layout draws on screen, read off the layout rather than the featureHeight slot, a per-feature jexl callback that throws with no feature in scope. | LinearCanvasBaseDisplay |
fitMinScalenumber | Floor on the fit squeeze: the smallest vertical scale that still leaves every drawn box at least MIN_FIT_BOX_PX tall. | LinearCanvasBaseDisplay |
fitMaxScalenumber | Ceiling on the fit grow: the largest vertical scale before a feature body exceeds the height it would have outside fit mode. | LinearCanvasBaseDisplay |
fitStageFitStage | The resolved fit outcome — which reservation level survived, its unscaled layout, and the vertical scale to fill the track — bundled so the three can never disagree. | LinearCanvasBaseDisplay |
fitScalenumber | Uniform vertical scale for fit mode; 1 unless the resolved stack is being grown to fill the track (> 1) or the bodies stack squeezed to fit (< 1). | LinearCanvasBaseDisplay |
laidOutDataMapReadonlyMap<number, FeatureDataResult> | What every consumer (hit test, GPU upload, React render) reads: the resolved fit layout, cloned and scaled only when grown or squeezed. | LinearCanvasBaseDisplay |
renderedShowDescriptionsboolean | Descriptions are painted where the kept rung reserved room for them. | LinearCanvasBaseDisplay |
renderedShowLabelsboolean | Names are painted where the kept rung reserved row height + overhang for them. | LinearCanvasBaseDisplay |
renderedShowSubfeatureLabelsboolean | A subfeature label (a transcript name under its gene) is worker-baked and its row is reserved in the pack, so it survives every rung that kept those rows and goes only where the kept rung spent them at zero. | LinearCanvasBaseDisplay |
fitDropsFitDrops | What the ladder took from the labels the settings reserved, and how far it squeezed — the one derivation both user-facing notes read. | LinearCanvasBaseDisplay |
fitNotestring | undefined | The track-sizing control's account of what fit mode gave up, or undefined when nothing. | LinearCanvasBaseDisplay |
labelsFitHintstring | undefined | The note on the selected "Labels" radio while the ladder is not honouring it (see inertLabelHint). | LinearCanvasBaseDisplay |
morphEasednumber | LinearCanvasBaseDisplay | |
renderDataMapReadonlyMap<number, FeatureDataResult> | LinearCanvasBaseDisplay | |
settledMaxYnumber | LinearCanvasBaseDisplay | |
maxYnumber | LinearCanvasBaseDisplay | |
scrollExtentMaxYnumber | LinearCanvasBaseDisplay | |
hasOverflowboolean | LinearCanvasBaseDisplay | |
truncatedFeatureCountnumber | LinearCanvasBaseDisplay | |
contentHeightnumber | LinearCanvasBaseDisplay | |
scrollContentHeightnumber | LinearCanvasBaseDisplay | |
scrollableHeightnumber | LinearCanvasBaseDisplay | |
growTargetHeightnumber | LinearCanvasBaseDisplay | |
featureIdIndexMap<string, FlatbushItem> | LinearCanvasBaseDisplay | |
subfeatureIdIndexMap<string, SubfeatureInfo> | LinearCanvasBaseDisplay | |
hoveredFeatureFlatbushItem | undefined | LinearCanvasBaseDisplay | |
hoveredSubfeatureSubfeatureInfo | undefined | LinearCanvasBaseDisplay | |
hoverBoxFeatureFlatbushItem | undefined | The feature the hover box frames: the open context menu's target while one is open, so the box always agrees with what the menu acts on, else the feature under the cursor. | LinearCanvasBaseDisplay |
hoverBoxSubfeatureSubfeatureInfo | undefined | The transcript the hover box frames instead of its gene, by the rule of hoverBoxFeature. | LinearCanvasBaseDisplay |
featureItemMapMap<string, FeatureItemEntry> | LinearCanvasBaseDisplay | |
flatbushIndexesMap<number, FlatbushRegionIndexes> | LinearCanvasBaseDisplay | |
zoomFetchKeystring | LinearCanvasBaseDisplay | |
parentTrackAbstractTrackModel | BaseDisplay | |
RenderingComponentFC<…> | BaseDisplay | |
| DisplayBlurb | BaseDisplay | |
adapterConfigRecord<string, unknown> | BaseDisplay | |
isMinimizedboolean | Returns true if the parent track is minimized. Used to skip expensive operations like autoruns when track is not visible. | BaseDisplay |
heightnumber | TrackHeightMixin | |
resizingboolean | True for the duration of a height drag on this track, whichever handle is running it. A display whose row geometry is a function of the track height restretches every row per animation frame, and can use this to sit an expensive per-frame layer out of the drag (MAF's dense per-base letter overlay is a Canvas2D pass that scales with rows x columns). The flag itself is the track's ( BaseTrackModel), so the view brackets a drag without needing the active display to have opted into this mixin. Reading it here is what makes self.resizing available to a display that did. | TrackHeightMixin |
heightMode"fit" | "fixed" | "grow" | The resolved track-height strategy (fixed/grow/fit). Promotable sentinel slot: resolveConf walks the customized-track -> session-default -> fixed cascade and never returns the inherit sentinel. | HeightModeMixin |
fitTargetHeightnumber | The drag-resizable track height as stored in the config slot — the fit target the fit/grow layout scales or packs content into. Read there instead of the reactive height getter to break the grow-mode cycle (height->grownHeight->layout->height). Equals height in fixed/fit. | HeightModeMixin |
growMaxHeightnumber | Ceiling grow mode sizes the track to, in px (content past it scrolls). Lives here rather than as a constant so a track whose whole point is a deep pileup can raise it; both displays that own a grownHeight read this, so the two can't diverge. | HeightModeMixin |
autoHeightboolean | grow mode as a boolean, derived from the unified heightMode slot. | HeightModeMixin |
fitHeightToDisplayboolean | fit mode as a boolean, derived from the unified heightMode slot. | HeightModeMixin |
grownHeightnumber | Target track height for grow: what the content wants, capped so a deep stack doesn't grow the track to thousands of px (the remainder scrolls). What installGrowExitBake bakes into the slot on exit. | HeightModeMixin |
showLegendboolean | Whether the legend is drawn. Resolved through the promotable-slot tiers (resolveConf): an explicit track value customizes it either way, otherwise it follows the session-wide default for this display type, falling back to the slot's promotedBase. | LegendMixin |
showLegendDisplayTypeDefaultPin | The legend checkbox over every open track of this type. showLegendCheckboxItem takes this as its pin. | LegendMixin |
hostRegionHost | The containing LinearGenomeView, typed once for every display in this family — see containingHost for the cast it owns and why both foundations still declare the name. | MultiRegionDisplayMixin |
canvasWidthPxnumber | The CSS width of this display's on-screen canvas, in px — and the canvasWidth its renderState must carry, since the two have to agree or the bp→px mapping is scaled against a box it doesn't fill.trackWidthPx, not view.width: TrackRenderingContainer insets the rendering component by the 2px track outline under contain: strict, so a view.width-wide canvas overhangs its own container and the browser clips the overhang away. It renders almost identically, which is why MAF drifted onto view.width uncaught.A getter rather than a note on each display, because the choice was being made by copying a neighbour out of four plausible view getters — width (the viewport), this one, and totalWidthPx / totalWidthPxWithoutBorders (the content width, which the global family's heatmaps legitimately want: a different question, not a different answer). no-restricted-syntax bans the underlying read everywhere but this line, since a second spelling agrees until it doesn't.SVG export is the one exception: the export shell has no outline, so renderSvg overrides canvasWidth with the shell's own width (see LgvSvgBodyProps). | MultiRegionDisplayMixin |
settledSubPixelBinBpnumber | Genomic bp one cell of a per-base pass stands for at the settled zoom: subPixelBinBp off the host's debounced coarseBpPerPx, and 1 until the view initializes. A per-base encode or fetch reads this rather than the live zoom so a wheel tick does not redo every region. | MultiRegionDisplayMixin |
canRenderboolean | Overrides RenderLifecycleMixin's default-true hook with the LGV precondition both foundations share — see foundationCanRender. | MultiRegionDisplayMixin |
rendersCanvasboolean | Fills RenderLifecycleMixin's hook off fetchInert, as GlobalFetchMixin does: a display that will never fetch here shows a placeholder where its canvas would be. | MultiRegionDisplayMixin |
viewportWithinLoadedDataboolean | true when every visible block lies within an already-fetched region — i.e. the viewport shows data we actually loaded, not the stale fringe left after a zoom-out/pan. Drives the loading overlay through the pre-refetch debounce. Spatial only, and it stays that way. Whether the data held for a block is still what a fetch would bring back is isCacheValid, which dataCurrent conjoins for the export gate. The scrim reads this getter and dataSuperseded, never isCacheValid: a phase that went loading on a moved fetchInputs would raise the overlay into every zoom. | MultiRegionDisplayMixin |
viewportEmptyboolean | No content block is on screen, so this display has nothing to fetch and nothing to paint — see viewportEmpty.ts for the one viewport that reaches it, how narrow that is, and why the state still has to be terminal rather than a permanent scrim. Both foundations declare it over that one expression, the same way they each declare host and paintInert. | MultiRegionDisplayMixin |
fetchSuspendedboolean | Overridable hook (default false), read by the fetch plan: the display is drawing something in the features' place and wants no fetch while it does. DensityTierMixin says it while the band is up and the gate is not blocking, so a track forced to density never downloads the features it will not draw, while a refused viewport keeps its measurement pass and the gate can still release.Not fetchInert: that one suppresses the scrim and ends the export wait, and a display saying this still has its stand-in to load. On this foundation alone, because only this family's plan reads it. | MultiRegionDisplayMixin |
dataSupersededboolean | Overridable hook (default false): the held data is loaded and covers the viewport, but a fetch input has moved past it, so the data is about to be refetched. A display says so here rather than overriding dataCurrent, for the reason FetchMixin.fetchInert is a hook: an override has to restate the freshness terms and then misses the next one added.Both answers a display gives about being finished read it — the export gate through dataCurrent, the loading scrim through displayPhase. The export gate is the sharper case: awaitSvgReady samples freshness once, and an export that samples it inside this window renders the data that is about to be replaced. GWAS's LD auto-index is that case: adopting the top hit as the index SNP is an rpcProps change, so the very load that produced the top hit is what it invalidates — and SettingsInvalidate lands a tick after the write, so until it does not even staleSettingsDrawn has seen it.The window is NOT invisible on screen, which this used to say while displayPhase took a spatial-only argument: alignments' per-base wall spends the debounce plus the RPC painting a 1 px stripe every 8 px, with nothing in the key having moved yet.The input need not have settled yet. Alignments counts the debounce window ahead of its per-base bin, where the bin the data was fetched under has not moved and the clear is inevitable rather than committed. That is the half of the window an export lands in, since a reader zooms and then reaches for the menu. What may NOT go in is a change that could still be taken back: this fails hung, not stale. So state the live-vs-settled half as a value compare and leave key strings alone. The settled half — the stamp a fetch committed under against the key a fetch now would use — is the foundation's already, through the isCacheValid term in dataCurrent, and an override restating it buys nothing: a second derivation of the key's vocabulary reads "16|fine" against a live "16" the day the key grows an axis, latches this true, and every export of the display then waits out awaitSvgReady's backstop instead of failing. | MultiRegionDisplayMixin |
renderBlocksRenderBlock[] | Shared cached view for every LGV-based GPU display. A single displayedRegion may produce multiple render blocks (shared GPU buffer, different scissor clips on screen). Plugins that want to suppress rendering in certain states (e.g. no domain yet) can override this getter to return [] — the autorun lifecycle will then issue an empty-blocks render that clears the canvas. | MultiRegionDisplayMixin |
fetchInputsFetchInputs | What a fetch issued right now would stamp on a region: the settings tier (rpcProps() and the adapter config) and the zoom tier (the display's zoomFetchArgs() object, or its zoomFetchKey string where it has not been converted). fetchRegions captures it before the RPC goes out and stamps it beside the loaded region; isCacheValid compares against it.A value, not a string. The inputs already exist as the object the display sends the worker, so a second serialized spelling of them is one more thing to keep in step — and JSON.stringify, which was that spelling, cannot tell an undefined-valued field from an absent one. | MultiRegionDisplayMixin |
settingsFetchInputsunknown | The settings tier alone, which staleSettingsDrawn compares: the scrim goes up on a settings or adapter change and stays down on a zoom. | MultiRegionDisplayMixin |
regionPayloadsReadonlyMap<number, unknown> | The store's payloads, keyed by displayedRegionIndex. A display narrows this once — get rpcDataMap() { return self.regionPayloads as ReadonlyMap<number, MyResult> } — and every reader it already had goes on reading a map.MST makes a .views() getter a computed, so the Map is built once per store change and handed back by reference after that — which is what keeps installUpload's diff a reference compare per key and a frame that changed no data free of it. While something observes it: MobX suspends an unobserved computed and rebuilds on every read, so a display whose only reader is a pointer handler needs the keep-alive canvas and Manhattan both install (display-kit/CLAUDE.md §"A hit test's index needs an observer"). The render lifecycle's upload autorun is that reader for every display that draws. | MultiRegionDisplayMixin |
hasRegionDataboolean | A fetch has landed: at least one region's payload is in the store. The render callback's first-paint gate reads this, so an empty frame before any data cannot flip canvasDrawn; an empty but loaded region counts, and paints its empty frame. | MultiRegionDisplayMixin |
staleSettingsDrawnboolean | A visible block's held data was fetched under a settings or adapter key that has since moved: drawn, and wrong for the current settings, until the refetch isCacheValid already owes lands. The loading scrim's third staleness term, beside spatial coverage and dataSuperseded — the one that used to come from SettingsInvalidate emptying the coverage map, and the reason it no longer has to.False on a zoom by construction: LoadedRegion.settingsKey is the key minus its zoom axis, so a moved zoomFetchKey raises no scrim. That is the whole distance from the fold REJECTED_IDEAS.md "Folding content staleness into displayPhase" declines, which compared the whole key and put the overlay 250 ms into every zoom. | MultiRegionDisplayMixin |
dataCurrentboolean | This family's answer to the shared freshness question every display foundation must answer (dataCurrent): the held data corresponds to what is on screen right now. Four terms — spatial coverage of every visible block, loadedRegions.size to rule out the vacuously-true empty viewport, isCacheValid per block, and the display's own dataSuperseded. Regions stream in one at a time, so this (not "the first datum arrived") is what keeps a multi-region/whole-genome export complete.isCacheValid belongs here and not in the scrim. Coverage answers "is the data here", never "is it what a fetch now would bring back", so a zoom that moves fetchInputs leaves every held region covered and stale at once — and an export sampling svgReady across that window painted bins the worker computed for the previous zoom. displayPhase takes dataSuperseded but NOT this term: folding a moved fetchInputs into the phase raises the loading scrim into every zoom, which is the trade REJECTED_IDEAS.md "Folding content staleness into displayPhase" turned down and this does not take.The term cannot latch, and the reason is structural rather than a case list: a block reaches fetchNeeded unless planRegionFetch finds it ungated, covered AND cache-valid, and it reads that last term tracked. The && short-circuits ahead of it drop its observables only where the block is fetched anyway, so the key move that closes this gate is the same read, in the same dependency set, that wakes the refetch reopening it. | MultiRegionDisplayMixin |
| loadedAssembly | The assembly the data in hand came from, once it can answer about refNames — undefined before that.Off the first LOADED region rather than the view's displayed ones, which is the distinction that makes it belong here: a display holding fetched data is asking about the assembly THAT data is on, and the view's regions can already have moved on. The initialized gate is why this returns the assembly rather than its name. getCanonicalRefName2 and refNameToIndex answer WRONGLY rather than throwing before the aliases land — identity, and a miss — so a caller that skips the gate gets a plausible answer and no signal. Handing back undefined until it can answer is what makes the caller write its fallback. | MultiRegionDisplayMixin |
phaseViewportCurrentboolean | The loading scrim's staleness argument: what is drawn answers for what is on screen. Spatial coverage, dataSuperseded and staleSettingsDrawn; NOT isCacheValid, which is dataCurrent's and would scrim every zoom (REJECTED_IDEAS.md "Folding content staleness into displayPhase"). displayPhase reads it, and so does a stand-in phase (coarseTierDisplayPhase) — one predicate, so a term added here reaches both. | MultiRegionDisplayMixin |
svgReadyboolean | true once an off-screen (SVG) export can safely read this display's data. Policy single-sourced in computeSvgReady; this family supplies only the freshness half, which foundationSvgReady reads as dataCurrent or the vacuous currency of viewportEmpty. Off-screen renderers gate on it via awaitSvgReady(model) instead of inlining the condition. | MultiRegionDisplayMixin |
paintInertboolean | Fills RenderLifecycleMixin's paintInert hook — see there for why a failed fetch has to read as finished to the consumers outside the display, and foundationPaintInert for the second such state and why both fetch families answer it through one function. Overridable, as the hook is: a display with a third inert state of its own says so here. | MultiRegionDisplayMixin |
paintSupersededboolean | Fills RenderLifecycleMixin's hook with staleSettingsDrawn, so painted — and data-display-drawn through it — reads pending over a canvas painted under the previous settings until the refetch lands. clearAllRpcData used to reset canvasDrawn for the same effect; the hook says it without blanking anything. | MultiRegionDisplayMixin |
displayPhaseDisplayPhase | The display's mutually-exclusive visual state, mapped in foundationDisplayPhase — every foundation calls it and supplies only its staleness argument, so a term added to computeLoadingTerm reaches all three without being wired three times.This family's argument is phaseViewportCurrent: spatial coverage AND dataSuperseded (data a settled fetch-input change is drawing wrong right now — alignments zooming perBaseLetter from 16 bp/px to 1 stays inside the loaded region and reported ready over a wall drawn as a 1 px stripe every 8 px) AND staleSettingsDrawn.A thunk, so a suppressed or already-loading display doesn't subscribe to viewport churn. A subclass customizes this through fetchInert (FetchMixin), never by overriding the getter — see that hook. | MultiRegionDisplayMixin |
gateEnabledboolean | The opt-in. Overridden with a literal true by gated displays, and check-gated-adapter-budgets insists on a literal: this mixin returns early on it in an autorun and in commitFetchBytes. | RegionTooLargeMixin |
byteGateAdapterConfigRecord<string, unknown> | The adapter config the gate measures — the one at byteGateAdapterPath. Overridable for a display whose adapter config is synthesized rather than read off the track. | RegionTooLargeMixin |
configuredFetchSizeLimitnumber | undefined | The display's fetchSizeLimit slot, from regionTooLargeConfigSchemaFields. number | undefined, because getConf answers undefined for a slot a composing display's schema never declared and typing it number hid the whole failure — resolveByteLimit falls back closed, and says why. | RegionTooLargeMixin |
densityTooLargeboolean | The density axis's verdict, and the whole of that axis's opt-in: CanvasFeatureGateMixin overrides it beside the measurement that fills it, and a byte-only display leaves it false. | RegionTooLargeMixin |
byteGateAdapterPathstring[] | Where on the track config the measured adapter sits. A tiered display overrides this one hook (MAF: ['adapter', 'summaryAdapter'] while showSummary), and both the measurement and the budget follow it. | RegionTooLargeMixin |
adapterFetchSizeLimitnumber | undefined | The measured adapter's own fetchSizeLimit slot, read off the live track config rather than the adapterConfig snapshot, which omits slots at their default. | RegionTooLargeMixin |
configForceLoadboolean | The declarative forceLoad slot. | RegionTooLargeMixin |
gateViewportGateViewport | undefined | What a measurement taken now would be about: the span on screen, and a key for the stretch of genome it covers and the settings it would be taken under. Undefined until the view is measured, and the mixin's only read of the view. Captured before the fetch's round trip, never at commit, so the stamp names the settings the worker actually counted under. The settings term is rpcPropsCacheKey, the axis both families already invalidate data on. It belongs in the measurement because the worker's density probe counts ADMITTED features (densityGate's admit), so a filter admitting almost nothing is a different measurement of the same viewport — and while staleness was viewport-only, the main thread never went back to ask. The byte axis is an index read no rpcProps field can move; the rule is one rule rather than one per axis. | RegionTooLargeMixin |
byteGateAdapterKeystring | Which tier the estimate is about, as a comparable string. | RegionTooLargeMixin |
aboveForceLoadFloorboolean | Whether the span on screen is at or above AUTO_FORCE_LOAD_BP, the one comparison against that constant. False on an unmeasured view. | RegionTooLargeMixin |
gateExemptboolean | Nothing may gate on either axis: the forceLoad slot or the button. | RegionTooLargeMixin |
estimatedFetchBytesnumber | undefined | The stored estimate's bytes; undefined when nothing has been measured. | RegionTooLargeMixin |
gateMeasurementStaleboolean | Whether the last measurement still describes what a fetch issued now would ask: the viewport on screen, under the settings on screen. True before any measurement. The triple's third term, the adapter tier, is not here — a tier swap drops the measurement outright (ClearByteEstimateOnNavOrTierSwap) rather than marking it stale. | RegionTooLargeMixin |
gateByteLimitnumber | The byte budget: the adapter's limit, else the display's, doubled below AUTO_FORCE_LOAD_BP. Read only through resolvedByteLimit(). | RegionTooLargeMixin |
gateActiveboolean | Whether the gate may act right now, on any axis: opted in, not exempt, view measured. The view is read last, so an ungated display never touches it. | RegionTooLargeMixin |
densityGateActiveboolean | Whether the density axis may act: gateActive, and the span is above the floor — the one axis the floor applies to. Whether it has anything to say is densityTooLarge. | RegionTooLargeMixin |
tooLargeStatusRegionTooLargeStatus | The verdict and its banner text, from the stored estimate against resolvedByteLimit() and the density axis when it may act. | RegionTooLargeMixin |
regionTooLargeboolean | RegionTooLargeMixin | |
regionTooLargeReasonstring | Banner text for the axis that tripped; empty when not too large. | RegionTooLargeMixin |
zoomCanReleaseGateboolean | Whether "zoom in to see features" is honest advice. Density always releases on zoom; bytes only if the last zoom-in moved the estimate. | RegionTooLargeMixin |
gateSkipsMeasuredViewportboolean | The skip both fetch skeletons apply: the banner is up and its measurement already describes the viewport on screen. | RegionTooLargeMixin |
paintedboolean | The first-paint answer every consumer outside the display should read, canvasDrawn being only the raw flag: a display that is deliberately not painting a canvas has finished, and saying otherwise is a lie that never resolves.The two rendersCanvas: false states each had three of their four consumers wired by hand — the loading scrim (rendersCanvas / fetchInert) and the SVG export (fetchInert) — while the fourth, data-display-drawn, went on publishing "false" forever off the raw flag. That attribute is what PENDING_DISPLAYS (@jbrowse/browser-test-utils) selects on, so a zoomed-out reference sequence track made every waitForDisplaysDone on the page burn its full timeout — silently, since that wait swallows its own. Same shape as fetchInert on the comparative side: the reader you forget is the one outside the display, so the display has to publish one name for it.paintInert is the third term and the same argument once more, for the state where a display would paint a canvas and never gets to — a fetch that failed before first paint. paintSuperseded is the fourth, and the one that subtracts: a canvas painted from data a settings change has made wrong is drawn and not finished. See both hooks. | RenderLifecycleMixin |
isLoadingboolean | true while a fetch is active | FetchMixin |
isLoadingOrCanceledboolean | isLoading widened to cover a user-canceled load. This, not isLoading, is what a displayPhase loading term wants. cancelFetchByUser clears the stop token synchronously, so isLoading goes false the instant the user clicks Cancel — and the loading overlay that unmounts on it is carrying the Retry button, which is the only way back: the state is deliberately durable, so no autorun restarts the fetch on its own. A bare isLoading therefore reads as ready over a display that is stopped, empty and offering nothing.Arc read isLoading directly and had exactly that hole. It is a getter here so no family has to remember the second term. | FetchMixin |
fetchInertboolean | Overridable hook (default false): the states where this display deliberately never fetches, so it holds no data and none is coming. Sequence sets it past base resolution ("Zoom in to see sequence"); LD sets it with the triangle toggled off. One hook, three readers, and that is the whole point — a display that grows such a state has one thing to say rather than three, and the reader it would have forgotten is always the one outside itself: - the loading scrim ( computeLoadingTerm), which otherwise parks over the placeholder, permanently once a cancel has been clicked; - the SVG export (computeSvgReady's extraTerminal), whose awaitSvgReady is an unbounded when, so one such display hangs the whole view's export; - the retry contract check (makeRetryContractCheck), which would otherwise report a dead Retry on a display correctly declining to load anything.It was three hooks — loadingSuppressed, svgReadyExtraTerminal on each of the two foundations, and fetchInert on the comparative family, which had already collapsed them. Both LGV displays that override it returned one expression for all three, and one of the three was hard-coded false on the global family for a while, which is how LD came to be able to express only half its own state. One declaration for all three fetch families since the comparative one composed this mixin (ADR-105), so the retry check reads one field everywhere. ADR-082.A hook rather than a displayPhase override, because overriding the getter means restating the whole loading condition — which is how sequence came to hold a verbatim copy of the other terms, one git blame away from silently missing the next one added.It lives here because this is the one mixin all three display foundations compose. Same argument, one level down, that put rendersCanvas on RenderLifecycleMixin beside canvasDrawn. | FetchMixin |
awaitingPrerequisiteboolean | Overridable hook (default false), read only by the retry contract check (makeRetryContractCheck): "this run declined because a prerequisite fetch in another autorun has not landed, and its arrival wakes this one again". It defers the retry verdict to that later run rather than waiving it, so a display cannot spend its retry on a decline it called preliminary.Two displays say it, one per fetch foundation, which is why it lives beside fetchInert rather than on either: HiC's contacts fetch declines until CoreGetInfo lands, and MultiSampleVariantBaseModel's fetchNeeded declines until sourcesBase does. Both have a reload() that wakes the prerequisite's autorun as well as their own.It has to be strictly narrower than the gate it explains. One that restates the gate's negation makes every decline a deferred one, so no run is ever judged and the display has silently opted out — an exemption by another name. HiC is in that shape deliberately, because its gate and its prerequisite are one condition; what covers its retry instead is LinearHicDisplay/infoFetchFailure.test.ts.Not for a display deliberately not fetching at all — that is fetchInert above, which the loading scrim and the export read too. | FetchMixin |
awaitingDependentDataboolean | Overridable hook (default false), read by computeLoadingTerm: a load this display depends on beyond its primary fetch has not landed for the first time, so the frame the primary fetch calls current is still missing something. Multi-way synteny says it until its lane genes and lane links first arrive, so an export or a capture never lands between the ortholog fetch and the gene models that fill the lanes.A hook rather than a displayPhase override, for the reason fetchInert is one: that display carried the override, restating the foundation's two arguments verbatim to append one term, which is the shape that silently misses the next term added.Not dataSuperseded, which holds the export through every later refetch too: a display saying this wants the scrim on the first landing only, since later lane fetches redraw over lanes already on screen. | FetchMixin |
rpcPropsCacheKeystring | The RPC cache key both fetch foundations invalidate on: this display's rpcProps() payload serialized to a string. serializeRpcProps owns the why, including the silently-dead-axis corollary.Here, beside the two hooks above, for the same reason they are: it describes the display, and every foundation composes this mixin. The per-region family watches it from SettingsInvalidate and the global one from its fetch autorun's trigger list — one getter and one name, so the two cannot come to invalidate on different axes. The global side built its own local computed over the same function until 2026-08, which was the same value under a second spelling. | FetchMixin |
adapterConfigKeystring | The adapter axis of the same key, watched by the same two readers as rpcPropsCacheKey: SettingsInvalidate per-region and the global family's currentFetchKey. A track re-pointed in the config editor is a different fetch, and until 2026-09 only the comparative family said so. | FetchMixin |
visibleFeatureDensityPerPxnumber | Density at the debounced coarseBpPerPx, so the verdict shares the layout cadence. | CanvasFeatureGateMixin |
maxFeatureDensitynumber | undefined | Undefined when the axis may not act. | CanvasFeatureGateMixin |
coarseTierStandsInboolean | DensityBandMixin | |
densityBandLayerDensityBandLayer | DensityBandMixin | |
densityHoverDensityHover | undefined | DensityBandMixin | |
densityPeakReadoutstring | The band's line of text with no cursor over it, which is what the SVG export writes. | DensityBandMixin |
densityReadoutstring | Blank until the first read lands, so the scrim is not captioned "no density data" for a read still in flight. | DensityBandMixin |
coarseAdapterSlotstring | DensityTierMixin | |
densityTierMode"auto" | "density" | "features" | The densityTier slot's value. | DensityTierMixin |
densityTierThresholdBpPerPxnumber | DensityTierMixin | |
coarseTierModeCoarseTierMode | DensityTierMixin | |
coarseTierPastThresholdboolean | auto also swaps from the densityTierBpPerPx slot outward, where a track asks for the band before the region is too large to fetch. | DensityTierMixin |
coarseReadKeystring | The bins are read at the view's bp/px, so a real zoom re-reads at the level the sidecar keeps for it and a small one reuses what is held. | DensityTierMixin |
coarseTierGatedboolean | Overridable hook (default false): the coarse read is a feature download the byte gate has to measure. The gate then measures the coarse adapter while the tier is up, its refusal is the banner, the detail fetch stands down outright since the coarse read is the measurement pass, and the swap is by threshold alone — the verdict is about whichever tier is up, so it cannot also pick the tier. A read bounded by construction (bins per screen pixel) leaves this off. | CoarseTierMixin |
coarseSourceConfigunknown | The coarse source's config, read off the live track config so a re-pointed adapter follows. | CoarseTierMixin |
hasCoarseSourceboolean | CoarseTierMixin | |
coarseTierActiveboolean | Whether the coarse tier stands in for the detail right now. | CoarseTierMixin |
gateMeasuresCoarseboolean | The byte gate is measuring the coarse read rather than the detail fetch, so its verdict is about the tier on screen. | CoarseTierMixin |
gateRefusesDetailboolean | The gate's refusal is about the detail fetch, so that fetch owes the re-measure the gate releases through. | CoarseTierMixin |
coarseTierIssueKeystring | The whole key a read is held under: the coarse adapter and the display's own term. | CoarseTierMixin |
drawsWhenTooLargeboolean | renderDisplaySvg's hook: the export paints the tier in place of the too-large note, the same swap the chrome makes on screen — unless the note is about the coarse read itself. | CoarseTierMixin |
Methods
| Member | Description | Defined by |
|---|---|---|
() => MenuItem[] | The shared feature menu plus, on a breakend record, the row that opens the split view for it. Super-captured rather than replaced, so every generic row (details, zoom to, highlight, show/hide, copy) stays where a reader already learned it. | LinearVariantDisplay |
() => MenuItem[] | LinearVariantDisplay | |
configuredFilters() => string[] | What the jexlFilters config slot alone declares, jexl:-prefixed; in its own block so featureFilterCount, which subclasses super-capture and call unbound, reaches it through self. | LinearCanvasBaseDisplay |
activeFilters() => string[] | The filters actually applied, as jexl:-prefixed expressions — see activeJexlFilters, which is the shared two-tier resolution. | LinearCanvasBaseDisplay |
rpcProps() => {…} | LinearCanvasBaseDisplay | |
gpuProps() => { colorTable: Uint32Array<ArrayBuffer>; } | What the main-thread encode needs beyond a region's own data: the packed color for every theme class the worker emitted, off session.palette so a theme toggle re-encodes what is loaded instead of refetching it. | LinearCanvasBaseDisplay |
| fitLayoutAt | One fit-escalation candidate: the stack packed with the given label reservation, via that config's own memo instance so each keeps stable references across renders. | LinearCanvasBaseDisplay |
decimatedLayoutInputs(labelRoomFactor: number) => LayoutInputs | Layout inputs for the decimated rung at one whitespace factor. | LinearCanvasBaseDisplay |
solveLabelRoomFactor(trackHeight: number) => number | undefined | The whitespace factor the decimated rung commits at: the smallest one whose packed stack fits trackHeight (smallest = most names kept), or undefined when even the most aggressive decimation overflows. | LinearCanvasBaseDisplay |
morphOffsetFor(featureId: string) => number | LinearCanvasBaseDisplay | |
| searchFeatureByID | LinearCanvasBaseDisplay | |
| renderSvg | LinearCanvasBaseDisplay | |
featureNarrowings() => Reversibles | Everything this display is doing to narrow what the user sees, each declared once, so the "Filter by... (n)" count, its undo rows and "Clear all filters" cannot disagree; a method, not a getter, because a getter cannot be super-captured. | LinearCanvasBaseDisplay |
featureMarks() => Reversibles | Reversible state that MARKS features rather than hiding them — the highlight boxes and the pins holding features at the top of the layout. | LinearCanvasBaseDisplay |
featureFilterCount() => number | How many independent things are narrowing what the display shows, derived so it cannot drift from the list it counts. | LinearCanvasBaseDisplay |
() => MenuItem[] | LinearCanvasBaseDisplay | |
() => MenuItem[] | LinearCanvasBaseDisplay | |
() => MenuItem[] | Flattened "Show..." submenu: all checkbox toggles first, then the radio groups (each under its own subHeader). | LinearCanvasBaseDisplay |
() => MenuItem[] | Color-related track menu entries: a single "Color by..." entry whose "Solid color..." choice opens the solid+UTR color picker. | LinearCanvasBaseDisplay |
() => MenuItem[] | One "Feature height" menu with two independent radio groups: the size presets and, under a "Track sizing" subheader, how the track responds when there are more features than fit. | LinearCanvasBaseDisplay |
() => MenuItem[] | LinearCanvasBaseDisplay | |
| renderingProps | props passed to the renderer's React "Rendering" component. these are client-side only and never sent to the worker. includes displayModel and callbacks | BaseDisplay |
regionHasData(displayedRegionIndex: number) => boolean | Overridable hook, and the converted form of zoomFetchKey above: the zoom-derived worker arguments as an object, which the display spreads into its own RPC call and the foundation stamps beside every region the call loads. A display that fills this leaves zoomFetchKey alone; the foundation prefers this when it exists.One declaration instead of two is the whole of it. The key and the argument are the same fact, and writing them apart is what lets them disagree — a zoomFetchKey that reads no observable is memoized for the display's life while the call goes on sending a live value, and a key naming a threshold while the call sends the mode behind it says stale on a crossing the worker never sees.Looked up dynamically rather than declared, so a display keeps its narrow return type through MST's .views() chain — the same reason rpcProps is not declared here. Overridable hook: whether the display can actually draw what this region is marked loaded over.The default answers off the store — an entry a fetch committed carries what it stored — so "marked loaded with nothing behind it" is a state only a hand-written setLoadedRegion reaches. It used to be true, and the base canvas display overrode it with rpcDataMap.has(idx) to get this answer back.What survives an override is the question the store cannot answer: which of several held payloads answers. MAF caches a summary tier and a detail tier side by side under one displayedRegionIndex, so crossing the threshold inside an already-loaded region changes which map has to answer — something neither the coverage bounds nor one payload slot can see. A key would refetch the summary on every zoom back out, since both tiers are still held. The multi-row display's override survives for its second half, the auto-partition reconciliation (regionHasPinnedData).What the old fail-open default was protecting is now explicit. A byte-gate refusal never commits at all, so it is unreachable either way. The case that mattered is sequence's legitimately-empty region, which stamped without storing and which a store-derived default would have refetched forever — and a commit is a payload now, the empty record, so it stays terminal. A view, not an action, for the reason zoomFetchKey is a getter. | MultiRegionDisplayMixin |
isCacheValid(displayedRegionIndex: number) => boolean | Whether the data held for a region still answers the current view. Not a hook a display fills: a display states its rule as zoomFetchArgs (the zoom-derived arguments a fetch now would send) and regionHasData (did the last one store anything), and this compares the whole input set against the one the region was fetched under. | MultiRegionDisplayMixin |
resolvedByteLimit() => number | undefined | The budget the worker enforces and the banner compares against — the one spelling of that pair. Undefined when the gate may not act. | RegionTooLargeMixin |
gateFetchState() => GateFetchState | The gate as it stands for a fetch about to be issued. Calling it is the capture, which is why it is a method. | RegionTooLargeMixin |
observedMaxDensity(bpPerPx: number) => number | CanvasFeatureGateMixin |
Actions
| Member | Description | Defined by |
|---|---|---|
openFilterDialog() => void | LinearVariantDisplay | |
beginYMorph(fromTops: Map<string, number>, fromMaxY: number) => void | LinearCanvasBaseDisplay | |
setMorphProgress(t: number) => void | LinearCanvasBaseDisplay | |
endYMorph() => void | LinearCanvasBaseDisplay | |
| setRpcData | Stage a region as fetched — the store's raw write with this display's payload shape, so a test stands up a loaded display in one call. | LinearCanvasBaseDisplay |
pruneDensityStatsToVisible(visibleDisplayedRegionIndices: Set<number>) => void | The gate's own measurements, which are keyed by region and are not fetch payloads, so the store's bound does not reach them. | LinearCanvasBaseDisplay |
startRenderingBackend(backend: CanvasFeatureRenderingBackend) => void | LinearCanvasBaseDisplay | |
togglePinnedFeature(featureId: string) => void | LinearCanvasBaseDisplay | |
clearPinnedFeatures() => void | LinearCanvasBaseDisplay | |
toggleExpandedGene(featureId: string) => void | Open or re-collapse one gene's isoforms, from the badge on its own label. | LinearCanvasBaseDisplay |
clearExpandedGenes() => void | Re-collapse every gene opened from a badge. | LinearCanvasBaseDisplay |
toggleSoloFeature(featureId: string) => void | LinearCanvasBaseDisplay | |
applySolo() => void | LinearCanvasBaseDisplay | |
soloFeature(featureId: string) => void | LinearCanvasBaseDisplay | |
clearSolo() => void | LinearCanvasBaseDisplay | |
hideFeature(featureId: string) => void | LinearCanvasBaseDisplay | |
() => void | LinearCanvasBaseDisplay | |
| setHover | LinearCanvasBaseDisplay | |
clearHover() => void | LinearCanvasBaseDisplay | |
setFeatureHighlights(highlights: FeatureHighlight[]) => void | LinearCanvasBaseDisplay | |
addFeatureHighlightForItem(target: HighlightTarget, refName: string) => void | LinearCanvasBaseDisplay | |
removeFeatureHighlightsForId(featureId: string) => void | LinearCanvasBaseDisplay | |
clearFeatureHighlights() => void | LinearCanvasBaseDisplay | |
(info: FeatureContextMenuInfo) => void | Drops the hover first, so its tooltip does not sit under the menu; the highlight box stays on the target through hoverBoxFeature. | LinearCanvasBaseDisplay |
| openFeatureDetails | Open the feature-details widget on what fetch resolves to, with the adapter's header metadata beside it; a lookup that resolves to nothing is reported as a miss. | LinearCanvasBaseDisplay |
selectFeature(feature: Feature) => void | Open the feature-details widget on a feature already in hand. | LinearCanvasBaseDisplay |
clearSelection() => void | LinearCanvasBaseDisplay | |
| setShowLabels | LinearCanvasBaseDisplay | |
setJexlFilters(filters?: string[] | undefined) => void | Sets the runtime filter override (already-jexl:-prefixed expressions). | LinearCanvasBaseDisplay |
setShowOutline(value: boolean) => void | LinearCanvasBaseDisplay | |
setFeatureColor(color?: string | undefined) => void | LinearCanvasBaseDisplay | |
setUtrColor(color?: string | undefined) => void | LinearCanvasBaseDisplay | |
setSequenceHoverPosition(pos: SequenceHoverPosition | undefined) => void | LinearCanvasBaseDisplay | |
| setDisplayMode | LinearCanvasBaseDisplay | |
openSetColorDialog(showUtrColor?: any) => void | LinearCanvasBaseDisplay | |
openColorByAttributeDialog() => void | LinearCanvasBaseDisplay | |
| fetchFullFeature | LinearCanvasBaseDisplay | |
clearAllFeatureFilters() => void | Reverse every narrowing. | LinearCanvasBaseDisplay |
| selectFeatureById | LinearCanvasBaseDisplay | |
reload() => void | Clears the loaded regions and fetches straight away, rather than waiting out FetchVisibleRegions' 600ms debounce as the rest of the family does — Retry and Force load are both clicks, and this is the display the user is most often clicking on. | LinearCanvasBaseDisplay |
fetchNeeded(needed: IndexedRegion[]) => void | LinearCanvasBaseDisplay | |
clearHoveredFeature() => void | Fills BaseDisplay's hover-clear hook, which the fetch foundation's reaction calls on every viewport change. | LinearCanvasBaseDisplay |
setStatusMessage(status?: RpcStatus | undefined) => void | BaseDisplay | |
setError(error?: unknown) => void | BaseDisplay | |
| applyDisplaySettings | Apply a bag of display settings to the LIVE display, and report what landed. Each key runs through the display config schema's preProcessSnapshot (shorthand expansions, legacy-key migrations — the same lowering a session spec's inline track keys get in showTrackGeneric), then writes the matching config slot. Keys that are not slots come back in unapplied rather than vanishing: the settings vocabulary's historical failure mode is the silently dropped key.allowSetters additionally routes a non-slot key to a conventionally named single-argument set<Key> action. Opt-in, never the default: the declarative surfaces (session specs, share links, embeds) feed this whole bags of untyped JSON, and a blanket fallback would let them reach internal setters (setError, setScrollTop, ...) and call multi-argument setters with one argument. A caller that wants a specific action can also simply call it.A key whose write THREW is reported separately, in failed — it is the only one of the three that means the caller got something wrong, and the only one worth a notification. unapplied is not: at the showTrackGeneric call site it also collects keys that surface consumed itself (type) and MST display props the display snapshot already applied (resolution), so treating it as "dropped" would report a correct call as broken.Per-key errors do not abort the rest of the bag — a caller mid- showTrack has already pushed the track, and one rejected value must not strand a half-configured track. | BaseDisplay |
setScrollTop(scrollTop: number) => void | Clamped into [0, scrollableHeight], so no caller has to remember the bound. Unbounded for a display that leaves scrollableHeight at its Infinity default. | TrackHeightMixin |
setHeight(displayHeight: number) => number | TrackHeightMixin | |
resizeHeight(distance: number) => number | TrackHeightMixin | |
expandToContentHeight() => number | Grow the track by exactly the content it is currently hiding, so a display scrolled over a taller stack ends up showing all of it. The track's resize handle runs this on a double click.scrollableHeight is the whole measurement — it is already every scrolling display's answer to "how much is off the bottom", so no display has to supply a second one. A display that doesn't scroll internally leaves it at Infinity and gets a no-op, as does one already showing everything (0).Routed through resizeHeight rather than setHeight so grow mode's override still gets to leave grow first; going straight to the slot would let the reactive height re-derive grownHeight and the double click would appear to do nothing. | TrackHeightMixin |
setHeightMode(mode: "fit" | "fixed" | "grow") => void | Set the track-height strategy by writing the unified heightMode slot; the modes are mutually exclusive by construction. Leaving grow bakes the grown height into the height slot in the same action, so the switch is atomic: installGrowExitBake also covers this exit, but it is a reaction, and an observer scheduled ahead of it would catch the new mode against the stale slot — a track grown to 800px fitting one frame into the 100px the slot still held. The reaction sees the slot move with the mode and skips, the same guard that protects a drag-resize exit. Entering a non-fixed mode drops a leftover scroll offset that the reconfigured height contradicts — neither fit nor grow generally scrolls, and a sticky canvas left at an out-of-range offset paints clipped or blank with no DOM scroll event to resync it. Displays with more transient state to reset super-capture this. | HeightModeMixin |
setShowLegend(arg: boolean) => void | LegendMixin | |
| setLoadedRegion | The raw write behind ctx.commitRegion, and not what a fetch should call: a display naming its own span is the bug this family spent a release on, and going through the context is what makes that inexpressible — see RegionFetchContext. Direct callers are tests staging an already-loaded display.The payload is named on every call, undefined included: this write replaces the whole record, so a re-stamp that left it off dropped the data a test had staged one line earlier, and the failure surfaced as a reader throwing three layers away. A test stages a claim with nothing behind it by saying so.An action so callers after an async boundary stay in MST strict mode. Stamps the region with the fetch key its data came back under. fetchRegions passes the key it captured before issuing the RPC; the default reads it now, which is right for a caller holding the region already and wrong for anything resuming after an await, where the viewport may have moved under the fetch. | MultiRegionDisplayMixin |
evictRegionStore(keep: ReadonlySet<number>) => void | The store's bound. Drops the entries a fetch can no longer be about: an index outside the view's buffered viewport, once the store is over MAX_STORED_REGIONS, oldest first.One rule for every display, where canvas hand-rolled pruneRpcDataMapToVisible (prune to the buffer on every fetch) and every other display had no bound at all beyond displayedRegions.length — which is the contig count, so a fragmented assembly had none worth the name. The cap is what lets a pan back onto a recently-visited region draw immediately, which the prune-to-buffer rule gave up. | MultiRegionDisplayMixin |
dropLoadedRegion(displayedRegionIndex: number) => void | Forget one region — for a display pruning what has scrolled off screen. | MultiRegionDisplayMixin |
clearDisplaySpecificData() => void | Overridable hook (no-op base): drop what this display holds beside the store — a second store of its own, a verdict about the viewport that was just dropped. Called by clearAllRpcData, which runs on a displayed-regions change, on a viewport move past an error or a cancel, and on reload(). | MultiRegionDisplayMixin |
clearSettingsBakedData() => void | Overridable hook (no-op base): drop what this display holds that is wrong under a changed setting rather than merely stale — a payload whose shape the setting decides. Called by invalidateSettings, where clearDisplaySpecificData is deliberately not: bins, reads and features fetched under the previous setting draw honestly under the scrim staleSettingsDrawn raises until the refetch lands, the way canvas has kept its features since ADR-006 and every display does since 2026-09.The variant matrix overrides it, for a structural reason: it holds one payload for every visible region and the row set is a setting, so there is no per-region replacement to wait for. | MultiRegionDisplayMixin |
clearAllRpcData() => void | full reset: cancels fetch, clears error, loadedRegions, display-specific data, and the canvas-drawn flag. The too-large gate is derived (a pure function of the cached estimate × viewport), so it needs no explicit clear here — the fetch autorun re-measures at the new viewport and the verdict follows. | MultiRegionDisplayMixin |
invalidateSettings() => void | SettingsInvalidate's reset: the half of clearAllRpcData a settings change still needs now that the settings and adapter axes are in fetchInputs. The in-flight fetch is superseded now rather than when its payload lands stamped stale, a blocking error or cancel is cleared so the plan is not blocked, and the display drops its settings-baked data. loadedRegions and the canvas-drawn flag stay: every held region already reads !isCacheValid, so the plan refetches it, and until that lands the data stays on screen under the scrim staleSettingsDrawn raises. | MultiRegionDisplayMixin |
| fetchRegions | Run a per-region fetch. The work callback calls ctx.commitRegion as it stores each region's payload, which is what marks it loaded — see RegionFetchContext for why this function no longer does that itself. Its only callers are the three helpers in fetchEachRegion.ts, which make that call for every display in the family; a display reaching past them owns both ctx.isStale() guards and the commit by hand, and none does.The fetch key is captured here, at issue, and carried into every commit — never re-read after the await. ctx.isStale() trips on a newer fetch or a cancel, not on a viewport that moved under a fetch that is still current, so a key read at commit time would stamp this data with a zoom it was not fetched at. | MultiRegionDisplayMixin |
afterAttach() => void | installs the fetch-lifecycle autoruns (DisplayedRegionsChange, FetchVisibleRegions, SettingsInvalidate, ClearBlockingStateOnViewportChange) | MultiRegionDisplayMixin |
clearByteEstimate() => void | Drops the estimate and the viewport stamp. forceLoadTrack survives: it is a track-wide approval. | RegionTooLargeMixin |
setForceLoadTrack(flag: boolean) => void | RegionTooLargeMixin | |
| commitFetchBytes | The byte axis of a finished fetch, called by the fetch runners with the gateFetchState() they captured at issue. Commits the per-region max; an empty batch, or an ungated display, commits nothing. | RegionTooLargeMixin |
forceLoad() => void | The banner's button: exempt the track on both axes and refetch. | RegionTooLargeMixin |
markCanvasDrawn() => void | RenderLifecycleMixin | |
resetCanvasDrawn() => void | RenderLifecycleMixin | |
stopRenderingBackend() => void | RenderLifecycleMixin | |
renderNow() => void | RenderLifecycleMixin | |
setRenderError(error: unknown) => void | set/clear the render-backend error. Called by useRenderingBackend: with the error when the canvas factory rejects (or context-loss re-init fails), and with undefined on successful (re)init and on retry. | RenderLifecycleMixin |
| attachRenderingBackend | attach a GPU/Canvas2D backend and install the upload + render autorun pair. Idempotent: re-calling swaps the backend and does not run setup again, so the callbacks and everything they close over are the first call's. | RenderLifecycleMixin |
stopActiveFetch() => void | Abort the in-flight fetch (if any) and retire its slot. The shared preamble of both cancel paths; the difference between them is only what they do to fetchCanceled / fetchGeneration afterward. | FetchMixin |
openStatusStream(isCurrent: () => boolean) => StatusStream | Open one operation's slot on the display's status field: an RPC statusCallback throttled through the display-wide window and guarded so a callback that fires after the node is torn down (RPCs resolve their status stream asynchronously) is a safe no-op, plus the clear that retires the slot when the operation ends.Every operation on the display opens one, and the two come back together because an operation that never retires goes on voting for a phase that is over. The viewport fetch ( runFetch), the clustering run and a lent createStopTokenRotation are three of them on one field; before ADR-081 each blanked the field outright and the last one to finish decided what the other two were still saying.isCurrent is required and has no "node is alive" default, because alive is not the interesting question: a superseded fetch is on a live node, and its late status repainting the overlay of the fetch that replaced it is the failure this guards. runFetch passes !isStale(), which is what every display gets for free through ctx.statusCallback; a caller outside a fetch (the clustering autorun) passes its own run's flag. Defaulting to isAlive made the loose answer the easy one and five displays took it.runFetch's own slot is opened by the rotation; this is for an operation outside any fetch, the tree sidebar's clustering run. | FetchMixin |
cancelFetch() => void | cancel any in-flight fetch and bump fetchGeneration (always bumps, so callers can retrigger fetch autoruns even when nothing was in flight). This is the internal reset clearAllRpcData runs — it clears any user-cancel flag so the retrigger actually re-fetches. | FetchMixin |
cancelFetchByUser() => void | User-initiated cancel from the loading overlay. Stops the in-flight fetch and lands in a durable fetchCanceled state. Unlike cancelFetch, it does NOT bump fetchGeneration — so the fetch autoruns don't immediately restart the load. The user retries via reload (the overlay's retry button), or it clears on the next viewport change. | FetchMixin |
beforeDestroy() => void | Release an in-flight fetch's stop token on teardown. Without this, a display destroyed mid-fetch (track/view closed while loading) never signals the worker to abort the now-useless work, and its in-flight HTTP reads keep downloading. MST auto-chains lifecycle hooks, so a composing display can still define its own beforeDestroy. | FetchMixin |
beginFetch(stopToken: StopToken) => void | The onBegin half of a fetch's bookkeeping: publish the in-flight token (isLoading) and clear the durable user-cancel — a load starting is the single clear point that covers every retrigger path (reload, viewport change, settings invalidate). An action of its own for the same reason endFetch is: installFetch's lifecycle callbacks run outside any MST flow this mixin owns. | FetchMixin |
endFetch(current: boolean) => void | The finally half of runFetch's bookkeeping, an action of its own because runFetchOnce's finally resumes on a microtask the flow does not own — a direct volatile write there is outside the action context, which is the one thing hoisting the sequence into a shared function costs. The stale branch is a superseded fetch, which must not clear the loading flag the run that replaced it just set. The stop token itself is released by the rotation's own end(), one layer down. | FetchMixin |
runFetch(work: (ctx: FetchContext) => Promise<void>) => Promise<void> | Run a cancel-safe fetch (cancels any prior). The work callback gets a FetchContext with a stopToken to forward to the RPC and an isStale() check to short-circuit commits once the user has moved on. The MST-flow wrapper over the shared runFetchOnce sequence, and only the wrapper: the begin/clear/run/commit/error/end order, and the rules that keep a superseded run from writing back, are the same function every other fetch in the tree runs. What this adds is the observable bookkeeping a display needs — isLoading through activeStopToken, fetchGeneration, the user-cancel clear — and the flow itself, which is an action, so work's synchronous prefix runs untracked wherever a fetch autorun calls this. | FetchMixin |
| setDensityStats | CanvasFeatureGateMixin | |
clearGateMeasurements() => void | CanvasFeatureGateMixin | |
| commitGateMeasurements | Judged by the tier captured at issue. | CanvasFeatureGateMixin |
setDensityHoverPx(px?: number | undefined) => void | Kept only while the band is up, so a pointer over features writes nothing here. | DensityBandMixin |
| fetchCoarseTier | DensityTierMixin | |
setCoarseTier(entries: CoarseTierEntry<P>[], read: CoarseTierRead) => void | CoarseTierMixin | |
clearCoarseTier() => void | CoarseTierMixin | |
setCoarseTierLoading(loading: boolean) => void | CoarseTierMixin | |
() => void | ContextMenuMixin |