Spaces:
Running on Zero
Running on Zero
feat(ui): support CTA bar — '♥ at the top to support · follow for what's next'
Browse filesSingle-line banner between the brand header and the tab strip. Two CTAs:
- '♥ at the top' points at HF Space's native heart-widget so users can
support without leaving the page
- 'Follow @techfreakworm ' links to the HF profile for future-project signal
Visual restraint: dim text on a faint amber wash, hairline border, soft
2.4s pulse on the heart. Wraps to two lines under 600 px so phones get a
clean stacked layout. Inspired by LTX2.3 Studio's tipbar pattern but
adapted to the Soft Dark Restraint palette.
app.py
CHANGED
|
@@ -244,9 +244,21 @@ HEADER_HTML = """
|
|
| 244 |
""".strip()
|
| 245 |
|
| 246 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 247 |
def build_app() -> gr.Blocks:
|
| 248 |
with gr.Blocks(theme=theme.build_theme(), css=theme.CSS, title="Z-Image Studio") as demo:
|
| 249 |
gr.HTML(HEADER_HTML)
|
|
|
|
| 250 |
|
| 251 |
with gr.Tabs():
|
| 252 |
with gr.Tab("Text → Image"):
|
|
|
|
| 244 |
""".strip()
|
| 245 |
|
| 246 |
|
| 247 |
+
CTA_HTML = """
|
| 248 |
+
<div class="zis-cta">
|
| 249 |
+
Built with care.
|
| 250 |
+
<strong>Drop a <span class="zis-cta-heart">♥</span> at the top</strong> to support it
|
| 251 |
+
<span class="zis-cta-sep">·</span>
|
| 252 |
+
Follow <a href="https://huggingface.co/techfreakworm" target="_blank" rel="noopener noreferrer">@techfreakworm</a>
|
| 253 |
+
for what's next.
|
| 254 |
+
</div>
|
| 255 |
+
""".strip()
|
| 256 |
+
|
| 257 |
+
|
| 258 |
def build_app() -> gr.Blocks:
|
| 259 |
with gr.Blocks(theme=theme.build_theme(), css=theme.CSS, title="Z-Image Studio") as demo:
|
| 260 |
gr.HTML(HEADER_HTML)
|
| 261 |
+
gr.HTML(CTA_HTML)
|
| 262 |
|
| 263 |
with gr.Tabs():
|
| 264 |
with gr.Tab("Text → Image"):
|
theme.py
CHANGED
|
@@ -128,4 +128,48 @@ CSS: str = """
|
|
| 128 |
margin-right: 6px;
|
| 129 |
vertical-align: middle;
|
| 130 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 131 |
""".strip()
|
|
|
|
| 128 |
margin-right: 6px;
|
| 129 |
vertical-align: middle;
|
| 130 |
}
|
| 131 |
+
|
| 132 |
+
/* CTA bar — single-line "drop a like / follow for what's next". Subtle by
|
| 133 |
+
design: dim text, faintest amber wash, hairline underline. Avoids the
|
| 134 |
+
needy "PLEASE STAR THE REPO" energy. */
|
| 135 |
+
.zis-cta {
|
| 136 |
+
margin: 4px 0 10px 0;
|
| 137 |
+
padding: 8px 14px;
|
| 138 |
+
font-size: 12px;
|
| 139 |
+
line-height: 1.5;
|
| 140 |
+
color: #988B7C;
|
| 141 |
+
background:
|
| 142 |
+
linear-gradient(180deg, rgba(255,176,46,0.05), rgba(255,176,46,0.02));
|
| 143 |
+
border: 1px solid #2A241E;
|
| 144 |
+
border-radius: 8px;
|
| 145 |
+
text-align: center;
|
| 146 |
+
}
|
| 147 |
+
.zis-cta strong { color: #F0E8DD; font-weight: 600; }
|
| 148 |
+
.zis-cta .zis-cta-heart {
|
| 149 |
+
display: inline-block;
|
| 150 |
+
color: #FFB02E;
|
| 151 |
+
transform: translateY(-1px);
|
| 152 |
+
margin: 0 1px;
|
| 153 |
+
animation: zis-cta-pulse 2.4s ease-in-out infinite;
|
| 154 |
+
}
|
| 155 |
+
@keyframes zis-cta-pulse {
|
| 156 |
+
0%, 60%, 100% { transform: translateY(-1px) scale(1); }
|
| 157 |
+
30% { transform: translateY(-1px) scale(1.18); }
|
| 158 |
+
}
|
| 159 |
+
.zis-cta .zis-cta-sep { margin: 0 10px; color: #3A3128; }
|
| 160 |
+
.zis-cta a {
|
| 161 |
+
color: #FFB02E;
|
| 162 |
+
text-decoration: none;
|
| 163 |
+
border-bottom: 1px dashed rgba(255,176,46,0.4);
|
| 164 |
+
transition: border-color 0.15s, color 0.15s;
|
| 165 |
+
}
|
| 166 |
+
.zis-cta a:hover {
|
| 167 |
+
color: #FFC85A;
|
| 168 |
+
border-bottom-color: #FFB02E;
|
| 169 |
+
}
|
| 170 |
+
|
| 171 |
+
@media (max-width: 600px) {
|
| 172 |
+
.zis-cta { font-size: 11px; padding: 8px 10px; }
|
| 173 |
+
.zis-cta .zis-cta-sep { display: block; height: 4px; margin: 0; visibility: hidden; }
|
| 174 |
+
}
|
| 175 |
""".strip()
|