Update app.py
Browse files
app.py
CHANGED
|
@@ -206,4 +206,11 @@ with gr.Blocks(theme="soft", fill_height=True) as demo:
|
|
| 206 |
in_query = gr.Textbox(label="Buscar texto o tag")
|
| 207 |
sel_cat = gr.Dropdown(choices=["todas", "personajes", "fotografia"], value="todas", label="Categor铆a")
|
| 208 |
btn_buscar = gr.Button("Buscar")
|
| 209 |
-
tabla_busqueda = gr.Dataframe(headers=["Categor铆a", "Nombre", "Texto"], interactive=False, wrap=True)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 206 |
in_query = gr.Textbox(label="Buscar texto o tag")
|
| 207 |
sel_cat = gr.Dropdown(choices=["todas", "personajes", "fotografia"], value="todas", label="Categor铆a")
|
| 208 |
btn_buscar = gr.Button("Buscar")
|
| 209 |
+
tabla_busqueda = gr.Dataframe(headers=["Categor铆a", "Nombre", "Texto"], interactive=False, wrap=True)
|
| 210 |
+
btn_buscar.click(
|
| 211 |
+
fn=buscar,
|
| 212 |
+
inputs=[in_query, sel_cat],
|
| 213 |
+
outputs=[tabla_busqueda]
|
| 214 |
+
)
|
| 215 |
+
if __name__ == "__main__":
|
| 216 |
+
demo.launch()
|