From 5908d844b87df491e04f8828551485f0d2c2c9ee Mon Sep 17 00:00:00 2001 From: Kyle Fiedler Date: Fri, 22 Jun 2012 16:21:51 -0400 Subject: [PATCH 1/4] Added styles to be more consistant across pages --- cms/static/sass/_module-header.scss | 125 ---------- cms/static/sass/_problem.scss | 238 ++++++++++++++---- cms/static/sass/_week.scss | 302 ++++++++++------------- cms/static/sass/base-style.scss | 2 +- cms/templates/unit.html | 19 +- cms/templates/widgets/html-edit.html | 58 +++++ cms/templates/widgets/problem-edit.html | 118 ++++----- cms/templates/widgets/sequence-edit.html | 201 +++++++-------- 8 files changed, 527 insertions(+), 536 deletions(-) delete mode 100644 cms/static/sass/_module-header.scss diff --git a/cms/static/sass/_module-header.scss b/cms/static/sass/_module-header.scss deleted file mode 100644 index 03acbecd9b..0000000000 --- a/cms/static/sass/_module-header.scss +++ /dev/null @@ -1,125 +0,0 @@ -section.video-new, -section.video-edit, -section.problem-new, -section.problem-edit, -section.html-edit { - background: #fff; - border: 1px solid #333; - border-right: 0; - - > header { - background: #eee; - @include clearfix; - padding: 6px; - border-bottom: 1px solid #333; - -webkit-font-smoothing: antialiased; - - h2 { - float: left; - font-size: 14px; - } - - a { - color: #fff; - - &.save-update { - float: right; - } - - &.cancel { - float: left; - } - } - - } - - > section { - padding: 20px; - - > header { - h1 { - font-size: 24px; - margin: 12px 0; - } - - section { - &.status-settings { - ul { - list-style: none; - @include border-radius(2px); - border: 1px solid #999; - @include inline-block(); - - li { - @include inline-block(); - border-right: 1px solid #999; - padding: 6px; - - &:last-child { - border-right: 0; - } - - &.current { - background: #eee; - } - } - } - - a.settings { - @include inline-block(); - margin: 0 20px; - border: 1px solid #999; - padding: 6px; - } - - select { - float: right; - } - } - - &.meta { - background: #eee; - padding: 10px; - margin: 20px 0; - @include clearfix(); - - div { - float: left; - margin-right: 20px; - - h2 { - font-size: 14px; - @include inline-block(); - } - - p { - @include inline-block(); - } - } - } - } - } - - section.notes { - margin-top: 20px; - padding: 6px; - background: #eee; - border: 1px solid #ccc; - - textarea { - @include box-sizing(border-box); - display: block; - width: 100%; - } - - h2 { - font-size: 14px; - margin-bottom: 6px; - } - - input[type="submit"]{ - margin-top: 10px; - } - } - } -} diff --git a/cms/static/sass/_problem.scss b/cms/static/sass/_problem.scss index 39df062cde..fa2657c0d1 100644 --- a/cms/static/sass/_problem.scss +++ b/cms/static/sass/_problem.scss @@ -4,68 +4,200 @@ section#unit-wrapper { @include clearfix(); padding: 6px 20px; - h1 { - font-size: 18px; - text-transform: uppercase; - letter-spacing: 1px; + section { float: left; + + h1 { + font-size: 16px; + text-transform: uppercase; + letter-spacing: 1px; + @include inline-block(); + } + + p { + @include inline-block(); + margin-left: 10px; + color: #999; + font-size: 12px; + font-style: italic; + } } - p { + div { float: right; + color: #666; } } + > section { padding: 20px; - a.save-update { - @extend .button; - @include inline-block(); + + section.meta { + section { + &.status-settings { + float: left; + margin-bottom: 10px; + + ul { + list-style: none; + @include border-radius(2px); + border: 1px solid #999; + @include inline-block(); + + li { + @include inline-block(); + border-right: 1px solid #999; + padding: 6px; + + &:last-child { + border-right: 0; + } + + &.current { + background: #eee; + } + } + } + + a.settings { + @include inline-block(); + margin: 0 20px; + border: 1px solid #999; + padding: 6px; + } + + select { + float: right; + } + } + + &.author { + float: right; + + dl { + dt { + font-weight: bold; + } + + dd, dt { + @include inline-block(); + } + } + } + + &.tags { + background: #eee; + padding: 10px; + margin: 0 0 20px; + @include clearfix(); + clear: both; + + div { + float: left; + margin-right: 20px; + + h2 { + font-size: 14px; + @include inline-block(); + } + + p { + @include inline-block(); + } + } + } + } + } + + //general styles for main content + textarea { + @include box-sizing(border-box); + display: block; + width: 100%; + } + + div.preview { + background: #eee; + @include box-sizing(border-box); + min-height: 40px; + padding: 10px; + width: 100%; + margin-top: 10px; + + h1 { + font-size: 24px; + margin-bottom: 1em; + } + + h2 { + font-size: 20px; + margin-bottom: 1em; + } + + h3 { + font-size: 18; + margin-bottom: 1em; + } + + ul { + padding-left: 20px; + margin-bottom: 1em; + } + + p { + margin-bottom: 1em; + } + } + + //notes + section.notes { margin-top: 20px; + padding: 20px 0 0; + border-top: 1px solid #ccc; + + h2 { + font-size: 14px; + margin-bottom: 6px; + } + + form { + margin-bottom: 20px; + + textarea { + @include box-sizing(border-box); + display: block; + width: 100%; + } + + input[type="submit"]{ + margin-top: 10px; + } + } + + ul { + list-style: none; + + li { + margin-bottom: 20px; + + p { + margin-bottom: 10px; + + &.author { + font-style: italic; + color: #999; + } + } + } + } + } + + div.actions { + a.save-update { + @extend .button; + @include inline-block(); + margin-top: 20px; + } } } } - -section.problem-new, -section.problem-edit, -section.html-edit { - textarea { - @include box-sizing(border-box); - display: block; - width: 100%; - } - - - div.preview { - background: #eee; - @include box-sizing(border-box); - min-height: 40px; - padding: 10px; - width: 100%; - margin-top: 10px; - - h1 { - font-size: 24px; - margin-bottom: 1em; - } - - h2 { - font-size: 20px; - margin-bottom: 1em; - } - - h3 { - font-size: 18; - margin-bottom: 1em; - } - - ul { - padding-left: 20px; - margin-bottom: 1em; - } - - p { - margin-bottom: 1em; - } - } -} - diff --git a/cms/static/sass/_week.scss b/cms/static/sass/_week.scss index b638a36f5c..0aa42f99de 100644 --- a/cms/static/sass/_week.scss +++ b/cms/static/sass/_week.scss @@ -6,47 +6,6 @@ section.sequence-edit { border-bottom: 2px solid #333; @include clearfix(); - div { - @include clearfix(); - padding: 6px 20px; - - h1 { - font-size: 18px; - text-transform: uppercase; - letter-spacing: 1px; - float: left; - } - - p { - float: right; - } - - &.week { - background: #eee; - font-size: 12px; - border-bottom: 1px solid #ccc; - - h2 { - font-size: 12px; - @include inline-block(); - margin-right: 20px; - } - - ul { - list-style: none; - @include inline-block(); - - li { - @include inline-block(); - margin-right: 10px; - - p { - float: none; - } - } - } - } - } section.goals { background: #eee; @@ -68,121 +27,116 @@ section.sequence-edit { } } - > section.content { - @include box-sizing(border-box); - padding: 20px; + section.filters { + @include clearfix; + margin-bottom: 10px; + background: #efefef; + border: 1px solid #ddd; - section.filters { - @include clearfix; - margin-bottom: 10px; - background: #efefef; - border: 1px solid #ddd; + ul { + @include clearfix(); + list-style: none; + padding: 6px; - ul { - @include clearfix(); - list-style: none; - padding: 6px; + li { + @include inline-block(); - li { - @include inline-block(); - - &.advanced { - float: right; - } + &.advanced { + float: right; } } } + } - > div { - display: table; - border: 1px solid; - width: 100%; + > div { + display: table; + border: 1px solid; + width: 100%; - section { - header { - background: #eee; - padding: 6px; - border-bottom: 1px solid #ccc; - @include clearfix; + section { + header { + background: #eee; + padding: 6px; + border-bottom: 1px solid #ccc; + @include clearfix; - h2 { - text-transform: uppercase; - letter-spacing: 1px; - font-size: 12px; - float: left; + h2 { + text-transform: uppercase; + letter-spacing: 1px; + font-size: 12px; + float: left; + } + } + + &.modules { + @include box-sizing(border-box); + display: table-cell; + width: flex-grid(6, 9); + border-right: 1px solid #333; + + &.empty { + text-align: center; + vertical-align: middle; + + a { + @extend .button; + @include inline-block(); + margin-top: 10px; } } - &.modules { - @include box-sizing(border-box); - display: table-cell; - width: flex-grid(6, 9); - border-right: 1px solid #333; + ol { + list-style: none; + border-bottom: 1px solid #333; - &.empty { - text-align: center; - vertical-align: middle; - - a { - @extend .button; - @include inline-block(); - margin-top: 10px; - } - } - - ol { - list-style: none; + li { border-bottom: 1px solid #333; - li { - border-bottom: 1px solid #333; + &:last-child{ + border-bottom: 0; + } - &:last-child{ - border-bottom: 0; - } + a { + color: #000; + } - a { - color: #000; - } + ol { + list-style: none; - ol { - list-style: none; - - li { - padding: 6px; - - &:hover { - a.draggable { - opacity: 1; - } - } + li { + padding: 6px; + &:hover { a.draggable { - float: right; - opacity: .5; + opacity: 1; + } + } + + a.draggable { + float: right; + opacity: .5; + } + + &.group { + padding: 0; + + header { + padding: 6px; + background: none; + + h3 { + font-size: 14px; + } } - &.group { - padding: 0; - header { - padding: 6px; - background: none; - - h3 { - font-size: 14px; - } - } - - - ol { + ol { border-left: 4px solid #999; border-bottom: 0; - li { - &:last-child { - border-bottom: 0; - } + li { + &:last-child { + border-bottom: 0; } } } @@ -191,63 +145,63 @@ section.sequence-edit { } } } + } - &.scratch-pad { - @include box-sizing(border-box); - display: table-cell; - width: flex-grid(3, 9) + flex-gutter(9); - vertical-align: top; + &.scratch-pad { + @include box-sizing(border-box); + display: table-cell; + width: flex-grid(3, 9) + flex-gutter(9); + vertical-align: top; - ol { - list-style: none; + ol { + list-style: none; + border-bottom: 1px solid #999; + + li { border-bottom: 1px solid #999; + background: #f9f9f9; - li { - border-bottom: 1px solid #999; - background: #f9f9f9; + &:last-child { + border-bottom: 0; + } - &:last-child { - border-bottom: 0; - } + ul { + list-style: none; - ul { - list-style: none; + li { + padding: 6px; - li { - padding: 6px; - - &:last-child { - border-bottom: 0; - } - - &:hover { - a.draggable { - opacity: 1; - } - } - - &.empty { - padding: 12px; - - a { - @extend .button; - display: block; - text-align: center; - } - } + &:last-child { + border-bottom: 0; + } + &:hover { a.draggable { - float: right; - opacity: .3; - } - - a { - color: #000; + opacity: 1; } } - } + &.empty { + padding: 12px; + + a { + @extend .button; + display: block; + text-align: center; + } + } + + a.draggable { + float: right; + opacity: .3; + } + + a { + color: #000; + } + } } + } } } diff --git a/cms/static/sass/base-style.scss b/cms/static/sass/base-style.scss index 133e1bda1b..092e40d9c5 100644 --- a/cms/static/sass/base-style.scss +++ b/cms/static/sass/base-style.scss @@ -3,4 +3,4 @@ @import 'base'; @import 'calendar'; -@import 'week', 'video', 'problem', 'module-header'; +@import 'week', 'video', 'problem'; diff --git a/cms/templates/unit.html b/cms/templates/unit.html index c9a3d82b5a..92f54fe5d7 100644 --- a/cms/templates/unit.html +++ b/cms/templates/unit.html @@ -1,19 +1,16 @@
-

${name}

-

Unit type: ${type}

- - - - -
-
- ${contents} -
-
+
+

${name}

+

${type}

+
+ + +
+ ${contents}
diff --git a/cms/templates/widgets/html-edit.html b/cms/templates/widgets/html-edit.html index cbd8a7f3df..e34e8e6480 100644 --- a/cms/templates/widgets/html-edit.html +++ b/cms/templates/widgets/html-edit.html @@ -1,4 +1,62 @@
+
+ +
+ + Settings +
+ +
+
+
Last modified:
+
mm/dd/yy
+
By
+
Anant Agarwal
+
+
+ +
+
+

Tags:

+

Click to edit

+
+ +
+

Goal

+

Click to edit

+
+
+
+
${module.definition['data']['text']}
+ + + +
+

Add notes

+
+ + +
+ +
    +
  • +

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    +

    Anant Agarwal

    +
  • +
  • +

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    +

    Anant Agarwal

    +
  • +
+
diff --git a/cms/templates/widgets/problem-edit.html b/cms/templates/widgets/problem-edit.html index 991326c987..aa98c468fe 100644 --- a/cms/templates/widgets/problem-edit.html +++ b/cms/templates/widgets/problem-edit.html @@ -1,73 +1,61 @@
-
- Cancel - Save & Update -
- -
-
-

${module.name}

-
-
-

Last modified:

-

mm/dd/yy

-
- -
-

By

-

Anant Agarwal

-
-
- -
- - Settings - - -
-
-
-

Tags:

-

Click to edit

-
- -
-

Goal

-

Click to edit

-
-
-
- -
- -
- Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. -
+
+
+ + Settings
-
-

Add notes

+
+
+
Last modified:
+
mm/dd/yy
+
By
+
Anant Agarwal
+
+
+ +
+
+

Tags:

+

Click to edit

+
+ +
+

Goal

+

Click to edit

+
+
+
+ +
+ +
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. +
+
+ +
+

Add notes

+
+
-
    -
  • -

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    -

    Anant Agarwal

    -
  • -
  • -

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    -

    Anant Agarwal

    -
  • -
- - Save & Update +
    +
  • +

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    +

    Anant Agarwal

    +
  • +
  • +

    Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

    +

    Anant Agarwal

    +
  • +
+ diff --git a/cms/templates/widgets/sequence-edit.html b/cms/templates/widgets/sequence-edit.html index 219145aefb..62742edd3e 100644 --- a/cms/templates/widgets/sequence-edit.html +++ b/cms/templates/widgets/sequence-edit.html @@ -1,119 +1,106 @@
-
-
-

${module.name}

-

Module Type:${module.type}

-
-
+
+
    +
  • + + +
  • -
    -
    -
      +
    • + + +
    • +
    • + +
    • + +
    • + Advanced filters +
    • + +
    • + +
    • +
    +
    + +
    +
    +
    1. - - +
        + % for child in module.get_children(): +
      1. + ${child.name} + handle +
      2. + %endfor +
    2. -
    3. - - -
    4. -
    5. - -
    6. - -
    7. - Advanced filters -
    8. - -
    9. - -
    10. -
+
-
-
-
    -
  1. -
      - % for child in module.get_children(): -
    1. - ${child.name} - handle -
    2. - %endfor -
    -
  2. - - - - -
-
- -
-
    -
  1. -
    -

    Section Scratch

    -
    - +
  2. +
  3. +
    +

    Course Scratch

    +
    - -
  4. - - - - -
-
-
-
+ + + +
+
From 3081258836defd7e1362db5ba107ec4430518e4e Mon Sep 17 00:00:00 2001 From: Kyle Fiedler Date: Mon, 25 Jun 2012 11:21:15 -0400 Subject: [PATCH 2/4] Refactored the css and fixed some smaller bugs --- cms/static/coffee/main.coffee | 3 + cms/static/sass/_base.scss | 68 +++---------------- cms/static/sass/_calendar.scss | 1 - cms/static/sass/_layout.scss | 53 +++++++++++++++ cms/static/sass/{_week.scss => _section.scss} | 32 +-------- cms/static/sass/{_problem.scss => _unit.scss} | 20 +++--- cms/static/sass/_video.scss | 33 --------- cms/static/sass/base-style.scss | 4 +- cms/templates/unit.html | 3 +- cms/templates/widgets/html-edit.html | 19 +----- cms/templates/widgets/notes.html | 21 ++++++ cms/templates/widgets/problem-edit.html | 25 ++----- cms/templates/widgets/sequence-edit.html | 2 +- 13 files changed, 109 insertions(+), 175 deletions(-) create mode 100644 cms/static/sass/_layout.scss rename cms/static/sass/{_week.scss => _section.scss} (88%) rename cms/static/sass/{_problem.scss => _unit.scss} (93%) delete mode 100644 cms/static/sass/_video.scss create mode 100644 cms/templates/widgets/notes.html diff --git a/cms/static/coffee/main.coffee b/cms/static/coffee/main.coffee index 06b8701366..6535034faf 100644 --- a/cms/static/coffee/main.coffee +++ b/cms/static/coffee/main.coffee @@ -63,6 +63,9 @@ $ -> $('section.edit-pane').show() return false + $('a.module-edit').click -> + $('body.content .cal').css('height', contentHeight) + $(document).ready(setHeight) $(window).bind('resize', setHeight) diff --git a/cms/static/sass/_base.scss b/cms/static/sass/_base.scss index d961f461fd..6d1111980c 100644 --- a/cms/static/sass/_base.scss +++ b/cms/static/sass/_base.scss @@ -2,65 +2,14 @@ $fg-column: 70px; $fg-gutter: 26px; $fg-max-columns: 12; $body-font-family: "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", Geneva, Verdana, sans-serif; +$body-font-size: 14px; +$body-line-height: 20px; +// Base html styles html { height: 100%; } -body { - @include clearfix(); - height: 100%; - font: 14px $body-font-family; - - > section { - display: table; - width: 100%; - } - - > header { - background: #000; - color: #fff; - display: block; - float: none; - padding: 6px 20px; - width: 100%; - @include box-sizing(border-box); - - nav { - @include clearfix; - - h2 { - font-size: 14px; - text-transform: uppercase; - float: left; - } - - ul { - float: left; - - &.user-nav { - float: right; - } - - li { - @include inline-block(); - margin-left: 15px; - } - } - } - } - - &.content { - section.main-content { - border-left: 2px solid #000; - @include box-sizing(border-box); - width: flex-grid(9); - float: left; - @include box-shadow( -2px 0 3px #ddd ); - } - } -} - a { text-decoration: none; color: #888; @@ -77,6 +26,13 @@ input[type="submit"], .button { padding: 6px; } +textarea { + @include box-sizing(border-box); + display: block; + width: 100%; +} + +// Extends .new-module { position: relative; @@ -111,7 +67,3 @@ input[type="submit"], .button { display: block; float: right; } - -textarea { - overflow: auto; -} diff --git a/cms/static/sass/_calendar.scss b/cms/static/sass/_calendar.scss index fa10c65950..71f12f2425 100644 --- a/cms/static/sass/_calendar.scss +++ b/cms/static/sass/_calendar.scss @@ -49,7 +49,6 @@ section.cal { ol { list-style: none; @include clearfix; - @include box-sizing(border-box); border-left: 1px solid #333; border-top: 1px solid #333; width: 100%; diff --git a/cms/static/sass/_layout.scss b/cms/static/sass/_layout.scss new file mode 100644 index 0000000000..98f49940fd --- /dev/null +++ b/cms/static/sass/_layout.scss @@ -0,0 +1,53 @@ +body { + @include clearfix(); + height: 100%; + font: 14px $body-font-family; + + > section { + display: table; + width: 100%; + } + + > header { + background: #000; + color: #fff; + display: block; + float: none; + padding: 6px 20px; + width: 100%; + @include box-sizing(border-box); + + nav { + @include clearfix; + + h2 { + font-size: 14px; + text-transform: uppercase; + float: left; + } + + ul { + float: left; + + &.user-nav { + float: right; + } + + li { + @include inline-block(); + margin-left: 15px; + } + } + } + } + + &.content { + section.main-content { + border-left: 2px solid #000; + @include box-sizing(border-box); + width: flex-grid(9); + float: left; + @include box-shadow( -2px 0 3px #ddd ); + } + } +} diff --git a/cms/static/sass/_week.scss b/cms/static/sass/_section.scss similarity index 88% rename from cms/static/sass/_week.scss rename to cms/static/sass/_section.scss index 0aa42f99de..2048607565 100644 --- a/cms/static/sass/_week.scss +++ b/cms/static/sass/_section.scss @@ -1,32 +1,4 @@ -section.week-edit, -section.week-new, -section.sequence-edit { - - > header { - border-bottom: 2px solid #333; - @include clearfix(); - - - section.goals { - background: #eee; - padding: 6px 20px; - border-top: 1px solid #ccc; - - ul { - list-style: none; - color: #999; - - li { - margin-bottom: 6px; - - &:last-child { - margin-bottom: 0; - } - } - } - } - } - +section#unit-wrapper { section.filters { @include clearfix; margin-bottom: 10px; @@ -48,7 +20,7 @@ section.sequence-edit { } } - > div { + div.content { display: table; border: 1px solid; width: 100%; diff --git a/cms/static/sass/_problem.scss b/cms/static/sass/_unit.scss similarity index 93% rename from cms/static/sass/_problem.scss rename to cms/static/sass/_unit.scss index fa2657c0d1..f1e47d36be 100644 --- a/cms/static/sass/_problem.scss +++ b/cms/static/sass/_unit.scss @@ -26,6 +26,14 @@ section#unit-wrapper { div { float: right; color: #666; + + a { + &.cancel { + margin-right: 20px; + font-style: italic; + font-size: 12px; + } + } } } @@ -110,12 +118,6 @@ section#unit-wrapper { } //general styles for main content - textarea { - @include box-sizing(border-box); - display: block; - width: 100%; - } - div.preview { background: #eee; @include box-sizing(border-box); @@ -163,12 +165,6 @@ section#unit-wrapper { form { margin-bottom: 20px; - textarea { - @include box-sizing(border-box); - display: block; - width: 100%; - } - input[type="submit"]{ margin-top: 10px; } diff --git a/cms/static/sass/_video.scss b/cms/static/sass/_video.scss deleted file mode 100644 index b68176e2db..0000000000 --- a/cms/static/sass/_video.scss +++ /dev/null @@ -1,33 +0,0 @@ -section.video-new, section.video-edit { - > section { - - section.upload { - padding: 6px; - margin-bottom: 10px; - border: 1px solid #ddd; - - a.upload-button { - @extend .button; - @include inline-block(); - } - } - - section.in-use { - h2 { - font-size: 14px; - } - - div { - background: #eee; - text-align: center; - padding: 6px; - } - } - - a.save-update { - @extend .button; - @include inline-block(); - margin-top: 20px; - } - } -} diff --git a/cms/static/sass/base-style.scss b/cms/static/sass/base-style.scss index 092e40d9c5..3a6c6e0cea 100644 --- a/cms/static/sass/base-style.scss +++ b/cms/static/sass/base-style.scss @@ -1,6 +1,6 @@ @import 'bourbon/bourbon'; @import 'reset'; -@import 'base'; +@import 'base', 'layout'; @import 'calendar'; -@import 'week', 'video', 'problem'; +@import 'section', 'unit'; diff --git a/cms/templates/unit.html b/cms/templates/unit.html index 92f54fe5d7..8cc75cd3bf 100644 --- a/cms/templates/unit.html +++ b/cms/templates/unit.html @@ -4,9 +4,10 @@

${name}

${type}

+
- Save & Update Cancel + Save & Update
diff --git a/cms/templates/widgets/html-edit.html b/cms/templates/widgets/html-edit.html index e34e8e6480..7b17a2ed14 100644 --- a/cms/templates/widgets/html-edit.html +++ b/cms/templates/widgets/html-edit.html @@ -41,22 +41,5 @@ Cancel -
-

Add notes

-
- - -
- - -
+ <%include file="notes.html"/> diff --git a/cms/templates/widgets/notes.html b/cms/templates/widgets/notes.html new file mode 100644 index 0000000000..71c7afab85 --- /dev/null +++ b/cms/templates/widgets/notes.html @@ -0,0 +1,21 @@ +
+

Notes

+ + + +
+

Add a note

+ + +
+
+ diff --git a/cms/templates/widgets/problem-edit.html b/cms/templates/widgets/problem-edit.html index aa98c468fe..a2da078927 100644 --- a/cms/templates/widgets/problem-edit.html +++ b/cms/templates/widgets/problem-edit.html @@ -37,25 +37,12 @@
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.
+ +
+ Cancel + Save & Update +
-
-

Add notes

-
- - -
- - -
+ <%include file="notes.html"/> - diff --git a/cms/templates/widgets/sequence-edit.html b/cms/templates/widgets/sequence-edit.html index 62742edd3e..abeec9209d 100644 --- a/cms/templates/widgets/sequence-edit.html +++ b/cms/templates/widgets/sequence-edit.html @@ -30,7 +30,7 @@ -
+
  1. From 656fa389441372c3aec44e79071c46e9a5f07cec Mon Sep 17 00:00:00 2001 From: Kyle Fiedler Date: Mon, 25 Jun 2012 11:44:06 -0400 Subject: [PATCH 3/4] Added wip class --- cms/static/coffee/main.coffee | 2 ++ cms/static/sass/_base.scss | 4 ++++ cms/templates/widgets/html-edit.html | 4 ++-- cms/templates/widgets/module-dropdown.html | 2 +- cms/templates/widgets/navigation.html | 2 +- cms/templates/widgets/notes.html | 2 +- 6 files changed, 11 insertions(+), 5 deletions(-) diff --git a/cms/static/coffee/main.coffee b/cms/static/coffee/main.coffee index 6535034faf..66f375a7cc 100644 --- a/cms/static/coffee/main.coffee +++ b/cms/static/coffee/main.coffee @@ -37,6 +37,8 @@ $ -> $(this).parent().parent().hide() return false + # $('html').keypress -> + # $('.wip').css('visibility', 'visible') setHeight = -> windowHeight = $(this).height() diff --git a/cms/static/sass/_base.scss b/cms/static/sass/_base.scss index 6d1111980c..01f3af3ac7 100644 --- a/cms/static/sass/_base.scss +++ b/cms/static/sass/_base.scss @@ -67,3 +67,7 @@ textarea { display: block; float: right; } + +.wip { + outline: 1px solid #ff0 !important; +} diff --git a/cms/templates/widgets/html-edit.html b/cms/templates/widgets/html-edit.html index 7b17a2ed14..7eec86215a 100644 --- a/cms/templates/widgets/html-edit.html +++ b/cms/templates/widgets/html-edit.html @@ -1,5 +1,5 @@
    -
    +
      @@ -36,7 +36,7 @@
      ${module.definition['data']['text']}
      -
      + diff --git a/cms/templates/widgets/module-dropdown.html b/cms/templates/widgets/module-dropdown.html index 7c6e1e068c..6edb142e40 100644 --- a/cms/templates/widgets/module-dropdown.html +++ b/cms/templates/widgets/module-dropdown.html @@ -1,4 +1,4 @@ -
    • +
    • + Add new module diff --git a/cms/templates/widgets/navigation.html b/cms/templates/widgets/navigation.html index 3fbcda675c..cbdc7660ce 100644 --- a/cms/templates/widgets/navigation.html +++ b/cms/templates/widgets/navigation.html @@ -1,5 +1,5 @@
      -
      +

      Filter content:

      • diff --git a/cms/templates/widgets/notes.html b/cms/templates/widgets/notes.html index 71c7afab85..920e88cbcd 100644 --- a/cms/templates/widgets/notes.html +++ b/cms/templates/widgets/notes.html @@ -1,4 +1,4 @@ -
        +

        Notes

          From 863568ec997593ed6472ab57a1c0258496654c35 Mon Sep 17 00:00:00 2001 From: Kyle Fiedler Date: Mon, 25 Jun 2012 11:52:43 -0400 Subject: [PATCH 4/4] Added red wip class and added tag for it --- cms/static/sass/_base.scss | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/cms/static/sass/_base.scss b/cms/static/sass/_base.scss index 01f3af3ac7..afda14800f 100644 --- a/cms/static/sass/_base.scss +++ b/cms/static/sass/_base.scss @@ -69,5 +69,15 @@ textarea { } .wip { - outline: 1px solid #ff0 !important; + outline: 1px solid #f00 !important; + position: relative; + + &:after { + content: "WIP"; + font-size: 8px; + padding: 2px; + background: #f00; + color: #fff; + @include position(absolute, 0px 0px 0 0); + } }