Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adapt positioning of the inline chat #184598

Merged
merged 24 commits into from
Jun 14, 2023
Merged

Adapt positioning of the inline chat #184598

merged 24 commits into from
Jun 14, 2023

Conversation

aiday-mar
Copy link
Contributor

@aiday-mar aiday-mar commented Jun 8, 2023

Fixes: microsoft/vscode-copilot-release#52
Fixes: https://github.com/microsoft/vscode-copilot/issues/251

When the inline chat appears, it is positioned at the primary cursor. When markdown messages or errors are rendered, the inline chat position remains at the initial position. It only changes position if there has been an edit response and therefore the editor model has changed. The positioning is as follows and depends on the viewing strategy for the inline chat:

  • livePreview: the inline chat is positioned at the end of the selection
  • live: the inline chat is positioned at the line number corresponding to the last local edit, or at the initial position if there are no local edits
  • preview: the inline chat is positioned at the initial position. Since no actual edits are done, it does not need to be positioned elsewhere.

@aiday-mar aiday-mar self-assigned this Jun 8, 2023
@aiday-mar aiday-mar changed the title Smart positioning of the inline chat Adapt positioning of the inline chat Jun 12, 2023
@aiday-mar aiday-mar marked this pull request as ready for review June 12, 2023 12:22
@aiday-mar aiday-mar requested a review from jrieken June 12, 2023 12:22
@VSCodeTriageBot VSCodeTriageBot added this to the June 2023 milestone Jun 12, 2023
@aiday-mar aiday-mar requested a review from jrieken June 13, 2023 16:30
@aiday-mar aiday-mar merged commit 1ad238a into main Jun 14, 2023
6 checks passed
@aiday-mar aiday-mar deleted the aiday/positioningInlineChat branch June 14, 2023 07:17
@github-actions github-actions bot locked and limited conversation to collaborators Jul 29, 2023
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.

The chat box shows location adaptation
3 participants