Skip to content
Snippets Groups Projects
_dashboard.scss 29.7 KiB
Newer Older
// lms - views - user/student dashboard
// ====================

// Table of Contents 
// * +Dashboard - Sidebar
// * +Dashboard - Course Listing
// * +Dashboard - Course Item
// * +Misc - Uncategorized
// * +Dashboard - Banner


// +Dashboard - Sidebar
// ==================== 
Matthew Mongeau's avatar
wip
Matthew Mongeau committed
.dashboard {
Matthew Mongeau's avatar
wip
Matthew Mongeau committed

  .profile-sidebar {
    @include float(right);
    @include margin-left(flex-gutter());
    width: flex-grid(3);
Matthew Mongeau's avatar
wip
Matthew Mongeau committed

      border: 1px solid $border-color-2;
      border-radius: ($baseline/4) ($baseline/4) 0 0;
      .username-header {
        margin-bottom: 0;
      }

      .username-label {
        @extend %t-title7;
        @extend %t-ultrastrong;
        @extend %cont-truncated;
        display: block;
        border: 1px solid $border-color-2;
        border-top: none;
        border-radius: 0 0 ($baseline/4) ($baseline/4);
        padding: $baseline;
Matthew Mongeau's avatar
wip
Matthew Mongeau committed

          border-bottom: 1px dotted $border-color-2;
          &:last-child {
            border-bottom: none;
            margin-bottom: 0;
            padding-bottom: 0;
          }

Matthew Mongeau's avatar
wip
Matthew Mongeau committed

Matthew Mongeau's avatar
wip
Matthew Mongeau committed
            }
          }
            white-space: nowrap;
            text-overflow: ellipsis;
            overflow: hidden;

            .third-party-auth {
              color: inherit;
              font-weight: inherit;
            .auth-provider {
              width: flex-grid(12);
              display: block;
              margin-top: ($baseline/4);

              .status {
                width: flex-grid(1);
                display: inline-block;
                color: $gray-l2;

                width: flex-grid(9);
                display: inline-block;
              }

              .control {
                width: flex-grid(2);
                display: inline-block;
                text-align: right;

                a:link, a:visited {
                  @extend %t-copy-sub2;
                }
Matthew Mongeau's avatar
wip
Matthew Mongeau committed
        }

        li.order-history {
          span a {
            font-size: 13px;
            line-height: 20px;
          }
        }
Matthew Mongeau's avatar
wip
Matthew Mongeau committed
      }
        padding: 0 0 0 ($baseline/2);
        margin: ($baseline/4) 0;

        .status-item {
          @extend %t-copy-sub2;
          margin-bottom: 7px;
          border-bottom: 0;
          padding: 0;

            display: inline-block;
            vertical-align: top;
            margin: ($baseline/10) ($baseline/4) 0 0;
          }

            color: $alert-color;
          }

          .label {
            @extend %text-sr;
          }

          .course-name {
            @include line-height(12);
            display: inline-block;
            vertical-align: top;
            width: 80%;
            color: inherit;
          }
        }
      }
        .list--nav {
          margin: ($baseline/2) 0 0 0;
          padding: 0;
        .nav__item {
          @extend %t-weight4;
          @include font-size(13);
          margin-left: 26px;
Matthew Mongeau's avatar
wip
Matthew Mongeau committed
  }
Matthew Mongeau's avatar
wip
Matthew Mongeau committed

// +Dashboard - Course Listing
// ==================== 
.dashboard {
    width: flex-grid(9);
Matthew Mongeau's avatar
wip
Matthew Mongeau committed


    .wrapper-header-courses {
      border-bottom: 4px solid $border-color-l4;
      margin-bottom: $baseline;

      .header-courses {
        @extend %t-title5;
        @include padding-right($baseline/2);
      }
    // CASE: empty dashboard
      padding: ($baseline*2) 0;
      text-align: center;

      p {
        color: $lighter-base-font-color;
        font-style: italic;
        text-shadow: 0 1px rgba(255,255,255, 0.6);
        @include background-image($button-bg-image);
        background-color: $button-bg-color;
        border: 1px solid $border-color-2;
        @include box-sizing(border-box);
        color: $base-font-color;
        font-family: $sans-serif;
        display: inline-block;
        padding: 5px 10px;
        text-shadow: 0 1px rgba(255,255,255, 0.6);

          color: $link-color;
          text-decoration: none;
Matthew Mongeau's avatar
wip
Matthew Mongeau committed
        }
      }
    }
        margin-bottom: $baseline;
        border-bottom: 4px solid $border-color-l4;
        padding-bottom: $baseline;
        &:last-child {
          margin-bottom: 0;
          border-bottom: none;
          padding-bottom: 0;
        }
// +Dashboard - Course
// ==================== 
.dashboard .my-courses {

  // UI: individual course item
  .course {
    @include box-sizing(box);
    @include transition(all 0.15s linear 0s);
    @include clearfix();
    @extend %ui-depth2;
    position: relative;
    margin: ($baseline/2);

    .details {
      .wrapper-course-image {
        @include float(left);
        @include margin-right(flex-gutter());
        width: flex-grid(3);
        .cover {
          @include box-sizing(border-box);
          @include transition(all 0.15s linear 0s);
          @include float(left);
          overflow: hidden;
          position: relative;
          max-height: 120px;
          border-radius: ($baseline/5);
          border: 1px solid $dashboard-course-cover-border;
          border-bottom: 4px solid $dashboard-course-cover-border;

          @include float(left);
          width: 100%;
          position: relative;
          bottom: 15px;
          display: inline-block;
          text-align: center;
          .deco-graphic {
            position: absolute;
            top: -5px;
            @include right(0);
          }
          .sts-enrollment-value {
            @extend %ui-depth1;
            @extend %copy-badge;
            @extend %t-demi-strong;
            font-size: 0.6em;
            line-height: 1.5em;
            border-radius: 0;
            padding: 1px ($baseline/4);
            color: white;
      .wrapper-course-details {
        display: block;
        @include float(left);
        width: flex-grid(9);
        padding: 0;
      }
        a, span {
          @extend %t-title3;
          @extend %t-light;
          display: inline-block;
          margin-bottom: ($baseline/2);

          &:hover, &:focus {
            text-decoration: none;
      }

      .course-info {
        display: block;
        @include float(left);
        width: flex-grid(4);
        padding: 0;
        margin-top: ($baseline/2);

        [class*="info-"] {
          color: $gray-d1;
          @extend %t-title6;
          display: inline-block;
        }
        .info-date-block {
          @extend %t-title7;
          color: $gray-l1;
      .wrapper-course-actions {
        display: block;
        @include float(right);
        width: flex-grid(8);
        padding: 0;
        margin-top: ($baseline/2);
      }
        .action {
          @include box-sizing(border-box);
          @include margin-right($baseline/2);
          @include float(right);
          min-width: ($baseline*2);
          color: $gray-l1;
          border-radius: 3px;
          padding: 12px;
          border: 1px solid $white;
          
          &:hover, &:focus {
            color: $gray-d3;
            border: 1px solid $gray-l4;
          }
          // STATE: is-disabled
          &.is-disabled {
            color: $gray-l4;
          }
          // TYPE: facebook share
          &.action-facebook, {
            color: $facebook-blue;
          // TYPE: twitter share
          &.action-twitter {
            color: $twitter-blue;
          }
        }
        // UI: general actions dropdown layout
        .wrapper-action-more {
          display: inline-block;
          position: relative;
          @include float(right);
          .actions-dropdown {
            @extend %ui-no-list;
            @extend %ui-depth1;
            display: none;
            position: absolute;
            top: ($baseline*2);
            right: 19px;
            pointer-events: none;
            min-width: ($baseline*7);
            &.is-visible {
              display: block;
              pointer-events: auto;
            }
            .actions-dropdown-list {
              @extend %ui-no-list;
              @include box-sizing(border-box);
              display: table;
              box-shadow: 0 1px 1px $shadow-l1;
              position: relative;
              width: 100%;
              border-radius: 3px;
              margin: ($baseline/4) 0 0 0;
              border: 1px solid $gray-l3;
              padding: ($baseline/4) ($baseline/2);
              background: $white;

              // ui triangle/nub
              &:after,
              &:before {
                bottom: 100%;
                @include right(3px);
                border: solid transparent;
                content: " ";
                height: 0;
                width: 0;
                position: absolute;
                pointer-events: none;
              &:after {
                border-color: $transparent;
                border-bottom-color: $white;
                border-width: 6px;
                @include margin-right(1px);
              }
              &:before {
                border-color: $transparent;
                border-bottom-color: $gray-l3;
                border-width: 7px;
              }
            }
            .actions-item {
              @extend %t-title7;
              display: block;
              margin: 0;
              &.is-hidden {
                display: none;
              }

              .action {
                @include margin-right(0);

                &:hover, &:focus {
                  border: 1px solid transparent;
                 }
      .course-status {
        background: $yellow;
        border: 1px solid $border-color-2;
        box-shadow: 0 1px 0 0 rgba(255,255,255, 0.6);
        margin-top: 17px;
        margin-right: flex-gutter();
        padding: ($baseline/4);
        width: flex-grid(8);
        @include float(left);
        @include box-sizing(border-box);
        p {
          color: $lighter-base-font-color;
          font-style: italic;
          letter-spacing: 1px;
          text-align: center;
      .course-status-completed {
        background: $gray-l3;
        color: $very-light-text;
      .enter-course {
        @include button(simple, $button-color);
        @include box-sizing(border-box);
        border-radius: 3px;
        @include float(right);
        font: normal 15px/1.6rem $sans-serif;
        letter-spacing: 0;
        text-align: center;
        &.archived {
          @include button(simple, $button-archive-color);
          font: normal 15px/1.6rem $sans-serif;
    // UI: messages
    .wrapper-messages-primary {
      @include clearfix();
      .messages-list {
        margin: 0;
        padding: 0;
      }
      .message {
        @extend %ui-depth1;
        border-radius: 3px;
        display: none;
        margin: $baseline 0 ($baseline/2) 0;
        background: $gray-l5;
        border: 1px solid $gray-l4;
        // STATE: shown
        &.is-shown {
          display: block;
        a {
          font-family: $sans-serif;
        strong {
          font-weight: 700;
        .actions {
          @include clearfix();
          list-style: none;
          margin: 0;
          padding: 0;
        .message-title,
        .message-copy .title {
          @extend %t-title6;
          @extend %t-weight4;
          line-height: 1em;
          margin-bottom: ($baseline/4);
        }
        .message-copy,
        .message-copy .copy {
          @extend %t-copy-sub1;
          margin: 2px 0 0 0;
        // CASE: expandable
        &.is-expandable {
            .message-title, .message-copy {
              margin-bottom: 0;
            }

            .message-title .value, .message-copy {
              @include transition(color $tmg-f2 ease-in-out 0s);
            }

            // STATE: hover
            &:hover {
              cursor: pointer;

              .message-title .value, .message-copy, .ui-toggle-expansion {
                color: $link-color;
              }
            }
          .wrapper-extended {
            @include transition(opacity $tmg-f2 ease-in-out 0);
            display: none;
            opacity: 0.0;
          .ui-toggle-expansion {
            @include rtl {
              @include transform(rotate(-90deg));
            @include ltr {
              @include transform(rotate(90deg));
            @include transform-origin(50% 50%);
          }

          .wrapper-extended {
            display: block;
            opacity: 1.0;
          .wrapper-tip {
            @include clearfix();
            .ui-toggle-expansion {
              @include transition(all $tmg-f2 ease-in-out 0s);
              display: inline-block;
              vertical-align: middle;
              margin-right: ($baseline/4);
            }
          .wrapper-extended {
            padding: ($baseline/2) 0;
            .message-copy {
              margin-bottom: $baseline;
            }
          }
          .action-upgrade {
            @extend %btn-primary-green;
            @include clearfix();
            position: relative;
            left: ($baseline/2);
            padding: 8px $baseline 8px ($baseline*2);

            .deco-graphic {
              position: absolute;
              top: -($baseline/4);
              left: -($baseline*0.75);
              width: ($baseline*2);
            }
            span {
              color: $white; // nasty but needed override for poor <span> styling
            }
            .copy, .copy-sub {
              display: inline-block;
              vertical-align: middle;
            }

            .copy {
              @extend %t-action3;
              @extend %t-weight4;
              margin-right: $baseline;
            }

            .copy-sub {
              @extend %t-action4;
              opacity: 0.875;
            }
          }
          background: tint($yellow,70%);
          border-color: $gray-l3;
          .message-copy {
            @extend %t-copy-sub1;
            margin: 0;
            .grade-value {
              font-size: 1.2rem;
              font-weight: bold;
            }
          }
              margin: 0 15px 0 0;
              .btn, .cta {
                display: inline-block;
              }

              .btn {
                @include box-sizing(border-box);
                border-radius: 3px;
                font: normal 0.8rem/1.2rem $sans-serif;
                letter-spacing: 1px;
                padding: 6px 12px;
                text-align: center;

                &.disabled {
                  cursor: default !important;

                  &:hover, &:focus {
                    @include background-image(linear-gradient(top, #EEE 0%, #C2C2C2 50%, #ABABAB 50%, #B0B0B0 100% ));
                font: normal 0.8rem/1.2rem $sans-serif;
                letter-spacing: 1px;
                padding: 6px 12px;
                text-align: center;
              }
            }
          .exam-registration-number {
            font-family: $sans-serif;
            font-size: 18px;
            a {
              font-family: $sans-serif;
          &.exam-register {
            .message-copy {
              margin-top: ($baseline/4);
              width: 55%;
            }
          &.exam-schedule {
            .exam-button {
              margin-top: ($baseline/4);
            }
          .exam-button {
            @include button(simple, $pink);
          .contact-button {
            @include button(simple, $pink);
          }
          .button {
            display: inline-block;
            margin-top: ($baseline/2);
            padding: 9px 18px 10px;
            font-size: 13px;
            font-weight: bold;
            letter-spacing: 0;
            &:hover, &:focus {
              text-decoration: none;
            }
          &.course-status-processing {
            background-color: $gray-l5;
            border: 0;
          &.course-status-certnotavailable {
            background-color: $gray-l5;
            border: 0;
          }
          &.course-status-certrendering {
            background-color: $gray-l5;
            border: 0;
          &.course-status-certavailable {
            background-color: $gray-l5;
            border: 0;
            .message-copy {
              width: flex-grid(6, 12);
              position: relative;
              @include float(left);
            }
            .actions-primary {
              width: flex-grid(6, 12);
              position: relative;
              @include float(right);
              .action {
                @include margin(0, 0, ($baseline/2), ($baseline*.75));
                float: none;
                text-align: center;
                &:last-child {
                  margin-bottom: 0;
                }
              .action-certificate .btn {
                @extend %btn-inherited-primary;
                @include box-sizing(border-box);
                float: none;
                border-radius: 3px;
                display: block;
                @include padding(7px, ($baseline*.75), 7px, ($baseline*.75));
                text-align: center;
                a:link, a:visited {
                  color: #fff;
                }
              }
              .action-share .btn {
                display: inline;
                letter-spacing: 0;
              }
            }
          }
          .actions-secondary {
            margin-top: ($baseline/2);
            border-top: 1px solid $gray-l4;
            padding-top: ($baseline/2);
            .action-share {
              @include float(right);
              margin: 0;
            }
          }
          .certificate-explanation {
            @extend %t-copy-sub1;
            margin-top: ($baseline/2);
            border-top: 1px solid $gray-l4;
            padding-top: ($baseline/2);
          .verification-reminder {
            width: flex-grid(8, 12);
            position: relative;
          .verification-cta {
            width: flex-grid(4, 12);
            position: relative;

            .cta {
              @include button(simple, $green-d1);
              @include box-sizing(border-box);
              @include float(right);
              border-radius: 3px;
              display: block;
              font: normal 15px/1.6rem $sans-serif;
              letter-spacing: 0;
              padding: 6px 32px 7px;
              text-align: center;
            }
        // TYPE: pre-requisites 
        .prerequisites {
          @include clearfix;
          .tip {
            font-family: $sans-serif;
            font-size: 1em;
            color: $lighter-base-font-color;
            margin-top: ($baseline/2);
          }
    // CASE: "enrolled as" status - professional ed
    &.professional {

      // changes to cover
      .wrapper-course-image .cover {
        border-color: $professional-color-lvl3;
        padding: ($baseline/10);
      }

      // course enrollment status message
      .sts-enrollment {
        .label {
          @extend %text-sr;