InterfaceBehavior
- Kind
- class
- Source
- src/behaviors/InterfaceBehavior.js:78
Description
Built-in behavior for responsive interface and touch-oriented app state.
Signature
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | Compact/fullscreen breakpoints, preferred dock side, and restore-prompt behavior. |
Returns
Behavior that tracks dock side, viewport class, active panels, controls visibility, and resume-session prompts.
TypeInterfaceBehaviorNotes
Helios Web can render without HeliosUI; this behavior stores the
serializable interface state that an app shell or UI layer can bind to.
Instance Properties
id
Source: src/behaviors/InterfaceBehavior.js:79
Id exposed by the class.
Filtering And State
Graph filtering and interaction state. When active, FilterBehavior and SelectionBehavior coordinate this area.
serializeInterfaceState(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:316
Read or set the serialize interface state setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current serialize interface state value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.serializeInterfaceState({
enabled: true,
});
restoreInterfaceState(snapshot = {}, options = {}) → {this}
Source: src/behaviors/InterfaceBehavior.js:329
Updates the interface state state on the current instance.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
snapshot | optional | {} | Value passed to restoreInterfaceState. | |
options | Object | optional | {} | Options object for this operation. |
Returns
This instance.
TypethisNetwork 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/InterfaceBehavior.js:95
Configures or reads attach.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
context | Value passed to attach. |
serialize()
Source: src/behaviors/InterfaceBehavior.js:286
Handles serialize for the current graph or visualization state.
restore(snapshot = {}) → {this}
Source: src/behaviors/InterfaceBehavior.js:301
Updates the restore state on the current instance.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
snapshot | optional | {} | Value passed to restore. |
Returns
This instance.
TypethisCamera And View
Camera framing, target following, dimensional mode, and transitions. InterfaceBehavior can expose these controls.
mode()
Source: src/behaviors/InterfaceBehavior.js:160
Configures or reads mode.
Appearance
Visual rendering settings for nodes, edges, labels, legends, density, shading, and background. AppearanceBehavior, LabelsBehavior, and LegendsBehavior cover the built-in controls.
viewportWidth()
Source: src/behaviors/InterfaceBehavior.js:172
Configures or reads viewport width.
setViewportWidth(width, options = {}) → {this}
Source: src/behaviors/InterfaceBehavior.js:176
Set the viewport width setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
width | Value passed to setViewportWidth. | |||
options | Object | optional | {} | Options object for this operation. |
Returns
This instance.
TypethisConfiguration
General configuration setters and compatibility helpers.
toggleDockSide()
Source: src/behaviors/InterfaceBehavior.js:156
Updates the dock side state on the current instance.
clearActiveControl() → {this}
Source: src/behaviors/InterfaceBehavior.js:264
Updates the active control state on the current instance.
Returns
This instance.
TypethisUtilities
Additional public helpers that do not belong to a narrower API area.
update(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:103
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,
});
bindUI(ui = null)
Source: src/behaviors/InterfaceBehavior.js:127
Configures or reads bind ui.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
ui | optional | null | Value passed to bindUI. |
compactBreakpoint(value) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:133
Read or set the compact breakpoint setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value | New compact breakpoint value. Omit this argument to read the current value. |
Returns
Current compact breakpoint value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.compactBreakpoint(1);
fullscreenBreakpoint(value) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:139
Read or set the fullscreen breakpoint setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value | New fullscreen breakpoint value. Omit this argument to read the current value. |
Returns
Current fullscreen breakpoint value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.fullscreenBreakpoint(1);
dockSide(value) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:145
Read or set the dock side setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value | New dock side value. Omit this argument to read the current value. |
Returns
Current dock side value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.dockSide(1);
isCompact()
Source: src/behaviors/InterfaceBehavior.js:164
Returns the current compact value or state.
Example
const value = helios.isCompact();
isFullscreen()
Source: src/behaviors/InterfaceBehavior.js:168
Returns the current fullscreen value or state.
Example
const value = helios.isFullscreen();
recomputeMode(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:221
Read or set the recompute mode setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current recompute mode value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.recomputeMode({
enabled: true,
});
controlsOpen(value) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:225
Read or set the controls open setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value | New controls open value. Omit this argument to read the current value. |
Returns
Current controls open value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.controlsOpen(1);
openControlsSurface()
Source: src/behaviors/InterfaceBehavior.js:240
Configures or reads open controls surface.
closeControlsSurface()
Source: src/behaviors/InterfaceBehavior.js:244
Configures or reads close controls surface.
activateControl(panelId) → {this}
Source: src/behaviors/InterfaceBehavior.js:248
Updates the control state on the current instance.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
panelId | Value passed to activateControl. |
Returns
This instance.
TypethisinterfaceVisible(value) → {number|this}
Source: src/behaviors/InterfaceBehavior.js:276
Read or set the interface visible setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
value | number | New interface visible value. Omit this argument to read the current value. |
Returns
Current interface visible value when called without arguments; otherwise this instance for chaining.
Typenumber|thisExample
helios.interfaceVisible(1);
ensurePersistenceReady()
Source: src/behaviors/InterfaceBehavior.js:352
Configures or reads ensure persistence ready.
persistResponsivePreferences(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:398
Read or set the persist responsive preferences setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current persist responsive preferences value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.persistResponsivePreferences({
enabled: true,
});
resumePrompt()
Source: src/behaviors/InterfaceBehavior.js:418
Configures or reads resume prompt.
resumeSession(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:422
Read or set the resume session setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current resume session value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.resumeSession({
enabled: true,
});
startFresh(options = {}) → {Object|this}
Source: src/behaviors/InterfaceBehavior.js:442
Read or set the start fresh setting.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
options | Object | optional | {} | Options object for this operation. |
Returns
Current start fresh value when called without arguments; otherwise this instance for chaining.
TypeObject|thisExample
helios.startFresh({
enabled: true,
});
dismissResumePrompt()
Source: src/behaviors/InterfaceBehavior.js:465
Configures or reads dismiss resume prompt.
emitChange(reason, detail = {})
Source: src/behaviors/InterfaceBehavior.js:492
Configures or reads emit change.
Parameters
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
reason | string | Reason for this operation. | ||
detail | optional | {} | Event payload passed to listeners. |