expo-intent-launcher 12.1.0-canary-20250221-ef26fed → 12.1.0-canary-20250303-4dba60e

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.
package/CHANGELOG.md CHANGED
@@ -16,6 +16,10 @@
16
16
  - [Android] Started using expo modules gradle plugin. ([#34176](https://github.com/expo/expo/pull/34176) by [@lukmccall](https://github.com/lukmccall))
17
17
  - [apple] Migrate remaining `expo-module.config.json` to unified platform syntax. ([#34445](https://github.com/expo/expo/pull/34445) by [@reichhartd](https://github.com/reichhartd))
18
18
 
19
+ ## 12.0.2 - 2025-01-10
20
+
21
+ _This version does not introduce any user-facing changes._
22
+
19
23
  ## 12.0.1 — 2024-10-22
20
24
 
21
25
  _This version does not introduce any user-facing changes._
@@ -160,11 +160,10 @@ export declare function startActivityAsync(activityAction: ActivityAction | stri
160
160
  * Opens an application by its package name.
161
161
  * @param packageName For example: `com.google.android.gm` for Gmail.
162
162
  */
163
- export declare function openApplication(packageName: string): any;
163
+ export declare function openApplication(packageName: string): void;
164
164
  /**
165
165
  * Returns the icon of the specified application as a base64-encoded PNG image string.
166
- * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image` `<Image>`
167
- * component's `source` prop.
166
+ * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image`'s [`Image.source`](./image/#source) prop.
168
167
  *
169
168
  * @param packageName The package name of the target application. For example, `com.google.android.gm` for Gmail.
170
169
  * @return A promise that resolves to the base64-encoded PNG icon of the specified application, or an empty string if the icon could not be retrieved.
@@ -1 +1 @@
1
- {"version":3,"file":"IntentLauncher.d.ts","sourceRoot":"","sources":["../src/IntentLauncher.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,oBAAY,cAAc;IACxB,sBAAsB,4CAA4C;IAClE,oBAAoB,0CAA0C;IAC9D,sBAAsB,4CAA4C;IAClE,YAAY,kCAAkC;IAC9C,0BAA0B,uDAAuD;IACjF,yBAAyB,+CAA+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AC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAGD,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,UAAU,EAAE,UAAU,CAAC;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAGD,oBAAY,UAAU;IACpB;;OAEG;IACH,OAAO,KAAK;IACZ;;OAEG;IACH,QAAQ,IAAI;IACZ;;OAEG;IACH,SAAS,IAAI;CACd;AAGD;;;;;;;;GAQG;AACH,wBAAsB,kBAAkB,CACtC,cAAc,EAAE,cAAc,GAAG,MAAM,EACvC,MAAM,GAAE,oBAAyB,GAChC,OAAO,CAAC,oBAAoB,CAAC,CAQ/B;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,CAKzD;AAED;;;;;;GAMG;AACH,wBAAsB,uBAAuB,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAKlF"}
@@ -134,8 +134,7 @@ export function openApplication(packageName) {
134
134
  }
135
135
  /**
136
136
  * Returns the icon of the specified application as a base64-encoded PNG image string.
137
- * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image` `<Image>`
138
- * component's `source` prop.
137
+ * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image`'s [`Image.source`](./image/#source) prop.
139
138
  *
140
139
  * @param packageName The package name of the target application. For example, `com.google.android.gm` for Gmail.
141
140
  * @return A promise that resolves to the base64-encoded PNG icon of the specified application, or an empty string if the icon could not be retrieved.
@@ -1 +1 @@
1
- {"version":3,"file":"IntentLauncher.js","sourceRoot":"","sources":["../src/IntentLauncher.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAExD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UAAU,eAAe,CAAC,WAAmB;IACjD,IAAI,CAAC,kBAAkB,CAAC,eAAe,EAAE;QACvC,MAAM,IAAI,mBAAmB,CAAC,gBAAgB,EAAE,iBAAiB,CAAC,CAAC;KACpE;IACD,OAAO,kBAAkB,CAAC,eAAe,CAAC,WAAW,CAAC,CAAC;AACzD,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAAC,WAAmB;IAC/D,IAAI,CAAC,kBAAkB,CAAC,kBAAkB,EAAE;QAC1C,MAAM,IAAI,mBAAmB,CAAC,gBAAgB,EAAE,yBAAyB,CAAC,CAAC;KAC5E;IACD,OAAO,kBAAkB,CAAC,kBAAkB,CAAC,WAAW,CAAC,CAAC;AAC5D,CAAC","sourcesContent":["import { UnavailabilityError } from 'expo-modules-core';\n\nimport ExpoIntentLauncher from './ExpoIntentLauncher';\n\n// @needsAudit\n/**\n * Constants are from the source code of [Settings provider](https://developer.android.com/reference/android/provider/Settings).\n */\nexport enum ActivityAction {\n ACCESSIBILITY_SETTINGS = 'android.settings.ACCESSIBILITY_SETTINGS',\n ADD_ACCOUNT_SETTINGS = 'android.settings.ADD_ACCOUNT_SETTINGS',\n AIRPLANE_MODE_SETTINGS = 'android.settings.AIRPLANE_MODE_SETTINGS',\n APN_SETTINGS = 'android.settings.APN_SETTINGS',\n APP_NOTIFICATION_REDACTION = 'android.settings.ACTION_APP_NOTIFICATION_REDACTION',\n APP_NOTIFICATION_SETTINGS = 'android.settings.APP_NOTIFICATION_SETTINGS',\n APP_OPS_SETTINGS = 'android.settings.APP_OPS_SETTINGS',\n APPLICATION_DETAILS_SETTINGS = 'android.settings.APPLICATION_DETAILS_SETTINGS',\n APPLICATION_DEVELOPMENT_SETTINGS = 'android.settings.APPLICATION_DEVELOPMENT_SETTINGS',\n APPLICATION_SETTINGS = 'android.settings.APPLICATION_SETTINGS',\n BATTERY_SAVER_SETTINGS = 'android.settings.BATTERY_SAVER_SETTINGS',\n BLUETOOTH_SETTINGS = 'android.settings.BLUETOOTH_SETTINGS',\n CAPTIONING_SETTINGS = 'android.settings.CAPTIONING_SETTINGS',\n CAST_SETTINGS = 'android.settings.CAST_SETTINGS',\n CONDITION_PROVIDER_SETTINGS = 'android.settings.ACTION_CONDITION_PROVIDER_SETTINGS',\n DATA_ROAMING_SETTINGS = 'android.settings.DATA_ROAMING_SETTINGS',\n DATE_SETTINGS = 'android.settings.DATE_SETTINGS',\n DEVICE_INFO_SETTINGS = 'android.settings.DEVICE_INFO_SETTINGS',\n DEVICE_NAME = 'android.settings.DEVICE_NAME',\n DISPLAY_SETTINGS = 'android.settings.DISPLAY_SETTINGS',\n DREAM_SETTINGS = 'android.settings.DREAM_SETTINGS',\n HARD_KEYBOARD_SETTINGS = 'android.settings.HARD_KEYBOARD_SETTINGS',\n HOME_SETTINGS = 'android.settings.HOME_SETTINGS',\n IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS = 'android.settings.IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS',\n IGNORE_BATTERY_OPTIMIZATION_SETTINGS = 'android.settings.IGNORE_BATTERY_OPTIMIZATION_SETTINGS',\n INPUT_METHOD_SETTINGS = 'android.settings.INPUT_METHOD_SETTINGS',\n INPUT_METHOD_SUBTYPE_SETTINGS = 'android.settings.INPUT_METHOD_SUBTYPE_SETTINGS',\n INTERNAL_STORAGE_SETTINGS = 'android.settings.INTERNAL_STORAGE_SETTINGS',\n LOCALE_SETTINGS = 'android.settings.LOCALE_SETTINGS',\n LOCATION_SOURCE_SETTINGS = 'android.settings.LOCATION_SOURCE_SETTINGS',\n MANAGE_ALL_APPLICATIONS_SETTINGS = 'android.settings.MANAGE_ALL_APPLICATIONS_SETTINGS',\n MANAGE_APPLICATIONS_SETTINGS = 'android.settings.MANAGE_APPLICATIONS_SETTINGS',\n MANAGE_DEFAULT_APPS_SETTINGS = 'android.settings.MANAGE_DEFAULT_APPS_SETTINGS',\n MEMORY_CARD_SETTINGS = 'android.settings.MEMORY_CARD_SETTINGS',\n MONITORING_CERT_INFO = 'android.settings.MONITORING_CERT_INFO',\n NETWORK_OPERATOR_SETTINGS = 'android.settings.NETWORK_OPERATOR_SETTINGS',\n NFC_PAYMENT_SETTINGS = 'android.settings.NFC_PAYMENT_SETTINGS',\n NFC_SETTINGS = 'android.settings.NFC_SETTINGS',\n NFCSHARING_SETTINGS = 'android.settings.NFCSHARING_SETTINGS',\n NIGHT_DISPLAY_SETTINGS = 'android.settings.NIGHT_DISPLAY_SETTINGS',\n NOTIFICATION_LISTENER_SETTINGS = 'android.settings.ACTION_NOTIFICATION_LISTENER_SETTINGS',\n NOTIFICATION_POLICY_ACCESS_SETTINGS = 'android.settings.NOTIFICATION_POLICY_ACCESS_SETTINGS',\n NOTIFICATION_SETTINGS = 'android.settings.NOTIFICATION_SETTINGS',\n PAIRING_SETTINGS = 'android.settings.PAIRING_SETTINGS',\n PRINT_SETTINGS = 'android.settings.ACTION_PRINT_SETTINGS',\n PRIVACY_SETTINGS = 'android.settings.PRIVACY_SETTINGS',\n QUICK_LAUNCH_SETTINGS = 'android.settings.QUICK_LAUNCH_SETTINGS',\n REQUEST_IGNORE_BATTERY_OPTIMIZATIONS = 'android.settings.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS',\n SECURITY_SETTINGS = 'android.settings.SECURITY_SETTINGS',\n SETTINGS = 'android.settings.SETTINGS',\n SHOW_ADMIN_SUPPORT_DETAILS = 'android.settings.SHOW_ADMIN_SUPPORT_DETAILS',\n SHOW_INPUT_METHOD_PICKER = 'android.settings.SHOW_INPUT_METHOD_PICKER',\n SHOW_REGULATORY_INFO = 'android.settings.SHOW_REGULATORY_INFO',\n SHOW_REMOTE_BUGREPORT_DIALOG = 'android.settings.SHOW_REMOTE_BUGREPORT_DIALOG',\n SOUND_SETTINGS = 'android.settings.SOUND_SETTINGS',\n STORAGE_MANAGER_SETTINGS = 'android.settings.STORAGE_MANAGER_SETTINGS',\n SYNC_SETTINGS = 'android.settings.SYNC_SETTINGS',\n SYSTEM_UPDATE_SETTINGS = 'android.settings.SYSTEM_UPDATE_SETTINGS',\n TETHER_PROVISIONING_UI = 'android.settings.TETHER_PROVISIONING_UI',\n TRUSTED_CREDENTIALS_USER = 'android.settings.TRUSTED_CREDENTIALS_USER',\n USAGE_ACCESS_SETTINGS = 'android.settings.USAGE_ACCESS_SETTINGS',\n USER_DICTIONARY_INSERT = 'android.settings.USER_DICTIONARY_INSERT',\n USER_DICTIONARY_SETTINGS = 'android.settings.USER_DICTIONARY_SETTINGS',\n USER_SETTINGS = 'android.settings.USER_SETTINGS',\n VOICE_CONTROL_AIRPLANE_MODE = 'android.settings.VOICE_CONTROL_AIRPLANE_MODE',\n VOICE_CONTROL_BATTERY_SAVER_MODE = 'android.settings.VOICE_CONTROL_BATTERY_SAVER_MODE',\n VOICE_CONTROL_DO_NOT_DISTURB_MODE = 'android.settings.VOICE_CONTROL_DO_NOT_DISTURB_MODE',\n VOICE_INPUT_SETTINGS = 'android.settings.VOICE_INPUT_SETTINGS',\n VPN_SETTINGS = 'android.settings.VPN_SETTINGS',\n VR_LISTENER_SETTINGS = 'android.settings.VR_LISTENER_SETTINGS',\n WEBVIEW_SETTINGS = 'android.settings.WEBVIEW_SETTINGS',\n WIFI_IP_SETTINGS = 'android.settings.WIFI_IP_SETTINGS',\n WIFI_SETTINGS = 'android.settings.WIFI_SETTINGS',\n WIRELESS_SETTINGS = 'android.settings.WIRELESS_SETTINGS',\n ZEN_MODE_AUTOMATION_SETTINGS = 'android.settings.ZEN_MODE_AUTOMATION_SETTINGS',\n ZEN_MODE_EVENT_RULE_SETTINGS = 'android.settings.ZEN_MODE_EVENT_RULE_SETTINGS',\n ZEN_MODE_EXTERNAL_RULE_SETTINGS = 'android.settings.ZEN_MODE_EXTERNAL_RULE_SETTINGS',\n ZEN_MODE_PRIORITY_SETTINGS = 'android.settings.ZEN_MODE_PRIORITY_SETTINGS',\n ZEN_MODE_SCHEDULE_RULE_SETTINGS = 'android.settings.ZEN_MODE_SCHEDULE_RULE_SETTINGS',\n ZEN_MODE_SETTINGS = 'android.settings.ZEN_MODE_SETTINGS',\n}\n\n// @needsAudit\nexport interface IntentLauncherParams {\n /**\n * A string specifying the MIME type of the data represented by the data parameter. Ignore this\n * argument to allow Android to infer the correct MIME type.\n */\n type?: string;\n /**\n * Category provides more details about the action the intent performs. See [`Intent.addCategory`](https://developer.android.com/reference/android/content/Intent#addCategory(java.lang.String)).\n */\n category?: string;\n /**\n * A map specifying additional key-value pairs which are passed with the intent as `extras`.\n * The keys must include a package prefix, for example the app `com.android.contacts` would use\n * names like `com.android.contacts.ShowAll`.\n */\n extra?: Record<string, any>;\n /**\n * A URI specifying the data that the intent should operate upon. (_Note:_ Android requires the URI\n * scheme to be lowercase, unlike the formal RFC.)\n */\n data?: string;\n /**\n * Bitmask of flags to be used. See [`Intent.setFlags`](https://developer.android.com/reference/android/content/Intent#setFlags(int)) for more details.\n */\n flags?: number;\n /**\n * Package name used as an identifier of ComponentName. Set this only if you want to explicitly\n * set the component to handle the intent.\n */\n packageName?: string;\n /**\n * Class name of the ComponentName.\n */\n className?: string;\n}\n\n// @needsAudit\nexport interface IntentLauncherResult {\n /**\n * Result code returned by the activity.\n */\n resultCode: ResultCode;\n /**\n * Optional data URI that can be returned by the activity.\n */\n data?: string;\n /**\n * Optional extras object that can be returned by the activity.\n */\n extra?: object;\n}\n\n// @needsAudit\nexport enum ResultCode {\n /**\n * Indicates that the activity operation succeeded.\n */\n Success = -1,\n /**\n * Means that the activity was canceled, for example, by tapping on the back button.\n */\n Canceled = 0,\n /**\n * First custom, user-defined value that can be returned by the activity.\n */\n FirstUser = 1,\n}\n\n// @needsAudit\n/**\n * Starts the specified activity. The method will return a promise which resolves when the user\n * returns to the app.\n * @param activityAction The action to be performed, for example, `IntentLauncher.ActivityAction.WIRELESS_SETTINGS`.\n * There are a few pre-defined constants you can use for this parameter.\n * You can find them at [`expo-intent-launcher/src/IntentLauncher.ts`](https://github.com/expo/expo/blob/main/packages/expo-intent-launcher/src/IntentLauncher.ts).\n * @param params An object of intent parameters.\n * @return A promise which fulfils with `IntentLauncherResult` object.\n */\nexport async function startActivityAsync(\n activityAction: ActivityAction | string,\n params: IntentLauncherParams = {}\n): Promise<IntentLauncherResult> {\n if (!ExpoIntentLauncher.startActivity) {\n throw new UnavailabilityError('IntentLauncher', 'startActivityAsync');\n }\n if (!activityAction || typeof activityAction !== 'string') {\n throw new TypeError(`'activityAction' argument must be a non-empty string!`);\n }\n return ExpoIntentLauncher.startActivity(activityAction, params);\n}\n\n/**\n * Opens an application by its package name.\n * @param packageName For example: `com.google.android.gm` for Gmail.\n */\nexport function openApplication(packageName: string) {\n if (!ExpoIntentLauncher.openApplication) {\n throw new UnavailabilityError('IntentLauncher', 'openApplication');\n }\n return ExpoIntentLauncher.openApplication(packageName);\n}\n\n/**\n * Returns the icon of the specified application as a base64-encoded PNG image string.\n * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image` `<Image>`\n * component's `source` prop.\n *\n * @param packageName The package name of the target application. For example, `com.google.android.gm` for Gmail.\n * @return A promise that resolves to the base64-encoded PNG icon of the specified application, or an empty string if the icon could not be retrieved.\n */\nexport async function getApplicationIconAsync(packageName: string): Promise<string> {\n if (!ExpoIntentLauncher.getApplicationIcon) {\n throw new UnavailabilityError('IntentLauncher', 'getApplicationIconAsync');\n }\n return ExpoIntentLauncher.getApplicationIcon(packageName);\n}\n"]}
1
+ {"version":3,"file":"IntentLauncher.js","sourceRoot":"","sources":["../src/IntentLauncher.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAExD,OAAO,kBAAkB,MAAM,sBAAsB,CAAC;AAEtD,cAAc;AACd;;GAEG;AACH,MAAM,CAAN,IAAY,cAiFX;AAjFD,WAAY,cAAc;IACxB,oFAAkE,CAAA;IAClE,gFAA8D,CAAA;IAC9D,oFAAkE,CAAA;IAClE,gEAA8C,CAAA;IAC9C,mGA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CAAC;AAED;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAAC,WAAmB;IAC/D,IAAI,CAAC,kBAAkB,CAAC,kBAAkB,EAAE;QAC1C,MAAM,IAAI,mBAAmB,CAAC,gBAAgB,EAAE,yBAAyB,CAAC,CAAC;KAC5E;IACD,OAAO,kBAAkB,CAAC,kBAAkB,CAAC,WAAW,CAAC,CAAC;AAC5D,CAAC","sourcesContent":["import { UnavailabilityError } from 'expo-modules-core';\n\nimport ExpoIntentLauncher from './ExpoIntentLauncher';\n\n// @needsAudit\n/**\n * Constants are from the source code of [Settings provider](https://developer.android.com/reference/android/provider/Settings).\n */\nexport enum ActivityAction {\n ACCESSIBILITY_SETTINGS = 'android.settings.ACCESSIBILITY_SETTINGS',\n ADD_ACCOUNT_SETTINGS = 'android.settings.ADD_ACCOUNT_SETTINGS',\n AIRPLANE_MODE_SETTINGS = 'android.settings.AIRPLANE_MODE_SETTINGS',\n APN_SETTINGS = 'android.settings.APN_SETTINGS',\n APP_NOTIFICATION_REDACTION = 'android.settings.ACTION_APP_NOTIFICATION_REDACTION',\n APP_NOTIFICATION_SETTINGS = 'android.settings.APP_NOTIFICATION_SETTINGS',\n APP_OPS_SETTINGS = 'android.settings.APP_OPS_SETTINGS',\n APPLICATION_DETAILS_SETTINGS = 'android.settings.APPLICATION_DETAILS_SETTINGS',\n APPLICATION_DEVELOPMENT_SETTINGS = 'android.settings.APPLICATION_DEVELOPMENT_SETTINGS',\n APPLICATION_SETTINGS = 'android.settings.APPLICATION_SETTINGS',\n BATTERY_SAVER_SETTINGS = 'android.settings.BATTERY_SAVER_SETTINGS',\n BLUETOOTH_SETTINGS = 'android.settings.BLUETOOTH_SETTINGS',\n CAPTIONING_SETTINGS = 'android.settings.CAPTIONING_SETTINGS',\n CAST_SETTINGS = 'android.settings.CAST_SETTINGS',\n CONDITION_PROVIDER_SETTINGS = 'android.settings.ACTION_CONDITION_PROVIDER_SETTINGS',\n DATA_ROAMING_SETTINGS = 'android.settings.DATA_ROAMING_SETTINGS',\n DATE_SETTINGS = 'android.settings.DATE_SETTINGS',\n DEVICE_INFO_SETTINGS = 'android.settings.DEVICE_INFO_SETTINGS',\n DEVICE_NAME = 'android.settings.DEVICE_NAME',\n DISPLAY_SETTINGS = 'android.settings.DISPLAY_SETTINGS',\n DREAM_SETTINGS = 'android.settings.DREAM_SETTINGS',\n HARD_KEYBOARD_SETTINGS = 'android.settings.HARD_KEYBOARD_SETTINGS',\n HOME_SETTINGS = 'android.settings.HOME_SETTINGS',\n IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS = 'android.settings.IGNORE_BACKGROUND_DATA_RESTRICTIONS_SETTINGS',\n IGNORE_BATTERY_OPTIMIZATION_SETTINGS = 'android.settings.IGNORE_BATTERY_OPTIMIZATION_SETTINGS',\n INPUT_METHOD_SETTINGS = 'android.settings.INPUT_METHOD_SETTINGS',\n INPUT_METHOD_SUBTYPE_SETTINGS = 'android.settings.INPUT_METHOD_SUBTYPE_SETTINGS',\n INTERNAL_STORAGE_SETTINGS = 'android.settings.INTERNAL_STORAGE_SETTINGS',\n LOCALE_SETTINGS = 'android.settings.LOCALE_SETTINGS',\n LOCATION_SOURCE_SETTINGS = 'android.settings.LOCATION_SOURCE_SETTINGS',\n MANAGE_ALL_APPLICATIONS_SETTINGS = 'android.settings.MANAGE_ALL_APPLICATIONS_SETTINGS',\n MANAGE_APPLICATIONS_SETTINGS = 'android.settings.MANAGE_APPLICATIONS_SETTINGS',\n MANAGE_DEFAULT_APPS_SETTINGS = 'android.settings.MANAGE_DEFAULT_APPS_SETTINGS',\n MEMORY_CARD_SETTINGS = 'android.settings.MEMORY_CARD_SETTINGS',\n MONITORING_CERT_INFO = 'android.settings.MONITORING_CERT_INFO',\n NETWORK_OPERATOR_SETTINGS = 'android.settings.NETWORK_OPERATOR_SETTINGS',\n NFC_PAYMENT_SETTINGS = 'android.settings.NFC_PAYMENT_SETTINGS',\n NFC_SETTINGS = 'android.settings.NFC_SETTINGS',\n NFCSHARING_SETTINGS = 'android.settings.NFCSHARING_SETTINGS',\n NIGHT_DISPLAY_SETTINGS = 'android.settings.NIGHT_DISPLAY_SETTINGS',\n NOTIFICATION_LISTENER_SETTINGS = 'android.settings.ACTION_NOTIFICATION_LISTENER_SETTINGS',\n NOTIFICATION_POLICY_ACCESS_SETTINGS = 'android.settings.NOTIFICATION_POLICY_ACCESS_SETTINGS',\n NOTIFICATION_SETTINGS = 'android.settings.NOTIFICATION_SETTINGS',\n PAIRING_SETTINGS = 'android.settings.PAIRING_SETTINGS',\n PRINT_SETTINGS = 'android.settings.ACTION_PRINT_SETTINGS',\n PRIVACY_SETTINGS = 'android.settings.PRIVACY_SETTINGS',\n QUICK_LAUNCH_SETTINGS = 'android.settings.QUICK_LAUNCH_SETTINGS',\n REQUEST_IGNORE_BATTERY_OPTIMIZATIONS = 'android.settings.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS',\n SECURITY_SETTINGS = 'android.settings.SECURITY_SETTINGS',\n SETTINGS = 'android.settings.SETTINGS',\n SHOW_ADMIN_SUPPORT_DETAILS = 'android.settings.SHOW_ADMIN_SUPPORT_DETAILS',\n SHOW_INPUT_METHOD_PICKER = 'android.settings.SHOW_INPUT_METHOD_PICKER',\n SHOW_REGULATORY_INFO = 'android.settings.SHOW_REGULATORY_INFO',\n SHOW_REMOTE_BUGREPORT_DIALOG = 'android.settings.SHOW_REMOTE_BUGREPORT_DIALOG',\n SOUND_SETTINGS = 'android.settings.SOUND_SETTINGS',\n STORAGE_MANAGER_SETTINGS = 'android.settings.STORAGE_MANAGER_SETTINGS',\n SYNC_SETTINGS = 'android.settings.SYNC_SETTINGS',\n SYSTEM_UPDATE_SETTINGS = 'android.settings.SYSTEM_UPDATE_SETTINGS',\n TETHER_PROVISIONING_UI = 'android.settings.TETHER_PROVISIONING_UI',\n TRUSTED_CREDENTIALS_USER = 'android.settings.TRUSTED_CREDENTIALS_USER',\n USAGE_ACCESS_SETTINGS = 'android.settings.USAGE_ACCESS_SETTINGS',\n USER_DICTIONARY_INSERT = 'android.settings.USER_DICTIONARY_INSERT',\n USER_DICTIONARY_SETTINGS = 'android.settings.USER_DICTIONARY_SETTINGS',\n USER_SETTINGS = 'android.settings.USER_SETTINGS',\n VOICE_CONTROL_AIRPLANE_MODE = 'android.settings.VOICE_CONTROL_AIRPLANE_MODE',\n VOICE_CONTROL_BATTERY_SAVER_MODE = 'android.settings.VOICE_CONTROL_BATTERY_SAVER_MODE',\n VOICE_CONTROL_DO_NOT_DISTURB_MODE = 'android.settings.VOICE_CONTROL_DO_NOT_DISTURB_MODE',\n VOICE_INPUT_SETTINGS = 'android.settings.VOICE_INPUT_SETTINGS',\n VPN_SETTINGS = 'android.settings.VPN_SETTINGS',\n VR_LISTENER_SETTINGS = 'android.settings.VR_LISTENER_SETTINGS',\n WEBVIEW_SETTINGS = 'android.settings.WEBVIEW_SETTINGS',\n WIFI_IP_SETTINGS = 'android.settings.WIFI_IP_SETTINGS',\n WIFI_SETTINGS = 'android.settings.WIFI_SETTINGS',\n WIRELESS_SETTINGS = 'android.settings.WIRELESS_SETTINGS',\n ZEN_MODE_AUTOMATION_SETTINGS = 'android.settings.ZEN_MODE_AUTOMATION_SETTINGS',\n ZEN_MODE_EVENT_RULE_SETTINGS = 'android.settings.ZEN_MODE_EVENT_RULE_SETTINGS',\n ZEN_MODE_EXTERNAL_RULE_SETTINGS = 'android.settings.ZEN_MODE_EXTERNAL_RULE_SETTINGS',\n ZEN_MODE_PRIORITY_SETTINGS = 'android.settings.ZEN_MODE_PRIORITY_SETTINGS',\n ZEN_MODE_SCHEDULE_RULE_SETTINGS = 'android.settings.ZEN_MODE_SCHEDULE_RULE_SETTINGS',\n ZEN_MODE_SETTINGS = 'android.settings.ZEN_MODE_SETTINGS',\n}\n\n// @needsAudit\nexport interface IntentLauncherParams {\n /**\n * A string specifying the MIME type of the data represented by the data parameter. Ignore this\n * argument to allow Android to infer the correct MIME type.\n */\n type?: string;\n /**\n * Category provides more details about the action the intent performs. See [`Intent.addCategory`](https://developer.android.com/reference/android/content/Intent#addCategory(java.lang.String)).\n */\n category?: string;\n /**\n * A map specifying additional key-value pairs which are passed with the intent as `extras`.\n * The keys must include a package prefix, for example the app `com.android.contacts` would use\n * names like `com.android.contacts.ShowAll`.\n */\n extra?: Record<string, any>;\n /**\n * A URI specifying the data that the intent should operate upon. (_Note:_ Android requires the URI\n * scheme to be lowercase, unlike the formal RFC.)\n */\n data?: string;\n /**\n * Bitmask of flags to be used. See [`Intent.setFlags`](https://developer.android.com/reference/android/content/Intent#setFlags(int)) for more details.\n */\n flags?: number;\n /**\n * Package name used as an identifier of ComponentName. Set this only if you want to explicitly\n * set the component to handle the intent.\n */\n packageName?: string;\n /**\n * Class name of the ComponentName.\n */\n className?: string;\n}\n\n// @needsAudit\nexport interface IntentLauncherResult {\n /**\n * Result code returned by the activity.\n */\n resultCode: ResultCode;\n /**\n * Optional data URI that can be returned by the activity.\n */\n data?: string;\n /**\n * Optional extras object that can be returned by the activity.\n */\n extra?: object;\n}\n\n// @needsAudit\nexport enum ResultCode {\n /**\n * Indicates that the activity operation succeeded.\n */\n Success = -1,\n /**\n * Means that the activity was canceled, for example, by tapping on the back button.\n */\n Canceled = 0,\n /**\n * First custom, user-defined value that can be returned by the activity.\n */\n FirstUser = 1,\n}\n\n// @needsAudit\n/**\n * Starts the specified activity. The method will return a promise which resolves when the user\n * returns to the app.\n * @param activityAction The action to be performed, for example, `IntentLauncher.ActivityAction.WIRELESS_SETTINGS`.\n * There are a few pre-defined constants you can use for this parameter.\n * You can find them at [`expo-intent-launcher/src/IntentLauncher.ts`](https://github.com/expo/expo/blob/main/packages/expo-intent-launcher/src/IntentLauncher.ts).\n * @param params An object of intent parameters.\n * @return A promise which fulfils with `IntentLauncherResult` object.\n */\nexport async function startActivityAsync(\n activityAction: ActivityAction | string,\n params: IntentLauncherParams = {}\n): Promise<IntentLauncherResult> {\n if (!ExpoIntentLauncher.startActivity) {\n throw new UnavailabilityError('IntentLauncher', 'startActivityAsync');\n }\n if (!activityAction || typeof activityAction !== 'string') {\n throw new TypeError(`'activityAction' argument must be a non-empty string!`);\n }\n return ExpoIntentLauncher.startActivity(activityAction, params);\n}\n\n/**\n * Opens an application by its package name.\n * @param packageName For example: `com.google.android.gm` for Gmail.\n */\nexport function openApplication(packageName: string): void {\n if (!ExpoIntentLauncher.openApplication) {\n throw new UnavailabilityError('IntentLauncher', 'openApplication');\n }\n return ExpoIntentLauncher.openApplication(packageName);\n}\n\n/**\n * Returns the icon of the specified application as a base64-encoded PNG image string.\n * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image`'s [`Image.source`](./image/#source) prop.\n *\n * @param packageName The package name of the target application. For example, `com.google.android.gm` for Gmail.\n * @return A promise that resolves to the base64-encoded PNG icon of the specified application, or an empty string if the icon could not be retrieved.\n */\nexport async function getApplicationIconAsync(packageName: string): Promise<string> {\n if (!ExpoIntentLauncher.getApplicationIcon) {\n throw new UnavailabilityError('IntentLauncher', 'getApplicationIconAsync');\n }\n return ExpoIntentLauncher.getApplicationIcon(packageName);\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-intent-launcher",
3
- "version": "12.1.0-canary-20250221-ef26fed",
3
+ "version": "12.1.0-canary-20250303-4dba60e",
4
4
  "description": "Provides a way to launch Android intents, e.g. opening a specific activity.",
5
5
  "main": "build/IntentLauncher.js",
6
6
  "types": "build/IntentLauncher.d.ts",
@@ -34,9 +34,10 @@
34
34
  "homepage": "https://docs.expo.dev/versions/latest/sdk/intent-launcher/",
35
35
  "dependencies": {},
36
36
  "devDependencies": {
37
- "expo-module-scripts": "4.0.5-canary-20250221-ef26fed"
37
+ "expo-module-scripts": "4.0.5-canary-20250303-4dba60e"
38
38
  },
39
39
  "peerDependencies": {
40
- "expo": "53.0.0-canary-20250221-ef26fed"
41
- }
40
+ "expo": "53.0.0-canary-20250303-4dba60e"
41
+ },
42
+ "gitHead": "4dba60e10b5d44b453073aa4968e9dbf312dea6c"
42
43
  }
@@ -185,7 +185,7 @@ export async function startActivityAsync(
185
185
  * Opens an application by its package name.
186
186
  * @param packageName For example: `com.google.android.gm` for Gmail.
187
187
  */
188
- export function openApplication(packageName: string) {
188
+ export function openApplication(packageName: string): void {
189
189
  if (!ExpoIntentLauncher.openApplication) {
190
190
  throw new UnavailabilityError('IntentLauncher', 'openApplication');
191
191
  }
@@ -194,8 +194,7 @@ export function openApplication(packageName: string) {
194
194
 
195
195
  /**
196
196
  * Returns the icon of the specified application as a base64-encoded PNG image string.
197
- * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image` `<Image>`
198
- * component's `source` prop.
197
+ * The returned string is prefixed with `data:image/png;base64,` and can be used directly in an `expo-image`'s [`Image.source`](./image/#source) prop.
199
198
  *
200
199
  * @param packageName The package name of the target application. For example, `com.google.android.gm` for Gmail.
201
200
  * @return A promise that resolves to the base64-encoded PNG icon of the specified application, or an empty string if the icon could not be retrieved.