Fix frontend lint: links, unused code, quotes, img elements

- Internal links use next/link instead of <a> (no full page reload).
- Remove dead code: RegisterForm's unreachable Yoco checkout branch, the
  unused AttendeeForms on the registration success page, unused Geist
  fonts, and assorted unused variables and catch bindings.
- Escape quotes in JSX text; replace @ts-ignore in apiFetch with a cast.
- Keep the intentional raw <img> elements (data URLs, runtime API host)
  with a documented lint exception; the event editor uses ApiImage.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-21 11:10:00 +02:00
co-authored by Claude Opus 5.5
parent 700b220906
commit 9e8244bb71
33 changed files with 73 additions and 266 deletions
@@ -218,7 +218,7 @@ export default function UserDashboardPage() {
requiredCount,
complete,
};
} catch (e) {
} catch {
// On any error, do not show forms status to avoid noisy UI
next[r.id] = { hasForm: false };
}
@@ -456,16 +456,6 @@ export default function UserDashboardPage() {
return Array.from(map.values()).sort((a, b) => new Date(a.startDate).getTime() - new Date(b.startDate).getTime());
}, [registrations]);
// Tickets by grouping
const ticketsByEvent = useMemo(() => {
const m: Record<string, any[]> = {};
for (const t of tickets) {
const eid = t.eventId;
if (!m[eid]) m[eid] = [];
m[eid].push(t);
}
return m;
}, [tickets]);
// Registration click -> open modal
const activeReg = useMemo(() => registrations.find(r => r.id === activeRegId) || null, [registrations, activeRegId]);
@@ -148,7 +148,7 @@ export default function UserProfilePage() {
try {
const res = await apiFetch<ActivityEvent[]>("/api/users/activity", { authToken: token });
setActivity(Array.isArray(res) ? res : []);
} catch (e) {
} catch {
// Non-critical — just leave the list empty rather than showing an error banner.
} finally {
setLoadingActivity(false);