import React from 'react'; export type DescriptionListLayout = 'horizontal' | 'stacked' | 'row'; export interface DescriptionListProps extends Omit, 'children'> { /** * `horizontal` (default): term beside its value, for a record's details — * it stacks when the list is narrower than 24rem. `stacked`: term above * value, one pair per line, for a narrow column. `row`: stacked pairs side * by side at their own width, wrapping when out of room — a strip of * short facts under a heading. */ layout?: DescriptionListLayout; /** * What an empty value is read as. It is shown as "—", which a screen * reader reads as "dash" or not at all. Default "Not set" — pass the * translation. */ emptyText?: string; /** DescriptionListItem children. */ children: React.ReactNode; } export interface DescriptionListItemProps extends Omit, 'children'> { /** The label — "Owner", "Started". Rendered as the `
`. */ term: React.ReactNode; /** * The value, rendered as the `
`. `null`, `undefined`, `false` or '' * render as an empty value: "—" to the eye, `emptyText` to a reader. */ children?: React.ReactNode; /** Set by the DescriptionList; pass it here only to override one item. */ emptyText?: string; } /** * DescriptionList — label–value pairs: a record's details, a settings * summary, a review step. * * WHY `
` AND NOT A TABLE OR A GRID OF DIVS * * A `
` is the element for name–value groups, and a screen reader says * so: it announces a list with its count, and reads each term with its * value. A two-column table claims rows and columns that nobody compares * down; a grid of `
`s says nothing at all, so "Owner" and "Priya Shah" * arrive as two unrelated lines. Each pair is wrapped in a `
`, which * HTML allows inside a `
`, so the layouts can style a pair as a unit. * * EMPTY IS SAID, NOT DRAWN ONLY * * An unset value is shown as an em dash — the convention every record page * uses — but "—" is read as "dash", or skipped, depending on the reader. * The dash is hidden from assistive technology and `emptyText` is read in * its place, so "Last run: Not set" is heard where "Last run: —" is seen. */ export declare function DescriptionList({ layout, emptyText, className, children, ...rest }: DescriptionListProps): React.JSX.Element; export declare namespace DescriptionList { var displayName: string; } export declare function DescriptionListItem({ term, children, emptyText, className, ...rest }: DescriptionListItemProps): React.JSX.Element; export declare namespace DescriptionListItem { var displayName: string; } //# sourceMappingURL=DescriptionList.d.ts.map