Use shadowRoot if inside of an iframe and don't use it if outside
This makes sure it will work everywhere
This commit is contained in:
parent
2eb5f103ab
commit
1075819b16
1 changed files with 1 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
||||||
function gradioApp(){
|
function gradioApp(){
|
||||||
return document
|
return !!document.getElementsByTagName('gradio-app')[0].shadowRoot ? document.getElementsByTagName('gradio-app')[0].shadowRoot : document
|
||||||
}
|
}
|
||||||
|
|
||||||
function get_uiCurrentTab() {
|
function get_uiCurrentTab() {
|
||||||
|
|
Loading…
Reference in a new issue