feat(avatar): Postie avatar creator + surface across app#113
Open
code418 wants to merge 1 commit into
Open
Conversation
…eaderboards, and profile
Players can now build a Postman James-style avatar from swappable parts
(skin, head, hair, eyes, nose, facial hair, hat, glasses, background).
The saved config persists to users/{uid}.avatar and is rendered wherever
players appear: friends list, leaderboards (global + friends-only),
profile header, and settings header. Falls back to initials when no
avatar is set.
Cloud Functions embed the avatar map in leaderboard entries so the
global tab renders avatars without an N+1 read; Firestore rules permit
the user to write only their own avatar map (size-capped).
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
users/{uid}.avatarand is rendered everywhere a player appears: friends list, both leaderboard tabs (global + friends-only), user profile header, settings header. Falls back to initials when no avatar is set.startScoring,updateDisplayName,newDayScoreboard) embed the avatar map into leaderboard entries so the global tab renders avatars without an N+1 user-doc read.avatarmap (size-capped at 20 keys).Implements the Royal Mail Avatar Workshop design from the Claude Design handoff bundle.
Test plan
flutter analyze— cleanflutter test— 98 passingnpm test(functions) — 227 passingflutter build web— succeedsfirebase deploy --only firestore:rules,functions🤖 Generated with Claude Code