show custom avatars throughout chat - #92
Merged
Merged
Conversation
morgmart
approved these changes
Aug 18, 2026
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.
Overview
Category: fix
User Impact: Custom agent avatars and generated gloopies now appear consistently throughout chat, just like default avatars.
Problem: Chat’s small avatar surfaces only looked for static catalog images, so generated and other cached custom avatars often fell back to generic agent icons. This made the selected agent’s identity disappear in messages, chips, pickers, and mention results.
Solution: Introduce one shared avatar renderer that prefers static images but falls back to cached poster or media representations. Use that renderer across every chat identity surface so default and custom avatars follow the same presentation path.
Changes
File changes
src/shared/ui/avatar-visual.tsx
Adds the shared avatar presentation component that resolves catalog images, cached posters, animated media, and caller-provided fallbacks in a consistent order.
src/shared/ui/avatar-visual.test.tsx
Covers default catalog avatars, custom poster-backed avatars, image-only custom avatars, and unavailable-media fallbacks.
src/features/chat/ui/ConversationEmptyAvatar.tsx
Uses the shared renderer for the large empty-conversation avatar while preserving the deterministic default fallback.
src/features/chat/ui/MessageBubble.tsx
Displays custom avatars and gloopies in assistant message gutters and inline assistant identity chrome.
src/features/chat/ui/MessageMetadataChip.tsx
Displays custom avatars in agent chips attached to sent messages.
src/features/chat/ui/PersonaPicker.tsx
Displays custom avatars in the selected-agent trigger, composer chip, and persona menu.
src/features/chat/ui/MentionAutocomplete.tsx
Displays custom avatars in agent mention search results.
src/features/chat/ui/tests/ConversationEmptyAvatar.test.tsx
Adds regression coverage for cached custom media in the fresh-chat avatar.
src/features/chat/ui/tests/MessageBubble.test.tsx
Adds regression coverage for generated gloopies in assistant message gutters.
src/features/design-system/generated/componentManifest.ts
Registers the new shared avatar renderer in the generated design-system inventory.
Reproduction Steps
@and confirm the same avatar appears beside the agent in mention autocomplete.Screenshots/Demos
Manually verified in the dev app with a custom generated gloopie across the composer and chat transcript surfaces.