UNPKG

@amsterdam/design-system-react

Version:

All React components from the Amsterdam Design System. Use it to compose pages in your website or application.

41 lines (40 loc) 1.4 kB
/** * @license EUPL-1.2+ * Copyright (c) 2021 Robbert Broersma * Copyright Gemeente Amsterdam */ import type { LabelHTMLAttributes, PropsWithChildren } from 'react'; import type { HintProps } from '../Hint'; export type LabelProps = { /** * Whether the label is nested inside a fieldset. * This will show the label in a lighter style. */ inFieldSet?: boolean; /** * Render a level 1 heading around the label. * Set this if the Field is the only content of the page. */ isPageHeading?: boolean; } & HintProps & PropsWithChildren<LabelHTMLAttributes<HTMLLabelElement>>; /** * @see {@link https://designsystem.amsterdam/?path=/docs/components-forms-label--docs Label docs at Amsterdam Design System} */ export declare const Label: import("react").ForwardRefExoticComponent<{ /** * Whether the label is nested inside a fieldset. * This will show the label in a lighter style. */ inFieldSet?: boolean; /** * Render a level 1 heading around the label. * Set this if the Field is the only content of the page. */ isPageHeading?: boolean; } & { hint?: string; inFieldSet?: boolean; optional?: boolean; } & import("react").HTMLAttributes<HTMLElement> & { children?: import("react").ReactNode | undefined; } & LabelHTMLAttributes<HTMLLabelElement> & import("react").RefAttributes<HTMLLabelElement>>;