Commit b4540a48 by Piotr Mitros

Merge

parents cbfe2ae8 4a734bf1
...@@ -5,6 +5,10 @@ ...@@ -5,6 +5,10 @@
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function() {
${init} ${init}
$(".sequence-nav li a").hover(function(){
$(this).siblings().toggle();
});
}); });
</script> </script>
</%block> </%block>
......
...@@ -85,6 +85,7 @@ ...@@ -85,6 +85,7 @@
<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>
<script> <script>
// Feedback form // Feedback form
$(function() { $(function() {
...@@ -117,6 +118,5 @@ $(function(){ ...@@ -117,6 +118,5 @@ $(function(){
</script> </script>
<%block name="js_extra"/> <%block name="js_extra"/>
</body> </body>
</html> </html>
...@@ -4,14 +4,14 @@ ...@@ -4,14 +4,14 @@
@import "base/reset", "base/font-face"; @import "base/reset", "base/font-face";
@import "base/variables", "base/functions", "base/extends", "base/base"; @import "base/variables", "base/functions", "base/extends", "base/base";
@import "layout/layout", "layout/header", "layout/footer", "layout/leanmodal"; @import "layout/layout", "layout/header", "layout/footer", "layout/leanmodal";
@import "jquery-ui-1.8.16.custom"; @import "plugins/jquery-ui-1.8.16.custom";
// pages // pages
@import "courseware/courseware", "courseware/sidebar", "courseware/video", "courseware/sequence-nav", "courseware/amplifier"; @import "courseware/courseware", "courseware/sidebar", "courseware/video", "courseware/sequence-nav", "courseware/amplifier";
@import "textbook"; @import "textbook";
@import "info"; @import "info";
@import "profile"; @import "profile";
@import "wiki/basic-html", "wiki/sidebar", "wiki/create", "wiki/wiki"; @import "wiki/basic-html", "wiki/sidebar", "wiki/create", "wiki/wiki", "wiki/table";
@import "help"; @import "help";
@import "discussion/askbot-original", "discussion/discussion","discussion/sidebar", "discussion/questions", "discussion/tags", "discussion/question-view" , "discussion/answers", "discussion/forms", "discussion/form-wmd-toolbar", "discussion/modals", "discussion/profile"; @import "discussion/askbot-original", "discussion/discussion","discussion/sidebar", "discussion/questions", "discussion/tags", "discussion/question-view" , "discussion/answers", "discussion/forms", "discussion/form-wmd-toolbar", "discussion/modals", "discussion/profile";
...@@ -6,11 +6,15 @@ nav.sequence-nav { ...@@ -6,11 +6,15 @@ nav.sequence-nav {
display: table-row; display: table-row;
float: left; float: left;
width: flex-grid(7.5,9) + flex-gutter(); width: flex-grid(7.5,9) + flex-gutter();
position: relative;
a { a {
@extend .block-link; @extend .block-link;
} }
li {
display: table-cell;
.inactive { .inactive {
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -26,6 +30,7 @@ nav.sequence-nav { ...@@ -26,6 +30,7 @@ nav.sequence-nav {
&:hover { &:hover {
background-color: #F6EFD4; background-color: #F6EFD4;
background-position: center center;
} }
} }
...@@ -37,18 +42,19 @@ nav.sequence-nav { ...@@ -37,18 +42,19 @@ nav.sequence-nav {
&:hover { &:hover {
background-color: #fff; background-color: #fff;
background-position: center;
} }
} }
li { a {
@include box-shadow(1px 0 0 #fff); @include box-shadow(1px 0 0 #fff);
background-position: center center; background-position: center center;
border: none; border: none;
border-right: 1px solid darken(#F6EFD4, 10%); border-right: 1px solid darken(#F6EFD4, 10%);
cursor: pointer; cursor: pointer;
display: table-cell;
padding: 14px 4px; padding: 14px 4px;
width: 28px; width: 28px;
height: 17px;
// @media screen and (max-width: 800px) { // @media screen and (max-width: 800px) {
// padding: 12px 8px; // padding: 12px 8px;
...@@ -58,50 +64,92 @@ nav.sequence-nav { ...@@ -58,50 +64,92 @@ nav.sequence-nav {
&.seq_video_inactive { &.seq_video_inactive {
@extend .inactive; @extend .inactive;
background-image: url('/static/images/sequence-nav/video-icon-normal.png'); background-image: url('/static/images/sequence-nav/video-icon-normal.png');
background-position: center;
} }
&.seq_video_visited { &.seq_video_visited {
@extend .visited; @extend .visited;
background-image: url('/static/images/sequence-nav/video-icon-visited.png'); background-image: url('/static/images/sequence-nav/video-icon-visited.png');
background-position: center;
} }
&.seq_video_active { &.seq_video_active {
@extend .active; @extend .active;
background-image: url('/static/images/sequence-nav/video-icon-current.png'); background-image: url('/static/images/sequence-nav/video-icon-current.png');
background-position: center;
} }
//other //other
&.seq_other_inactive { &.seq_other_inactive {
@extend .inactive; @extend .inactive;
background-image: url('/static/images/sequence-nav/document-icon-normal.png'); background-image: url('/static/images/sequence-nav/document-icon-normal.png');
background-position: center;
} }
&.seq_other_visited { &.seq_other_visited {
@extend .visited; @extend .visited;
background-image: url('/static/images/sequence-nav/document-icon-visited.png'); background-image: url('/static/images/sequence-nav/document-icon-visited.png');
background-position: center;
} }
&.seq_other_active { &.seq_other_active {
@extend .active; @extend .active;
background-image: url('/static/images/sequence-nav/document-icon-current.png'); background-image: url('/static/images/sequence-nav/document-icon-current.png');
background-position: center;
} }
//vertical & problems //vertical & problems
&.seq_vertical_inactive, &.seq_problem_inactive { &.seq_vertical_inactive, &.seq_problem_inactive {
@extend .inactive; @extend .inactive;
background-image: url('/static/images/sequence-nav/list-icon-normal.png'); background-image: url('/static/images/sequence-nav/list-icon-normal.png');
background-position: center;
} }
&.seq_vertical_visited, &.seq_problem_visited { &.seq_vertical_visited, &.seq_problem_visited {
@extend .visited; @extend .visited;
background-image: url('/static/images/sequence-nav/list-icon-visited.png'); background-image: url('/static/images/sequence-nav/list-icon-visited.png');
background-position: center;
} }
&.seq_vertical_active, &.seq_problem_active { &.seq_vertical_active, &.seq_problem_active {
@extend .active; @extend .active;
background-image: url('/static/images/sequence-nav/list-icon-current.png'); background-image: url('/static/images/sequence-nav/list-icon-current.png');
background-position: center;
}
} }
p {
position: absolute;
display: none;
background: #B3A87E;
padding: 6px;
white-space: pre-wrap;
z-index: 99;
margin: 4px 0 0 -5px;
text-shadow: 0 -1px 0 darken(#B3A87E, 10%);
color: #fff;
&:empty {
background: none;
&::after {
display: none;
}
}
&::after {
background: #B3A87E;
content: " ";
display: block;
height: 10px;
position: absolute;
top: -5px;
left: 18px;
@include transform(rotate(45deg));
@include transition();
width: 10px;
}
}
} }
} }
......
...@@ -143,42 +143,28 @@ section.course-content { ...@@ -143,42 +143,28 @@ section.course-content {
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
h3 { h3 {
@include inline-block();
a { a {
color: #fff; color: #fff;
display: block;
padding: 0 lh(.5); padding: 0 lh(.5);
@include inline-block();
&:hover { &:hover {
text-decoration: none; text-decoration: none;
background-color: #444; // background-color: #444;
} }
} }
} }
// fix for now
ol#video_speeds { ol#video_speeds {
@extend .clearfix;
background: #333;
border: 1px solid #000;
font-weight: bold;
@include inline-block(); @include inline-block();
padding: 0 lh(); padding-right: lh(.5);
position: absolute;
right: 79px;
@include box-shadow(inset 0 1px 0 #555);
li { li {
cursor: pointer; cursor: pointer;
float: left; @include inline-block();
margin-bottom: 0;
margin-right: lh(.5);
&:last-child {
margin-right: 0;
}
&:hover {
color: $mit-red;
}
} }
} }
} }
......
...@@ -39,6 +39,7 @@ body.askbot { ...@@ -39,6 +39,7 @@ body.askbot {
div.discussion-content { div.discussion-content {
@include box-sizing(border-box); @include box-sizing(border-box);
display: table-cell; display: table-cell;
min-width: 650px;
padding: lh(); padding: lh();
vertical-align: top; vertical-align: top;
width: flex-grid(9) + flex-gutter(); width: flex-grid(9) + flex-gutter();
......
...@@ -14,7 +14,7 @@ body.user-profile-page { ...@@ -14,7 +14,7 @@ body.user-profile-page {
> li { > li {
display: table-cell; display: table-cell;
padding: (flex-gutter(9)/2); padding: (flex-gutter(9)/2);
border-right: 1px solid #ddd; border-right: 1px dashed #efefef;
@include box-sizing(border-box); @include box-sizing(border-box);
&:first-child { &:first-child {
...@@ -76,7 +76,7 @@ body.user-profile-page { ...@@ -76,7 +76,7 @@ body.user-profile-page {
&.up { &.up {
background-color:#d1e3a8; background-color:#d1e3a8;
background-image: url(/static/images/askbot/vote-arrow-up.png); background-image: url(/static/images/askbot/vote-arrow-up-activate.png);
margin-right: 6px; margin-right: 6px;
span.vote-count { span.vote-count {
...@@ -85,7 +85,7 @@ body.user-profile-page { ...@@ -85,7 +85,7 @@ body.user-profile-page {
} }
&.down { &.down {
background-image: url(/static/images/askbot/vote-arrow-down.png); background-image: url(/static/images/askbot/vote-arrow-down-activate.png);
background-color:#eac6ad; background-color:#eac6ad;
span.vote-count { span.vote-count {
......
...@@ -19,14 +19,19 @@ div.question-header { ...@@ -19,14 +19,19 @@ div.question-header {
&.post-vote { &.post-vote {
@include border-radius(4px); @include border-radius(4px);
background-color: lighten(#F6EFD4, 3%); background-color: lighten(#F6EFD4, 5%);
border: 1px solid darken( #F6EFD4,10% );
@include box-shadow(inset 0 1px 0px #fff);
} }
&.question-img-upvote, &.answer-img-upvote { &.question-img-upvote, &.answer-img-upvote {
background-image: url(/static/images/askbot/vote-arrow-up.png); background-image: url(/static/images/askbot/vote-arrow-up.png);
@include box-shadow(inset 0 1px 0px rgba(255, 255, 255, 0.5));
&:hover, &.on { &:hover, &.on {
background-color:#d1e3a8; background-color:#d1e3a8;
border-color: darken(#D1E3A8, 20%);
background-image: url(/static/images/askbot/vote-arrow-up-activate.png);
} }
} }
...@@ -34,7 +39,9 @@ div.question-header { ...@@ -34,7 +39,9 @@ div.question-header {
background-image: url(/static/images/askbot/vote-arrow-down.png); background-image: url(/static/images/askbot/vote-arrow-down.png);
&:hover, &.on { &:hover, &.on {
background-color:#eac6ad; background-color:#EAC6AD;
border-color: darken(#EAC6AD, 20%);
background-image: url(/static/images/askbot/vote-arrow-down-activate.png);
} }
} }
} }
...@@ -99,7 +106,7 @@ div.question-header { ...@@ -99,7 +106,7 @@ div.question-header {
div.post-update-container { div.post-update-container {
display: inline-block; display: inline-block;
float: left; float: left;
width: flex-grid(1.8,8); width: 20%;
border-left: 1px dashed #ddd; border-left: 1px dashed #ddd;
div.post-update-info { div.post-update-info {
...@@ -319,6 +326,5 @@ div.share-question { ...@@ -319,6 +326,5 @@ div.share-question {
p { p {
padding: 0; padding: 0;
margin: 0; margin: 0;
font-weight: bold;
} }
} }
...@@ -42,7 +42,7 @@ div.question-list-header { ...@@ -42,7 +42,7 @@ div.question-list-header {
div.question-sort { div.question-sort {
float: right; float: right;
margin-left: flex-gutter(); margin-left: flex-gutter();
margin-top: 10px; margin-top: 6px;
nav { nav {
@extend .action-link; @extend .action-link;
...@@ -87,7 +87,8 @@ div.question-list-header { ...@@ -87,7 +87,8 @@ div.question-list-header {
} }
ul.tags li { ul.tags {
li {
background: #fff; background: #fff;
&:before { &:before {
...@@ -95,6 +96,7 @@ div.question-list-header { ...@@ -95,6 +96,7 @@ div.question-list-header {
} }
} }
} }
}
} }
ul.question-list, div#question-list { ul.question-list, div#question-list {
...@@ -138,9 +140,14 @@ ul.question-list, div#question-list { ...@@ -138,9 +140,14 @@ ul.question-list, div#question-list {
text-transform: none; text-transform: none;
} }
p.excerpt {
color: #777;
}
div.user-info { div.user-info {
display: inline-block; display: inline-block;
vertical-align: top; vertical-align: top;
margin-bottom: 10px;
span.relative-time { span.relative-time {
font-weight: normal; font-weight: normal;
...@@ -158,8 +165,11 @@ ul.question-list, div#question-list { ...@@ -158,8 +165,11 @@ ul.question-list, div#question-list {
} }
&.question-meta { &.question-meta {
float: right;
margin-top: 10px;
width: flex-grid(3.5,9); width: flex-grid(3.5,9);
ul { ul {
text-align: right; text-align: right;
...@@ -172,6 +182,10 @@ ul.question-list, div#question-list { ...@@ -172,6 +182,10 @@ ul.question-list, div#question-list {
margin-right: 10px; margin-right: 10px;
width: 60px; width: 60px;
&:last-child {
margin-right: 0px;
}
&:hover { &:hover {
span, div { span, div {
color: #555; color: #555;
......
...@@ -7,6 +7,10 @@ div.discussion-wrapper aside { ...@@ -7,6 +7,10 @@ div.discussion-wrapper aside {
padding: lh(); padding: lh();
width: flex-grid(3); width: flex-grid(3);
&.main-sidebar {
min-width:200px;
}
h1 { h1 {
@extend .bottom-border; @extend .bottom-border;
margin: (-(lh())) (-(lh())) 0; margin: (-(lh())) (-(lh())) 0;
...@@ -26,8 +30,15 @@ div.discussion-wrapper aside { ...@@ -26,8 +30,15 @@ div.discussion-wrapper aside {
box-shadow: none; box-shadow: none;
} }
div.inputs {
input[type="submit"] {
width: 27%;
float: right;
}
input[type="text"] { input[type="text"] {
width: 76%; width: 62%;
}
} }
div.box { div.box {
...@@ -283,6 +294,11 @@ div.discussion-wrapper aside { ...@@ -283,6 +294,11 @@ div.discussion-wrapper aside {
text-align: center; text-align: center;
padding: 10px; padding: 10px;
display: block; display: block;
margin-top: 10px;
&:first-child {
margin-top: 0;
}
span { span {
font-weight: bold; font-weight: bold;
......
table.wiki-history {
thead {
background: #ddd;
// border-bottom: 1px solid #ddd;
tr {
height: 40px;
th {
padding-top: 10px;
padding-left: 15px;
&#revision {
width: 5%;
}
&#comment {
width: 15%;
}
&#diff {
width: 60%;
}
&#modified {
width:20%;
}
}
}
}
tbody {
tr td {
padding: 8px 15px;
}
}
tr.dark {
background-color: #efefef;
}
}
div.history-controls {
margin-top: 20px;
input[type="submit"] {
@extend .light-button;
}
}
...@@ -7,6 +7,8 @@ div.wiki-wrapper { ...@@ -7,6 +7,8 @@ div.wiki-wrapper {
header { header {
@extend .topbar; @extend .topbar;
height:46px;
@include box-shadow(inset 0 1px 0 white);
&:empty { &:empty {
display: none !important; display: none !important;
...@@ -35,7 +37,6 @@ div.wiki-wrapper { ...@@ -35,7 +37,6 @@ div.wiki-wrapper {
@include box-shadow(inset 1px 0 0 lighten(#f6efd4, 5%)); @include box-shadow(inset 1px 0 0 lighten(#f6efd4, 5%));
@include border-radius(0); @include border-radius(0);
@include transition(); @include transition();
background: darken(#F6EFD4, 5%);
border: 0; border: 0;
border-left: 1px solid darken(#f6efd4, 20%); border-left: 1px solid darken(#f6efd4, 20%);
color: darken(#F6EFD4, 80%); color: darken(#F6EFD4, 80%);
...@@ -44,11 +45,25 @@ div.wiki-wrapper { ...@@ -44,11 +45,25 @@ div.wiki-wrapper {
font-size: 12px; font-size: 12px;
text-transform: uppercase; text-transform: uppercase;
letter-spacing: 1px; letter-spacing: 1px;
padding: 14px; padding: 14.9px;
padding-left: 38px;
margin: 0; margin: 0;
&.view {
background: darken(#F6EFD4, 5%) url('/static/images/sequence-nav/view.png') no-repeat 12px 12px;
}
&.history {
background: darken(#F6EFD4, 5%) url('/static/images/sequence-nav/history.png') no-repeat 12px 12px;
}
&.edit {
background: darken(#F6EFD4, 5%) url('/static/images/sequence-nav/edit.png') no-repeat 12px 12px;
}
&:hover { &:hover {
background: none; background-color: #F6EFD4;
} }
} }
} }
...@@ -66,10 +81,19 @@ div.wiki-wrapper { ...@@ -66,10 +81,19 @@ div.wiki-wrapper {
line-height: 1.6em; line-height: 1.6em;
} }
#wiki_history_table { ul.article-list {
tr.dark { margin-left: 15px;
background-color: $light-gray;
li {
margin: 10px 0;
list-style-image: url('/static/images/bullet-triangle.png');
h3 {
font-size: 18px;
font-weight: normal;
}
} }
} }
} }
} }
<nav class="sequence-nav"> <nav class="sequence-nav">
<ol> <ol>
% for t in range(1,1+len(items)): % for t in range(1,1+len(items)):
<li class="seq_inactive" id="tt_${ t }">&nbsp;</li> <li><a href="#" class="seq_inactive" id="tt_${ t }"></a></li>
% endfor % endfor
</ol> </ol>
...@@ -11,8 +11,5 @@ ...@@ -11,8 +11,5 @@
</ul> </ul>
</nav> </nav>
<div id="seq_content"></div>
<!-- <td colspan=${ len(items) }> -->
<div id="seq_content"></div>
<!-- </td> -->
...@@ -54,7 +54,7 @@ function ${ id }goto(i) { ...@@ -54,7 +54,7 @@ function ${ id }goto(i) {
function ${ id }setup_click(i) { function ${ id }setup_click(i) {
$('#tt_'+i).click(function(eo) { ${ id }goto(i);}); $('#tt_'+i).click(function(eo) { ${ id }goto(i);});
$('#tt_'+i).addClass("seq_"+${ id }types[i]+"_inactive"); $('#tt_'+i).addClass("seq_"+${ id }types[i]+"_inactive");
$('#tt_'+i).attr("title", ${ id }titles[i-1]); $('#tt_'+i).parent().append("<p>" + ${ id }titles[i-1] + "</p>");
} }
......
...@@ -149,15 +149,15 @@ ...@@ -149,15 +149,15 @@
<ul> <ul>
<li> <li>
<input type="button" onclick="javascript:location.href='${reverse("wiki_view", args=[wiki_article.get_url()])}'" value="View" /> <input type="button" onclick="javascript:location.href='${reverse("wiki_view", args=[wiki_article.get_url()])}'" value="View" class="view" />
</li> </li>
<li> <li>
<input type="button" onclick="javascript:location.href='${reverse("wiki_edit", args=[wiki_article.get_url()])}'" value="Edit" ${'disabled="true"' if not wiki_write else ""}/> <input type="button" onclick="javascript:location.href='${reverse("wiki_edit", args=[wiki_article.get_url()])}'" value="Edit" ${'disabled="true"' if not wiki_write else ""} class="edit"/>
</li> </li>
<li> <li>
<input type="button" onclick="javascript:location.href='${reverse("wiki_history", args=[wiki_article.get_url(),1])}'" value="History" class="button" /> <input type="button" onclick="javascript:location.href='${reverse("wiki_history", args=[wiki_article.get_url(),1])}'" value="History" class="button history" />
</li> </li>
</ul> </ul>
%endif %endif
......
...@@ -17,7 +17,7 @@ ${ wiki_article.title } ...@@ -17,7 +17,7 @@ ${ wiki_article.title }
<div style="display:none"> <div style="display:none">
<input type="hidden" name="csrfmiddlewaretoken" value="${csrf_token}"/> <input type="hidden" name="csrfmiddlewaretoken" value="${csrf_token}"/>
</div> </div>
<table id="wiki_history_table"> <table id="wiki_history_table" class="wiki-history">
<thead> <thead>
<tr> <tr>
<th id="revision">Revision</th> <th id="revision">Revision</th>
...@@ -72,17 +72,18 @@ ${ wiki_article.title } ...@@ -72,17 +72,18 @@ ${ wiki_article.title }
</tfoot> </tfoot>
%endif %endif
</table> </table>
<input type="submit" name="view" value="View revision"/> <div class="history-controls"><input type="submit" name="view" value="View revision"/>
<input type="submit" name="change" value="Change to revision" <input type="submit" name="change" value="Change to revision"
%if not wiki_write: %if not wiki_write:
disabled="true" disabled="true"
%endif %endif
/> />
%if show_delete_revision: %if show_delete_revision:
<input type="submit" name="delete" value="Admin Delete revision"/> <input type="submit" name="delete" value="Delete revision"/>
<input type="submit" name="restore" value="Admin Restore revision"/> <input type="submit" name="restore" value="Restore revision"/>
<input type="submit" name="delete_all" value="Admin Delete all revisions"> <input type="submit" name="delete_all" value="Delete all revisions">
<input type="submit" name="lock_article" value="${'Lock Article' if not wiki_article.locked else 'Unlock Article'}"> <input type="submit" name="lock_article" value="${'Lock Article' if not wiki_article.locked else 'Unlock Article'}">
%endif %endif
</div>
</form> </form>
</%block> </%block>
...@@ -5,24 +5,26 @@ ...@@ -5,24 +5,26 @@
<%block name="title"><title>Search Results - MITx 6.002 Wiki</title></%block> <%block name="title"><title>Search Results - MITx 6.002 Wiki</title></%block>
<%! <%!
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
%> %>
<%block name="wiki_page_title"> <%block name="wiki_page_title">
%if wiki_search_query: %if wiki_search_query:
Search results for ${wiki_search_query | h} Search results for ${wiki_search_query | h}
%else: %else:
Displaying all articles Displaying all articles
%endif %endif
</%block> </%block>
<%block name="wiki_body"> <%block name="wiki_body">
%for article in wiki_search_results: <ul class="article-list">
<% article_deleted = not article.current_revision.deleted == 0 %> %for article in wiki_search_results:
<a href="${reverse("wiki_view", args=[article.get_url()])}">${article.get_url()} ${'(Deleted)' if article_deleted else ''}</a><br/> <% article_deleted = not article.current_revision.deleted == 0 %>
%endfor <li><h3><a href="${reverse("wiki_view", args=[article.get_url()])}">${article.title} ${'(Deleted)' if article_deleted else ''}</a></h3></li>
%endfor
%if not wiki_search_results: %if not wiki_search_results:
No articles matching <b>${wiki_search_query if wiki_search_query is not UNDEFINED else ""} </b>! No articles matching <b>${wiki_search_query if wiki_search_query is not UNDEFINED else ""} </b>!
%endif %endif
</ul>
</%block> </%block>
...@@ -69,14 +69,6 @@ ...@@ -69,14 +69,6 @@
$(this).text((link_text == 'on') ? 'off' : 'on'); $(this).text((link_text == 'on') ? 'off' : 'on');
return false; return false;
}); });
$('.speeds ol').hide();
$('.speeds h3 a').click(function() {
$('.speeds ol').toggle();
return false;
});
}); });
</script> </script>
</%block> </%block>
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