How to change IOS badge notification colour from d

2019-02-18 22:30发布

问题:

The default APNS allows a number (badge) to appear in Red background on top of our app icon to state that there is a new notification.

Is there a way to change the Red colour background to any other colours based on the backend server output?

回答1:

I don't believe this is possible with public iOS SDK APIs



回答2:

According to Apple iOS Human Interface Guidelines, you cannot change the color or size of the pending notification badge.

A badge is a small red oval that displays the number of pending notification items (a badge appears over the upper-right corner of an app’s icon). You have no control over the size or color of the badge.

If however you are just curious on how to do it, there is a sample project here.



回答3:

Apple not allow to access the UILocalnotification properties so we can not change any thing in uilocal notification , we can only use its default properties