Add events list and Applause for a Cause event page

This commit is contained in:
Ian Gulliver
2025-12-29 13:04:15 -08:00
parent 39d88019e8
commit 9636171b7f
3 changed files with 113 additions and 16 deletions

View File

@@ -11,37 +11,67 @@
body {
font-family: var(--wa-font-sans);
display: flex;
justify-content: center;
flex-direction: column;
align-items: center;
min-height: 100vh;
margin: 0;
padding: 1rem;
}
.profile {
#signin { display: none; }
#main { display: none; width: 100%; max-width: 600px; }
.header {
display: flex;
align-items: center;
gap: 1rem;
margin-bottom: 2rem;
width: 100%;
}
.profile img {
width: 64px;
height: 64px;
.header img {
width: 40px;
height: 40px;
border-radius: 50%;
}
#signin, #welcome { display: none; }
.header .user-info {
display: flex;
align-items: center;
gap: 0.5rem;
}
.header .spacer { flex: 1; }
.event-card {
display: flex;
align-items: center;
gap: 1rem;
text-decoration: none;
color: inherit;
}
.event-card img {
height: 80px;
border-radius: 8px;
}
.event-info h3 { margin: 0 0 0.25rem 0; }
.event-info p { margin: 0; opacity: 0.7; }
</style>
</head>
<body style="opacity: 0">
<div id="signin"></div>
<wa-card id="welcome">
<div class="profile" slot="header">
<div id="main">
<div class="header">
<img data-bind="picture" alt="Profile">
<div>
<div><strong data-bind="name"></strong></div>
<div data-bind="email"></div>
</div>
<span data-bind="name"></span>
<span class="spacer"></span>
<wa-button variant="neutral" size="small" id="logout-btn">Switch User</wa-button>
</div>
<p>Welcome to HCA Tickets!</p>
<wa-button variant="neutral" id="logout-btn">Switch User</wa-button>
</wa-card>
<h2>Events</h2>
<wa-card>
<a href="/afac26.html" class="event-card">
<img src="/afac26-logo.png" alt="Applause for a Cause">
<div class="event-info">
<p>Feb 7, 2026 · 6:30 PM</p>
<p>Helios Gym</p>
</div>
</a>
</wa-card>
</div>
<script type="module">
import { auth, logout } from '/app.js';
@@ -50,7 +80,7 @@
});
await auth();
document.getElementById('welcome').style.display = 'block';
document.getElementById('main').style.display = 'block';
document.getElementById('logout-btn').addEventListener('click', logout);
await customElements.whenDefined('wa-card');