lucid-ui
Version:
A UI component library from Xandr.
94 lines • 3.28 kB
TypeScript
import React from 'react';
import PropTypes from 'prop-types';
import { StandardProps } from '../../util/component-types';
export interface IPanelHeaderProps extends StandardProps, React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement> {
description?: string;
}
export interface IPanelFooterProps extends StandardProps, React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement> {
description?: string;
}
export interface IPanelProps extends StandardProps, React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement> {
/** *Child Element* - Header contents. Only one \`Header\` is used. */
Header?: React.ReactNode & {
props: IPanelHeaderProps;
};
/** *Child Element* - Footer contents. Only one \`Footer\` is used. */
Footer?: React.ReactNode & {
props: IPanelFooterProps;
};
/** If set to true, creates a content section with no padding. */
isGutterless: boolean;
/** If set to false, removes margin around the Panel */
hasMargin: boolean;
/** If set to true, makes content overflow scrollable, when Panel has a set
* height. */
isScrollable: boolean;
}
export declare const Panel: {
(props: IPanelProps): React.ReactElement;
defaultProps: {
isGutterless: boolean;
hasMargin: boolean;
isScrollable: boolean;
};
displayName: string;
peek: {
description: string;
categories: string[];
};
propTypes: {
/**
Appended to the component-specific class names set on the root element.
*/
className: PropTypes.Requireable<string>;
Header: PropTypes.Requireable<PropTypes.ReactNodeLike>;
/**
*Child Element* - Footer contents. Only one \`Footer\` is used.
*/
Footer: PropTypes.Requireable<PropTypes.ReactNodeLike>;
/**
Generally you should only have a single child element so the centering
works correctly.
*/
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
/**
If set to true, creates a content section with no padding.
*/
isGutterless: PropTypes.Requireable<boolean>;
/**
Styles that are passed through to root element.
*/
style: PropTypes.Requireable<object>;
/**
If set to true, makes content overflow scrollable, when Panel has a set
height.
*/
isScrollable: PropTypes.Requireable<boolean>;
};
Header: {
(_props: IPanelHeaderProps): null;
displayName: string;
peek: {
description: string;
};
propTypes: {
description: PropTypes.Requireable<string>;
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
};
propName: string;
};
Footer: {
(_props: IPanelFooterProps): null;
displayName: string;
peek: {
description: string;
};
propTypes: {
description: PropTypes.Requireable<string>;
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
};
propName: string;
};
};
export default Panel;
//# sourceMappingURL=Panel.d.ts.map