patternfly / patternfly/patternfly-react
DatePicker: specify time zone for today's date (current)
まだ誰も着手していません。
- 主要言語
- TypeScript
- スター
- 862
- フォーク
- 392
- 平均マージ
- 4日 8時間
- マージ済み PR(30日)
- 9
説明
Describe the enhancement or change
We propose adding a property to the DatePicker (and CalendarMonth) components to specify the time zone to be applied when determining today's date.
Details
In our application, users can specify the time zone they are working in.
For instance, a user located in the PST time zone may collaborate with users in the UK and choose to use the UTC time zone within the application.
If the user sets the time zone to UTC (01:02, 21 November), the application may still highlight the 20th because it reflects the local date based on the user's computer settings rather than the selected UTC time zone (17:02, 20 November).
When the user changes their computer’s clock to UTC, then the today's date is updated to the 21st as expected.
Is this request originating from a Red Hat product team? If so, which ones and is there any sort of deadline for this enhancement?
No
Any other information?
Link to hardcoded today's date: https://github.com/patternfly/patternfly-react/blob/main/packages/react-core/src/components/CalendarMonth/CalendarMonth.tsx#L122
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
packages/react-core/src/components/CalendarMonth/CalendarMonth.tsx のハードコードされた今日の日付付近から始め、DatePicker と CalendarMonth が現在の日をどのように決定しているかを追跡します。Issue の UTC の例に基づいてタイムゾーンプロパティの動作を定義し、今日の日付の強調表示がコンピューターのローカル設定ではなく、選択されたタイムゾーンに従うことを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- react, typescript
- 領域
- frontend
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 42/100