1 | /// <reference types="node" />
|
2 | /// <reference types="react" />
|
3 | export interface Props {
|
4 | /**
|
5 | * Stdin stream passed to `render()` in `options.stdin` or `process.stdin` by default. Useful if your app needs to handle user input.
|
6 | */
|
7 | readonly stdin?: NodeJS.ReadStream;
|
8 | /**
|
9 | * Ink exposes this function via own `<StdinContext>` to be able to handle Ctrl+C, that's why you should use Ink's `setRawMode` instead of `process.stdin.setRawMode`.
|
10 | * If the `stdin` stream passed to Ink does not support setRawMode, this function does nothing.
|
11 | */
|
12 | readonly setRawMode: (value: boolean) => void;
|
13 | /**
|
14 | * A boolean flag determining if the current `stdin` supports `setRawMode`. A component using `setRawMode` might want to use `isRawModeSupported` to nicely fall back in environments where raw mode is not supported.
|
15 | */
|
16 | readonly isRawModeSupported: boolean;
|
17 | readonly internal_exitOnCtrlC: boolean;
|
18 | }
|
19 | /**
|
20 | * `StdinContext` is a React context, which exposes input stream.
|
21 | */
|
22 | declare const StdinContext: import("react").Context<Props>;
|
23 | export default StdinContext;
|