Skip to content

Commit

Permalink
Fix missing iframeStyle
Browse files Browse the repository at this point in the history
  • Loading branch information
Olivia Thet committed Oct 24, 2023
1 parent 786379f commit 8f10bc9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/email-recovery/src/components/Recovery.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export function Recovery(props: RecoveryProps) {
iframeUrl: props.iframeUrl,
iframeContainerId: TurnkeyIframeContainerId,
iframeElementId: TurnkeyIframeElementId,
iframeStyle: "",
});
iframeStamper.init().then(() => {
setIframeStamper(iframeStamper);
Expand Down
1 change: 1 addition & 0 deletions packages/iframe-stamper/src/__tests__/iframe-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ test("throws when instantiated outside of a browser environment", async function
iframeUrl: "https://recovery.tkhqlabs.xyz",
iframeContainerId: "my-container-id",
iframeElementId: "my-iframe-id",
iframeStyle: "",
});
}).toThrow("Cannot initialize iframe in non-browser environment");
});
2 changes: 1 addition & 1 deletion packages/iframe-stamper/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export class IframeStamper {
let iframe = window.document.createElement("iframe");
iframe.id = config.iframeElementId;
iframe.src = config.iframeUrl;
if (config.iframeStyle != null) {
if (config.iframeStyle != "") {
iframe.setAttribute("style", config.iframeStyle);
}

Expand Down

0 comments on commit 8f10bc9

Please sign in to comment.