mirror of
https://github.com/screentinker/screentinker.git
synced 2026-06-17 11:42:40 -06:00
ROOT CAUSE (hard evidence this time, from the response headers): the app sends Referrer-Policy: no-referrer globally (helmet default). A raw YouTube iframe then reaches youtube.com with NO Referer, so YouTube can't identify the embedding site and shows "Video player configuration error" (153). Confirmed by the three facts: the same /embed URL plays in a top-level tab (no embed check), plays in the device player (YT.Player loads iframe_api and validates via an ORIGIN postMessage handshake, which doesn't need Referer), and fails only as a raw iframe on a no-referrer page. The player's page is ALSO no-referrer, proving it's the embed method that saves it, not the headers. Fix: add referrerpolicy="strict-origin-when-cross-origin" to the preview iframe — overrides the page's no-referrer for just this element so YouTube receives our origin and validates the embed. Scoped (only the YouTube embed sends a referrer; only the origin, not the path), no JS API machinery needed for a passive preview, page-level no-referrer untouched. Supersedes the earlier enablejsapi/origin strip, which was inert (those params do nothing in a raw iframe with no IFrame API). Frontend-only; suite 149 green. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| components | ||
| i18n | ||
| views | ||
| agency-portal.js | ||
| api.js | ||
| app.js | ||
| brand-prime.js | ||
| branding.js | ||
| i18n.js | ||
| socket.js | ||
| utils.js | ||