mirror of
https://github.com/Mastermindzh/react-cookie-consent.git
synced 2025-02-01 08:12:34 +01:00
Adjust the typing and the prop-type definitions related to the ButtonComponent property
This commit is contained in:
parent
4a37243ec2
commit
c1659cef53
2
src/index.d.ts
vendored
2
src/index.d.ts
vendored
@ -32,7 +32,7 @@ export interface CookieConsentProps {
|
|||||||
disableButtonStyles?: boolean;
|
disableButtonStyles?: boolean;
|
||||||
enableDeclineButton?: boolean;
|
enableDeclineButton?: boolean;
|
||||||
flipButtons?: boolean;
|
flipButtons?: boolean;
|
||||||
ButtonComponent?: Function | React.ReactElement;
|
ButtonComponent?: React.ElementType;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default class CookieConsent extends React.Component<CookieConsentProps, {}> {}
|
export default class CookieConsent extends React.Component<CookieConsentProps, {}> {}
|
||||||
|
@ -301,7 +301,7 @@ CookieConsent.propTypes = {
|
|||||||
disableButtonStyles: PropTypes.bool,
|
disableButtonStyles: PropTypes.bool,
|
||||||
enableDeclineButton: PropTypes.bool,
|
enableDeclineButton: PropTypes.bool,
|
||||||
flipButtons: PropTypes.bool,
|
flipButtons: PropTypes.bool,
|
||||||
ButtonComponent: PropTypes.oneOfType([PropTypes.func, PropTypes.element])
|
ButtonComponent: PropTypes.elementType
|
||||||
};
|
};
|
||||||
|
|
||||||
CookieConsent.defaultProps = {
|
CookieConsent.defaultProps = {
|
||||||
|
Loading…
Reference in New Issue
Block a user