Commit 291db0ab by brianhw

Merge pull request #1365 from edx/talbs/lms-cssarch

LMS: Revised CSS Architecture (resolves LMS_1020)
parents 014089e6 bbcb3810
...@@ -51,6 +51,8 @@ node_modules ...@@ -51,6 +51,8 @@ node_modules
*.scssc *.scssc
lms/static/sass/*.css lms/static/sass/*.css
lms/static/sass/application.scss lms/static/sass/application.scss
lms/static/sass/application-extend1.scss
lms/static/sass/application-extend2.scss
lms/static/sass/course.scss lms/static/sass/course.scss
cms/static/sass/*.css cms/static/sass/*.css
......
...@@ -587,7 +587,7 @@ MIDDLEWARE_CLASSES = ( ...@@ -587,7 +587,7 @@ MIDDLEWARE_CLASSES = (
# catches any uncaught RateLimitExceptions and returns a 403 instead of a 500 # catches any uncaught RateLimitExceptions and returns a 403 instead of a 500
'ratelimitbackend.middleware.RateLimitMiddleware', 'ratelimitbackend.middleware.RateLimitMiddleware',
# For A/B testing # For A/B testing
'waffle.middleware.WaffleMiddleware', 'waffle.middleware.WaffleMiddleware',
) )
...@@ -628,25 +628,49 @@ open_ended_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/open_end ...@@ -628,25 +628,49 @@ open_ended_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/open_end
notes_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/notes/**/*.coffee')) notes_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/notes/**/*.coffee'))
PIPELINE_CSS = { PIPELINE_CSS = {
'application': { 'style-vendor': {
'source_filenames': ['sass/application.css'], 'source_filenames': [
'output_filename': 'css/lms-application.css', 'css/vendor/font-awesome.css',
'css/vendor/jquery.qtip.min.css',
'css/vendor/responsive-carousel/responsive-carousel',
'css/vendor/responsive-carousel/responsive-carousel.slide',
],
'output_filename': 'css/lms-style-vendor.css',
}, },
'course': { 'style-app': {
'source_filenames': [
'sass/application.css',
'sass/ie.css'
],
'output_filename': 'css/lms-style-app.css',
},
'style-app-extend1': {
'source_filenames': [
'sass/application-extend1.css',
],
'output_filename': 'css/lms-style-app-extend1.css',
},
'style-app-extend2': {
'source_filenames': [
'sass/application-extend2.css',
],
'output_filename': 'css/lms-style-app-extend2.css',
},
'style-course-vendor': {
'source_filenames': [ 'source_filenames': [
'js/vendor/CodeMirror/codemirror.css', 'js/vendor/CodeMirror/codemirror.css',
'css/vendor/jquery.treeview.css', 'css/vendor/jquery.treeview.css',
'css/vendor/ui-lightness/jquery-ui-1.8.22.custom.css', 'css/vendor/ui-lightness/jquery-ui-1.8.22.custom.css',
'css/vendor/jquery.qtip.min.css',
'css/vendor/annotator.min.css', 'css/vendor/annotator.min.css',
],
'output_filename': 'css/lms-style-course-vendor.css',
},
'style-course': {
'source_filenames': [
'sass/course.css', 'sass/course.css',
'xmodule/modules.css', 'xmodule/modules.css',
], ],
'output_filename': 'css/lms-course.css', 'output_filename': 'css/lms-style-course.css',
},
'ie-fixes': {
'source_filenames': ['sass/ie.css'],
'output_filename': 'css/lms-ie.css',
}, },
} }
......
...@@ -230,3 +230,10 @@ ...@@ -230,3 +230,10 @@
footer .references { footer .references {
@include footer_references_style; @include footer_references_style;
} }
// ====================
// poor cascade made worse by CSS splitting requires us to redefine the dashboard views' visual top padding
.dashboard {
padding-top: 60px;
}
## NOTE: This Sass infrastructure is redundant, but needed in order to address an IE9 rule limit within CSS - http://blogs.msdn.com/b/ieinternals/archive/2011/05/14/10164546.aspx
// lms - css application architecture (platform)
// ====================
// libs and resets *do not edit*
@import 'bourbon/bourbon'; // lib - bourbon
// BASE *default edX offerings*
// ====================
// base - utilities
@import 'base/reset';
@import 'base/mixins';
@import 'base/variables';
## THEMING
## -------
## Set up this file to import an edX theme library if the environment
## indicates that a theme should be used. The assumption is that the
## theme resides outside of this main edX repository, in a directory
## called themes/<theme-name>/, with its base Sass file in
## themes/<theme-name>/static/sass/_<theme-name>.scss. That one entry
## point can be used to @import in as many other things as needed.
% if env.get('THEME_NAME') is not None:
// import theme's Sass overrides
@import '${env.get('THEME_NAME')}';
% endif
@import 'base/base';
// base - assets
@import 'base/font_face';
@import 'base/extends';
@import 'base/animations';
// base - starter
@import 'base/base';
// base - elements
@import 'elements/typography';
@import 'elements/controls';
// shared - platform
@import 'multicourse/home';
@import 'multicourse/dashboard';
@import 'multicourse/account';
@import 'multicourse/testcenter-register';
@import 'multicourse/courses';
@import 'multicourse/course_about';
@import 'multicourse/jobs';
@import 'multicourse/media-kit';
@import 'multicourse/about_pages';
@import 'multicourse/press_release';
@import 'multicourse/password_reset';
@import 'multicourse/error-pages';
@import 'multicourse/help';
@import 'multicourse/edge';
## NOTE: needed here for cascade and dependency purposes, but not a great permanent solution
@import 'shame'; // shame file - used for any bad-form/orphaned scss that knowingly violate edX FED architecture/standards (see - http://csswizardry.com/2013/04/shame-css/)
## NOTE: This Sass infrastructure is redundant, but needed in order to address an IE9 rule limit within CSS - http://blogs.msdn.com/b/ieinternals/archive/2011/05/14/10164546.aspx
// lms - css application architecture (platform)
// ====================
// libs and resets *do not edit*
@import 'bourbon/bourbon'; // lib - bourbon
// BASE *default edX offerings*
// ====================
// base - utilities
@import 'base/reset';
@import 'base/mixins';
@import 'base/variables';
## THEMING
## -------
## Set up this file to import an edX theme library if the environment
## indicates that a theme should be used. The assumption is that the
## theme resides outside of this main edX repository, in a directory
## called themes/<theme-name>/, with its base Sass file in
## themes/<theme-name>/static/sass/_<theme-name>.scss. That one entry
## point can be used to @import in as many other things as needed.
% if env.get('THEME_NAME') is not None:
// import theme's Sass overrides
@import '${env.get('THEME_NAME')}';
% endif
@import 'base/base';
// base - assets
@import 'base/font_face';
@import 'base/extends';
@import 'base/animations';
// base - starter
@import 'base/base';
// base - elements
@import 'elements/typography';
@import 'elements/controls';
// base - specific views
@import 'views/verification';
@import 'views/shoppingcart';
// applications
@import 'discussion';
@import 'news';
## NOTE: needed here for cascade and dependency purposes, but not a great permanent solution
@import 'shame'; // shame file - used for any bad-form/orphaned scss that knowingly violate edX FED architecture/standards (see - http://csswizardry.com/2013/04/shame-css/)
## Note: This Sass infrastructure is repeated in application-extend1 and application-extend2, but needed in order to address an IE9 rule limit within CSS - http://blogs.msdn.com/b/ieinternals/archive/2011/05/14/10164546.aspx
// lms - css application architecture // lms - css application architecture
// ==================== // ====================
// libs and resets *do not edit* // libs and resets *do not edit*
@import 'bourbon/bourbon'; // lib - bourbon @import 'bourbon/bourbon'; // lib - bourbon
// VENDOR + REBASE *referenced/used vendor presentation and reset*
// ====================
@import 'base/reset';
@import 'vendor/font-awesome';
@import 'vendor/responsive-carousel/responsive-carousel';
@import 'vendor/responsive-carousel/responsive-carousel.slide';
// BASE *default edX offerings* // BASE *default edX offerings*
// ==================== // ====================
// base - utilities
// base - utilities
@import 'base/reset';
@import 'base/mixins'; @import 'base/mixins';
@import 'base/variables'; @import 'base/variables';
...@@ -46,10 +41,6 @@ ...@@ -46,10 +41,6 @@
@import 'elements/typography'; @import 'elements/typography';
@import 'elements/controls'; @import 'elements/controls';
// base - specific views
@import 'views/verification';
@import 'views/shoppingcart';
// shared - course // shared - course
@import 'shared/forms'; @import 'shared/forms';
@import 'shared/footer'; @import 'shared/footer';
...@@ -60,24 +51,5 @@ ...@@ -60,24 +51,5 @@
@import 'shared/activation_messages'; @import 'shared/activation_messages';
@import 'shared/unsubscribe'; @import 'shared/unsubscribe';
// shared - platform ## NOTE: needed here for cascade and dependency purposes, but not a great permanent solution
@import 'multicourse/home';
@import 'multicourse/dashboard';
@import 'multicourse/account';
@import 'multicourse/testcenter-register';
@import 'multicourse/courses';
@import 'multicourse/course_about';
@import 'multicourse/jobs';
@import 'multicourse/media-kit';
@import 'multicourse/about_pages';
@import 'multicourse/press_release';
@import 'multicourse/password_reset';
@import 'multicourse/error-pages';
@import 'multicourse/help';
@import 'multicourse/edge';
// applications
@import 'discussion';
@import 'news';
@import 'shame'; // shame file - used for any bad-form/orphaned scss that knowingly violate edX FED architecture/standards (see - http://csswizardry.com/2013/04/shame-css/) @import 'shame'; // shame file - used for any bad-form/orphaned scss that knowingly violate edX FED architecture/standards (see - http://csswizardry.com/2013/04/shame-css/)
...@@ -194,3 +194,92 @@ ...@@ -194,3 +194,92 @@
%t-weight5 { %t-weight5 {
font-weight: 700; font-weight: 700;
} }
// ====================
// MISC: extends - type
// application: canned headings
%hd-lv1 {
@extend %t-title1;
@extend %t-weight1;
color: $m-gray-d4;
margin: 0 0 ($baseline*2) 0;
}
%hd-lv2 {
@extend %t-title4;
@extend %t-weight1;
margin: 0 0 ($baseline*0.75) 0;
border-bottom: 1px solid $m-gray-l3;
padding-bottom: ($baseline/2);
color: $m-gray-d4;
}
%hd-lv3 {
@extend %t-title6;
@extend %t-weight4;
margin: 0 0 ($baseline/4) 0;
color: $m-gray-d4;
}
%hd-lv4 {
@extend %t-title6;
@extend %t-weight2;
margin: 0 0 $baseline 0;
color: $m-gray-d4;
}
%hd-lv5 {
@extend %t-title7;
@extend %t-weight4;
margin: 0 0 ($baseline/4) 0;
color: $m-gray-d4;
}
// application: canned copy
%copy-base {
@extend %t-copy-base;
color: $m-gray-d2;
}
%copy-lead1 {
@extend %t-copy-lead2;
color: $m-gray;
}
%copy-detail {
@extend %t-copy-sub1;
@extend %t-weight3;
color: $m-gray-d1;
}
%copy-metadata {
@extend %t-copy-sub2;
color: $m-gray-d1;
%copy-metadata-value {
@extend %t-weight2;
}
%copy-metadata-value {
@extend %t-weight4;
}
}
// application: canned links
%copy-link {
border-bottom: 1px dotted transparent;
&:hover, &:active {
border-color: $link-color-d1;
}
}
%copy-badge {
@extend %t-title8;
@extend %t-weight5;
border-radius: ($baseline/5);
padding: ($baseline/2) $baseline;
text-transform: uppercase;
}
...@@ -2,184 +2,188 @@ ...@@ -2,184 +2,188 @@
@import "base/variables"; @import "base/variables";
// These are all quick solutions for IE please rewrite // These are all quick solutions for IE please rewrite
//Make overlay white because ie doesn't like rgba .ie {
.highlighted-courses .courses .course header.course-preview, .find-courses .courses .course header.course-preview,
.home .highlighted-courses > h2, .home .highlighted-courses > section.outside-app h1, section.outside-app .home .highlighted-courses > h1,
header.global {
background: #FFF;
}
// hide all actions //Make overlay white because ie doesn't like rgba
.home > header .title .actions, .highlighted-courses .courses .course header.course-preview, .find-courses .courses .course header.course-preview,
.home > header .title:hover .actions { .home .highlighted-courses > h2, .home .highlighted-courses > section.outside-app h1, section.outside-app .home .highlighted-courses > h1,
display: none; header.global {
height: auto; background: #FFF;
} }
// hide all actions
.home > header .title .actions,
.home > header .title:hover .actions {
display: none;
height: auto;
}
.home > header .title { .home > header .title {
&:hover { &:hover {
> hgroup { > hgroup {
h1 { h1 {
border-bottom: 0; border-bottom: 0;
padding-bottom: 0; padding-bottom: 0;
} }
h2 { h2 {
opacity: 1.0; opacity: 1.0;
}
} }
}
.actions { .actions {
opacity: 0; opacity: 0;
}
} }
} }
}
// because ie doesn't like :last // because ie doesn't like :last
.last { .last {
margin-right: 0 !important; margin-right: 0 !important;
}
// make partners not animate
.home .university-partners .partners a {
.name {
position: static;
} }
&:hover { // make partners not animate
text-decoration: none; .home .university-partners .partners a {
&::before {
opacity: 1.0;
}
.name { .name {
bottom: 0px; position: static;
} }
img { &:hover {
top: 0px; text-decoration: none;
}
}
} &::before {
opacity: 1.0;
}
.home .university-partners .partners { .name {
width: 660px; bottom: 0px;
}
li.partner { img {
float: left; top: 0px;
display: block; }
padding: 0; }
width: 220px;
overflow: hidden;
}
}
// make animations on homepage not animate and show everything
.highlighted-courses .courses .course, .find-courses .courses .course {
.meta-info {
display: none;
} }
.inner-wrapper { .home .university-partners .partners {
height: 100%; width: 660px;
overflow: visible;
position: relative; li.partner {
float: left;
display: block;
padding: 0;
width: 220px;
overflow: hidden;
}
} }
header.course-preview { // make animations on homepage not animate and show everything
left: 0px; .highlighted-courses .courses .course, .find-courses .courses .course {
position: relative; .meta-info {
top: 0px; display: none;
width: 100%; }
z-index: 3;
height: auto;
hgroup { .inner-wrapper {
height: 100%;
overflow: visible;
position: relative; position: relative;
right: 0;
top: 0;
} }
} header.course-preview {
left: 0px;
position: relative;
top: 0px;
width: 100%;
z-index: 3;
height: auto;
.info { hgroup {
height: auto; position: relative;
position: static; right: 0;
overflow: visible; top: 0;
}
.desc {
height: auto;
} }
}
&:hover {
background: rgb(245,245,245);
border-color: rgb(170,170,170);
box-shadow: 0 1px 16px 0 rgba($blue, 0.4);
.info { .info {
top: 0; height: auto;
} position: static;
overflow: visible;
.meta-info { .desc {
opacity: 0; height: auto;
}
} }
}
}
// make overlay flat black since IE cant handle rgba &:hover {
#lean_overlay { background: rgb(245,245,245);
background: #000; border-color: rgb(170,170,170);
} box-shadow: 0 1px 16px 0 rgba($blue, 0.4);
// active navigation .info {
nav.course-material ol.course-tabs li a.active, nav.course-material .xmodule_SequenceModule nav.sequence-nav ol.course-tabs li a.seq_video.active, .xmodule_SequenceModule nav.sequence-nav nav.course-material ol.course-tabs li a.seq_video.active { top: 0;
background-color: #333; }
background-color: rgba(0, 0, 0, .4);
}
// make dropdown user consistent size .meta-info {
header.global ol.user > li.primary a.dropdown { opacity: 0;
padding-top: 6px; }
padding-bottom: 6px; }
} }
// always hide arrow in IE // make overlay flat black since IE cant handle rgba
.dashboard .my-courses .my-course .cover .arrow { #lean_overlay {
display: none; background: #000;
} }
.ie-banner { // active navigation
display: block !important; nav.course-material ol.course-tabs li a.active, nav.course-material .xmodule_SequenceModule nav.sequence-nav ol.course-tabs li a.seq_video.active, .xmodule_SequenceModule nav.sequence-nav nav.course-material ol.course-tabs li a.seq_video.active {
} background-color: #333;
background-color: rgba(0, 0, 0, .4);
}
div.course-wrapper { // make dropdown user consistent size
display: block !important; header.global ol.user > li.primary a.dropdown {
padding-top: 6px;
padding-bottom: 6px;
}
section.course-content, // always hide arrow in IE
section.course-index { .dashboard .my-courses .my-course .cover .arrow {
display: block !important; display: none;
float: left;
} }
section.course-content { .ie-banner {
width: 71.27%; display: block !important;
} }
}
.sidebar { div.course-wrapper {
float: left !important; display: block !important;
display: block !important;
}
.sequence-nav ol { section.course-content,
display: block !important; section.course-index {
display: block !important;
float: left;
}
li { section.course-content {
width: 71.27%;
}
}
.sidebar {
float: left !important; float: left !important;
width: 50px; display: block !important;
} }
.sequence-nav ol {
display: block !important;
li {
float: left !important;
width: 50px;
}
}
} }
// lms - views - verification flow // lms - views - verification flow
// ==================== // ====================
// MISC: extends - type // MISC: extends - button
// application: canned headings
%hd-lv1 {
@extend %t-title1;
@extend %t-weight1;
color: $m-gray-d4;
margin: 0 0 ($baseline*2) 0;
}
%hd-lv2 {
@extend %t-title4;
@extend %t-weight1;
margin: 0 0 ($baseline*0.75) 0;
border-bottom: 1px solid $m-gray-l3;
padding-bottom: ($baseline/2);
color: $m-gray-d4;
}
%hd-lv3 {
@extend %t-title6;
@extend %t-weight4;
margin: 0 0 ($baseline/4) 0;
color: $m-gray-d4;
}
%hd-lv4 {
@extend %t-title6;
@extend %t-weight2;
margin: 0 0 $baseline 0;
color: $m-gray-d4;
}
%hd-lv5 {
@extend %t-title7;
@extend %t-weight4;
margin: 0 0 ($baseline/4) 0;
color: $m-gray-d4;
}
// application: canned copy
%copy-base {
@extend %t-copy-base;
color: $m-gray-d2;
}
%copy-lead1 {
@extend %t-copy-lead2;
color: $m-gray;
}
%copy-detail {
@extend %t-copy-sub1;
@extend %t-weight3;
color: $m-gray-d1;
}
%copy-metadata {
@extend %t-copy-sub2;
color: $m-gray-d1;
%copy-metadata-value {
@extend %t-weight2;
}
%copy-metadata-value {
@extend %t-weight4;
}
}
// application: canned links
%copy-link {
border-bottom: 1px dotted transparent;
&:hover, &:active {
border-color: $link-color-d1;
}
}
%copy-badge {
@extend %t-title8;
@extend %t-weight5;
border-radius: ($baseline/5);
padding: ($baseline/2) $baseline;
text-transform: uppercase;
}
// ====================
%btn-verify-primary { %btn-verify-primary {
@extend %btn-primary-green; @extend %btn-primary-green;
} }
......
...@@ -6,7 +6,8 @@ ...@@ -6,7 +6,8 @@
<%block name="title"><title>${_("Courseware")} - ${settings.PLATFORM_NAME}</title></%block> <%block name="title"><title>${_("Courseware")} - ${settings.PLATFORM_NAME}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%include file="/courseware/course_navigation.html" args="active_page='courseware'" /> <%include file="/courseware/course_navigation.html" args="active_page='courseware'" />
......
...@@ -5,8 +5,11 @@ ...@@ -5,8 +5,11 @@
<%block name="title"><title>${_("{course_number} Courseware").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Courseware").format(course_number=course.display_number_with_default) | h}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%include file="../discussion/_js_head_dependencies.html" /> <%static:css group='style-course'/>
<%include file="../discussion/_js_head_dependencies.html" />
% if show_chat: % if show_chat:
<link rel="stylesheet" href="${static.url('css/vendor/ui-lightness/jquery-ui-1.8.22.custom.css')}" /> <link rel="stylesheet" href="${static.url('css/vendor/ui-lightness/jquery-ui-1.8.22.custom.css')}" />
## It'd be better to have this in a place like lms/css/vendor/candy, ## It'd be better to have this in a place like lms/css/vendor/candy,
......
...@@ -11,7 +11,8 @@ ...@@ -11,7 +11,8 @@
</%block> </%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<style type="text/css"> <style type="text/css">
% for (grade, _), color in zip(ordered_grades, ['green', 'Chocolate']): % for (grade, _), color in zip(ordered_grades, ['green', 'Chocolate']):
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course.display_number_with_default} Course Info").format(course=course) | h}</title></%block> <%block name="title"><title>${_("{course.display_number_with_default} Course Info").format(course=course) | h}</title></%block>
......
...@@ -4,7 +4,9 @@ ...@@ -4,7 +4,9 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.axislabels.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.axislabels.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/jquery-jvectormap-1.1.1/jquery-jvectormap-1.1.1.min.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/jquery-jvectormap-1.1.1/jquery-jvectormap-1.1.1.min.js')}"></script>
......
...@@ -5,7 +5,8 @@ ...@@ -5,7 +5,8 @@
<%block name="title"><title>${_("News - MITx 6.002x")}</title></%block> <%block name="title"><title>${_("News - MITx 6.002x")}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="js_extra"> <%block name="js_extra">
......
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%namespace name="progress_graph" file="/courseware/progress_graph.js"/> <%namespace name="progress_graph" file="/courseware/progress_graph.js"/>
......
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${course.display_number_with_default | h} ${tab['name']}</title></%block> <%block name="title"><title>${course.display_number_with_default | h} ${tab['name']}</title></%block>
......
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course.display_number_with_default} Course Info").format(course=course) | h}</title></%block> <%block name="title"><title>${_("{course.display_number_with_default} Course Info").format(course=course) | h}</title></%block>
......
...@@ -9,8 +9,10 @@ ...@@ -9,8 +9,10 @@
<%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%include file="_js_head_dependencies.html" /> <%static:css group='style-course'/>
<%include file="_js_head_dependencies.html" />
</%block> </%block>
<%block name="js_extra"> <%block name="js_extra">
...@@ -28,7 +30,7 @@ ...@@ -28,7 +30,7 @@
<div class="discussion-column"> <div class="discussion-column">
</div> </div>
</div> </div>
</section> </section>
<%include file="_underscore_templates.html" /> <%include file="_underscore_templates.html" />
<%include file="_thread_list_template.html" /> <%include file="_thread_list_template.html" />
...@@ -10,7 +10,9 @@ ...@@ -10,7 +10,9 @@
<%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<%include file="_js_head_dependencies.html" /> <%include file="_js_head_dependencies.html" />
</%block> </%block>
......
...@@ -7,7 +7,9 @@ ...@@ -7,7 +7,9 @@
<%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("Discussion - {course_number}").format(course_number=course.display_number_with_default) | h}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<%include file="_js_head_dependencies.html" /> <%include file="_js_head_dependencies.html" />
</%block> </%block>
......
...@@ -4,7 +4,9 @@ ...@@ -4,7 +4,9 @@
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.axislabels.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.axislabels.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/jquery-jvectormap-1.1.1/jquery-jvectormap-1.1.1.min.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/jquery-jvectormap-1.1.1/jquery-jvectormap-1.1.1.min.js')}"></script>
...@@ -25,14 +27,14 @@ ...@@ -25,14 +27,14 @@
var i = 1 var i = 1
$(".hint-select").each(function(){ $(".hint-select").each(function(){
if ($(this).is(":checked")) { if ($(this).is(":checked")) {
data_dict[i] = [$(this).parent().attr("data-problem"), data_dict[i] = [$(this).parent().attr("data-problem"),
$(this).parent().attr("data-answer"), $(this).parent().attr("data-answer"),
$(this).parent().attr("data-pk")]; $(this).parent().attr("data-pk")];
i += 1 i += 1
} }
}); });
$.ajax(window.location.pathname, { $.ajax(window.location.pathname, {
type: "POST", type: "POST",
data: data_dict, data: data_dict,
success: update_contents success: update_contents
}); });
...@@ -42,16 +44,16 @@ ...@@ -42,16 +44,16 @@
var data_dict = {'op': 'change votes', var data_dict = {'op': 'change votes',
'field': field} 'field': field}
for (var i=0; i<changed_votes.length; i++) { for (var i=0; i<changed_votes.length; i++) {
data_dict[i] = [$(changed_votes[i]).parent().attr("data-problem"), data_dict[i] = [$(changed_votes[i]).parent().attr("data-problem"),
$(changed_votes[i]).parent().attr("data-answer"), $(changed_votes[i]).parent().attr("data-answer"),
$(changed_votes[i]).parent().attr("data-pk"), $(changed_votes[i]).parent().attr("data-pk"),
$(changed_votes[i]).val()]; $(changed_votes[i]).val()];
} }
$.ajax(window.location.pathname, { $.ajax(window.location.pathname, {
type: "POST", type: "POST",
data: data_dict, data: data_dict,
success: update_contents success: update_contents
}); });
}); });
$("#switch-fields").click(function(){ $("#switch-fields").click(function(){
...@@ -61,7 +63,7 @@ ...@@ -61,7 +63,7 @@
type: "POST", type: "POST",
data: out_dict, data: out_dict,
success: update_contents success: update_contents
}); });
}); });
...@@ -87,14 +89,14 @@ ...@@ -87,14 +89,14 @@
var i = 1 var i = 1
$(".hint-select").each(function(){ $(".hint-select").each(function(){
if ($(this).is(":checked")) { if ($(this).is(":checked")) {
data_dict[i] = [$(this).parent().attr("data-problem"), data_dict[i] = [$(this).parent().attr("data-problem"),
$(this).parent().attr("data-answer"), $(this).parent().attr("data-answer"),
$(this).parent().attr("data-pk")]; $(this).parent().attr("data-pk")];
i += 1 i += 1
} }
}); });
$.ajax(window.location.pathname, { $.ajax(window.location.pathname, {
type: "POST", type: "POST",
data: data_dict, data: data_dict,
success: update_contents success: update_contents
}); });
...@@ -102,7 +104,7 @@ ...@@ -102,7 +104,7 @@
} }
$(document).ready(setup); $(document).ready(setup);
function update_contents(data, status, jqXHR) { function update_contents(data, status, jqXHR) {
$('.instructor-dashboard-content').html(data.contents); $('.instructor-dashboard-content').html(data.contents);
setup(); setup();
......
...@@ -17,7 +17,8 @@ ...@@ -17,7 +17,8 @@
## 6. And tests go in lms/djangoapps/instructor/tests/ ## 6. And tests go in lms/djangoapps/instructor/tests/
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<script type="text/javascript" src="${static.url('js/vendor/underscore-min.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/underscore-min.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/mustache.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/mustache.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script> <script type="text/javascript" src="${static.url('js/vendor/flot/jquery.flot.js')}"></script>
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course_number} Staff Grading").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Staff Grading").format(course_number=course.display_number_with_default) | h}</title></%block>
......
...@@ -16,9 +16,10 @@ ...@@ -16,9 +16,10 @@
</%def> </%def>
<!DOCTYPE html> <!DOCTYPE html>
<!--[if lt IE 8]><html class="ie"><![endif]--> <!--[if IE 7]><html class="ie ie7 lte9 lte8 lte7"><![endif]-->
<!--[if IE 8]><html class="ie8"><![endif]--> <!--[if IE 8]><html class="ie ie8 lte9 lte8"><![endif]-->
<!--[if gte IE 9]><!--><html><!--<![endif]--> <!--[if IE 9]><html class="ie ie9 lte9"><![endif]-->
<!--[if gt IE 9]><!--><html><!--<![endif]-->
<head> <head>
<%block name="title"> <%block name="title">
% if stanford_theme_enabled(): % if stanford_theme_enabled():
...@@ -45,21 +46,22 @@ ...@@ -45,21 +46,22 @@
<link rel="icon" type="image/x-icon" href="${static.url(settings.FAVICON_PATH)}" /> <link rel="icon" type="image/x-icon" href="${static.url(settings.FAVICON_PATH)}" />
<%static:css group='application'/> <%static:css group='style-vendor'/>
<%static:css group='style-app'/>
<%static:css group='style-app-extend1'/>
<%static:css group='style-app-extend2'/>
<%static:js group='main_vendor'/> <%static:js group='main_vendor'/>
<%block name="headextra"/> <%block name="headextra"/>
% if theme_enabled(): % if theme_enabled():
<%include file="theme-head-extra.html" /> <%include file="theme-head-extra.html" />
% endif % endif
<!--[if lt IE 9]> <!--[if lt IE 9]>
<script src="${static.url('js/html5shiv.js')}"></script> <script src="${static.url('js/html5shiv.js')}"></script>
<![endif]--> <![endif]-->
<!--[if lte IE 9]>
<%static:css group='ie-fixes'/>
<![endif]-->
<meta name="path_prefix" content="${MITX_ROOT_URL}"> <meta name="path_prefix" content="${MITX_ROOT_URL}">
<meta name="google-site-verification" content="_mipQ4AtZQDNmbtOkwehQDOgCxUUV2fb_C0b6wbiRHY" /> <meta name="google-site-verification" content="_mipQ4AtZQDNmbtOkwehQDOgCxUUV2fb_C0b6wbiRHY" />
......
...@@ -19,9 +19,6 @@ ...@@ -19,9 +19,6 @@
<script src="${static.url('js/html5shiv.js')}"></script> <script src="${static.url('js/html5shiv.js')}"></script>
<![endif]--> <![endif]-->
<!--[if lte IE 9]>
<%static:css group='ie-fixes'/>
<![endif]-->
<meta name="path_prefix" content="{{MITX_ROOT_URL}}"> <meta name="path_prefix" content="{{MITX_ROOT_URL}}">
</head> </head>
......
<%namespace name='static' file='static_content.html'/> <%namespace name='static' file='static_content.html'/>
<!DOCTYPE html> <!DOCTYPE html>
<html class="view-iframe"> <!--[if IE 7]><html class="ie ie7 lte9 lte8 lte7 view-iframe"><![endif]-->
<!--[if IE 8]><html class="ie ie8 lte9 lte8 view-iframe"><![endif]-->
<!--[if IE 9]><html class="ie ie9 lte9 view-iframe"><![endif]-->
<!--[if gt IE 9]><!--><html class="view-iframe"><!--<![endif]-->
<head> <head>
<%block name="title"></%block> <%block name="title"></%block>
...@@ -8,17 +11,15 @@ ...@@ -8,17 +11,15 @@
<meta name="path_prefix" content="${MITX_ROOT_URL}" /> <meta name="path_prefix" content="${MITX_ROOT_URL}" />
<meta name="google-site-verification" content="_mipQ4AtZQDNmbtOkwehQDOgCxUUV2fb_C0b6wbiRHY" /> <meta name="google-site-verification" content="_mipQ4AtZQDNmbtOkwehQDOgCxUUV2fb_C0b6wbiRHY" />
<%static:css group='application'/> <%static:css group='style-vendor'/>
<%static:css group='style-app'/>
<%static:js group='main_vendor'/> <%static:js group='main_vendor'/>
<!--[if IE]> <!--[if lt IE 9]>
<script src="${static.url('js/html5shiv.js')}"></script> <script src="${static.url('js/html5shiv.js')}"></script>
<![endif]--> <![endif]-->
<!--[if lte IE 9]>
<%static:css group='ie-fixes'/>
<![endif]-->
<%block name="headextra"/> <%block name="headextra"/>
% if not course: % if not course:
......
...@@ -7,8 +7,10 @@ ...@@ -7,8 +7,10 @@
%> %>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:js group='courseware'/> <%static:css group='style-course'/>
<%static:js group='courseware'/>
<style type="text/css"> <style type="text/css">
blockquote { blockquote {
background:#f9f9f9; background:#f9f9f9;
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course_number} Combined Notifications").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Combined Notifications").format(course_number=course.display_number_with_default) | h}</title></%block>
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course_number} Flagged Open Ended Problems").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Flagged Open Ended Problems").format(course_number=course.display_number_with_default) | h}</title></%block>
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<%namespace name='static' file='/static_content.html'/> <%namespace name='static' file='/static_content.html'/>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
</%block> </%block>
<%block name="title"><title>${_("{course_number} Open Ended Problems").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Open Ended Problems").format(course_number=course.display_number_with_default) | h}</title></%block>
......
...@@ -6,7 +6,8 @@ ...@@ -6,7 +6,8 @@
</%block> </%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<%static:js group='courseware'/> <%static:js group='courseware'/>
</%block> </%block>
......
...@@ -9,7 +9,8 @@ ...@@ -9,7 +9,8 @@
</%block> </%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<%static:js group='courseware'/> <%static:js group='courseware'/>
<link rel="stylesheet" href="/static/css/pdfviewer.css"/> <link rel="stylesheet" href="/static/css/pdfviewer.css"/>
<script type="text/javascript" src="/static/js/vendor/pdfjs/pdf.js"></script> <script type="text/javascript" src="/static/js/vendor/pdfjs/pdf.js"></script>
......
...@@ -5,7 +5,9 @@ ...@@ -5,7 +5,9 @@
<%block name="title"><title>${_("{course_number} Textbook").format(course_number=course.display_number_with_default) | h}</title></%block> <%block name="title"><title>${_("{course_number} Textbook").format(course_number=course.display_number_with_default) | h}</title></%block>
<%block name="headextra"> <%block name="headextra">
<%static:css group='course'/> <%static:css group='style-course-vendor'/>
<%static:css group='style-course'/>
<%static:js group='courseware'/> <%static:js group='courseware'/>
</%block> </%block>
......
...@@ -2,26 +2,26 @@ ...@@ -2,26 +2,26 @@
<%namespace name='static' file='static_content.html'/> <%namespace name='static' file='static_content.html'/>
<!DOCTYPE html> <!DOCTYPE html>
<html> <!--[if IE 7]><html class="ie ie7 lte9 lte8 lte7"><![endif]-->
<!--[if IE 8]><html class="ie ie8 lte9 lte8"><![endif]-->
<!--[if IE 9]><html class="ie ie9 lte9"><![endif]-->
<!--[if gt IE 9]><!--><html><!--<![endif]-->
<head> <head>
## "edX" should not be translated ## "edX" should not be translated
<%block name="title"><title>edX</title></%block> <%block name="title"><title>edX</title></%block>
<link rel="icon" type="image/x-icon" href="${static.url('images/favicon.ico')}" /> <link rel="icon" type="image/x-icon" href="${static.url('images/favicon.ico')}" />
<%static:css group='application'/> <%static:css group='style-vendor'/>
<%static:css group='style-app'/>
<%static:js group='main_vendor'/> <%static:js group='main_vendor'/>
<%block name="headextra"/> <%block name="headextra"/>
<!--[if lt IE 9]> <!--[if lt IE 9]>
<script src="${static.url('js/html5shiv.js')}"></script> <script src="${static.url('js/html5shiv.js')}"></script>
<![endif]--> <![endif]-->
<!--[if lte IE 9]>
<%static:css group='ie-fixes'/>
<![endif]-->
<meta name="path_prefix" content="${MITX_ROOT_URL}"> <meta name="path_prefix" content="${MITX_ROOT_URL}">
</head> </head>
......
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