UNPKG

@dnanpm/styleguide

Version:

DNA Styleguide repository provides the set of components and theme object used in various DNA projects.

32 lines (31 loc) 842 B
import type { ReactNode } from 'react'; import React from 'react'; type LabelType = 'campaign' | 'new' | 'presale' | 'other'; type HeadingLevel = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'; interface Props { /** * Enables the Label component to be rendered as a heading element * * @default 'span' */ headingLevel?: HeadingLevel; /** * Allows to change the background color of component */ type: LabelType; /** * Content of Label component */ children?: ReactNode; /** * Allows to pass a custom className */ className?: string; /** * Allows to pass testid string for testing purposes */ 'data-testid'?: string; } declare const Label: ({ "data-testid": dataTestId, ...props }: Props) => React.JSX.Element; /** @component */ export default Label;