chowa
Version:
UI component library based on React
51 lines (50 loc) • 1.63 kB
TypeScript
/**
* @license chowa v1.1.3
*
* Copyright (c) Chowa Techonlogies Co.,Ltd.(http://www.chowa.cn).
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
import * as React from 'react';
import * as PropTypes from 'prop-types';
import { PopoverProps } from '../popover';
export interface PopConfirmProps extends PopoverProps {
className?: string;
style?: React.CSSProperties;
title: string;
iconType?: string;
iconColor?: string;
onConfirm?: () => void;
onCancel?: () => void;
cancelText?: string;
confirmText?: string;
}
export interface PopConfirmState {
selfVisible: boolean;
}
declare class PopConfirm extends React.PureComponent<PopConfirmProps, PopConfirmState> {
static propTypes: {
className: PropTypes.Requireable<string>;
style: PropTypes.Requireable<object>;
title: PropTypes.Validator<string>;
iconType: PropTypes.Requireable<string>;
iconColor: PropTypes.Requireable<string>;
onConfirm: PropTypes.Requireable<(...args: any[]) => any>;
onCancel: PropTypes.Requireable<(...args: any[]) => any>;
cancelText: PropTypes.Requireable<string>;
confirmText: PropTypes.Requireable<string>;
};
static defaultProps: {
trigger: string;
iconType: string;
visible: boolean;
defaultVisible: boolean;
};
constructor(props: PopConfirmProps);
private onCancelHandler;
private onConfirmHandler;
private onVisibleChangeHandelr;
render(): JSX.Element;
}
export default PopConfirm;