Commit 589aa6ba by Reda Lemeden

Merge with head

parents bd2e82c2 c1543c7f
No preview for this file type
...@@ -16,6 +16,10 @@ ...@@ -16,6 +16,10 @@
<script type="text/javascript" src="/static/js/schematic.js"></script> <script type="text/javascript" src="/static/js/schematic.js"></script>
<script type="text/javascript" src="/static/js/cktsim.js"></script> <script type="text/javascript" src="/static/js/cktsim.js"></script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!-- Warning: Do not upgrade FancyBox. V2.0 is under a non-free CC license --> <!-- Warning: Do not upgrade FancyBox. V2.0 is under a non-free CC license -->
<script type="text/javascript" src="/static/lib/fancybox/jquery.fancybox-1.3.4.js"></script> <script type="text/javascript" src="/static/lib/fancybox/jquery.fancybox-1.3.4.js"></script>
<link rel="stylesheet" href="/static/lib/fancybox/jquery.fancybox-1.3.4.css"> <link rel="stylesheet" href="/static/lib/fancybox/jquery.fancybox-1.3.4.css">
......
...@@ -15,9 +15,13 @@ ...@@ -15,9 +15,13 @@
<script type="text/javascript" src="/static/lib//swfobject/swfobject.js"></script> <script type="text/javascript" src="/static/lib//swfobject/swfobject.js"></script>
<script type="text/javascript" src="/static/lib/jquery.treeview.js"></script> <script type="text/javascript" src="/static/lib/jquery.treeview.js"></script>
<script type="text/javascript" src="/static/js/video_player.js"></script> <script type="text/javascript" src="/static/js/video_player.js"></script>
<script type="text/javascript" src="/static/js/schematic.js"></script> <!-- <script type="text/javascript" src="/static/js/schematic.js"></script> -->
<script> <!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<script>
$(function() { $(function() {
// Set up FancyBox pop-ups // Set up FancyBox pop-ups
$("a.modal").fancybox({ $("a.modal").fancybox({
......
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
<p>Forgotten your password? Enter your e-mail address below, and we'll e-mail instructions for setting a new one.</p> <p>Forgotten your password? Enter your e-mail address below, and we'll e-mail instructions for setting a new one.</p>
<form action="/password_reset/" method="post"> <form action="/password_reset/" method="post">
<input type='hidden' name='csrfmiddlewaretoken' value='${ csrf }' /> <input type='hidden' name='csrfmiddlewaretoken' value='${ csrf }' />
<p><label for="id_email">E-mail address:</label> <input id="id_email" type="text" name="email" maxlength="75" /> <input type="button" id="pwd_reset_button" value="Reset my password" /></p> <label for="id_email">E-mail address:</label>
<input id="id_email" type="email" name="email" maxlength="75" /> <input type="button" id="pwd_reset_button" value="Reset my password" />
</form> </form>
...@@ -27,7 +27,6 @@ div#fancybox-wrap { ...@@ -27,7 +27,6 @@ div#fancybox-wrap {
h1 { h1 {
font-size: 24px; font-size: 24px;
margin-top: 0; margin-top: 0;
font-family: "Oswald";
padding-bottom: lh(); padding-bottom: lh();
border-bottom: 1px solid #eee; border-bottom: 1px solid #eee;
margin-bottom: lh(); margin-bottom: lh();
...@@ -36,28 +35,40 @@ div#fancybox-wrap { ...@@ -36,28 +35,40 @@ div#fancybox-wrap {
form { form {
text-align: left; text-align: left;
div#enroll_error { div#enroll_error, div#login_error {
padding-bottom: lh(); margin-bottom: lh();
color: #DF8B2C; background-color: #F50200;
color: #fff;
text-transform: uppercase; text-transform: uppercase;
letter-spacing: 1px; letter-spacing: 1px;
font-weight: bold; font-weight: bold;
-webkit-font-smoothing: antialiased;
padding: lh(.2);
&:empty {
padding: 0;
}
}
label {
display: block;
font-weight: bold;
}
#{$all-text-inputs} {
width: 100%;
@include box-sizing(border-box);
}
input[type="checkbox"] {
margin-right: 10px;
} }
ol { ol {
li { li {
margin-bottom: lh(); margin-bottom: lh();
width: grid-width(6);
float: left;
&:nth-child(odd) {
margin-right: $gw-gutter;
}
&.terms, &.remember { &.terms, &.remember {
float: none;
width: auto;
clear: both;
padding-top: lh(); padding-top: lh();
border-top: 1px solid #eee; border-top: 1px solid #eee;
} }
...@@ -67,10 +78,6 @@ div#fancybox-wrap { ...@@ -67,10 +78,6 @@ div#fancybox-wrap {
float: none; float: none;
} }
label {
display: block;
font-weight: bold;
}
ul { ul {
list-style: disc outside none; list-style: disc outside none;
...@@ -84,15 +91,6 @@ div#fancybox-wrap { ...@@ -84,15 +91,6 @@ div#fancybox-wrap {
float: none; float: none;
} }
} }
#{$all-text-inputs} {
width: 100%;
@include box-sizing(border-box);
}
input[type="checkbox"] {
margin-right: 10px;
}
} }
} }
...@@ -121,11 +119,22 @@ div#fancybox-wrap { ...@@ -121,11 +119,22 @@ div#fancybox-wrap {
a { a {
color: #999; color: #999;
&:hover { &:hover {
color: #444; color: #444;
} }
} }
} }
div#pwd_reset {
p {
margin-bottom: lh();
}
input[type="email"] {
margin-bottom: lh();
}
}
} }
} }
} }
...@@ -140,20 +140,21 @@ body { ...@@ -140,20 +140,21 @@ body {
} }
header.announcement { header.announcement {
@include background-size(cover); // @include background-size(cover);
background: #333; background: #333;
border-bottom: 1px solid #000; border-bottom: 1px solid #000;
color: #fff; color: #fff;
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
&.home { &.home {
background: #e3e3e3 url("/static/images/marketing/shot-1-medium.jpg");
@media screen and (min-width: 1200px) { @media screen and (min-width: 1200px) {
background: #e3e3e3 url("/static/images/marketing/shot-1-large.jpg"); background: #e3e3e3 url("/static/images/marketing/shot-1-large.jpg");
} }
@media screen and (max-width: 1199px) { // @media screen and (max-width: 1199px) {
background: #e3e3e3 url("/static/images/marketing/shot-1-medium.jpg"); // }
}
div { div {
padding: lh(10) lh() lh(3); padding: lh(10) lh() lh(3);
...@@ -161,6 +162,7 @@ header.announcement { ...@@ -161,6 +162,7 @@ header.announcement {
} }
&.course { &.course {
background: #e3e3e3 url("/static/images/marketing/course-bg-small.jpg");
@media screen and (min-width: 1200px) { @media screen and (min-width: 1200px) {
background: #e3e3e3 url("/static/images/marketing/course-bg-large.jpg"); background: #e3e3e3 url("/static/images/marketing/course-bg-large.jpg");
...@@ -168,12 +170,6 @@ header.announcement { ...@@ -168,12 +170,6 @@ header.announcement {
@media screen and (max-width: 1199px) and (min-width: 700px) { @media screen and (max-width: 1199px) and (min-width: 700px) {
background: #e3e3e3 url("/static/images/marketing/course-bg-medium.jpg"); background: #e3e3e3 url("/static/images/marketing/course-bg-medium.jpg");
@include background-size(cover);
}
@media screen and (max-width: 699px) {
background: #e3e3e3 url("/static/images/marketing/course-bg-small.jpg");
@include background-size(cover);
} }
div { div {
...@@ -190,6 +186,7 @@ header.announcement { ...@@ -190,6 +186,7 @@ header.announcement {
top: 0; top: 0;
right: lh(); right: lh();
@include border-radius(0 0 3px 3px); @include border-radius(0 0 3px 3px);
background: #333;
background: rgba(#000, .7); background: rgba(#000, .7);
padding: lh(.5); padding: lh(.5);
...@@ -334,6 +331,7 @@ section.index-content { ...@@ -334,6 +331,7 @@ section.index-content {
p { p {
width: auto; width: auto;
clear: both;
strong { strong {
font-family: "Open sans"; font-family: "Open sans";
......
html, body, div, span, applet, object, iframe, /*
html5doctor.com Reset Stylesheet
v1.6.1
Last Updated: 2010-09-17
Author: Richard Clark - http://richclarkdesign.com
Twitter: @rich_clark
*/
html, body, div, span, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre, h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code, abbr, address, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp, del, dfn, em, img, ins, kbd, q, samp,
small, strike, strong, sub, sup, tt, var, small, strong, sub, sup, var,
b, i,
dl, dt, dd, ol, ul, li, dl, dt, dd, ol, ul, li,
fieldset, form, label, legend, fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td { table, caption, tbody, tfoot, thead, tr, th, td,
margin: 0; article, aside, canvas, details, figcaption, figure,
padding: 0; footer, header, hgroup, menu, nav, section, summary,
border: 0; time, mark, audio, video {
outline: 0; margin:0;
font-weight: inherit; padding:0;
font-style: inherit; border:0;
font-size: 100%; outline:0;
font-family: inherit; font-size:100%;
vertical-align: baseline; vertical-align:baseline;
background:transparent;
} }
body { body {
line-height: 1; line-height:1;
color: black;
background: white;
} }
table { article,aside,details,figcaption,figure,
border-collapse: separate; footer,header,hgroup,menu,nav,section {
border-spacing: 0; display:block;
}
nav ul {
list-style:none;
} }
caption, th, td {
text-align: left; blockquote, q {
font-weight: normal; quotes:none;
} }
blockquote:before, blockquote:after, blockquote:before, blockquote:after,
q:before, q:after { q:before, q:after {
content: ""; content:'';
content:none;
} }
blockquote, q { a {
quotes: "" ""; margin:0;
padding:0;
font-size:100%;
vertical-align:baseline;
background:transparent;
}
/* change colours to suit your needs */
ins {
background-color:#ff9;
color:#000;
text-decoration:none;
}
/* change colours to suit your needs */
mark {
background-color:#ff9;
color:#000;
font-style:italic;
font-weight:bold;
} }
del {
text-decoration: line-through;
}
abbr[title], dfn[title] {
border-bottom:1px dotted;
cursor:help;
}
table {
border-collapse:collapse;
border-spacing:0;
}
/* change border colour to suit your needs */
hr {
display:block;
height:1px;
border:0;
border-top:1px solid #cccccc;
margin:1em 0;
padding:0;
}
input, select {
vertical-align:middle;
}
...@@ -14,6 +14,7 @@ ${ wiki_article.title } ...@@ -14,6 +14,7 @@ ${ wiki_article.title }
${wiki_form} ${wiki_form}
<input type="submit" value="Edit article" /></td> <input type="submit" name="edit" value="Edit article" />
<input type="submit" name="delete" value="Delete article" />
</form> </form>
</%block> </%block>
...@@ -18,85 +18,66 @@ ${wiki_error} ...@@ -18,85 +18,66 @@ ${wiki_error}
%endif %endif
%if wiki_err_notfound is not UNDEFINED: %if wiki_err_notfound is not UNDEFINED:
%if wiki_url is not UNDEFINED: %if wiki_url is not UNDEFINED:
<p> <p>
The page you requested could not be found. The page you requested could not be found.
Click <a href="${reverse("wiki_create", args=[wiki_url])}">here</a> to create it. Click <a href="${reverse("wiki_create", args=[wiki_url])}">here</a> to create it.
</p> </p>
%else: %else:
<p> <p>
Or maybe rather: Congratulations! It seems that there's no root Or maybe rather: Congratulations! It seems that there's no root
article, which is probably because you just installed simple-wiki article, which is probably because you just installed simple-wiki
and your installation is working. Now you can create the root article. and your installation is working. Now you can create the root article.
Click <a href="{% url wiki_create "" %}">here</a> to create it. Click <a href="{% url wiki_create "" %}">here</a> to create it.
</p> </p>
%endif %endif
%else: %else:
%if wiki_err_noparent is not UNDEFINED: %if wiki_err_noparent is not UNDEFINED:
<p> <p>
You cannot create this page, because its parent You cannot create this page, because its parent
does not exist. Click <a href="${reverse("wiki_create", args=[wiki_url_parent])}">here</a> does not exist. Click <a href="${reverse("wiki_create", args=[wiki_url_parent])}">here</a>
to create it. to create it.
</p> </p>
%else:
%if wiki_err_keyword is not UNDEFINED:
<p>
The page you're trying to create <b>${wiki_url}</b> starts with <b>_</b>, which is reserved for internal use.
</p>
%else: %else:
%if wiki_err_keyword is not UNDEFINED and wiki_err_keyword:
%if wiki_err_locked is not UNDEFINED: <p>
<p> The page you're trying to create <b>${wiki_url}</b> starts with <b>_</b>, which is reserved for internal use.
The article you are trying to modify is locked. </p>
</p> %elif wiki_err_locked is not UNDEFINED and wiki_err_locked:
%else: <p>
The article you are trying to modify is locked.
%if wiki_err_noread is not UNDEFINED: </p>
<p> %elif wiki_err_noread is not UNDEFINED and wiki_err_noread:
You do not have access to read this article. <p>
</p> You do not have access to read this article.
%else: </p>
%elif wiki_err_nowrite is not UNDEFINED and wiki_err_nowrite:
%if wiki_err_nowrite is not UNDEFINED: <p>
<p> You do not have access to edit this article.
You do not have access to edit this article. </p>
</p> %elif wiki_err_noanon is not UNDEFINED and wiki_err_noanon:
%else: <p>
Anonymous attachments are not allowed. Try logging in.
%if wiki_err_noanon is not UNDEFINED: </p>
<p> %elif wiki_err_create is not UNDEFINED and wiki_err_create:
Anonymous attachments are not allowed. Try logging in. <p>
</p> You do not have access to create this article.
%else: </p>
%elif wiki_err_encode is not UNDEFINED and wiki_err_encode:
%if wiki_err_create is not UNDEFINED: <p>
<p> The url you requested could not be handled by the wiki.
You do not have access to create this article. Probably you used a bad character in the URL.
</p> Only use digits, English letters, underscore and dash. For instance
/wiki/An_Article-1
</p>
%elif wiki_err_deleted is not UNDEFINED and wiki_err_deleted:
<p>
The article you tried to access has been deleted. You may be able to restore it to an earlier version in its <a href="${reverse("wiki_history", args=[wiki_article.get_url(),1])}">history</a>, or <a href="${reverse("wiki_edit", args=[wiki_article.get_url()])}">create a new version</a>.
</p>
%else: %else:
<p>
%if wiki_err_encode is not UNDEFINED: An error has occured.
<p> </p>
The url you requested could not be handled by the wiki.
Probably you used a bad character in the URL.
Only use digits, English letters, underscore and dash. For instance
/wiki/An_Article-1
</p>
%else:
<p>
An error has occured.
</p>
%endif
%endif
%endif
%endif
%endif
%endif
%endif %endif
%endif %endif
%endif %endif
......
...@@ -27,30 +27,32 @@ ${ wiki_article.title } ...@@ -27,30 +27,32 @@ ${ wiki_article.title }
<tbody> <tbody>
<% loopCount = 0 %> <% loopCount = 0 %>
%for revision in wiki_history: %for revision in wiki_history:
<% loopCount += 1 %> %if revision.deleted < 2 or show_delete_revision:
<tr style="border-top: 1px" ${'class="dark"' if (loopCount % 2) == 0 else ''}> <% loopCount += 1 %>
<td width="15px"> <tr style="border-top: 1px" class="${'dark ' if (loopCount % 2) == 0 else ''}${'deleted ' if (revision.deleted==2) else ''}" >
<input type="radio" name="revision" id="${revision.id}" value="${revision.id}"${"checked" if wiki_article.current_revision.id == revision.id else ""}/> <td width="15px">
<label for="${revision.id}"> <input type="radio" name="revision" id="${revision.id}" value="${revision.id}"${"checked" if wiki_article.current_revision.id == revision.id else ""}/>
${ revision } <label for="${revision.id}">
%if revision.previous_revision: ${ revision }
%if not revision.counter == revision.previous_revision.counter + 1: %if revision.previous_revision:
<br/>(based on ${revision.previous_revision}) %if not revision.counter == revision.previous_revision.counter + 1:
%endif <br/>(based on ${revision.previous_revision})
%endif %endif
</label> %endif
</td> </label>
<td> </td>
${ revision.revision_text if revision.revision_text else "<i>None</i>" }</td> <td>
<td class="diff"> ${ revision.revision_text if revision.revision_text else "<i>None</i>" }</td>
%for x in revision.get_diff(): <td class="diff">
${x|h}<br/> %for x in revision.get_diff():
%endfor </td> ${x|h}<br/>
<td>${revision.get_user} %endfor </td>
<br/> <td>${revision.get_user()}
${revision.revision_date.strftime("%b %d, %Y, %I:%M %p")} <br/>
</td> ${revision.revision_date.strftime("%b %d, %Y, %I:%M %p")}
</tr> </td>
</tr>
%endif
%endfor %endfor
</tbody> </tbody>
%if wiki_prev_page or wiki_next_page: %if wiki_prev_page or wiki_next_page:
...@@ -68,10 +70,16 @@ ${ wiki_article.title } ...@@ -68,10 +70,16 @@ ${ wiki_article.title }
</tfoot> </tfoot>
%endif %endif
</table> </table>
<input type="submit" value="Change revision" <input type="submit" name="change" value="Change revision"
%if not wiki_write: %if not wiki_write:
disabled="true" disabled="true"
%endif %endif
/> />
%if show_delete_revision:
<input type="submit" name="delete" value="Admin Delete revision"/>
<input type="submit" name="restore" value="Admin Restore revision"/>
<input type="submit" name="delete_all" value="Admin Delete all revisions">
<input type="submit" name="lock_article" value="${'Lock Article' if not wiki_article.locked else 'Unlock Article'}">
%endif
</form> </form>
</%block> </%block>
...@@ -16,7 +16,8 @@ ...@@ -16,7 +16,8 @@
<%block name="wiki_body"> <%block name="wiki_body">
%for article in wiki_search_results: %for article in wiki_search_results:
<a href="${reverse("wiki_view", args=[article.get_url()])}">${article.get_url()}</a><br/> <% article_deleted = not article.current_revision.deleted == 0 %>
<a href="${reverse("wiki_view", args=[article.get_url()])}">${article.get_url()} ${'(Deleted)' if article_deleted else ''}</a><br/>
%endfor %endfor
%if not wiki_search_results: %if not wiki_search_results:
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<%inherit file="simplewiki_base.html"/> <%inherit file="simplewiki_base.html"/>
<%block name="wiki_page_title"> <%block name="wiki_page_title">
${ wiki_article.title } ${ wiki_article.title } ${'<span style="color: red;">- Deleted Revision!</span>' if wiki_current_revision_deleted else ''}
</%block> </%block>
<%block name="wiki_body"> <%block name="wiki_body">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment