Now that it's possible to close an open submenu from anywhere in the DOM (#18), it would be a very nice developer convenience to declaratively use that feature.
So my current thought is this:
<button data-close-clicky-menus="menu-id">Close Open Menu</button>
Where "menu-id" is the ID of a valid clicky-menu instance. If that were in the DOM when the script first executes, I could find those instances and then automatically handle closing submenus when the button is clicked, reducing requirements for custom code.
Now that it's possible to close an open submenu from anywhere in the DOM (#18), it would be a very nice developer convenience to declaratively use that feature.
So my current thought is this:
<button data-close-clicky-menus="menu-id">Close Open Menu</button>
Where "menu-id" is the ID of a valid clicky-menu instance. If that were in the DOM when the script first executes, I could find those instances and then automatically handle closing submenus when the button is clicked, reducing requirements for custom code.