🎥 Make videos programmatically with React
put video apps everywhere
Jonny Burgerae9df73e50f4
diff --git a/packages/docs/components/LambdaSplash/BuildApps.tsx b/packages/docs/components/LambdaSplash/BuildApps.tsxindex 60810e712a..c7ddef87b9 100644--- a/packages/docs/components/LambdaSplash/BuildApps.tsx+++ b/packages/docs/components/LambdaSplash/BuildApps.tsx@@ -2,6 +2,7 @@ import { useColorMode } from "@docusaurus/theme-common";import React from "react";import { BlueButton } from "../layout/Button";import { Spacer } from "../layout/Spacer";+import { VideoApps } from "./VideoApps";const panel: React.CSSProperties = {backgroundColor: "var(--ifm-background-color)",@@ -67,141 +68,21 @@ export const BuildApps: React.FC = () => {const { colorMode } = useColorMode();return (<div>- <h1 style={center}>Build Video Apps</h1>+ <h1 style={center}>+ Build video{" "}+ <span+ style={{+ color: "var(--ifm-color-primary)",+ }}+ >+ apps+ </span>+ </h1>+ <p style={{ textAlign: "center" }}>+ Combine our tools to build apps that leverage programmatic video.+ </p><br />- <div style={row}>- <div style={step}>- <h2 style={stepTitle}>Remotion</h2>- <strong style={center}>Write videos in React</strong>- <br />- <div- style={{- display: "flex",- justifyContent: "center",- alignItems: "center",- flex: 1,- }}- >- <img src="/img/writeinreact.png" />- </div>- <ul style={list}>- <li>Use the Web to create graphics</li>- <hr style={hr} />- <li>Consume user input and APIs</li>- <hr style={hr} />- <li>Render real MP4 videos</li>- </ul>- <div style={row}>- <div style={flex}>- <a style={docsButton} href="/">- <BlueButton loading={false} fullWidth size="sm">- Learn more- </BlueButton>- </a>- </div>- <Spacer />- <Spacer />- <div style={flex}>- <a style={docsButton} href="/docs">- <BlueButton loading={false} fullWidth size="sm">- Read docs- </BlueButton>- </a>- </div>- </div>- </div>- <Spacer />- <Spacer />- <Spacer />- <div style={step}>- <h2 style={stepTitle}>Remotion Player</h2>- <strong style={center}>Embeddable interactive videos</strong>- <br />-- <div- style={{- display: "flex",- justifyContent: "center",- alignItems: "center",- flex: 1,- }}- >- <img- src={- colorMode === "dark"- ? "/img/player-example-dark.png"- : "/img/player-example.png"- }- />- </div>- <ul style={list}>- <li>Preview videos in the browser</li>- <hr style={hr} />- <li>React to user input</li>- <hr style={hr} />- <li>Customize look and behavior</li>- </ul>- <div style={row}>- <div style={flex}>- <a style={docsButton} href="/player">- <BlueButton loading={false} fullWidth size="sm">- Learn more- </BlueButton>- </a>- </div>- <Spacer />- <Spacer />- <div style={flex}>- <a style={docsButton} href="/docs/player">- <BlueButton loading={false} fullWidth size="sm">- Read docs- </BlueButton>- </a>- </div>- </div>- </div>- <Spacer />- <Spacer />- <Spacer />- <div style={step}>- <h2 style={stepTitle}>Remotion Lambda</h2>- <strong style={center}>Render at scale</strong>- <br />- <div- style={{- display: "flex",- justifyContent: "center",- alignItems: "center",- flex: 1,- }}- >- <img- src={- colorMode === "dark"- ? "/img/cluster-dark.png"- : "/img/cluster.png"- }- />- </div>-- <ul style={list}>- <li>Render videos in the cloud</li>- <hr style={hr} />- <li>Scale according to your volume</li>- <hr style={hr} />- <li>Fast because distributed</li>- </ul>- <div style={row}>- <div style={flex}>- <a style={docsButton} href="/docs/lambda">- <BlueButton loading={false} fullWidth size="sm">- Read docs- </BlueButton>- </a>- </div>- </div>- </div>- </div>+ <VideoApps /><br /><p style={center}>All Remotion products are source-available, for self-hosting, free fordiff --git a/packages/docs/components/LambdaSplash/Disclaimers.tsx b/packages/docs/components/LambdaSplash/Disclaimers.tsxindex 6ea5876372..1a375b9674 100644--- a/packages/docs/components/LambdaSplash/Disclaimers.tsx+++ b/packages/docs/components/LambdaSplash/Disclaimers.tsx@@ -21,11 +21,12 @@ export const Disclaimers: React.FC = () => {us-east-1 region. Does not include S3 and data transfer costs.</div><div className={styles.disclaimer}>- 3) Estimated cost when rendering the Remotion Lambda trailer with{" "}- <code>--frames-per-lambda=12</code>, an ARM64 Lambda function with- 2048MB RAM, on warm Lambdas on the us-east-1 region. Does not include S3- and data transfer costs. Check <a href="/docs/license">Licensing</a>{" "}- whether you need to acquire a license to use Remotion Lambda.+ 3) Estimated cost per minute of video when rendering the Remotion Lambda+ trailer with <code>--frames-per-lambda=12</code>, an ARM64 Lambda+ function with 2048MB RAM, on warm Lambdas on the us-east-1 region. Does+ not include S3 and data transfer costs. Check{" "}+ <a href="/docs/license">Licensing</a> whether you need to acquire a+ license to use Remotion Lambda.</div></div>);diff --git a/packages/docs/components/LambdaSplash/RenderTimes.tsx b/packages/docs/components/LambdaSplash/RenderTimes.tsxindex ba4b3a4a96..a44d23db86 100644--- a/packages/docs/components/LambdaSplash/RenderTimes.tsx+++ b/packages/docs/components/LambdaSplash/RenderTimes.tsx@@ -3,33 +3,44 @@ import styles from "./rendertimes.module.css";export const RenderTimes: React.FC = () => {return (- <div- style={{- display: "flex",- flexDirection: "row",- }}- >- <div className={styles.stat}>- <p>80 sec video rendered in</p>- <h1>- 15 sec<sup>1)</sup>- </h1>+ <div className={styles.row}>+ <div+ style={{+ display: "flex",+ flexDirection: "row",+ flex: 1,+ }}+ >+ <div className={styles.stat}>+ <p>80 sec video rendered in</p>+ <h1>+ 15 sec<sup>1)</sup>+ </h1>+ </div>+ <div className={styles.stat}>+ <p>2 hr video rendered in</p>+ <h1>+ 12 min<sup>2)</sup>+ </h1>+ </div></div>- <div className={styles.stat}>- <p>2 hr video rendered in</p>- <h1>- 12 min<sup>2)</sup>- </h1>- </div>- <div className={styles.stat}>- <p>Concurrency up to</p>- <h1>200x</h1>- </div>- <div className={styles.stat}>- <p>Cost per minute</p>- <h1>- $0.01<sup>3)</sup>- </h1>+ <div+ style={{+ display: "flex",+ flexDirection: "row",+ flex: 1,+ }}+ >+ <div className={styles.stat}>+ <p>Concurrency up to</p>+ <h1>200x</h1>+ </div>+ <div className={styles.stat}>+ <p>Cost per minute</p>+ <h1>+ $0.01<sup>3)</sup>+ </h1>+ </div></div></div>);diff --git a/packages/docs/components/LambdaSplash/VideoApps.tsx b/packages/docs/components/LambdaSplash/VideoApps.tsxnew file mode 100644index 0000000000..5dc306bc3f--- /dev/null+++ b/packages/docs/components/LambdaSplash/VideoApps.tsx@@ -0,0 +1,204 @@+import { useColorMode } from "@docusaurus/theme-common";+import React from "react";+import { BlueButton } from "../layout/Button";+import { Spacer } from "../layout/Spacer";+import videoapps from "./videoapps.module.css";++const panel: React.CSSProperties = {+ backgroundColor: "var(--ifm-background-color)",+ boxShadow: "var(--box-shadow)",+ padding: 10,+ borderRadius: 15,+ flex: 1,+ paddingTop: 30,+ paddingBottom: 10,+ minHeight: 500,+ display: "flex",+ flexDirection: "column",+};++const center: React.CSSProperties = {+ textAlign: "center",+};++const row: React.CSSProperties = {+ display: "flex",+ flexDirection: "row",+};++const flex: React.CSSProperties = {+ flex: 1,+};++const step: React.CSSProperties = {+ flex: 1,+ ...panel,+};++const list: React.CSSProperties = {+ listStyleType: "none",+ textAlign: "center",+ paddingLeft: 0,+ display: "flex",+ flexDirection: "column",+ alignItems: "center",+ fontWeight: 500,+};++const hr: React.CSSProperties = {+ width: 20,+ textAlign: "center",+ borderTop: 0,+ marginTop: 10,+ marginBottom: 10,+};++const stepTitle: React.CSSProperties = {+ textAlign: "center",+ fontSize: "1.6em",+ marginBottom: 0,+ color: "var(--ifm-color-primary)",+};++const docsButton: React.CSSProperties = {+ textDecoration: "none",+};++export const VideoApps: React.FC = () => {+ const { colorMode } = useColorMode();+ return (+ <div className={videoapps.row}>+ <div style={step}>+ <h2 style={stepTitle}>Remotion</h2>+ <strong style={center}>Write videos in React</strong>+ <br />+ <div+ style={{+ display: "flex",+ justifyContent: "center",+ alignItems: "center",+ flex: 1,+ }}+ >+ <img src="/img/writeinreact.png" />+ </div>+ <ul style={list}>+ <li>Use the Web to create graphics</li>+ <hr style={hr} />+ <li>Consume user input and APIs</li>+ <hr style={hr} />+ <li>Render real MP4 videos</li>+ </ul>+ <div style={row}>+ <div style={flex}>+ <a style={docsButton} href="/">+ <BlueButton loading={false} fullWidth size="sm">+ Learn more+ </BlueButton>+ </a>+ </div>+ <Spacer />+ <Spacer />+ <div style={flex}>+ <a style={docsButton} href="/docs">+ <BlueButton loading={false} fullWidth size="sm">+ Read docs+ </BlueButton>+ </a>+ </div>+ </div>+ </div>+ <Spacer />+ <Spacer />+ <Spacer />+ <div style={step}>+ <h2 style={stepTitle}>Remotion Player</h2>+ <strong style={center}>Embeddable interactive videos</strong>+ <br />++ <div+ style={{+ display: "flex",+ justifyContent: "center",+ alignItems: "center",+ flex: 1,+ }}+ >+ <img+ src={+ colorMode === "dark"+ ? "/img/player-example-dark.png"+ : "/img/player-example.png"+ }+ />+ </div>+ <ul style={list}>+ <li>Preview videos in the browser</li>+ <hr style={hr} />+ <li>React to user input</li>+ <hr style={hr} />+ <li>Customize look and behavior</li>+ </ul>+ <div style={row}>+ <div style={flex}>+ <a style={docsButton} href="/player">+ <BlueButton loading={false} fullWidth size="sm">+ Learn more+ </BlueButton>+ </a>+ </div>+ <Spacer />+ <Spacer />+ <div style={flex}>+ <a style={docsButton} href="/docs/player">+ <BlueButton loading={false} fullWidth size="sm">+ Read docs+ </BlueButton>+ </a>+ </div>+ </div>+ </div>+ <Spacer />+ <Spacer />+ <Spacer />+ <div style={step}>+ <h2 style={stepTitle}>Remotion Lambda</h2>+ <strong style={center}>Render at scale</strong>+ <br />+ <div+ style={{+ display: "flex",+ justifyContent: "center",+ alignItems: "center",+ flex: 1,+ }}+ >+ <img+ src={+ colorMode === "dark"+ ? "/img/cluster-dark.png"+ : "/img/cluster.png"+ }+ />+ </div>++ <ul style={list}>+ <li>Render videos in the cloud</li>+ <hr style={hr} />+ <li>Scale according to your volume</li>+ <hr style={hr} />+ <li>Fast because distributed</li>+ </ul>+ <div style={row}>+ <div style={flex}>+ <a style={docsButton} href="/docs/lambda">+ <BlueButton loading={false} fullWidth size="sm">+ Read docs+ </BlueButton>+ </a>+ </div>+ </div>+ </div>+ </div>+ );+};diff --git a/packages/docs/components/LambdaSplash/VideoAppsTitle.tsx b/packages/docs/components/LambdaSplash/VideoAppsTitle.tsxnew file mode 100644index 0000000000..191bf0826d--- /dev/null+++ b/packages/docs/components/LambdaSplash/VideoAppsTitle.tsx@@ -0,0 +1,15 @@+import React from "react";+import styles from "./remotionvideoappstitle.module.css";++export const VideoAppsTitle: React.FC = () => {+ return (+ <div className={styles.container}>+ <h2 className={styles.title}>+ Build video <span className={styles.highlight}>apps</span>+ </h2>+ <p>+ Use our suite of tools to build apps that lets others create videos.+ </p>+ </div>+ );+};diff --git a/packages/docs/components/LambdaSplash/remotionvideoappstitle.module.css b/packages/docs/components/LambdaSplash/remotionvideoappstitle.module.cssnew file mode 100644index 0000000000..93ed9f6389--- /dev/null+++ b/packages/docs/components/LambdaSplash/remotionvideoappstitle.module.css@@ -0,0 +1,16 @@+.container {+ text-align: center+}++.title {+ font-size: 2.5em;+ font-weight: 700;+ font-family: --apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,+ Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;+ line-height: 1.1;+}++.highlight {+ color: var(--ifm-color-primary);+}+diff --git a/packages/docs/components/LambdaSplash/rendertimes.module.css b/packages/docs/components/LambdaSplash/rendertimes.module.cssindex 168d85e4d3..2ca00e8891 100644--- a/packages/docs/components/LambdaSplash/rendertimes.module.css+++ b/packages/docs/components/LambdaSplash/rendertimes.module.css@@ -1,3 +1,15 @@+.row {+ display: flex;+ flex-direction: row;+}++@media screen and (max-width: 900px) {+ .row {+ flex-direction: column+ }+}++.stat {flex: 1;text-align: center;diff --git a/packages/docs/components/LambdaSplash/videoapps.module.css b/packages/docs/components/LambdaSplash/videoapps.module.cssnew file mode 100644index 0000000000..e485b9a742--- /dev/null+++ b/packages/docs/components/LambdaSplash/videoapps.module.css@@ -0,0 +1,11 @@+.row {+ display: flex;+ flex-direction: row;+}+++@media screen and (max-width: 900px) {+ .row {+ flex-direction: column+ }+}diff --git a/packages/docs/components/LandingPage/parametrize.tsx b/packages/docs/components/LandingPage/parametrize.tsxindex 25e0fda70d..c0aaa609ab 100644--- a/packages/docs/components/LandingPage/parametrize.tsx+++ b/packages/docs/components/LandingPage/parametrize.tsx@@ -109,7 +109,8 @@ export const Parametrize: React.FC = () => {Fetch data from an API and use it as the content. <br />Display it in real-time with the{" "}<a href="/player">@remotion/player</a>.<br />- Render videos programmatically using our server-side APIs.+ Render videos programmatically using{" "}+ <a href="/lambda">@remotion/lambda</a>.</p><span style={{ fontSize: 13 }}>Customize the video by entering your GitHub username.diff --git a/packages/docs/src/pages/index.tsx b/packages/docs/src/pages/index.tsxindex fa2d800220..fe84e455a0 100644--- a/packages/docs/src/pages/index.tsx+++ b/packages/docs/src/pages/index.tsx@@ -10,6 +10,8 @@ import { RealMP4Videos } from "../../components/LandingPage/real-mp4-videos";import { SuccessFeatures } from "../../components/LandingPage/SuccessFeatures";import { WriteInReact } from "../../components/LandingPage/WriteInReact";import styles from "./landing.module.css";+import { VideoApps } from "../../components/LambdaSplash/VideoApps";+import { VideoAppsTitle } from "../../components/LambdaSplash/VideoAppsTitle";setTimeout(() => {splitbee.init();@@ -52,6 +54,8 @@ const NewLanding: React.FC = () => {<Parametrize /><br /><br />+ <VideoAppsTitle />+ <VideoApps /><br /><br /><FreePricing />diff --git a/packages/docs/src/pages/player/index.tsx b/packages/docs/src/pages/player/index.tsxindex f064e86936..3e4975d3ef 100644--- a/packages/docs/src/pages/player/index.tsx+++ b/packages/docs/src/pages/player/index.tsx@@ -6,6 +6,8 @@ import { PoweredByRemotion } from "../../../components/Player/PoweredByRemotion"import { PlayerPageFooter } from "../../../components/Player/Footer";import { WrappedBanner } from "../../../components/Player/Wrapped";import Head from "@docusaurus/Head";+import { VideoAppsTitle } from "../../../components/LambdaSplash/VideoAppsTitle";+import { VideoApps } from "../../../components/LambdaSplash/VideoApps";const container: React.CSSProperties = {maxWidth: 1000,@@ -35,6 +37,12 @@ export default () => {<div style={container}><PlayerFeatures /></div>+ <div style={container}>+ <VideoAppsTitle />+ <VideoApps />+ </div>+ <br />+ <br /><WrappedBanner /><PlayerPageFooter /></Layout>