[READ-ONLY] Mirror of https://github.com/bombshell-dev/docs. bomb.sh/docs
0

Configure Feed

Select the types of activity you want to include in your feed.

docs: add multi-line text and update text/password sections (#39)

* docs: add multi-line text and update text/password sections

* deps: update clack

authored by

Willow (GHOST) and committed by
GitHub
(May 11, 2026, 6:53 PM -0500) e78749e3 94570577

+75 -30
+2 -2
package.json
··· 14 14 "dependencies": { 15 15 "@astrojs/starlight": "^0.37.1", 16 16 "@bomb.sh/args": "^0.3.1", 17 - "@clack/core": "^1.2.0", 18 - "@clack/prompts": "^1.2.0", 17 + "@clack/core": "^1.3.0", 18 + "@clack/prompts": "^1.3.0", 19 19 "@types/node": "^22.19.3", 20 20 "@webcontainer/api": "^1.6.1", 21 21 "@webcontainer/snapshot": "^0.1.0",
+27 -25
pnpm-lock.yaml
··· 15 15 specifier: ^0.3.1 16 16 version: 0.3.1 17 17 '@clack/core': 18 - specifier: ^1.2.0 19 - version: 1.2.0 18 + specifier: ^1.3.0 19 + version: 1.3.0 20 20 '@clack/prompts': 21 - specifier: ^1.2.0 22 - version: 1.2.0 21 + specifier: ^1.3.0 22 + version: 1.3.0 23 23 '@types/node': 24 24 specifier: ^22.19.3 25 25 version: 22.19.3 ··· 128 128 resolution: {integrity: sha512-8XqW8xGn++Eqqbz3e9wKuK7mxryeRjs4LOHLxbh2lwKeSbuNR4NFifDZT4KzvjU6HMOPbiNTsWpniK5EJfTWkg==} 129 129 engines: {node: '>=18'} 130 130 131 - '@clack/core@1.2.0': 132 - resolution: {integrity: sha512-qfxof/3T3t9DPU/Rj3OmcFyZInceqj/NVtO9rwIuJqCUgh32gwPjpFQQp/ben07qKlhpwq7GzfWpST4qdJ5Drg==} 131 + '@clack/core@1.3.0': 132 + resolution: {integrity: sha512-xJPHpAmEQUBrXSLx0gF+q5K/IyihXpsHZcha+jB+tyahsKRK3Dxo4D0coZDewHo12NhiuzC3dTtMPbm53GEAAA==} 133 + engines: {node: '>= 20.12.0'} 133 134 134 - '@clack/prompts@1.2.0': 135 - resolution: {integrity: sha512-4jmztR9fMqPMjz6H/UZXj0zEmE43ha1euENwkckKKel4XpSfokExPo5AiVStdHSAlHekz4d0CA/r45Ok1E4D3w==} 135 + '@clack/prompts@1.3.0': 136 + resolution: {integrity: sha512-GgcWwRCs/xPtaqlMy8qRhPnZf9vlWcWZNHAitnVQ3yk7JmSralSiq5q07yaffYE8SogtDm7zFeKccx1QNVARpw==} 137 + engines: {node: '>= 20.12.0'} 136 138 137 139 '@cloudflare/kv-asset-handler@0.4.2': 138 140 resolution: {integrity: sha512-SIOD2DxrRRwQ+jgzlXCqoEFiKOFqaPjhnNTGKXSRLvp1HiOvapLaFG2kEr9dYQTYe8rKrd9uvDUzmAITeNyaHQ==} ··· 1439 1441 fast-deep-equal@3.1.3: 1440 1442 resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} 1441 1443 1442 - fast-string-truncated-width@1.2.1: 1443 - resolution: {integrity: sha512-Q9acT/+Uu3GwGj+5w/zsGuQjh9O1TyywhIwAxHudtWrgF09nHOPrvTLhQevPbttcxjr/SNN7mJmfOw/B1bXgow==} 1444 + fast-string-truncated-width@3.0.3: 1445 + resolution: {integrity: sha512-0jjjIEL6+0jag3l2XWWizO64/aZVtpiGE3t0Zgqxv0DPuxiMjvB3M24fCyhZUO4KomJQPj3LTSUnDP3GpdwC0g==} 1444 1446 1445 - fast-string-width@1.1.0: 1446 - resolution: {integrity: sha512-O3fwIVIH5gKB38QNbdg+3760ZmGz0SZMgvwJbA1b2TGXceKE6A2cOlfogh1iw8lr049zPyd7YADHy+B7U4W9bQ==} 1447 + fast-string-width@3.0.2: 1448 + resolution: {integrity: sha512-gX8LrtNEI5hq8DVUfRQMbr5lpaS4nMIWV+7XEbXk2b8kiQIizgnlr12B4dA3ZEx3308ze0O4Q1R+cHts8kyUJg==} 1447 1449 1448 - fast-wrap-ansi@0.1.6: 1449 - resolution: {integrity: sha512-HlUwET7a5gqjURj70D5jl7aC3Zmy4weA1SHUfM0JFI0Ptq987NH2TwbBFLoERhfwk+E+eaq4EK3jXoT+R3yp3w==} 1450 + fast-wrap-ansi@0.2.0: 1451 + resolution: {integrity: sha512-rLV8JHxTyhVmFYhBJuMujcrHqOT2cnO5Zxj37qROj23CP39GXubJRBUFF0z8KFK77Uc0SukZUf7JZhsVEQ6n8w==} 1450 1452 1451 1453 fdir@6.5.0: 1452 1454 resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} ··· 2554 2556 dependencies: 2555 2557 fontkit: 2.0.4 2556 2558 2557 - '@clack/core@1.2.0': 2559 + '@clack/core@1.3.0': 2558 2560 dependencies: 2559 - fast-wrap-ansi: 0.1.6 2561 + fast-wrap-ansi: 0.2.0 2560 2562 sisteransi: 1.0.5 2561 2563 2562 - '@clack/prompts@1.2.0': 2564 + '@clack/prompts@1.3.0': 2563 2565 dependencies: 2564 - '@clack/core': 1.2.0 2565 - fast-string-width: 1.1.0 2566 - fast-wrap-ansi: 0.1.6 2566 + '@clack/core': 1.3.0 2567 + fast-string-width: 3.0.2 2568 + fast-wrap-ansi: 0.2.0 2567 2569 sisteransi: 1.0.5 2568 2570 2569 2571 '@cloudflare/kv-asset-handler@0.4.2': {} ··· 3679 3681 3680 3682 fast-deep-equal@3.1.3: {} 3681 3683 3682 - fast-string-truncated-width@1.2.1: {} 3684 + fast-string-truncated-width@3.0.3: {} 3683 3685 3684 - fast-string-width@1.1.0: 3686 + fast-string-width@3.0.2: 3685 3687 dependencies: 3686 - fast-string-truncated-width: 1.2.1 3688 + fast-string-truncated-width: 3.0.3 3687 3689 3688 - fast-wrap-ansi@0.1.6: 3690 + fast-wrap-ansi@0.2.0: 3689 3691 dependencies: 3690 - fast-string-width: 1.1.0 3692 + fast-string-width: 3.0.2 3691 3693 3692 3694 fdir@6.5.0(picomatch@4.0.3): 3693 3695 optionalDependencies:
+46 -3
src/content/docs/clack/packages/prompts.mdx
··· 103 103 104 104 ### Text Input 105 105 106 + The text prompt accepts a single line of text. 107 + 106 108 ```ts twoslash 107 109 // @errors: 2339 18048 108 110 import { text } from '@clack/prompts'; ··· 122 124 <font color="#06989A">│</font> <span style="background-color:#FFFFFF"><font color="#181818">J</font></span><font color="#AAAAAA">ohn Doe</font> 123 125 <font color="#06989A">└</font></pre> 124 126 127 + Options: 128 + 129 + - `message`: The prompt message shown to the user above the input. 130 + - `placeholder`: A visual hint shown when the field has no content. 131 + - `defaultValue`: A fallback value returned when the user provides nothing (empty input). 132 + - `initialValue`: The starting value shown when the prompt first renders. Users can edit this value before submitting. 133 + - `validate`: A function that validates user input. Return a `string` or `Error` to show as a validation error, or `undefined` to accept the result. 134 + - All [Common Options](#common-options) 135 + 125 136 ### Password Input 137 + 138 + Behaves like the text component, but the input is masked. 126 139 127 140 ```ts twoslash 128 141 import { password } from '@clack/prompts'; ··· 147 160 <font color="#06989A">└</font></pre> 148 161 149 162 Options: 150 - - `message`: The prompt message to display 151 - - `mask`: Character used to mask input (default: `'▪'`) 152 - - `clearOnError`: When `true`, clears the input field when validation fails (useful for security) 163 + 164 + - `message`: The prompt message or question shown to the user above the input. 165 + - `mask`: Character to use for masking input. Default: `'▪/•'`. 166 + - `validate`: A function that validates user input. Return a `string` or `Error` to show as a validation error, or `undefined` to accept the result. 167 + - `clearOnError`: When enabled it causes the input to be cleared if/when validation fails. Default: `false`. 168 + - All [Common Options](#common-options) 169 + 170 + Common options (`withGuide`, `signal`, `input`, `output`) are also supported. 171 + 172 + ### Multi-line Text 173 + 174 + The multi-line component accepts multiple lines of text input. By default, pressing Enter twice submits the input. 175 + 176 + ```ts twoslash 177 + import { multiline } from '@clack/prompts'; 178 + 179 + const bio = await multiline({ 180 + message: 'Enter your bio', 181 + placeholder: 'Tell us about yourself...', 182 + showSubmit: true, 183 + }); 184 + ``` 185 + 186 + <pre class="cli-preview"><font color="#555753">│</font> 187 + <font color="#06989A">◆</font> Enter your bio 188 + <font color="#06989A">│</font> <span style="background-color:#FFFFFF"><font color="#181818">T</font></span><font color="#AAAAAA">ell us about yourself...</font> 189 + <font color="#06989A">└</font> 190 + <font color="#AAAAAA"> [ submit ]</font></pre> 191 + 192 + Options: 193 + 194 + - `showSubmit`: When enabled it shows a `[ submit ]` button that can be focused with tab. By default, pressing Enter twice submits the input. Default: `false`. 195 + - All [Text Options](#text-input) 153 196 154 197 ### Selection 155 198