Skip to content
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

Preview notifications using background app refresh #4323

Closed
pedropombeiro opened this issue May 17, 2018 · 1 comment
Closed

Preview notifications using background app refresh #4323

pedropombeiro opened this issue May 17, 2018 · 1 comment

Comments

@pedropombeiro
Copy link
Contributor

pedropombeiro commented May 17, 2018

User Story

As a user, I want to see a preview of my messages in the notifications. We should leverage the work from #3451 to create a local PN with the additional context.

Description

Type: Features

Summary:

The application could run in the background upon reception of a notification to fetch recent messages, decrypt them and show and update the notification to show a preview of the message without having to actually send the message body to the notification service.

Expected behavior

Notification says who sent a message and shows a preview of the message

Actual behavior

Notification says a message has been received

Reproduction

  • Open Status
  • Connect to an account and put Status in background
  • Send message from another device
  • Should receive notification

Solution

Summary:
It could be done using background app refresh feature on iOS which allows an app to wake up for 30 sec in the background upon reception of a notification

When a background update notification is delivered to the user's device, iOS wakes up your app in the background and gives it up to 30 seconds to run. In iOS, the system delivers background update notifications by calling the application:didReceiveRemoteNotification:fetchCompletionHandler: method of your app delegate. Use that method to initiate any download operations needed to fetch new data. Processing remote notifications in the background requires that you add the appropriate background modes to your app.

Similar feature should exist on Android.

@pedropombeiro
Copy link
Contributor Author

Closing as a dupe of #3451

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant