{"_id":"@inquirer/confirm@6.3.3","bugs":{"url":"https://github.com/SBoudrias/Inquirer.js/issues"},"dist":{"shasum":"95397513769802cfc377a5f90936a105c34da83b","tarball":"http://registry-npm.ywwl.com/@inquirer/confirm/download/@inquirer/confirm-6.3.3.tgz","integrity":"sha512-ImOBgpl/sJTFp8naeSkNu4S0Sf8F8pxv3/CUx+LoBAdQvCVqFz6rSB2A/oZYsJge3+yphbEDxEkfaRNYq1OU0A==","fileCount":5,"unpackedSize":11902,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@inquirer%2fconfirm@6.3.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIDe8yaruF32pZ/b8hpOAXG0uXrP5gRiK2mUaJ9fYjN04AiEAnykOS4bHYdXaiIBgazGN4rgXoncrsDxg1HJl1SMB/hw="}],"size":4470,"noattachment":false,"key":"/@inquirer/confirm/-/@inquirer/confirm-6.3.3.tgz"},"main":"./dist/index.js","name":"@inquirer/confirm","type":"module","types":"./dist/index.d.ts","author":{"name":"Simon Boudrias","email":"admin@simonboudrias.com"},"engines":{"node":">=23.5.0 || ^22.13.0 || ^20.17.0"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"./package.json":"./package.json"},"gitHead":"a9436bd94d55a439df308f50e77a7cd0b2078e98","license":"MIT","scripts":{"tsc":"tsc"},"version":"6.3.3","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"81a15851-ce1e-4e8a-b498-0179ef8267fd"},"approver":{"name":"sboudrias","email":"admin@simonboudrias.com"}},"homepage":"https://github.com/SBoudrias/Inquirer.js/blob/main/packages/confirm/README.md","keywords":["answer","answers","ask","base","cli","command","command-line","confirm","enquirer","generate","generator","hyper","input","inquire","inquirer","interface","iterm","javascript","menu","node","nodejs","prompt","promptly","prompts","question","readline","scaffold","scaffolder","scaffolding","stdin","stdout","terminal","tty","ui","yeoman","yo","zsh"],"repository":{"url":"git+https://github.com/SBoudrias/Inquirer.js.git","type":"git"},"_npmVersion":"lerna/5.6.1/node@v24.21.0+x64 (linux)","description":"Inquirer confirm prompt","directories":{},"maintainers":[{"name":"sboudrias","email":"admin@simonboudrias.com"},{"name":"mischah","email":"mail@michael-kuehnel.de"}],"sideEffects":false,"_nodeVersion":"24.21.0","dependencies":{"@inquirer/core":"^12.0.4","@inquirer/type":"4.2.0"},"publishConfig":{"access":"public"},"devDependencies":{"typescript":"^6.0.2","@repo/tsconfig":"0.0.0"},"peerDependencies":{"@types/node":">=18"},"peerDependenciesMeta":{"@types/node":{"optional":true}},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/confirm_6.3.3_1791135722346_0.5443523077136918"},"_hasShrinkwrap":false,"readme":"# `@inquirer/confirm`\n\nSimple interactive command line prompt to gather boolean input from users.\n\n![Confirm prompt](https://cdn.rawgit.com/SBoudrias/Inquirer.js/28ae8337ba51d93e359ef4f7ee24e79b69898962/assets/screenshots/confirm.svg)\n\n# Installation\n\n<table>\n<tr>\n  <th>yarn</th>\n  <th>pnpm</th>\n</tr>\n<tr>\n<td>\n\n```sh\nyarn add @inquirer/prompts\n```\n\n</td>\n<td>\n\n```sh\npnpm add @inquirer/prompts\n```\n\n</td>\n</tr>\n<tr>\n  <th>bun</th>\n  <th>deno</th>\n</tr>\n<tr>\n<td>\n\n```sh\nbun add @inquirer/prompts\n```\n\n</td>\n<td>\n\n```sh\ndeno add npm:@inquirer/prompts\n```\n\n</td>\n</tr>\n<tr>\n<th colSpan=\"2\">npm</th>\n</tr>\n<tr>\n<td colSpan=\"2\">\n\n```sh\nnpm install @inquirer/prompts\n```\n\n</td>\n</tr>\n<tr>\n<td colSpan=\"2\" align=\"center\">Or</td>\n</tr>\n<tr>\n  <th>yarn</th>\n  <th>pnpm</th>\n</tr>\n<tr>\n<td>\n\n```sh\nyarn add @inquirer/confirm\n```\n\n</td>\n<td>\n\n```sh\npnpm add @inquirer/confirm\n```\n\n</td>\n</tr>\n<tr>\n  <th>bun</th>\n  <th>deno</th>\n</tr>\n<tr>\n<td>\n\n```sh\nbun add @inquirer/confirm\n```\n\n</td>\n<td>\n\n```sh\ndeno add npm:@inquirer/confirm\n```\n\n</td>\n</tr>\n<tr>\n<th colSpan=\"2\">npm</th>\n</tr>\n<tr>\n<td colSpan=\"2\">\n\n```sh\nnpm install @inquirer/confirm\n```\n\n</td>\n</tr>\n</table>\n\nOn Deno, prompts detect the terminal's unicode and color support from the environment, so run your script with `--allow-env`.\n\n# Usage\n\n```js\nimport { confirm } from '@inquirer/prompts';\n// Or\n// import confirm from '@inquirer/confirm';\n\nconst answer = await confirm({ message: 'Continue?' });\n```\n\n## Options\n\n| Property    | Type                    | Required | Description                                             |\n| ----------- | ----------------------- | -------- | ------------------------------------------------------- |\n| message     | `string`                | yes      | The question to ask                                     |\n| default     | `boolean`               | no       | Default answer (true or false)                          |\n| transformer | `(boolean) => string`   | no       | Transform the prompt printed message to a custom string |\n| theme       | [See Theming](#Theming) | no       | Customize look of the prompt.                           |\n\n## Theming\n\nYou can theme a prompt by passing a `theme` object option. The theme object only need to includes the keys you wish to modify, we'll fallback on the defaults for the rest.\n\n```ts\ntype Theme = {\n  prefix: string | { idle: string; done: string };\n  spinner: {\n    interval: number;\n    frames: string[];\n  };\n  keywords: {\n    yes: string;\n    no: string;\n    error: (keywords: { yes: string; no: string }) => string;\n  };\n  style: {\n    answer: (text: string) => string;\n    message: (text: string, status: 'idle' | 'done' | 'loading') => string;\n    defaultAnswer: (text: string) => string;\n    confirmDefault: (text: string) => string;\n  };\n};\n```\n\nThe `keywords` property defines the words accepted as \"yes\" and \"no\". Matching is\nprefix-based and case-insensitive, and the first character of each word is shown in\nthe hint (e.g. `Y/n`). The matched word is also displayed once the prompt is answered.\n\nThe built-in `y`/`n`/`yes`/`no` answers are always accepted, whatever the keywords\nare. Unrecognized input shows the `keywords.error` message instead of silently\nfalling back on the default answer.\n\nOverriding `keywords` is how `@inquirer/i18n` localizes the prompt:\n\n```ts\nconfirm({\n  message: '¿Continuar?',\n  theme: {\n    keywords: { yes: 'Sí', no: 'No' },\n  },\n});\n```\n\nThe `confirmDefault` style marks the character representing the default answer in the\nhint. By default it uppercases the character (`Y/n`); for scripts without case\n(e.g. Chinese) it highlights the character with a color instead.\n\n# License\n\nCopyright (c) 2023 Simon Boudrias (twitter: [@vaxilart](https://twitter.com/Vaxilart))<br/>\nLicensed under the MIT license.\n","publish_time":1791135722432,"_cnpm_publish_time":1791135722432,"dist-tags":{"latest":"6.4.0"}}