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

Change default theme from light to the system's default theme #2544

Merged
merged 5 commits into from
Apr 16, 2024

Conversation

adam-rozen
Copy link
Contributor

This PR is to change the default visual theme from light to the system default.

At the moment, light theme is always default. There is already functionality built-in to Actual for using the system theme, so this change will just set the system theme be the default for Actual. Users can still override the theme manually like before, but now Actual will obey the user's set preference right away. This change only comes into play when the theme is not set.

I tried to test with the playwright module, but the test Schedules › creates a new schedule, posts the transaction and later completes it failed saying that the Target page, context, or browser has been closed and then it timed out. Might be a local issue, so submitting the PR to see if the automated build passes.

Copy link

netlify bot commented Apr 3, 2024

Deploy Preview for actualbudget ready!

Name Link
🔨 Latest commit 8608227
🔍 Latest deploy log https://app.netlify.com/sites/actualbudget/deploys/661eb6838a5d4600086a3401
😎 Deploy Preview https://deploy-preview-2544.demo.actualbudget.org
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

github-actions bot commented Apr 3, 2024

Bundle Stats — desktop-client

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
9 4.64 MB 0%

Changeset

No files were changed

View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

No assets were smaller

Unchanged

Asset File Size % Changed
static/js/indexeddb-main-thread-worker-e59fee74.js 13.5 kB 0%
static/js/resize-observer.js 18.37 kB 0%
static/js/BackgroundImage.js 122.29 kB 0%
static/js/narrow.js 56.68 kB 0%
static/js/usePreviewTransactions.js 790 B 0%
static/js/AppliedFilters.js 20.35 kB 0%
static/js/wide.js 262.74 kB 0%
static/js/ReportRouter.js 1.19 MB 0%
static/js/index.js 2.97 MB 0%

Copy link
Contributor

github-actions bot commented Apr 3, 2024

Bundle Stats — loot-core

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
1 1.2 MB → 1.2 MB (-1 B) -0.00%
Changeset
File Δ Size
packages/loot-core/src/server/main.ts 📉 -1 B (-0.00%) 64.39 kB → 64.39 kB
View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

Asset File Size % Changed
kcab.worker.js 1.2 MB → 1.2 MB (-1 B) -0.00%

Unchanged

No assets were unchanged

@adam-rozen adam-rozen changed the title Change Actual default theme to System Default Change default theme from light to the system's default theme Apr 3, 2024
@adam-rozen adam-rozen marked this pull request as ready for review April 3, 2024 04:38
@adam-rozen
Copy link
Contributor Author

Hello! This automated visual testing stuff is very cool and makes it easy to tell what changed. The visual regression test failed, looks to be due to the fact that the symbol on the default theme is the computer, while it expects the light theme to be set and using the sun symbol. I can't check all the photos due to some file system limitations (file names are too long).

Would appreciate some advice here on the next steps!

@shall0pass
Copy link
Contributor

shall0pass commented Apr 3, 2024

Hello! This automated visual testing stuff is very cool and makes it easy to tell what changed. The visual regression test failed, looks to be due to the fact that the symbol on the default theme is the computer, while it expects the light theme to be set and using the sun symbol. I can't check all the photos due to some file system limitations (file names are too long).

Would appreciate some advice here on the next steps!

There are instructions how to run the VRT tests locally and update the snapshots here: https://github.com/actualbudget/actual/tree/master/packages/desktop-client/README.md

@adam-rozen
Copy link
Contributor Author

Thanks for updating that. I just figured out late yesterday that the reason I was struggling with running the tests was my computer's speed. Updating the timeout fixed it, but I hadn't had a chance to commit & push it yet.

@youngcw
Copy link
Member

youngcw commented Apr 16, 2024

Thanks for updating that. I just figured out late yesterday that the reason I was struggling with running the tests was my computer's speed. Updating the timeout fixed it, but I hadn't had a chance to commit & push it yet.

I guess I should have been a bit more patient. Glad you got your end figured out

@MatissJanis
Copy link
Member

(totally unrelated to your PR and it should not block merging this PR you did here)

Do folks understand what the desktop icon means? I get what the "sun" icon (or moon) would represent. But if we're now defaulting to "desktop" version - do people actually understand what the default desktop icon represents? Personally, I wouldn't understand what it is (unless I clicked on it).

@youngcw
Copy link
Member

youngcw commented Apr 16, 2024

(totally unrelated to your PR and it should not block merging this PR you did here)

Do folks understand what the desktop icon means? I get what the "sun" icon (or moon) would represent. But if we're now defaulting to "desktop" version - do people actually understand what the default desktop icon represents? Personally, I wouldn't understand what it is (unless I clicked on it).

It had been discussed removing that button unless in a dev environment. I imagine people really only use it to compare the themes, then don't use it again unless testing changes

@MatissJanis
Copy link
Member

It had been discussed removing that button unless in a dev environment. I imagine people really only use it to compare the themes, then don't use it again unless testing changes

That makes sense! It would also reduce the amount of buttons we have on screen (thus reduce clutter) :)

@youngcw youngcw merged commit a2c1c2d into actualbudget:master Apr 16, 2024
19 checks passed
@trafico-bot trafico-bot bot added ✨ Merged Pull Request has been merged successfully and removed ✅ Approved labels Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ Merged Pull Request has been merged successfully
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants