--- a/mouchak/server.py +++ b/mouchak/server.py @@ -40,6 +40,10 @@ return {'content': content, 'menu': menu} +@app.errorhandler(404) +def pageNotFound(e): + return flask.render_template('404.html'), 404 + @app.route('/', methods=['GET']) def index(): --- a/mouchak/static/css/editor.css +++ b/mouchak/static/css/editor.css @@ -1,5 +1,20 @@ -.page { +body { + background-color: #EEE; +} +.prettybox-lg { + background-color: #FFF; border: 1px solid #999; + border-radius: 6px; + box-shadow: 1px 1px 9px #333; +} +.prettybox-side { + border: 1px solid #999; + background-color: #FFF; + border-radius: 4px; + box-shadow: 0 0 5px #999; +} + +.page { padding: 30px; padding-bottom: 10px; width: 600px; @@ -8,15 +23,13 @@ position: absolute; left: 20px; top: 20px; - border: 1px solid #999; padding: 10px; width: 300px; - /*height: 80%;*/ } #page { position: absolute; - left: 400px; - top: 40px; + left: 420px; + top: 20px; } #pagelist { padding: 10px; @@ -36,10 +49,9 @@ padding: 3px; } #contentview { - border: 1px solid #999; - padding: 30px; + padding: 35px; margin: 10px; - width: 85%; + width: 88%; } .contentview { } @@ -75,5 +87,7 @@ background-color: #FFFFFF; opacity: 0.7; display: none; +} +#hud { } --- a/mouchak/static/js/editor.js +++ b/mouchak/static/js/editor.js @@ -3,7 +3,7 @@ /* view to manage list of pages - add, remove and show them */ var PageListView = Backbone.View.extend({ tagName: 'div', - className: '', + className: 'prettybox-side', id: 'pages', events: { 'click .pagename .disp': 'showPage', @@ -101,6 +101,7 @@ * add content, remove and show content, and update the page */ var PageView = Backbone.View.extend({ tagName: 'div', + className: 'prettybox-lg', id: 'page', events: { 'click #updatePage': 'updatePage', @@ -270,9 +271,11 @@ /* view to manage, render and update each content */ var ContentView = Backbone.View.extend({ id: 'contentview', + className: 'prettybox-lg', events: { 'click #done': 'done', 'click #updateContent': 'update', + 'click #back' : 'back', 'click #edit-type button' : 'editTypeChanged', 'change .contentview select': 'typeChanged' }, @@ -388,12 +391,16 @@ done: function() { this.update(); this.cleanUp(); + }, + back: function() { + this.cleanUp(); } }); /* view to configure custom navigation menu */ var MenuConfigView = Backbone.View.extend({ tagName: 'div', + className: 'prettybox-lg', id: 'page', events: { 'change #custom-menu': 'customMenuChange', --- a/mouchak/templates/404.html +++ b/mouchak/templates/404.html @@ -1,154 +1,158 @@ - - - Page Not Found :( - - - -
-

Not found :(

-

Sorry, but the page you were trying to view does not exist.

-

It looks like this was the result of either:

- -
- + input::-moz-focus-inner { + padding: 0; + border: 0; + } + + + +
+

Not found :(

+

Sorry, but the page you were trying to view does not exist.

+

It looks like this was the result of either:

+ +
+
+ Mouchak +
+
+ --- a/mouchak/templates/editor.html +++ b/mouchak/templates/editor.html @@ -130,7 +130,10 @@