Skip to content

AI media harness for planning, generating, and editing locally

TypeScript

Simplify timeline scenes

Bitti1bc3218f46b8
diff --git a/src/components/ProjectWorkspace.test.ts b/src/components/ProjectWorkspace.test.ts
index 8044a52..86e2bd0 100644
--- a/src/components/ProjectWorkspace.test.ts
+++ b/src/components/ProjectWorkspace.test.ts
@@ -321,6 +321,10 @@ describe("project workspace timecode", () => {
expect(container.querySelector(".scene-list")!.textContent).toContain("First scene");
expect(container.querySelector(".scene-list")!.textContent).not.toContain("Macro footage");
+ expect(container.querySelector(".scene-list")!.textContent).not.toContain("Not rendered yet");
+ expect(container.querySelector(".scene-card__thumb")).not.toBeNull();
+ expect(container.querySelector(".scene-card__thumb .shot-thumb")).toBeNull();
+ expect(screen.queryByRole("heading", { name: "Generator scenes" })).toBeNull();
fireEvent.click(screen.getByRole("button", { name: "Media" }));
const media = container.querySelector(".media-grid")! as HTMLElement;
expect(within(media).getByText("Macro footage")).not.toBeNull();
diff --git a/src/components/workspace/TimelineView.tsx b/src/components/workspace/TimelineView.tsx
index 3c3ca3e..2ce60a0 100644
--- a/src/components/workspace/TimelineView.tsx
+++ b/src/components/workspace/TimelineView.tsx
@@ -722,9 +722,8 @@ export function TimelineView({ config, folderPath, generationCompletionTimes = {
<button className={panelTab === "scenes" ? "active" : ""} onClick={() => setPanelTab("scenes")}><Layers3 size={16} /> Scenes</button>
<button className={panelTab === "media" ? "active" : ""} onClick={() => setPanelTab("media")}><Film size={16} /> Media</button>
</div>
- <div className="scene-panel__head">
- <h2>{panelTab === "scenes" ? "Generator scenes" : "Project media"}</h2>
- {panelTab === "media" && (
+ {panelTab === "media" && <div className="scene-panel__head">
+ <h2>Project media</h2>
<div className="layout-toggle" role="group" aria-label="Media layout">
<button
className={mediaLayout === "grid" ? "active" : ""}
@@ -739,8 +738,7 @@ export function TimelineView({ config, folderPath, generationCompletionTimes = {
title="Show media as a list"
><List size={16} /><span className="sr-only">List</span></button>
</div>
- )}
- </div>
+ </div>}
{panelTab === "scenes" ? (
<div className="scene-list">
{config.generationJobs.map((job, index) => {
@@ -764,7 +762,7 @@ export function TimelineView({ config, folderPath, generationCompletionTimes = {
title={`${job.title} — drag onto a video track below`}
>
<span className="scene-card__thumb">
- <ShotThumbnail folderPath={folderPath} job={job} seconds={0} shotNumber={1} estimatedCompletionAt={generationCompletionTimes[job.id] ?? null} />
+ {job.status !== "draft" && <ShotThumbnail folderPath={folderPath} job={job} seconds={0} shotNumber={1} estimatedCompletionAt={generationCompletionTimes[job.id] ?? null} />}
<i>{String(index + 1).padStart(2, "0")}</i><em>{sceneDurationSeconds(job).toFixed(1)}s</em>
</span>
<span><b>{job.title}</b><small>{STATUS_WORD[job.status]}{placements > 0 ? ` · ${placements} on timeline` : ""}</small><small>{sceneShape(job)}</small></span>
diff --git a/src/styles/timeline.css b/src/styles/timeline.css
index 214cb45..cdd9693 100644
--- a/src/styles/timeline.css
+++ b/src/styles/timeline.css
@@ -90,9 +90,8 @@
}
/* --- Region headings -------------------------------------------------------
- The edit view now carries a real heading outline (sr-only h1 → h2 per region
- → h3 inside the inspector). These h2s replace the plain <span>/<strong> that
- used to sit in the panel chrome, so they inherit the exact same look. */
+ Media and the program monitor retain real h2 headings; Scenes starts
+ directly below its already-labelled tab. */
.scene-panel__head h2,
.program-panel > .panel-chrome h2 {
@@ -120,9 +119,9 @@
line-height: var(--leading-snug);
}
-/* Panel body fills what is left after the tabs (48px) and the head (48px). */
+/* Scenes start directly below the tabs; they do not need a second heading. */
.scene-list {
- height: calc(100% - (var(--control-lg) * 2));
+ height: calc(100% - var(--control-lg));
padding: 0 var(--space-2) var(--space-4);
overflow-y: auto;
}