Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -23,18 +23,23 @@ def convert_image(image, target_format):
|
|
23 |
except Exception as e:
|
24 |
return f"Error: {e}"
|
25 |
|
26 |
-
#
|
|
|
|
|
|
|
|
|
|
|
27 |
interface = gr.Interface(
|
28 |
fn=convert_image,
|
29 |
inputs=[
|
30 |
-
gr.Image(label="Upload Image", type="filepath", height=
|
31 |
gr.Dropdown(label="Select Target Format", choices=supported_formats)
|
32 |
],
|
33 |
outputs=gr.File(label="Converted Image"),
|
34 |
title="Universal Image Format Converter",
|
35 |
description="Upload an image and select any target format for conversion. Supports all formats recognized by Pillow.",
|
36 |
live=True,
|
37 |
-
|
38 |
)
|
39 |
|
40 |
# Jalankan aplikasi
|
|
|
23 |
except Exception as e:
|
24 |
return f"Error: {e}"
|
25 |
|
26 |
+
# CSS untuk menyembunyikan footer
|
27 |
+
css = """
|
28 |
+
footer {display: none;}
|
29 |
+
"""
|
30 |
+
|
31 |
+
# Antarmuka Gradio dengan tema kustom untuk menyembunyikan footer
|
32 |
interface = gr.Interface(
|
33 |
fn=convert_image,
|
34 |
inputs=[
|
35 |
+
gr.Image(label="Upload Image", type="filepath", height=100), # Atur tinggi gambar input
|
36 |
gr.Dropdown(label="Select Target Format", choices=supported_formats)
|
37 |
],
|
38 |
outputs=gr.File(label="Converted Image"),
|
39 |
title="Universal Image Format Converter",
|
40 |
description="Upload an image and select any target format for conversion. Supports all formats recognized by Pillow.",
|
41 |
live=True,
|
42 |
+
css=css # Menyertakan CSS kustom untuk menghapus footer
|
43 |
)
|
44 |
|
45 |
# Jalankan aplikasi
|