AI media harness for planning, generating, and editing locally
TypeScript
Drop the two heading blurbs and the references explainer, default to 24 fps
Bitti42c9640ab599
diff --git a/src/components/ProjectWorkspace.test.ts b/src/components/ProjectWorkspace.test.tsindex b38edf1..7ed57fb 100644--- a/src/components/ProjectWorkspace.test.ts+++ b/src/components/ProjectWorkspace.test.ts@@ -402,7 +402,8 @@ describe("project workspace timecode", () => {fireEvent.change(lasts, { target: { value: "8" } });expect(lastDuration()).toBe(8_000);fireEvent.change(lasts, { target: { value: "00:12:15" } });- expect(lastDuration()).toBe(12_500);+ // 15 frames at the project's 24 fps is 625 ms, not half a second.+ expect(lastDuration()).toBe(12_625);expect(parseProjectConfig(onChange.mock.calls.at(-1)![0] as ProjectConfig)).toBeTruthy();// Half-typed text is not a length, and must not be turned into one.@@ -411,10 +412,10 @@ describe("project workspace timecode", () => {expect(onChange.mock.calls.length).toBe(before);expect(lasts.value).toBe("00:");- // Clamped at both ends: a clip cannot be nothing, and cannot play footage- // the file does not have.+ // Clamped at both ends: a clip cannot be shorter than one frame — 42 ms at+ // 24 fps — and cannot play footage the file does not have.fireEvent.change(lasts, { target: { value: "0" } });- expect(lastDuration()).toBe(33);+ expect(lastDuration()).toBe(42);fireEvent.change(lasts, { target: { value: "90" } });expect(lastDuration()).toBe(40_000);expect(parseProjectConfig(onChange.mock.calls.at(-1)![0] as ProjectConfig)).toBeTruthy();@@ -562,7 +563,7 @@ describe("project workspace timecode", () => {// the heading while the monitor printed it again, which reads as two clocks.expect(container.textContent!.match(/\d\d:\d\d:\d\d:\d\d/g)).toHaveLength(1);// Pixels, not the id: "1080p" names one edge and leaves the other a guess.- expect(container.querySelector(".transport-format")!.textContent).toBe("1920 × 1080 · 30 fps");+ expect(container.querySelector(".transport-format")!.textContent).toBe("1920 × 1080 · 24 fps");// An empty timeline has nothing to play, and every control says so rather// than only going grey.@@ -827,8 +828,9 @@ describe("project workspace timecode", () => {// The screen must describe the rule the code implements. isReferenceUsable// qualifies an image on its FILE alone, so this imported picture IS bound// and IS sent — nothing on the page may say it is skipped or waiting on a- // definition. Three sentences here once said exactly that while the card- // beside them correctly said the file was sent.+ // definition. The explainer panel that once said exactly that is gone; the+ // card is now the only place the screen states the rule, and it says the+ // file is sent.cleanup();const withImport = onChange.mock.calls[0][0];expect(withImport.references[0].relativePath).toBeTruthy();@@ -837,7 +839,6 @@ describe("project workspace timecode", () => {for (const staleRule of ["you’ve described", "described references", "skipped", "is skipped until you write"]) {expect(screenText, `stale binding rule on screen: ${staleRule}`).not.toContain(staleRule);}- expect(screenText).toContain("An image counts as soon as you import it");expect(screenText).toContain("Not described yet — the picture is sent, but nothing tells the engine what to keep.");});diff --git a/src/components/workspace/ExportView.test.tsx b/src/components/workspace/ExportView.test.tsxindex 5d68330..bec4d4d 100644--- a/src/components/workspace/ExportView.test.tsx+++ b/src/components/workspace/ExportView.test.tsx@@ -54,7 +54,7 @@ describe("the export view where nothing can encode", () => {it("states the real duration, clip count and frame size of the planned file", () => {render(<ExportView config={project([clip("a", 0, 2_000), clip("b", 2_000, 1_000)])} folderPath="/tmp/project" />);expect(screen.getByText("00:03.000")).toBeTruthy();- expect(screen.getByText("90 frames at 30 fps")).toBeTruthy();+ expect(screen.getByText("72 frames at 24 fps")).toBeTruthy();expect(screen.getByText("1920 × 1080")).toBeTruthy();});diff --git a/src/components/workspace/GeneratorView.tsx b/src/components/workspace/GeneratorView.tsxindex 8404757..3ff6f26 100644--- a/src/components/workspace/GeneratorView.tsx+++ b/src/components/workspace/GeneratorView.tsx@@ -225,10 +225,7 @@ export function GeneratorView({ config, folderPath, runtime = null, onChange, on<main className="generator-main"><header className="generator-heading">- <div>- <h1>Generator</h1>- <p>A scene is up to fifteen seconds long and holds as many shots as you split it into. Add one with + and write what happens in each shot, or ask Pol along the bottom to build one from a prompt; PolStudio turns the whole scene into a single MiniMax H3 prompt you can read before anything is sent.</p>- </div>+ <h1>Generator</h1></header>{selected && <section className="job-detail">diff --git a/src/components/workspace/ReferencesView.tsx b/src/components/workspace/ReferencesView.tsxindex ac1cfb1..073b513 100644--- a/src/components/workspace/ReferencesView.tsx+++ b/src/components/workspace/ReferencesView.tsx@@ -1,4 +1,4 @@-import { BookOpen, Check, FileText, Image, Link2, Plus, Sparkles, Trash2, Upload, Users } from "lucide-react";+import { BookOpen, Check, FileText, Image, Link2, Plus, Trash2, Upload, Users } from "lucide-react";import { invoke } from "@tauri-apps/api/core";import { useMemo, useState } from "react";import { isReferenceDescribed, type ProjectConfig, type ProjectReference } from "../../lib/project";@@ -66,10 +66,7 @@ export function ReferencesView({ config, folderPath, onChange }: { config: Projereturn <div className="references-view"><header className="references-heading">- <div>- <h1>References</h1>- <p>Keep the people, places, products, and visual rules for this project in one place. A scene uses one once you drag it into a shot’s line in the generator.</p>- </div>+ <h1>References</h1><div><button className="secondary-button" onClick={() => addTextReference()}><FileText size={16} /> New definition</button><button className="primary-button" onClick={() => void addImage()}><Upload size={16} /> Add image</button>@@ -95,12 +92,6 @@ export function ReferencesView({ config, folderPath, onChange }: { config: Proje</button>)}<button className="reference-add-card" onClick={() => void addImage()}><span><Plus size={22} /></span><b>Add a reference</b><small>Import an image or write a definition</small></button></div>- <div className="reference-explainer"><Sparkles size={18} /><div><b>References guide new shots, not your timeline</b>{/* The rule the code actually implements: isReferenceUsable qualifies an- image on its FILE alone, so an imported picture is bound and sent- whether or not it has been described. Saying it was "skipped until- you write its definition" contradicted the card 30px away, which- correctly says the picture is sent. */}- <p>Each new shot uses the first two it can use from this list. An image counts as soon as you import it: its file is copied into the project’s <code>references/</code> folder and sent to the video engine, and describing it tells the engine what to keep about it. A text definition isn’t used until you write it, and then it reaches the engine as words in the shot’s prompt. Newest additions go to the top.</p></div></div></section><aside className="reference-inspector">diff --git a/src/lib/project.ts b/src/lib/project.tsindex e6cb4bc..aa1b1bb 100644--- a/src/lib/project.ts+++ b/src/lib/project.ts@@ -992,7 +992,7 @@ export function createProjectConfig(input: CreateProjectInput): ProjectConfig {createdAt: now,updatedAt: now,thumbnail: null,- settings: { aspectRatio: input.aspectRatio, resolution: input.resolution, frameRate: 30, backgroundColor: "#10131a" },+ settings: { aspectRatio: input.aspectRatio, resolution: input.resolution, frameRate: 24, backgroundColor: "#10131a" },brief: {prompt: brief, status: "draft", targetDurationSeconds: input.targetDurationSeconds,aspectRatio: input.aspectRatio, resolution: input.resolution,diff --git a/src/styles/generator.css b/src/styles/generator.cssindex 06f95a8..e3d98b5 100644--- a/src/styles/generator.css+++ b/src/styles/generator.css@@ -317,11 +317,6 @@margin: 0 auto var(--space-5);}-.generator-heading > div {- min-width: 0;- max-width: 68ch;-}-.generator-heading h1 {margin: var(--space-2) 0 var(--space-2);font-size: var(--text-2xl);@@ -330,13 +325,6 @@letter-spacing: var(--tracking-hero);}-.generator-heading p {- margin: 0;- color: var(--text-muted);- font-size: var(--text-base);- line-height: var(--leading-normal);-}-/* --- The scene editor ------------------------------------------------------The main control on this screen. The lines the user writes are the largestdiff --git a/src/styles/references.css b/src/styles/references.cssindex fb8403d..1ccaf14 100644--- a/src/styles/references.css+++ b/src/styles/references.css@@ -38,14 +38,6 @@letter-spacing: var(--tracking-hero);}-.references-heading p {- margin: 0;- max-width: 68ch;- color: var(--text-secondary);- font-size: var(--text-base);- line-height: var(--leading-normal);-}-/* --- Layout ---------------------------------------------------------------- */.reference-layout {@@ -313,36 +305,6 @@line-height: var(--leading-snug);}-.reference-explainer {- display: flex;- gap: var(--space-3);- margin: var(--space-2) var(--space-4) 0;- padding: var(--space-4);- border: 1px solid var(--accent-line);- border-radius: var(--radius-md);- color: var(--accent-bright);- background: var(--accent-soft);-}--.reference-explainer b {- display: block;- color: var(--text-primary);- font-size: var(--text-base);- font-weight: var(--weight-semibold);- line-height: var(--leading-snug);-}--.reference-explainer p {- margin: var(--space-1) 0 0;- color: var(--text-secondary);- font-size: var(--text-base);- line-height: var(--leading-normal);-}--.reference-explainer code {- font: var(--weight-medium) var(--text-sm) / 1 var(--font-mono);-}-/* --- Reference inspector --------------------------------------------------- */.reference-inspector {