feat: Implement user profile management and navigation updates
- Added a new profile page (my_profil.html) for users to manage their events and personal information. - Introduced a new CSS file (my_profil.css) for styling the profile page. - Created a JavaScript file (my_profil.js) to handle profile data retrieval, event registration management, and form submission. - Updated navigation logic (navigation.js) to dynamically display login/signup or event management links based on user authentication status. - Enhanced event creation and detail pages to support user-specific actions (registration/unregistration). - Improved login and signup processes to handle user data more robustly, including fallback user creation. - Refactored event overview to show user-specific events and registrations. - Added error handling and validation for user input in profile management.
This commit is contained in:
1 parent
46074df578
commit
1efa4dcd39
17 files changed
+1076
-29
No files matched your search
+102
@@ -0,0 +1,102 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="de">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Mein Profil | Invité</title>
|
||||
|
||||
<!-- Stylesheet für diese Seite -->
|
||||
<link rel="stylesheet" href="css/my_profil.css">
|
||||
<!-- Globales Stylesheet -->
|
||||
<link rel="stylesheet" href="css/stylesheet_global.css">
|
||||
<script src="js/navigation.js" defer></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<header class="top-nav-wrap">
|
||||
<div class="top-nav">
|
||||
<a class="brand" href="index.html" aria-label="Zur Startseite">
|
||||
<img src="assets/logo_invite.svg" alt="Invite Logo">
|
||||
</a>
|
||||
<nav class="nav-tab-links" aria-label="Hauptnavigation">
|
||||
<a class="button-small" href="login.html" aria-label="Login">Login</a>
|
||||
</nav>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main class="container profile-page">
|
||||
<section class="profile-hero" aria-label="Profilübersicht">
|
||||
<div>
|
||||
<p class="profile-kicker">Mein Bereich</p>
|
||||
<h1 id="profile-headline">Mein Profil</h1>
|
||||
<p id="profile-subline" class="profile-subline">Hier findest du deine Events, deine Anmeldungen und kannst deine Profildaten verwalten.</p>
|
||||
</div>
|
||||
<button id="logout-button" class="button-small profile-logout" type="button">Logout</button>
|
||||
</section>
|
||||
|
||||
<section id="logged-out-state" class="profile-panel hidden" aria-live="polite">
|
||||
<h2 class="panel-title">Du bist noch nicht eingeloggt</h2>
|
||||
<p>Melde dich an, damit wir deine Events und Anmeldungen anzeigen können.</p>
|
||||
<div class="profile-cta-row">
|
||||
<a class="button" href="login.html">Zum Login</a>
|
||||
<a class="button profile-button-secondary" href="signup.html">Konto erstellen</a>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section id="logged-in-content" class="profile-grid">
|
||||
<article class="profile-panel">
|
||||
<div class="panel-head">
|
||||
<h2 class="panel-title">Meine Events</h2>
|
||||
<span id="my-events-count" class="panel-count">0</span>
|
||||
</div>
|
||||
<div id="my-events-list" class="profile-card-list"></div>
|
||||
</article>
|
||||
|
||||
<article class="profile-panel">
|
||||
<div class="panel-head">
|
||||
<h2 class="panel-title">Meine Anmeldungen</h2>
|
||||
<span id="my-registrations-count" class="panel-count">0</span>
|
||||
</div>
|
||||
<div id="my-registrations-list" class="profile-card-list"></div>
|
||||
</article>
|
||||
|
||||
<article class="profile-panel profile-panel-form">
|
||||
<h2 class="panel-title">Profil verwalten</h2>
|
||||
<form id="profile-form" novalidate>
|
||||
<div class="form-grid">
|
||||
<div class="form-group">
|
||||
<label for="vorname">Vorname</label>
|
||||
<input type="text" id="vorname" name="vorname" required>
|
||||
<p class="input-error" id="vorname-error">Bitte gib deinen Vornamen ein.</p>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="nachname">Nachname</label>
|
||||
<input type="text" id="nachname" name="nachname" required>
|
||||
<p class="input-error" id="nachname-error">Bitte gib deinen Nachnamen ein.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="email">E-Mail</label>
|
||||
<input type="email" id="email" name="email" required>
|
||||
<p class="input-error" id="email-error">Bitte gib eine gültige E-Mail-Adresse ein.</p>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="passwort">Passwort</label>
|
||||
<input type="password" id="passwort" name="passwort" minlength="6" placeholder="Mindestens 6 Zeichen">
|
||||
<p class="input-hint">Nur ausfüllen, wenn du dein Passwort ändern möchtest.</p>
|
||||
<p class="input-error" id="passwort-error">Das Passwort muss mindestens 6 Zeichen lang sein.</p>
|
||||
</div>
|
||||
|
||||
<button class="button" type="submit">Profil speichern</button>
|
||||
<p id="profile-feedback" class="profile-feedback" aria-live="polite"></p>
|
||||
</form>
|
||||
</article>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<script src="js/my_profil.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in new issue
Block a user