dotnet / try

Try .NET provides developers and content authors with tools to create interactive experiences.
MIT License
2.9k stars 527 forks source link

Hide scroll bar in iframe #1210

Closed ocallesp closed 5 months ago

ocallesp commented 5 months ago

https://github.com/dotnet/try/issues/1198

hideScrollBar

Thanks @danzhu54 for the fix suggestion

ocallesp commented 5 months ago

@jwmunn does this change break something on Learning ?

jonsequitur commented 5 months ago

We should close this PR and take a different approach. The editor's API can be called directly by the host page and that's going to be more flexible than one-size-fits-all attempts to remedy this with CSS.

danzhu54 commented 5 months ago

@jonsequitur will you expose a setSize function on your API instead? I believe this change will resolve all editor overflow issues. Learn is facing the same issue: image

colombod commented 5 months ago

Who is the owner of the scroll bars? is it the iframe or the div inside?

colombod commented 5 months ago

This is what I see: The content of the iframe is bigger than the iframe: image the element with class monaco-editor is se to this the size 1245px X 839px in the style sheet (side effect of calling the layout code)

this is the iframe size : image

and this is the actual size of the div image

jonsequitur commented 5 months ago

Let's move this discussion to the associated issue.

https://github.com/dotnet/try/issues/1198#issuecomment-2148221113