-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Add the ability to add a link to the logo block #56820
Comments
Perhaps, though my hesitation is that this makes it confusing for most users — even if the URL control is only added when the link toggle is disabled.
Why not add your site icon (i.e. favicon) then replace the site logo block with an image/link of your choice? |
I would say the link to homepage toggle has been used as a quick fix. As far as I’m aware this format isn’t consistent with any other blocks. We already have an excellent linking system which supports internal and external links. These are also used on image blocks. I’m not sure why this wouldn’t be added to the logo block. You have correctly identified a temporary solution for this issue but I don’t believe that should be the recommend approach. |
Because site logos link to the homepage on nearly every website. :) |
That’s an easy perspective to have now WordPress has fully fledged page builder. But WordPress (the blogging platform) has also commonly be used for micro sites. Such as blogs, events, job boards, recipe sites, small WooCommerce sites, running on sub-domains. I do agree with your point I just don’t know why you would purposely limit functionality, and not follow an already established design pattern. Would be interested to hear alternative perspectives on this topic. |
Just to be clear, I'm not entirely opposed to this—I'm just keeping in mind the additional complexity it introduces by showing/hiding an alternate control for the link. There's weight to consider if the majority of users would not necessarily benefit from an additional control, or feature.
Agreed! @WordPress/gutenberg-design thoughts? |
Brainstorming... The current Site Logo controls are very constrained compared to other blocks. We can compare the Image block and the Site Logo block. Look at controls of the Image block in comparison with the Site Logo block. Image block has a much wider toolbar compared to the Site Logo block. The Site Logo is usually fairly small and having a smaller toolbar helps because of the small space it is in. But should it have a Replace button, an alignment option and a link option added to the toolbar? Now in the Site Logo block. There is a toggle "Link image to home" Toggling this off could add a field to where one can add a custom link or leave blank for no link. Toggling image to not link to home could add the option to link to another location. Not filling in a custom link would then not link the Site Logo to go anywhere. Btw Rich @richtabor |
I'll echo Rich, that having the site logo's link be defined by the values set in Reading Settings in WordPress is likely going to be the most predictable user experience, and avoid complexity. Though I want to also say, we could come back to this at a later time, for example once reading settings get revisited. That might be a better place to explore a holistic solution to this. Because keep in mind, there's not just the site logo block, there's also a "Home Link" in the navigation block. So changing what is defined as a "homepage" is risky to do on a per-block basis, it can easily get out of sync and confusing. In the mean time, I'd echo the idea that an image with an aspect ratio applied can be a good solution, just like a custom "Home" link in navigation would. |
I wonder if the Image block could entertain refs in the future. So you could tell an Image block to use the site logo, similar to how the Cover block can reference the featured image. |
Personally I see a lot of value in keeping the logo block separate. It adds a lot of future-proofing, knowing you can use this to return the site logo. I’d also say as much as I’d like the logo to support a custom link I think it’s important to keep the UX as familiar as possible. I’m not sure an additional input field for the link based on the toggle status is correct. Personally I’d have the logo block by default always link to the site homepage. But add the link to the logo block toolbar so it can be changed or completely removed if required. |
I meant in addition to, not instead of :) |
I would like to just update this thread to mention that its not possible to include an image inside the navigation block. The impact of this decision means that you can't display the logo (image) on the mobile menu overlay without custom code. Regardless of the discussion surrounding if you should be able to add a custom link to the site logo the proposed intermediary solution isn't viable. |
I'd just like to update this thread to keep it maintained with WordPress releases. The Site logo still offers a site icon option which is now covered under Settings > General. Potentially making this option redundant. I'd also note using an Image instead of the site logo means the image doesn't render on the mobile menu, meaning you have no logo when the mobile menu is open/active. |
It's the same option that powers both. If you change the site logo in general settings, it is reflected in the site logo block (and vise-versa). |
What problem does this address?
It's currently not possible to link the site logo anywhere other than homepage. If you build a website on a sub-domain e.g. blog.site-name.com it's not possible to link back to the parent website. This renders the logo block useless and instead requires an image block which won't add favicon support.
What is your proposed solution?
Add the ability to add a free text URL link to the site logo block if the "Link image to home" toggle is not enabled.
The text was updated successfully, but these errors were encountered: