@codingame/monaco-vscode-markdown-language-features-default-extension 1.82.6 → 1.83.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index2.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { registerExtension } from 'vscode/extensions';
2
2
 
3
- var manifest = {name:"markdown-language-features",displayName:"Markdown Language Features",description:"Provides rich language support for Markdown.",version:"1.0.0",icon:"icon.png",publisher:"vscode",license:"MIT",aiKey:"0c6ae279ed8443289764825290e4f9e2-1a736e7c-1324-4338-be46-fc2a58ae4d14-7255",engines:{vscode:"^1.70.0"},main:undefined,browser:"./dist/browser/extension",categories:["Programming Languages"],enabledApiProposals:["documentPaste","dropMetadata"],activationEvents:["onLanguage:markdown","onCommand:markdown.api.render","onCommand:markdown.api.reloadPlugins","onWebviewPanel:markdown.preview"],capabilities:{virtualWorkspaces:true,untrustedWorkspaces:{supported:"limited",description:"Required for loading styles configured in the workspace.",restrictedConfigurations:["markdown.styles"]}},contributes:{notebookRenderer:[{id:"vscode.markdown-it-renderer",displayName:"Markdown it renderer",entrypoint:"./notebook-out/index.js",mimeTypes:["text/markdown","text/latex","text/x-css","text/x-html","text/x-json","text/x-typescript","text/x-abap","text/x-apex","text/x-azcli","text/x-bat","text/x-cameligo","text/x-clojure","text/x-coffee","text/x-cpp","text/x-csharp","text/x-csp","text/x-css","text/x-dart","text/x-dockerfile","text/x-ecl","text/x-fsharp","text/x-go","text/x-graphql","text/x-handlebars","text/x-hcl","text/x-html","text/x-ini","text/x-java","text/x-javascript","text/x-julia","text/x-kotlin","text/x-less","text/x-lexon","text/x-lua","text/x-m3","text/x-markdown","text/x-mips","text/x-msdax","text/x-mysql","text/x-objective-c/objective","text/x-pascal","text/x-pascaligo","text/x-perl","text/x-pgsql","text/x-php","text/x-postiats","text/x-powerquery","text/x-powershell","text/x-pug","text/x-python","text/x-r","text/x-razor","text/x-redis","text/x-redshift","text/x-restructuredtext","text/x-ruby","text/x-rust","text/x-sb","text/x-scala","text/x-scheme","text/x-scss","text/x-shell","text/x-solidity","text/x-sophia","text/x-sql","text/x-st","text/x-swift","text/x-systemverilog","text/x-tcl","text/x-twig","text/x-typescript","text/x-vb","text/x-xml","text/x-yaml","application/json"]}],commands:[{command:"_markdown.copyImage",title:"Copy Image",category:"Markdown"},{command:"markdown.showPreview",title:"Open Preview",category:"Markdown",icon:{light:"./media/preview-light.svg",dark:"./media/preview-dark.svg"}},{command:"markdown.showPreviewToSide",title:"Open Preview to the Side",category:"Markdown",icon:"$(open-preview)"},{command:"markdown.showLockedPreviewToSide",title:"Open Locked Preview to the Side",category:"Markdown",icon:"$(open-preview)"},{command:"markdown.showSource",title:"Show Source",category:"Markdown",icon:"$(go-to-file)"},{command:"markdown.showPreviewSecuritySelector",title:"Change Preview Security Settings",category:"Markdown"},{command:"markdown.preview.refresh",title:"Refresh Preview",category:"Markdown"},{command:"markdown.preview.toggleLock",title:"Toggle Preview Locking",category:"Markdown"},{command:"markdown.findAllFileReferences",title:"Find File References",category:"Markdown"},{command:"markdown.editor.insertLinkFromWorkspace",title:"Insert Link to File in Workspace",category:"Markdown",enablement:"editorLangId == markdown && !activeEditorIsReadonly"},{command:"markdown.editor.insertImageFromWorkspace",title:"Insert Image from Workspace",category:"Markdown",enablement:"editorLangId == markdown && !activeEditorIsReadonly"}],menus:{"webview/context":[{command:"_markdown.copyImage",when:"webviewId == 'markdown.preview' && webviewSection == 'image'"}],"editor/title":[{command:"markdown.showPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused && !hasCustomMarkdownPreview",alt:"markdown.showPreview",group:"navigation"},{command:"markdown.showSource",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"navigation"},{command:"markdown.preview.refresh",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"},{command:"markdown.preview.toggleLock",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"},{command:"markdown.showPreviewSecuritySelector",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"}],"explorer/context":[{command:"markdown.showPreview",when:"resourceLangId == markdown && !hasCustomMarkdownPreview",group:"navigation"},{command:"markdown.findAllFileReferences",when:"resourceLangId == markdown",group:"4_search"}],"editor/title/context":[{command:"markdown.showPreview",when:"resourceLangId == markdown && !hasCustomMarkdownPreview",group:"1_open"},{command:"markdown.findAllFileReferences",when:"resourceLangId == markdown"}],commandPalette:[{command:"_markdown.copyImage",when:"false"},{command:"markdown.showPreview",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showLockedPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showSource",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"navigation"},{command:"markdown.showPreviewSecuritySelector",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.showPreviewSecuritySelector",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.preview.toggleLock",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.preview.refresh",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.preview.refresh",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.findAllFileReferences",when:"editorLangId == markdown"}]},keybindings:[{command:"markdown.showPreview",key:"shift+ctrl+v",mac:"shift+cmd+v",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.showPreviewToSide",key:"ctrl+k v",mac:"cmd+k v",when:"editorLangId == markdown && !notebookEditorFocused"}],configuration:{type:"object",title:"Markdown",order:20,properties:{"markdown.styles":{type:"array",items:{type:"string"},"default":[],description:"A list of URLs or local paths to CSS style sheets to use from the Markdown preview. Relative paths are interpreted relative to the folder open in the Explorer. If there is no open folder, they are interpreted relative to the location of the Markdown file. All '\\' need to be written as '\\\\'.",scope:"resource"},"markdown.preview.breaks":{type:"boolean","default":false,description:"Sets how line-breaks are rendered in the Markdown preview. Setting it to 'true' creates a <br> for newlines inside paragraphs.",scope:"resource"},"markdown.preview.linkify":{type:"boolean","default":true,description:"Convert URL-like text to links in the Markdown preview.",scope:"resource"},"markdown.preview.typographer":{type:"boolean","default":false,description:"Enable some language-neutral replacement and quotes beautification in the Markdown preview.",scope:"resource"},"markdown.preview.fontFamily":{type:"string","default":"-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', system-ui, 'Ubuntu', 'Droid Sans', sans-serif",description:"Controls the font family used in the Markdown preview.",scope:"resource"},"markdown.preview.fontSize":{type:"number","default":14,description:"Controls the font size in pixels used in the Markdown preview.",scope:"resource"},"markdown.preview.lineHeight":{type:"number","default":1.6,description:"Controls the line height used in the Markdown preview. This number is relative to the font size.",scope:"resource"},"markdown.preview.scrollPreviewWithEditor":{type:"boolean","default":true,description:"When a Markdown editor is scrolled, update the view of the preview.",scope:"resource"},"markdown.preview.markEditorSelection":{type:"boolean","default":true,description:"Mark the current editor selection in the Markdown preview.",scope:"resource"},"markdown.preview.scrollEditorWithPreview":{type:"boolean","default":true,description:"When a Markdown preview is scrolled, update the view of the editor.",scope:"resource"},"markdown.preview.doubleClickToSwitchToEditor":{type:"boolean","default":true,description:"Double-click in the Markdown preview to switch to the editor.",scope:"resource"},"markdown.preview.openMarkdownLinks":{type:"string","default":"inPreview",description:"Controls how links to other Markdown files in the Markdown preview should be opened.",scope:"resource","enum":["inPreview","inEditor"],enumDescriptions:["Try to open links in the Markdown preview.","Try to open links in the editor."]},"markdown.links.openLocation":{type:"string","default":"currentGroup",description:"Controls where links in Markdown files should be opened.",scope:"resource","enum":["currentGroup","beside"],enumDescriptions:["Open links in the active editor group.","Open links beside the active editor."]},"markdown.suggest.paths.enabled":{type:"boolean","default":true,description:"Enable path suggestions while writing links in Markdown files.",scope:"resource"},"markdown.suggest.paths.includeWorkspaceHeaderCompletions":{type:"string","default":"onDoubleHash",scope:"resource",markdownDescription:"Enable suggestions for headers in other Markdown files in the current workspace. Accepting one of these suggestions inserts the full path to header in that file, for example: `[link text](/path/to/file.md#header)`.","enum":["never","onDoubleHash","onSingleOrDoubleHash"],markdownEnumDescriptions:["Disable workspace header suggestions.","Enable workspace header suggestions after typing `##` in a path, for example: `[link text](##`.","Enable workspace header suggestions after typing either `##` or `#` in a path, for example: `[link text](#` or `[link text](##`."]},"markdown.trace.extension":{type:"string","enum":["off","verbose"],"default":"off",description:"Enable debug logging for the Markdown extension.",scope:"window"},"markdown.trace.server":{type:"string",scope:"window","enum":["off","messages","verbose"],"default":"off",description:"Traces the communication between VS Code and the Markdown language server."},"markdown.server.log":{type:"string",scope:"window","enum":["off","debug","trace"],"default":"off",description:"Controls the logging level of the Markdown language server."},"markdown.editor.drop.enabled":{type:"boolean","default":true,markdownDescription:"Enable dropping files into a Markdown editor while holding Shift. Requires enabling `#editor.dropIntoEditor.enabled#`.",scope:"resource"},"markdown.editor.drop.copyIntoWorkspace":{type:"string",markdownDescription:"Controls if files outside of the workspace that are dropped into a Markdown editor should be copied into the workspace.\n\nUse `#markdown.copyFiles.destination#` to configure where copied dropped files should be created","default":"mediaFiles","enum":["mediaFiles","never"],markdownEnumDescriptions:["Try to copy external image and video files into the workspace.","Do not copy external files into the workspace."]},"markdown.editor.filePaste.enabled":{type:"boolean",scope:"resource",markdownDescription:"Enable pasting files into a Markdown editor to create Markdown links. Requires enabling `#editor.pasteAs.enabled#`.","default":true},"markdown.editor.filePaste.copyIntoWorkspace":{type:"string",markdownDescription:"Controls if files outside of the workspace that are pasted into a Markdown editor should be copied into the workspace.\n\nUse `#markdown.copyFiles.destination#` to configure where copied files should be created.","default":"mediaFiles","enum":["mediaFiles","never"],markdownEnumDescriptions:["Try to copy external image and video files into the workspace.","Do not copy external files into the workspace."]},"markdown.editor.pasteUrlAsFormattedLink.enabled":{type:"string",scope:"resource",markdownDescription:"Controls how a Markdown link is created when a URL is pasted into the Markdown editor. Requires enabling `#editor.pasteAs.enabled#`.","default":"never","enum":["always","smart","never"],markdownEnumDescriptions:["Always creates a Markdown link when a URL is pasted into the Markdown editor.","Smartly avoids creating a Markdown link in specific cases, such as within code brackets or inside an existing Markdown link.","Never creates a Markdown link when a URL is pasted into the Markdown editor."]},"markdown.validate.enabled":{type:"boolean",scope:"resource",description:"Enable all error reporting in Markdown files.","default":false},"markdown.validate.referenceLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate reference links in Markdown files, for example: `[link][ref]`. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fragmentLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate fragment links to headers in the current Markdown file, for example: `[link](#header)`. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fileLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate links to other files in Markdown files, for example `[link](/path/to/file.md)`. This checks that the target files exists. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fileLinks.markdownFragmentLinks":{type:"string",scope:"resource",markdownDescription:"Validate the fragment part of links to headers in other files in Markdown files, for example: `[link](/path/to/file.md#header)`. Inherits the setting value from `#markdown.validate.fragmentLinks.enabled#` by default.","default":"inherit","enum":["inherit","ignore","warning","error"]},"markdown.validate.ignoredLinks":{type:"array",scope:"resource",markdownDescription:"Configure links that should not be validated. For example adding `/about` would not validate the link `[about](/about)`, while the glob `/assets/**/*.svg` would let you skip validation for any link to `.svg` files under the `assets` directory.",items:{type:"string"}},"markdown.validate.unusedLinkDefinitions.enabled":{type:"string",scope:"resource",markdownDescription:"Validate link definitions that are unused in the current file.","default":"hint","enum":["ignore","hint","warning","error"]},"markdown.validate.duplicateLinkDefinitions.enabled":{type:"string",scope:"resource",markdownDescription:"Validate duplicated definitions in the current file.","default":"warning","enum":["ignore","warning","error"]},"markdown.updateLinksOnFileMove.enabled":{type:"string","enum":["prompt","always","never"],markdownEnumDescriptions:["Prompt on each file move.","Always update links automatically.","Never try to update link and don't prompt."],"default":"never",markdownDescription:"Try to update links in Markdown files when a file is renamed/moved in the workspace. Use `#markdown.updateLinksOnFileMove.include#` to configure which files trigger link updates.",scope:"window"},"markdown.updateLinksOnFileMove.include":{type:"array",markdownDescription:"Glob patterns that specifies files that trigger automatic link updates. See `#markdown.updateLinksOnFileMove.enabled#` for details about this feature.",scope:"window",items:{type:"string",description:"The glob pattern to match file paths against. Set to true to enable the pattern."},"default":["**/*.{md,mkd,mdwn,mdown,markdown,markdn,mdtxt,mdtext,workbook}","**/*.{jpg,jpe,jpeg,png,bmp,gif,ico,webp,avif,tiff,svg,mp4}"]},"markdown.updateLinksOnFileMove.enableForDirectories":{type:"boolean","default":true,description:"Enable updating links when a directory is moved or renamed in the workspace.",scope:"window"},"markdown.occurrencesHighlight.enabled":{type:"boolean","default":false,description:"Enable highlighting link occurrences in the current document.",scope:"resource"},"markdown.copyFiles.destination":{type:"object",markdownDescription:"Defines where files copied created by drop or paste should be created. This is a map from globs that match on the Markdown document to destinations.\n\nThe destinations may use the following variables:\n\n- `${documentFileName}` — The full filename of the Markdown document, for example: `readme.md`.\n- `${documentBaseName}` — The basename of Markdown document, for example: `readme`.\n- `${documentExtName}` — The extension of the Markdown document, for example: `md`.\n- `${documentDirName}` — The name of the Markdown document's parent directory.\n- `${documentWorkspaceFolder}` — The workspace folder for the Markdown document, for example: `/Users/me/myProject`. This is the same as `${documentDirName}` if the file is not part of a workspace.\n- `${fileName}` — The file name of the dropped file, for example: `image.png`.",additionalProperties:{type:"string"}},"markdown.copyFiles.overwriteBehavior":{type:"string",markdownDescription:"Controls if files created by drop or paste should overwrite existing files.","default":"nameIncrementally","enum":["nameIncrementally","overwrite"],markdownEnumDescriptions:["If a file with the same name already exists, append a number to the file name, for example: `image.png` becomes `image-1.png`.","If a file with the same name already exists, overwrite it."]},"markdown.preferredMdPathExtensionStyle":{type:"string","default":"auto",markdownDescription:"Controls if file extensions (e.g. `.md`) are added or not for links to Markdown files. This setting is used when file paths are added by tooling such as path completions or file renames.","enum":["auto","includeExtension","removeExtension"],markdownEnumDescriptions:["For existing paths, try to maintain the file extension style. For new paths, add file extensions.","Prefer including the file extension. For example, path completions to a file named `file.md` will insert `file.md`.","Prefer removing the file extension. For example, path completions to a file named `file.md` will insert `file` without the `.md`."]}}},configurationDefaults:{"[markdown]":{"editor.wordWrap":"on","editor.quickSuggestions":{comments:"off",strings:"off",other:"off"}}},jsonValidation:[{fileMatch:"package.json",url:"./schemas/package.schema.json"}],"markdown.previewStyles":["./media/markdown.css","./media/highlight.css"],"markdown.previewScripts":["./media/index.js"],customEditors:[{viewType:"vscode.markdown.preview.editor",displayName:"Markdown Preview",priority:"option",selector:[{filenamePattern:"*.md"}]}]},scripts:{compile:"gulp compile-extension:markdown-language-features-languageService && gulp compile-extension:markdown-language-features-server && gulp compile-extension:markdown-language-features && npm run build-preview && npm run build-notebook",watch:"npm run build-preview && gulp watch-extension:markdown-language-features watch-extension:markdown-language-features-languageService watch-extension:markdown-language-features-server","vscode:prepublish":"npm run build-ext && npm run build-preview","build-ext":"node ../../node_modules/gulp/bin/gulp.js --gulpfile ../../build/gulpfile.extensions.js compile-extension:markdown-language-features ./tsconfig.json","build-notebook":"node ./esbuild-notebook","build-preview":"node ./esbuild-preview","compile-web":"npx webpack-cli --config extension-browser.webpack.config --mode none","watch-web":"npx webpack-cli --config extension-browser.webpack.config --mode none --watch --info-verbosity verbose"},dependencies:{"@vscode/extension-telemetry":"^0.8.4",dompurify:"^3.0.5","highlight.js":"^11.8.0","markdown-it":"^12.3.2","markdown-it-front-matter":"^0.2.1",morphdom:"^2.6.1",picomatch:"^2.3.1","vscode-languageclient":"^8.0.2","vscode-uri":"^3.0.3"},devDependencies:{"@types/dompurify":"^3.0.2","@types/lodash.throttle":"^4.1.3","@types/markdown-it":"12.2.3","@types/picomatch":"^2.3.0","@types/vscode-notebook-renderer":"^1.60.0","@types/vscode-webview":"^1.57.0","lodash.throttle":"^4.1.1","vscode-languageserver-types":"^3.17.2","vscode-markdown-languageservice":"^0.3.0-alpha.3"},repository:{type:"git",url:"https://github.com/microsoft/vscode.git"}};
3
+ var manifest = {name:"markdown-language-features",displayName:"Markdown Language Features",description:"Provides rich language support for Markdown.",version:"1.0.0",icon:"icon.png",publisher:"vscode",license:"MIT",aiKey:"0c6ae279ed8443289764825290e4f9e2-1a736e7c-1324-4338-be46-fc2a58ae4d14-7255",engines:{vscode:"^1.70.0"},main:undefined,browser:"./dist/browser/extension",categories:["Programming Languages"],enabledApiProposals:["documentPaste","dropMetadata"],activationEvents:["onLanguage:markdown","onCommand:markdown.api.render","onCommand:markdown.api.reloadPlugins","onWebviewPanel:markdown.preview"],capabilities:{virtualWorkspaces:true,untrustedWorkspaces:{supported:"limited",description:"Required for loading styles configured in the workspace.",restrictedConfigurations:["markdown.styles"]}},contributes:{notebookRenderer:[{id:"vscode.markdown-it-renderer",displayName:"Markdown it renderer",entrypoint:"./notebook-out/index.js",mimeTypes:["text/markdown","text/latex","text/x-css","text/x-html","text/x-json","text/x-typescript","text/x-abap","text/x-apex","text/x-azcli","text/x-bat","text/x-cameligo","text/x-clojure","text/x-coffee","text/x-cpp","text/x-csharp","text/x-csp","text/x-css","text/x-dart","text/x-dockerfile","text/x-ecl","text/x-fsharp","text/x-go","text/x-graphql","text/x-handlebars","text/x-hcl","text/x-html","text/x-ini","text/x-java","text/x-javascript","text/x-julia","text/x-kotlin","text/x-less","text/x-lexon","text/x-lua","text/x-m3","text/x-markdown","text/x-mips","text/x-msdax","text/x-mysql","text/x-objective-c/objective","text/x-pascal","text/x-pascaligo","text/x-perl","text/x-pgsql","text/x-php","text/x-postiats","text/x-powerquery","text/x-powershell","text/x-pug","text/x-python","text/x-r","text/x-razor","text/x-redis","text/x-redshift","text/x-restructuredtext","text/x-ruby","text/x-rust","text/x-sb","text/x-scala","text/x-scheme","text/x-scss","text/x-shell","text/x-solidity","text/x-sophia","text/x-sql","text/x-st","text/x-swift","text/x-systemverilog","text/x-tcl","text/x-twig","text/x-typescript","text/x-vb","text/x-xml","text/x-yaml","application/json"]}],commands:[{command:"_markdown.copyImage",title:"Copy Image",category:"Markdown"},{command:"markdown.showPreview",title:"Open Preview",category:"Markdown",icon:{light:"./media/preview-light.svg",dark:"./media/preview-dark.svg"}},{command:"markdown.showPreviewToSide",title:"Open Preview to the Side",category:"Markdown",icon:"$(open-preview)"},{command:"markdown.showLockedPreviewToSide",title:"Open Locked Preview to the Side",category:"Markdown",icon:"$(open-preview)"},{command:"markdown.showSource",title:"Show Source",category:"Markdown",icon:"$(go-to-file)"},{command:"markdown.showPreviewSecuritySelector",title:"Change Preview Security Settings",category:"Markdown"},{command:"markdown.preview.refresh",title:"Refresh Preview",category:"Markdown"},{command:"markdown.preview.toggleLock",title:"Toggle Preview Locking",category:"Markdown"},{command:"markdown.findAllFileReferences",title:"Find File References",category:"Markdown"},{command:"markdown.editor.insertLinkFromWorkspace",title:"Insert Link to File in Workspace",category:"Markdown",enablement:"editorLangId == markdown && !activeEditorIsReadonly"},{command:"markdown.editor.insertImageFromWorkspace",title:"Insert Image from Workspace",category:"Markdown",enablement:"editorLangId == markdown && !activeEditorIsReadonly"}],menus:{"webview/context":[{command:"_markdown.copyImage",when:"webviewId == 'markdown.preview' && webviewSection == 'image'"}],"editor/title":[{command:"markdown.showPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused && !hasCustomMarkdownPreview",alt:"markdown.showPreview",group:"navigation"},{command:"markdown.showSource",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"navigation"},{command:"markdown.preview.refresh",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"},{command:"markdown.preview.toggleLock",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"},{command:"markdown.showPreviewSecuritySelector",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"1_markdown"}],"explorer/context":[{command:"markdown.showPreview",when:"resourceLangId == markdown && !hasCustomMarkdownPreview",group:"navigation"},{command:"markdown.findAllFileReferences",when:"resourceLangId == markdown",group:"4_search"}],"editor/title/context":[{command:"markdown.showPreview",when:"resourceLangId == markdown && !hasCustomMarkdownPreview",group:"1_open"},{command:"markdown.findAllFileReferences",when:"resourceLangId == markdown"}],commandPalette:[{command:"_markdown.copyImage",when:"false"},{command:"markdown.showPreview",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showLockedPreviewToSide",when:"editorLangId == markdown && !notebookEditorFocused",group:"navigation"},{command:"markdown.showSource",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'",group:"navigation"},{command:"markdown.showPreviewSecuritySelector",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.showPreviewSecuritySelector",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.preview.toggleLock",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.preview.refresh",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.preview.refresh",when:"activeWebviewPanelId == 'markdown.preview' || activeCustomEditorId == 'vscode.markdown.preview.editor'"},{command:"markdown.findAllFileReferences",when:"editorLangId == markdown"}]},keybindings:[{command:"markdown.showPreview",key:"shift+ctrl+v",mac:"shift+cmd+v",when:"editorLangId == markdown && !notebookEditorFocused"},{command:"markdown.showPreviewToSide",key:"ctrl+k v",mac:"cmd+k v",when:"editorLangId == markdown && !notebookEditorFocused"}],configuration:{type:"object",title:"Markdown",order:20,properties:{"markdown.styles":{type:"array",items:{type:"string"},"default":[],description:"A list of URLs or local paths to CSS style sheets to use from the Markdown preview. Relative paths are interpreted relative to the folder open in the Explorer. If there is no open folder, they are interpreted relative to the location of the Markdown file. All '\\' need to be written as '\\\\'.",scope:"resource"},"markdown.preview.breaks":{type:"boolean","default":false,description:"Sets how line-breaks are rendered in the Markdown preview. Setting it to 'true' creates a <br> for newlines inside paragraphs.",scope:"resource"},"markdown.preview.linkify":{type:"boolean","default":true,description:"Convert URL-like text to links in the Markdown preview.",scope:"resource"},"markdown.preview.typographer":{type:"boolean","default":false,description:"Enable some language-neutral replacement and quotes beautification in the Markdown preview.",scope:"resource"},"markdown.preview.fontFamily":{type:"string","default":"-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', system-ui, 'Ubuntu', 'Droid Sans', sans-serif",description:"Controls the font family used in the Markdown preview.",scope:"resource"},"markdown.preview.fontSize":{type:"number","default":14,description:"Controls the font size in pixels used in the Markdown preview.",scope:"resource"},"markdown.preview.lineHeight":{type:"number","default":1.6,description:"Controls the line height used in the Markdown preview. This number is relative to the font size.",scope:"resource"},"markdown.preview.scrollPreviewWithEditor":{type:"boolean","default":true,description:"When a Markdown editor is scrolled, update the view of the preview.",scope:"resource"},"markdown.preview.markEditorSelection":{type:"boolean","default":true,description:"Mark the current editor selection in the Markdown preview.",scope:"resource"},"markdown.preview.scrollEditorWithPreview":{type:"boolean","default":true,description:"When a Markdown preview is scrolled, update the view of the editor.",scope:"resource"},"markdown.preview.doubleClickToSwitchToEditor":{type:"boolean","default":true,description:"Double-click in the Markdown preview to switch to the editor.",scope:"resource"},"markdown.preview.openMarkdownLinks":{type:"string","default":"inPreview",description:"Controls how links to other Markdown files in the Markdown preview should be opened.",scope:"resource","enum":["inPreview","inEditor"],enumDescriptions:["Try to open links in the Markdown preview.","Try to open links in the editor."]},"markdown.links.openLocation":{type:"string","default":"currentGroup",description:"Controls where links in Markdown files should be opened.",scope:"resource","enum":["currentGroup","beside"],enumDescriptions:["Open links in the active editor group.","Open links beside the active editor."]},"markdown.suggest.paths.enabled":{type:"boolean","default":true,description:"Enable path suggestions while writing links in Markdown files.",scope:"resource"},"markdown.suggest.paths.includeWorkspaceHeaderCompletions":{type:"string","default":"onDoubleHash",scope:"resource",markdownDescription:"Enable suggestions for headers in other Markdown files in the current workspace. Accepting one of these suggestions inserts the full path to header in that file, for example: `[link text](/path/to/file.md#header)`.","enum":["never","onDoubleHash","onSingleOrDoubleHash"],markdownEnumDescriptions:["Disable workspace header suggestions.","Enable workspace header suggestions after typing `##` in a path, for example: `[link text](##`.","Enable workspace header suggestions after typing either `##` or `#` in a path, for example: `[link text](#` or `[link text](##`."]},"markdown.trace.extension":{type:"string","enum":["off","verbose"],"default":"off",description:"Enable debug logging for the Markdown extension.",scope:"window"},"markdown.trace.server":{type:"string",scope:"window","enum":["off","messages","verbose"],"default":"off",description:"Traces the communication between VS Code and the Markdown language server."},"markdown.server.log":{type:"string",scope:"window","enum":["off","debug","trace"],"default":"off",description:"Controls the logging level of the Markdown language server."},"markdown.editor.drop.enabled":{type:"boolean","default":true,markdownDescription:"Enable dropping files into a Markdown editor while holding Shift. Requires enabling `#editor.dropIntoEditor.enabled#`.",scope:"resource"},"markdown.editor.drop.copyIntoWorkspace":{type:"string",markdownDescription:"Controls if files outside of the workspace that are dropped into a Markdown editor should be copied into the workspace.\n\nUse `#markdown.copyFiles.destination#` to configure where copied dropped files should be created","default":"mediaFiles","enum":["mediaFiles","never"],markdownEnumDescriptions:["Try to copy external image and video files into the workspace.","Do not copy external files into the workspace."]},"markdown.editor.filePaste.enabled":{type:"boolean",scope:"resource",markdownDescription:"Enable pasting files into a Markdown editor to create Markdown links. Requires enabling `#editor.pasteAs.enabled#`.","default":true},"markdown.editor.filePaste.copyIntoWorkspace":{type:"string",markdownDescription:"Controls if files outside of the workspace that are pasted into a Markdown editor should be copied into the workspace.\n\nUse `#markdown.copyFiles.destination#` to configure where copied files should be created.","default":"mediaFiles","enum":["mediaFiles","never"],markdownEnumDescriptions:["Try to copy external image and video files into the workspace.","Do not copy external files into the workspace."]},"markdown.editor.pasteUrlAsFormattedLink.enabled":{type:"string",scope:"resource",markdownDescription:"Controls how a Markdown link is created when a URL is pasted into the Markdown editor. Requires enabling `#editor.pasteAs.enabled#`.","default":"never","enum":["always","smart","never"],markdownEnumDescriptions:["Always creates a Markdown link when a URL is pasted into the Markdown editor.","Smartly avoids creating a Markdown link in specific cases, such as within code brackets or inside an existing Markdown link.","Never creates a Markdown link when a URL is pasted into the Markdown editor."]},"markdown.validate.enabled":{type:"boolean",scope:"resource",description:"Enable all error reporting in Markdown files.","default":false},"markdown.validate.referenceLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate reference links in Markdown files, for example: `[link][ref]`. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fragmentLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate fragment links to headers in the current Markdown file, for example: `[link](#header)`. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fileLinks.enabled":{type:"string",scope:"resource",markdownDescription:"Validate links to other files in Markdown files, for example `[link](/path/to/file.md)`. This checks that the target files exists. Requires enabling `#markdown.validate.enabled#`.","default":"warning","enum":["ignore","warning","error"]},"markdown.validate.fileLinks.markdownFragmentLinks":{type:"string",scope:"resource",markdownDescription:"Validate the fragment part of links to headers in other files in Markdown files, for example: `[link](/path/to/file.md#header)`. Inherits the setting value from `#markdown.validate.fragmentLinks.enabled#` by default.","default":"inherit","enum":["inherit","ignore","warning","error"]},"markdown.validate.ignoredLinks":{type:"array",scope:"resource",markdownDescription:"Configure links that should not be validated. For example adding `/about` would not validate the link `[about](/about)`, while the glob `/assets/**/*.svg` would let you skip validation for any link to `.svg` files under the `assets` directory.",items:{type:"string"}},"markdown.validate.unusedLinkDefinitions.enabled":{type:"string",scope:"resource",markdownDescription:"Validate link definitions that are unused in the current file.","default":"hint","enum":["ignore","hint","warning","error"]},"markdown.validate.duplicateLinkDefinitions.enabled":{type:"string",scope:"resource",markdownDescription:"Validate duplicated definitions in the current file.","default":"warning","enum":["ignore","warning","error"]},"markdown.updateLinksOnFileMove.enabled":{type:"string","enum":["prompt","always","never"],markdownEnumDescriptions:["Prompt on each file move.","Always update links automatically.","Never try to update link and don't prompt."],"default":"never",markdownDescription:"Try to update links in Markdown files when a file is renamed/moved in the workspace. Use `#markdown.updateLinksOnFileMove.include#` to configure which files trigger link updates.",scope:"window"},"markdown.updateLinksOnFileMove.include":{type:"array",markdownDescription:"Glob patterns that specifies files that trigger automatic link updates. See `#markdown.updateLinksOnFileMove.enabled#` for details about this feature.",scope:"window",items:{type:"string",description:"The glob pattern to match file paths against. Set to true to enable the pattern."},"default":["**/*.{md,mkd,mdwn,mdown,markdown,markdn,mdtxt,mdtext,workbook}","**/*.{jpg,jpe,jpeg,png,bmp,gif,ico,webp,avif,tiff,svg,mp4}"]},"markdown.updateLinksOnFileMove.enableForDirectories":{type:"boolean","default":true,description:"Enable updating links when a directory is moved or renamed in the workspace.",scope:"window"},"markdown.occurrencesHighlight.enabled":{type:"boolean","default":false,description:"Enable highlighting link occurrences in the current document.",scope:"resource"},"markdown.copyFiles.destination":{type:"object",markdownDescription:"Defines where files copied created by drop or paste should be created. This is a map from globs that match on the Markdown document to destinations.\n\nThe destinations may use the following variables:\n\n- `${documentFileName}` — The full filename of the Markdown document, for example: `readme.md`.\n- `${documentBaseName}` — The basename of Markdown document, for example: `readme`.\n- `${documentExtName}` — The extension of the Markdown document, for example: `md`.\n- `${documentDirName}` — The name of the Markdown document's parent directory.\n- `${documentWorkspaceFolder}` — The workspace folder for the Markdown document, for example: `/Users/me/myProject`. This is the same as `${documentDirName}` if the file is not part of a workspace.\n- `${fileName}` — The file name of the dropped file, for example: `image.png`.",additionalProperties:{type:"string"}},"markdown.copyFiles.overwriteBehavior":{type:"string",markdownDescription:"Controls if files created by drop or paste should overwrite existing files.","default":"nameIncrementally","enum":["nameIncrementally","overwrite"],markdownEnumDescriptions:["If a file with the same name already exists, append a number to the file name, for example: `image.png` becomes `image-1.png`.","If a file with the same name already exists, overwrite it."]},"markdown.preferredMdPathExtensionStyle":{type:"string","default":"auto",markdownDescription:"Controls if file extensions (e.g. `.md`) are added or not for links to Markdown files. This setting is used when file paths are added by tooling such as path completions or file renames.","enum":["auto","includeExtension","removeExtension"],markdownEnumDescriptions:["For existing paths, try to maintain the file extension style. For new paths, add file extensions.","Prefer including the file extension. For example, path completions to a file named `file.md` will insert `file.md`.","Prefer removing the file extension. For example, path completions to a file named `file.md` will insert `file` without the `.md`."]}}},configurationDefaults:{"[markdown]":{"editor.wordWrap":"on","editor.quickSuggestions":{comments:"off",strings:"off",other:"off"}}},jsonValidation:[{fileMatch:"package.json",url:"./schemas/package.schema.json"}],"markdown.previewStyles":["./media/markdown.css","./media/highlight.css"],"markdown.previewScripts":["./media/index.js"],customEditors:[{viewType:"vscode.markdown.preview.editor",displayName:"Markdown Preview",priority:"option",selector:[{filenamePattern:"*.md"}]}]},scripts:{compile:"gulp compile-extension:markdown-language-features-languageService && gulp compile-extension:markdown-language-features-server && gulp compile-extension:markdown-language-features && npm run build-preview && npm run build-notebook",watch:"npm run build-preview && gulp watch-extension:markdown-language-features watch-extension:markdown-language-features-languageService watch-extension:markdown-language-features-server","vscode:prepublish":"npm run build-ext && npm run build-preview","build-ext":"node ../../node_modules/gulp/bin/gulp.js --gulpfile ../../build/gulpfile.extensions.js compile-extension:markdown-language-features ./tsconfig.json","build-notebook":"node ./esbuild-notebook","build-preview":"node ./esbuild-preview","compile-web":"npx webpack-cli --config extension-browser.webpack.config --mode none","watch-web":"npx webpack-cli --config extension-browser.webpack.config --mode none --watch --info-verbosity verbose"},dependencies:{"@vscode/extension-telemetry":"^0.8.5",dompurify:"^3.0.5","highlight.js":"^11.8.0","markdown-it":"^12.3.2","markdown-it-front-matter":"^0.2.1",morphdom:"^2.6.1",picomatch:"^2.3.1","vscode-languageclient":"^8.0.2","vscode-uri":"^3.0.3"},devDependencies:{"@types/dompurify":"^3.0.2","@types/lodash.throttle":"^4.1.3","@types/markdown-it":"12.2.3","@types/picomatch":"^2.3.0","@types/vscode-notebook-renderer":"^1.60.0","@types/vscode-webview":"^1.57.0","lodash.throttle":"^4.1.1","vscode-languageserver-types":"^3.17.2","vscode-markdown-languageservice":"^0.3.0-alpha.3"},repository:{type:"git",url:"https://github.com/microsoft/vscode.git"}};
4
4
 
5
5
  const { registerFileUrl, whenReady } = registerExtension(manifest);
6
6
  registerFileUrl('./media/preview-light.svg', new URL('./preview-light.svg', import.meta.url).toString(), 'image/svg+xml');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-markdown-language-features-default-extension",
3
- "version": "1.82.6",
3
+ "version": "1.83.1",
4
4
  "keywords": [],
5
5
  "author": {
6
6
  "name": "CodinGame",
@@ -18,6 +18,6 @@
18
18
  "module": "index2.js",
19
19
  "types": "index.d.ts",
20
20
  "dependencies": {
21
- "vscode": "npm:@codingame/monaco-vscode-api@1.82.6"
21
+ "vscode": "npm:@codingame/monaco-vscode-api@1.83.1"
22
22
  }
23
23
  }
package/workerMain.js CHANGED
@@ -14097,23 +14097,25 @@ const linkPattern = new RegExp(
14097
14097
  /**
14098
14098
  * Matches `[text][ref]` or `[shorthand]` or `[shorthand][]`
14099
14099
  */
14100
- const referenceLinkPattern = new RegExp((0, string_1.r) `(^|[^\]\\])` + // Must not start with another bracket (workaround for lack of support for negative look behinds)
14100
+ const referenceLinkPattern = new RegExp((0, string_1.r) `(?<![\]\\])` + // Must not start with another bracket
14101
14101
  (0, string_1.r) `(?:` +
14102
- /**/ (0, string_1.r) `(?:` +
14103
- /****/ (0, string_1.r) `(` + // Start link prefix
14104
- /******/ (0, string_1.r) `!?` + // Optional image ref
14105
- /******/ (0, string_1.r) `\[((?:` + // Link text
14106
- /********/ (0, string_1.r) `\\\]|` + // escaped bracket, or...
14107
- /********/ (0, string_1.r) `[^\[\]]|` + //non bracket char, or...
14108
- /********/ (0, string_1.r) `\[[^\[\]]*\]` + // matched bracket pair
14109
- /******/ `+)*)\]` + // end link text
14110
- /******/ (0, string_1.r) `\[\s*?` + // Start of link def
14111
- /****/ (0, string_1.r) `)` + // end link prefix
14112
- /****/ (0, string_1.r) `(` +
14113
- /******/ (0, string_1.r) `[^\]]*?)\]` + //link def
14114
- /******/ (0, string_1.r) `|` +
14115
- /******/ (0, string_1.r) `\[\s*?([^\\\]]*?)\s*\])(?![\(])` +
14116
- (0, string_1.r) `)`, 'gm');
14102
+ // [text][ref] or [text][]
14103
+ /**/ (0, string_1.r) `(?<prefix>` + // Start link prefix
14104
+ /****/ (0, string_1.r) `!?` + // Optional image ref
14105
+ /****/ (0, string_1.r) `\[((?:` + // Link text
14106
+ /******/ (0, string_1.r) `\\.|` + // escaped character, or...
14107
+ /******/ (0, string_1.r) `[^\[\]\\]|` + // non bracket char, or...
14108
+ /******/ (0, string_1.r) `\[[^\[\]]*\]` + // matched bracket pair
14109
+ /****/ `)*)\]` + // end link text
14110
+ /****/ (0, string_1.r) `\[\s*` + // Start of link def
14111
+ /**/ (0, string_1.r) `)` + // end link prefix
14112
+ /**/ (0, string_1.r) `((?:[^\\\]]|\\.)*?)\]` + // link def
14113
+ /**/ (0, string_1.r) `|` +
14114
+ // [shorthand]
14115
+ /****/ (0, string_1.r) `\[\s*((?:\\.|[^\[\]])+?)\s*\]` +
14116
+ (0, string_1.r) `)` +
14117
+ (0, string_1.r) `(?![\(])`, // Must not be followed by a paren to avoid matching normal links
14118
+ 'gm');
14117
14119
  /**
14118
14120
  * Matches `<http://example.com>`
14119
14121
  */
@@ -14273,16 +14275,16 @@ class MdLinkComputer {
14273
14275
  }
14274
14276
  *#getReferenceLinksInText(document, text, startingOffset, noLinkRanges) {
14275
14277
  for (const match of text.matchAll(referenceLinkPattern)) {
14276
- const linkStartOffset = startingOffset + (match.index ?? 0) + match[1].length;
14278
+ const linkStartOffset = startingOffset + (match.index ?? 0);
14277
14279
  const linkStart = document.positionAt(linkStartOffset);
14278
14280
  if (noLinkRanges.contains(linkStart)) {
14279
14281
  continue;
14280
14282
  }
14281
14283
  let hrefStart;
14282
14284
  let hrefEnd;
14283
- let reference = match[4];
14285
+ let reference = match[3];
14284
14286
  if (reference === '') { // [ref][],
14285
- reference = match[3];
14287
+ reference = match[2].trim();
14286
14288
  if (!reference) {
14287
14289
  continue;
14288
14290
  }
@@ -14291,30 +14293,33 @@ class MdLinkComputer {
14291
14293
  hrefEnd = document.positionAt(offset + reference.length);
14292
14294
  }
14293
14295
  else if (reference) { // [text][ref]
14294
- const text = match[3];
14296
+ const text = match[2];
14295
14297
  if (!text) {
14296
14298
  // Handle the case ![][cat]
14297
- if (!match[2].startsWith('!')) {
14299
+ if (!match[0].startsWith('!')) {
14298
14300
  // Empty links are not valid
14299
14301
  continue;
14300
14302
  }
14301
14303
  }
14302
- if (!match[2].startsWith('!')) {
14304
+ if (!match[0].startsWith('!')) {
14303
14305
  // Also get links in text
14304
- yield* this.#getReferenceLinksInText(document, match[3], linkStartOffset + 1, noLinkRanges);
14306
+ yield* this.#getReferenceLinksInText(document, match[2], linkStartOffset + 1, noLinkRanges);
14305
14307
  }
14306
- const pre = match[2];
14308
+ const pre = match[1];
14307
14309
  const offset = linkStartOffset + pre.length;
14308
14310
  hrefStart = document.positionAt(offset);
14309
14311
  hrefEnd = document.positionAt(offset + reference.length);
14310
14312
  }
14311
- else if (match[5]) { // [ref]
14312
- reference = match[5];
14313
+ else if (match[4]) { // [ref]
14314
+ reference = match[4].trim();
14315
+ if (!reference) {
14316
+ continue;
14317
+ }
14313
14318
  const offset = linkStartOffset + 1;
14314
14319
  hrefStart = document.positionAt(offset);
14315
14320
  const line = (0, textDocument_1.getLine)(document, hrefStart.line);
14316
14321
  // See if link looks like link definition
14317
- if (linkStart.character === 0 && line[match[0].length - match[1].length] === ':') {
14322
+ if (linkStart.character === 0 && line[match[0].length] === ':') {
14318
14323
  continue;
14319
14324
  }
14320
14325
  // See if link looks like a checkbox
@@ -14327,7 +14332,7 @@ class MdLinkComputer {
14327
14332
  else {
14328
14333
  continue;
14329
14334
  }
14330
- const linkEnd = (0, position_1.translatePosition)(linkStart, { characterDelta: match[0].length - match[1].length });
14335
+ const linkEnd = (0, position_1.translatePosition)(linkStart, { characterDelta: match[0].length });
14331
14336
  const hrefRange = { start: hrefStart, end: hrefEnd };
14332
14337
  yield {
14333
14338
  kind: MdLinkKind.Link,
@@ -23971,7 +23976,7 @@ exports.getLinkRenameEdit = getLinkRenameEdit;
23971
23976
  Object.defineProperty(exports, "__esModule", ({ value: true }));
23972
23977
  exports.hasBalancedParens = exports.needsAngleBracketLink = exports.escapeForAngleBracketLink = void 0;
23973
23978
  function escapeForAngleBracketLink(linkText) {
23974
- return linkText.replace(/([<>])/g, '\\$1');
23979
+ return linkText.replace(/([<>])/g, '\\$1'); // CodeQL [SM02383] This escaping is done for text in an editor, not for rendered markdown.
23975
23980
  }
23976
23981
  exports.escapeForAngleBracketLink = escapeForAngleBracketLink;
23977
23982
  function needsAngleBracketLink(linkText) {
@@ -25143,6 +25148,9 @@ class MdPathCompletionProvider {
25143
25148
  }
25144
25149
  }
25145
25150
  #getPathInsertText(context, name) {
25151
+ // If the path has a literal `%` in it, we need encode it to prevent
25152
+ // it being incorrectly decoded
25153
+ name = name.replaceAll('%', '%25');
25146
25154
  if (context.kind === CompletionContextKind.HtmlAttribute) {
25147
25155
  return name
25148
25156
  .replaceAll(`"`, '&quot;')