lambda-live-debugger 1.12.7 → 1.12.8

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.
Files changed (308) hide show
  1. package/dist/extension/extension.zip +0 -0
  2. package/dist/extension/nodejs/node_modules/interceptor.js +258 -47
  3. package/dist/extension/nodejs/node_modules/interceptor.js.map +4 -4
  4. package/node_modules/@aws-sdk/checksums/package.json +5 -5
  5. package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/index.js +1 -1
  6. package/node_modules/@aws-sdk/client-cloudformation/package.json +8 -8
  7. package/node_modules/@aws-sdk/client-iam/dist-cjs/index.js +1 -1
  8. package/node_modules/@aws-sdk/client-iam/package.json +9 -9
  9. package/node_modules/@aws-sdk/client-iot/dist-cjs/index.js +71 -9
  10. package/node_modules/@aws-sdk/client-iot/dist-es/models/enums.js +14 -0
  11. package/node_modules/@aws-sdk/client-iot/dist-es/schemas/schemas_0.js +49 -8
  12. package/node_modules/@aws-sdk/client-iot/dist-types/commands/AttachSecurityProfileCommand.d.ts +4 -1
  13. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CancelDetectMitigationActionsTaskCommand.d.ts +4 -1
  14. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CreateCustomMetricCommand.d.ts +4 -1
  15. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CreateDimensionCommand.d.ts +4 -1
  16. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CreateSecurityProfileCommand.d.ts +4 -1
  17. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CreateTopicRuleCommand.d.ts +34 -0
  18. package/node_modules/@aws-sdk/client-iot/dist-types/commands/CreateTopicRuleDestinationCommand.d.ts +14 -0
  19. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeleteCustomMetricCommand.d.ts +4 -1
  20. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeleteDimensionCommand.d.ts +4 -1
  21. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeleteSecurityProfileCommand.d.ts +4 -1
  22. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeleteTopicRuleDestinationCommand.d.ts +2 -1
  23. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeleteV2LoggingLevelCommand.d.ts +1 -1
  24. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DeprecateThingTypeCommand.d.ts +1 -1
  25. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DescribeCustomMetricCommand.d.ts +4 -1
  26. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DescribeDetectMitigationActionsTaskCommand.d.ts +4 -1
  27. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DescribeDimensionCommand.d.ts +4 -1
  28. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DescribeSecurityProfileCommand.d.ts +4 -1
  29. package/node_modules/@aws-sdk/client-iot/dist-types/commands/DetachSecurityProfileCommand.d.ts +4 -1
  30. package/node_modules/@aws-sdk/client-iot/dist-types/commands/GetBehaviorModelTrainingSummariesCommand.d.ts +4 -1
  31. package/node_modules/@aws-sdk/client-iot/dist-types/commands/GetTopicRuleCommand.d.ts +34 -0
  32. package/node_modules/@aws-sdk/client-iot/dist-types/commands/GetTopicRuleDestinationCommand.d.ts +7 -0
  33. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListActiveViolationsCommand.d.ts +4 -1
  34. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListCustomMetricsCommand.d.ts +4 -1
  35. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListDetectMitigationActionsExecutionsCommand.d.ts +4 -1
  36. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListDetectMitigationActionsTasksCommand.d.ts +4 -1
  37. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListDimensionsCommand.d.ts +4 -1
  38. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListSecurityProfilesCommand.d.ts +4 -1
  39. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListSecurityProfilesForTargetCommand.d.ts +4 -1
  40. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListStreamsCommand.d.ts +2 -1
  41. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListTagsForResourceCommand.d.ts +1 -1
  42. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListTargetsForPolicyCommand.d.ts +1 -2
  43. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListTargetsForSecurityProfileCommand.d.ts +4 -1
  44. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListTopicRuleDestinationsCommand.d.ts +7 -0
  45. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ListViolationEventsCommand.d.ts +4 -1
  46. package/node_modules/@aws-sdk/client-iot/dist-types/commands/PutVerificationStateOnViolationCommand.d.ts +4 -1
  47. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ReplaceTopicRuleCommand.d.ts +34 -0
  48. package/node_modules/@aws-sdk/client-iot/dist-types/commands/StartDetectMitigationActionsTaskCommand.d.ts +4 -1
  49. package/node_modules/@aws-sdk/client-iot/dist-types/commands/UpdateCustomMetricCommand.d.ts +4 -1
  50. package/node_modules/@aws-sdk/client-iot/dist-types/commands/UpdateDimensionCommand.d.ts +4 -1
  51. package/node_modules/@aws-sdk/client-iot/dist-types/commands/UpdateSecurityProfileCommand.d.ts +4 -1
  52. package/node_modules/@aws-sdk/client-iot/dist-types/commands/ValidateSecurityProfileBehaviorsCommand.d.ts +4 -1
  53. package/node_modules/@aws-sdk/client-iot/dist-types/models/enums.d.ts +38 -0
  54. package/node_modules/@aws-sdk/client-iot/dist-types/models/models_0.d.ts +195 -45
  55. package/node_modules/@aws-sdk/client-iot/dist-types/models/models_1.d.ts +46 -69
  56. package/node_modules/@aws-sdk/client-iot/dist-types/models/models_2.d.ts +112 -2
  57. package/node_modules/@aws-sdk/client-iot/dist-types/schemas/schemas_0.d.ts +5 -0
  58. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/DeleteTopicRuleDestinationCommand.d.ts +2 -4
  59. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/DeleteV2LoggingLevelCommand.d.ts +1 -1
  60. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/DeprecateThingTypeCommand.d.ts +1 -1
  61. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/ListStreamsCommand.d.ts +2 -1
  62. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +1 -1
  63. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/commands/ListTargetsForPolicyCommand.d.ts +1 -2
  64. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/models/enums.d.ts +18 -0
  65. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/models/models_0.d.ts +36 -11
  66. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/models/models_1.d.ts +11 -18
  67. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/models/models_2.d.ts +28 -0
  68. package/node_modules/@aws-sdk/client-iot/dist-types/ts3.4/schemas/schemas_0.d.ts +5 -0
  69. package/node_modules/@aws-sdk/client-iot/package.json +8 -8
  70. package/node_modules/@aws-sdk/client-iot-data-plane/dist-cjs/index.js +1 -1
  71. package/node_modules/@aws-sdk/client-iot-data-plane/package.json +8 -8
  72. package/node_modules/@aws-sdk/client-lambda/README.md +21 -0
  73. package/node_modules/@aws-sdk/client-lambda/dist-cjs/index.js +83 -3
  74. package/node_modules/@aws-sdk/client-lambda/dist-es/Lambda.js +6 -0
  75. package/node_modules/@aws-sdk/client-lambda/dist-es/commands/DeleteResourcePolicyCommand.js +4 -0
  76. package/node_modules/@aws-sdk/client-lambda/dist-es/commands/GetResourcePolicyCommand.js +4 -0
  77. package/node_modules/@aws-sdk/client-lambda/dist-es/commands/PutResourcePolicyCommand.js +4 -0
  78. package/node_modules/@aws-sdk/client-lambda/dist-es/commands/index.js +3 -0
  79. package/node_modules/@aws-sdk/client-lambda/dist-es/models/enums.js +5 -0
  80. package/node_modules/@aws-sdk/client-lambda/dist-es/schemas/schemas_0.js +52 -2
  81. package/node_modules/@aws-sdk/client-lambda/dist-types/Lambda.d.ts +21 -0
  82. package/node_modules/@aws-sdk/client-lambda/dist-types/LambdaClient.d.ts +5 -2
  83. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/AddPermissionCommand.d.ts +1 -1
  84. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/CreateFunctionCommand.d.ts +6 -0
  85. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/DeleteResourcePolicyCommand.d.ts +88 -0
  86. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetFunctionCommand.d.ts +3 -0
  87. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetFunctionConfigurationCommand.d.ts +3 -0
  88. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetProvisionedConcurrencyConfigCommand.d.ts +4 -4
  89. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/GetResourcePolicyCommand.d.ts +84 -0
  90. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/ListFunctionsCommand.d.ts +3 -0
  91. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/ListVersionsByFunctionCommand.d.ts +3 -0
  92. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/PublishVersionCommand.d.ts +3 -0
  93. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/PutResourcePolicyCommand.d.ts +98 -0
  94. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/RemovePermissionCommand.d.ts +1 -1
  95. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/UpdateFunctionCodeCommand.d.ts +3 -0
  96. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/UpdateFunctionConfigurationCommand.d.ts +6 -0
  97. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/index.d.ts +3 -0
  98. package/node_modules/@aws-sdk/client-lambda/dist-types/models/enums.d.ts +13 -0
  99. package/node_modules/@aws-sdk/client-lambda/dist-types/models/errors.d.ts +1 -1
  100. package/node_modules/@aws-sdk/client-lambda/dist-types/models/models_0.d.ts +95 -4
  101. package/node_modules/@aws-sdk/client-lambda/dist-types/schemas/schemas_0.d.ts +9 -0
  102. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/Lambda.d.ts +51 -0
  103. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/LambdaClient.d.ts +18 -0
  104. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/commands/DeleteResourcePolicyCommand.d.ts +38 -0
  105. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/commands/GetResourcePolicyCommand.d.ts +39 -0
  106. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/commands/PutResourcePolicyCommand.d.ts +39 -0
  107. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/commands/index.d.ts +3 -0
  108. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/models/enums.d.ts +6 -0
  109. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/models/models_0.d.ts +25 -0
  110. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/schemas/schemas_0.d.ts +9 -0
  111. package/node_modules/@aws-sdk/client-lambda/package.json +9 -9
  112. package/node_modules/@aws-sdk/client-s3/dist-cjs/index.js +1 -1
  113. package/node_modules/@aws-sdk/client-s3/package.json +13 -13
  114. package/node_modules/@aws-sdk/core/package.json +5 -5
  115. package/node_modules/@aws-sdk/credential-provider-cognito-identity/package.json +5 -5
  116. package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
  117. package/node_modules/@aws-sdk/credential-provider-http/package.json +7 -7
  118. package/node_modules/@aws-sdk/credential-provider-ini/package.json +12 -12
  119. package/node_modules/@aws-sdk/credential-provider-login/package.json +6 -6
  120. package/node_modules/@aws-sdk/credential-provider-node/dist-cjs/index.js +2 -0
  121. package/node_modules/@aws-sdk/credential-provider-node/dist-es/runtime/memoize-chain.js +2 -0
  122. package/node_modules/@aws-sdk/credential-provider-node/package.json +10 -10
  123. package/node_modules/@aws-sdk/credential-provider-process/package.json +5 -5
  124. package/node_modules/@aws-sdk/credential-provider-sso/package.json +7 -7
  125. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +6 -6
  126. package/node_modules/@aws-sdk/credential-providers/package.json +15 -15
  127. package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +6 -6
  128. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +1 -1
  129. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +1 -1
  130. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +1 -1
  131. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +1 -1
  132. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +1 -1
  133. package/node_modules/@aws-sdk/nested-clients/package.json +8 -8
  134. package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +3 -3
  135. package/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +8 -4
  136. package/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +8 -4
  137. package/node_modules/@aws-sdk/token-providers/package.json +6 -6
  138. package/node_modules/@aws-sdk/types/package.json +2 -2
  139. package/node_modules/@aws-sdk/xml-builder/package.json +2 -2
  140. package/node_modules/@inquirer/ansi/package.json +3 -2
  141. package/node_modules/@inquirer/checkbox/dist/index.d.ts +12 -1
  142. package/node_modules/@inquirer/checkbox/package.json +7 -6
  143. package/node_modules/@inquirer/confirm/README.md +23 -0
  144. package/node_modules/@inquirer/confirm/dist/index.d.ts +27 -3
  145. package/node_modules/@inquirer/confirm/dist/index.js +40 -14
  146. package/node_modules/@inquirer/confirm/package.json +5 -4
  147. package/node_modules/@inquirer/core/README.md +9 -3
  148. package/node_modules/@inquirer/core/dist/lib/create-prompt.d.ts +10 -3
  149. package/node_modules/@inquirer/core/dist/lib/hook-engine.d.ts +2 -8
  150. package/node_modules/@inquirer/core/dist/lib/make-theme.js +1 -0
  151. package/node_modules/@inquirer/core/dist/lib/pagination/use-pagination.d.ts +2 -3
  152. package/node_modules/@inquirer/core/dist/lib/theme.d.ts +1 -1
  153. package/node_modules/@inquirer/core/dist/lib/use-memo.js +1 -1
  154. package/node_modules/@inquirer/core/dist/lib/use-state.d.ts +5 -2
  155. package/node_modules/@inquirer/core/dist/lib/use-state.js +7 -2
  156. package/node_modules/@inquirer/core/package.json +7 -6
  157. package/node_modules/@inquirer/editor/dist/index.d.ts +10 -2
  158. package/node_modules/@inquirer/editor/package.json +6 -5
  159. package/node_modules/@inquirer/expand/README.md +1 -1
  160. package/node_modules/@inquirer/expand/dist/index.d.ts +12 -1
  161. package/node_modules/@inquirer/expand/package.json +5 -4
  162. package/node_modules/@inquirer/external-editor/README.md +13 -0
  163. package/node_modules/@inquirer/external-editor/package.json +4 -3
  164. package/node_modules/@inquirer/figures/package.json +4 -3
  165. package/node_modules/@inquirer/input/dist/index.d.ts +13 -1
  166. package/node_modules/@inquirer/input/package.json +5 -4
  167. package/node_modules/@inquirer/number/dist/index.d.ts +12 -2
  168. package/node_modules/@inquirer/number/dist/index.js +1 -6
  169. package/node_modules/@inquirer/number/dist/is-step-of.d.ts +1 -0
  170. package/node_modules/@inquirer/number/dist/is-step-of.js +22 -0
  171. package/node_modules/@inquirer/number/package.json +5 -4
  172. package/node_modules/@inquirer/password/README.md +24 -6
  173. package/node_modules/@inquirer/password/dist/index.d.ts +9 -1
  174. package/node_modules/@inquirer/password/dist/index.js +27 -8
  175. package/node_modules/@inquirer/password/package.json +6 -5
  176. package/node_modules/@inquirer/prompts/README.md +67 -7
  177. package/node_modules/@inquirer/prompts/package.json +14 -13
  178. package/node_modules/@inquirer/rawlist/dist/index.d.ts +8 -1
  179. package/node_modules/@inquirer/rawlist/package.json +5 -4
  180. package/node_modules/@inquirer/search/README.md +9 -8
  181. package/node_modules/@inquirer/search/dist/index.d.ts +13 -1
  182. package/node_modules/@inquirer/search/dist/index.js +6 -1
  183. package/node_modules/@inquirer/search/package.json +6 -5
  184. package/node_modules/@inquirer/select/dist/index.d.ts +9 -1
  185. package/node_modules/@inquirer/select/package.json +7 -6
  186. package/node_modules/@inquirer/type/dist/utils.d.ts +8 -3
  187. package/node_modules/@inquirer/type/package.json +3 -2
  188. package/node_modules/@smithy/core/CHANGELOG.md +7 -0
  189. package/node_modules/@smithy/core/dist-cjs/index.js +3 -1
  190. package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +126 -39
  191. package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +14 -3
  192. package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.browser.js +3 -1
  193. package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.js +3 -1
  194. package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.browser.js +10 -1
  195. package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +10 -1
  196. package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +16 -2
  197. package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.browser.js +4 -1
  198. package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.js +4 -1
  199. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +4 -1
  200. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +4 -1
  201. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +4 -1
  202. package/node_modules/@smithy/core/dist-cjs/submodules/transport/index.js +7 -0
  203. package/node_modules/@smithy/core/dist-es/legacy-root-exports/util-identity-and-auth/DefaultIdentityProviderConfig.js +3 -0
  204. package/node_modules/@smithy/core/dist-es/submodules/cbor/cbor-decode.js +29 -13
  205. package/node_modules/@smithy/core/dist-es/submodules/cbor/cbor-encode.js +12 -4
  206. package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v1/CborShapeDeserializer.js +9 -0
  207. package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v1/CborShapeSerializer.js +7 -0
  208. package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v2/CborShapeDeserializer2.js +44 -15
  209. package/node_modules/@smithy/core/dist-es/submodules/cbor/codec-v2/CborShapeSerializer2.js +22 -4
  210. package/node_modules/@smithy/core/dist-es/submodules/cbor/parseCborBody.js +5 -0
  211. package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/extensions/checksum.js +3 -0
  212. package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/get-value-from-text-node.js +4 -1
  213. package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/object-mapping.js +6 -1
  214. package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/serde-json.js +4 -1
  215. package/node_modules/@smithy/core/dist-es/submodules/endpoints/util-endpoints/resolveEndpoint.js +3 -0
  216. package/node_modules/@smithy/core/dist-es/submodules/event-streams/EventStreamSerde.js +7 -0
  217. package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/HeaderMarshaller.js +4 -1
  218. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js +9 -0
  219. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +5 -0
  220. package/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js +3 -0
  221. package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/parseRetryAfterHeader.js +4 -1
  222. package/node_modules/@smithy/core/dist-es/submodules/serde/index.browser.js +1 -0
  223. package/node_modules/@smithy/core/dist-es/submodules/serde/index.js +1 -0
  224. package/node_modules/@smithy/core/dist-es/submodules/serde/index.native.js +1 -0
  225. package/node_modules/@smithy/core/dist-es/submodules/serde/parse-utils.js +3 -0
  226. package/node_modules/@smithy/core/dist-es/submodules/transport/hasOwn.js +3 -0
  227. package/node_modules/@smithy/core/dist-es/submodules/transport/index.js +1 -0
  228. package/node_modules/@smithy/core/dist-es/submodules/transport/toEndpointV1.js +3 -0
  229. package/node_modules/@smithy/core/dist-types/submodules/serde/index.browser.d.ts +1 -0
  230. package/node_modules/@smithy/core/dist-types/submodules/serde/index.d.ts +1 -0
  231. package/node_modules/@smithy/core/dist-types/submodules/serde/index.native.d.ts +1 -0
  232. package/node_modules/@smithy/core/dist-types/submodules/transport/hasOwn.d.ts +4 -0
  233. package/node_modules/@smithy/core/dist-types/submodules/transport/index.d.ts +1 -0
  234. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.browser.d.ts +1 -0
  235. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.d.ts +1 -0
  236. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/serde/index.native.d.ts +1 -0
  237. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/transport/hasOwn.d.ts +4 -0
  238. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/transport/index.d.ts +1 -0
  239. package/node_modules/@smithy/core/package.json +1 -1
  240. package/node_modules/@smithy/node-http-handler/CHANGELOG.md +23 -0
  241. package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +18 -6
  242. package/node_modules/@smithy/node-http-handler/dist-es/get-transformed-headers.js +3 -0
  243. package/node_modules/@smithy/node-http-handler/dist-es/http2/ClientHttp2SessionRef.js +1 -0
  244. package/node_modules/@smithy/node-http-handler/dist-es/node-http-handler.js +3 -0
  245. package/node_modules/@smithy/node-http-handler/dist-es/node-http2-connection-manager.js +2 -3
  246. package/node_modules/@smithy/node-http-handler/dist-es/node-http2-handler.js +8 -1
  247. package/node_modules/@smithy/node-http-handler/package.json +3 -3
  248. package/node_modules/@smithy/types/CHANGELOG.md +6 -0
  249. package/node_modules/@smithy/types/dist-types/http/httpHandlerInitialization.d.ts +14 -0
  250. package/node_modules/@smithy/types/dist-types/ts3.4/http/httpHandlerInitialization.d.ts +14 -0
  251. package/node_modules/@smithy/types/package.json +1 -1
  252. package/node_modules/@types/node/README.md +1 -1
  253. package/node_modules/@types/node/buffer.buffer.d.ts +10 -5
  254. package/node_modules/@types/node/crypto.d.ts +2 -4
  255. package/node_modules/@types/node/dgram.d.ts +119 -4
  256. package/node_modules/@types/node/ffi.d.ts +1 -1
  257. package/node_modules/@types/node/fs/promises.d.ts +61 -65
  258. package/node_modules/@types/node/fs.d.ts +86 -76
  259. package/node_modules/@types/node/http.d.ts +17 -1
  260. package/node_modules/@types/node/http2.d.ts +12 -4
  261. package/node_modules/@types/node/index.d.ts +1 -0
  262. package/node_modules/@types/node/inspector.d.ts +2 -1
  263. package/node_modules/@types/node/net.d.ts +108 -16
  264. package/node_modules/@types/node/package.json +2 -2
  265. package/node_modules/@types/node/process.d.ts +52 -0
  266. package/node_modules/@types/node/quic.d.ts +246 -38
  267. package/node_modules/@types/node/sqlite.d.ts +6 -2
  268. package/node_modules/@types/node/stream/iter.d.ts +4 -4
  269. package/node_modules/@types/node/test.d.ts +36 -0
  270. package/node_modules/@types/node/tls.d.ts +24 -0
  271. package/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +5 -0
  272. package/node_modules/@types/node/ts5.6/index.d.ts +1 -0
  273. package/node_modules/@types/node/ts5.7/index.d.ts +1 -0
  274. package/node_modules/@types/node/tty.d.ts +4 -3
  275. package/node_modules/@types/node/vfs.d.ts +210 -0
  276. package/node_modules/@types/node/vm.d.ts +1 -1
  277. package/node_modules/fast-xml-parser/CHANGELOG.md +8 -1
  278. package/node_modules/fast-xml-parser/README.md +1 -1
  279. package/node_modules/fast-xml-parser/lib/fxp.cjs +1 -1
  280. package/node_modules/fast-xml-parser/lib/fxp.min.js +1 -1
  281. package/node_modules/fast-xml-parser/lib/fxp.min.js.map +1 -1
  282. package/node_modules/fast-xml-parser/lib/fxparser.min.js +1 -1
  283. package/node_modules/fast-xml-parser/lib/fxparser.min.js.map +1 -1
  284. package/node_modules/fast-xml-parser/lib/fxvalidator.min.js +1 -1
  285. package/node_modules/fast-xml-parser/lib/fxvalidator.min.js.map +1 -1
  286. package/node_modules/fast-xml-parser/package.json +2 -2
  287. package/node_modules/fast-xml-parser/src/fxp.d.ts +2 -0
  288. package/node_modules/fast-xml-parser/src/validator.js +98 -5
  289. package/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js +16 -1
  290. package/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +23 -1
  291. package/node_modules/fast-xml-parser/src/xmlparser/xmlNode.js +14 -0
  292. package/node_modules/inquirer/README.md +3 -9
  293. package/node_modules/inquirer/dist/index.d.ts +2 -3
  294. package/node_modules/inquirer/dist/index.js +1 -1
  295. package/node_modules/inquirer/dist/types.d.ts +3 -3
  296. package/node_modules/inquirer/package.json +7 -6
  297. package/node_modules/strnum/CHANGELOG.md +6 -0
  298. package/node_modules/strnum/package.json +1 -1
  299. package/node_modules/strnum/strnum.js +5 -1
  300. package/package.json +19 -19
  301. package/node_modules/@inquirer/external-editor/dist/errors/CreateFileError.d.ts +0 -10
  302. package/node_modules/@inquirer/external-editor/dist/errors/CreateFileError.js +0 -13
  303. package/node_modules/@inquirer/external-editor/dist/errors/LaunchEditorError.d.ts +0 -10
  304. package/node_modules/@inquirer/external-editor/dist/errors/LaunchEditorError.js +0 -13
  305. package/node_modules/@inquirer/external-editor/dist/errors/ReadFileError.d.ts +0 -10
  306. package/node_modules/@inquirer/external-editor/dist/errors/ReadFileError.js +0 -13
  307. package/node_modules/@inquirer/external-editor/dist/errors/RemoveFileError.d.ts +0 -10
  308. package/node_modules/@inquirer/external-editor/dist/errors/RemoveFileError.js +0 -13
