import "./back_button.css"; import type * as React from "react"; import { Button as Base } from "@base-ui/react/button"; import { type StyleProps, type TriggerProps } from "./style_props"; export interface BackButtonProps extends StyleProps, TriggerProps { onPress?: (event: React.MouseEvent) => void; /** Names where back GOES ("Orders", "Danh sách"). Renders beside the circular * glyph as part of the SAME control — a label you can't press is a lie. Omit * for the bare glyph. */ label?: string; /** Accessible name. Defaults to `label`, else the locale's `nav.back` * ("Back" / "Quay lại"). */ accessibilityLabel?: string; testID?: string; ref?: React.Ref; render?: Base.Props["render"]; } /** * THE go-back control: a circular glyph that leaves the current screen or panel, * optionally naming where it goes. * * It is one purpose, so it takes no size or colour — a caller reaching for those * wants a different control. In particular a drawer header's small inline arrow * is NOT this: that sits beside a title inside a header row, where a 40px disc * would outweigh the name it belongs to. That one is an `IconButton`, and the * distinction is prominence — this one HEADS a surface, that one annotates a * title. * * THE DISC IS A PART, not a nested control. The labelled form is ONE pressable * over the disc AND the words, so an `IconButton` inside it would be a button * nested in a button — which is why the circle was hand-rolled beside one, with * that component's spec restated in a comment. A spec copied into a comment is a * spec that drifts; the disc's rules are in `back_button.css` and belong to this * component alone. * * IT BORROWS NOTHING FROM ANOTHER CONTROL. Its glyph ink is zinc-900 because * that is what this glyph is, not because a secondary button happens to be that * colour today — tying the two means a change to the button palette silently * restyles the back affordance for a reason nobody would connect. The one thing * it does share is the BAND height, which is the system's promise that every * 40px control lines up. */ export declare function BackButton(props: BackButtonProps): React.JSX.Element;