Thanks for your attention to this. It would be great to have a truly accessible mega menu solution I could recommend to my WP clients, and I think yours is very close!
VoiceOver is probably what you’re using on Mac. On Windows, there is the built in Narrator utility, but most people use NVDA (it recently surpassed JAWS).
Here’s the issue I’m seeing… While using NVDA or Narrator, when I tab thru the navigation items and want to expand one of them, I hit “Enter or Space” and nothing happens. I would expect Enter/Space to expand the sub menu. If I’m not using a screen reader, it all works fine.
The problem is that Narrator and NVDA are in “browse mode” which intercepts/swallows some keystrokes. If I exit NVDA browse mode and switch into “forms mode” then it works, but we can’t expect users to do that. One possible solution might be to modify your JavaScript to use “click” instead of “keypress” as suggested in this thread: https://stackoverflow.com/questions/65181014/js-function-with-e-key-enter-wont-fire-when-in-screenreader-nvda-brows
You may also find this pattern and example provided by the W3C to be useful: https://www.w3.org/WAI/ARIA/apg/patterns/disclosure/examples/disclosure-navigation/
Here’s a screencast of me using screen readers with the Max Mega Menu: https://www.loom.com/share/3c368831630347e69817dc6c866a4bf6?sid=dc819f1c-8062-4b81-a61e-769c7d8935e6
I hope all that help. If you’d like me to retest, please let me know.