Split global context off from ViewerContext
and make DataUi
(and friends) "context-agnostic"
#9029
Labels
ViewerContext
and make DataUi
(and friends) "context-agnostic"
#9029
Background
The current
ViewerContext
is way too specific in terms of current recording/blueprint and visualisation thereof to be meaningfully used in for the upcoming "Redap browser". However, it does contain stuff of general usefulness that the Redap browser requires, such as the registry of component UI.Proposal
Let's split it!
We currently already have a hierarchy of increasingly specific context structure:
We propose to extend this hierarchy:
Some subsystems, such as
re_data_ui
andre_component_ui
, should be available globally (because we display stuff everywhere), but benefit from more specific context when available. For example aClassId
component might be able to display the corresponding color if, and only if, a datastore and a latest-at query are known, enabling anAnnotationContext
to be queried. TheClassId
should also be correctly displayed (albeit without color) if there is no such knowledge.To address that, we further propose to update these api to accept an enum of any of these contexts:
Some code to get started
Related
Option<RowId>
argument inComponentUiRegistry
's methods #7617The text was updated successfully, but these errors were encountered: