Debian Codegraph @

node/@patternfly/react-core/dist/js/components/Banner/Banner.d.ts

raw
1 /// <reference types="react" />
2 export type BannerColor = 'red' | 'orangered' | 'orange' | 'yellow' | 'green' | 'teal' | 'blue' | 'purple';
3 export type BannerStatus = 'success' | 'warning' | 'danger' | 'info' | 'custom';
4 export interface BannerProps extends React.HTMLProps<HTMLDivElement> {
5 /** Content rendered inside the banner. */
6 children?: React.ReactNode;
7 /** Additional classes added to the banner. */
8 className?: string;
9 /** If set to true, the banner sticks to the top of its container */
10 isSticky?: boolean;
11 /** If set to true, the banner will have a pill shape */
12 isPill?: boolean;
13 /** Text announced by screen readers to indicate the type of banner. This prop should only
14 * be passed in when the banner conveys status/severity.
15 */
16 screenReaderText?: string;
17 /** Color options for the banner, will be overwritten by any applied using the status prop. */
18 color?: BannerColor;
19 /** Status style options for the banner, will overwrite any color applied using the color prop. */
20 status?: BannerStatus;
21 }
22 interface StatusBanner extends BannerProps {
23 color?: never;
24 status?: BannerStatus;
25 }
26 interface NonStatusBanner extends BannerProps {
27 color?: BannerColor;
28 status?: never;
29 }
30 export declare const Banner: React.FunctionComponent<StatusBanner | NonStatusBanner>;
31 export {};
32 //# sourceMappingURL=Banner.d.ts.map