Skip to content

Commit

Permalink
Issue #288 Add tests for adding the data-locale attribute for Faceboo…
Browse files Browse the repository at this point in the history
…k posts
  • Loading branch information
m4olivei committed Sep 24, 2021
1 parent 63f5a85 commit c249dc5
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,13 @@
class="fb-xfbml-parse-ignore">Posted by <a href="https://www.facebook.com/zuck">Mark Zuckerberg</a> on&nbsp;<a
href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3">Wednesday,
September 14, 2011</a></blockquote>
</div>

<div class="fb-post"
data-href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3"
data-width="500" data-show-text="true" data-locale="en">
<blockquote cite="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3"
class="fb-xfbml-parse-ignore">Posted by <a href="https://www.facebook.com/zuck">Mark Zuckerberg</a> on&nbsp;<a
href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3">Wednesday,
September 14, 2011</a></blockquote>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

<amp-facebook layout="responsive" data-href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3" data-embed-as="post" height="366" width="500"></amp-facebook>

<amp-facebook layout="responsive" data-href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3" data-embed-as="post" height="366" width="500" data-locale="en"></amp-facebook>

ORIGINAL HTML
---------------
Line 1: <div id="fb-root"></div>
Expand Down Expand Up @@ -64,6 +66,15 @@ Line 48: class="fb-xfbml-parse-ignore">Posted by <a href="https:
Line 49: href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3">Wednesday,
Line 50: September 14, 2011</a></blockquote>
Line 51: </div>
Line 52:
Line 53: <div class="fb-post"
Line 54: data-href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3"
Line 55: data-width="500" data-show-text="true" data-locale="en">
Line 56: <blockquote cite="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3"
Line 57: class="fb-xfbml-parse-ignore">Posted by <a href="https://www.facebook.com/zuck">Mark Zuckerberg</a> on&nbsp;<a
Line 58: href="https://www.facebook.com/photo.php?fbid=986393557241&amp;set=a.941146602501.2418915.4&amp;type=3">Wednesday,
Line 59: September 14, 2011</a></blockquote>
Line 60: </div>


Transformations made from HTML tags to AMP custom tags
Expand All @@ -87,6 +98,9 @@ Transformations made from HTML tags to AMP custom tags
<div class="fb-post" data-href="https://www.facebook.com/photo.php?fbid=986393557241&set=a.941146602501.2418915.4&type=3" data-width="500" data-show-text="true"> at line 46
ACTION TAKEN: div.fb-post facebook javascript sdk embed code was converted to the amp-facebook tag.

<div class="fb-post" data-href="https://www.facebook.com/photo.php?fbid=986393557241&set=a.941146602501.2418915.4&type=3" data-width="500" data-show-text="true" data-locale="en"> at line 55
ACTION TAKEN: div.fb-post facebook javascript sdk embed code was converted to the amp-facebook tag.


AMP-HTML Validation Issues and Fixes
-------------------------------------
Expand Down

0 comments on commit c249dc5

Please sign in to comment.