When true, the edges of the graph will be rendered with a flow animation. Use this to indicate that the graph is currently "running".
Provides access to the underlying
Fired when the DiazoContext has been acquired from the underlying Diazo component. DiazoContext represents the operating state (model) of the Diazo editor.
Specify a set of custom components that will be used to render specific types of
properties. Each custom property type specifies a "namespace" and an "id".
You use this custom type in the properties
declaration on a node (or via
universalPropertySets) by specifying property.type = "namespace:id"
(for example).
Fired when the graph has been changed by the user. More technically this is fired when a change transaction is "committed" to the Diazo Context. These change transactions underpin Diazo's support for Undo/Redo.
Stores the current graph context object. This represents the state logic for the graph being edited within the Diazo editor
If true, the Diazo editor will allow no changes to the graph whatsoever.
When this is true, readonly
is also considered to be true. The difference
between locked
and readonly
is mainly that the nodes cannot be moved around
by the user.
Provides the NodeSets which are currently visible in the New Node menu, subject to the search query entered by the user.
Provides the Nodes which are currently visible
in the New Node menu, subject to the search query
entered by the user. This is a flattening of the nodes
found in matchingNodeSets
.
When true, the Node Menu is in keyboard mode, and certain
keystrokes (up/down/enter) can be used to select and insert
a node visible in the menu, This works in concert with
matchingNodes
.
Specify a set of custom components that will be used to render specific types of nodes. The key of this map should match the "$.type" property of a node you wish to use a custom component with. The value is the Angular component class.
The custom component can inject the DiazoNodeContext
instance in order
to interact with the node state.
Allows the consumer to specify dynamic option sources for use with properties of type "select". Since properties are static declarations, it is generally not possible to dynamically populate the options of a "select" property. The "optionSources" system provides a good way to do this. To use it, define a property such as {type: "select", optionSource: "mySource"} and specify "optionSources" as { mySource: { option1: "Option 1", option2: "Option 2"}}. The Diazo editor will automatically populate these options into the select box in the Properties panel.
A proxy object which is capable of getting or setting property values across the nodes that are currently selected in the editor. The keys of this object are interpreted as either JSONPath (when the key starts with '$') or Diazo's custom object path format (otherwise).
Allows the consumer to pass in a set of dependency injection providers which will be used whenever a custom property editor or custom node is created. Use this to pass in services needed by your custom controls.
If true, the Diazo editor will be placed in Read Only mode. The user can still move nodes around, but new nodes cannot be created, existing nodes cannot be removed, and edges cannot be changed.
Bind to this event to receive Save events from the user (Diazo Editor does not do anything special with a Save request by default, that is up to the consumer). This fires when the user presses Ctrl+S / Cmd+S.
The index of a node in the New Node menu that the user has selected via Keyboard Mode.
Get the currently selected node context (the first one if multiple nodes are currently selected)
Get the currently selected node-contexts
Provides the PropertySets which are currently visible subject to the search query entered by the user.
Specify an array of PropertySets which will be shown for all nodes that exist in the graph. These PropertySets will be shown after the ones defined on the node itself.
Specify a set of "value types" which are used to declare the types of edges that can be created within the graph. The value type system supports compatibility by class heirarchy by default, and custom value type classes can even redefine the notion of compatibility however they want. Compatibility here refers to whether a slot with one "value" is allowed to be connected to a slot with another "value".
Value types also define the color and appearance of the edge when rendered within Diazo.
Allows the consumer to pass in the set of nodes that will be available for the user to add to the graph via the New Node menu (right click).
Allows the consumer to pass in the set of nodes that will be available for the user to add to the graph via the New Node menu (right click).
Specify the Diazo object that this editor should work with.
The object is passed by reference here, and the object will be
modified by the Diazo editor in place. Note that you can
also receive immutable snapshots of the graph via the
graphChanged
event.
Specify the Diazo object that this editor should work with.
The object is passed by reference here, and the object will be
modified by the Diazo editor in place. Note that you can
also receive immutable snapshots of the graph via the
graphChanged
event.
The text the user has entered into the Node Menu's Search box.
The text the user has entered into the Node Menu's Search box.
The text the user has entered into the Property Sheet's Search box.
The text the user has entered into the Property Sheet's Search box.
Get the currently selected DiazoNode (the first one if there are multiple nodes selected)
Get the currently selected DiazoNodes.
This is true if the selection of nodes is considered "readonly". The selection is considered readonly if any selected node is marked as "readonly".
True when the user has made the Properties sidebar visible. False when the user has hidden it. This also has special behavior if the user has not yet shown/hidden the sidebar -- if the screen size is small enough to be considered "mobile", then this will return false. Otherwise it will be true.
True when the user has made the Properties sidebar visible. False when the user has hidden it. This also has special behavior if the user has not yet shown/hidden the sidebar -- if the screen size is small enough to be considered "mobile", then this will return false. Otherwise it will be true.
Hide the node menu if it is currently visible.
Show the node menu if it is not currently visible.
Options used for Monaco when editing JSON.
Options used for Monaco when editing Markdown.
Options used for Monaco when editing TypeScript.
Generated using TypeDoc
Provides a full-featured Diazo editor, including a searchable New Node list and a powerful property sheet implementation.
<dz-editor [graph]="myGraph" [availableNodes]="myDefinedNodes"></dz-editor>
Here,
[graph]
is the graph that should be rendered. Any changes made by the user will be applied to the bound object.[availableNodes]
is an array of {@linkcode DiazoNode} objects made available to the user in the New Node menuSee More