@@ -1,14 +1,13 @@
1
- import type { Prettify } from '@inquirer/type';
2
1
  export declare function usePagination<T>({ items, active, renderItem, pageSize, loop, }: {
3
2
  items: ReadonlyArray<T>;
4
3
  /** The index of the active item. */
5
4
  active: number;
6
5
  /** Renders an item as part of a page. */
7
- renderItem: (layout: Prettify<{
6
+ renderItem: (layout: {
8
7
  item: T;
9
8
  index: number;
10
9
  isActive: boolean;
11
- }>) => string;
10
+ }) => string;
12
11
  /** The size of the page. */
13
12
  pageSize: number;
14
13
  /** Allows creating an infinitely looping list. `true` if unspecified. */
@@ -160,7 +160,7 @@ type DefaultTheme = {
160
160
  key: (text: string) => string;
161
161
  };
162
162
  };
163
- export type Theme<Extension extends object = object> = Prettify<Extension & DefaultTheme>;
163
+ export type Theme<Extension extends object = object> = Extension & DefaultTheme;
164
164
  export declare const defaultTheme: DefaultTheme;
165
165
  export declare function getDefaultTheme(): DefaultTheme;
166
166
  export {};
@@ -2,7 +2,7 @@ import { withPointer } from "./hook-engine.js";
2
2
  export function useMemo(fn, dependencies) {
3
3
  return withPointer((pointer) => {
4
4
  const prev = pointer.get();
5
- if (!prev ||
5
+ if (!pointer.initialized ||
6
6
  prev.dependencies.length !== dependencies.length ||
7
7
  prev.dependencies.some((dep, i) => dep !== dependencies[i])) {
8
8
  const value = fn();
@@ -1,4 +1,7 @@
1
1
  type NotFunction<T> = T extends (...args: never) => unknown ? never : T;
2
- export declare function useState<Value>(defaultValue: NotFunction<Value> | (() => Value)): [Value, (newValue: Value) => void];
3
- export declare function useState<Value>(defaultValue?: NotFunction<Value> | (() => Value)): [Value | undefined, (newValue?: Value) => void];
2
+ type Reducer<Value> = (currentValue: Value) => Value;
3
+ type SetState<Value> = (newValue: NotFunction<Value> | Reducer<Value>) => void;
4
+ type OptionalSetState<Value> = (newValue?: NotFunction<Value> | Reducer<Value>) => void;
5
+ export declare function useState<Value>(defaultValue: NotFunction<Value> | (() => Value)): [Value, SetState<Value>];
6
+ export declare function useState<Value>(defaultValue?: NotFunction<Value> | (() => Value)): [Value | undefined, OptionalSetState<Value | undefined>];
4
7
  export {};
@@ -3,12 +3,17 @@ import { withPointer, handleChange } from "./hook-engine.js";
3
3
  function isFactory(value) {
4
4
  return typeof value === 'function';
5
5
  }
6
+ function isReducer(value) {
7
+ return typeof value === 'function';
8
+ }
6
9
  export function useState(defaultValue) {
7
10
  return withPointer((pointer) => {
8
11
  const setState = AsyncResource.bind(function setState(newValue) {
12
+ const currentValue = pointer.get();
13
+ const nextValue = isReducer(newValue) ? newValue(currentValue) : newValue;
9
14
  // Noop if the value is still the same.
10
- if (pointer.get() !== newValue) {
11
- pointer.set(newValue);
15
+ if (!Object.is(currentValue, nextValue)) {
16
+ pointer.set(nextValue);
12
17
  // Trigger re-render
13
18
  handleChange();
14
19
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/core",
3
- "version": "11.2.1",
3
+ "version": "12.0.2",
4
4
  "description": "Core Inquirer prompt API",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,17 +67,18 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/ansi": "^2.0.7",
71
- "@inquirer/figures": "^2.0.7",
72
- "@inquirer/type": "^4.0.7",
70
+ "@inquirer/ansi": "^2.0.8",
71
+ "@inquirer/figures": "^2.0.9",
72
+ "@inquirer/type": "4.1.1",
73
73
  "cli-width": "^4.1.0",
74
74
  "fast-wrap-ansi": "^0.2.0",
75
75
  "mute-stream": "^3.0.0",
76
76
  "signal-exit": "^4.1.0"
77
77
  },
78
78
  "devDependencies": {
79
+ "@repo/tsconfig": "0.0.0",
79
80
  "@types/mute-stream": "^0.0.4",
80
- "@types/node": "^25.5.2",
81
+ "@types/node": "^26.1.1",
81
82
  "typescript": "^6.0.2"
82
83
  },
83
84
  "peerDependencies": {
@@ -93,5 +94,5 @@
93
94
  },
94
95
  "main": "./dist/index.js",
95
96
  "types": "./dist/index.d.ts",
96
- "gitHead": "b43359d803733b1a7c4638addcc270987fb894c3"
97
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
97
98
  }
@@ -10,12 +10,20 @@ type EditorTheme = {
10
10
  };
11
11
  type EditorConfig = {
12
12
  message: string;
13
- default?: string;
13
+ default?: string | undefined;
14
14
  postfix?: string;
15
15
  waitForUserInput?: boolean;
16
16
  validate?: (value: string) => boolean | string | Promise<string | boolean>;
17
17
  file?: FileOptions;
18
18
  theme?: PartialDeep<Theme<EditorTheme>>;
19
19
  };
20
- declare const _default: import("@inquirer/type").Prompt<string, EditorConfig>;
20
+ declare const _default: import("@inquirer/type").Prompt<string, {
21
+ message: string;
22
+ default?: string | undefined | undefined;
23
+ postfix?: string | undefined;
24
+ waitForUserInput?: boolean | undefined;
25
+ validate?: ((value: string) => boolean | string | Promise<string | boolean>) | undefined;
26
+ file?: FileOptions | undefined;
27
+ theme?: PartialDeep<Theme<EditorTheme>> | undefined;
28
+ } & EditorConfig>;
21
29
  export default _default;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/editor",
3
- "version": "5.2.2",
3
+ "version": "5.3.2",
4
4
  "description": "Inquirer multiline editor prompt",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,11 +67,12 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/core": "^11.2.1",
71
- "@inquirer/external-editor": "^3.0.3",
72
- "@inquirer/type": "^4.0.7"
70
+ "@inquirer/core": "^12.0.2",
71
+ "@inquirer/external-editor": "^3.0.5",
72
+ "@inquirer/type": "4.1.1"
73
73
  },
74
74
  "devDependencies": {
75
+ "@repo/tsconfig": "0.0.0",
75
76
  "typescript": "^6.0.2"
76
77
  },
77
78
  "peerDependencies": {
@@ -87,5 +88,5 @@
87
88
  },
88
89
  "main": "./dist/index.js",
89
90
  "types": "./dist/index.d.ts",
90
- "gitHead": "bfd8710229e3d3c9784bef3bbfbd84c7bd09bb9e"
91
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
91
92
  }
@@ -112,7 +112,7 @@ Here's each property:
112
112
 
113
113
  - `value`: The value is what will be returned by `await expand()`.
114
114
  - `name`: The string displayed in the choice list. It'll default to the stringify `value`.
115
- - `key`: The input the use must provide to select the choice. Must be a lowercase single alpha-numeric character string.
115
+ - `key`: The input the use must provide to select the choice. Must be a lowercase single alphanumeric character string.
116
116
 
117
117
  ## Theming
118
118
 
@@ -9,6 +9,17 @@ type Choice<Value> = {
9
9
  name: string;
10
10
  value: Value;
11
11
  };
12
+ type ExpandConfig<Value = string> = {
13
+ message: string;
14
+ choices: readonly (Separator | {
15
+ key: Key;
16
+ name: Value & string;
17
+ value?: never;
18
+ } | Choice<Value>)[];
19
+ default?: Key | 'h';
20
+ expanded?: boolean;
21
+ theme?: PartialDeep<Theme>;
22
+ };
12
23
  declare const expand: <const Value>(config: {
13
24
  message: string;
14
25
  choices: readonly (Separator | {
@@ -19,6 +30,6 @@ declare const expand: <const Value>(config: {
19
30
  default?: (Key | "h") | undefined;
20
31
  expanded?: boolean | undefined;
21
32
  theme?: PartialDeep<Theme> | undefined;
22
- }, context?: import("@inquirer/type").Context) => Promise<Value>;
33
+ } & ExpandConfig<Value>, context?: import("@inquirer/type").Context) => Promise<Value>;
23
34
  export default expand;
24
35
  export { Separator } from '@inquirer/core';
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/expand",
3
- "version": "5.1.1",
3
+ "version": "5.1.4",
4
4
  "description": "Inquirer checkbox prompt",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,10 +67,11 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/core": "^11.2.1",
71
- "@inquirer/type": "^4.0.7"
70
+ "@inquirer/core": "^12.0.2",
71
+ "@inquirer/type": "4.1.1"
72
72
  },
73
73
  "devDependencies": {
74
+ "@repo/tsconfig": "0.0.0",
74
75
  "typescript": "^6.0.2"
75
76
  },
76
77
  "peerDependencies": {
@@ -86,5 +87,5 @@
86
87
  },
87
88
  "main": "./dist/index.js",
88
89
  "types": "./dist/index.d.ts",
89
- "gitHead": "b43359d803733b1a7c4638addcc270987fb894c3"
90
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
90
91
  }
@@ -77,6 +77,19 @@ try {
77
77
  }
78
78
  ```
79
79
 
80
+ ### Windows editor commands
81
+
82
+ On Windows, prefer setting `$VISUAL` or `$EDITOR` to the editor executable
83
+ rather than a `.cmd` or `.bat` shim. This package launches the editor directly
84
+ instead of through a shell so editor arguments and temporary file paths are not
85
+ interpreted as shell commands.
86
+
87
+ For example, use `Code.exe` with `--wait` instead of `code.cmd`:
88
+
89
+ ```powershell
90
+ setx VISUAL '"C:\Program Files\Microsoft VS Code\Code.exe" --wait'
91
+ ```
92
+
80
93
  #### API
81
94
 
82
95
  **Convenience Functions**
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/external-editor",
3
- "version": "3.0.3",
3
+ "version": "3.0.5",
4
4
  "description": "Edit a string with the users preferred text editor using $VISUAL or $ENVIRONMENT",
5
5
  "keywords": [
6
6
  "answer",
@@ -76,8 +76,9 @@
76
76
  "iconv-lite": "^0.7.2"
77
77
  },
78
78
  "devDependencies": {
79
+ "@repo/tsconfig": "0.0.0",
79
80
  "@types/chardet": "^1.0.0",
80
- "@types/node": "^25.5.2",
81
+ "@types/node": "^26.1.1",
81
82
  "typescript": "^6.0.2"
82
83
  },
83
84
  "peerDependencies": {
@@ -93,5 +94,5 @@
93
94
  },
94
95
  "main": "./dist/index.js",
95
96
  "types": "./dist/index.d.ts",
96
- "gitHead": "bfd8710229e3d3c9784bef3bbfbd84c7bd09bb9e"
97
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
97
98
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/figures",
3
- "version": "2.0.7",
3
+ "version": "2.0.9",
4
4
  "description": "Vendored version of figures, for CJS compatibility",
5
5
  "keywords": [
6
6
  "answer",
@@ -68,7 +68,8 @@
68
68
  "tsc": "tsc"
69
69
  },
70
70
  "devDependencies": {
71
- "@types/node": "^25.5.2",
71
+ "@repo/tsconfig": "0.0.0",
72
+ "@types/node": "^26.1.1",
72
73
  "typescript": "^6.0.2"
73
74
  },
74
75
  "engines": {
@@ -76,5 +77,5 @@
76
77
  },
77
78
  "main": "./dist/index.js",
78
79
  "types": "./dist/index.d.ts",
79
- "gitHead": "b43359d803733b1a7c4638addcc270987fb894c3"
80
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
80
81
  }
@@ -16,5 +16,17 @@ type InputConfig = {
16
16
  pattern?: RegExp;
17
17
  patternError?: string;
18
18
  };
19
- declare const _default: import("@inquirer/type").Prompt<string, InputConfig>;
19
+ declare const _default: import("@inquirer/type").Prompt<string, {
20
+ message: string;
21
+ default?: string | undefined | undefined;
22
+ prefill?: "tab" | "editable" | undefined;
23
+ required?: boolean | undefined;
24
+ transformer?: ((value: string, { isFinal }: {
25
+ isFinal: boolean;
26
+ }) => string) | undefined;
27
+ validate?: ((value: string) => boolean | string | Promise<string | boolean>) | undefined;
28
+ theme?: PartialDeep<Theme<InputTheme>> | undefined;
29
+ pattern?: RegExp | undefined;
30
+ patternError?: string | undefined;
31
+ } & InputConfig>;
20
32
  export default _default;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/input",
3
- "version": "5.1.2",
3
+ "version": "5.1.5",
4
4
  "description": "Inquirer input text prompt",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,10 +67,11 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/core": "^11.2.1",
71
- "@inquirer/type": "^4.0.7"
70
+ "@inquirer/core": "^12.0.2",
71
+ "@inquirer/type": "4.1.1"
72
72
  },
73
73
  "devDependencies": {
74
+ "@repo/tsconfig": "0.0.0",
74
75
  "typescript": "^6.0.2"
75
76
  },
76
77
  "peerDependencies": {
@@ -86,5 +87,5 @@
86
87
  },
87
88
  "main": "./dist/index.js",
88
89
  "types": "./dist/index.d.ts",
89
- "gitHead": "bfd8710229e3d3c9784bef3bbfbd84c7bd09bb9e"
90
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
90
91
  }
@@ -1,13 +1,23 @@
1
1
  import { type Theme } from '@inquirer/core';
2
2
  import type { PartialDeep } from '@inquirer/type';
3
- declare const _default: <Required extends boolean>(config: {
3
+ type NumberConfig<Required extends boolean = boolean> = {
4
4
  message: string;
5
5
  default?: number | undefined;
6
+ min?: number;
7
+ max?: number;
8
+ step?: number | 'any';
9
+ required?: Required;
10
+ validate?: (value: Required extends true ? number : number | undefined) => boolean | string | Promise<string | boolean>;
11
+ theme?: PartialDeep<Theme>;
12
+ };
13
+ declare const _default: <Required extends boolean>(config: {
14
+ message: string;
15
+ default?: number | undefined | undefined;
6
16
  min?: number | undefined;
7
17
  max?: number | undefined;
8
18
  step?: number | "any" | undefined;
9
19
  required?: Required | undefined;
10
20
  validate?: ((value: Required extends true ? number : number | undefined) => boolean | string | Promise<string | boolean>) | undefined;
11
21
  theme?: PartialDeep<Theme> | undefined;
12
- }, context?: import("@inquirer/type").Context) => Promise<Required extends true ? number : number | undefined>;
22
+ } & NumberConfig<Required>, context?: import("@inquirer/type").Context) => Promise<Required extends true ? number : number | undefined>;
13
23
  export default _default;
@@ -1,10 +1,5 @@
1
1
  import { createPrompt, useState, useKeypress, usePrefix, isBackspaceKey, isEnterKey, isTabKey, makeTheme, } from '@inquirer/core';
2
- function isStepOf(value, step, min) {
3
- const valuePow = value * Math.pow(10, 6);
4
- const stepPow = step * Math.pow(10, 6);
5
- const minPow = min * Math.pow(10, 6);
6
- return (valuePow - (Number.isFinite(min) ? minPow : 0)) % stepPow === 0;
7
- }
2
+ import { isStepOf } from "./is-step-of.js";
8
3
  function validateNumber(value, { min, max, step, }) {
9
4
  if (value == null || Number.isNaN(value)) {
10
5
  return false;
@@ -0,0 +1 @@
1
+ export declare function isStepOf(value: number, step: number, min: number): boolean;
@@ -0,0 +1,22 @@
1
+ function toDecimal(value) {
2
+ const [coefficient = '', exponent = '0'] = value.toString().toLowerCase().split('e');
3
+ const [integer = '', fraction = ''] = coefficient.split('.');
4
+ return {
5
+ significand: BigInt(`${integer}${fraction}`),
6
+ exponent: Number(exponent) - fraction.length,
7
+ };
8
+ }
9
+ export function isStepOf(value, step, min) {
10
+ if (!Number.isFinite(value) || !Number.isFinite(step) || step === 0) {
11
+ return false;
12
+ }
13
+ const valueDecimal = toDecimal(value);
14
+ const stepDecimal = toDecimal(step);
15
+ const minDecimal = Number.isFinite(min) ? toDecimal(min) : undefined;
16
+ const exponent = Math.min(valueDecimal.exponent, stepDecimal.exponent, minDecimal?.exponent ?? Infinity);
17
+ const toInteger = (decimal) => decimal.significand * 10n ** BigInt(decimal.exponent - exponent);
18
+ const valueInteger = toInteger(valueDecimal);
19
+ const stepInteger = toInteger(stepDecimal);
20
+ const minInteger = minDecimal ? toInteger(minDecimal) : 0n;
21
+ return (valueInteger - minInteger) % stepInteger === 0n;
22
+ }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/number",
3
- "version": "4.1.1",
3
+ "version": "4.2.2",
4
4
  "description": "Inquirer number prompt",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,10 +67,11 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/core": "^11.2.1",
71
- "@inquirer/type": "^4.0.7"
70
+ "@inquirer/core": "^12.0.2",
71
+ "@inquirer/type": "4.1.1"
72
72
  },
73
73
  "devDependencies": {
74
+ "@repo/tsconfig": "0.0.0",
74
75
  "typescript": "^6.0.2"
75
76
  },
76
77
  "peerDependencies": {
@@ -86,5 +87,5 @@
86
87
  },
87
88
  "main": "./dist/index.js",
88
89
  "types": "./dist/index.d.ts",
89
- "gitHead": "b43359d803733b1a7c4638addcc270987fb894c3"
90
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
90
91
  }
@@ -60,12 +60,13 @@ const answer = await password({ message: 'Enter your name' });
60
60
 
61
61
  ## Options
62
62
 
63
- | Property | Type | Required | Description |
64
- | -------- | ----------------------------------------------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
65
- | message | `string` | yes | The question to ask |
66
- | mask | `boolean` | no | Show a `*` mask over the input or keep it transparent |
67
- | validate | `string => boolean \| string \| Promise<boolean \| string>` | no | On submit, validate the filtered answered content. When returning a string, it'll be used as the error message displayed to the user. Note: returning a rejected promise, we'll assume a code error happened and crash. |
68
- | theme | [See Theming](#Theming) | no | Customize look of the prompt. |
63
+ | Property | Type | Required | Description |
64
+ | ---------- | ----------------------------------------------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
65
+ | message | `string` | yes | The question to ask |
66
+ | mask | `boolean \| string` | no | Show a `*` mask over the input, use a custom mask character, or keep it transparent. |
67
+ | toggleMask | `boolean` | no | Allow the user to press `ctrl+t` to temporarily reveal the typed value. Defaults to `true`; set to `false` to disable both the shortcut and its help line. |
68
+ | validate | `string => boolean \| string \| Promise<boolean \| string>` | no | On submit, validate the filtered answered content. When returning a string, it'll be used as the error message displayed to the user. Note: returning a rejected promise, we'll assume a code error happened and crash. |
69
+ | theme | [See Theming](#Theming) | no | Customize look of the prompt. |
69
70
 
70
71
  ## Theming
71
72
 
@@ -83,10 +84,27 @@ type Theme = {
83
84
  message: (text: string, status: 'idle' | 'done' | 'loading') => string;
84
85
  error: (text: string) => string;
85
86
  help: (text: string) => string;
87
+ maskedText: string;
88
+ keysHelpTip: (keys: [key: string, action: string][]) => string | undefined;
86
89
  };
87
90
  };
88
91
  ```
89
92
 
93
+ `maskedText` is the inline tip shown when `mask` is off and the value is hidden (default: `[input is masked]`).
94
+
95
+ ### `theme.style.keysHelpTip`
96
+
97
+ This function customizes the keyboard shortcut help displayed on the line below the prompt. It receives `[['ctrl+t', 'toggle visibility']]` while the value is hidden. Use it to change the formatting or localize the action, or return `undefined` to hide the help line entirely.
98
+
99
+ ```js
100
+ theme: {
101
+ style: {
102
+ keysHelpTip: (keys) =>
103
+ keys.map(([key, action]) => `${key}: ${action}`).join(' | '),
104
+ },
105
+ }
106
+ ```
107
+
90
108
  # License
91
109
 
92
110
  Copyright (c) 2023 Simon Boudrias (twitter: [@vaxilart](https://twitter.com/Vaxilart))<br/>
@@ -3,13 +3,21 @@ import type { PartialDeep } from '@inquirer/type';
3
3
  type PasswordTheme = {
4
4
  style: {
5
5
  maskedText: string;
6
+ keysHelpTip: (keys: [key: string, action: string][]) => string | undefined;
6
7
  };
7
8
  };
8
9
  type PasswordConfig = {
9
10
  message: string;
10
11
  mask?: boolean | string;
12
+ toggleMask?: boolean;
11
13
  validate?: (value: string) => boolean | string | Promise<string | boolean>;
12
14
  theme?: PartialDeep<Theme<PasswordTheme>>;
13
15
  };
14
- declare const _default: import("@inquirer/type").Prompt<string, PasswordConfig>;
16
+ declare const _default: import("@inquirer/type").Prompt<string, {
17
+ message: string;
18
+ mask?: boolean | string | undefined;
19
+ toggleMask?: boolean | undefined;
20
+ validate?: ((value: string) => boolean | string | Promise<string | boolean>) | undefined;
21
+ theme?: PartialDeep<Theme<PasswordTheme>> | undefined;
22
+ } & PasswordConfig>;
15
23
  export default _default;
@@ -1,16 +1,21 @@
1
1
  import { createPrompt, useState, useKeypress, usePrefix, isEnterKey, makeTheme, } from '@inquirer/core';
2
2
  import { cursorHide } from '@inquirer/ansi';
3
+ import { styleText } from 'node:util';
3
4
  const passwordTheme = {
4
5
  style: {
5
6
  maskedText: '[input is masked]',
7
+ keysHelpTip: (keys) => keys
8
+ .map(([key, action]) => `${styleText('bold', key)} ${styleText('dim', action)}`)
9
+ .join(styleText('dim', ' • ')),
6
10
  },
7
11
  };
8
12
  export default createPrompt((config, done) => {
9
- const { validate = () => true } = config;
13
+ const { toggleMask = true, validate = () => true } = config;
10
14
  const theme = makeTheme(passwordTheme, config.theme);
11
15
  const [status, setStatus] = useState('idle');
12
16
  const [errorMsg, setError] = useState();
13
17
  const [value, setValue] = useState('');
18
+ const [revealed, setRevealed] = useState(false);
14
19
  const prefix = usePrefix({ status, theme });
15
20
  useKeypress(async (key, rl) => {
16
21
  // Ignore keypress while our prompt is doing other processing.
@@ -34,27 +39,41 @@ export default createPrompt((config, done) => {
34
39
  setStatus('idle');
35
40
  }
36
41
  }
42
+ else if (toggleMask && key.ctrl && key.name === 't') {
43
+ setRevealed((prev) => !prev);
44
+ }
37
45
  else {
38
46
  setValue(rl.line);
39
47
  setError(undefined);
40
48
  }
41
49
  });
42
50
  const message = theme.style.message(config.message, status);
51
+ const showPlaintext = toggleMask && revealed && status === 'idle';
43
52
  let formattedValue = '';
44
- let helpTip;
45
- if (config.mask) {
53
+ if (showPlaintext) {
54
+ formattedValue = value;
55
+ }
56
+ else if (config.mask) {
46
57
  const maskChar = typeof config.mask === 'string' ? config.mask : '*';
47
58
  formattedValue = maskChar.repeat(value.length);
48
59
  }
49
60
  else if (status !== 'done') {
50
- helpTip = `${theme.style.help(theme.style.maskedText)}${cursorHide}`;
61
+ formattedValue = theme.style.help(theme.style.maskedText);
51
62
  }
52
63
  if (status === 'done') {
53
64
  formattedValue = theme.style.answer(formattedValue);
54
65
  }
55
- let error = '';
56
- if (errorMsg) {
57
- error = theme.style.error(errorMsg);
66
+ else if (!config.mask) {
67
+ formattedValue += cursorHide;
58
68
  }
59
- return [[prefix, message, config.mask ? formattedValue : helpTip].join(' '), error];
69
+ const content = [prefix, message, formattedValue].filter(Boolean).join(' ');
70
+ const bottomContent = [
71
+ errorMsg ? theme.style.error(errorMsg) : '',
72
+ toggleMask && status === 'idle'
73
+ ? theme.style.keysHelpTip([['ctrl+t', 'toggle visibility']])
74
+ : '',
75
+ ]
76
+ .filter(Boolean)
77
+ .join('\n');
78
+ return [content, bottomContent];
60
79
  });
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/password",
3
- "version": "5.1.1",
3
+ "version": "5.2.1",
4
4
  "description": "Inquirer password prompt",
5
5
  "keywords": [
6
6
  "answer",
@@ -67,11 +67,12 @@
67
67
  "tsc": "tsc"
68
68
  },
69
69
  "dependencies": {
70
- "@inquirer/ansi": "^2.0.7",
71
- "@inquirer/core": "^11.2.1",
72
- "@inquirer/type": "^4.0.7"
70
+ "@inquirer/ansi": "^2.0.8",
71
+ "@inquirer/core": "^12.0.2",
72
+ "@inquirer/type": "4.1.1"
73
73
  },
74
74
  "devDependencies": {
75
+ "@repo/tsconfig": "0.0.0",
75
76
  "typescript": "^6.0.2"
76
77
  },
77
78
  "peerDependencies": {
@@ -87,5 +88,5 @@
87
88
  },
88
89
  "main": "./dist/index.js",
89
90
  "types": "./dist/index.d.ts",
90
- "gitHead": "b43359d803733b1a7c4638addcc270987fb894c3"
91
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
91
92
  }