dotnet/try

Sizing issues of the IFrame containing the interactive editor

Opened this issue · 9 comments

image

This is needed in order to improve the UI.

In production it looks seamless
image

however with the new version we can see some unnecessary overflow
image

Additional context: this is specific to the marketing page.

The fix should go in the host

The element that needs to be sized is here:
image

It should be sized using the Monaco API, which is exposed by trydotnet.js.

@jonsequitur can you point me to the Monaco API for sizing?

When does the editor set the size by default?
It seems to be called twice: once when it initializes and then again when I set the size with setSize
image

Is it possible for me to pass in my size preferences to the editor via createSessionWithProjectAndOpenDocument?

@danzhu54 you cannot pass the size of the editor via createSessionWithProjectAndOpenDocument