Spaces:
Sleeping
Sleeping
Fix UTM links
Browse files
app.py
CHANGED
|
@@ -24,12 +24,6 @@ POLL_MAX_SECONDS = 120
|
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
-
# ============ UTM Tracking ============
|
| 28 |
-
UTM_CAMPAIGN = "upscaler_comparison"
|
| 29 |
-
|
| 30 |
-
def add_utm(base_url: str, content: str) -> str:
|
| 31 |
-
separator = "&" if "?" in base_url else "?"
|
| 32 |
-
return f"{base_url}{separator}utm_source=huggingface&utm_medium=space&utm_campaign={UTM_CAMPAIGN}&utm_content={content}"
|
| 33 |
|
| 34 |
# ============ CSS ============
|
| 35 |
CUSTOM_CSS = """
|
|
@@ -393,7 +387,7 @@ with gr.Blocks(css=CUSTOM_CSS, title="Image Upscaler Comparison") as demo:
|
|
| 393 |
<div class="hero-container">
|
| 394 |
<div class="hero-badge">WAVESPEED AI</div>
|
| 395 |
<h1 class="hero-title">Image Upscaler Comparison</h1>
|
| 396 |
-
<p class="hero-desc">Compare Image Upscaler vs Ultimate Upscaler side by side. Try on <a href="
|
| 397 |
</div>
|
| 398 |
""")
|
| 399 |
|
|
@@ -407,7 +401,7 @@ with gr.Blocks(css=CUSTOM_CSS, title="Image Upscaler Comparison") as demo:
|
|
| 407 |
<svg width="20" height="20" fill="#06b6d4" viewBox="0 0 20 20"><path fill-rule="evenodd" d="M18 8a6 6 0 01-7.743 5.743L10 14l-1 1-1 1H6v2H2v-4l4.257-4.257A6 6 0 1118 8zm-6-4a1 1 0 100 2 2 2 0 012 2 1 1 0 102 0 4 4 0 00-4-4z" clip-rule="evenodd"/></svg>
|
| 408 |
API Key
|
| 409 |
</span>
|
| 410 |
-
<a href="
|
| 411 |
</div>
|
| 412 |
""")
|
| 413 |
api_key_input = gr.Textbox(
|
|
@@ -448,7 +442,7 @@ with gr.Blocks(css=CUSTOM_CSS, title="Image Upscaler Comparison") as demo:
|
|
| 448 |
<div class="cta-container">
|
| 449 |
<h3 class="cta-title">Want More Features?</h3>
|
| 450 |
<p class="cta-desc">Higher resolutions, batch processing, and 700+ AI models</p>
|
| 451 |
-
<a href="
|
| 452 |
Explore WaveSpeed.ai
|
| 453 |
</a>
|
| 454 |
</div>
|
|
|
|
| 24 |
|
| 25 |
|
| 26 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27 |
|
| 28 |
# ============ CSS ============
|
| 29 |
CUSTOM_CSS = """
|
|
|
|
| 387 |
<div class="hero-container">
|
| 388 |
<div class="hero-badge">WAVESPEED AI</div>
|
| 389 |
<h1 class="hero-title">Image Upscaler Comparison</h1>
|
| 390 |
+
<p class="hero-desc">Compare Image Upscaler vs Ultimate Upscaler side by side. Try on <a href="https://wavespeed.ai/models?utm_source=huggingface_space + upscaler_comparison"</a></p>
|
| 391 |
</div>
|
| 392 |
""")
|
| 393 |
|
|
|
|
| 401 |
<svg width="20" height="20" fill="#06b6d4" viewBox="0 0 20 20"><path fill-rule="evenodd" d="M18 8a6 6 0 01-7.743 5.743L10 14l-1 1-1 1H6v2H2v-4l4.257-4.257A6 6 0 1118 8zm-6-4a1 1 0 100 2 2 2 0 012 2 1 1 0 102 0 4 4 0 00-4-4z" clip-rule="evenodd"/></svg>
|
| 402 |
API Key
|
| 403 |
</span>
|
| 404 |
+
<a href="https://wavespeed.ai/models?utm_source=huggingface_space + upscaler_comparison" target="_blank" class="get-key-btn">Get API Key</a>
|
| 405 |
</div>
|
| 406 |
""")
|
| 407 |
api_key_input = gr.Textbox(
|
|
|
|
| 442 |
<div class="cta-container">
|
| 443 |
<h3 class="cta-title">Want More Features?</h3>
|
| 444 |
<p class="cta-desc">Higher resolutions, batch processing, and 700+ AI models</p>
|
| 445 |
+
<a href="https://wavespeed.ai/models?utm_source=huggingface_space + upscaler_comparison" target="_blank" class="cta-btn">
|
| 446 |
Explore WaveSpeed.ai
|
| 447 |
</a>
|
| 448 |
</div>
|