-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Avatar block: error on loading if Avatars are disabled on Settings #41577
Conversation
Size Change: +4 B (0%) Total Size: 1.24 MB
ℹ️ View Unchanged
|
Can we add a warning, for consistency with what we're doing in the Post Comments block (and in some Comments blocks)? FWIW, I've recently discussed this subject with @jameskoster, and we kind of settled on warnings after all. |
Hi @ockham , I'm going to move the warning to a new issue/PR, as will need some design feedback. As we can have Avatars anywhere on the site, the warning does not fit in all places (like the header, each comment, etc) |
Let's do that experiment in another PR, so we can fix this error in the next minor. Closing this PR as it will be fixed in #41354 |
What?
Fixes #41308
Closes #41313
Closes #41354
Why?
Right now, if Avatars are disabled on settings and we try to add it as a block, we got an error:
How?
Maybe it would be a good idea to make this block conditional if Avatar is disabled, or add a warning. But in this PR, we are just avoiding the JS error (the avatar will load the default one on the editor, and not in the frontend if they are disabled, causing some inconsistency between them).
We can maybe address it in another PR after some design feedback:
cc @javierarce , @richtabor, @estelaris
Testing Instructions
In trunk:
1.) Disable avatars on settings.
2.) Add Avatar block.
3.) Check the crash
After the fix:
1.) Disable avatars on settings.
2.) Add Avatar block.
3.) Avatar is displayed on the editor, not in the frontend.
Screenshots or screencast