Files
lemonspace_app/lib/canvas-node-templates.ts
Matthias Meister ed08b976f9 feat(canvas): add video-prompt node and enhance video generation support
- Introduced a new node type "video-prompt" for AI video generation, including its integration into the canvas command palette and node template picker.
- Updated connection validation to allow connections from text nodes to video-prompt and from video-prompt to ai-video nodes.
- Enhanced error handling and messaging for video generation failures, including specific cases for provider issues.
- Added tests to validate new video-prompt functionality and connection policies.
- Updated localization files to include new labels and prompts for video-prompt and ai-video nodes.
2026-04-07 08:50:59 +02:00

119 lines
2.0 KiB
TypeScript

export const CANVAS_NODE_TEMPLATES = [
{
type: "image",
label: "Bild",
width: 280,
height: 180,
defaultData: {},
},
{
type: "text",
label: "Text",
width: 256,
height: 120,
defaultData: { content: "" },
},
{
type: "prompt",
label: "Prompt",
width: 320,
height: 220,
defaultData: { prompt: "", model: "", aspectRatio: "1:1" },
},
{
type: "video-prompt",
label: "KI-Video",
width: 320,
height: 220,
defaultData: {
prompt: "",
modelId: "wan-2-2-720p",
durationSeconds: 5,
hasAudio: false,
},
},
{
type: "note",
label: "Notiz",
width: 220,
height: 120,
defaultData: { content: "" },
},
{
type: "frame",
label: "Frame",
width: 360,
height: 240,
defaultData: { label: "Untitled", exportWidth: 1080, exportHeight: 1080 },
},
{
type: "compare",
label: "Vergleich",
width: 500,
height: 380,
defaultData: {},
},
{
type: "group",
label: "Gruppe",
width: 400,
height: 300,
defaultData: { label: "Gruppe" },
},
{
type: "asset",
label: "Asset (Stock)",
width: 260,
height: 240,
defaultData: {},
},
{
type: "video",
label: "Video",
width: 320,
height: 180,
defaultData: {},
},
{
type: "curves",
label: "Kurven",
width: 320,
height: 660,
defaultData: {},
},
{
type: "color-adjust",
label: "Farbe",
width: 320,
height: 800,
defaultData: {},
},
{
type: "light-adjust",
label: "Licht",
width: 320,
height: 920,
defaultData: {},
},
{
type: "detail-adjust",
label: "Detail",
width: 320,
height: 880,
defaultData: {},
},
{
type: "render",
label: "Render",
width: 300,
height: 420,
defaultData: {
outputResolution: "original",
format: "png",
jpegQuality: 90,
},
},
] as const;
export type CanvasNodeTemplate = (typeof CANVAS_NODE_TEMPLATES)[number];