/** * @copyright 2026 NHCarrigan * @license Naomi's Public License * @author Naomi Carrigan */ import { Component, OnInit, inject, signal, computed } from '@angular/core'; import { CommonModule } from '@angular/common'; import { FormsModule } from '@angular/forms'; import { Router } from '@angular/router'; import { ReportService } from '../../services/report.service'; import { CommentReportService } from '../../services/comment-report.service'; import { CommentsService } from '../../services/comments.service'; import { UserService } from '../../services/user.service'; import { AuthService } from '../../services/auth.service'; import { ToastService } from '../../services/toast.service'; import { ProfileReportWithUsers, CommentReportWithDetails, ReportStatus, ReportReason, PrimaryBadge } from '@library/shared-types'; @Component({ selector: 'app-admin-reports', standalone: true, imports: [CommonModule, FormsModule], template: `
Loading reports...
{{ error() }}
{{ report.details }}
{{ report.reviewNotes }}
@if (report.reviewer) { Reviewed by {{ report.reviewer.username }} }No profile reports found.
{{ report.details }}
{{ report.reviewNotes }}
@if (report.reviewer) { Reviewed by {{ report.reviewer.username }} }No comment reports found.
{{ truncateComment(report.reportedComment.content) }}