codemirror-theme-jetbrains-dark
v1.0.0
Published
JetBrains Islands Dark editor theme for CodeMirror 6.
Downloads
29
Maintainers
Readme
codemirror-theme-jetbrains-dark
JetBrains Islands Dark editor theme for CodeMirror 6.
The color and editor typography tokens are mapped from JetBrains' official Islands Dark UI theme and editor color scheme:
- https://github.com/JetBrains/intellij-community/blob/master/platform/platform-resources/src/themes/islands/ManyIslandsDark.theme.json
- https://github.com/JetBrains/intellij-community/blob/master/platform/platform-resources/src/themes/islands/IslandSchemeDark.xml
Install
pnpm add codemirror-theme-jetbrains-darkUsage
import { EditorView } from '@codemirror/view';
import { jetbrainsDark } from 'codemirror-theme-jetbrains-dark';
new EditorView({
doc: 'SELECT * FROM users;',
extensions: [jetbrainsDark],
parent: document.body,
});Exports
jetbrainsDark: full CodeMirror extension array.jetbrainsDarkTheme: base CodeMirror editor theme.jetbrainsDarkHighlightStyle: syntax highlight style.jetbrainsDarkColors: shared JetBrains Islands Dark color tokens.jetbrainsDarkTypography: JetBrains Mono editor typography tokens.
The theme includes custom selection drawing via drawSelection(). If your editor setup already enables CodeMirror's drawSelection, disable the duplicate in your basic setup.
