Unity-Technologies / com.unity.mobile.notifications

Mobile Notifications Package
https://docs.unity3d.com/Packages/com.unity.mobile.notifications@2.1/manual/index.html
Other
131 stars 42 forks source link

Add support for Action icons #241

Closed aurimasc closed 1 year ago

aurimasc commented 1 year ago

https://jira.unity3d.com/browse/MNB-26

Since iOS 15 notification actions can have icons on them. This PR adds new APIs to support that. There are two ways to specify an icon: system icon by name, or icon in app bundle by name (the later means an icon placed in XCode project). In the test project the actionable notification button has been modified. The Reject action now has system icon on it, while Later has one from app bundle. Due to lack of API, the later doesn't work out of the box, there is an image file in the Main projects root directory that you have to drag into XCode to make it work.

I've tested it already, the only extra testing required is to see that older iOS versions don't blow up (no icon support there, but actions should work).