elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.48k stars 8.04k forks source link

[Console Monaco migration] Add a comma to the previous line when autocomplete is selected #184856

Open yuliacech opened 1 month ago

yuliacech commented 1 month ago

The Ace editor has a feature that adds a comma to the previous property in the request body, if it's missing and the next property is being autocompleted from suggestions. We should consider implementing this feature in the Monaco editor. This might not be possible when just inserting a suggestion, because it seems that the editor won't accept suggestions that insert a text before the cursor position in the editor. But we might be able to execute an additional edit after inserting the suggestion.

Screen recordings

Ace

https://github.com/elastic/kibana/assets/6585477/e9260d79-a70c-4cea-8455-792304294ddb

Monaco

https://github.com/elastic/kibana/assets/6585477/9b178cf7-d944-40ee-a637-e527f6484fc4

elasticmachine commented 1 month ago

Pinging @elastic/kibana-management (Team:Kibana Management)

sama-rah commented 1 month ago

thanks fixed!