-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: mobile push notifications #13006
base: main
Are you sure you want to change the base?
Conversation
TODO - must update segment-schema repo for this to be available in MXP
- remove coupling notification services with these managers/services - remove notification service types from the transaction notification types - tidy FCMService to match extension/CORE - remove coupling from the notifee NotificationService file.
update types, and add correct push interface
This is now done in the controller. The push click handler may need to be done through UI though.
remove old code
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
Updated dependencies detected. Learn more about Socket for GitHub ↗︎
|
// TODO - Find out how to handle clicking notifications in the background. | ||
// The only approach notifee + navigate offers is through React. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Notifee + ReactNavigation offers react bindings for clicking notifications, but I don't see non-react bindings.
2 Approaches:
- We use a react approach and invoke a hook at root.
- There are "Deep Links" that we can add to IOS and Android settings to prompt what page/view the application should open up into.
- Fallback - we can just open the home page worst case.
contains some fixes we found that needed to be added to the package
…add-controller-push-notifications
…add-controller-push-notifications
…add-controller-push-notifications
…add-controller-push-notifications
ensures that notifications are enabled before we register for push notifications
…ot enabled I don't really like this, I think we might need to actually decouple notifications from push notifications?
remove some actions that are unused, and add some comments to come back to
…add-controller-push-notifications
…add-controller-push-notifications
remove unused methods, and add tests
…add-controller-push-notifications
…add-controller-push-notifications
notifee can only store string objects
we forgot to update some allowed actions and events
this prevents the app from being fully rendered if in headless mode
I dont think this is necessary anymore
we don't need to call it from the index.js file
this matches notifee notifications to give some similarities for foreground/background/killed notifications
…add-controller-push-notifications
these changes are not needed as IOS does not run in expo
609d5ce
to
84ec599
Compare
this has issues for both android and ios, so instead our server will send a notification payload
PUSH_NOTIFICATIONS_RECEIVED: generateOpt( | ||
EVENT_NAME.PUSH_NOTIFICATIONS_RECEIVED, | ||
), | ||
PUSH_NOTIFICATIONS_CLICKED: generateOpt( | ||
EVENT_NAME.PUSH_NOTIFICATIONS_CLICKED, | ||
), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm removing these events for mobile, they are not feasible.
Context:
Mobile background and killed push notifications currently will not run headless JS for us to then intercept and send events for receive and clicks
Description
Adds support for mobile push notifications. Reorganised some services, and utilising the shared controller over custom logic.
Draft TODO:
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist