expo-notifications 0.14.1 → 0.15.2

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.
Files changed (198) hide show
  1. package/CHANGELOG.md +31 -1
  2. package/README.md +22 -20
  3. package/android/build.gradle +25 -11
  4. package/android/src/main/java/expo/modules/notifications/notifications/background/BackgroundRemoteNotificationTaskConsumer.java +5 -5
  5. package/android/src/main/java/expo/modules/notifications/notifications/background/ExpoBackgroundNotificationTasksModule.java +1 -1
  6. package/android/src/main/java/expo/modules/notifications/service/NotificationsService.kt +8 -14
  7. package/android/src/main/java/expo/modules/notifications/service/delegates/ExpoSchedulingDelegate.kt +21 -6
  8. package/android/src/main/java/expo/modules/notifications/tokens/PushTokenModule.java +5 -6
  9. package/build/BackgroundNotificationTasksModule.native.d.ts +1 -0
  10. package/build/BackgroundNotificationTasksModule.native.d.ts.map +1 -0
  11. package/build/BackgroundNotificationTasksModule.types.d.ts +1 -0
  12. package/build/BackgroundNotificationTasksModule.types.d.ts.map +1 -0
  13. package/build/BackgroundNotificationTasksModule.web.d.ts +1 -0
  14. package/build/BackgroundNotificationTasksModule.web.d.ts.map +1 -0
  15. package/build/BadgeModule.d.ts +1 -0
  16. package/build/BadgeModule.d.ts.map +1 -0
  17. package/build/BadgeModule.native.d.ts +1 -0
  18. package/build/BadgeModule.native.d.ts.map +1 -0
  19. package/build/BadgeModule.types.d.ts +1 -0
  20. package/build/BadgeModule.types.d.ts.map +1 -0
  21. package/build/BadgeModule.web.d.ts +1 -0
  22. package/build/BadgeModule.web.d.ts.map +1 -0
  23. package/build/DevicePushTokenAutoRegistration.fx.d.ts +1 -0
  24. package/build/DevicePushTokenAutoRegistration.fx.d.ts.map +1 -0
  25. package/build/NotificationCategoriesModule.native.d.ts +1 -0
  26. package/build/NotificationCategoriesModule.native.d.ts.map +1 -0
  27. package/build/NotificationCategoriesModule.types.d.ts +1 -0
  28. package/build/NotificationCategoriesModule.types.d.ts.map +1 -0
  29. package/build/NotificationCategoriesModule.web.d.ts +1 -0
  30. package/build/NotificationCategoriesModule.web.d.ts.map +1 -0
  31. package/build/NotificationChannelGroupManager.d.ts +1 -0
  32. package/build/NotificationChannelGroupManager.d.ts.map +1 -0
  33. package/build/NotificationChannelGroupManager.native.d.ts +1 -0
  34. package/build/NotificationChannelGroupManager.native.d.ts.map +1 -0
  35. package/build/NotificationChannelGroupManager.types.d.ts +1 -0
  36. package/build/NotificationChannelGroupManager.types.d.ts.map +1 -0
  37. package/build/NotificationChannelManager.d.ts +1 -0
  38. package/build/NotificationChannelManager.d.ts.map +1 -0
  39. package/build/NotificationChannelManager.native.d.ts +1 -0
  40. package/build/NotificationChannelManager.native.d.ts.map +1 -0
  41. package/build/NotificationChannelManager.types.d.ts +1 -0
  42. package/build/NotificationChannelManager.types.d.ts.map +1 -0
  43. package/build/NotificationPermissions.d.ts +1 -0
  44. package/build/NotificationPermissions.d.ts.map +1 -0
  45. package/build/NotificationPermissions.types.d.ts +1 -0
  46. package/build/NotificationPermissions.types.d.ts.map +1 -0
  47. package/build/NotificationPermissionsModule.d.ts +1 -0
  48. package/build/NotificationPermissionsModule.d.ts.map +1 -0
  49. package/build/NotificationPermissionsModule.native.d.ts +1 -0
  50. package/build/NotificationPermissionsModule.native.d.ts.map +1 -0
  51. package/build/NotificationPermissionsModule.types.d.ts +1 -0
  52. package/build/NotificationPermissionsModule.types.d.ts.map +1 -0
  53. package/build/NotificationPresenterModule.d.ts +1 -0
  54. package/build/NotificationPresenterModule.d.ts.map +1 -0
  55. package/build/NotificationPresenterModule.native.d.ts +1 -0
  56. package/build/NotificationPresenterModule.native.d.ts.map +1 -0
  57. package/build/NotificationPresenterModule.types.d.ts +1 -0
  58. package/build/NotificationPresenterModule.types.d.ts.map +1 -0
  59. package/build/NotificationScheduler.d.ts +1 -0
  60. package/build/NotificationScheduler.d.ts.map +1 -0
  61. package/build/NotificationScheduler.native.d.ts +1 -0
  62. package/build/NotificationScheduler.native.d.ts.map +1 -0
  63. package/build/NotificationScheduler.types.d.ts +1 -0
  64. package/build/NotificationScheduler.types.d.ts.map +1 -0
  65. package/build/Notifications.types.d.ts +1 -0
  66. package/build/Notifications.types.d.ts.map +1 -0
  67. package/build/NotificationsEmitter.d.ts +1 -0
  68. package/build/NotificationsEmitter.d.ts.map +1 -0
  69. package/build/NotificationsEmitterModule.d.ts +1 -0
  70. package/build/NotificationsEmitterModule.d.ts.map +1 -0
  71. package/build/NotificationsEmitterModule.native.d.ts +1 -0
  72. package/build/NotificationsEmitterModule.native.d.ts.map +1 -0
  73. package/build/NotificationsEmitterModule.types.d.ts +1 -0
  74. package/build/NotificationsEmitterModule.types.d.ts.map +1 -0
  75. package/build/NotificationsHandler.d.ts +1 -0
  76. package/build/NotificationsHandler.d.ts.map +1 -0
  77. package/build/NotificationsHandlerModule.d.ts +1 -0
  78. package/build/NotificationsHandlerModule.d.ts.map +1 -0
  79. package/build/NotificationsHandlerModule.native.d.ts +1 -0
  80. package/build/NotificationsHandlerModule.native.d.ts.map +1 -0
  81. package/build/NotificationsHandlerModule.types.d.ts +1 -0
  82. package/build/NotificationsHandlerModule.types.d.ts.map +1 -0
  83. package/build/PushTokenManager.d.ts +1 -0
  84. package/build/PushTokenManager.d.ts.map +1 -0
  85. package/build/PushTokenManager.native.d.ts +1 -0
  86. package/build/PushTokenManager.native.d.ts.map +1 -0
  87. package/build/PushTokenManager.types.d.ts +1 -0
  88. package/build/PushTokenManager.types.d.ts.map +1 -0
  89. package/build/ServerRegistrationModule.d.ts +1 -0
  90. package/build/ServerRegistrationModule.d.ts.map +1 -0
  91. package/build/ServerRegistrationModule.native.d.ts +1 -0
  92. package/build/ServerRegistrationModule.native.d.ts.map +1 -0
  93. package/build/ServerRegistrationModule.types.d.ts +1 -0
  94. package/build/ServerRegistrationModule.types.d.ts.map +1 -0
  95. package/build/ServerRegistrationModule.web.d.ts +1 -0
  96. package/build/ServerRegistrationModule.web.d.ts.map +1 -0
  97. package/build/ServerRegistrationModule.web.js +1 -1
  98. package/build/ServerRegistrationModule.web.js.map +1 -1
  99. package/build/TokenEmitter.d.ts +1 -0
  100. package/build/TokenEmitter.d.ts.map +1 -0
  101. package/build/Tokens.types.d.ts +1 -0
  102. package/build/Tokens.types.d.ts.map +1 -0
  103. package/build/cancelAllScheduledNotificationsAsync.d.ts +1 -0
  104. package/build/cancelAllScheduledNotificationsAsync.d.ts.map +1 -0
  105. package/build/cancelScheduledNotificationAsync.d.ts +1 -0
  106. package/build/cancelScheduledNotificationAsync.d.ts.map +1 -0
  107. package/build/deleteNotificationCategoryAsync.d.ts +1 -0
  108. package/build/deleteNotificationCategoryAsync.d.ts.map +1 -0
  109. package/build/deleteNotificationChannelAsync.android.d.ts +1 -0
  110. package/build/deleteNotificationChannelAsync.android.d.ts.map +1 -0
  111. package/build/deleteNotificationChannelAsync.d.ts +1 -0
  112. package/build/deleteNotificationChannelAsync.d.ts.map +1 -0
  113. package/build/deleteNotificationChannelGroupAsync.android.d.ts +1 -0
  114. package/build/deleteNotificationChannelGroupAsync.android.d.ts.map +1 -0
  115. package/build/deleteNotificationChannelGroupAsync.d.ts +1 -0
  116. package/build/deleteNotificationChannelGroupAsync.d.ts.map +1 -0
  117. package/build/dismissAllNotificationsAsync.d.ts +1 -0
  118. package/build/dismissAllNotificationsAsync.d.ts.map +1 -0
  119. package/build/dismissNotificationAsync.d.ts +1 -0
  120. package/build/dismissNotificationAsync.d.ts.map +1 -0
  121. package/build/getAllScheduledNotificationsAsync.d.ts +1 -0
  122. package/build/getAllScheduledNotificationsAsync.d.ts.map +1 -0
  123. package/build/getBadgeCountAsync.d.ts +1 -0
  124. package/build/getBadgeCountAsync.d.ts.map +1 -0
  125. package/build/getDevicePushTokenAsync.d.ts +1 -0
  126. package/build/getDevicePushTokenAsync.d.ts.map +1 -0
  127. package/build/getDevicePushTokenAsync.web.d.ts +1 -0
  128. package/build/getDevicePushTokenAsync.web.d.ts.map +1 -0
  129. package/build/getDevicePushTokenAsync.web.js +1 -1
  130. package/build/getDevicePushTokenAsync.web.js.map +1 -1
  131. package/build/getExpoPushTokenAsync.d.ts +1 -0
  132. package/build/getExpoPushTokenAsync.d.ts.map +1 -0
  133. package/build/getExpoPushTokenAsync.js +4 -4
  134. package/build/getExpoPushTokenAsync.js.map +1 -1
  135. package/build/getNextTriggerDateAsync.d.ts +1 -0
  136. package/build/getNextTriggerDateAsync.d.ts.map +1 -0
  137. package/build/getNotificationCategoriesAsync.d.ts +1 -0
  138. package/build/getNotificationCategoriesAsync.d.ts.map +1 -0
  139. package/build/getNotificationChannelAsync.android.d.ts +1 -0
  140. package/build/getNotificationChannelAsync.android.d.ts.map +1 -0
  141. package/build/getNotificationChannelAsync.d.ts +1 -0
  142. package/build/getNotificationChannelAsync.d.ts.map +1 -0
  143. package/build/getNotificationChannelGroupAsync.android.d.ts +1 -0
  144. package/build/getNotificationChannelGroupAsync.android.d.ts.map +1 -0
  145. package/build/getNotificationChannelGroupAsync.d.ts +1 -0
  146. package/build/getNotificationChannelGroupAsync.d.ts.map +1 -0
  147. package/build/getNotificationChannelGroupsAsync.android.d.ts +1 -0
  148. package/build/getNotificationChannelGroupsAsync.android.d.ts.map +1 -0
  149. package/build/getNotificationChannelGroupsAsync.d.ts +1 -0
  150. package/build/getNotificationChannelGroupsAsync.d.ts.map +1 -0
  151. package/build/getNotificationChannelsAsync.android.d.ts +1 -0
  152. package/build/getNotificationChannelsAsync.android.d.ts.map +1 -0
  153. package/build/getNotificationChannelsAsync.d.ts +1 -0
  154. package/build/getNotificationChannelsAsync.d.ts.map +1 -0
  155. package/build/getPresentedNotificationsAsync.d.ts +1 -0
  156. package/build/getPresentedNotificationsAsync.d.ts.map +1 -0
  157. package/build/index.d.ts +1 -0
  158. package/build/index.d.ts.map +1 -0
  159. package/build/presentNotificationAsync.d.ts +1 -0
  160. package/build/presentNotificationAsync.d.ts.map +1 -0
  161. package/build/registerTaskAsync.d.ts +1 -0
  162. package/build/registerTaskAsync.d.ts.map +1 -0
  163. package/build/scheduleNotificationAsync.d.ts +1 -0
  164. package/build/scheduleNotificationAsync.d.ts.map +1 -0
  165. package/build/setBadgeCountAsync.d.ts +1 -0
  166. package/build/setBadgeCountAsync.d.ts.map +1 -0
  167. package/build/setNotificationCategoryAsync.d.ts +1 -0
  168. package/build/setNotificationCategoryAsync.d.ts.map +1 -0
  169. package/build/setNotificationChannelAsync.android.d.ts +1 -0
  170. package/build/setNotificationChannelAsync.android.d.ts.map +1 -0
  171. package/build/setNotificationChannelAsync.d.ts +1 -0
  172. package/build/setNotificationChannelAsync.d.ts.map +1 -0
  173. package/build/setNotificationChannelGroupAsync.android.d.ts +1 -0
  174. package/build/setNotificationChannelGroupAsync.android.d.ts.map +1 -0
  175. package/build/setNotificationChannelGroupAsync.d.ts +1 -0
  176. package/build/setNotificationChannelGroupAsync.d.ts.map +1 -0
  177. package/build/unregisterTaskAsync.d.ts +1 -0
  178. package/build/unregisterTaskAsync.d.ts.map +1 -0
  179. package/build/useLastNotificationResponse.d.ts +1 -0
  180. package/build/useLastNotificationResponse.d.ts.map +1 -0
  181. package/build/utils/updateDevicePushTokenAsync.d.ts +1 -0
  182. package/build/utils/updateDevicePushTokenAsync.d.ts.map +1 -0
  183. package/build/utils/updateDevicePushTokenAsync.js +1 -1
  184. package/build/utils/updateDevicePushTokenAsync.js.map +1 -1
  185. package/ios/EXNotifications/Notifications/Background/EXBackgroundNotificationTasksModule.m +3 -3
  186. package/ios/EXNotifications/Notifications/Background/EXBackgroundRemoteNotificationConsumer.h +3 -3
  187. package/ios/EXNotifications/Notifications/Background/EXBackgroundRemoteNotificationConsumer.m +4 -4
  188. package/ios/EXNotifications.xcframework/ios-arm64/EXNotifications.framework/EXNotifications +0 -0
  189. package/ios/EXNotifications.xcframework/ios-arm64/EXNotifications.framework/Info.plist +0 -0
  190. package/ios/EXNotifications.xcframework/ios-arm64_x86_64-simulator/EXNotifications.framework/EXNotifications +0 -0
  191. package/ios/EXNotifications.xcframework/ios-arm64_x86_64-simulator/EXNotifications.framework/Info.plist +0 -0
  192. package/package.json +7 -8
  193. package/src/ServerRegistrationModule.web.ts +1 -1
  194. package/src/getDevicePushTokenAsync.web.ts +1 -1
  195. package/src/getExpoPushTokenAsync.ts +4 -4
  196. package/src/utils/updateDevicePushTokenAsync.ts +1 -1
  197. package/android/src/main/java/expo/modules/notifications/badge/SetBadgeCountNotificationEffect.java +0 -56
  198. package/android/src/main/java/expo/modules/notifications/notifications/presentation/builders/BadgeSettingNotificationBuilder.java +0 -66
package/CHANGELOG.md CHANGED
@@ -10,7 +10,37 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
- ## 0.14.1 — 2022-02-01
13
+ ## 0.15.2 — 2022-05-05
14
+
15
+ ### 🐛 Bug fixes
16
+
17
+ - Fixed Android 12+ runtime crash caused by `PendingIntent` misconfiguration. ([#17333](https://github.com/expo/expo/pull/17333) by [@kudo](https://github.com/kudo))
18
+
19
+ ### ⚠️ Notices
20
+
21
+ - Fixed exception on Android 12+ devices for missing `SCHEDULE_EXACT_ALARM` permission. If `scheduleNotificationAsync` needs a precise timer, the `SCHEDULE_EXACT_ALARM` should be explicitly added to **AndroidManifest.xml**. ([#17334](https://github.com/expo/expo/pull/17334) by [@kudo](https://github.com/kudo))
22
+
23
+ ## 0.15.1 — 2022-04-27
24
+
25
+ ### 💡 Others
26
+
27
+ - Remove badge deadcode ([#17205](https://github.com/expo/expo/pull/17205) by [@wschurman](https://github.com/wschurman))
28
+
29
+ ## 0.15.0 — 2022-04-18
30
+
31
+ ### 🐛 Bug fixes
32
+
33
+ - Upgrade firebase messaging dependency to v21. This means `expo-notifications` no longer relies on `FirebaseInstanceId`. If you added `com.google.firebase:firebase-iid` to your `android/app/build.gradle` file for this library, it is no longer required and you can safely remove that dependency. ([#15010](https://github.com/expo/expo/pull/15010) by [@cruzach](https://github.com/cruzach))
34
+
35
+ ### 💡 Others
36
+
37
+ - Updated `@expo/config-plugins` from `4.0.2` to `4.0.14` and `@expo/image-utils` from `^0.3.16` to `^0.3.18` ([#15621](https://github.com/expo/expo/pull/15621) by [@EvanBacon](https://github.com/EvanBacon))
38
+
39
+ ### ⚠️ Notices
40
+
41
+ - On Android bump `compileSdkVersion` to `31`, `targetSdkVersion` to `31` and `Java` version to `11`. ([#16941](https://github.com/expo/expo/pull/16941) by [@bbarthec](https://github.com/bbarthec))
42
+
43
+ ## 0.14.1 - 2022-02-01
14
44
 
15
45
  ### 🐛 Bug fixes
16
46
 
package/README.md CHANGED
@@ -18,7 +18,7 @@ Provides an API to fetch push notification tokens and to present, schedule, rece
18
18
 
19
19
  # Installation in managed Expo projects
20
20
 
21
- Please refer to the [installation instructions in the Expo documentation](https://docs.expo.io/versions/latest/sdk/notifications/#installation).
21
+ Please refer to the [installation instructions in the Expo documentation](https://docs.expo.dev/versions/latest/sdk/notifications/#installation).
22
22
 
23
23
  # Installation in bare React Native projects
24
24
 
@@ -43,10 +43,12 @@ In order to be able to receive push notifications on the device:
43
43
 
44
44
  ### Configure for Android
45
45
 
46
- In order to be able to receive push notifications on the device ensure that your project is set up for Firebase. For more information on how to do it, see [this guide](https://docs.expo.io/guides/setup-native-firebase/#bare-workflow-setup).
46
+ In order to be able to receive push notifications on the device ensure that your project is set up for Firebase. For more information on how to do it, see [this guide](https://docs.expo.dev/guides/setup-native-firebase/#bare-workflow-setup).
47
47
 
48
48
  This module requires permission to subscribe to device boot. It's used to setup the scheduled notifications right after the device (re)starts. The `RECEIVE_BOOT_COMPLETED` permission is added automatically.
49
49
 
50
+ **Note:** Starting from Android 12 (API level 31), to schedule the notification that triggers at the exact time, you need to add `<uses-permission android:name="android.permission.SCHEDULE_EXACT_ALARM"/>` to **AndroidManifest.xml**. You can read more about the exact alarm permission [here](https://developer.android.com/about/versions/12/behavior-changes-12#exact-alarm-permission).
51
+
50
52
  <details><summary><strong>Expand to view how the notification icon and the default color can be customized in a plain React Native app</strong></summary> <p>
51
53
 
52
54
  - **To customize the icon**:
@@ -117,7 +119,7 @@ This module requires permission to subscribe to device boot. It's used to setup
117
119
 
118
120
  ### Config plugin setup (optional)
119
121
 
120
- If you're using EAS Build, you can set your Android notification icon and color tint, add custom push notification sounds, and set your iOS notification environment using the expo-notifications config plugin ([what's a config plugin?](http://docs.expo.io/guides/config-plugins/)). To setup, just add the config plugin to the plugins array of your `app.json` or `app.config.js` as shown below, then rebuild the app.
122
+ If you're using EAS Build, you can set your Android notification icon and color tint, add custom push notification sounds, and set your iOS notification environment using the expo-notifications config plugin ([what's a config plugin?](http://docs.expo.dev/guides/config-plugins/)). To setup, just add the config plugin to the plugins array of your `app.json` or `app.config.js` as shown below, then rebuild the app.
121
123
 
122
124
  ```json
123
125
  {
@@ -152,7 +154,7 @@ If you're using EAS Build, you can set your Android notification icon and color
152
154
 
153
155
  If you would like to send notifications with Expo servers, the servers will need to have a way to authenticate with APNS/FCM that they are authorized to send notifications on your behalf. To do this:
154
156
 
155
- - for Firebase Cloud Messaging, check out this guide: _[Uploading Server Credentials](https://docs.expo.io/push-notifications/using-fcm/#uploading-server-credentials)_,
157
+ - for Firebase Cloud Messaging, check out this guide: _[Uploading Server Credentials](https://docs.expo.dev/push-notifications/using-fcm/#uploading-server-credentials)_,
156
158
  - for APNS:
157
159
  - run `expo credentials:manager` in the root of your application,
158
160
  - if you've already uploaded a Push Notifications Key in another project and would like to reuse it in the current project, select _Use existing Push Notifications Key in current project_ (you may need to set `slug` and `ios.bundleIdentifier` fields in `app.json` so that the server knows to which `experienceId` and `bundleIdentifier` the key should be attributed),
@@ -216,7 +218,7 @@ If the device you're experiencing this on hasn't been setup with a SIM card it l
216
218
 
217
219
  ### Setting custom notification sounds
218
220
 
219
- Custom notification sounds are only supported when using [EAS Build](https://docs.expo.io/build/introduction/), or in the bare workflow.
221
+ Custom notification sounds are only supported when using [EAS Build](https://docs.expo.dev/build/introduction/), or in the bare workflow.
220
222
 
221
223
  To add custom push notification sounds to your app, add the `expo-notifications` plugin to your `app.json` file:
222
224
 
@@ -364,7 +366,7 @@ The following methods are exported by the `expo-notifications` module:
364
366
 
365
367
  ## Custom notification icon and colors (Android only)
366
368
 
367
- Setting a default icon and color for all of your app's notifications is almost too easy. In the managed workflow, just set your [`notification.icon`](https://docs.expo.io/versions/latest/config/app/#notification) and [`notification.color`](https://docs.expo.io/versions/latest/config/app/#notification) keys in `app.json`, and rebuild your app! In the bare workflow, you'll need to follow [these instructions](https://github.com/expo/expo/tree/master/packages/expo-notifications#configure-for-android).
369
+ Setting a default icon and color for all of your app's notifications is almost too easy. In the managed workflow, just set your [`notification.icon`](https://docs.expo.dev/versions/latest/config/app/#notification) and [`notification.color`](https://docs.expo.dev/versions/latest/config/app/#notification) keys in `app.json`, and rebuild your app! In the bare workflow, you'll need to follow [these instructions](https://github.com/expo/expo/tree/main/packages/expo-notifications#configure-for-android).
368
370
 
369
371
  For your notification icon, make sure you follow [Google's design guidelines](https://material.io/design/iconography/product-icons.html#design-principles) (the icon must be all white with a transparent background) or else it may not be displayed as intended.
370
372
 
@@ -390,9 +392,9 @@ export interface FirebaseData {
390
392
 
391
393
  ### `getExpoPushTokenAsync(options: ExpoTokenOptions): ExpoPushToken`
392
394
 
393
- Returns an Expo token that can be used to send a push notification to this device using Expo push notifications service. [Read more in the Push Notifications guide](https://docs.expo.io/guides/push-notifications/).
395
+ Returns an Expo token that can be used to send a push notification to this device using Expo push notifications service. [Read more in the Push Notifications guide](https://docs.expo.dev/guides/push-notifications/).
394
396
 
395
- > **Note:** For Expo's backend to be able to send notifications to your app, you will need to provide it with push notification keys. This can be done using `expo-cli` (`expo credentials:manager`). [Read more in the “Upload notifications credentials” guide](https://docs.expo.io/push-notifications/push-notifications-setup/#credentials).
397
+ > **Note:** For Expo's backend to be able to send notifications to your app, you will need to provide it with push notification keys. This can be done using `expo-cli` (`expo credentials:manager`). [Read more in the “Upload notifications credentials” guide](https://docs.expo.dev/push-notifications/push-notifications-setup/#credentials).
396
398
 
397
399
  > **Note:** Especially on iOS, `Promise`s returned by this method may take longer periods of time to fulfill. For more information see [Fetching a push token takes a long time on iOS](#fetching-a-push-token-takes-a-long-time-on-ios).
398
400
 
@@ -400,10 +402,10 @@ Returns an Expo token that can be used to send a push notification to this devic
400
402
 
401
403
  This function accepts an optional object allowing you to pass in configuration, consisting of fields (all are optional, but some may have to be defined if configuration cannot be inferred):
402
404
 
403
- - **experienceId (_string_)** -- The ID of the experience to which the token should be attributed. Defaults to [`Constants.manifest.id`](https://docs.expo.io/versions/latest/sdk/constants/#constantsmanifest) exposed by `expo-constants`. In the bare workflow, you must provide a value which takes the shape `@username/projectSlug`, where `username` is the Expo account that the project is associated with, and `projectSlug` is your [`slug` from `app.json`](https://docs.expo.io/versions/latest/config/app/#slug).
405
+ - **experienceId (_string_)** -- The ID of the experience to which the token should be attributed. Defaults to [`Constants.manifest.id`](https://docs.expo.dev/versions/latest/sdk/constants/#constantsmanifest) exposed by `expo-constants`. In the bare workflow, you must provide a value which takes the shape `@username/projectSlug`, where `username` is the Expo account that the project is associated with, and `projectSlug` is your [`slug` from `app.json`](https://docs.expo.dev/versions/latest/config/app/#slug).
404
406
  - **devicePushToken ([_DevicePushToken_](#devicepushtoken))** -- The device push token with which to register at the backend. Defaults to a token fetched with [`getDevicePushTokenAsync()`](#getdevicepushtokenasync-devicepushtoken).
405
- - **applicationId (_string_)** -- The ID of the application to which the token should be attributed. Defaults to [`Application.applicationId`](https://docs.expo.io/versions/latest/sdk/application/#applicationapplicationid) exposed by `expo-application`.
406
- - **development (_boolean_)** -- Makes sense only on iOS, where there are two push notification services: sandbox and production. This defines whether the push token is supposed to be used with the sandbox platform notification service. Defaults to [`Application.getIosPushNotificationServiceEnvironmentAsync()`](https://docs.expo.io/versions/latest/sdk/application/#applicationgetiospushnotificationserviceenvironmentasync) exposed by `expo-application` or `false`. Most probably you won't need to customize that. You may want to customize that if you don't want to install `expo-application` and still use the sandbox APNS.
407
+ - **applicationId (_string_)** -- The ID of the application to which the token should be attributed. Defaults to [`Application.applicationId`](https://docs.expo.dev/versions/latest/sdk/application/#applicationapplicationid) exposed by `expo-application`.
408
+ - **development (_boolean_)** -- Makes sense only on iOS, where there are two push notification services: sandbox and production. This defines whether the push token is supposed to be used with the sandbox platform notification service. Defaults to [`Application.getIosPushNotificationServiceEnvironmentAsync()`](https://docs.expo.dev/versions/latest/sdk/application/#applicationgetiospushnotificationserviceenvironmentasync) exposed by `expo-application` or `false`. Most probably you won't need to customize that. You may want to customize that if you don't want to install `expo-application` and still use the sandbox APNS.
407
409
 
408
410
  #### Returns
409
411
 
@@ -744,7 +746,7 @@ Notifications.setNotificationHandler({
744
746
 
745
747
  ### `registerTaskAsync(taskName: string): void`
746
748
 
747
- When a notification is received while the app is backgrounded, using this function you can set a callback that will be run in response to that notification. Under the hood, this function is run using `expo-task-manager`. You **must** define the task _first_, with [`TaskManager.defineTask`](https://docs.expo.io/versions/latest/sdk/task-manager/#taskmanagerdefinetasktaskname-task). Make sure you define it in the global scope.
749
+ When a notification is received while the app is backgrounded, using this function you can set a callback that will be run in response to that notification. Under the hood, this function is run using `expo-task-manager`. You **must** define the task _first_, with [`TaskManager.defineTask`](https://docs.expo.dev/versions/latest/sdk/task-manager/#taskmanagerdefinetasktaskname-task). Make sure you define it in the global scope.
748
750
 
749
751
  The `taskName` argument is the string you passed to `TaskManager.defineTask` as the "taskName". The callback function you define with `TaskManager.defineTask` will receive the following arguments:
750
752
 
@@ -754,18 +756,18 @@ The `taskName` argument is the string you passed to `TaskManager.defineTask` as
754
756
 
755
757
  #### Examples
756
758
 
757
- Implementing a notification handler that always shows the notification when it is received
758
-
759
759
  ```ts
760
+ import * as TaskManager from 'expo-task-manager';
760
761
  import * as Notifications from 'expo-notifications';
761
762
 
762
- Notifications.setNotificationHandler({
763
- handleNotification: async () => ({
764
- shouldShowAlert: true,
765
- shouldPlaySound: false,
766
- shouldSetBadge: false,
767
- }),
763
+ const BACKGROUND_NOTIFICATION_TASK = 'BACKGROUND-NOTIFICATION-TASK';
764
+
765
+ TaskManager.defineTask(BACKGROUND_NOTIFICATION_TASK, ({ data, error, executionInfo }) => {
766
+ console.log('Received a notification in the background!');
767
+ // Do something with the notification data
768
768
  });
769
+
770
+ Notifications.registerTaskAsync(BACKGROUND_NOTIFICATION_TASK);
769
771
  ```
770
772
 
771
773
  ### `unregisterTaskAsync(taskName: string): void`
@@ -3,20 +3,35 @@ apply plugin: 'kotlin-android'
3
3
  apply plugin: 'maven-publish'
4
4
 
5
5
  group = 'host.exp.exponent'
6
- version = '0.14.1'
6
+ version = '0.15.2'
7
7
 
8
8
  buildscript {
9
+ def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
10
+ if (expoModulesCorePlugin.exists()) {
11
+ apply from: expoModulesCorePlugin
12
+ applyKotlinExpoModulesCorePlugin()
13
+ }
14
+
9
15
  // Simple helper that allows the root project to override versions declared by this library.
10
16
  ext.safeExtGet = { prop, fallback ->
11
17
  rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
12
18
  }
13
19
 
20
+ // Ensures backward compatibility
21
+ ext.getKotlinVersion = {
22
+ if (ext.has("kotlinVersion")) {
23
+ ext.kotlinVersion()
24
+ } else {
25
+ ext.safeExtGet("kotlinVersion", "1.6.10")
26
+ }
27
+ }
28
+
14
29
  repositories {
15
30
  mavenCentral()
16
31
  }
17
32
 
18
33
  dependencies {
19
- classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${safeExtGet('kotlinVersion', '1.4.21')}")
34
+ classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${getKotlinVersion()}")
20
35
  }
21
36
  }
22
37
 
@@ -44,22 +59,22 @@ afterEvaluate {
44
59
  }
45
60
 
46
61
  android {
47
- compileSdkVersion safeExtGet("compileSdkVersion", 30)
62
+ compileSdkVersion safeExtGet("compileSdkVersion", 31)
48
63
 
49
64
  compileOptions {
50
- sourceCompatibility JavaVersion.VERSION_1_8
51
- targetCompatibility JavaVersion.VERSION_1_8
65
+ sourceCompatibility JavaVersion.VERSION_11
66
+ targetCompatibility JavaVersion.VERSION_11
52
67
  }
53
68
 
54
69
  kotlinOptions {
55
- jvmTarget = JavaVersion.VERSION_1_8
70
+ jvmTarget = JavaVersion.VERSION_11.majorVersion
56
71
  }
57
72
 
58
73
  defaultConfig {
59
74
  minSdkVersion safeExtGet("minSdkVersion", 21)
60
- targetSdkVersion safeExtGet("targetSdkVersion", 30)
75
+ targetSdkVersion safeExtGet("targetSdkVersion", 31)
61
76
  versionCode 21
62
- versionName '0.14.1'
77
+ versionName '0.15.2'
63
78
  }
64
79
 
65
80
  lintOptions {
@@ -69,16 +84,15 @@ android {
69
84
 
70
85
  dependencies {
71
86
  implementation project(':expo-modules-core')
72
- implementation project(':unimodules-task-manager-interface')
73
87
 
74
88
  api 'androidx.core:core:1.5.0'
75
89
  api 'androidx.lifecycle:lifecycle-runtime:2.2.0'
76
90
  api 'androidx.lifecycle:lifecycle-process:2.2.0'
77
91
  api 'androidx.lifecycle:lifecycle-common-java8:2.2.0'
78
92
 
79
- implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${safeExtGet('kotlinVersion', '1.4.21')}"
93
+ implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${getKotlinVersion()}"
80
94
 
81
- api 'com.google.firebase:firebase-messaging:20.2.4'
95
+ api 'com.google.firebase:firebase-messaging:21.1.0'
82
96
 
83
97
  api 'me.leolin:ShortcutBadger:1.1.22@aar'
84
98
  }
@@ -12,11 +12,6 @@ import androidx.lifecycle.ProcessLifecycleOwner;
12
12
 
13
13
  import org.json.JSONException;
14
14
  import org.json.JSONObject;
15
- import org.unimodules.interfaces.taskManager.TaskConsumer;
16
- import org.unimodules.interfaces.taskManager.TaskConsumerInterface;
17
- import org.unimodules.interfaces.taskManager.TaskExecutionCallback;
18
- import org.unimodules.interfaces.taskManager.TaskInterface;
19
- import org.unimodules.interfaces.taskManager.TaskManagerUtilsInterface;
20
15
 
21
16
  import java.util.Collections;
22
17
  import java.util.List;
@@ -24,6 +19,11 @@ import java.util.Map;
24
19
 
25
20
  import expo.modules.notifications.notifications.NotificationSerializer;
26
21
  import expo.modules.notifications.service.delegates.FirebaseMessagingDelegate;
22
+ import expo.modules.interfaces.taskManager.TaskConsumer;
23
+ import expo.modules.interfaces.taskManager.TaskConsumerInterface;
24
+ import expo.modules.interfaces.taskManager.TaskExecutionCallback;
25
+ import expo.modules.interfaces.taskManager.TaskInterface;
26
+ import expo.modules.interfaces.taskManager.TaskManagerUtilsInterface;
27
27
 
28
28
  /**
29
29
  * Represents a task to be run when the app is backgrounded and receives a remote push
@@ -6,7 +6,7 @@ import expo.modules.core.ExportedModule;
6
6
  import expo.modules.core.ModuleRegistry;
7
7
  import expo.modules.core.Promise;
8
8
  import expo.modules.core.interfaces.ExpoMethod;
9
- import org.unimodules.interfaces.taskManager.TaskManagerInterface;
9
+ import expo.modules.interfaces.taskManager.TaskManagerInterface;
10
10
 
11
11
  import java.util.Collections;
12
12
 
@@ -7,20 +7,10 @@ import android.content.Context
7
7
  import android.content.Intent
8
8
  import android.content.pm.ActivityInfo
9
9
  import android.net.Uri
10
- import android.os.Bundle
11
- import android.os.Parcel
12
- import android.os.Parcelable
13
- import android.os.ResultReceiver
10
+ import android.os.*
14
11
  import android.util.Log
15
12
  import androidx.core.app.RemoteInput
16
- import expo.modules.notifications.notifications.model.Notification
17
- import expo.modules.notifications.notifications.model.NotificationAction
18
- import expo.modules.notifications.notifications.model.NotificationBehavior
19
- import expo.modules.notifications.notifications.model.NotificationCategory
20
- import expo.modules.notifications.notifications.model.NotificationRequest
21
- import expo.modules.notifications.notifications.model.NotificationResponse
22
- import expo.modules.notifications.notifications.model.TextInputNotificationAction
23
- import expo.modules.notifications.notifications.model.TextInputNotificationResponse
13
+ import expo.modules.notifications.notifications.model.*
24
14
  import expo.modules.notifications.service.delegates.ExpoCategoriesDelegate
25
15
  import expo.modules.notifications.service.delegates.ExpoHandlingDelegate
26
16
  import expo.modules.notifications.service.delegates.ExpoPresentationDelegate
@@ -424,11 +414,13 @@ open class NotificationsService : BroadcastReceiver() {
424
414
  intent.putExtra(IDENTIFIER_KEY, identifier)
425
415
  }
426
416
 
417
+ // We're defaulting to the behaviour prior API 31 (mutable) even though Android recommends immutability
418
+ val mutableFlag = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) PendingIntent.FLAG_MUTABLE else 0
427
419
  return PendingIntent.getBroadcast(
428
420
  context,
429
421
  intent.component?.className?.hashCode() ?: NotificationsService::class.java.hashCode(),
430
422
  intent,
431
- PendingIntent.FLAG_UPDATE_CURRENT
423
+ PendingIntent.FLAG_UPDATE_CURRENT or mutableFlag
432
424
  )
433
425
  }
434
426
 
@@ -458,11 +450,13 @@ open class NotificationsService : BroadcastReceiver() {
458
450
  intent.putExtra(NOTIFICATION_ACTION_KEY, action as Parcelable)
459
451
  }
460
452
 
453
+ // We're defaulting to the behaviour prior API 31 (mutable) even though Android recommends immutability
454
+ val mutableFlag = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) PendingIntent.FLAG_MUTABLE else 0
461
455
  return PendingIntent.getBroadcast(
462
456
  context,
463
457
  intent.component?.className?.hashCode() ?: NotificationsService::class.java.hashCode(),
464
458
  intent,
465
- PendingIntent.FLAG_UPDATE_CURRENT
459
+ PendingIntent.FLAG_UPDATE_CURRENT or mutableFlag
466
460
  )
467
461
  }
468
462
 
@@ -1,7 +1,9 @@
1
1
  package expo.modules.notifications.service.delegates
2
2
 
3
3
  import android.app.AlarmManager
4
+ import android.app.PendingIntent
4
5
  import android.content.Context
6
+ import android.os.Build
5
7
  import android.util.Log
6
8
  import androidx.core.app.AlarmManagerCompat
7
9
  import expo.modules.notifications.notifications.interfaces.SchedulableNotificationTrigger
@@ -57,12 +59,7 @@ class ExpoSchedulingDelegate(protected val context: Context) : SchedulingDelegat
57
59
  NotificationsService.removeScheduledNotification(context, request.identifier)
58
60
  } else {
59
61
  store.saveNotificationRequest(request)
60
- AlarmManagerCompat.setExactAndAllowWhileIdle(
61
- alarmManager,
62
- AlarmManager.RTC_WAKEUP,
63
- nextTriggerDate.time,
64
- NotificationsService.createNotificationTrigger(context, request.identifier)
65
- )
62
+ setupAlarm(nextTriggerDate.time, NotificationsService.createNotificationTrigger(context, request.identifier))
66
63
  }
67
64
  }
68
65
  }
@@ -99,4 +96,22 @@ class ExpoSchedulingDelegate(protected val context: Context) : SchedulingDelegat
99
96
  alarmManager.cancel(NotificationsService.createNotificationTrigger(context, it))
100
97
  }
101
98
  }
99
+
100
+ private fun setupAlarm(triggerAtMillis: Long, operation: PendingIntent) {
101
+ if (Build.VERSION.SDK_INT < Build.VERSION_CODES.S || alarmManager.canScheduleExactAlarms()) {
102
+ AlarmManagerCompat.setExactAndAllowWhileIdle(
103
+ alarmManager,
104
+ AlarmManager.RTC_WAKEUP,
105
+ triggerAtMillis,
106
+ operation
107
+ )
108
+ } else {
109
+ AlarmManagerCompat.setAndAllowWhileIdle(
110
+ alarmManager,
111
+ AlarmManager.RTC_WAKEUP,
112
+ triggerAtMillis,
113
+ operation
114
+ )
115
+ }
116
+ }
102
117
  }
@@ -5,8 +5,7 @@ import android.os.Bundle;
5
5
 
6
6
  import com.google.android.gms.tasks.OnCompleteListener;
7
7
  import com.google.android.gms.tasks.Task;
8
- import com.google.firebase.iid.FirebaseInstanceId;
9
- import com.google.firebase.iid.InstanceIdResult;
8
+ import com.google.firebase.messaging.FirebaseMessaging;
10
9
 
11
10
  import expo.modules.core.ExportedModule;
12
11
  import expo.modules.core.ModuleRegistry;
@@ -61,10 +60,10 @@ public class PushTokenModule extends ExportedModule implements PushTokenListener
61
60
  */
62
61
  @ExpoMethod
63
62
  public void getDevicePushTokenAsync(final Promise promise) {
64
- FirebaseInstanceId.getInstance().getInstanceId()
65
- .addOnCompleteListener(new OnCompleteListener<InstanceIdResult>() {
63
+ FirebaseMessaging.getInstance().getToken()
64
+ .addOnCompleteListener(new OnCompleteListener<String>() {
66
65
  @Override
67
- public void onComplete(@NonNull Task<InstanceIdResult> task) {
66
+ public void onComplete(@NonNull Task<String> task) {
68
67
  if (!task.isSuccessful() || task.getResult() == null) {
69
68
  if (task.getException() == null) {
70
69
  promise.reject(REGISTRATION_FAIL_CODE, "Fetching the token failed.");
@@ -74,7 +73,7 @@ public class PushTokenModule extends ExportedModule implements PushTokenListener
74
73
  return;
75
74
  }
76
75
 
77
- String token = task.getResult().getToken();
76
+ String token = task.getResult();
78
77
 
79
78
  promise.resolve(token);
80
79
  onNewToken(token);
@@ -1,3 +1,4 @@
1
1
  import { BackgroundNotificationTasksModule } from './BackgroundNotificationTasksModule.types';
2
2
  declare const _default: BackgroundNotificationTasksModule;
3
3
  export default _default;
4
+ //# sourceMappingURL=BackgroundNotificationTasksModule.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackgroundNotificationTasksModule.native.d.ts","sourceRoot":"","sources":["../src/BackgroundNotificationTasksModule.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,iCAAiC,EAAE,MAAM,2CAA2C,CAAC;;AAE9F,wBAA6G"}
@@ -8,3 +8,4 @@ export declare enum BackgroundNotificationResult {
8
8
  NewData = 2,
9
9
  Failed = 3
10
10
  }
11
+ //# sourceMappingURL=BackgroundNotificationTasksModule.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackgroundNotificationTasksModule.types.d.ts","sourceRoot":"","sources":["../src/BackgroundNotificationTasksModule.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEtD,MAAM,WAAW,iCAAkC,SAAQ,iBAAiB;IAC1E,iBAAiB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACvD,mBAAmB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC1D;AAED,oBAAY,4BAA4B;IACtC,MAAM,IAAI;IACV,OAAO,IAAI;IACX,MAAM,IAAI;CACX"}
@@ -3,3 +3,4 @@ declare const _default: {
3
3
  unregisterTaskAsync(taskName: string): Promise<null>;
4
4
  };
5
5
  export default _default;
6
+ //# sourceMappingURL=BackgroundNotificationTasksModule.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackgroundNotificationTasksModule.web.d.ts","sourceRoot":"","sources":["../src/BackgroundNotificationTasksModule.web.ts"],"names":[],"mappings":";gCACoC,MAAM,GAAG,QAAQ,IAAI,CAAC;kCAGpB,MAAM,GAAG,QAAQ,IAAI,CAAC;;AAJ5D,wBAOE"}
@@ -1,3 +1,4 @@
1
1
  import { BadgeModule } from './BadgeModule.types';
2
2
  declare const _default: BadgeModule;
3
3
  export default _default;
4
+ //# sourceMappingURL=BadgeModule.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeModule.d.ts","sourceRoot":"","sources":["../src/BadgeModule.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;;AAElD,wBAGiB"}
@@ -1,3 +1,4 @@
1
1
  import { BadgeModule } from './BadgeModule.types';
2
2
  declare const _default: BadgeModule;
3
3
  export default _default;
4
+ //# sourceMappingURL=BadgeModule.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeModule.native.d.ts","sourceRoot":"","sources":["../src/BadgeModule.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;;AAElD,wBAQiB"}
@@ -7,3 +7,4 @@ export interface BadgeModule extends ProxyNativeModule {
7
7
  setBadgeCountAsync?: (badgeCount: number, options: SetBadgeCountOptions) => Promise<boolean>;
8
8
  }
9
9
  export {};
10
+ //# sourceMappingURL=BadgeModule.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeModule.types.d.ts","sourceRoot":"","sources":["../src/BadgeModule.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEtD,oBAAY,uBAAuB,GAAG,aAAa,CAAC;AACpD,aAAK,oBAAoB,GAAG,uBAAuB,GAAG,SAAS,CAAC;AAEhE,MAAM,WAAW,WAAY,SAAQ,iBAAiB;IACpD,kBAAkB,CAAC,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAC;IAC3C,kBAAkB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,oBAAoB,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;CAC9F"}
@@ -1,3 +1,4 @@
1
1
  import { BadgeModule } from './BadgeModule.types';
2
2
  declare const badgeModule: BadgeModule;
3
3
  export default badgeModule;
4
+ //# sourceMappingURL=BadgeModule.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeModule.web.d.ts","sourceRoot":"","sources":["../src/BadgeModule.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAIlD,QAAA,MAAM,WAAW,EAAE,WAqBlB,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -15,3 +15,4 @@ export declare function setAutoServerRegistrationEnabledAsync(enabled: boolean):
15
15
  * This function is exported only for testing purposes.
16
16
  */
17
17
  export declare function __handlePersistedRegistrationInfoAsync(registrationInfo: string | null | undefined): Promise<void>;
18
+ //# sourceMappingURL=DevicePushTokenAutoRegistration.fx.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DevicePushTokenAutoRegistration.fx.d.ts","sourceRoot":"","sources":["../src/DevicePushTokenAutoRegistration.fx.ts"],"names":[],"mappings":"AAAA,OAAO,2BAA2B,CAAC;AAiBnC;;GAEG;AACH,oBAAY,2BAA2B,GAAG;IACxC,SAAS,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF;;;;GAIG;AACH,wBAAsB,qCAAqC,CAAC,OAAO,EAAE,OAAO,iBAY3E;AAED;;GAEG;AACH,wBAAsB,sCAAsC,CAC1D,gBAAgB,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,iBAiC5C"}
@@ -1,3 +1,4 @@
1
1
  import { NotificationCategoriesModule } from './NotificationCategoriesModule.types';
2
2
  declare const _default: NotificationCategoriesModule;
3
3
  export default _default;
4
+ //# sourceMappingURL=NotificationCategoriesModule.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationCategoriesModule.native.d.ts","sourceRoot":"","sources":["../src/NotificationCategoriesModule.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,4BAA4B,EAAE,MAAM,sCAAsC,CAAC;;AAEpF,wBAAmG"}
@@ -14,3 +14,4 @@ export interface NotificationCategoriesModule extends ProxyNativeModule {
14
14
  }) => Promise<NotificationCategory>;
15
15
  deleteNotificationCategoryAsync: (identifier: string) => Promise<boolean>;
16
16
  }
17
+ //# sourceMappingURL=NotificationCategoriesModule.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationCategoriesModule.types.d.ts","sourceRoot":"","sources":["../src/NotificationCategoriesModule.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEtD,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAEjF,MAAM,WAAW,4BAA6B,SAAQ,iBAAiB;IACrE,8BAA8B,EAAE,MAAM,OAAO,CAAC,oBAAoB,EAAE,CAAC,CAAC;IACtE,4BAA4B,EAAE,CAC5B,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,kBAAkB,EAAE,EAC7B,OAAO,CAAC,EAAE;QACR,kBAAkB,CAAC,EAAE,MAAM,CAAC;QAC5B,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;QAC7B,qBAAqB,CAAC,EAAE,MAAM,CAAC;QAC/B,mBAAmB,CAAC,EAAE,OAAO,CAAC;QAC9B,cAAc,CAAC,EAAE,OAAO,CAAC;QACzB,SAAS,CAAC,EAAE,OAAO,CAAC;QACpB,YAAY,CAAC,EAAE,OAAO,CAAC;QACvB,iBAAiB,CAAC,EAAE,OAAO,CAAC;KAC7B,KACE,OAAO,CAAC,oBAAoB,CAAC,CAAC;IACnC,+BAA+B,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;CAC3E"}
@@ -5,3 +5,4 @@ declare const _default: {
5
5
  deleteNotificationCategoryAsync(identifier: string): Promise<null>;
6
6
  };
7
7
  export default _default;
8
+ //# sourceMappingURL=NotificationCategoriesModule.web.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationCategoriesModule.web.d.ts","sourceRoot":"","sources":["../src/NotificationCategoriesModule.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;;sCAGjB,QAAQ,IAAI,CAAC;6CAIvC,MAAM,WACT,kBAAkB,EAAE,iCAE5B,QAAQ,IAAI,CAAC;gDAGkC,MAAM,GAAG,QAAQ,IAAI,CAAC;;AAX1E,wBAcE"}
@@ -1,3 +1,4 @@
1
1
  import { NotificationChannelGroupManager } from './NotificationChannelGroupManager.types';
2
2
  declare const _default: NotificationChannelGroupManager;
3
3
  export default _default;
4
+ //# sourceMappingURL=NotificationChannelGroupManager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelGroupManager.d.ts","sourceRoot":"","sources":["../src/NotificationChannelGroupManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,+BAA+B,EAAE,MAAM,yCAAyC,CAAC;;AAE1F,wBAGqC"}
@@ -1,3 +1,4 @@
1
1
  import { NotificationChannelGroupManager } from './NotificationChannelGroupManager.types';
2
2
  declare const _default: NotificationChannelGroupManager;
3
3
  export default _default;
4
+ //# sourceMappingURL=NotificationChannelGroupManager.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelGroupManager.native.d.ts","sourceRoot":"","sources":["../src/NotificationChannelGroupManager.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,+BAA+B,EAAE,MAAM,yCAAyC,CAAC;;AAE1F,wBAAgH"}
@@ -17,3 +17,4 @@ export interface NotificationChannelGroupManager extends ProxyNativeModule {
17
17
  setNotificationChannelGroupAsync?: (groupId: string, group: NotificationChannelGroupInput) => Promise<NotificationChannelGroup | null>;
18
18
  deleteNotificationChannelGroupAsync?: (groupId: string) => Promise<void>;
19
19
  }
20
+ //# sourceMappingURL=NotificationChannelGroupManager.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelGroupManager.types.d.ts","sourceRoot":"","sources":["../src/NotificationChannelGroupManager.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,oCAAoC,CAAC;AAEzE,MAAM,WAAW,wBAAwB;IACvC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,mBAAmB,EAAE,CAAC;CACjC;AAED,MAAM,WAAW,6BAA6B;IAC5C,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B;AAED,MAAM,WAAW,+BAAgC,SAAQ,iBAAiB;IACxE,iCAAiC,CAAC,EAAE,MAAM,OAAO,CAAC,wBAAwB,EAAE,CAAC,CAAC;IAC9E,gCAAgC,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,OAAO,CAAC,wBAAwB,GAAG,IAAI,CAAC,CAAC;IACjG,gCAAgC,CAAC,EAAE,CACjC,OAAO,EAAE,MAAM,EACf,KAAK,EAAE,6BAA6B,KACjC,OAAO,CAAC,wBAAwB,GAAG,IAAI,CAAC,CAAC;IAC9C,mCAAmC,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC1E"}
@@ -1,3 +1,4 @@
1
1
  import { NotificationChannelManager } from './NotificationChannelManager.types';
2
2
  declare const _default: NotificationChannelManager;
3
3
  export default _default;
4
+ //# sourceMappingURL=NotificationChannelManager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelManager.d.ts","sourceRoot":"","sources":["../src/NotificationChannelManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;;AAEhF,wBAGgC"}
@@ -1,3 +1,4 @@
1
1
  import { NotificationChannelManager } from './NotificationChannelManager.types';
2
2
  declare const _default: NotificationChannelManager;
3
3
  export default _default;
4
+ //# sourceMappingURL=NotificationChannelManager.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelManager.native.d.ts","sourceRoot":"","sources":["../src/NotificationChannelManager.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;;AAEhF,wBAAsG"}
@@ -78,3 +78,4 @@ export interface NotificationChannelManager extends ProxyNativeModule {
78
78
  deleteNotificationChannelAsync?: (channelId: string) => Promise<void>;
79
79
  }
80
80
  export {};
81
+ //# sourceMappingURL=NotificationChannelManager.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationChannelManager.types.d.ts","sourceRoot":"","sources":["../src/NotificationChannelManager.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEtD,oBAAY,6BAA6B;IACvC,OAAO,IAAI;IACX,MAAM,IAAI;IACV,OAAO,IAAI;IACX,MAAM,IAAI;CACX;AAED,oBAAY,uBAAuB;IACjC,OAAO,IAAI;IACX,MAAM,IAAI;IACV,KAAK,IAAI;IACT,KAAK,IAAI;IACT,YAAY,IAAI;CACjB;AAED,oBAAY,iBAAiB;IAC3B,OAAO,IAAI;IACX,WAAW,IAAI;IACf,IAAI,IAAI;IACR,GAAG,IAAI;IACP,GAAG,IAAI;IACP,OAAO,IAAI;IACX,wCAAwC;IACxC,QAAQ,IAAI;IACZ,IAAI,IAAI;IACR,GAAG,IAAI;CACR;AAED,oBAAY,iBAAiB;IAC3B,OAAO,IAAI;IACX,KAAK,IAAI;IACT,mBAAmB,IAAI;IACvB,8BAA8B,IAAI;IAClC,KAAK,IAAI;IACT,YAAY,IAAI;IAChB,qBAAqB,IAAI;IACzB,kCAAkC,IAAI;IACtC,kCAAkC,IAAI;IACtC,kCAAkC,IAAI;IACtC,kBAAkB,KAAK;IACvB,wBAAwB,KAAK;IAC7B,8BAA8B,KAAK;IACnC,uBAAuB,KAAK;IAC5B,IAAI,KAAK;CACV;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,iBAAiB,CAAC;IACzB,WAAW,EAAE,uBAAuB,CAAC;IACrC,KAAK,EAAE;QACL,iBAAiB,EAAE,OAAO,CAAC;QAC3B,wCAAwC,EAAE,OAAO,CAAC;KACnD,CAAC;CACH;AAKD,oBAAY,oBAAoB,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AAE5D,MAAM,WAAW,mBAAmB;IAClC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,UAAU,EAAE,iBAAiB,CAAC;IAC9B,SAAS,EAAE,OAAO,CAAC;IACnB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,oBAAoB,EAAE,6BAA6B,CAAC;IACpD,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,SAAS,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnC,eAAe,EAAE,eAAe,CAAC;IACjC,gBAAgB,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAClC,YAAY,EAAE,OAAO,CAAC;IACtB,aAAa,EAAE,OAAO,CAAC;CACxB;AAED,aAAK,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAEnF,oBAAY,wBAAwB,GAAG,UAAU,CAC/C,IAAI,CACF,mBAAmB,EACjB,IAAI,GACJ,iBAAiB,GACjB,OAAO,CACV,GAAG;IAAE,eAAe,CAAC,EAAE,oBAAoB,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,EACrE,MAAM,GAAG,YAAY,CACtB,CAAC;AAEF,MAAM,WAAW,0BAA2B,SAAQ,iBAAiB;IACnE,4BAA4B,CAAC,EAAE,MAAM,OAAO,CAAC,mBAAmB,EAAE,GAAG,IAAI,CAAC,CAAC;IAC3E,2BAA2B,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,OAAO,CAAC,mBAAmB,GAAG,IAAI,CAAC,CAAC;IACzF,2BAA2B,CAAC,EAAE,CAC5B,SAAS,EAAE,MAAM,EACjB,oBAAoB,EAAE,wBAAwB,KAC3C,OAAO,CAAC,mBAAmB,GAAG,IAAI,CAAC,CAAC;IACzC,8BAA8B,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACvE"}
@@ -11,3 +11,4 @@ export declare function requestPermissionsAsync(permissions?: NotificationPermis
11
11
  * ```
12
12
  */
13
13
  export declare const usePermissions: (options?: import("expo-modules-core").PermissionHookOptions<NotificationPermissionsRequest> | undefined) => [NotificationPermissionsStatus | null, () => Promise<NotificationPermissionsStatus>, () => Promise<NotificationPermissionsStatus>];
14
+ //# sourceMappingURL=NotificationPermissions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationPermissions.d.ts","sourceRoot":"","sources":["../src/NotificationPermissions.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,8BAA8B,EAC9B,6BAA6B,EAC9B,MAAM,iCAAiC,CAAC;AAGzC,wBAAsB,mBAAmB,2CAMxC;AAED,wBAAsB,uBAAuB,CAAC,WAAW,CAAC,EAAE,8BAA8B,0CAczF;AAGD;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc,iPAMzB,CAAC"}
@@ -54,3 +54,4 @@ export interface NotificationPermissionsRequest {
54
54
  ios?: IosNotificationPermissionsRequest;
55
55
  android?: AndroidNotificationPermissionRequest;
56
56
  }
57
+ //# sourceMappingURL=NotificationPermissions.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationPermissions.types.d.ts","sourceRoot":"","sources":["../src/NotificationPermissions.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAE9E,oBAAY,aAAa;IACvB,IAAI,IAAI;IACR,MAAM,IAAI;IACV,KAAK,IAAI;CACV;AAED,oBAAY,iBAAiB;IAC3B,KAAK,IAAI;IACT,MAAM,IAAI;IACV,kBAAkB,IAAI;CACvB;AAED,oBAAY,sBAAsB;IAChC,cAAc,IAAI;IAClB,MAAM,IAAI;IACV,UAAU,IAAI;IACd,WAAW,IAAI;IACf,SAAS,IAAI;CACd;AAED,OAAO,EAAE,qBAAqB,EAAE,CAAC;AAEjC,MAAM,WAAW,6BAA8B,SAAQ,kBAAkB;IACvE,OAAO,CAAC,EAAE;QACR,UAAU,EAAE,MAAM,CAAC;QACnB,kBAAkB,CAAC,EAAE,MAAM,CAAC;KAC7B,CAAC;IACF,GAAG,CAAC,EAAE;QACJ,MAAM,EAAE,sBAAsB,CAAC;QAC/B,iCAAiC,EAAE,OAAO,GAAG,IAAI,CAAC;QAClD,yBAAyB,EAAE,OAAO,GAAG,IAAI,CAAC;QAC1C,sBAAsB,EAAE,OAAO,GAAG,IAAI,CAAC;QACvC,WAAW,EAAE,OAAO,GAAG,IAAI,CAAC;QAC5B,WAAW,EAAE,OAAO,GAAG,IAAI,CAAC;QAC5B,WAAW,EAAE,OAAO,GAAG,IAAI,CAAC;QAC5B,oBAAoB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;QACtC,UAAU,EAAE,aAAa,CAAC;QAC1B,cAAc,CAAC,EAAE,iBAAiB,CAAC;QACnC,+BAA+B,CAAC,EAAE,OAAO,CAAC;QAC1C,mBAAmB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;KACtC,CAAC;CACH;AAED,MAAM,WAAW,iCAAiC;IAChD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,8BAA8B,CAAC,EAAE,OAAO,CAAC;IACzC,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAED,MAAM,WAAW,oCAAoC;CAAG;AAExD,oBAAY,oCAAoC,GAC5C,iCAAiC,GACjC,oCAAoC,CAAC;AAEzC,MAAM,WAAW,8BAA8B;IAC7C,GAAG,CAAC,EAAE,iCAAiC,CAAC;IACxC,OAAO,CAAC,EAAE,oCAAoC,CAAC;CAChD"}