feat: group the user actions menu by purpose

Merged
GG
18d ago
+143-38

Proposed changes (including videos or screenshots)

The user actions menu (user card kebab, user info, members list) builds one section per action type, in the order each type first appears. Today "Reported messages" sits in the same section as the room role changes, and mute comes after them.

The menu is now grouped by purpose:

  1. Communication: Message, calls and "Reported messages"
  2. Management: Mute and Ignore
  3. Manage room roles (new section title): Set as owner / leader / moderator
  4. Moderation: Remove from room, Ban

Only the order and the section title change; no action is added or removed.

The quick-action buttons in the user card, user info and members list take the first entries of the same list, so they follow this order too: when Message and the calls are unavailable, "Reported messages" and Mute now come before the room role changes. This is the order the user information redesign (#41650) uses.

Extracted from #41650 (user information redesign), where @ivans-netto defined this grouping. Stacked on #42508; #41650 is stacked on top.

Issue(s)

CORE-1962

Steps to test or reproduce

  1. As a room owner, open another member's user info and the kebab menu.
  2. Check the sections follow the order above, with "Manage room roles" as the title of the role changes.

Further comments

useUserInfoActions.spec.ts checks the sections and their order with the individual action hooks mocked; it fails against the previous order.

Summary by CodeRabbit

  • User Experience
    • Reorganized the user actions menu, placing communication actions before mute and ignore, and grouping room-role and moderation actions.
    • Added a “Manage room roles” label for the room-role section.
    • Updated message headers to display workspace and room role descriptions when available.