Class: ToggleTourView

Drupal.tour.views.ToggleTourView()

new ToggleTourView()

Handles edit mode toggle interactions.

Source:

Extends

  • Backbone.View

Members

events :object

Type:
  • object
Source:

Methods

_getDocument() → {jQuery}

Gets the relevant document as a jQuery element.

Source:
Returns:

A jQuery element pointing to the document within which a tour would be started given the current state.

Type
jQuery

_getTour() → {jQuery}

Gets the tour.

Source:
Returns:

A jQuery element pointing to a <ol> containing tour items.

Type
jQuery

_removeIrrelevantTourItems($tour, $document)

Removes tour items for elements that don't have matching page elements.

Or that are explicitly filtered out via the 'tips' query string.

Parameters:
Name Type Description
$tour jQuery

A jQuery element pointing to a <ol> containing tour items.

$document jQuery

A jQuery element pointing to the document within which the elements should be sought.

Source:
See:
Example

This will filter out tips that do not have a matching page element or don't have the "bar" class.

http://example.com/foo?tips=bar

onClick(event)

Toolbar tab click event handler; toggles isActive.

Parameters:
Name Type Description
event jQuery.Event

The click event.

Source:

render() → {Drupal.tour.views.ToggleTourView}

{@inheritdoc}

Source:
Returns:

The ToggleTourView view.

Type
Drupal.tour.views.ToggleTourView

toggleTour()

Model change handler; starts or stops the tour.

Source: