Spaces:
Running
Running
full width
Browse files
app.py
CHANGED
|
@@ -12,7 +12,7 @@ from huggingface_hub import HfApi
|
|
| 12 |
READ_PARQUET_FUNCTIONS = ("dd.read_parquet", "pd.read_parquet")
|
| 13 |
EMPTY_TABLE = pa.Table.from_pylist([{str(i): "" for i in range(4)}] * 10)
|
| 14 |
EMPTY_DF: pd.DataFrame = EMPTY_TABLE.to_pandas()
|
| 15 |
-
NUM_ROWS =
|
| 16 |
MAX_NUM_COLUMNS = 20
|
| 17 |
NUM_TRENDING_DATASETS = 10
|
| 18 |
NUM_USER_DATASETS = 10
|
|
@@ -46,7 +46,10 @@ thead {
|
|
| 46 |
font-size: .75rem;
|
| 47 |
color: var(--block-title-text-color);
|
| 48 |
}
|
| 49 |
-
|
|
|
|
|
|
|
|
|
|
| 50 |
"""
|
| 51 |
js = """
|
| 52 |
function load() {
|
|
@@ -133,7 +136,9 @@ with gr.Blocks(css=css, js=js) as demo:
|
|
| 133 |
dataset_subset_split_textbox = gr.Textbox(visible=False)
|
| 134 |
input_table_state = gr.State()
|
| 135 |
run_button = gr.Button(visible=False, elem_id="run_button")
|
| 136 |
-
gr.
|
|
|
|
|
|
|
| 137 |
with gr.Group():
|
| 138 |
with gr.Row():
|
| 139 |
dataset_dropdown = gr.Dropdown(label="Dataset", allow_custom_value=True, scale=10)
|
|
|
|
| 12 |
READ_PARQUET_FUNCTIONS = ("dd.read_parquet", "pd.read_parquet")
|
| 13 |
EMPTY_TABLE = pa.Table.from_pylist([{str(i): "" for i in range(4)}] * 10)
|
| 14 |
EMPTY_DF: pd.DataFrame = EMPTY_TABLE.to_pandas()
|
| 15 |
+
NUM_ROWS = 20
|
| 16 |
MAX_NUM_COLUMNS = 20
|
| 17 |
NUM_TRENDING_DATASETS = 10
|
| 18 |
NUM_USER_DATASETS = 10
|
|
|
|
| 46 |
font-size: .75rem;
|
| 47 |
color: var(--block-title-text-color);
|
| 48 |
}
|
| 49 |
+
.gradio-container {
|
| 50 |
+
padding: var(--size-4) 0 !important;
|
| 51 |
+
max-width: 98% !important;
|
| 52 |
+
}
|
| 53 |
"""
|
| 54 |
js = """
|
| 55 |
function load() {
|
|
|
|
| 136 |
dataset_subset_split_textbox = gr.Textbox(visible=False)
|
| 137 |
input_table_state = gr.State()
|
| 138 |
run_button = gr.Button(visible=False, elem_id="run_button")
|
| 139 |
+
with gr.Row():
|
| 140 |
+
with gr.Column():
|
| 141 |
+
gr.Markdown("# <p style='text-align:center;'>π₯ DuckDB Spreadsheets π</p>\n\n<p style='text-align:center;'>Edit any dataset on Hugging Face (full list <a href='https://huggingface.co/datasets' target='_blank'>here</a>) using DuckDB functions (documentation <a href='https://duckdb.org/docs/sql/functions/overview' target='_blank'>here</a>)</p>")
|
| 142 |
with gr.Group():
|
| 143 |
with gr.Row():
|
| 144 |
dataset_dropdown = gr.Dropdown(label="Dataset", allow_custom_value=True, scale=10)
|