fix: theme switch without reload#5132
Conversation
|
✅ All Jest tests passed! This PR is ready to merge. |
2756eb5 to
6179b63
Compare
|
✅ All Jest tests passed! This PR is ready to merge. |
1 similar comment
|
✅ All Jest tests passed! This PR is ready to merge. |
5b3a14e to
17f7a16
Compare
|
✅ All Jest tests passed! This PR is ready to merge. |
|
@omsuneri i did run prettier, it showed the same after 3 tries :) |
|
@7se7en72025 Does it change the color of the background canvas as well? |
|
Sorry i forgot it, will commit soon. |
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
|
@Commanderk3 done pls check the changes, updated video in desc |
|
@7se7en72025 To resolve this ESLint issue, I suggest installing the latest version of Prettier (CI always uses the latest version) and then run Prettier on the affected files. |
|
Ahh Thanx ,will try and commit soon |
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
Refactor jest.spyOn for getItem to improve readability.
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
|
same happened with me in #4832 |
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
|
❌ Some Jest tests failed. Please check the logs and fix the issues before merging. Failed Tests: |
|
oops. I thought I fixed it. Aargh. |
* fix: instant theme switching without page reload * Fix canvas background not updating on theme switch * Refactor theme application to use arrow functions * Refactor themebox test for consistency and clarity * Refactor getItem mock implementation in tests Refactor jest.spyOn for getItem to improve readability. * Refactor themebox test for improved readability * prettier --------- Co-authored-by: Walter Bender <walter@sorceo.com>
theme now switches instantly without refreshing the whole page
added applyThemeInstantly() to update colors in real-time quick.
updates body classes, canvas bg, platformColor, meta tags
refreshes palettes and floating windows on the fly
updated tests....
sugarlabs_finalthemechangefix.mp4
fixes #4520