Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 299225

Edit should use the new drupalContextualLinkAdded event to cleanly instead of hackily insert its "Quick edit" contextual link

$
0
0

Title says it all.

That event is being introduced at #1971108: Convert contextual.js to use Backbone (and support dynamic contextual links).

From #2 of that issue:

Essentially, I want to get rid of this hacky, ad-hoc solution:

   // Add "Quick edit" links to all contextual menus where editing the full
   // node is possible.
   // @todo Generalize this to work for all entities.
-  $('ul.contextual-links li.node-edit')
+  $('ul.contextual-links').find('li.node-edit, li.taxonomy-edit, li.custom-block-edit')
   .before('<li class="quick-edit"></li>')

This will become more important once #1966704: In-place editing for taxonomy terms and custom blocks lands.


Viewing all articles
Browse latest Browse all 299225

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>