@cliptude/cli 0.1.36 → 0.1.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cliptude_mcp/widgets/player.html +13 -2
- package/package.json +1 -1
- package/pyproject.toml +1 -1
|
@@ -24,6 +24,7 @@
|
|
|
24
24
|
<div id="toast" role="status" aria-live="polite"></div>
|
|
25
25
|
<script>
|
|
26
26
|
/*@BRIDGE_JS@*/
|
|
27
|
+
/*@VIEWS_JS@*/
|
|
27
28
|
(function () {
|
|
28
29
|
"use strict";
|
|
29
30
|
var h = UI.h;
|
|
@@ -36,7 +37,7 @@
|
|
|
36
37
|
var r = data.render;
|
|
37
38
|
return { title: r.title || data.title || "Edited video", url: r.output_url || "", status: r.status || "",
|
|
38
39
|
progress: r.progress, step: r.current_step || "", error: r.error_message || "", expires: r.output_url_expires_in_s,
|
|
39
|
-
kind: "render", id: r.id };
|
|
40
|
+
kind: "render", id: r.id, jobId: r.job_id || "" };
|
|
40
41
|
}
|
|
41
42
|
if (data.stage !== undefined) {
|
|
42
43
|
var out = data.output || {};
|
|
@@ -116,7 +117,17 @@
|
|
|
116
117
|
var v = normalize(data);
|
|
117
118
|
document.getElementById("title").textContent = v.title;
|
|
118
119
|
setFacts([fmtDuration(v.duration), v.url ? "MP4" : (v.status || "").replace(/_/g, " ")]);
|
|
119
|
-
if (v.url)
|
|
120
|
+
if (!v.url) { renderPending(v); return; }
|
|
121
|
+
renderVideo(v);
|
|
122
|
+
// A finished export: show its publish kit (the kit plays this export at the top), as a finished job does.
|
|
123
|
+
if (v.kind === "render" && v.jobId && Cliptude.canCallTools()) {
|
|
124
|
+
Cliptude.callTool("show_publish_kit", { job_id: v.jobId }).then(function (kit) {
|
|
125
|
+
if (!kit || UI.errorText(kit)) return;
|
|
126
|
+
document.getElementById("title").textContent = kit.title ? "Publish kit · " + kit.title : "Publish kit";
|
|
127
|
+
Views.publishKit(content, kit);
|
|
128
|
+
Cliptude.reportSize();
|
|
129
|
+
}).catch(function () {});
|
|
130
|
+
}
|
|
120
131
|
},
|
|
121
132
|
onCancelled: function () { UI.status(content, "Cancelled."); }
|
|
122
133
|
}).catch(function () { UI.status(content, "This view could not connect to the chat.", "error"); });
|
package/package.json
CHANGED
package/pyproject.toml
CHANGED