synapse-react-client
Version:
[](https://travis-ci.com/Sage-Bionetworks/Synapse-React-Client) [](https://badge.fury.io/js/synaps
38 lines (37 loc) • 1.46 kB
TypeScript
import * as React from 'react';
import { FileEntity, UserProfile } from '../utils/synapseTypes/';
export declare type EntityFormProps = {
parentContainerId: string;
formSchemaEntityId: string;
formUiSchemaEntityId: string;
initFormData: boolean;
synIdCallback: (synId: string) => void;
};
declare type EntityFormState = {
error?: any;
isLoading?: boolean;
successfullyUploaded: boolean;
containerId?: string;
userprofile?: UserProfile;
currentFileEntity?: FileEntity;
formData?: any;
formSchema?: any;
formUiSchema?: any;
};
export default class EntityForm extends React.Component<EntityFormProps, EntityFormState> {
static contextType: React.Context<import("../utils/SynapseContext").SynapseContextType | undefined>;
formRef: any;
constructor(props: EntityFormProps);
componentDidMount(): void;
submitForm: () => void;
refresh: () => void;
getSchemaFileContent: (targetFolderId: string, formSchemaFileEntity: FileEntity, formUiSchemaFileEntity: FileEntity) => void;
getExistingFileData: (targetFolderId: string, formSchemaContent: any, formUiSchemaContent: any) => void;
getTargetContainer: (userprofile: UserProfile, token: string) => Promise<string | void>;
finishedProcessing: () => void;
onError: (error: any) => void;
onSubmit: ({ formData }: any) => void;
createEntityFile: (fileContentsBlob: Blob) => void;
render(): JSX.Element;
}
export {};