mirror of
https://github.com/pawelmalak/flame.git
synced 2025-07-19 03:29:37 +02:00
13 lines
347 B
TypeScript
13 lines
347 B
TypeScript
import { ReactNode } from 'react';
|
|
import classes from './Message.module.css';
|
|
|
|
interface Props {
|
|
children: ReactNode;
|
|
isPrimary?: boolean;
|
|
}
|
|
|
|
export const Message = ({ children, isPrimary = true }: Props): JSX.Element => {
|
|
const style = isPrimary ? classes.message : classes.messageCenter;
|
|
|
|
return <p className={style}>{children}</p>;
|
|
};
|