import React, { HTMLAttributes } from "react"; import ErrorSummaryItem from "./ErrorSummaryItem"; export interface ErrorSummaryProps extends Omit, "tabIndex"> { /** * Collection of `ErrorSummary.Item`. */ children: React.ReactNode; /** * Changes padding and font-sizes. * @default "medium" */ size?: "medium" | "small"; /** * Heading above links. * @default "Du må rette disse feilene før du kan fortsette:" */ heading?: React.ReactNode; /** * Allows setting a different HTML h-tag. * @default "h2" */ headingTag?: React.ElementType; } interface ErrorSummaryComponent extends React.ForwardRefExoticComponent> { /** * Error message with link to field. * * @see [🤖 OverridableComponent](https://aksel.nav.no/grunnleggende/kode/overridablecomponent) support * * @example * ```jsx * * Felt må fylles ut med alder * * ``` */ Item: typeof ErrorSummaryItem; } /** * Summary of errors in a form. * * @see [📝 Documentation](https://aksel.nav.no/komponenter/core/errorsummary) * @see 🏷️ {@link ErrorSummaryProps} * * @example * ```jsx * * * Felt må fylles ut med alder * * * Tekstfeltet må ha en godkjent e-post * * * ``` */ export declare const ErrorSummary: ErrorSummaryComponent; export default ErrorSummary;