is it possible to defined the color of select in codemirror6

I am using codemirror6 as a online latex editor, now I found when I select the text, the text did not highlight. click the mouse twice will highlight the whole paragraph. drag the mouse to select will not highlight. is it possible to enable the drag mouse select text highlight and custom the drag select background color? what should I do?

Are you using drawSelection? Are you styling the line background to something opaque (that will hide the selection, which is drawn as a backdrop behind it)?

I am not use drawSelection, I am not styling the line background to somehing opaque. This is the style look like:

const extensions = [
    EditorView.contentAttributes.of({ spellcheck: 'true' }),
        "&": { height: "100%" },
        '.cm-content': {
            fontSize: '16px'
        '.cm-scroller': {


Then you are getting the native browser selection, which should be visible.