Mercurial > hg > isophonics-drupal-site
view core/modules/toolbar/js/models/ToolbarModel.js @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
line wrap: on
line source
/** * DO NOT EDIT THIS FILE. * See the following change record for more information, * https://www.drupal.org/node/2815083 * @preserve **/ (function (Backbone, Drupal) { Drupal.toolbar.ToolbarModel = Backbone.Model.extend({ defaults: { activeTab: null, activeTray: null, isOriented: false, isFixed: false, areSubtreesLoaded: false, isViewportOverflowConstrained: false, orientation: 'horizontal', locked: false, isTrayToggleVisible: true, height: null, offsets: { top: 0, right: 0, bottom: 0, left: 0 } }, validate: function validate(attributes, options) { if (attributes.orientation === 'horizontal' && this.get('locked') && !options.override) { return Drupal.t('The toolbar cannot be set to a horizontal orientation when it is locked.'); } } }); })(Backbone, Drupal);