Open
Description
The Jetpack plugin currently ships with 3 versions of elements of https://github.com/Automattic/social-logos :
- One is added as a npm dependency: it is used in our React-powered interfaces (Jetpack Dashboard > SEO Tools / the post editor)
jetpack/projects/plugins/jetpack/package.json
Line 103 in eb5dc63
- The other is a direct copy of the icon font only:
- The third one is a copy of the SVG sprite, used for both the Social Icons Widget and the Social Menus theme tool: https://github.com/Automattic/jetpack/blob/eb5dc637d0bec1cd195ea99171e309de2d6398a5/projects/plugins/jetpack/modules/theme-tools/social-menu/social-menu.svg
While this works today, it has a few inconvenients:
- This complexity makes adding a new logo a multi-step process: add the logo in the source repo, release a new version of the package, start using the package in the Jetpack plugin, update the SVG sprite in the Jetpack plugin, update the icon font in the Jetpack plugin. This, of course, assuming the source repo tooling works in our favor (right now it doesn't, due to https://github.com/Automattic/social-logos/issues/116 )
- The icon font is problematic for display, and can cause issues in some scenarios: Shorten font url for "social-logos" font family. Causes 414 errors on some hosts. #6076, Social Logos CSS Not Optimized #13201, and Sharing: issues decoding Social Logos font on pages including sharing buttons #7148 are good examples.
- Relying on the SVG sprite in the Social Menu outputs all the SVGs on sites that may only need to display a few: Social Icons Widget / Social Menu Theme Tool: include only SVGs needed #16673
As part of #27817, maybe we could switch all our implementations to one single npm dependency and single SVGs that would be used when necessary. cc @davemart-in
Issues that could be closed if this were addressed:
Metadata
Metadata
Assignees
Labels
React-powered dashboard under the Jetpack menuFormerly "Primary Issue", or "Master Issue"Post sharing, sharing buttonsIssues related to the block editor, aka Gutenberg, and its extensions developed in JetpackIssues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/Issues about the Jetpack Social pluginChanges to an existing feature — removing, adding, or changing parts of it
Activity