mirror of
https://github.com/narrrl/narl-workspace.git
synced 2026-11-04 08:57:00 +01:00
fix: legible caret and working :q!
CodeMirror injects its own `.cm-cursor` rule after our stylesheet, so the equally specific override lost and the caret painted black on a dark background. Qualify the selector, same as `.cm-activeLine`. `:q!` reached the command table as the literal name `quit!`, which nothing matched. Commands now carry an optional `bang` variant, and `runCommand` splits a trailing `!` off any head before looking it up. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01476ZKdB4k3rPDwvVhXcnDg
This commit is contained in:
1 parent
e0565ea1b4
commit
bf3c1f547a
4 files changed
+38
-16
No files matched your search
+11
-2
@@ -198,11 +198,20 @@ input::placeholder { color: var(--fg-faint); }
|
||||
.cm-editor .cm-activeLine { background: color-mix(in srgb, var(--fg) 4%, transparent); }
|
||||
.cm-selectionBackground, .cm-content ::selection { background: var(--select) !important; }
|
||||
|
||||
/* Insert mode: a 2px bar reads far better than the browser's hairline caret. */
|
||||
.cm-cursor, .cm-cursor-primary {
|
||||
/*
|
||||
* Insert mode: a 2px bar reads far better than the browser's hairline caret.
|
||||
* CodeMirror injects `.cm-cursor { border-left: 1.2px solid black }` after this
|
||||
* stylesheet, so — like `.cm-activeLine` above — an equally specific selector
|
||||
* loses and the caret renders black on a dark background. Qualify it to win.
|
||||
*/
|
||||
.cm-editor .cm-cursor,
|
||||
.cm-editor .cm-cursor-primary,
|
||||
.cm-editor .cm-dropCursor {
|
||||
border-left: 2px solid var(--accent);
|
||||
border-right: 0;
|
||||
margin-left: -1px;
|
||||
}
|
||||
.cm-editor .cm-cursor-secondary { border-left-color: var(--accent-dim); }
|
||||
|
||||
/*
|
||||
* Normal mode: the vim plugin paints the character *inside* the block cursor,
|
||||
|
||||
Reference in new issue
Block a user