From ff6d8a96d80596fde47ddd05262d371c1dfb161c Mon Sep 17 00:00:00 2001 From: Andrew Brown Date: Sat, 16 May 2020 16:04:21 -0500 Subject: [PATCH] more work on dark mode --- app/assets/stylesheets/content.css.scss | 5 +- app/assets/stylesheets/dark-mode.scss | 164 +++++++++++++++++- .../serendipitous/_content_question.html.erb | 4 +- .../cards/_content_relation_list.html.erb | 4 +- .../cards/_in_universe_content_list.html.erb | 2 +- .../components/_list_filter_bar.html.erb | 6 +- app/views/content/list/_cards.html.erb | 4 +- app/views/content_page_shares/_form.html.erb | 2 +- app/views/data/collaboration.html.erb | 4 +- app/views/data/uploads.html.erb | 2 +- .../analysis/sections/_readability.html.erb | 6 +- .../analysis/sections/_style.html.erb | 2 +- app/views/layouts/_document_navbar.html.erb | 2 +- app/views/layouts/_navbar.html.erb | 2 +- app/views/layouts/application.html.erb | 2 +- app/views/layouts/editor.html.erb | 2 +- app/views/layouts/forum.html.erb | 2 +- app/views/main/index.html.erb | 4 +- app/views/page_collections/explore.html.erb | 8 +- app/views/page_collections/show.html.erb | 2 +- app/views/subscriptions/prepay.html.erb | 2 +- 21 files changed, 194 insertions(+), 37 deletions(-) diff --git a/app/assets/stylesheets/content.css.scss b/app/assets/stylesheets/content.css.scss index 36b9eea1..95cce714 100644 --- a/app/assets/stylesheets/content.css.scss +++ b/app/assets/stylesheets/content.css.scss @@ -68,7 +68,10 @@ p.long-form { margin-right: -5px; margin-bottom: 20px; position: relative; - background: white; + + background: rgba(255, 255, 255, 0.15); + background-blend-mode: darken; + z-index: 1; textarea { diff --git a/app/assets/stylesheets/dark-mode.scss b/app/assets/stylesheets/dark-mode.scss index 0e0be951..8049e76d 100644 --- a/app/assets/stylesheets/dark-mode.scss +++ b/app/assets/stylesheets/dark-mode.scss @@ -8,18 +8,50 @@ body { background-color: #202123; color: #fff; nav { - background-color: #26A69A; + background-color: #2196F3; } .card { - background-color: rgba(255,255,255,0.2); + background-color: rgba(255, 255, 255, 0.2); + } + .card-reveal { + background-color: #2D2D31; + + .card-title { + color: #fff; + } } + .dropdown-content { + background-color: #2D2D31; + a { + color: #ccc; + &:hover { + background-color: #3B4043; + } + } + } + .modal { + background-color: #2D2D31; + } .btn { - background-color: #EE6F73; + background-color: #000000; + border: 1px solid #aaa; + border-top: 1px solid #ccc; + border-bottom: 1px solid #888; } .divider { opacity: 0.2; - } - .sidenav { + } + textarea, input { + color: #fff; + + &::placeholder { + color: #aaa; + } + } + .collapsible-header { + background-color: #3B4043; + } + .sidenav, .collapsible-body { background-color: #2D2D31; li { a { @@ -45,5 +77,127 @@ body { border-bottom: 1px solid rgba(255,255,255,0.2);; } } + #editor { + background-color: #3B4043; + color: white; + } + + #thredded--container { + input { + color: white; + } + + .thredded--form.thredded--navigation--search.thredded--navigation--search-topics input { + background-color: #2196F3; + } + + .thredded--form { + input, textarea { + color: white; + background-color: #3B4043; + + &::placeholder { + color: #ddd; + } + } + + .thredded--preview-area { + color: #ddd; + } + + .thredded--form--submit { + background-color: #2196F3; + color: white; + } + } + + .thredded--messageboard, .thredded--form { + background-color: #3B4043; + } + + .thredded--messageboard--description { + color: white; + } + + .thredded--messageboard--byline, .thredded--messageboard--meta--counts, .thredded--navigation-breadcrumbs li a { + color: #9AA0A6; + } + + .thredded--nav-text { + color: #ddd; + } + + .thredded--post--created-at { + color: #9AA0A6; + } + + .thredded--topic-header { + .thredded--topic-header--title { + color: white; + } + + .thredded--topic-header--started-by, .thredded--topic-followers, .thredded--topic-header--follow-info--reason { + color: #9AA0A6; + + a { + color: #4CAF50; + } + } + } + + .thredded--post--user { + color: black; + + a { + color: #4CAF50; + } + } + + .thredded--post { + background: #3B4043; + color: white; + + border-bottom: 1px solid #333; + border-top: 1px solid #666; + } + + .thredded--topics--topic { + background-color: #3B4043; + + .thredded--topics--title a { + color: white; + } + + .thredded--topics--updated-by { + color: #9AA0A6; + + a { + color: #4CAF50; + } + } + + .thredded--topics--posts-count { + border: 1px solid #555; + } + } + + .thredded--currently-online { + background-color: #3B4043; + + .thredded--currently-online--title { + color: #9AA0A6; + } + } + + .thredded--user-navigation--item a { + &:hover { + color: #000; + } + } + } + + .thredded--post-form--title { + color: #9AA0A6; + } } } \ No newline at end of file diff --git a/app/views/cards/serendipitous/_content_question.html.erb b/app/views/cards/serendipitous/_content_question.html.erb index 936609b8..e80f768a 100644 --- a/app/views/cards/serendipitous/_content_question.html.erb +++ b/app/views/cards/serendipitous/_content_question.html.erb @@ -15,7 +15,7 @@ ) %> -
+
<%= form_for content do |f| %> <%= hidden_field(:override, :redirect_path, value: redirect_path) if defined?(redirect_path) %> @@ -30,7 +30,7 @@ Save answer to <%= content.name_field_value.downcase %> <% end %> <% if !defined?(show_view_button) || !!show_view_button %> - <%= link_to content, class: 'btn white black-text', target: '_new' do %> + <%= link_to content, class: 'btn', target: '_new' do %> <%= content.class.icon %> View <%= content.name_field_value %> <% end %> diff --git a/app/views/content/cards/_content_relation_list.html.erb b/app/views/content/cards/_content_relation_list.html.erb index fd21b912..6e8c959c 100644 --- a/app/views/content/cards/_content_relation_list.html.erb +++ b/app/views/content/cards/_content_relation_list.html.erb @@ -16,7 +16,7 @@ render partial: 'content/cards/content_relation_list', locals: { content_type: : <% end %>
- + <% if defined? card_title %> <% formatted_card_title = card_title.dup @@ -36,7 +36,7 @@ render partial: 'content/cards/content_relation_list', locals: { content_type: :

- + <% if relations.any? %> <%= content_type_class.icon %> diff --git a/app/views/content/cards/_in_universe_content_list.html.erb b/app/views/content/cards/_in_universe_content_list.html.erb index 11d071c3..2a9a8b22 100644 --- a/app/views/content/cards/_in_universe_content_list.html.erb +++ b/app/views/content/cards/_in_universe_content_list.html.erb @@ -76,7 +76,7 @@
- + <% if content_list.any? %> <%= content_type_class.icon %> diff --git a/app/views/content/components/_list_filter_bar.html.erb b/app/views/content/components/_list_filter_bar.html.erb index fa1c308d..e4c91777 100644 --- a/app/views/content/components/_list_filter_bar.html.erb +++ b/app/views/content/components/_list_filter_bar.html.erb @@ -9,7 +9,7 @@ <% if content_type.new.respond_to?(:universe) %>
- + <%= ContentFormatterService.show(text: content.name.presence || 'Untitled', viewing_user: current_user) %>

@@ -36,7 +36,7 @@ <% end %>

- + <%= content.name.presence || 'Document preview' %> close diff --git a/app/views/content_page_shares/_form.html.erb b/app/views/content_page_shares/_form.html.erb index 86f31717..ce85ed0f 100644 --- a/app/views/content_page_shares/_form.html.erb +++ b/app/views/content_page_shares/_form.html.erb @@ -4,7 +4,7 @@ share Click here to share a page
-
+
<%= form_for [current_user, ContentPageShare.new(user: current_user)] do |f| %>
diff --git a/app/views/data/collaboration.html.erb b/app/views/data/collaboration.html.erb index 5a96fb3a..164f8161 100644 --- a/app/views/data/collaboration.html.erb +++ b/app/views/data/collaboration.html.erb @@ -22,7 +22,7 @@ <%= universe.name %> (<%= pluralize universe.contributors.count, 'collaborator' %>)
-
+
<%= render partial: 'content/display/contributors', locals: { content: universe } %>
@@ -41,7 +41,7 @@ <%= Universe.icon %> <%= universe.name %>
-
+
<%= render partial: 'content/display/contributors', locals: { content: universe } %>
diff --git a/app/views/data/uploads.html.erb b/app/views/data/uploads.html.erb index 893d5240..fef53f50 100644 --- a/app/views/data/uploads.html.erb +++ b/app/views/data/uploads.html.erb @@ -75,7 +75,7 @@
- + Readability scales close @@ -133,7 +133,7 @@
- + Why is this important? close @@ -172,7 +172,7 @@
- + Why is this important? close diff --git a/app/views/documents/analysis/sections/_style.html.erb b/app/views/documents/analysis/sections/_style.html.erb index 252892b2..c221f7c6 100644 --- a/app/views/documents/analysis/sections/_style.html.erb +++ b/app/views/documents/analysis/sections/_style.html.erb @@ -27,7 +27,7 @@
- + Words per sentence close diff --git a/app/views/layouts/_document_navbar.html.erb b/app/views/layouts/_document_navbar.html.erb index 27379059..bedcfce8 100644 --- a/app/views/layouts/_document_navbar.html.erb +++ b/app/views/layouts/_document_navbar.html.erb @@ -31,7 +31,7 @@