Journal Link to task: typing after a keyboard choice still appends to the title (follow-up to #480)

オープン 初心者向け
#484 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
76/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
csharp, react
領域
frontend

調査の方向性

TaskTypeahead.tsx とそのテストを読み、handleSelect、handleKeyDown、handleInputChange に注目してください。矢印キーと Enter でタスクを選択し、その後、文字を入力するか ArrowDown を押して再現します。フォーカスが入力欄に残っている状態で Escape を押した場合も確認してください。次のキー入力で選択中のタイトルが置き換わり、ArrowDown でタイトルが選択された状態のリストが再び開けば完了です。

索引モデルが issue の本文から書いたものです。

説明

Follow-up to #480 (PR #483), found in the plan review of PR #483 and listed by the builder as a follow-up candidate. Web only (TaskFlow.Web). Not groomed yet.

Problem

#480 fixed the "Link to task" picker (TaskTypeahead) so that focusing (Tab) or clicking the input on a linked daily log row selects the prefilled title, and the first keystroke replaces it. The keyboard path after choosing a task was not covered by any acceptance criterion and still has the original bug:

  1. In the picker, choose a task with the arrow keys and Enter. handleSelect sets inputValue to '' and closes the list. Focus stays in the input, which shows the new title (displayValue is selectedTitle while closed), with nothing selected.
  2. Type 42. handleInputChange receives <title>42, so the filter is the title plus the new characters and task #42 is not found. This is the bug #480 fixed for focus and click.
  3. Or press ArrowDown instead. The list reopens with inputValue still '', so the title disappears from the input instead of being shown selected.

A mouse click at step 2 works, because #483's click path reopens the list and selects the title.

Expected

After choosing a task by keyboard, the next keystroke replaces the title, and ArrowDown reopens the list with the chosen title shown and selected. This matches what a click does after a selection.

Notes

  • Web only: TaskTypeahead.tsx (handleSelect, handleKeyDown, handleInputChange) and its tests.
  • Builds on PR #483 (#480), so it comes after that merges.
  • The builder's suggestion: on a keyboard reopen, set inputValue to selectedTitle and select it.
  • Check the same path after Escape when onEscape keeps focus in the input.
  • Minor: clicking the input first, or clearing the text, works around it.
主要言語
C#
スター
1
フォーク
0
平均マージ
2時間 28分
マージ済み PR(30日)
107

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

nevridge/TaskFlow のほかの issue

nevridge/TaskFlow の issue をすべて見る

似ている issue

C# の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。