{
+ setOpenVideo(true);
+ triggerTrackingEvent('hero_section_video_open_diagram', 0.4);
+ }}
+ />
diff --git a/docs-src/src/components/replication-diagram.tsx b/docs-src/src/components/replication-diagram.tsx
index 1700b212ec9..f6218fe5b1f 100644
--- a/docs-src/src/components/replication-diagram.tsx
+++ b/docs-src/src/components/replication-diagram.tsx
@@ -19,11 +19,13 @@ export function ReplicationDiagram({
dark,
hasIcon = true,
demoOffline = false,
+ onPlayClick,
}: {
scale?: number;
dark: boolean;
hasIcon?: boolean;
demoOffline?: boolean;
+ onPlayClick?: () => void;
}) {
const containerRef = useRef(null);
@@ -232,6 +234,33 @@ export function ReplicationDiagram({
+ {/* YouTube play button (center overlay) */}
+ {onPlayClick && (
+ {
+ e.currentTarget.style.transform = 'translate(-50%, -50%) scale(1.08)';
+ }}
+ onMouseLeave={(e) => {
+ e.currentTarget.style.transform = 'translate(-50%, -50%) scale(1)';
+ }}
+ >
+
+
+ )}
+
{/* Lines & devices */}
{linesData.map(({ angleDeg, lineLength, deviceX, deviceY, inwardName, outwardName }, i) => {
const lineStart = serverRadius + serverMargin;
@@ -369,3 +398,23 @@ const styles = {
overflow: 'visible', // let diagram content grow
} as React.CSSProperties,
};
+
+function YouTubePlayButtonSvg({ width = 68 }: { width?: number; }) {
+ const height = (width * 48) / 68;
+ return (
+
+ );
+}