@uiw/codemirror-themes 4.21.19 → 4.21.21

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.
Files changed (2) hide show
  1. package/README.md +7 -7
  2. package/package.json +2 -1
package/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  # Custom Codemirror Themes
2
2
 
3
+ [![Buy me a coffee](https://img.shields.io/badge/Buy%20me%20a%20coffee-048754?logo=buymeacoffee)](https://jaywcjlove.github.io/#/sponsor)
3
4
  [![npm version](https://img.shields.io/npm/v/@uiw/codemirror-themes.svg)](https://www.npmjs.com/package/@uiw/codemirror-themes)
4
5
 
5
6
  Themes for CodeMirror.
@@ -29,6 +30,7 @@ const myTheme = createTheme({
29
30
  selection: '#036dd626',
30
31
  selectionMatch: '#036dd626',
31
32
  lineHighlight: '#8a91991a',
33
+ gutterBorder: '1px solid #ffffff10',
32
34
  gutterBackground: '#fff',
33
35
  gutterForeground: '#8a919966',
34
36
  },
@@ -292,19 +294,17 @@ export interface CreateThemeOptions {
292
294
  * Settings to customize the look of the editor, like background, gutter, selection and others.
293
295
  */
294
296
  settings: Settings;
295
- /**
296
- * Syntax highlighting styles.
297
- */
297
+ /** Syntax highlighting styles. */
298
298
  styles: TagStyle[];
299
299
  }
300
- declare type Theme = 'light' | 'dark';
300
+ type Theme = 'light' | 'dark';
301
301
  export interface Settings {
302
302
  /** Editor background color. */
303
- background: string;
303
+ background?: string;
304
304
  /** Editor background image. */
305
305
  backgroundImage?: string;
306
306
  /** Default text color. */
307
- foreground: string;
307
+ foreground?: string;
308
308
  /** Caret color. */
309
309
  caret?: string;
310
310
  /** Selection background. */
@@ -324,7 +324,7 @@ export interface Settings {
324
324
  /** set editor font */
325
325
  fontFamily?: string;
326
326
  }
327
- declare const createTheme: ({ dark, settings, styles }: CreateThemeOptions) => Extension;
327
+ export declare const createTheme: ({ theme, settings, styles }: CreateThemeOptions) => Extension;
328
328
  export default createTheme;
329
329
  ```
330
330
 
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@uiw/codemirror-themes",
3
- "version": "4.21.19",
3
+ "version": "4.21.21",
4
4
  "description": "Themes for CodeMirror.",
5
5
  "homepage": "https://uiwjs.github.io/react-codemirror/#/theme/doc",
6
+ "funding": "https://jaywcjlove.github.io/#/sponsor",
6
7
  "author": "kenny wong <wowohoo@qq.com>",
7
8
  "license": "MIT",
8
9
  "main": "./cjs/index.js",