import { a as ToolPart } from './parts-dj7AcUg0.js'; import { T as ToolDisplayMetadata } from './tool-display-z4JcDmMQ.js'; import { T as ToolCategory } from './run-PfLmDAox.js'; import { ClassValue } from 'clsx'; import 'react'; import './message-BHWbxBtT.js'; /** * Copy text to clipboard with a non-secure-context fallback. * Returns true if a copy strategy likely succeeded. */ declare function copyText(text: string): Promise; /** Format a duration in milliseconds to a human-readable string. */ declare function formatDuration(ms: number): string; /** Truncate text to `max` characters, appending "..." if truncated. */ declare function truncateText(text: string, max: number): string; /** * Format an uptime duration in milliseconds with progressive * granularity, so short-lived sandboxes don't render as "0d 0h". * - < 60s → "Ns" * - < 60m → "Nm Ss" * - < 24h → "Nh Mm" * - otherwise → "Nd Hh" */ declare function formatUptime(ms: number): string; /** * Format a byte count using binary units (KiB/MiB/GiB, surfaced as * "KB/MB/GB" for readability). KB and MB use one decimal below 10 and * round above; GB keeps two decimals below 10 so half-GB changes stay * visible on memory dashboards, and drops to one decimal above. */ declare function formatBytes(bytes: number): string; declare function timeAgo(ts: number): string; declare const TOOL_CATEGORY_ICONS: Record; declare function getToolCategory(toolName: string): ToolCategory; declare function getToolDisplayMetadata(part: ToolPart): ToolDisplayMetadata; /** Extract error text from a tool part, if any. */ declare function getToolErrorText(part: ToolPart, fallback?: string): string | undefined; declare function cn(...inputs: ClassValue[]): string; export { TOOL_CATEGORY_ICONS, cn, copyText, formatBytes, formatDuration, formatUptime, getToolCategory, getToolDisplayMetadata, getToolErrorText, timeAgo, truncateText };