Spaces:
Running on Zero
Running on Zero
Play studio results with sound and enable sign-in for the workflow canvas
Browse filesThe studio result video no longer starts muted (it falls back to muted only if the browser blocks sound). hf_oauth lets workflow visitors sign in so runs use their own ZeroGPU quota.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- README.md +1 -0
- studio.html +4 -1
README.md
CHANGED
|
@@ -7,6 +7,7 @@ python_version: 3.12
|
|
| 7 |
sdk: gradio
|
| 8 |
sdk_version: 6.32.0
|
| 9 |
app_file: app.py
|
|
|
|
| 10 |
startup_duration_timeout: 1h
|
| 11 |
pinned: false
|
| 12 |
license: other
|
|
|
|
| 7 |
sdk: gradio
|
| 8 |
sdk_version: 6.32.0
|
| 9 |
app_file: app.py
|
| 10 |
+
hf_oauth: true
|
| 11 |
startup_duration_timeout: 1h
|
| 12 |
pinned: false
|
| 13 |
license: other
|
studio.html
CHANGED
|
@@ -298,7 +298,7 @@
|
|
| 298 |
<figure class="doc" id="doc-after">
|
| 299 |
<figcaption>Output video</figcaption>
|
| 300 |
<div class="stage" id="after-stage">
|
| 301 |
-
<video id="result-video" controls
|
| 302 |
<div class="drop-hint" id="result-hint"><b>Nothing yet</b>Hit Generate — 2 or 4 steps, audio included</div>
|
| 303 |
</div>
|
| 304 |
<div class="doc-bar">
|
|
@@ -635,6 +635,9 @@
|
|
| 635 |
video.src = uri;
|
| 636 |
video.hidden = false;
|
| 637 |
video.classList.add("previewing");
|
|
|
|
|
|
|
|
|
|
| 638 |
$("result-hint").style.display = "none";
|
| 639 |
const dl = $("result-download");
|
| 640 |
dl.href = uri; dl.hidden = false;
|
|
|
|
| 298 |
<figure class="doc" id="doc-after">
|
| 299 |
<figcaption>Output video</figcaption>
|
| 300 |
<div class="stage" id="after-stage">
|
| 301 |
+
<video id="result-video" controls playsinline hidden></video>
|
| 302 |
<div class="drop-hint" id="result-hint"><b>Nothing yet</b>Hit Generate — 2 or 4 steps, audio included</div>
|
| 303 |
</div>
|
| 304 |
<div class="doc-bar">
|
|
|
|
| 635 |
video.src = uri;
|
| 636 |
video.hidden = false;
|
| 637 |
video.classList.add("previewing");
|
| 638 |
+
// play with sound (the visitor clicked Generate); fall back to muted if the browser blocks it
|
| 639 |
+
video.muted = false;
|
| 640 |
+
video.play().catch(() => { video.muted = true; video.play().catch(() => {}); });
|
| 641 |
$("result-hint").style.display = "none";
|
| 642 |
const dl = $("result-download");
|
| 643 |
dl.href = uri; dl.hidden = false;
|