// Copyright 2019-2020 Signal Messenger, LLC // SPDX-License-Identifier: AGPL-3.0-only import * as React from 'react'; import * as classnames from 'classnames'; import * as styles from './Typography.scss'; export type Props = { children: React.ReactNode; }; export type HeadingProps = React.HTMLProps; export type ParagraphProps = React.HTMLProps & { center?: boolean; wide?: boolean; secondary?: boolean; }; export type SpanProps = React.HTMLProps; export const H1 = React.memo( ({ children, className, ...rest }: Props & HeadingProps) => (

{children}

) ); export const H2 = React.memo( ({ children, className, ...rest }: Props & HeadingProps) => (

{children}

) ); export const Text = React.memo( ({ children, className, center, secondary, ...rest }: Props & ParagraphProps) => (

{children}

) ); export const Inline = React.memo( ({ children, className, ...rest }: Props & SpanProps) => ( {children} ) );