mattermost-plugin-playbooks icon indicating copy to clipboard operation
mattermost-plugin-playbooks copied to clipboard

Mm 44752 add dot menu to lhs

Open gbochora opened this issue 2 years ago • 3 comments

Summary

This PR adds a dot menu to the LHS. Playbook menu items:

  • Favorite / Unfavorite
  • Copy link
  • Leave

Run menu items:

  • Favorite / Unfavorite
  • Copy link
  • Follow / Unfollow
  • Leave (Only if participants)

Changelog highlights:

  • DotMenu had issues with z-index and content overflow, thanks to @calebroseland switched to using dropdown instead.
  • Moved menu items from contex_menu to controls to reuse them in the LHS
  • Moved shared components to shared.tsx

https://user-images.githubusercontent.com/4368372/187399285-3803723d-10e4-421f-a7fe-b9e021a38a0b.mp4

Ticket Link

https://mattermost.atlassian.net/browse/MM-44752

Checklist

~~- [ ] Telemetry updated~~ ~~- [ ] Gated by experimental feature flag~~

  • [x] Unit tests updated

gbochora avatar Aug 30 '22 09:08 gbochora

Something I noticed - for runs, favorite/unfavorite using the dot menu updates the LHS as expected, however the star icon in the run details does not change until a refresh.

Phrynobatrachus avatar Aug 31 '22 14:08 Phrynobatrachus

Favorite/unfavorite is working better in that the run details star now updates when clicking away and back to the run without a full page refresh, but I still would like that to happen immediately in the same view if possible.

Phrynobatrachus avatar Sep 02 '22 15:09 Phrynobatrachus

Favorite/unfavorite is working better in that the run details star now updates when clicking away and back to the run without a full page refresh, but I still would like that to happen immediately in the same view if possible.

Unfortunately, there is no easy way to make the live update work for Follow/Unfollow and Favorite/Unfavorite until we move entirely run API to GraphQL. I'll add Jira bugs and will fix them after API is migrated.

gbochora avatar Sep 02 '22 18:09 gbochora

Just a detail, you must force a refreshLHS when setting a new owner to force LHS to know about the change, and allow you to leave the run.

Nice catch! thanks.

gbochora avatar Sep 05 '22 06:09 gbochora