import { ComponentType } from 'react' export type FeedSourceItem = { props: Props // If pending, the item will count towards the pending count. pending: boolean /** * If present, the item will be sorted by this value in ascending order. * Smaller values will appear first. */ order?: number } export type FeedSourceDaoWithItems = { chainId: string coreAddress: string items: FeedSourceItem[] } export type FeedSourceData = { loading: boolean refreshing: boolean daosWithItems: FeedSourceDaoWithItems[] refresh: () => void } export type FeedSource = { id: string Renderer: ComponentType useData: () => FeedSourceData } export type FeedItem = FeedSourceItem & { Renderer: ComponentType } export type FeedDaoWithItems = { dao: { chainId: string coreAddress: string name: string imageUrl: string } items: FeedItem[] } export type FeedState = { loading: boolean refreshing: boolean daosWithItems: FeedDaoWithItems[] pendingItemCount: number totalItemCount: number refresh: () => void } export type FeedFilter = { chainId?: string }