@ornikar/kitt-universal 9.46.1 → 9.46.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/definitions/forms/DatePicker/reducers/keyboardDatePickerReducer.d.ts.map +1 -1
- package/dist/index-browser-all.es.android.js +8 -3
- package/dist/index-browser-all.es.android.js.map +1 -1
- package/dist/index-browser-all.es.ios.js +8 -3
- package/dist/index-browser-all.es.ios.js.map +1 -1
- package/dist/index-browser-all.es.js +8 -3
- package/dist/index-browser-all.es.js.map +1 -1
- package/dist/index-browser-all.es.web.js +8 -3
- package/dist/index-browser-all.es.web.js.map +1 -1
- package/dist/index-node-14.17.cjs.js +8 -3
- package/dist/index-node-14.17.cjs.js.map +1 -1
- package/dist/index-node-14.17.cjs.web.js +8 -3
- package/dist/index-node-14.17.cjs.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +3 -3
|
@@ -2650,6 +2650,11 @@ function getYearInInterval(value, minDate, maxDate) {
|
|
|
2650
2650
|
return value !== undefined ? Math.max(minValue, Math.min(maxValue, value)) : value;
|
|
2651
2651
|
}
|
|
2652
2652
|
|
|
2653
|
+
function getValueToDisplayedString(value) {
|
|
2654
|
+
// We exclude the undefined value since 0 is a valid number
|
|
2655
|
+
if (value === undefined) return '';
|
|
2656
|
+
return value.toString();
|
|
2657
|
+
}
|
|
2653
2658
|
const keyboardDatePickerReducer = (state, action) => {
|
|
2654
2659
|
switch (action.type) {
|
|
2655
2660
|
case 'day-change':
|
|
@@ -2660,7 +2665,7 @@ const keyboardDatePickerReducer = (state, action) => {
|
|
|
2660
2665
|
return {
|
|
2661
2666
|
...state,
|
|
2662
2667
|
currentDay: nextDay,
|
|
2663
|
-
displayedDay: nextDay
|
|
2668
|
+
displayedDay: getValueToDisplayedString(nextDay)
|
|
2664
2669
|
};
|
|
2665
2670
|
}
|
|
2666
2671
|
case 'month-change':
|
|
@@ -2671,7 +2676,7 @@ const keyboardDatePickerReducer = (state, action) => {
|
|
|
2671
2676
|
return {
|
|
2672
2677
|
...state,
|
|
2673
2678
|
currentMonth: nextMonth,
|
|
2674
|
-
displayedMonth: nextMonth
|
|
2679
|
+
displayedMonth: getValueToDisplayedString(nextMonth)
|
|
2675
2680
|
};
|
|
2676
2681
|
}
|
|
2677
2682
|
case 'year-change':
|
|
@@ -2682,7 +2687,7 @@ const keyboardDatePickerReducer = (state, action) => {
|
|
|
2682
2687
|
return {
|
|
2683
2688
|
...state,
|
|
2684
2689
|
currentYear: nextYear,
|
|
2685
|
-
displayedYear: nextYear
|
|
2690
|
+
displayedYear: getValueToDisplayedString(nextYear)
|
|
2686
2691
|
};
|
|
2687
2692
|
}
|
|
2688
2693
|
case 'day-blur':
|