Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pass through assign attrs in link#navigate helper #47

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jprincipe
Copy link

I noticed that the keyboard navigation of the Sidebar User Menu wasn't working for anything except the Sign Out link. The issue was the attributes that are passed in to the other menu items (i.e. role="menuitem") were being dropped in the live link helper:

def link(%{navigate: _to} = assigns do
   # ...
end

Rather than passing along all incoming assigns as attributes, it was extracting just the class assign and using that. This PR just updates that link/1 function so it works like the other link/1 helpers.

I'd also like to thank you for putting together a project like this. Invaluable resource for learning the new features of LiveView.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant