CodinGame / monaco-vscode-api

VSCode public API plugged on the monaco editor
MIT License
226 stars 31 forks source link

Display problem in "Peek" mode #305

Closed Tnze closed 6 months ago

Tnze commented 9 months ago

Please watch the video:

https://github.com/CodinGame/monaco-vscode-api/assets/19628575/436af707-2898-4b4f-9770-c69e7c0f6ae6

  1. The peeked file doesn't shown before resizing.
  2. The split panel is weird.
Tnze commented 9 months ago

It seems to have a very small size in the upper left corner, before I resize the editor.

CGNonofr commented 9 months ago

What a weird bug!

Are you sure it's related to that library? the peek component is included in monaco itself

github-actions[bot] commented 8 months ago

This issue is stale because it has been open for 30 days with no activity.

ndeyefatoudiop1993 commented 8 months ago

I have also noted this issue with the Monaco editor when you try to peek a definition. The fix was to either wait for the definitions to be loaded or apply some css to the editor so it takes full width/height

Tnze commented 8 months ago

wait for the definitions to be loaded

How do I wait for the definitions to be loaded?

ndeyefatoudiop1993 commented 8 months ago

wait for the definitions to be loaded

How do I wait for the definitions to be loaded?

It depends on how you get the definitions. When I use for example vscode-languageclient, I can use the middleware and intercept when the definitions are received from the language server. Then I make sure that the files for the definitions are actually loaded.

Else try to put a width/height of 100% on the element “.reference-inline-widget .inline”

github-actions[bot] commented 7 months ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 6 months ago

This issue was closed because it has been inactive for 14 days since being marked as stale.