@codemirror/autocomplete 0.20.3 → 6.0.0
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/CHANGELOG.md +6 -0
- package/dist/index.cjs +4 -1
- package/dist/index.js +4 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -1269,7 +1269,10 @@ function snippet(template) {
|
|
|
1269
1269
|
let snippet = Snippet.parse(template);
|
|
1270
1270
|
return (editor, _completion, from, to) => {
|
|
1271
1271
|
let { text, ranges } = snippet.instantiate(editor.state, from);
|
|
1272
|
-
let spec = {
|
|
1272
|
+
let spec = {
|
|
1273
|
+
changes: { from, to, insert: state.Text.of(text) },
|
|
1274
|
+
scrollIntoView: true
|
|
1275
|
+
};
|
|
1273
1276
|
if (ranges.length)
|
|
1274
1277
|
spec.selection = fieldSelection(ranges, 0);
|
|
1275
1278
|
if (ranges.length > 1) {
|
package/dist/index.js
CHANGED
|
@@ -1265,7 +1265,10 @@ function snippet(template) {
|
|
|
1265
1265
|
let snippet = Snippet.parse(template);
|
|
1266
1266
|
return (editor, _completion, from, to) => {
|
|
1267
1267
|
let { text, ranges } = snippet.instantiate(editor.state, from);
|
|
1268
|
-
let spec = {
|
|
1268
|
+
let spec = {
|
|
1269
|
+
changes: { from, to, insert: Text.of(text) },
|
|
1270
|
+
scrollIntoView: true
|
|
1271
|
+
};
|
|
1269
1272
|
if (ranges.length)
|
|
1270
1273
|
spec.selection = fieldSelection(ranges, 0);
|
|
1271
1274
|
if (ranges.length > 1) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codemirror/autocomplete",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "6.0.0",
|
|
4
4
|
"description": "Autocompletion for the CodeMirror code editor",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "cm-runtests",
|
|
@@ -26,10 +26,10 @@
|
|
|
26
26
|
"sideEffects": false,
|
|
27
27
|
"license": "MIT",
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@codemirror/language": "^0.
|
|
30
|
-
"@codemirror/state": "^0.
|
|
31
|
-
"@codemirror/view": "^0.
|
|
32
|
-
"@lezer/common": "^0.
|
|
29
|
+
"@codemirror/language": "^6.0.0",
|
|
30
|
+
"@codemirror/state": "^6.0.0",
|
|
31
|
+
"@codemirror/view": "^6.0.0",
|
|
32
|
+
"@lezer/common": "^1.0.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@codemirror/buildhelper": "^0.1.5"
|