kylewm / redwind

Flask-based personal website #IndieWeb #OwnYourData
Other
45 stars 5 forks source link

better display for Bridgy responses that no longer have e-content #44

Open kylewm opened 9 years ago

kylewm commented 9 years ago

e.g.,

https://brid-gy.appspot.com/rsvp/facebook/12802152/1565113317092307/10101508925782433

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Bridgy Response</title>
<style type="text/css">
.u-uid { display: none; }
</style>
</head>
<article class="h-entry">
  <span class="u-uid">tag:facebook.com,2013:1565113317092307_rsvp_10101508925782433</span>

  <div class="p-name"><a class="u-url" href="https://www.facebook.com/1565113317092307#10101508925782433">invited</a></div>
  <div class="">
    <div class="h-card p-invitee">
    <div class="p-name"><a class="u-url" href="https://www.facebook.com/10101508925782433">Tantek Çelik</a></div>
    <img class="u-photo" src="https://graph.facebook.com/v2.2/10101508925782433/picture?type=large" alt="" />
  </div>

  </div>

  <a class="u-in-reply-to" href="https://indiewebcamp.com/events/2015-03-25-homebrew-website-club"></a>
  <a class="u-in-reply-to" href="https://kylewm.com/2015/03/homebrew-website-club-2015-march-25"></a>

</article>

</html>
kylewm commented 9 years ago

mf2 parses as

{
  "items": [
    {
      "type": [
        "h-entry"
      ],
      "properties": {
        "invitee": [
          {
            "type": [
              "h-card"
            ],
            "properties": {
              "name": [
                "Tantek \u00c7elik"
              ],
              "url": [
                "https:\/\/www.facebook.com\/10101508925782433"
              ],
              "photo": [
                "https:\/\/graph.facebook.com\/v2.2\/10101508925782433\/picture?type=large"
              ]
            },
            "value": "Tantek \u00c7elik"
          }
        ],
        "name": [
          "invited"
        ],
        "uid": [
          "tag:facebook.com,2013:1565113317092307_rsvp_10101508925782433"
        ],
        "url": [
          "https:\/\/www.facebook.com\/1565113317092307#10101508925782433"
        ],
        "in-reply-to": [
          "https:\/\/indiewebcamp.com\/events\/2015-03-25-homebrew-website-club",
          "https:\/\/kylewm.com\/2015\/03\/homebrew-website-club-2015-march-25"
        ]
      }
    }
  ],
  "rels": {

  }
}

mf2util parses as


  "in-reply-to": [
    "https://indiewebcamp.com/events/2015-03-25-homebrew-website-club",
    "https://kylewm.com/2015/03/homebrew-website-club-2015-march-25"
  ],
  "name": "invited",
  "syndication": [],
  "type": "entry",
  "url": "https://www.facebook.com/1565113317092307#10101508925782433"
}