mrwweb / clicky-menus

Simple click-triggered navigation submenus. Accessible and progressively enhanced.
MIT License
90 stars 15 forks source link

Generate id based on attribute, not anchor text #11

Closed juanjosezg closed 1 year ago

juanjosezg commented 2 years ago

It is necessary to change the way in which the ids of the submenus are generated .. it is better to be based on the id of the parent or the container div ... currently it is based on the text of the link that has the submenu but it causes problems when you have the same menu in two different parts of the website.

aria

mrwweb commented 2 years ago

Thanks for the report @juanjosezg. That makes total sense. It probably makes sense to fix this and #2 together. No ETA on a fix, but really appreciate you flagging this issue.

mrwweb commented 1 year ago

@juanjosezg I just pushed an update that adds an iterator for each menu instance that resolves this issue. If you ever test it, I'd love to know if it works for you!