2 * DO NOT EDIT THIS FILE.
3 * See the following change record for more information,
4 * https://www.drupal.org/node/2815083
8 (function ($, Drupal, Backbone) {
10 tabbingReleased: Drupal.t('Tabbing is no longer constrained by the Contextual module.'),
11 tabbingConstrained: Drupal.t('Tabbing is constrained to a set of @contextualsCount and the edit mode toggle.'),
12 pressEsc: Drupal.t('Press the esc key to exit.')
15 function initContextualToolbar(context) {
16 if (!Drupal.contextual || !Drupal.contextual.collection) {
20 var contextualToolbar = Drupal.contextualToolbar;
21 var model = contextualToolbar.model = new contextualToolbar.StateModel({
22 isViewing: localStorage.getItem('Drupal.contextualToolbar.isViewing') !== 'false'
24 contextualCollection: Drupal.contextual.collection
28 el: $('.toolbar .toolbar-bar .contextual-toolbar-tab'),
32 new contextualToolbar.VisualView(viewOptions);
33 new contextualToolbar.AuralView(viewOptions);
36 Drupal.behaviors.contextualToolbar = {
37 attach: function attach(context) {
38 if ($('body').once('contextualToolbar-init').length) {
39 initContextualToolbar(context);
44 Drupal.contextualToolbar = {
47 })(jQuery, Drupal, Backbone);