Skip to content
This repository has been archived by the owner on Sep 4, 2020. It is now read-only.

Notification doesn't show the app icon #112

Closed
ashishsajwan opened this issue Sep 7, 2015 · 5 comments
Closed

Notification doesn't show the app icon #112

ashishsajwan opened this issue Sep 7, 2015 · 5 comments

Comments

@ashishsajwan
Copy link

var push = PushNotification.init({ 
        "android": { 
            "senderID": "123456789", "icon": "icon", "iconColor": "blue"}, 
       "ios": {}, "windows": {} 
    });

setting "icon" : "icon" because i have icon.png inside drawable folder ...

but on receiving notification , instead of icon, it shows white square inside a grey circle ...

@macdonst @bobeast @EddyVerbruggen

@ashishsajwan ashishsajwan changed the title Notification on doesn't show the app icon Notification doesn't show the app icon Sep 7, 2015
@ashishsajwan
Copy link
Author

Here are the screen shots. .. on lock screen it shows app icon with colored background .. although i was expecting app icon to fill up all the space ..

screenshot_2015-09-07-16-44-12

but once you unlock this is how it looks

screenshot_2015-09-07-16-45-06

@macdonst
Copy link
Member

macdonst commented Sep 7, 2015

@ashishsajwan what you show here is proper behaviour. As of Android 5+ there are new guidelines to follow for icons. Check out: http://developer.android.com/design/patterns/notifications.html under "Use distinct icons".

The small icon is only supposed to be white with transparency. That is why I added in the icon property for Android so you could specify the properly formatted icon.

@macdonst macdonst closed this as completed Sep 7, 2015
@ashishsajwan
Copy link
Author

but how to show colored notification icon on kitkat & user this new icon only on lolipop ??

@macdonst

@utamanna
Copy link

@macdonst, like @ashishsajwan asked, how can we show the new icon for Android 5+ but also be backwards compatible for Android versions below 5 (mainly Android versions Jelly Bean and KitKat, they still have pretty significant install numbers Google Dashboard).

@lock
Copy link

lock bot commented Jun 4, 2018

This thread has been automatically locked.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

3 participants