Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<StorageImage /> always displays alt text and loading failure status first! #6254

Open
4 tasks done
xunziheng opened this issue Dec 14, 2024 · 0 comments
Open
4 tasks done
Labels
pending-maintainer-response Issue is pending response from an Amplify UI maintainer pending-triage Issue is pending triage

Comments

@xunziheng
Copy link

Before creating a new issue, please confirm:

On which framework/platform are you having an issue?

React

Which UI component?

Storage

How is your app built?

webpack

What browsers are you seeing the problem on?

Chrome

Which region are you seeing the problem in?

EU

Please describe your bug.

I am using StorageImage component in my project like this <StorageImage alt='logo' path={logoImageKey} />

When I load this page, I will see alt text and broken image first,then see the truly image I have setup.

I observed the data in the network and found that when the image request has not yet returned, the alt text is displayed instead of loading or blank. that is weird.

image

What's the expected behaviour?

show loading or blank instead of alt before image request return.

Help us reproduce the bug!

<StorageImage alt='logo' path={logoImageKey} />

set network to slow 3G

Code Snippet

// Put your code below this line.
<StorageImage alt='logo' path={logoImageKey} />

Console log output

No response

Additional information and screenshots

No response

@github-actions github-actions bot added pending-triage Issue is pending triage pending-maintainer-response Issue is pending response from an Amplify UI maintainer labels Dec 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending-maintainer-response Issue is pending response from an Amplify UI maintainer pending-triage Issue is pending triage
Projects
None yet
Development

No branches or pull requests

1 participant