From 2165d24099258652c488ba012cfd757136b8555a Mon Sep 17 00:00:00 2001 From: madrilene Date: Thu, 13 Mar 2025 16:30:01 +0100 Subject: [PATCH] update video docs --- src/docs/video.md | 46 +++++++++++++++++++++++++++++++++++++++++++++ src/docs/youtube.md | 13 ------------- 2 files changed, 46 insertions(+), 13 deletions(-) create mode 100644 src/docs/video.md delete mode 100644 src/docs/youtube.md diff --git a/src/docs/video.md b/src/docs/video.md new file mode 100644 index 0000000..806e0df --- /dev/null +++ b/src/docs/video.md @@ -0,0 +1,46 @@ +--- +title: Video +--- + +### YouTube + +`` is a wrapper around [Lite YouTube Embed](https://github.com/paulirish/lite-youtube-embed), optimizing video playback for performance. + +`@slug` video ID +`@start` (optional) start time in seconds +`@label` Used for accessibility and the `` fallback +`@poster` (optional) custom poster image URL (with https://v1.opengraph.11ty.dev/) +`@posterSize` (optional, default: 'auto') size passed in to custom poster +`@jsapi` (optional, default: 'undefined') Enables [JavaScript API support](https://github.com/paulirish/lite-youtube-embed?tab=readme-ov-file#access-the-youtube-iframe-player-api). + +``` + + +``` + +
+ +### PeerTube + +`` is a wrapper around [PeerTube](https://joinpeertube.org/)’s embed system. + +`@instance` PeerTube domain hosting the video +`@embed-slug` – The unique ID used in the embed URL. +`@start` (optional) start time +`@slug` unique video identifier for direct links in the `` fallback +`@label` Used for accessibility and the `` fallback. + +``` + + +``` + +
+ +
\ No newline at end of file diff --git a/src/docs/youtube.md b/src/docs/youtube.md deleted file mode 100644 index 4251150..0000000 --- a/src/docs/youtube.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -title: Youtube ---- - -The `@slug` attribute is used to pass the video ID to the `` element. -`@label` ist used for the nested `` which adds a link to watch on YouTube. This also serves as a fallback in case JS is deactivated. -Uses the [Lite YouTube Embed repository](https://github.com/paulirish/lite-youtube-embed). - -``` - -``` - -