From 7dfb01a3973fa4c3c0ec2d69f3e310c433aeaacd Mon Sep 17 00:00:00 2001 From: Adam Butterworth Date: Mon, 4 May 2020 16:06:19 -0400 Subject: [PATCH] Mobile fixes: content tools and verified certificate details (#57) * Prevent wrapping of show notes button * text overflow * Update layout for course sock --- src/courseware/course/course-sock/index.jsx | 254 ++++++++++-------- src/courseware/course/tools/ContentTools.jsx | 2 +- .../course/tools/calculator/calculator.scss | 2 +- .../course/tools/notes/NotesVisibility.jsx | 25 +- src/courseware/course/tools/tools.scss | 4 + 5 files changed, 157 insertions(+), 130 deletions(-) diff --git a/src/courseware/course/course-sock/index.jsx b/src/courseware/course/course-sock/index.jsx index 1e364a13..d2c7aad8 100644 --- a/src/courseware/course/course-sock/index.jsx +++ b/src/courseware/course/course-sock/index.jsx @@ -32,128 +32,152 @@ export default class CourseSock extends Component { {this.state.showUpsell && ( -
-
-

+ <> +

-

- -

-
    -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
-

-

-
    -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
  • -
-

-

-
- Christina Fong -
- -
- - +
+
+
+ Example Certificate +
+
+
+ + + +
+
+
+
+

+ +

+
    +
  • + +
  • +
  • + +
  • +
  • + +
  • +
  • + +
  • +
+

+ +

+
    +
  • + +
  • +
  • + +
  • +
  • + +
  • +
  • + +
  • +
+ +

+ +

+
+ Christina Fong +
+ +

+ — +

+
+
+
+ Chery Troell +
+ +

+ — +

+
+
-
- Chery Troell -
- -
- - -
-
-
-
- Example Certificate - - - -
-
+ )}
); diff --git a/src/courseware/course/tools/ContentTools.jsx b/src/courseware/course/tools/ContentTools.jsx index 0485b424..0baaffc2 100644 --- a/src/courseware/course/tools/ContentTools.jsx +++ b/src/courseware/course/tools/ContentTools.jsx @@ -10,7 +10,7 @@ export default function ContentTools({ }) { return (
-
+
{course.showCalculator && ( )} diff --git a/src/courseware/course/tools/calculator/calculator.scss b/src/courseware/course/tools/calculator/calculator.scss index 2c5d11d0..43e88ef5 100644 --- a/src/courseware/course/tools/calculator/calculator.scss +++ b/src/courseware/course/tools/calculator/calculator.scss @@ -1,5 +1,5 @@ .calculator { - width: 100%; + flex-grow: 1; .calculator-content { background-color: #f1f1f1; box-shadow: 0 -1px 0 0 #ddd; diff --git a/src/courseware/course/tools/notes/NotesVisibility.jsx b/src/courseware/course/tools/notes/NotesVisibility.jsx index 309d7535..f47e7c7f 100644 --- a/src/courseware/course/tools/notes/NotesVisibility.jsx +++ b/src/courseware/course/tools/notes/NotesVisibility.jsx @@ -35,19 +35,18 @@ class NotesVisibility extends Component { render() { const message = this.state.visible ? 'notes.button.hide' : 'notes.button.show'; return ( -
-
-
-
+ ); } } diff --git a/src/courseware/course/tools/tools.scss b/src/courseware/course/tools/tools.scss index ad2337c9..732ef260 100644 --- a/src/courseware/course/tools/tools.scss +++ b/src/courseware/course/tools/tools.scss @@ -16,6 +16,10 @@ border-top-right-radius: .3rem; border-bottom-left-radius: 0; border-bottom-right-radius: 0; + text-overflow: ellipsis; + overflow: hidden; + padding-left: .75rem; + white-space: nowrap; &:before { border-radius: .5rem; }