rm defunct TitleLevel from SimplePageHeader
@@ -4,7 +4,6 @@ import {
Text,
TextContent,
Title,
- TitleLevel,
TitleProps,
} from '@patternfly/react-core';
import { InfoCircleIcon } from '@patternfly/react-icons';
@@ -18,19 +17,20 @@ export interface ISimplePageHeaderProps {
i18nDescription?: string;
variant?: PageSectionProps['variant'];
titleSize?: TitleProps['size'];
- titleHeadingLevel?: keyof typeof TitleLevel;
+ titleHeadingLevel?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
className?: string;
isTechPreview?: boolean;
i18nTechPreview?: string;
techPreviewPopoverHtml?: React.ReactNode;
}
-export const SimplePageHeader: React.FunctionComponent<ISimplePageHeaderProps> = ({
+export const SimplePageHeader: React.FunctionComponent<ISimplePageHeaderProps> =
+ ({
i18nTitle,
i18nDescription,
variant = 'light',
titleSize = '2xl',
- titleHeadingLevel = TitleLevel.h1,
+ titleHeadingLevel = 'h1',
className,
isTechPreview,
i18nTechPreview,
@@ -46,7 +46,7 @@ export const SimplePageHeader: React.FunctionComponent<ISimplePageHeaderProps> =
<TextContent>
<Title
size={titleSize}
- headingLevel={TitleLevel[titleHeadingLevel]}
+ headingLevel={titleHeadingLevel}
className={
'simple-page-header__title ' +
(isTechPreview ? 'simple-page-header__title_tech-preview' : '')
