AppearanceBehavior
- Kind
- class
- Source
- src/behaviors/AppearanceBehavior.js:463
Description
Built-in behavior for global visual appearance and render quality.
Signature
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | Background, node/edge scale and opacity, shading, ambient occlusion, and adaptive edge quality options. |
Returns
Behavior that keeps appearance settings serializable and synchronized with UI bindings.
TypeAppearanceBehaviorNotes
Renderer capability affects some appearance options. Query
supportsAmbientOcclusion() after await helios.ready before exposing
ambient-occlusion controls.
Instance Properties
id
Source: src/behaviors/AppearanceBehavior.js:464
Id exposed by the class.
Filtering And State
Graph filtering and interaction state. When active, FilterBehavior and SelectionBehavior coordinate this area.
getPublicState()
Source: src/behaviors/AppearanceBehavior.js:634
Returns the current public state value or state.
Example
const value = helios.getPublicState();
Network And Persistence
Network replacement, serialization, and visualization state persistence. ExporterBehavior and InterfaceBehavior can surface parts of this flow in the UI.
attach(context)
Source: src/behaviors/AppearanceBehavior.js:473
Configures or reads attach.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
context | Value passed to attach. |
serialize()
Source: src/behaviors/AppearanceBehavior.js:504
Handles serialize for the current graph or visualization state.
restore(snapshot = {}) → {this}
Source: src/behaviors/AppearanceBehavior.js:618
Updates the restore state on the current instance.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
snapshot | optional | {} | Value passed to restore. |
Returns
This instance.
TypethisAppearance
Visual rendering settings for nodes, edges, labels, legends, density, shading, and background. AppearanceBehavior, LabelsBehavior, and LegendsBehavior cover the built-in controls.
supportsAmbientOcclusion()
Source: src/behaviors/AppearanceBehavior.js:630
Configures or reads supports ambient occlusion.
Utilities
Additional public helpers that do not belong to a narrower API area.
update(options = {}) → {Object|this}
Source: src/behaviors/AppearanceBehavior.js:494
Read or set the update setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current update value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.update({
enabled: true,
});
stateEntries()
Source: src/behaviors/AppearanceBehavior.js:510
Configures or reads state entries.
appearance(options) → {Object|this}
Source: src/behaviors/AppearanceBehavior.js:625
Read or set the appearance setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | Options object for this operation. |
Returns
Current appearance value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.appearance({
enabled: true,
});
emitChange(reason, detail = {})
Source: src/behaviors/AppearanceBehavior.js:638
Configures or reads emit change.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
reason | string | Reason for this operation. | ||
detail | optional | {} | Event payload passed to listeners. |