From 5547431b825ae330cb8b8a473393bd056d8714e9 Mon Sep 17 00:00:00 2001 From: fingadumbledore Date: Mon, 30 Oct 2023 08:20:32 +0100 Subject: [PATCH] =?UTF-8?q?versuch=20f=C3=BCr=20Mobile=20version?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- party/static/css/mobile.css | 0 party/static/js/login.js | 17 ++++++++++ party/templates/login.html | 15 +-------- party/templates/mobile.html | 67 +++++++++++++++++++++++++++++++++++++ 4 files changed, 85 insertions(+), 14 deletions(-) create mode 100644 party/static/css/mobile.css create mode 100644 party/static/js/login.js create mode 100644 party/templates/mobile.html diff --git a/party/static/css/mobile.css b/party/static/css/mobile.css new file mode 100644 index 0000000..e69de29 diff --git a/party/static/js/login.js b/party/static/js/login.js new file mode 100644 index 0000000..f8c06db --- /dev/null +++ b/party/static/js/login.js @@ -0,0 +1,17 @@ +const isMobile = /Mobi|Android/i.test(navigator.userAgent); +const deviceData = { + isMobile: isMobile, + userAgent: navigator.userAgent + }; + + document.getElementById("loginForm").addEventListener("submit", function(event) { + event.preventDefault(); // Verhindert das normale Absenden des Formulars + + var nameInput = document.getElementById("nameInput"); + var name = nameInput.value; + + sessionStorage.setItem("name", name); + + // Das Formular manuell absenden + this.submit(); +}); \ No newline at end of file diff --git a/party/templates/login.html b/party/templates/login.html index c1bb44a..ca153ec 100644 --- a/party/templates/login.html +++ b/party/templates/login.html @@ -18,19 +18,6 @@
Partycontroller Version 0.1
© Lostkids
- - + diff --git a/party/templates/mobile.html b/party/templates/mobile.html new file mode 100644 index 0000000..b96de67 --- /dev/null +++ b/party/templates/mobile.html @@ -0,0 +1,67 @@ + + + + + + Party Mobile version + + + + +

mobile version of party controll

+
+

Home

+
+
+

Game

+
+

point

+
+
+

time

+
+
+

team

+
+
+
+

Chat

+
+

generell

+
+
+

direct

+
+
+

team

+ + + +
+
+
+

Planer

+
+
+

Mate

+
+
+

Settings

+ + +
+ + \ No newline at end of file