Skip to content

🎥 Make videos programmatically with React

design changes

Jonny Burger01dc59a14775
diff --git a/packages/docs/docusaurus.config.js b/packages/docs/docusaurus.config.js
index 136d2e0080..9faea1df9b 100644
--- a/packages/docs/docusaurus.config.js
+++ b/packages/docs/docusaurus.config.js
@@ -168,10 +168,13 @@ module.exports = {
label: "For companies",
href: "https://companies.remotion.dev",
},
+ {
+ label: "Brand",
+ href: "https://github.com/remotion-dev/logo",
+ },
],
},
],
- copyright: `Copyright © ${new Date().getFullYear()} Remotion AG. Built with Docusaurus.`,
},
colorMode: {
respectPrefersColorScheme: true,
diff --git a/packages/docs/src/theme/Footer/Layout/index.tsx b/packages/docs/src/theme/Footer/Layout/index.tsx
new file mode 100644
index 0000000000..ccd5fbf61c
--- /dev/null
+++ b/packages/docs/src/theme/Footer/Layout/index.tsx
@@ -0,0 +1,20 @@
+import { useColorMode } from "@docusaurus/theme-common";
+import clsx from "clsx";
+import React from "react";
+
+export default ({ style, links }) => {
+ const { isDarkTheme } = useColorMode();
+ return (
+ <footer
+ className={clsx("footer", {
+ "footer--dark": style === "dark",
+ })}
+ style={{
+ backgroundColor: isDarkTheme ? "#1f1f1f" : "#fcfcfc",
+ borderTop: isDarkTheme ? "1px solid #2f2f2f" : "1px solid #eaeaea",
+ }}
+ >
+ <div className="container container-fluid">{links}</div>
+ </footer>
+ );
+};
diff --git a/packages/docs/src/theme/Footer/Links/MultiColumn/index.tsx b/packages/docs/src/theme/Footer/Links/MultiColumn/index.tsx
new file mode 100644
index 0000000000..460fe5c11c
--- /dev/null
+++ b/packages/docs/src/theme/Footer/Links/MultiColumn/index.tsx
@@ -0,0 +1,74 @@
+import { useColorMode } from "@docusaurus/theme-common";
+import LinkItem from "@theme/Footer/LinkItem";
+import React from "react";
+
+const footerTitle: React.CSSProperties = {
+ fontFamily: "GT Planar",
+};
+
+const ColumnLinkItem = ({ item }) => {
+ return item.html ? (
+ <li
+ // Developer provided the HTML, so assume it's safe.
+ // eslint-disable-next-line react/no-danger
+ dangerouslySetInnerHTML={{ __html: item.html }}
+ className="footer__item"
+ />
+ ) : (
+ <li key={item.href ?? item.to} className="footer__item">
+ <LinkItem item={item} />
+ </li>
+ );
+};
+
+const Column = ({ column }) => {
+ return (
+ <div className="col footer__col">
+ <div style={footerTitle} className="footer__title">
+ {column.title}
+ </div>
+ <ul className="footer__items clean-list">
+ {column.items.map((item, i) => (
+ <ColumnLinkItem key={i} item={item} />
+ ))}
+ </ul>
+ </div>
+ );
+};
+
+const copyright: React.CSSProperties = {
+ textAlign: "left",
+ color: "var(--ifm-footer-link-color)",
+ fontSize: "0.8em",
+ marginTop: 15,
+ marginRight: 38,
+};
+
+export default ({ columns }) => {
+ const { isDarkTheme } = useColorMode();
+ return (
+ <div className="row footer__links">
+ <div
+ style={{
+ padding: "0 var(--ifm-spacing-horizontal)",
+ marginBottom: 20,
+ }}
+ >
+ <img
+ src={isDarkTheme ? "/img/remotion-white.png" : "/img/new-logo.png"}
+ style={{
+ height: 32,
+ marginRight: 80,
+ }}
+ />
+ <p style={copyright}>
+ © Copyright {new Date().getFullYear()} Remotion AG. <br /> Website
+ created with Docusaurus.
+ </p>
+ </div>
+ {columns.map((column, i) => (
+ <Column key={i} column={column} />
+ ))}
+ </div>
+ );
+};
diff --git a/packages/docs/src/theme/Footer/Links/index.tsx b/packages/docs/src/theme/Footer/Links/index.tsx
new file mode 100644
index 0000000000..ea737dff18
--- /dev/null
+++ b/packages/docs/src/theme/Footer/Links/index.tsx
@@ -0,0 +1,6 @@
+import React from "react";
+import FooterLinksMultiColumn from "./MultiColumn";
+
+export default ({ links, style }) => {
+ return <FooterLinksMultiColumn style={style} columns={links} />;
+};
diff --git a/packages/docs/src/theme/Footer/index.tsx b/packages/docs/src/theme/Footer/index.tsx
new file mode 100644
index 0000000000..2d65b3e344
--- /dev/null
+++ b/packages/docs/src/theme/Footer/index.tsx
@@ -0,0 +1,23 @@
+import { useThemeConfig } from "@docusaurus/theme-common";
+import React from "react";
+import FooterLayout from "./Layout";
+import FooterLinks from "./Links";
+
+const Footer = () => {
+ const { footer } = useThemeConfig();
+ if (!footer) {
+ return null;
+ }
+
+ const { links, style } = footer;
+ return (
+ <FooterLayout
+ style={style}
+ links={
+ links && links.length > 0 && <FooterLinks style={style} links={links} />
+ }
+ />
+ );
+};
+
+export default React.memo(Footer);