UNPKG

caravan-x

Version:

A terminal-based utility for managing Caravan multisig wallets in regtest mode. This tool simplifies development and testing with Caravan by providing an easy-to-use interface

93 lines (92 loc) 2.79 kB
import { Ora } from "ora"; /** * Consistent color scheme for the application */ export declare const colors: { primary: import("chalk").ChalkInstance; secondary: import("chalk").ChalkInstance; accent: import("chalk").ChalkInstance; success: import("chalk").ChalkInstance; warning: import("chalk").ChalkInstance; error: import("chalk").ChalkInstance; info: import("chalk").ChalkInstance; muted: import("chalk").ChalkInstance; header: import("chalk").ChalkInstance; commandName: import("chalk").ChalkInstance; subtle: import("chalk").ChalkInstance; highlight: import("chalk").ChalkInstance; bitcoin: import("chalk").ChalkInstance; code: import("chalk").ChalkInstance; }; /** * ASCII art logo for Caravan */ export declare const caravanLogo: string; /** * Format numbers with commas for better readability */ export declare function formatNumber(num: number): string; /** * Format Bitcoin amounts with appropriate precision */ export declare function formatBitcoin(amount: number): string; /** * Truncate strings like transaction IDs or hashes for display */ export declare function truncate(str: string, length?: number): string; /** * Create a simple box around text */ export declare function boxText(text: string, options?: { padding?: number; title?: string; titleColor?: chalk.Chalk; }): string; /** * Display a command title with consistent formatting */ export declare function displayCommandTitle(title: string): void; /** * Clear the terminal */ export declare function clearScreen(): void; /** * Create a table with column headers */ export declare function createTable(headers: string[], rows: string[][]): string; /** * Format progress bar */ export declare function progressBar(percent: number, width?: number): string; /** * Update a spinner with progress information */ export declare function updateSpinnerProgress(spinner: Ora, current: number, total: number, message: string): void; /** * Paginate text output for display */ export declare function paginateOutput(text: string, pageSize?: number): string[]; /** * Get terminal width */ export declare function getTerminalWidth(): number; /** * Create a horizontal divider */ export declare function divider(char?: string, color?: chalk.Chalk): string; /** * Display key-value information in a formatted way */ export declare function keyValue(key: string, value: string | number): string; /** * Format warnings in a consistent way */ export declare function formatWarning(message: string): string; /** * Format errors in a consistent way */ export declare function formatError(message: string): string; /** * Format success messages in a consistent way */ export declare function formatSuccess(message: string): string;