Skip to content

Commit 3c703ef

Browse files
committed
fix(expo): stop removing UIUserInterfaceStyle when darkColors is present
The plugin was deleting UIUserInterfaceStyle from Info.plist whenever the theme JSON included darkColors, overriding the developer's app-wide userInterfaceStyle setting from app.json. This broke apps that intentionally pin to light or dark mode. The plugin now only embeds the theme data. Dark mode switching is controlled by the developer via Expo's existing userInterfaceStyle config.
1 parent 19bc65a commit 3c703ef

1 file changed

Lines changed: 0 additions & 8 deletions

File tree

packages/expo/app.plugin.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -670,14 +670,6 @@ const withClerkTheme = (config, props = {}) => {
670670
config = withInfoPlist(config, modConfig => {
671671
modConfig.modResults.ClerkTheme = themeJson;
672672
console.log('✅ Embedded Clerk theme in Info.plist');
673-
674-
// When darkColors is provided, remove UIUserInterfaceStyle to allow
675-
// the system to switch between light and dark mode automatically.
676-
if (themeJson.darkColors) {
677-
delete modConfig.modResults.UIUserInterfaceStyle;
678-
console.log('✅ Removed UIUserInterfaceStyle to enable system dark mode');
679-
}
680-
681673
return modConfig;
682674
});
683675

0 commit comments

Comments
 (0)