Mercurial > hg > cmmr2012-drupal-site
comparison core/modules/quickedit/js/views/EntityDecorationView.js @ 0:c75dbcec494b
Initial commit from drush-created site
author | Chris Cannam |
---|---|
date | Thu, 05 Jul 2018 14:24:15 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:c75dbcec494b |
---|---|
1 /** | |
2 * DO NOT EDIT THIS FILE. | |
3 * See the following change record for more information, | |
4 * https://www.drupal.org/node/2815083 | |
5 * @preserve | |
6 **/ | |
7 | |
8 (function (Drupal, $, Backbone) { | |
9 Drupal.quickedit.EntityDecorationView = Backbone.View.extend({ | |
10 initialize: function initialize() { | |
11 this.listenTo(this.model, 'change', this.render); | |
12 }, | |
13 render: function render() { | |
14 this.$el.toggleClass('quickedit-entity-active', this.model.get('isActive')); | |
15 }, | |
16 remove: function remove() { | |
17 this.setElement(null); | |
18 Backbone.View.prototype.remove.call(this); | |
19 } | |
20 }); | |
21 })(Drupal, jQuery, Backbone); |