Joffrey Thomas commited on
Commit
33bd7ec
·
1 Parent(s): 777bf12
Files changed (1) hide show
  1. app.py +7 -5
app.py CHANGED
@@ -483,8 +483,9 @@ body, .gradio-container, .gradio-container *{color:#111 !important}
483
  .svelte-3lgy39 .wrap-inner, .wrap-inner{ color: inherit; }
484
  #popup-overlay, #popup-overlay * {color:#f9fafb !important}
485
  #popup-overlay #ai-analysis-box, #popup-overlay #ai-analysis-box * { color: #1e293b !important; }
486
- /* Position login button in top right corner */
487
- #login_button {position: fixed !important; top: 16px !important; right: 16px !important; z-index: 1000 !important; box-shadow: 0 2px 8px rgba(0,0,0,0.15) !important;}
 
488
  """
489
 
490
  # Client boot JS to initialize the mini-map reliably in Gradio (scripts in HTML are sanitized)
@@ -704,7 +705,10 @@ APP_BOOT_JS = """
704
  with gr.Blocks(css=APP_CSS, title="LLM GeoGuessr") as demo:
705
  user_profile = gr.State()
706
 
707
- gr.Markdown("## LLM GeoGuessr", elem_id="title_md")
 
 
 
708
  gr.Markdown("""
709
  ### How to Play
710
  1. **Select a difficulty** and click "Start Game".
@@ -714,8 +718,6 @@ with gr.Blocks(css=APP_CSS, title="LLM GeoGuessr") as demo:
714
  """)
715
 
716
  login_prompt_md = gr.Markdown("### Please log in with your Hugging Face account to play.", visible=True)
717
- login_button = LoginButton(visible=True, elem_id="login_button")
718
-
719
  logged_in_md = gr.Markdown(visible=False)
720
 
721
  with gr.Group(visible=False, elem_id="lobby_group") as lobby_group:
 
483
  .svelte-3lgy39 .wrap-inner, .wrap-inner{ color: inherit; }
484
  #popup-overlay, #popup-overlay * {color:#f9fafb !important}
485
  #popup-overlay #ai-analysis-box, #popup-overlay #ai-analysis-box * { color: #1e293b !important; }
486
+ /* Style login button to be compact */
487
+ #login_button {max-width: 180px !important;}
488
+ #login_button button {padding: 6px 14px !important; font-size: 0.9rem !important;}
489
  """
490
 
491
  # Client boot JS to initialize the mini-map reliably in Gradio (scripts in HTML are sanitized)
 
705
  with gr.Blocks(css=APP_CSS, title="LLM GeoGuessr") as demo:
706
  user_profile = gr.State()
707
 
708
+ with gr.Row():
709
+ gr.Markdown("## LLM GeoGuessr", elem_id="title_md")
710
+ login_button = LoginButton(visible=True, elem_id="login_button", scale=0, min_width=180)
711
+
712
  gr.Markdown("""
713
  ### How to Play
714
  1. **Select a difficulty** and click "Start Game".
 
718
  """)
719
 
720
  login_prompt_md = gr.Markdown("### Please log in with your Hugging Face account to play.", visible=True)
 
 
721
  logged_in_md = gr.Markdown(visible=False)
722
 
723
  with gr.Group(visible=False, elem_id="lobby_group") as lobby_group: