Page MenuHomePhabricator

[native] use savedEmojiAvatarSelectorForCurrentUser in EmojiAvatarCreation
ClosedPublic

Authored by ginsu on Apr 12 2023, 12:17 PM.
Tags
None
Referenced Files
F2133047: D7403.id25071.diff
Fri, Jun 28, 1:44 AM
Unknown Object (File)
Thu, Jun 27, 5:21 PM
Unknown Object (File)
Tue, Jun 25, 11:41 PM
Unknown Object (File)
Tue, Jun 25, 6:01 PM
Unknown Object (File)
Tue, Jun 25, 8:51 AM
Unknown Object (File)
Tue, Jun 25, 8:28 AM
Unknown Object (File)
Sat, Jun 22, 5:53 PM
Unknown Object (File)
Sun, Jun 16, 1:55 AM
Subscribers

Details

Summary

Based on feedback I got in D7359, when we "reset" the emoji avatar during the emoji avatar creation flow , we want to reset to the current state in redux which we are considering the source of truth. This is the diff that implements the selector I introduced in the previous diff

Depends on D7402

Test Plan

The reset functionality behaves as expected:

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

ashoat added inline comments.
native/profile/emoji-avatar-creation.react.js
17 ↗(On Diff #25054)

See my note about making this selector return a function in D7402

This revision is now accepted and ready to land.Apr 12 2023, 5:56 PM
native/profile/emoji-avatar-creation.react.js
22–27 ↗(On Diff #25071)

We could pass initialization functions to useState to avoid needing to call savedEmojiAvatarFunc() when we don't need to, but it's not a huge deal

42 ↗(On Diff #25071)

We could call savedEmojiAvatarFunc() here to avoid calling it unless we need to

native/profile/emoji-avatar-creation.react.js
25

Shouldn't this be .color?

native/profile/emoji-avatar-creation.react.js
25

thanks for catching that