@talend/react-containers
Version:
Provide connected components aka containers for @talend/react-cmf based on @talend/react-components.
47 lines (46 loc) • 1.6 kB
TypeScript
/**
* DeleteResource is used to delete a specific resource.
* When the component is mounted, it opens a confirm dialog.
* It uses the saga matching pattern to launch a race between the cancel and validate action.
*/
export class DeleteResource extends Component<any, any, any> {
static displayName: string;
static propTypes: any;
static defaultProps: {
validateActionProps: {};
t: import("i18next").TFunction<["translation", ...string[]], undefined>;
};
constructor(props: any);
/**
* Get the label from the collections.
* Return the label and a boolean to confirm that the item has been found.
*/
getLabelInfo(): {
label: any;
found: boolean;
};
/**
* Build an object with all the data's resource we need.
*/
getResourceInfo(): {
id: any;
redirectUrl: any;
onCancelRedirectUrl: any;
resource: any;
label: any;
found: boolean;
resourceType: any;
collectionId: any;
resourceTypeLabel: any;
uri: any;
};
/**
* onHide handler, called when click outside delete modal
* @param event
*/
onHide(event: any): void;
render(): import("react/jsx-runtime").JSX.Element;
}
declare const _default: import("react").ComponentType<Omit<import("react-i18next/helpers").$Subtract<any, import("react-i18next").WithTranslationProps>, keyof import("react-i18next").WithTranslation<Ns, undefined>> & import("react-i18next").WithTranslationProps>;
export default _default;
import { Component } from 'react';