Can't customize vim text color under cursor

I’m trying to change the color under the cursor in vim (visual mode), with no avail. I’ve used the same syntax found in this thread, but it looks like it doesn’t work.

This is my theme.css:

.cm-fat-cursor .CodeMirror-cursor {
    background-color: #ff0000 !important;
    color: #000000 !important;
    opacity: 60% !important;
}

.cm-animate-fat-cursor .CodeMirror-cursor {
    background-color: #ff0000 !important;
    color: #000000 !important;
    opacity: 60% !important;
}

While this is the result:

Screen Shot 2021-01-09 at 12.34.41

The expected result would the text color, under the cursor, to be black instead. Like this:

Screen Shot 2021-01-09 at 12.42.20

1 Like

The .CodeMirror-cursor and .cm-animate-fat-cursor don’t seem to work anymore. If you just do the following then it should work for at least the bare minimum of changing the cursor color (or at least as far as I’ve been able to get):

.cm-fat-cursor {
    background-color: #ff0000 !important;
    color: #000000 !important;
    opacity: 60% !important;
}

You can also add a width tag in there if you want to make the cursor a standard width if you aren’t already using a monospace font.