import { ReactNode } from "react"; /** One row in the MoreItems popover grid — id, label and an optional dot color. */ export interface MoreItem { /** React key for the row; not shown or emitted. */ id: string | number; /** Row text, truncated with an ellipsis when it overflows the column. */ label: string; /** Optional leading dot color. Falls back to colorResolver or a neutral gray. */ color?: string; } /** Full trigger + popover configuration for MoreItems — see MoreItem for the shape of each listed row. */ export interface MoreItemsProps { /** Items shown inside the popover. */ items: MoreItem[]; /** Defaults to items.length; ≤0 either way hides the trigger, falling back to bare triggerText or null. */ moreCount?: number; /** Text shown before the "+N more" pill (e.g. the first visible value). */ triggerText?: ReactNode; /** Only runs when item.color is unset — item.color always wins over this resolver. */ colorResolver?: (item: MoreItem) => string | undefined; /** Hide the colored leading dot entirely. */ hideDots?: boolean; /** Columns inside the popover grid. */ columns?: number; /** Min width of the popover panel. */ minWidth?: string; /** Max width of the trigger before truncation. */ triggerMaxWidth?: string; /** Open on "hover" (default) or "click". */ trigger?: "hover" | "click"; /** Popover placement. */ placement?: "bottom-start" | "bottom-end" | "bottom" | "top" | "right" | "left"; }