---
title: "嵌入"
subtitle: "<Embed>（别名 <IFrame>）响应式 iframe，嵌入在线演示、设计稿或 PDF。"
---

响应式 iframe，适合嵌入在线演示、设计稿或 PDF（别名 `<IFrame>`），默认 16:9：

```mdx
<Embed src="https://example.com/demo" title="在线演示" ratio="4/3" />
<Embed src="/assets/whitepaper.pdf" title="白皮书" height="640px" />
```

<ParamField path="src" type="url" required>页面、视频或 PDF 地址（也接受 `url`）。</ParamField>
<ParamField path="title" type="string">无障碍标题。</ParamField>
<ParamField path="ratio" type="string">宽高比，例如 `16/9`、`4:3`（也接受 `aspectRatio`）。</ParamField>
<ParamField path="height" type="string">固定高度，代替宽高比。</ParamField>
<ParamField path="allow" type="string">iframe 的 `allow` 权限列表。</ParamField>
