import { t } from "../../i18n"; import { Box, Text, TextAttributes } from "../../ui"; import { useThemeColors } from "../../theme/theme-context"; import { Button, type ButtonProps } from "./button"; import { DisclosureMarker } from "./disclosure-marker"; export type ActionRowProps = Pick & { /** Text color when the row is neither disabled nor active; team headers use their accent. */ fg?: string; }; /** * A summary row with one action. Put independent actions beside it, not inside it. * * The row is the full width of the list it sits in, so it uses `plain`: a box * around it would read as a control nested inside the surface rather than as * the surface's own header. `active` says unread/changed, which the accent and * weight carry instead of a fill. */ export function ActionRow({ label, children, expanded, active, disabled, fg, ...props }: ActionRowProps) { const colors = useThemeColors(); const foreground = disabled ? colors.textMuted : fg ?? (active ? colors.textBright : colors.text); return ( ); }