vue-codemirror6 0.5.5 → 0.6.2

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "vue-codemirror6",
4
- "version": "0.5.5",
4
+ "version": "0.6.2",
5
5
  "description": "CodeMirror6 Component for vue2 and vue3",
6
6
  "keywords": [
7
7
  "vuejs",
@@ -33,7 +33,7 @@
33
33
  "url": "https://github.com/logue/vue-codemirror6/issues"
34
34
  },
35
35
  "engines": {
36
- "node": ">=16.15.0",
36
+ "node": ">=16.15.1",
37
37
  "yarn": ">=1.22.4"
38
38
  },
39
39
  "packageManager": "yarn@3.2.1",
@@ -64,11 +64,7 @@
64
64
  "prepare": "husky install"
65
65
  },
66
66
  "dependencies": {
67
- "@codemirror/basic-setup": "0.20.0",
68
- "@codemirror/commands": "0.20.0",
69
- "@codemirror/lint": "0.20.3",
70
- "@codemirror/state": "0.20.1",
71
- "@codemirror/view": "0.20.7",
67
+ "codemirror": "^6.0.0",
72
68
  "vue-demi": "latest"
73
69
  },
74
70
  "peerDependencies": {
@@ -81,39 +77,39 @@
81
77
  }
82
78
  },
83
79
  "devDependencies": {
84
- "@codemirror/lang-javascript": "^0.20.1",
85
- "@codemirror/lang-markdown": "^0.20.1",
80
+ "@codemirror/lang-javascript": "^6.0.0",
81
+ "@codemirror/lang-markdown": "^6.0.0",
86
82
  "@types/lodash": "^4.14.182",
87
- "@types/node": "^17.0.41",
88
- "@typescript-eslint/eslint-plugin": "^5.27.1",
89
- "@typescript-eslint/parser": "^5.27.1",
83
+ "@types/node": "^18.0.0",
84
+ "@typescript-eslint/eslint-plugin": "^5.29.0",
85
+ "@typescript-eslint/parser": "^5.29.0",
90
86
  "@vitejs/plugin-vue": "^2.3.3",
91
87
  "@vue/eslint-config-prettier": "^7.0.0",
92
- "eslint": "^8.17.0",
88
+ "eslint": "^8.18.0",
93
89
  "eslint-config-google": "^0.14.0",
94
90
  "eslint-config-prettier": "^8.5.0",
95
91
  "eslint-import-resolver-alias": "^1.1.2",
96
92
  "eslint-import-resolver-typescript": "^2.7.1",
97
93
  "eslint-plugin-html": "^6.2.0",
98
94
  "eslint-plugin-import": "^2.26.0",
99
- "eslint-plugin-jsdoc": "^39.3.2",
95
+ "eslint-plugin-jsdoc": "^39.3.3",
100
96
  "eslint-plugin-tsdoc": "^0.2.16",
101
- "eslint-plugin-vue": "^9.1.0",
97
+ "eslint-plugin-vue": "^9.1.1",
102
98
  "eslint-plugin-vuejs-accessibility": "^1.2.0",
103
99
  "eslint-plugin-yaml": "^0.5.0",
104
100
  "eslint4b-prebuilt": "^6.7.2",
105
101
  "husky": "^8.0.1",
106
- "lint-staged": "^13.0.0",
102
+ "lint-staged": "^13.0.2",
107
103
  "lodash": "^4.17.21",
108
- "prettier": "^2.6.2",
104
+ "prettier": "^2.7.1",
109
105
  "rimraf": "^3.0.2",
110
106
  "rollup-plugin-visualizer": "^5.6.0",
111
- "typescript": "^4.7.3",
112
- "vite": "^2.9.10",
107
+ "typescript": "^4.7.4",
108
+ "vite": "^2.9.12",
113
109
  "vite-plugin-checker": "^0.4.6",
114
110
  "vue": "^3.2.37",
115
111
  "vue-eslint-parser": "^9.0.2",
116
- "vue-tsc": "^0.37.3"
112
+ "vue-tsc": "^0.38.1"
117
113
  },
