|
|
@ -1,13 +1,17 @@ |
|
|
|
/** |
|
|
|
* Interfaces for the give records with limited contact information, good to show on a feed. |
|
|
|
**/ |
|
|
|
|
|
|
|
import { GiveSummaryRecord } from "./records"; |
|
|
|
|
|
|
|
// Common interface for contact information
|
|
|
|
// Common interface for views with summary contact information
|
|
|
|
export interface ContactInfo { |
|
|
|
known: boolean; |
|
|
|
displayName: string; |
|
|
|
profileImageUrl?: string; |
|
|
|
} |
|
|
|
|
|
|
|
// Define the contact information fields
|
|
|
|
// Define a subset of contact information fields
|
|
|
|
interface GiveContactInfo { |
|
|
|
giver: ContactInfo; |
|
|
|
issuer: ContactInfo; |
|
|
@ -17,5 +21,5 @@ interface GiveContactInfo { |
|
|
|
image?: string; |
|
|
|
} |
|
|
|
|
|
|
|
// Combine GiveSummaryRecord with contact information using intersection type
|
|
|
|
// Combine GiveSummaryRecord with contact information
|
|
|
|
export type GiveRecordWithContactInfo = GiveSummaryRecord & GiveContactInfo; |
|
|
|