Search
DashboardCanvas Members
Constructors Properties Methods
 


Represents a dashboard control.

The following tables list the members exposed by the DashboardCanvas type.

 Public Constructors

  Name Description

DashboardCanvas

Initializes a new instance of the DashboardCanvas class.

 Public Properties

  Name Description

currentLayout

Gets or sets the active layout manager instance.

dashboard

Gets or sets the underlying Dashboard data model.

layout

Gets or sets the layout algorithm used by the canvas.

mode

Gets or sets the operational mode of the canvas (View or Edit).

 Public Methods

  Name Description

addWidget

Adds a widget to the dashboard at the specified grid position for GridLayout or with specified bounds for DiagramLayout.

attach

Attaches the pointer input handlers used for interactive editing and drag operations.

attachDashboardEvents

Subscribes to dashboard lifecycle events.

clearAll

Clears all widgets and resets the active layout state.

create

Creates and initializes a new DashboardCanvas from the specified element. This method is static and can be called without creating an instance of the class.

createController

Creates a controller for the active layout when the canvas is in edit mode.

detachDashboardEvents

Unsubscribes from dashboard lifecycle events.

dispose

Releases resources used by the dashboard canvas.

draw

Renders the current layout and container structure into the DOM.

find

Returns the specified DashboardCanvas object. This member is static and can be invoked without creating an instance of the class.

fromJson

Populates the dashboard canvas from a serialized JSON payload.

invalidate

Invalidates the canvas and triggers a refresh.

invalidateWidget

Marks a widget as needing a refresh during the next render frame.

onWidgetAdded

Handles the addition of a widget to the dashboard model.

onWidgetRemoved

Handles the removal of a widget from the dashboard model.

refreshWidget

Refreshes the DOM representation of a single widget.

refreshWidgets

Refreshes all widgets that were invalidated.

removeWidget

Removes a widget from the dashboard and its layout container.

requestRender

Requests a render on the next animation frame.

serializeLayouts

Serializes all cached layouts into a JSON-compatible array.

toJson

Saves the diagram to a JSON string.

 See Also