-
Notifications
You must be signed in to change notification settings - Fork 161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shortcut items with no icon URL are ignored #116
Comments
Looking at this section of the template project, it seems this is by design. The icon is somewhat required on Android, as if the developer doesn't set it in It doesn't sound to me that llama-pack would be better to provide a default icon that would be able to convey any better meaning to the actions. I do think we should alert developers of missing data in the shortcuts, so they know it's not being included and know how to fix it. @rayankans will know more about the current design. |
Just checked, can't confirm the case of item with no icon, the situation with WebAPK is very sad. I've opened https://crbug.com/1057380. |
Hi, I explained on the bug how the case with WebAPKs is related to caching and the fact that this hasn't been enabled on all channels. As for llama-pack, as @andreban mentioned, this was a design decision. I could be convinced otherwise. Maybe a warning that it's being skipped is best for now? I believe that we we show developers a summary of the shortcuts included though when they are generating the TWA. |
+1 to a warning of with what is being skipped and a summary of the shortcuts being included. |
The web app manifest spec doesn't require icon for shortcut items, it's optional (see https://w3c.github.io/manifest/#example-11). If the developer declared 5 shortcut items (and 2 of them have no icons) in the web app manifest for PWA, then he expects to see these 5 shortcut items for TWA (and 2 of them should have default icon — android heads). I.e. we should skip items only if
or
Since #103 is not fixed yet, if BTW, is the number of shortcut items limited? What if the developer declared e.g. 100 items? |
The manifest spec doesn't require it, but an Icon is required on Android. When an icon is not included in shortcuts.xml, a default icon is included, but results in a bad user experience. We want to ensure applications using Trusted Web Activity are high quality Android Apps. Therefore, it makes sense being more strict than the manifest spec in this case. |
I believe we should align with WebAPK behavior. @rayankans What if the icon for shortcut item is not provided in the manifest in case of WebAPK? Will it be android head icon or something else default icon? (Which exactly?) Or will this shortcut item be ignored? And what if the icon has unsupported format (e.g. SVG)? Will this shortcut item be ignored or has default icon? |
@FluorescentHallucinogen WebAPKs don't ignore any shortcuts. They currently use a fully transparent icon if nothing was provided. I don't think llama-pack should match behaviour with WebAPKs. It already gives the option to modify manifest values, or provide a custom manifest, so it makes sense to have its own quality enforcements. I think a warning should suffice. @andreban any thoughts on the matter? |
+1 to the warning. |
For me WebAPK always shows transparent icon even if icon is provided and has supported format. PTAL at https://crbug.com/1057380. You closed this issue with "WontFix" status, but it's not fixed! :-/ |
Repro:
llama-pack init --manifest https://shortcut-bugs.web.app/manifest.json
.Shortcut items with no icon URL are just ignored.
llama-pack
should provide some default icon in this case instead of ignoring them.The text was updated successfully, but these errors were encountered: