[w3c/manifest] custom padding for maskable icons (#805)

This is a follow-up to [Issue 555](https://github.com/w3c/manifest/issues/555).

I have Android in mind, in particular, but this may apply equally to other platforms.

[This comment](https://github.com/w3c/manifest/issues/555#issuecomment-404097653) by @mgiuca  discusses how a user agent may work around the fact that Android's adaptive icons specify a different safe zone than the web spec ([link](https://developer.android.com/guide/practices/ui_guidelines/icon_design_adaptive)).

The chosen path forward, referred to as "Option B" suggests that the user agent insert a 15% padding border around the icon ([example with black padding](https://user-images.githubusercontent.com/228433/42558175-c9b31ade-8533-11e8-87b0-14982ab7a31c.png)).

The discussion assumes that the extra border will be far enough away from the centre of the icon that a user will probably never see it. Unfortunately, in my experience, this is not the case - particularly if the user is using an alternative launcher or non-circular icons. Seeing black when dragging the icon doesn't look great.

It's also suggested in [Issue 555](https://github.com/w3c/manifest/issues/555) that instead of black icons, the user agent may choose use the theme colour, average icon colour, most common icon colour, etc. This would help, but possibly still not look that great.

I'd like to consider two improvements.

**1 (short term):** Specify in the spec exactly what the border colour should be, if one is needed. Developers should know what to expect. What the colour we specify actually ends up being is less important, I think the main thing is that it's predictable and consistent across user agents. Theme colour or average icon colour both seem reasonable.

**2 (longer term):** Explore ways that we can expose custom padding to the developer. If we choose to use the theme colour, then it is already customizable to an extend. Maybe it should be a separate manifest field independent of theme colour? Maybe even optionally something more sophisticated like a larger image to composite on top of? Just spit-balling here, but a solid colour might not always be desirable.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/manifest/issues/805

Received on Monday, 30 September 2019 17:04:12 UTC