Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -580,6 +580,7 @@ css = '''
|
|
580 |
#random_btn{font-size: 300%}
|
581 |
#component-11{align-self: stretch;}
|
582 |
|
|
|
583 |
/* ๊ฐค๋ฌ๋ฆฌ ๋ฉ์ธ ์ปจํ
์ด๋ */
|
584 |
#lora_gallery {
|
585 |
margin: 20px 0;
|
@@ -589,8 +590,8 @@ css = '''
|
|
589 |
background: linear-gradient(to bottom right, #ffffff, #f8f9fa);
|
590 |
width: 100% !important;
|
591 |
height: 800px !important;
|
592 |
-
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1)
|
593 |
-
|
594 |
}
|
595 |
|
596 |
/* ๊ฐค๋ฌ๋ฆฌ ๊ทธ๋ฆฌ๋ ์ปจํ
์ด๋ */
|
@@ -602,6 +603,7 @@ css = '''
|
|
602 |
width: 100% !important;
|
603 |
height: 100% !important;
|
604 |
overflow-y: auto !important;
|
|
|
605 |
}
|
606 |
|
607 |
/* ๊ฐค๋ฌ๋ฆฌ ์์ดํ
*/
|
@@ -614,6 +616,7 @@ css = '''
|
|
614 |
transition: transform 0.3s ease, box-shadow 0.3s ease;
|
615 |
border-radius: 12px;
|
616 |
overflow: hidden;
|
|
|
617 |
}
|
618 |
|
619 |
/* ๊ฐค๋ฌ๋ฆฌ ์ด๋ฏธ์ง */
|
@@ -624,26 +627,45 @@ css = '''
|
|
624 |
border-radius: 12px !important;
|
625 |
}
|
626 |
|
627 |
-
/* ๊ฐค๋ฌ๋ฆฌ ์์ดํ
ํธ๋ฒ ํจ๊ณผ */
|
628 |
-
.gallery-item:hover {
|
629 |
-
transform: translateY(-5px) scale(1.02);
|
630 |
-
box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
|
631 |
-
z-index: 1;
|
632 |
-
}
|
633 |
-
|
634 |
/* ๊ฐค๋ฌ๋ฆฌ ๊ทธ๋ฆฌ๋ ๋ํผ */
|
635 |
-
.grid-wrap {
|
636 |
width: 100% !important;
|
637 |
-
|
638 |
-
|
|
|
639 |
}
|
640 |
|
641 |
-
/*
|
642 |
.gradio-container {
|
643 |
width: 100% !important;
|
644 |
max-width: none !important;
|
645 |
}
|
646 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
647 |
/* ํ ์ค์ */
|
648 |
.row {
|
649 |
width: 100% !important;
|
@@ -712,14 +734,11 @@ with gr.Blocks(theme=custom_theme, css=css, delete_cache=(60, 3600)) as app:
|
|
712 |
๊ฐค๋ฌ๋ฆฌ์์ ์ํ๋ ๋ชจ๋ธ์ ์ ํ(์ต๋ 3๊ฐ๊น์ง) < ํ๋กฌํํธ์ ํ๊ธ ๋๋ ์๋ฌธ์ผ๋ก ์ํ๋ ๋ด์ฉ์ ์
๋ ฅ < Generate ๋ฒํผ ์คํ
|
713 |
"""
|
714 |
)
|
715 |
-
|
716 |
-
# Gallery ์ปดํฌ๋ํธ ์์
|
717 |
with gr.Row(elem_id="lora_gallery", equal_height=True):
|
718 |
gallery = gr.Gallery(
|
719 |
value=[(item["image"], item["title"]) for item in loras],
|
720 |
label="LoRA Explorer Gallery",
|
721 |
columns=6,
|
722 |
-
rows="auto",
|
723 |
elem_id="gallery",
|
724 |
height="800px",
|
725 |
object_fit="cover",
|
@@ -727,12 +746,11 @@ with gr.Blocks(theme=custom_theme, css=css, delete_cache=(60, 3600)) as app:
|
|
727 |
allow_preview=False,
|
728 |
show_share_button=False,
|
729 |
scale=1,
|
730 |
-
min_width=
|
731 |
container=True,
|
732 |
preview=False
|
733 |
-
)
|
734 |
|
735 |
-
|
736 |
|
737 |
with gr.Tab(label="Generate"):
|
738 |
# Prompt and Generate Button
|
|
|
580 |
#random_btn{font-size: 300%}
|
581 |
#component-11{align-self: stretch;}
|
582 |
|
583 |
+
|
584 |
/* ๊ฐค๋ฌ๋ฆฌ ๋ฉ์ธ ์ปจํ
์ด๋ */
|
585 |
#lora_gallery {
|
586 |
margin: 20px 0;
|
|
|
590 |
background: linear-gradient(to bottom right, #ffffff, #f8f9fa);
|
591 |
width: 100% !important;
|
592 |
height: 800px !important;
|
593 |
+
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
|
594 |
+
display: block !important;
|
595 |
}
|
596 |
|
597 |
/* ๊ฐค๋ฌ๋ฆฌ ๊ทธ๋ฆฌ๋ ์ปจํ
์ด๋ */
|
|
|
603 |
width: 100% !important;
|
604 |
height: 100% !important;
|
605 |
overflow-y: auto !important;
|
606 |
+
max-width: 100% !important;
|
607 |
}
|
608 |
|
609 |
/* ๊ฐค๋ฌ๋ฆฌ ์์ดํ
*/
|
|
|
616 |
transition: transform 0.3s ease, box-shadow 0.3s ease;
|
617 |
border-radius: 12px;
|
618 |
overflow: hidden;
|
619 |
+
flex: 1 1 calc(16.666% - 15px) !important;
|
620 |
}
|
621 |
|
622 |
/* ๊ฐค๋ฌ๋ฆฌ ์ด๋ฏธ์ง */
|
|
|
627 |
border-radius: 12px !important;
|
628 |
}
|
629 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
630 |
/* ๊ฐค๋ฌ๋ฆฌ ๊ทธ๋ฆฌ๋ ๋ํผ */
|
631 |
+
.grid-wrap, .grid-container {
|
632 |
width: 100% !important;
|
633 |
+
max-width: 100% !important;
|
634 |
+
margin: 0 !important;
|
635 |
+
display: block !important;
|
636 |
}
|
637 |
|
638 |
+
/* Gradio ์ปจํ
์ด๋ ์์ */
|
639 |
.gradio-container {
|
640 |
width: 100% !important;
|
641 |
max-width: none !important;
|
642 |
}
|
643 |
|
644 |
+
.gradio-container .contain {
|
645 |
+
width: 100% !important;
|
646 |
+
max-width: 100% !important;
|
647 |
+
display: block !important;
|
648 |
+
}
|
649 |
+
|
650 |
+
/* ํ ์ปจํ
์ด๋ ์์ */
|
651 |
+
.row > * {
|
652 |
+
width: 100% !important;
|
653 |
+
max-width: 100% !important;
|
654 |
+
}
|
655 |
+
|
656 |
+
/* ๊ฐค๋ฌ๋ฆฌ ์ปจํ
์ด๋ ๊ฐ์ ์ค์ */
|
657 |
+
.gallery-container {
|
658 |
+
width: 100% !important;
|
659 |
+
max-width: 100% !important;
|
660 |
+
display: block !important;
|
661 |
+
}
|
662 |
+
|
663 |
+
/* ๊ฐค๋ฌ๋ฆฌ ์์ดํ
์ปจํ
์ด๋ */
|
664 |
+
.gallery-item-container {
|
665 |
+
width: 100% !important;
|
666 |
+
display: contents !important;
|
667 |
+
}
|
668 |
+
|
669 |
/* ํ ์ค์ */
|
670 |
.row {
|
671 |
width: 100% !important;
|
|
|
734 |
๊ฐค๋ฌ๋ฆฌ์์ ์ํ๋ ๋ชจ๋ธ์ ์ ํ(์ต๋ 3๊ฐ๊น์ง) < ํ๋กฌํํธ์ ํ๊ธ ๋๋ ์๋ฌธ์ผ๋ก ์ํ๋ ๋ด์ฉ์ ์
๋ ฅ < Generate ๋ฒํผ ์คํ
|
735 |
"""
|
736 |
)
|
|
|
|
|
737 |
with gr.Row(elem_id="lora_gallery", equal_height=True):
|
738 |
gallery = gr.Gallery(
|
739 |
value=[(item["image"], item["title"]) for item in loras],
|
740 |
label="LoRA Explorer Gallery",
|
741 |
columns=6,
|
|
|
742 |
elem_id="gallery",
|
743 |
height="800px",
|
744 |
object_fit="cover",
|
|
|
746 |
allow_preview=False,
|
747 |
show_share_button=False,
|
748 |
scale=1,
|
749 |
+
min_width="100%", # ์์
|
750 |
container=True,
|
751 |
preview=False
|
752 |
+
)
|
753 |
|
|
|
754 |
|
755 |
with gr.Tab(label="Generate"):
|
756 |
# Prompt and Generate Button
|