Page MenuHomePhabricator

[native] introduce relationship button
ClosedPublic

Authored by ginsu on Sep 27 2023, 2:40 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 1, 1:07 PM
Unknown Object (File)
Sat, Oct 26, 1:27 AM
Unknown Object (File)
Sun, Oct 20, 3:42 PM
Unknown Object (File)
Sun, Oct 20, 3:42 PM
Unknown Object (File)
Sun, Oct 20, 3:42 PM
Unknown Object (File)
Sun, Oct 20, 3:41 PM
Unknown Object (File)
Sun, Oct 20, 3:34 PM
Unknown Object (File)
Sun, Oct 20, 12:55 AM
Subscribers

Details

Summary

In D9258, I got some feedback to factor out some of the logic in UserProfileRelationshipButton into its own separate RelationshipButton component. This diff introduces this compnent and should address that feedback

Test Plan

Please see the screenshots below:

add:

Screenshot 2023-09-27 at 5.11.20 PM.png (1×948 px, 677 KB)

withdraw:

Screenshot 2023-09-27 at 5.11.29 PM.png (1×948 px, 686 KB)

accept & reject (there is a wrapping View for this in a parent component which is why it is in the row direction):

Screenshot 2023-09-27 at 5.47.12 PM.png (1×948 px, 448 KB)

block:

Screenshot 2023-09-27 at 5.11.04 PM.png (1×948 px, 678 KB)

unblock:

Screenshot 2023-09-27 at 5.11.10 PM.png (1×948 px, 678 KB)

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

native/components/relationship-button.react.js
15–16 ↗(On Diff #31469)

Added block and unblock preemptively in case we ever wanted to use this component in those situations as well.

ginsu requested review of this revision.Sep 27 2023, 2:59 PM
atul added inline comments.
native/components/relationship-button.react.js
15–16 ↗(On Diff #31469)

Love that it's flexible

This revision is now accepted and ready to land.Sep 27 2023, 4:28 PM
This revision was automatically updated to reflect the committed changes.