mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-21 02:32:18 +00:00
LIVE loads YouTube only after Play, and stops when its view is hidden
Selecting a station no longer builds the player: the LIVE section and the Cockpit's LIVE page show a poster with Play under the line that YouTube sees the viewer's IP address, as SECURITY.md asks of third-party media. The player goes when the section collapses, Context collapses or closes, the Cockpit leaves its LIVE page, or the Cockpit is entered or left, so nothing plays unseen. A selection that moves straight on to another entry of the same station (the Cockpit stepping between views) keeps the player instead of rebuilding it. SECURITY.md also lists the ISS telemetry relay.
This commit is contained in:
1 parent
71d57481b7
commit
1e2332eeb6
14 files changed
+314
-108
No files matched your search
+6
-4
@@ -55,7 +55,8 @@ function photonEndpointSetting(value) {
|
||||
* Content-Security-Policy for every document the dev/preview server serves.
|
||||
* No inline script is permitted, and the only foreign script origins are the
|
||||
* three that the Bhote Koshi event's embedded media needs (YouTube, Facebook
|
||||
* and X), which frame-src matches for their players and posts. 'unsafe-eval' is
|
||||
* and X), which frame-src matches for their players and posts; the stations'
|
||||
* LIVE video uses the same YouTube player, after the viewer presses Play. 'unsafe-eval' is
|
||||
* required: Knockout (bundled inside @cesium/widgets) resolves the global
|
||||
* object with `(0, eval)("this")` at module load, and without it the Cesium
|
||||
* widget never initializes (verified in headless Chrome). It also covers
|
||||
@@ -66,9 +67,10 @@ function photonEndpointSetting(value) {
|
||||
*/
|
||||
export const BROWSER_CSP = [
|
||||
"default-src 'self'",
|
||||
// The Bhote Koshi event's embedded media: the YouTube player API, the
|
||||
// Facebook video SDK and X's post widget (src/data/bhoteKoshiEmbeddedMedia.js);
|
||||
// and the Maps JavaScript API that Street Level's Google Street View runs on.
|
||||
// The Bhote Koshi event's embedded media: the YouTube player API (also the
|
||||
// stations' LIVE video, src/data/youtubeLivePlayer.js), the Facebook video
|
||||
// SDK and X's post widget (src/data/bhoteKoshiEmbeddedMedia.js); and the
|
||||
// Maps JavaScript API that Street Level's Google Street View runs on.
|
||||
"script-src 'self' 'unsafe-eval' blob: https://www.youtube.com https://connect.facebook.net https://platform.twitter.com https://maps.googleapis.com",
|
||||
"style-src 'self' 'unsafe-inline' https://fonts.googleapis.com",
|
||||
"font-src 'self' data: https://fonts.gstatic.com",
|
||||
|
||||
Reference in new issue
Block a user