aboutsummaryrefslogtreecommitdiffstats
path: root/public/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'public/index.html')
-rw-r--r--public/index.html50
1 files changed, 50 insertions, 0 deletions
diff --git a/public/index.html b/public/index.html
new file mode 100644
index 0000000..f9ab8c8
--- /dev/null
+++ b/public/index.html
@@ -0,0 +1,50 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+<title>&#8203;</title>
+<meta name="viewport" content="width=device-width, initial-scale=1.0">
+<meta charset="UTF-8">
+<link rel="stylesheet" href="/style.css">
+</head>
+<body>
+<div class="container">
+<h1>📝</h1>
+
+<!--- auth section. --->
+<div id="auth-section">
+ <div class="tabs">
+ <button class="tab-btn active" id="login-tab" onclick="switchTab('login')">Log in_::</button>
+ <button class="tab-btn" id="register-tab" onclick="switchTab('register')">Register_::</button>
+ </div>
+ <form id="login-form" onsubmit="login(event)">
+ <input type="text" id="login-username" placeholder=":user" required>
+ <input type="password" id="login-password" placeholder=":pass" required>
+ <button type="submit">Login</button>
+ </form>
+ <form id="register-form" style="display:none" onsubmit="register(event)">
+ <input type="text" id="reg-username" placeholder=":user" required>
+ <input type="password" id="reg-password" placeholder=":pass" required>
+ <button type="submit">Register</button>
+ </form>
+ <p id="auth-error" class="error"></p>
+</div>
+
+<!--- tasks section. --->
+<div id="tasks-section" style="display:none">
+ <div class="header">
+ <h2>Your Tasks</h2>
+ <button onclick="logout()" class="logout-btn">Logout</button>
+ </div>
+ <!--- create task. --->
+ <form id="task-form" onsubmit="createTask(event)">
+ <input type="text" id="task-title" placeholder="Task title" required>
+ <input type="text" id="task-desc" placeholder="Description (optional)">
+ <button type="submit">Add Task</button>
+ </form>
+ <!--- task list. --->
+ <ul id="task-list"></ul>
+</div>
+
+<script src="/app.js"></script>
+</body>
+</html>