/** * Condensed budget card for a homepage column: one ring gauge per * enforcement level (key → personal → team), each showing the limit nearest * its cap. Where the full `LiteLLMBudgetWidget` lists every limit as a * spend-vs-cap meter, this trades detail for density — a single row of rings * with a label and spend figure under each. * * Gauges are always rendered in the same order, with an empty ring when the * user has no cap at that level, so the card keeps a stable shape as data * loads and across users. When a level holds several limits, the ring shows * the one closest to its cap and a "+N more" link counts the rest. * * The bottom action bar is composable: pass any subset of `ctas` — mint a new * key, open the LiteLLM module, or expand the full per-limit list in place — * in the order you want. `action` remains an escape hatch for a fully custom * node; when either is present it renders below a divider. */ import React from 'react'; /** Preset action-bar buttons. `label` overrides the default copy. */ export type BudgetCtaKind = 'new-key' | 'module' | 'all-limits'; export interface BudgetCtaSpec { kind: BudgetCtaKind; /** Override the default label. */ label?: string; } /** Either a bare kind (`'module'`) or a spec object (`{ kind: 'module' }`). */ export type BudgetCta = BudgetCtaKind | BudgetCtaSpec; export interface LiteLLMBudgetGaugesProps { /** Optional title override. Defaults to 'Budget'. */ title?: string; /** Ring diameter in px. Defaults to 72. */ size?: number; /** Where the "+N more" key link points. Defaults to the Keys tab. */ keysHref?: string; /** Where the module CTA points. Defaults to the LiteLLM page. */ moduleHref?: string; /** * Called when the "new key" CTA is used. When omitted, the CTA deep-links * to the module with `?generate=1`, which opens the generate-key dialog. */ onCreateKey?: () => void; /** * Action-bar buttons to render, in order. Defaults to * `['new-key', 'module', 'all-limits']`. Pass `[]` to hide the bar; the * `all-limits` entry is dropped automatically when the user has no limits. */ ctas?: BudgetCta[]; /** Max key limits listed in the expanded view. Defaults to 8. */ maxExpandedKeys?: number; /** Controlled expanded state for the all-limits view. */ expanded?: boolean; /** Initial expanded state when uncontrolled. Defaults to false. */ defaultExpanded?: boolean; /** Notified whenever the expanded state changes. */ onExpandedChange?: (expanded: boolean) => void; /** Fully custom node pinned below the CTAs, below a divider. */ action?: React.ReactNode; } export declare const LiteLLMBudgetGauges: React.FC;