1import { ConfigPlugin, createRunOncePlugin, withPlugins } from 'expo/config-plugins';
2
3import { withAndroidRootViewBackgroundColor } from './withAndroidRootViewBackgroundColor';
4import { withAndroidUserInterfaceStyle } from './withAndroidUserInterfaceStyle';
5import { withIosRootViewBackgroundColor } from './withIosRootViewBackgroundColor';
6import { withIosUserInterfaceStyle } from './withIosUserInterfaceStyle';
7
8const pkg = require('expo-system-ui/package.json');
9
10const withSystemUI: ConfigPlugin = (config) => {
11  return withPlugins(config, [
12    withAndroidRootViewBackgroundColor,
13    withIosRootViewBackgroundColor,
14    withAndroidUserInterfaceStyle,
15    withIosUserInterfaceStyle,
16  ]);
17};
18
19export default createRunOncePlugin(withSystemUI, pkg.name, pkg.version);
20