@codemirror/autocomplete
Advanced tools
Changelog
6.8.1 (2023-06-23)
acceptCompletion
now returns false (allowing other handlers to take effect) when the completion popup is open but disabled.
Changelog
6.8.0 (2023-06-12)
The result of Completion.info
may now include a destroy
method that will be called when the tooltip is removed.
Changelog
6.7.1 (2023-05-13)
Fix a bug that cause incorrect ordering of completions when some results covered input text and others didn't.
Changelog
6.7.0 (2023-05-11)
The new hasNextSnippetField
and hasPrevSnippetField
functions can be used to figure out if the snippet-field-motion commands apply to a given state.
Changelog
6.6.1 (2023-05-03)
Fix a bug that made the editor use the completion's original position, rather than its current position, when changes happened in the document while a result was active.
Changelog
6.6.0 (2023-04-27)
Fix a bug in insertCompletionText
that caused it to replace the wrong range when a result set's to
fell after the cursor.
Functions returned by snippet
can now be called without a completion object.
Changelog
6.5.1 (2023-04-13)
Keep completions open when interaction with an info tooltip moves focus out of the editor.
Changelog
6.5.0 (2023-04-13)
When closeBrackets
skips a bracket, it now generates a change that overwrites the bracket.
Replace the entire selected range when picking a completion with a non-cursor selection active.
Completions can now provide a section
field that is used to group them into sections.
The new positionInfo
option can be used to provide custom logic for positioning the info tooltips.
Changelog
6.4.2 (2023-02-17)
Fix a bug where the apply method created by snippet
didn't add a pickedCompletion
annotation to the transactions it created.
Changelog
6.4.1 (2023-02-14)
Don't consider node names in trees that aren't the same language as the one at the completion position in ifIn
and ifNotIn
.
Make sure completions that exactly match the input get a higher score than those that don't (so that even if the latter has a score boost, it ends up lower in the list).