Class: VisualView

Drupal.contextualToolbar.VisualView()

new VisualView()

Renders the visual view of the edit mode toggle.

Listens to mouse & touch and handles edit mode toggle interactions.

Source:

Extends

  • Backbone.View

Methods

events() → {object}

Events for the Backbone view.

Source:
Returns:

A mapping of events to be used in the view.

Type
object

persist(model, isViewing)

Model change handler; persists the isViewing value to localStorage.

isViewing === true is the default, so only stores in localStorage when it's not the default value (i.e. false).

Parameters:
Name Type Description
model Drupal.contextualToolbar.StateModel

A Drupal.contextualToolbar.StateModel model.

isViewing bool

The value of the isViewing attribute in the model.

Source:

render() → {Drupal.contextualToolbar.VisualView}

{@inheritdoc}

Source:
Returns:

The current contextual toolbar visual view.

Type
Drupal.contextualToolbar.VisualView