-
I am attempting (and mostly succeeding) to add a couple of custom Follow Buttons to the footer in the default Simple theme. The changes I have made to config.json and footer.hbs have resulted in the follow buttons I want appearing in Theme Settings. The published site also has links in the footer that are correct so I feel like those changes are solid. The problem I am having is that one of the follow buttons (Mastodon) displays an icon in the footer, but the other (RSS) does not display an icon. So I'm thinking the changes I've made to either or both svg-map.svg and svg-map.js have a defect. To be clear I have absolutely no clue about either of these files, I'm just copying sections above and changing the values that look like they need changing. So I'm probably just doing something dumb. Id appreciate anyone who is able to point out my stupidity. These are the additions I've made to svg-map.svg in the overrides folder.
These are the additions I've made to svg-map.js in the overrides folder
The svg path details for both icons were derived in the same manner; Loading an icon file into Inkscape and consolidating it to a single object and then cutting and pasting the path data from the resulting svg file opened in a text editor. I have two trains of thought. One is there is a bleedingly obvious syntax error in one or both of the above that my ignorance renders invisible to me. Or, the process of generating the svg data worked for the mastodon icon but not for the RSS icon. If any of you tremendous people can assist I'd appreciate it. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
Do you have a live link that you could share so that we can inspect the file? Could even be a quick drop in Netlify or GitHub |
Beta Was this translation helpful? Give feedback.
-
Sure. The live site is here: Please let me know if there is anything else I can do to be useful. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
Mastodon icon
The viewBox is set to 32px, but the icon itself has different dimensions, around 16px. The viewBox should reflect the icon's actual size. Below, I've included the correct code for an icon size 32px.
Icon code:
<svg viewBox="0 0 32 32"><path d="M22,23.9c3.8-.5,7-2.8,7.4-4.9.6-3.3.6-8.1.6-8.1,0-6.5-4.3-8.4-4.3-8.4-2.2-1-5.8-1.4-9.7-1.4h0c-3.8,0-7.5.4-9.7,1.4,0,0-4.3,1.9-4.3,8.4v1.2c0,1.2,0,2.5,0,3.9.2,6.4,1.2,12.6,7.1,14.2,2.7.7,5,.9,6.9.8,3.4-.2,5.3-1.2,5.3-1.2v-2.5c-.1,0-2.5.8-5.3.7-2.7,0-5.6-.3-6-3.6,0-.3,0-.6,0-.9,0,0,2.7.6,6,.8,2.1,0,4-.1,6-.4h0ZM25,19.2h-3.1v-7.7c0-1.6-.7-2.4-2-2.4s-2.3,1-2.3,2.9v4.2h-3.1v-4.2c0-1.9-.8-2.9-2.3-2.9s-2,.8-2,2.4v7.6h-3.1v-7.9c0-1.6.4-2.9,1…