Spaces:
Running
Running
Zenith Wang
commited on
Commit
·
613a3b0
1
Parent(s):
50845b1
Adjust File component height to match text input box
Browse files
app.py
CHANGED
@@ -247,11 +247,22 @@ css = """
|
|
247 |
font-size: 12px !important;
|
248 |
}
|
249 |
.compact-image .upload-container {
|
250 |
-
min-height:
|
|
|
251 |
}
|
252 |
.compact-image .wrap .or {
|
253 |
display: none !important;
|
254 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
255 |
"""
|
256 |
|
257 |
with gr.Blocks(title="Step-3", theme=gr.themes.Soft(), css=css) as demo:
|
@@ -290,7 +301,8 @@ with gr.Blocks(title="Step-3", theme=gr.themes.Soft(), css=css) as demo:
|
|
290 |
file_count="multiple",
|
291 |
file_types=[".png", ".jpg", ".jpeg", ".gif", ".webp"],
|
292 |
interactive=True,
|
293 |
-
show_label=True
|
|
|
294 |
)
|
295 |
with gr.Column(scale=1, min_width=100):
|
296 |
submit_btn = gr.Button("Send", variant="primary")
|
|
|
247 |
font-size: 12px !important;
|
248 |
}
|
249 |
.compact-image .upload-container {
|
250 |
+
min-height: 60px !important;
|
251 |
+
max-height: 60px !important;
|
252 |
}
|
253 |
.compact-image .wrap .or {
|
254 |
display: none !important;
|
255 |
}
|
256 |
+
.compact-file input[type="file"] {
|
257 |
+
height: 60px !important;
|
258 |
+
}
|
259 |
+
.compact-file .file-preview {
|
260 |
+
max-height: 60px !important;
|
261 |
+
overflow-y: auto !important;
|
262 |
+
}
|
263 |
+
.compact-file > div {
|
264 |
+
height: 60px !important;
|
265 |
+
}
|
266 |
"""
|
267 |
|
268 |
with gr.Blocks(title="Step-3", theme=gr.themes.Soft(), css=css) as demo:
|
|
|
301 |
file_count="multiple",
|
302 |
file_types=[".png", ".jpg", ".jpeg", ".gif", ".webp"],
|
303 |
interactive=True,
|
304 |
+
show_label=True,
|
305 |
+
elem_classes="compact-file"
|
306 |
)
|
307 |
with gr.Column(scale=1, min_width=100):
|
308 |
submit_btn = gr.Button("Send", variant="primary")
|