model2 commited on
Commit
59cd0a4
·
1 Parent(s): 395a855
Files changed (1) hide show
  1. app.py +4 -48
app.py CHANGED
@@ -268,64 +268,20 @@ def advance_blur(input_image):
268
 
269
  if __name__ == "__main__":
270
  # Updated, more flexible CSS
271
- css_code = """
272
- /* Container for side-by-side example images */
273
- #example-images {
274
- display: flex;
275
- flex-direction: row;
276
- justify-content: center;
277
- align-items: flex-start;
278
- flex-wrap: wrap;
279
- gap: 16px;
280
- margin: 0 auto;
281
- max-width: 680px; /* ✅ NEW: constrain the overall width */
282
- width: 100%;
283
- }
284
-
285
- .example-image {
286
- flex: 1 1 45%;
287
- max-width: 300px;
288
- }
289
-
290
- .example-image img {
291
- width: 100%;
292
- height: auto;
293
- border-radius: 8px;
294
- }
295
-
296
- /* Mobile: allow scroll if necessary */
297
- @media (max-width: 768px) {
298
- #example-images {
299
- flex-wrap: nowrap;
300
- overflow-x: auto;
301
- justify-content: flex-start;
302
- max-width: 320px;
303
- }
304
-
305
- .example-image {
306
- flex: 0 0 auto;
307
- margin-right: 16px;
308
- max-width: 50%;
309
- }
310
-
311
- .example-image img {
312
- max-width: 130px;
313
- }
314
- }
315
- """
316
 
317
  with gr.Blocks(css=css_code, theme=gr.themes.Base()) as app:
318
  gr.Markdown("# 🥸 Advance Blur")
319
 
320
- with gr.Row(elem_id="example-images"):
321
- with gr.Column(elem_classes=["example-image"]):
322
  gr.Image(
323
  value="before.jpg",
324
  label="Before",
325
  show_label=True,
326
  interactive=False,
327
  )
328
- with gr.Column(elem_classes=["example-image"]):
329
  gr.Image(
330
  value="after.jpg",
331
  label="After",
 
268
 
269
  if __name__ == "__main__":
270
  # Updated, more flexible CSS
271
+ css_code = ""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
272
 
273
  with gr.Blocks(css=css_code, theme=gr.themes.Base()) as app:
274
  gr.Markdown("# 🥸 Advance Blur")
275
 
276
+ with gr.Row():
277
+ with gr.Column(scale=1, min_width=160):
278
  gr.Image(
279
  value="before.jpg",
280
  label="Before",
281
  show_label=True,
282
  interactive=False,
283
  )
284
+ with gr.Column(scale=1, min_width=160):
285
  gr.Image(
286
  value="after.jpg",
287
  label="After",