import "./callout.css"; import type * as React from "react"; import { Button as Base } from "@base-ui/react/button"; import { useRender } from "@base-ui/react/use-render"; import { type IconName } from "./icon"; import { type StyleProps } from "./style_props"; export type CalloutTone = "info" | "success" | "warning" | "error" | "neutral"; interface CalloutProps extends StyleProps { /** Default "info". */ tone?: CalloutTone; /** `null` drops it. */ icon?: IconName | null; children: React.ReactNode; testID?: string; ref?: React.Ref; render?: useRender.RenderProp; } /** * An inline status box (info / success / warning / error / neutral) inside a flow: form feedback, a * heads-up, a failure. A dead region is a `RegionState`; a blocking prompt `Alert`; a one-word * status `Status`. Tone is icon, tint and border, never colour alone. The body is a title — the * message, in the callout's emphasis — with an optional muted `CalloutDescription` under it; several * pairs may stack, then `CalloutActions`, or a `CalloutLink` to the place that clears it. The icon stands on * the first title's line. */ export declare function Callout({ tone, icon, children, testID, render, ref, ...props }: CalloutProps): React.ReactElement>; export interface CalloutTitleProps extends StyleProps { children: React.ReactNode; ref?: React.Ref; render?: useRender.RenderProp; } /** The message: the callout's emphasis, a weight above its description. A one-line callout is its title. */ export declare function CalloutTitle({ children, render, ref, ...props }: CalloutTitleProps): React.JSX.Element; export interface CalloutDescriptionProps extends StyleProps { children: React.ReactNode; ref?: React.Ref; render?: useRender.RenderProp; } /** What the title means for the reader — what it refuses, what to do — muted, directly under its title. */ export declare function CalloutDescription({ children, render, ref, ...props }: CalloutDescriptionProps): React.JSX.Element; export interface CalloutActionsProps extends StyleProps { children: React.ReactNode; ref?: React.Ref; render?: useRender.RenderProp; } export declare function CalloutActions({ children, render, ref, ...props }: CalloutActionsProps): React.ReactElement>; export interface CalloutLinkProps extends StyleProps { /** The name of what it leads to — an act's verb. */ children: string; /** The id of the place it lands on, elsewhere on the screen. */ target: string; testID?: string; ref?: React.Ref; /** Substitutes the link's element. */ render?: Base.Props["render"]; } /** * A quiet way from what the callout says to the place that clears it — "Xuất hóa đơn →", in link ink under * its words. Pressed, it brings that place into view and rings it (`landOn`) — drawn first where its frame holds * it undrawn, a drawer's field in another tab; it never acts itself, so a callout at the top of a page carries no * button that writes. Nothing lands where no element holds the id. */ export declare function CalloutLink({ children, target, testID, ref, render, ...props }: CalloutLinkProps): React.JSX.Element; export type { CalloutProps };