Commit Graph

12367 Commits

Author SHA1 Message Date
Matt Bierner e4f7f6a9da Add PasteEditProvider (#107283)
For #30066

This adds a new `documentPaste` api proposal that lets extensions hook into copy and paste.

This can be used to do things such as:

- Create link when pasting an image
- Bring along imports when copy and pasting code
2022-05-25 12:27:58 +02:00
Matt Bierner a6724dcc10 Bump default JS target for scripts in html (#150240)
* Bump default JS target for scripts in html

For JS/TS files, we target ES2020 by default. However in html files we're still stuck targetting es6

This change aligns the two

* use es2020.full (includes dom), fix web, avoid searching in node_modules

Co-authored-by: Martin Aeschlimann <martinae@microsoft.com>
2022-05-25 11:50:44 +02:00
Logan Ramos 3a8b1fe03e More telemetry comments (#150303)
* Add owners to all telemetry events

* More comments

* Add comments to non typescript GDPR annotation

* Another comment
2022-05-24 16:00:55 -07:00
Matt Bierner bf7ec548f5 Adopt TS 4.7 final (#150313)
Picks up the offical TS 4.7 release
2022-05-24 20:19:04 +00:00
Ladislau Szomoru 3e83fa95b0 Fix #150266 (#150267) 2022-05-24 15:06:34 +02:00
Matt Bierner 1c7991f1e8 Markdown ignoreLink should apply to paths in header links (#150223)
This change lets you ignore all links to a given file, even if those links include a header. For example: `[text](/path/to/file#some-header)` can be ignored using `/path/to/file`
2022-05-23 17:07:15 -07:00
Matt Bierner 45304da73d Finalize NotebookEditor api proposal (#149767)
* Finalize NotebookEditor api proposal

Fixes #149271

This finalizes most parts of the NotebookEditor api proposal. I haven't removed the proposal entirely as there are still a few parts being left behind:

- The deprecated properties/functions
- A few contribution points such as `notebook/cell/executePrimary`

* remove extra quote
2022-05-23 23:27:17 +00:00
Matt Bierner b8420578fd Add additional allowed tags in untrusted notebook markdown (#150228)
This adds some extra allowed tags when rendering markdown in notebooks. Additions are:

```
  "b",

    "br",

    "caption",

    "center",

    "col",

    "colgroup",

    "details",

    "em",

    "font",

    "i",

    "kbd",

    "sub",

    "summary",

    "sup",

    "table",

    "tbody",

    "tfoot",

    "thead",

    "td",

    "th",

    "tr",

    "tt",

    "u",

    "video"
```
2022-05-23 22:30:42 +00:00
Martin Aeschlimann f1b392ed55 polish names 2022-05-22 20:03:30 +02:00
Martin Aeschlimann 49944b1501 DiagnosticsSupport for json and html 2022-05-22 20:03:30 +02:00
Martin Aeschlimann aacb387ef1 implement diagnostic pull 2022-05-22 20:03:30 +02:00
Rob Lourens 3649387f3f Bump php grammar, fix #142824, fix #116103 (#150067) 2022-05-21 00:18:25 +00:00
Matt Bierner 96cae45ba9 Rename skipPaths to ignoreLinks (#150064)
This change renames the experimental skipPaths setting to ignoreLinks. This setting applies to all types of links, and can also be used to ignore links to headers
2022-05-20 22:54:21 +00:00
Esteban Dalel R e76ad21903 Fix typo (#150042) 2022-05-20 19:06:35 +00:00
Matt Bierner 993c36c920 Fix markdown ext errors accessing disposed webview (#149960)
When reloading windows that need to restore a markdown preview, sometimes I'll see an error when the markdown preview tries accessing a disposed of webview. This seems to be cause caused by `provideTextDocumentContent`, where we end up disposing of the webview before an `await` resumes execution
2022-05-20 09:17:57 -07:00
Matt Bierner 0ee05bb617 Pick up latest markdown-it-katex (#149978)
Fixes #149682
2022-05-19 21:54:08 +00:00
Matt Bierner a00e138040 Changing dependency syntax for markdown-it-katex (#149962)
Fixes #149291
2022-05-19 18:25:45 +00:00
Martin Aeschlimann e783fdc25e css/html/json update to lsp 8 (#148715) 2022-05-19 12:48:53 +02:00
Matt Bierner 0d55d50173 Expose outputItem in notebook markdown eve (#149870)
For #121256

This change adds the current `ouputItem` to the notebook markdown renderer's environment

Renders that extend our markdown renderer can use this to access output item metadata for example
2022-05-18 16:14:32 -07:00
Matt Bierner 27903c28aa Remove unfinished test (#149864)
Mistakenly checked this in
2022-05-18 16:01:28 -07:00
Rob Lourens a49e21c63b Fix notebook output double spacing (#149842)
Fixes #149563
2022-05-18 15:37:22 -07:00
Matt Bierner daf0d5e551 Add skipPaths option for markdown link validation (#149859)
The new `markdown.experimental.validate.fileLinks.skipPaths` setting lets you specify a list of paths (as globs) that should not be validation

This is useful since markdown is used in a range of environments, and sometimes you may need to link to paths that don't exist on disk but will exist on deployment

A few other changes here:

- Adds a quick fix that adds paths to `skipPaths`
- Rename existing settings to use the `.enabled` prefix
2022-05-18 14:37:08 -07:00
Roj 64e09597f1 Handle multiline commit messages when creating PR (#149426)
- This makes the body of the pull request non-empty when the commit message consists more than one line.
- The GitHub web client fills the body the same way, too, when you create a pull request.
- Some commit messages consist more than one line, like this one, which is giving more detail about the commit, and can be used as a shortcut to not write the same text when opening a pull request and on GitHub.
- Without these changes, the pull request title will be messed up if the commit message is similar to this.

Co-authored-by: João Moreno <joao.moreno@microsoft.com>
2022-05-18 11:13:32 -07:00
Matt Bierner 6bd7605ae1 Enable strictNullChecks for implicit projects (#149844)
Mistakenly enabled checkJS instead of strictNullChecks
2022-05-18 10:47:37 -07:00
Matt Bierner ff975bc211 Update list of enabled APIs (#149838)
We use `notebookWorkspaceEdit` even though it's not enforced
2022-05-18 10:39:40 -07:00
Martin Aeschlimann ba5691170f update vscode-grammar-updater 2022-05-18 11:58:51 +02:00
Matt Bierner c9c5990e38 Adopt notebookWorkspaceEdit proposal internally (#149778)
This switches us to use the new `notebookWorkspaceEdit` proposal instead of `notebookEditorEdit`
2022-05-17 18:51:25 -07:00
Matt Bierner 1c7ab35761 Rename to DocumentOnDropEditProvider (#149730)
This change renames `DocumentOnDropProvider` to `DocumentOnDropEditProvider`. This new name aligns with the existing `DocumentFormattingEditProvider`
2022-05-17 09:26:54 -07:00
Martin Aeschlimann caa463191f add telemetry event comments and owner (#149070) 2022-05-17 15:20:02 +02:00
Ladislau Szomoru 38de430140 Add scope for settings (#149696) 2022-05-17 12:41:45 +02:00
David Dossett 5f3e9c120a Update custom menu styles (#149187)
* Initial updates

* Add border radius

* Address PR feedback

* Fix typo

* Update shadow blur

* Update LR padding and use description foreground for shortcuts

* Typo

* Fix separator padding/margin

* fix jumpy items in hc themes

* Fix shadow and border radius

* Use opacity for keybinding for better color blend

* Update min width and container padding T/B

* Revert actionbar margin and remove unnecessary menu css file

* Ensure menus respect 0 horizontal margin rule

* set bg/fg color on menu container

* better fix for jumpy menu items

* use outline instead of border

* clean up dead css in style.css
fix opacity for separators in menus

* bring back vertical action bar margins

* Remove old CSS import

Co-authored-by: SteVen Batten <sbatten@microsoft.com>
2022-05-16 18:40:33 -07:00
Matt Bierner c2b064538b Don't detect links in markdown code blocks (#149680)
Fixes #149678
2022-05-16 17:35:16 -07:00
Matt Bierner d71f6ec0d9 Update markdown diagnostics when linked files change (#149672)
For #146303

This PR updates the markdown diagnostic reporter to watch linked to files. If one of these linked to files is created or deleted, we recompute the diagnostics for all markdown files that linked to it
2022-05-16 17:30:39 -07:00
Matt Bierner 101f6fb31d Enable enabling js/ts.implicitProjectConfig.checkJs by default (#149660)
Fixes #149659
2022-05-16 11:52:27 -07:00
Matt Bierner dd9dca9825 Fixing some html tags detected as autolinks for diagnostics (#149511)
For markdown such as `<scope:tag>b</scope:tag>`, we currently detect `<scope:tag>` as an uri (an autolink) and then try validating it as a file path

This change doesn't fix `<scope:tag>` being detected as a link (which is actually correct if there isn't closing html), but does fix the us trying to validate it by marking the uri as external
2022-05-16 12:19:29 +02:00
Ladislau Szomoru 42ec698ec9 Git - Add trace level telemetry to repository discovery (#149469)
* Add trace level telemetry to help investigate repository scan issues

* Remove empty line

* Switch back to the localized warning message
2022-05-13 16:31:28 +02:00
Ladislau Szomoru a28eab6873 Git - branch protection (#149360)
* Initial implementation of branch protection

* Pull request feedback

* Update extensions/git/src/commands.ts

Co-authored-by: João Moreno <joao.moreno@microsoft.com>
2022-05-13 02:15:01 -07:00
Martin Aeschlimann f572583d9a fix word range in XML. For #149318 2022-05-13 10:22:33 +02:00
John Murray 479abbf95e Add "Open Containing Folder" etc to file context menu in Git SCM view (#149150)
* Add "Open Containing Folder" etc to file context menu in Git SCM view

Caption is "Reveal in Finder" on macOS and "Reveal in File Explorer" on Windows.
This resolves #137828

* Use multiple decorators on a method to simplify code
2022-05-13 09:48:36 +02:00
Matt Bierner 113287ccc3 Don't treat escaped markdown reference links as links (#149407)
Fixes #149406

Make sure that escaping the leading `[` of a reference link means it is not considered a link

- Picks up new grammar with fixes
- Updates our document link provider to also not consider these as link
2022-05-12 19:35:36 -07:00
Matt Bierner a075453e55 Clean up the markdown document link provider tests (#149405)
- Use `joinLines` instead of
- Inline document text
- Always use `example.com`
- Move issue numbers into test titles
- Clean up text
2022-05-12 16:01:51 -07:00
Matt Bierner 5485b8e215 Include " and '/' as puctuators for slugify (#149404)
We already include `'` and `/` makes sense to treat as a puctuator too for titles such as `# do A / B`
2022-05-12 15:56:25 -07:00
Matt Bierner 4923404e98 Don't include leading @ in JS/TS completion word range (#149400)
Fixes #149385
2022-05-12 15:22:18 -07:00
Matt Bierner 67014adc30 Remove the textDocumentNotebook API proposal (#149277)
* Remove the textDocumentNotebook API proposal

All consumers have now been migrated off of this proposal, so it is safe to remove from our code

* Remove deprecated api usage from test
2022-05-12 08:59:11 +02:00
Matt Bierner 93d046904e Pick up TS 4.7 RC (#149301)
Also picks up new TS nightly version for building VS Code
2022-05-11 17:34:23 -07:00
Ladislau Szomoru 2a9f19d36f Engineering - create pull request pipeline (#149171) 2022-05-11 03:08:54 -07:00
Joyce Er c5da5332d5 git: validate URI for clone command (#149180)
Co-authored-by: Ladislau Szomoru <3372902+lszomoru@users.noreply.github.com>
2022-05-10 11:32:02 -07:00
Matt Bierner 9e42783398 Don't repeat markdown link validation (#149169)
We currently validate each link in a markdown file individually. This means that if there are multiple links to the same file, we check if that file exists multiple times

With this change, we instead will check that the file exists once and then use this to add diagnostics for all the links to it. This is done by introducing a new `FileLinkMap` which maps file paths to links within that file
2022-05-10 09:14:40 -07:00
Remco Haszing a9fc85ff47 Specify tsconfig.tsbuildinfo is json (#149065) 2022-05-10 08:59:40 -07:00
Ladislau Szomoru b44e3caa96 Git - branch prefix + random name generation (#149069) 2022-05-10 15:14:52 +00:00