Files
damus/damus/Features/Actions/Reports/Models/Report.swift
ericholguin 65a22813a3 refactor: Adding structure
Huge refactor to add better structure to the project.
Separating features with their associated view and model structure.
This should be better organization and will allow us to improve the
overall architecture in the future.

I forsee many more improvements that can follow this change. e.g. MVVM Arch
As well as cleaning up duplicate, unused, functionality.
Many files have global functions that can also be moved or be renamed.

damus/
├── Features/
│   ├── <Feature>/
│   │   ├── Views/
│   │   └── Models/
├── Shared/
│   ├── Components/
│   ├── Media/
│   ├── Buttons/
│   ├── Extensions/
│   ├── Empty Views/
│   ├── ErrorHandling/
│   ├── Modifiers/
│   └── Utilities/
├── Core/
│   ├── Nostr/
│   ├── NIPs/
│   ├── DIPs/
│   ├── Types/
│   ├── Networking/
│   └── Storage/

Signed-off-by: ericholguin <ericholguin@apache.org>
2025-08-06 10:24:00 -07:00

43 lines
1.1 KiB
Swift

//
// Report.swift
// damus
//
// Created by William Casarin on 2023-01-24.
//
import Foundation
enum ReportType: String, CustomStringConvertible, CaseIterable {
case spam
case nudity
case profanity
case illegal
case impersonation
var description: String {
switch self {
case .spam:
return NSLocalizedString("Spam", comment: "Description of report type for spam.")
case .nudity:
return NSLocalizedString("Nudity", comment: "Description of report type for nudity.")
case .profanity:
return NSLocalizedString("Profanity", comment: "Description of report type for profanity.")
case .illegal:
return NSLocalizedString("Illegal Content", comment: "Description of report type for illegal content.")
case .impersonation:
return NSLocalizedString("Impersonation", comment: "Description of report type for impersonation.")
}
}
}
struct ReportNoteTarget {
let pubkey: Pubkey
let note_id: NoteId
}
enum ReportTarget {
case user(Pubkey)
case note(ReportNoteTarget)
}