embed icon indicating copy to clipboard operation
embed copied to clipboard

Link to sandbox endpoint always opens in new tab

Open jkjustjoshing opened this issue 1 year ago • 3 comments

Background

I'm rendering the following Typeform embed

<Widget
  {...}
  enableSandbox={isStaging}
  redirectTarget="_self"
/>

In production, when a user completes the form, the iframe (because of redirectTarget="self") redirects to my ending URL. This URL uses window.parent.postMessage() to send a message to my SPA to update the UI as appropriate.

The problem

In Sandbox mode, the Typeform iframe redirects to a final page that displays a link to the ending URL. If I click on that URL, I expect the same behavior as if the user submitted the form in non-sandbox mode (besides the lack of a form submission). Namely, I expect the redirect to the ending URL to happen inside the iframe due to my redirectTarget setting.

Requested solution

If my embed is running in sandbox mode, the ending URL link displayed after completing the form should be equal to the redirectTarget value.

jkjustjoshing avatar Sep 12 '24 14:09 jkjustjoshing

Hello @jkjustjoshing

how did you setup the redirect in your form? Can you share the form URL, please?

mathio avatar Sep 18 '24 07:09 mathio

Form ID [redacted] @mathio

jkjustjoshing avatar Sep 18 '24 08:09 jkjustjoshing

Thanks you! We have identified the issue.

I will update you here when we have a fix ready, however this is not a priority at the moment. Sorry.

mathio avatar Sep 19 '24 13:09 mathio