[openstreetmap/openstreetmap-website] Remove logo from Open Graph previews (Issue #4073)
Minh Nguyễn
notifications at github.com
Wed Jun 28 01:07:26 UTC 2023
Every page has an [Open Graph preview](https://ogp.me/#metadata) that includes the OpenStreetMap logo as the `og:image`. Most sites set this meta tag to an image that represents the specific object, not the site as a whole. When a page-specific image is unavailable, they just omit the meta tag. OSM should also omit the `og:image` tag until we’re able to fill it in with something more meaningful for #2965.
I like the OSM logo. However, using it as the object’s image causes some Open Graph clients to display the OSM page less than ideally. Discourse and Slack already include the favicon automatically, making the image redundant. Slack displays the image at full size, dominating the preview as if it’s the most important element. (OSMUS Slack specifically disabled previews for anything on openstreetmap.org in 2016 because it got so obnoxious.)
It’s not at all uncommon for sites to omit `og:image` – the OSM Wiki omits it, for example. If we do need to keep the logo for branding reasons, can we at least shrink it to match a more typical size in link previews?
## Screenshots
[Open Graph Preview](https://www.opengraphpreview.xyz/open-graph/https%3A%2F%2Fwww.openstreetmap.org%2Fnode%2F3815077900) has mockups of more websites.
### Discord
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/a8664d9c-4f23-4a11-a8a8-778fe6903513" width="520" alt="Discord">
### Discourse
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/0d51b936-c3b8-4573-ab4d-89f072ed0e89" width="704" alt="Discourse">
### Facebook
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/b2874127-8006-4036-99a7-84b8ec72050d" width="500" alt="Facebook">
In some contexts, Facebook shows a variation of the preview that stretches the image to be as wide as the preview, which causes the logo to look quite blurry.
### Mastodon
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/fcd1eb2a-9db7-4dfa-94df-310390386e32" width="548" alt="Mastodon">
### Slack
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/6ceebc92-c36b-4123-8884-df018c1848b2" width="596" alt="Slack">
### Telegram
<img width="334" alt="Telegram" src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/fbf52b05-9ea3-4843-b554-b16b792bd83a">
### Twitter
<img src="https://github.com/openstreetmap/openstreetmap-website/assets/1231218/7f705460-4598-41fa-8933-abd34365580f" width="514" alt="Twitter">
## Implementation notes
This would be just a matter of removing these lines:
https://github.com/openstreetmap/openstreetmap-website/blob/466de96a91ece362400ec7ffe73ed243f9ce3067/app/helpers/open_graph_helper.rb#L7-L8
/ref #2007
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/4073
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/issues/4073 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20230627/08c21318/attachment.htm>
More information about the rails-dev
mailing list