Astroport.ONE/templates/register.html

180 lines
6.2 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>[Astroport] : G1Visa Application : _HOSTNAME_ :: _IPFSNODEID_ </title>
<meta http-equiv="refresh" content="999; url='http://127.0.0.1:12345'" />
<link rel="icon" type="image/png" href="http://127.0.0.1:8080/ipfs/QmaCh8mywWfxkXF3JziFzqZS6yZFo3eNS5fSfnzJqdSQvX/logo.png" />
<link rel="stylesheet" href="http://127.0.0.1:8080/ipfs/QmaCh8mywWfxkXF3JziFzqZS6yZFo3eNS5fSfnzJqdSQvX/decoration.css" type="text/css" />
<link rel="stylesheet" href="http://127.0.0.1:8080/ipfs/QmaCh8mywWfxkXF3JziFzqZS6yZFo3eNS5fSfnzJqdSQvX/layout.css" type="text/css" />
<style>
body {
background-image:url("http://127.0.0.1:8080/ipfs/QmSFgatcq3q898J56epa8SyGbH651vRBFnv93kQSwfoi83/background.000.jpg");
background-repeat: no-repeat;
background-size: 100% 100%;
}
html {
height: 100%
}
header {
opacity: 0.8;
}
input[type=submit] {
width: 12em; height: 4em;
}
input[type=checkbox] {
width: 2em; height: 2em;
}
input {
width: 26em; height: 2em;
}
#yellow {
background: yellow;
position: absolute;
top: 12%;
left: 66%;
width: 18%;
visibility: hidden;
}
#login {
right: 10%;
top: 5%
}
</style>
<!-- Typed text animation -->
<script src="http://127.0.0.1:8080/ipfs/QmYyJmAT3cUbjk4vVWQG7LdpY3HkFH9phFD1VzzetHrgpa"></script>
<!-- Astro API JS LIB -->
<script src="http://127.0.0.1:8080/ipfs/Qmae5v9zydax9u6C9ceDijURu5PYdd5avmv4NkenCw7RFv/astro.js"></script>
</head>
<body>
<header>
<!--
<div id="login"><button onclick="promptUser('login')">LOGIN</button><button onclick="promptUser('logout')">LOGOUT</button></div>
-->
<div>
<button onclick="homeAstroportStation('/?qrcode=station', '', 21654)">Ğ1Station</button>
</div>
<span><div id="ainfo"></div></span>
<div id="debug"></div>
</header>
<main>
<center>
<b>Welkom - Mirë se vini - Willkommen - Welkomma - Welcome - Marhaban - Bari galoust - Xos gelmissiniz - Welkum - Ongi etorri- Swagata - Ansuf yiswen - ščyra zaprašajem - Kyo tzo pa eit - ॐ★ॐ - Ani kié - Dobro došli - Dagemer mat - Dobre doshŭl - Benvinguts - Ulihebisdi - ௐ- Huān yíng - Karibu - Eoso eoseyo - Benvenuti - Bel bonjou - Bienvini - Dobrodošli - Velkommen - Bienvenido - Bonvenon - Tere tulemast - Gabitê - Vælkomin - Tervetuloa - Welkom - Wìllkòmme - Binvignut - Fàilte - Benvido - Croeso - Planvenguda - Mikouabô - Kalos irthate - Eguahé porá - Baroukh habaim - ﷽ </b><br>
<header>
<form id="formlink" action = "http://127.0.0.1:1234" method = "GET" enctype="application/x-www-form-urlencoded">
<h1><span>Astroport</span> <a href="https://pad.p2p.legal/s/Astroport.ONE">Ŋ1</a></h1>
<div id="yellow">
<input type=hidden name='salt' value='0'>
<h3><a title="SERVE YOURSELF" href="http://127.0.0.1:12345"> >>> (◕‿‿◕) <<< </a></h3>
<input type=hidden name='pepper' value='0'>
</div>
<input name=g1pub value='any youtube link to feed your TW with ?'></br>
<span>Email : </span><input name=email value=''></br></br>
<input type=hidden name='lat' value='0.00'>
<input type=hidden name='lon' value='0.00'>
<input type='submit' value='[(♥‿‿♥)]'>
</form>
<h6>
<p id="station"><div id='countdown'></div></span></p>
</h6>
</main>
</body>
<script>
// Extract latitude and longitude from URL parameters
const urlParams = new URLSearchParams(window.location.search);
const lat = urlParams.get('lat').toFixed(2);
const lon = urlParams.get('lon').toFixed(2);
// Set latitude and longitude values to hidden inputs
document.getElementById('salt').value = lat;
document.getElementById('pepper').value = lon;
var typed = new Typed('#typed', {
stringsElement: '#typed-strings',
smartBackspace: true,
backDelay: 700,
loop: true,
typeSpeed: 40
});
</script>
<script>
const el = document.getElementById('yellow');
//~ const log = document.getElementById('login');
//~ log.style.visibility = 'visible';
setTimeout(() => {
el.style.visibility = 'visible';
}, 5456); // 👈️ delay in milliseconds
var arrTimes = [];
var i = 0; // start
var timesToTest = 3;
var tThreshold = 300; //ms
var testImage = "https://ipfs.copylaradio.com/ipfs/QmUUyiuCM4yXgaeGyqC2SVUUXZksuxhDfHQYpUpZPuL2oS/astroport.jpg"; // small image in your server
var dummyImage = new Image();
var isConnectedFast = false;
testLatency(function(avg){
isConnectedFast = (avg <= tThreshold);
/** output */
document.body.appendChild(
document.createTextNode("Time: " + (avg.toFixed(2)) + "ms - ♥Box ready ? " + isConnectedFast)
);
});
/** test and average time took to download image from server, called recursively timesToTest times */
function testLatency(cb) {
var tStart = new Date().getTime();
if (i<timesToTest-1) {
dummyImage.src = testImage + '?t=' + tStart;
dummyImage.onload = function() {
var tEnd = new Date().getTime();
var tTimeTook = tEnd-tStart;
arrTimes[i] = tTimeTook;
testLatency(cb);
i++;
};
} else {
/** calculate average of array items then callback */
var sum = arrTimes.reduce(function(a, b) { return a + b; });
var avg = sum / arrTimes.length;
cb(avg);
}
}
</script>
<script>
let cookies = document.cookie;
console.log(cookies);
var timeLeft = 5;
var elem = document.getElementById("countdown");
var timerId = setInterval(countdown, 999);
function countdown() {
if (timeLeft == -1) {
clearTimeout(timerId);
document.getElementById("countdown").innerHTML = "<form method='get' action='http://g1billet.localhost:33101' target='aframe'><input type='hidden' name='montant' value='0' ><label for='type'>Type :</label><select name='type'><option value=''>G1BILLET+ ( x 6 )</option><option value='jeu'>G1CARD</option><option value='xastro' selected>G1CARD+TW</option><option value='@astroport'>G1CARD+@</option></select><input type='hidden' name='dice' value='4' >&nbsp;&nbsp;&nbsp;&nbsp;<button type='submit'>Extra</button></form>";
} else {
// elem.innerHTML = timeLeft + " s";
timeLeft--;
}
}
// promptUser();
</script>
</html>