Live video on the AT Protocol
at natb/urfave 45 lines 1.4 kB view raw
1<!doctype html> 2<html lang="en"> 3 <head> 4 <meta charset="UTF-8" /> 5 <meta name="viewport" content="width=device-width, initial-scale=1.0" /> 6 <title>Streamplace App Return</title> 7 <style> 8 html, 9 body { 10 height: 100%; 11 width: 100%; 12 margin: 0; 13 padding: 0; 14 background-color: black; 15 display: flex; 16 align-items: center; 17 justify-content: center; 18 } 19 button { 20 background-color: rgb(189, 110, 134); 21 color: white; 22 padding: 10px 20px; 23 border-radius: 5px; 24 border: none; 25 font-size: 1.5rem; 26 font-weight: bold; 27 cursor: pointer; 28 } 29 </style> 30 </head> 31 <body> 32 <button>Complete Login</button> 33 </body> 34 <script> 35 const appBundleId = "APP_BUNDLE_ID_REPLACE_ME"; 36 // This should work. It does work on iOS. On Android, it causes the token to be 37 // authorized twice? I don't know why. I spent two hours trying to figure out why 38 // without luck. You're welcome to try more if you want! In the meantime, using 39 // an annoying button makes it work every time. 40 document.location.href = `${appBundleId}:/${window.location.search}`; 41 document.querySelector("button").addEventListener("click", () => { 42 document.location.href = `${appBundleId}:/${window.location.search}`; 43 }); 44 </script> 45</html>