[web] Introduce useUploadAvatarMedia to AvatarHooks
Summary:
This function is similar to useUploadProcessedMedia() in native/avatar-hooks. It basically lets us upload the File we receive from image input.
We consume useUploadAvatarMedia in EditUserAvatarMenu to upload the selected image. In subsequent diffs, we will update onImageSelected to handle the setting of the image avatar as well.
Test Plan:
- Select "Select image" from EditUserAvatarMenu
- Select an image from the file explorer
- Check the uploads table and observe that the image was uploaded:
Reviewers: ashoat, ginsu
Reviewed By: ashoat
Subscribers: tomek
Differential Revision: https://phab.comm.dev/D8724