DraggableEmbed

API reference for the DraggableEmbed component.
import React from "react";
import { DraggableEmbed } from "components/draggable_embed";
export function App() {
return (
<DraggableEmbed
embedUrl="https://www.youtube.com/embed/L3MtFGWRXAA"
previewUrl="https://www.canva.dev/example-assets/images/puppyhood.jpg"
previewSize={{ width: 320, height: 180 }}
title="Heartwarming Chatter: Adorable Conversation with a Puppy"
subtitle="Puppyhood"
/>
);
}
tsx
#embedUrlstring
Required

The URL of the embeddable media.

This URL must be supported by Iframely. To learn more, see What URLs to send to Iframely.

#previewUrlstring
Required

The URL of a thumbnail image.

#previewSizestring
Required

The dimensions of the preview image, in pixels.

#titlestring
Required

A human-readable title for the embed.

#subtitlestring
Optional

A human-readable subtitle for the embed.