@bhsd/codemirror-mediawiki 2.17.5 → 2.18.1
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/README.md +6 -0
- package/dist/codemirror.d.ts +2 -1
- package/dist/color.d.ts +5 -0
- package/dist/fold.d.ts +3 -3
- package/dist/main.min.js +15 -15
- package/dist/mw.min.js +19 -19
- package/dist/wiki.min.js +19 -19
- package/i18n/en.json +2 -1
- package/i18n/zh-hans.json +2 -1
- package/i18n/zh-hant.json +2 -1
- package/package.json +4 -2
package/README.md
CHANGED
|
@@ -521,6 +521,12 @@ Key bindings:
|
|
|
521
521
|
|
|
522
522
|
Allow the editor to be scrolled down past the end of the document.
|
|
523
523
|
|
|
524
|
+
## colorPicker
|
|
525
|
+
|
|
526
|
+
*version added: 2.18.0*
|
|
527
|
+
|
|
528
|
+
Provide color pickers for CSS and MediaWiki modes.
|
|
529
|
+
|
|
524
530
|
## escape
|
|
525
531
|
|
|
526
532
|
*version added: 2.2.2*
|
package/dist/codemirror.d.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { EditorView } from '@codemirror/view';
|
|
2
2
|
import type { KeyBinding } from '@codemirror/view';
|
|
3
|
-
import type { Text } from '@codemirror/state';
|
|
3
|
+
import type { Extension, Text } from '@codemirror/state';
|
|
4
4
|
import type { SyntaxNode } from '@lezer/common';
|
|
5
5
|
import type { Diagnostic } from '@codemirror/lint';
|
|
6
6
|
import type { MwConfig } from './token';
|
|
7
7
|
import type { DocRange } from './fold';
|
|
8
8
|
export type { MwConfig };
|
|
9
9
|
export type LintSource = (doc: Text) => Diagnostic[] | Promise<Diagnostic[]>;
|
|
10
|
+
export type Addon<T> = [(config?: T) => Extension, Record<string, T>];
|
|
10
11
|
/** CodeMirror 6 编辑器 */
|
|
11
12
|
export declare class CodeMirror6 {
|
|
12
13
|
#private;
|
package/dist/color.d.ts
ADDED
package/dist/fold.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import type { EditorView } from '@codemirror/view';
|
|
2
2
|
import type { Extension } from '@codemirror/state';
|
|
3
|
+
import type { Addon } from './codemirror';
|
|
3
4
|
export interface DocRange {
|
|
4
5
|
from: number;
|
|
5
6
|
to: number;
|
|
6
7
|
}
|
|
7
|
-
|
|
8
|
+
declare const _default: Addon<Extension>;
|
|
9
|
+
export default _default;
|
|
8
10
|
/**
|
|
9
11
|
* 点击提示折叠模板参数
|
|
10
12
|
* @param view
|
|
11
13
|
*/
|
|
12
14
|
export declare const foldHandler: (view: EditorView) => (e: MouseEvent) => void;
|
|
13
|
-
export declare const foldOnIndent: Extension;
|
|
14
|
-
export declare const defaultFoldExtension: Extension[];
|