IFRAME won't redirect to login page

I’ve embedded Metabase in a web page using an IFRAME. This allows me to pass dashbooard ID, autorefresh settings and cascading parameters from the parent page.
This all works well for public dashboards, but when I try to share a non-public dashboard, I just get a blank page instead of being redirected to the login screen.
If I view the source and just browse to the iframe url to view the dashboard, I’m redirected to the login.

I have no idea why I’m seeing different behaviour. Any ideas or workarounds?

I suspect it’s due to click-jacking prevention

That looks like the problem.
I also tried changing the redirect link on the login page, that didn’t work either.

Is there a workaround? Perhaps adding a trusted domain? I’d prefer not to remove the clickjacking protection all together.

Found there’s already a GitHub request: