The author can say what is wrong with a picture, and have it redrawn

report_frame_fault existed in the worker and was on no page.
This commit is contained in:
gator 2026-09-19 15:33:35 +00:00
parent 00c4bc38b5
commit 03052f7182

View file

@ -50,6 +50,10 @@
.whoin .p input{width:100%;box-sizing:border-box;font:inherit;padding:5px 7px;
border:1px solid var(--line);border-radius:6px;background:transparent;color:inherit}
.whoin .p .go{margin-top:5px;font-size:12px;padding:3px 9px}
.ffault{display:flex;gap:8px;margin:0 0 10px}
.ffault input{flex:1;min-width:0;font:inherit;font-size:12px;padding:5px 8px;
border:1px solid var(--line);border-radius:6px;background:transparent;color:inherit}
.ffault .go{font-size:12px;padding:3px 10px;white-space:nowrap}
.whole{border:1px solid var(--line);border-radius:10px;padding:12px;margin:0 0 18px}
.whole h4{margin:0 0 4px;font-size:14px}
.whole p{margin:0 0 8px;color:var(--muted);font-size:13px}
@ -224,7 +228,7 @@
if (String(PKG.look_state || "")
&& (Date.now() - (Date.parse(PKG.look_started || "") || 0)) < 15 * 60 * 1000) return true;
return (PKG.shots || []).some(function (s) {
return s.writing || s.drawing || stillFilming(s); });
return s.writing || s.drawing || s.fixing || stillFilming(s); });
}
// Preparing the storyboard audio is work too. Without this the page stops
@ -845,6 +849,19 @@
}).join("");
}
// "That is not right" - about the PICTURE, in the author's own words. The
// picture is what the shot is filmed from, so a fault here is inherited by
// the film and cannot be fixed by filming again.
function frameFaultHtml(s) {
if (!s.opening_url || s.clip_url) return "";
if (s.fixing || s.drawing)
return '<p class="busy">Redrawing this scene\u2019s pictures from your note\u2026</p>';
return '<div class="ffault"><input type="text" id="ff-' + esc(s.id) + '" maxlength="400" '
+ 'placeholder="Something wrong with this picture? Say what you see \u2014 \u201cit should be night\u201d, '
+ '\u201cthere should be nobody else in the garden\u201d\u2026">'
+ '<button type="button" class="btn go" data-ffgo="' + esc(s.id) + '">Redraw &middot; $0.16</button></div>';
}
// WHO IS IN THIS SCENE, as they look in it. This is where an author changes
// a hat, a dress, a cut lip - in words, about one person, in one scene - and
// it holds from here on until they change it again.
@ -1017,6 +1034,7 @@
+ (s.day ? ' &middot; <span class="scene">' + esc(s.day) + '</span>' : '')
+ '</div>'
+ media
+ frameFaultHtml(s)
+ whoInHtml(s)
+ '<p class="act">' + esc(s.action || "") + '</p>'
+ (s.camera ? '<p class="cam">camera: ' + esc(s.camera) + '</p>' : '')
@ -1204,6 +1222,18 @@
z.classList.add("on");
return;
}
if ((el = hit("data-ffgo"))) {
var fsid = el.getAttribute("data-ffgo");
var fbox = document.getElementById("ff-" + fsid);
var fnote = fbox ? fbox.value.trim() : "";
if (fnote.length < 4) { if (fbox) fbox.focus(); return; }
el.disabled = true; el.textContent = "working\u2026";
r = await act("report_frame_fault", { draft_id: CUR, shot_id: fsid, note: fnote });
if (r) { showMsg("msg", "Redrawing shot " + fsid + " from your note. It takes about a minute.", "ok");
await refresh(); }
else { el.disabled = false; el.innerHTML = "Redraw &middot; $0.16"; }
return;
}
if ((el = hit("data-lookgo"))) {
var pr = el.getAttribute("data-lookgo").split("|");
var box = document.getElementById("look-" + pr[0] + "-" + pr[1]);