[Request] Retrieve the partial user input on text prompt cancelation
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 48/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- nodejs, typescript
- 領域
- cli
調査の方向性
@clack/prompts の text メソッドと、issue で言及されている TextPrompt のカスタマイズから始めます。キャンセルが発生したときに部分的な入力を利用できるかを追跡し、次に、呼び出し元が空でない入力を取得でき、繰り返される空のキャンセルを区別できるようにキャンセル結果を定義します。既存の text prompt の動作が維持されることを確認します。
索引モデルが issue の本文から書いたものです。
説明
Is your feature request related to a problem? Please describe.
Currently, when using the @clack/prompts text prompt, all that is returned is either the user entered value (if submitted) or the cancel symbol (if canceled). When the request is canceled, there is no way to know what the user had typed up to that point.
Describe the solution you'd like
I would like to get a way to retrieve what the user had for input when it canceled the request. This is to implement a feature similar to the node CLI, where canceling with a non-empty value clears the input, while canceling with an empty value twice in a row triggers an exit.
Describe alternatives you've considered
For now I have to treat empty and non-empty values in the same way. I was considering re-implementing the text method, but feels a lot of work (the great TextPrompt customization would need to be duplicated) and I'm not even sure if the data would be available there to begin with.
- 主要言語
- TypeScript
- スター
- 8.1k
- フォーク
- 217
- 平均マージ
- 1日 11時間
- マージ済み PR(30日)
- 5
環境構築
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
bombshell-dev/clack のほかの issue
-
難易度 5/5 1週間以上 初心者へのやさしさ 30/100
bombshell-dev/clack#597 ·
-
rfc: accessible modeオープンenhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
bombshell-dev/clack#585 · コメント 1 件 · リアクション 1 件 ·
-
bug
難易度 3/5 1〜2日 初心者へのやさしさ 68/100
bombshell-dev/clack#573 · コメント 1 件 · リアクション 2 件 ·
-
enhancement
難易度 3/5 1〜2日 初心者へのやさしさ 62/100
bombshell-dev/clack#565 · コメント 1 件 · リアクション 1 件 ·
-
enhancement
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
bombshell-dev/clack#564 · リアクション 1 件 ·
bombshell-dev/clack の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
diegosouzapw/OmniRoute#14869 ·
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 94/100
メンテナーはふだん 1 日以内に返信
-
status: waiting triage
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
freeCodeCamp/freeCodeCamp#70412 ·
メンテナーはふだん 1 日以内に返信
-
Mend: dependency security vulnerability untriaged
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
opensearch-project/OpenSearch-Dashboards#12816 ·
メンテナーはふだん 1 日以内に返信