@codemirror/autocomplete 6.20.1 → 6.20.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/CHANGELOG.md +6 -0
- package/README.md +2 -2
- package/dist/index.cjs +4 -3
- package/dist/index.js +4 -3
- package/package.json +2 -2
- package/.github/workflows/dispatch.yml +0 -16
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @codemirror/autocomplete [](https://www.npmjs.org/package/@codemirror/autocomplete)
|
|
2
2
|
|
|
3
|
-
[ [**WEBSITE**](https://codemirror.net/) | [**DOCS**](https://codemirror.net/docs/ref/#autocomplete) | [**ISSUES**](https://
|
|
3
|
+
[ [**WEBSITE**](https://codemirror.net/) | [**DOCS**](https://codemirror.net/docs/ref/#autocomplete) | [**ISSUES**](https://code.haverbeke.berlin/codemirror/dev/issues) | [**FORUM**](https://discuss.codemirror.net/) | [**CHANGELOG**](https://code.haverbeke.berlin/codemirror/autocomplete/src/branch/main/CHANGELOG.md) ]
|
|
4
4
|
|
|
5
5
|
This package implements autocompletion for the
|
|
6
6
|
[CodeMirror](https://codemirror.net/) code editor.
|
|
@@ -10,7 +10,7 @@ number of [examples](https://codemirror.net/examples/) and the
|
|
|
10
10
|
[documentation](https://codemirror.net/docs/).
|
|
11
11
|
|
|
12
12
|
This code is released under an
|
|
13
|
-
[MIT license](https://
|
|
13
|
+
[MIT license](https://code.haverbeke.berlin/codemirror/autocomplete/tree/main/LICENSE).
|
|
14
14
|
|
|
15
15
|
We aim to be an inclusive, welcoming community. To make that explicit,
|
|
16
16
|
we have a [code of
|
package/dist/index.cjs
CHANGED
|
@@ -497,8 +497,8 @@ function rangeAroundSelected(total, selected, max) {
|
|
|
497
497
|
let off = Math.floor(selected / max);
|
|
498
498
|
return { from: off * max, to: (off + 1) * max };
|
|
499
499
|
}
|
|
500
|
-
let off = Math.
|
|
501
|
-
return { from: total -
|
|
500
|
+
let off = Math.ceil((total - selected) / max);
|
|
501
|
+
return { from: total - off * max, to: total - (off - 1) * max };
|
|
502
502
|
}
|
|
503
503
|
class CompletionTooltip {
|
|
504
504
|
constructor(view, stateField, applyCompletion) {
|
|
@@ -1357,7 +1357,8 @@ const baseTheme = view.EditorView.baseTheme({
|
|
|
1357
1357
|
content: '"···"',
|
|
1358
1358
|
opacity: 0.5,
|
|
1359
1359
|
display: "block",
|
|
1360
|
-
textAlign: "center"
|
|
1360
|
+
textAlign: "center",
|
|
1361
|
+
cursor: "pointer",
|
|
1361
1362
|
},
|
|
1362
1363
|
".cm-tooltip.cm-completionInfo": {
|
|
1363
1364
|
position: "absolute",
|
package/dist/index.js
CHANGED
|
@@ -495,8 +495,8 @@ function rangeAroundSelected(total, selected, max) {
|
|
|
495
495
|
let off = Math.floor(selected / max);
|
|
496
496
|
return { from: off * max, to: (off + 1) * max };
|
|
497
497
|
}
|
|
498
|
-
let off = Math.
|
|
499
|
-
return { from: total -
|
|
498
|
+
let off = Math.ceil((total - selected) / max);
|
|
499
|
+
return { from: total - off * max, to: total - (off - 1) * max };
|
|
500
500
|
}
|
|
501
501
|
class CompletionTooltip {
|
|
502
502
|
constructor(view, stateField, applyCompletion) {
|
|
@@ -1355,7 +1355,8 @@ const baseTheme = /*@__PURE__*/EditorView.baseTheme({
|
|
|
1355
1355
|
content: '"···"',
|
|
1356
1356
|
opacity: 0.5,
|
|
1357
1357
|
display: "block",
|
|
1358
|
-
textAlign: "center"
|
|
1358
|
+
textAlign: "center",
|
|
1359
|
+
cursor: "pointer",
|
|
1359
1360
|
},
|
|
1360
1361
|
".cm-tooltip.cm-completionInfo": {
|
|
1361
1362
|
position: "absolute",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codemirror/autocomplete",
|
|
3
|
-
"version": "6.20.
|
|
3
|
+
"version": "6.20.2",
|
|
4
4
|
"description": "Autocompletion for the CodeMirror code editor",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "cm-runtests",
|
|
@@ -36,6 +36,6 @@
|
|
|
36
36
|
},
|
|
37
37
|
"repository": {
|
|
38
38
|
"type": "git",
|
|
39
|
-
"url": "git+https://
|
|
39
|
+
"url": "git+https://code.haverbeke.berlin/codemirror/autocomplete.git"
|
|
40
40
|
}
|
|
41
41
|
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
name: Trigger CI
|
|
2
|
-
on: push
|
|
3
|
-
|
|
4
|
-
jobs:
|
|
5
|
-
build:
|
|
6
|
-
name: Dispatch to main repo
|
|
7
|
-
runs-on: ubuntu-latest
|
|
8
|
-
steps:
|
|
9
|
-
- name: Emit repository_dispatch
|
|
10
|
-
uses: mvasigh/dispatch-action@main
|
|
11
|
-
with:
|
|
12
|
-
# You should create a personal access token and store it in your repository
|
|
13
|
-
token: ${{ secrets.DISPATCH_AUTH }}
|
|
14
|
-
repo: dev
|
|
15
|
-
owner: codemirror
|
|
16
|
-
event_type: push
|