@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.
@@ -10,7 +10,7 @@ import { useEffect, useState } from "react";
10
10
  import { useCalendar } from "@react-aria/calendar";
11
11
  //#region src/components/inputs/DateTime/shared/Calendar.tsx
12
12
  var Calendar = (t0) => {
13
- const $ = c(88);
13
+ const $ = c(89);
14
14
  let className;
15
15
  let datePickerState;
16
16
  let hourCycle;
@@ -226,7 +226,7 @@ var Calendar = (t0) => {
226
226
  } else t14 = $[51];
227
227
  const handleDateChange = t14;
228
228
  let t15;
229
- if ($[52] !== datePickerState || $[53] !== granularity || $[54] !== handleDateChange || $[55] !== includesTime || $[56] !== onDateSelection || $[57] !== onMonthSelectionChange || $[58] !== onMonthYearChange || $[59] !== onMonthYearCommit || $[60] !== onYearSelectionChange || $[61] !== props.state || $[62] !== selectedDate || $[63] !== toggleState) {
229
+ if ($[52] !== datePickerState || $[53] !== granularity || $[54] !== handleDateChange || $[55] !== includesTime || $[56] !== onApply || $[57] !== onDateSelection || $[58] !== onMonthSelectionChange || $[59] !== onMonthYearChange || $[60] !== onMonthYearCommit || $[61] !== onYearSelectionChange || $[62] !== props.state || $[63] !== selectedDate || $[64] !== toggleState) {
230
230
  t15 = () => {
231
231
  if (!toggleState) {
232
232
  if (granularity === "month") return /* @__PURE__ */ jsx(MonthPicker, {
@@ -246,6 +246,7 @@ var Calendar = (t0) => {
246
246
  return /* @__PURE__ */ jsx(CalendarGrid, {
247
247
  state: props.state,
248
248
  onApply: handleDateChange,
249
+ onDoubleClickApply: !includesTime ? onApply : void 0,
249
250
  onDateSelection
250
251
  });
251
252
  }
@@ -282,25 +283,26 @@ var Calendar = (t0) => {
282
283
  $[53] = granularity;
283
284
  $[54] = handleDateChange;
284
285
  $[55] = includesTime;
285
- $[56] = onDateSelection;
286
- $[57] = onMonthSelectionChange;
287
- $[58] = onMonthYearChange;
288
- $[59] = onMonthYearCommit;
289
- $[60] = onYearSelectionChange;
290
- $[61] = props.state;
291
- $[62] = selectedDate;
292
- $[63] = toggleState;
293
- $[64] = t15;
294
- } else t15 = $[64];
286
+ $[56] = onApply;
287
+ $[57] = onDateSelection;
288
+ $[58] = onMonthSelectionChange;
289
+ $[59] = onMonthYearChange;
290
+ $[60] = onMonthYearCommit;
291
+ $[61] = onYearSelectionChange;
292
+ $[62] = props.state;
293
+ $[63] = selectedDate;
294
+ $[64] = toggleState;
295
+ $[65] = t15;
296
+ } else t15 = $[65];
295
297
  const getContent = t15;
296
298
  let t16;
297
- if ($[65] !== className) {
299
+ if ($[66] !== className) {
298
300
  t16 = clsx("flex min-h-0 w-full flex-col items-center", className);
299
- $[65] = className;
300
- $[66] = t16;
301
- } else t16 = $[66];
301
+ $[66] = className;
302
+ $[67] = t16;
303
+ } else t16 = $[67];
302
304
  let t17;
303
- if ($[67] !== datePickerState || $[68] !== granularity || $[69] !== headerNextButtonProps || $[70] !== headerPrevButtonProps || $[71] !== hourCycle || $[72] !== includesTime || $[73] !== props.state || $[74] !== toggleState) {
305
+ if ($[68] !== datePickerState || $[69] !== granularity || $[70] !== headerNextButtonProps || $[71] !== headerPrevButtonProps || $[72] !== hourCycle || $[73] !== includesTime || $[74] !== props.state || $[75] !== toggleState) {
304
306
  t17 = /* @__PURE__ */ jsx(CalendarHeader, {
305
307
  calendarState: props.state,
306
308
  datePickerState,
@@ -312,52 +314,52 @@ var Calendar = (t0) => {
312
314
  toggleState,
313
315
  setToggleState
314
316
  });
315
- $[67] = datePickerState;
316
- $[68] = granularity;
317
- $[69] = headerNextButtonProps;
318
- $[70] = headerPrevButtonProps;
319
- $[71] = hourCycle;
320
- $[72] = includesTime;
321
- $[73] = props.state;
322
- $[74] = toggleState;
323
- $[75] = t17;
324
- } else t17 = $[75];
317
+ $[68] = datePickerState;
318
+ $[69] = granularity;
319
+ $[70] = headerNextButtonProps;
320
+ $[71] = headerPrevButtonProps;
321
+ $[72] = hourCycle;
322
+ $[73] = includesTime;
323
+ $[74] = props.state;
324
+ $[75] = toggleState;
325
+ $[76] = t17;
326
+ } else t17 = $[76];
325
327
  const t18 = toggleState !== "year" && "pb-8 md:pb-0";
326
328
  let t19;
327
- if ($[76] !== t18) {
329
+ if ($[77] !== t18) {
328
330
  t19 = clsx("flex min-h-0 w-full flex-1 flex-col items-center", t18);
329
- $[76] = t18;
330
- $[77] = t19;
331
- } else t19 = $[77];
331
+ $[77] = t18;
332
+ $[78] = t19;
333
+ } else t19 = $[78];
332
334
  let t20;
333
- if ($[78] !== getContent) {
335
+ if ($[79] !== getContent) {
334
336
  t20 = getContent();
335
- $[78] = getContent;
336
- $[79] = t20;
337
- } else t20 = $[79];
337
+ $[79] = getContent;
338
+ $[80] = t20;
339
+ } else t20 = $[80];
338
340
  let t21;
339
- if ($[80] !== t19 || $[81] !== t20) {
341
+ if ($[81] !== t19 || $[82] !== t20) {
340
342
  t21 = /* @__PURE__ */ jsx("div", {
341
343
  className: t19,
342
344
  children: t20
343
345
  });
344
- $[80] = t19;
345
- $[81] = t20;
346
- $[82] = t21;
347
- } else t21 = $[82];
346
+ $[81] = t19;
347
+ $[82] = t20;
348
+ $[83] = t21;
349
+ } else t21 = $[83];
348
350
  let t22;
349
- if ($[83] !== calendarProps || $[84] !== t16 || $[85] !== t17 || $[86] !== t21) {
351
+ if ($[84] !== calendarProps || $[85] !== t16 || $[86] !== t17 || $[87] !== t21) {
350
352
  t22 = /* @__PURE__ */ jsxs("div", {
351
353
  ...calendarProps,
352
354
  className: t16,
353
355
  children: [t17, t21]
354
356
  });
355
- $[83] = calendarProps;
356
- $[84] = t16;
357
- $[85] = t17;
358
- $[86] = t21;
359
- $[87] = t22;
360
- } else t22 = $[87];
357
+ $[84] = calendarProps;
358
+ $[85] = t16;
359
+ $[86] = t17;
360
+ $[87] = t21;
361
+ $[88] = t22;
362
+ } else t22 = $[88];
361
363
  return t22;
362
364
  };
363
365
  //#endregion
@@ -5,6 +5,7 @@ import { DateValue } from 'react-aria';
5
5
  interface CalendarCellProps extends AriaCalendarCellProps {
6
6
  state: CalendarState | RangeCalendarState;
7
7
  onApply?: (selectedDate?: DateValue) => void;
8
+ onDoubleClickApply?: (selectedDate?: DateValue) => void;
8
9
  shouldCloseOnSelect?: boolean;
9
10
  onDateSelection?: (date: DateValue) => void;
10
11
  onDateHover?: (date: DateValue | null) => void;
@@ -16,5 +17,5 @@ interface CalendarCellProps extends AriaCalendarCellProps {
16
17
  hoverDate?: DateValue | null;
17
18
  onKeyboardNavigation?: (event: KeyboardEvent, date: DateValue) => boolean;
18
19
  }
19
- export declare const CalendarCell: ({ state, onApply, shouldCloseOnSelect, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, ...props }: CalendarCellProps) => import("react/jsx-runtime").JSX.Element;
20
+ export declare const CalendarCell: ({ state, onApply, onDoubleClickApply, shouldCloseOnSelect, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, ...props }: CalendarCellProps) => import("react/jsx-runtime").JSX.Element;
20
21
  export {};
@@ -12,59 +12,75 @@ var isRange = (state) => {
12
12
  return "highlightedRange" in state;
13
13
  };
14
14
  var CalendarCell = (t0) => {
15
- const $ = c(98);
15
+ const $ = c(104);
16
16
  let hoverDate;
17
17
  let onApply;
18
18
  let onDateHover;
19
19
  let onDateSelection;
20
+ let onDoubleClickApply;
20
21
  let onKeyboardNavigation;
21
22
  let props;
22
23
  let rangeSelection;
23
24
  let state;
24
25
  let t1;
25
26
  if ($[0] !== t0) {
26
- ({state, onApply, shouldCloseOnSelect: t1, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, ...props} = t0);
27
+ ({state, onApply, onDoubleClickApply, shouldCloseOnSelect: t1, onDateSelection, onDateHover, rangeSelection, hoverDate, onKeyboardNavigation, ...props} = t0);
27
28
  $[0] = t0;
28
29
  $[1] = hoverDate;
29
30
  $[2] = onApply;
30
31
  $[3] = onDateHover;
31
32
  $[4] = onDateSelection;
32
- $[5] = onKeyboardNavigation;
33
- $[6] = props;
34
- $[7] = rangeSelection;
35
- $[8] = state;
36
- $[9] = t1;
33
+ $[5] = onDoubleClickApply;
34
+ $[6] = onKeyboardNavigation;
35
+ $[7] = props;
36
+ $[8] = rangeSelection;
37
+ $[9] = state;
38
+ $[10] = t1;
37
39
  } else {
38
40
  hoverDate = $[1];
39
41
  onApply = $[2];
40
42
  onDateHover = $[3];
41
43
  onDateSelection = $[4];
42
- onKeyboardNavigation = $[5];
43
- props = $[6];
44
- rangeSelection = $[7];
45
- state = $[8];
46
- t1 = $[9];
44
+ onDoubleClickApply = $[5];
45
+ onKeyboardNavigation = $[6];
46
+ props = $[7];
47
+ rangeSelection = $[8];
48
+ state = $[9];
49
+ t1 = $[10];
47
50
  }
48
51
  const shouldCloseOnSelect = t1 === void 0 ? true : t1;
49
52
  const ref = useRef(null);
50
53
  const { cellProps, buttonProps, formattedDate, isSelected, isDisabled, isOutsideVisibleRange } = useCalendarCell(props, state, ref);
51
54
  const { focusProps } = useFocusRing();
52
55
  let t2;
53
- if ($[10] !== buttonProps || $[11] !== isDisabled || $[12] !== onApply || $[13] !== onDateSelection || $[14] !== props.date || $[15] !== shouldCloseOnSelect) {
56
+ if ($[11] !== buttonProps || $[12] !== isDisabled || $[13] !== onApply || $[14] !== onDateSelection || $[15] !== props.date || $[16] !== shouldCloseOnSelect) {
54
57
  t2 = (event) => {
55
58
  buttonProps.onClick?.(event);
56
59
  if (onDateSelection) onDateSelection(props.date);
57
60
  if (shouldCloseOnSelect && !isDisabled) onApply?.(props.date);
58
61
  };
59
- $[10] = buttonProps;
60
- $[11] = isDisabled;
61
- $[12] = onApply;
62
- $[13] = onDateSelection;
63
- $[14] = props.date;
64
- $[15] = shouldCloseOnSelect;
65
- $[16] = t2;
66
- } else t2 = $[16];
62
+ $[11] = buttonProps;
63
+ $[12] = isDisabled;
64
+ $[13] = onApply;
65
+ $[14] = onDateSelection;
66
+ $[15] = props.date;
67
+ $[16] = shouldCloseOnSelect;
68
+ $[17] = t2;
69
+ } else t2 = $[17];
67
70
  const onClick = t2;
71
+ let t3;
72
+ if ($[18] !== isDisabled || $[19] !== onDoubleClickApply || $[20] !== props.date) {
73
+ t3 = (event_0) => {
74
+ if (isDisabled) return;
75
+ event_0.preventDefault();
76
+ onDoubleClickApply?.(props.date);
77
+ };
78
+ $[18] = isDisabled;
79
+ $[19] = onDoubleClickApply;
80
+ $[20] = props.date;
81
+ $[21] = t3;
82
+ } else t3 = $[21];
83
+ const onDoubleClick = t3;
68
84
  let isSelectionStart;
69
85
  let isSelectionEnd;
70
86
  let isSelectedCell;
@@ -72,22 +88,22 @@ var CalendarCell = (t0) => {
72
88
  let isHoverRange = false;
73
89
  let isSelectingMode = false;
74
90
  if (rangeSelection?.start) {
75
- let t3;
76
- if ($[17] !== props.date || $[18] !== rangeSelection.start) {
77
- t3 = isSameDay(props.date, rangeSelection.start);
78
- $[17] = props.date;
79
- $[18] = rangeSelection.start;
80
- $[19] = t3;
81
- } else t3 = $[19];
82
- isSelectionStart = t3;
83
91
  let t4;
84
- if ($[20] !== props.date || $[21] !== rangeSelection.end) {
85
- t4 = rangeSelection.end ? isSameDay(props.date, rangeSelection.end) : false;
86
- $[20] = props.date;
87
- $[21] = rangeSelection.end;
88
- $[22] = t4;
89
- } else t4 = $[22];
90
- isSelectionEnd = t4;
92
+ if ($[22] !== props.date || $[23] !== rangeSelection.start) {
93
+ t4 = isSameDay(props.date, rangeSelection.start);
94
+ $[22] = props.date;
95
+ $[23] = rangeSelection.start;
96
+ $[24] = t4;
97
+ } else t4 = $[24];
98
+ isSelectionStart = t4;
99
+ let t5;
100
+ if ($[25] !== props.date || $[26] !== rangeSelection.end) {
101
+ t5 = rangeSelection.end ? isSameDay(props.date, rangeSelection.end) : false;
102
+ $[25] = props.date;
103
+ $[26] = rangeSelection.end;
104
+ $[27] = t5;
105
+ } else t5 = $[27];
106
+ isSelectionEnd = t5;
91
107
  isSelectedCell = isSelectionStart || isSelectionEnd;
92
108
  isSelectingMode = rangeSelection.isSelecting && !rangeSelection.end;
93
109
  if (rangeSelection.start && rangeSelection.end) {
@@ -107,44 +123,44 @@ var CalendarCell = (t0) => {
107
123
  isHoverRange = isAfterStart_0 && isBeforeEnd_0;
108
124
  }
109
125
  } else {
110
- let t3;
111
- if ($[23] !== isSelected || $[24] !== props.date || $[25] !== state) {
112
- t3 = isRange(state) && state.highlightedRange ? isSameDay(props.date, state.highlightedRange.start) : isSelected;
113
- $[23] = isSelected;
114
- $[24] = props.date;
115
- $[25] = state;
116
- $[26] = t3;
117
- } else t3 = $[26];
118
- isSelectionStart = t3;
119
126
  let t4;
120
- if ($[27] !== isSelected || $[28] !== props.date || $[29] !== state) {
121
- t4 = isRange(state) && state.highlightedRange ? isSameDay(props.date, state.highlightedRange.end) : isSelected;
122
- $[27] = isSelected;
123
- $[28] = props.date;
124
- $[29] = state;
125
- $[30] = t4;
126
- } else t4 = $[30];
127
- isSelectionEnd = t4;
127
+ if ($[28] !== isSelected || $[29] !== props.date || $[30] !== state) {
128
+ t4 = isRange(state) && state.highlightedRange ? isSameDay(props.date, state.highlightedRange.start) : isSelected;
129
+ $[28] = isSelected;
130
+ $[29] = props.date;
131
+ $[30] = state;
132
+ $[31] = t4;
133
+ } else t4 = $[31];
134
+ isSelectionStart = t4;
128
135
  let t5;
129
- if ($[31] !== isSelected || $[32] !== isSelectionEnd || $[33] !== isSelectionStart || $[34] !== state) {
130
- t5 = isSelectionStart || isSelectionEnd || !isRange(state) && isSelected;
131
- $[31] = isSelected;
132
- $[32] = isSelectionEnd;
133
- $[33] = isSelectionStart;
136
+ if ($[32] !== isSelected || $[33] !== props.date || $[34] !== state) {
137
+ t5 = isRange(state) && state.highlightedRange ? isSameDay(props.date, state.highlightedRange.end) : isSelected;
138
+ $[32] = isSelected;
139
+ $[33] = props.date;
134
140
  $[34] = state;
135
141
  $[35] = t5;
136
142
  } else t5 = $[35];
137
- isSelectedCell = t5;
143
+ isSelectionEnd = t5;
138
144
  let t6;
139
145
  if ($[36] !== isSelected || $[37] !== isSelectionEnd || $[38] !== isSelectionStart || $[39] !== state) {
140
- t6 = isRange(state) && isSelected && !isSelectionStart && !isSelectionEnd;
146
+ t6 = isSelectionStart || isSelectionEnd || !isRange(state) && isSelected;
141
147
  $[36] = isSelected;
142
148
  $[37] = isSelectionEnd;
143
149
  $[38] = isSelectionStart;
144
150
  $[39] = state;
145
151
  $[40] = t6;
146
152
  } else t6 = $[40];
147
- isInRange = t6;
153
+ isSelectedCell = t6;
154
+ let t7;
155
+ if ($[41] !== isSelected || $[42] !== isSelectionEnd || $[43] !== isSelectionStart || $[44] !== state) {
156
+ t7 = isRange(state) && isSelected && !isSelectionStart && !isSelectionEnd;
157
+ $[41] = isSelected;
158
+ $[42] = isSelectionEnd;
159
+ $[43] = isSelectionStart;
160
+ $[44] = state;
161
+ $[45] = t7;
162
+ } else t7 = $[45];
163
+ isInRange = t7;
148
164
  if (isRange(state) && state.highlightedRange && !isSelected) {
149
165
  const dateValue_1 = props.date;
150
166
  const isAfterStart_1 = dateValue_1.compare(state.highlightedRange.start) > 0;
@@ -152,9 +168,9 @@ var CalendarCell = (t0) => {
152
168
  isHoverRange = isAfterStart_1 && isBeforeEnd_1;
153
169
  }
154
170
  }
155
- let t3;
156
- if ($[41] !== isHoverRange || $[42] !== isInRange || $[43] !== isSelectedCell || $[44] !== isSelectingMode || $[45] !== isSelectionEnd || $[46] !== isSelectionStart) {
157
- t3 = {
171
+ let t4;
172
+ if ($[46] !== isHoverRange || $[47] !== isInRange || $[48] !== isSelectedCell || $[49] !== isSelectingMode || $[50] !== isSelectionEnd || $[51] !== isSelectionStart) {
173
+ t4 = {
158
174
  isSelectionStart,
159
175
  isSelectionEnd,
160
176
  isSelectedCell,
@@ -162,152 +178,154 @@ var CalendarCell = (t0) => {
162
178
  isHoverRange,
163
179
  isSelectingMode
164
180
  };
165
- $[41] = isHoverRange;
166
- $[42] = isInRange;
167
- $[43] = isSelectedCell;
168
- $[44] = isSelectingMode;
169
- $[45] = isSelectionEnd;
170
- $[46] = isSelectionStart;
171
- $[47] = t3;
172
- } else t3 = $[47];
173
- const selectionState = t3;
174
- let t4;
175
- if ($[48] !== isOutsideVisibleRange || $[49] !== isSelected || $[50] !== onApply || $[51] !== props.date || $[52] !== shouldCloseOnSelect || $[53] !== state) {
176
- t4 = (event_0, eventHandler) => {
181
+ $[46] = isHoverRange;
182
+ $[47] = isInRange;
183
+ $[48] = isSelectedCell;
184
+ $[49] = isSelectingMode;
185
+ $[50] = isSelectionEnd;
186
+ $[51] = isSelectionStart;
187
+ $[52] = t4;
188
+ } else t4 = $[52];
189
+ const selectionState = t4;
190
+ let t5;
191
+ if ($[53] !== isOutsideVisibleRange || $[54] !== isSelected || $[55] !== onApply || $[56] !== props.date || $[57] !== shouldCloseOnSelect || $[58] !== state) {
192
+ t5 = (event_1, eventHandler) => {
177
193
  if (isOutsideVisibleRange) {
178
194
  state.selectDate(props.date);
179
195
  state.setFocusedDate(props.date);
180
196
  }
181
- eventHandler?.(event_0);
197
+ eventHandler?.(event_1);
182
198
  if (isSelected && shouldCloseOnSelect) onApply?.(props.date);
183
199
  };
184
- $[48] = isOutsideVisibleRange;
185
- $[49] = isSelected;
186
- $[50] = onApply;
187
- $[51] = props.date;
188
- $[52] = shouldCloseOnSelect;
189
- $[53] = state;
190
- $[54] = t4;
191
- } else t4 = $[54];
192
- const handleEvent = t4;
193
- let t5;
194
- if ($[55] !== onDateHover || $[56] !== props.date || $[57] !== selectionState.isSelectingMode) {
195
- t5 = () => {
196
- if (onDateHover && selectionState.isSelectingMode) onDateHover(props.date);
197
- };
198
- $[55] = onDateHover;
200
+ $[53] = isOutsideVisibleRange;
201
+ $[54] = isSelected;
202
+ $[55] = onApply;
199
203
  $[56] = props.date;
200
- $[57] = selectionState.isSelectingMode;
201
- $[58] = t5;
202
- } else t5 = $[58];
203
- const onMouseEnter = t5;
204
+ $[57] = shouldCloseOnSelect;
205
+ $[58] = state;
206
+ $[59] = t5;
207
+ } else t5 = $[59];
208
+ const handleEvent = t5;
204
209
  let t6;
205
- if ($[59] !== onDateHover || $[60] !== selectionState.isSelectingMode) {
210
+ if ($[60] !== onDateHover || $[61] !== props.date || $[62] !== selectionState.isSelectingMode) {
206
211
  t6 = () => {
212
+ if (onDateHover && selectionState.isSelectingMode) onDateHover(props.date);
213
+ };
214
+ $[60] = onDateHover;
215
+ $[61] = props.date;
216
+ $[62] = selectionState.isSelectingMode;
217
+ $[63] = t6;
218
+ } else t6 = $[63];
219
+ const onMouseEnter = t6;
220
+ let t7;
221
+ if ($[64] !== onDateHover || $[65] !== selectionState.isSelectingMode) {
222
+ t7 = () => {
207
223
  if (onDateHover && selectionState.isSelectingMode) onDateHover(null);
208
224
  };
209
- $[59] = onDateHover;
210
- $[60] = selectionState.isSelectingMode;
211
- $[61] = t6;
212
- } else t6 = $[61];
213
- const onMouseLeave = t6;
225
+ $[64] = onDateHover;
226
+ $[65] = selectionState.isSelectingMode;
227
+ $[66] = t7;
228
+ } else t7 = $[66];
229
+ const onMouseLeave = t7;
214
230
  const { isSelectedCell: isSelectedCell_0, isInRange: isInRange_0, isHoverRange: isHoverRange_0, isSelectingMode: isSelectingMode_0, isSelectionStart: isSelectionStart_0, isSelectionEnd: isSelectionEnd_0 } = selectionState;
215
- const t7 = !isSelectedCell_0 && !isOutsideVisibleRange && "bg-elevation-fill-default-1 text-interactive-text-secondary-idle";
216
- const t8 = !isSelectedCell_0 && isOutsideVisibleRange && "bg-elevation-fill-default-1 text-interactive-text-secondary-disabled";
217
- const t9 = isSelectedCell_0 && !isOutsideVisibleRange && "bg-interactive-contained-primary-idle text-interactive-contained-primary-on-idle";
218
- const t10 = isSelectedCell_0 && !isOutsideVisibleRange && rangeSelection && !rangeSelection.isSelecting && isSelectionStart_0 && !isSelectionEnd_0 && "rounded-r-none";
219
- const t11 = isSelectedCell_0 && !isOutsideVisibleRange && rangeSelection && !rangeSelection.isSelecting && isSelectionEnd_0 && !isSelectionStart_0 && "rounded-l-none";
220
- const t12 = isDisabled && !isOutsideVisibleRange && "cursor-default";
221
- const t13 = isDisabled && "opacity-20";
222
- const t14 = !isSelectedCell_0 && !isInRange_0 && !isHoverRange_0 && !isSelectingMode_0 && !isDisabled && !isOutsideVisibleRange && "[@media(pointer:fine)]:hover:border-elevation-outline-default-1 [@media(pointer:fine)]:hover:text-interactive-text-secondary-hover";
223
- const t15 = isInRange_0 && !isOutsideVisibleRange && "!rounded-none !bg-elevation-fill-default-2 text-interactive-text-secondary-hover";
224
- const t16 = isHoverRange_0 && !isOutsideVisibleRange && "!rounded-none !bg-elevation-fill-default-2 text-interactive-text-secondary-hover";
225
- const t17 = !isInRange_0 && !isSelectedCell_0 && isSelectingMode_0 && "hover:bg-interactive-contained-primary-idle hover:text-interactive-text-primary-idle-inverted";
226
- const t18 = isSelectingMode_0 && !isSelectedCell_0 && !isInRange_0 && !isHoverRange_0 && !isDisabled && !isOutsideVisibleRange && "transition-all duration-75 hover:border-elevation-outline-default-1";
227
- let t19;
228
- if ($[62] !== t10 || $[63] !== t11 || $[64] !== t12 || $[65] !== t13 || $[66] !== t14 || $[67] !== t15 || $[68] !== t16 || $[69] !== t17 || $[70] !== t18 || $[71] !== t7 || $[72] !== t8 || $[73] !== t9) {
229
- t19 = clsx("mx-auto flex h-10 w-full max-w-10 items-center justify-center rounded-button-rounding-m p-2", "focus:outline-none focus-visible:outline-1 focus-visible:outline-interactive-contained-primary-focus focus-visible:outline-offset-1", "border border-transparent border-solid", t7, t8, t9, t10, t11, t12, t13, t14, t15, t16, t17, t18);
230
- $[62] = t10;
231
- $[63] = t11;
232
- $[64] = t12;
233
- $[65] = t13;
234
- $[66] = t14;
235
- $[67] = t15;
236
- $[68] = t16;
237
- $[69] = t17;
238
- $[70] = t18;
239
- $[71] = t7;
240
- $[72] = t8;
241
- $[73] = t9;
242
- $[74] = t19;
243
- } else t19 = $[74];
244
- const cellClassName = t19;
231
+ const t8 = !isSelectedCell_0 && !isOutsideVisibleRange && "bg-elevation-fill-default-1 text-interactive-text-secondary-idle";
232
+ const t9 = !isSelectedCell_0 && isOutsideVisibleRange && "bg-elevation-fill-default-1 text-interactive-text-secondary-disabled";
233
+ const t10 = isSelectedCell_0 && !isOutsideVisibleRange && "bg-interactive-contained-primary-idle text-interactive-contained-primary-on-idle";
234
+ const t11 = isSelectedCell_0 && !isOutsideVisibleRange && rangeSelection && !rangeSelection.isSelecting && isSelectionStart_0 && !isSelectionEnd_0 && "rounded-r-none";
235
+ const t12 = isSelectedCell_0 && !isOutsideVisibleRange && rangeSelection && !rangeSelection.isSelecting && isSelectionEnd_0 && !isSelectionStart_0 && "rounded-l-none";
236
+ const t13 = isDisabled && !isOutsideVisibleRange && "cursor-default";
237
+ const t14 = isDisabled && "opacity-20";
238
+ const t15 = !isSelectedCell_0 && !isInRange_0 && !isHoverRange_0 && !isSelectingMode_0 && !isDisabled && !isOutsideVisibleRange && "[@media(pointer:fine)]:hover:border-elevation-outline-default-1 [@media(pointer:fine)]:hover:text-interactive-text-secondary-hover";
239
+ const t16 = isInRange_0 && !isOutsideVisibleRange && "!rounded-none !bg-elevation-fill-default-2 text-interactive-text-secondary-hover";
240
+ const t17 = isHoverRange_0 && !isOutsideVisibleRange && "!rounded-none !bg-elevation-fill-default-2 text-interactive-text-secondary-hover";
241
+ const t18 = !isInRange_0 && !isSelectedCell_0 && isSelectingMode_0 && "hover:bg-interactive-contained-primary-idle hover:text-interactive-text-primary-idle-inverted";
242
+ const t19 = isSelectingMode_0 && !isSelectedCell_0 && !isInRange_0 && !isHoverRange_0 && !isDisabled && !isOutsideVisibleRange && "transition-all duration-75 hover:border-elevation-outline-default-1";
245
243
  let t20;
246
- if ($[75] !== buttonProps || $[76] !== focusProps) {
247
- t20 = mergeProps(buttonProps, focusProps);
248
- $[75] = buttonProps;
249
- $[76] = focusProps;
250
- $[77] = t20;
251
- } else t20 = $[77];
244
+ if ($[67] !== t10 || $[68] !== t11 || $[69] !== t12 || $[70] !== t13 || $[71] !== t14 || $[72] !== t15 || $[73] !== t16 || $[74] !== t17 || $[75] !== t18 || $[76] !== t19 || $[77] !== t8 || $[78] !== t9) {
245
+ t20 = clsx("mx-auto flex h-10 w-full max-w-10 items-center justify-center rounded-button-rounding-m p-2", "focus:outline-none focus-visible:outline-1 focus-visible:outline-interactive-contained-primary-focus focus-visible:outline-offset-1", "border border-transparent border-solid", t8, t9, t10, t11, t12, t13, t14, t15, t16, t17, t18, t19);
246
+ $[67] = t10;
247
+ $[68] = t11;
248
+ $[69] = t12;
249
+ $[70] = t13;
250
+ $[71] = t14;
251
+ $[72] = t15;
252
+ $[73] = t16;
253
+ $[74] = t17;
254
+ $[75] = t18;
255
+ $[76] = t19;
256
+ $[77] = t8;
257
+ $[78] = t9;
258
+ $[79] = t20;
259
+ } else t20 = $[79];
260
+ const cellClassName = t20;
252
261
  let t21;
253
- if ($[78] !== handleEvent || $[79] !== onClick) {
254
- t21 = (e) => handleEvent(e, onClick);
255
- $[78] = handleEvent;
256
- $[79] = onClick;
257
- $[80] = t21;
258
- } else t21 = $[80];
262
+ if ($[80] !== buttonProps || $[81] !== focusProps) {
263
+ t21 = mergeProps(buttonProps, focusProps);
264
+ $[80] = buttonProps;
265
+ $[81] = focusProps;
266
+ $[82] = t21;
267
+ } else t21 = $[82];
259
268
  let t22;
260
- if ($[81] !== handleEvent || $[82] !== onKeyboardNavigation || $[83] !== props.date) {
261
- t22 = (e_0) => handleEvent(e_0, () => onKeyboardNavigation?.(e_0, props.date));
262
- $[81] = handleEvent;
263
- $[82] = onKeyboardNavigation;
264
- $[83] = props.date;
265
- $[84] = t22;
266
- } else t22 = $[84];
269
+ if ($[83] !== handleEvent || $[84] !== onClick) {
270
+ t22 = (e) => handleEvent(e, onClick);
271
+ $[83] = handleEvent;
272
+ $[84] = onClick;
273
+ $[85] = t22;
274
+ } else t22 = $[85];
267
275
  let t23;
268
- if ($[85] !== formattedDate) {
269
- t23 = /* @__PURE__ */ jsx(Typography, {
276
+ if ($[86] !== handleEvent || $[87] !== onKeyboardNavigation || $[88] !== props.date) {
277
+ t23 = (e_0) => handleEvent(e_0, () => onKeyboardNavigation?.(e_0, props.date));
278
+ $[86] = handleEvent;
279
+ $[87] = onKeyboardNavigation;
280
+ $[88] = props.date;
281
+ $[89] = t23;
282
+ } else t23 = $[89];
283
+ let t24;
284
+ if ($[90] !== formattedDate) {
285
+ t24 = /* @__PURE__ */ jsx(Typography, {
270
286
  as: "span",
271
287
  size: "label-2",
272
288
  className: "block w-6 overflow-hidden text-ellipsis text-center",
273
289
  children: formattedDate
274
290
  });
275
- $[85] = formattedDate;
276
- $[86] = t23;
277
- } else t23 = $[86];
278
- let t24;
279
- if ($[87] !== cellClassName || $[88] !== onMouseEnter || $[89] !== onMouseLeave || $[90] !== t20 || $[91] !== t21 || $[92] !== t22 || $[93] !== t23) {
280
- t24 = /* @__PURE__ */ jsx("div", {
291
+ $[90] = formattedDate;
292
+ $[91] = t24;
293
+ } else t24 = $[91];
294
+ let t25;
295
+ if ($[92] !== cellClassName || $[93] !== onDoubleClick || $[94] !== onMouseEnter || $[95] !== onMouseLeave || $[96] !== t21 || $[97] !== t22 || $[98] !== t23 || $[99] !== t24) {
296
+ t25 = /* @__PURE__ */ jsx("div", {
281
297
  ref,
282
- ...t20,
298
+ ...t21,
283
299
  "aria-disabled": void 0,
284
300
  onMouseEnter,
285
301
  onMouseLeave,
286
302
  className: cellClassName,
287
- onClick: t21,
288
- onKeyDown: t22,
289
- children: t23
303
+ onClick: t22,
304
+ onDoubleClick,
305
+ onKeyDown: t23,
306
+ children: t24
290
307
  });
291
- $[87] = cellClassName;
292
- $[88] = onMouseEnter;
293
- $[89] = onMouseLeave;
294
- $[90] = t20;
295
- $[91] = t21;
296
- $[92] = t22;
297
- $[93] = t23;
298
- $[94] = t24;
299
- } else t24 = $[94];
300
- let t25;
301
- if ($[95] !== cellProps || $[96] !== t24) {
302
- t25 = /* @__PURE__ */ jsx("td", {
308
+ $[92] = cellClassName;
309
+ $[93] = onDoubleClick;
310
+ $[94] = onMouseEnter;
311
+ $[95] = onMouseLeave;
312
+ $[96] = t21;
313
+ $[97] = t22;
314
+ $[98] = t23;
315
+ $[99] = t24;
316
+ $[100] = t25;
317
+ } else t25 = $[100];
318
+ let t26;
319
+ if ($[101] !== cellProps || $[102] !== t25) {
320
+ t26 = /* @__PURE__ */ jsx("td", {
303
321
  ...cellProps,
304
- children: t24
322
+ children: t25
305
323
  });
306
- $[95] = cellProps;
307
- $[96] = t24;
308
- $[97] = t25;
309
- } else t25 = $[97];
310
- return t25;
324
+ $[101] = cellProps;
325
+ $[102] = t25;
326
+ $[103] = t26;
327
+ } else t26 = $[103];
328
+ return t26;
311
329
  };
312
330
  //#endregion
313
331
  export { CalendarCell };