@povio/ui 2.3.0-rc.18 → 2.3.0-rc.19
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/components/inputs/DateTime/DatePicker/DatePicker.d.ts +1 -0
- package/dist/components/inputs/DateTime/DatePicker/DatePicker.js +6 -4
- package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.d.ts +1 -0
- package/dist/components/inputs/DateTime/DateRangePicker/DateRangePicker.js +6 -4
- package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.d.ts +1 -0
- package/dist/components/inputs/DateTime/DateTimePicker/DateTimePicker.js +6 -4
- package/dist/components/inputs/DateTime/TimePicker/TimePicker.d.ts +1 -0
- package/dist/components/inputs/DateTime/TimePicker/TimePicker.js +193 -185
- package/dist/components/inputs/DateTime/shared/Calendar.js +49 -47
- package/dist/components/inputs/DateTime/shared/CalendarCell.d.ts +2 -1
- package/dist/components/inputs/DateTime/shared/CalendarCell.js +199 -181
- package/dist/components/inputs/DateTime/shared/CalendarGrid.d.ts +2 -1
- package/dist/components/inputs/DateTime/shared/CalendarGrid.js +59 -55
- package/dist/components/inputs/DateTime/shared/DatePickerInput.d.ts +2 -1
- package/dist/components/inputs/DateTime/shared/DatePickerInput.js +143 -134
- package/dist/components/inputs/DateTime/shared/TimePickerInput.d.ts +2 -1
- package/dist/components/inputs/DateTime/shared/TimePickerInput.js +44 -43
- package/dist/config/uiConfig.context.d.ts +1 -1
- package/dist/config/uiConfig.context.js +1 -0
- package/package.json +1 -1
|
@@ -5,6 +5,7 @@ import { DateValue } from 'react-aria';
|
|
|
5
5
|
interface CalendarGridProps extends AriaCalendarGridProps {
|
|
6
6
|
state: CalendarState | RangeCalendarState;
|
|
7
7
|
onApply?: (selectedDate?: DateValue) => void;
|
|
8
|
+
onDoubleClickApply?: (selectedDate?: DateValue) => void;
|
|
8
9
|
offset?: {
|
|
9
10
|
months?: number;
|
|
10
11
|
};
|
|
@@ -21,5 +22,5 @@ interface CalendarGridProps extends AriaCalendarGridProps {
|
|
|
21
22
|
onKeyboardNavigation?: (event: KeyboardEvent, date: DateValue) => boolean;
|
|
22
23
|
calendarSide?: "left" | "right";
|
|
23
24
|
}
|
|
24
|
-
export declare const CalendarGrid: ({ state, onApply, shouldCloseOnSelect, offset, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, className, calendarSide, ...props }: CalendarGridProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export declare const CalendarGrid: ({ state, onApply, onDoubleClickApply, shouldCloseOnSelect, offset, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, className, calendarSide, ...props }: CalendarGridProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
26
|
export {};
|
|
@@ -14,13 +14,14 @@ var WEEK_INDICES = [
|
|
|
14
14
|
5
|
|
15
15
|
];
|
|
16
16
|
var CalendarGrid = (t0) => {
|
|
17
|
-
const $ = c(
|
|
17
|
+
const $ = c(37);
|
|
18
18
|
let calendarSide;
|
|
19
19
|
let className;
|
|
20
20
|
let hoverDate;
|
|
21
21
|
let onApply;
|
|
22
22
|
let onDateHover;
|
|
23
23
|
let onDateSelection;
|
|
24
|
+
let onDoubleClickApply;
|
|
24
25
|
let onKeyboardNavigation;
|
|
25
26
|
let props;
|
|
26
27
|
let rangeSelection;
|
|
@@ -28,7 +29,7 @@ var CalendarGrid = (t0) => {
|
|
|
28
29
|
let state;
|
|
29
30
|
let t1;
|
|
30
31
|
if ($[0] !== t0) {
|
|
31
|
-
({state, onApply, shouldCloseOnSelect, offset: t1, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, className, calendarSide, ...props} = t0);
|
|
32
|
+
({state, onApply, onDoubleClickApply, shouldCloseOnSelect, offset: t1, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, className, calendarSide, ...props} = t0);
|
|
32
33
|
$[0] = t0;
|
|
33
34
|
$[1] = calendarSide;
|
|
34
35
|
$[2] = className;
|
|
@@ -36,12 +37,13 @@ var CalendarGrid = (t0) => {
|
|
|
36
37
|
$[4] = onApply;
|
|
37
38
|
$[5] = onDateHover;
|
|
38
39
|
$[6] = onDateSelection;
|
|
39
|
-
$[7] =
|
|
40
|
-
$[8] =
|
|
41
|
-
$[9] =
|
|
42
|
-
$[10] =
|
|
43
|
-
$[11] =
|
|
44
|
-
$[12] =
|
|
40
|
+
$[7] = onDoubleClickApply;
|
|
41
|
+
$[8] = onKeyboardNavigation;
|
|
42
|
+
$[9] = props;
|
|
43
|
+
$[10] = rangeSelection;
|
|
44
|
+
$[11] = shouldCloseOnSelect;
|
|
45
|
+
$[12] = state;
|
|
46
|
+
$[13] = t1;
|
|
45
47
|
} else {
|
|
46
48
|
calendarSide = $[1];
|
|
47
49
|
className = $[2];
|
|
@@ -49,69 +51,71 @@ var CalendarGrid = (t0) => {
|
|
|
49
51
|
onApply = $[4];
|
|
50
52
|
onDateHover = $[5];
|
|
51
53
|
onDateSelection = $[6];
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
54
|
+
onDoubleClickApply = $[7];
|
|
55
|
+
onKeyboardNavigation = $[8];
|
|
56
|
+
props = $[9];
|
|
57
|
+
rangeSelection = $[10];
|
|
58
|
+
shouldCloseOnSelect = $[11];
|
|
59
|
+
state = $[12];
|
|
60
|
+
t1 = $[13];
|
|
58
61
|
}
|
|
59
62
|
const offset = t1 === void 0 ? {} : t1;
|
|
60
63
|
let t2;
|
|
61
|
-
if ($[
|
|
64
|
+
if ($[14] !== props) {
|
|
62
65
|
t2 = {
|
|
63
66
|
...props,
|
|
64
67
|
weekdayStyle: "short"
|
|
65
68
|
};
|
|
66
|
-
$[
|
|
67
|
-
$[
|
|
68
|
-
} else t2 = $[
|
|
69
|
+
$[14] = props;
|
|
70
|
+
$[15] = t2;
|
|
71
|
+
} else t2 = $[15];
|
|
69
72
|
const { gridProps, headerProps, weekDays } = useCalendarGrid(t2, state);
|
|
70
73
|
const startDate = state.visibleRange.start.add(offset);
|
|
71
74
|
let t3;
|
|
72
|
-
if ($[
|
|
75
|
+
if ($[16] !== calendarSide || $[17] !== onDateSelection) {
|
|
73
76
|
t3 = (date) => {
|
|
74
77
|
onDateSelection?.(date, calendarSide);
|
|
75
78
|
};
|
|
76
|
-
$[
|
|
77
|
-
$[
|
|
78
|
-
$[
|
|
79
|
-
} else t3 = $[
|
|
79
|
+
$[16] = calendarSide;
|
|
80
|
+
$[17] = onDateSelection;
|
|
81
|
+
$[18] = t3;
|
|
82
|
+
} else t3 = $[18];
|
|
80
83
|
const handleDateSelection = t3;
|
|
81
84
|
let t4;
|
|
82
|
-
if ($[
|
|
85
|
+
if ($[19] !== className) {
|
|
83
86
|
t4 = clsx("h-72 w-full px-3 py-1 md:w-80", className);
|
|
84
|
-
$[
|
|
85
|
-
$[
|
|
86
|
-
} else t4 = $[
|
|
87
|
+
$[19] = className;
|
|
88
|
+
$[20] = t4;
|
|
89
|
+
} else t4 = $[20];
|
|
87
90
|
const t5 = "0";
|
|
88
91
|
const t6 = "w-full";
|
|
89
92
|
let t7;
|
|
90
|
-
if ($[
|
|
93
|
+
if ($[21] !== weekDays) {
|
|
91
94
|
t7 = weekDays.map(_temp);
|
|
92
|
-
$[
|
|
93
|
-
$[
|
|
94
|
-
} else t7 = $[
|
|
95
|
+
$[21] = weekDays;
|
|
96
|
+
$[22] = t7;
|
|
97
|
+
} else t7 = $[22];
|
|
95
98
|
let t8;
|
|
96
|
-
if ($[
|
|
99
|
+
if ($[23] !== t7) {
|
|
97
100
|
t8 = /* @__PURE__ */ jsx("tr", { children: t7 });
|
|
98
|
-
$[
|
|
99
|
-
$[
|
|
100
|
-
} else t8 = $[
|
|
101
|
+
$[23] = t7;
|
|
102
|
+
$[24] = t8;
|
|
103
|
+
} else t8 = $[24];
|
|
101
104
|
let t9;
|
|
102
|
-
if ($[
|
|
105
|
+
if ($[25] !== headerProps || $[26] !== t8) {
|
|
103
106
|
t9 = /* @__PURE__ */ jsx("thead", {
|
|
104
107
|
...headerProps,
|
|
105
108
|
children: t8
|
|
106
109
|
});
|
|
107
|
-
$[
|
|
108
|
-
$[
|
|
109
|
-
$[
|
|
110
|
-
} else t9 = $[
|
|
110
|
+
$[25] = headerProps;
|
|
111
|
+
$[26] = t8;
|
|
112
|
+
$[27] = t9;
|
|
113
|
+
} else t9 = $[27];
|
|
111
114
|
const t10 = WEEK_INDICES.map((weekIndex) => /* @__PURE__ */ jsx("tr", { children: state.getDatesInWeek(weekIndex, startDate).map((date_0, i) => date_0 ? /* @__PURE__ */ jsx(CalendarCell, {
|
|
112
115
|
state,
|
|
113
116
|
date: date_0,
|
|
114
117
|
onApply,
|
|
118
|
+
onDoubleClickApply,
|
|
115
119
|
shouldCloseOnSelect,
|
|
116
120
|
onDateSelection: handleDateSelection,
|
|
117
121
|
onDateHover,
|
|
@@ -120,34 +124,34 @@ var CalendarGrid = (t0) => {
|
|
|
120
124
|
onKeyboardNavigation
|
|
121
125
|
}, i) : /* @__PURE__ */ jsx("td", {}, i)) }, weekIndex));
|
|
122
126
|
let t11;
|
|
123
|
-
if ($[
|
|
127
|
+
if ($[28] !== t10) {
|
|
124
128
|
t11 = /* @__PURE__ */ jsx("tbody", { children: t10 });
|
|
125
|
-
$[
|
|
126
|
-
$[
|
|
127
|
-
} else t11 = $[
|
|
129
|
+
$[28] = t10;
|
|
130
|
+
$[29] = t11;
|
|
131
|
+
} else t11 = $[29];
|
|
128
132
|
let t12;
|
|
129
|
-
if ($[
|
|
133
|
+
if ($[30] !== gridProps || $[31] !== t11 || $[32] !== t9) {
|
|
130
134
|
t12 = /* @__PURE__ */ jsxs("table", {
|
|
131
135
|
...gridProps,
|
|
132
136
|
cellPadding: t5,
|
|
133
137
|
className: t6,
|
|
134
138
|
children: [t9, t11]
|
|
135
139
|
});
|
|
136
|
-
$[
|
|
137
|
-
$[
|
|
138
|
-
$[
|
|
139
|
-
$[
|
|
140
|
-
} else t12 = $[
|
|
140
|
+
$[30] = gridProps;
|
|
141
|
+
$[31] = t11;
|
|
142
|
+
$[32] = t9;
|
|
143
|
+
$[33] = t12;
|
|
144
|
+
} else t12 = $[33];
|
|
141
145
|
let t13;
|
|
142
|
-
if ($[
|
|
146
|
+
if ($[34] !== t12 || $[35] !== t4) {
|
|
143
147
|
t13 = /* @__PURE__ */ jsx("div", {
|
|
144
148
|
className: t4,
|
|
145
149
|
children: t12
|
|
146
150
|
});
|
|
147
|
-
$[
|
|
148
|
-
$[
|
|
149
|
-
$[
|
|
150
|
-
} else t13 = $[
|
|
151
|
+
$[34] = t12;
|
|
152
|
+
$[35] = t4;
|
|
153
|
+
$[36] = t13;
|
|
154
|
+
} else t13 = $[36];
|
|
151
155
|
return t13;
|
|
152
156
|
};
|
|
153
157
|
function _temp(day) {
|
|
@@ -33,6 +33,7 @@ interface DatePickerInputProps extends InputVariantProps {
|
|
|
33
33
|
timeZone?: string;
|
|
34
34
|
isTimeOptional?: boolean;
|
|
35
35
|
format?: string;
|
|
36
|
+
fireBlurOnChange?: boolean;
|
|
36
37
|
}
|
|
37
|
-
export declare const DatePickerInput: ({ ref, as, groupProps, fieldProps, endFieldProps, buttonProps, isDisabled, isInvalid, disableDropdown, variant, size, isDateTime, isClearable, headerProps, todayIcon, todayIconButtonSize, todayIconPlacement, isDirty, isRequired, disableManualEntry, autoFixYear, placeholder, className, onOpenDropdown, dateGranularity, timeZone, isTimeOptional, format, ...props }: DatePickerInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
38
|
+
export declare const DatePickerInput: ({ ref, as, groupProps, fieldProps, endFieldProps, buttonProps, isDisabled, isInvalid, disableDropdown, variant, size, isDateTime, isClearable, headerProps, todayIcon, todayIconButtonSize, todayIconPlacement, isDirty, isRequired, disableManualEntry, autoFixYear, placeholder, className, onOpenDropdown, dateGranularity, timeZone, isTimeOptional, format, fireBlurOnChange, ...props }: DatePickerInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
38
39
|
export {};
|
|
@@ -18,8 +18,8 @@ import { useFocusVisible, useFocusWithin, useHover } from "react-aria";
|
|
|
18
18
|
import { today } from "@internationalized/date";
|
|
19
19
|
//#region src/components/inputs/DateTime/shared/DatePickerInput.tsx
|
|
20
20
|
var DatePickerInput = (t0) => {
|
|
21
|
-
const $ = c(
|
|
22
|
-
const { ref, as, groupProps, fieldProps, endFieldProps, buttonProps, isDisabled, isInvalid, disableDropdown, variant, size, isDateTime, isClearable, headerProps, todayIcon, todayIconButtonSize: t1, todayIconPlacement: t2, isDirty, isRequired, disableManualEntry, autoFixYear: t3, placeholder, className, onOpenDropdown, dateGranularity: t4, timeZone, isTimeOptional: t5, format, ...props } = t0;
|
|
21
|
+
const $ = c(99);
|
|
22
|
+
const { ref, as, groupProps, fieldProps, endFieldProps, buttonProps, isDisabled, isInvalid, disableDropdown, variant, size, isDateTime, isClearable, headerProps, todayIcon, todayIconButtonSize: t1, todayIconPlacement: t2, isDirty, isRequired, disableManualEntry, autoFixYear: t3, placeholder, className, onOpenDropdown, dateGranularity: t4, timeZone, isTimeOptional: t5, format, fireBlurOnChange, ...props } = t0;
|
|
23
23
|
const todayIconButtonSize = t1 === void 0 ? "none" : t1;
|
|
24
24
|
const todayIconPlacement = t2 === void 0 ? "content" : t2;
|
|
25
25
|
const autoFixYear = t3 === void 0 ? false : t3;
|
|
@@ -57,7 +57,7 @@ var DatePickerInput = (t0) => {
|
|
|
57
57
|
const endDateFieldRef = useRef(null);
|
|
58
58
|
const containerRef = useRef(null);
|
|
59
59
|
let t8;
|
|
60
|
-
if ($[4] !== endFieldProps || $[5] !== fieldProps) {
|
|
60
|
+
if ($[4] !== endFieldProps || $[5] !== fieldProps || $[6] !== fireBlurOnChange) {
|
|
61
61
|
t8 = () => ({
|
|
62
62
|
clear: () => {
|
|
63
63
|
dateFieldRef.current?.clearField();
|
|
@@ -65,42 +65,48 @@ var DatePickerInput = (t0) => {
|
|
|
65
65
|
endDateFieldRef.current?.clearField();
|
|
66
66
|
if (endFieldProps) endFieldProps.onChange?.(null);
|
|
67
67
|
setCanClear(false);
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
if (fireBlurOnChange) {
|
|
69
|
+
fieldProps.onBlur?.(null);
|
|
70
|
+
endFieldProps?.onBlur?.(null);
|
|
71
|
+
}
|
|
70
72
|
},
|
|
71
73
|
getContainer: () => containerRef.current
|
|
72
74
|
});
|
|
73
75
|
$[4] = endFieldProps;
|
|
74
76
|
$[5] = fieldProps;
|
|
75
|
-
$[6] =
|
|
76
|
-
|
|
77
|
+
$[6] = fireBlurOnChange;
|
|
78
|
+
$[7] = t8;
|
|
79
|
+
} else t8 = $[7];
|
|
77
80
|
useImperativeHandle(ref, t8);
|
|
78
81
|
let t9;
|
|
79
|
-
if ($[
|
|
82
|
+
if ($[8] === Symbol.for("react.memo_cache_sentinel")) {
|
|
80
83
|
t9 = (canClearInput) => {
|
|
81
84
|
setCanClear(canClearInput);
|
|
82
85
|
};
|
|
83
|
-
$[
|
|
84
|
-
} else t9 = $[
|
|
86
|
+
$[8] = t9;
|
|
87
|
+
} else t9 = $[8];
|
|
85
88
|
const onClearChange = t9;
|
|
86
89
|
let t10;
|
|
87
|
-
if ($[
|
|
90
|
+
if ($[9] !== endFieldProps || $[10] !== fieldProps || $[11] !== fireBlurOnChange) {
|
|
88
91
|
t10 = () => {
|
|
89
92
|
dateFieldRef.current?.clearField();
|
|
90
93
|
fieldProps.onChange?.(null);
|
|
91
94
|
endDateFieldRef.current?.clearField();
|
|
92
95
|
endFieldProps?.onChange?.(null);
|
|
93
96
|
setCanClear(false);
|
|
94
|
-
|
|
95
|
-
|
|
97
|
+
if (fireBlurOnChange) {
|
|
98
|
+
fieldProps.onBlur?.(null);
|
|
99
|
+
endFieldProps?.onBlur?.(null);
|
|
100
|
+
}
|
|
96
101
|
};
|
|
97
|
-
$[
|
|
98
|
-
$[
|
|
99
|
-
$[
|
|
100
|
-
|
|
102
|
+
$[9] = endFieldProps;
|
|
103
|
+
$[10] = fieldProps;
|
|
104
|
+
$[11] = fireBlurOnChange;
|
|
105
|
+
$[12] = t10;
|
|
106
|
+
} else t10 = $[12];
|
|
101
107
|
const onClear = t10;
|
|
102
108
|
let t11;
|
|
103
|
-
if ($[
|
|
109
|
+
if ($[13] !== effectiveTimeZone || $[14] !== endFieldProps || $[15] !== fieldProps || $[16] !== fireBlurOnChange || $[17] !== isDateTime) {
|
|
104
110
|
t11 = () => {
|
|
105
111
|
if (isDateTime) {
|
|
106
112
|
const calendarDateTime = DateTimeUtils.getCurrentWallClockCalendarDateTime();
|
|
@@ -110,26 +116,29 @@ var DatePickerInput = (t0) => {
|
|
|
110
116
|
fieldProps.onChange?.(today(effectiveTimeZone));
|
|
111
117
|
if (endFieldProps) endFieldProps.onChange?.(today(effectiveTimeZone));
|
|
112
118
|
}
|
|
113
|
-
|
|
114
|
-
|
|
119
|
+
if (fireBlurOnChange) {
|
|
120
|
+
fieldProps.onBlur?.(null);
|
|
121
|
+
endFieldProps?.onBlur?.(null);
|
|
122
|
+
}
|
|
115
123
|
};
|
|
116
|
-
$[
|
|
117
|
-
$[
|
|
118
|
-
$[
|
|
119
|
-
$[
|
|
120
|
-
$[
|
|
121
|
-
|
|
124
|
+
$[13] = effectiveTimeZone;
|
|
125
|
+
$[14] = endFieldProps;
|
|
126
|
+
$[15] = fieldProps;
|
|
127
|
+
$[16] = fireBlurOnChange;
|
|
128
|
+
$[17] = isDateTime;
|
|
129
|
+
$[18] = t11;
|
|
130
|
+
} else t11 = $[18];
|
|
122
131
|
const onToday = t11;
|
|
123
132
|
const hidePlaceholder = as === "floating" && !fieldProps.value && !isFocused;
|
|
124
133
|
let t12;
|
|
125
|
-
if ($[
|
|
134
|
+
if ($[19] !== todayIcon) {
|
|
126
135
|
t12 = getDatePickerTodayIcon(todayIcon);
|
|
127
|
-
$[
|
|
128
|
-
$[
|
|
129
|
-
} else t12 = $[
|
|
136
|
+
$[19] = todayIcon;
|
|
137
|
+
$[20] = t12;
|
|
138
|
+
} else t12 = $[20];
|
|
130
139
|
const todayIconComponent = t12;
|
|
131
140
|
let t13;
|
|
132
|
-
if ($[
|
|
141
|
+
if ($[21] !== onToday || $[22] !== todayIconButtonSize || $[23] !== todayIconComponent) {
|
|
133
142
|
t13 = todayIconComponent ? /* @__PURE__ */ jsx(InlineIconButton, {
|
|
134
143
|
label: "",
|
|
135
144
|
icon: todayIconComponent,
|
|
@@ -137,11 +146,11 @@ var DatePickerInput = (t0) => {
|
|
|
137
146
|
onPress: onToday,
|
|
138
147
|
className: "relative z-1 !border-none"
|
|
139
148
|
}) : null;
|
|
140
|
-
$[
|
|
141
|
-
$[
|
|
142
|
-
$[
|
|
143
|
-
$[
|
|
144
|
-
} else t13 = $[
|
|
149
|
+
$[21] = onToday;
|
|
150
|
+
$[22] = todayIconButtonSize;
|
|
151
|
+
$[23] = todayIconComponent;
|
|
152
|
+
$[24] = t13;
|
|
153
|
+
} else t13 = $[24];
|
|
145
154
|
const todayIconButton = t13;
|
|
146
155
|
const shouldRenderTodayIconWithFieldLabel = todayIconPlacement === "fieldLabel";
|
|
147
156
|
const pickerIcon = isDateTime ? uiConfig.dateInput.dateTimeIcon : uiConfig.dateInput.calendarIcon;
|
|
@@ -162,49 +171,49 @@ var DatePickerInput = (t0) => {
|
|
|
162
171
|
const t24 = isRequired || void 0;
|
|
163
172
|
const t25 = fieldProps.value !== null || void 0;
|
|
164
173
|
let t26;
|
|
165
|
-
if ($[
|
|
174
|
+
if ($[25] !== as || $[26] !== inputSizeCva || $[27] !== size) {
|
|
166
175
|
t26 = clsx("flex w-full items-center gap-input-gap-input-text-to-elements pr-0!", inputSizeCva({
|
|
167
176
|
size,
|
|
168
177
|
as
|
|
169
178
|
}));
|
|
170
|
-
$[
|
|
171
|
-
$[
|
|
172
|
-
$[
|
|
173
|
-
$[
|
|
174
|
-
} else t26 = $[
|
|
179
|
+
$[25] = as;
|
|
180
|
+
$[26] = inputSizeCva;
|
|
181
|
+
$[27] = size;
|
|
182
|
+
$[28] = t26;
|
|
183
|
+
} else t26 = $[28];
|
|
175
184
|
let t27;
|
|
176
|
-
if ($[
|
|
185
|
+
if ($[29] !== as || $[30] !== headerProps) {
|
|
177
186
|
t27 = as && ["filter", "floating"].includes(as) && headerProps && /* @__PURE__ */ jsx(FormFieldLabel, {
|
|
178
187
|
as,
|
|
179
188
|
...headerProps
|
|
180
189
|
});
|
|
181
|
-
$[
|
|
182
|
-
$[
|
|
183
|
-
$[
|
|
184
|
-
} else t27 = $[
|
|
190
|
+
$[29] = as;
|
|
191
|
+
$[30] = headerProps;
|
|
192
|
+
$[31] = t27;
|
|
193
|
+
} else t27 = $[31];
|
|
185
194
|
const t28 = shouldRenderTodayIconWithFieldLabel && todayIconButton;
|
|
186
195
|
let t29;
|
|
187
|
-
if ($[
|
|
196
|
+
if ($[32] !== datePickerInputContentRowCva || $[33] !== size) {
|
|
188
197
|
t29 = datePickerInputContentRowCva({ size });
|
|
189
|
-
$[
|
|
190
|
-
$[
|
|
191
|
-
$[
|
|
192
|
-
} else t29 = $[
|
|
198
|
+
$[32] = datePickerInputContentRowCva;
|
|
199
|
+
$[33] = size;
|
|
200
|
+
$[34] = t29;
|
|
201
|
+
} else t29 = $[34];
|
|
193
202
|
let t30;
|
|
194
|
-
if ($[
|
|
203
|
+
if ($[35] !== disableManualEntry || $[36] !== isDisabled || $[37] !== onOpenDropdown) {
|
|
195
204
|
t30 = disableManualEntry && /* @__PURE__ */ jsx(Button, {
|
|
196
205
|
onPress: onOpenDropdown,
|
|
197
206
|
className: "absolute inset-0 z-0",
|
|
198
207
|
isDisabled
|
|
199
208
|
});
|
|
200
|
-
$[
|
|
201
|
-
$[
|
|
202
|
-
$[
|
|
203
|
-
$[
|
|
204
|
-
} else t30 = $[
|
|
209
|
+
$[35] = disableManualEntry;
|
|
210
|
+
$[36] = isDisabled;
|
|
211
|
+
$[37] = onOpenDropdown;
|
|
212
|
+
$[38] = t30;
|
|
213
|
+
} else t30 = $[38];
|
|
205
214
|
const t31 = !shouldRenderTodayIconWithFieldLabel && todayIconButton;
|
|
206
215
|
let t32;
|
|
207
|
-
if ($[
|
|
216
|
+
if ($[39] !== as || $[40] !== dateGranularity || $[41] !== disableManualEntry || $[42] !== effectiveTimeZone || $[43] !== endFieldProps || $[44] !== fieldProps || $[45] !== format || $[46] !== hidePlaceholder || $[47] !== isDisabled || $[48] !== isInvalid || $[49] !== isTimeOptional || $[50] !== onClearChange || $[51] !== placeholder) {
|
|
208
217
|
t32 = disableManualEntry && placeholder && !fieldProps.value ? /* @__PURE__ */ jsx(Typography, {
|
|
209
218
|
size: "label-1",
|
|
210
219
|
className: "text-text-default-3",
|
|
@@ -236,23 +245,23 @@ var DatePickerInput = (t0) => {
|
|
|
236
245
|
format,
|
|
237
246
|
timeZone: effectiveTimeZone
|
|
238
247
|
})] })] });
|
|
239
|
-
$[
|
|
240
|
-
$[
|
|
241
|
-
$[
|
|
242
|
-
$[
|
|
243
|
-
$[
|
|
244
|
-
$[
|
|
245
|
-
$[
|
|
246
|
-
$[
|
|
247
|
-
$[
|
|
248
|
-
$[
|
|
249
|
-
$[
|
|
250
|
-
$[
|
|
251
|
-
$[
|
|
252
|
-
$[
|
|
253
|
-
} else t32 = $[
|
|
248
|
+
$[39] = as;
|
|
249
|
+
$[40] = dateGranularity;
|
|
250
|
+
$[41] = disableManualEntry;
|
|
251
|
+
$[42] = effectiveTimeZone;
|
|
252
|
+
$[43] = endFieldProps;
|
|
253
|
+
$[44] = fieldProps;
|
|
254
|
+
$[45] = format;
|
|
255
|
+
$[46] = hidePlaceholder;
|
|
256
|
+
$[47] = isDisabled;
|
|
257
|
+
$[48] = isInvalid;
|
|
258
|
+
$[49] = isTimeOptional;
|
|
259
|
+
$[50] = onClearChange;
|
|
260
|
+
$[51] = placeholder;
|
|
261
|
+
$[52] = t32;
|
|
262
|
+
} else t32 = $[52];
|
|
254
263
|
let t33;
|
|
255
|
-
if ($[
|
|
264
|
+
if ($[53] !== t29 || $[54] !== t30 || $[55] !== t31 || $[56] !== t32) {
|
|
256
265
|
t33 = /* @__PURE__ */ jsxs("div", {
|
|
257
266
|
className: t29,
|
|
258
267
|
children: [
|
|
@@ -261,14 +270,14 @@ var DatePickerInput = (t0) => {
|
|
|
261
270
|
t32
|
|
262
271
|
]
|
|
263
272
|
});
|
|
264
|
-
$[
|
|
265
|
-
$[
|
|
266
|
-
$[
|
|
267
|
-
$[
|
|
268
|
-
$[
|
|
269
|
-
} else t33 = $[
|
|
273
|
+
$[53] = t29;
|
|
274
|
+
$[54] = t30;
|
|
275
|
+
$[55] = t31;
|
|
276
|
+
$[56] = t32;
|
|
277
|
+
$[57] = t33;
|
|
278
|
+
} else t33 = $[57];
|
|
270
279
|
let t34;
|
|
271
|
-
if ($[
|
|
280
|
+
if ($[58] !== t26 || $[59] !== t27 || $[60] !== t28 || $[61] !== t33) {
|
|
272
281
|
t34 = /* @__PURE__ */ jsxs("div", {
|
|
273
282
|
className: t26,
|
|
274
283
|
children: [
|
|
@@ -277,36 +286,36 @@ var DatePickerInput = (t0) => {
|
|
|
277
286
|
t33
|
|
278
287
|
]
|
|
279
288
|
});
|
|
280
|
-
$[
|
|
281
|
-
$[
|
|
282
|
-
$[
|
|
283
|
-
$[
|
|
284
|
-
$[
|
|
285
|
-
} else t34 = $[
|
|
289
|
+
$[58] = t26;
|
|
290
|
+
$[59] = t27;
|
|
291
|
+
$[60] = t28;
|
|
292
|
+
$[61] = t33;
|
|
293
|
+
$[62] = t34;
|
|
294
|
+
} else t34 = $[62];
|
|
286
295
|
let t35;
|
|
287
|
-
if ($[
|
|
296
|
+
if ($[63] !== as || $[64] !== inputSizeCva || $[65] !== size) {
|
|
288
297
|
t35 = clsx(inputSizeCva({
|
|
289
298
|
size,
|
|
290
299
|
as
|
|
291
300
|
}), "flex items-center gap-input-gap-trailing-elements py-0! pl-0!");
|
|
292
|
-
$[
|
|
293
|
-
$[
|
|
294
|
-
$[
|
|
295
|
-
$[
|
|
296
|
-
} else t35 = $[
|
|
301
|
+
$[63] = as;
|
|
302
|
+
$[64] = inputSizeCva;
|
|
303
|
+
$[65] = size;
|
|
304
|
+
$[66] = t35;
|
|
305
|
+
} else t35 = $[66];
|
|
297
306
|
let t36;
|
|
298
|
-
if ($[
|
|
307
|
+
if ($[67] !== canClear || $[68] !== isClearable || $[69] !== onClear) {
|
|
299
308
|
t36 = isClearable && /* @__PURE__ */ jsx(InputClear, {
|
|
300
309
|
onClear,
|
|
301
310
|
show: canClear
|
|
302
311
|
});
|
|
303
|
-
$[
|
|
304
|
-
$[
|
|
305
|
-
$[
|
|
306
|
-
$[
|
|
307
|
-
} else t36 = $[
|
|
312
|
+
$[67] = canClear;
|
|
313
|
+
$[68] = isClearable;
|
|
314
|
+
$[69] = onClear;
|
|
315
|
+
$[70] = t36;
|
|
316
|
+
} else t36 = $[70];
|
|
308
317
|
let t37;
|
|
309
|
-
if ($[
|
|
318
|
+
if ($[71] !== buttonProps || $[72] !== disableDropdown || $[73] !== disableManualEntry || $[74] !== isDisabled || $[75] !== pickerIcon) {
|
|
310
319
|
t37 = (!disableDropdown || disableManualEntry) && /* @__PURE__ */ jsx(InlineIconButton, {
|
|
311
320
|
label: "",
|
|
312
321
|
color: "secondary",
|
|
@@ -315,26 +324,26 @@ var DatePickerInput = (t0) => {
|
|
|
315
324
|
isDisabled,
|
|
316
325
|
className: "border-0!"
|
|
317
326
|
});
|
|
318
|
-
$[
|
|
319
|
-
$[
|
|
320
|
-
$[
|
|
321
|
-
$[
|
|
322
|
-
$[
|
|
323
|
-
$[
|
|
324
|
-
} else t37 = $[
|
|
327
|
+
$[71] = buttonProps;
|
|
328
|
+
$[72] = disableDropdown;
|
|
329
|
+
$[73] = disableManualEntry;
|
|
330
|
+
$[74] = isDisabled;
|
|
331
|
+
$[75] = pickerIcon;
|
|
332
|
+
$[76] = t37;
|
|
333
|
+
} else t37 = $[76];
|
|
325
334
|
let t38;
|
|
326
|
-
if ($[
|
|
335
|
+
if ($[77] !== t35 || $[78] !== t36 || $[79] !== t37) {
|
|
327
336
|
t38 = /* @__PURE__ */ jsxs("div", {
|
|
328
337
|
className: t35,
|
|
329
338
|
children: [t36, t37]
|
|
330
339
|
});
|
|
331
|
-
$[
|
|
332
|
-
$[
|
|
333
|
-
$[
|
|
334
|
-
$[
|
|
335
|
-
} else t38 = $[
|
|
340
|
+
$[77] = t35;
|
|
341
|
+
$[78] = t36;
|
|
342
|
+
$[79] = t37;
|
|
343
|
+
$[80] = t38;
|
|
344
|
+
} else t38 = $[80];
|
|
336
345
|
let t39;
|
|
337
|
-
if ($[
|
|
346
|
+
if ($[81] !== focusWithinProps || $[82] !== groupProps || $[83] !== hoverProps || $[84] !== t14 || $[85] !== t15 || $[86] !== t16 || $[87] !== t17 || $[88] !== t18 || $[89] !== t19 || $[90] !== t20 || $[91] !== t21 || $[92] !== t22 || $[93] !== t23 || $[94] !== t24 || $[95] !== t25 || $[96] !== t34 || $[97] !== t38) {
|
|
338
347
|
t39 = /* @__PURE__ */ jsxs("div", {
|
|
339
348
|
ref: containerRef,
|
|
340
349
|
className: t14,
|
|
@@ -356,25 +365,25 @@ var DatePickerInput = (t0) => {
|
|
|
356
365
|
...hoverProps,
|
|
357
366
|
children: [t34, t38]
|
|
358
367
|
});
|
|
359
|
-
$[
|
|
360
|
-
$[
|
|
361
|
-
$[
|
|
362
|
-
$[
|
|
363
|
-
$[
|
|
364
|
-
$[
|
|
365
|
-
$[
|
|
366
|
-
$[
|
|
367
|
-
$[
|
|
368
|
-
$[
|
|
369
|
-
$[
|
|
370
|
-
$[
|
|
371
|
-
$[
|
|
372
|
-
$[
|
|
373
|
-
$[
|
|
374
|
-
$[
|
|
375
|
-
$[
|
|
376
|
-
$[
|
|
377
|
-
} else t39 = $[
|
|
368
|
+
$[81] = focusWithinProps;
|
|
369
|
+
$[82] = groupProps;
|
|
370
|
+
$[83] = hoverProps;
|
|
371
|
+
$[84] = t14;
|
|
372
|
+
$[85] = t15;
|
|
373
|
+
$[86] = t16;
|
|
374
|
+
$[87] = t17;
|
|
375
|
+
$[88] = t18;
|
|
376
|
+
$[89] = t19;
|
|
377
|
+
$[90] = t20;
|
|
378
|
+
$[91] = t21;
|
|
379
|
+
$[92] = t22;
|
|
380
|
+
$[93] = t23;
|
|
381
|
+
$[94] = t24;
|
|
382
|
+
$[95] = t25;
|
|
383
|
+
$[96] = t34;
|
|
384
|
+
$[97] = t38;
|
|
385
|
+
$[98] = t39;
|
|
386
|
+
} else t39 = $[98];
|
|
378
387
|
return t39;
|
|
379
388
|
};
|
|
380
389
|
//#endregion
|
|
@@ -18,6 +18,7 @@ interface DatePickerInputProps extends InputVariantProps {
|
|
|
18
18
|
placeholder?: string;
|
|
19
19
|
className?: string;
|
|
20
20
|
onPress: () => void;
|
|
21
|
+
fireBlurOnChange?: boolean;
|
|
21
22
|
}
|
|
22
|
-
export declare const TimePickerInput: ({ ref, as, fieldProps, state, isDisabled, isDirty, isRequired, isInvalid, disableDropdown, variant, size, isClearable, headerProps, disableManualEntry, placeholder, className, onPress, ...props }: DatePickerInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export declare const TimePickerInput: ({ ref, as, fieldProps, state, isDisabled, isDirty, isRequired, isInvalid, disableDropdown, variant, size, isClearable, headerProps, disableManualEntry, placeholder, className, onPress, fireBlurOnChange, ...props }: DatePickerInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
23
24
|
export {};
|