Commit Graph

832 Commits

Author SHA1 Message Date
Henning Dieterichs a9f0f574fc adds proposed createQuickDiffInformation API, adopts it in markdown editor. (#323470)
* adds proposed createQuickDiffInformation API, adopts it in markdown editor.

* Extends textEditorDiffInformation proposal instead of having new quickDiff proposal
2026-06-29 16:37:26 +00:00
Henning Dieterichs d56b538686 Updates markdown editor & implements code block syntax highlighting 2026-06-16 23:46:07 +02:00
Matt Bierner 3dbb91368e Update caller 2026-06-12 08:49:16 -07:00
Henning Dieterichs 5286e6ed9e Fixes builtin markdown editor paths 2026-06-10 17:58:14 +02:00
Henning Dieterichs ffd6d6e703 Fixes CI 2026-06-09 09:49:57 +02:00
Henning Dieterichs 58c0981e26 Registers @vscode/markdown-editor in markdown-language-features extension 2026-06-09 09:49:57 +02:00
Matt Bierner 4eee2b2f6d Pass along correct lsp type
Fixes #298733
2026-06-04 09:31:54 -07:00
dileepyavan ca425775e4 Revert "Optimize shared built-in extension dependencies (#318045)" (#319774)
This reverts commit 26e580781a.
2026-06-03 17:21:27 +00:00
Dmitriy Vasyura 26e580781a Optimize shared built-in extension dependencies (#318045) 2026-06-03 08:49:40 +00:00
Dmitriy Vasyura 92fe1dc89b Clear timeouts/intervals on dispose in extensions (#319125)
* Clear timeouts/intervals on dispose in chat extension

* Revert uneeded change

Co-authored-by: Copilot <copilot@github.com>

* Revert unneeded change.

* Dispose timers

Co-authored-by: Copilot <copilot@github.com>

* Type fix

* Clear timeouts/intervals on dispose in extensions

---------

Co-authored-by: Copilot <copilot@github.com>
2026-05-30 12:19:14 +00:00
Matt Bierner f4c17b347c Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-05-21 13:03:53 -07:00
Matt Bierner bed9e7518b Show a warning when showing the rendered markdown diff
Our current implementation has some bugs that can hide changes. However even after fixing these, I'm not 100% confident a unexpected change wont sneak through. Best to make users aware of this while also trying to prevent this
2026-05-21 11:43:57 -07:00
Matt Bierner 42a80c7cbe Merge pull request #317459 from mjbvz/dev/mjbvz/successful-roundworm
Fix some bugs and clean up how markdown change indicators are rendered
2026-05-19 23:04:57 -07:00
Matt Bierner cc02f7d4ce Fix some bugs and clean up how markdown change indicators are rendered 2026-05-19 22:23:55 -07:00
Matt Bierner 4d8a4fdb18 Fix a few simple anys in extensions 2026-05-19 15:38:59 -07:00
Matt Bierner 8bc23c9116 Aligning more markdown wording and UI
- Use `frontmatter` (one word)

- Align  `Show source` icon and text with the reopen with

- Make the `Open preview` in explorer use `reopen with` instead so you can nicely toggle the opened preview
2026-05-15 10:53:34 -07:00
Matt Bierner 719badd255 Merge pull request #316329 from microsoft/dev/mjbvz/profitable-marmot
Let markdown preview scripts mark themselves as modules
2026-05-13 16:09:58 -07:00
Matt Bierner 421cab3b7f Let markdown preview scripts mark themselves as modules
Fixes #316328
2026-05-13 15:42:00 -07:00
Matt Bierner 268eaf471d Add title and context menu for frontmatter in markdown preview
Follow up on #316140

Makes it easier to discover what the table is and hide it
2026-05-13 13:43:05 -07:00
Matt Bierner 06115d9e8f Add improved markdown front matter rendering
Fixes #316140

Let's try with `table` as the default initially but we can switch to `hide` is we prefer
2026-05-12 16:33:15 -07:00
Matt Bierner f856c4c486 Various improvements and fixes for markdown diff rendering
For  #315174

Adding better inline diff indicators
2026-05-08 19:10:55 -07:00
Matt Bierner 962c0a02b8 Use a broadcast channel for md preview diff scroll sync
This makes scroll sync faster by using a broadcast channel instead of the normal vscode webview api. This means the two webviews can communicate with each other directly instead of having to go through the extension host and renderer each time
2026-05-07 14:41:06 -07:00
Matt Bierner 240f639bbb Add inner highlighting support in md diff preview 2026-05-07 10:14:44 -07:00
Matt Bierner fbdf54506e Add document diff api proposal
This adds a propose api for computing the diff between two files. Custom diff editors can use this to make sure they have the same diffs that VS Code would use in it's built-in diff editor
2026-05-07 00:16:39 -07:00
Matt Bierner 9a6cabf884 Fix some bugs around preserving location when switching current tab to md preview 2026-05-05 08:21:16 -07:00
Matt Bierner c2604688bc Merge branch 'main' into dev/mjbvz/comfortable-baboon 2026-05-04 22:29:22 -07:00
Matt Bierner 7c8e7a3693 Naming 2026-05-01 15:47:16 -07:00
Matt Bierner 7e3a9f8165 Add basic support for custom diff editors
For #138525
Fixes #298924

Markdown logic is a bit rough still but basics work

Co-authored-by: Copilot <copilot@github.com>
2026-05-01 15:44:27 -07:00
Matt Bierner ff66ce6441 Merge branch 'main' into fix/markdown-preview-scroll-sync-regressions 2026-05-01 15:22:45 -07:00
Matt Bierner 7b9366db79 Make it easy to switch current md doc between preview and edit mode
Fixes #312425

Also adds a toggle preview command
2026-04-29 21:19:08 -07:00
angan dcd26d5716 markdown scrolling preview no longer jumpy 2026-04-23 16:14:30 -04:00
AshtonYoon 611bf74afd markdown: fix scroll sync regressions introduced in #287050
Two regressions from the merge of #287050:

1. preview.ts: The merge retained `this.#isScrolling = false` inside
   the early-return guard of `scrollTo()`, which was intentionally
   removed in the original PR. This resets the timer-based flag on
   the very first forward-sync call, allowing subsequent editor scroll
   events to re-trigger forward sync while reverse sync is in
   progress, causing the editor to jump back up.

2. index.ts: The PR converted `onUpdateView` from a decrement-counter
   to a timer-based approach but left initialization and resize
   handlers still using `scrollDisabledCount += 1` without a
   corresponding timer reset. The old scroll handler decremented the
   counter naturally; the new handler only returns early. As a result,
   after page load `scrollDisabledCount` stays at 1 indefinitely,
   blocking all preview-to-editor sync until the user scrolls the
   editor once.

Fixes:
- Remove the erroneous `this.#isScrolling = false` from scrollTo()
- Apply the same timer-reset pattern (200ms) to initialization and
  resize handlers so scrollDisabledCount is always auto-cleared

Fixes #307762
2026-04-04 10:14:34 +09:00
Matt Bierner 87d56f7104 Merge pull request #305550 from mjbvz/dev/mjbvz/tense-dragon
Use `areUrisEqual` helper for better uri checks
2026-03-27 01:01:26 -07:00
Matt Bierner bd5b480c23 Use areUrisEqual helper for better uri checks 2026-03-27 00:42:39 -07:00
Matt Bierner 5f966ed2ed Also default to treating macos as case insensitive for md file checks 2026-03-27 00:38:30 -07:00
Matt Bierner 243bce7593 Merge branch 'main' into fix/janky-scrolling-in-markdown-preview 2026-03-26 15:14:38 -07:00
Matt Bierner deda22fcab Merge pull request #300674 from mjbvz/dev/mjbvz/teenage-gamefowl
Experiment with switching markdown extension to use native privates
2026-03-11 01:10:53 -07:00
Matt Bierner 7df46143a1 Experiment with switching markdown extension to use native privates
Let's try this out with one extension to start
2026-03-10 23:13:16 -07:00
Matt Bierner a04eb6787a Merge pull request #296821 from tamuratak/make_markdown_range_link_work
markdown-language-features: enhance document link handling with improved URI parsing and selection
2026-03-10 23:02:52 -07:00
Ashton Yoon 1be6ff2ae9 Merge branch 'main' into fix/janky-scrolling-in-markdown-preview 2026-03-11 13:46:36 +09:00
Matt Bierner 46af82816c Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-03-10 20:54:15 -07:00
Matt Bierner 909a106725 Use case insentive file uri compare in md extension
For #265277
2026-03-10 19:27:33 -07:00
Takashi Tamura 0e3178d4be Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-23 06:58:44 +09:00
Takashi Tamura dc9e5e1625 Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-23 06:56:55 +09:00
Takashi Tamura 3017b9d709 Update extensions/markdown-language-features/src/util/openDocumentLink.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-23 06:51:58 +09:00
Takashi Tamura d00bde0b39 markdown-language-features: enhance document link handling with improved URI parsing and selection 2026-02-22 20:26:37 +09:00
Matt Bierner 37cdd0eb43 Fixing errors 2026-02-12 12:43:36 -08:00
Matt Bierner 5d33f345e1 Merge branch 'main' into dev/mjbvz/legitimate-squirrel 2026-02-12 12:37:14 -08:00
Paul 12bce8da5a Agent skills management UX and file support (#287201) 2026-01-16 05:46:36 +11:00
AshtonYoon 8cfe3492f9 markdown: fix janky scrolling in preview with code blocks
Fixes #278930

This commit fixes the scroll synchronization issues between the markdown
editor and preview when scrolling through code blocks:

1. **Code block line tracking**: Added endLine calculation for fenced
   code blocks by counting newlines, enabling accurate line-to-position
   mapping within multi-line code blocks.

2. **Padding-aware scrolling**: Implemented getContentBounds() to
   calculate scroll positions excluding padding, preventing jumps when
   scrolling through code blocks with padding.

3. **Scroll loop prevention**: Changed scroll disable flags from counters
   to timer-based booleans (50ms) to prevent infinite sync loops while
   maintaining smooth bidirectional synchronization.

The fix ensures smooth scrolling through code blocks without jumping or
stuttering in both directions (editor ↔ preview).
2026-01-12 12:39:02 +09:00