Fixes#155552
For lists, the outer ul/ol always has the same source line as the first element in the list. We should prefer using the first element in the list when highlighting the active line
This also fixes a bug where scroll sync would stop working if you added lines to the doc. This was caused by `lineCount` getting out of sync as the document is being updated. I've removed this state and made the reveal logic more robust instead
* Move attachment out of custom metadata, prep for attachment clean up in diff editor
* recover attachments from dirty notebook document
* Allow metadata to be restored when content changed/reverted in nb diff editor
* add `WorkspaceEditMetadata` and use it for `applyEdit`,
https://github.com/microsoft/vscode/issues/112109
* fix compilo in tests
* workspace edits from updating paths are marked as refactoring fyi @mjbvz
* Rework how markdown server works with documents
This rewrites how the markdown server works with documents. The goal is to better handle switching between in-memory versions of a doc (from `TextDocument`) and versions of the same doc on disk. From the markdown service's POV, there is only one type of document
As part of this, I've also adopted the newest markdown language service version
* Bump package-lock versions
* Remove vscode-notebook-tests in favor of an .ipynb in vscode-smoketest-express
* Update build folder
* Add build task to correct platform
* Build for smoke tests on other platforms
* Fix repo url and remove comment
* Just -media?
* Update darwin/win32 as well
* Initial contents for JavaScript walkthrough.
* Just suggest a `.js` file.
* Switch the walkthrough to be a Node.js walkthrough.
* Remove leftover file from HTML walkthrough.
* Add basic detection mechanism for node.
* Don't check for a Node install until the user runs debug.
* Add "learn more" link.
* Some assets.
* Remove "run" section.
* Add a "try debugging anyway" option just in case.
* Remove "view terminal" command in run & debug.
* More copy.
* Remove unused command.
* Update icon and themed walkthrough SVGs
* Default to not showing the extension.
* Replace icon
* Delete TODO.md
* jsWelcome -> nodejsWelcome
Co-authored-by: David Dossett <ddossett@microsoft.com>
Co-authored-by: Matt Bierner <matb@microsoft.com>
* Compress notebook output streams before rendering
* OOps
* Combine the buffers manually
* Address code review
* oops
* Fixes
* We can have multiple stream mimes in an output
* oops
For #147248
When stepping through the liveshare code, we figured out they do not appear to be using `save`, `saveAs`, or `backup` (they return empty results for these)
This PR removes this part of the proposal so we can track just the parts of the api that they are using
* cache and cleaner complete, needs debounce
* minor renaming and reformatting
* bugfix for paste into new cell
* cleaning functionality complete
* refer to metadata as copy of current cell's
* check undef before reading from cache
* working state, pending cache restructure
* dots -> brackets
* pre-class refactor
* massive cleaner refactor
* cache typing, closed nb check, workspaceEdit only if metadata is changed
* undefined access fix
* proper debouncer
* get it up to work again
* no need to loop
* cell metadata uri parsing regression
* diagnostic
* Show diagnostics on document open
* transfer cache before file renames
* disable word wrap in notebook diff editor
* Avoid early notebook cell metadata deep clone
* No special case empty cell
* rename
* better naming
* Quick fix for invalid image attachment
* cleanup
* Add code action metadata
Co-authored-by: rebornix <penn.lv@gmail.com>
For #159805
This splits the markdown server into two main functions:
- `startVsCodeServer` which assumes the client can implement all the functionality of VS Code. It is not specific to VS Code however, the client just need to implement the custom messages that VS Code does
- `startServer` which lets you pass in your own implementation of the parser and workspace. A consumer of the server can then use this to have their own custom server implementation, which might use normal node apis to read files