@contractspec/lib.video-gen 2.7.16 → 2.7.18
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/dist/browser/compositions/api-overview.js +1 -645
- package/dist/browser/compositions/index.js +1 -1133
- package/dist/browser/compositions/primitives/animated-text.js +1 -144
- package/dist/browser/compositions/primitives/brand-frame.js +1 -181
- package/dist/browser/compositions/primitives/code-block.js +1 -226
- package/dist/browser/compositions/primitives/index.js +1 -656
- package/dist/browser/compositions/primitives/progress-bar.js +1 -59
- package/dist/browser/compositions/primitives/terminal.js +1 -265
- package/dist/browser/compositions/primitives/transition.js +1 -98
- package/dist/browser/compositions/social-clip.js +1 -500
- package/dist/browser/compositions/terminal-demo.js +1 -558
- package/dist/browser/design/index.js +1 -155
- package/dist/browser/design/layouts.js +1 -50
- package/dist/browser/design/motion.js +1 -43
- package/dist/browser/design/tokens.js +1 -28
- package/dist/browser/design/typography.js +1 -61
- package/dist/browser/docs/compositions.docblock.js +1 -182
- package/dist/browser/docs/design.docblock.js +2 -17
- package/dist/browser/docs/generators.docblock.js +2 -24
- package/dist/browser/docs/rendering.docblock.js +2 -24
- package/dist/browser/docs/video-gen.docblock.js +2 -17
- package/dist/browser/generators/index.js +7 -769
- package/dist/browser/generators/scene-planner.js +7 -651
- package/dist/browser/generators/script-generator.js +7 -599
- package/dist/browser/generators/video-generator.js +7 -768
- package/dist/browser/i18n/catalogs/en.js +3 -135
- package/dist/browser/i18n/catalogs/es.js +3 -135
- package/dist/browser/i18n/catalogs/fr.js +3 -135
- package/dist/browser/i18n/catalogs/index.js +7 -387
- package/dist/browser/i18n/index.js +7 -459
- package/dist/browser/i18n/keys.js +1 -54
- package/dist/browser/i18n/locale.js +1 -21
- package/dist/browser/i18n/messages.js +7 -399
- package/dist/browser/index.js +7 -1903
- package/dist/browser/player/demo-player.js +1 -1136
- package/dist/browser/player/index.js +1 -1136
- package/dist/browser/remotion/Root.js +2 -1172
- package/dist/browser/remotion/index.js +2 -1173
- package/dist/browser/renderers/config.js +1 -40
- package/dist/browser/renderers/index.js +1 -160
- package/dist/browser/renderers/local.js +1 -156
- package/dist/browser/types.js +1 -13
- package/dist/compositions/api-overview.js +1 -639
- package/dist/compositions/index.js +1 -1127
- package/dist/compositions/primitives/animated-text.js +1 -138
- package/dist/compositions/primitives/brand-frame.js +1 -175
- package/dist/compositions/primitives/code-block.js +1 -220
- package/dist/compositions/primitives/index.js +1 -650
- package/dist/compositions/primitives/progress-bar.js +1 -53
- package/dist/compositions/primitives/terminal.js +1 -259
- package/dist/compositions/primitives/transition.js +1 -92
- package/dist/compositions/social-clip.js +1 -494
- package/dist/compositions/terminal-demo.js +1 -552
- package/dist/design/index.js +1 -149
- package/dist/design/layouts.js +1 -44
- package/dist/design/motion.js +1 -37
- package/dist/design/tokens.js +1 -22
- package/dist/design/typography.js +1 -55
- package/dist/docs/compositions.docblock.js +1 -182
- package/dist/docs/design.docblock.js +2 -17
- package/dist/docs/generators.docblock.js +2 -24
- package/dist/docs/rendering.docblock.js +2 -24
- package/dist/docs/video-gen.docblock.js +2 -17
- package/dist/generators/index.js +7 -763
- package/dist/generators/scene-planner.js +7 -645
- package/dist/generators/script-generator.js +7 -593
- package/dist/generators/video-generator.js +7 -762
- package/dist/i18n/catalogs/en.js +3 -129
- package/dist/i18n/catalogs/es.js +3 -129
- package/dist/i18n/catalogs/fr.js +3 -129
- package/dist/i18n/catalogs/index.js +7 -381
- package/dist/i18n/index.js +7 -453
- package/dist/i18n/keys.js +1 -48
- package/dist/i18n/locale.js +1 -15
- package/dist/i18n/messages.js +7 -393
- package/dist/index.js +7 -1897
- package/dist/node/compositions/api-overview.js +1 -640
- package/dist/node/compositions/index.js +1 -1128
- package/dist/node/compositions/primitives/animated-text.js +1 -139
- package/dist/node/compositions/primitives/brand-frame.js +1 -176
- package/dist/node/compositions/primitives/code-block.js +1 -221
- package/dist/node/compositions/primitives/index.js +1 -651
- package/dist/node/compositions/primitives/progress-bar.js +1 -54
- package/dist/node/compositions/primitives/terminal.js +1 -260
- package/dist/node/compositions/primitives/transition.js +1 -93
- package/dist/node/compositions/social-clip.js +1 -495
- package/dist/node/compositions/terminal-demo.js +1 -553
- package/dist/node/design/index.js +1 -150
- package/dist/node/design/layouts.js +1 -45
- package/dist/node/design/motion.js +1 -38
- package/dist/node/design/tokens.js +1 -23
- package/dist/node/design/typography.js +1 -56
- package/dist/node/docs/compositions.docblock.js +1 -182
- package/dist/node/docs/design.docblock.js +2 -17
- package/dist/node/docs/generators.docblock.js +2 -24
- package/dist/node/docs/rendering.docblock.js +2 -24
- package/dist/node/docs/video-gen.docblock.js +2 -17
- package/dist/node/generators/index.js +7 -764
- package/dist/node/generators/scene-planner.js +7 -646
- package/dist/node/generators/script-generator.js +7 -594
- package/dist/node/generators/video-generator.js +7 -763
- package/dist/node/i18n/catalogs/en.js +3 -130
- package/dist/node/i18n/catalogs/es.js +3 -130
- package/dist/node/i18n/catalogs/fr.js +3 -130
- package/dist/node/i18n/catalogs/index.js +7 -382
- package/dist/node/i18n/index.js +7 -454
- package/dist/node/i18n/keys.js +1 -49
- package/dist/node/i18n/locale.js +1 -16
- package/dist/node/i18n/messages.js +7 -394
- package/dist/node/index.js +7 -1898
- package/dist/node/player/demo-player.js +1 -1131
- package/dist/node/player/index.js +1 -1131
- package/dist/node/remotion/Root.js +2 -1167
- package/dist/node/remotion/index.js +2 -1168
- package/dist/node/renderers/config.js +1 -35
- package/dist/node/renderers/index.js +1 -155
- package/dist/node/renderers/local.js +1 -151
- package/dist/node/types.js +1 -8
- package/dist/player/demo-player.js +1 -1130
- package/dist/player/index.js +1 -1130
- package/dist/remotion/Root.js +2 -1166
- package/dist/remotion/index.js +2 -1167
- package/dist/renderers/config.js +1 -34
- package/dist/renderers/index.js +1 -154
- package/dist/renderers/local.js +1 -150
- package/dist/types.js +1 -7
- package/package.json +18 -18
|
@@ -1,150 +1 @@
|
|
|
1
|
-
import {
|
|
2
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
3
|
-
|
|
4
|
-
// src/design/motion.ts
|
|
5
|
-
import { Easing } from "remotion";
|
|
6
|
-
var videoEasing = {
|
|
7
|
-
entrance: Easing.out(Easing.exp),
|
|
8
|
-
exit: Easing.in(Easing.exp),
|
|
9
|
-
emphasis: Easing.out(Easing.back(1.4)),
|
|
10
|
-
linear: Easing.linear,
|
|
11
|
-
gentle: Easing.bezier(0.25, 0.1, 0.25, 1),
|
|
12
|
-
spring: Easing.out(Easing.back(1.7))
|
|
13
|
-
};
|
|
14
|
-
var videoDurations = {
|
|
15
|
-
sceneTransition: 20,
|
|
16
|
-
textEntrance: 15,
|
|
17
|
-
textExit: 12,
|
|
18
|
-
codeTypingPerChar: 2,
|
|
19
|
-
sectionPause: 30,
|
|
20
|
-
emphasisPause: 15,
|
|
21
|
-
brandReveal: 25,
|
|
22
|
-
minScene: 60,
|
|
23
|
-
shortScene: 60,
|
|
24
|
-
mediumScene: 120,
|
|
25
|
-
longScene: 240
|
|
26
|
-
};
|
|
27
|
-
var videoTransitions = {
|
|
28
|
-
fade: { type: "fade", durationInFrames: 20 },
|
|
29
|
-
slideLeft: { type: "slide-left", durationInFrames: 20 },
|
|
30
|
-
slideRight: { type: "slide-right", durationInFrames: 20 },
|
|
31
|
-
wipe: { type: "wipe", durationInFrames: 15 },
|
|
32
|
-
none: { type: "none", durationInFrames: 0 }
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
// src/design/tokens.ts
|
|
36
|
-
import { defaultTokens } from "@contractspec/lib.design-system";
|
|
37
|
-
var defaultVideoColors = {
|
|
38
|
-
canvasBackground: defaultTokens.colors.background,
|
|
39
|
-
codeBackground: "#1e1e2e",
|
|
40
|
-
terminalBackground: "#0d1117",
|
|
41
|
-
terminalForeground: "#c9d1d9",
|
|
42
|
-
highlight: defaultTokens.colors.accent,
|
|
43
|
-
gradientStart: defaultTokens.colors.primary,
|
|
44
|
-
gradientEnd: defaultTokens.colors.accent
|
|
45
|
-
};
|
|
46
|
-
var defaultVideoTheme = {
|
|
47
|
-
...defaultTokens,
|
|
48
|
-
video: defaultVideoColors
|
|
49
|
-
};
|
|
50
|
-
|
|
51
|
-
// src/design/typography.ts
|
|
52
|
-
var videoTypography = {
|
|
53
|
-
title: {
|
|
54
|
-
fontSize: 72,
|
|
55
|
-
lineHeight: 1.1,
|
|
56
|
-
fontWeight: 700,
|
|
57
|
-
letterSpacing: -1
|
|
58
|
-
},
|
|
59
|
-
heading: {
|
|
60
|
-
fontSize: 56,
|
|
61
|
-
lineHeight: 1.2,
|
|
62
|
-
fontWeight: 600,
|
|
63
|
-
letterSpacing: -0.5
|
|
64
|
-
},
|
|
65
|
-
subheading: {
|
|
66
|
-
fontSize: 40,
|
|
67
|
-
lineHeight: 1.25,
|
|
68
|
-
fontWeight: 500
|
|
69
|
-
},
|
|
70
|
-
body: {
|
|
71
|
-
fontSize: 32,
|
|
72
|
-
lineHeight: 1.5,
|
|
73
|
-
fontWeight: 400
|
|
74
|
-
},
|
|
75
|
-
code: {
|
|
76
|
-
fontSize: 28,
|
|
77
|
-
lineHeight: 1.6,
|
|
78
|
-
fontWeight: 400
|
|
79
|
-
},
|
|
80
|
-
caption: {
|
|
81
|
-
fontSize: 24,
|
|
82
|
-
lineHeight: 1.4,
|
|
83
|
-
fontWeight: 400
|
|
84
|
-
},
|
|
85
|
-
label: {
|
|
86
|
-
fontSize: 20,
|
|
87
|
-
lineHeight: 1.3,
|
|
88
|
-
fontWeight: 600,
|
|
89
|
-
letterSpacing: 1
|
|
90
|
-
}
|
|
91
|
-
};
|
|
92
|
-
function scaleTypography(style, targetWidth) {
|
|
93
|
-
const scale = targetWidth / 1920;
|
|
94
|
-
return {
|
|
95
|
-
...style,
|
|
96
|
-
fontSize: Math.round(style.fontSize * scale),
|
|
97
|
-
letterSpacing: style.letterSpacing ? Math.round(style.letterSpacing * scale * 10) / 10 : undefined
|
|
98
|
-
};
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
// src/design/layouts.ts
|
|
102
|
-
import { VIDEO_FORMATS } from "@contractspec/lib.contracts-integrations/integrations/providers/video";
|
|
103
|
-
var DEFAULT_FPS = 30;
|
|
104
|
-
var videoSafeZone = {
|
|
105
|
-
horizontal: 120,
|
|
106
|
-
vertical: 80,
|
|
107
|
-
contentWidth: 1680,
|
|
108
|
-
contentHeight: 920
|
|
109
|
-
};
|
|
110
|
-
function scaleSafeZone(format) {
|
|
111
|
-
const scaleX = format.width / 1920;
|
|
112
|
-
const scaleY = format.height / 1080;
|
|
113
|
-
return {
|
|
114
|
-
horizontal: Math.round(videoSafeZone.horizontal * scaleX),
|
|
115
|
-
vertical: Math.round(videoSafeZone.vertical * scaleY),
|
|
116
|
-
contentWidth: Math.round(videoSafeZone.contentWidth * scaleX),
|
|
117
|
-
contentHeight: Math.round(videoSafeZone.contentHeight * scaleY)
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
var videoPositions = {
|
|
121
|
-
center: { x: 960, y: 540 },
|
|
122
|
-
topLeft: { x: 120, y: 80 },
|
|
123
|
-
topRight: { x: 1800, y: 80 },
|
|
124
|
-
bottomLeft: { x: 120, y: 1000 },
|
|
125
|
-
bottomRight: { x: 1800, y: 1000 },
|
|
126
|
-
bottomCenter: { x: 960, y: 960 }
|
|
127
|
-
};
|
|
128
|
-
function getAllFormatVariants() {
|
|
129
|
-
return [
|
|
130
|
-
VIDEO_FORMATS.landscape,
|
|
131
|
-
VIDEO_FORMATS.square,
|
|
132
|
-
VIDEO_FORMATS.portrait
|
|
133
|
-
];
|
|
134
|
-
}
|
|
135
|
-
export {
|
|
136
|
-
videoTypography,
|
|
137
|
-
videoTransitions,
|
|
138
|
-
videoSafeZone,
|
|
139
|
-
videoPositions,
|
|
140
|
-
videoEasing,
|
|
141
|
-
videoDurations,
|
|
142
|
-
scaleTypography,
|
|
143
|
-
scaleSafeZone,
|
|
144
|
-
getAllFormatVariants,
|
|
145
|
-
defaultVideoTheme,
|
|
146
|
-
defaultVideoColors,
|
|
147
|
-
defaultTokens,
|
|
148
|
-
VIDEO_FORMATS,
|
|
149
|
-
DEFAULT_FPS
|
|
150
|
-
};
|
|
1
|
+
import{createRequire as J}from"node:module";var N=J(import.meta.url);import{Easing as x}from"remotion";var $={entrance:x.out(x.exp),exit:x.in(x.exp),emphasis:x.out(x.back(1.4)),linear:x.linear,gentle:x.bezier(0.25,0.1,0.25,1),spring:x.out(x.back(1.7))},P={sceneTransition:20,textEntrance:15,textExit:12,codeTypingPerChar:2,sectionPause:30,emphasisPause:15,brandReveal:25,minScene:60,shortScene:60,mediumScene:120,longScene:240},w={fade:{type:"fade",durationInFrames:20},slideLeft:{type:"slide-left",durationInFrames:20},slideRight:{type:"slide-right",durationInFrames:20},wipe:{type:"wipe",durationInFrames:15},none:{type:"none",durationInFrames:0}};import{defaultTokens as z}from"@contractspec/lib.design-system";var K={canvasBackground:z.colors.background,codeBackground:"#1e1e2e",terminalBackground:"#0d1117",terminalForeground:"#c9d1d9",highlight:z.colors.accent,gradientStart:z.colors.primary,gradientEnd:z.colors.accent},X={...z,video:K};var m={title:{fontSize:72,lineHeight:1.1,fontWeight:700,letterSpacing:-1},heading:{fontSize:56,lineHeight:1.2,fontWeight:600,letterSpacing:-0.5},subheading:{fontSize:40,lineHeight:1.25,fontWeight:500},body:{fontSize:32,lineHeight:1.5,fontWeight:400},code:{fontSize:28,lineHeight:1.6,fontWeight:400},caption:{fontSize:24,lineHeight:1.4,fontWeight:400},label:{fontSize:20,lineHeight:1.3,fontWeight:600,letterSpacing:1}};function p(j,B){let q=B/1920;return{...j,fontSize:Math.round(j.fontSize*q),letterSpacing:j.letterSpacing?Math.round(j.letterSpacing*q*10)/10:void 0}}import{VIDEO_FORMATS as H}from"@contractspec/lib.contracts-integrations/integrations/providers/video";var F=30,G={horizontal:120,vertical:80,contentWidth:1680,contentHeight:920};function I(j){let B=j.width/1920,q=j.height/1080;return{horizontal:Math.round(G.horizontal*B),vertical:Math.round(G.vertical*q),contentWidth:Math.round(G.contentWidth*B),contentHeight:Math.round(G.contentHeight*q)}}var M={center:{x:960,y:540},topLeft:{x:120,y:80},topRight:{x:1800,y:80},bottomLeft:{x:120,y:1000},bottomRight:{x:1800,y:1000},bottomCenter:{x:960,y:960}};function R(){return[H.landscape,H.square,H.portrait]}export{m as videoTypography,w as videoTransitions,G as videoSafeZone,M as videoPositions,$ as videoEasing,P as videoDurations,p as scaleTypography,I as scaleSafeZone,R as getAllFormatVariants,X as defaultVideoTheme,K as defaultVideoColors,z as defaultTokens,H as VIDEO_FORMATS,F as DEFAULT_FPS};
|
|
@@ -1,45 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
3
|
-
|
|
4
|
-
// src/design/layouts.ts
|
|
5
|
-
import { VIDEO_FORMATS } from "@contractspec/lib.contracts-integrations/integrations/providers/video";
|
|
6
|
-
var DEFAULT_FPS = 30;
|
|
7
|
-
var videoSafeZone = {
|
|
8
|
-
horizontal: 120,
|
|
9
|
-
vertical: 80,
|
|
10
|
-
contentWidth: 1680,
|
|
11
|
-
contentHeight: 920
|
|
12
|
-
};
|
|
13
|
-
function scaleSafeZone(format) {
|
|
14
|
-
const scaleX = format.width / 1920;
|
|
15
|
-
const scaleY = format.height / 1080;
|
|
16
|
-
return {
|
|
17
|
-
horizontal: Math.round(videoSafeZone.horizontal * scaleX),
|
|
18
|
-
vertical: Math.round(videoSafeZone.vertical * scaleY),
|
|
19
|
-
contentWidth: Math.round(videoSafeZone.contentWidth * scaleX),
|
|
20
|
-
contentHeight: Math.round(videoSafeZone.contentHeight * scaleY)
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
var videoPositions = {
|
|
24
|
-
center: { x: 960, y: 540 },
|
|
25
|
-
topLeft: { x: 120, y: 80 },
|
|
26
|
-
topRight: { x: 1800, y: 80 },
|
|
27
|
-
bottomLeft: { x: 120, y: 1000 },
|
|
28
|
-
bottomRight: { x: 1800, y: 1000 },
|
|
29
|
-
bottomCenter: { x: 960, y: 960 }
|
|
30
|
-
};
|
|
31
|
-
function getAllFormatVariants() {
|
|
32
|
-
return [
|
|
33
|
-
VIDEO_FORMATS.landscape,
|
|
34
|
-
VIDEO_FORMATS.square,
|
|
35
|
-
VIDEO_FORMATS.portrait
|
|
36
|
-
];
|
|
37
|
-
}
|
|
38
|
-
export {
|
|
39
|
-
videoSafeZone,
|
|
40
|
-
videoPositions,
|
|
41
|
-
scaleSafeZone,
|
|
42
|
-
getAllFormatVariants,
|
|
43
|
-
VIDEO_FORMATS,
|
|
44
|
-
DEFAULT_FPS
|
|
45
|
-
};
|
|
1
|
+
import{createRequire as w}from"node:module";var y=w(import.meta.url);import{VIDEO_FORMATS as j}from"@contractspec/lib.contracts-integrations/integrations/providers/video";var C=30,h={horizontal:120,vertical:80,contentWidth:1680,contentHeight:920};function G(k){let q=k.width/1920,u=k.height/1080;return{horizontal:Math.round(h.horizontal*q),vertical:Math.round(h.vertical*u),contentWidth:Math.round(h.contentWidth*q),contentHeight:Math.round(h.contentHeight*u)}}var H={center:{x:960,y:540},topLeft:{x:120,y:80},topRight:{x:1800,y:80},bottomLeft:{x:120,y:1000},bottomRight:{x:1800,y:1000},bottomCenter:{x:960,y:960}};function J(){return[j.landscape,j.square,j.portrait]}export{h as videoSafeZone,H as videoPositions,G as scaleSafeZone,J as getAllFormatVariants,j as VIDEO_FORMATS,C as DEFAULT_FPS};
|
|
@@ -1,38 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
3
|
-
|
|
4
|
-
// src/design/motion.ts
|
|
5
|
-
import { Easing } from "remotion";
|
|
6
|
-
var videoEasing = {
|
|
7
|
-
entrance: Easing.out(Easing.exp),
|
|
8
|
-
exit: Easing.in(Easing.exp),
|
|
9
|
-
emphasis: Easing.out(Easing.back(1.4)),
|
|
10
|
-
linear: Easing.linear,
|
|
11
|
-
gentle: Easing.bezier(0.25, 0.1, 0.25, 1),
|
|
12
|
-
spring: Easing.out(Easing.back(1.7))
|
|
13
|
-
};
|
|
14
|
-
var videoDurations = {
|
|
15
|
-
sceneTransition: 20,
|
|
16
|
-
textEntrance: 15,
|
|
17
|
-
textExit: 12,
|
|
18
|
-
codeTypingPerChar: 2,
|
|
19
|
-
sectionPause: 30,
|
|
20
|
-
emphasisPause: 15,
|
|
21
|
-
brandReveal: 25,
|
|
22
|
-
minScene: 60,
|
|
23
|
-
shortScene: 60,
|
|
24
|
-
mediumScene: 120,
|
|
25
|
-
longScene: 240
|
|
26
|
-
};
|
|
27
|
-
var videoTransitions = {
|
|
28
|
-
fade: { type: "fade", durationInFrames: 20 },
|
|
29
|
-
slideLeft: { type: "slide-left", durationInFrames: 20 },
|
|
30
|
-
slideRight: { type: "slide-right", durationInFrames: 20 },
|
|
31
|
-
wipe: { type: "wipe", durationInFrames: 15 },
|
|
32
|
-
none: { type: "none", durationInFrames: 0 }
|
|
33
|
-
};
|
|
34
|
-
export {
|
|
35
|
-
videoTransitions,
|
|
36
|
-
videoEasing,
|
|
37
|
-
videoDurations
|
|
38
|
-
};
|
|
1
|
+
import{createRequire as h}from"node:module";var k=h(import.meta.url);import{Easing as d}from"remotion";var v={entrance:d.out(d.exp),exit:d.in(d.exp),emphasis:d.out(d.back(1.4)),linear:d.linear,gentle:d.bezier(0.25,0.1,0.25,1),spring:d.out(d.back(1.7))},w={sceneTransition:20,textEntrance:15,textExit:12,codeTypingPerChar:2,sectionPause:30,emphasisPause:15,brandReveal:25,minScene:60,shortScene:60,mediumScene:120,longScene:240},x={fade:{type:"fade",durationInFrames:20},slideLeft:{type:"slide-left",durationInFrames:20},slideRight:{type:"slide-right",durationInFrames:20},wipe:{type:"wipe",durationInFrames:15},none:{type:"none",durationInFrames:0}};export{x as videoTransitions,v as videoEasing,w as videoDurations};
|
|
@@ -1,23 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
3
|
-
|
|
4
|
-
// src/design/tokens.ts
|
|
5
|
-
import { defaultTokens } from "@contractspec/lib.design-system";
|
|
6
|
-
var defaultVideoColors = {
|
|
7
|
-
canvasBackground: defaultTokens.colors.background,
|
|
8
|
-
codeBackground: "#1e1e2e",
|
|
9
|
-
terminalBackground: "#0d1117",
|
|
10
|
-
terminalForeground: "#c9d1d9",
|
|
11
|
-
highlight: defaultTokens.colors.accent,
|
|
12
|
-
gradientStart: defaultTokens.colors.primary,
|
|
13
|
-
gradientEnd: defaultTokens.colors.accent
|
|
14
|
-
};
|
|
15
|
-
var defaultVideoTheme = {
|
|
16
|
-
...defaultTokens,
|
|
17
|
-
video: defaultVideoColors
|
|
18
|
-
};
|
|
19
|
-
export {
|
|
20
|
-
defaultVideoTheme,
|
|
21
|
-
defaultVideoColors,
|
|
22
|
-
defaultTokens
|
|
23
|
-
};
|
|
1
|
+
import{createRequire as q}from"node:module";var B=q(import.meta.url);import{defaultTokens as j}from"@contractspec/lib.design-system";var z={canvasBackground:j.colors.background,codeBackground:"#1e1e2e",terminalBackground:"#0d1117",terminalForeground:"#c9d1d9",highlight:j.colors.accent,gradientStart:j.colors.primary,gradientEnd:j.colors.accent},F={...j,video:z};export{F as defaultVideoTheme,z as defaultVideoColors,j as defaultTokens};
|
|
@@ -1,56 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
3
|
-
|
|
4
|
-
// src/design/typography.ts
|
|
5
|
-
var videoTypography = {
|
|
6
|
-
title: {
|
|
7
|
-
fontSize: 72,
|
|
8
|
-
lineHeight: 1.1,
|
|
9
|
-
fontWeight: 700,
|
|
10
|
-
letterSpacing: -1
|
|
11
|
-
},
|
|
12
|
-
heading: {
|
|
13
|
-
fontSize: 56,
|
|
14
|
-
lineHeight: 1.2,
|
|
15
|
-
fontWeight: 600,
|
|
16
|
-
letterSpacing: -0.5
|
|
17
|
-
},
|
|
18
|
-
subheading: {
|
|
19
|
-
fontSize: 40,
|
|
20
|
-
lineHeight: 1.25,
|
|
21
|
-
fontWeight: 500
|
|
22
|
-
},
|
|
23
|
-
body: {
|
|
24
|
-
fontSize: 32,
|
|
25
|
-
lineHeight: 1.5,
|
|
26
|
-
fontWeight: 400
|
|
27
|
-
},
|
|
28
|
-
code: {
|
|
29
|
-
fontSize: 28,
|
|
30
|
-
lineHeight: 1.6,
|
|
31
|
-
fontWeight: 400
|
|
32
|
-
},
|
|
33
|
-
caption: {
|
|
34
|
-
fontSize: 24,
|
|
35
|
-
lineHeight: 1.4,
|
|
36
|
-
fontWeight: 400
|
|
37
|
-
},
|
|
38
|
-
label: {
|
|
39
|
-
fontSize: 20,
|
|
40
|
-
lineHeight: 1.3,
|
|
41
|
-
fontWeight: 600,
|
|
42
|
-
letterSpacing: 1
|
|
43
|
-
}
|
|
44
|
-
};
|
|
45
|
-
function scaleTypography(style, targetWidth) {
|
|
46
|
-
const scale = targetWidth / 1920;
|
|
47
|
-
return {
|
|
48
|
-
...style,
|
|
49
|
-
fontSize: Math.round(style.fontSize * scale),
|
|
50
|
-
letterSpacing: style.letterSpacing ? Math.round(style.letterSpacing * scale * 10) / 10 : undefined
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
export {
|
|
54
|
-
videoTypography,
|
|
55
|
-
scaleTypography
|
|
56
|
-
};
|
|
1
|
+
import{createRequire as m}from"node:module";var u=m(import.meta.url);var A={title:{fontSize:72,lineHeight:1.1,fontWeight:700,letterSpacing:-1},heading:{fontSize:56,lineHeight:1.2,fontWeight:600,letterSpacing:-0.5},subheading:{fontSize:40,lineHeight:1.25,fontWeight:500},body:{fontSize:32,lineHeight:1.5,fontWeight:400},code:{fontSize:28,lineHeight:1.6,fontWeight:400},caption:{fontSize:24,lineHeight:1.4,fontWeight:400},label:{fontSize:20,lineHeight:1.3,fontWeight:600,letterSpacing:1}};function B(b,k){let j=k/1920;return{...b,fontSize:Math.round(b.fontSize*j),letterSpacing:b.letterSpacing?Math.round(b.letterSpacing*j*10)/10:void 0}}export{A as videoTypography,B as scaleTypography};
|
|
@@ -1,182 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { registerDocBlocks } from "@contractspec/lib.contracts-spec/docs";
|
|
3
|
-
var compositionsDocBlocks = [
|
|
4
|
-
{
|
|
5
|
-
id: "docs.video-gen.compositions",
|
|
6
|
-
title: "Video Compositions & Primitives",
|
|
7
|
-
summary: "Remotion composition components and reusable primitives for building programmatic videos.",
|
|
8
|
-
kind: "reference",
|
|
9
|
-
visibility: "public",
|
|
10
|
-
route: "/docs/video-gen/compositions",
|
|
11
|
-
tags: ["video", "remotion", "compositions", "primitives", "react"],
|
|
12
|
-
owners: ["@contractspec/lib.video-gen"],
|
|
13
|
-
body: `# Video Compositions & Primitives
|
|
14
|
-
|
|
15
|
-
Compositions are React components rendered by Remotion. They use \`useCurrentFrame()\`, \`useVideoConfig()\`, and \`interpolate()\` to produce frame-accurate animations. All compositions must be **deterministic**: same props = same visual output.
|
|
16
|
-
|
|
17
|
-
## Primitive Components
|
|
18
|
-
|
|
19
|
-
Primitives are reusable building blocks for constructing full compositions.
|
|
20
|
-
|
|
21
|
-
\`\`\`ts
|
|
22
|
-
import {
|
|
23
|
-
AnimatedText,
|
|
24
|
-
CodeBlock,
|
|
25
|
-
Terminal,
|
|
26
|
-
BrandFrame,
|
|
27
|
-
ProgressBar,
|
|
28
|
-
SceneTransitionWrapper,
|
|
29
|
-
} from "@contractspec/lib.video-gen/compositions/primitives";
|
|
30
|
-
\`\`\`
|
|
31
|
-
|
|
32
|
-
### AnimatedText
|
|
33
|
-
|
|
34
|
-
Text with entrance/exit slide + fade animations.
|
|
35
|
-
|
|
36
|
-
| Prop | Type | Default | Description |
|
|
37
|
-
|------|------|---------|-------------|
|
|
38
|
-
| \`text\` | \`string\` | -- | Text content |
|
|
39
|
-
| \`variant\` | \`keyof videoTypography\` | \`"body"\` | Typography preset (title, heading, subheading, body, code, caption, label) |
|
|
40
|
-
| \`enterAt\` | \`number\` | \`0\` | Frame at which text enters |
|
|
41
|
-
| \`exitAt\` | \`number\` | -- | Frame at which text exits (omit to keep visible) |
|
|
42
|
-
| \`color\` | \`string\` | \`"#ffffff"\` | Text color |
|
|
43
|
-
| \`align\` | \`"left" \\| "center" \\| "right"\` | \`"left"\` | Text alignment |
|
|
44
|
-
|
|
45
|
-
### CodeBlock
|
|
46
|
-
|
|
47
|
-
Syntax-aware code display with typing animation and macOS-style title bar.
|
|
48
|
-
|
|
49
|
-
| Prop | Type | Default | Description |
|
|
50
|
-
|------|------|---------|-------------|
|
|
51
|
-
| \`code\` | \`string\` | -- | Code string to display |
|
|
52
|
-
| \`language\` | \`string\` | \`"typescript"\` | Language label in the title bar |
|
|
53
|
-
| \`startAt\` | \`number\` | \`0\` | Frame at which typing starts |
|
|
54
|
-
| \`typeAnimation\` | \`boolean\` | \`true\` | Animate character-by-character typing |
|
|
55
|
-
| \`filename\` | \`string\` | -- | Filename in the title bar (overrides language) |
|
|
56
|
-
|
|
57
|
-
### Terminal
|
|
58
|
-
|
|
59
|
-
CLI simulator with command typing, output lines, and cursor animation.
|
|
60
|
-
|
|
61
|
-
| Prop | Type | Default | Description |
|
|
62
|
-
|------|------|---------|-------------|
|
|
63
|
-
| \`lines\` | \`TerminalLine[]\` | -- | Lines to display in sequence |
|
|
64
|
-
| \`startAt\` | \`number\` | \`0\` | Frame at which terminal appears |
|
|
65
|
-
| \`prompt\` | \`string\` | \`"$ "\` | Prompt string before commands |
|
|
66
|
-
| \`title\` | \`string\` | \`"Terminal"\` | Title bar text |
|
|
67
|
-
| \`typingSpeed\` | \`number\` | \`2\` | Frames per character for commands |
|
|
68
|
-
|
|
69
|
-
\`TerminalLine\` types: \`command\` (typed), \`output\` (faded in), \`error\` (red), \`success\` (green), \`comment\` (dimmed with \`#\` prefix).
|
|
70
|
-
|
|
71
|
-
### BrandFrame
|
|
72
|
-
|
|
73
|
-
Branded container with safe-zone padding, gradient/solid/dark backgrounds, and optional watermark.
|
|
74
|
-
|
|
75
|
-
| Prop | Type | Default | Description |
|
|
76
|
-
|------|------|---------|-------------|
|
|
77
|
-
| \`variant\` | \`"solid" \\| "gradient" \\| "dark"\` | \`"gradient"\` | Background style |
|
|
78
|
-
| \`showBranding\` | \`boolean\` | \`true\` | Show "ContractSpec" watermark |
|
|
79
|
-
| \`animateEntrance\` | \`boolean\` | \`true\` | Fade-in on first frames |
|
|
80
|
-
| \`styleOverrides\` | \`VideoStyleOverrides\` | -- | Override colors, fonts, dark mode |
|
|
81
|
-
|
|
82
|
-
### ProgressBar
|
|
83
|
-
|
|
84
|
-
Thin progress indicator at the top or bottom of the frame.
|
|
85
|
-
|
|
86
|
-
| Prop | Type | Default | Description |
|
|
87
|
-
|------|------|---------|-------------|
|
|
88
|
-
| \`height\` | \`number\` | \`4\` | Bar height in pixels |
|
|
89
|
-
| \`color\` | \`string\` | primary color | Bar fill color |
|
|
90
|
-
| \`position\` | \`"top" \\| "bottom"\` | \`"bottom"\` | Placement |
|
|
91
|
-
|
|
92
|
-
### SceneTransitionWrapper
|
|
93
|
-
|
|
94
|
-
Wraps children with entrance/exit transitions (fade, slide-left, slide-right, wipe).
|
|
95
|
-
|
|
96
|
-
| Prop | Type | Default | Description |
|
|
97
|
-
|------|------|---------|-------------|
|
|
98
|
-
| \`type\` | \`SceneTransitionType\` | -- | Transition type |
|
|
99
|
-
| \`durationInFrames\` | \`number\` | -- | Transition duration |
|
|
100
|
-
| \`direction\` | \`"in" \\| "out"\` | -- | Entering or exiting |
|
|
101
|
-
|
|
102
|
-
## Full Compositions
|
|
103
|
-
|
|
104
|
-
Full compositions combine primitives into complete video templates. They are registered in Remotion Studio via \`RemotionRoot\`.
|
|
105
|
-
|
|
106
|
-
### ApiOverview
|
|
107
|
-
|
|
108
|
-
Visualizes a ContractSpec definition generating a full API surface. Used for homepage demos and documentation.
|
|
109
|
-
|
|
110
|
-
\`\`\`tsx
|
|
111
|
-
import { ApiOverview } from "@contractspec/lib.video-gen/compositions/api-overview";
|
|
112
|
-
|
|
113
|
-
<ApiOverview
|
|
114
|
-
specName="CreateUser"
|
|
115
|
-
method="POST"
|
|
116
|
-
endpoint="/api/users"
|
|
117
|
-
specCode={\`export const createUser = defineCommand({...})\`}
|
|
118
|
-
generatedOutputs={["REST Endpoint", "GraphQL Mutation", "Prisma Model"]}
|
|
119
|
-
tagline="One spec. Every surface."
|
|
120
|
-
/>
|
|
121
|
-
\`\`\`
|
|
122
|
-
|
|
123
|
-
**Scenes**: Title + method badge -> Code typing animation -> Generated outputs fan-out -> Tagline.
|
|
124
|
-
|
|
125
|
-
### SocialClip
|
|
126
|
-
|
|
127
|
-
Short-form marketing content for LinkedIn, X, YouTube Shorts. Adapts layout for landscape (16:9), square (1:1), and portrait (9:16).
|
|
128
|
-
|
|
129
|
-
\`\`\`tsx
|
|
130
|
-
import { SocialClip } from "@contractspec/lib.video-gen/compositions/social-clip";
|
|
131
|
-
|
|
132
|
-
<SocialClip
|
|
133
|
-
hook="Stop rewriting the same API logic."
|
|
134
|
-
message="Generate REST, GraphQL, DB, SDK from a single spec."
|
|
135
|
-
points={["Deterministic output", "Fully ejectable", "No lock-in"]}
|
|
136
|
-
cta="Try ContractSpec"
|
|
137
|
-
ctaUrl="contractspec.dev"
|
|
138
|
-
/>
|
|
139
|
-
\`\`\`
|
|
140
|
-
|
|
141
|
-
**Scenes**: Hook (attention grabber) -> Main message -> Supporting points -> CTA button.
|
|
142
|
-
|
|
143
|
-
### TerminalDemo
|
|
144
|
-
|
|
145
|
-
CLI command walkthrough with animated terminal. Used in documentation and tutorial videos.
|
|
146
|
-
|
|
147
|
-
\`\`\`tsx
|
|
148
|
-
import { TerminalDemo } from "@contractspec/lib.video-gen/compositions/terminal-demo";
|
|
149
|
-
|
|
150
|
-
<TerminalDemo
|
|
151
|
-
title="Getting Started with ContractSpec"
|
|
152
|
-
subtitle="Define once, generate everything."
|
|
153
|
-
lines={[
|
|
154
|
-
{ type: "command", text: "npx contractspec init my-api" },
|
|
155
|
-
{ type: "output", text: "Created my-api/ with 3 sample contracts" },
|
|
156
|
-
{ type: "command", text: "npx contractspec build" },
|
|
157
|
-
{ type: "success", text: "Built 3 contracts -> 18 generated files" },
|
|
158
|
-
]}
|
|
159
|
-
summary="Ship faster. Stay coherent."
|
|
160
|
-
/>
|
|
161
|
-
\`\`\`
|
|
162
|
-
|
|
163
|
-
**Scenes**: Title + subtitle -> Terminal typing animation -> Summary.
|
|
164
|
-
|
|
165
|
-
## Creating New Compositions
|
|
166
|
-
|
|
167
|
-
1. Create a new \`.tsx\` file in \`src/compositions/\`.
|
|
168
|
-
2. Use primitives from \`./primitives/\` and design tokens from \`../design/\`.
|
|
169
|
-
3. Use \`useCurrentFrame()\` and \`interpolate()\` for frame-based animations.
|
|
170
|
-
4. Register in \`src/remotion/Root.tsx\` with a \`<Composition>\` entry.
|
|
171
|
-
5. Export from \`src/compositions/index.ts\`.
|
|
172
|
-
6. Add the export path to \`package.json\` (both workspace and publishConfig).
|
|
173
|
-
|
|
174
|
-
### Guardrails
|
|
175
|
-
|
|
176
|
-
- Keep compositions **pure**: no side effects, no network calls, no randomness.
|
|
177
|
-
- Use \`scaleSafeZone()\` and \`scaleTypography()\` to support multiple formats.
|
|
178
|
-
- All timing should be frame-based (not time-based) for deterministic output.
|
|
179
|
-
`
|
|
180
|
-
}
|
|
181
|
-
];
|
|
182
|
-
registerDocBlocks(compositionsDocBlocks);
|
|
1
|
+
import{registerDocBlocks as f}from"@contractspec/lib.contracts-spec/docs";var h=[{id:"docs.video-gen.compositions",title:"Video Compositions & Primitives",summary:"Remotion composition components and reusable primitives for building programmatic videos.",kind:"reference",visibility:"public",route:"/docs/video-gen/compositions",tags:["video","remotion","compositions","primitives","react"],owners:["@contractspec/lib.video-gen"],body:'# Video Compositions & Primitives\n\nCompositions are React components rendered by Remotion. They use `useCurrentFrame()`, `useVideoConfig()`, and `interpolate()` to produce frame-accurate animations. All compositions must be **deterministic**: same props = same visual output.\n\n## Primitive Components\n\nPrimitives are reusable building blocks for constructing full compositions.\n\n```ts\nimport {\n AnimatedText,\n CodeBlock,\n Terminal,\n BrandFrame,\n ProgressBar,\n SceneTransitionWrapper,\n} from "@contractspec/lib.video-gen/compositions/primitives";\n```\n\n### AnimatedText\n\nText with entrance/exit slide + fade animations.\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `text` | `string` | -- | Text content |\n| `variant` | `keyof videoTypography` | `"body"` | Typography preset (title, heading, subheading, body, code, caption, label) |\n| `enterAt` | `number` | `0` | Frame at which text enters |\n| `exitAt` | `number` | -- | Frame at which text exits (omit to keep visible) |\n| `color` | `string` | `"#ffffff"` | Text color |\n| `align` | `"left" \\| "center" \\| "right"` | `"left"` | Text alignment |\n\n### CodeBlock\n\nSyntax-aware code display with typing animation and macOS-style title bar.\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `code` | `string` | -- | Code string to display |\n| `language` | `string` | `"typescript"` | Language label in the title bar |\n| `startAt` | `number` | `0` | Frame at which typing starts |\n| `typeAnimation` | `boolean` | `true` | Animate character-by-character typing |\n| `filename` | `string` | -- | Filename in the title bar (overrides language) |\n\n### Terminal\n\nCLI simulator with command typing, output lines, and cursor animation.\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `lines` | `TerminalLine[]` | -- | Lines to display in sequence |\n| `startAt` | `number` | `0` | Frame at which terminal appears |\n| `prompt` | `string` | `"$ "` | Prompt string before commands |\n| `title` | `string` | `"Terminal"` | Title bar text |\n| `typingSpeed` | `number` | `2` | Frames per character for commands |\n\n`TerminalLine` types: `command` (typed), `output` (faded in), `error` (red), `success` (green), `comment` (dimmed with `#` prefix).\n\n### BrandFrame\n\nBranded container with safe-zone padding, gradient/solid/dark backgrounds, and optional watermark.\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `variant` | `"solid" \\| "gradient" \\| "dark"` | `"gradient"` | Background style |\n| `showBranding` | `boolean` | `true` | Show "ContractSpec" watermark |\n| `animateEntrance` | `boolean` | `true` | Fade-in on first frames |\n| `styleOverrides` | `VideoStyleOverrides` | -- | Override colors, fonts, dark mode |\n\n### ProgressBar\n\nThin progress indicator at the top or bottom of the frame.\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `height` | `number` | `4` | Bar height in pixels |\n| `color` | `string` | primary color | Bar fill color |\n| `position` | `"top" \\| "bottom"` | `"bottom"` | Placement |\n\n### SceneTransitionWrapper\n\nWraps children with entrance/exit transitions (fade, slide-left, slide-right, wipe).\n\n| Prop | Type | Default | Description |\n|------|------|---------|-------------|\n| `type` | `SceneTransitionType` | -- | Transition type |\n| `durationInFrames` | `number` | -- | Transition duration |\n| `direction` | `"in" \\| "out"` | -- | Entering or exiting |\n\n## Full Compositions\n\nFull compositions combine primitives into complete video templates. They are registered in Remotion Studio via `RemotionRoot`.\n\n### ApiOverview\n\nVisualizes a ContractSpec definition generating a full API surface. Used for homepage demos and documentation.\n\n```tsx\nimport { ApiOverview } from "@contractspec/lib.video-gen/compositions/api-overview";\n\n<ApiOverview\n specName="CreateUser"\n method="POST"\n endpoint="/api/users"\n specCode={`export const createUser = defineCommand({...})`}\n generatedOutputs={["REST Endpoint", "GraphQL Mutation", "Prisma Model"]}\n tagline="One spec. Every surface."\n/>\n```\n\n**Scenes**: Title + method badge -> Code typing animation -> Generated outputs fan-out -> Tagline.\n\n### SocialClip\n\nShort-form marketing content for LinkedIn, X, YouTube Shorts. Adapts layout for landscape (16:9), square (1:1), and portrait (9:16).\n\n```tsx\nimport { SocialClip } from "@contractspec/lib.video-gen/compositions/social-clip";\n\n<SocialClip\n hook="Stop rewriting the same API logic."\n message="Generate REST, GraphQL, DB, SDK from a single spec."\n points={["Deterministic output", "Fully ejectable", "No lock-in"]}\n cta="Try ContractSpec"\n ctaUrl="contractspec.dev"\n/>\n```\n\n**Scenes**: Hook (attention grabber) -> Main message -> Supporting points -> CTA button.\n\n### TerminalDemo\n\nCLI command walkthrough with animated terminal. Used in documentation and tutorial videos.\n\n```tsx\nimport { TerminalDemo } from "@contractspec/lib.video-gen/compositions/terminal-demo";\n\n<TerminalDemo\n title="Getting Started with ContractSpec"\n subtitle="Define once, generate everything."\n lines={[\n { type: "command", text: "npx contractspec init my-api" },\n { type: "output", text: "Created my-api/ with 3 sample contracts" },\n { type: "command", text: "npx contractspec build" },\n { type: "success", text: "Built 3 contracts -> 18 generated files" },\n ]}\n summary="Ship faster. Stay coherent."\n/>\n```\n\n**Scenes**: Title + subtitle -> Terminal typing animation -> Summary.\n\n## Creating New Compositions\n\n1. Create a new `.tsx` file in `src/compositions/`.\n2. Use primitives from `./primitives/` and design tokens from `../design/`.\n3. Use `useCurrentFrame()` and `interpolate()` for frame-based animations.\n4. Register in `src/remotion/Root.tsx` with a `<Composition>` entry.\n5. Export from `src/compositions/index.ts`.\n6. Add the export path to `package.json` (both workspace and publishConfig).\n\n### Guardrails\n\n- Keep compositions **pure**: no side effects, no network calls, no randomness.\n- Use `scaleSafeZone()` and `scaleTypography()` to support multiple formats.\n- All timing should be frame-based (not time-based) for deterministic output.\n'}];f(h);
|
|
@@ -1,16 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { registerDocBlocks } from "@contractspec/lib.contracts-spec/docs";
|
|
3
|
-
var designDocBlocks = [
|
|
4
|
-
{
|
|
5
|
-
id: "docs.video-gen.design",
|
|
6
|
-
title: "Video Design System",
|
|
7
|
-
summary: "Design tokens, motion primitives, typography scale, and layout system optimized for programmatic video.",
|
|
8
|
-
kind: "reference",
|
|
9
|
-
visibility: "public",
|
|
10
|
-
route: "/docs/video-gen/design",
|
|
11
|
-
tags: ["video", "design-tokens", "motion", "typography", "layout"],
|
|
12
|
-
owners: ["@contractspec/lib.video-gen"],
|
|
13
|
-
body: `# Video Design System
|
|
1
|
+
import{registerDocBlocks as f}from"@contractspec/lib.contracts-spec/docs";var h=[{id:"docs.video-gen.design",title:"Video Design System",summary:"Design tokens, motion primitives, typography scale, and layout system optimized for programmatic video.",kind:"reference",visibility:"public",route:"/docs/video-gen/design",tags:["video","design-tokens","motion","typography","layout"],owners:["@contractspec/lib.video-gen"],body:`# Video Design System
|
|
14
2
|
|
|
15
3
|
The design layer bridges \`@contractspec/lib.design-system\` brand tokens with video-specific extensions for motion, typography, and spatial layout. All values are optimized for 1920x1080 (landscape) and scale proportionally for other formats.
|
|
16
4
|
|
|
@@ -181,7 +169,4 @@ VIDEO_FORMATS.square; // { type: "square", width: 1080, height: 1080 }
|
|
|
181
169
|
getAllFormatVariants(); // [landscape, square, portrait]
|
|
182
170
|
DEFAULT_FPS; // 30
|
|
183
171
|
\`\`\`
|
|
184
|
-
`
|
|
185
|
-
}
|
|
186
|
-
];
|
|
187
|
-
registerDocBlocks(designDocBlocks);
|
|
172
|
+
`}];f(h);
|
|
@@ -1,23 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { registerDocBlocks } from "@contractspec/lib.contracts-spec/docs";
|
|
3
|
-
var generatorsDocBlocks = [
|
|
4
|
-
{
|
|
5
|
-
id: "docs.video-gen.generators",
|
|
6
|
-
title: "Video Generation Pipeline",
|
|
7
|
-
summary: "VideoGenerator, ScenePlanner, and ScriptGenerator -- from content brief to video project with optional LLM enhancement.",
|
|
8
|
-
kind: "reference",
|
|
9
|
-
visibility: "public",
|
|
10
|
-
route: "/docs/video-gen/generators",
|
|
11
|
-
tags: [
|
|
12
|
-
"video",
|
|
13
|
-
"generators",
|
|
14
|
-
"scene-planner",
|
|
15
|
-
"script-generator",
|
|
16
|
-
"llm",
|
|
17
|
-
"content-pipeline"
|
|
18
|
-
],
|
|
19
|
-
owners: ["@contractspec/lib.video-gen"],
|
|
20
|
-
body: `# Video Generation Pipeline
|
|
1
|
+
import{registerDocBlocks as f}from"@contractspec/lib.contracts-spec/docs";var h=[{id:"docs.video-gen.generators",title:"Video Generation Pipeline",summary:"VideoGenerator, ScenePlanner, and ScriptGenerator -- from content brief to video project with optional LLM enhancement.",kind:"reference",visibility:"public",route:"/docs/video-gen/generators",tags:["video","generators","scene-planner","script-generator","llm","content-pipeline"],owners:["@contractspec/lib.video-gen"],body:`# Video Generation Pipeline
|
|
21
2
|
|
|
22
3
|
The generators layer converts a \`VideoBrief\` (content brief + video config) into a fully specified \`VideoProject\` (scene graph ready for rendering). It follows the \`@contractspec/lib.content-gen\` pattern: optional LLM, deterministic fallback.
|
|
23
4
|
|
|
@@ -181,7 +162,4 @@ interface PlannedScene {
|
|
|
181
162
|
- LLM responses are parsed as JSON; any parse failure falls back to deterministic.
|
|
182
163
|
- Temperature defaults are conservative (0.3-0.5) for reproducibility.
|
|
183
164
|
- Duration estimates use 150 words/min speaking rate.
|
|
184
|
-
`
|
|
185
|
-
}
|
|
186
|
-
];
|
|
187
|
-
registerDocBlocks(generatorsDocBlocks);
|
|
165
|
+
`}];f(h);
|
|
@@ -1,23 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { registerDocBlocks } from "@contractspec/lib.contracts-spec/docs";
|
|
3
|
-
var renderingDocBlocks = [
|
|
4
|
-
{
|
|
5
|
-
id: "docs.video-gen.rendering",
|
|
6
|
-
title: "Video Rendering & Playback",
|
|
7
|
-
summary: "LocalRenderer for MP4 output, render configuration, quality presets, DemoPlayer for web embedding, and Remotion Studio setup.",
|
|
8
|
-
kind: "reference",
|
|
9
|
-
visibility: "public",
|
|
10
|
-
route: "/docs/video-gen/rendering",
|
|
11
|
-
tags: [
|
|
12
|
-
"video",
|
|
13
|
-
"rendering",
|
|
14
|
-
"remotion",
|
|
15
|
-
"player",
|
|
16
|
-
"mp4",
|
|
17
|
-
"quality-presets"
|
|
18
|
-
],
|
|
19
|
-
owners: ["@contractspec/lib.video-gen"],
|
|
20
|
-
body: `# Video Rendering & Playback
|
|
1
|
+
import{registerDocBlocks as f}from"@contractspec/lib.contracts-spec/docs";var h=[{id:"docs.video-gen.rendering",title:"Video Rendering & Playback",summary:"LocalRenderer for MP4 output, render configuration, quality presets, DemoPlayer for web embedding, and Remotion Studio setup.",kind:"reference",visibility:"public",route:"/docs/video-gen/rendering",tags:["video","rendering","remotion","player","mp4","quality-presets"],owners:["@contractspec/lib.video-gen"],body:`# Video Rendering & Playback
|
|
21
2
|
|
|
22
3
|
The rendering layer wraps \`@remotion/renderer\` for MP4/WebM output and \`@remotion/player\` for interactive web embedding. It implements the \`VideoProvider\` contract from \`@contractspec/lib.contracts-integrations\`.
|
|
23
4
|
|
|
@@ -191,7 +172,4 @@ All compositions run at 30fps.
|
|
|
191
172
|
- Import \`LocalRenderer\` from the \`/renderers/local\` subpath to avoid bundling \`@remotion/renderer\` in browser builds.
|
|
192
173
|
- The \`remotion\` entry point (\`@contractspec/lib.video-gen/remotion\`) is a **side-effect module** that calls \`registerRoot()\`. Only import it from Remotion Studio or render scripts.
|
|
193
174
|
- Use quality presets for consistency: \`draft\` for development, \`standard\` for CI, \`high\` for releases.
|
|
194
|
-
`
|
|
195
|
-
}
|
|
196
|
-
];
|
|
197
|
-
registerDocBlocks(renderingDocBlocks);
|
|
175
|
+
`}];f(h);
|
|
@@ -1,16 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { registerDocBlocks } from "@contractspec/lib.contracts-spec/docs";
|
|
3
|
-
var videoGenDocBlocks = [
|
|
4
|
-
{
|
|
5
|
-
id: "docs.video-gen.overview",
|
|
6
|
-
title: "Video Generation Library",
|
|
7
|
-
summary: "Programmatic video generation with Remotion -- from content brief to rendered MP4 in a single pipeline.",
|
|
8
|
-
kind: "reference",
|
|
9
|
-
visibility: "public",
|
|
10
|
-
route: "/docs/video-gen/overview",
|
|
11
|
-
tags: ["video", "remotion", "generation", "content-pipeline"],
|
|
12
|
-
owners: ["@contractspec/lib.video-gen"],
|
|
13
|
-
body: `# Video Generation Library
|
|
1
|
+
import{registerDocBlocks as f}from"@contractspec/lib.contracts-spec/docs";var h=[{id:"docs.video-gen.overview",title:"Video Generation Library",summary:"Programmatic video generation with Remotion -- from content brief to rendered MP4 in a single pipeline.",kind:"reference",visibility:"public",route:"/docs/video-gen/overview",tags:["video","remotion","generation","content-pipeline"],owners:["@contractspec/lib.video-gen"],body:`# Video Generation Library
|
|
14
2
|
|
|
15
3
|
\`@contractspec/lib.video-gen\` provides **programmatic video generation** using [Remotion](https://remotion.dev). It follows the same generator pattern as \`@contractspec/lib.content-gen\` and consumes provider contracts from \`@contractspec/lib.contracts-integrations/integrations/providers/video\`.
|
|
16
4
|
|
|
@@ -135,7 +123,4 @@ This matches the content-gen pattern: \`constructor({ llm? })\` -> \`generate(br
|
|
|
135
123
|
- Design tokens bridge from \`@contractspec/lib.design-system\` -- do not duplicate brand values.
|
|
136
124
|
- \`LocalRenderer\` works with Node.js and Bun. On Bun, SSR scripts may not auto-quit (see [Remotion Bun docs](https://www.remotion.dev/docs/bun)).
|
|
137
125
|
- The \`remotion\` entry point is a side-effect module (calls \`registerRoot\`) -- import it only from Remotion Studio or render scripts.
|
|
138
|
-
`
|
|
139
|
-
}
|
|
140
|
-
];
|
|
141
|
-
registerDocBlocks(videoGenDocBlocks);
|
|
126
|
+
`}];f(h);
|