@inquirer/select 2.4.4 → 2.4.6
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 +4 -1
- package/dist/esm/index.mjs +5 -2
- package/package.json +5 -5
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 = '';
|
|
@@ -111,7 +114,7 @@ exports.default = (0, core_1.createPrompt)((config, done) => {
|
|
|
111
114
|
if (core_1.Separator.isSeparator(item)) {
|
|
112
115
|
return ` ${item.separator}`;
|
|
113
116
|
}
|
|
114
|
-
const line = item.name || item.value;
|
|
117
|
+
const line = String(item.name || item.value);
|
|
115
118
|
if (item.disabled) {
|
|
116
119
|
const disabledLabel = typeof item.disabled === 'string' ? item.disabled : '(disabled)';
|
|
117
120
|
return theme.style.disabled(`${line} ${disabledLabel}`);
|
package/dist/esm/index.mjs
CHANGED
|
@@ -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 = '';
|
|
@@ -104,7 +107,7 @@ export default createPrompt((config, done) => {
|
|
|
104
107
|
if (Separator.isSeparator(item)) {
|
|
105
108
|
return ` ${item.separator}`;
|
|
106
109
|
}
|
|
107
|
-
const line = item.name || item.value;
|
|
110
|
+
const line = String(item.name || item.value);
|
|
108
111
|
if (item.disabled) {
|
|
109
112
|
const disabledLabel = typeof item.disabled === 'string' ? item.disabled : '(disabled)';
|
|
110
113
|
return theme.style.disabled(`${line} ${disabledLabel}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inquirer/select",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.6",
|
|
4
4
|
"description": "Inquirer select/list prompt",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"typings": "./dist/cjs/types/index.d.ts",
|
|
@@ -54,14 +54,14 @@
|
|
|
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.
|
|
57
|
+
"@inquirer/core": "^9.0.9",
|
|
58
58
|
"@inquirer/figures": "^1.0.5",
|
|
59
|
-
"@inquirer/type": "^1.5.
|
|
59
|
+
"@inquirer/type": "^1.5.2",
|
|
60
60
|
"ansi-escapes": "^4.3.2",
|
|
61
61
|
"yoctocolors-cjs": "^2.1.2"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
|
-
"@inquirer/testing": "^2.1.
|
|
64
|
+
"@inquirer/testing": "^2.1.31"
|
|
65
65
|
},
|
|
66
66
|
"scripts": {
|
|
67
67
|
"tsc": "yarn run tsc:esm && yarn run tsc:cjs",
|
|
@@ -88,5 +88,5 @@
|
|
|
88
88
|
}
|
|
89
89
|
},
|
|
90
90
|
"sideEffects": false,
|
|
91
|
-
"gitHead": "
|
|
91
|
+
"gitHead": "056e26aa6497e0036864d032f9eb8d821de821e7"
|
|
92
92
|
}
|