(value: string)
| 32 | }, []); |
| 33 | |
| 34 | const handleSelectOption = async (value: string): Promise<void> => { |
| 35 | if (value === 'clipboard') { |
| 36 | // Copy to clipboard immediately |
| 37 | const raw = await setClipboard(content); |
| 38 | if (raw) process.stdout.write(raw); |
| 39 | onDone({ success: true, message: 'Conversation copied to clipboard' }); |
| 40 | } else if (value === 'file') { |
| 41 | setSelectedOption('file'); |
| 42 | setShowFilenameInput(true); |
| 43 | } |
| 44 | }; |
| 45 | |
| 46 | const handleFilenameSubmit = () => { |
| 47 | const finalFilename = filename.endsWith('.txt') ? filename : filename.replace(/\.[^.]+$/, '') + '.txt'; |
no test coverage detected