Browse Source

add /pebble page to use as the client_id

pull/10/head
Aaron Parecki 9 years ago
parent
commit
d34330f52e
3 changed files with 31 additions and 1 deletions
  1. +3
    -1
      controllers/controllers.php
  2. +7
    -0
      controllers/pebble.php
  3. +21
    -0
      views/pebble.php

+ 3
- 1
controllers/controllers.php View File

@ -258,7 +258,9 @@ $app->get('/:domain', function($domain) use($app) {
'newer' => ($newer ? $newer->id : false)
));
$app->response()->body($html);
});
})->conditions(array(
'domain' => '[a-zA-Z0-9\.-]+\.[a-z]+'
));
$app->get('/:domain/:entry', function($domain, $entry_id) use($app) {

+ 7
- 0
controllers/pebble.php View File

@ -1,5 +1,12 @@
<?php
$app->get('/pebble', function() use($app) {
$html = render('pebble', array(
'title' => 'Teacup for Pebble'
));
$app->response()->body($html);
});
$app->get('/pebble/settings', function() use($app) {
$html = render('pebble-settings-login', array(
'title' => 'Log In',

+ 21
- 0
views/pebble.php View File

@ -0,0 +1,21 @@
<div class="narrow">
<div class="jumbotron h-x-app">
<h1><img src="/images/teacup-logo-144.png" height="72" style="margin-bottom: 13px;" class="u-logo" alt="Teacup">Teacup</h1>
<p class="tagline"><span class="p-name">Teacup for Pebble</span> is a simple app for tracking what you are drinking.</p>
<p>To use Teacup, sign in with your domain. If your website supports <a href="http://indiewebcamp.com/micropub">Micropub</a>, it will log posts directly to your site. Otherwise, it will post to your profile on teacup.p3k.io.</p>
<img src="/images/banner.jpg" width="100%" class="screenshot">
</div>
</div>
<style type="text/css">
.screenshot {
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
}
</style>

Loading…
Cancel
Save