-
Notifications
You must be signed in to change notification settings - Fork 75
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
Deprecate isDarkMode in favor of useThemeStore #847
Conversation
apps/antalmanac/src/components/RightPane/SectionTable/SectionTableBody.tsx
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This mostly looks good other than a different change that slipped into the commit. Also, instead of deprecating isDarkMode()
and, therefore, leaving it there, just delete it since nothing uses it.
Because I'm a pedant, I'll say that the the better implementation of appTheme == "dark"
would be appTheme.isDark()
so that "dark" and "light" aren't magic values. Intellisense tells you, but you ideally shouldn't need Intellisence. I know you didn't write the interface to begin with, so I won't make you do the search-and-replace (but it should be pretty easy). I say it for the sake of future code.
Also, for the future, please fix the merge conflicts so that there is at least one deployment so the reviewer doesn't need to spin up a local instance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for holding your PR up in review. Everything looks good except for the logic I mentioned. I can't let that slide.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Summary
Refactored implementations of isDarkMode() (from helpers) in favor of useThemeStore
Closes #812 #854