Page MenuHomePhabricator

Proper collection sharing format/content
Closed, ResolvedPublic3 Estimated Story Points

Description

When a user shares a collection via FB or twitter, the following is true:

  • image is the lead image for the collection
  • Title of share is title of collection
  • Content of share is author of collection and description of collection

Avoid using non-standard tags where possible or introduce configuration variable to control the tags we use.

Event Timeline

JKatzWMF raised the priority of this task from to Needs Triage.
JKatzWMF updated the task description. (Show Details)
JKatzWMF added a project: Gather.

Take a look at microformats.org

Change 200745 had a related patch set uploaded (by Jdlrobson):
Fix meta tags for collections

https://gerrit.wikimedia.org/r/200745

Patch covers description and title. To get a nice image showing up though we will have to do one of two things

  1. Add the image for collection at the top of the page. It can be hidden if necessary.
  2. Switch from our use of background images to actual images - position images inside a div with overflow hidden to control positioning.
  3. Use og tags (I'd prefer not to)

You can test here https://developers.facebook.com/tools/debug/og/object/

I'm leaning towards 2

Change 200754 had a related patch set uploaded (by Jdlrobson):
Use images rather than background-image for page images in collection

https://gerrit.wikimedia.org/r/200754

Change 200745 merged by jenkins-bot:
Fix meta tags for collections

https://gerrit.wikimedia.org/r/200745

@Jhernandez since you know the most about the image handling feel free to take over ownership of this bug and look at https://gerrit.wikimedia.org/r/200754

Plz review

(PS3) Jhernandez: Include collection image in html for sharing [extensions/Gather] - https://gerrit.wikimedia.org/r/200754 (https://phabricator.wikimedia.org/T91696) (owner: Jdlrobson)

Workz fine with facebook, but a pain to test because of what I've commented on the commit message. This just adds a hidden image in the html for the scrappers to pick up.

So I did a bit more research and hidden image only works for Facebook... There is an interesting thread on wikitech about exposing og:image meta tag ...

Change 202250 had a related patch set uploaded (by Jdlrobson):
Add ogimage tag

https://gerrit.wikimedia.org/r/202250

Change 200754 abandoned by Jdlrobson:
Include collection image in html for sharing

Reason:
no longer needed

https://gerrit.wikimedia.org/r/200754

@Jdlrobson, looks good on FB. this still doesn't work on twitter