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

Changes to Profile Name or Team Name not immediately reflected in menu... #99

Closed
telkins opened this issue Sep 8, 2020 · 5 comments · Fixed by #132
Closed

Changes to Profile Name or Team Name not immediately reflected in menu... #99

telkins opened this issue Sep 8, 2020 · 5 comments · Fixed by #132

Comments

@telkins
Copy link
Contributor

telkins commented Sep 8, 2020

  • Jetstream Version: 1.0.0
  • Laravel Version: 8.0.0
  • PHP Version: 7.4.9
  • Database Driver & Version: n/a

Description:

When changing the team name or profile name, neither the team name in the drop-down menu nor the avatar (initials) reflect the changes until a refresh is made.

This probably isn't a big deal, but I thought I'd point it out. 🤓

Steps To Reproduce:

Install new app: laravel new l8app --jet --teams --stack=livewire
Build front-end: npm install && npm run dev
Visit site
Register
Go to Team Settings or Profile
Change team name or name
Notice that the user avatar (initials) or drop-down menu don't update to reflect the changes

@mallardduck
Copy link
Contributor

Seems like the easiest fix would be to force those actions to trigger a complete page reload. I wonder if Livewire provides functionality for that OOTB, or if they have another solution to this issue to force other elements on page update.

@stevebauman
Copy link
Contributor

stevebauman commented Sep 9, 2020

@mallardduck

I wonder if Livewire provides functionality for that OOTB

I think we could use the $this->emit() feature in Livewire to emit an update event to other components that an account update has occurred and to refresh themselves?

@mallardduck
Copy link
Contributor

Ahh @stevebauman great point!

I only just started working with livewire a few weeks back, so overlooked that.
Great idea that should be a fancier UX than doing a full reload.

@calebporzio
Copy link
Contributor

I proposed a solution in this PR: #132

@telkins
Copy link
Contributor Author

telkins commented Sep 10, 2020

I proposed a solution in this PR: #132

Thx...! 🤓

I thought the PR made good sense, but I also suggested changing the event name to instead say what's happening vs what should happen. 😜

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 a pull request may close this issue.

5 participants