Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Keyboard shortcut for "Toggle Line Comment" (Cmd+/) does not work inside code chunks in Visual Mode

Abierto
#987 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
55/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Tranquilo
Stack tecnológico
typescript
Área
frontend

Línea de trabajo

No files or tests are named in the issue. Start by locating the Visual Mode keyboard-shortcut handling and how code chunks connect to the underlying editor, then reproduce the Cmd+/ and Ctrl+/ cases in a .qmd or .Rmd file. Done means the current line inside a code chunk is commented in Visual Mode on macOS and Windows, with regression coverage for the shortcut.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

bug visual-editor
Bug description

In Positron, when working in Visual Mode within a .qmd or .Rmd file, the keyboard shortcut for toggling line comments (Cmd + / on macOS or Ctrl + / on Windows) does not work when the cursor is inside a code chunk (e.g., {python} or {r}).

However, it works perfectly fine when switching back to Source Mode.

In RStudio, the comment shortcut works seamlessly inside code chunks even in Visual Mode. As an RStudio user migrating to Positron, this feels like a slight regression in the user experience. It would be highly appreciated if the Visual Editor could pass the comment shortcut down to the underlying code cell.

Steps to reproduce
Open a .qmd or .Rmd document in Positron.
Switch to Visual Mode.
Insert or find a code chunk (e.g., {python}).
Place the cursor on a line of code inside the chunk.
Press Cmd + / (macOS) or Ctrl + / (Windows).
Expected behavior
The current line of code inside the chunk should be commented out (e.g., adding # at the beginning of the line), just like it does in RStudio's Visual Mode or Positron's Source Mode.

Actual behavior
Nothing happens. The shortcut seems to be intercepted or ignored by the Visual Editor.

Environment
OS: macOS (or Windows, please specify)
Positron Version: (You can find this in Positron menu -> About Positron)

Steps to reproduce

No response

Actual behavior

No response

Expected behavior

No response

Your environment

No response

Lenguaje dominante
TypeScript
Estrellas
652
Forks
64
Merge medio
8 h 45 min
PR fusionados (30 d)
36

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de quarto-dev/quarto

Todos los issues de quarto-dev/quarto

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.