<p><strong>Reason:</strong><br>
Changeset, relation, way and node pages are regularly shared on IM and social media channels to discuss, promote or brag about OSM contributions. Right now all of these pages use the same variable "layouts.intro_text" for the OpenGraph description meta tag og:description which is just a general OSM project description: <em>OpenStreetMap is a map of the world, created by people like you and free to use under an open licence.</em><br>
See example rich preview for a changeset (and card rendering preview for IM and social media types): <a href="https://richpreview.com/?url=https%3A%2F%2Fwww.openstreetmap.org%2Frelation%2F36970" rel="nofollow">https://richpreview.com/?url=https%3A%2F%2Fwww.openstreetmap.org%2Frelation%2F36970</a><br>
Some prerequisites/observations:</p>
<ul>
<li>Page type and IDs/names are already represented in the page title.</li>
<li>Rich previews work best for descriptions below 50 characters.</li>
<li>The relating code currently resides in <a href="https://github.com/openstreetmap/openstreetmap-website/blob/1285bcbd712044720c15e2de2e6bacaf4b0b0a92/app/helpers/open_graph_helper.rb#L10">openstreetmap-website/app/helpers/open_graph_helper.rb</a></li>
</ul>
<p><strong>Proposal:</strong><br>
Description field should describe/represent the page's content.<br>
Change og:description for detail page types on openstreetmap.org:</p>
<ul>
<li>Changeset: <em><changeset_description_cropped_to_50_characters> by <osm_username> on <changeset_timestamp></em></li>
<li>Relation: <em><relation_name> - <member_count> members - Last changed: <last_updated_timestamp></em> (If relation doesn't have a name use type instead for <relation_name>)</li>
<li>Way: <em><way_name> - <node_count> nodes - Last changed: <last_updated_timestamp></em> (If way doesn't have a name either omit completely or alternatively show key:value for popular top level keys, like highway=<em>, amenity=</em>, waterway=*)</li>
<li>Node: <em><node_name> - Location: - Last changed: <last_updated_timestamp></em> (Same comment as for way names should apply here as well)</li>
<li>User: <em><changeset_count> changes, last <last_changeset_timestamp> - <track_count> tracks - <blog_count> blogs</em></li>
</ul>
<p>NB: The OpenGraph description should remain as is (layouts.intro_text) for all other pages</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/issues/2007">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABWnLb17uTx7K2Yu98-z7Ktb2sXhz-M3ks5uf84_gaJpZM4XAqJW">mute the thread</a>.<img src="https://github.com/notifications/beacon/ABWnLQ2r2sgYJ360u4CU9nYX7A3I-Xneks5uf84_gaJpZM4XAqJW.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/openstreetmap/openstreetmap-website","title":"openstreetmap/openstreetmap-website","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/openstreetmap/openstreetmap-website"}},"updates":{"snippets":[{"icon":"DESCRIPTION","message":"Enhance opengraph rich preview for changeset, relation, way, node, user pages (#2007)"}],"action":{"name":"View Issue","url":"https://github.com/openstreetmap/openstreetmap-website/issues/2007"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/issues/2007",
"url": "https://github.com/openstreetmap/openstreetmap-website/issues/2007",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "Enhance opengraph rich preview for changeset, relation, way, node, user pages (#2007)",
"sections": [
{
"text": "",
"activityTitle": "**Claudius**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@claudiush",
"facts": [
{
"name": "Repository: ",
"value": "openstreetmap/openstreetmap-website"
},
{
"name": "Issue #: ",
"value": 2007
}
]
}
],
"potentialAction": [
{
"name": "Add a comment",
"@type": "ActionCard",
"inputs": [
{
"isMultiLine": true,
"@type": "TextInput",
"id": "IssueComment",
"isRequired": false
}
],
"actions": [
{
"name": "Comment",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueComment\",\n\"repositoryFullName\": \"openstreetmap/openstreetmap-website\",\n\"issueId\": 2007,\n\"IssueComment\": \"{{IssueComment.value}}\"\n}"
}
]
},
{
"name": "Close issue",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueClose\",\n\"repositoryFullName\": \"openstreetmap/openstreetmap-website\",\n\"issueId\": 2007\n}"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/openstreetmap/openstreetmap-website/issues/2007"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 386048598\n}"
}
],
"themeColor": "26292E"
}
]</script>