From f6c09db69fefa10a3f2dbec164a4c6a4a48b46d4 Mon Sep 17 00:00:00 2001 From: Stefanie Kaltenhauser Date: Mon, 11 Nov 2024 10:57:15 +0100 Subject: [PATCH 1/3] Disable showing related videos from other channels in YouTubeVideoBlock --- packages/site/cms-site/src/blocks/YouTubeVideoBlock.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/site/cms-site/src/blocks/YouTubeVideoBlock.tsx b/packages/site/cms-site/src/blocks/YouTubeVideoBlock.tsx index b4d17f98ad..a6e552cc5a 100644 --- a/packages/site/cms-site/src/blocks/YouTubeVideoBlock.tsx +++ b/packages/site/cms-site/src/blocks/YouTubeVideoBlock.tsx @@ -48,6 +48,7 @@ export const YouTubeVideoBlock = withPreview( const identifier = parseYoutubeIdentifier(youtubeIdentifier); const searchParams = new URLSearchParams(); searchParams.append("modestbranding", "1"); + searchParams.append("rel", "0"); if (autoplay !== undefined || (hasPreviewImage && !showPreviewImage)) searchParams.append("autoplay", Number(autoplay || (hasPreviewImage && !showPreviewImage)).toString()); From 6fe2ce4290aca02b533d6c59105932e25d68147f Mon Sep 17 00:00:00 2001 From: Stefanie Kaltenhauser Date: Mon, 11 Nov 2024 12:16:25 +0100 Subject: [PATCH 2/3] Add changeset --- .changeset/fast-carrots-divide.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 .changeset/fast-carrots-divide.md diff --git a/.changeset/fast-carrots-divide.md b/.changeset/fast-carrots-divide.md new file mode 100644 index 0000000000..dae3aa33d6 --- /dev/null +++ b/.changeset/fast-carrots-divide.md @@ -0,0 +1,7 @@ +--- +"@comet/cms-site": minor +--- + +Add rel=0 to youtube search parameters + +By setting the parameter rel to 0 in the `YouTubeVideoBlock` only related videos from the same channel as the embedded video are shown. From 298d1c5a73fe37de6a7dc53a3a1bbd3e049dcc5b Mon Sep 17 00:00:00 2001 From: Stefanie Kaltenhauser Date: Tue, 12 Nov 2024 11:27:01 +0100 Subject: [PATCH 3/3] Update changeset --- .changeset/fast-carrots-divide.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.changeset/fast-carrots-divide.md b/.changeset/fast-carrots-divide.md index dae3aa33d6..49e387d74f 100644 --- a/.changeset/fast-carrots-divide.md +++ b/.changeset/fast-carrots-divide.md @@ -2,6 +2,6 @@ "@comet/cms-site": minor --- -Add rel=0 to youtube search parameters +Disable showing related videos from other channels in `YouTubeVideoBlock` -By setting the parameter rel to 0 in the `YouTubeVideoBlock` only related videos from the same channel as the embedded video are shown. +By setting the parameter `rel` to `0` only related videos from the same channel as the embedded video are shown.