Skip to content

🎥 Make videos programmatically with React

finish editor starter docs

JonnyBurger818e38974560
diff --git a/packages/docs/docs/editor-starter/TableOfContents.tsx b/packages/docs/docs/editor-starter/TableOfContents.tsx
index 0b343ba441..b105ed6f0c 100644
--- a/packages/docs/docs/editor-starter/TableOfContents.tsx
+++ b/packages/docs/docs/editor-starter/TableOfContents.tsx
@@ -38,6 +38,10 @@ export const TableOfContents: React.FC = () => {
<strong>Undo and Redo</strong>
<div>Undo and Redo functionality in the Editor Starter</div>
</TOCItem>
+ <TOCItem link="/docs/editor-starter/copy-paste">
+ <strong>Copy and Paste</strong>
+ <div>How it is implemented in the Editor Starter</div>
+ </TOCItem>
<TOCItem link="/docs/editor-starter/fonts">
<strong>Fonts</strong>
<div>How fonts work and which ones are included</div>
diff --git a/packages/docs/docs/editor-starter/copy-paste.mdx b/packages/docs/docs/editor-starter/copy-paste.mdx
new file mode 100644
index 0000000000..51de838d95
--- /dev/null
+++ b/packages/docs/docs/editor-starter/copy-paste.mdx
@@ -0,0 +1,39 @@
+---
+image: /generated/articles-docs-editor-starter-copy-paste.png
+title: Copy and Paste in the Editor Starter
+sidebar_label: Copy and Paste
+id: copy-paste
+crumb: Editor Starter
+---
+
+The Remotion Editor Starter implements copy and pasting from layers
+
+## Considerations
+
+When reading the browser's [Clipboard API](https://developer.mozilla.org/en-US/docs/Web/API/Clipboard_API), only the following MIME types are supported:
+
+- `text/plain`
+- `text/html`
+- `image/png`
+
+None of these are the ideal MIME types for copying items.
+
+We are therefore using a workaround that is used by [Figma](https://figma.com/) and [tldraw](https://tldraw.com/): The items are serialized, put into a `<div>` and then copied to the clipboard with the MIME type `text/html`. This prevents overwriting the `text/plain` slot.
+
+## Ways of copy-pasting
+
+Copy and pasting works by right-clicking on an item, or using the standard keyboard shortcuts <kbd>Cmd</kbd>/<kbd>Ctrl</kbd>+<kbd>X</kbd>, <kbd>Cmd</kbd>/<kbd>Ctrl</kbd>+<kbd>C</kbd> and <kbd>Cmd</kbd>/<kbd>Ctrl</kbd>+<kbd>V</kbd>.
+
+## Pasting
+
+When pasting contents, the Editor Starter first checks if the clipboard data has the MIME type `text/html` and deserializes the contents of the `<div>` into items.
+
+Items are being copied and assigned a new unique ID before being added to the top of the timeline.
+
+## Customizing
+
+The logic for copy-paste can be found under [`src/editor/clipboard`](https://github.com/remotion-dev/editor-starter/tree/main/src/editor/clipboard).
+
+## See also
+
+- [Features](/docs/editor-starter/features)
diff --git a/packages/docs/docs/editor-starter/production-checklist.mdx b/packages/docs/docs/editor-starter/production-checklist.mdx
new file mode 100644
index 0000000000..7346abcb96
--- /dev/null
+++ b/packages/docs/docs/editor-starter/production-checklist.mdx
@@ -0,0 +1,41 @@
+---
+image: /generated/articles-docs-editor-starter-production-checklist.png
+title: Production Checklist
+sidebar_label: Production Checklist
+id: production-checklist
+crumb: Editor Starter
+---
+
+Ready to launch? Congrats!
+Before shipping your project to production, here are some things you should check.
+
+## Protected endpoints
+
+The [backend routes](/docs/editor-starter/backend-routes) for assets, captions and rendering are not protected by any authentication or rate limit in our template.
+Did you implement the necessary protections to prevent abuse?
+
+## Asset cleanup
+
+By default, deleted assets are not automatically cleaned up.
+Have you implemented [asset cleanup](/docs/editor-starter/asset-cleanup)?
+
+## Lambda checklist
+
+There is a separate [Lambda checklist](/docs/editor-starter/lambda-checklist) for the Remotion Lambda integration.
+
+## Features not included
+
+Did you check the [features not included](/docs/editor-starter/features-not-included) to see if you are missing any important features you need?
+
+## Unintentional features
+
+Did you check the [features](/docs/editor-starter/features) to see if there are any features you are shipping you didn't know about? Disable them if you don't need them.
+
+## Company License
+
+If you are a company that is not eligible for the Free License, did you purchase a [Remotion Company License](/docs/license)?
+
+---
+
+Congrats if you are shipping your project to production!
+Post your product in the `#showcase` channel on [Discord](https://remotion.dev/discord).
diff --git a/packages/docs/sidebars.ts b/packages/docs/sidebars.ts
index 675d9bf03d..aa1cb0f641 100644
--- a/packages/docs/sidebars.ts
+++ b/packages/docs/sidebars.ts
@@ -1375,6 +1375,7 @@ const sidebars: SidebarsConfig = {
'editor-starter/state-management',
'editor-starter/tracks-items-assets',
'editor-starter/undo-redo',
+ 'editor-starter/copy-paste',
'editor-starter/fonts',
'editor-starter/asset-uploads',
'editor-starter/asset-cleanup',
@@ -1382,6 +1383,7 @@ const sidebars: SidebarsConfig = {
'editor-starter/captioning',
'editor-starter/rendering',
'editor-starter/backend-routes',
+ 'editor-starter/production-checklist',
'editor-starter/features-not-included',
'editor-starter/faq',
],
diff --git a/packages/docs/src/data/articles.ts b/packages/docs/src/data/articles.ts
index f40ff80bd0..ebc1522ef1 100644
--- a/packages/docs/src/data/articles.ts
+++ b/packages/docs/src/data/articles.ts
@@ -1297,7 +1297,7 @@ export const articles = [
},
{
id: 'backend-routes',
- title: 'Backend routes',
+ title: 'Backend routes in the Editor Starter',
relativePath: 'docs/editor-starter/backend-routes.mdx',
compId: 'articles-docs-editor-starter-backend-routes',
crumb: 'Editor Starter',
@@ -1331,6 +1331,15 @@ export const articles = [
noAi: false,
slug: 'editor-starter/captioning',
},
+ {
+ id: 'copy-paste',
+ title: 'Copy and Paste in the Editor Starter',
+ relativePath: 'docs/editor-starter/copy-paste.mdx',
+ compId: 'articles-docs-editor-starter-copy-paste',
+ crumb: 'Editor Starter',
+ noAi: false,
+ slug: 'editor-starter/copy-paste',
+ },
{
id: 'editor-starter/dependencies',
title: 'Dependencies of the Editor Starter',
@@ -1360,7 +1369,7 @@ export const articles = [
},
{
id: 'features',
- title: 'Features',
+ title: 'Features in the Editor Starter',
relativePath: 'docs/editor-starter/features.mdx',
compId: 'articles-docs-editor-starter-features',
crumb: 'Editor Starter',
@@ -1394,9 +1403,18 @@ export const articles = [
noAi: false,
slug: 'editor-starter/persistance',
},
+ {
+ id: 'production-checklist',
+ title: 'Production Checklist',
+ relativePath: 'docs/editor-starter/production-checklist.mdx',
+ compId: 'articles-docs-editor-starter-production-checklist',
+ crumb: 'Editor Starter',
+ noAi: false,
+ slug: 'editor-starter/production-checklist',
+ },
{
id: 'rendering',
- title: 'Rendering',
+ title: 'Rendering in the Editor Starter',
relativePath: 'docs/editor-starter/rendering.mdx',
compId: 'articles-docs-editor-starter-rendering',
crumb: 'Editor Starter',
diff --git a/packages/docs/static/generated/articles-docs-editor-starter-copy-paste.png b/packages/docs/static/generated/articles-docs-editor-starter-copy-paste.png
new file mode 100644
index 0000000000..2a1d3b62d6
Binary files /dev/null and b/packages/docs/static/generated/articles-docs-editor-starter-copy-paste.png differ
diff --git a/packages/docs/static/generated/articles-docs-editor-starter-production-checklist.png b/packages/docs/static/generated/articles-docs-editor-starter-production-checklist.png
new file mode 100644
index 0000000000..49d1120f9a
Binary files /dev/null and b/packages/docs/static/generated/articles-docs-editor-starter-production-checklist.png differ