@inquirer/select 2.4.4 → 2.4.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/index.js CHANGED
@@ -91,6 +91,9 @@ exports.default = (0, core_1.createPrompt)((config, done) => {
91
91
  }, 700);
92
92
  }
93
93
  });
94
+ (0, core_1.useEffect)(() => () => {
95
+ clearTimeout(searchTimeoutRef.current);
96
+ }, []);
94
97
  const message = theme.style.message(config.message);
95
98
  let helpTipTop = '';
96
99
  let helpTipBottom = '';
@@ -1,4 +1,4 @@
1
- import { createPrompt, useState, useKeypress, usePrefix, usePagination, useRef, useMemo, isBackspaceKey, isEnterKey, isUpKey, isDownKey, isNumberKey, Separator, ValidationError, makeTheme, } from '@inquirer/core';
1
+ import { createPrompt, useState, useKeypress, usePrefix, usePagination, useRef, useMemo, useEffect, isBackspaceKey, isEnterKey, isUpKey, isDownKey, isNumberKey, Separator, ValidationError, makeTheme, } from '@inquirer/core';
2
2
  import colors from 'yoctocolors-cjs';
3
3
  import figures from '@inquirer/figures';
4
4
  import ansiEscapes from 'ansi-escapes';
@@ -84,6 +84,9 @@ export default createPrompt((config, done) => {
84
84
  }, 700);
85
85
  }
86
86
  });
87
+ useEffect(() => () => {
88
+ clearTimeout(searchTimeoutRef.current);
89
+ }, []);
87
90
  const message = theme.style.message(config.message);
88
91
  let helpTipTop = '';
89
92
  let helpTipBottom = '';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/select",
3
- "version": "2.4.4",
3
+ "version": "2.4.5",
4
4
  "description": "Inquirer select/list prompt",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "typings": "./dist/cjs/types/index.d.ts",
@@ -54,7 +54,7 @@
54
54
  "license": "MIT",
55
55
  "homepage": "https://github.com/SBoudrias/Inquirer.js/blob/main/packages/select/README.md",
56
56
  "dependencies": {
57
- "@inquirer/core": "^9.0.7",
57
+ "@inquirer/core": "^9.0.8",
58
58
  "@inquirer/figures": "^1.0.5",
59
59
  "@inquirer/type": "^1.5.1",
60
60
  "ansi-escapes": "^4.3.2",
@@ -88,5 +88,5 @@
88
88
  }
89
89
  },
90
90
  "sideEffects": false,
91
- "gitHead": "b89972b992a65005afd6397b57aa4635010a5ef7"
91
+ "gitHead": "8be69de6107bed7d85a7f2bfe99353d106d9c3bf"
92
92
  }