Spaces:
Runtime error
Runtime error
Create app.py
Browse files
app.py
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import gradio as gr
|
| 2 |
+
|
| 3 |
+
# สร้างแอปที่มีสองแท็บ
|
| 4 |
+
with gr.Blocks() as app:
|
| 5 |
+
with gr.Tab("Tab 1"):
|
| 6 |
+
gr.Markdown("This is Tab 1") # ข้อความในแท็บแรก
|
| 7 |
+
|
| 8 |
+
with gr.Tab("Tab 2"):
|
| 9 |
+
gr.Markdown("This is Tab 2") # ข้อความในแท็บที่สอง
|
| 10 |
+
|
| 11 |
+
# เรียกใช้งานแอป
|
| 12 |
+
app.launch()
|