UNPKG

@podx/cli

Version:

💻 Command-line interface for PODx - Advanced Twitter/X scraping and crypto analysis toolkit

65 lines (51 loc) 2.81 kB
export function displayBanner(): void { console.log('\n🖥️ PODx v2.0.0 - Advanced X (Twitter) Scraper & Crypto Analysis Tool'); console.log('📊 Use --help for available commands or run without arguments for interactive mode\n'); } export function showWelcomeBanner(): void { console.clear(); // Direct ANSI escape sequences for better compatibility const termWidth = process.stdout.columns || 80; // Clear screen and set black background console.log('\x1b[40m\x1b[37m'); // Black background, white text const podAscii = [ ' ██████╗ ██████╗ ██████╗', ' ██╔══██╗██╔═══██╗██╔══██╗', ' ██████╔╝██║ ██║██║ ██║', ' ██╔═══╝ ██║ ██║██║ ██║', ' ██║ ╚██████╔╝██████╔╝', ' ╚═╝ ╚═════╝ ╚═════╝' ]; // Top border const topBorder = '╔' + '═'.repeat(termWidth - 2) + '╗'; console.log('\x1b[31m' + topBorder + '\x1b[37m'); // Red border // Black background bar const blackBar = '\x1b[40m' + ' '.repeat(termWidth - 2) + '\x1b[37m'; console.log('\x1b[31m║\x1b[37m' + blackBar + '\x1b[31m║\x1b[37m'); // POD ASCII Art centered podAscii.forEach(line => { const padding = Math.floor((termWidth - line.length - 2) / 2); const leftPad = ' '.repeat(Math.max(0, padding)); const rightPad = ' '.repeat(Math.max(0, termWidth - line.length - 2 - padding)); console.log('\x1b[31m║\x1b[37m' + leftPad + '\x1b[31m' + line + '\x1b[37m' + rightPad + '\x1b[31m║\x1b[37m'); }); console.log('\x1b[31m║\x1b[37m' + blackBar + '\x1b[31m║\x1b[37m'); // Title lines const titleLines: Array<[string, string]> = [ ['🔥 PROMPT OR DIE 🔥', '\x1b[31m'], // Red ['🚀 POD-SCRAPE v2.0.0 🚀', '\x1b[35m'], // Magenta ['Ultimate X (Twitter) Scraper CLI', '\x1b[36m'], // Cyan ['⚡ Built for the fearless scrapers ⚡', '\x1b[33m'] // Yellow ]; titleLines.forEach(([line, color]) => { const padding = Math.floor((termWidth - line.length - 2) / 2); const leftPad = ' '.repeat(Math.max(0, padding)); const rightPad = ' '.repeat(Math.max(0, termWidth - line.length - 2 - padding)); console.log('\x1b[31m║\x1b[37m' + leftPad + color + line + '\x1b[37m' + rightPad + '\x1b[31m║\x1b[37m'); }); console.log('\x1b[31m║\x1b[37m' + blackBar + '\x1b[31m║\x1b[37m'); // Bottom border const bottomBorder = '╚' + '═'.repeat(termWidth - 2) + '╝'; console.log('\x1b[31m' + bottomBorder + '\x1b[0m'); console.log('\n\x1b[37m💀 Interactive Mode: Use ↑↓ arrows to navigate • Press Enter to select\x1b[0m\n'); }