Datepicker is not allowing clearing date
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 45/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- react, typescript
- 領域
- frontend
調査の方向性
Datepicker コンポーネントから始め、クリアボタンがどのように onSelectedDateChanged を呼び出すかを追跡します。callback の現在の引数と元の値がどのように復元されるかを確認し、そのうえで issue に記載されたクリア操作の動作を定義し、日付の選択が引き続き通常どおり動作することを検証します。ユーザーが既存の日付をクリアでき、利用側でクリアと日付の選択を区別できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
- I have searched the Issues to see if this bug has already been reported
- I have tested the latest version
Summary
Currently, the Datepicker component in Flowbite-React allows users to select a date, but lacks a fully functional clear button that can reset the date to null. The clear button only resets the date to the original value. I propose adding a flag like isClearAction to the onSelectedDateChanged callback function. This flag would be set to true when the clear button is used, allowing developers to explicitly handle the clear action by setting the date to null if desired.
Example implementation:
<Controller
control={control}
name="birthday"
render={({ field: { onChange, value } }) => (
<Datepicker
onSelectedDateChanged={(date, isClear) => {
if (isClear) {
onChange(null); // Explicitly handle clear action
return;
}
onChange(date); // Handle date change normally
}}
placeholder="Please enter date"
ref={elementRef}
value={value ? moment(value).format('YYYY-MM-DD') : ''}
/>
)}
/>
This feature would enable developers to easily implement scenarios where a user might need to completely remove a previously selected date.
Context
In various applications, especially in forms involving date entries like event planning, user registrations, or bookings, having the capability to clear a date completely is crucial. Currently, without this feature, users of our application cannot remove a date once selected; they can only change it. This limitation affects the flexibility and user experience of the application. By implementing this feature, we will provide a more robust and intuitive interaction for users who need to reset their date selections entirely.
- 主要言語
- TypeScript
- スター
- 2.1k
- フォーク
- 502
- 平均マージ
- 19時間 16分
- マージ済み PR(30日)
- 2
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
themesberg/flowbite-react のほかの issue
-
fix(Carousel): can't give dynamic children to Carousel対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン:bug: bug
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
themesberg/flowbite-react#1469 · コメント 1 件 ·
-
Pagination is broken if there is only one page対応中かも @Mukilan1600 が 1019 日前に担当しました。 オープン:bug: bug confirmed good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
themesberg/flowbite-react#1048 · コメント 7 件 · リアクション 1 件 ·
-
:books: documentation help wanted
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
themesberg/flowbite-react#1696 · コメント 2 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 15/100
themesberg/flowbite-react#1693 ·
-
NavbarCollapse closes when toggling a MegaMenuDropdown on mobile再び着手できるかも @sarthak-11231 が 43 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 58/100
themesberg/flowbite-react#1686 · コメント 2 件 ·
themesberg/flowbite-react の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
vercel-labs/durable-harness#53 ·
メンテナーはふだん 1 日以内に返信
-
[Bug]: Redesign tab bars ignore clicks on Linux: hidden chat layers keep window drag regions対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
experiência: a doc manda subir para o Micro do Supabase, mas não diz que exige plano pago nem quanto custa対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンarea/docs area/ui enhancement
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
melgarafael/DeskcommCRM#4098 ·
メンテナーはふだん 1 日以内に返信
-
bug ready-for-agent
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
kerti/balances-v2#801 ·
メンテナーはふだん 1 日以内に返信
-
lesson-submission pending-review
難易度 1/5 1時間未満 初心者へのやさしさ 84/100
Ikalus1988/MisakaNet#4510 ·
メンテナーはふだん 1 日以内に返信