-
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
Register new variation for social link does not work #34559
Comments
@mkkeck The It looks like the icons shown in the editor are currently hard-coded: gutenberg/packages/block-library/src/social-link/variations.js Lines 4 to 47 in 44d1d32
So I don't think this is extensible. The only option is to completely replace the block's editor functionality. I see there's an existing issue (#19041) about extensibility, it's been open a while, but I'll leave a comment there mentioning your issue and will close this as a duplicate. |
Okay, that would not a problem to me patch the variations to display the correct icon in the backend, when I try to extend the variations json. But on the front end pages the new added icon is still not shown, instead the share icon is displayed. What I've done to get it work:
This is hell, I know. Suggestion:
|
@mkkeck Yes, you're right that the PHP rendering code is also hard-coded and uses an icon defined there, it seems like it needs to be replaced entirely.
I'm an atheist so I don't believe in that. 😄
This issue is closed, I think it'd be good to leave comments on #19041 as comments here are unlikely to be seen by anyone other than me. I notice there is also a pull request that seeks to resolve this - #30749, it seems like some progress was made there, but still a bit to do. |
Description
I have following code:
Step-by-step reproduction instructions
Screenshots, screen recording, code snippet
Environment info
Wordpres 5.8
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
The text was updated successfully, but these errors were encountered: