shayekh commited on
Commit
850f72a
Β·
verified Β·
1 Parent(s): ce6cd0b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -1
app.py CHANGED
@@ -1983,8 +1983,15 @@ def create_demo():
1983
  ::-webkit-scrollbar-thumb { background: rgba(139, 92, 246, 0.4); border-radius: 3px; }
1984
  ::-webkit-scrollbar-thumb:hover { background: rgba(139, 92, 246, 0.6); }
1985
  """
 
 
 
 
 
 
 
1986
 
1987
- with gr.Blocks(title="LocalDuo", theme=custom_theme, css=css) as demo:
1988
  gr.Markdown("# LocalDuo β€” Learn Korean from PDFs, Websites & YouTube")
1989
  gr.Markdown("πŸ‡°πŸ‡·βœ¨ Enter a website URL 🌐, upload a PDF πŸ“„, upload an audio file 🎡, or paste a YouTube link 🎬. The app uses a **Vision-Language Model (VLM)** 🧠, **ASR** 🎀, and **TTS** πŸ—£οΈ to generate vocabulary flashcards.")
1990
 
 
1983
  ::-webkit-scrollbar-thumb { background: rgba(139, 92, 246, 0.4); border-radius: 3px; }
1984
  ::-webkit-scrollbar-thumb:hover { background: rgba(139, 92, 246, 0.6); }
1985
  """
1986
+ # Force dark mode via JavaScript so Gradio's internal CSS variables default to dark
1987
+ dark_mode_js = """
1988
+ function() {
1989
+ document.body.classList.add('dark');
1990
+ document.documentElement.classList.add('dark');
1991
+ }
1992
+ """
1993
 
1994
+ with gr.Blocks(title="LocalDuo", theme=custom_theme, css=css, js=dark_mode_js) as demo:
1995
  gr.Markdown("# LocalDuo β€” Learn Korean from PDFs, Websites & YouTube")
1996
  gr.Markdown("πŸ‡°πŸ‡·βœ¨ Enter a website URL 🌐, upload a PDF πŸ“„, upload an audio file 🎡, or paste a YouTube link 🎬. The app uses a **Vision-Language Model (VLM)** 🧠, **ASR** 🎀, and **TTS** πŸ—£οΈ to generate vocabulary flashcards.")
1997