@engie-group/fluid-design-system-react
Version:
Fluid Design System React
49 lines (48 loc) • 1.5 kB
TypeScript
import React, { ComponentPropsWithoutRef, PropsWithChildren } from 'react';
import './NJSidepanelHeader.scss';
export type NJSidepanelHeaderProps = ComponentPropsWithoutRef<'div'> & PropsWithChildren & {
/**
* Header title
*/
title?: string;
/**
* Custom title content. Will not be rendered if `title` property is provided.
*/
children?: React.ReactNode;
/**
* Close icon text alternative for assistive technologies
*/
closeIconLabel?: string;
/**
* Function called on close button click
*/
onCloseIconClicked?: React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>;
/**
* Sidepanel actions
*/
actions?: React.ReactNode[];
};
export declare const NJSidepanelHeader: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
children?: React.ReactNode | undefined;
} & {
/**
* Header title
*/
title?: string;
/**
* Custom title content. Will not be rendered if `title` property is provided.
*/
children?: React.ReactNode;
/**
* Close icon text alternative for assistive technologies
*/
closeIconLabel?: string;
/**
* Function called on close button click
*/
onCloseIconClicked?: React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>;
/**
* Sidepanel actions
*/
actions?: React.ReactNode[];
} & React.RefAttributes<HTMLDivElement>>;