@bfrs/agentic-components 0.7.9 → 0.8.1
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/data-display/DataTable/DataTable.js +310 -299
- package/dist/components/data-display/DataTable/DataTable.js.map +1 -1
- package/dist/components/data-display/DataTable/TableEmptyState.d.ts +1 -0
- package/dist/components/data-display/DataTable/TableEmptyState.js +8 -4
- package/dist/components/data-display/DataTable/TableEmptyState.js.map +1 -1
- package/dist/components/data-display/DataTable/TableViewSelector.js +217 -213
- package/dist/components/data-display/DataTable/TableViewSelector.js.map +1 -1
- package/dist/components/filters/DateRangePicker/DateRangePicker.d.ts +1 -1
- package/dist/components/filters/DateRangePicker/DateRangePicker.js +418 -389
- package/dist/components/filters/DateRangePicker/DateRangePicker.js.map +1 -1
- package/dist/components/filters/DateRangePicker/DateRangePicker.types.d.ts +8 -0
- package/dist/components/filters/DateRangePicker/DateRangePicker.utils.d.ts +30 -0
- package/dist/components/filters/DateRangePicker/DateRangePicker.utils.js +98 -65
- package/dist/components/filters/DateRangePicker/DateRangePicker.utils.js.map +1 -1
- package/dist/custom-elements.js +8623 -8549
- package/dist/custom-elements.js.map +1 -1
- package/dist/index.js +264 -256
- package/package.json +1 -1
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { Root as
|
|
1
|
+
import { jsxs as c, jsx as r, Fragment as gt } from "react/jsx-runtime";
|
|
2
|
+
import { Root as zt, Trigger as Wt, Portal as Ft, Content as It } from "../../../node_modules/@radix-ui/react-popover/dist/index.js";
|
|
3
3
|
import { CalendarBlank as Lt } from "../../../node_modules/@phosphor-icons/react/dist/csr/CalendarBlank.es.js";
|
|
4
|
-
import { CaretDown as
|
|
5
|
-
import { CaretLeft as
|
|
6
|
-
import { CaretRight as
|
|
7
|
-
import { Check as
|
|
8
|
-
import { X as
|
|
9
|
-
import { useState as
|
|
4
|
+
import { CaretDown as ft } from "../../../node_modules/@phosphor-icons/react/dist/csr/CaretDown.es.js";
|
|
5
|
+
import { CaretLeft as Qe } from "../../../node_modules/@phosphor-icons/react/dist/csr/CaretLeft.es.js";
|
|
6
|
+
import { CaretRight as Ze } from "../../../node_modules/@phosphor-icons/react/dist/csr/CaretRight.es.js";
|
|
7
|
+
import { Check as et } from "../../../node_modules/@phosphor-icons/react/dist/csr/Check.es.js";
|
|
8
|
+
import { X as Yt } from "../../../node_modules/@phosphor-icons/react/dist/csr/X.es.js";
|
|
9
|
+
import { useState as S, useMemo as x, useRef as Et, useCallback as De, useEffect as pt } from "react";
|
|
10
10
|
import o from "@emotion/styled";
|
|
11
|
-
import { twRing as
|
|
12
|
-
import { Button as
|
|
13
|
-
import { WarningAlertIcon as
|
|
14
|
-
import { floatingCollisionPadding as
|
|
15
|
-
import { coerceDateRangeValue as
|
|
16
|
-
import { BfrsPortalScope as
|
|
17
|
-
import { Select as
|
|
18
|
-
const
|
|
19
|
-
...
|
|
11
|
+
import { twRing as Oe, twTransform as mt, kfContentIn as Ht } from "../../../lib/emotionTw.js";
|
|
12
|
+
import { Button as Ne } from "../../primitives/Button/Button.js";
|
|
13
|
+
import { WarningAlertIcon as Nt, warningSurfaceTextStyle as _t } from "../../ui/feedback/warningVisual.js";
|
|
14
|
+
import { floatingCollisionPadding as Vt } from "../../ui/overlays/overlayPositioning.js";
|
|
15
|
+
import { coerceDateRangeValue as tt, CUSTOM_PRESET_ID as p, buildDayWindowOptions as Ot, YEAR_LAST_30_DAYS as $t, dayWindowValueForSpan as jt, YEAR_LAST_ONE as we, getInitialCalendar as _e, shiftMonth as B, startOfDay as v, addDays as Ce, computeYearRange as rt, compareDay as W, hasCompleteRange as C, sameDay as Ae, dayWindowValue as Gt, differenceInCalendarDays as ot, BASE_YEAR as ht, getPresetLabel as Ut, defaultDateRangePresets as Xt, defaultFormatDate as ut, clampYearRange as qt, YEAR_OPTIONS as nt, RESTRICTED_WINDOW_DAYS as Jt, normalizeRange as $e, daysInMonth as Kt, MONTH_NAMES as Qt, SHORT_MONTH_NAMES as at, DAY_HEADS as Zt } from "./DateRangePicker.utils.js";
|
|
16
|
+
import { BfrsPortalScope as er } from "../../ui/providers/BfrsProvider/BfrsProvider.js";
|
|
17
|
+
import { Select as tr } from "../../ui/forms/Select/Select.js";
|
|
18
|
+
const je = (e) => e ? Oe("2px", `hsl(var(--bfrs-color-border-focus) / ${e})`) : {
|
|
19
|
+
...Oe("2px", "hsl(var(--bfrs-color-border-focus) / var(--tw-ring-opacity, 1))"),
|
|
20
20
|
"--tw-ring-opacity": "1"
|
|
21
|
-
},
|
|
21
|
+
}, V = {
|
|
22
22
|
"--tw-text-opacity": "1",
|
|
23
23
|
color: "hsl(var(--bfrs-color-text-muted) / var(--tw-text-opacity, 1))"
|
|
24
|
-
},
|
|
24
|
+
}, M = {
|
|
25
25
|
"--tw-text-opacity": "1",
|
|
26
26
|
color: "hsl(var(--bfrs-color-text-primary) / var(--tw-text-opacity, 1))"
|
|
27
|
-
},
|
|
27
|
+
}, Te = {
|
|
28
28
|
"--tw-text-opacity": "1",
|
|
29
29
|
color: "hsl(var(--bfrs-color-text-secondary) / var(--tw-text-opacity, 1))"
|
|
30
30
|
}, Z = {
|
|
@@ -40,30 +40,30 @@ const $e = (e) => e ? He("2px", `hsl(var(--bfrs-color-border-focus) / ${e})`) :
|
|
|
40
40
|
"--tw-border-opacity": "1",
|
|
41
41
|
borderColor: "hsl(var(--bfrs-color-border) / var(--tw-border-opacity, 1))"
|
|
42
42
|
};
|
|
43
|
-
function _(e,
|
|
44
|
-
const
|
|
45
|
-
return
|
|
43
|
+
function _(e, s) {
|
|
44
|
+
const m = Date.UTC(e.year, e.month, 1), d = Date.UTC(s.year, s.month, 1);
|
|
45
|
+
return m === d ? 0 : m < d ? -1 : 1;
|
|
46
46
|
}
|
|
47
|
-
function
|
|
48
|
-
return _(e,
|
|
47
|
+
function rr(e, s, m) {
|
|
48
|
+
return _(e, s) < 0 || _(e, m) > 0;
|
|
49
49
|
}
|
|
50
|
-
function
|
|
50
|
+
function it(e) {
|
|
51
51
|
return { year: e.getFullYear(), month: e.getMonth() };
|
|
52
52
|
}
|
|
53
|
-
function
|
|
54
|
-
const d =
|
|
55
|
-
if (!
|
|
53
|
+
function or(e, s, m) {
|
|
54
|
+
const d = B(e.year, e.month, 1);
|
|
55
|
+
if (!m || _(d, m) <= 0)
|
|
56
56
|
return { left: e, right: d };
|
|
57
|
-
const
|
|
58
|
-
return !
|
|
57
|
+
const h = B(e.year, e.month, -1);
|
|
58
|
+
return !s || _(h, s) >= 0 ? { left: h, right: e } : { left: e, right: d };
|
|
59
59
|
}
|
|
60
|
-
function
|
|
61
|
-
const
|
|
62
|
-
if (
|
|
63
|
-
const
|
|
64
|
-
return _(
|
|
60
|
+
function Ve(e, s, m, d) {
|
|
61
|
+
const h = it(e);
|
|
62
|
+
if (m === 1) return { left: h, right: h };
|
|
63
|
+
const O = it(s);
|
|
64
|
+
return _(h, O) < 0 ? { left: h, right: O } : or(h, d == null ? void 0 : d.minMonth, d == null ? void 0 : d.maxMonth);
|
|
65
65
|
}
|
|
66
|
-
const
|
|
66
|
+
const nr = /* @__PURE__ */ o("div", {
|
|
67
67
|
label: "AgenticDateRangePicker-calendar"
|
|
68
68
|
})({
|
|
69
69
|
width: "252px",
|
|
@@ -75,14 +75,14 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
75
75
|
"--tw-shadow": "var(--bfrs-shadow-low)",
|
|
76
76
|
"--tw-shadow-colored": "var(--bfrs-shadow-low)",
|
|
77
77
|
boxShadow: "var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)"
|
|
78
|
-
}),
|
|
78
|
+
}), ar = /* @__PURE__ */ o("div", {
|
|
79
79
|
label: "AgenticDateRangePicker-calendarHeader"
|
|
80
80
|
})({
|
|
81
81
|
marginBottom: ".5rem",
|
|
82
82
|
display: "flex",
|
|
83
83
|
alignItems: "center",
|
|
84
84
|
justifyContent: "space-between"
|
|
85
|
-
}),
|
|
85
|
+
}), Se = /* @__PURE__ */ o("button", {
|
|
86
86
|
label: "AgenticDateRangePicker-navButton",
|
|
87
87
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
88
88
|
})(({ ownerState: e }) => [
|
|
@@ -93,14 +93,14 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
93
93
|
alignItems: "center",
|
|
94
94
|
justifyContent: "center",
|
|
95
95
|
borderRadius: "var(--bfrs-radius-md)",
|
|
96
|
-
|
|
96
|
+
...V,
|
|
97
97
|
outline: "2px solid transparent",
|
|
98
98
|
outlineOffset: "2px",
|
|
99
99
|
"&:hover": {
|
|
100
100
|
...N,
|
|
101
|
-
...
|
|
101
|
+
...M
|
|
102
102
|
},
|
|
103
|
-
"&:focus-visible":
|
|
103
|
+
"&:focus-visible": je()
|
|
104
104
|
},
|
|
105
105
|
e.disableable && {
|
|
106
106
|
"&:disabled": {
|
|
@@ -108,12 +108,12 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
108
108
|
opacity: ".3"
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
-
]),
|
|
111
|
+
]), lt = /* @__PURE__ */ o("div", {
|
|
112
112
|
label: "AgenticDateRangePicker-navSpacer"
|
|
113
113
|
})({
|
|
114
114
|
width: "1.75rem",
|
|
115
115
|
height: "1.75rem"
|
|
116
|
-
}),
|
|
116
|
+
}), ir = /* @__PURE__ */ o("button", {
|
|
117
117
|
label: "AgenticDateRangePicker-titleButton"
|
|
118
118
|
})({
|
|
119
119
|
display: "flex",
|
|
@@ -122,7 +122,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
122
122
|
fontSize: ".875rem",
|
|
123
123
|
lineHeight: "1.25rem",
|
|
124
124
|
fontWeight: 700,
|
|
125
|
-
...
|
|
125
|
+
...M,
|
|
126
126
|
outline: "2px solid transparent",
|
|
127
127
|
outlineOffset: "2px",
|
|
128
128
|
"&:hover": {
|
|
@@ -132,18 +132,18 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
132
132
|
transitionProperty: "color,background-color,border-color,text-decoration-color,fill,stroke",
|
|
133
133
|
transitionTimingFunction: "cubic-bezier(.4,0,.2,1)",
|
|
134
134
|
transitionDuration: ".15s"
|
|
135
|
-
}),
|
|
135
|
+
}), lr = /* @__PURE__ */ o(ft, {
|
|
136
136
|
label: "AgenticDateRangePicker-titleCaret",
|
|
137
137
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
138
138
|
})(({ ownerState: e }) => [
|
|
139
139
|
{
|
|
140
|
-
|
|
140
|
+
...V,
|
|
141
141
|
transitionProperty: "transform",
|
|
142
142
|
transitionTimingFunction: "cubic-bezier(.4,0,.2,1)",
|
|
143
143
|
transitionDuration: ".15s"
|
|
144
144
|
},
|
|
145
|
-
e.open &&
|
|
146
|
-
]),
|
|
145
|
+
e.open && mt({ "--tw-rotate": "180deg" })
|
|
146
|
+
]), cr = /* @__PURE__ */ o("div", {
|
|
147
147
|
label: "AgenticDateRangePicker-monthGrid"
|
|
148
148
|
})({
|
|
149
149
|
display: "grid",
|
|
@@ -151,7 +151,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
151
151
|
gap: ".375rem",
|
|
152
152
|
paddingTop: ".25rem",
|
|
153
153
|
paddingBottom: ".25rem"
|
|
154
|
-
}),
|
|
154
|
+
}), sr = /* @__PURE__ */ o("button", {
|
|
155
155
|
label: "AgenticDateRangePicker-monthButton",
|
|
156
156
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
157
157
|
})(({ ownerState: e }) => [
|
|
@@ -163,7 +163,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
163
163
|
paddingBottom: ".625rem",
|
|
164
164
|
fontSize: "12px",
|
|
165
165
|
fontWeight: 500,
|
|
166
|
-
...
|
|
166
|
+
...Te,
|
|
167
167
|
outline: "2px solid transparent",
|
|
168
168
|
outlineOffset: "2px",
|
|
169
169
|
transitionProperty: "color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter",
|
|
@@ -171,9 +171,9 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
171
171
|
transitionDuration: ".15s",
|
|
172
172
|
"&:hover": {
|
|
173
173
|
...N,
|
|
174
|
-
...
|
|
174
|
+
...M
|
|
175
175
|
},
|
|
176
|
-
"&:focus-visible":
|
|
176
|
+
"&:focus-visible": je()
|
|
177
177
|
},
|
|
178
178
|
e.current && {
|
|
179
179
|
"--tw-bg-opacity": "1",
|
|
@@ -197,7 +197,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
197
197
|
...Z
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
|
-
]),
|
|
200
|
+
]), dr = /* @__PURE__ */ o("div", {
|
|
201
201
|
label: "AgenticDateRangePicker-dayHeads"
|
|
202
202
|
})({
|
|
203
203
|
marginBottom: ".125rem",
|
|
@@ -206,7 +206,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
206
206
|
borderBottomWidth: "1px",
|
|
207
207
|
...te,
|
|
208
208
|
paddingBottom: ".375rem"
|
|
209
|
-
}),
|
|
209
|
+
}), gr = /* @__PURE__ */ o("div", {
|
|
210
210
|
label: "AgenticDateRangePicker-dayHead"
|
|
211
211
|
})({
|
|
212
212
|
textAlign: "center",
|
|
@@ -214,12 +214,12 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
214
214
|
lineHeight: "1rem",
|
|
215
215
|
fontWeight: 600,
|
|
216
216
|
...Z
|
|
217
|
-
}),
|
|
217
|
+
}), fr = /* @__PURE__ */ o("div", {
|
|
218
218
|
label: "AgenticDateRangePicker-daysGrid"
|
|
219
219
|
})({
|
|
220
220
|
display: "grid",
|
|
221
221
|
gridTemplateColumns: "repeat(7,minmax(0,1fr))"
|
|
222
|
-
}),
|
|
222
|
+
}), pr = /* @__PURE__ */ o("div", {
|
|
223
223
|
label: "AgenticDateRangePicker-monthLabel"
|
|
224
224
|
})({
|
|
225
225
|
gridColumn: "span 7 / span 7",
|
|
@@ -231,11 +231,11 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
231
231
|
fontWeight: 700,
|
|
232
232
|
letterSpacing: ".12em",
|
|
233
233
|
...Z
|
|
234
|
-
}),
|
|
234
|
+
}), mr = /* @__PURE__ */ o("div", {
|
|
235
235
|
label: "AgenticDateRangePicker-blankCell"
|
|
236
236
|
})({
|
|
237
237
|
height: "2rem"
|
|
238
|
-
}),
|
|
238
|
+
}), hr = /* @__PURE__ */ o("div", {
|
|
239
239
|
label: "AgenticDateRangePicker-dayCell"
|
|
240
240
|
})({
|
|
241
241
|
position: "relative",
|
|
@@ -243,7 +243,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
243
243
|
height: "2rem",
|
|
244
244
|
alignItems: "center",
|
|
245
245
|
justifyContent: "center"
|
|
246
|
-
}),
|
|
246
|
+
}), ur = /* @__PURE__ */ o("div", {
|
|
247
247
|
label: "AgenticDateRangePicker-rangeBand",
|
|
248
248
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
249
249
|
})(({ ownerState: e }) => [
|
|
@@ -265,7 +265,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
265
265
|
borderTopRightRadius: "var(--bfrs-radius-lg)",
|
|
266
266
|
borderBottomRightRadius: "var(--bfrs-radius-lg)"
|
|
267
267
|
}
|
|
268
|
-
]),
|
|
268
|
+
]), br = /* @__PURE__ */ o("button", {
|
|
269
269
|
label: "AgenticDateRangePicker-dayButton",
|
|
270
270
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
271
271
|
})(({ ownerState: e }) => [
|
|
@@ -284,7 +284,7 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
284
284
|
transitionProperty: "color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter",
|
|
285
285
|
transitionTimingFunction: "cubic-bezier(.4,0,.2,1)",
|
|
286
286
|
transitionDuration: ".15s",
|
|
287
|
-
"&:focus-visible":
|
|
287
|
+
"&:focus-visible": je()
|
|
288
288
|
},
|
|
289
289
|
e.shape === "start" ? {
|
|
290
290
|
borderTopLeftRadius: "var(--bfrs-radius-lg)",
|
|
@@ -303,12 +303,12 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
303
303
|
"--tw-shadow-colored": "var(--bfrs-shadow-low)",
|
|
304
304
|
boxShadow: "var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)"
|
|
305
305
|
},
|
|
306
|
-
!e.selected && e.inRange && { fontWeight: 500, ...
|
|
306
|
+
!e.selected && e.inRange && { fontWeight: 500, ...M },
|
|
307
307
|
!e.selected && !e.inRange && {
|
|
308
|
-
...
|
|
308
|
+
...Te,
|
|
309
309
|
"&:hover": {
|
|
310
310
|
...N,
|
|
311
|
-
...
|
|
311
|
+
...M
|
|
312
312
|
}
|
|
313
313
|
},
|
|
314
314
|
e.disabled && {
|
|
@@ -321,154 +321,154 @@ const Kt = /* @__PURE__ */ o("div", {
|
|
|
321
321
|
}
|
|
322
322
|
}
|
|
323
323
|
]);
|
|
324
|
-
function
|
|
324
|
+
function ct({
|
|
325
325
|
year: e,
|
|
326
|
-
month:
|
|
327
|
-
from:
|
|
326
|
+
month: s,
|
|
327
|
+
from: m,
|
|
328
328
|
to: d,
|
|
329
|
-
hovered:
|
|
330
|
-
awaitingTo:
|
|
331
|
-
isDateDisabled:
|
|
332
|
-
onSelectDate:
|
|
333
|
-
onHoverDate:
|
|
334
|
-
onPrev:
|
|
335
|
-
onNext:
|
|
329
|
+
hovered: h,
|
|
330
|
+
awaitingTo: O,
|
|
331
|
+
isDateDisabled: ve,
|
|
332
|
+
onSelectDate: ye,
|
|
333
|
+
onHoverDate: $,
|
|
334
|
+
onPrev: Be,
|
|
335
|
+
onNext: Me,
|
|
336
336
|
showPrev: F = !0,
|
|
337
337
|
showNext: I = !0,
|
|
338
|
-
minMonth:
|
|
339
|
-
maxMonth:
|
|
340
|
-
onNavigateTo:
|
|
341
|
-
className:
|
|
338
|
+
minMonth: u,
|
|
339
|
+
maxMonth: ze,
|
|
340
|
+
onNavigateTo: de,
|
|
341
|
+
className: We
|
|
342
342
|
}) {
|
|
343
|
-
const [
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
}, [e,
|
|
347
|
-
const
|
|
348
|
-
for (let
|
|
349
|
-
oe.push(
|
|
343
|
+
const [R, xe] = S(!1), [k, re] = S(e), Fe = (/* @__PURE__ */ new Date()).getFullYear();
|
|
344
|
+
pt(() => {
|
|
345
|
+
R || re(e);
|
|
346
|
+
}, [e, R]);
|
|
347
|
+
const ge = new Date(e, s, 1).getDay(), Re = Kt(e, s), oe = Array(ge).fill(null);
|
|
348
|
+
for (let l = 1; l <= Re; l += 1)
|
|
349
|
+
oe.push(l);
|
|
350
350
|
for (; oe.length % 7 !== 0; )
|
|
351
351
|
oe.push(null);
|
|
352
|
-
const
|
|
353
|
-
return /* @__PURE__ */
|
|
354
|
-
/* @__PURE__ */
|
|
355
|
-
|
|
356
|
-
|
|
352
|
+
const ke = d ?? (O ? h : void 0), g = m && ke ? $e(m, ke) : void 0;
|
|
353
|
+
return /* @__PURE__ */ c(nr, { className: We, children: [
|
|
354
|
+
/* @__PURE__ */ c(ar, { children: [
|
|
355
|
+
R ? /* @__PURE__ */ r(
|
|
356
|
+
Se,
|
|
357
357
|
{
|
|
358
358
|
type: "button",
|
|
359
359
|
ownerState: { disableable: !0 },
|
|
360
|
-
onClick: () => re((
|
|
361
|
-
disabled:
|
|
360
|
+
onClick: () => re((l) => l - 1),
|
|
361
|
+
disabled: k <= ht,
|
|
362
362
|
"aria-label": "Previous year",
|
|
363
|
-
children: /* @__PURE__ */ r(
|
|
363
|
+
children: /* @__PURE__ */ r(Qe, { size: 14, weight: "bold" })
|
|
364
364
|
}
|
|
365
|
-
) : F ? /* @__PURE__ */ r(
|
|
366
|
-
/* @__PURE__ */
|
|
367
|
-
|
|
365
|
+
) : F ? /* @__PURE__ */ r(Se, { type: "button", ownerState: { disableable: !1 }, onClick: Be, "aria-label": "Previous month", children: /* @__PURE__ */ r(Qe, { size: 14, weight: "bold" }) }) : /* @__PURE__ */ r(lt, { "aria-hidden": "true" }),
|
|
366
|
+
/* @__PURE__ */ c(
|
|
367
|
+
ir,
|
|
368
368
|
{
|
|
369
369
|
type: "button",
|
|
370
370
|
onClick: () => {
|
|
371
|
-
re(e),
|
|
371
|
+
re(e), xe((l) => !l);
|
|
372
372
|
},
|
|
373
373
|
children: [
|
|
374
|
-
|
|
375
|
-
/* @__PURE__ */ r(
|
|
374
|
+
R ? k : `${Qt[s]}, ${e}`,
|
|
375
|
+
/* @__PURE__ */ r(lr, { size: 11, weight: "bold", ownerState: { open: R } })
|
|
376
376
|
]
|
|
377
377
|
}
|
|
378
378
|
),
|
|
379
|
-
|
|
380
|
-
|
|
379
|
+
R ? /* @__PURE__ */ r(
|
|
380
|
+
Se,
|
|
381
381
|
{
|
|
382
382
|
type: "button",
|
|
383
383
|
ownerState: { disableable: !0 },
|
|
384
|
-
onClick: () => re((
|
|
385
|
-
disabled:
|
|
384
|
+
onClick: () => re((l) => l + 1),
|
|
385
|
+
disabled: k >= Fe + 1,
|
|
386
386
|
"aria-label": "Next year",
|
|
387
|
-
children: /* @__PURE__ */ r(
|
|
387
|
+
children: /* @__PURE__ */ r(Ze, { size: 14, weight: "bold" })
|
|
388
388
|
}
|
|
389
|
-
) : I ? /* @__PURE__ */ r(
|
|
389
|
+
) : I ? /* @__PURE__ */ r(Se, { type: "button", ownerState: { disableable: !1 }, onClick: Me, "aria-label": "Next month", children: /* @__PURE__ */ r(Ze, { size: 14, weight: "bold" }) }) : /* @__PURE__ */ r(lt, { "aria-hidden": "true" })
|
|
390
390
|
] }),
|
|
391
|
-
|
|
392
|
-
const
|
|
391
|
+
R ? /* @__PURE__ */ r(cr, { children: at.map((l, P) => {
|
|
392
|
+
const y = P === s && k === e, A = rr({ year: k, month: P }, u, ze);
|
|
393
393
|
return /* @__PURE__ */ r(
|
|
394
|
-
|
|
394
|
+
sr,
|
|
395
395
|
{
|
|
396
396
|
type: "button",
|
|
397
|
-
disabled:
|
|
398
|
-
ownerState: { current:
|
|
397
|
+
disabled: A,
|
|
398
|
+
ownerState: { current: y, disabled: A },
|
|
399
399
|
onClick: () => {
|
|
400
|
-
|
|
400
|
+
A || (de == null || de(k, P), xe(!1));
|
|
401
401
|
},
|
|
402
|
-
children:
|
|
402
|
+
children: l
|
|
403
403
|
},
|
|
404
|
-
|
|
404
|
+
P
|
|
405
405
|
);
|
|
406
|
-
}) }) : /* @__PURE__ */
|
|
407
|
-
/* @__PURE__ */ r(
|
|
408
|
-
/* @__PURE__ */
|
|
409
|
-
/* @__PURE__ */ r(
|
|
410
|
-
oe.map((
|
|
411
|
-
if (!
|
|
412
|
-
return /* @__PURE__ */ r(
|
|
413
|
-
const
|
|
414
|
-
return /* @__PURE__ */
|
|
415
|
-
|
|
406
|
+
}) }) : /* @__PURE__ */ c(gt, { children: [
|
|
407
|
+
/* @__PURE__ */ r(dr, { children: Zt.map((l, P) => /* @__PURE__ */ r(gr, { children: l }, `${l}-${P}`)) }),
|
|
408
|
+
/* @__PURE__ */ c(fr, { children: [
|
|
409
|
+
/* @__PURE__ */ r(pr, { children: at[s] }),
|
|
410
|
+
oe.map((l, P) => {
|
|
411
|
+
if (!l)
|
|
412
|
+
return /* @__PURE__ */ r(mr, {}, `blank-${P}`);
|
|
413
|
+
const y = new Date(e, s, l), A = Ae(y, (g == null ? void 0 : g.from) ?? m), fe = Ae(y, (g == null ? void 0 : g.to) ?? d), b = A || fe, T = !!(g && W(y, g.from) > 0 && W(y, g.to) < 0), z = ve(y), L = P % 7, j = !!(g && W(g.from, g.to) !== 0);
|
|
414
|
+
return /* @__PURE__ */ c(
|
|
415
|
+
hr,
|
|
416
416
|
{
|
|
417
|
-
onMouseEnter: () =>
|
|
418
|
-
onMouseLeave: () =>
|
|
417
|
+
onMouseEnter: () => $(y),
|
|
418
|
+
onMouseLeave: () => $(void 0),
|
|
419
419
|
children: [
|
|
420
|
-
(
|
|
421
|
-
|
|
420
|
+
(T || j && b) && /* @__PURE__ */ r(
|
|
421
|
+
ur,
|
|
422
422
|
{
|
|
423
423
|
ownerState: {
|
|
424
|
-
shape:
|
|
425
|
-
roundLeft:
|
|
426
|
-
roundRight:
|
|
424
|
+
shape: j && A ? "start" : j && fe ? "end" : "middle",
|
|
425
|
+
roundLeft: L === 0 || l === 1,
|
|
426
|
+
roundRight: L === 6 || l === Re
|
|
427
427
|
},
|
|
428
428
|
"aria-hidden": "true"
|
|
429
429
|
}
|
|
430
430
|
),
|
|
431
431
|
/* @__PURE__ */ r(
|
|
432
|
-
|
|
432
|
+
br,
|
|
433
433
|
{
|
|
434
434
|
type: "button",
|
|
435
|
-
disabled:
|
|
436
|
-
onClick: () =>
|
|
437
|
-
"aria-pressed":
|
|
438
|
-
"aria-label":
|
|
435
|
+
disabled: z,
|
|
436
|
+
onClick: () => ye(y),
|
|
437
|
+
"aria-pressed": b,
|
|
438
|
+
"aria-label": ut(y),
|
|
439
439
|
ownerState: {
|
|
440
440
|
// Range endpoints square off the side that meets the band so they sit flush
|
|
441
441
|
// with it; the start keeps its left corners, the end keeps its right corners.
|
|
442
|
-
shape:
|
|
443
|
-
selected:
|
|
444
|
-
inRange:
|
|
445
|
-
disabled:
|
|
442
|
+
shape: j && A ? "start" : j && fe ? "end" : "single",
|
|
443
|
+
selected: b,
|
|
444
|
+
inRange: T,
|
|
445
|
+
disabled: z
|
|
446
446
|
},
|
|
447
|
-
children:
|
|
447
|
+
children: l
|
|
448
448
|
}
|
|
449
449
|
)
|
|
450
450
|
]
|
|
451
451
|
},
|
|
452
|
-
|
|
452
|
+
l
|
|
453
453
|
);
|
|
454
454
|
})
|
|
455
455
|
] })
|
|
456
456
|
] })
|
|
457
457
|
] });
|
|
458
458
|
}
|
|
459
|
-
const
|
|
459
|
+
const wr = /* @__PURE__ */ o("div", {
|
|
460
460
|
label: "AgenticDateRangePicker-root"
|
|
461
461
|
})({
|
|
462
462
|
display: "inline-flex",
|
|
463
463
|
flexDirection: "column",
|
|
464
464
|
gap: ".375rem"
|
|
465
|
-
}),
|
|
465
|
+
}), vr = /* @__PURE__ */ o("div", {
|
|
466
466
|
label: "AgenticDateRangePicker-label"
|
|
467
467
|
})({
|
|
468
468
|
fontSize: "12px",
|
|
469
469
|
fontWeight: 600,
|
|
470
|
-
...
|
|
471
|
-
}),
|
|
470
|
+
...M
|
|
471
|
+
}), yr = /* @__PURE__ */ o("button", {
|
|
472
472
|
label: "AgenticDateRangePicker-trigger",
|
|
473
473
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
474
474
|
})(({ ownerState: e }) => [
|
|
@@ -485,7 +485,7 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
485
485
|
...ee,
|
|
486
486
|
fontSize: "12px",
|
|
487
487
|
fontWeight: 400,
|
|
488
|
-
...
|
|
488
|
+
...M,
|
|
489
489
|
outline: "2px solid transparent",
|
|
490
490
|
outlineOffset: "2px",
|
|
491
491
|
transitionProperty: "color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter",
|
|
@@ -496,24 +496,24 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
496
496
|
"--tw-bg-opacity": "1",
|
|
497
497
|
backgroundColor: "hsl(var(--bfrs-color-surface-muted) / var(--tw-bg-opacity, 1))"
|
|
498
498
|
},
|
|
499
|
-
"&:focus-visible":
|
|
499
|
+
"&:focus-visible": Oe("2px", "hsl(var(--bfrs-color-border-focus) / .25)"),
|
|
500
500
|
"&:disabled": {
|
|
501
501
|
pointerEvents: "none",
|
|
502
502
|
opacity: ".55"
|
|
503
503
|
}
|
|
504
504
|
},
|
|
505
505
|
e.md ? { height: "2.25rem", paddingLeft: ".75rem", paddingRight: ".75rem" } : { height: "1.75rem", paddingLeft: ".75rem", paddingRight: ".75rem" },
|
|
506
|
-
e.empty ?
|
|
506
|
+
e.empty ? V : M,
|
|
507
507
|
e.smFilled && {
|
|
508
508
|
"--tw-border-opacity": "1",
|
|
509
509
|
borderColor: "hsl(var(--bfrs-color-border-focus) / var(--tw-border-opacity, 1))"
|
|
510
510
|
}
|
|
511
|
-
]),
|
|
511
|
+
]), xr = /* @__PURE__ */ o(Lt, {
|
|
512
512
|
label: "AgenticDateRangePicker-triggerIcon"
|
|
513
513
|
})({
|
|
514
514
|
flexShrink: 0,
|
|
515
|
-
|
|
516
|
-
}),
|
|
515
|
+
...V
|
|
516
|
+
}), Rr = /* @__PURE__ */ o("span", {
|
|
517
517
|
label: "AgenticDateRangePicker-triggerLabel"
|
|
518
518
|
})({
|
|
519
519
|
flex: "1 1 0%",
|
|
@@ -521,19 +521,19 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
521
521
|
textOverflow: "ellipsis",
|
|
522
522
|
whiteSpace: "nowrap",
|
|
523
523
|
textAlign: "left"
|
|
524
|
-
}),
|
|
524
|
+
}), kr = /* @__PURE__ */ o(ft, {
|
|
525
525
|
label: "AgenticDateRangePicker-caret",
|
|
526
526
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
527
527
|
})(({ ownerState: e }) => [
|
|
528
528
|
{
|
|
529
529
|
flexShrink: 0,
|
|
530
|
-
|
|
530
|
+
...V,
|
|
531
531
|
transitionProperty: "transform",
|
|
532
532
|
transitionTimingFunction: "cubic-bezier(.4,0,.2,1)",
|
|
533
533
|
transitionDuration: ".15s"
|
|
534
534
|
},
|
|
535
|
-
e.open &&
|
|
536
|
-
]),
|
|
535
|
+
e.open && mt({ "--tw-rotate": "180deg" })
|
|
536
|
+
]), Pr = /* @__PURE__ */ o(It, {
|
|
537
537
|
label: "AgenticDateRangePicker-content",
|
|
538
538
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
539
539
|
})(({ ownerState: e }) => [
|
|
@@ -552,13 +552,13 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
552
552
|
boxShadow: "var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)",
|
|
553
553
|
outline: "2px solid transparent",
|
|
554
554
|
outlineOffset: "2px",
|
|
555
|
-
...
|
|
555
|
+
...Ht,
|
|
556
556
|
animation: "bfrs-bfrs-content-in var(--bfrs-motion-normal) var(--bfrs-ease-out)"
|
|
557
557
|
},
|
|
558
558
|
e.widthMode === "presets" && { width: "14rem" },
|
|
559
559
|
e.widthMode === "one" && { width: "min(calc(100vw - 1rem),420px)" },
|
|
560
560
|
e.widthMode === "two" && { width: "min(calc(100vw - 1rem),700px)" }
|
|
561
|
-
]),
|
|
561
|
+
]), Dr = /* @__PURE__ */ o("div", {
|
|
562
562
|
label: "AgenticDateRangePicker-scroll",
|
|
563
563
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
564
564
|
})(({ ownerState: e }) => [
|
|
@@ -573,7 +573,7 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
573
573
|
flexDirection: "column",
|
|
574
574
|
"@media (min-width:768px)": { flexDirection: "row" }
|
|
575
575
|
}
|
|
576
|
-
]),
|
|
576
|
+
]), Cr = /* @__PURE__ */ o("div", {
|
|
577
577
|
label: "AgenticDateRangePicker-presetColumn",
|
|
578
578
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
579
579
|
})(({ ownerState: e }) => [
|
|
@@ -591,13 +591,13 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
591
591
|
borderRightWidth: "1px"
|
|
592
592
|
}
|
|
593
593
|
}
|
|
594
|
-
]),
|
|
594
|
+
]), Sr = /* @__PURE__ */ o("div", {
|
|
595
595
|
label: "AgenticDateRangePicker-presetList"
|
|
596
596
|
})({
|
|
597
597
|
flex: "1 1 0%",
|
|
598
598
|
paddingTop: ".5rem",
|
|
599
599
|
paddingBottom: ".5rem"
|
|
600
|
-
}),
|
|
600
|
+
}), st = /* @__PURE__ */ o("button", {
|
|
601
601
|
label: "AgenticDateRangePicker-presetButton",
|
|
602
602
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
603
603
|
})(({ ownerState: e }) => [
|
|
@@ -619,14 +619,14 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
619
619
|
"&:focus-visible": N
|
|
620
620
|
},
|
|
621
621
|
e.md ? { height: "2.25rem", paddingLeft: ".75rem", paddingRight: ".75rem" } : { height: "1.75rem", paddingLeft: ".625rem", paddingRight: ".625rem" },
|
|
622
|
-
e.selected ? { ...N, fontWeight: 700, ...
|
|
622
|
+
e.selected ? { ...N, fontWeight: 700, ...M } : { fontWeight: 500, ...Te },
|
|
623
623
|
e.presetDisabled && {
|
|
624
624
|
cursor: "not-allowed",
|
|
625
625
|
...Z,
|
|
626
626
|
opacity: ".6",
|
|
627
627
|
"&:hover": { backgroundColor: "transparent" }
|
|
628
628
|
}
|
|
629
|
-
]),
|
|
629
|
+
]), Ar = /* @__PURE__ */ o("div", {
|
|
630
630
|
label: "AgenticDateRangePicker-rangeLimit"
|
|
631
631
|
})({
|
|
632
632
|
position: "sticky",
|
|
@@ -643,26 +643,26 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
643
643
|
paddingBottom: ".75rem",
|
|
644
644
|
fontSize: ".75rem",
|
|
645
645
|
lineHeight: "1.25rem",
|
|
646
|
-
|
|
647
|
-
}),
|
|
646
|
+
...V
|
|
647
|
+
}), Tr = /* @__PURE__ */ o("span", {
|
|
648
648
|
label: "AgenticDateRangePicker-rangeLimitIcon"
|
|
649
649
|
})({
|
|
650
650
|
marginTop: ".125rem",
|
|
651
651
|
display: "flex",
|
|
652
652
|
flexShrink: 0
|
|
653
|
-
}),
|
|
653
|
+
}), Br = /* @__PURE__ */ o("div", {
|
|
654
654
|
label: "AgenticDateRangePicker-customArea"
|
|
655
655
|
})({
|
|
656
656
|
minWidth: "0px",
|
|
657
657
|
flex: "1 1 0%",
|
|
658
658
|
...ee
|
|
659
|
-
}),
|
|
659
|
+
}), Mr = /* @__PURE__ */ o("div", {
|
|
660
660
|
label: "AgenticDateRangePicker-yearRow"
|
|
661
661
|
})({
|
|
662
662
|
paddingLeft: "1rem",
|
|
663
663
|
paddingRight: "1rem",
|
|
664
664
|
paddingTop: "1rem"
|
|
665
|
-
}),
|
|
665
|
+
}), zr = /* @__PURE__ */ o("div", {
|
|
666
666
|
label: "AgenticDateRangePicker-yearBanner"
|
|
667
667
|
})({
|
|
668
668
|
display: "flex",
|
|
@@ -673,21 +673,21 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
673
673
|
paddingRight: ".75rem",
|
|
674
674
|
paddingTop: ".5rem",
|
|
675
675
|
paddingBottom: ".5rem"
|
|
676
|
-
}),
|
|
676
|
+
}), Wr = /* @__PURE__ */ o("span", {
|
|
677
677
|
label: "AgenticDateRangePicker-yearText"
|
|
678
678
|
})({
|
|
679
679
|
flex: "1 1 0%",
|
|
680
680
|
fontSize: "12.5px",
|
|
681
681
|
fontWeight: 500,
|
|
682
|
-
...
|
|
683
|
-
}),
|
|
682
|
+
...M
|
|
683
|
+
}), Fr = /* @__PURE__ */ o(tr, {
|
|
684
684
|
label: "AgenticDateRangePicker-yearSelect"
|
|
685
685
|
})({
|
|
686
686
|
"&&": {
|
|
687
687
|
width: "8rem",
|
|
688
688
|
flexShrink: 0
|
|
689
689
|
}
|
|
690
|
-
}),
|
|
690
|
+
}), Ir = /* @__PURE__ */ o("div", {
|
|
691
691
|
label: "AgenticDateRangePicker-calendarGrid",
|
|
692
692
|
shouldForwardProp: (e) => e !== "ownerState"
|
|
693
693
|
})(({ ownerState: e }) => [
|
|
@@ -698,7 +698,7 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
698
698
|
padding: "1rem"
|
|
699
699
|
},
|
|
700
700
|
e.two ? { "@media (min-width:768px)": { gridTemplateColumns: "repeat(2,minmax(0,1fr))" } } : { gridTemplateColumns: "repeat(1,minmax(0,1fr))" }
|
|
701
|
-
]),
|
|
701
|
+
]), Lr = /* @__PURE__ */ o("div", {
|
|
702
702
|
label: "AgenticDateRangePicker-footer"
|
|
703
703
|
})({
|
|
704
704
|
display: "flex",
|
|
@@ -706,7 +706,7 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
706
706
|
alignItems: "stretch",
|
|
707
707
|
borderTopWidth: "1px",
|
|
708
708
|
...te
|
|
709
|
-
}),
|
|
709
|
+
}), Yr = /* @__PURE__ */ o("div", {
|
|
710
710
|
label: "AgenticDateRangePicker-footerInner"
|
|
711
711
|
})({
|
|
712
712
|
display: "flex",
|
|
@@ -723,359 +723,388 @@ const gr = /* @__PURE__ */ o("div", {
|
|
|
723
723
|
alignItems: "center",
|
|
724
724
|
justifyContent: "space-between"
|
|
725
725
|
}
|
|
726
|
-
}),
|
|
726
|
+
}), Er = /* @__PURE__ */ o("div", {
|
|
727
727
|
label: "AgenticDateRangePicker-selectedBlock"
|
|
728
728
|
})({
|
|
729
729
|
display: "flex",
|
|
730
730
|
flexDirection: "column",
|
|
731
731
|
gap: ".125rem"
|
|
732
|
-
}),
|
|
732
|
+
}), Hr = /* @__PURE__ */ o("div", {
|
|
733
733
|
label: "AgenticDateRangePicker-selectedText"
|
|
734
734
|
})({
|
|
735
735
|
fontSize: "13px",
|
|
736
|
-
...
|
|
737
|
-
}),
|
|
736
|
+
...Te
|
|
737
|
+
}), Nr = /* @__PURE__ */ o("span", {
|
|
738
738
|
label: "AgenticDateRangePicker-selectedLabel"
|
|
739
739
|
})({
|
|
740
740
|
fontWeight: 600,
|
|
741
741
|
"--tw-text-opacity": "1",
|
|
742
742
|
color: "hsl(var(--bfrs-color-primary) / var(--tw-text-opacity, 1))"
|
|
743
|
-
}),
|
|
743
|
+
}), dt = /* @__PURE__ */ o("span", {
|
|
744
744
|
label: "AgenticDateRangePicker-selectedValue"
|
|
745
745
|
})({
|
|
746
746
|
fontWeight: 500
|
|
747
|
-
}),
|
|
747
|
+
}), _r = /* @__PURE__ */ o("span", {
|
|
748
748
|
label: "AgenticDateRangePicker-selectedTo"
|
|
749
|
-
})(
|
|
749
|
+
})(V), Vr = /* @__PURE__ */ o("div", {
|
|
750
750
|
label: "AgenticDateRangePicker-incomplete"
|
|
751
751
|
})({
|
|
752
752
|
fontSize: "12px",
|
|
753
753
|
"--tw-text-opacity": "1",
|
|
754
754
|
color: "hsl(var(--bfrs-color-danger) / var(--tw-text-opacity, 1))"
|
|
755
|
-
}),
|
|
755
|
+
}), Or = /* @__PURE__ */ o("div", {
|
|
756
756
|
label: "AgenticDateRangePicker-footerActions"
|
|
757
757
|
})({
|
|
758
758
|
display: "flex",
|
|
759
759
|
flexWrap: "wrap",
|
|
760
760
|
justifyContent: "flex-end",
|
|
761
761
|
gap: ".5rem"
|
|
762
|
-
}),
|
|
762
|
+
}), $r = /* @__PURE__ */ o("div", {
|
|
763
763
|
label: "AgenticDateRangePicker-helper"
|
|
764
764
|
})({
|
|
765
765
|
fontSize: ".75rem",
|
|
766
766
|
lineHeight: "1.25rem",
|
|
767
|
-
|
|
767
|
+
...V
|
|
768
768
|
});
|
|
769
|
-
function
|
|
769
|
+
function so({
|
|
770
770
|
className: e,
|
|
771
|
-
value:
|
|
772
|
-
defaultValue:
|
|
771
|
+
value: s,
|
|
772
|
+
defaultValue: m,
|
|
773
773
|
onChange: d,
|
|
774
|
-
presets:
|
|
775
|
-
placeholder:
|
|
776
|
-
label:
|
|
777
|
-
helperText:
|
|
778
|
-
size:
|
|
779
|
-
disabled:
|
|
780
|
-
clearable:
|
|
774
|
+
presets: h = Xt,
|
|
775
|
+
placeholder: O = "Select date range",
|
|
776
|
+
label: ve,
|
|
777
|
+
helperText: ye,
|
|
778
|
+
size: $ = "md",
|
|
779
|
+
disabled: Be,
|
|
780
|
+
clearable: Me,
|
|
781
781
|
minDate: F,
|
|
782
782
|
maxDate: I,
|
|
783
|
-
maxRangeDays:
|
|
784
|
-
months:
|
|
785
|
-
align:
|
|
786
|
-
side:
|
|
787
|
-
open:
|
|
788
|
-
defaultOpen:
|
|
789
|
-
onOpenChange:
|
|
783
|
+
maxRangeDays: u,
|
|
784
|
+
months: ze = 2,
|
|
785
|
+
align: de = "start",
|
|
786
|
+
side: We = "bottom",
|
|
787
|
+
open: R,
|
|
788
|
+
defaultOpen: xe = !1,
|
|
789
|
+
onOpenChange: k,
|
|
790
790
|
infoText: re,
|
|
791
|
-
customPresetLabel:
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
791
|
+
customPresetLabel: Fe = "Custom",
|
|
792
|
+
customPresetDefaultDays: ge = 30,
|
|
793
|
+
applyLabel: Re = "Apply",
|
|
794
|
+
cancelLabel: oe = "Cancel",
|
|
795
|
+
clearLabel: ke = "Clear",
|
|
796
|
+
formatDate: g = ut,
|
|
797
|
+
formatRange: l,
|
|
798
|
+
triggerClassName: P,
|
|
799
|
+
contentClassName: y,
|
|
800
|
+
calendarClassName: A,
|
|
801
|
+
rangeLimitClassName: fe,
|
|
802
|
+
restrictToLast3Months: b = !1,
|
|
803
|
+
singleDateMode: T = !1,
|
|
804
|
+
allowedFutureDate: z = !1,
|
|
805
|
+
showLastOneYearOnly: L = !1,
|
|
806
|
+
...j
|
|
806
807
|
}) {
|
|
807
|
-
const
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
808
|
+
const D = T ? 1 : ze, [Ie, bt] = S(() => tt(m ?? {})), n = x(() => tt(s ?? Ie), [s, Ie]), [wt, vt] = S(xe), pe = R ?? wt, [Ge, ne] = S(n.preset ?? p), [f, Y] = S(n), [Ue, ae] = S(), [ie, G] = S(!1), me = x(
|
|
809
|
+
() => Ot(u ?? Jt),
|
|
810
|
+
[u]
|
|
811
|
+
), Le = x(() => {
|
|
812
|
+
const t = ge > 0 ? Math.floor(ge) : 30;
|
|
813
|
+
return u ? Math.min(t, u) : t;
|
|
814
|
+
}, [ge, u]), he = x(
|
|
815
|
+
() => b ? jt(Le, me) : $t,
|
|
816
|
+
[b, Le, me]
|
|
817
|
+
), [Ye, le] = S(
|
|
818
|
+
L ? we : he
|
|
819
|
+
), [U, X] = S(() => _e(n, D)), [ce, q] = S(() => {
|
|
820
|
+
const t = _e(n, D);
|
|
821
|
+
return B(t.year, t.month, 1);
|
|
822
|
+
}), Xe = Et(!1), J = D, Pe = x(() => {
|
|
823
|
+
if (b) {
|
|
824
|
+
const t = v(/* @__PURE__ */ new Date());
|
|
825
|
+
return { min: Ce(t, -90), max: t };
|
|
814
826
|
}
|
|
815
|
-
return
|
|
816
|
-
}, [
|
|
817
|
-
if (
|
|
818
|
-
return
|
|
819
|
-
const t =
|
|
820
|
-
return F &&
|
|
821
|
-
}, [
|
|
822
|
-
if (
|
|
823
|
-
return
|
|
824
|
-
const t =
|
|
825
|
-
return I &&
|
|
826
|
-
}, [
|
|
827
|
+
return rt(Ye);
|
|
828
|
+
}, [b, Ye]), K = x(() => {
|
|
829
|
+
if (z)
|
|
830
|
+
return Ce(v(/* @__PURE__ */ new Date()), 1);
|
|
831
|
+
const t = Pe.min;
|
|
832
|
+
return F && W(v(F), t) > 0 ? v(F) : t;
|
|
833
|
+
}, [z, Pe, F]), Q = x(() => {
|
|
834
|
+
if (z)
|
|
835
|
+
return Ce(v(/* @__PURE__ */ new Date()), 365);
|
|
836
|
+
const t = Pe.max;
|
|
837
|
+
return I && W(v(I), t) < 0 ? v(I) : t;
|
|
838
|
+
}, [z, Pe, I]), ue = x(
|
|
827
839
|
() => ({ year: K.getFullYear(), month: K.getMonth() }),
|
|
828
840
|
[K]
|
|
829
|
-
), E =
|
|
841
|
+
), E = x(
|
|
830
842
|
() => ({ year: Q.getFullYear(), month: Q.getMonth() }),
|
|
831
843
|
[Q]
|
|
832
|
-
),
|
|
844
|
+
), yt = x(() => J !== 2 ? E : B(ce.year, ce.month, -1), [E, ce, J]), xt = x(() => B(U.year, U.month, 1), [U]), be = De(
|
|
833
845
|
(t) => {
|
|
834
|
-
|
|
846
|
+
R === void 0 && vt(t), k == null || k(t);
|
|
835
847
|
},
|
|
836
|
-
[
|
|
837
|
-
),
|
|
848
|
+
[R, k]
|
|
849
|
+
), Ee = De(
|
|
838
850
|
(t) => {
|
|
839
|
-
|
|
851
|
+
s === void 0 && bt(t), d == null || d(t);
|
|
840
852
|
},
|
|
841
|
-
[d,
|
|
853
|
+
[d, s]
|
|
842
854
|
);
|
|
843
|
-
|
|
844
|
-
const t =
|
|
845
|
-
if (
|
|
846
|
-
if (Y(n), ne(n.preset ?? (C(n) ?
|
|
847
|
-
const
|
|
848
|
-
minMonth:
|
|
855
|
+
pt(() => {
|
|
856
|
+
const t = pe && !Xe.current;
|
|
857
|
+
if (Xe.current = pe, !t) return;
|
|
858
|
+
if (Y(n), ne(n.preset ?? (C(n) ? p : "")), ae(void 0), G(!1), C(n) && D === 2) {
|
|
859
|
+
const a = Ve(n.from, n.to, D, {
|
|
860
|
+
minMonth: ue,
|
|
849
861
|
maxMonth: E
|
|
850
862
|
});
|
|
851
|
-
X(
|
|
863
|
+
X(a.left), q(a.right);
|
|
852
864
|
} else {
|
|
853
|
-
const
|
|
854
|
-
X(
|
|
865
|
+
const a = _e(n, D);
|
|
866
|
+
X(a), q(B(a.year, a.month, 1));
|
|
855
867
|
}
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
868
|
+
if (b) {
|
|
869
|
+
const a = C(n) && n.preset === p && Ae(n.to, v(/* @__PURE__ */ new Date())) ? Gt(ot(n.to, n.from) + 1) : void 0;
|
|
870
|
+
le(
|
|
871
|
+
a && me.some((w) => w.value === a) ? a : he
|
|
872
|
+
);
|
|
873
|
+
return;
|
|
874
|
+
}
|
|
875
|
+
const i = (/* @__PURE__ */ new Date()).getFullYear();
|
|
876
|
+
if (C(n) && n.preset === p) {
|
|
877
|
+
const a = n.from.getFullYear(), w = n.to.getFullYear();
|
|
878
|
+
a === w && a >= ht && a < i ? le(String(a)) : le(we);
|
|
860
879
|
} else
|
|
861
|
-
|
|
862
|
-
}, [
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
880
|
+
le(L ? we : he);
|
|
881
|
+
}, [
|
|
882
|
+
n,
|
|
883
|
+
me,
|
|
884
|
+
he,
|
|
885
|
+
E,
|
|
886
|
+
ue,
|
|
887
|
+
D,
|
|
888
|
+
pe,
|
|
889
|
+
b,
|
|
890
|
+
L
|
|
891
|
+
]);
|
|
892
|
+
const Rt = x(() => {
|
|
893
|
+
if (l)
|
|
894
|
+
return l(n);
|
|
895
|
+
const t = Ut(h, n.preset);
|
|
896
|
+
return t && n.preset !== p ? t : C(n) ? Ae(n.from, n.to) ? g(n.from) : `${g(n.from)} - ${g(n.to)}` : O;
|
|
897
|
+
}, [n, g, l, O, h]), kt = De(
|
|
869
898
|
(t) => {
|
|
870
|
-
|
|
871
|
-
const
|
|
872
|
-
Y({ preset:
|
|
873
|
-
const
|
|
874
|
-
minMonth: { year:
|
|
875
|
-
maxMonth: { year:
|
|
899
|
+
le(t);
|
|
900
|
+
const i = rt(t), { from: a, to: w } = qt(i, { minDate: F, maxDate: I, maxRangeDays: u });
|
|
901
|
+
Y({ preset: p, from: a, to: w });
|
|
902
|
+
const se = Ve(a, w, D, {
|
|
903
|
+
minMonth: { year: a.getFullYear(), month: a.getMonth() },
|
|
904
|
+
maxMonth: { year: w.getFullYear(), month: w.getMonth() }
|
|
876
905
|
});
|
|
877
|
-
X(
|
|
906
|
+
X(se.left), q(se.right), G(!1), ae(void 0);
|
|
878
907
|
},
|
|
879
|
-
[
|
|
880
|
-
),
|
|
908
|
+
[D, F, I, u]
|
|
909
|
+
), He = De(
|
|
881
910
|
(t) => {
|
|
882
|
-
const
|
|
883
|
-
return !!(
|
|
911
|
+
const i = v(t), a = v(K), w = v(Q);
|
|
912
|
+
return !!(W(i, a) < 0 || W(i, w) > 0 || ie && f.from && u && ot(i, f.from) + 1 > u);
|
|
884
913
|
},
|
|
885
|
-
[ie,
|
|
886
|
-
),
|
|
914
|
+
[ie, f.from, K, Q, u]
|
|
915
|
+
), Pt = (t) => {
|
|
887
916
|
if (t.disabled) return;
|
|
888
|
-
const
|
|
889
|
-
|
|
890
|
-
},
|
|
891
|
-
ne(
|
|
892
|
-
const t = (
|
|
893
|
-
Y({ preset:
|
|
894
|
-
const
|
|
895
|
-
minMonth:
|
|
917
|
+
const i = t.getRange(), a = $e(i.from, i.to);
|
|
918
|
+
Ee({ preset: t.id, ...a }), be(!1);
|
|
919
|
+
}, Dt = () => {
|
|
920
|
+
ne(p), le(L ? we : he);
|
|
921
|
+
const t = (se) => W(se, K) < 0 ? K : W(se, Q) > 0 ? Q : se, i = t(v(/* @__PURE__ */ new Date())), a = t(Ce(i, -(Le - 1)));
|
|
922
|
+
Y({ preset: p, from: a, to: i });
|
|
923
|
+
const w = Ve(a, i, D, {
|
|
924
|
+
minMonth: ue,
|
|
896
925
|
maxMonth: E
|
|
897
926
|
});
|
|
898
|
-
X(
|
|
899
|
-
},
|
|
900
|
-
if (
|
|
901
|
-
const
|
|
902
|
-
if (
|
|
903
|
-
Y({ preset:
|
|
927
|
+
X(w.left), q(w.right), G(!1), ae(void 0);
|
|
928
|
+
}, qe = (t) => {
|
|
929
|
+
if (He(t)) return;
|
|
930
|
+
const i = v(t);
|
|
931
|
+
if (T) {
|
|
932
|
+
Y({ preset: p, from: i, to: i }), ne(p);
|
|
904
933
|
return;
|
|
905
934
|
}
|
|
906
|
-
if (!ie || !
|
|
907
|
-
Y({ preset:
|
|
935
|
+
if (!ie || !f.from || f.to) {
|
|
936
|
+
Y({ preset: p, from: i, to: void 0 }), ne(p), G(!0);
|
|
908
937
|
return;
|
|
909
938
|
}
|
|
910
|
-
const
|
|
911
|
-
Y({ preset:
|
|
912
|
-
},
|
|
913
|
-
C(
|
|
914
|
-
},
|
|
915
|
-
Y(n), ne(n.preset ?? (C(n) ?
|
|
916
|
-
},
|
|
917
|
-
|
|
918
|
-
},
|
|
919
|
-
return /* @__PURE__ */
|
|
920
|
-
|
|
921
|
-
/* @__PURE__ */
|
|
922
|
-
/* @__PURE__ */ r(
|
|
923
|
-
|
|
939
|
+
const a = $e(f.from, i);
|
|
940
|
+
Y({ preset: p, ...a }), G(!1);
|
|
941
|
+
}, Ct = () => {
|
|
942
|
+
C(f) && (Ee({ preset: p, from: f.from, to: f.to }), be(!1));
|
|
943
|
+
}, St = () => {
|
|
944
|
+
Y(n), ne(n.preset ?? (C(n) ? p : "")), G(!1), ae(void 0), be(!1);
|
|
945
|
+
}, At = () => {
|
|
946
|
+
Ee({}), Y({}), ne(""), G(!1), be(!1);
|
|
947
|
+
}, Tt = C(f), H = Ge === p, Bt = T ? !!f.from : Tt, Je = re ?? (u ? `Date range can be selected for up to ${u} days.` : b ? "Date can be viewed only for the last 90 days." : T && z ? "Date can be viewed only for a period of future date." : "Date can be viewed only for a period of up to 1 year."), Mt = _(U, ue) > 0, Ke = J === 2 ? _(ce, E) < 0 : _(U, E) < 0;
|
|
948
|
+
return /* @__PURE__ */ c(wr, { className: e, ...j, children: [
|
|
949
|
+
ve && /* @__PURE__ */ r(vr, { children: ve }),
|
|
950
|
+
/* @__PURE__ */ c(zt, { open: pe, onOpenChange: be, children: [
|
|
951
|
+
/* @__PURE__ */ r(Wt, { asChild: !0, children: /* @__PURE__ */ c(
|
|
952
|
+
yr,
|
|
924
953
|
{
|
|
925
954
|
type: "button",
|
|
926
|
-
disabled:
|
|
955
|
+
disabled: Be,
|
|
927
956
|
"data-filled": C(n) || n.preset ? "" : void 0,
|
|
928
957
|
ownerState: {
|
|
929
|
-
md:
|
|
958
|
+
md: $ === "md",
|
|
930
959
|
empty: !C(n) && !n.preset,
|
|
931
|
-
smFilled:
|
|
960
|
+
smFilled: $ === "sm" && (C(n) || !!n.preset)
|
|
932
961
|
},
|
|
933
|
-
className:
|
|
962
|
+
className: P,
|
|
934
963
|
children: [
|
|
935
|
-
/* @__PURE__ */ r(
|
|
936
|
-
/* @__PURE__ */ r(
|
|
937
|
-
/* @__PURE__ */ r(
|
|
964
|
+
/* @__PURE__ */ r(xr, { size: 13 }),
|
|
965
|
+
/* @__PURE__ */ r(Rr, { children: Rt }),
|
|
966
|
+
/* @__PURE__ */ r(kr, { size: 10, weight: "bold", ownerState: { open: pe } })
|
|
938
967
|
]
|
|
939
968
|
}
|
|
940
969
|
) }),
|
|
941
|
-
/* @__PURE__ */ r(
|
|
942
|
-
|
|
970
|
+
/* @__PURE__ */ r(Ft, { children: /* @__PURE__ */ r(er, { children: /* @__PURE__ */ c(
|
|
971
|
+
Pr,
|
|
943
972
|
{
|
|
944
|
-
align:
|
|
945
|
-
side:
|
|
973
|
+
align: de,
|
|
974
|
+
side: We,
|
|
946
975
|
sideOffset: 6,
|
|
947
|
-
collisionPadding:
|
|
976
|
+
collisionPadding: Vt,
|
|
948
977
|
ownerState: { widthMode: H ? J === 1 ? "one" : "two" : "presets" },
|
|
949
|
-
className:
|
|
978
|
+
className: y,
|
|
950
979
|
children: [
|
|
951
|
-
/* @__PURE__ */
|
|
952
|
-
/* @__PURE__ */
|
|
953
|
-
/* @__PURE__ */
|
|
954
|
-
|
|
955
|
-
const
|
|
956
|
-
return /* @__PURE__ */
|
|
957
|
-
|
|
980
|
+
/* @__PURE__ */ c(Dr, { ownerState: { customPanel: H }, children: [
|
|
981
|
+
/* @__PURE__ */ c(Cr, { ownerState: { customPanel: H }, children: [
|
|
982
|
+
/* @__PURE__ */ c(Sr, { children: [
|
|
983
|
+
h.map((t) => {
|
|
984
|
+
const i = Ge === t.id;
|
|
985
|
+
return /* @__PURE__ */ c(
|
|
986
|
+
st,
|
|
958
987
|
{
|
|
959
988
|
type: "button",
|
|
960
989
|
disabled: t.disabled,
|
|
961
|
-
onClick: () =>
|
|
962
|
-
ownerState: { md:
|
|
990
|
+
onClick: () => Pt(t),
|
|
991
|
+
ownerState: { md: $ === "md", selected: i, presetDisabled: !!t.disabled },
|
|
963
992
|
children: [
|
|
964
993
|
/* @__PURE__ */ r("span", { children: t.label }),
|
|
965
|
-
|
|
994
|
+
i && /* @__PURE__ */ r(et, { size: 14, weight: "bold" })
|
|
966
995
|
]
|
|
967
996
|
},
|
|
968
997
|
t.id
|
|
969
998
|
);
|
|
970
999
|
}),
|
|
971
|
-
/* @__PURE__ */
|
|
972
|
-
|
|
1000
|
+
/* @__PURE__ */ c(
|
|
1001
|
+
st,
|
|
973
1002
|
{
|
|
974
1003
|
type: "button",
|
|
975
|
-
onClick:
|
|
976
|
-
ownerState: { md:
|
|
1004
|
+
onClick: Dt,
|
|
1005
|
+
ownerState: { md: $ === "md", selected: H, presetDisabled: !1 },
|
|
977
1006
|
children: [
|
|
978
|
-
/* @__PURE__ */ r("span", { children:
|
|
979
|
-
H && /* @__PURE__ */ r(
|
|
1007
|
+
/* @__PURE__ */ r("span", { children: Fe }),
|
|
1008
|
+
H && /* @__PURE__ */ r(et, { size: 14, weight: "bold" })
|
|
980
1009
|
]
|
|
981
1010
|
}
|
|
982
1011
|
)
|
|
983
1012
|
] }),
|
|
984
|
-
|
|
985
|
-
/* @__PURE__ */ r(
|
|
986
|
-
/* @__PURE__ */ r("span", { children:
|
|
1013
|
+
Je && H && /* @__PURE__ */ c(Ar, { className: fe, children: [
|
|
1014
|
+
/* @__PURE__ */ r(Tr, { children: /* @__PURE__ */ r(Nt, {}) }),
|
|
1015
|
+
/* @__PURE__ */ r("span", { children: Je })
|
|
987
1016
|
] })
|
|
988
1017
|
] }),
|
|
989
|
-
H && /* @__PURE__ */
|
|
990
|
-
!
|
|
991
|
-
/* @__PURE__ */ r(
|
|
1018
|
+
H && /* @__PURE__ */ c(Br, { children: [
|
|
1019
|
+
!z && !T && /* @__PURE__ */ r(Mr, { children: /* @__PURE__ */ c(zr, { style: _t, children: [
|
|
1020
|
+
/* @__PURE__ */ r(Wr, { children: b ? "Please select the period you want to view data for" : "Please select the year you want to view data for" }),
|
|
992
1021
|
/* @__PURE__ */ r(
|
|
993
|
-
|
|
1022
|
+
Fr,
|
|
994
1023
|
{
|
|
995
1024
|
size: "sm",
|
|
996
|
-
value:
|
|
997
|
-
onValueChange:
|
|
998
|
-
options:
|
|
1025
|
+
value: Ye,
|
|
1026
|
+
onValueChange: kt,
|
|
1027
|
+
options: b ? me : L ? nt.filter((t) => t.value === we) : nt
|
|
999
1028
|
}
|
|
1000
1029
|
)
|
|
1001
1030
|
] }) }),
|
|
1002
|
-
/* @__PURE__ */
|
|
1031
|
+
/* @__PURE__ */ c(Ir, { ownerState: { two: J === 2 }, children: [
|
|
1003
1032
|
/* @__PURE__ */ r(
|
|
1004
|
-
|
|
1033
|
+
ct,
|
|
1005
1034
|
{
|
|
1006
1035
|
year: U.year,
|
|
1007
1036
|
month: U.month,
|
|
1008
|
-
from:
|
|
1009
|
-
to:
|
|
1010
|
-
hovered:
|
|
1037
|
+
from: f.from,
|
|
1038
|
+
to: f.to,
|
|
1039
|
+
hovered: Ue,
|
|
1011
1040
|
awaitingTo: ie,
|
|
1012
|
-
isDateDisabled:
|
|
1013
|
-
onSelectDate:
|
|
1041
|
+
isDateDisabled: He,
|
|
1042
|
+
onSelectDate: qe,
|
|
1014
1043
|
onHoverDate: ae,
|
|
1015
|
-
onPrev: () => X((t) =>
|
|
1016
|
-
onNext: () => X((t) =>
|
|
1017
|
-
onNavigateTo: (t,
|
|
1018
|
-
minMonth:
|
|
1019
|
-
maxMonth:
|
|
1020
|
-
showPrev:
|
|
1021
|
-
showNext: J !== 2 &&
|
|
1022
|
-
className:
|
|
1044
|
+
onPrev: () => X((t) => B(t.year, t.month, -1)),
|
|
1045
|
+
onNext: () => X((t) => B(t.year, t.month, 1)),
|
|
1046
|
+
onNavigateTo: (t, i) => X({ year: t, month: i }),
|
|
1047
|
+
minMonth: ue,
|
|
1048
|
+
maxMonth: yt,
|
|
1049
|
+
showPrev: Mt,
|
|
1050
|
+
showNext: J !== 2 && Ke,
|
|
1051
|
+
className: A
|
|
1023
1052
|
}
|
|
1024
1053
|
),
|
|
1025
1054
|
J === 2 && /* @__PURE__ */ r(
|
|
1026
|
-
|
|
1055
|
+
ct,
|
|
1027
1056
|
{
|
|
1028
|
-
year:
|
|
1029
|
-
month:
|
|
1030
|
-
from:
|
|
1031
|
-
to:
|
|
1032
|
-
hovered:
|
|
1057
|
+
year: ce.year,
|
|
1058
|
+
month: ce.month,
|
|
1059
|
+
from: f.from,
|
|
1060
|
+
to: f.to,
|
|
1061
|
+
hovered: Ue,
|
|
1033
1062
|
awaitingTo: ie,
|
|
1034
|
-
isDateDisabled:
|
|
1035
|
-
onSelectDate:
|
|
1063
|
+
isDateDisabled: He,
|
|
1064
|
+
onSelectDate: qe,
|
|
1036
1065
|
onHoverDate: ae,
|
|
1037
|
-
onPrev: () => q((t) =>
|
|
1038
|
-
onNext: () => q((t) =>
|
|
1039
|
-
onNavigateTo: (t,
|
|
1040
|
-
minMonth:
|
|
1066
|
+
onPrev: () => q((t) => B(t.year, t.month, -1)),
|
|
1067
|
+
onNext: () => q((t) => B(t.year, t.month, 1)),
|
|
1068
|
+
onNavigateTo: (t, i) => q({ year: t, month: i }),
|
|
1069
|
+
minMonth: xt,
|
|
1041
1070
|
maxMonth: E,
|
|
1042
1071
|
showPrev: !1,
|
|
1043
|
-
showNext:
|
|
1044
|
-
className:
|
|
1072
|
+
showNext: Ke,
|
|
1073
|
+
className: A
|
|
1045
1074
|
}
|
|
1046
1075
|
)
|
|
1047
1076
|
] })
|
|
1048
1077
|
] })
|
|
1049
1078
|
] }),
|
|
1050
|
-
H && /* @__PURE__ */ r(
|
|
1051
|
-
/* @__PURE__ */
|
|
1052
|
-
/* @__PURE__ */
|
|
1053
|
-
/* @__PURE__ */ r(
|
|
1079
|
+
H && /* @__PURE__ */ r(Lr, { children: /* @__PURE__ */ c(Yr, { children: [
|
|
1080
|
+
/* @__PURE__ */ c(Er, { children: [
|
|
1081
|
+
/* @__PURE__ */ c(Hr, { children: [
|
|
1082
|
+
/* @__PURE__ */ r(Nr, { children: "Selected:" }),
|
|
1054
1083
|
" ",
|
|
1055
|
-
/* @__PURE__ */ r(
|
|
1056
|
-
!
|
|
1084
|
+
/* @__PURE__ */ r(dt, { children: f.from ? g(f.from) : "--/--/----" }),
|
|
1085
|
+
!T && /* @__PURE__ */ c(gt, { children: [
|
|
1057
1086
|
" ",
|
|
1058
|
-
/* @__PURE__ */ r(
|
|
1087
|
+
/* @__PURE__ */ r(_r, { children: "To" }),
|
|
1059
1088
|
" ",
|
|
1060
|
-
/* @__PURE__ */ r(
|
|
1089
|
+
/* @__PURE__ */ r(dt, { children: f.to ? g(f.to) : "--/--/----" })
|
|
1061
1090
|
] })
|
|
1062
1091
|
] }),
|
|
1063
|
-
ie && !
|
|
1092
|
+
ie && !T && /* @__PURE__ */ r(Vr, { children: "Date range incomplete. Select both Start and End dates." })
|
|
1064
1093
|
] }),
|
|
1065
|
-
/* @__PURE__ */
|
|
1066
|
-
|
|
1067
|
-
/* @__PURE__ */ r(
|
|
1068
|
-
/* @__PURE__ */ r(
|
|
1094
|
+
/* @__PURE__ */ c(Or, { children: [
|
|
1095
|
+
Me && /* @__PURE__ */ r(Ne, { variant: "ghost", size: "sm", leftIcon: /* @__PURE__ */ r(Yt, { size: 13, weight: "bold" }), onClick: At, children: ke }),
|
|
1096
|
+
/* @__PURE__ */ r(Ne, { variant: "outline", size: "sm", onClick: St, children: oe }),
|
|
1097
|
+
/* @__PURE__ */ r(Ne, { size: "sm", disabled: !Bt, onClick: Ct, children: Re })
|
|
1069
1098
|
] })
|
|
1070
1099
|
] }) })
|
|
1071
1100
|
]
|
|
1072
1101
|
}
|
|
1073
1102
|
) }) })
|
|
1074
1103
|
] }),
|
|
1075
|
-
|
|
1104
|
+
ye && /* @__PURE__ */ r($r, { children: ye })
|
|
1076
1105
|
] });
|
|
1077
1106
|
}
|
|
1078
1107
|
export {
|
|
1079
|
-
|
|
1108
|
+
so as DateRangePicker
|
|
1080
1109
|
};
|
|
1081
1110
|
//# sourceMappingURL=DateRangePicker.js.map
|