-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsettings.html
More file actions
120 lines (116 loc) · 4.99 KB
/
settings.html
File metadata and controls
120 lines (116 loc) · 4.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Settings - Treasurehunter Companion</title>
<link rel="stylesheet" href="css/main.css">
<link rel="stylesheet" href="css/settings.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css">
<link rel="icon" type="image/x-icon" href="/images/favicon.ico">
</head>
<body>
<header>
<div class="header-content">
<button class="mobile-menu-toggle" aria-label="Toggle mobile menu">
<i class="fas fa-bars"></i>
</button>
<a href="/" class="logo">Treasurehunter Companion</a>
<nav id="main-nav">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="map.html">Map</a></li>
<li><a href="compendium.html">Compendium</a></li>
<li><a href="wiki.html">Wiki</a></li>
<li><a href="clan.html">Clan</a></li>
<li><a href="#">Market</a></li>
</ul>
</nav>
<div class="user-panel">
<div class="notification-container">
<i id="notification-icon" class="fas fa-bell"></i>
<div id="notification-dropdown" class="dropdown-content">
<div id="notification-list"></div>
</div>
</div>
<button class="user-panel-toggle">
<img id="user-panel-avatar" src="/images/default-avatar.jpg" alt="User Avatar">
<span id="user-panel-username"></span>
<i class="fas fa-chevron-down"></i>
</button>
<div class="user-dropdown">
<a href="/profile">Profile</a>
<a href="/settings">Settings</a>
<a href="#" id="logout-link">Logout</a>
</div>
</div>
</div>
</header>
<main class="settings-main">
<h2>User Settings</h2>
<div class="settings-container">
<form id="settings-form">
<div class="form-group">
<label for="username">Username:</label>
<input type="text" id="username" name="username" required>
</div>
<div class="form-group">
<label for="email">Email:</label>
<input type="email" id="email" name="email" required>
</div>
<div class="form-group">
<label for="new-password">New Password:</label>
<input type="password" id="new-password" name="new-password">
</div>
<div class="form-group">
<label for="confirm-password">Confirm New Password:</label>
<input type="password" id="confirm-password" name="confirm-password">
</div>
<button type="submit" class="btn btn-primary">Save Changes</button>
</form>
</div>
</main>
<footer>
<div class="footer-content">
<div class="footer-logo"><img src="/images/DevCat_Logo.png" alt="DevCat Logo"></div>
<div class="footer-links">
<a href="/index.html">Home</a>
<a href="#">About</a>
<a href="#">Contact</a>
<a href="#">Privacy Policy</a>
</div>
<div class="footer-social">
<a href="https://github.com/DevelopmentCats"><i class="fab fa-github"></i></a>
<a href="#"><i class="fab fa-discord"></i></a>
<a href="#"><i class="fab fa-facebook"></i></a>
</div>
</div>
<div class="footer-bottom">
© 2024 DeveloperCats. All rights reserved.
</div>
</footer>
<script src="https://cdn.jsdelivr.net/npm/date-fns@3.6.0/cdn.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/uuid@8.3.2/dist/umd/uuid.min.js"></script>
<script type="module">
import { setupMobileNavigation } from './js/utils.js';
import logger, { initializeBrowserLogger } from './js/logger.js';
import { isLoggedIn, checkAuth } from './js/auth.js';
import './js/userPanel.js';
import './js/settings.js';
import { loadNotifications } from './js/notifications.js';
async function init() {
await initializeBrowserLogger();
setupMobileNavigation();
logger.info('Settings page loaded');
if (isLoggedIn()) {
loadNotifications();
} else {
window.location.href = 'login.html';
}
checkAuth();
// Any other settings-specific initialization can go here
}
init().catch(error => console.error('Initialization error:', error));
</script>
</body>
</html>