Skip to content
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

[VSCODE] Check icon sizes in snippets #3747

Closed
1 task done
MehdiZangenehBar opened this issue Jan 6, 2023 · 2 comments · Fixed by #3882
Closed
1 task done

[VSCODE] Check icon sizes in snippets #3747

MehdiZangenehBar opened this issue Jan 6, 2023 · 2 comments · Fixed by #3882
Assignees

Comments

@MehdiZangenehBar
Copy link

MehdiZangenehBar commented Jan 6, 2023

What happened?

I got this two error or warning:

image

What do you expect to happen?

We can fix the first error by adding the icon path for 96x icon (which accidentally I found that is exist in your website):

"shortcuts": [
    {
        "name":"The name you would like to be displayed for your shortcut",
        "url":"The url you would like to open when the user chooses this shortcut. This must be a URL local to your PWA. For example: If my start_url is /, this URL must be something like /shortcut",
        "description":"A description of the functionality of this shortcut",
        "icons": [
            {
                "src": "https://www.pwabuilder.com/assets/icons/icon_96.png",
                "sizes": "96x96",
                "type": "image/png",
                "purpose": "maskable"
            }
        ]
    }
]

And about the second error, we can match the size with the image you addressed.

What version of VS Code are you using?

No response

Relevant log output

No response

Are you using the latest version of the VS Code extension?

  • I am using the latest version of the VS Code extension
@jgw96
Copy link
Contributor

jgw96 commented Jan 12, 2023

@MehdiZangenehBar Could you explain more of what the issue is here?

@MehdiZangenehBar
Copy link
Author

I just created the manifest file by using PWABuilder and I see that mentioned part is missed (shortcuts > Icons) in the snipped code.

@jgw96 jgw96 changed the title [VSCODE] [VSCODE] Check icon sizes in snippets Feb 7, 2023
jgw96 added a commit that referenced this issue Mar 6, 2023
fixes #3747
<!-- Link to relevant issue (for ex: "fixes #1234") which will
automatically close the issue once the PR is merged -->

## PR Type
<!-- Please uncomment one ore more that apply to this PR -->

Bugfix 
<!-- - Feature -->
<!-- - Code style update (formatting) -->
<!-- - Refactoring (no functional changes, no api changes) -->
<!-- - Build or CI related changes -->
<!-- - Documentation content changes -->
<!-- - Sample app changes -->
<!-- - Other... Please describe: -->


## Describe the current behavior?
<!-- Please describe the current behavior that is being modified or link
to a relevant issue. -->
Shortcuts snippet did not include icons array, which is technically
invalid, although it would work in the browser (using the apps icon
instead, automagically by the browser)

## Describe the new behavior?
Shortcuts snippet now includes icon array.
We now build the shortcuts snippet from an array to avoid frustrating
syntax with vscode snippets


## PR Checklist

- [ x] Test: run `npm run test` and ensure that all tests pass
- [x ] Target main branch (or an appropriate release branch if
appropriate for a bug fix)
- [x ] Ensure that your contribution follows [standard accessibility
guidelines](https://docs.microsoft.com/en-us/microsoft-edge/accessibility/design).
Use tools like https://webhint.io/ to validate your changes.


## Additional Information

---------

Co-authored-by: Justin Willis (HE / HIM) <[email protected]>
@ghost ghost locked as resolved and limited conversation to collaborators Apr 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Status: Done ✔️
Development

Successfully merging a pull request may close this issue.

3 participants