Commit graph

49 commits

Author SHA1 Message Date
Matt Bierner cd48aa9544
Remove @types/node dep for simple browser
This package does not use any node modules
2021-07-22 17:16:33 -07:00
Martin Aeschlimann 7927075f89
Merge pull request #128545 from microsoft/joh/webpack5
Adopt webpack 5
2021-07-14 22:32:54 +02:00
Matt Bierner 5b8ce768f3
Add getNonce function to generate webview nonces 2021-07-13 10:02:24 -07:00
Martin Aeschlimann 7ebe6a6054
adopt web extensions to webpack 5 2021-07-08 21:41:03 +02:00
Matt Bierner 986dcaf7a3
Add simple browser readme
Fixes #127690
2021-07-01 10:18:50 -07:00
Matt Bierner b8f11107f7
Use @types/vscode-webview 2021-05-27 13:41:38 -07:00
Robo bce4d71f64
chore: bump node@14.x in devDependencies (#122905) 2021-05-04 10:04:13 +02:00
Sandeep Somavarapu ac151b40a5
enable virtual workspace capability 2021-04-23 10:20:23 +02:00
SteVen Batten f9fc28d47d update ext manifest schema validation and built-in exts 2021-04-21 11:54:42 -07:00
Miguel Solorio ac48f78dd6
Add icons for built-in extensions (fixes #81760) 2021-04-20 12:09:24 -07:00
Matt Bierner a5d656cd3f
Configure workspace trust for simple browser and image preview 2021-04-14 20:37:01 -07:00
Matt Bierner 119581fc2a
Use more standard name for shared extension tsconfig
This enables Intellisense in the `tsconfig.base` file
2021-04-12 15:58:38 -07:00
Alex Ross 2894338f38
Add all valid hosts to simple browser (#120929)
and pass sourceUri not targetUri
2021-04-09 16:54:31 +02:00
Matt Bierner 73ae56b82b
Build with latest TS nightly (#120690)
* Pick up new TS 4.3

Also tests adding override keywords for extensions as part of #120675

* Update to daily TS and workaround TS 4.3 issue

Works around https://github.com/microsoft/TypeScript/issues/43578
2021-04-07 12:19:05 -07:00
Jean Pierre 8117fec7df
Fixes #120036 (#120275) 2021-04-06 15:29:36 -07:00
Matt Bierner addf2d6d9e Fix spelling for gitignore 2021-03-24 12:29:08 -07:00
Matt Bierner f8c1ffbb0c Build simple-browser media during watch
Fixes #119795

This lets us avoid having these files checked in
2021-03-24 12:27:30 -07:00
SteVen Batten 9c00242866 updating telemetry module for built-in exts 2021-03-22 16:28:08 -07:00
Matt Bierner 043a0ee0d9 Try cache busting on reload in simple browser
Fixes #118389
2021-03-17 17:24:48 -07:00
Matt Bierner 94447bd20e Use button foreground on hover
Fixes #117568
2021-02-25 17:31:15 -08:00
Matt Bierner ba7d28d53c Use shared webpack version instead of installing locally for simple-browser 2021-02-09 17:47:32 -08:00
Matt Bierner 87a3effc79 Try to disable caching in the simple browser's iframes 2021-02-08 21:31:04 -08:00
Matt Bierner ff03697a1a Use node script instead of 'cp' command
this should also work on widnows
2021-02-08 14:54:37 -08:00
Matt Bierner 46e28e3bbe Copy codicon files directly into sources instead of taking a non dev dependecy on the entire package 2021-02-08 14:27:16 -08:00
Matt Bierner 5b32b28037 Mark simple browser as a UI extension 2021-02-08 14:27:16 -08:00
Matt Bierner eb62ecb01e Use white background in simple browser by default 2021-02-08 14:27:16 -08:00
João Moreno 8bf9b56ade
Merge branch 'joao/extensions' 2021-02-02 12:06:01 +01:00
Matt Bierner d9ff550d02 Add intellisense for onOpenExternalUri activation and rename event
Fixes #115131

Also renames the activation event to `onOpenExternalUri`
2021-02-01 19:57:54 -08:00
João Moreno ec805db5ed
add repository field to extensions package.json 2021-01-29 15:30:45 +01:00
Matt Bierner e5c4f426fe Fix setting decription and remove unused setting 2021-01-26 16:03:36 -08:00
Matt Bierner 542de8e009 Move schemes to opener metadata 2021-01-21 14:41:25 -08:00
Matt Bierner 885585c7f8 Remove test math formula from readme 2021-01-21 14:41:25 -08:00
Matt Bierner d87041edde Downgrade simple browser to prompt instead of being the default on web
We need more testing in codespaces before enabling it automatically
2021-01-15 10:38:50 -08:00
Matt Bierner 6cceb4eab0 Remove enabled setting and try to open simple browser to side of current editor 2021-01-14 17:06:14 -08:00
Matt Bierner 1e3a23b4e0 Fix simple browser button color for light themes 2021-01-14 17:06:14 -08:00
Matt Bierner cc5e8b22fa Continue work on url opener api
For #109277

- Add `option` opener priority. This means the oper will only be shown if requested but will not replace the default opener
- Persist registered openers for IntelliSense suggestions
2021-01-14 17:06:14 -08:00
Matt Bierner 5d6cba5cbc Reworking external opener implementation to allow configured openers to be called directly without a canOpen check
If the user has configured a specific external uri opener, we should always try to use that without first calling `canOpen` to filter down the list of openers.

This change also adds `ExternalUriOpenerEnablement` which allows an opener to mark itself as the preferred opener for a given uri. If only a single preferred opener is returned, it will be used automatically for that uri (although user configuration can override this)
2021-01-14 10:37:00 -08:00
Matt Bierner 710846866f Activate extension on simpleBrowser.api.open 2021-01-13 16:56:39 -08:00
Matt Bierner b7f9eddf04 Allow passing viewColumn to simpleBrowser.api.open 2021-01-13 16:56:39 -08:00
Matt Bierner e7aa009ac3 Remove enabledHosts setting
This setting is no longer used
2021-01-13 12:53:18 -08:00
Matt Bierner 47aa3ad09a Continue work on opener service
- Add error notification if opener throws an exception
- Add public facing id to openers. This is used in settings
- Add intellisense for the opener id setting
2021-01-13 12:53:18 -08:00
Matt Bierner 47a135e715 Rework opener api proposal
For #109277

- Add more explicit two phase structure to api
- Make opener pass along label when registered
2021-01-12 16:14:42 -08:00
Matt Bierner 0949d5b794 Remove unused var 2021-01-07 17:52:06 -08:00
Matt Bierner acda4aed82 Make the external opener a two phase process
This changes makes a few changes to the openers:

- Move the opener prompting from the extension host into the main thread
- Make the external opener process two phases: get openers and then open. This would let us skip the trusted domain validation for extension handled links if we want to in the future
- Add lifecycle to commands used by the uri opener

For #109277
2021-01-07 17:42:12 -08:00
Matt Bierner e2c305f3a3 Allow registering additional external uri openers
This change moves the extension uri opener contribution point to instead use the internal `IExternalOpener` api instead of the more generic `IOpener` api. This is required since external uri openers should see the resolved uri that has gone through port forwarding, not the raw uri that the user clicked on
2021-01-07 11:41:07 -08:00
Matt Bierner bdf57b45ce Remove button background in simple browser 2021-01-07 11:41:07 -08:00
Matt Bierner 809d2f63d0 Added show options to simple browser open command 2021-01-06 12:17:36 -08:00
Matt Bierner 2fed7ba374 Adding settings to control which schemes simple browser is enabled for
Also adds a setting to enable/disable the focus lock indicator
2021-01-06 12:17:36 -08:00
Matt Bierner 3ed300eb9d
Add simple browser extension (#109276)
* Add support for TS's Hierarchical refactorings API

https://github.com/microsoft/TypeScript/pull/41975

* Add simple browser extension

This change adds a new 'simple browser' extension. This extension uses a webview to render webpages directly in VS Code. We plan on using it for optionally previewing local servers in both desktop and codespaces

The browser itself has a number of limitations due to the security around iframes:

- It traps keyboard focus
- We can't detect if a page fails to load
- We can't track the current url of the iframe

* Add experimental alert when the iframe is focused

* Disable events on focus warning

* Hooking up simple browser to opener
2021-01-04 19:06:53 -08:00