toodego: pass expand icon click to parent (#40211)

This commit is contained in:
Frédéric Péters 2020-02-26 15:40:01 +01:00
parent 0ce9e36007
commit 6173f67606
1 changed files with 5 additions and 1 deletions

View File

@ -948,7 +948,11 @@ $(function() {
function init_group_titles_for_a11y() {
$('.group-title h2').each(function(idx, elem) {
if ($(elem).find('.a11y-toggle-link').length) return;
$(elem).append('<a class="a11y-toggle-link" href=""><span class="sr-only">plier/déplier la section</span></a>')
var a = $(elem).append('<a class="a11y-toggle-link" href=""><span class="sr-only">plier/déplier la section</span></a>')
$(a).on('click', function() {
$(this).parent().trigger('click');
return false;
});
});
}
init_group_titles_for_a11y();