Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a
uw.avatars
API. The public API is:uw.avatars.getAvailableAvatars(user)
- List available avatar descriptors.uw.avatars.setAvatar(user, descriptor)
- Set the user's avatar to one of thegetAvailableAvatars()
descriptorsuw.avatars.supportsCustomAvatars()
- Check if custom avatar uploads are possible (requires configuring a file storage path)uw.avatars.setCustomAvatar(user, stream)
- Store the avatar from the readablestream
and set it as the user's avatarThe default implementation has these features:
A client is expected to show a list of available avatars to choose from, and an image upload form if uploads are enabled.
TODOs
assets
plugin of some sort to store and serve the uploaded avatars Asset store for uploaded files #397After this is done, the pending social account stuff should use the avatar selection screen on the client end. That way we don't show user's faces in chat immediately if they signed up with their google account for example. (This is why google signup is not enabled on wlk.yt fwiw 🤣 )