I’m trying to tweak my editor’s current CodeMirror 6 theme to fit the surrounding brand, and it’s been a bit tricky. For example - styling the hover-triggered popup that shows lint issues:
- I can’t select it in the Chrome Devtools because if I right-click on it to inspect, it’ll disappear.
- I can’t find a reference for what the classes are that apply to this element, like
.cm-diagnosticAction
. Reading the source code of the@codemirror/lint
package is helpful, but doesn’t tell the full story about what structure those classes are in, what nesting is like. - It’s not clear how to override built-in lints in a predictable way.
@codemirror/lint
brings with it default styles, which aren’t overridden if you just write".cm-diagnostic": {}
- you need to specifically override each default rule. It’s not clear if there’s a way to use a package like@codemirror/lint
but not include its default styles.
Any help from folks who have worked out a good workflow here would be super useful, thanks!