Page MenuHomePhabricator

[web] make it possible to select farcaster avatar on web
ClosedPublic

Authored by varun on Sep 18 2024, 6:19 AM.
Tags
None
Referenced Files
F3012119: D13380.id44299.diff
Sat, Oct 19, 2:33 AM
Unknown Object (File)
Mon, Oct 14, 5:20 AM
Unknown Object (File)
Mon, Oct 14, 4:24 AM
Unknown Object (File)
Sat, Oct 5, 3:18 PM
Unknown Object (File)
Wed, Oct 2, 2:33 AM
Unknown Object (File)
Wed, Oct 2, 2:31 AM
Unknown Object (File)
Tue, Oct 1, 12:31 PM
Unknown Object (File)
Tue, Oct 1, 6:45 AM
Subscribers
None

Details

Summary

if the user has an fid, we try to get their farcaster avatar URL. if we find a URL, we'll display the option to set the farcaster avatar as the user's comm avatar. if the user selects the farcaster avatar, their avatar is updated in the app and on the keyserver.

Depends on D13379

Test Plan

can successfully set farcaster avatar on web and it subsequently appears on other clients. can reset the avatar, too.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

varun requested review of this revision.Sep 18 2024, 6:35 AM
ashoat added inline comments.
web/avatars/edit-user-avatar-menu.react.js
157 ↗(On Diff #44299)

Assume this will not be set if there is no FID?

This revision is now accepted and ready to land.Sep 18 2024, 7:55 AM
web/avatars/edit-user-avatar-menu.react.js
157 ↗(On Diff #44299)

yeah that's right, useFarcasterAvatar (renaming to useFarcasterAvatarURL before landing) will return null if there is no FID