Repository navigation
[CP Staging] Fix Season F1 custom avatars rendering partially black in Share QR code - #96324
Conversation
The QR library's LogoSVG always spreads its fill prop onto the SVG logo
component. When no logo color is provided, fill={undefined} erases root
attributes like fill="none", so avatars with stroke-only paths (the
Season F1 custom avatars) fall back to SVG's default black fill.
Wrap catalog-backed avatar logos so fill is only forwarded when set.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
@bernhardoj Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
The QR logo wrapper only forwards an explicitly set fill so stroke-only avatar SVGs keep their fill="none" root attribute; cover both fill branches and the URL fallback for non-catalog avatars. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
🚧 roryabraham has triggered a test Expensify/App build. You can view the workflow run here. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
…black-fill Fix Season F1 custom avatars rendering partially black in Share QR code (cherry picked from commit 5b36cf8) (cherry-picked to staging by roryabraham)
…black-fill Fix Season F1 custom avatars rendering partially black in Share QR code (cherry picked from commit 5b36cf8) (cherry-picked to staging by roryabraham)
…520108581-1 🍒 Cherry pick PR #96324 to staging 🍒
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.4.35-6 🚀
|
|
🤖 I reviewed the changes in this PR against the help site articles under No help site changes are required. This PR is a visual bug fix: catalog-backed avatars (Season F1 custom, numbered default, and Agent avatars) were rendering partially black in the center of the Share QR code because the QR library spread an The change is scoped to Since no changes are needed, I have not created a draft help site PR. @NicolasBonet, please review the linked help site PR and confirm it reflects the current behavior. Then mark the linked help site PR |
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.4.36-0 🚀
|
|
🚀 Deployed to production by https://github.com/jasperhuangg in version: 9.4.35-6 🚀
|
Help site review: no changes requiredI reviewed the changes in this PR and no updates to the help site files under Why: This PR is a purely internal rendering bug fix. It wraps the profile QR logo in a small wrapper component (
I checked the help articles that reference QR codes (workspace join flows, Two-Factor Authentication, etc.) and none of them document avatar appearance inside the Share QR code, so nothing there is now inaccurate. @NicolasBonet, since no help site PR was created, please confirm you agree that this rendering fix doesn't require any |
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.4.38-0 🚀
|
|
🤖 Help site review: no changes required I reviewed the changes in this PR against Expensify's help site files under Why: This is a purely visual bug fix. It changes how the QR-code library forwards the The help articles that mention the Share/QR code feature (e.g. Because no changes are required, I did not create a draft help site PR. @NicolasBonet, if you believe a documented behavior actually did change and a docs update is warranted, let me know and I'll draft the PR. |
|
🚀 Cherry-picked to staging by https://github.com/roryabraham in version: 9.4.40-0 🚀
|
|
🤖 No help site changes required. I reviewed the changes in this PR and confirmed no updates are needed to the help site files under Why: This is a purely visual bug fix. It restores correct color rendering of catalog-backed avatars (Season F1 custom, numbered default, and Agent avatars) in the center of the Share QR code by only forwarding the There is no change to any user-facing feature, workflow, setting label, button, or documented behavior. The QR code and avatar sharing behavior is unchanged from the user's perspective — it simply renders correctly again. The existing help articles that mention QR codes (e.g. workspace join flows) and profile photos/avatars don't document the internal rendering of an avatar inside a QR code, so there's nothing to add or correct. Since no documentation changes are warranted, I did not create a draft PR. @NicolasBonet, please review the linked help site PR and confirm it reflects the current behavior. Then mark the linked help site PR |
|
🚀 Deployed to production by https://github.com/yuwenmemon in version: 9.4.40-0 🚀
Bundle Size Analysis (Sentry): |

Explanation of Change
After #96112, catalog-backed avatars (agent, default user, and Season F1 custom avatars) render in the center of the Share QR code from their bundled local SVG via the
svgLogoprop.react-native-qrcode-svg'sLogoSVGalways spreads itsfillprop onto that component — even when it'sundefined. Spreadingfill={undefined}onto the SVG root erases root attributes likefill="none".The Season F1 custom avatars rely on that root
fill="none": they contain stroke-only paths with no explicit fill of their own. With the attribute erased, those paths fall back to SVG's default fill (black), which made those avatars render partially black in the QR code. Agent and numbered default avatars were unaffected because every one of their paths gets its fill from CSS classes.This change wraps the local avatar logo in a small module-level component that only forwards
fillwhen it's actually set. The wrapper is scoped toShareCodePage; the workspace share QR (which always providessvgLogoFillColor) and all other QR usages are untouched, and the offline behavior added by #96112 is preserved for all catalog avatars.Fixed Issues
$ #96254
Tests
Offline tests
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
MacOS: Chrome / Safari