Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Current highlighted line color #424

Closed
sam-rez opened this issue Dec 3, 2022 · 3 comments
Closed

Current highlighted line color #424

sam-rez opened this issue Dec 3, 2022 · 3 comments

Comments

@sam-rez
Copy link

sam-rez commented Dec 3, 2022

When highlighting lines of text, the current highlighted line color is different than the rest. In the image below, line 1 is different than the rest of the highlighted block.

How can I make the entire highlighted block the same color?

codemirror-highlight

@jaywcjlove
Copy link
Member

@jaywcjlove
Copy link
Member

@sam-rez

import CodeMirror from '@uiw/react-codemirror';
import { zebraStripes } from '@uiw/codemirror-zebra-stripes';

function App() {
  return (
    <CodeMirror
      value=""
      height="200px"
      extensions={[
        zebraStripes({
          lineNumber: [1, [3, 6], 10],
          lightColor: '#aca2ff33',
          darkColor: '#aca2ff40',
        }),
      ]}
    />
  );
}
export default App;

image

image

@sam-rez
Copy link
Author

sam-rez commented Dec 7, 2022

I fixed it by adding
highlightActiveLine: false
in basicSetup

@sam-rez sam-rez closed this as completed Dec 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants