2 * DO NOT EDIT THIS FILE.
3 * See the following change record for more information,
4 * https://www.drupal.org/node/2815083
8 (function ($, Backbone, Drupal) {
9 Drupal.quickedit.ContextualLinkView = Backbone.View.extend({
10 events: function events() {
11 function touchEndToClick(event) {
12 event.preventDefault();
17 'click a': function clickA(event) {
18 event.preventDefault();
19 this.model.set('state', 'launching');
21 'touchEnd a': touchEndToClick
24 initialize: function initialize(options) {
25 this.$el.find('a').text(options.strings.quickEdit);
29 this.listenTo(this.model, 'change:isActive', this.render);
31 render: function render(entityModel, isActive) {
32 this.$el.find('a').attr('aria-pressed', isActive);
34 this.$el.closest('.contextual').toggle(!isActive);
39 })(jQuery, Backbone, Drupal);