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

Test: Proposed Webview API #44466

Closed
3 tasks done
mjbvz opened this issue Feb 27, 2018 · 0 comments
Closed
3 tasks done

Test: Proposed Webview API #44466

mjbvz opened this issue Feb 27, 2018 · 0 comments

Comments

@mjbvz
Copy link
Collaborator

mjbvz commented Feb 27, 2018

Test for #43713

Size: 3

OS:

Summary

The proposed webview API makes it easier for extension authors to create and interact with webviews.

Setup

  • With a new extension or an existing extension
  • Copy vscode.proposed.d.ts into the extension and set "enableProposedApi": true in the package.json

Verify

  • Read through the proposed webview API docs. Does the documentation make sense? After reading it, do you understand how to use the webview api or are some parts unclear? Try creating a webview using the API

  • Make sure that your newly created webview can be moved around like a normal editor. Confirm that you cannot split a webview

  • Confirm that find works in the webview

  • Try adding some state to your webview contents, such as a simple counter:

    <p id='counter' style='font-size: 100px; font-family: "Comic Sans MS";'></p>
    
    <script>
        const counter = document.getElementById('counter')
    
        let count = 0
        setInterval(() => {3
            counter.textContent = '' + count++;
        }, 100);
    </script>
  • Confirm that when you switch the webview into the background and then restore it, the content is restored but the counter is reset

  • Now enable the retainContextWhenHidden setting on the webview. When the webview editor is put into the background now, the counter should be restored when it comes to the foreground again.

  • Check accessibility. Enable voiceover / NVDA and try tabbing to the webview content. Make sure the tab order is correct

@mjbvz mjbvz added this to the February 2018 milestone Feb 27, 2018
@octref octref removed their assignment Feb 28, 2018
@jrieken jrieken removed their assignment Feb 28, 2018
@tsalinger tsalinger removed their assignment Feb 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

7 participants