mirror of
https://github.com/leaningtech/cheerpj-meta.git
synced 2025-03-15 01:54:48 +01:00
26 lines
669 B
HTML
26 lines
669 B
HTML
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>Client</title>
|
|
<script src="https://cjrtnc.leaningtech.com/3.1/cj3loader.js"></script>
|
|
</head>
|
|
<body>
|
|
<input type="text" id="ip"></input>
|
|
<script>
|
|
async function start(ip) {
|
|
await cheerpjInit({
|
|
tailscaleAuthKey: "PasteYourKeyHere",
|
|
});
|
|
cheerpjCreateDisplay(800, 600);
|
|
await cheerpjRunJar("/app/Client.jar", ip);
|
|
};
|
|
let el = document.querySelector("#ip");
|
|
el.addEventListener("keydown", (e) => {
|
|
if (e.key == "Enter") {
|
|
start(el.value);
|
|
}
|
|
});
|
|
</script>
|
|
</body>
|
|
</html> |