microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
165.01k stars 29.55k forks source link

Markdown iframe scrolling issue #180147

Open kolibril13 opened 1 year ago

kolibril13 commented 1 year ago

When I add an Iframe into a VS Code Jupyter markdown cell, it renders correctly. However, as soon as I hover the mouse over this iframe and try to scroll up and down, the notebook does not scroll anymore. I tried to set the parameter scrolling="no" but that did not work eighter. Here is the markdown cell code for reproducing this bug:

<iframe src="https://twitframe.com/show?url=https://twitter.com/code/status/1643989447346892800" width = "300px" height="600px" scrolling="no" overflow="hidden"></iframe>

https://user-images.githubusercontent.com/44469195/230721845-c331aad8-d9fa-4cad-b772-f6905054739a.mov


Additional note: iframes are not at all shown in jupyterlab notebooks at all: https://github.com/ipython/ipython/issues/5711

Environment data

kolibril13 commented 1 year ago

Additional note: When I embed a tweet from an HTML embedding string, the same scrolling issue occurs.

from IPython.core.display import HTML
code = """<blockquote class="twitter-tweet"><p lang="en" dir="ltr">Something I would like to use when teaching with <a href="https://twitter.com/ProjectJupyter?ref_src=twsrc%5Etfw">@ProjectJupyter</a>: step-by-step cell appearance, where correct answers unlock the next section. <a href="https://t.co/NweljI3Xon">pic.twitter.com/NweljI3Xon</a></p>&mdash; Jan-Hendrik Müller (@kolibril13) <a href="https://twitter.com/kolibril13/status/1639262409175990272?ref_src=twsrc%5Etfw">March 24, 2023</a></blockquote> <script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script>"""
HTML(code)
image