Skip to content

Commit

Permalink
Update logic
Browse files Browse the repository at this point in the history
  • Loading branch information
felixhabib committed May 7, 2024
1 parent f23b35a commit 379375b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Playroom/CodeEditor/keymaps/comment.ts
Expand Up @@ -254,9 +254,10 @@ const determineCommentType = (
if (isJavaScriptMode && !isBlockComment && !containsTag) {
return 'line';
}
const lineEmpty = isOnlyWhitespace(cm.getLine(from.line));

if (
(!isJavaScriptMode && !containsAttribute) ||
(!isJavaScriptMode && !containsAttribute && !lineEmpty) ||
containsTag ||
isJavaScriptMode
) {
Expand Down

0 comments on commit 379375b

Please sign in to comment.