UNPKG

synapse-react-client

Version:

[![Build Status](https://travis-ci.com/Sage-Bionetworks/Synapse-React-Client.svg?branch=main)](https://travis-ci.com/Sage-Bionetworks/Synapse-React-Client) [![npm version](https://badge.fury.io/js/synapse-react-client.svg)](https://badge.fury.io/js/synaps

31 lines (30 loc) 1.2 kB
import * as React from 'react'; import { QueryResultBundle, UserProfile } from '../utils/synapseTypes/'; import { UserCardSize } from './UserCard'; export declare type UserCardListProps = { list: string[]; size?: UserCardSize; data?: QueryResultBundle; }; declare type MapOwnerIdToUserProfile = { [index: number]: UserProfile; }; export declare type UserCardListState = { userProfileMap: MapOwnerIdToUserProfile; }; export default class UserCardList extends React.Component<UserCardListProps, UserCardListState> { constructor(props: UserCardListProps); componentDidMount(): void; componentDidUpdate(prevProps: UserCardListProps): void; update(list: string[]): void; /** * Given data this will find rows where there is no userId columnType and create faux user profiles * using firstName, lastName, and instituion (company in UserProfile object). * @param {QueryResultBundle} data * @returns list of UserProfiles with firstName, lastName, company, userName (first letter of firstName) filled out. * @memberof UserCardList */ manuallyExtractData(data: QueryResultBundle): UserProfile[]; render(): JSX.Element; } export {};