On June 8, 2021 at 1:00 a.m. Beijing time, Apple held its WWDC 21 conference. At the event, the new version of iOS 15 was unveiled. The theme of iOS is Focus, Connect, and Explore.
For those of you who are interested, the Focus mentioned in this topic is the new notification change in iOS 15. This article is about the new push feature in iOS 15.
There was a Focus mode before iOS 15. Focus mode for iOS 15 is actually an evolution of the current version of Do not Disturb Mode.
You can see that the first part is the specific pattern, the default is the individual, do not disturb mode, work, sleep. In fact, there is no difference between the four is to use the name as a distinction, and choose different modes at different times to give yourself a better notification use experience. We can also manually add focus mode, set the focus mode name, icon, and corresponding configuration.
We can set the focus mode to be shared across all devices, and we can also set which apps can access the user’s focus state. This feature is currently only available to Apple’s own apps, and I haven’t found any code or Settings to access this feature yet.
The phone is the only App that can be set globally in focus mode alone, specifying which calls can be received when focus mode is on.
When we click on “Personal” to enter the specific focus mode, we can see that there are multiple configurations. We can set up a whitelist for certain address book members and apps that is not affected by focus mode.
You can also set whether to turn on Time Sensitive notifications, a new notification feature in iOS 15 that we’ll cover in a future article.
Setting the shared focus state is similar to setting the global focus state to access the focus mode, but the scope is different. Speculated that apple will be updated in the subsequent versions (another possibility is to use getNotificationSettingsWithCompletionHandler interface to access, just get to not focus mode, where the official document description is a little fuzzy, can’t completely confirmation)
In iOS 15 and later, notifications can be adjusted more fine-grained by specifying dispatch times and setting the focus mode. The dispatch notification schedule allows users to choose whether to receive notifications immediately or to dispatch notifications using summaries for a time period of their choice. Focus mode helps people filter notifications during periods of time they define, such as sleeping, working, reading, or driving.
People can whitelist selected contacts and apps to receive notifications in Focus mode.
For example, in a work-centric environment, people might want to receive messages immediately from colleagues, family members, and work-related applications. People may also want to receive all time-sensitive notifications while in focus mode. Time-sensitive notifications contain basic information that people want immediately.
Note that even though the focus mode may delay the delivery of notifications, the notifications themselves will be available as soon as they arrive.
Specify a system-defined interrupt level for each notification that an application can send. The system uses the interrupt level to help determine when to dispatch notifications; When a communication notification arrives, the system uses the sender’s configuration to determine when to dispatch the notification.
The system defines four interrupt levels for non-communication notifications:
• To be Passive. People can check information at their leisure, such as restaurant recommendations. •Active (Active, default). When information arrives, people may want to know about it, such as a score update for their favorite team. •Time Sensitive Information that directly affects users and requires their immediate attention, such as account security issues or delivery information. •Critical. Urgent information about personal health and public safety that directly affects users and requires their immediate attention. Critical notifications are rare and usually come from government and public agencies or healthcare applications. To use this interrupt level, you need to apply for the corresponding permission.
The abilities of the four levels are shown in the figure above. Passive and active are the same, with time-sensitive levels that override timing push and focus mode, and important levels of notifications that even block calls and mute Settings.
In this new feature we can see some of apple’s historical design ideas, where developers are expected to set the exact urgency of each notification to build trust.
Users have several ways to adjust the way they receive notifications from your app, such as turning off all notifications. Therefore, you must be as realistic as possible when assigning interrupt levels. I don’t think you want the user to feel like you’re interrupting their work with a high-level notification, but the message is a low-level message, which will probably cause the user to turn off notifications for your App.
When your application first receives a time-sensitive notification, the system describes how it works and provides a way to turn it off if the user does not agree that the information needs immediate attention.
Do not use time-sensitive interrupt levels to send marketing notifications. Users may have agreed to receive marketing notifications from your app, but such notifications should not break out of focus mode or scheduled notification delivery Settings.
About interrupt level this paragraph is a large part of the original apple translation, interested students can have a look.
The author tried to verify the experience of different interrupt levels in the whole link. However, iOS 15 has just been released and is in the early stage. There is no relevant information in the document of “Generate a Remote Notification” and “Send Notification Request to APNs”, so it cannot be measured.
I switched to the idea that although the API wasn’t updated, the code might have been, so I updated the Xcode 13.0 beta and looked at the framework API.
We can in the frame of the < UserNotifications/UserNotifications. H > find the latest iOS 15 related code, In the < UserNotifications/UNNotificationContent. H > can we see a new enumeration of interrupt level.
If we look at the English description, we can see the difference between passive and active interrupt levels. Passive interrupt levels do not highlight and play push sounds and are only added to the notification list (notification center, I should say), while active interrupt levels, the default, are immediately displayed and highlight and play push sounds.
In addition, there are new corresponding properties.
It should be understood that interruptionLevel is the level of interruption for this push. The relevanceScore property, which is mentioned in WWDC but not mentioned in the Apple notification guide, should also be set in the APNs API.
Those who don’t want to download the Xcode Beta right now, but want to see the latest API, can also see it in the official iOS documentation.
Xcode is getting bigger and bigger
Timed push Summary Finally, let’s talk about this timed push summary. It is often mentioned before that push notifications are sent according to the actual situation.
Due to the lack of official APNs API updates, I haven’t fully understood the logic of timing feeds. Let’s first look at the Settings section in iOS 15.
In the notification interface, we added a regular feed push entry. We opened this function, and then set the feed push several times a day according to the time. We need to select specific apps to adapt to this configuration, which is closed by default. For example, if I set the notification digest to be sent 4 times a day, I would not be prompted immediately when the notification is sent, but would wait until the time of the digest.
But actual phenomenon is like that, I sent a notice, immediately received, then, for example, five in the afternoon I bit message is pushed into a new category called night and expectations are different, speculated that it may be because the default message type is active, passive type of message may need to send to trigger this function.
There are still more uncertainties to explore about the abstract.
So here, about the notice on the iOS 15 new features of a preliminary study was over, the author at the time of writing this article still think iOS 15 now is still in a Beta version of the early stage, refer to the document found part of the function is still in the stage of not completely let go, according to apple’s habit before release the GM version should also have some adjustments, So the content in this article is subject to change, please refer to the latest iOS 15 can see the effect shall prevail.
Thank you for reading 😅. This article was written on June 21, 2021, the first Beta version of iOS 15.