Spaces:
Running
Running
Juan Jimenez Carrero
feat: lock-all, plan wishes, location tags in form, shopping usage, PWA
9f40540 | <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" /> | |
| <title>CookAIware</title> | |
| <link rel="icon" href="/icon.png" type="image/png" /> | |
| <link rel="manifest" href="/manifest.webmanifest" /> | |
| <link rel="apple-touch-icon" href="/icon.png" /> | |
| <meta name="theme-color" content="#2c8b88" /> | |
| <link rel="preconnect" href="https://fonts.googleapis.com" /> | |
| <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> | |
| <link | |
| href="https://fonts.googleapis.com/css2?family=Fraunces:wght@400;600;700&family=Nunito:wght@400;600;700&display=swap" | |
| rel="stylesheet" | |
| /> | |
| <!-- Theme bootstrap: paints the right palette BEFORE CSS lands so | |
| there's no flash. Priority: `?theme=dark|light` query param | |
| (set by the host when iframing us), then `prefers-color-scheme`. --> | |
| <script> | |
| (function () { | |
| try { | |
| var params = new URLSearchParams(window.location.search); | |
| var raw = params.get("theme"); | |
| var mode; | |
| if (raw === "dark" || raw === "light") { | |
| mode = raw; | |
| } else if (window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches === false) { | |
| mode = "light"; | |
| } else { | |
| mode = "dark"; | |
| } | |
| document.documentElement.setAttribute("data-theme", mode); | |
| } catch (_) { | |
| document.documentElement.setAttribute("data-theme", "dark"); | |
| } | |
| })(); | |
| </script> | |
| <!-- HF Spaces helper variables. | |
| - In production, HF substitutes these placeholders at file- | |
| serve time when `hf_oauth: true` is set on the Space. | |
| - In `npm run dev`, placeholders stay untouched; we detect | |
| that and drop `window.huggingface` so the SDK falls back to | |
| the clientId supplied via `mountHost({ clientId })`. --> | |
| <script> | |
| (function () { | |
| var clientId = "__OAUTH_CLIENT_ID__"; | |
| var scopes = "__OAUTH_SCOPES__"; | |
| var spaceHost = "__SPACE_HOST__"; | |
| var spaceId = "__SPACE_ID__"; | |
| var looksSubstituted = clientId && clientId.indexOf("__") !== 0; | |
| if (looksSubstituted) { | |
| window.huggingface = window.huggingface || {}; | |
| window.huggingface.variables = { | |
| OAUTH_CLIENT_ID: clientId, | |
| OAUTH_SCOPES: scopes && scopes.indexOf("__") !== 0 ? scopes : "openid profile", | |
| SPACE_HOST: spaceHost && spaceHost.indexOf("__") !== 0 ? spaceHost : "", | |
| SPACE_ID: spaceId && spaceId.indexOf("__") !== 0 ? spaceId : "", | |
| }; | |
| } | |
| })(); | |
| </script> | |
| </head> | |
| <body> | |
| <!-- Capture the robot's inbound audio track BEFORE the Reachy SDK module | |
| loads, so the voice loop can read Reachy's microphone. The SDK only | |
| surfaces video tracks to app code; audio lands here. --> | |
| <script> | |
| (function () { | |
| window.__reachyCapturedAudioTrack = null; | |
| var _OrigPC = window.RTCPeerConnection; | |
| if (!_OrigPC) return; | |
| function PatchedPC() { | |
| var pc = new (Function.prototype.bind.apply(_OrigPC, [null].concat([].slice.call(arguments))))(); | |
| pc.addEventListener("track", function (e) { | |
| if (e.track && e.track.kind === "audio" && !window.__reachyCapturedAudioTrack) { | |
| window.__reachyCapturedAudioTrack = e.track; | |
| } | |
| }); | |
| return pc; | |
| } | |
| PatchedPC.prototype = _OrigPC.prototype; | |
| Object.setPrototypeOf(PatchedPC, _OrigPC); | |
| window.RTCPeerConnection = PatchedPC; | |
| })(); | |
| </script> | |
| <div id="root"></div> | |
| <!-- Single dispatcher. Picks the host shell (standalone visit) or | |
| the embedded app (host's iframe) based on `?embedded=1`. --> | |
| <script type="module" src="/src/dispatch.ts"></script> | |
| </body> | |
| </html> | |