OptionalclassForwarded to the element's class attribute.
OptionalclientThe viewer's data source, forwarded to the element's load() method
whenever it changes.
Table (or Promise<Table>) displays that table directly.Client (e.g. from perspective.worker() or a WebSocket
connection to a remote server) connects the viewer to every table
hosted by that client; the table each panel displays is chosen by
PerspectiveViewerProps.config or interactively by the user.undefined calls eject(), returning the viewer to an unloaded
state without unmounting it.The component does not take ownership of the Table — delete it
yourself when it is no longer needed, e.g.
table.delete({ lazy: true }).
OptionalconfigDeclarative viewer state — group-bys, splits, filters, sorts,
expressions, plugin and plugin config — applied with the element's
restore() method whenever it (or
PerspectiveViewerProps.client) changes. A config with a
panels property is treated as a multi-panel workspace layout and
applied with restoreWorkspace() instead.
Configs are compared structurally, so passing a fresh-but-equal object literal on each render does not re-apply. Combine with PerspectiveViewerProps.onConfigUpdate to use the viewer as a controlled component.
OptionalhiddenForwarded to the element's hidden attribute.
OptionalidForwarded to the element's id attribute.
OptionalonCalled when the user clicks a datapoint (the element's
"perspective-click" Custom Event), with the clicked row's data and a
filter config which would select it.
OptionalonCalled with the viewer's complete configuration whenever the user
reconfigures it through its UI (the element's
"perspective-config-update" Custom Event). Use this to persist the
user's view or reflect it back through
PerspectiveViewerProps.config.
OptionalonCalled when the user selects or deselects a datapoint or row (the
element's "perspective-select" Custom Event).
OptionalslotForwarded to the element's slot attribute.
OptionalstyleForwarded to the element's inline style.
OptionaltabForwarded to the element's tabindex attribute.
OptionaltitleForwarded to the element's title attribute.
Props for the PerspectiveViewer component.