---
/**
 * Link preview (Open Graph) embed component for Portable Text
 *
 * Wraps astro-embed's LinkPreview component, extracting props from the PT block node.
 * astro-portabletext passes `node` (not `value`) for custom type components.
 */
import { LinkPreview as AstroLinkPreview } from "astro-embed";
import type { LinkPreviewBlock } from "../schemas.js";

interface Props {
	node: LinkPreviewBlock;
}

const { node } = Astro.props;
const { id, hideMedia } = node;
---

<AstroLinkPreview id={id} hideMedia={hideMedia} />
