Spaces:
Runtime error
Runtime error
Tyler Lastovich
commited on
Commit
·
280001e
1
Parent(s):
7d2b5b9
Updating theme for app
Browse files
app.py
CHANGED
|
@@ -142,14 +142,16 @@ custom_css="""
|
|
| 142 |
width: 100vw;
|
| 143 |
max-width: 1500px;
|
| 144 |
}
|
| 145 |
-
.
|
| 146 |
justify-content: flex-end;
|
| 147 |
}
|
| 148 |
-
|
|
|
|
| 149 |
flex: 0 0 0;
|
| 150 |
min-width: 150px;
|
| 151 |
}
|
| 152 |
-
|
|
|
|
| 153 |
background: #11213A;
|
| 154 |
border-radius: 5px;
|
| 155 |
color: #FFFFFF;
|
|
@@ -159,52 +161,55 @@ custom_css="""
|
|
| 159 |
letter-spacing: 0.15em;
|
| 160 |
flex: 0 0 0;
|
| 161 |
}
|
| 162 |
-
.
|
| 163 |
background: #000000;
|
| 164 |
}
|
| 165 |
|
| 166 |
-
.input_text {
|
| 167 |
-
font: 200 50px garamond-premier-pro-display, serif;
|
| 168 |
-
line-height: 115%;
|
| 169 |
-
color: #11213A;
|
| 170 |
-
border-radius: 0px;
|
| 171 |
-
border: 3px solid #11213A;
|
| 172 |
-
}
|
| 173 |
.input_text:focus {
|
| 174 |
border-color: #FA7880;
|
| 175 |
}
|
| 176 |
-
.
|
| 177 |
-
.
|
| 178 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 179 |
}
|
| 180 |
.input_text textarea:focus-visible {
|
| 181 |
outline: none;
|
| 182 |
}
|
|
|
|
| 183 |
.panel:nth-child(1) {
|
| 184 |
margin-left: 50px;
|
| 185 |
margin-right: 50px;
|
| 186 |
-
margin-top: 80px;
|
| 187 |
margin-bottom: 80px;
|
| 188 |
max-width: 750px;
|
| 189 |
}
|
| 190 |
-
.panel
|
| 191 |
-
background:
|
|
|
|
|
|
|
|
|
|
| 192 |
}
|
| 193 |
-
.
|
| 194 |
-
|
| 195 |
}
|
| 196 |
-
.
|
| 197 |
background: transparent;
|
| 198 |
opacity: 1 !important;
|
| 199 |
}"""
|
| 200 |
creative_slider = gr.inputs.Radio(["Low", "Medium", "High"], default="Low", label='Creativity')
|
| 201 |
-
textbox = gr.inputs.Textbox(placeholder='
|
| 202 |
-
label="DESCRIBE YOUR
|
| 203 |
generated = gr.outputs.Image(label='Generated Layout')
|
| 204 |
|
| 205 |
iface = gr.Interface(fn=prompt_to_layout, inputs=[textbox, creative_slider],
|
| 206 |
outputs=[generated],
|
| 207 |
css=custom_css,
|
|
|
|
| 208 |
allow_flagging=False,
|
| 209 |
allow_screenshot=False,
|
| 210 |
thumbnail="thumbnail_gradio.PNG")
|
|
|
|
| 142 |
width: 100vw;
|
| 143 |
max-width: 1500px;
|
| 144 |
}
|
| 145 |
+
.gradio_page[theme=default] .panel_buttons {
|
| 146 |
justify-content: flex-end;
|
| 147 |
}
|
| 148 |
+
|
| 149 |
+
.gradio_page[theme=default] .panel_button {
|
| 150 |
flex: 0 0 0;
|
| 151 |
min-width: 150px;
|
| 152 |
}
|
| 153 |
+
|
| 154 |
+
.gradio_page[theme=default] .gradio_interface .panel_button.submit {
|
| 155 |
background: #11213A;
|
| 156 |
border-radius: 5px;
|
| 157 |
color: #FFFFFF;
|
|
|
|
| 161 |
letter-spacing: 0.15em;
|
| 162 |
flex: 0 0 0;
|
| 163 |
}
|
| 164 |
+
.gradio_page[theme=default] .gradio_interface .panel_button.submit:hover {
|
| 165 |
background: #000000;
|
| 166 |
}
|
| 167 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 168 |
.input_text:focus {
|
| 169 |
border-color: #FA7880;
|
| 170 |
}
|
| 171 |
+
.gradio_page[theme=default] .gradio_interface .input_text input,
|
| 172 |
+
.gradio_page[theme=default] .gradio_interface .input_text textarea {
|
| 173 |
+
font: 200 45px garamond-premier-pro-display, serif;
|
| 174 |
+
line-height: 110%;
|
| 175 |
+
color: #11213A;
|
| 176 |
+
border-radius: 5px;
|
| 177 |
+
padding: 15px;
|
| 178 |
+
border: none;
|
| 179 |
+
background: #F2F4F4;
|
| 180 |
}
|
| 181 |
.input_text textarea:focus-visible {
|
| 182 |
outline: none;
|
| 183 |
}
|
| 184 |
+
|
| 185 |
.panel:nth-child(1) {
|
| 186 |
margin-left: 50px;
|
| 187 |
margin-right: 50px;
|
|
|
|
| 188 |
margin-bottom: 80px;
|
| 189 |
max-width: 750px;
|
| 190 |
}
|
| 191 |
+
.panel {
|
| 192 |
+
background: transparent;
|
| 193 |
+
}
|
| 194 |
+
.panel:nth-child(2) .gradio_page[theme=default] .gradio_interface .component_set {
|
| 195 |
+
background: transparent;
|
| 196 |
}
|
| 197 |
+
.panel:nth-child(2) .gradio_page[theme=default] .gradio_interface .panel_header {
|
| 198 |
+
display: none;
|
| 199 |
}
|
| 200 |
+
.gradio_page[theme=default] .component_set {
|
| 201 |
background: transparent;
|
| 202 |
opacity: 1 !important;
|
| 203 |
}"""
|
| 204 |
creative_slider = gr.inputs.Radio(["Low", "Medium", "High"], default="Low", label='Creativity')
|
| 205 |
+
textbox = gr.inputs.Textbox(placeholder='An apartment with two bedrooms and one bathroom', lines="3",
|
| 206 |
+
label="DESCRIBE YOUR IDEAL APARTMENT")
|
| 207 |
generated = gr.outputs.Image(label='Generated Layout')
|
| 208 |
|
| 209 |
iface = gr.Interface(fn=prompt_to_layout, inputs=[textbox, creative_slider],
|
| 210 |
outputs=[generated],
|
| 211 |
css=custom_css,
|
| 212 |
+
theme="default",
|
| 213 |
allow_flagging=False,
|
| 214 |
allow_screenshot=False,
|
| 215 |
thumbnail="thumbnail_gradio.PNG")
|