diff --git a/fuel/app/classes/controller/api/user.php b/fuel/app/classes/controller/api/user.php index 467d2082a..914baded9 100644 --- a/fuel/app/classes/controller/api/user.php +++ b/fuel/app/classes/controller/api/user.php @@ -26,6 +26,7 @@ public function post_settings() $set_meta = [ 'useGravatar' => Input::json('useGravatar', null), 'notify' => Input::json('notify', null), + 'darkMode' => Input::json('darkMode', null) ]; $success = Materia\Api::user_update_meta($set_meta); diff --git a/fuel/app/classes/controller/qsets.php b/fuel/app/classes/controller/qsets.php index fa1c1d119..5a32f4580 100644 --- a/fuel/app/classes/controller/qsets.php +++ b/fuel/app/classes/controller/qsets.php @@ -6,6 +6,7 @@ class Controller_Qsets extends Controller { + use Trait_CommonControllerTemplate; public function action_import() { diff --git a/fuel/app/classes/controller/questions.php b/fuel/app/classes/controller/questions.php index a75e4c24d..2d2ef7aff 100644 --- a/fuel/app/classes/controller/questions.php +++ b/fuel/app/classes/controller/questions.php @@ -6,6 +6,8 @@ class Controller_Questions extends Controller { + use Trait_CommonControllerTemplate; + public function get_import() { // Validate Logged in diff --git a/fuel/app/classes/model/user.php b/fuel/app/classes/model/user.php index 122456326..23f152d78 100644 --- a/fuel/app/classes/model/user.php +++ b/fuel/app/classes/model/user.php @@ -5,7 +5,8 @@ class Model_User extends Orm\Model protected static $_default_profile_fields = [ 'useGravatar' => true, - 'notify' => true + 'notify' => true, + 'darkMode' => false ]; protected static $_properties = [ diff --git a/fuel/app/classes/trait/commoncontrollertemplate.php b/fuel/app/classes/trait/commoncontrollertemplate.php index 0b02488b0..c13f758bc 100644 --- a/fuel/app/classes/trait/commoncontrollertemplate.php +++ b/fuel/app/classes/trait/commoncontrollertemplate.php @@ -7,6 +7,7 @@ trait Trait_CommonControllerTemplate { use Trait_Analytics; + use Trait_DarkMode; protected $_disable_browser_cache = false; @@ -32,6 +33,11 @@ public function after($response) $this->inject_common_js_constants(); + if ($this->is_using_darkmode()) + { + $this->theme->get_template()->set('darkmode', true); + } + return parent::after($response); } diff --git a/fuel/app/classes/trait/darkmode.php b/fuel/app/classes/trait/darkmode.php new file mode 100644 index 000000000..d69f98ca1 --- /dev/null +++ b/fuel/app/classes/trait/darkmode.php @@ -0,0 +1,19 @@ +profile_fields; + $darkmode = ! empty($meta['darkMode']) && $meta['darkMode']; + return $darkmode; + } + else return false; + } +} \ No newline at end of file diff --git a/fuel/app/themes/default/layouts/react.php b/fuel/app/themes/default/layouts/react.php index 6bd6b8093..c50ba271b 100644 --- a/fuel/app/themes/default/layouts/react.php +++ b/fuel/app/themes/default/layouts/react.php @@ -14,7 +14,7 @@ = Css::render() ?> = $partials['google_analytics'] ?? '' ?> -
+ = Js::render() ?> diff --git a/public/img/404_beachandocean_dark.png b/public/img/404_beachandocean_dark.png new file mode 100644 index 000000000..5280253c6 Binary files /dev/null and b/public/img/404_beachandocean_dark.png differ diff --git a/public/img/404_insand_dark.png b/public/img/404_insand_dark.png new file mode 100644 index 000000000..52c9f4e40 Binary files /dev/null and b/public/img/404_insand_dark.png differ diff --git a/public/img/404_logo_balls_dark.png b/public/img/404_logo_balls_dark.png new file mode 100644 index 000000000..56847a0eb Binary files /dev/null and b/public/img/404_logo_balls_dark.png differ diff --git a/public/img/banner_dark.png b/public/img/banner_dark.png new file mode 100644 index 000000000..c0a7343f4 Binary files /dev/null and b/public/img/banner_dark.png differ diff --git a/public/img/kogneato_metal_detecting_dark.png b/public/img/kogneato_metal_detecting_dark.png new file mode 100644 index 000000000..49fb412ea Binary files /dev/null and b/public/img/kogneato_metal_detecting_dark.png differ diff --git a/public/img/kogneato_metal_detecting_dark.svg b/public/img/kogneato_metal_detecting_dark.svg new file mode 100644 index 000000000..2cff6f059 --- /dev/null +++ b/public/img/kogneato_metal_detecting_dark.svg @@ -0,0 +1,134 @@ + + + diff --git a/public/img/kogneato_mywidgets_dark.svg b/public/img/kogneato_mywidgets_dark.svg new file mode 100644 index 000000000..e7a18c2af --- /dev/null +++ b/public/img/kogneato_mywidgets_dark.svg @@ -0,0 +1,82 @@ + + + diff --git a/public/img/kogneato_no_scores_dark.svg b/public/img/kogneato_no_scores_dark.svg new file mode 100644 index 000000000..dddc18e17 --- /dev/null +++ b/public/img/kogneato_no_scores_dark.svg @@ -0,0 +1,122 @@ + + + diff --git a/public/img/kogneato_with_a_broom_dark.svg b/public/img/kogneato_with_a_broom_dark.svg new file mode 100644 index 000000000..2b64927d7 --- /dev/null +++ b/public/img/kogneato_with_a_broom_dark.svg @@ -0,0 +1,64 @@ + + + diff --git a/public/img/magnifyingglass_dark.png b/public/img/magnifyingglass_dark.png new file mode 100644 index 000000000..f6d05b685 Binary files /dev/null and b/public/img/magnifyingglass_dark.png differ diff --git a/public/img/materia-logo-default-darkmode.svg b/public/img/materia-logo-default-darkmode.svg new file mode 100644 index 000000000..bd9bef41b --- /dev/null +++ b/public/img/materia-logo-default-darkmode.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/img/materia-logo-default-lightmode.svg b/public/img/materia-logo-default-lightmode.svg new file mode 100644 index 000000000..8f9c1fe8e --- /dev/null +++ b/public/img/materia-logo-default-lightmode.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/img/materia-logo-default.svg b/public/img/materia-logo-default.svg deleted file mode 100644 index 7025e9e37..000000000 --- a/public/img/materia-logo-default.svg +++ /dev/null @@ -1,66 +0,0 @@ - - - - diff --git a/public/img/materia-logo-thin-darkmode.svg b/public/img/materia-logo-thin-darkmode.svg new file mode 100644 index 000000000..43ba9d606 --- /dev/null +++ b/public/img/materia-logo-thin-darkmode.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/img/materia-logo-thin.svg b/public/img/materia-logo-thin.svg index e8ef22156..0a63eb14e 100644 --- a/public/img/materia-logo-thin.svg +++ b/public/img/materia-logo-thin.svg @@ -1,66 +1 @@ - - - - + \ No newline at end of file diff --git a/public/img/materia_tmp_logo.png b/public/img/materia_tmp_logo.png deleted file mode 100644 index 09311645d..000000000 Binary files a/public/img/materia_tmp_logo.png and /dev/null differ diff --git a/public/img/retina/materia_tmp_logo_dark@2x.png b/public/img/retina/materia_tmp_logo_dark@2x.png new file mode 100644 index 000000000..0602c28cb Binary files /dev/null and b/public/img/retina/materia_tmp_logo_dark@2x.png differ diff --git a/public/img/user_page_background_dark.gif b/public/img/user_page_background_dark.gif new file mode 100644 index 000000000..ee583c78a Binary files /dev/null and b/public/img/user_page_background_dark.gif differ diff --git a/src/components/404.scss b/src/components/404.scss index 62e826602..efdd500a7 100644 --- a/src/components/404.scss +++ b/src/components/404.scss @@ -60,4 +60,24 @@ } } } +} + +.darkMode #notfound { + background: #21232a; + + .page { + background: url('/img/kogneato_metal_detecting_dark.png') 66% no-repeat, + url('/img/404_logo_balls_dark.png') 80% no-repeat, + url('/img/404_beachandocean_dark.png') 0 255px no-repeat; + background-position: right center; + + h1 { + background: url('/img/404_insand_dark.png') top center no-repeat; + background-size: contain; + } + + p { + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.75); + } + } } \ No newline at end of file diff --git a/src/components/500.scss b/src/components/500.scss index 78df58230..0602ee706 100644 --- a/src/components/500.scss +++ b/src/components/500.scss @@ -40,4 +40,12 @@ text-align: center; } +} + +.darkMode .container.general { + background-color: #21232a; + + .page h1 { + color: #61a4e2; + } } \ No newline at end of file diff --git a/src/components/bar-graph.jsx b/src/components/bar-graph.jsx index 72e49fc66..7f193b9f7 100644 --- a/src/components/bar-graph.jsx +++ b/src/components/bar-graph.jsx @@ -3,7 +3,7 @@ import { axisBottom, axisLeft, scaleBand, scaleLinear, select } from 'd3' const BarGraph = ({ data, width, height, rowLabel = `Y Axis`, colLabel = `X Axis`, graphTitle = 'Title' }) => { - const linesColor = { color: `#a9a9a9` } + const linesColor = { color: `#333333` } const margin = { top: 50, bottom: 25, left: 25, right: 25 } const graphWidth = width - margin.left - margin.right const graphHeight = height - margin.top - margin.bottom @@ -75,7 +75,7 @@ const BarGraph = ({ data, width, height, rowLabel = `Y Axis`, colLabel = `X Axis y={yAxis(value)} width={xAxis.bandwidth()} height={height - yAxis(value)} - fill={`#0093e7`} + fill={`#0077e7`} /> ))} >) diff --git a/src/components/catalog.scss b/src/components/catalog.scss index 608142f15..95610d41e 100644 --- a/src/components/catalog.scss +++ b/src/components/catalog.scss @@ -88,6 +88,7 @@ svg { height: 100%; width: 100%; + fill: #c7c7c7; } } @@ -130,6 +131,7 @@ right: 0; padding: 4px 35px 4px 35px; font-size: 14px; + color: #fff; background: #fff; border: solid 1px #b0b0b0; border-radius: 12px; @@ -212,6 +214,7 @@ &.feature-button { cursor: pointer; background: #f2f2f2; + color: #fff; border: 0; margin: 3px 3px; border-radius: 5px; @@ -234,6 +237,7 @@ width: 16px; height: auto; margin-right: 6px; + fill: #fff; } } } @@ -369,6 +373,7 @@ svg { position: relative; top: 4px; + fill: #fff; } } } @@ -388,6 +393,12 @@ margin-left: 135px; margin-right: 8px; font-size: 0.88em; + font-weight: 400; + + .blurb { + color: $extremely-dark-gray; + margin-bottom: 1em; + } .accessibility-holder { height: 25px; @@ -410,6 +421,7 @@ svg { height: 20px; width: auto; + fill: #fff; &:last-of-type { padding-left: 10px; @@ -470,6 +482,7 @@ width: 12px; height: auto; margin-right: 6px; + fill: #fff; } } } @@ -485,6 +498,199 @@ } } +.darkMode .catalog { + + section.page { + background: #21232a; + border: #181920 1px solid; + box-shadow: 1px 3px 10px #08090c; + } + + .top { + background: hsl(233, 14%, 11%); + color: #c7c7c7; + + aside { + + button.filter-toggle { + border-bottom: solid 1px #61a4e2; + color: #61a4e2; + + &.close-mode:after { + color: #c7c7c7; + } + } + + .search { + + .search-icon { + svg { + fill: #c7c7c7; + } + } + + .search-close { + + &:before, + &:after { + background-color: white; + } + } + + input { + color: #fff; + background: $color-input-box-bg-dark; + border: solid 1px #13151a; + } + } + } + } + + .cancel_button { + color: #3690e6; + } + + #filters-container { + + .filter-labels-container { + + &:before { + + color: #c7c7c7; + } + + &.accessibility:before { + color: #c7c7c7; + } + + button { + + &.feature-button { + background: #3c3e47; + + &:hover { + background: #1b304b; + } + + &.selected { + background: #295b99; + color: #fff; + + svg { + fill: #fff; + } + } + + svg { + fill: #fff; + } + } + } + } + } + + #no-widgets-message { + color: #888888; + } + + .widget-group { + border: 1px dashed #47484e; + + .container-label { + color: #c7c7c7;; + + span { + background: #21232a; + } + } + } + + .widgets-container { + .widget { + background-color: #2b2d35; + border: #181920 1px solid; + box-shadow: 1px 3px 10px #08090c; + + &:hover { + border: transparent 1px solid; + background-color: #2c3f57; + box-shadow: 0px 0px 4px #08090c; + } + + .infocard { + color: #fff; + + &:focus { + background-color: #295b99; + } + + .header { + margin-bottom: 4px; + background: #181920; + + h1 { + color: #c7c7c7; + } + + div.featured-label { + background: #295b99; + + svg { + fill: #fff; + } + } + } + + .widget-info { + + .blurb { + color: $light-gray; + } + + .accessibility-holder { + + .accessibility-indicators { + + div { + svg { + fill: #fff; + } + + .tool-tip { + box-shadow: 1px 2px 5px #08090c; + background-color: #2c3f57; + } + } + } + } + } + + ul { + li { + background: #4c4e58; + color: #fff; + + &.selected { + background: #295b99; + color: white; + + &.accessibility-status svg { + fill: #fff; + } + } + + &.accessibility-status { + svg { + fill: #fff; + } + } + } + } + } + } + } +} + @media (max-width: 960px) { .catalog { #filters-container { diff --git a/src/components/detail.scss b/src/components/detail.scss index 55bb2264b..648d451ca 100644 --- a/src/components/detail.scss +++ b/src/components/detail.scss @@ -7,6 +7,8 @@ $color-green: #c5dd60; .page { margin: 0 auto 20px; max-width: 950px; + + font-weight: 400; } #breadcrumb-container { @@ -17,7 +19,7 @@ $color-green: #c5dd60; padding: 5px 10px; background: #eee; border-radius: 3px; - font-size: 12px; + font-size: 14px; border: 1px solid #ccc; .breadcrumb { @@ -825,6 +827,213 @@ a { } } +.darkMode { + #breadcrumb-container { + + background: #1d1f25; + border: 1px solid #181920; + + .breadcrumb { + a { + color: #91c8fc; + } + } + + svg { + fill: #fff; + } + } + + .feature-list { + &.accessibility-options { + .list-holder { + ul { + li { + &.accessibility-description { + color: #d8d8d8; + } + + .icon-spacer { + svg { + fill: #fff; + } + } + + span { + color: #fff; + } + } + } + } + } + + .feature { + .guide-link { + background: #555; + color: #fff; + + &:hover { + background-color: #000; + } + } + + .feature-name { + background: #295b99; + color: #fff; + + &:hover { + background: $color-features-active; + + &:after { + border-top: 6px solid $color-features-active; + } + } + } + + .feature-description { + color: #fff; + background: $color-features-active; + box-shadow: 1px 2px 5px #08090c; + } + } + } + + .widget_detail { + background: #21232a; + border: #181920 1px solid; + box-shadow: 1px 3px 10px #08090c; + + .top { + background: #1d1f25; + color: #fff; + } + + .pics { + button.pic-arrow { + fill: #fff; + background: #000; + } + + button.demo-dot { + background-color: #4c4e58; + color: white; + + &:before { + border-top: 5px solid transparent; + border-bottom: 5px solid transparent; + border-left: 8px solid white; + } + + &:hover, + &:focus { + background-color: #686a74; + outline: none; + color: white; + } + + &.selected { + background-color: #565964; + color: white; + } + } + + button.pic-dot { + &:before { + background-color: #fff; + opacity: 0.25; + } + + &:hover:before { + opacity: 0.5; + } + + &:focus:before { + opacity: 0.5; + } + + &.selected:before { + opacity: 1; + } + } + } + + #pics-scroller { + > div { + background: #4c4e58; + + &.playing, + &.loading { + background: #b944cc; + } + + &:active { + cursor: grabbing; + } + + h3 { + color: #fff; + } + } + } + + #demo-cover { + &.hidden, + &.loading { + button { + &:after { + background-color: #535353; + } + } + } + + button { + box-shadow: 1px 2px 4px #08090c; + text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.5); + border: 3px solid #181920; + + &:hover { + + #demo-cover-background { + opacity: 0.7; + } + } + + svg { + fill: #535353; + } + } + } + + #demo-cover-background { + background: radial-gradient( + ellipse farthest-corner at center center, + rgba(33, 35, 42, 0.85) 20%, + rgba(29, 31, 37, 0.97) 100% + ) + repeat scroll 0% 0%; + } + + .bottom { + .widget-action-buttons { + + h4 { + color: #fff; + } + } + + #createLink { + + svg { + fill: #535353; + } + } + + #last-updated { + color: #b5b5b5; + } + } + } +} + @media (max-width: 720px) { #breadcrumb-container { padding: 3px 10px; diff --git a/src/components/extra-attempts-dialog.scss b/src/components/extra-attempts-dialog.scss index 1bd425955..8372eb547 100644 --- a/src/components/extra-attempts-dialog.scss +++ b/src/components/extra-attempts-dialog.scss @@ -249,3 +249,61 @@ cursor: pointer; } } + +.darkMode .modal .extraAttemptsModal { + + .title { + color: #d8d8d8; + border-bottom: #d8d8d8 dotted 1px; + } + + .attempts-input { + border: solid 1px #08090c; + background-color: #1d1f25; + color: #fff; + } + + .attempts_search_list { + background-color: #21232a; + border: #bfbfbf 1px solid; + + .attempts_search_match { + background-color: #21232a; + } + + .attempts_search_match:hover { + background-color: #295b99; + } + } + + .attempts_list_container { + background-color: #24262e; + + .headers { + background: #4c4e58; + color: white; + } + + .attempts_list { + + .extra_attempt { + + .remove { + color: #bfbfbf; + background: transparent; + + &:hover { + color: #fff; + background: #21232a; + } + } + } + } + } + + .save-error { + p { + color: red; + } + } +} \ No newline at end of file diff --git a/src/components/guide-page.scss b/src/components/guide-page.scss index 85808a55a..5aeb696ab 100644 --- a/src/components/guide-page.scss +++ b/src/components/guide-page.scss @@ -43,6 +43,27 @@ } } +.darkMode #top { + #guide-tabs { + &.players-guide { + a:first-of-type { + background: #1778af; + } + } + + &.creators-guide { + a:nth-of-type(2) { + background: #1778af; + } + } + + a { + background: #004268; + color: white; + } + } +} + #guide-container { .guide { height: calc(100vh - 200px); @@ -53,6 +74,16 @@ } } +.darkMode .page { + background: $color-background-dark; + box-shadow: 1px 3px 10px #08090c; + color: #c7c7c7; +} + +.darkMode #guide-container { + background: #fff; +} + // mobile @media (max-width: 720px) { .page { diff --git a/src/components/help-page.scss b/src/components/help-page.scss index a611dfb63..78e1aed5f 100644 --- a/src/components/help-page.scss +++ b/src/components/help-page.scss @@ -7,6 +7,7 @@ position: relative; font-family: 'Lato', arial, serif; + font-weight: 400; .page { z-index: 100; @@ -102,7 +103,7 @@ h3 { margin: 30px 0 0 0; - font-size: 16px; + font-size: 18px; } h3 + p { @@ -124,10 +125,11 @@ dl { dt { font-weight: bold; - font-size: 14px; + font-size: 15px; } dd { + line-height: 1.4em; margin: 0.5em 0 0 0; padding-bottom: 10px; } @@ -135,6 +137,43 @@ } } +.darkMode.docs { + .container { + .page { + border: #181920 1px solid; + + box-shadow: 1px 3px 10px #08090c; + background-color: #21232a; + + color: $very-light-gray; + + a { + color: #61a4e2; + } + + .content { + nav { + border-right: solid 0.5px $color-background-dark-gray; + + ul { + li { + border-bottom: solid 0.5px $color-background-dark-gray; + + a { + color: #61a4e2; + } + } + } + } + } + } + + h1 { + border-bottom: solid #dcdcdc .5px; + } + } +} + @media (max-width: 850px) { .docs { diff --git a/src/components/homepage.scss b/src/components/homepage.scss index 62f3be0c9..a485bfa16 100644 --- a/src/components/homepage.scss +++ b/src/components/homepage.scss @@ -61,6 +61,7 @@ } h1 { + color: #000; font-weight: 500; font-size: calc(35px + (40 - 35) * ((100vw - 300px) / (1600 - 300))); margin: 0; @@ -104,6 +105,34 @@ } } +.darkMode .spotlight { + + .main_container { + background: #21232a; + + .store_main { + p { + color: #fff; + } + + section { + background: linear-gradient(to right, rgba(33, 35, 42, 0), rgba(33, 35, 42, 1) 55%), url(/img/banner_dark.png) no-repeat; + background-size: contain; + + .store_content { + h1 span.engage { + color: #61a4e2; + } + } + } + } + } + + h1 { + color: #fff; + } +} + .front_bottom { display: grid; width: 100%; @@ -170,6 +199,23 @@ float: left; } } + +.darkMode .front_bottom { + background-color: #21232a; + + div { + color: #fff; + + h2 { + color: #fff; + border-bottom: dotted 1px #666; + } + } + + img { + border: dotted 1px #666; + } +} @media only screen and (min-width: 900px) { .p_s { @@ -227,6 +273,16 @@ } } } + +.darkMode .p_s { + h2 { + color: #fff; + } + p { + color: #fff; + } +} + @media (max-width: 700px) { .get_started { height: 280px !important; @@ -269,6 +325,10 @@ width: 100%; height: 240px; background-image: linear-gradient(115deg, #3690E6 60%, #37A9E6 40%); + //background-image: linear-gradient(115deg, #227ace 60%, #1d8fcc 40%); + .darkMode { + background-image: linear-gradient(115deg, #28445a 60%, #3a5766 40%); + } img { width: 30%; @@ -318,4 +378,23 @@ font-weight: 700; } } +} + +.darkMode .get_started { + color: #474747; + background-image: linear-gradient(115deg, #295b99 60%, #3e74b6 40%); + h1 { + &.subHeader { + color: #ffffff; + } + } + p { + &.desc { + color: #ffffff; + } + } +} + +body .darkMode { + background-color: #21232a; } \ No newline at end of file diff --git a/src/components/include.scss b/src/components/include.scss index c95b09a4e..46fc98ecf 100644 --- a/src/components/include.scss +++ b/src/components/include.scss @@ -13,6 +13,20 @@ $light-gray: #dadada; $gray: #9a9a9a; $extremely-dark-gray: #333; +$color-background-dark: #21232a; +$color-header-dark: #1d1f25; +$color-background-dark-gray: #4c4e58; +$color-border-dark: #181920; +$color-box-shadow-dark: #08090c; +$color-text-light-gray: #d8d8d8; +$color-features-dark: #295b99; +$color-blue-hover-dark: #1b304b; +$color-link-dark: #61a4e2; + +$color-input-desc-dark: #111317; +$color-input-box-bg-dark: #30323b; +$color-input-box-border-dark: #13151a; + body, html { @@ -25,6 +39,13 @@ body { font-family: 'Lato', arial, sans-serif; font-weight: 300; overflow: auto; + color: #333; + background-color: #fff; +} + +body.darkMode { + color: #fff; + background-color: $color-background-dark; } .action_button { @@ -64,6 +85,26 @@ body { } } +.darkMode .action_button { + background-color: $color-yellow; + color: $extremely-dark-gray; + + &.green { + background: #c4dd61; + color: #525252; + + &:hover { + background: #d5ea7f; + } + } + + &:hover { + background-color: #ffc904; + color: #000; + box-shadow: 0px 1px 3px #08090c; + } +} + a { color: #0093e7; text-decoration: none; @@ -77,6 +118,10 @@ a { } } +.darkMode a { + color: #61a4e2; +} + header { position: relative; z-index: 1000; @@ -110,8 +155,8 @@ header { height: 0; padding: 60px 0 0 10px; margin: 10px 0 0 10px; - background: url(/img/retina/materia_tmp_logo@2x.png) 0% 0% no-repeat; - background-size: 160px 68px; + background: url('/img/materia-logo-default-lightmode.svg') 50% 100% no-repeat; + background-size: 80px auto; } } @@ -148,7 +193,7 @@ header { a { font-size: 14px; - font-weight: 300; + font-weight: 400; color: #4c4c4c; white-space: nowrap; overflow: hidden; @@ -192,7 +237,7 @@ header { a { font-size: 14px; - font-weight: 100; + font-weight: 400; margin: 0; padding: 0; color: #4c4c4c; @@ -253,7 +298,7 @@ header { a { font-size: 14px; - font-weight: 300; + font-weight: 400; margin: 0; padding: 0; } @@ -262,7 +307,7 @@ header { } a { - color: #0093e7; + color: #0093e7; text-decoration: none; &:hover { @@ -453,6 +498,216 @@ header { } } +.checkbox-wrapper { + display: flex; + align-items: center; + margin-bottom: 0.25rem; + cursor: pointer; + + input { + position: absolute; + opacity: 0; + cursor: pointer; + } + + input:checked + .custom-checkbox { + background-color: #007bff; + border-color: #007bff; + } + + input:checked + .custom-checkbox::after { + display: block; + } + + .custom-checkbox { + position: relative; + display: inline-block; + width: 16px; + height: 16px; + margin: 0 0.5em 0 0; + padding: 0; + + background-color: #fff; + border: 2px solid #7e7e7e; + border-radius: 4px; + + transition: all 0.3s; + + &:after { + content: '✓'; + position: absolute; + display: none; + left: 50%; + top: 50%; + transform: translate(-50%, -50%); + color: #fff; + font-size: 14px; + } + } +} + +.radio-wrapper { + display: flex; + align-items: center; + margin-bottom: 0.5rem; + cursor: pointer; + + input { + position: absolute; + opacity: 0; + cursor: pointer; + } + + input:checked + .custom-radio { + background-color: #007bff; + border-color: #007bff; + } + + input:checked + .custom-radio::after { + display: block; + } + + .custom-radio { + position: relative; + display: inline-block; + width: 16px; + height: 16px; + margin: 0 0.5em 0 0; + padding: 0; + + background-color: #fff; + border: 2px solid #7e7e7e; + border-radius: 50%; + + transition: all 0.3s; + + &:after { + content: ''; + position: absolute; + display: none; + left: 50%; + top: 50%; + width: 8px; + height: 8px; + border-radius: 50%; + background-color: #fff; + transform: translate(-50%, -50%); + } + } +} + +.darkMode header { + &.logged_in { + background: #1d1f25 url(/img/header_border_alt.png) 0% 100% repeat-x; + } + + h1.logo { + a { + background: #1d1f25 url('/img/materia-logo-default-darkmode.svg') 50% 100% no-repeat; + background-size: 80px auto; + } + } + + .profile-bar + { + a { + color: $color-text-light-gray; + } + } + + // Not being used but kept just in case + .profile-menu + { + background-color: white; + box-shadow: 1px 10px 10px 1px rgba(0,0,0,0.1); + border: 1px solid white; + + ul { + li { + a { + color: $color-text-light-gray; + } + + a:hover { + border-bottom: 2px solid #0093E7; + } + } + } + + .arrow-top { + border-left: 15px solid transparent; + border-right: 15px solid transparent; + border-bottom: 15px solid white; + } + } + + .elevated { + color: #ffa52b; + } + + .nav_expandable { + color: #0093e7; + + ul { + background-color: $color-header-dark; + border-left: 1px solid $color-border-dark; + border-right: 1px solid $color-border-dark; + border-bottom: 1px solid $color-border-dark; + } + } + + #notices { + box-shadow: 1px 10px 10px 1px $color-box-shadow-dark; + background-color: $color-background-dark; + + h2 + { + color: #d8d8d8; + } + } + + .notice { + &:hover{ + background-color: $color-features-dark; + } + } + + .notice.deleted { + background-color:red !important + } + + #notifications_link { + background:url(../../../img/envelope.svg) 0% 0% no-repeat; + &:hover { + box-shadow: 0px 0px 5px 0px $color-box-shadow-dark; + } + } + + #notifications_link.notEmpty:after { + border: 1px solid red; + color: white; + background-color: red; + } + + .grantAccessTitle + { + border-top: 1px solid #d8d8d8; + } + + .notif-date + { + color: #d8d8d8; + } + + #removeAllNotifications + { + color: #d8d8d8; + &:hover { + color: red; + } + } +} + // mobile header @media (max-width: 720px) { header { @@ -611,7 +866,7 @@ header { a { font-size: 14px; - font-weight: 300; + font-weight: 400; margin: 0; padding: 0; } @@ -685,6 +940,21 @@ nav { } } +.darkMode nav { + ul { + li { + a { + color: #d8d8d8; + } + + a:hover { + border-bottom: 2px solid #0093E7; + color: #fff; + } + } + } +} + h1.logo { position: absolute; left: 0; @@ -698,21 +968,38 @@ h1.logo { height: 0; padding: 60px 0 0 10px; margin: 10px 0 0 10px; - background: url(/img/materia_tmp_logo.png) 0% 0% no-repeat; + background: url('/img/materia-logo-default-lightmode.svg') 50% 100% no-repeat; + background-size: 80px auto; + } +} + +.darkMode h1.logo { + a { + background: url('/img/materia-logo-default-darkmode.svg') 0% 0% no-repeat; + background-size: 80px auto; } } @media only screen and (min-device-pixel-ratio: 2), only screen and (-webkit-min-device-pixel-ratio: 2) { h1.logo a { - background: url(/img/retina/materia_tmp_logo@2x.png) 0% 0% no-repeat; - background-size: 160px 68px; + background: url('/img/materia-logo-default-lightmode.svg') 50% 100% no-repeat; + background-size: 80px auto; } header { background: #fff; background-size: 12px 6px; } + .darkMode h1.logo a { + background: url('/img/materia-logo-default-darkmode.svg') 50% 100% no-repeat; + background-size: 80px auto; + } + + .darkMode header { + background: #1d1f25; + background-size: 12px 6px; + } } .action_button { @@ -794,6 +1081,16 @@ h1.logo { } } +.darkMode .page, .widget { + .alert-wrapper { + background: rgba(0,0,0,0.66); + + .alert-dialog { + background: #21232a; + } + } +} + section, header, nav, @@ -807,6 +1104,7 @@ footer { color: #555; text-decoration: underline; margin: 10px 15px; + font-weight: 400; } .popup h2, @@ -819,6 +1117,13 @@ footer { // text-shadow: 0px 1px 0px #ccc; } +.darkMode +.popup h2, +.darkMode +.detail h2 { + color: #fff; +} + .error-support span.subtitle { font-size: 0.9em; margin-top: 0px; diff --git a/src/components/media.scss b/src/components/media.scss index a956efef9..fc6b7c248 100644 --- a/src/components/media.scss +++ b/src/components/media.scss @@ -128,6 +128,46 @@ body.import { } } +.darkMode .media-importer { + > section { + &:first-child { + &:before { + color: #dadada; + } + + &:after { + border-left: thin solid #dadada; + } + } + + .loading-icon-holder { + background: rgba(33,35,45,0.95); + } + } + + .pane-header { + &.darker { + color: #484848; + } + + .close-button { + &:after { + color: #fff; + } + } + } + + .pane-footer { + span.content { + background: rgba(255,255,255,0.95); + + &.error-state { + color: #730000; + } + } + } +} + #drag-wrapper { position: relative; height: 333px; diff --git a/src/components/modal.scss b/src/components/modal.scss index 9b6190f05..87cffd29f 100644 --- a/src/components/modal.scss +++ b/src/components/modal.scss @@ -42,6 +42,12 @@ text-align: center; } } + +.darkMode .modal { + background: #21232a; + border: #181920 3px solid; +} + .closed { display: none; } @@ -60,6 +66,7 @@ background: rgba(0, 0, 0, 0.5); } + .modal-guts { position: relative; top: 0; @@ -93,6 +100,10 @@ color: black; } +.darkMode .modal .close-button { + color: white; +} + .open-button { border: 0; position: absolute; diff --git a/src/components/my-widgets-collaborate-dialog.scss b/src/components/my-widgets-collaborate-dialog.scss index d1a6be550..d3c165272 100644 --- a/src/components/my-widgets-collaborate-dialog.scss +++ b/src/components/my-widgets-collaborate-dialog.scss @@ -1,3 +1,5 @@ +@import 'include.scss'; + // Collaborate dialog .modal .collaborate-modal { width: 100%; @@ -36,9 +38,11 @@ } .user-add { - width: 445px; - height: 30px; z-index: 2; + flex-grow: 2; + height: 30px; + margin-left: 1em; + padding-left: 0.5em; border: solid 1px #c9c9c9; font-size: 16px; } @@ -315,9 +319,12 @@ text-align: left; select { - cursor: pointer; display: inline-block; + padding: 0.25em; margin-bottom: 5px; + cursor: pointer; + + border-width: 1px; } .expires { @@ -405,6 +412,144 @@ } } +.darkMode .modal .collaborate-modal { + .title { + color: #fff; + border-bottom: #4c4e58 dotted 1px; + } + + .user-add { + border: solid 1px $color-input-box-border-dark; + background-color: $color-input-box-bg-dark; + color: #fff; + } + + .shareNotAllowed { + p { + color: red; + } + } + + .collab-search-list { + background-color: #21232a; + border: #181920 1px solid; + + .collab-search-match { + background-color: #21232a; + } + + .collab-search-match:hover { + background-color: #1b304b; + } + } + + .collab-container { + + .access-list { + background-color: #1d1f25; + } + } + + .disclaimer { + color: #d8d8d8; + } + + .access-list { + .user-perm { + &::after { + border-bottom: 1px solid #181920; + } + + .demote-dialog { + box-shadow: 0 2px 2px rgba(0, 0, 0, 0.3); + color: black; + background: #fcdbdb; + + .arrow { + background: url(/img/pink-arrow-left.png) no-repeat 0 center; + } + + .no-button { + color: #555; + } + + .yes-button { + background: #e10000; + border-color: #747474; + color: #ffffff; + } + + .yes-button:hover { + background: #ca0000; + } + } + + .remove { + color: #bfbfbf; + + &:hover:enabled { + color: white; + background: #21232a; + } + } + + .about { + .name { + &.user-match-student:after { + color: #d8d8d8; + } + + &.user-match-owner:after { + color: #d8d8d8; + } + } + } + + .options { + + select { + background-color: $color-input-box-bg-dark; + color: #fff; + border-color: $color-input-box-border-dark; + } + + .expires { + .expire-open-button { + color: #61a4e2; + + &:hover { + /* border-bottom: 1px #1778af solid; */ + color: #94c8fa; + } + } + .expire-open-button-disabled { + color: #d8d8d8; + } + .expire-date-container { + background: #21232a; + + .remove { + color: #d8d8d8; + &:hover { + color: #fff; + } + } + + .date-finish { + background: #295b99; + color: white; + + &:hover { + background: #366cad; + } + } + } + } + } + } + } +} + .react-datepicker__tab-loop .react-datepicker-popper { z-index: 9000; } diff --git a/src/components/my-widgets-copy-dialog.jsx b/src/components/my-widgets-copy-dialog.jsx index f6502ac45..e14aa1c55 100644 --- a/src/components/my-widgets-copy-dialog.jsx +++ b/src/components/my-widgets-copy-dialog.jsx @@ -65,11 +65,12 @@ const MyWidgetsCopyDialog = ({inst, name, onClose, onCopySuccess, onCopyError}) />Email notifications will be sent to {currentUser.email}.
+ +Email notifications will be sent to {currentUser.email}.
Note: This does not influence widgets.