import { ComponentProps, ReactNode } from "react"; //#region src/inspector/entity-tab.d.ts /** * One rail tab for an open entity: a bordered `InspectorRailTab` cell * showing the active tab's icon, with a tooltip carrying the full label. * Generic over what "entity" means — the host supplies the icon dispatch * (file type, task status, chat, …) and, for kinds that want it, the * inactive-state glyph; this only owns the cell's shared shape and * affordances. */ export declare const InspectorEntityTab: ({ active, label, glyph, icon, inactiveIcon, onClose, onSelect, ...props }: InspectorEntityTabProps) => import("react").JSX.Element; type InspectorEntityTabPassthroughProps = Omit, "children" | "onAuxClick" | "onClick">; /** * What an inactive tab does to an `icon` it has no `glyph` to swap to. * * `dim` suits a pictorial or coloured mark (status glyph, matter dot, * connector logo): it survives the fade, and the fade is a second inactive * signal after the cell's own spine and fill. `legible` is for an icon that * is itself small type the reader has to decipher, such as a court's * abbreviation chip, where 70% opacity takes two capitals under the contrast * floor and the tab is already marked inactive twice over. */ export type InspectorEntityTabInactiveIcon = "dim" | "legible"; export type InspectorEntityTabProps = { /** Whether this tab is the one currently shown in the pane. Drives the * active spine, and — when `glyph` is given — swaps the cell's content * between `glyph` and `icon`. */ active: boolean; /** Full entity name. Both the button's accessible name and the tooltip * text — the cell itself never has room to show it. */ label: string; /** * Short text shown in the cell instead of `icon` while the tab is * inactive (e.g. a 3-character stem the host derives with * `entityTabGlyph`). Omit it for an entity kind whose icon alone already * identifies it (a status glyph, a colored dot, a logo): `icon` then * renders in both states, dimmed while inactive instead of swapping to * text. */ glyph?: string | undefined; /** Shown in the cell while the tab is active — and, with no `glyph`, * while inactive too (dimmed, unless `inactiveIcon` says otherwise). */ icon: ReactNode; /** How `icon` is drawn while the tab is inactive. Defaults to `dim`. */ inactiveIcon?: InspectorEntityTabInactiveIcon | undefined; /** * Middle-click (`onAuxClick` button 1) closes the tab. A keyboard- and * pointer-reachable close affordance still has to exist — normally a * "Close" item in the host's own context menu, wired to the same * callback — this only covers the middle-click gesture. */ onClose?: (() => void) | undefined; /** Fires on a (contained) left click: activate this tab. */ onSelect?: (() => void) | undefined; } & InspectorEntityTabPassthroughProps; /** * Short abbreviation for a rail tab's inactive glyph: the filename stem, * the first `length` characters; the cell uppercases it. * * A leading dot is part of the name, not an extension separator — a * dotfile's own extension (a second dot further in) still drops, but the * leading dot itself survives into the glyph: `entityTabGlyph(".gitignore")` * is `".gi"`, not `""`. */ export declare const entityTabGlyph: (name: string, length?: number) => string; //#endregion