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

[Improvement]: Revamp the completions provided for resource access methods #41636

Closed
3 tasks done
nipunayf opened this issue Nov 3, 2023 · 0 comments · Fixed by #41663
Closed
3 tasks done

[Improvement]: Revamp the completions provided for resource access methods #41636

nipunayf opened this issue Nov 3, 2023 · 0 comments · Fixed by #41663
Assignees
Labels
Area/Completion Issues related to Language Server Auto Completions Team/LanguageServer Language Server Implementation related issues. #Compiler Type/Improvement
Milestone

Comments

@nipunayf
Copy link
Contributor

nipunayf commented Nov 3, 2023

Description

The current completions provided to the user for resource access methods are less intuitive when filling the paths.

Describe your problem(s)

Upon typing cl ->/ <cursor>, the LS server provides at most two sets of completions to the user. Since any variable value can be inserted into a computed resource path parameter, completion items are provided for these resource paths with both the parameter name and the type. However, if the resource path parameter contains a value that can be written as an identifier, the LS additionally provides completions with a named segment. However, these named segment completions are less intuitive since the placeholder is labeled <path> and not its parameter name.

As the resource methods of a client class grow higher, the completion suggestions also go higher. Thus, suggestions with computed resource access segments go to the bottom of the completion list, making the completion item less intuitive for the user as named segments are at the top.

Describe your solution(s)

The following tasks are designed to improve the UX of the completions.

  • Replace the <path> in the named segment with its parameter value so the user is more aware of the completion item they are selecting.
  • Reorder the completion items so that computed resource segments are at the top.
  • Group both named and computed resource segments together so that one category won't be left out at the bottom.

Related area

-> Compilation

Related issue(s) (optional)

#41563

Suggested label(s) (optional)

No response

Suggested assignee(s) (optional)

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area/Completion Issues related to Language Server Auto Completions Team/LanguageServer Language Server Implementation related issues. #Compiler Type/Improvement
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant