Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tweak dark themes into a higher contrast #991

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

donnywellson
Copy link

I have modified the dark themes. I made some changes to how they switch from light to dark. The changes aren't much. In the theme.dart file instead of using the case method to switch between light and dark themes, I created two static constructors that would be placed in the theme and darktheme parameter. I also moved all files I could find relating theme to a new folder called themes. It was the only way I could stop myself from being confused and making repeated mistakes. Because of that, I had to remove most unused imports and place new ones. So the pull request may say over a dozen files have changed but it's really not that many. I also created some custom themes and placed them in a folder under themes to make the theme.dart code easier to read. I changed the DesignereVariables.dark constructor's values into something that would give the app a higher contrast. If you are unsatisfied with how the dark theme of the app turned out I could change the values again

@PIG208 PIG208 linked an issue Oct 8, 2024 that may be closed by this pull request
@chrisbobbe
Copy link
Collaborator

Thanks for the PR. Please make the following changes so that we can review it:

  1. In the PR description, link the issue or previous conversation that prompted the PR. It's Tweak dark theme for slightly higher contrast #973, right?
  2. Tidy up your PR branch into clear and coherent commits. If you need help with this, please ask in #git help in the development community.
  3. Make sure all commits pass all tests (tools/check).
  4. In the commit(s) that change the colors that are used, the commit message should link to the source of the new colors. Greg pointed to an updated Figma in Tweak dark theme for slightly higher contrast #973; I believe that means you don't have to choose any colors yourself.

@donnywellson
Copy link
Author

donnywellson commented Oct 9, 2024 via email

@donnywellson
Copy link
Author

donnywellson commented Oct 12, 2024

Tweak dark theme for slightly higher contrast #973
. In this pull request, I moved all files I could find that related to themes into a folder called themes to stop myself from being confused. I also edited the theme by making two static ThemeData returns. This seemed more understandable. I also created custom themes which I placed inside a folder called custom themes under the created themes folder. This was to make the code in themes more readable. I also created widget tests for the custom themes which I placed in the themes_test.dart file. I also add the get package dependency to the pubsec.yaml file to add in the custom them tests. I see that there is conflict in this pull request. I suspect it's from me adding the get dependency, moving files to the themes folder and removing imports beacus e of the moved files. Pleas review my pull request and inform me if there is something you'd like me to change

@gnprice
Copy link
Member

gnprice commented Oct 12, 2024

You'll need to clean up the Git branch in order to make it possible to review this any further. See the resources Chris linked above.

@donnywellson
Copy link
Author

In this final revision of my commit history, I didn't move any files in the themes folder, which I had done previously. Everything else remains the same. I created two static ThemeData returns in the theme.dart file because it makes the code easier to read and understand. The app.dart file now includes values for both the light and dark themes. I created custom themes and placed them in the themes folder. Additionally, I altered the values of DesignVariables.dark. I was advised to use Figma for this, but since I am still learning how to use Figma, I utilized the Visual Studio Code color editor instead. I also created tests for the custom themes to ensure that their values would switch as the app transitions from light to dark mode. If you are unsatisfied with the outcome of the dark theme mode, please let me know.

@gnprice
Copy link
Member

gnprice commented Oct 13, 2024

This is a bit closer but the Git history still isn't clear enough to make this possible to review.

In particular there will need to be a commit that just changes the colors, and doesn't make other changes in the same commit.

@donnywellson
Copy link
Author

donnywellson commented Oct 14, 2024 via email

@gnprice
Copy link
Member

gnprice commented Oct 14, 2024

Git can tell you what the sequence of changes in your commits actually is. Then it enables you to revise the commits. Again, see the Git resources Chris linked above.

@donnywellson
Copy link
Author

donnywellson commented Oct 14, 2024

This is the same as my previous commit history except I have made a commit about altering the DesignVaruiables.dark(). I realize my error. The ThemeData returns and the DesgnVariables were in the same class, which caused me to make such a mistake. In one of my previous commit histories, I separated these two by placing them in different classes to prevent such a mistake, which I recommend doing, but in an attempt to resolve some conflicts between repositories, I abandoned the idea, for now. Please review my pull request and tell me the areas you are unsatisfied with,

Comment on lines +102 to +105
background: const Color(0xff000000), // Keeps deep black background for full dark contrast.
bgCounterUnread: const Color(0xff333366).withValues(alpha: 0.37), // Darkened for better contrast with lighter text.
bgTopBar: const Color(0xff1a1a1a), // Darkened for better distinction from the background.
borderBar: Colors.black.withValues(alpha: 0.41), // Lower contrast for subtle visibility.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this PR is trying to make an original redesign of all our dark-theme colors. That isn't what this issue calls for.

See again what Chris said at #991 (comment) , the first comment above:

4. In the commit(s) that change the colors that are used, the commit message should link to the source of the new colors. Greg pointed to an updated Figma in Tweak dark theme for slightly higher contrast #973; I believe that means you don't have to choose any colors yourself.

@gnprice
Copy link
Member

gnprice commented Oct 16, 2024

This also still doesn't meet our standards for a clean Git history. In particular it doesn't satisfy this point Chris mentioned above:

3. Make sure all commits pass all tests (tools/check).

because it's broken after the first commit (and in fact stays broken until near the end).

You need to invest more effort in reviewing your own work before asking others to review it for you. When we're just repeating the same points because they haven't been addressed, that's not a good use of our time or of yours.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tweak dark theme for slightly higher contrast
3 participants