Debian Codegraph @

node/@patternfly/react-core/dist/esm/components/Drawer/Drawer.d.ts

raw
1 /// <reference types="react" />
2 export declare enum DrawerColorVariant {
3 default = "default",
4 secondary = "secondary",
5 /**
6 * @deprecated `DrawerColorVariant.noBackground` is deprecated. Use the `isPlain` prop on `DrawerPanelContent` and the `DrawerSection`instead.
7 */
8 noBackground = "no-background"
9 }
10 export interface DrawerProps extends React.HTMLProps<HTMLDivElement> {
11 /** Additional classes added to the Drawer. */
12 className?: string;
13 /** Content rendered in the drawer panel */
14 children?: React.ReactNode;
15 /** Indicates if the drawer is expanded */
16 isExpanded?: boolean;
17 /** Indicates if the content element and panel element are displayed side by side. */
18 isInline?: boolean;
19 /** @beta Indicates if the drawer will have pill styles */
20 isPill?: boolean;
21 /** Indicates if the drawer will always show both content and panel. */
22 isStatic?: boolean;
23 /** Position of the drawer panel. left and right are deprecated, use start and end instead. */
24 position?: 'start' | 'end' | 'bottom' | 'left' | 'right';
25 /** Callback when drawer panel is expanded after waiting 250ms for animation to complete. */
26 onExpand?: (event: KeyboardEvent | React.MouseEvent | React.TransitionEvent) => void;
27 }
28 export interface DrawerContextProps {
29 isExpanded: boolean;
30 isStatic: boolean;
31 onExpand?: (event: KeyboardEvent | React.MouseEvent | React.TransitionEvent) => void;
32 position?: string;
33 drawerRef?: React.RefObject<HTMLDivElement | null>;
34 drawerContentRef?: React.RefObject<HTMLDivElement | null>;
35 isInline: boolean;
36 }
37 export declare const DrawerContext: import("react").Context<Partial<DrawerContextProps>>;
38 export declare const Drawer: React.FunctionComponent<DrawerProps>;
39 //# sourceMappingURL=Drawer.d.ts.map