FLPATH-4272 | [DCM] Hardcoded colors may break dark mode#3336
Conversation
Changed Packages
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #3336 +/- ##
==========================================
- Coverage 54.01% 54.00% -0.02%
==========================================
Files 2402 2403 +1
Lines 87402 87607 +205
Branches 24207 24292 +85
==========================================
+ Hits 47212 47309 +97
- Misses 38694 38789 +95
- Partials 1496 1509 +13
*This pull request uses carry forward flags. Click here to find out more. Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
mareklibra
left a comment
There was a problem hiding this comment.
Besides of the comment about isDarkMode(), it would be good to find other occurances difficult for the dark mode.
Hint: CatalogItemFormFields.tsx (background)
But there might be others
| borderRadius: theme.shape.borderRadius, | ||
| boxShadow: '0 1px 2px rgba(0, 0, 0, 0.06)', | ||
| boxShadow: | ||
| theme.palette.type === 'dark' |
There was a problem hiding this comment.
In a previous PR, a isDarkMode() function has been added. It would be good to reuse it here instead
|



Replace hardcoded colors and shadows with theme-aware values for dark mode support.
theme.palette.dividerinstead ofrgba(0,0,0,0.2)theme.palette.success.maininstead of#28a745theme.palette.typecheck