118
114
  "husky": {
119
115
  "hooks": {
@@ -1,270 +0,0 @@
1
- import { type PropType, type Ref, type SetupContext } from 'vue-demi';
2
- import { EditorSelection } from '@codemirror/state';
3
- import type { Extension, SelectionRange, Text } from '@codemirror/state';
4
- import type { LanguageSupport } from '@codemirror/language';
5
- import type { ViewUpdate } from '@codemirror/view';
6
- import type { LintSource } from '@codemirror/lint';
7
- import type { StyleSpec } from 'style-mod';
8
- /** Emit Interface */
9
- export interface CodeMirrorEmitsInterface {
10
- /** Model Update */
11
- (e: 'update:modelValue', value: string | Text): void;
12
- /** CodeMirror ViewUpdate */
13
- (e: 'update', value: ViewUpdate): void;
14
- }
15
- /** CodeMirror Component */
16
- declare const _default: import("vue-demi").DefineComponent<{
17
- /** Model value */
18
- modelValue: {
19
- type: PropType<string | Text>;
20
- default: string;
21
- };
22
- /**
23
- * Theme
24
- *
25
- * @see {@link https://codemirror.net/6/examples/styling/ | Example: Styling}
26
- */
27
- theme: {
28
- type: PropType<{
29
- [selector: string]: StyleSpec;
30
- }>;
31
- default: () => {};
32
- };
33
- /** Dark Mode */
34
- dark: {
35
- type: BooleanConstructor;
36
- default: boolean;
37
- };
38
- /**
39
- * Use Basic Setup
40
- *
41
- * @see {@link https://codemirror.net/6/docs/ref/#basic-setup | basic-setup}
42
- */
43
- basic: {
44
- type: BooleanConstructor;
45
- default: boolean;
46
- };
47
- /**
48
- * Line wrapping
49
- *
50
- * @see {@link https://codemirror.net/6/docs/ref/#view.EditorView%5ElineWrapping | LineWrapping}
51
- */
52
- wrap: {
53
- type: BooleanConstructor;
54
- default: boolean;
55
- };
56
- /**
57
- * Tab handling
58
- *
59
- * @see {@link https://codemirror.net/6/examples/tab/ | Tab Handling}
60
- */
61
- tab: {
62
- type: BooleanConstructor;
63
- default: boolean;
64
- };
65
- /**
66
- * Readonly
67
- *
68
- * @see {@link https://codemirror.net/6/docs/ref/#state.EditorState%5EreadOnly | readOnly}
69
- */
70
- readonly: {
71
- type: BooleanConstructor;
72
- default: boolean;
73
- };
74
- /**
75
- * Editable
76
- *
77
- * @see {@link https://codemirror.net/6/docs/ref/#view.EditorView%5Eeditable | editable}
78
- */
79
- editable: {
80
- type: BooleanConstructor;
81
- default: boolean;
82
- };
83
- /**
84
- * Additional Extension
85
- *
86
- * @see {@link https://codemirror.net/6/docs/ref/#state.Extension | Extending Editor State}
87
- */
88
- extensions: {
89
- type: PropType<Extension[]>;
90
- default: () => never[];
91
- };
92
- /**
93
- * Language Phreses
94
- *
95
- * @see {@link https://codemirror.net/6/examples/translate/ | Example: Internationalization}
96
- */
97
- phrases: {
98
- type: PropType<Record<string, string>>;
99
- default: () => undefined;
100
- };
101
- /**
102
- * CodeMirror Language
103
- *
104
- * @see {@link https://codemirror.net/6/docs/ref/#language | @codemirror/language}
105
- */
106
- lang: {
107
- type: PropType<LanguageSupport>;
108
- default: () => undefined;
109
- };
110
- /**
111
- * CodeMirror Linter
112
- *
113
- * @see {@link https://codemirror.net/6/docs/ref/#lint | @codemirror/lint}
114
- */
115
- linter: {
116
- type: PropType<LintSource>;
117
- default: undefined;
118
- };
119
- /** Show Gutter */
120
- lintGutter: {
121
- type: BooleanConstructor;
122
- defalt: boolean;
123
- };
124
- }, {
125
- context: SetupContext<import("vue-demi").EmitsOptions>;
126
- editor: Ref<Element | undefined>;
127
- selection: () => EditorSelection;
128
- getRange: (a?: number, b?: number) => string;
129
- getLine: (n: number) => string;
130
- lineCount: () => number;
131
- getCursor: () => number;
132
- listSelections: () => readonly SelectionRange[];
133
- getSelection: () => string;
134
- getSelections: () => string[];
135
- somethingSelected: () => boolean;
136
- replaceRange: (text: string | Text, from: number, to: number) => void;
137
- replaceSelection: (text: string | Text) => void;
138
- setCursor: (pos: number) => void;
139
- setSelection: (anchor: number, head: number) => void;
140
- setSelections: (ranges: readonly SelectionRange[], mainIndex?: number | undefined) => void;
141
- extendSelectionsBy: (f: any) => void;
142
- focus: () => void;
143
- hasFocus: () => boolean;
144
- }, unknown, {}, {}, import("vue-demi").ComponentOptionsMixin, import("vue-demi").ComponentOptionsMixin, import("vue-demi").EmitsOptions, "update:modelValue" | "update", import("vue-demi").VNodeProps & import("vue-demi").AllowedComponentProps & import("vue-demi").ComponentCustomProps, Readonly<import("vue-demi").ExtractPropTypes<{
145
- /** Model value */
146
- modelValue: {
147
- type: PropType<string | Text>;
148
- default: string;
149
- };
150
- /**
151
- * Theme
152
- *
153
- * @see {@link https://codemirror.net/6/examples/styling/ | Example: Styling}
154
- */
155
- theme: {
156
- type: PropType<{
157
- [selector: string]: StyleSpec;
158
- }>;
159
- default: () => {};
160
- };
161
- /** Dark Mode */
162
- dark: {
163
- type: BooleanConstructor;
164
- default: boolean;
165
- };
166
- /**
167
- * Use Basic Setup
168
- *
169
- * @see {@link https://codemirror.net/6/docs/ref/#basic-setup | basic-setup}
170
- */
171
- basic: {
172
- type: BooleanConstructor;
173
- default: boolean;
174
- };
175
- /**
176
- * Line wrapping
177
- *
178
- * @see {@link https://codemirror.net/6/docs/ref/#view.EditorView%5ElineWrapping | LineWrapping}
179
- */
180
- wrap: {
181
- type: BooleanConstructor;
182
- default: boolean;
183
- };
184
- /**
185
- * Tab handling
186
- *
187
- * @see {@link https://codemirror.net/6/examples/tab/ | Tab Handling}
188
- */
189
- tab: {
190
- type: BooleanConstructor;
191
- default: boolean;
192
- };
193
- /**
194
- * Readonly
195
- *
196
- * @see {@link https://codemirror.net/6/docs/ref/#state.EditorState%5EreadOnly | readOnly}
197
- */
198
- readonly: {
199
- type: BooleanConstructor;
200
- default: boolean;
201
- };
202
- /**
203
- * Editable
204
- *
205
- * @see {@link https://codemirror.net/6/docs/ref/#view.EditorView%5Eeditable | editable}
206
- */
207
- editable: {
208
- type: BooleanConstructor;
209
- default: boolean;
210
- };
211
- /**
212
- * Additional Extension
213
- *
214
- * @see {@link https://codemirror.net/6/docs/ref/#state.Extension | Extending Editor State}
215
- */
216
- extensions: {
217
- type: PropType<Extension[]>;
218
- default: () => never[];
219
- };
220
- /**
221
- * Language Phreses
222
- *
223
- * @see {@link https://codemirror.net/6/examples/translate/ | Example: Internationalization}
224
- */
225
- phrases: {
226
- type: PropType<Record<string, string>>;
227
- default: () => undefined;
228
- };
229
- /**
230
- * CodeMirror Language
231
- *
232
- * @see {@link https://codemirror.net/6/docs/ref/#language | @codemirror/language}
233
- */
234
- lang: {
235
- type: PropType<LanguageSupport>;
236
- default: () => undefined;
237
- };
238
- /**
239
- * CodeMirror Linter
240
- *
241
- * @see {@link https://codemirror.net/6/docs/ref/#lint | @codemirror/lint}
242
- */
243
- linter: {
244
- type: PropType<LintSource>;
245
- default: undefined;
246
- };
247
- /** Show Gutter */
248
- lintGutter: {
249
- type: BooleanConstructor;
250
- defalt: boolean;
251
- };
252
- }>>, {
253
- modelValue: string | Text;
254
- theme: {
255
- [selector: string]: StyleSpec;
256
- };
257
- dark: boolean;
258
- basic: boolean;
259
- wrap: boolean;
260
- tab: boolean;
261
- readonly: boolean;
262
- editable: boolean;
263
- extensions: Extension[];
264
- phrases: Record<string, string>;
265
- lang: LanguageSupport;
266
- linter: LintSource;
267
- lintGutter: boolean;
268
- }>;
269
- export default _default;
270
- //# sourceMappingURL=CodeMirror.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CodeMirror.d.ts","sourceRoot":"","sources":["../../src/components/CodeMirror.ts"],"names":[],"mappings":"AAAA,OAAO,EASL,KAAK,QAAQ,EACb,KAAK,GAAG,EACR,KAAK,YAAY,EAClB,MAAM,UAAU,CAAC;AAElB,OAAO,EAAE,eAAe,EAAe,MAAM,mBAAmB,CAAC;AAUjE,OAAO,KAAK,EACV,SAAS,EACT,cAAc,EACd,IAAI,EAEL,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAE3C,qBAAqB;AACrB,MAAM,WAAW,wBAAwB;IACvC,mBAAmB;IACnB,CAAC,CAAC,EAAE,mBAAmB,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;IACrD,4BAA4B;IAC5B,CAAC,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,GAAG,IAAI,CAAC;CACxC;AAED,2BAA2B;;IAWvB,kBAAkB;;;;;IAKlB;;;;OAIG;;;;;;;IAOH,gBAAgB;;;;;IAKhB;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAOH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH,kBAAkB;;;;;;;;;mBAsJI,MAAM,MAAM,MAAM,KAAG,MAAM;iBAE7B,MAAM,KAAG,MAAM;qBACb,MAAM;qBACN,MAAM;0BACD,SAAS,cAAc,EAAE;wBAC3B,MAAM;yBAEL,MAAM,EAAE;6BAEJ,OAAO;yBAIT,MAAM,GAAG,IAAI,QAAQ,MAAM,MAAM,MAAM;6BAInC,MAAM,GAAG,IAAI;qBAErB,MAAM;2BAEA,MAAM,QAAQ,MAAM;4BAGxC,SAAS,cAAc,EAAE,cACrB,MAAM,GAAG,SAAS;;;oBAeX,OAAO;;IAvS5B,kBAAkB;;;;;IAKlB;;;;OAIG;;;;;;;IAOH,gBAAgB;;;;;IAKhB;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAOH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH,kBAAkB;;;;;;;;;;;;;;;;;;;;;;AAlHtB,wBA2VG"}
@@ -1,14 +0,0 @@
1
- interface Options {
2
- class?: string;
3
- domProps?: Record<any, any>;
4
- on?: Record<any, any>;
5
- props?: Record<any, any>;
6
- ref?: string;
7
- style?: string;
8
- }
9
- declare const h: (type: string | Record<any, any>, options?: Options, chidren?: any) => import("vue-demi").VNode<import("vue-demi").RendererNode, import("vue-demi").RendererElement, {
10
- [key: string]: any;
11
- }>;
12
- declare const slot: (defaultSlots: any) => any;
13
- export { slot, h as default };
14
- //# sourceMappingURL=h-demi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"h-demi.d.ts","sourceRoot":"","sources":["../../src/helpers/h-demi.ts"],"names":[],"mappings":"AAEA,UAAU,OAAO;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IAC5B,EAAE,CAAC,EAAE,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;IACzB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAWD,QAAA,MAAM,CAAC,SACC,MAAM,GAAG,OAAO,GAAG,EAAE,GAAG,CAAC,YACtB,OAAO,YACN,GAAG;;EAWd,CAAC;AAEF,QAAA,MAAM,IAAI,iBAAkB,GAAG,QACoC,CAAC;AAEpE,OAAO,EAAE,IAAI,EAAE,CAAC,IAAI,OAAO,EAAE,CAAC"}
package/dist/index.d.ts DELETED
@@ -1,12 +0,0 @@
1
- /**
2
- * Vue CodeMirror6 Component
3
- *
4
- * @license MIT
5
- * @author Logue {@link logue@hotmail.co.jp}
6
- * @copyright 2022 Masashi Yoshikawa {@link https://logue.dev/} All rights reserved.
7
- * @see {@link https://github.com/logue/vue-codemirror6}
8
- */
9
- import CodeMirror from './components/CodeMirror';
10
- declare const installCodeMirror: (app: any) => any;
11
- export { CodeMirror as default, installCodeMirror as install };
12
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA;;;;;;;GAOG;AAEH,OAAO,UAAU,MAAM,yBAAyB,CAAC;AAGjD,QAAA,MAAM,iBAAiB,mBAAiD,CAAC;AAEzE,OAAO,EAAE,UAAU,IAAI,OAAO,EAAE,iBAAiB,IAAI,OAAO,EAAE,CAAC"}