LSP-copilot
LSP-copilot copied to clipboard
feat: update the phantom while typing
Closes #52
This PR tries to emulate VSCode when the phantom(ghost) text is updated while typing(without triggering an extra request).
Unfortunately, due to the phantom API limitations, it is currently not possible(see the attached video)
https://user-images.githubusercontent.com/471335/194121909-c98ed8eb-4ae7-4221-ac32-b7bd7a1b7cfa.mov
The main problem is that the cursor always jumps when updating the phantom in real time.
I opened it just to have some reference but, in general, this PR should be merged only when the problem with the cursor is fixed(see https://github.com/sublimehq/sublime_text/issues/5536 and https://github.com/TheSecEng/LSP-copilot/issues/54)
I feel, at this moment, the UX in the video is worse than without this PR.
Just in case, here is how it works in VSCode
https://user-images.githubusercontent.com/471335/194123754-1cc878d3-dd7a-4681-9f87-242237fa4a1e.mov
Yes, it is horrible. That's why we shouldn't merge this one.
We could close it, as I opened it purely to have some reference
We could close it, as I opened it purely to have some reference
Keep it open is fine to help us remember this 😄