Preview-vs-save flow, interactive recreate checkbox, top status message
Browse files
app.py
CHANGED
|
@@ -353,6 +353,10 @@ input:not([type='checkbox']):not([type='radio']), textarea{border-radius:0 !impo
|
|
| 353 |
-webkit-text-fill-color:var(--ink) !important;
|
| 354 |
font-family:'Spline Sans Mono',monospace !important;}
|
| 355 |
input::placeholder, textarea::placeholder{color:rgba(51,49,43,.45) !important;-webkit-text-fill-color:rgba(51,49,43,.45) !important;}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 356 |
footer{display:none !important;}
|
| 357 |
"""
|
| 358 |
|
|
@@ -422,7 +426,7 @@ with gr.Blocks(title="Build Small — Certificate Generator") as demo:
|
|
| 422 |
|
| 423 |
gr.HTML('<div class="bs-section">Your certificate</div>')
|
| 424 |
certificate_image = gr.Image(label="Preview", type="filepath", interactive=False)
|
| 425 |
-
certificate_file = gr.File(label="Download (PNG)", interactive=False)
|
| 426 |
|
| 427 |
gr.HTML('<div class="bs-section">Share</div>')
|
| 428 |
linkedin_html = gr.HTML(render_linkedin_button(""))
|
|
|
|
| 353 |
-webkit-text-fill-color:var(--ink) !important;
|
| 354 |
font-family:'Spline Sans Mono',monospace !important;}
|
| 355 |
input::placeholder, textarea::placeholder{color:rgba(51,49,43,.45) !important;-webkit-text-fill-color:rgba(51,49,43,.45) !important;}
|
| 356 |
+
/* Download (PNG) file row — force light bg + readable ink text in any theme */
|
| 357 |
+
#cert-file, #cert-file *{background-color:#fff !important;color:var(--ink) !important;
|
| 358 |
+
-webkit-text-fill-color:var(--ink) !important;border-color:var(--ink) !important;fill:var(--ink) !important;}
|
| 359 |
+
#cert-file a, #cert-file a *{color:var(--forest) !important;-webkit-text-fill-color:var(--forest) !important;}
|
| 360 |
footer{display:none !important;}
|
| 361 |
"""
|
| 362 |
|
|
|
|
| 426 |
|
| 427 |
gr.HTML('<div class="bs-section">Your certificate</div>')
|
| 428 |
certificate_image = gr.Image(label="Preview", type="filepath", interactive=False)
|
| 429 |
+
certificate_file = gr.File(label="Download (PNG)", interactive=False, elem_id="cert-file")
|
| 430 |
|
| 431 |
gr.HTML('<div class="bs-section">Share</div>')
|
| 432 |
linkedin_html = gr.HTML(render_linkedin_button(""))
|