Panda Markdown Review is a VS Code extension for reviewing Markdown and source code in a rendered, source-aware preview. It supports local Markdown comments and a complete Azure DevOps pull request workflow without adding review metadata to PR files.
Current pull request support: Azure DevOps (ADO) PR review supports Markdown and common source-code files, including C#, C/C++, TypeScript, JavaScript, Python, Java, Go, Rust, Kotlin, Ruby, PowerShell, shell, SQL, HTML, CSS, XML, YAML, and JSON. Other pull request providers such as GitHub and GitLab are not currently supported.
Feature Overview
Markdown Preview and Navigation
- Source-aware rendered preview with continuous two-way scroll synchronization.
- Heading index, comment list, and review timeline for navigating large documents.
- Mermaid rendering with an interactive zoom/pan view and element-level comment targets.
- Syntax-highlighted code blocks, local image support, and zoom controls.
- Stable source-line navigation after images and diagrams change the page layout.
Local Markdown Review
- Create comments from selected preview text or a source line.
- Store self-contained
[[CM-...]]and[[CR-...]]markers in the Markdown file. - View, edit, delete, copy, and navigate comments from the review preview.
- Drag an open comment thread by its header to keep reviewed content visible.
- Keep the source editor and rendered review aligned while reading or editing.
Azure DevOps Pull Request Review
- Open an Azure DevOps PR URL directly on its first changed reviewable file, or open a specific file URL.
- Review source code as syntax-highlighted HTML with line numbers and exact source-line selection mapping.
- Browse changed files in a native VS Code Explorer tree, with collapsible directories, new-file and rename indicators, unresolved comment counts, and active-file highlighting.
- See the total number of Active, Pending, and Won't Fix comments across every file in the pull request directly in the review toolbar, and open the all-PR comments list to switch files and focus a selected thread.
- Review added and removed source lines inline while keeping comments anchored to current-file lines, with identifiable badges on bordered comment ranges.
- Read, create, edit, reply to, delete, and set PR comments to Active, Pending, Won't Fix, or Closed. Closed comments stay hidden from the comments list.
- Filter the all-PR comments list by Active, Pending, or Won't Fix state and by author; the state filter defaults to Active.
- Send an individual review comment and its replies to Copilot Chat from the compact action beside Delete, with a prompt to implement and validate the requested change.
- Start a complete Copilot review from the Auto Review toolbar button. Panda supplies authoritative PR diffs and collects findings as unpublished comments for approval.
- Review, edit, delete, and selectively publish generated pending comments with source-line and full-line range anchors.
- Highlight comment selections and Mermaid element comments in the rendered document.
- Search users with mention autocomplete and display participant avatars.
- Switch among PR revisions while preserving revision-scoped content and comment positions; newly detected revisions appear in the dropdown without changing the displayed revision.
- For Markdown files, use Show Diff to toggle added/replaced-content highlights in the rendered review. New documents start with diff highlighting hidden. Source-code files show additions and removals inline by default.
- Navigate long pull request files from a clickable right-edge overview of changed regions, with current and base content prefetched for faster markers.
- Keep the review preview and modified side of the PR diff continuously synchronized in both directions.
- Auto-refresh comments and optionally notify when new threads or replies arrive.
- Open source-code reviews directly as target-branch diffs, with cached base content, deduplicated file discovery, non-overlapping refreshes, and bounded nearby-file prefetching.
- Search review and source previews with VS Code's native find widget, and open new review tabs in the active editor group.
- Open an editable original-to-local diff beside the review and commit changes as a new PR revision. A matching open workspace file is used directly; otherwise the extension creates a temporary file.
- Switch between the immutable Online revision and an unpublished Local draft.
PR integration currently supports Azure DevOps only. Binary and unrecognized file types are excluded from the file picker.
Quick Start
Markdown Review
Open a Markdown file and run Markdown Review from the editor context menu, Explorer context menu, or Command Palette.

Open a Pull Request
Run Markdown Review: Open Pull Request File from the Command Palette, then paste an Azure DevOps PR overview URL or a supported file URL. The review opens the requested file, or the first changed reviewable file when using an overview URL. VS Code Explorer opens Pull Request Files automatically so you can navigate the complete PR by directory.
In Pull Request Files, select any file to switch the existing review panel. Added files use a green status icon and +; renamed files use a (rename) prefix while retaining their natural filename sort order; files with active comments use a discussion icon and a compact count. An added file with comments combines both states as + N. Hover over a file for its full path and status details.

