diff options
author | apolinario <joaopaulo.passos@gmail.com> | 2022-12-06 14:13:41 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-06 14:13:41 +0000 |
commit | 1075819b16ef328805dd946acaffd43efa2eb444 (patch) | |
tree | 34629bd77c187788d87a194cce6a459495d26b9f /script.js | |
parent | 2eb5f103ab1b41477440cc391165ea7ef5f7f959 (diff) | |
download | stable-diffusion-webui-gfx803-1075819b16ef328805dd946acaffd43efa2eb444.tar.gz stable-diffusion-webui-gfx803-1075819b16ef328805dd946acaffd43efa2eb444.tar.bz2 stable-diffusion-webui-gfx803-1075819b16ef328805dd946acaffd43efa2eb444.zip |
Use shadowRoot if inside of an iframe and don't use it if outside
This makes sure it will work everywhere
Diffstat (limited to 'script.js')
-rw-r--r-- | script.js | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1,5 +1,5 @@ function gradioApp(){ - return document + return !!document.getElementsByTagName('gradio-app')[0].shadowRoot ? document.getElementsByTagName('gradio-app')[0].shadowRoot : document } function get_uiCurrentTab() { |