Read-side accessors for application code that needs the current canvas projection.
Prefer the narrow query that answers the question directly. Use state/1
when passing the canonical state into lower-level helpers such as graph
bounds, graph navigation, drawing queries, or custom projections.
Summary
Functions
Returns the current actor identity map.
Returns the current actor's %Clipboard{} or nil when empty.
Returns the recent browser command envelopes received by the runtime, reduced to display-oriented field deltas.
Returns the content availability status for one item, or nil when none is recorded.
Returns item content availability statuses keyed by item id.
Returns the current actor's history projection for layout mutations.
Returns one item by id, or nil if it does not exist on the canvas.
Returns all canvas items as a list.
Returns metadata for the most recent runtime command handled by this socket.
Returns the participants currently joined to the canvas.
Returns the current actor's %Selection{}.
Returns the %Selection{} for the given client_id.
Returns the canonical canvas State struct.
Returns the current actor's viewport, or nil if not yet reported.
Returns viewport anchors keyed by anchor name.
Returns the current actor's viewport profile name.
Returns the active viewport sequence as anchor names.
Returns the canvas z-order from front to back.
Types
@type socket() :: Phoenix.LiveView.Socket.t()
Functions
@spec actor(socket()) :: LivePanels.Canvas.actor()
Returns the current actor identity map.
@spec clipboard(socket()) :: LivePanels.Canvas.Clipboard.t() | nil
Returns the current actor's %Clipboard{} or nil when empty.
Returns the recent browser command envelopes received by the runtime, reduced to display-oriented field deltas.
Returns the content availability status for one item, or nil when none is recorded.
Returns item content availability statuses keyed by item id.
@spec history(socket()) :: LivePanels.Canvas.History.t()
Returns the current actor's history projection for layout mutations.
@spec item(socket(), String.t()) :: LivePanels.Item.t() | nil
Returns one item by id, or nil if it does not exist on the canvas.
@spec items(socket()) :: [LivePanels.Item.t()]
Returns all canvas items as a list.
Returns metadata for the most recent runtime command handled by this socket.
Rejected commands include :reason and :message entries even when the
canvas model itself was not changed.
Returns the participants currently joined to the canvas.
@spec selection(socket()) :: LivePanels.Canvas.Selection.t()
Returns the current actor's %Selection{}.
@spec selection_for(socket(), String.t()) :: LivePanels.Canvas.Selection.t()
Returns the %Selection{} for the given client_id.
@spec state(socket()) :: LivePanels.Canvas.State.t()
Returns the canonical canvas State struct.
Returns the current actor's viewport, or nil if not yet reported.
Returns viewport anchors keyed by anchor name.
Returns the current actor's viewport profile name.
Returns the active viewport sequence as anchor names.
Returns the canvas z-order from front to back.