summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Parecki <aaron@parecki.com>2017-03-18 17:26:12 +0000
committerAaron Parecki <aaron@parecki.com>2017-03-18 17:26:12 +0000
commit34afa1f5f220af14c055e5eb5e0844be0b5120aa (patch)
tree960c55e5f1a6cd8286aa89a04642c4c2c876b63c
parentdef648bba6307a2259bd41e1509731bdec1daf97 (diff)
add docs for favorites
-rw-r--r--controllers/static.php5
-rw-r--r--public/images/favorite-interface.jpgbin0 -> 33523 bytes
-rw-r--r--views/docs/creating-posts.php1
-rw-r--r--views/docs/favorite.php30
4 files changed, 34 insertions, 2 deletions
diff --git a/controllers/static.php b/controllers/static.php
index e2006af..9822d6b 100644
--- a/controllers/static.php
+++ b/controllers/static.php
@@ -5,8 +5,9 @@ function doc_pages($page=null) {
'signing-in' => 'Signing In',
'creating-posts' => 'Creating Posts',
'editor' => 'Rich Editor',
- 'note' => 'Note Interface',
- 'bookmark' => 'Bookmark Interface',
+ 'note' => 'Creating a Note',
+ 'bookmark' => 'Creating a Bookmark',
+ 'favorite' => 'Favoriting a Post',
'syndication' => 'Syndication',
'post-status' => 'Post Status',
];
diff --git a/public/images/favorite-interface.jpg b/public/images/favorite-interface.jpg
new file mode 100644
index 0000000..a9b4840
--- /dev/null
+++ b/public/images/favorite-interface.jpg
Binary files differ
diff --git a/views/docs/creating-posts.php b/views/docs/creating-posts.php
index e1775bd..6c5cb16 100644
--- a/views/docs/creating-posts.php
+++ b/views/docs/creating-posts.php
@@ -10,6 +10,7 @@
<li><a href="/docs/editor">Rich Editor</a></li>
<li><a href="/docs/note">Note</a></li>
<li><a href="/docs/bookmark">Bookmark</a></li>
+ <li><a href="/docs/favorite">Favorite</a></li>
<li>... more documentation soon!</li>
</ul>
diff --git a/views/docs/favorite.php b/views/docs/favorite.php
new file mode 100644
index 0000000..c962fa5
--- /dev/null
+++ b/views/docs/favorite.php
@@ -0,0 +1,30 @@
+<div class="narrow">
+ <?= partial('partials/header') ?>
+
+ <h2>Favorite</h2>
+
+ <img src="/images/favorite-interface.jpg" style="max-width: 300px; float: right;">
+
+ <p>The favorite interface is for creating favorite posts.</p>
+
+ <h3>Bookmarklet</h3>
+
+ <p>On the favorite interface, you can drag a bookmarklet to your bookmarks toolbar. This will let you favorite pages that you're viewing with a single click.</p>
+
+ <h3>Post Properties</h3>
+
+ <p>The following properties will be sent in the Micropub request. This request will be sent as a form-encoded request.</p>
+
+ <p>The access token is sent in the Authorization HTTP header:</p>
+ <pre>Authorization: Bearer XXXXXXXXX</pre>
+
+ <ul>
+ <li><code>h=entry</code> - This indicates that this is a request to create a new <a href="https://indieweb.org/h-entry">h-entry</a> post.</li>
+ <li><code>like-of</code> - This is the URL that you are favoriting.</li>
+ </ul>
+
+ <hr>
+
+ <p>Back to <a href="/docs/creating-posts">Creating Posts</a></p>
+
+</div>