Skip to content

fix(simulation): scale token logo fallback and handle image load errors#86

Merged
Sednaoui merged 1 commit into
developfrom
fix/fallback-token-logo-load
May 18, 2026
Merged

fix(simulation): scale token logo fallback and handle image load errors#86
Sednaoui merged 1 commit into
developfrom
fix/fallback-token-logo-load

Conversation

@andrewwahid
Copy link
Copy Markdown
Member

@andrewwahid andrewwahid commented May 18, 2026

Summary by CodeRabbit

  • Bug Fixes
    • Improved fallback handling for token logo display when logos are unavailable or fail to load, ensuring consistent visual presentation across all scenarios.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 18, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e2903d99-8853-4c7e-8894-afa2c798c5de

📥 Commits

Reviewing files that changed from the base of the PR and between 196fa4f and 7ed8b9c.

📒 Files selected for processing (1)
  • lib/features/verify_safe_transaction/simulation/safe_tx_simulation_screen.dart

📝 Walkthrough

Walkthrough

Updated the _tokenLogo widget in the safe transaction simulation screen to improve error resilience. The change extracts a reusable fallback widget (grey "?" with scaled styling) that is now applied both when the logo URI is explicitly "unknown" and when network image loading fails via an errorBuilder callback.

Changes

Token Logo Fallback Handling

Layer / File(s) Summary
Token logo fallback widget
lib/features/verify_safe_transaction/simulation/safe_tx_simulation_screen.dart
_tokenLogo method now defines a shared fallback widget and uses it for both the "unknown" logo URI case and when Image.network fails to load, adding robust error handling via errorBuilder.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

  • candidelabs/safe-opensig#84: Both PRs modify the _tokenLogo behavior in safe_tx_simulation_screen.dart—this PR adds error handling and a shared fallback widget, while the other PR introduces or expands usage of the token logo placeholder in token detail and tappable UI components.

Poem

🐰 A logo fell into the net, a grey question mark rose instead,
Now reused, reliable, and shared—no fallback left unspread.
From "unknown" to error, one path appears so neat,
Making token screens resilient, the fix is sweet! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main changes: scaling the token logo fallback and adding image load error handling.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

@andrewwahid andrewwahid requested a review from Sednaoui May 18, 2026 13:22
@Sednaoui Sednaoui merged commit 25722f2 into develop May 18, 2026
1 check passed
@Sednaoui Sednaoui deleted the fix/fallback-token-logo-load branch May 18, 2026 13:23
@coderabbitai coderabbitai Bot mentioned this pull request May 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants