Spaces:
Running
Running
Add title component to Gradio app for improved user guidance; enhance description for clarity and support.
Browse files
app.py
CHANGED
|
@@ -352,6 +352,12 @@ def respond(message, history: list[tuple[str, str]]):
|
|
| 352 |
|
| 353 |
# Create the Gradio app with Blocks for better control
|
| 354 |
with gr.Blocks(theme=gr.themes.Monochrome(), css=style, fill_height=True) as demo:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 355 |
# Description component that can be hidden
|
| 356 |
description = gr.HTML(
|
| 357 |
value='<div class="app-description">🤖 Este chatbot te guía <strong>paso a paso</strong> para crear credenciales de API de <strong>Gmail</strong> (Google Cloud) ☁️ o <strong>OneDrive</strong> (Microsoft Entra ID) 🔑. Puedes enviar 📸 <strong>capturas de pantalla</strong> para recibir ayuda visual personalizada. El asistente te dará <strong>una instrucción a la vez</strong> para que no te abrumes ✨</div>',
|
|
@@ -361,10 +367,10 @@ with gr.Blocks(theme=gr.themes.Monochrome(), css=style, fill_height=True) as dem
|
|
| 361 |
# State to track if first message has been sent
|
| 362 |
first_message_sent = gr.State(False)
|
| 363 |
|
| 364 |
-
# ChatInterface without description (handled separately above)
|
| 365 |
chat = gr.ChatInterface(
|
| 366 |
fn=respond,
|
| 367 |
-
title="
|
| 368 |
description="",
|
| 369 |
textbox=gr.MultimodalTextbox(
|
| 370 |
file_types=["image", ".png", ".jpg", ".jpeg", ".webp", ".gif"],
|
|
|
|
| 352 |
|
| 353 |
# Create the Gradio app with Blocks for better control
|
| 354 |
with gr.Blocks(theme=gr.themes.Monochrome(), css=style, fill_height=True) as demo:
|
| 355 |
+
# Title component
|
| 356 |
+
title = gr.Markdown(
|
| 357 |
+
value="# Gmail & Outlook API Helper",
|
| 358 |
+
visible=True
|
| 359 |
+
)
|
| 360 |
+
|
| 361 |
# Description component that can be hidden
|
| 362 |
description = gr.HTML(
|
| 363 |
value='<div class="app-description">🤖 Este chatbot te guía <strong>paso a paso</strong> para crear credenciales de API de <strong>Gmail</strong> (Google Cloud) ☁️ o <strong>OneDrive</strong> (Microsoft Entra ID) 🔑. Puedes enviar 📸 <strong>capturas de pantalla</strong> para recibir ayuda visual personalizada. El asistente te dará <strong>una instrucción a la vez</strong> para que no te abrumes ✨</div>',
|
|
|
|
| 367 |
# State to track if first message has been sent
|
| 368 |
first_message_sent = gr.State(False)
|
| 369 |
|
| 370 |
+
# ChatInterface without title and description (handled separately above)
|
| 371 |
chat = gr.ChatInterface(
|
| 372 |
fn=respond,
|
| 373 |
+
title="",
|
| 374 |
description="",
|
| 375 |
textbox=gr.MultimodalTextbox(
|
| 376 |
file_types=["image", ".png", ".jpg", ".jpeg", ".webp", ".gif"],
|