From c2e9f31a8dcc88abe39f3f5e89d69fb863c822d8 Mon Sep 17 00:00:00 2001 From: mdellanoce Date: Tue, 26 Sep 2023 13:56:35 +0000 Subject: [PATCH] Apply formatting changes --- packages/rrweb/src/record/iframe-manager.ts | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/packages/rrweb/src/record/iframe-manager.ts b/packages/rrweb/src/record/iframe-manager.ts index 06a11146c1..8796102f2c 100644 --- a/packages/rrweb/src/record/iframe-manager.ts +++ b/packages/rrweb/src/record/iframe-manager.ts @@ -52,11 +52,14 @@ export class IframeManager { this.crossOriginIframeMap.set(iframeEl.contentWindow, iframeEl); if (!iframeEl.contentDocument && iframeEl.contentWindow) - iframeEl.contentWindow.postMessage({ - type: "rrweb", - origin: window.location.origin, - snapshot: true - }, "*"); + iframeEl.contentWindow.postMessage( + { + type: 'rrweb', + origin: window.location.origin, + snapshot: true, + }, + '*', + ); } public addLoadListener(cb: (iframeEl: HTMLIFrameElement) => unknown) { @@ -104,7 +107,11 @@ export class IframeManager { const iframeSourceWindow = message.source; if (!iframeSourceWindow) return; - if (iframeSourceWindow == window.parent && window != window.parent && message.data.snapshot) { + if ( + iframeSourceWindow == window.parent && + window != window.parent && + message.data.snapshot + ) { this.takeFullSnapshot(); return; }