feat(Moderation): enhance moderation reporting and user feedback
All checks were successful
Deploy to production / deploy (push) Successful in 1m55s

- Added user blocking checks in authentication and reporting processes, returning appropriate error responses.
- Expanded moderation report functionality to include new target types and optional fields for reports.
- Implemented a new API endpoint to retrieve the count of open moderation reports.
- Enhanced frontend components to allow users to report profiles, images, and guestbook entries, with corresponding UI updates.
- Updated internationalization files to include new strings for reporting features in both German and English.
This commit is contained in:
Torsten Schulz (local)
2026-04-27 15:57:02 +02:00
parent e94ae4350d
commit 530855e26e
16 changed files with 417 additions and 20 deletions

View File

@@ -22,6 +22,10 @@
"view": {
"loading": "Laden…",
"edit": "Bearbeiten",
"reportBlog": "Blog melden",
"reportPost": "Beitrag melden",
"reportBlogSent": "Blog wurde an die Moderation gemeldet.",
"reportPostSent": "Beitrag wurde an die Moderation gemeldet.",
"entriesCount": "{count} Einträge",
"empty": "Keine Einträge vorhanden.",
"fallbackDescription": "Öffentlicher Community-Blog auf YourPart.",

View File

@@ -67,6 +67,7 @@
"m-administration": {
"contactrequests": "Kontaktanfragen",
"moderationReports": "Moderationsmeldungen",
"moderationBadgeTitle": "Offene Moderationsmeldungen",
"users": "Benutzer",
"userrights": "Benutzerrechte",
"m-users": {

View File

@@ -126,8 +126,12 @@
"imageUpload": "Bild",
"submit": "Eintrag absenden",
"noEntries": "Keine Einträge gefunden",
"entryImageAlt": "Bild zum Gästebucheintrag"
"entryImageAlt": "Bild zum Gästebucheintrag",
"reportEntry": "Melden",
"deleteEntry": "Löschen",
"confirmDeleteEntry": "Diesen Gästebucheintrag wirklich löschen?"
},
"reportProfile": "Benutzername/Profil melden",
"interestedInGender": "Interessiert an",
"hasChildren": "Hat Kinder",
"smokes": "Rauchen",
@@ -199,7 +203,8 @@
"title": "Bild"
},
"imagePreviewAlt": "Bildvorschau",
"imageLoadingAlt": "Bild wird geladen"
"imageLoadingAlt": "Bild wird geladen",
"reportImage": "Bild melden"
},
"guestbook": {
"kicker": "Gästebuch",
@@ -209,6 +214,14 @@
"nextPage": "Weiter",
"page": "Seite"
},
"reporting": {
"reasonPrompt": "Kurzer Meldegrund (z. B. Spam, Beleidigung, Hassrede):",
"reasonTooShort": "Bitte gib mindestens 3 Zeichen als Meldegrund ein.",
"profileReported": "Profil wurde an die Moderation gemeldet.",
"imageReported": "Bild wurde an die Moderation gemeldet.",
"guestbookReported": "Gästebucheintrag wurde an die Moderation gemeldet.",
"reportError": "Meldung konnte nicht gesendet werden."
},
"diary": {
"kicker": "Persönliche Einträge",
"intro": "Gedanken, Notizen und kurze Updates in einer ruhigen, persönlichen Ansicht.",

View File

@@ -22,6 +22,10 @@
"view": {
"loading": "Loading…",
"edit": "Edit",
"reportBlog": "Report blog",
"reportPost": "Report post",
"reportBlogSent": "Blog has been reported to moderation.",
"reportPostSent": "Post has been reported to moderation.",
"entriesCount": "{count} entries",
"empty": "No entries available.",
"fallbackDescription": "Public community blog on YourPart.",

View File

@@ -67,6 +67,7 @@
"m-administration": {
"contactrequests": "Contact requests",
"moderationReports": "Moderation reports",
"moderationBadgeTitle": "Open moderation reports",
"users": "Users",
"userrights": "User rights",
"m-users": {

View File

@@ -126,8 +126,12 @@
"imageUpload": "Image",
"submit": "Submit entry",
"noEntries": "No entries found",
"entryImageAlt": "Guestbook entry image"
"entryImageAlt": "Guestbook entry image",
"reportEntry": "Report",
"deleteEntry": "Delete",
"confirmDeleteEntry": "Delete this guestbook entry?"
},
"reportProfile": "Report username/profile",
"interestedInGender": "Interested in",
"hasChildren": "Has children",
"smokes": "Smoking",
@@ -199,7 +203,8 @@
"title": "Image"
},
"imagePreviewAlt": "Image preview",
"imageLoadingAlt": "Loading image"
"imageLoadingAlt": "Loading image",
"reportImage": "Report image"
},
"guestbook": {
"kicker": "Guestbook",
@@ -209,6 +214,14 @@
"nextPage": "Next",
"page": "Page"
},
"reporting": {
"reasonPrompt": "Short report reason (e.g. spam, insult, hate speech):",
"reasonTooShort": "Please enter at least 3 characters as report reason.",
"profileReported": "Profile has been reported to moderation.",
"imageReported": "Image has been reported to moderation.",
"guestbookReported": "Guestbook entry has been reported to moderation.",
"reportError": "Report could not be submitted."
},
"diary": {
"kicker": "Personal entries",
"intro": "Thoughts, notes, and short updates in a calm personal view.",