From b4445b1f7cfd13cbff164b495c93b11f68d93c10 Mon Sep 17 00:00:00 2001 From: Vignesh Joglekar Date: Tue, 12 Oct 2021 04:50:24 -0500 Subject: [PATCH] Adds various dark mode missing styles (#1367) * Swaps issue template to new issue form syntax * Indentation update * Indentation update? * More indentation * Intendation is hard * Finalized indentation? * Github indentation * Missing fields * Formatting changes * Checkbox changes * Fixes various dark mode issues * Couple more dark mode issues --- assets/js/dashboard/datepicker.js | 2 +- assets/js/dashboard/filters.js | 2 +- assets/js/dashboard/stats/modals/filter.js | 10 ++--- assets/tailwind.config.js | 1 + .../templates/site/index.html.eex | 18 ++++----- .../membership/invite_member_form.html.eex | 26 ++++++------- .../templates/site/settings_people.html.eex | 37 +++++++++---------- .../site/settings_search_console.html.eex | 2 +- 8 files changed, 49 insertions(+), 49 deletions(-) diff --git a/assets/js/dashboard/datepicker.js b/assets/js/dashboard/datepicker.js index 490000d6a..7168b4778 100644 --- a/assets/js/dashboard/datepicker.js +++ b/assets/js/dashboard/datepicker.js @@ -302,7 +302,7 @@ class DatePicker extends React.Component { onClick={this.close} query={this.props.query} className={`${boldClass } px-4 py-2 text-sm leading-tight hover:bg-gray-100 hover:text-gray-900 - dark:hover:bg-gray-900 hover:text-gray-900 dark:hover:text-gray-100 flex items-center justify-between`} + dark:hover:bg-gray-900 dark:hover:text-gray-100 flex items-center justify-between`} > {text} {keybinds[text]} diff --git a/assets/js/dashboard/filters.js b/assets/js/dashboard/filters.js index 64c13da29..7e58e6f6b 100644 --- a/assets/js/dashboard/filters.js +++ b/assets/js/dashboard/filters.js @@ -112,7 +112,7 @@ function filterDropdownOption(site, option) { diff --git a/assets/js/dashboard/stats/modals/filter.js b/assets/js/dashboard/stats/modals/filter.js index 129559238..9ef8c90c1 100644 --- a/assets/js/dashboard/stats/modals/filter.js +++ b/assets/js/dashboard/stats/modals/filter.js @@ -201,9 +201,9 @@ class FilterModal extends React.Component { {({ open }) => ( <>
- + { this.selectedFilterType(filterName) } -
@@ -219,7 +219,7 @@ class FilterModal extends React.Component { >
@@ -227,7 +227,7 @@ class FilterModal extends React.Component { this.setFilterType(filterName, 'is')} className={classNames( - active ? 'bg-gray-100 text-gray-900' : 'text-gray-700', + active ? 'bg-gray-100 dark:bg-gray-900 text-gray-900 dark:text-gray-100' : 'text-gray-700 dark:text-gray-200', 'cursor-pointer block px-4 py-2 text-sm' )} > @@ -241,7 +241,7 @@ class FilterModal extends React.Component { this.setFilterType(filterName, 'is_not')} className={classNames( - active ? 'bg-gray-100 text-gray-900' : 'text-gray-700', + active ? 'bg-gray-100 dark:bg-gray-900 text-gray-900 dark:text-gray-100' : 'text-gray-700 dark:text-gray-200', 'cursor-pointer block px-4 py-2 text-sm' )} > diff --git a/assets/tailwind.config.js b/assets/tailwind.config.js index f36c7b823..77d73b415 100644 --- a/assets/tailwind.config.js +++ b/assets/tailwind.config.js @@ -47,6 +47,7 @@ module.exports = { cursor: ['hover'], justifyContent: ['responsive'], backgroundColor: ['odd', 'even'], + shadow: ['dark'] } }, plugins: [ diff --git a/lib/plausible_web/templates/site/index.html.eex b/lib/plausible_web/templates/site/index.html.eex index 62d7e5f82..a8104197f 100644 --- a/lib/plausible_web/templates/site/index.html.eex +++ b/lib/plausible_web/templates/site/index.html.eex @@ -118,7 +118,7 @@ x-transition:leave="transition ease-in duration-200" x-transition:leave-start="opacity-100" x-transition:leave-end="opacity-0" - class="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" + class="fixed inset-0 bg-gray-500 dark:bg-gray-800 bg-opacity-75 dark:bg-opacity-75 transition-opacity" aria-hidden="true" @click="invitationOpen = false" >
@@ -134,11 +134,11 @@ x-transition:leave="transition ease-in duration-200" x-transition:leave-start="opacity-100 translate-y-0 sm:scale-100" x-transition:leave-end="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95" - class="inline-block align-bottom bg-white rounded-lg text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-lg sm:w-full" + class="inline-block align-bottom bg-white dark:bg-gray-900 rounded-lg text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-lg sm:w-full" > -
+
-
-

+

You've been invited to the analytics dashboard as Admin.

-

+

If you accept the ownership transfer, you will be responsible for billing going forward. <%= if is_nil(@current_user.trial_expiry_date) && is_nil(@current_user.subscription) do %>

@@ -173,11 +173,11 @@

-
+
-
diff --git a/lib/plausible_web/templates/site/membership/invite_member_form.html.eex b/lib/plausible_web/templates/site/membership/invite_member_form.html.eex index c358b1412..81467a65c 100644 --- a/lib/plausible_web/templates/site/membership/invite_member_form.html.eex +++ b/lib/plausible_web/templates/site/membership/invite_member_form.html.eex @@ -1,12 +1,12 @@ <%= form_for @conn, Routes.membership_path(@conn, :invite_member, @site.domain), [class: "max-w-lg w-full mx-auto bg-white dark:bg-gray-800 shadow-md rounded px-8 pt-6 pb-8 mb-4 mt-8"], fn f -> %>

Invite member to <%= @site.domain %>

-

+

Enter the email address and role of the person you want to invite. We will contact them over email to offer them access to <%= @site.domain %> analytics.

-

+

The invitation will expire in 48 hours

@@ -18,35 +18,35 @@ <%= label f, :email, "Email address", class: "block text-sm font-medium text-gray-700 dark:text-gray-300" %>
- +
- <%= email_input(f, :email, class: "focus:ring-indigo-500 focus:border-indigo-500 block w-full rounded-md pl-10 sm:text-sm border-gray-300", placeholder: "john.doe@example.com", required: "true") %> + <%= email_input(f, :email, class: "focus:ring-indigo-500 focus:border-indigo-500 dark:bg-gray-900 dark:text-gray-300 block w-full rounded-md pl-10 sm:text-sm border-gray-300 dark:border-gray-500", placeholder: "john.doe@example.com", required: "true") %>
<%= error_tag f, :email %>
<%= label f, :role, class: "block text-sm font-medium text-gray-700 dark:text-gray-300" %> -
-