[TIMOB-27126] iOS 13: Support dark mode
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | None |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2019-09-09T10:17:49.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 8.2.0 |
Components | n/a |
Labels | n/a |
Reporter | Vijay Singh |
Assignee | Ewan Harris |
Created | 2019-06-03T23:48:01.000+0000 |
Updated | 2019-09-10T16:26:58.000+0000 |
Description
Apple announced dark mode in iOS 13. Look for apis to support in SDK. WWDC 2019 video for dark mode support - https://developer.apple.com/videos/play/wwdc2019/214/
Dark mode is made via the asset catalog. Having semantic colors and images is the key here. I have a local plugin running that could even generate this cross platform, so maybe it could be a an SDK extension as well.
Required CLI hook + native bridge: https://github.com/hansemannn/titanium-dark-mode Pull request: https://github.com/appcelerator/titanium_mobile/pull/10937 The CLI hook and bridge could eventually be moved to the SDK, but this way it's a bit more flexible for developers right now.
master: https://github.com/appcelerator/titanium_mobile/pull/11097
FR passed. tested with the sample app here .https://github.com/ewanharris/darkmode-example. PR #10937 is merged. waiting on Jenkins for other PR
PR merged
Verified feature in SDK version
8.2.0.v20190904142953
. One thing I noticed is that images on the tabGroup do not change automatically when switching from light and dark mode unlike an imageVIew do, to see the image change on the tabGroup an app restart is needed. Is this an intended [~eharris]?.[~smohammed] It's not intended. Let me check on this.
[~kmahalingam] [~smohammed] PR for above fix - PR - https://github.com/appcelerator/titanium_mobile/pull/11200
FR passed.
*Closing ticket* New feature verified in SDK version 8.2.0.v20190906140307. Test and other information can be found at: https://github.com/appcelerator/titanium_mobile/pull/11200 https://github.com/appcelerator/titanium_mobile/pull/10937 https://github.com/hansemannn/titanium-dark-mode https://github.com/ewanharris/darkmode-example
A few remaining questions for parity: 1. Does it handle the alpha fallback for iOS < 13 and Android already, e.g. the ARGB conversion? 2. Are there plans to properly support Android, e.g. the
userInterfaceStyle
property?