vinterliste/server
Ole-Morten Duesund 54d8ed22f4 feat(tags): moderators and admins can delete public tags
Add DELETE /api/tags/:name (gated by isModerator(), which also passes
for admins per the admin-implies-moderator invariant in roles.ts).
The endpoint normalises the name the same way creation does so the
URL casing doesn't matter, then deletes the tag and detaches it from
every activity_tags row in one transaction.

UI: new "Etiketter" nav entry visible to moderators + admins, opens
a ModerateTags.svelte view with search-as-you-type (reusing the
/api/tags suggestion endpoint) and a Slett button per row. Private
tags are unaffected — they're encrypted in the activity payload and
never reach the server tag table.

Tests: 3 new cases on top of the admin suite — moderator can delete,
plain user gets 403 (anonymous gets 401), unknown tag gets 404.
2026-05-25 17:57:33 +02:00
..
activities.ts perf(activities): bulk-fetch list serialisation (N+1 → constant) 2026-05-25 17:45:46 +02:00
admin.ts Admin role, root/home URL split, activity permalinks 2026-05-25 13:23:13 +02:00
auth.ts External profile links (max 5 per user) 2026-05-25 16:20:04 +02:00
db.ts Drag-and-drop unified activity list with per-user sort order 2026-05-25 16:47:55 +02:00
feedback.ts fix(feedback): stop exposing done_by user id in API responses 2026-05-25 13:54:07 +02:00
friends.ts Friends + friends-only visibility + blocking 2026-05-25 14:47:20 +02:00
index.ts chore(sessions): schedule periodic expired-session GC 2026-05-25 17:50:06 +02:00
invites.ts fix(invites): build share URL on the client, not the server 2026-05-25 16:25:55 +02:00
og.ts OpenGraph meta on the SPA's shareable routes 2026-05-25 16:05:43 +02:00
roles.ts Admin role, root/home URL split, activity permalinks 2026-05-25 13:23:13 +02:00
session.ts Scaffold Vinterliste — end-to-end encrypted winter activity list 2026-05-25 12:27:14 +02:00
settings.ts Self-registry toggle, invite links with attribution, first-user-admin 2026-05-25 13:45:32 +02:00
tags.ts feat(tags): moderators and admins can delete public tags 2026-05-25 17:57:33 +02:00
users.ts perf(activities): bulk-fetch list serialisation (N+1 → constant) 2026-05-25 17:45:46 +02:00