@expo/prebuild-config 10.0.7 → 10.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -104,6 +104,9 @@ async function setNotificationIconAsync(config, projectRoot) {
104
104
  function setNotificationConfig(config, manifest) {
105
105
  const icon = getNotificationIcon(config);
106
106
  const color = getNotificationColor(config);
107
+ if (config.notification) {
108
+ _configPlugins().WarningAggregator.addWarningAndroid('config.notification', 'The `notification` property in app config is deprecated. Use the `expo-notifications` config plugin instead.');
109
+ }
107
110
  const mainApplication = getMainApplicationOrThrow(manifest);
108
111
  if (icon) {
109
112
  addMetaDataItemToMainApplication(mainApplication, META_DATA_NOTIFICATION_ICON, NOTIFICATION_ICON_RESOURCE, 'resource');
@@ -1 +1 @@
1
- {"version":3,"file":"withAndroidNotifications.js","names":["_configPlugins","data","require","_imageUtils","_fs","_interopRequireDefault","_path","_withAndroidIcons","e","__esModule","default","Colors","AndroidConfig","addMetaDataItemToMainApplication","getMainApplicationOrThrow","removeMetaDataItemFromMainApplication","Manifest","BASELINE_PIXEL_SIZE","META_DATA_NOTIFICATION_ICON","exports","META_DATA_NOTIFICATION_ICON_COLOR","NOTIFICATION_ICON","NOTIFICATION_ICON_RESOURCE","NOTIFICATION_ICON_COLOR","NOTIFICATION_ICON_COLOR_RESOURCE","withNotificationIcons","config","withDangerousMod","setNotificationIconAsync","modRequest","projectRoot","withNotificationIconColor","withAndroidColors","modResults","setNotificationIconColor","withNotificationManifest","withAndroidManifest","setNotificationConfig","getNotificationIcon","notification","icon","getNotificationColor","color","writeNotificationIconImageFilesAsync","removeNotificationIconImageFilesAsync","manifest","mainApplication","colors","assignColorValue","name","value","Promise","all","Object","values","dpiValues","map","folderName","scale","drawableFolderName","replace","dpiFolderPath","path","resolve","ANDROID_RES_PATH","fs","promises","mkdir","recursive","iconSizePx","resizedIcon","generateImageAsync","cacheType","src","width","height","resizeMode","backgroundColor","source","writeFile","Error","rm","force"],"sources":["../../../../src/plugins/unversioned/expo-notifications/withAndroidNotifications.ts"],"sourcesContent":["import {\n AndroidConfig,\n ConfigPlugin,\n withAndroidColors,\n withAndroidManifest,\n withDangerousMod,\n} from '@expo/config-plugins';\nimport { ExpoConfig } from '@expo/config-types';\nimport { generateImageAsync } from '@expo/image-utils';\nimport fs from 'fs';\nimport path from 'path';\n\nimport { ANDROID_RES_PATH, dpiValues } from '../../icons/withAndroidIcons';\n\nconst { Colors } = AndroidConfig;\nconst {\n addMetaDataItemToMainApplication,\n getMainApplicationOrThrow,\n removeMetaDataItemFromMainApplication,\n} = AndroidConfig.Manifest;\n\ntype AndroidManifest = AndroidConfig.Manifest.AndroidManifest;\nconst BASELINE_PIXEL_SIZE = 24;\nexport const META_DATA_NOTIFICATION_ICON = 'expo.modules.notifications.default_notification_icon';\nexport const META_DATA_NOTIFICATION_ICON_COLOR =\n 'expo.modules.notifications.default_notification_color';\nexport const NOTIFICATION_ICON = 'notification_icon';\nexport const NOTIFICATION_ICON_RESOURCE = `@drawable/${NOTIFICATION_ICON}`;\nexport const NOTIFICATION_ICON_COLOR = 'notification_icon_color';\nexport const NOTIFICATION_ICON_COLOR_RESOURCE = `@color/${NOTIFICATION_ICON_COLOR}`;\n\nexport const withNotificationIcons: ConfigPlugin = (config) => {\n return withDangerousMod(config, [\n 'android',\n async (config) => {\n await setNotificationIconAsync(config, config.modRequest.projectRoot);\n return config;\n },\n ]);\n};\n\nexport const withNotificationIconColor: ConfigPlugin = (config) => {\n return withAndroidColors(config, (config) => {\n config.modResults = setNotificationIconColor(config, config.modResults);\n return config;\n });\n};\n\nexport const withNotificationManifest: ConfigPlugin = (config) => {\n return withAndroidManifest(config, (config) => {\n config.modResults = setNotificationConfig(config, config.modResults);\n return config;\n });\n};\n\nexport function getNotificationIcon(config: ExpoConfig) {\n return config.notification?.icon || null;\n}\n\nexport function getNotificationColor(config: ExpoConfig) {\n return config.notification?.color || null;\n}\n\n/**\n * Applies configuration for expo-notifications, including\n * the notification icon and notification color.\n */\nexport async function setNotificationIconAsync(config: ExpoConfig, projectRoot: string) {\n const icon = getNotificationIcon(config);\n if (icon) {\n await writeNotificationIconImageFilesAsync(icon, projectRoot);\n } else {\n await removeNotificationIconImageFilesAsync(projectRoot);\n }\n}\n\nexport function setNotificationConfig(config: ExpoConfig, manifest: AndroidManifest) {\n const icon = getNotificationIcon(config);\n const color = getNotificationColor(config);\n const mainApplication = getMainApplicationOrThrow(manifest);\n if (icon) {\n addMetaDataItemToMainApplication(\n mainApplication,\n META_DATA_NOTIFICATION_ICON,\n NOTIFICATION_ICON_RESOURCE,\n 'resource'\n );\n } else {\n removeMetaDataItemFromMainApplication(mainApplication, META_DATA_NOTIFICATION_ICON);\n }\n if (color) {\n addMetaDataItemToMainApplication(\n mainApplication,\n META_DATA_NOTIFICATION_ICON_COLOR,\n NOTIFICATION_ICON_COLOR_RESOURCE,\n 'resource'\n );\n } else {\n removeMetaDataItemFromMainApplication(mainApplication, META_DATA_NOTIFICATION_ICON_COLOR);\n }\n return manifest;\n}\n\nexport function setNotificationIconColor(\n config: ExpoConfig,\n colors: AndroidConfig.Resources.ResourceXML\n) {\n return Colors.assignColorValue(colors, {\n name: NOTIFICATION_ICON_COLOR,\n value: getNotificationColor(config),\n });\n}\n\nasync function writeNotificationIconImageFilesAsync(icon: string, projectRoot: string) {\n await Promise.all(\n Object.values(dpiValues).map(async ({ folderName, scale }) => {\n const drawableFolderName = folderName.replace('mipmap', 'drawable');\n const dpiFolderPath = path.resolve(projectRoot, ANDROID_RES_PATH, drawableFolderName);\n await fs.promises.mkdir(dpiFolderPath, { recursive: true });\n const iconSizePx = BASELINE_PIXEL_SIZE * scale;\n\n try {\n const resizedIcon = (\n await generateImageAsync(\n { projectRoot, cacheType: 'android-notification' },\n {\n src: icon,\n width: iconSizePx,\n height: iconSizePx,\n resizeMode: 'cover',\n backgroundColor: 'transparent',\n }\n )\n ).source;\n await fs.promises.writeFile(\n path.resolve(dpiFolderPath, NOTIFICATION_ICON + '.png'),\n resizedIcon\n );\n } catch (e) {\n throw new Error('Encountered an issue resizing Android notification icon: ' + e);\n }\n })\n );\n}\n\nasync function removeNotificationIconImageFilesAsync(projectRoot: string) {\n await Promise.all(\n Object.values(dpiValues).map(async ({ folderName }) => {\n const drawableFolderName = folderName.replace('mipmap', 'drawable');\n const dpiFolderPath = path.resolve(projectRoot, ANDROID_RES_PATH, drawableFolderName);\n await fs.promises.rm(path.resolve(dpiFolderPath, NOTIFICATION_ICON + '.png'), {\n force: true,\n });\n })\n );\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAAA,eAAA;EAAA,MAAAC,IAAA,GAAAC,OAAA;EAAAF,cAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAQA,SAAAE,YAAA;EAAA,MAAAF,IAAA,GAAAC,OAAA;EAAAC,WAAA,YAAAA,CAAA;IAAA,OAAAF,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAG,IAAA;EAAA,MAAAH,IAAA,GAAAI,sBAAA,CAAAH,OAAA;EAAAE,GAAA,YAAAA,CAAA;IAAA,OAAAH,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAK,MAAA;EAAA,MAAAL,IAAA,GAAAI,sBAAA,CAAAH,OAAA;EAAAI,KAAA,YAAAA,CAAA;IAAA,OAAAL,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAEA,SAAAM,kBAAA;EAAA,MAAAN,IAAA,GAAAC,OAAA;EAAAK,iBAAA,YAAAA,CAAA;IAAA,OAAAN,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAA2E,SAAAI,uBAAAG,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE3E,MAAM;EAAEG;AAAO,CAAC,GAAGC,8BAAa;AAChC,MAAM;EACJC,gCAAgC;EAChCC,yBAAyB;EACzBC;AAC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;AACH;AAEA,eAAeoC,qCAAqCA,CAACd,WAAmB,EAAE;EACxE,MAAMqB,OAAO,CAACC,GAAG,CACfC,MAAM,CAACC,MAAM,CAACC,6BAAS,CAAC,CAACC,GAAG,CAAC,OAAO;IAAEC;EAAW,CAAC,KAAK;IACrD,MAAME,kBAAkB,GAAGF,UAAU,CAACG,OAAO,CAAC,QAAQ,EAAE,UAAU,CAAC;IACnE,MAAMC,aAAa,GAAGC,eAAI,CAACC,OAAO,CAACjC,WAAW,EAAEkC,oCAAgB,EAAEL,kBAAkB,CAAC;IACrF,MAAMM,aAAE,CAACC,QAAQ,CAACe,EAAE,CAACnB,eAAI,CAACC,OAAO,CAACF,aAAa,EAAExC,iBAAiB,GAAG,MAAM,CAAC,EAAE;MAC5E6D,KAAK,EAAE;IACT,CAAC,CAAC;EACJ,CAAC,CACH,CAAC;AACH","ignoreList":[]}
1
+ {"version":3,"file":"withAndroidNotifications.js","names":["_configPlugins","data","require","_imageUtils","_fs","_interopRequireDefault","_path","_withAndroidIcons","e","__esModule","default","Colors","AndroidConfig","addMetaDataItemToMainApplication","getMainApplicationOrThrow","removeMetaDataItemFromMainApplication","Manifest","BASELINE_PIXEL_SIZE","META_DATA_NOTIFICATION_ICON","exports","META_DATA_NOTIFICATION_ICON_COLOR","NOTIFICATION_ICON","NOTIFICATION_ICON_RESOURCE","NOTIFICATION_ICON_COLOR","NOTIFICATION_ICON_COLOR_RESOURCE","withNotificationIcons","config","withDangerousMod","setNotificationIconAsync","modRequest","projectRoot","withNotificationIconColor","withAndroidColors","modResults","setNotificationIconColor","withNotificationManifest","withAndroidManifest","setNotificationConfig","getNotificationIcon","notification","icon","getNotificationColor","color","writeNotificationIconImageFilesAsync","removeNotificationIconImageFilesAsync","manifest","WarningAggregator","addWarningAndroid","mainApplication","colors","assignColorValue","name","value","Promise","all","Object","values","dpiValues","map","folderName","scale","drawableFolderName","replace","dpiFolderPath","path","resolve","ANDROID_RES_PATH","fs","promises","mkdir","recursive","iconSizePx","resizedIcon","generateImageAsync","cacheType","src","width","height","resizeMode","backgroundColor","source","writeFile","Error","rm","force"],"sources":["../../../../src/plugins/unversioned/expo-notifications/withAndroidNotifications.ts"],"sourcesContent":["import {\n AndroidConfig,\n ConfigPlugin,\n WarningAggregator,\n withAndroidColors,\n withAndroidManifest,\n withDangerousMod,\n} from '@expo/config-plugins';\nimport { ExpoConfig } from '@expo/config-types';\nimport { generateImageAsync } from '@expo/image-utils';\nimport fs from 'fs';\nimport path from 'path';\n\nimport { ANDROID_RES_PATH, dpiValues } from '../../icons/withAndroidIcons';\n\nconst { Colors } = AndroidConfig;\nconst {\n addMetaDataItemToMainApplication,\n getMainApplicationOrThrow,\n removeMetaDataItemFromMainApplication,\n} = AndroidConfig.Manifest;\n\ntype AndroidManifest = AndroidConfig.Manifest.AndroidManifest;\nconst BASELINE_PIXEL_SIZE = 24;\nexport const META_DATA_NOTIFICATION_ICON = 'expo.modules.notifications.default_notification_icon';\nexport const META_DATA_NOTIFICATION_ICON_COLOR =\n 'expo.modules.notifications.default_notification_color';\nexport const NOTIFICATION_ICON = 'notification_icon';\nexport const NOTIFICATION_ICON_RESOURCE = `@drawable/${NOTIFICATION_ICON}`;\nexport const NOTIFICATION_ICON_COLOR = 'notification_icon_color';\nexport const NOTIFICATION_ICON_COLOR_RESOURCE = `@color/${NOTIFICATION_ICON_COLOR}`;\n\nexport const withNotificationIcons: ConfigPlugin = (config) => {\n return withDangerousMod(config, [\n 'android',\n async (config) => {\n await setNotificationIconAsync(config, config.modRequest.projectRoot);\n return config;\n },\n ]);\n};\n\nexport const withNotificationIconColor: ConfigPlugin = (config) => {\n return withAndroidColors(config, (config) => {\n config.modResults = setNotificationIconColor(config, config.modResults);\n return config;\n });\n};\n\nexport const withNotificationManifest: ConfigPlugin = (config) => {\n return withAndroidManifest(config, (config) => {\n config.modResults = setNotificationConfig(config, config.modResults);\n return config;\n });\n};\n\nexport function getNotificationIcon(config: ExpoConfig) {\n return config.notification?.icon || null;\n}\n\nexport function getNotificationColor(config: ExpoConfig) {\n return config.notification?.color || null;\n}\n\n/**\n * Applies configuration for expo-notifications, including\n * the notification icon and notification color.\n */\nexport async function setNotificationIconAsync(config: ExpoConfig, projectRoot: string) {\n const icon = getNotificationIcon(config);\n if (icon) {\n await writeNotificationIconImageFilesAsync(icon, projectRoot);\n } else {\n await removeNotificationIconImageFilesAsync(projectRoot);\n }\n}\n\nexport function setNotificationConfig(config: ExpoConfig, manifest: AndroidManifest) {\n const icon = getNotificationIcon(config);\n const color = getNotificationColor(config);\n if (config.notification) {\n WarningAggregator.addWarningAndroid(\n 'config.notification',\n 'The `notification` property in app config is deprecated. Use the `expo-notifications` config plugin instead.'\n );\n }\n const mainApplication = getMainApplicationOrThrow(manifest);\n if (icon) {\n addMetaDataItemToMainApplication(\n mainApplication,\n META_DATA_NOTIFICATION_ICON,\n NOTIFICATION_ICON_RESOURCE,\n 'resource'\n );\n } else {\n removeMetaDataItemFromMainApplication(mainApplication, META_DATA_NOTIFICATION_ICON);\n }\n if (color) {\n addMetaDataItemToMainApplication(\n mainApplication,\n META_DATA_NOTIFICATION_ICON_COLOR,\n NOTIFICATION_ICON_COLOR_RESOURCE,\n 'resource'\n );\n } else {\n removeMetaDataItemFromMainApplication(mainApplication, META_DATA_NOTIFICATION_ICON_COLOR);\n }\n return manifest;\n}\n\nexport function setNotificationIconColor(\n config: ExpoConfig,\n colors: AndroidConfig.Resources.ResourceXML\n) {\n return Colors.assignColorValue(colors, {\n name: NOTIFICATION_ICON_COLOR,\n value: getNotificationColor(config),\n });\n}\n\nasync function writeNotificationIconImageFilesAsync(icon: string, projectRoot: string) {\n await Promise.all(\n Object.values(dpiValues).map(async ({ folderName, scale }) => {\n const drawableFolderName = folderName.replace('mipmap', 'drawable');\n const dpiFolderPath = path.resolve(projectRoot, ANDROID_RES_PATH, drawableFolderName);\n await fs.promises.mkdir(dpiFolderPath, { recursive: true });\n const iconSizePx = BASELINE_PIXEL_SIZE * scale;\n\n try {\n const resizedIcon = (\n await generateImageAsync(\n { projectRoot, cacheType: 'android-notification' },\n {\n src: icon,\n width: iconSizePx,\n height: iconSizePx,\n resizeMode: 'cover',\n backgroundColor: 'transparent',\n }\n )\n ).source;\n await fs.promises.writeFile(\n path.resolve(dpiFolderPath, NOTIFICATION_ICON + '.png'),\n resizedIcon\n );\n } catch (e) {\n throw new Error('Encountered an issue resizing Android notification icon: ' + e);\n }\n })\n );\n}\n\nasync function removeNotificationIconImageFilesAsync(projectRoot: string) {\n await Promise.all(\n Object.values(dpiValues).map(async ({ folderName }) => {\n const drawableFolderName = folderName.replace('mipmap', 'drawable');\n const dpiFolderPath = path.resolve(projectRoot, ANDROID_RES_PATH, drawableFolderName);\n await fs.promises.rm(path.resolve(dpiFolderPath, NOTIFICATION_ICON + '.png'), {\n force: true,\n });\n })\n );\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAAA,eAAA;EAAA,MAAAC,IAAA,GAAAC,OAAA;EAAAF,cAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AASA,SAAAE,YAAA;EAAA,MAAAF,IAAA,GAAAC,OAAA;EAAAC,WAAA,YAAAA,CAAA;IAAA,OAAAF,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAG,IAAA;EAAA,MAAAH,IAAA,GAAAI,sBAAA,CAAAH,OAAA;EAAAE,GAAA,YAAAA,CAAA;IAAA,OAAAH,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAK,MAAA;EAAA,MAAAL,IAAA,GAAAI,sBAAA,CAAAH,OAAA;EAAAI,KAAA,YAAAA,CAAA;IAAA,OAAAL,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAEA,SAAAM,kBAAA;EAAA,MAAAN,IAAA,GAAAC,OAAA;EAAAK,iBAAA,YAAAA,CAAA;IAAA,OAAAN,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAA2E,SAAAI,uBAAAG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nB,CACF,CAAC,EACDC,MAAM;MACR,MAAMb,aAAE,CAACC,QAAQ,CAACa,SAAS,CACzBjB,eAAI,CAACC,OAAO,CAACF,aAAa,EAAE1C,iBAAiB,GAAG,MAAM,CAAC,EACvDmD,WACF,CAAC;IACH,CAAC,CAAC,OAAOhE,CAAC,EAAE;MACV,MAAM,IAAI0E,KAAK,CAAC,2DAA2D,GAAG1E,CAAC,CAAC;IAClF;EACF,CAAC,CACH,CAAC;AACH;AAEA,eAAeoC,qCAAqCA,CAACd,WAAmB,EAAE;EACxE,MAAMuB,OAAO,CAACC,GAAG,CACfC,MAAM,CAACC,MAAM,CAACC,6BAAS,CAAC,CAACC,GAAG,CAAC,OAAO;IAAEC;EAAW,CAAC,KAAK;IACrD,MAAME,kBAAkB,GAAGF,UAAU,CAACG,OAAO,CAAC,QAAQ,EAAE,UAAU,CAAC;IACnE,MAAMC,aAAa,GAAGC,eAAI,CAACC,OAAO,CAACnC,WAAW,EAAEoC,oCAAgB,EAAEL,kBAAkB,CAAC;IACrF,MAAMM,aAAE,CAACC,QAAQ,CAACe,EAAE,CAACnB,eAAI,CAACC,OAAO,CAACF,aAAa,EAAE1C,iBAAiB,GAAG,MAAM,CAAC,EAAE;MAC5E+D,KAAK,EAAE;IACT,CAAC,CAAC;EACJ,CAAC,CACH,CAAC;AACH","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@expo/prebuild-config",
3
- "version": "10.0.7",
3
+ "version": "10.0.8",
4
4
  "description": "Get the prebuild config",
5
5
  "main": "build/index.js",
6
6
  "scripts": {
@@ -37,14 +37,14 @@
37
37
  "devDependencies": {
38
38
  "@types/debug": "^4.1.5",
39
39
  "@types/xml2js": "~0.4.11",
40
- "expo-module-scripts": "^5.0.5"
40
+ "expo-module-scripts": "^5.0.6"
41
41
  },
42
42
  "dependencies": {
43
- "@expo/config": "~12.0.6",
44
- "@expo/config-plugins": "~11.0.6",
45
- "@expo/config-types": "^54.0.6",
46
- "@expo/image-utils": "^0.8.5",
47
- "@expo/json-file": "^10.0.5",
43
+ "@expo/config": "~12.0.7",
44
+ "@expo/config-plugins": "~11.0.7",
45
+ "@expo/config-types": "^54.0.7",
46
+ "@expo/image-utils": "^0.8.6",
47
+ "@expo/json-file": "^10.0.6",
48
48
  "@react-native/normalize-colors": "0.81.1",
49
49
  "debug": "^4.3.1",
50
50
  "resolve-from": "^5.0.0",
@@ -54,5 +54,5 @@
54
54
  "publishConfig": {
55
55
  "access": "public"
56
56
  },
57
- "gitHead": "1dafdaa317c182191909a94a355c8b08a2654783"
57
+ "gitHead": "d635404a12ea7996b987ce0fb7679a238ebcf31b"
58
58
  }