Skip to content

feat: add minimap hover preview with multi-line code preview#307809

Open
Mohamed998788 wants to merge 1 commit intomicrosoft:mainfrom
Mohamed998788:feature/minimap-hover-preview-clean
Open

feat: add minimap hover preview with multi-line code preview#307809
Mohamed998788 wants to merge 1 commit intomicrosoft:mainfrom
Mohamed998788:feature/minimap-hover-preview-clean

Conversation

@Mohamed998788
Copy link
Copy Markdown

Summary

  • Add a floating code preview that appears when hovering over the minimap
  • Multi-line preview centered on the hovered line with highlighted center line
  • Debounced rendering (default 300ms) for optimal performance on large files
  • Automatic theme support via CSS custom variables (dark/light/high-contrast)
  • Truncates long lines at 200 chars with ellipsis

New Settings

  • editor.minimap.showHoverPreview (boolean, default true)
  • editor.minimap.hoverPreviewDelay (number, default 300ms)
  • editor.minimap.hoverPreviewMaxLines (number, default 5)

Files Changed

  • src/vs/editor/browser/viewParts/minimap/minimap.ts - MinimapHoverPreview class + integration
  • src/vs/editor/browser/viewParts/minimap/minimap.css - hover preview styles
  • src/vs/editor/common/config/editorOptions.ts - new minimap settings

@Mohamed998788
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants