From 3e0a35e080b1c744907d0735bb50f411157b5f4c Mon Sep 17 00:00:00 2001 From: Harvey Zack Date: Thu, 12 Jan 2023 09:48:40 +0800 Subject: [PATCH] update docs --- packages/artplayer-vitepress/docs/plugin/iframe.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/artplayer-vitepress/docs/plugin/iframe.md b/packages/artplayer-vitepress/docs/plugin/iframe.md index f7aa1603d..7d0e0606a 100644 --- a/packages/artplayer-vitepress/docs/plugin/iframe.md +++ b/packages/artplayer-vitepress/docs/plugin/iframe.md @@ -112,7 +112,7 @@ https://unpkg.com/artplayer-plugin-iframe/dist/artplayer-plugin-iframe.js ### `commit` -将消息推送到 iframe,该函数将在 iframe 内部运行 +从 `index.html` 将消息推送到 `iframe.html`,该函数将在 `iframe.html` 内部运行 ```js iframe.commit(() => { @@ -126,7 +126,7 @@ iframe.commit(() => { art.seek = 5; }); -// Get the value from the iframe +// Get the value from the iframe.html (async function () { // Use the return keyword var currentTime = await iframe.commit(() => { @@ -144,7 +144,7 @@ iframe.commit(() => { ### `message` -接收来自 iframe 的消息 +在 `index.html` 接收来自 `iframe.html` 的消息 ```js iframe.message((event) => { @@ -154,7 +154,7 @@ iframe.message((event) => { ### `destroy` -销毁实例,销毁后无法与 iframe 通信 +销毁实例,销毁后 `index.html` 无法与 `iframe.html` 通信 ```js iframe.destroy(); @@ -164,7 +164,7 @@ iframe.destroy(); :::warning 提示 -`Iframe` 接口 只能运行在 `iframe` 里 +`Iframe` 接口 只能运行在 `iframe.html` 里 :::