@uiw/codemirror-themes 4.21.8 → 4.21.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cjs/index.js CHANGED
@@ -59,8 +59,8 @@ var createTheme = function createTheme(_ref) {
59
59
  }
60
60
  themeOptions['.cm-activeLineGutter'] = activeLineGutterStyle;
61
61
  if (settings.selection) {
62
- themeOptions['&.cm-focused .cm-selectionBackground, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'] = {
63
- backgroundColor: settings.selection
62
+ themeOptions['&.cm-focused .cm-selectionBackground, &.cm-focused .cm-line::selection, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'] = {
63
+ backgroundColor: settings.selection + ' !important'
64
64
  };
65
65
  }
66
66
  if (settings.selectionMatch) {
package/esm/index.js CHANGED
@@ -53,8 +53,8 @@ export var createTheme = _ref => {
53
53
  }
54
54
  themeOptions['.cm-activeLineGutter'] = activeLineGutterStyle;
55
55
  if (settings.selection) {
56
- themeOptions['&.cm-focused .cm-selectionBackground, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'] = {
57
- backgroundColor: settings.selection
56
+ themeOptions['&.cm-focused .cm-selectionBackground, &.cm-focused .cm-line::selection, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'] = {
57
+ backgroundColor: settings.selection + ' !important'
58
58
  };
59
59
  }
60
60
  if (settings.selectionMatch) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uiw/codemirror-themes",
3
- "version": "4.21.8",
3
+ "version": "4.21.9",
4
4
  "description": "Themes for CodeMirror.",
5
5
  "homepage": "https://uiwjs.github.io/react-codemirror/#/theme/doc",
6
6
  "author": "kenny wong <wowohoo@qq.com>",
package/src/index.tsx CHANGED
@@ -95,9 +95,9 @@ export const createTheme = ({ theme, settings = {}, styles = [] }: CreateThemeOp
95
95
 
96
96
  if (settings.selection) {
97
97
  themeOptions[
98
- '&.cm-focused .cm-selectionBackground, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'
98
+ '&.cm-focused .cm-selectionBackground, &.cm-focused .cm-line::selection, & .cm-selectionLayer .cm-selectionBackground, .cm-content ::selection'
99
99
  ] = {
100
- backgroundColor: settings.selection,
100
+ backgroundColor: settings.selection + ' !important',
101
101
  };
102
102
  }
103
103
  if (settings.selectionMatch) {