diff options
-rw-r--r-- | controllers/editor.php | 10 | ||||
-rw-r--r-- | public/editor/editor.js | 3 | ||||
-rw-r--r-- | public/editor/style.css | 4 | ||||
-rw-r--r-- | views/editor.php | 10 | ||||
-rw-r--r-- | views/partials/appcache.php | 2 |
5 files changed, 18 insertions, 11 deletions
diff --git a/controllers/editor.php b/controllers/editor.php index 995438b..a66c188 100644 --- a/controllers/editor.php +++ b/controllers/editor.php @@ -33,9 +33,9 @@ $app->get('/editor/oembed', function() use($app) { $app->response()->body($json); }); -$app->get('/appcache.manifest', function() use($app) { - $content = partial('partials/appcache'); +// $app->get('/appcache.manifest', function() use($app) { +// $content = partial('partials/appcache'); - $app->response()['Content-type'] = 'text/cache-manifest'; - $app->response()->body($content); -}); +// $app->response()['Content-type'] = 'text/cache-manifest'; +// $app->response()->body($content); +// }); diff --git a/public/editor/editor.js b/public/editor/editor.js index bdf0580..2c4972f 100644 --- a/public/editor/editor.js +++ b/public/editor/editor.js @@ -26,4 +26,7 @@ $(function () { } } }); + $('.editable').focus(function(){ + $('.placeholder').removeClass('placeholder'); + }); }); diff --git a/public/editor/style.css b/public/editor/style.css index b72bf92..bec46db 100644 --- a/public/editor/style.css +++ b/public/editor/style.css @@ -95,3 +95,7 @@ blockquote { border-bottom: 1px solid #dbdbdb; border-top: 1px solid #dbdbdb; } + +.editable .placeholder { + color: #ccc; +} diff --git a/views/editor.php b/views/editor.php index 5036723..fc4fcc6 100644 --- a/views/editor.php +++ b/views/editor.php @@ -1,5 +1,5 @@ <!doctype html> -<html lang="en" manifest="appcache.manifest"> +<html lang="en" manifest_="appcache.manifest"> <head> <title>Quill Editor</title> <meta charset="utf-8"> @@ -31,7 +31,6 @@ <script src="/editor/medium-editor/js/medium-editor.min.js"></script> <script src="/editor/medium-editor/js/medium-editor-insert-plugin.min.js"></script> <script src="/editor/localforage/localforage.js"></script> - <script src="/editor/editor.js"></script> <link rel="apple-touch-icon" sizes="57x57" href="/images/quill-icon-57.png"> <link rel="apple-touch-icon" sizes="72x72" href="/images/quill-icon-72.png"> @@ -43,10 +42,11 @@ <body> <div class="container"> -<input id="post-name" type="text" value="Lorem Ipsum"> -<div id="content" class="editable"> - <?= partial('/partials/sample-html') ?> + <input id="post-name" type="text" value="" placeholder="Title"> + <div id="content" class="editable"><p class="placeholder">Tell your story...</p></div> </div> +<script src="/editor/editor.js"></script> + </body> </html>
\ No newline at end of file diff --git a/views/partials/appcache.php b/views/partials/appcache.php index 4fa1f13..546685f 100644 --- a/views/partials/appcache.php +++ b/views/partials/appcache.php @@ -1,6 +1,6 @@ CACHE MANIFEST -# v1 +# v3 /editor /editor/style.css |