Commit 7a17c825 authored by webchick's avatar webchick

Issue #1993894 by mgifford, Jelle_S, Wim Leers | jessebeach: Contextual quick...

Issue #1993894 by mgifford, Jelle_S, Wim Leers | jessebeach: Contextual quick edit toggle should be a <a role='button'> not a <a> because it tracks on/off state.
parent 3921d700
......@@ -390,7 +390,7 @@ function initializeEntityContextualLink (contextualLink) {
var initContextualLink = _.once(function () {
var $links = $(contextualLink.el).find('.contextual-links');
var contextualLinkView = new Drupal.edit.ContextualLinkView($.extend({
el: $('<li class="quick-edit"><a href=""></a></li>').prependTo($links),
el: $('<li class="quick-edit"><a href="" role="button" aria-pressed="false"></a></li>').prependTo($links),
model: entityModel,
}, options));
......@@ -45,6 +45,8 @@ Drupal.edit.ContextualLinkView = Backbone.View.extend({
* {@inheritdoc}
render: function (entityModel, isActive) {
this.$el.find('a').attr('aria-pressed', isActive);
// Hides the contextual links if an in-place editor is active.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment