(options: AutoCompleteOptionsReq<A>)
| 3618 | }) |
| 3619 | |
| 3620 | const handleAutoCompleteClear = <A>(options: AutoCompleteOptionsReq<A>) => |
| 3621 | Effect.fnUntraced(function*(state: AutoCompleteState, _: Action<AutoCompleteState, A>) { |
| 3622 | const terminal = yield* Terminal.Terminal |
| 3623 | const columns = yield* terminal.columns |
| 3624 | const figures = yield* getTheme(options) |
| 3625 | const clearPrompt = Ansi.eraseLine + Ansi.cursorLeft |
| 3626 | const promptText = renderAutoCompleteOutput( |
| 3627 | state, |
| 3628 | figures.prefix, |
| 3629 | figures.pointerSmall, |
| 3630 | options, |
| 3631 | figures, |
| 3632 | { plain: true } |
| 3633 | ) |
| 3634 | const choicesText = renderAutoCompleteChoices(state, options, figures, { plain: true }) |
| 3635 | const clearOutput = eraseText(`${promptText}\n${choicesText}`, columns) |
| 3636 | return clearOutput + clearPrompt |
| 3637 | }) |
| 3638 | |
| 3639 | const handleSelectProcess = <A>(options: SelectOptionsReq<A>) => { |
| 3640 | return (input: Terminal.UserInput, state: SelectState) => { |
no test coverage detected