cleaning html, other ui fixes

This commit is contained in:
Matthew Scragg 2013-10-03 13:13:10 -05:00
parent 4992b29bd8
commit afa4da4869
6 changed files with 28 additions and 34 deletions

View file

@ -1,5 +1,6 @@
.navbar { body {
padding-top: 50px;
background-color:#eee;
} }
#main-body { #main-body {
@ -42,27 +43,18 @@
border: 1px solid #EEE; border: 1px solid #EEE;
-webkit-border-radius: 4px; -webkit-border-radius: 4px;
-moz-border-radius: 4px; -moz-border-radius: 4px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px; border-radius: 4px;
-webkit-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-moz-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-webkit-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-moz-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box; -webkit-box-sizing: border-box;
-moz-box-sizing: border-box; -moz-box-sizing: border-box;
box-sizing: border-box; box-sizing: border-box;
-webkit-box-flex: 1; -webkit-box-flex: 1;
-moz-box-flex: 1; -moz-box-flex: 1;
-ms-box-flex: 1; -ms-box-flex: 1;
-webkit-box-flex: 1;
-moz-box-flex: 1;
-ms-box-flex: 1;
-o-box-flex: 1; -o-box-flex: 1;
box-flex: 1; box-flex: 1;
-moz-box-shadow: 0 1px 2px rgba(0,0,0,.15);
-webkit-box-shadow: 0 1px 2px rgba(0,0,0,.15);
box-shadow: 0 1px 2px rgba(0,0,0,.15);
} }
#editor { #editor {
@ -74,27 +66,17 @@
right: 50%; right: 50%;
-webkit-border-radius: 4px; -webkit-border-radius: 4px;
-moz-border-radius: 4px; -moz-border-radius: 4px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px; border-radius: 4px;
-webkit-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-moz-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-webkit-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-moz-box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
box-shadow: 0 0 80px rgba(0,0,0,0.3) inset 0 0 5px rgba(0,0,0,0.6);
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box; -webkit-box-sizing: border-box;
-moz-box-sizing: border-box; -moz-box-sizing: border-box;
box-sizing: border-box; box-sizing: border-box;
-webkit-box-flex: 1; -webkit-box-flex: 1;
-moz-box-flex: 1; -moz-box-flex: 1;
-ms-box-flex: 1; -ms-box-flex: 1;
-webkit-box-flex: 1;
-moz-box-flex: 1;
-ms-box-flex: 1;
-o-box-flex: 1; -o-box-flex: 1;
box-flex: 1; box-flex: 1;
-webkit-box-shadow: 0 1px 2px rgba(0,0,0,.15);
box-shadow: 0 1px 2px rgba(0,0,0,.15);
} }
.user-avatar a img { .user-avatar a img {

View file

@ -129,7 +129,6 @@ $(function(){
if (p.filename != $pagename.val()) { if (p.filename != $pagename.val()) {
updateUserProfile({ filename: $pagename.val(), currentMd: "" }); updateUserProfile({ filename: $pagename.val(), currentMd: "" });
} }
profile = p profile = p
} }
@ -417,6 +416,8 @@ $(function(){
isManual && Notifier.showMessage(Notifier.messages.docSavedLocal); isManual && Notifier.showMessage(Notifier.messages.docSavedLocal);
if (isManual) { if (isManual) {
updateUserProfile({ currentMd: "" });
var data = { var data = {
name: $("#page-name").val(), name: $("#page-name").val(),
message: $("#page-message").val(), message: $("#page-message").val(),

View file

@ -12,11 +12,6 @@
<link href="/static/css/font-awesome.min.css" rel="stylesheet"> <link href="/static/css/font-awesome.min.css" rel="stylesheet">
<link href="/static/css/style.css" rel="stylesheet"> <link href="/static/css/style.css" rel="stylesheet">
<style>
body {
padding-top: 60px;
}
</style>
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]> <!--[if lt IE 9]>
<script src="/static/js/html5shiv.js"></script> <script src="/static/js/html5shiv.js"></script>

View file

@ -6,6 +6,16 @@
<script src="/static/js/dillinger.js"></script> <script src="/static/js/dillinger.js"></script>
{% endblock %} {% endblock %}
{% block body %} {% block body %}
<style>
#main-body {
background: inherit;
border: inherit;
padding: 0;
-webkit-box-shadow: 0;
-moz-box-shadow: 0;
box-shadow: 0;
}
</style>
<div id="app-wrap" class="container-fluid"> <div id="app-wrap" class="container-fluid">
<div id="app-controls" class="row"> <div id="app-controls" class="row">

View file

@ -1,6 +1,10 @@
import os import os
from lxml.html.clean import clean_html
import ghdiff import ghdiff
from gittle import Gittle from gittle import Gittle
from util import to_canonical from util import to_canonical
@ -58,7 +62,7 @@ class Wiki():
self.path = path self.path = path
def write_page(self, name, content, message=None, create=False, username=None, email=None): def write_page(self, name, content, message=None, create=False, username=None, email=None):
#content = clean_html(content) content = clean_html(content)
filename = self.cname_to_filename(to_canonical(name)) filename = self.cname_to_filename(to_canonical(name))
f = open(self.path + "/" + filename, 'w') f = open(self.path + "/" + filename, 'w')
f.write(content) f.write(content)

View file

@ -7,3 +7,5 @@ nginx:
- reload: True - reload: True
- require: - require:
- pkg: nginx - pkg: nginx
/etc/