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

There is no Replace button in Site logo block #39913

Closed
SergeGusev opened this issue Mar 30, 2022 · 10 comments
Closed

There is no Replace button in Site logo block #39913

SergeGusev opened this issue Mar 30, 2022 · 10 comments
Labels
[Block] Site Logo Affects the Site Logo Block [Status] Needs More Info Follow-up required in order to be actionable. [Type] Bug An existing feature does not function as intended

Comments

@SergeGusev
Copy link

SergeGusev commented Mar 30, 2022

Description

I cannot upload or change the site logo in the Site Logo block, because there is no Replace button in the block's attributes. But I'm able to do it on an Image block - it has Replace button and allows me to select an image from Media library or disk.

Step-by-step reproduction instructions

1, Install new WP 5.9.2
2. Set TwentyTwentyTwo theme as Active.
3. Press Customize button.
4. In the Site Editor select the current Site logo component. In the block attributes panel there is no Replace button.

My video with all steps a available below.

Screenshots, screen recording, code snippet

https://drive.google.com/file/d/1mcBkPSH43z_a9g6qGzlOVRaBOy1VuO3N/view?usp=sharing

Environment info

WordPress 5.9.2 - clear, no plugins
Theme - TwentyTwentyTwo, block theme.
OS - Windows 10.
Chrome
IIS

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@Mamaduka Mamaduka added the [Block] Site Logo Affects the Site Logo Block label Mar 30, 2022
@AdsonCicilioti
Copy link

Hi @SergeGusev,

Had the same problem at #39776 .

It seems to be something related to your environment, as it was in my case, but I don't know if it's the same cause.

What does the browser console show?

@SergeGusev
Copy link
Author

The console shows a lot of rows like Updated block core/spacer with content:

Block successfully updated for `core/spacer` (Object).

New content generated by `save` function:

<div style="height:50px" aria-hidden="true" class="wp-block-spacer"></div>

Content retrieved from post body:

<div style="height:50px" aria-hidden="true" class="wp-block-spacer"></div>

No red errors, info only

@SergeGusev
Copy link
Author

image

My Chrome console.

@ntsekouras
Copy link
Contributor

ntsekouras commented Apr 11, 2022

👋 - in order for the Replace functionality to be shown, the user need to have the right permissions. I could see from the code also that if for any reason you cannot fetch the logo from the REST API, it won't be shown too. This is related to @AdsonCicilioti 's comment:

It seems to be something related to your environment, as it was in my case,

Regarding the logs, they are not related at all, as they are migration logs for available patterns that are pre-parsed.

@SergeGusev
Copy link
Author

ntsekouras, thank you, looks like you are correct. When I try to execute the site unders IIS, I have the described problem. But when I'm working with Build-in local server, I can see Upload button and Replace button.

I'm sure my wp-content folder has enough permissions. But maybe Gutenberg works with another folder? Where can I find/set this option to check necessary permissions?

@ntsekouras
Copy link
Contributor

ntsekouras commented Apr 12, 2022

But maybe Gutenberg works with another folder? Where can I find/set this option to check necessary permissions?

Oh.. I linked something wrong in my previous comment 😄 . The place we check permissions is here:https://github.com/WordPress/gutenberg/blob/trunk/packages/block-library/src/site-logo/edit.js#L380.

It's not about directory permissions, but it's about user permissions.

@SergeGusev
Copy link
Author

It's not about directory permissions, but it's about user permissions.

It is interesting, because I work with the same user on the same computer with the same site and the same database, I'm sure. The only difference - using IIS or Build-in server. This is video - first half of them I work with Build-in server (and the buttons do exist), then I work with IIS and there are no buttons.

https://drive.google.com/file/d/1XejPKunXhPyT15GoGZmqIHhCOAHDbpxI/view?usp=sharing

@websupergirl
Copy link

My Chrome console.

@SergeGusev did you figure out why you were getting a whole bunch of block updated messages? I am having the same issue trying to go from wp 5.8->5.9 on another site and there doesn't seem to be much info on this "Updated Block" situation.

@jordesign
Copy link
Contributor

Testing in WP6.3 I now see a 'replace' button consistently. @SergeGusev @websupergirl do either of you still see this error occuring?

@jordesign jordesign added [Type] Bug An existing feature does not function as intended [Status] Needs More Info Follow-up required in order to be actionable. labels Sep 14, 2023
@jordesign
Copy link
Contributor

This seems resolved, and with no further reports I'll close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Site Logo Affects the Site Logo Block [Status] Needs More Info Follow-up required in order to be actionable. [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

6 participants