synapse-react-client
Version:
[](https://travis-ci.com/Sage-Bionetworks/Synapse-React-Client) [](https://badge.fury.io/js/synaps
36 lines (35 loc) • 1.57 kB
TypeScript
import React from 'react';
import { EntityType, Reference } from '../../../utils/synapseTypes';
import { BreadcrumbItem } from '../Breadcrumbs';
import { EntityDetailsListDataConfiguration } from '../details/EntityDetailsList';
import { NodeAppearance } from './TreeNode';
import { Map } from 'immutable';
export declare enum FinderScope {
CURRENT_PROJECT = "Current Project",
ALL_PROJECTS = "All Projects",
CREATED_BY_ME = "Projects Created By Me",
FAVORITES = "My Favorites"
}
export declare type TreeViewProps = {
initialScope?: FinderScope;
/** To show the current project, projectId must be defined */
projectId?: string;
initialContainer: string | 'root' | null;
showDropdown: boolean;
selectedEntities: Map<string, number>;
visibleTypes?: EntityType[];
toggleSelection?: (entity: Reference) => void;
setDetailsViewConfiguration?: (configuration: EntityDetailsListDataConfiguration) => void;
setBreadcrumbItems?: (items: BreadcrumbItem[]) => void;
/** Determines whether to show the root node corresponding to the selected scope */
showScopeAsRootNode?: boolean;
nodeAppearance: NodeAppearance;
/** The entity types that may be selected. */
selectableTypes: EntityType[];
};
/**
* The TreeView displays a user's entities hierarchically, allowing a user to quickly dive into an entity tree.
*
* The tree view currently can only be used to drive a DetailsView using the `setDetailsViewConfiguration` property.
*/
export declare const TreeView: React.FunctionComponent<TreeViewProps>;