Page MenuHomePhabricator

[native] introduce block action to relationship list item tooltip menu
ClosedPublic

Authored by ginsu on Oct 5 2023, 1:46 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Oct 26, 1:27 AM
Unknown Object (File)
Sun, Oct 20, 9:30 AM
Unknown Object (File)
Sun, Oct 20, 9:29 AM
Unknown Object (File)
Sun, Oct 20, 9:29 AM
Unknown Object (File)
Sun, Oct 20, 9:29 AM
Unknown Object (File)
Sun, Oct 20, 9:24 AM
Unknown Object (File)
Thu, Oct 17, 9:39 PM
Unknown Object (File)
Sep 20 2024, 9:52 AM
Subscribers

Details

Summary

This stack will finish up the functionality for the user profile menu button. When a user presses on the menu button, we expect that a tooltip menu will pop up with some relationship actions (blocking, unfriending, etc). We already have RelationshipListItemTooltipModal which does exactly what we need but we need to make a few tweaks to this in order to make RelationshipListItemTooltipModal more general purpose and work for the case of both the RelationshipListItem as well as the UserProfile.

Screenshot 2023-10-05 at 4.44.56 PM.png (1×1 px, 170 KB)

This is step 1 in the list below
Outlined below are the steps I will take to update RelationshipListItemTooltipModal:

  1. Add the block action to relationship list item tooltip menu (RelationshipListItem won't need this option, but User profiles will. This is shown in the figma screenshot above)
  2. Rename RelationshipListItemTooltipModal to something more generic like UserRelationshipTooltipModal
  3. Make UserRelationshipTooltipButton into a functional component (We need to use the useColors hook in a subsequent diff)
  4. Introduce the tooltipButtonIcon as a param to RelationshipListItemTooltipModal (RelationshipListItem will use a pencil icon and user profiles will use a kebab menu icon)
  5. Introduce UserProfileMenuButton (This component will handle navigating to RelationshipListItemTooltipModal

Depends on D9377

Test Plan

Confirmed that RelationshipListItem does not have the block action (this is expected since block was not added to the visibleEntryIDs in RelationshipListItem), but here is what it is going to look like in the user profile (introduced later in this stack)

RelationshipListItem:

Screenshot 2023-10-05 at 4.47.29 PM.png (1×1 px, 300 KB)

User Profile:

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

ginsu requested review of this revision.Oct 5 2023, 2:04 PM
This revision is now accepted and ready to land.Oct 5 2023, 4:25 PM
This revision was landed with ongoing or failed builds.Oct 5 2023, 6:38 PM
This revision was automatically updated to reflect the committed changes.