jovian commited on
Commit
f02cbcd
·
1 Parent(s): e051a30
Files changed (1) hide show
  1. app.py +11 -11
app.py CHANGED
@@ -401,22 +401,22 @@ header .left a span{
401
 
402
 
403
 
404
- # js_func = """
405
- # function refresh() {
406
- # const url = new URL(window.location);
407
-
408
- # if (url.searchParams.get('__theme') !== 'light') {
409
- # url.searchParams.set('__theme', 'light');
410
- # window.location.href = url.href;
411
- # }
412
- # }
413
 
414
- # """
415
 
416
 
417
 
418
  # Gradio interface components
419
- with gr.Blocks(css = css) as demo:
420
 
421
  gr.HTML("""
422
  <nav>
 
401
 
402
 
403
 
404
+ js_func = """
405
+ function refresh() {
406
+ const url = new URL(window.location);
407
+
408
+ if (url.searchParams.get('__theme') !== 'light') {
409
+ url.searchParams.set('__theme', 'light');
410
+ window.location.href = url.href;
411
+ }
412
+ }
413
 
414
+ """
415
 
416
 
417
 
418
  # Gradio interface components
419
+ with gr.Blocks(css = css,js=js_func) as demo:
420
 
421
  gr.HTML("""
422
  <nav>