Monitor Project Pull Requests
Run Markdown Review: Monitor Project Pull Requests and paste any Azure DevOps URL containing the organization and project on first use. The monitor opens the last saved project directly on later uses; select Change project in the monitor to switch it. It lists pull requests across every repository in that project. Filter by text or select multiple repositories, authors, reviewers, states, tracking states, and interest colors; optionally hide drafts. Filter selections are saved separately for each project.
Rows identify drafts, forks, state, reviewer approval totals, all visible discussions, and highlighted active discussions without listing every reviewer. My comment is detected from Azure DevOps and cached locally. Opening a PR marks it Reviewed, which can also be toggled manually. Use Flag to cycle through yellow, red, green, hidden, and unflagged states. Hidden PRs are excluded by default; include the hidden interest state to find or restore them. Review and flag records are stored locally per project and PR.
The monitor initially loads up to 50 pull requests for each selected state. When more results are available, scrolling near the bottom loads and appends the next page. This keeps completed and abandoned PR histories from blocking the initial monitor view.
Commands
- Markdown Review - open a rendered review for a local Markdown file.
- Markdown Review: Open Pull Request File - open an Azure DevOps PR Markdown or source-code file for review.
- Markdown Review: Monitor Project Pull Requests - list and filter active pull requests across an Azure DevOps project.
- Commit PR Revision - push an edited PR source document as a new revision. This command appears in the edit-source title bar.
The first two commands are also available from Markdown editor and Explorer context menus where applicable.
PR Review Workflow
-
Run Markdown Review: Open Pull Request File.
-
Paste an Azure DevOps PR overview URL or PR file URL, for example:
https://dev.azure.com/example/project/_git/repository/pullrequest/123 -
If the URL does not identify a file, the first changed reviewable file opens automatically.
-
Authenticate if prompted. The extension first tries Git credentials, then a stored PAT, then prompts for a PAT.
-
Select text in the preview and use the context menu to create a PR comment.
-
Use Pull Request Files in VS Code Explorer to inspect the directory tree, new files, and unresolved comment counts, then select a file to switch the active review.
-
Use the revision picker to review a specific PR iteration and its anchored comments.
-
Select Auto Review to submit
#panda-reviewto Copilot Chat. Panda supplies changed-file diffs directly from Azure DevOps even when no matching repository is open. For supporting code, Copilot verifies and uses the matching repository; if required context or repository access is unavailable, it asks you to open, configure, or repair the repository before continuing. Inspect generated findings in Pending Comments, then publish selected comments to Azure DevOps. -
Open a comment and select the Copilot icon beside Delete to ask Copilot Chat to implement that thread's requested change.
-
For Markdown files, select Show Diff to turn changed-content highlights and the diff overview ruler on or off. Source-code reviews show the diff inline and do not display this button.
-
Select Source to open an original-to-local diff. If the matching repository is open in VS Code, the local file is used; otherwise an editable temporary file is created. Without write permission, the diff is read-only.
-
Use Commit PR Revision from the editable source title bar to push your changes.
The Online view always represents the selected server revision and its comments. The Local view represents unpublished edits and intentionally hides PR comment decorations.
Local Review Workflow
- Open a Markdown file and run Markdown Review.
- Navigate with the heading index, comments list, or timeline.
- Select preview text and use the context menu to add a comment.
- Edit or delete existing comments from the preview, or use the Copilot icon beside Delete to send one comment to Copilot Chat for implementation.
Settings
| Setting | Default | Description |
|---|---|---|
pandamarkdownreview.azureDevOpsPat |
Empty | Optional Azure DevOps PAT fallback. Secrets entered at a prompt are stored in VS Code secret storage. |
pandamarkdownreview.prNotifyOnIncomingComments |
true |
Show notifications for new PR threads and replies. |
pandamarkdownreview.prAutoRefreshIntervalSeconds |
15 |
Background PR comment refresh interval, with a minimum of 5 seconds. |
pandamarkdownreview.prBlockInteractionUntilLoaded |
true |
Show a loading blocker and prevent PR preview interaction until initial comments, revisions, and changed-file metadata finish loading. |
pandamarkdownreview.reviewContext |
Empty | Additional required instructions for Copilot PR reviews, such as a skill or guidance file to read. |
pandamarkdownreview.previewTheme |
dark-black |
Preview palette: dark-blue, VS Code-inspired dark-black, light, high-contrast, or custom. |
pandamarkdownreview.previewFontSize |
14 |
Base preview and comment font size in pixels, from 10 to 32. |
pandamarkdownreview.previewCustomTheme |
Dark blue palette | JSON object containing colorScheme, textColor, backgroundColor, linkColor, surfaceColor, and borderColor. |
pandamarkdownreview.logLevel |
INFO |
Output verbosity: VERBOSE, DEBUG, INFO, WARN, or ERROR. |
Appearance changes apply immediately to open reviews. Preset themes override the custom theme object but retain the configured font size. Custom colors accept six-digit hex values.
Authentication Behavior
PR mode uses this authorization order:
- Git credential store (for organization URL).
- Stored PAT (VS Code secret/config).
- Prompt for PAT if needed.
Troubleshooting Azure DevOps
Use scripts/test-pr-comments.ps1 to inspect what Azure DevOps returns for a PR file:
Example:
./scripts/test-pr-comments.ps1 -Project "Project" -Repository "Repository" -PullRequestId 123 -FilePath "/docs/design.md" -ShowRaw
The script:
- Calls PR threads API with paging.
- Filters by file path.
- Reports status/path/comment visibility reasons.
- Can validate a specific discussionId.
Development
Prerequisites: Node.js 18+, npm, and VS Code 1.90+.
npm install
npm run compile
npm test
Packaging
npm run package
npm run release:package
The VSIX is written to out/pandamarkdownreview.vsix.
Release Notes
0.4.3
- Show the complete pull request file tree as soon as discovery finishes instead of waiting for slower comment and revision hydration.
- Added diagnostic logging for pull request file discovery and Explorer publication, with failures retained at warning level.
0.4.2
- Changed the Markdown PR diff control to an opt-in Show Diff toggle so newly opened documents no longer highlight every changed region by default.
0.4.1
- Fixed right-edge diff overview alignment so multi-line markers span their full rendered changed regions.
0.4.0
- Added a project-wide Azure DevOps pull request monitor with persistent multi-select filters, personal review tracking, interest flags, and direct review opening.
- Added incremental loading for completed and abandoned pull requests, plus fork, approval, draft, state, and active-discussion indicators.
- Kept initial PR loading blocked until the complete Explorer file snapshot is ready, and restored comments to closed-by-default behavior.
0.3.12
- Fixed right-edge diff overview alignment so multi-line markers span their full rendered changed regions.
0.3.11
- Added a clickable right-edge diff overview for quickly locating changed regions in long pull request files.
- Loaded and prefetched base content in parallel so overview markers appear sooner without delaying the initial preview.
0.3.10
- Added live preview theme presets with Dark Black as the default, plus Dark Blue, Light, High Contrast, and Custom options.
- Consolidated custom preview colors into one validated JSON theme object while preserving existing appearance settings as migration input.
0.3.9
- Improved pull request opening and switching with cached content, deduplicated discovery, non-overlapping refreshes, and direct source-diff rendering.
- Added rename-aware Azure DevOps diffs and
(rename)Explorer labels without classifying renamed files as additions or changing filename sort order. - Defaulted comment filtering to Active, enabled native preview find, and opened new review tabs in the active editor group.
0.3.8
- Clarified that Copilot receives changed pull request files directly from Azure DevOps even without a local checkout.
- Require Copilot to verify and scope supporting-code review to the matching PR repository, and to stop with actionable setup guidance when required repository context is unavailable or broken.
0.3.7
- Added live preview appearance settings for font size, color scheme, text, background, links, surfaces, and borders, with a higher-contrast default link color.
- Enlarged comment dialogs and made comment and reply inputs grow with their content within viewport-aware limits.
0.3.6
- Count only Active pull request threads in toolbar totals and per-file badges while keeping Pending and Won't Fix threads visible in comment lists.
0.3.5
- Added Azure DevOps Pending and Won't Fix comment-state support alongside Active and Closed.
- Kept Active, Pending, and Won't Fix threads visible in comment lists and counts while excluding Closed threads.
- Added composable state and author filters to the all-PR comments list.
0.3.4
- Restored local View Source navigation to the original Markdown file in a standard VS Code editor.
- Added an on-demand document map for pull request Markdown previews while keeping it hidden for source-code files.
- Start document maps collapsed and place the accessible map icon beside Settings for a quieter toolbar.
0.3.3
- Maintenance release: repackaged the extension after merging upstream updates and revalidating test coverage.
0.3.2
- Prevented Mermaid modal comment popout from opening after drag-scroll/pan gestures; comments now open only on intentional click.
- Added movable comment thread dialogs that can be dragged by their header and remain within the preview viewport.
0.3.1
- Added Panda's
#panda-reviewCopilot tool and instructions for authoritative active-PR diff review, with an Auto Review toolbar action. - Added configurable review context so Copilot can follow project-specific skills or guidance during reviews.
- Added approval-based pending findings with edit, delete, selective publish, immediate post-publish cleanup, and precise source ranges.
- Corrected Azure DevOps thread line numbering and generated-comment anchors.
- Consolidated the comments-list toggle into the Active count control to reduce toolbar clutter.
- Added all-PR Active comment navigation with automatic file switching and thread focus, plus mutually exclusive Active and Pending panels.
- Refresh the revision dropdown when new PR revisions appear without switching content until the user selects one.
- Fixed pending-dialog Publish so it cannot fall through to duplicate PR comment creation and removes successful pending items immediately.
0.3.0
- Added an Active toolbar total that counts unresolved comments across every reviewable file in the pull request; local reviews continue to count only the current file.
- Improved source-code first paint by rendering the current revision immediately while target-branch content and comments hydrate concurrently.
- Prefetch up to four adjacent PR files with two concurrent requests, shared in-flight downloads, a bounded cache, and a two-minute freshness limit.
- Made Node and VS Code ambient type resolution explicit for consistent editor and command-line diagnostics.
0.2.9
- Added a compact per-comment Copilot action beside Delete for local and Azure DevOps reviews.
- Open Copilot Chat with the selected comment's file, line, status, author, content, and PR replies, plus instructions to implement and validate the change.
- Updated PR marker and selection-offset tests to match DOM-based comment decoration and precise source ranges.
0.2.8
- Moved changed-file navigation into a native Pull Request Files view in VS Code Explorer and removed the duplicate file list from the review webview.
- Open and focus the PR file tree automatically when a pull request review starts, with native expandable directories and active-file reveal.
- Preserve added-file and unresolved-comment metadata with compact status visuals: green added icons, colored discussion icons,
+, comment counts, and detailed tooltips. - Route native Explorer selections through the same revision fetch, comment refresh, local-file cleanup, and review-panel switching workflow.
0.2.7
- Made Source prefer the PR-relative file in the matching Git repository or open workspace, including repositories nested below a workspace folder.
- Keep local repository files available for editing by users and Copilot even when Azure DevOps PR push permission is unavailable.
- Track temporary edit files explicitly so cleanup never deletes a local workspace file.
0.2.6
- Added rich Azure DevOps PR review for C# and other common source-code files, with syntax highlighting, source-line mapping, inline additions and removals, and anchored code comments.
- Replaced the flat changed-file list with a searchable, collapsible directory tree that preserves folder state and shows unresolved comment counts.
- Added a
+indicator for newly added PR files and automatic opening of the first reviewable file from PR overview URLs. - Added workspace-aware source editing: matching repository files open directly in an original-to-local diff, with temporary editable files as a fallback.
- Improved code comment visibility with bordered line ranges and author badges.
- Kept Show PR Diff for rendered Markdown reviews while source-code reviews display their diff inline by default.
0.2.5
- Accept Azure DevOps PR overview URLs and show a searchable picker containing the changed Markdown files in the PR.
- Keep direct PR Markdown file URLs as the fast path with no additional selection step.
- Replace HTML export with a toolbar Markdown file selector. Single-file reviews show a disabled selector; multi-file PR reviews switch to any changed Markdown file in the same review panel.
- Reuse the existing PR review panel when Open Pull Request File is run again, including for a different PR or Markdown file.
- Highlight added and replaced current-revision lines in the review panel whenever Show PR Diff opens the synchronized source diff.
0.2.4
- Added Show PR Diff to compare the selected PR revision with the original Markdown at the PR target commit.
- Added continuous two-way source-line synchronization between the review preview and the modified side of the VS Code diff editor.
- Diff opening now waits for the modified editor and starts at the review's current visible source line.
- Added support for newly introduced PR Markdown files by comparing them against an empty original document.
- Refreshed the feature overview, PR workflow, settings, development, and troubleshooting documentation.
0.2.3
- Added PR revision picker to the toolbar: select any PR iteration to view its content and the comments that were anchored to that specific revision. Each iteration uses
$iterationIdon the Azure DevOps threads API so comment positions are always correct for the selected revision. - Added Local/Online toggle button in the PR review toolbar. Online (default) shows the selected PR revision with full comment decorations; Local shows your locally-edited draft without any comments. The review panel is never refreshed from local edits in Online mode.
- Local edits now drive a
localPreviewUpdatemessage that only updates the Local draft buffer — the Online view stays locked to the selected PR revision and is unaffected by typing in the edit source file. - Mermaid element badges are hidden in Local mode, consistent with other comment decorations.
- Fixed comments not appearing on initial PR open:
webviewReadyhandshake ensures the snapshot is re-delivered after first page load. - Fixed newly-created table-cell comments showing as block indicators immediately after creation by preserving
selectedTextthrough the snapshot rebuild cycle. - "Add Comment" context-menu item is now disabled when no text is selected.
- Fixed a webview
SyntaxErrorcaused by a\nescape inside a JS comment in the HTML template literal.
0.2.2
-
PR comment threads are now highlighted in-place using DOM-based text wrapping.
-
Fixed comments not appearing on initial PR file open via
webviewReadyhandshake. -
Newly created comments (including table-cell selections) are immediately decorated with inline text wrapping.
-
"Add Comment" disabled when no text is selected.
-
Fixed webview syntax error from
\nescape in JS comment inside template literal. -
Fixed Mermaid modal element interaction: element clicks now work consistently by debouncing modal refresh operations and re-binding click handlers after each refresh.
-
Fixed badge click handlers not working on initial modal open by deferring badge binding to refresh cycle when SVG coordinates are properly established.
-
Fixed ESC key behavior: comment editor and mermaid modal now close in layers (editor first, then modal) instead of closing simultaneously.
-
Added comprehensive INFO-level logging for modal interactions, badge binding, element clicks, and refresh operations to aid debugging.
-
Modal refresh operations now debounced to 500ms to prevent rapid successive refreshes that destroyed event listeners.
0.2.0
- Added the ability to edit a PR markdown file and commit it back as a new revision: the Source button opens an editable editor (when you have permission), and the Commit PR Revision title-bar button pushes your changes as a new PR revision.
- Toolbar now wraps cleanly and button labels no longer overflow their rectangles at smaller preview sizes.
- Consolidated the zoom controls into a compact group and removed the redundant reset button; the percentage label itself is now clickable to reset zoom.
- Scroll sync now also works with the opened PR source editor (both read-only "View Source" and editable "Edit Source"), keeping the source and preview panes aligned in both directions.
0.1.9
- Fixed PR comment markers (
[[PR-...]]) being injected inside fenced code blocks (e.g. Mermaid diagrams), which caused Mermaid parse errors. Markers are now placed on the line immediately after the closing fence.
0.1.8
- Major PR review performance upgrade: preview panel now opens immediately with a loading UI while PR file content downloads in the background.
- Reduced first-load command latency by deferring heavy markdown engine loading until first render.
- Added startup pre-activation and command-path performance logs to diagnose cold-start delays.
- Optimized PR open flow by skipping revision enumeration for default Latest mode.
- Improved perceived responsiveness by rendering markdown first, then hydrating PR comments and mention users asynchronously.
0.1.7
- Added Azure DevOps identity search and mention autocomplete for PR comments and replies.
- Added participant avatars to mention suggestions, comments, and replies.
- Display mention names while composing and submit Azure DevOps mention GUID tokens to the service.
- Made mentions atomic when deleting text to prevent partial names and broken autocomplete state.
- Added visible webview error reporting and generated-script syntax regression coverage.
- Clarified that PR review currently supports only Markdown files in Azure DevOps pull requests.
0.1.3
- Fixed PR comment retrieval edge cases (paged thread fetch, left/right anchor handling).
- Improved PR comment list reliability by using PR snapshot as list source of truth.
- Added discussionId-aware thread matching for PR URL workflows.
- Added PR comment diagnostics script for backend validation.
- Added comment-list metadata display (author/time).
0.1.2
- Added PR notifications for incoming new comments/replies.
- Added settings for PR notification toggle and auto-refresh interval.
- Improved TOC jump behavior stability for large/reflowing content.
0.0.4
- Refactored extension into modular architecture.
- Fixed Mermaid rendering and preview context-menu behavior.
- Fixed comment update regressions.
0.0.3
- Added Copy action in preview context menu.
- Improved preview/editor pane behavior and lifecycle.
- Improved scroll sync behavior.
Project Structure
- src/extension.ts: activation and registration entry point.
- src/commands.ts: command handlers and PR workflow orchestration.
- src/html.ts: webview UI, interaction wiring, and panels.
- src/prApi.ts: Azure DevOps API integration.
- scripts/test-pr-comments.ps1: PR comment diagnostics helper.
License
UNLICENSED