// @flow
import {Component} from 'react'
import type {Time} from '../../constants/types/flow-types'
import type {SimpleProofState} from '../../constants/tracker'

type InviteBase = {
  id: string,
  created: Time,
}

export type PendingInvite = {
  url: string,
  email: ?string,
} & InviteBase

export type AcceptedInvite = {
  username: string,
  fullname: string,
  currentlyFollowing: boolean,
  trackerState: SimpleProofState,
} & InviteBase

export type Props = {
  inviteEmail: string,
  inviteMessage: string,
  showMessageField: boolean,
  pendingInvites: Array<PendingInvite>,
  acceptedInvites: Array<AcceptedInvite>,
  onSelectUser: (username: string) => void,
  onReclaimInvitation: (invitationId: string) => void,
  onRefresh: () => void,
  onGenerateInvitation: (email: string, message: string) => void,
  onClearError: () => void,
  onSelectPendingInvite: (invite: PendingInvite) => void,
  waitingForResponse: boolean,
  error: ?Error,
}

export default class Invites extends Component<void, Props, void> {}
