Spaces:
Running
Running
Upload 25 files
Browse files- _res/_custom.css +300 -524
- _res/_custom.js +110 -21
- _res/assets/icons.ai +0 -0
- _res/assets/random_dark.svg +16 -0
- _res/assets/random_dark_48.png +0 -0
- _res/assets/random_light.svg +20 -0
- _res/assets/random_light_48.png +0 -0
- _res/assets/run_1_dark.svg +16 -0
- _res/assets/run_1_dark_48.png +0 -0
- _res/assets/run_1_light.svg +20 -0
- _res/assets/run_1_light_48.png +0 -0
- _res/assets/star_dark.svg +16 -0
- _res/assets/star_dark_48.png +0 -0
- _res/assets/star_light.svg +20 -0
- _res/assets/star_light_48.png +0 -0
- _res/testimages/1.png +0 -0
- _res/testimages/10.png +0 -0
- _res/testimages/2.png +0 -0
- _res/testimages/3.png +0 -0
- _res/testimages/4.png +0 -0
- _res/testimages/5.png +0 -0
- _res/testimages/6.png +0 -0
- _res/testimages/7.png +0 -0
- _res/testimages/8.png +0 -0
- _res/testimages/9.png +0 -0
_res/_custom.css
CHANGED
|
@@ -1,524 +1,300 @@
|
|
| 1 |
-
/* :root {
|
| 2 |
-
--
|
| 3 |
-
--primary-50:
|
| 4 |
-
--primary-100:
|
| 5 |
-
--primary-200:
|
| 6 |
-
--primary-300:
|
| 7 |
-
--primary-400:
|
| 8 |
-
--primary-500:
|
| 9 |
-
--primary-600:
|
| 10 |
-
--primary-
|
| 11 |
-
--primary-
|
| 12 |
-
--primary-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
--
|
| 17 |
-
--
|
| 18 |
-
--
|
| 19 |
-
--
|
| 20 |
-
--
|
| 21 |
-
--
|
| 22 |
-
--
|
| 23 |
-
--
|
| 24 |
-
--
|
| 25 |
-
--
|
| 26 |
-
--
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
--
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
--
|
| 46 |
-
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
--
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
|
| 55 |
-
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
--
|
| 61 |
-
-
|
| 62 |
-
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
--
|
| 79 |
-
--
|
| 80 |
-
-
|
| 81 |
-
|
| 82 |
-
-
|
| 83 |
-
-
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
-
|
| 90 |
-
|
| 91 |
-
|
| 92 |
-
|
| 93 |
-
-
|
| 94 |
-
|
| 95 |
-
|
| 96 |
-
-
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
-
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
-
|
| 106 |
-
-
|
| 107 |
-
-
|
| 108 |
-
--
|
| 109 |
-
|
| 110 |
-
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
-
|
| 114 |
-
|
| 115 |
-
|
| 116 |
-
|
| 117 |
-
-
|
| 118 |
-
|
| 119 |
-
|
| 120 |
-
|
| 121 |
-
|
| 122 |
-
|
| 123 |
-
-
|
| 124 |
-
-
|
| 125 |
-
|
| 126 |
-
-
|
| 127 |
-
|
| 128 |
-
|
| 129 |
-
|
| 130 |
-
-
|
| 131 |
-
-
|
| 132 |
-
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
--
|
| 136 |
-
|
| 137 |
-
|
| 138 |
-
|
| 139 |
-
--
|
| 140 |
-
|
| 141 |
-
-
|
| 142 |
-
-
|
| 143 |
-
-
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
|
| 147 |
-
-
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
|
| 159 |
-
|
| 160 |
-
|
| 161 |
-
|
| 162 |
-
|
| 163 |
-
|
| 164 |
-
|
| 165 |
-
|
| 166 |
-
|
| 167 |
-
|
| 168 |
-
|
| 169 |
-
|
| 170 |
-
|
| 171 |
-
|
| 172 |
-
|
| 173 |
-
-
|
| 174 |
-
-
|
| 175 |
-
|
| 176 |
-
|
| 177 |
-
|
| 178 |
-
-
|
| 179 |
-
-
|
| 180 |
-
|
| 181 |
-
--
|
| 182 |
-
-
|
| 183 |
-
-
|
| 184 |
-
-
|
| 185 |
-
|
| 186 |
-
|
| 187 |
-
|
| 188 |
-
|
| 189 |
-
|
| 190 |
-
|
| 191 |
-
|
| 192 |
-
|
| 193 |
-
|
| 194 |
-
|
| 195 |
-
|
| 196 |
-
|
| 197 |
-
|
| 198 |
-
|
| 199 |
-
|
| 200 |
-
|
| 201 |
-
|
| 202 |
-
|
| 203 |
-
|
| 204 |
-
|
| 205 |
-
|
| 206 |
-
|
| 207 |
-
|
| 208 |
-
.
|
| 209 |
-
|
| 210 |
-
|
| 211 |
-
|
| 212 |
-
|
| 213 |
-
|
| 214 |
-
|
| 215 |
-
|
| 216 |
-
|
| 217 |
-
|
| 218 |
-
|
| 219 |
-
-
|
| 220 |
-
|
| 221 |
-
|
| 222 |
-
|
| 223 |
-
|
| 224 |
-
|
| 225 |
-
|
| 226 |
-
|
| 227 |
-
|
| 228 |
-
|
| 229 |
-
|
| 230 |
-
|
| 231 |
-
|
| 232 |
-
|
| 233 |
-
|
| 234 |
-
|
| 235 |
-
|
| 236 |
-
|
| 237 |
-
|
| 238 |
-
|
| 239 |
-
|
| 240 |
-
|
| 241 |
-
-
|
| 242 |
-
--
|
| 243 |
-
-
|
| 244 |
-
|
| 245 |
-
--
|
| 246 |
-
|
| 247 |
-
|
| 248 |
-
-
|
| 249 |
-
-
|
| 250 |
-
-
|
| 251 |
-
|
| 252 |
-
|
| 253 |
-
|
| 254 |
-
|
| 255 |
-
|
| 256 |
-
|
| 257 |
-
|
| 258 |
-
|
| 259 |
-
|
| 260 |
-
-
|
| 261 |
-
|
| 262 |
-
|
| 263 |
-
|
| 264 |
-
|
| 265 |
-
|
| 266 |
-
|
| 267 |
-
|
| 268 |
-
|
| 269 |
-
|
| 270 |
-
|
| 271 |
-
|
| 272 |
-
|
| 273 |
-
|
| 274 |
-
|
| 275 |
-
|
| 276 |
-
|
| 277 |
-
|
| 278 |
-
|
| 279 |
-
|
| 280 |
-
-
|
| 281 |
-
|
| 282 |
-
|
| 283 |
-
|
| 284 |
-
|
| 285 |
-
|
| 286 |
-
|
| 287 |
-
|
| 288 |
-
|
| 289 |
-
|
| 290 |
-
|
| 291 |
-
|
| 292 |
-
-
|
| 293 |
-
|
| 294 |
-
|
| 295 |
-
|
| 296 |
-
|
| 297 |
-
|
| 298 |
-
|
| 299 |
-
|
| 300 |
-
|
| 301 |
-
--primary-50: #fdf2f8;
|
| 302 |
-
--primary-100: #fce7f3;
|
| 303 |
-
--primary-200: #fbcfe8;
|
| 304 |
-
--primary-300: #f9a8d4;
|
| 305 |
-
--primary-400: #f472b6;
|
| 306 |
-
--primary-500: #ec4899;
|
| 307 |
-
--primary-600: #db2777;
|
| 308 |
-
--primary-700: #be185d;
|
| 309 |
-
--primary-800: #9d174d;
|
| 310 |
-
--primary-900: #831843;
|
| 311 |
-
--primary-950: #6e1a3d;
|
| 312 |
-
--secondary-50: #eef2ff;
|
| 313 |
-
--secondary-100: #e0e7ff;
|
| 314 |
-
--secondary-200: #c7d2fe;
|
| 315 |
-
--secondary-300: #a5b4fc;
|
| 316 |
-
--secondary-400: #818cf8;
|
| 317 |
-
--secondary-500: #6366f1;
|
| 318 |
-
--secondary-600: #4f46e5;
|
| 319 |
-
--secondary-700: #4338ca;
|
| 320 |
-
--secondary-800: #3730a3;
|
| 321 |
-
--secondary-900: #312e81;
|
| 322 |
-
--secondary-950: #2b2c5e;
|
| 323 |
-
--neutral-50: #f9fafb;
|
| 324 |
-
--neutral-100: #f3f4f6;
|
| 325 |
-
--neutral-200: #e5e7eb;
|
| 326 |
-
--neutral-300: #d1d5db;
|
| 327 |
-
--neutral-400: #9ca3af;
|
| 328 |
-
--neutral-500: #6b7280;
|
| 329 |
-
--neutral-600: #4b5563;
|
| 330 |
-
--neutral-700: #374151;
|
| 331 |
-
--neutral-800: #1f2937;
|
| 332 |
-
--neutral-900: #111827;
|
| 333 |
-
--neutral-950: #0b0f19;
|
| 334 |
-
--spacing-xxs: 1px;
|
| 335 |
-
--spacing-xs: 2px;
|
| 336 |
-
--spacing-sm: 4px;
|
| 337 |
-
--spacing-md: 6px;
|
| 338 |
-
--spacing-lg: 8px;
|
| 339 |
-
--spacing-xl: 10px;
|
| 340 |
-
--spacing-xxl: 16px;
|
| 341 |
-
--radius-xxs: 1px;
|
| 342 |
-
--radius-xs: 1px;
|
| 343 |
-
--radius-sm: 2px;
|
| 344 |
-
--radius-md: 4px;
|
| 345 |
-
--radius-lg: 6px;
|
| 346 |
-
--radius-xl: 8px;
|
| 347 |
-
--radius-xxl: 12px;
|
| 348 |
-
--text-xxs: 9px;
|
| 349 |
-
--text-xs: 10px;
|
| 350 |
-
--text-sm: 12px;
|
| 351 |
-
--text-md: 14px;
|
| 352 |
-
--text-lg: 16px;
|
| 353 |
-
--text-xl: 22px;
|
| 354 |
-
--text-xxl: 26px;
|
| 355 |
-
--font: 'Montserrat', 'ui-sans-serif', 'system-ui', sans-serif;
|
| 356 |
-
--font-mono: 'IBM Plex Mono', 'ui-monospace', 'Consolas', monospace;
|
| 357 |
-
--body-text-size: var(--text-md);
|
| 358 |
-
--body-text-weight: 400;
|
| 359 |
-
--embed-radius: var(--radius-lg);
|
| 360 |
-
--color-accent: var(--primary-500);
|
| 361 |
-
--shadow-drop: 0 1px 4px 0 rgb(0 0 0 / 0.1);
|
| 362 |
-
--shadow-drop-lg: 0 2px 5px 0 rgb(0 0 0 / 0.1);
|
| 363 |
-
--shadow-inset: rgba(0, 0, 0, 0.05) 0px 2px 4px 0px inset;
|
| 364 |
-
--block-border-width: 0px;
|
| 365 |
-
--block-info-text-size: var(--text-sm);
|
| 366 |
-
--block-info-text-weight: 400;
|
| 367 |
-
--block-label-border-width: 1px;
|
| 368 |
-
--block-label-shadow: var(--block-shadow);
|
| 369 |
-
--block-label-margin: var(--spacing-md);
|
| 370 |
-
--block-label-padding: var(--spacing-sm) var(--spacing-md);
|
| 371 |
-
--block-label-radius: var(--radius-md);
|
| 372 |
-
--block-label-right-radius: 0 calc(var(--radius-lg) - 1px) 0 calc(var(--radius-lg) - 1px);
|
| 373 |
-
--block-label-text-size: var(--text-md);
|
| 374 |
-
--block-label-text-weight: 600;
|
| 375 |
-
--block-padding: var(--spacing-xl) calc(var(--spacing-xl) + 2px);
|
| 376 |
-
--block-radius: var(--radius-lg);
|
| 377 |
-
--block-shadow: none;
|
| 378 |
-
--block-title-background-fill: var(--block-label-background-fill);
|
| 379 |
-
--block-title-border-color: none;
|
| 380 |
-
--block-title-border-width: 0px;
|
| 381 |
-
--block-title-padding: var(--block-label-padding);
|
| 382 |
-
--block-title-radius: var(--block-label-radius);
|
| 383 |
-
--block-title-text-size: var(--text-md);
|
| 384 |
-
--block-title-text-weight: 600;
|
| 385 |
-
--container-radius: var(--radius-lg);
|
| 386 |
-
--form-gap-width: 0px;
|
| 387 |
-
--layout-gap: var(--spacing-xxl);
|
| 388 |
-
--panel-border-width: 1px;
|
| 389 |
-
--section-header-text-size: var(--text-md);
|
| 390 |
-
--section-header-text-weight: 400;
|
| 391 |
-
--checkbox-border-radius: var(--radius-sm);
|
| 392 |
-
--checkbox-label-gap: var(--spacing-lg);
|
| 393 |
-
--checkbox-label-padding: var(--spacing-md) calc(2 * var(--spacing-md));
|
| 394 |
-
--checkbox-label-shadow: var(--shadow-drop-lg);
|
| 395 |
-
--checkbox-label-text-size: var(--text-md);
|
| 396 |
-
--checkbox-label-text-weight: 400;
|
| 397 |
-
--checkbox-check: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e");
|
| 398 |
-
--radio-circle: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e");
|
| 399 |
-
--checkbox-shadow: none;
|
| 400 |
-
--error-border-width: 1px;
|
| 401 |
-
--input-border-width: 0px;
|
| 402 |
-
--input-padding: var(--spacing-xl);
|
| 403 |
-
--input-radius: var(--radius-lg);
|
| 404 |
-
--input-shadow: var(--shadow-drop);
|
| 405 |
-
--input-shadow-focus: var(--shadow-drop-lg);
|
| 406 |
-
--input-text-size: var(--text-md);
|
| 407 |
-
--input-text-weight: 400;
|
| 408 |
-
--loader-color: var(--color-accent);
|
| 409 |
-
--prose-text-size: var(--text-md);
|
| 410 |
-
--prose-text-weight: 400;
|
| 411 |
-
--prose-header-text-weight: 600;
|
| 412 |
-
--table-radius: var(--radius-lg);
|
| 413 |
-
--button-large-padding: var(--spacing-lg) calc(2 * var(--spacing-lg));
|
| 414 |
-
--button-large-radius: var(--radius-lg);
|
| 415 |
-
--button-large-text-size: var(--text-lg);
|
| 416 |
-
--button-large-text-weight: 600;
|
| 417 |
-
--button-shadow: var(--shadow-drop-lg);
|
| 418 |
-
--button-shadow-active: var(--shadow-inset);
|
| 419 |
-
--button-shadow-hover: var(--shadow-drop-lg);
|
| 420 |
-
--button-small-padding: var(--spacing-sm) calc(2 * var(--spacing-sm));
|
| 421 |
-
--button-small-radius: var(--radius-lg);
|
| 422 |
-
--button-small-text-size: var(--text-md);
|
| 423 |
-
--button-small-text-weight: 400;
|
| 424 |
-
--button-transition: background-color 0.2s ease;
|
| 425 |
-
} */
|
| 426 |
-
|
| 427 |
-
body>gradio-app {
|
| 428 |
-
background: var(--primary-950);
|
| 429 |
-
background: linear-gradient(180deg, color-mix(in srgb, var(--primary-950), transparent 50%) 0%, color-mix(in srgb, var(--primary-950), transparent 50%) 28%, var(--neutral-950) 28%, var(--neutral-950) 100%) !important;
|
| 430 |
-
padding-top: 120px;
|
| 431 |
-
min-widh: 900px;
|
| 432 |
-
}
|
| 433 |
-
|
| 434 |
-
gradio-app .gradio-container {
|
| 435 |
-
max-width: 80% !important;
|
| 436 |
-
}
|
| 437 |
-
|
| 438 |
-
div.tabs>div.tab-nav>button.selected {
|
| 439 |
-
border-width: 0 !important;
|
| 440 |
-
background: var(--primary-600) !important;
|
| 441 |
-
color: var(--neutral-950);
|
| 442 |
-
font-weight: 600;
|
| 443 |
-
}
|
| 444 |
-
|
| 445 |
-
div.tabs>div.tab-nav {
|
| 446 |
-
border-bottom: none !important;
|
| 447 |
-
padding: 0 0.25rem 0 0.25rem !important;
|
| 448 |
-
}
|
| 449 |
-
|
| 450 |
-
div.tabs div.tabitem {
|
| 451 |
-
background-color: var(--neutral-900) !important;
|
| 452 |
-
border-width: 0 !important;
|
| 453 |
-
border-top: 8px solid var(--primary-600) !important;
|
| 454 |
-
border-radius: var(--container-radius) !important;
|
| 455 |
-
}
|
| 456 |
-
|
| 457 |
-
.top-description h1 {
|
| 458 |
-
color: var(--neutral-400);
|
| 459 |
-
font-size: 2rem;
|
| 460 |
-
}
|
| 461 |
-
|
| 462 |
-
.prompt-input textarea {
|
| 463 |
-
font-size: 1.2rem;
|
| 464 |
-
color: var(--neutral-300);
|
| 465 |
-
}
|
| 466 |
-
|
| 467 |
-
.ratio_buttons_wrapper {
|
| 468 |
-
display: flex !important;
|
| 469 |
-
flex-grow: 0 !important;
|
| 470 |
-
min-width: min(48px, 30%) !important;
|
| 471 |
-
flex: 1 1 0%;
|
| 472 |
-
flex-wrap: nowrap;
|
| 473 |
-
}
|
| 474 |
-
|
| 475 |
-
.image_size_selctor_wrapper {
|
| 476 |
-
flex-grow: 2 !important;
|
| 477 |
-
min-width: min(120px, 10%) !important;
|
| 478 |
-
}
|
| 479 |
-
|
| 480 |
-
.info-text-wrapper {
|
| 481 |
-
padding: calc(var(--spacing-xl) / 2) calc(var(--spacing-xl) + 2px);
|
| 482 |
-
}
|
| 483 |
-
|
| 484 |
-
span.info-text {
|
| 485 |
-
margin-bottom: var(--spacing-lg);
|
| 486 |
-
color: var(--block-info-text-color);
|
| 487 |
-
font-weight: var(--block-info-text-weight);
|
| 488 |
-
font-size: var(--block-info-text-size);
|
| 489 |
-
line-height: var(--line-sm);
|
| 490 |
-
}
|
| 491 |
-
|
| 492 |
-
.image-input-read-exfi {
|
| 493 |
-
max-height: 120px;
|
| 494 |
-
}
|
| 495 |
-
|
| 496 |
-
.image-input-read-exfi>button {
|
| 497 |
-
transform: scale(.8);
|
| 498 |
-
}
|
| 499 |
-
|
| 500 |
-
.image-ratio-buttons {
|
| 501 |
-
& label input {
|
| 502 |
-
display: none;
|
| 503 |
-
}
|
| 504 |
-
|
| 505 |
-
&label span {
|
| 506 |
-
margin-left: 0;
|
| 507 |
-
}
|
| 508 |
-
}
|
| 509 |
-
|
| 510 |
-
.switch-ratio-btn {
|
| 511 |
-
max-width: 38px;
|
| 512 |
-
min-width: 38px !important;
|
| 513 |
-
height: 33px;
|
| 514 |
-
}
|
| 515 |
-
|
| 516 |
-
/* .image-height-selector {
|
| 517 |
-
& div.head {
|
| 518 |
-
justify-content: end;
|
| 519 |
-
}
|
| 520 |
-
|
| 521 |
-
& label {
|
| 522 |
-
display: none;
|
| 523 |
-
}
|
| 524 |
-
} */
|
|
|
|
| 1 |
+
/* :root {
|
| 2 |
+
--primary-700: rgb(67, 56, 202);
|
| 3 |
+
--primary-50: color-mix(in srgb, var(--primary-700) 5%, white);
|
| 4 |
+
--primary-100: color-mix(in srgb, var(--primary-700) 10%, white);
|
| 5 |
+
--primary-200: color-mix(in srgb, var(--primary-700) 20%, white);
|
| 6 |
+
--primary-300: color-mix(in srgb, var(--primary-700) 60%, white);
|
| 7 |
+
--primary-400: color-mix(in srgb, var(--primary-700) 70%, white);
|
| 8 |
+
--primary-500: color-mix(in srgb, var(--primary-700) 80%, white);
|
| 9 |
+
--primary-600: color-mix(in srgb, var(--primary-700) 90%, white);
|
| 10 |
+
--primary-800: color-mix(in srgb, var(--primary-700) 70%, black);
|
| 11 |
+
--primary-900: color-mix(in srgb, var(--primary-700) 80%, black);
|
| 12 |
+
--primary-950: color-mix(in srgb, var(--primary-700) 90%, black);
|
| 13 |
+
}
|
| 14 |
+
|
| 15 |
+
.dark {
|
| 16 |
+
--primary-700: rgb(67, 56, 202);
|
| 17 |
+
--primary-50: color-mix(in srgb, var(--primary-700) 5%, white);
|
| 18 |
+
--primary-100: color-mix(in srgb, var(--primary-700) 10%, white);
|
| 19 |
+
--primary-200: color-mix(in srgb, var(--primary-700) 20%, white);
|
| 20 |
+
--primary-300: color-mix(in srgb, var(--primary-700) 60%, white);
|
| 21 |
+
--primary-400: color-mix(in srgb, var(--primary-700) 70%, white);
|
| 22 |
+
--primary-500: color-mix(in srgb, var(--primary-700) 80%, white);
|
| 23 |
+
--primary-600: color-mix(in srgb, var(--primary-700) 90%, white);
|
| 24 |
+
--primary-800: color-mix(in srgb, var(--primary-700) 70%, black);
|
| 25 |
+
--primary-900: color-mix(in srgb, var(--primary-700) 80%, black);
|
| 26 |
+
--primary-950: color-mix(in srgb, var(--primary-700) 90%, black);
|
| 27 |
+
} */
|
| 28 |
+
|
| 29 |
+
/* width */
|
| 30 |
+
::-webkit-scrollbar {
|
| 31 |
+
width: 0px;
|
| 32 |
+
}
|
| 33 |
+
|
| 34 |
+
body::-webkit-scrollbar {
|
| 35 |
+
width: 8px;
|
| 36 |
+
}
|
| 37 |
+
|
| 38 |
+
/* Track */
|
| 39 |
+
::-webkit-scrollbar-track {
|
| 40 |
+
background: var(--neutral-900);
|
| 41 |
+
}
|
| 42 |
+
|
| 43 |
+
/* Handle */
|
| 44 |
+
::-webkit-scrollbar-thumb {
|
| 45 |
+
background: var(--primary-600);
|
| 46 |
+
border-radius: 3px;
|
| 47 |
+
}
|
| 48 |
+
|
| 49 |
+
/* Handle on hover */
|
| 50 |
+
::-webkit-scrollbar-thumb:hover {
|
| 51 |
+
background: var(--primary-800);
|
| 52 |
+
}
|
| 53 |
+
|
| 54 |
+
body {
|
| 55 |
+
min-height: 101vh;
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
body>gradio-app {
|
| 59 |
+
/* background: var(--primary-950);
|
| 60 |
+
background-image: linear-gradient(180deg, color-mix(in srgb, var(--primary-950), transparent 50%) 0%, color-mix(in srgb, var(--primary-950), transparent 50%) 28%, var(--neutral-950) 28%, var(--neutral-950) 100%) !important; */
|
| 61 |
+
padding-top: 120px;
|
| 62 |
+
min-width: 900px;
|
| 63 |
+
transition: opacity 0.4s linear;
|
| 64 |
+
position: relative;
|
| 65 |
+
}
|
| 66 |
+
|
| 67 |
+
body>gradio-app::before {
|
| 68 |
+
position: absolute;
|
| 69 |
+
content: "";
|
| 70 |
+
background: var(--primary-950);
|
| 71 |
+
width: 100%;
|
| 72 |
+
height: 355px;
|
| 73 |
+
top: 0;
|
| 74 |
+
z-index: 0;
|
| 75 |
+
}
|
| 76 |
+
|
| 77 |
+
body>gradio-app.has-bg-image::before {
|
| 78 |
+
/* --bg-image-path: none; */
|
| 79 |
+
/* --bg-image-path: url("https://image.pollinations.ai/prompt/A%20midnight%20blue%20stallion%20gallops%20across%20a%20misty%2C%20moonlit%20meadow%2C%20its%20mane%20and%20tail%20flowing%20in%20the%20wind%20like%20a%20celestial%20river%2C%20as%20stars%20twinkle%20in%20the%20sky%20above%20-%20Expressionist%20Watercolor%20Painting?model=flux&width=1024&height=683&nologo=true&enhance=false&nofeed=true&seed=42"); */
|
| 80 |
+
background-image: var(--bg-image-path);
|
| 81 |
+
background-size: cover;
|
| 82 |
+
background-position: center;
|
| 83 |
+
background-repeat: no-repeat;
|
| 84 |
+
filter: blur(12px);
|
| 85 |
+
|
| 86 |
+
}
|
| 87 |
+
|
| 88 |
+
gradio-app .gradio-container {
|
| 89 |
+
max-width: 80% !important;
|
| 90 |
+
}
|
| 91 |
+
|
| 92 |
+
div.tabs>div.tab-nav>button.selected {
|
| 93 |
+
border-width: 0 !important;
|
| 94 |
+
background: var(--primary-600) !important;
|
| 95 |
+
color: var(--neutral-950);
|
| 96 |
+
font-weight: 600;
|
| 97 |
+
}
|
| 98 |
+
|
| 99 |
+
div.tabs>div.tab-nav {
|
| 100 |
+
border-bottom: none !important;
|
| 101 |
+
padding: 0 0.25rem 0 0.25rem !important;
|
| 102 |
+
}
|
| 103 |
+
|
| 104 |
+
div.tabs div.tabitem {
|
| 105 |
+
background-color: var(--neutral-900) !important;
|
| 106 |
+
border-width: 0 !important;
|
| 107 |
+
border-top: 8px solid var(--primary-600) !important;
|
| 108 |
+
border-radius: var(--container-radius) !important;
|
| 109 |
+
}
|
| 110 |
+
|
| 111 |
+
.top-description h1 {
|
| 112 |
+
color: var(--neutral-400);
|
| 113 |
+
font-size: 2rem;
|
| 114 |
+
}
|
| 115 |
+
|
| 116 |
+
.prompt-input textarea {
|
| 117 |
+
font-size: 1.2rem;
|
| 118 |
+
color: var(--neutral-300);
|
| 119 |
+
}
|
| 120 |
+
|
| 121 |
+
.ratio_buttons_wrapper {
|
| 122 |
+
display: flex !important;
|
| 123 |
+
flex-grow: 0 !important;
|
| 124 |
+
min-width: min(48px, 30%) !important;
|
| 125 |
+
flex: 1 1 0%;
|
| 126 |
+
flex-wrap: nowrap;
|
| 127 |
+
}
|
| 128 |
+
|
| 129 |
+
.image_size_selctor_wrapper {
|
| 130 |
+
flex-grow: 2 !important;
|
| 131 |
+
min-width: min(120px, 10%) !important;
|
| 132 |
+
}
|
| 133 |
+
|
| 134 |
+
.info-text-wrapper {
|
| 135 |
+
padding: calc(var(--spacing-xl) / 2) calc(var(--spacing-xl) + 2px);
|
| 136 |
+
}
|
| 137 |
+
|
| 138 |
+
span.info-text {
|
| 139 |
+
margin-bottom: var(--spacing-lg);
|
| 140 |
+
color: var(--block-info-text-color);
|
| 141 |
+
font-weight: var(--block-info-text-weight);
|
| 142 |
+
font-size: var(--block-info-text-size);
|
| 143 |
+
line-height: var(--line-sm);
|
| 144 |
+
}
|
| 145 |
+
|
| 146 |
+
.image-input-read-exfi {
|
| 147 |
+
max-height: 120px;
|
| 148 |
+
}
|
| 149 |
+
|
| 150 |
+
.image-input-read-exfi>button {
|
| 151 |
+
transform: scale(.8);
|
| 152 |
+
}
|
| 153 |
+
|
| 154 |
+
.image-ratio-buttons {
|
| 155 |
+
height: 120px;
|
| 156 |
+
|
| 157 |
+
& label {
|
| 158 |
+
width: calc(25% - calc(var(--spacing-xl) + 2px) * 2 / 4);
|
| 159 |
+
justify-content: center;
|
| 160 |
+
align-items: end;
|
| 161 |
+
|
| 162 |
+
& input {
|
| 163 |
+
display: none;
|
| 164 |
+
}
|
| 165 |
+
}
|
| 166 |
+
|
| 167 |
+
& label span {
|
| 168 |
+
margin-left: 0;
|
| 169 |
+
}
|
| 170 |
+
}
|
| 171 |
+
|
| 172 |
+
span.has-info+div {
|
| 173 |
+
margin-top: var(--spacing-lg);
|
| 174 |
+
margin-bottom: var(--spacing-lg);
|
| 175 |
+
}
|
| 176 |
+
|
| 177 |
+
.switch-ratio-btn {
|
| 178 |
+
/* max-width: 38px;
|
| 179 |
+
min-width: 38px !important;
|
| 180 |
+
height: 33px; */
|
| 181 |
+
--icon-ratio: 3/2;
|
| 182 |
+
aspect-ratio: 1;
|
| 183 |
+
min-width: 40px;
|
| 184 |
+
max-width: 120px;
|
| 185 |
+
|
| 186 |
+
& svg {
|
| 187 |
+
fill: var(--block-title-text-color);
|
| 188 |
+
width: 70%;
|
| 189 |
+
transition: transform 0.2s ease-in-out;
|
| 190 |
+
}
|
| 191 |
+
|
| 192 |
+
& svg.portrait {
|
| 193 |
+
transform: rotate(90deg) rotateX(180deg);
|
| 194 |
+
}
|
| 195 |
+
}
|
| 196 |
+
|
| 197 |
+
.switch-ratio-btn:hover {
|
| 198 |
+
& svg {
|
| 199 |
+
transform: rotate(40deg);
|
| 200 |
+
}
|
| 201 |
+
|
| 202 |
+
& svg.portrait {
|
| 203 |
+
transform: rotate(40deg) rotateX(180deg);
|
| 204 |
+
}
|
| 205 |
+
}
|
| 206 |
+
|
| 207 |
+
/* .image-height-selector {
|
| 208 |
+
& div.head {
|
| 209 |
+
justify-content: end;
|
| 210 |
+
}
|
| 211 |
+
#component-5057 > label > input
|
| 212 |
+
& label {
|
| 213 |
+
display: none;
|
| 214 |
+
}
|
| 215 |
+
} */
|
| 216 |
+
|
| 217 |
+
.fade-bg *,
|
| 218 |
+
.fade-bg .primary {
|
| 219 |
+
/* transition: background-color 0.8s ease-in-out;
|
| 220 |
+
transition: background 0.8s ease-in-out; */
|
| 221 |
+
/* transition: background-color 1.8s linear; */
|
| 222 |
+
/* transition: background 1.8s linear; */
|
| 223 |
+
}
|
| 224 |
+
|
| 225 |
+
.output-dominant-image-color {
|
| 226 |
+
display: none;
|
| 227 |
+
}
|
| 228 |
+
|
| 229 |
+
.image-info-wrapper {
|
| 230 |
+
transition: opacity 0.4s linear;
|
| 231 |
+
/* opacity: 0;
|
| 232 |
+
display: none; */
|
| 233 |
+
}
|
| 234 |
+
|
| 235 |
+
.tb-img-width input[type=text],
|
| 236 |
+
.tb-img-height input[type=text],
|
| 237 |
+
.tb-img-seed input[type=text] {
|
| 238 |
+
display: block;
|
| 239 |
+
position: relative;
|
| 240 |
+
outline: none !important;
|
| 241 |
+
box-shadow: var(--input-shadow);
|
| 242 |
+
border: var(--input-border-width) solid var(--input-border-color);
|
| 243 |
+
border-radius: var(--input-radius);
|
| 244 |
+
background: var(--input-background-fill);
|
| 245 |
+
padding: var(--size-2) var(--size-2);
|
| 246 |
+
height: var(--size-6);
|
| 247 |
+
color: var(--body-text-color);
|
| 248 |
+
font-size: var(--input-text-size);
|
| 249 |
+
line-height: var(--line-sm);
|
| 250 |
+
text-align: center;
|
| 251 |
+
}
|
| 252 |
+
|
| 253 |
+
#output_image>div.image-container>div.icon-buttons {
|
| 254 |
+
|
| 255 |
+
|
| 256 |
+
/* display: flex;
|
| 257 |
+
position: absolute;
|
| 258 |
+
top: var(--block-label-margin);
|
| 259 |
+
right: var(--block-label-margin);
|
| 260 |
+
align-items: center; */
|
| 261 |
+
& button,
|
| 262 |
+
a button {
|
| 263 |
+
display: inline-block;
|
| 264 |
+
position: relative;
|
| 265 |
+
z-index: var(--layer-4);
|
| 266 |
+
border: solid var(--block-title-border-width) var(--block-title-border-color);
|
| 267 |
+
border-radius: var(--block-title-radius);
|
| 268 |
+
background: var(--block-title-background-fill);
|
| 269 |
+
padding: var(--block-title-padding);
|
| 270 |
+
color: var(--block-title-text-color);
|
| 271 |
+
font-weight: var(--block-title-text-weight);
|
| 272 |
+
font-size: var(--block-title-text-size);
|
| 273 |
+
line-height: var(--line-sm);
|
| 274 |
+
}
|
| 275 |
+
}
|
| 276 |
+
|
| 277 |
+
.random-prompt-btn,
|
| 278 |
+
.enhance-prompt-btn,
|
| 279 |
+
.run-btn {
|
| 280 |
+
min-width: 110px;
|
| 281 |
+
|
| 282 |
+
& svg {
|
| 283 |
+
fill: var(--block-title-text-color);
|
| 284 |
+
width: 1.8rem;
|
| 285 |
+
}
|
| 286 |
+
|
| 287 |
+
}
|
| 288 |
+
|
| 289 |
+
.image-height-selector>label,
|
| 290 |
+
.image-width-selector>label {
|
| 291 |
+
display: flex;
|
| 292 |
+
justify-content: space-between;
|
| 293 |
+
|
| 294 |
+
& input {
|
| 295 |
+
min-width: 100px;
|
| 296 |
+
width: 50%;
|
| 297 |
+
height: var(--size-9);
|
| 298 |
+
}
|
| 299 |
+
|
| 300 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_res/_custom.js
CHANGED
|
@@ -1,24 +1,113 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
}
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15 |
})
|
| 16 |
-
})
|
| 17 |
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23 |
})
|
| 24 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
function gradioColorChange() {
|
| 2 |
+
function onDomChange(callback) {
|
| 3 |
+
const observer = new MutationObserver(callback)
|
| 4 |
+
observer.observe(document.querySelector("#dominant_image_color"), {
|
| 5 |
+
childList: true,
|
| 6 |
+
subtree: true,
|
| 7 |
+
})
|
| 8 |
+
}
|
| 9 |
+
|
| 10 |
+
onDomChange(() => {
|
| 11 |
+
console.log("changed: " + document.querySelector("#dominant_image_color > label > textarea").value)
|
| 12 |
+
if (document.querySelector("#dominant_image_color > label > textarea").value.match(/^rgb\((\d{1,3}),(\s\d{1,3}),(\s\d{1,3})\)$/) && document.querySelector("#output_image > div.image-container.svelte-1p15vfy > button > div > img").src) {
|
| 13 |
+
document.querySelector("#output_image > div.image-container.svelte-1p15vfy > button > div > img").style.opacity = "0"
|
| 14 |
+
document.querySelector("body > gradio-app > div").classList.add("fade-bg")
|
| 15 |
+
document.querySelector("gradio-app").style.opacity = "0"
|
| 16 |
+
setTimeout(() => {
|
| 17 |
+
document.querySelector("body").style.setProperty("--primary-700", document.querySelector("#dominant_image_color > label > textarea").value)
|
| 18 |
+
document.querySelector("gradio-app").classList.add("has-bg-image")
|
| 19 |
+
document.querySelector("body").style.setProperty("--bg-image-path", `url("${document.querySelector("#output_image > div.image-container.svelte-1p15vfy > button > div > img").src}")`)
|
| 20 |
+
}, 400)
|
| 21 |
+
setTimeout(() => {
|
| 22 |
+
document.querySelector("gradio-app").style.opacity = "1"
|
| 23 |
+
document.querySelector("#output_image > div.image-container.svelte-1p15vfy > button > div > img").style.opacity = "1"
|
| 24 |
+
document.querySelector("#dominant_image_color > label > textarea").value = ""
|
| 25 |
+
}, 800)
|
| 26 |
+
setTimeout(() => {
|
| 27 |
+
//document.querySelector("body > gradio-app > div").classList.remove("fade-bg")
|
| 28 |
+
}, 2000)
|
| 29 |
+
}
|
| 30 |
+
//document.querySelector("body").style.setProperty("--primary-700", document.querySelector("#dominant_image_color > label > textarea").value)
|
| 31 |
})
|
|
|
|
| 32 |
|
| 33 |
+
document.querySelector("body").style.setProperty("--primary-700", "rgb(14, 116, 144)")
|
| 34 |
+
document.querySelector("body").style.setProperty("--primary-50", "color-mix(in srgb, var(--primary-700) 5%, white)")
|
| 35 |
+
document.querySelector("body").style.setProperty("--primary-100", "color-mix(in srgb, var(--primary-700) 10%, white)")
|
| 36 |
+
document.querySelector("body").style.setProperty("--primary-200", "color-mix(in srgb, var(--primary-700) 20%, white)")
|
| 37 |
+
document.querySelector("body").style.setProperty("--primary-300", "color-mix(in srgb, var(--primary-700) 60%, white)")
|
| 38 |
+
document.querySelector("body").style.setProperty("--primary-400", "color-mix(in srgb, var(--primary-700) 70%, white)")
|
| 39 |
+
document.querySelector("body").style.setProperty("--primary-500", "color-mix(in srgb, var(--primary-700) 80%, white)")
|
| 40 |
+
document.querySelector("body").style.setProperty("--primary-600", "color-mix(in srgb, var(--primary-700) 90%, white)")
|
| 41 |
+
document.querySelector("body").style.setProperty("--primary-800", "color-mix(in srgb, var(--primary-700) 70%, black)")
|
| 42 |
+
document.querySelector("body").style.setProperty("--primary-900", "color-mix(in srgb, var(--primary-700) 80%, black)")
|
| 43 |
+
document.querySelector("body").style.setProperty("--primary-950", "color-mix(in srgb, var(--primary-700) 90%, black)")
|
| 44 |
+
|
| 45 |
+
const imageRatioBtns = document.querySelectorAll("#image_ratio_buttons > div label")
|
| 46 |
+
const width_selector = document.querySelector("#image_width_selector > label > input")
|
| 47 |
+
const hight_selector = document.querySelector("#image_height_selector > label > input")
|
| 48 |
+
const switch_width_height = document.querySelector("#switch_width_height")
|
| 49 |
+
|
| 50 |
+
const random_prompt_btn = document.querySelector("#random_prompt_btn")
|
| 51 |
+
random_prompt_btn.innerHTML =
|
| 52 |
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><g data-name="Ebene_1"><path fill="none" d="M0 48V0h48v48z"/><path d="M42.15 9.85C41.58 9.28 40.9 9 40.12 9H7.88c-.78 0-1.46.28-2.03.85S5 11.1 5 11.88v24.23c0 .78.28 1.46.85 2.03s1.25.85 2.03.85h32.23c.78 0 1.46-.28 2.03-.85s.85-1.25.85-2.03V11.88c0-.78-.28-1.46-.85-2.03ZM13.66 30.78c-.68 0-1.24-.55-1.24-1.24s.55-1.24 1.24-1.24 1.24.55 1.24 1.24-.55 1.24-1.24 1.24Zm2.8-7.78-1.3 1.8c-.32.45-.41.76-.48 1.23-.04.26-.13.48-.28.64-.17.19-.42.29-.73.29s-.56-.12-.73-.31c-.16-.18-.25-.42-.25-.73 0-.68.12-1.09.65-1.8l1.48-2c.33-.45.58-.87.58-1.47 0-1.04-.75-1.83-1.83-1.83-.52 0-.99.15-1.36.52-.29.29-.43.65-.55 1.12-.06.22-.16.47-.27.58-.15.17-.39.29-.7.29-.26 0-.49-.1-.66-.29-.18-.2-.23-.42-.23-.71 0-.67.35-1.58 1.03-2.22.68-.65 1.62-1.03 2.73-1.03 2.11 0 3.79 1.4 3.79 3.57 0 1-.35 1.62-.89 2.36Zm7.28 7.78c-.68 0-1.24-.55-1.24-1.24s.55-1.24 1.24-1.24 1.24.55 1.24 1.24-.55 1.24-1.24 1.24Zm2.8-7.78-1.3 1.8c-.32.45-.41.76-.48 1.23-.04.26-.13.48-.28.64-.17.19-.42.29-.73.29s-.56-.12-.73-.31c-.16-.18-.25-.42-.25-.73 0-.68.12-1.09.65-1.8l1.48-2c.33-.45.58-.87.58-1.47 0-1.04-.75-1.83-1.83-1.83-.52 0-.99.15-1.36.52-.29.29-.43.65-.55 1.12-.06.22-.16.47-.27.58-.15.17-.39.29-.7.29-.26 0-.49-.1-.66-.29-.18-.2-.23-.42-.23-.71 0-.67.35-1.58 1.03-2.22.68-.65 1.62-1.03 2.73-1.03 2.11 0 3.79 1.4 3.79 3.57 0 1-.35 1.62-.89 2.36Zm7.28 7.78c-.68 0-1.24-.55-1.24-1.24s.55-1.24 1.24-1.24 1.24.55 1.24 1.24-.55 1.24-1.24 1.24Zm2.8-7.78-1.3 1.8c-.32.45-.41.76-.48 1.23-.04.26-.13.48-.28.64-.17.19-.42.29-.73.29s-.56-.12-.73-.31c-.16-.18-.25-.42-.25-.73 0-.68.12-1.09.65-1.8l1.48-2c.33-.45.58-.87.58-1.47 0-1.04-.75-1.83-1.83-1.83-.52 0-.99.15-1.36.52-.29.29-.43.65-.55 1.12-.06.22-.16.47-.27.58-.15.17-.39.29-.7.29-.26 0-.49-.1-.66-.29-.18-.2-.23-.42-.23-.71 0-.67.35-1.58 1.03-2.22.68-.65 1.62-1.03 2.73-1.03 2.11 0 3.79 1.4 3.79 3.57 0 1-.35 1.62-.89 2.36Z"/></g></svg>'
|
| 53 |
+
const enhance_prompt_btn = document.querySelector("#enhance_prompt_btn")
|
| 54 |
+
enhance_prompt_btn.innerHTML =
|
| 55 |
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><g data-name="Ebene_1"><path fill="none" d="M0 48V0h48v48z"/><path d="m33.91 29.59 9.37-8.07h.38c.4.05.72.21.95.49.23.28.35.59.35.91 0 .18-.05.37-.14.55-.09.18-.22.35-.37.5l-7.55 6.48 2.31 10s.04.1.04.17v.14c0 .41-.14.73-.42.98-.28.24-.6.37-.97.37-.12 0-.24-.01-.37-.04s-.25-.07-.37-.13l-.4-.27-2.8-12.09Zm-4.95-15.31-3-7.1.16-.33c.1-.27.26-.47.5-.63.24-.15.49-.23.75-.23.24 0 .49.07.74.22s.43.36.55.65l3.25 7.67-2.95-.26ZM12.1 37.29l8.69-5.23 8.69 5.29-2.3-9.9 7.65-6.64-10.09-.89-3.95-9.31-3.95 9.25-10.09.89 7.65 6.66-2.3 9.88Zm-3.09 1.65 2.44-10.56-8.16-7.13c-.2-.18-.35-.38-.46-.59-.11-.22-.16-.42-.16-.63 0-.41.14-.79.43-1.14.29-.34.67-.53 1.14-.55l10.8-.96 4.18-9.96c.13-.34.34-.59.64-.76.3-.17.6-.25.91-.25s.62.08.93.25c.31.17.53.42.66.76l4.18 9.96 10.8.96c.48.02.86.21 1.15.55.29.34.44.72.44 1.13 0 .22-.06.44-.18.65-.12.21-.27.4-.47.58l-8.16 7.13 2.47 10.56c.03.09.05.21.05.36 0 .48-.17.89-.51 1.22-.34.33-.73.49-1.16.49-.09 0-.4-.09-.93-.27l-9.26-5.59-9.26 5.59c-.14.08-.29.14-.46.19-.16.05-.31.08-.44.08-.5 0-.94-.21-1.31-.62-.37-.41-.48-.9-.32-1.45Z"/></g></svg>'
|
| 56 |
+
const run_btn = document.querySelector("#run_btn")
|
| 57 |
+
run_btn.innerHTML =
|
| 58 |
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><g data-name="Ebene_1"><path fill="none" d="M0 48V0h48v48z"/><path d="M29.27 43.84V33.13l-6.01-5.57-1.89 8.38c-.1.4-.31.7-.64.92-.33.21-.69.28-1.08.22L9.48 34.99c-.28-.06-.51-.21-.69-.46s-.24-.54-.19-.86c.05-.3.21-.53.48-.68s.54-.2.82-.15l8.99 1.79 3.86-19.69-5.88 2.67v5.52c0 .33-.11.6-.33.82-.22.22-.5.33-.83.33-.33 0-.61-.11-.82-.33-.22-.22-.33-.5-.33-.82V17c0-.3.08-.58.25-.82.17-.24.38-.43.65-.55l7.42-3.07c.94-.41 1.62-.67 2.04-.78.42-.11.83-.17 1.22-.17.6 0 1.14.13 1.61.4.47.27.88.66 1.21 1.17l2.12 3.37c.79 1.27 1.85 2.4 3.16 3.39 1.31.99 2.81 1.62 4.5 1.91.33.06.61.2.83.42.23.22.34.49.34.8s-.11.6-.34.82c-.23.22-.49.31-.81.27-1.84-.22-3.58-.87-5.2-1.96-1.62-1.09-3.12-2.68-4.49-4.79l-2.09 9.07 4.11 3.88c.16.14.28.31.36.49.08.19.13.38.13.57v12.42c0 .33-.11.6-.34.82-.23.22-.5.33-.82.33s-.61-.11-.82-.33c-.22-.22-.33-.5-.33-.82Zm-.06-34.83c-.97 0-1.8-.34-2.48-1.02-.68-.68-1.03-1.51-1.03-2.48s.34-1.8 1.02-2.48C27.4 2.35 28.23 2 29.2 2s1.8.34 2.48 1.02c.68.68 1.03 1.51 1.03 2.48s-.34 1.8-1.02 2.48c-.68.68-1.51 1.03-2.48 1.03Z"/></g></svg>'
|
| 59 |
+
|
| 60 |
+
switch_width_height.innerHTML =
|
| 61 |
+
'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48"><g data-name="Ebene_1"><path fill="none" d="M0 48V0h48v48z"/><path d="M33.75 22.5V6.01c0-1.84-1.5-3.34-3.34-3.34H5.01c-1.84 0-3.34 1.5-3.34 3.34V22.5c0 1.84 1.5 3.34 3.34 3.34h25.4c1.84 0 3.34-1.5 3.34-3.34Zm-29.41 0V6.01c0-.37.3-.67.67-.67h25.4c.37 0 .67.3.67.67V22.5c0 .37-.3.67-.67.67H5.01a.67.67 0 0 1-.67-.67Z"/><path d="M39.65 15.1c-.41-.72-1.33-.97-2.05-.56s-.97 1.33-.56 2.05C38.32 18.84 39 21.4 39 24c0 8.27-6.73 15-15 15-5.2 0-9.91-2.61-12.68-7H16c.83 0 1.5-.67 1.5-1.5S16.83 29 16 29H7.5c-.83 0-1.5.67-1.5 1.5V39c0 .83.67 1.5 1.5 1.5S9 39.83 9 39v-5.06C12.35 39 17.9 42 24 42c9.93 0 18-8.07 18-18 0-3.12-.81-6.2-2.35-8.9Z"/></g></svg>'
|
| 62 |
+
|
| 63 |
+
switch_width_height.addEventListener("click", () => {
|
| 64 |
+
switch_width_height.querySelector("svg").classList.toggle("portrait")
|
| 65 |
+
switch_width_height.querySelector("svg").classList.toggle("landscape")
|
| 66 |
+
|
| 67 |
+
imageRatioBtns.forEach((_) => {
|
| 68 |
+
const ratio = _.querySelector("input").value
|
| 69 |
+
const [a, b] = ratio.split(":")
|
| 70 |
+
_.dataset.testid = `${b}:${a}-radio-label`
|
| 71 |
+
_.querySelector("input").value = `${b}:${a}`
|
| 72 |
+
_.querySelector("span").textContent = `${b}:${a}`
|
| 73 |
+
})
|
| 74 |
+
|
| 75 |
+
const imageRatioBtnsLabel = document.querySelector("#image_ratio_buttons > span")
|
| 76 |
+
imageRatioBtnsLabel.textContent = imageRatioBtnsLabel.textContent === "Querformat" ? "Hochformat" : "Querformat"
|
| 77 |
+
const new_hight = width_selector.value
|
| 78 |
+
const new_width = hight_selector.value
|
| 79 |
+
width_selector.value = new_width
|
| 80 |
+
hight_selector.value = new_hight
|
| 81 |
})
|
| 82 |
+
|
| 83 |
+
//document.querySelector("#image_ratio_buttons > div.wrap.svelte-1kzox3m > label")
|
| 84 |
+
imageRatioBtns.forEach((_) => {
|
| 85 |
+
_.querySelector("input").addEventListener("click", (e) => {
|
| 86 |
+
let set_width
|
| 87 |
+
let set_height
|
| 88 |
+
const clicked_on = e.target
|
| 89 |
+
console.log("Clicked Btn:", clicked_on.value)
|
| 90 |
+
|
| 91 |
+
const ratio = e.target.value
|
| 92 |
+
const [a, b] = ratio.split(":")
|
| 93 |
+
|
| 94 |
+
if (parseInt(a) > parseInt(b)) {
|
| 95 |
+
console.log("a: " + a + " > " + "b: " + b)
|
| 96 |
+
set_width = 1024
|
| 97 |
+
set_height = Math.round(set_width * (b / a))
|
| 98 |
+
} else if (parseInt(a) < parseInt(b)) {
|
| 99 |
+
console.log("a: " + a + " < " + "b: " + b)
|
| 100 |
+
set_height = 1024
|
| 101 |
+
set_width = Math.round(set_height * (a / b))
|
| 102 |
+
} else if (parseInt(a) == parseInt(b)) {
|
| 103 |
+
set_height = 1024
|
| 104 |
+
set_width = 1024
|
| 105 |
+
}
|
| 106 |
+
|
| 107 |
+
width_selector.value = set_width
|
| 108 |
+
hight_selector.value = set_height
|
| 109 |
+
})
|
| 110 |
+
})
|
| 111 |
+
|
| 112 |
+
return "Animation created"
|
| 113 |
+
}
|
_res/assets/icons.ai
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
_res/assets/random_dark.svg
ADDED
|
|
_res/assets/random_dark_48.png
ADDED
|
_res/assets/random_light.svg
ADDED
|
|
_res/assets/random_light_48.png
ADDED
|
_res/assets/run_1_dark.svg
ADDED
|
|
_res/assets/run_1_dark_48.png
ADDED
|
_res/assets/run_1_light.svg
ADDED
|
|
_res/assets/run_1_light_48.png
ADDED
|
_res/assets/star_dark.svg
ADDED
|
|
_res/assets/star_dark_48.png
ADDED
|
_res/assets/star_light.svg
ADDED
|
|
_res/assets/star_light_48.png
ADDED
|
_res/testimages/1.png
ADDED
|
_res/testimages/10.png
ADDED
|
_res/testimages/2.png
ADDED
|
_res/testimages/3.png
ADDED
|
_res/testimages/4.png
ADDED
|
_res/testimages/5.png
ADDED
|
_res/testimages/6.png
ADDED
|
_res/testimages/7.png
ADDED
|
_res/testimages/8.png
ADDED
|
_res/testimages/9.png
ADDED
|