Makes dropdown clickable, and work with screen reader
I'm lightly peeved with bulma that it wasn't clear how to make hover menus accessible, but clickable menus are just fine with my anyway.
This commit is contained in:
@ -152,8 +152,11 @@ function handleTabChange(target, parentElement) {
|
||||
}
|
||||
|
||||
function toggleMenu(e) {
|
||||
var el = e.target.closest('.pulldown-menu');
|
||||
el.setAttribute('aria-expanded', el.getAttribute('aria-expanded') == 'false');
|
||||
var el = e.currentTarget;
|
||||
var expanded = el.getAttribute('aria-expanded') == 'false';
|
||||
el.setAttribute('aria-expanded', expanded);
|
||||
var target = document.getElementById(el.getAttribute('data-controls'));
|
||||
addRemoveClass(target, 'is-active', expanded);
|
||||
}
|
||||
|
||||
function ajaxPost(form) {
|
||||
|
Reference in New Issue
Block a user