Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -107,9 +107,9 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
107 |
|
108 |
result = gr.Markdown()
|
109 |
|
110 |
-
#
|
111 |
def create_button(label, dosha_type, fn):
|
112 |
-
return gr.Button(label, variant="primary").click(fn, inputs=[name, dob, tob, location, tz], outputs=result
|
113 |
|
114 |
gr.Markdown("## 🌟 Dosha Analysis")
|
115 |
with gr.Row():
|
@@ -129,4 +129,3 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
|
|
129 |
gr.Markdown("### 🔍 Enter your details above and click the relevant button to analyze your astrology report!")
|
130 |
|
131 |
demo.launch()
|
132 |
-
|
|
|
107 |
|
108 |
result = gr.Markdown()
|
109 |
|
110 |
+
# Function to create a button with dosha_type as gr.State
|
111 |
def create_button(label, dosha_type, fn):
|
112 |
+
return gr.Button(label, variant="primary").click(fn, inputs=[name, dob, tob, location, tz, gr.State(dosha_type)], outputs=result)
|
113 |
|
114 |
gr.Markdown("## 🌟 Dosha Analysis")
|
115 |
with gr.Row():
|
|
|
129 |
gr.Markdown("### 🔍 Enter your details above and click the relevant button to analyze your astrology report!")
|
130 |
|
131 |
demo.launch()
|
|