Skip to content
This repository was archived by the owner on Apr 15, 2026. It is now read-only.

Export startCompletionEffect and closeCompletionEffect#25

Closed
ankoh wants to merge 1 commit intocodemirror:mainfrom
ankoh:main
Closed

Export startCompletionEffect and closeCompletionEffect#25
ankoh wants to merge 1 commit intocodemirror:mainfrom
ankoh:main

Conversation

@ankoh
Copy link
Copy Markdown

@ankoh ankoh commented Aug 18, 2024

This commit is exposing startCompletionEffect and closeCompletionEffect.
It allows us to modify StateFields whenever the completion popup opens/closes.

@ankoh
Copy link
Copy Markdown
Author

ankoh commented Aug 18, 2024

Let me know if there's a better way to update StateFields whenever the completion is either applied or aborted.
I thought about hooking into Candidate apply, CompletionResult validFor and CompletionResult map, but you're still missing some cases where the completion is, for example, canceled by deleting the whole word.

@ankoh
Copy link
Copy Markdown
Author

ankoh commented Aug 18, 2024

Ah, I just found that mine is a duplicate of #24 , sorry.

@ankoh
Copy link
Copy Markdown
Author

ankoh commented Aug 18, 2024

Feel free to close if you don't like exposing the effect, I'll use the workaround of #24 in the meantime.

@marijnh
Copy link
Copy Markdown
Member

marijnh commented Aug 18, 2024

Yeah these are really intended to be internal.

@marijnh marijnh closed this Aug 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants