Workpam commited on
Commit
fd69e1b
Β·
verified Β·
1 Parent(s): 843c61f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -25
app.py CHANGED
@@ -550,12 +550,11 @@ with gr.Blocks(css=css) as demo:
550
  temp_dir_state = gr.State(None)
551
 
552
  gr.HTML(lamp_html)
553
- gr.Markdown("<h1>πŸ–ΌοΈ Image Processor</h1>")
554
-
555
- # ─────── DEFINE STATUS FIRST ───────
556
-
557
  with gr.Row():
 
 
558
  # ─────── LEFT PANEL ───────
 
559
  with gr.Column(scale=3, min_width=500):
560
  with gr.Group(elem_classes="panel"):
561
  mode_toggle = gr.Radio(
@@ -607,31 +606,24 @@ with gr.Blocks(css=css) as demo:
607
  process_btn = gr.Button("βš™οΈ Process", elem_id="process-btn-url")
608
 
609
  with gr.Group(elem_classes="panel"):
610
- format_choice = gr.Dropdown(
611
- ["JPEG","PNG","WEBP","TIFF","GIF","JFIF","AVIF"],
612
- label="πŸ–ΌοΈ Format",
613
- value="JPEG"
614
- )
615
- width = gr.Number(label="Width (px)", value=1000, precision=0)
616
- height = gr.Number(label="Height (px)", value=1000, precision=0)
617
-
618
- with gr.Row(elem_classes="btn-row"):
619
- stop_btn = gr.Button("Stop", elem_id="stop-btn")
620
- clear_btn = gr.Button("Clear", elem_id="clear-btn")
621
 
622
- # ─────── RIGHT PANEL ───────
623
- with gr.Column(scale=2, min_width=400):
624
  with gr.Group(elem_classes="panel"):
625
- status = gr.Textbox(
626
- label="πŸ“£ Status",
627
- lines=18,
628
- interactive=False,
629
- elem_id="status-box"
630
- )
631
  zip_download_btn = gr.Button("πŸ“¦ Download ZIP")
632
- zip_file_hidden = gr.File(visible=False)
633
  with gr.Accordion("🧷 Individual Files", open=False):
634
- single_downloads = gr.File(file_count="multiple")
 
 
 
 
 
 
635
 
636
  # ─────── HOOK UP EVENTS ───────
637
  process_btn.click(
 
550
  temp_dir_state = gr.State(None)
551
 
552
  gr.HTML(lamp_html)
 
 
 
 
553
  with gr.Row():
554
+ gr.Markdown("<h1>πŸ–ΌοΈ Image Processor</h1>")
555
+
556
  # ─────── LEFT PANEL ───────
557
+ with gr.Row():
558
  with gr.Column(scale=3, min_width=500):
559
  with gr.Group(elem_classes="panel"):
560
  mode_toggle = gr.Radio(
 
606
  process_btn = gr.Button("βš™οΈ Process", elem_id="process-btn-url")
607
 
608
  with gr.Group(elem_classes="panel"):
609
+ with gr.Row():
610
+ format_choice = gr.Dropdown(["JPEG","PNG","WEBP","TIFF","GIF","JFIF","AVIF"],label="πŸ–ΌοΈ Format", value="JPEG")
611
+ width = gr.Number(label="Width (px)", value=1000, precision=0)
612
+ height = gr.Number(label="Height (px)", value=1000, precision=0)
 
 
 
 
 
 
 
613
 
614
+ with gr.Column(scale=2):
 
615
  with gr.Group(elem_classes="panel"):
616
+ status = gr.Textbox(label="πŸ“£ Status", lines=6, interactive=False, elem_id="status-box")
 
 
 
 
 
617
  zip_download_btn = gr.Button("πŸ“¦ Download ZIP")
618
+ zip_file_hidden = gr.File(visible=False)
619
  with gr.Accordion("🧷 Individual Files", open=False):
620
+ single_downloads = gr.File(label="Files", file_count="multiple")
621
+
622
+ with gr.Row(elem_classes="btn-row"):
623
+ stop_btn = gr.Button("Stop", elem_id="stop-btn")
624
+ clear_btn = gr.Button("Clear", elem_id="clear-btn")
625
+
626
+ gr.Markdown("<center style='margin-top:1rem;color:white'>Created with πŸ’œ by Vishakha</center>")
627
 
628
  # ─────── HOOK UP EVENTS ───────
629
  process_btn.click(