Preferred light/dark theme?
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- android, ios, javascript, react-native
- Domain
- mobile
Research direction
Start by reviewing React Native's AndroidInfoModule entry point and the Android uiMode and iOS traitCollection.userInterfaceStyle APIs cited in the issue. The work is done when the theme provider can distinguish unspecified, light, and dark preferences on both platforms, with behavior covered by appropriate tests.
Written by the indexing model from the issue text.
Description
Describe the feature
It'd be nice to automatically be able to accommodate a user's preferred light/dark theme preferences.
Perhaps, simplifying the check of uiMode && UI_MODE_NIGHT_MASK on Android and traitCollection.userInterfaceStyle on iOS.
These both have undefined/unspecified, light, and dark/night.
Unfortunately, the built-in react-native uiMode doesn't give this information.
Motivation
With iOS 13 and Android Q making this sort of theming more integrated (and Google and Apple's own apps supporting the ability to switch at the OS level), it'd be nice to automatically detect what theme the user wants.
I'd rather not force a user to fumble through app settings to configure the theme if they've already got an option to specify it at the OS level.
Related Issues
I didn't see any at first glance, but I may have missed them.
- Dominant language
- JavaScript
- Stars
- 466
- Forks
- 53
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from callstack/react-theme-provider
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
-
question
Difficulty 5/5 Over a week Newbie friendliness 10/100
callstack/react-theme-provider#156 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
callstack/react-theme-provider#144 · 3 comments · 4 reactions ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 25/100
callstack/react-theme-provider#139 · 1 comment · 12 reactions ·
All issues in callstack/react-theme-provider
Similar issues
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 90/100
apache/cloudstack#14222 ·
-
Browser Waiting for: Product Owner
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
getsentry/sentry-javascript#24577 · 1 comment ·
-
curation good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
amponce/archive-movie-browser#186 ·
-
light
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
aemdemos/patients-stryker#253 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
clerk/javascript#9852 ·