Skip to content

Commit d07aae3

Browse files
committed
Merge branch 'c-eiser13-issue-576-datetime' into dev
2 parents 70bb2c2 + b2e7bd1 commit d07aae3

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/controls/dateTimePicker/DateTimePicker.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,15 @@ export class DateTimePicker extends React.Component<IDateTimePickerProps, IDateT
128128
if (hoursSplit[1] && hoursSplit[1].toLowerCase().indexOf("pm") !== -1) {
129129
hours += 12;
130130
if (hours === 24) {
131-
hours = 0;
131+
//this is noon - set to 12 not 0
132+
//hours = 0;
133+
hours = 12;
132134
}
133135
}
136+
else if (hours === 12) {
137+
//am - if hours == 12, set hours to 0 here
138+
hours = 0;
139+
}
134140
}
135141

136142
if (hours > 23) {

0 commit comments

Comments
 (0)