🎥 Make videos programmatically with React
awesome
Jonny Burger8c18a85c4f23
diff --git a/packages/promo-pages/src/components/homepage/CommunityStats.module.css b/packages/promo-pages/src/components/homepage/CommunityStats.module.cssdeleted file mode 100644index 82858a9c9d..0000000000--- a/packages/promo-pages/src/components/homepage/CommunityStats.module.css+++ /dev/null@@ -1,61 +0,0 @@-.container {- max-width: 700px;- margin: 0 auto;- text-align: center;- justify-content: center;-}--.title {- font-size: 2.5rem;- font-weight: bold;- margin-bottom: 0.5rem;-}--.subtitle {- font-size: 1.25rem;- margin-bottom: 1.5rem;-}--.statsGrid {- display: flex;- flex-wrap: wrap;- justify-content: space-between;- gap: 1rem;- width: 100%;- align-items: center;-}--.statItemLink {- text-decoration: none;- color: inherit;- display: contents; /* "display: contents" causes an element's children to appear as if they were direct children of the element's parent, ignoring the element itself. This can be useful when a wrapper element should be ignored when using CSS grid or similar layout techniques. */-}--.statItemLink:hover,-.statItemLink:focus,-.statItemLink:active {- text-decoration: none;- color: inherit;-}--.statItem {- background-color: var(--ifm-background-surface-color);- border-radius: 0.5rem;- border: 2px solid var(--box-stroke);- border-bottom: 4px solid var(--box-stroke);- padding: 0.3rem;- line-height: 1;- display: flex;- flex-wrap: wrap;- justify-content: center;- align-items: center;- align-content: center;- flex: 1 1 30%;- min-width: 200px;- min-height: 80px;- max-height: 110px;- flex: 1 1 30%; /* Makes the items grow/shrink consistently */- transition:- transform 0.2s,- box-shadow 0.2s;-}diff --git a/packages/promo-pages/src/components/homepage/CommunityStats.tsx b/packages/promo-pages/src/components/homepage/CommunityStats.tsxindex 3cc61e163a..15d486bfd0 100644--- a/packages/promo-pages/src/components/homepage/CommunityStats.tsx+++ b/packages/promo-pages/src/components/homepage/CommunityStats.tsx@@ -1,5 +1,4 @@import React from 'react';-import styles from './CommunityStats.module.css';import {Contributors,DiscordMembers,@@ -14,18 +13,22 @@ const SectionLink: React.FC<{readonly href: string;readonly children: React.ReactNode;}> = ({href, children}) => (- <a target="_blank" href={href} className={styles.statItemLink}>+ <a+ target="_blank"+ href={href}+ className={'no-underline text-inherit contents'}+ >{children}</a>);const CommunityStats: React.FC = () => (- <div className={styles.container}>+ <div className={'m-auto max-w-[700px] text-center'}><SectionTitle>Never build alone</SectionTitle><div className={'font-brand text-center mb-10'}>Join a thriving community of developers.</div>- <div className={styles.statsGrid}>+ <div className={'flex flex-wrap justify-between gap-4 w-full items-center'}><SectionLink href="https://www.npmjs.com/package/remotion"><InstallsPerMonth /></SectionLink>diff --git a/packages/promo-pages/src/components/homepage/CommunityStatsItems.tsx b/packages/promo-pages/src/components/homepage/CommunityStatsItems.tsxindex 5161d6b846..10be8c904c 100644--- a/packages/promo-pages/src/components/homepage/CommunityStatsItems.tsx+++ b/packages/promo-pages/src/components/homepage/CommunityStatsItems.tsx@@ -1,5 +1,5 @@import React from 'react';-import styles from './CommunityStats.module.css';+import {cn} from '../../cn';// StatItemContent componentconst StatItemContent: React.FC<{@@ -39,12 +39,25 @@ const StatItemContent: React.FC<{</div>);-export const InstallsPerMonth: React.FC = () => {+const Pill: React.FC<{+ readonly children: React.ReactNode;+ readonly className?: string;+}> = ({children, className}) => {return (<div- className={styles.statItem}- style={{width: '30%', flexDirection: 'column'}}+ className={cn(+ className,+ 'card leading-none flex flex-wrap justify-center items-center min-w-[200px] min-h-[80px] max-h-[110px] flex-1 p-0',+ )}>+ {children}+ </div>+ );+};++export const InstallsPerMonth: React.FC = () => {+ return (+ <Pill className={'w-[30%] flex-col'}><divstyle={{display: 'flex',@@ -82,16 +95,13 @@ export const InstallsPerMonth: React.FC = () => {fontSize="1.0rem"fontWeight="bold"/>- </div>+ </Pill>);};export const PagesOfDocs: React.FC = () => {return (- <div- className={styles.statItem}- style={{width: '30%', flexDirection: 'column'}}- >+ <Pill className="flex-col"><div style={{display: 'flex', alignItems: 'center'}}><StatItemContentcontent={@@ -124,19 +134,12 @@ export const PagesOfDocs: React.FC = () => {fontSize="1.0rem"fontWeight="bold"/>- </div>+ </Pill>);};export const TemplatesAndExamples: React.FC = () => (- <div- className={styles.statItem}- style={{- width: '30%',- display: 'flex',- alignItems: 'center',- }}- >+ <Pill className="w-[30%] flex items-center"><StatItemContentcontent="35"width="60px"@@ -149,15 +152,12 @@ export const TemplatesAndExamples: React.FC = () => (fontSize="1.35rem"fontWeight="bold"/>- </div>+ </Pill>);export const GitHubStars: React.FC = () => {return (- <div- className={styles.statItem}- style={{width: '30%', flexDirection: 'column'}}- >+ <Pill className="w-[30%] flex-col"><div style={{display: 'flex', alignItems: 'center'}}><StatItemContentcontent={@@ -189,13 +189,13 @@ export const GitHubStars: React.FC = () => {fontSize="1.0rem"fontWeight="bold"/>- </div>+ </Pill>);};export const DiscordMembers: React.FC = () => {return (- <div className={styles.statItem} style={{width: '30%'}}>+ <Pill className={'w-[30%]'}><divstyle={{width: '80%',@@ -250,21 +250,13 @@ export const DiscordMembers: React.FC = () => {/></div></div>- </div>+ </Pill>);};export const Contributors: React.FC = () => {return (- <div- className={styles.statItem}- style={{- width: '30%',- display: 'flex',- alignItems: 'center',- justifyContent: 'center',- }}- >+ <Pill className="w-[30%]"><div style={{display: 'flex', justifyContent: 'center'}}><div style={{display: 'flex', justifyContent: 'center'}}><StatItemContent@@ -307,6 +299,6 @@ export const Contributors: React.FC = () => {/></div></div>- </div>+ </Pill>);};diff --git a/packages/promo-pages/src/components/homepage/Demo/done.module.css b/packages/promo-pages/src/components/homepage/Demo/done.module.cssdeleted file mode 100644index 2798fdf09c..0000000000--- a/packages/promo-pages/src/components/homepage/Demo/done.module.css+++ /dev/null@@ -1,3 +0,0 @@-.jump {- animation: jump 0.2s ease-out;-}diff --git a/packages/promo-pages/src/components/homepage/EvaluateRemotionSection.module.css b/packages/promo-pages/src/components/homepage/EvaluateRemotionSection.module.cssdeleted file mode 100644index 53aec83739..0000000000--- a/packages/promo-pages/src/components/homepage/EvaluateRemotionSection.module.css+++ /dev/null@@ -1,113 +0,0 @@-/* components/LandingPage/EvaluateRemotionSection.module.css */-.container {- display: flex;- justify-content: center;- gap: 20px;- margin: 40px 0;-}--.card {- display: flex;- flex-direction: column;- justify-content: space-between; /* This will push the content to the top and the buttons/avatars to the bottom */- background-color: var(--ifm-background-surface-color);- border: 2px solid var(--box-stroke);- border-bottom: 4px solid var(--box-stroke);- border-radius: 10px;- padding: 20px;- width: 100%;- box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);- max-width: calc(50% - 10px);- position: relative;-}--.contentWrapper {- flex-grow: 1;- display: flex;- flex-direction: column;- justify-content: top; /* Adjust this as needed */-}--.title {- font-size: 1.4em;- font-weight: bold;- margin-bottom: 10px;-}--.description {- margin-bottom: 30px;-}--.scheduleButton {- background-color: var(--ifm-color-primary);- color: white;- border: none;- padding: 8px 16px;- border-radius: 4px;- cursor: pointer;- display: flex;- align-items: center;- font-size: 0.9em;-}--.calendarIcon {- margin-right: 5px;-}--.expertsSection {- display: flex;- justify-content: space-between;- align-items: flex-end; /* Align items to the bottom with a little padding */- width: 100%;-}--.remotionIcon {- font-size: 1.2em;- margin-right: 5px;-}--.expertsInfo {- display: flex;- align-items: center; /* Center items vertically */- justify-content: flex-start; /* Align items to the left */- flex: 1; /* Take up the full width available */-}--.expertsText {- font-weight: bold;- margin-right: 10px;-}--.avatar {- width: 50px; /* Example width */- height: 50px; /* Example height */- border-radius: 50%; /* Circular avatars */- background-color: #ccc; /* Placeholder background color, replace with actual image */- background-size: cover; /* Ensure the image covers the avatar area */- background-position: center; /* Center the image within the avatar */- margin-left: -20px; /* Negative margin to create overlap. Adjust as needed */- border: 1px solid #000; /* Fine solid line around the avatars */-}--.avatars {- display: flex;- justify-content: flex-end; /* Align avatars to the right */- align-items: flex-end; /* Align avatars to the bottom */- gap: 10px; /* Space between avatars */-}--@media screen and (max-width: 900px) {- .container {- flex-direction: column;- align-items: center;- }- .card {- max-width: none; /* Allow cards to use the adjusted width on smaller screens */- }-}--@media screen and (max-width: 440px) {- .avatars {- display: none; /* Hide avatars when the screen width is 450px or less */- }-}diff --git a/packages/promo-pages/src/components/homepage/writeinreact.module.css b/packages/promo-pages/src/components/homepage/writeinreact.module.cssdeleted file mode 100644index c12a1a4397..0000000000--- a/packages/promo-pages/src/components/homepage/writeinreact.module.css+++ /dev/null@@ -1,9 +0,0 @@-.text {- text-shadow: 0 5px 30px var(--background);-}--@media screen and (max-width: 900px) {- .writeincss {- flex-direction: column;- }-}