PhoenixDnd.Scene (phoenix_dnd v0.1.0)

Copy Markdown View Source

The complete, server-authoritative snapshot rendered by an editor.

Scene revisions are monotonic within one editor component instance. Durable graph state belongs here; active pointer gestures and measured geometry do not.

Summary

Types

t()

@type t() :: %PhoenixDnd.Scene{
  edges: [PhoenixDnd.Edge.t()],
  meta: term(),
  nodes: [PhoenixDnd.Node.t()],
  revision: non_neg_integer(),
  selection: PhoenixDnd.Selection.t(),
  viewport: PhoenixDnd.Viewport.t()
}

Functions

bump(scene, changes \\ %{})

@spec bump(t(), map() | keyword()) :: t()

new!(attrs \\ %{})

@spec new!(map() | keyword() | t()) :: t()