@devopness/ui-react
Version:
Devopness Design System React Components - Painless essential DevOps to everyone
30 lines (29 loc) • 996 B
TypeScript
import { PropsWithChildren } from 'react';
import { Color } from '../../../colors';
declare const variants: {
readonly white: string;
readonly colored: string;
};
type CoverProps = {
/** Choose between 'white' and 'colored' logos */
logo?: keyof typeof variants;
/** Optional className */
className?: string;
/** Background color */
backgroundColor?: Color;
/** Minimum width at which to show the cover (ex: '600px', '48em', etc) */
minWidth?: string;
};
/**
* A component that renders a cover with a logo and background color.
*
* It only renders when the screen width is greater than or equal to the provided `minWidth`.
*
* @example
* <Cover minWidth="600px" logo="colored">
* <p>Content inside the Cover component</p>
* </Cover>
*/
declare const Cover: ({ className, logo, backgroundColor, minWidth, children, }: PropsWithChildren<CoverProps>) => import("react/jsx-runtime").JSX.Element | null;
export { Cover };
export type { CoverProps };