Skip to content

fix: selected text inside the active line was invisible#826

Merged
CodeMyst merged 10 commits intomainfrom
fix/codemirror-highlighted-text
Feb 5, 2026
Merged

fix: selected text inside the active line was invisible#826
CodeMyst merged 10 commits intomainfrom
fix/codemirror-highlighted-text

Conversation

@CodeMyst
Copy link
Member

@CodeMyst CodeMyst commented Feb 5, 2026

Closes #803

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request fixes issue #803 where selected text inside the active line was invisible in CodeMirror editors. The fix involves modifying all 8 CodeMirror theme files to adjust z-index layering and selection colors, plus removing conflicting hover styles from the Editor component.

Changes:

  • Added position: "relative" and zIndex: -3 to .cm-activeLine in all theme files to push the active line background behind selection highlights
  • Updated selection background colors in all themes to use more visible, semi-transparent colors
  • Fixed a typo in dracula.ts selector (removed extra 'm' in .cm-selectionBackground)
  • Removed background-color hover effects from Editor.svelte that could interfere with the new z-index layering

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
client/src/lib/codemirror-themes/solarized.ts Applied z-index fix to active line, updated selection colors, removed unused selection variable
client/src/lib/codemirror-themes/rose-pine.ts Applied z-index fix to active line, updated selection colors to semi-transparent
client/src/lib/codemirror-themes/rose-pine-dawn.ts Applied z-index fix to active line, updated selection colors to semi-transparent
client/src/lib/codemirror-themes/myst.ts Applied z-index fix to active line, updated selection colors, removed unused sel variable
client/src/lib/codemirror-themes/myst-light.ts Applied z-index fix to active line, updated selection colors, removed unused sel variable
client/src/lib/codemirror-themes/dracula.ts Applied z-index fix to active line, updated selection colors, fixed selector typo, removed unused selection variable
client/src/lib/codemirror-themes/catppuccin.ts Applied z-index fix to active line, updated selection colors to semi-transparent
client/src/lib/codemirror-themes/catppuccin-late.ts Applied z-index fix to active line, updated selection colors to semi-transparent
client/src/lib/Editor.svelte Removed background-color hover effects that could conflict with theme z-index layering

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

CodeMyst and others added 9 commits February 5, 2026 22:07
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@CodeMyst CodeMyst merged commit 3715b43 into main Feb 5, 2026
5 checks passed
@CodeMyst CodeMyst deleted the fix/codemirror-highlighted-text branch February 5, 2026 21:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

codemirror - highlighted text inside the current line is not visible

2 participants