Page MenuHomePhabricator

[native] introduce copy username functionality to user profiles
ClosedPublic

Authored by ginsu on Aug 22 2023, 9:33 AM.
Tags
None
Referenced Files
F3395867: D8915.id30447.diff
Sun, Dec 1, 8:16 AM
F3395856: D8915.id30236.diff
Sun, Dec 1, 8:11 AM
Unknown Object (File)
Thu, Nov 28, 9:41 PM
Unknown Object (File)
Sat, Nov 23, 6:55 PM
Unknown Object (File)
Thu, Nov 21, 7:26 AM
Unknown Object (File)
Thu, Nov 21, 7:26 AM
Unknown Object (File)
Thu, Nov 21, 7:26 AM
Unknown Object (File)
Thu, Nov 21, 7:26 AM

Details

Summary

With profiles, we want to give the user the ability to easily copy another user's username into their clipboard. This diff introduces this functionality.

In the figma doc, @ted described how this functionality should behave:

The “Copy username” toggle will turn into “Username copied!” to confirm that the username has been copied successfully. The toggle will revert back to the default state after 3 seconds.

Here are the screenshots of the designs:

Screenshot 2023-08-22 at 12.32.39 PM.png (2×3 px, 1 MB)

Depends on D8914

Test Plan

Please see demo video below

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

ginsu edited the test plan for this revision. (Show Details)
ginsu added reviewers: atul, inka.
ginsu added a subscriber: ted.
ginsu requested review of this revision.Aug 22 2023, 9:51 AM
native/components/user-profile.react.js
27

Prefer using sleep to setTimeout

This revision is now accepted and ready to land.Aug 26 2023, 4:38 PM

address comments / rebase before landing