pnp / pnp/sp-dev-fx-controls-react

DatePicker: TimeConvention.Hour24 doesn't affect on Time Dropdown

Open
#551 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status:tracked type:bug
Dominant language
TypeScript
Stars
433
Forks
418
Avg merge
5d 6m
Merged PRs (30d)
19

Description

Category

[ ] Enhancement

[x] Bug

[ ] Question

Version

Please specify what version of the library you are using: [1.17.0]

Expected / Desired Behavior / Question

If we select 24-hour time format and dropdown as time control the dropdown should show 0-23.

Observed Behavior

The dropdown shows 1AM - 12AM, 1PM - 12PM

Steps to Reproduce
<DateTimePicker timeConvention={TimeConvention.Hour24} timeDisplayControlType={TimeDisplayControlType.Dropdown} />

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the DateTimePicker implementation and trace how timeConvention and timeDisplayControlType are handled when the control is a dropdown. Reproduce the TypeScript example from the issue, then verify that Hour24 displays hours from 0 through 23 rather than AM/PM values.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.