/** Minimal user snapshot embedded in audit payloads. */
export type ContentAuditUser = {
  id: string
  name: string | null
  email: string
  image: string | null
}

/** Standard audit block returned by content APIs (create + last update). */
export type ContentAudit = {
  createdAt: string
  updatedAt: string
  createdBy: ContentAuditUser | null
  updatedBy: ContentAuditUser | null
}

/** Which slice of audit data a UI component should emphasize. */
export type ContentAuditDisplayMode = "created" | "updated" | "both"

/** Prisma `select` fragment for user relations on auditable content. */
export const contentAuditUserSelect = {
  id: true,
  name: true,
  email: true,
  image: true,
} as const
