mirror of
https://github.com/pawelmalak/flame.git
synced 2025-07-28 15:19:36 +02:00
18 lines
430 B
TypeScript
18 lines
430 B
TypeScript
|
import { Fragment } from 'react';
|
||
|
import classes from './Headline.module.css';
|
||
|
|
||
|
interface ComponentProps {
|
||
|
title: string;
|
||
|
subtitle?: string;
|
||
|
}
|
||
|
|
||
|
const Headline = (props: ComponentProps): JSX.Element => {
|
||
|
return (
|
||
|
<Fragment>
|
||
|
<h2 className={classes.HeadlineTitle}>{props.title}</h2>
|
||
|
{props.subtitle && <p className={classes.HeadlineSubtitle}>{props.subtitle}</p>}
|
||
|
</Fragment>
|
||
|
)
|
||
|
}
|
||
|
|
||
|
export default Headline;
|