/* eslint-disable react/no-array-index-key */ import React, { FC, Fragment } from 'react'; type Props = { header?: string | null; content: React.JSX.Element[]; actions?: React.JSX.Element[]; type?: 'warning' | 'attention' | 'confirm' | 'information'; classNames?: string[]; }; const AUNotificationComponent: FC = ({ header = null, content, actions = [], type = 'information', classNames = [], }) => { const typeClass = type === 'information' ? '' : `notification--${type}`; return (
{ header &&

{header}

} {content.map((c, i) => {c})}
{ (actions || []).length > 0 && (
{(actions || []).map((a, i) => {a})}
) }
); }; AUNotificationComponent.displayName = 'AUNotificationComponent'; export default AUNotificationComponent;