Keyboard shortcut for "Toggle Line Comment" (Cmd+/) does not work inside code chunks in Visual Mode
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 55/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 冷清
- 技术栈
- typescript
- 领域
- frontend
调研方向
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.
由索引模型根据 Issue 内容生成。
描述
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
- 主要语言
- TypeScript
- 星标
- 652
- 派生
- 64
- 平均合并
- 8 小时 45 分钟
- 30 天内合并 PR
- 36
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
quarto-dev/quarto 的其他 Issue
-
VS Code extension: `quarto preview` fails when the file path contains parentheses (path not shell-quoted)可能已有人在做 @Bondrewd-K 于 3 天前认领。 未关闭bug vscode
难度 2/5 1-3 小时 新手友好度 78/100
quarto-dev/quarto#1194 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 84/100
quarto-dev/quarto#1139 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 1/5 1-3 小时 新手友好度 90/100
quarto-dev/quarto#1138 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
quarto-dev/quarto#1137 ·
维护者通常 1 天内回复
-
Add dependabot?可能重新可做 关联的 PR 已关闭且未合并。 未关闭
难度 2/5 1-3 小时 新手友好度 68/100
quarto-dev/quarto#1135 ·
维护者通常 1 天内回复
查看 quarto-dev/quarto 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 67/100
agilepathway/label-checker#739 · 4 条评论 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 68/100
CopilotKit/OpenBot#800 ·
维护者通常 1 天内回复
-
Endpoint links in the tag operations list are below the 24px target size可能已有人在做 @AdzerKI 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 79/100
ehmpathy/rhachet-roles-bhuild#471 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 73/100
维护者通常 1 天内回复