corrected code for the gsheet_url component
Browse files
app.py
CHANGED
|
@@ -563,9 +563,16 @@ with gr.Blocks(theme=gr.themes.Soft(), title=APP_TITLE) as app:
|
|
| 563 |
with gr.Column(scale=1):
|
| 564 |
gr.Markdown("### 1. Data Input")
|
| 565 |
file_upload = gr.File(label="Upload CSV File", file_types=[".csv"])
|
| 566 |
-
gsheet_url = gr.Textbox(
|
| 567 |
-
|
| 568 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 569 |
|
| 570 |
gr.Markdown("### 2. Select Columns")
|
| 571 |
text_columns_checkboxgroup = gr.CheckboxGroup(label="Select Text Columns for Analysis", interactive=True)
|
|
|
|
| 563 |
with gr.Column(scale=1):
|
| 564 |
gr.Markdown("### 1. Data Input")
|
| 565 |
file_upload = gr.File(label="Upload CSV File", file_types=[".csv"])
|
| 566 |
+
gsheet_url = gr.Textbox(
|
| 567 |
+
label="Or Paste Google Sheets URL",
|
| 568 |
+
placeholder="https://docs.google.com/spreadsheets/d/e/.../pub?output=csv",
|
| 569 |
+
# FIX: Using triple quotes to create a correctly terminated string
|
| 570 |
+
# that is also more readable.
|
| 571 |
+
info="""How to get the link: In Google Sheets, go to File > Share > Publish to web.
|
| 572 |
+
Select 'Comma-separated values (.csv)' and copy the generated link.
|
| 573 |
+
Example: https://docs.google.com/spreadsheets/d/e/2PACX-1vTn-mRrOCk6fww892XfziUk63pJu9g8uOdy4nHjygKXcN7oO3EAhXLMD7WZAatvoLubSPpMdQ5ymouz/pub?output=csv"""
|
| 574 |
+
)
|
| 575 |
+
|
| 576 |
|
| 577 |
gr.Markdown("### 2. Select Columns")
|
| 578 |
text_columns_checkboxgroup = gr.CheckboxGroup(label="Select Text Columns for Analysis", interactive=True)
|