Skip to content

Commit

Permalink
Update 1.1 embed code samples
Browse files Browse the repository at this point in the history
  • Loading branch information
reefdog committed Nov 4, 2016
1 parent 9143025 commit efe1da7
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 6 deletions.
2 changes: 1 addition & 1 deletion test/v1.1-async/_embed_code.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div id="DC-note-42283" class="DC-note-container"></div>
<div id="DC-note-42283" class="DC-embed DC-embed-note DC-note-container"></div>
<script src="//notes-assets.dcloud.org/test/v1.1-async/loader.js"></script>
<script>
dc.embed.loadNote('https://www.documentcloud.org/documents/282753-lefler-thesis/annotations/42283.js', {
Expand Down
11 changes: 10 additions & 1 deletion test/v1.1-async/_oembed_code.json
Original file line number Diff line number Diff line change
@@ -1 +1,10 @@
{"type":"rich","version":"1.0","provider_name":"DocumentCloud","provider_url":"https://www.documentcloud.org","cache_age":300,"height":null,"width":null,"html":"\u003cdiv id=\"DC-note-80993\" class=\"DC-note-container\"\u003e\u003c/div\u003e\u003cscript src=\"http://notes-assets.dcloud.org/test/v1.1-async/loader.js\"\u003e\u003c/script\u003e\u003cscript\u003edc.embed.loadNote('https://www.documentcloud.org/documents/282753-lefler-thesis/annotations/80993.js', {container: '#DC-note-80993'});\u003c/script\u003e"}
{
"type": "rich",
"version": "1.0",
"provider_name": "DocumentCloud",
"provider_url": "https://www.documentcloud.org",
"cache_age": 300,
"height": null,
"width": null,
"html": "<link rel=\"stylesheet\" href=\"//assets.documentcloud.org/note_embed/note_embed.css\" type=\"text/css\"> <div class=\"DC-embed DC-embed-note DC-note-container\"> <div class=\"DC-note\" style=\"background-image:url('https://assets.documentcloud.org/documents/282753/pages/lefler-thesis-p13-normal.gif')\"> <div class=\"DC-note-header\"> <a class=\"DC-note-embed-resource\" title=\"View the note “Test Note” in its original document context on DocumentCloud in a new window or tab\" target=\"_blank\" href=\"https://www.documentcloud.org/documents/282753-lefler-thesis.html#document/p13/a80993\"><span class=\"DC-note-title\">Test Note</span> <span class=\"DC-note-page-number\">(p. 13)</span></a> </div> <div class=\"DC-note-image-max-bounds\" style=\"max-height:324px;max-width:560px;\"> <div class=\"DC-note-image-aspect-ratio\" style=\"padding-bottom:57.857142857142854%;\"> <iframe class=\"DC-note-image-space-filler\" src=\"https://www.documentcloud.org/documents/282753-lefler-thesis/annotations/80993.html?embed=true\" title=\"Note “Test Note” on document “Lefler Thesis”\" sandbox=\"allow-scripts allow-same-origin allow-popups\" frameborder=\"0\"></iframe> </div> </div> <div class=\"DC-note-body\"></div> <div class=\"DC-note-credit\"> <a title=\"View the note “Test Note” in its original document context on DocumentCloud in a new window or tab\" target=\"_blank\" href=\"https://www.documentcloud.org/documents/282753-lefler-thesis.html#document/p13/a80993\">View entire document on <span class='DC-note-logotype-link'>DocumentCloud</span></a> </div> <div class=\"DC-note-background-fader\"></div> </div> </div>"
}
6 changes: 3 additions & 3 deletions test/v1.1-async/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ <h1>DocumentCloud Note Embed Test</h1>
<h3 class="h5">Default:</h3>
<div class="row">
<div class="col-md-6 col-xs-12">
<div id="DC-note-42282" class="DC-note-container"></div>
<div id="DC-note-42282" class="DC-embed DC-embed-note DC-note-container"></div>
<script src="/test/v1.1-async/loader.js"></script>
<script>
dc.embed.loadNote('https://www.documentcloud.org:443/documents/282753-lefler-thesis/annotations/42282.js', {
Expand All @@ -56,7 +56,7 @@ <h3 class="h5">Default:</h3>
<h3 class="h5">With non-default <code>container</code>:</h3>
<div class="row">
<div class="col-md-6 col-xs-12">
<div id="DC-note-asdf" class="DC-note-container"></div>
<div id="DC-note-asdf" class="DC-embed DC-embed-note DC-note-container"></div>
<script src="/test/v1.1-async/loader.js"></script>
<script>
dc.embed.loadNote('https://www.documentcloud.org:443/documents/282753-lefler-thesis/annotations/42281.js', {
Expand All @@ -82,7 +82,7 @@ <h3 class="h5">With non-default <code>container</code>:</h3>
<h3 class="h5">With matching <code>div</code> but no <code>container</code> option:</h3>
<div class="row">
<div class="col-md-6 col-xs-12">
<div id="DC-note-99206" class="DC-note-container"></div>
<div id="DC-note-99206" class="DC-embed DC-embed-note DC-note-container"></div>
<script src="/test/v1.1-async/loader.js"></script>
<script>
dc.embed.loadNote('https://www.documentcloud.org:443/documents/282753-lefler-thesis/annotations/99206.js');
Expand Down
2 changes: 1 addition & 1 deletion test/v1.1-async/pjax_content.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div id="DC-note-42273" class="DC-note-container"></div>
<div id="DC-note-42273" class="DC-embed DC-embed-note DC-note-container"></div>
<script src="//notes-assets.dcloud.org/test/v1.1-async/loader.js"></script>
<script>
dc.embed.loadNote('https://www.documentcloud.org:443/documents/282753-lefler-thesis/annotations/42273.js', {
Expand Down

0 comments on commit efe1da7

Please sign in to comment.