@calcom/atoms 1.0.95 → 1.0.96-beta-2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AddressInput-jf7dQUjM.js → AddressInput-BwaFtJdW.js} +9 -8
- package/dist/{AlbyPriceComponent-xvHTaJkB.js → AlbyPriceComponent-5_IY8XI4.js} +53 -52
- package/dist/AppCard-vvom7JzI.js +162 -0
- package/dist/AppListCardPlatformWrapper-BMbohX9G.js +9 -0
- package/dist/{AppListCardWebWrapper-mvJDHeHP.js → AppListCardWebWrapper-jgSaE2tc.js} +10 -9
- package/dist/AppSettingsInterface-GvEAHqgC.js +23 -0
- package/dist/AppSettingsInterface-hahnFvsF.js +29 -0
- package/dist/AppSettingsInterface-rwvU2JZ1.js +75 -0
- package/dist/{DateRangePicker-sOCh5jbf.js → DateRangePicker-H2MDflCi.js} +784 -783
- package/dist/EventTypeAppCardInterface-12lncOdf.js +34 -0
- package/dist/EventTypeAppCardInterface-27TiN1LB.js +34 -0
- package/dist/EventTypeAppCardInterface-4REsm-ax.js +24 -0
- package/dist/EventTypeAppCardInterface-BIBLDaQW.js +41 -0
- package/dist/EventTypeAppCardInterface-Bxn2VRDe.js +42 -0
- package/dist/EventTypeAppCardInterface-Ia4uQvA6.js +24 -0
- package/dist/EventTypeAppCardInterface-IsxbWtC-.js +86 -0
- package/dist/EventTypeAppCardInterface-MYYfLsWy.js +31 -0
- package/dist/EventTypeAppCardInterface-TvEkNxDI.js +34 -0
- package/dist/EventTypeAppCardInterface-W-C-Vuq4.js +32 -0
- package/dist/EventTypeAppCardInterface-YC7gXugR.js +41 -0
- package/dist/EventTypeAppCardInterface-ZN2mBt9v.js +34 -0
- package/dist/EventTypeAppCardInterface-Ze5KpMAZ.js +24 -0
- package/dist/EventTypeAppCardInterface-ZshqKbPT.js +34 -0
- package/dist/{EventTypeAppCardInterface-fTBMlXsW.js → EventTypeAppCardInterface-_8D8Qs9P.js} +17 -16
- package/dist/EventTypeAppCardInterface-cXUeW2Wg.js +24 -0
- package/dist/EventTypeAppCardInterface-f4ubwOzR.js +42 -0
- package/dist/EventTypeAppCardInterface-g5WwbLf6.js +39 -0
- package/dist/EventTypeAppCardInterface-iMFMTR_Q.js +24 -0
- package/dist/EventTypeAppCardInterface-kh27UiaS.js +34 -0
- package/dist/EventTypeAppCardInterface-loGF0ZWc.js +452 -0
- package/dist/EventTypeAppCardInterface-mpaqmq1C.js +32 -0
- package/dist/EventTypeAppCardInterface-n2hGNKAo.js +34 -0
- package/dist/EventTypeAppCardInterface-nYtaHSPH.js +49 -0
- package/dist/EventTypeAppCardInterface-qIAbqcW-.js +51 -0
- package/dist/EventTypeAppCardInterface-zTg1f5hR.js +33 -0
- package/dist/{EventTypeAppSettingsInterface-uy_EiYRt.js → EventTypeAppSettingsInterface-2iQLRc2L.js} +6 -5
- package/dist/{EventTypeAppSettingsInterface-PqMppH4B.js → EventTypeAppSettingsInterface-4j95fNdX.js} +72 -71
- package/dist/EventTypeAppSettingsInterface-7r6Eayog.js +221 -0
- package/dist/{EventTypeAppSettingsInterface-WFmNo91Z.js → EventTypeAppSettingsInterface-8XJ_he7F.js} +7 -6
- package/dist/EventTypeAppSettingsInterface-PHF7Vsmi.js +43 -0
- package/dist/EventTypeAppSettingsInterface-ThYijWt9.js +42 -0
- package/dist/EventTypeAppSettingsInterface-WrZ3-X7V.js +48 -0
- package/dist/{EventTypeAppSettingsInterface-CJVHdj5Z.js → EventTypeAppSettingsInterface-eJdqCSck.js} +39 -38
- package/dist/{EventTypeAppSettingsInterface-W6KdgBF4.js → EventTypeAppSettingsInterface-hI24Lgxv.js} +6 -5
- package/dist/{EventTypeAppSettingsInterface-5MFFd8K-.js → EventTypeAppSettingsInterface-rDoWsnFN.js} +6 -5
- package/dist/EventTypeAppSettingsInterface-vOTw0emu.js +72 -0
- package/dist/EventTypeAppSettingsInterface-wRHYYE7a.js +78 -0
- package/dist/InstallAppButton-9T0Dl0KY.js +14 -0
- package/dist/InstallAppButton-J-143AmA.js +14 -0
- package/dist/{InstallAppButton-l1JAKXJ2.js → InstallAppButton-JXhBVaYJ.js} +8 -8
- package/dist/InstallAppButton-qpMMTpVW.js +58 -0
- package/dist/{PhoneInput-ZSx8kdAN.js → PhoneInput-EZYUI6dU.js} +97 -96
- package/dist/StripePaymentForm-N2YTyBqm.js +1157 -0
- package/dist/cal-atoms.js +6 -6
- package/dist/cal-atoms.umd.cjs +372 -436
- package/dist/{framer-features-12oM4SHg.js → framer-features-pqh7SjMd.js} +65 -65
- package/dist/{index-3tVCLfaZ.js → index-D4njVTQA.js} +2 -2
- package/dist/{index-LgmOiR20.js → index-KPOdbfnz.js} +1 -1
- package/dist/{index-xyF3DZet.js → index-_1f6rhg6.js} +72418 -98083
- package/dist/{index-sMgQwFEx.js → index-_1xRkNP6.js} +1 -1
- package/dist/index-v9tzGygd.js +626 -0
- package/dist/{isSupportedCountry-DPaP_R-3.js → isSupportedCountry--S1ZKbg0.js} +1 -1
- package/dist/packages/app-store/hitpay/pages/setup/index.d.ts.map +1 -1
- package/dist/packages/app-store/salesforce/lib/CrmService.d.ts.map +1 -1
- package/dist/packages/app-store/salesforce/lib/__tests__/salesforceMock.d.ts.map +1 -1
- package/dist/packages/features/eventtypes/components/EventTypeLayout.d.ts.map +1 -1
- package/dist/packages/features/schedules/components/DateOverrideList.d.ts +1 -1
- package/dist/packages/features/schedules/components/DateOverrideList.d.ts.map +1 -1
- package/dist/packages/features/shell/Shell.d.ts +0 -1
- package/dist/packages/features/shell/Shell.d.ts.map +1 -1
- package/dist/packages/platform/atoms/availability/AvailabilitySettings.d.ts +1 -1
- package/dist/packages/platform/atoms/availability/AvailabilitySettings.d.ts.map +1 -1
- package/dist/packages/platform/atoms/hooks/bookings/useHandleBookEvent.d.ts.map +1 -1
- package/dist/packages/platform/atoms/vite.config.d.ts.map +1 -1
- package/dist/packages/trpc/react/shared.d.ts +1 -1
- package/dist/packages/trpc/react/shared.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/_app.d.ts +469 -373
- package/dist/packages/trpc/server/routers/_app.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/_router.d.ts +0 -124
- package/dist/packages/trpc/server/routers/loggedInViewer/_router.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/viewer/__tests__/outOfOffice.handler.test.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/_router.d.ts +469 -373
- package/dist/packages/trpc/server/routers/viewer/_router.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/_router.d.ts +132 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/_router.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOffice.utils.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeCreateOrUpdate.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeCreateOrUpdate.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeCreateOrUpdate.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntriesList.handler.d.ts +6 -6
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntriesList.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntriesList.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntryDelete.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntryDelete.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntryDelete.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeReasons.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/_router.d.ts +26 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/_router.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/travelSchedules}/getTravelSchedules.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/getTravelSchedules.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/getTravelSchedules.schema.d.ts.map +1 -0
- package/dist/{useIsAppEnabled-lWZHByfn.js → useIsAppEnabled-EWMW2qIQ.js} +1 -1
- package/package.json +3 -2
- package/dist/AppCard-6POsrWUi.js +0 -161
- package/dist/AppListCardPlatformWrapper-lBuJfkuH.js +0 -8
- package/dist/AppSettingsInterface-4Tks23KV.js +0 -22
- package/dist/AppSettingsInterface-FOcRnk3Z.js +0 -28
- package/dist/AppSettingsInterface-GkmVYzlh.js +0 -74
- package/dist/EventTypeAppCardInterface-3WtIPV90.js +0 -48
- package/dist/EventTypeAppCardInterface-59_1Chn3.js +0 -23
- package/dist/EventTypeAppCardInterface-6vA3mNLM.js +0 -23
- package/dist/EventTypeAppCardInterface-8G0alNRB.js +0 -23
- package/dist/EventTypeAppCardInterface-DmRoseb5.js +0 -33
- package/dist/EventTypeAppCardInterface-E6oGIXby.js +0 -30
- package/dist/EventTypeAppCardInterface-F3iYQZzz.js +0 -33
- package/dist/EventTypeAppCardInterface-Gz942CB8.js +0 -41
- package/dist/EventTypeAppCardInterface-JtE97AbR.js +0 -38
- package/dist/EventTypeAppCardInterface-KoXkfIyN.js +0 -451
- package/dist/EventTypeAppCardInterface-O6Qm27_l.js +0 -33
- package/dist/EventTypeAppCardInterface-S1ri5C5w.js +0 -33
- package/dist/EventTypeAppCardInterface-SDs4emhR.js +0 -40
- package/dist/EventTypeAppCardInterface-_ilno5U4.js +0 -32
- package/dist/EventTypeAppCardInterface-b4zgfRie.js +0 -31
- package/dist/EventTypeAppCardInterface-dDQePpru.js +0 -33
- package/dist/EventTypeAppCardInterface-dxJA4SDA.js +0 -40
- package/dist/EventTypeAppCardInterface-dyUZdYi1.js +0 -31
- package/dist/EventTypeAppCardInterface-hEAZCP4y.js +0 -33
- package/dist/EventTypeAppCardInterface-iH8XDMJc.js +0 -23
- package/dist/EventTypeAppCardInterface-kzr8i-KV.js +0 -33
- package/dist/EventTypeAppCardInterface-nIcRzdps.js +0 -23
- package/dist/EventTypeAppCardInterface-n_WURLN6.js +0 -41
- package/dist/EventTypeAppCardInterface-oOvyPBbl.js +0 -85
- package/dist/EventTypeAppCardInterface-uxE48sJK.js +0 -50
- package/dist/EventTypeAppSettingsInterface-11qrPEq9.js +0 -47
- package/dist/EventTypeAppSettingsInterface-DQAYuCVY.js +0 -220
- package/dist/EventTypeAppSettingsInterface-G9QLW8nF.js +0 -42
- package/dist/EventTypeAppSettingsInterface-KP3N_MKJ.js +0 -71
- package/dist/EventTypeAppSettingsInterface-jExNP130.js +0 -77
- package/dist/EventTypeAppSettingsInterface-wvbPVzEw.js +0 -41
- package/dist/InstallAppButton-Texs62TM.js +0 -13
- package/dist/InstallAppButton-k-fI7lJG.js +0 -13
- package/dist/InstallAppButton-uI0Lr0hc.js +0 -57
- package/dist/StripePaymentForm-8vKNcyMv.js +0 -492
- package/dist/index-TRud8iK5.js +0 -510
- package/dist/packages/trpc/server/routers/loggedInViewer/__tests__/outOfOffice.handler.test.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/getTravelSchedules.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/getTravelSchedules.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOffice.utils.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeCreateOrUpdate.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeCreateOrUpdate.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntriesList.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntriesList.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntryDelete.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntryDelete.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeReasons.handler.d.ts.map +0 -1
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer}/__tests__/outOfOffice.handler.test.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOffice.utils.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeCreateOrUpdate.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntriesList.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntryDelete.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeReasons.handler.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/travelSchedules}/getTravelSchedules.schema.d.ts +0 -0
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { jsx as c, jsxs as O, Fragment as T } from "react/jsx-runtime";
|
|
2
|
+
import { Z as J, aQ as Ye, aR as Fe, a4 as Le, aS as Dt, aT as Mt, z as _t, aU as kt } from "./index-_1f6rhg6.js";
|
|
3
|
+
import { createContext as q, forwardRef as Nt, useContext as Q, useState as K, useEffect as ie, useLayoutEffect as xt, useRef as Pt } from "react";
|
|
4
|
+
function M(e) {
|
|
4
5
|
const t = Object.prototype.toString.call(e);
|
|
5
6
|
return e instanceof Date || typeof e == "object" && t === "[object Date]" ? new e.constructor(+e) : typeof e == "number" || t === "[object Number]" || typeof e == "string" || t === "[object String]" ? new Date(e) : /* @__PURE__ */ new Date(NaN);
|
|
6
7
|
}
|
|
7
|
-
function
|
|
8
|
+
function W(e, t) {
|
|
8
9
|
return e instanceof Date ? new e.constructor(t) : new Date(t);
|
|
9
10
|
}
|
|
10
11
|
function P(e, t) {
|
|
11
|
-
const n =
|
|
12
|
-
return isNaN(t) ?
|
|
12
|
+
const n = M(e);
|
|
13
|
+
return isNaN(t) ? W(e, NaN) : (t && n.setDate(n.getDate() + t), n);
|
|
13
14
|
}
|
|
14
|
-
function
|
|
15
|
-
const n =
|
|
15
|
+
function Y(e, t) {
|
|
16
|
+
const n = M(e);
|
|
16
17
|
if (isNaN(t))
|
|
17
|
-
return
|
|
18
|
+
return W(e, NaN);
|
|
18
19
|
if (!t)
|
|
19
20
|
return n;
|
|
20
|
-
const a = n.getDate(), r =
|
|
21
|
+
const a = n.getDate(), r = W(e, n.getTime());
|
|
21
22
|
r.setMonth(n.getMonth() + t + 1, 0);
|
|
22
23
|
const o = r.getDate();
|
|
23
24
|
return a >= o ? r : (n.setFullYear(
|
|
@@ -26,33 +27,33 @@ function S(e, t) {
|
|
|
26
27
|
a
|
|
27
28
|
), n);
|
|
28
29
|
}
|
|
29
|
-
const
|
|
30
|
-
let
|
|
31
|
-
function
|
|
32
|
-
return
|
|
30
|
+
const De = 6048e5, Ot = 864e5;
|
|
31
|
+
let Ct = {};
|
|
32
|
+
function Z() {
|
|
33
|
+
return Ct;
|
|
33
34
|
}
|
|
34
|
-
function
|
|
35
|
-
var s,
|
|
36
|
-
const n =
|
|
35
|
+
function I(e, t) {
|
|
36
|
+
var s, l, d, u;
|
|
37
|
+
const n = Z(), a = (t == null ? void 0 : t.weekStartsOn) ?? ((l = (s = t == null ? void 0 : t.locale) == null ? void 0 : s.options) == null ? void 0 : l.weekStartsOn) ?? n.weekStartsOn ?? ((u = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : u.weekStartsOn) ?? 0, r = M(e), o = r.getDay(), i = (o < a ? 7 : 0) + o - a;
|
|
37
38
|
return r.setDate(r.getDate() - i), r.setHours(0, 0, 0, 0), r;
|
|
38
39
|
}
|
|
39
|
-
function
|
|
40
|
-
return
|
|
40
|
+
function A(e) {
|
|
41
|
+
return I(e, { weekStartsOn: 1 });
|
|
41
42
|
}
|
|
42
|
-
function
|
|
43
|
-
const t =
|
|
43
|
+
function Xe(e) {
|
|
44
|
+
const t = M(e), n = t.getFullYear(), a = W(e, 0);
|
|
44
45
|
a.setFullYear(n + 1, 0, 4), a.setHours(0, 0, 0, 0);
|
|
45
|
-
const r =
|
|
46
|
+
const r = A(a), o = W(e, 0);
|
|
46
47
|
o.setFullYear(n, 0, 4), o.setHours(0, 0, 0, 0);
|
|
47
|
-
const i =
|
|
48
|
+
const i = A(o);
|
|
48
49
|
return t.getTime() >= r.getTime() ? n + 1 : t.getTime() >= i.getTime() ? n : n - 1;
|
|
49
50
|
}
|
|
50
|
-
function
|
|
51
|
-
const t =
|
|
51
|
+
function G(e) {
|
|
52
|
+
const t = M(e);
|
|
52
53
|
return t.setHours(0, 0, 0, 0), t;
|
|
53
54
|
}
|
|
54
|
-
function
|
|
55
|
-
const t =
|
|
55
|
+
function re(e) {
|
|
56
|
+
const t = M(e), n = new Date(
|
|
56
57
|
Date.UTC(
|
|
57
58
|
t.getFullYear(),
|
|
58
59
|
t.getMonth(),
|
|
@@ -65,77 +66,77 @@ function ne(e) {
|
|
|
65
66
|
);
|
|
66
67
|
return n.setUTCFullYear(t.getFullYear()), +e - +n;
|
|
67
68
|
}
|
|
68
|
-
function
|
|
69
|
-
const n =
|
|
70
|
-
return Math.round((r - o) /
|
|
69
|
+
function L(e, t) {
|
|
70
|
+
const n = G(e), a = G(t), r = +n - re(n), o = +a - re(a);
|
|
71
|
+
return Math.round((r - o) / Ot);
|
|
71
72
|
}
|
|
72
|
-
function
|
|
73
|
-
const t =
|
|
74
|
-
return n.setFullYear(t, 0, 4), n.setHours(0, 0, 0, 0),
|
|
73
|
+
function St(e) {
|
|
74
|
+
const t = Xe(e), n = W(e, 0);
|
|
75
|
+
return n.setFullYear(t, 0, 4), n.setHours(0, 0, 0, 0), A(n);
|
|
75
76
|
}
|
|
76
|
-
function
|
|
77
|
+
function we(e, t) {
|
|
77
78
|
const n = t * 7;
|
|
78
79
|
return P(e, n);
|
|
79
80
|
}
|
|
80
|
-
function
|
|
81
|
-
return
|
|
81
|
+
function Wt(e, t) {
|
|
82
|
+
return Y(e, t * 12);
|
|
82
83
|
}
|
|
83
|
-
function
|
|
84
|
+
function Tt(e) {
|
|
84
85
|
let t;
|
|
85
86
|
return e.forEach(function(n) {
|
|
86
|
-
const a =
|
|
87
|
+
const a = M(n);
|
|
87
88
|
(t === void 0 || t < a || isNaN(Number(a))) && (t = a);
|
|
88
89
|
}), t || /* @__PURE__ */ new Date(NaN);
|
|
89
90
|
}
|
|
90
|
-
function
|
|
91
|
+
function Yt(e) {
|
|
91
92
|
let t;
|
|
92
93
|
return e.forEach((n) => {
|
|
93
|
-
const a =
|
|
94
|
+
const a = M(n);
|
|
94
95
|
(!t || t > a || isNaN(+a)) && (t = a);
|
|
95
96
|
}), t || /* @__PURE__ */ new Date(NaN);
|
|
96
97
|
}
|
|
97
|
-
function
|
|
98
|
-
const n =
|
|
98
|
+
function C(e, t) {
|
|
99
|
+
const n = G(e), a = G(t);
|
|
99
100
|
return +n == +a;
|
|
100
101
|
}
|
|
101
|
-
function
|
|
102
|
+
function Me(e) {
|
|
102
103
|
return e instanceof Date || typeof e == "object" && Object.prototype.toString.call(e) === "[object Date]";
|
|
103
104
|
}
|
|
104
|
-
function
|
|
105
|
-
if (!
|
|
105
|
+
function Ft(e) {
|
|
106
|
+
if (!Me(e) && typeof e != "number")
|
|
106
107
|
return !1;
|
|
107
|
-
const t =
|
|
108
|
+
const t = M(e);
|
|
108
109
|
return !isNaN(Number(t));
|
|
109
110
|
}
|
|
110
|
-
function
|
|
111
|
-
const n =
|
|
111
|
+
function z(e, t) {
|
|
112
|
+
const n = M(e), a = M(t), r = n.getFullYear() - a.getFullYear(), o = n.getMonth() - a.getMonth();
|
|
112
113
|
return r * 12 + o;
|
|
113
114
|
}
|
|
114
|
-
function
|
|
115
|
-
const a =
|
|
116
|
-
return Math.round((o - i) /
|
|
115
|
+
function Lt(e, t, n) {
|
|
116
|
+
const a = I(e, n), r = I(t, n), o = +a - re(a), i = +r - re(r);
|
|
117
|
+
return Math.round((o - i) / De);
|
|
117
118
|
}
|
|
118
|
-
function
|
|
119
|
-
const t =
|
|
119
|
+
function _e(e) {
|
|
120
|
+
const t = M(e), n = t.getMonth();
|
|
120
121
|
return t.setFullYear(t.getFullYear(), n + 1, 0), t.setHours(23, 59, 59, 999), t;
|
|
121
122
|
}
|
|
122
|
-
function
|
|
123
|
-
const t =
|
|
123
|
+
function S(e) {
|
|
124
|
+
const t = M(e);
|
|
124
125
|
return t.setDate(1), t.setHours(0, 0, 0, 0), t;
|
|
125
126
|
}
|
|
126
|
-
function
|
|
127
|
-
const t =
|
|
127
|
+
function Ge(e) {
|
|
128
|
+
const t = M(e), n = W(e, 0);
|
|
128
129
|
return n.setFullYear(t.getFullYear(), 0, 1), n.setHours(0, 0, 0, 0), n;
|
|
129
130
|
}
|
|
130
|
-
function
|
|
131
|
-
var s,
|
|
132
|
-
const n =
|
|
131
|
+
function ke(e, t) {
|
|
132
|
+
var s, l, d, u;
|
|
133
|
+
const n = Z(), a = (t == null ? void 0 : t.weekStartsOn) ?? ((l = (s = t == null ? void 0 : t.locale) == null ? void 0 : s.options) == null ? void 0 : l.weekStartsOn) ?? n.weekStartsOn ?? ((u = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : u.weekStartsOn) ?? 0, r = M(e), o = r.getDay(), i = (o < a ? -7 : 0) + 6 - (o - a);
|
|
133
134
|
return r.setDate(r.getDate() + i), r.setHours(23, 59, 59, 999), r;
|
|
134
135
|
}
|
|
135
|
-
function
|
|
136
|
-
return
|
|
136
|
+
function Ve(e) {
|
|
137
|
+
return ke(e, { weekStartsOn: 1 });
|
|
137
138
|
}
|
|
138
|
-
const
|
|
139
|
+
const Et = {
|
|
139
140
|
lessThanXSeconds: {
|
|
140
141
|
one: "less than a second",
|
|
141
142
|
other: "less than {{count}} seconds"
|
|
@@ -197,54 +198,54 @@ const Yt = {
|
|
|
197
198
|
one: "almost 1 year",
|
|
198
199
|
other: "almost {{count}} years"
|
|
199
200
|
}
|
|
200
|
-
},
|
|
201
|
+
}, It = (e, t, n) => {
|
|
201
202
|
let a;
|
|
202
|
-
const r =
|
|
203
|
+
const r = Et[e];
|
|
203
204
|
return typeof r == "string" ? a = r : t === 1 ? a = r.one : a = r.other.replace("{{count}}", t.toString()), n != null && n.addSuffix ? n.comparison && n.comparison > 0 ? "in " + a : a + " ago" : a;
|
|
204
205
|
};
|
|
205
|
-
function
|
|
206
|
+
function fe(e) {
|
|
206
207
|
return (t = {}) => {
|
|
207
208
|
const n = t.width ? String(t.width) : e.defaultWidth;
|
|
208
209
|
return e.formats[n] || e.formats[e.defaultWidth];
|
|
209
210
|
};
|
|
210
211
|
}
|
|
211
|
-
const
|
|
212
|
+
const Rt = {
|
|
212
213
|
full: "EEEE, MMMM do, y",
|
|
213
214
|
long: "MMMM do, y",
|
|
214
215
|
medium: "MMM d, y",
|
|
215
216
|
short: "MM/dd/yyyy"
|
|
216
|
-
},
|
|
217
|
+
}, Bt = {
|
|
217
218
|
full: "h:mm:ss a zzzz",
|
|
218
219
|
long: "h:mm:ss a z",
|
|
219
220
|
medium: "h:mm:ss a",
|
|
220
221
|
short: "h:mm a"
|
|
221
|
-
},
|
|
222
|
+
}, jt = {
|
|
222
223
|
full: "{{date}} 'at' {{time}}",
|
|
223
224
|
long: "{{date}} 'at' {{time}}",
|
|
224
225
|
medium: "{{date}}, {{time}}",
|
|
225
226
|
short: "{{date}}, {{time}}"
|
|
226
|
-
},
|
|
227
|
-
date:
|
|
228
|
-
formats:
|
|
227
|
+
}, Ht = {
|
|
228
|
+
date: fe({
|
|
229
|
+
formats: Rt,
|
|
229
230
|
defaultWidth: "full"
|
|
230
231
|
}),
|
|
231
|
-
time:
|
|
232
|
-
formats:
|
|
232
|
+
time: fe({
|
|
233
|
+
formats: Bt,
|
|
233
234
|
defaultWidth: "full"
|
|
234
235
|
}),
|
|
235
|
-
dateTime:
|
|
236
|
-
formats:
|
|
236
|
+
dateTime: fe({
|
|
237
|
+
formats: jt,
|
|
237
238
|
defaultWidth: "full"
|
|
238
239
|
})
|
|
239
|
-
},
|
|
240
|
+
}, At = {
|
|
240
241
|
lastWeek: "'last' eeee 'at' p",
|
|
241
242
|
yesterday: "'yesterday at' p",
|
|
242
243
|
today: "'today at' p",
|
|
243
244
|
tomorrow: "'tomorrow at' p",
|
|
244
245
|
nextWeek: "eeee 'at' p",
|
|
245
246
|
other: "P"
|
|
246
|
-
},
|
|
247
|
-
function
|
|
247
|
+
}, qt = (e, t, n, a) => At[e];
|
|
248
|
+
function $(e) {
|
|
248
249
|
return (t, n) => {
|
|
249
250
|
const a = n != null && n.context ? String(n.context) : "standalone";
|
|
250
251
|
let r;
|
|
@@ -259,15 +260,15 @@ function G(e) {
|
|
|
259
260
|
return r[o];
|
|
260
261
|
};
|
|
261
262
|
}
|
|
262
|
-
const
|
|
263
|
+
const Qt = {
|
|
263
264
|
narrow: ["B", "A"],
|
|
264
265
|
abbreviated: ["BC", "AD"],
|
|
265
266
|
wide: ["Before Christ", "Anno Domini"]
|
|
266
|
-
},
|
|
267
|
+
}, Xt = {
|
|
267
268
|
narrow: ["1", "2", "3", "4"],
|
|
268
269
|
abbreviated: ["Q1", "Q2", "Q3", "Q4"],
|
|
269
270
|
wide: ["1st quarter", "2nd quarter", "3rd quarter", "4th quarter"]
|
|
270
|
-
},
|
|
271
|
+
}, Gt = {
|
|
271
272
|
narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
|
|
272
273
|
abbreviated: [
|
|
273
274
|
"Jan",
|
|
@@ -297,7 +298,7 @@ const At = {
|
|
|
297
298
|
"November",
|
|
298
299
|
"December"
|
|
299
300
|
]
|
|
300
|
-
},
|
|
301
|
+
}, Vt = {
|
|
301
302
|
narrow: ["S", "M", "T", "W", "T", "F", "S"],
|
|
302
303
|
short: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"],
|
|
303
304
|
abbreviated: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
|
|
@@ -310,7 +311,7 @@ const At = {
|
|
|
310
311
|
"Friday",
|
|
311
312
|
"Saturday"
|
|
312
313
|
]
|
|
313
|
-
},
|
|
314
|
+
}, $t = {
|
|
314
315
|
narrow: {
|
|
315
316
|
am: "a",
|
|
316
317
|
pm: "p",
|
|
@@ -341,7 +342,7 @@ const At = {
|
|
|
341
342
|
evening: "evening",
|
|
342
343
|
night: "night"
|
|
343
344
|
}
|
|
344
|
-
},
|
|
345
|
+
}, Ut = {
|
|
345
346
|
narrow: {
|
|
346
347
|
am: "a",
|
|
347
348
|
pm: "p",
|
|
@@ -372,7 +373,7 @@ const At = {
|
|
|
372
373
|
evening: "in the evening",
|
|
373
374
|
night: "at night"
|
|
374
375
|
}
|
|
375
|
-
},
|
|
376
|
+
}, Jt = (e, t) => {
|
|
376
377
|
const n = Number(e), a = n % 100;
|
|
377
378
|
if (a > 20 || a < 10)
|
|
378
379
|
switch (a % 10) {
|
|
@@ -384,61 +385,61 @@ const At = {
|
|
|
384
385
|
return n + "rd";
|
|
385
386
|
}
|
|
386
387
|
return n + "th";
|
|
387
|
-
},
|
|
388
|
-
ordinalNumber:
|
|
389
|
-
era:
|
|
390
|
-
values:
|
|
388
|
+
}, Kt = {
|
|
389
|
+
ordinalNumber: Jt,
|
|
390
|
+
era: $({
|
|
391
|
+
values: Qt,
|
|
391
392
|
defaultWidth: "wide"
|
|
392
393
|
}),
|
|
393
|
-
quarter:
|
|
394
|
-
values:
|
|
394
|
+
quarter: $({
|
|
395
|
+
values: Xt,
|
|
395
396
|
defaultWidth: "wide",
|
|
396
397
|
argumentCallback: (e) => e - 1
|
|
397
398
|
}),
|
|
398
|
-
month:
|
|
399
|
-
values:
|
|
399
|
+
month: $({
|
|
400
|
+
values: Gt,
|
|
400
401
|
defaultWidth: "wide"
|
|
401
402
|
}),
|
|
402
|
-
day:
|
|
403
|
-
values:
|
|
403
|
+
day: $({
|
|
404
|
+
values: Vt,
|
|
404
405
|
defaultWidth: "wide"
|
|
405
406
|
}),
|
|
406
|
-
dayPeriod:
|
|
407
|
-
values:
|
|
407
|
+
dayPeriod: $({
|
|
408
|
+
values: $t,
|
|
408
409
|
defaultWidth: "wide",
|
|
409
|
-
formattingValues:
|
|
410
|
+
formattingValues: Ut,
|
|
410
411
|
defaultFormattingWidth: "wide"
|
|
411
412
|
})
|
|
412
413
|
};
|
|
413
|
-
function
|
|
414
|
+
function U(e) {
|
|
414
415
|
return (t, n = {}) => {
|
|
415
416
|
const a = n.width, r = a && e.matchPatterns[a] || e.matchPatterns[e.defaultMatchWidth], o = t.match(r);
|
|
416
417
|
if (!o)
|
|
417
418
|
return null;
|
|
418
|
-
const i = o[0], s = a && e.parsePatterns[a] || e.parsePatterns[e.defaultParseWidth],
|
|
419
|
+
const i = o[0], s = a && e.parsePatterns[a] || e.parsePatterns[e.defaultParseWidth], l = Array.isArray(s) ? Zt(s, (f) => f.test(i)) : (
|
|
419
420
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- I challange you to fix the type
|
|
420
|
-
|
|
421
|
+
zt(s, (f) => f.test(i))
|
|
421
422
|
);
|
|
422
423
|
let d;
|
|
423
|
-
d = e.valueCallback ? e.valueCallback(
|
|
424
|
+
d = e.valueCallback ? e.valueCallback(l) : l, d = n.valueCallback ? (
|
|
424
425
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any -- I challange you to fix the type
|
|
425
426
|
n.valueCallback(d)
|
|
426
427
|
) : d;
|
|
427
|
-
const
|
|
428
|
-
return { value: d, rest:
|
|
428
|
+
const u = t.slice(i.length);
|
|
429
|
+
return { value: d, rest: u };
|
|
429
430
|
};
|
|
430
431
|
}
|
|
431
|
-
function
|
|
432
|
+
function zt(e, t) {
|
|
432
433
|
for (const n in e)
|
|
433
434
|
if (Object.prototype.hasOwnProperty.call(e, n) && t(e[n]))
|
|
434
435
|
return n;
|
|
435
436
|
}
|
|
436
|
-
function
|
|
437
|
+
function Zt(e, t) {
|
|
437
438
|
for (let n = 0; n < e.length; n++)
|
|
438
439
|
if (t(e[n]))
|
|
439
440
|
return n;
|
|
440
441
|
}
|
|
441
|
-
function
|
|
442
|
+
function en(e) {
|
|
442
443
|
return (t, n = {}) => {
|
|
443
444
|
const a = t.match(e.matchPattern);
|
|
444
445
|
if (!a)
|
|
@@ -452,23 +453,23 @@ function zt(e) {
|
|
|
452
453
|
return { value: i, rest: s };
|
|
453
454
|
};
|
|
454
455
|
}
|
|
455
|
-
const
|
|
456
|
+
const tn = /^(\d+)(th|st|nd|rd)?/i, nn = /\d+/i, an = {
|
|
456
457
|
narrow: /^(b|a)/i,
|
|
457
458
|
abbreviated: /^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,
|
|
458
459
|
wide: /^(before christ|before common era|anno domini|common era)/i
|
|
459
|
-
},
|
|
460
|
+
}, rn = {
|
|
460
461
|
any: [/^b/i, /^(a|c)/i]
|
|
461
|
-
},
|
|
462
|
+
}, on = {
|
|
462
463
|
narrow: /^[1234]/i,
|
|
463
464
|
abbreviated: /^q[1234]/i,
|
|
464
465
|
wide: /^[1234](th|st|nd|rd)? quarter/i
|
|
465
|
-
},
|
|
466
|
+
}, sn = {
|
|
466
467
|
any: [/1/i, /2/i, /3/i, /4/i]
|
|
467
|
-
},
|
|
468
|
+
}, ln = {
|
|
468
469
|
narrow: /^[jfmasond]/i,
|
|
469
470
|
abbreviated: /^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,
|
|
470
471
|
wide: /^(january|february|march|april|may|june|july|august|september|october|november|december)/i
|
|
471
|
-
},
|
|
472
|
+
}, un = {
|
|
472
473
|
narrow: [
|
|
473
474
|
/^j/i,
|
|
474
475
|
/^f/i,
|
|
@@ -497,18 +498,18 @@ const Zt = /^(\d+)(th|st|nd|rd)?/i, en = /\d+/i, tn = {
|
|
|
497
498
|
/^n/i,
|
|
498
499
|
/^d/i
|
|
499
500
|
]
|
|
500
|
-
},
|
|
501
|
+
}, cn = {
|
|
501
502
|
narrow: /^[smtwf]/i,
|
|
502
503
|
short: /^(su|mo|tu|we|th|fr|sa)/i,
|
|
503
504
|
abbreviated: /^(sun|mon|tue|wed|thu|fri|sat)/i,
|
|
504
505
|
wide: /^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i
|
|
505
|
-
},
|
|
506
|
+
}, dn = {
|
|
506
507
|
narrow: [/^s/i, /^m/i, /^t/i, /^w/i, /^t/i, /^f/i, /^s/i],
|
|
507
508
|
any: [/^su/i, /^m/i, /^tu/i, /^w/i, /^th/i, /^f/i, /^sa/i]
|
|
508
|
-
},
|
|
509
|
+
}, fn = {
|
|
509
510
|
narrow: /^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,
|
|
510
511
|
any: /^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i
|
|
511
|
-
},
|
|
512
|
+
}, hn = {
|
|
512
513
|
any: {
|
|
513
514
|
am: /^a/i,
|
|
514
515
|
pm: /^p/i,
|
|
@@ -519,99 +520,99 @@ const Zt = /^(\d+)(th|st|nd|rd)?/i, en = /\d+/i, tn = {
|
|
|
519
520
|
evening: /evening/i,
|
|
520
521
|
night: /night/i
|
|
521
522
|
}
|
|
522
|
-
},
|
|
523
|
-
ordinalNumber:
|
|
524
|
-
matchPattern:
|
|
525
|
-
parsePattern:
|
|
523
|
+
}, mn = {
|
|
524
|
+
ordinalNumber: en({
|
|
525
|
+
matchPattern: tn,
|
|
526
|
+
parsePattern: nn,
|
|
526
527
|
valueCallback: (e) => parseInt(e, 10)
|
|
527
528
|
}),
|
|
528
|
-
era:
|
|
529
|
-
matchPatterns: tn,
|
|
530
|
-
defaultMatchWidth: "wide",
|
|
531
|
-
parsePatterns: nn,
|
|
532
|
-
defaultParseWidth: "any"
|
|
533
|
-
}),
|
|
534
|
-
quarter: V({
|
|
529
|
+
era: U({
|
|
535
530
|
matchPatterns: an,
|
|
536
531
|
defaultMatchWidth: "wide",
|
|
537
532
|
parsePatterns: rn,
|
|
538
|
-
defaultParseWidth: "any"
|
|
539
|
-
valueCallback: (e) => e + 1
|
|
533
|
+
defaultParseWidth: "any"
|
|
540
534
|
}),
|
|
541
|
-
|
|
535
|
+
quarter: U({
|
|
542
536
|
matchPatterns: on,
|
|
543
537
|
defaultMatchWidth: "wide",
|
|
544
538
|
parsePatterns: sn,
|
|
545
|
-
defaultParseWidth: "any"
|
|
539
|
+
defaultParseWidth: "any",
|
|
540
|
+
valueCallback: (e) => e + 1
|
|
546
541
|
}),
|
|
547
|
-
|
|
542
|
+
month: U({
|
|
548
543
|
matchPatterns: ln,
|
|
549
544
|
defaultMatchWidth: "wide",
|
|
550
545
|
parsePatterns: un,
|
|
551
546
|
defaultParseWidth: "any"
|
|
552
547
|
}),
|
|
553
|
-
|
|
548
|
+
day: U({
|
|
554
549
|
matchPatterns: cn,
|
|
555
|
-
defaultMatchWidth: "
|
|
550
|
+
defaultMatchWidth: "wide",
|
|
556
551
|
parsePatterns: dn,
|
|
557
552
|
defaultParseWidth: "any"
|
|
553
|
+
}),
|
|
554
|
+
dayPeriod: U({
|
|
555
|
+
matchPatterns: fn,
|
|
556
|
+
defaultMatchWidth: "any",
|
|
557
|
+
parsePatterns: hn,
|
|
558
|
+
defaultParseWidth: "any"
|
|
558
559
|
})
|
|
559
|
-
},
|
|
560
|
+
}, $e = {
|
|
560
561
|
code: "en-US",
|
|
561
|
-
formatDistance:
|
|
562
|
-
formatLong:
|
|
563
|
-
formatRelative:
|
|
564
|
-
localize:
|
|
565
|
-
match:
|
|
562
|
+
formatDistance: It,
|
|
563
|
+
formatLong: Ht,
|
|
564
|
+
formatRelative: qt,
|
|
565
|
+
localize: Kt,
|
|
566
|
+
match: mn,
|
|
566
567
|
options: {
|
|
567
568
|
weekStartsOn: 0,
|
|
568
569
|
firstWeekContainsDate: 1
|
|
569
570
|
}
|
|
570
571
|
};
|
|
571
|
-
function
|
|
572
|
-
const t =
|
|
573
|
-
return
|
|
572
|
+
function vn(e) {
|
|
573
|
+
const t = M(e);
|
|
574
|
+
return L(t, Ge(t)) + 1;
|
|
574
575
|
}
|
|
575
|
-
function
|
|
576
|
-
const t =
|
|
577
|
-
return Math.round(n /
|
|
576
|
+
function Ue(e) {
|
|
577
|
+
const t = M(e), n = +A(t) - +St(t);
|
|
578
|
+
return Math.round(n / De) + 1;
|
|
578
579
|
}
|
|
579
|
-
function
|
|
580
|
-
var
|
|
581
|
-
const n =
|
|
580
|
+
function Je(e, t) {
|
|
581
|
+
var u, f, h, m;
|
|
582
|
+
const n = M(e), a = n.getFullYear(), r = Z(), o = (t == null ? void 0 : t.firstWeekContainsDate) ?? ((f = (u = t == null ? void 0 : t.locale) == null ? void 0 : u.options) == null ? void 0 : f.firstWeekContainsDate) ?? r.firstWeekContainsDate ?? ((m = (h = r.locale) == null ? void 0 : h.options) == null ? void 0 : m.firstWeekContainsDate) ?? 1, i = W(e, 0);
|
|
582
583
|
i.setFullYear(a + 1, 0, o), i.setHours(0, 0, 0, 0);
|
|
583
|
-
const s =
|
|
584
|
-
|
|
585
|
-
const d =
|
|
584
|
+
const s = I(i, t), l = W(e, 0);
|
|
585
|
+
l.setFullYear(a, 0, o), l.setHours(0, 0, 0, 0);
|
|
586
|
+
const d = I(l, t);
|
|
586
587
|
return n.getTime() >= s.getTime() ? a + 1 : n.getTime() >= d.getTime() ? a : a - 1;
|
|
587
588
|
}
|
|
588
|
-
function
|
|
589
|
-
var s,
|
|
590
|
-
const n =
|
|
591
|
-
return o.setFullYear(r, 0, a), o.setHours(0, 0, 0, 0),
|
|
589
|
+
function yn(e, t) {
|
|
590
|
+
var s, l, d, u;
|
|
591
|
+
const n = Z(), a = (t == null ? void 0 : t.firstWeekContainsDate) ?? ((l = (s = t == null ? void 0 : t.locale) == null ? void 0 : s.options) == null ? void 0 : l.firstWeekContainsDate) ?? n.firstWeekContainsDate ?? ((u = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : u.firstWeekContainsDate) ?? 1, r = Je(e, t), o = W(e, 0);
|
|
592
|
+
return o.setFullYear(r, 0, a), o.setHours(0, 0, 0, 0), I(o, t);
|
|
592
593
|
}
|
|
593
|
-
function
|
|
594
|
-
const n =
|
|
595
|
-
return Math.round(a /
|
|
594
|
+
function Ke(e, t) {
|
|
595
|
+
const n = M(e), a = +I(n, t) - +yn(n, t);
|
|
596
|
+
return Math.round(a / De) + 1;
|
|
596
597
|
}
|
|
597
|
-
function
|
|
598
|
+
function _(e, t) {
|
|
598
599
|
const n = e < 0 ? "-" : "", a = Math.abs(e).toString().padStart(t, "0");
|
|
599
600
|
return n + a;
|
|
600
601
|
}
|
|
601
|
-
const
|
|
602
|
+
const B = {
|
|
602
603
|
// Year
|
|
603
604
|
y(e, t) {
|
|
604
605
|
const n = e.getFullYear(), a = n > 0 ? n : 1 - n;
|
|
605
|
-
return
|
|
606
|
+
return _(t === "yy" ? a % 100 : a, t.length);
|
|
606
607
|
},
|
|
607
608
|
// Month
|
|
608
609
|
M(e, t) {
|
|
609
610
|
const n = e.getMonth();
|
|
610
|
-
return t === "M" ? String(n + 1) :
|
|
611
|
+
return t === "M" ? String(n + 1) : _(n + 1, 2);
|
|
611
612
|
},
|
|
612
613
|
// Day of the month
|
|
613
614
|
d(e, t) {
|
|
614
|
-
return
|
|
615
|
+
return _(e.getDate(), t.length);
|
|
615
616
|
},
|
|
616
617
|
// AM or PM
|
|
617
618
|
a(e, t) {
|
|
@@ -631,28 +632,28 @@ const E = {
|
|
|
631
632
|
},
|
|
632
633
|
// Hour [1-12]
|
|
633
634
|
h(e, t) {
|
|
634
|
-
return
|
|
635
|
+
return _(e.getHours() % 12 || 12, t.length);
|
|
635
636
|
},
|
|
636
637
|
// Hour [0-23]
|
|
637
638
|
H(e, t) {
|
|
638
|
-
return
|
|
639
|
+
return _(e.getHours(), t.length);
|
|
639
640
|
},
|
|
640
641
|
// Minute
|
|
641
642
|
m(e, t) {
|
|
642
|
-
return
|
|
643
|
+
return _(e.getMinutes(), t.length);
|
|
643
644
|
},
|
|
644
645
|
// Second
|
|
645
646
|
s(e, t) {
|
|
646
|
-
return
|
|
647
|
+
return _(e.getSeconds(), t.length);
|
|
647
648
|
},
|
|
648
649
|
// Fraction of second
|
|
649
650
|
S(e, t) {
|
|
650
651
|
const n = t.length, a = e.getMilliseconds(), r = Math.trunc(
|
|
651
652
|
a * Math.pow(10, n - 3)
|
|
652
653
|
);
|
|
653
|
-
return
|
|
654
|
+
return _(r, t.length);
|
|
654
655
|
}
|
|
655
|
-
},
|
|
656
|
+
}, X = {
|
|
656
657
|
am: "am",
|
|
657
658
|
pm: "pm",
|
|
658
659
|
midnight: "midnight",
|
|
@@ -661,7 +662,7 @@ const E = {
|
|
|
661
662
|
afternoon: "afternoon",
|
|
662
663
|
evening: "evening",
|
|
663
664
|
night: "night"
|
|
664
|
-
},
|
|
665
|
+
}, Ee = {
|
|
665
666
|
// Era
|
|
666
667
|
G: function(e, t, n) {
|
|
667
668
|
const a = e.getFullYear() > 0 ? 1 : 0;
|
|
@@ -683,21 +684,21 @@ const E = {
|
|
|
683
684
|
const a = e.getFullYear(), r = a > 0 ? a : 1 - a;
|
|
684
685
|
return n.ordinalNumber(r, { unit: "year" });
|
|
685
686
|
}
|
|
686
|
-
return
|
|
687
|
+
return B.y(e, t);
|
|
687
688
|
},
|
|
688
689
|
// Local week-numbering year
|
|
689
690
|
Y: function(e, t, n, a) {
|
|
690
|
-
const r =
|
|
691
|
+
const r = Je(e, a), o = r > 0 ? r : 1 - r;
|
|
691
692
|
if (t === "YY") {
|
|
692
693
|
const i = o % 100;
|
|
693
|
-
return
|
|
694
|
+
return _(i, 2);
|
|
694
695
|
}
|
|
695
|
-
return t === "Yo" ? n.ordinalNumber(o, { unit: "year" }) :
|
|
696
|
+
return t === "Yo" ? n.ordinalNumber(o, { unit: "year" }) : _(o, t.length);
|
|
696
697
|
},
|
|
697
698
|
// ISO week-numbering year
|
|
698
699
|
R: function(e, t) {
|
|
699
|
-
const n =
|
|
700
|
-
return
|
|
700
|
+
const n = Xe(e);
|
|
701
|
+
return _(n, t.length);
|
|
701
702
|
},
|
|
702
703
|
// Extended year. This is a single number designating the year of this calendar system.
|
|
703
704
|
// The main difference between `y` and `u` localizers are B.C. years:
|
|
@@ -710,7 +711,7 @@ const E = {
|
|
|
710
711
|
// while `uu` pads single digit years to 2 characters and returns other years unchanged.
|
|
711
712
|
u: function(e, t) {
|
|
712
713
|
const n = e.getFullYear();
|
|
713
|
-
return
|
|
714
|
+
return _(n, t.length);
|
|
714
715
|
},
|
|
715
716
|
// Quarter
|
|
716
717
|
Q: function(e, t, n) {
|
|
@@ -719,7 +720,7 @@ const E = {
|
|
|
719
720
|
case "Q":
|
|
720
721
|
return String(a);
|
|
721
722
|
case "QQ":
|
|
722
|
-
return
|
|
723
|
+
return _(a, 2);
|
|
723
724
|
case "Qo":
|
|
724
725
|
return n.ordinalNumber(a, { unit: "quarter" });
|
|
725
726
|
case "QQQ":
|
|
@@ -747,7 +748,7 @@ const E = {
|
|
|
747
748
|
case "q":
|
|
748
749
|
return String(a);
|
|
749
750
|
case "qq":
|
|
750
|
-
return
|
|
751
|
+
return _(a, 2);
|
|
751
752
|
case "qo":
|
|
752
753
|
return n.ordinalNumber(a, { unit: "quarter" });
|
|
753
754
|
case "qqq":
|
|
@@ -774,7 +775,7 @@ const E = {
|
|
|
774
775
|
switch (t) {
|
|
775
776
|
case "M":
|
|
776
777
|
case "MM":
|
|
777
|
-
return
|
|
778
|
+
return B.M(e, t);
|
|
778
779
|
case "Mo":
|
|
779
780
|
return n.ordinalNumber(a + 1, { unit: "month" });
|
|
780
781
|
case "MMM":
|
|
@@ -799,7 +800,7 @@ const E = {
|
|
|
799
800
|
case "L":
|
|
800
801
|
return String(a + 1);
|
|
801
802
|
case "LL":
|
|
802
|
-
return
|
|
803
|
+
return _(a + 1, 2);
|
|
803
804
|
case "Lo":
|
|
804
805
|
return n.ordinalNumber(a + 1, { unit: "month" });
|
|
805
806
|
case "LLL":
|
|
@@ -819,22 +820,22 @@ const E = {
|
|
|
819
820
|
},
|
|
820
821
|
// Local week of year
|
|
821
822
|
w: function(e, t, n, a) {
|
|
822
|
-
const r =
|
|
823
|
-
return t === "wo" ? n.ordinalNumber(r, { unit: "week" }) :
|
|
823
|
+
const r = Ke(e, a);
|
|
824
|
+
return t === "wo" ? n.ordinalNumber(r, { unit: "week" }) : _(r, t.length);
|
|
824
825
|
},
|
|
825
826
|
// ISO week of year
|
|
826
827
|
I: function(e, t, n) {
|
|
827
|
-
const a =
|
|
828
|
-
return t === "Io" ? n.ordinalNumber(a, { unit: "week" }) :
|
|
828
|
+
const a = Ue(e);
|
|
829
|
+
return t === "Io" ? n.ordinalNumber(a, { unit: "week" }) : _(a, t.length);
|
|
829
830
|
},
|
|
830
831
|
// Day of the month
|
|
831
832
|
d: function(e, t, n) {
|
|
832
|
-
return t === "do" ? n.ordinalNumber(e.getDate(), { unit: "date" }) :
|
|
833
|
+
return t === "do" ? n.ordinalNumber(e.getDate(), { unit: "date" }) : B.d(e, t);
|
|
833
834
|
},
|
|
834
835
|
// Day of year
|
|
835
836
|
D: function(e, t, n) {
|
|
836
|
-
const a =
|
|
837
|
-
return t === "Do" ? n.ordinalNumber(a, { unit: "dayOfYear" }) :
|
|
837
|
+
const a = vn(e);
|
|
838
|
+
return t === "Do" ? n.ordinalNumber(a, { unit: "dayOfYear" }) : _(a, t.length);
|
|
838
839
|
},
|
|
839
840
|
// Day of week
|
|
840
841
|
E: function(e, t, n) {
|
|
@@ -872,7 +873,7 @@ const E = {
|
|
|
872
873
|
case "e":
|
|
873
874
|
return String(o);
|
|
874
875
|
case "ee":
|
|
875
|
-
return
|
|
876
|
+
return _(o, 2);
|
|
876
877
|
case "eo":
|
|
877
878
|
return n.ordinalNumber(o, { unit: "day" });
|
|
878
879
|
case "eee":
|
|
@@ -905,7 +906,7 @@ const E = {
|
|
|
905
906
|
case "c":
|
|
906
907
|
return String(o);
|
|
907
908
|
case "cc":
|
|
908
|
-
return
|
|
909
|
+
return _(o, t.length);
|
|
909
910
|
case "co":
|
|
910
911
|
return n.ordinalNumber(o, { unit: "day" });
|
|
911
912
|
case "ccc":
|
|
@@ -938,7 +939,7 @@ const E = {
|
|
|
938
939
|
case "i":
|
|
939
940
|
return String(r);
|
|
940
941
|
case "ii":
|
|
941
|
-
return
|
|
942
|
+
return _(r, t.length);
|
|
942
943
|
case "io":
|
|
943
944
|
return n.ordinalNumber(r, { unit: "day" });
|
|
944
945
|
case "iii":
|
|
@@ -996,7 +997,7 @@ const E = {
|
|
|
996
997
|
b: function(e, t, n) {
|
|
997
998
|
const a = e.getHours();
|
|
998
999
|
let r;
|
|
999
|
-
switch (a === 12 ? r =
|
|
1000
|
+
switch (a === 12 ? r = X.noon : a === 0 ? r = X.midnight : r = a / 12 >= 1 ? "pm" : "am", t) {
|
|
1000
1001
|
case "b":
|
|
1001
1002
|
case "bb":
|
|
1002
1003
|
return n.dayPeriod(r, {
|
|
@@ -1025,7 +1026,7 @@ const E = {
|
|
|
1025
1026
|
B: function(e, t, n) {
|
|
1026
1027
|
const a = e.getHours();
|
|
1027
1028
|
let r;
|
|
1028
|
-
switch (a >= 17 ? r =
|
|
1029
|
+
switch (a >= 17 ? r = X.evening : a >= 12 ? r = X.afternoon : a >= 4 ? r = X.morning : r = X.night, t) {
|
|
1029
1030
|
case "B":
|
|
1030
1031
|
case "BB":
|
|
1031
1032
|
case "BBB":
|
|
@@ -1052,33 +1053,33 @@ const E = {
|
|
|
1052
1053
|
let a = e.getHours() % 12;
|
|
1053
1054
|
return a === 0 && (a = 12), n.ordinalNumber(a, { unit: "hour" });
|
|
1054
1055
|
}
|
|
1055
|
-
return
|
|
1056
|
+
return B.h(e, t);
|
|
1056
1057
|
},
|
|
1057
1058
|
// Hour [0-23]
|
|
1058
1059
|
H: function(e, t, n) {
|
|
1059
|
-
return t === "Ho" ? n.ordinalNumber(e.getHours(), { unit: "hour" }) :
|
|
1060
|
+
return t === "Ho" ? n.ordinalNumber(e.getHours(), { unit: "hour" }) : B.H(e, t);
|
|
1060
1061
|
},
|
|
1061
1062
|
// Hour [0-11]
|
|
1062
1063
|
K: function(e, t, n) {
|
|
1063
1064
|
const a = e.getHours() % 12;
|
|
1064
|
-
return t === "Ko" ? n.ordinalNumber(a, { unit: "hour" }) :
|
|
1065
|
+
return t === "Ko" ? n.ordinalNumber(a, { unit: "hour" }) : _(a, t.length);
|
|
1065
1066
|
},
|
|
1066
1067
|
// Hour [1-24]
|
|
1067
1068
|
k: function(e, t, n) {
|
|
1068
1069
|
let a = e.getHours();
|
|
1069
|
-
return a === 0 && (a = 24), t === "ko" ? n.ordinalNumber(a, { unit: "hour" }) :
|
|
1070
|
+
return a === 0 && (a = 24), t === "ko" ? n.ordinalNumber(a, { unit: "hour" }) : _(a, t.length);
|
|
1070
1071
|
},
|
|
1071
1072
|
// Minute
|
|
1072
1073
|
m: function(e, t, n) {
|
|
1073
|
-
return t === "mo" ? n.ordinalNumber(e.getMinutes(), { unit: "minute" }) :
|
|
1074
|
+
return t === "mo" ? n.ordinalNumber(e.getMinutes(), { unit: "minute" }) : B.m(e, t);
|
|
1074
1075
|
},
|
|
1075
1076
|
// Second
|
|
1076
1077
|
s: function(e, t, n) {
|
|
1077
|
-
return t === "so" ? n.ordinalNumber(e.getSeconds(), { unit: "second" }) :
|
|
1078
|
+
return t === "so" ? n.ordinalNumber(e.getSeconds(), { unit: "second" }) : B.s(e, t);
|
|
1078
1079
|
},
|
|
1079
1080
|
// Fraction of second
|
|
1080
1081
|
S: function(e, t) {
|
|
1081
|
-
return
|
|
1082
|
+
return B.S(e, t);
|
|
1082
1083
|
},
|
|
1083
1084
|
// Timezone (ISO-8601. If offset is 0, output is always `'Z'`)
|
|
1084
1085
|
X: function(e, t, n) {
|
|
@@ -1087,14 +1088,14 @@ const E = {
|
|
|
1087
1088
|
return "Z";
|
|
1088
1089
|
switch (t) {
|
|
1089
1090
|
case "X":
|
|
1090
|
-
return
|
|
1091
|
+
return Re(a);
|
|
1091
1092
|
case "XXXX":
|
|
1092
1093
|
case "XX":
|
|
1093
|
-
return
|
|
1094
|
+
return H(a);
|
|
1094
1095
|
case "XXXXX":
|
|
1095
1096
|
case "XXX":
|
|
1096
1097
|
default:
|
|
1097
|
-
return
|
|
1098
|
+
return H(a, ":");
|
|
1098
1099
|
}
|
|
1099
1100
|
},
|
|
1100
1101
|
// Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)
|
|
@@ -1102,14 +1103,14 @@ const E = {
|
|
|
1102
1103
|
const a = e.getTimezoneOffset();
|
|
1103
1104
|
switch (t) {
|
|
1104
1105
|
case "x":
|
|
1105
|
-
return
|
|
1106
|
+
return Re(a);
|
|
1106
1107
|
case "xxxx":
|
|
1107
1108
|
case "xx":
|
|
1108
|
-
return
|
|
1109
|
+
return H(a);
|
|
1109
1110
|
case "xxxxx":
|
|
1110
1111
|
case "xxx":
|
|
1111
1112
|
default:
|
|
1112
|
-
return
|
|
1113
|
+
return H(a, ":");
|
|
1113
1114
|
}
|
|
1114
1115
|
},
|
|
1115
1116
|
// Timezone (GMT)
|
|
@@ -1119,10 +1120,10 @@ const E = {
|
|
|
1119
1120
|
case "O":
|
|
1120
1121
|
case "OO":
|
|
1121
1122
|
case "OOO":
|
|
1122
|
-
return "GMT" +
|
|
1123
|
+
return "GMT" + Ie(a, ":");
|
|
1123
1124
|
case "OOOO":
|
|
1124
1125
|
default:
|
|
1125
|
-
return "GMT" +
|
|
1126
|
+
return "GMT" + H(a, ":");
|
|
1126
1127
|
}
|
|
1127
1128
|
},
|
|
1128
1129
|
// Timezone (specific non-location)
|
|
@@ -1132,35 +1133,35 @@ const E = {
|
|
|
1132
1133
|
case "z":
|
|
1133
1134
|
case "zz":
|
|
1134
1135
|
case "zzz":
|
|
1135
|
-
return "GMT" +
|
|
1136
|
+
return "GMT" + Ie(a, ":");
|
|
1136
1137
|
case "zzzz":
|
|
1137
1138
|
default:
|
|
1138
|
-
return "GMT" +
|
|
1139
|
+
return "GMT" + H(a, ":");
|
|
1139
1140
|
}
|
|
1140
1141
|
},
|
|
1141
1142
|
// Seconds timestamp
|
|
1142
1143
|
t: function(e, t, n) {
|
|
1143
1144
|
const a = Math.trunc(e.getTime() / 1e3);
|
|
1144
|
-
return
|
|
1145
|
+
return _(a, t.length);
|
|
1145
1146
|
},
|
|
1146
1147
|
// Milliseconds timestamp
|
|
1147
1148
|
T: function(e, t, n) {
|
|
1148
1149
|
const a = e.getTime();
|
|
1149
|
-
return
|
|
1150
|
+
return _(a, t.length);
|
|
1150
1151
|
}
|
|
1151
1152
|
};
|
|
1152
|
-
function
|
|
1153
|
+
function Ie(e, t = "") {
|
|
1153
1154
|
const n = e > 0 ? "-" : "+", a = Math.abs(e), r = Math.trunc(a / 60), o = a % 60;
|
|
1154
|
-
return o === 0 ? n + String(r) : n + String(r) + t +
|
|
1155
|
+
return o === 0 ? n + String(r) : n + String(r) + t + _(o, 2);
|
|
1155
1156
|
}
|
|
1156
|
-
function
|
|
1157
|
-
return e % 60 === 0 ? (e > 0 ? "-" : "+") +
|
|
1157
|
+
function Re(e, t) {
|
|
1158
|
+
return e % 60 === 0 ? (e > 0 ? "-" : "+") + _(Math.abs(e) / 60, 2) : H(e, t);
|
|
1158
1159
|
}
|
|
1159
|
-
function
|
|
1160
|
-
const n = e > 0 ? "-" : "+", a = Math.abs(e), r =
|
|
1160
|
+
function H(e, t = "") {
|
|
1161
|
+
const n = e > 0 ? "-" : "+", a = Math.abs(e), r = _(Math.trunc(a / 60), 2), o = _(a % 60, 2);
|
|
1161
1162
|
return n + r + t + o;
|
|
1162
1163
|
}
|
|
1163
|
-
const
|
|
1164
|
+
const Be = (e, t) => {
|
|
1164
1165
|
switch (e) {
|
|
1165
1166
|
case "P":
|
|
1166
1167
|
return t.date({ width: "short" });
|
|
@@ -1172,7 +1173,7 @@ const Ee = (e, t) => {
|
|
|
1172
1173
|
default:
|
|
1173
1174
|
return t.date({ width: "full" });
|
|
1174
1175
|
}
|
|
1175
|
-
},
|
|
1176
|
+
}, ze = (e, t) => {
|
|
1176
1177
|
switch (e) {
|
|
1177
1178
|
case "p":
|
|
1178
1179
|
return t.time({ width: "short" });
|
|
@@ -1184,10 +1185,10 @@ const Ee = (e, t) => {
|
|
|
1184
1185
|
default:
|
|
1185
1186
|
return t.time({ width: "full" });
|
|
1186
1187
|
}
|
|
1187
|
-
},
|
|
1188
|
+
}, bn = (e, t) => {
|
|
1188
1189
|
const n = e.match(/(P+)(p+)?/) || [], a = n[1], r = n[2];
|
|
1189
1190
|
if (!r)
|
|
1190
|
-
return
|
|
1191
|
+
return Be(e, t);
|
|
1191
1192
|
let o;
|
|
1192
1193
|
switch (a) {
|
|
1193
1194
|
case "P":
|
|
@@ -1204,130 +1205,130 @@ const Ee = (e, t) => {
|
|
|
1204
1205
|
o = t.dateTime({ width: "full" });
|
|
1205
1206
|
break;
|
|
1206
1207
|
}
|
|
1207
|
-
return o.replace("{{date}}",
|
|
1208
|
-
},
|
|
1209
|
-
p:
|
|
1210
|
-
P:
|
|
1211
|
-
},
|
|
1212
|
-
function
|
|
1213
|
-
return
|
|
1214
|
-
}
|
|
1215
|
-
function
|
|
1216
|
-
return
|
|
1217
|
-
}
|
|
1218
|
-
function
|
|
1219
|
-
const a =
|
|
1220
|
-
if (console.warn(a),
|
|
1208
|
+
return o.replace("{{date}}", Be(a, t)).replace("{{time}}", ze(r, t));
|
|
1209
|
+
}, gn = {
|
|
1210
|
+
p: ze,
|
|
1211
|
+
P: bn
|
|
1212
|
+
}, wn = /^D+$/, pn = /^Y+$/, Dn = ["D", "DD", "YY", "YYYY"];
|
|
1213
|
+
function Mn(e) {
|
|
1214
|
+
return wn.test(e);
|
|
1215
|
+
}
|
|
1216
|
+
function _n(e) {
|
|
1217
|
+
return pn.test(e);
|
|
1218
|
+
}
|
|
1219
|
+
function kn(e, t, n) {
|
|
1220
|
+
const a = Nn(e, t, n);
|
|
1221
|
+
if (console.warn(a), Dn.includes(e))
|
|
1221
1222
|
throw new RangeError(a);
|
|
1222
1223
|
}
|
|
1223
|
-
function
|
|
1224
|
+
function Nn(e, t, n) {
|
|
1224
1225
|
const a = e[0] === "Y" ? "years" : "days of the month";
|
|
1225
1226
|
return `Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${a} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`;
|
|
1226
1227
|
}
|
|
1227
|
-
const
|
|
1228
|
-
function
|
|
1229
|
-
var
|
|
1230
|
-
const a =
|
|
1231
|
-
if (!
|
|
1228
|
+
const xn = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, Pn = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, On = /^'([^]*?)'?$/, Cn = /''/g, Sn = /[a-zA-Z]/;
|
|
1229
|
+
function E(e, t, n) {
|
|
1230
|
+
var u, f, h, m, y, D, w, N;
|
|
1231
|
+
const a = Z(), r = (n == null ? void 0 : n.locale) ?? a.locale ?? $e, o = (n == null ? void 0 : n.firstWeekContainsDate) ?? ((f = (u = n == null ? void 0 : n.locale) == null ? void 0 : u.options) == null ? void 0 : f.firstWeekContainsDate) ?? a.firstWeekContainsDate ?? ((m = (h = a.locale) == null ? void 0 : h.options) == null ? void 0 : m.firstWeekContainsDate) ?? 1, i = (n == null ? void 0 : n.weekStartsOn) ?? ((D = (y = n == null ? void 0 : n.locale) == null ? void 0 : y.options) == null ? void 0 : D.weekStartsOn) ?? a.weekStartsOn ?? ((N = (w = a.locale) == null ? void 0 : w.options) == null ? void 0 : N.weekStartsOn) ?? 0, s = M(e);
|
|
1232
|
+
if (!Ft(s))
|
|
1232
1233
|
throw new RangeError("Invalid time value");
|
|
1233
|
-
let
|
|
1234
|
-
const
|
|
1235
|
-
if (
|
|
1236
|
-
const
|
|
1237
|
-
return
|
|
1234
|
+
let l = t.match(Pn).map((p) => {
|
|
1235
|
+
const x = p[0];
|
|
1236
|
+
if (x === "p" || x === "P") {
|
|
1237
|
+
const j = gn[x];
|
|
1238
|
+
return j(p, r.formatLong);
|
|
1238
1239
|
}
|
|
1239
1240
|
return p;
|
|
1240
|
-
}).join("").match(
|
|
1241
|
+
}).join("").match(xn).map((p) => {
|
|
1241
1242
|
if (p === "''")
|
|
1242
1243
|
return { isToken: !1, value: "'" };
|
|
1243
|
-
const
|
|
1244
|
-
if (
|
|
1245
|
-
return { isToken: !1, value:
|
|
1246
|
-
if (
|
|
1244
|
+
const x = p[0];
|
|
1245
|
+
if (x === "'")
|
|
1246
|
+
return { isToken: !1, value: Wn(p) };
|
|
1247
|
+
if (Ee[x])
|
|
1247
1248
|
return { isToken: !0, value: p };
|
|
1248
|
-
if (
|
|
1249
|
+
if (x.match(Sn))
|
|
1249
1250
|
throw new RangeError(
|
|
1250
|
-
"Format string contains an unescaped latin alphabet character `" +
|
|
1251
|
+
"Format string contains an unescaped latin alphabet character `" + x + "`"
|
|
1251
1252
|
);
|
|
1252
1253
|
return { isToken: !1, value: p };
|
|
1253
1254
|
});
|
|
1254
|
-
r.localize.preprocessor && (
|
|
1255
|
+
r.localize.preprocessor && (l = r.localize.preprocessor(s, l));
|
|
1255
1256
|
const d = {
|
|
1256
1257
|
firstWeekContainsDate: o,
|
|
1257
1258
|
weekStartsOn: i,
|
|
1258
1259
|
locale: r
|
|
1259
1260
|
};
|
|
1260
|
-
return
|
|
1261
|
+
return l.map((p) => {
|
|
1261
1262
|
if (!p.isToken)
|
|
1262
1263
|
return p.value;
|
|
1263
|
-
const
|
|
1264
|
-
(!(n != null && n.useAdditionalWeekYearTokens) &&
|
|
1265
|
-
const
|
|
1266
|
-
return
|
|
1264
|
+
const x = p.value;
|
|
1265
|
+
(!(n != null && n.useAdditionalWeekYearTokens) && _n(x) || !(n != null && n.useAdditionalDayOfYearTokens) && Mn(x)) && kn(x, t, String(e));
|
|
1266
|
+
const j = Ee[x[0]];
|
|
1267
|
+
return j(s, x, r.localize, d);
|
|
1267
1268
|
}).join("");
|
|
1268
1269
|
}
|
|
1269
|
-
function
|
|
1270
|
-
const t = e.match(
|
|
1271
|
-
return t ? t[1].replace(
|
|
1270
|
+
function Wn(e) {
|
|
1271
|
+
const t = e.match(On);
|
|
1272
|
+
return t ? t[1].replace(Cn, "'") : e;
|
|
1272
1273
|
}
|
|
1273
|
-
function
|
|
1274
|
-
const t =
|
|
1274
|
+
function Tn(e) {
|
|
1275
|
+
const t = M(e), n = t.getFullYear(), a = t.getMonth(), r = W(e, 0);
|
|
1275
1276
|
return r.setFullYear(n, a + 1, 0), r.setHours(0, 0, 0, 0), r.getDate();
|
|
1276
1277
|
}
|
|
1277
|
-
function
|
|
1278
|
-
return Math.trunc(+
|
|
1278
|
+
function Yn(e) {
|
|
1279
|
+
return Math.trunc(+M(e) / 1e3);
|
|
1279
1280
|
}
|
|
1280
|
-
function
|
|
1281
|
-
const t =
|
|
1281
|
+
function Fn(e) {
|
|
1282
|
+
const t = M(e), n = t.getMonth();
|
|
1282
1283
|
return t.setFullYear(t.getFullYear(), n + 1, 0), t.setHours(0, 0, 0, 0), t;
|
|
1283
1284
|
}
|
|
1284
|
-
function
|
|
1285
|
-
return
|
|
1286
|
-
|
|
1287
|
-
|
|
1285
|
+
function Ln(e, t) {
|
|
1286
|
+
return Lt(
|
|
1287
|
+
Fn(e),
|
|
1288
|
+
S(e),
|
|
1288
1289
|
t
|
|
1289
1290
|
) + 1;
|
|
1290
1291
|
}
|
|
1291
|
-
function
|
|
1292
|
-
const n =
|
|
1292
|
+
function pe(e, t) {
|
|
1293
|
+
const n = M(e), a = M(t);
|
|
1293
1294
|
return n.getTime() > a.getTime();
|
|
1294
1295
|
}
|
|
1295
|
-
function
|
|
1296
|
-
const n =
|
|
1296
|
+
function Ze(e, t) {
|
|
1297
|
+
const n = M(e), a = M(t);
|
|
1297
1298
|
return +n < +a;
|
|
1298
1299
|
}
|
|
1299
|
-
function
|
|
1300
|
-
const n =
|
|
1300
|
+
function Ne(e, t) {
|
|
1301
|
+
const n = M(e), a = M(t);
|
|
1301
1302
|
return n.getFullYear() === a.getFullYear() && n.getMonth() === a.getMonth();
|
|
1302
1303
|
}
|
|
1303
|
-
function
|
|
1304
|
-
const n =
|
|
1304
|
+
function En(e, t) {
|
|
1305
|
+
const n = M(e), a = M(t);
|
|
1305
1306
|
return n.getFullYear() === a.getFullYear();
|
|
1306
1307
|
}
|
|
1307
|
-
function
|
|
1308
|
+
function he(e, t) {
|
|
1308
1309
|
return P(e, -t);
|
|
1309
1310
|
}
|
|
1310
|
-
function
|
|
1311
|
-
const n =
|
|
1311
|
+
function me(e, t) {
|
|
1312
|
+
const n = M(e), a = n.getFullYear(), r = n.getDate(), o = W(e, 0);
|
|
1312
1313
|
o.setFullYear(a, t, 15), o.setHours(0, 0, 0, 0);
|
|
1313
|
-
const i =
|
|
1314
|
+
const i = Tn(o);
|
|
1314
1315
|
return n.setMonth(t, Math.min(r, i)), n;
|
|
1315
1316
|
}
|
|
1316
|
-
function
|
|
1317
|
-
const n =
|
|
1318
|
-
return isNaN(+n) ?
|
|
1317
|
+
function je(e, t) {
|
|
1318
|
+
const n = M(e);
|
|
1319
|
+
return isNaN(+n) ? W(e, NaN) : (n.setFullYear(t), n);
|
|
1319
1320
|
}
|
|
1320
|
-
var
|
|
1321
|
-
return
|
|
1321
|
+
var b = function() {
|
|
1322
|
+
return b = Object.assign || function(t) {
|
|
1322
1323
|
for (var n, a = 1, r = arguments.length; a < r; a++) {
|
|
1323
1324
|
n = arguments[a];
|
|
1324
1325
|
for (var o in n)
|
|
1325
1326
|
Object.prototype.hasOwnProperty.call(n, o) && (t[o] = n[o]);
|
|
1326
1327
|
}
|
|
1327
1328
|
return t;
|
|
1328
|
-
},
|
|
1329
|
+
}, b.apply(this, arguments);
|
|
1329
1330
|
};
|
|
1330
|
-
function
|
|
1331
|
+
function In(e, t) {
|
|
1331
1332
|
var n = {};
|
|
1332
1333
|
for (var a in e)
|
|
1333
1334
|
Object.prototype.hasOwnProperty.call(e, a) && t.indexOf(a) < 0 && (n[a] = e[a]);
|
|
@@ -1336,22 +1337,22 @@ function Fn(e, t) {
|
|
|
1336
1337
|
t.indexOf(a[r]) < 0 && Object.prototype.propertyIsEnumerable.call(e, a[r]) && (n[a[r]] = e[a[r]]);
|
|
1337
1338
|
return n;
|
|
1338
1339
|
}
|
|
1339
|
-
function
|
|
1340
|
+
function et(e, t, n) {
|
|
1340
1341
|
if (n || arguments.length === 2)
|
|
1341
1342
|
for (var a = 0, r = t.length, o; a < r; a++)
|
|
1342
1343
|
(o || !(a in t)) && (o || (o = Array.prototype.slice.call(t, 0, a)), o[a] = t[a]);
|
|
1343
1344
|
return e.concat(o || Array.prototype.slice.call(t));
|
|
1344
1345
|
}
|
|
1345
|
-
function
|
|
1346
|
+
function ee(e) {
|
|
1346
1347
|
return e.mode === "multiple";
|
|
1347
1348
|
}
|
|
1348
|
-
function
|
|
1349
|
+
function te(e) {
|
|
1349
1350
|
return e.mode === "range";
|
|
1350
1351
|
}
|
|
1351
|
-
function
|
|
1352
|
+
function se(e) {
|
|
1352
1353
|
return e.mode === "single";
|
|
1353
1354
|
}
|
|
1354
|
-
var
|
|
1355
|
+
var Rn = {
|
|
1355
1356
|
root: "rdp",
|
|
1356
1357
|
multiple_months: "rdp-multiple_months",
|
|
1357
1358
|
with_weeknumber: "rdp-with_weeknumber",
|
|
@@ -1394,63 +1395,63 @@ var Ln = {
|
|
|
1394
1395
|
day_range_end: "rdp-day_range_end",
|
|
1395
1396
|
day_range_middle: "rdp-day_range_middle"
|
|
1396
1397
|
};
|
|
1397
|
-
function
|
|
1398
|
-
return
|
|
1398
|
+
function Bn(e, t) {
|
|
1399
|
+
return E(e, "LLLL y", t);
|
|
1399
1400
|
}
|
|
1400
|
-
function
|
|
1401
|
-
return
|
|
1401
|
+
function jn(e, t) {
|
|
1402
|
+
return E(e, "d", t);
|
|
1402
1403
|
}
|
|
1403
|
-
function
|
|
1404
|
-
return
|
|
1404
|
+
function Hn(e, t) {
|
|
1405
|
+
return E(e, "LLLL", t);
|
|
1405
1406
|
}
|
|
1406
|
-
function
|
|
1407
|
+
function An(e) {
|
|
1407
1408
|
return "".concat(e);
|
|
1408
1409
|
}
|
|
1409
|
-
function
|
|
1410
|
-
return
|
|
1410
|
+
function qn(e, t) {
|
|
1411
|
+
return E(e, "cccccc", t);
|
|
1411
1412
|
}
|
|
1412
|
-
function
|
|
1413
|
-
return
|
|
1413
|
+
function Qn(e, t) {
|
|
1414
|
+
return E(e, "yyyy", t);
|
|
1414
1415
|
}
|
|
1415
|
-
var
|
|
1416
|
+
var Xn = /* @__PURE__ */ Object.freeze({
|
|
1416
1417
|
__proto__: null,
|
|
1417
|
-
formatCaption:
|
|
1418
|
-
formatDay:
|
|
1419
|
-
formatMonthCaption:
|
|
1420
|
-
formatWeekNumber:
|
|
1421
|
-
formatWeekdayName:
|
|
1422
|
-
formatYearCaption:
|
|
1423
|
-
}),
|
|
1424
|
-
return
|
|
1425
|
-
},
|
|
1418
|
+
formatCaption: Bn,
|
|
1419
|
+
formatDay: jn,
|
|
1420
|
+
formatMonthCaption: Hn,
|
|
1421
|
+
formatWeekNumber: An,
|
|
1422
|
+
formatWeekdayName: qn,
|
|
1423
|
+
formatYearCaption: Qn
|
|
1424
|
+
}), Gn = function(e, t, n) {
|
|
1425
|
+
return E(e, "do MMMM (EEEE)", n);
|
|
1426
|
+
}, Vn = function() {
|
|
1426
1427
|
return "Month: ";
|
|
1427
|
-
},
|
|
1428
|
+
}, $n = function() {
|
|
1428
1429
|
return "Go to next month";
|
|
1429
|
-
},
|
|
1430
|
+
}, Un = function() {
|
|
1430
1431
|
return "Go to previous month";
|
|
1431
|
-
},
|
|
1432
|
-
return
|
|
1433
|
-
},
|
|
1432
|
+
}, Jn = function(e, t) {
|
|
1433
|
+
return E(e, "cccc", t);
|
|
1434
|
+
}, Kn = function(e) {
|
|
1434
1435
|
return "Week n. ".concat(e);
|
|
1435
|
-
},
|
|
1436
|
+
}, zn = function() {
|
|
1436
1437
|
return "Year: ";
|
|
1437
|
-
},
|
|
1438
|
+
}, Zn = /* @__PURE__ */ Object.freeze({
|
|
1438
1439
|
__proto__: null,
|
|
1439
|
-
labelDay:
|
|
1440
|
-
labelMonthDropdown:
|
|
1441
|
-
labelNext:
|
|
1442
|
-
labelPrevious:
|
|
1443
|
-
labelWeekNumber:
|
|
1444
|
-
labelWeekday:
|
|
1445
|
-
labelYearDropdown:
|
|
1440
|
+
labelDay: Gn,
|
|
1441
|
+
labelMonthDropdown: Vn,
|
|
1442
|
+
labelNext: $n,
|
|
1443
|
+
labelPrevious: Un,
|
|
1444
|
+
labelWeekNumber: Kn,
|
|
1445
|
+
labelWeekday: Jn,
|
|
1446
|
+
labelYearDropdown: zn
|
|
1446
1447
|
});
|
|
1447
|
-
function
|
|
1448
|
-
var e = "buttons", t =
|
|
1448
|
+
function ea() {
|
|
1449
|
+
var e = "buttons", t = Rn, n = $e, a = {}, r = {}, o = 1, i = {}, s = /* @__PURE__ */ new Date();
|
|
1449
1450
|
return {
|
|
1450
1451
|
captionLayout: e,
|
|
1451
1452
|
classNames: t,
|
|
1452
|
-
formatters:
|
|
1453
|
-
labels:
|
|
1453
|
+
formatters: Xn,
|
|
1454
|
+
labels: Zn,
|
|
1454
1455
|
locale: n,
|
|
1455
1456
|
modifiersClassNames: a,
|
|
1456
1457
|
modifiers: r,
|
|
@@ -1460,281 +1461,281 @@ function zn() {
|
|
|
1460
1461
|
mode: "default"
|
|
1461
1462
|
};
|
|
1462
1463
|
}
|
|
1463
|
-
function
|
|
1464
|
+
function ta(e) {
|
|
1464
1465
|
var t = e.fromYear, n = e.toYear, a = e.fromMonth, r = e.toMonth, o = e.fromDate, i = e.toDate;
|
|
1465
|
-
return a ? o =
|
|
1466
|
-
fromDate: o ?
|
|
1467
|
-
toDate: i ?
|
|
1466
|
+
return a ? o = S(a) : t && (o = new Date(t, 0, 1)), r ? i = _e(r) : n && (i = new Date(n, 11, 31)), {
|
|
1467
|
+
fromDate: o ? G(o) : void 0,
|
|
1468
|
+
toDate: i ? G(i) : void 0
|
|
1468
1469
|
};
|
|
1469
1470
|
}
|
|
1470
|
-
var
|
|
1471
|
-
function
|
|
1472
|
-
var t, n = e.initialProps, a =
|
|
1471
|
+
var tt = q(void 0);
|
|
1472
|
+
function na(e) {
|
|
1473
|
+
var t, n = e.initialProps, a = ea(), r = ta(n), o = r.fromDate, i = r.toDate, s = (t = n.captionLayout) !== null && t !== void 0 ? t : a.captionLayout;
|
|
1473
1474
|
s !== "buttons" && (!o || !i) && (s = "buttons");
|
|
1474
|
-
var
|
|
1475
|
-
(
|
|
1476
|
-
var d =
|
|
1477
|
-
return
|
|
1475
|
+
var l;
|
|
1476
|
+
(se(n) || ee(n) || te(n)) && (l = n.onSelect);
|
|
1477
|
+
var d = b(b(b({}, a), n), { captionLayout: s, classNames: b(b({}, a.classNames), n.classNames), components: b({}, n.components), formatters: b(b({}, a.formatters), n.formatters), fromDate: o, labels: b(b({}, a.labels), n.labels), mode: n.mode || a.mode, modifiers: b(b({}, a.modifiers), n.modifiers), modifiersClassNames: b(b({}, a.modifiersClassNames), n.modifiersClassNames), onSelect: l, styles: b(b({}, a.styles), n.styles), toDate: i });
|
|
1478
|
+
return c(tt.Provider, { value: d, children: e.children });
|
|
1478
1479
|
}
|
|
1479
|
-
function
|
|
1480
|
-
var e =
|
|
1480
|
+
function k() {
|
|
1481
|
+
var e = Q(tt);
|
|
1481
1482
|
if (!e)
|
|
1482
1483
|
throw new Error("useDayPicker must be used within a DayPickerProvider.");
|
|
1483
1484
|
return e;
|
|
1484
1485
|
}
|
|
1485
|
-
function
|
|
1486
|
-
var t =
|
|
1487
|
-
return
|
|
1486
|
+
function nt(e) {
|
|
1487
|
+
var t = k(), n = t.locale, a = t.classNames, r = t.styles, o = t.formatters.formatCaption;
|
|
1488
|
+
return c("div", { className: a.caption_label, style: r.caption_label, "aria-live": "polite", role: "presentation", id: e.id, children: o(e.displayMonth, { locale: n }) });
|
|
1488
1489
|
}
|
|
1489
|
-
function
|
|
1490
|
-
return
|
|
1490
|
+
function aa(e) {
|
|
1491
|
+
return c("svg", b({ width: "8px", height: "8px", viewBox: "0 0 120 120", "data-testid": "iconDropdown" }, e, { children: c("path", { d: "M4.22182541,48.2218254 C8.44222828,44.0014225 15.2388494,43.9273804 19.5496459,47.9996989 L19.7781746,48.2218254 L60,88.443 L100.221825,48.2218254 C104.442228,44.0014225 111.238849,43.9273804 115.549646,47.9996989 L115.778175,48.2218254 C119.998577,52.4422283 120.07262,59.2388494 116.000301,63.5496459 L115.778175,63.7781746 L67.7781746,111.778175 C63.5577717,115.998577 56.7611506,116.07262 52.4503541,112.000301 L52.2218254,111.778175 L4.22182541,63.7781746 C-0.0739418023,59.4824074 -0.0739418023,52.5175926 4.22182541,48.2218254 Z", fill: "currentColor", fillRule: "nonzero" }) }));
|
|
1491
1492
|
}
|
|
1492
|
-
function
|
|
1493
|
-
var t, n, a = e.onChange, r = e.value, o = e.children, i = e.caption, s = e.className,
|
|
1494
|
-
return
|
|
1493
|
+
function at(e) {
|
|
1494
|
+
var t, n, a = e.onChange, r = e.value, o = e.children, i = e.caption, s = e.className, l = e.style, d = k(), u = (n = (t = d.components) === null || t === void 0 ? void 0 : t.IconDropdown) !== null && n !== void 0 ? n : aa;
|
|
1495
|
+
return O("div", { className: s, style: l, children: [c("span", { className: d.classNames.vhidden, children: e["aria-label"] }), c("select", { name: e.name, "aria-label": e["aria-label"], className: d.classNames.dropdown, style: d.styles.dropdown, value: r, onChange: a, children: o }), O("div", { className: d.classNames.caption_label, style: d.styles.caption_label, "aria-hidden": "true", children: [i, c(u, { className: d.classNames.dropdown_icon, style: d.styles.dropdown_icon })] })] });
|
|
1495
1496
|
}
|
|
1496
|
-
function
|
|
1497
|
-
var t, n =
|
|
1497
|
+
function ra(e) {
|
|
1498
|
+
var t, n = k(), a = n.fromDate, r = n.toDate, o = n.styles, i = n.locale, s = n.formatters.formatMonthCaption, l = n.classNames, d = n.components, u = n.labels.labelMonthDropdown;
|
|
1498
1499
|
if (!a)
|
|
1499
|
-
return
|
|
1500
|
+
return c(T, {});
|
|
1500
1501
|
if (!r)
|
|
1501
|
-
return
|
|
1502
|
+
return c(T, {});
|
|
1502
1503
|
var f = [];
|
|
1503
|
-
if (
|
|
1504
|
-
for (var h =
|
|
1505
|
-
f.push(
|
|
1504
|
+
if (En(a, r))
|
|
1505
|
+
for (var h = S(a), m = a.getMonth(); m <= r.getMonth(); m++)
|
|
1506
|
+
f.push(me(h, m));
|
|
1506
1507
|
else
|
|
1507
|
-
for (var h =
|
|
1508
|
-
f.push(
|
|
1508
|
+
for (var h = S(/* @__PURE__ */ new Date()), m = 0; m <= 11; m++)
|
|
1509
|
+
f.push(me(h, m));
|
|
1509
1510
|
var y = function(w) {
|
|
1510
|
-
var
|
|
1511
|
+
var N = Number(w.target.value), p = me(S(e.displayMonth), N);
|
|
1511
1512
|
e.onChange(p);
|
|
1512
|
-
},
|
|
1513
|
-
return
|
|
1514
|
-
return
|
|
1513
|
+
}, D = (t = d == null ? void 0 : d.Dropdown) !== null && t !== void 0 ? t : at;
|
|
1514
|
+
return c(D, { name: "months", "aria-label": u(), className: l.dropdown_month, style: o.dropdown_month, onChange: y, value: e.displayMonth.getMonth(), caption: s(e.displayMonth, { locale: i }), children: f.map(function(w) {
|
|
1515
|
+
return c("option", { value: w.getMonth(), children: s(w, { locale: i }) }, w.getMonth());
|
|
1515
1516
|
}) });
|
|
1516
1517
|
}
|
|
1517
|
-
function
|
|
1518
|
-
var t, n = e.displayMonth, a =
|
|
1518
|
+
function oa(e) {
|
|
1519
|
+
var t, n = e.displayMonth, a = k(), r = a.fromDate, o = a.toDate, i = a.locale, s = a.styles, l = a.classNames, d = a.components, u = a.formatters.formatYearCaption, f = a.labels.labelYearDropdown, h = [];
|
|
1519
1520
|
if (!r)
|
|
1520
|
-
return
|
|
1521
|
+
return c(T, {});
|
|
1521
1522
|
if (!o)
|
|
1522
|
-
return
|
|
1523
|
-
for (var m = r.getFullYear(), y = o.getFullYear(),
|
|
1524
|
-
h.push(
|
|
1523
|
+
return c(T, {});
|
|
1524
|
+
for (var m = r.getFullYear(), y = o.getFullYear(), D = m; D <= y; D++)
|
|
1525
|
+
h.push(je(Ge(/* @__PURE__ */ new Date()), D));
|
|
1525
1526
|
var w = function(p) {
|
|
1526
|
-
var
|
|
1527
|
-
e.onChange(
|
|
1528
|
-
},
|
|
1529
|
-
return
|
|
1530
|
-
return
|
|
1527
|
+
var x = je(S(n), Number(p.target.value));
|
|
1528
|
+
e.onChange(x);
|
|
1529
|
+
}, N = (t = d == null ? void 0 : d.Dropdown) !== null && t !== void 0 ? t : at;
|
|
1530
|
+
return c(N, { name: "years", "aria-label": f(), className: l.dropdown_year, style: s.dropdown_year, onChange: w, value: n.getFullYear(), caption: u(n, { locale: i }), children: h.map(function(p) {
|
|
1531
|
+
return c("option", { value: p.getFullYear(), children: u(p, { locale: i }) }, p.getFullYear());
|
|
1531
1532
|
}) });
|
|
1532
1533
|
}
|
|
1533
|
-
function
|
|
1534
|
-
var n =
|
|
1534
|
+
function ia(e, t) {
|
|
1535
|
+
var n = K(e), a = n[0], r = n[1], o = t === void 0 ? a : t;
|
|
1535
1536
|
return [o, r];
|
|
1536
1537
|
}
|
|
1537
|
-
function
|
|
1538
|
-
var t = e.month, n = e.defaultMonth, a = e.today, r = t || n || a || /* @__PURE__ */ new Date(), o = e.toDate, i = e.fromDate, s = e.numberOfMonths,
|
|
1539
|
-
if (o &&
|
|
1540
|
-
var d = -1 * (
|
|
1541
|
-
r =
|
|
1538
|
+
function sa(e) {
|
|
1539
|
+
var t = e.month, n = e.defaultMonth, a = e.today, r = t || n || a || /* @__PURE__ */ new Date(), o = e.toDate, i = e.fromDate, s = e.numberOfMonths, l = s === void 0 ? 1 : s;
|
|
1540
|
+
if (o && z(o, r) < 0) {
|
|
1541
|
+
var d = -1 * (l - 1);
|
|
1542
|
+
r = Y(o, d);
|
|
1542
1543
|
}
|
|
1543
|
-
return i &&
|
|
1544
|
+
return i && z(r, i) < 0 && (r = i), S(r);
|
|
1544
1545
|
}
|
|
1545
|
-
function
|
|
1546
|
-
var e =
|
|
1546
|
+
function la() {
|
|
1547
|
+
var e = k(), t = sa(e), n = ia(t, e.month), a = n[0], r = n[1], o = function(i) {
|
|
1547
1548
|
var s;
|
|
1548
1549
|
if (!e.disableNavigation) {
|
|
1549
|
-
var
|
|
1550
|
-
r(
|
|
1550
|
+
var l = S(i);
|
|
1551
|
+
r(l), (s = e.onMonthChange) === null || s === void 0 || s.call(e, l);
|
|
1551
1552
|
}
|
|
1552
1553
|
};
|
|
1553
1554
|
return [a, o];
|
|
1554
1555
|
}
|
|
1555
|
-
function
|
|
1556
|
-
for (var n = t.reverseMonths, a = t.numberOfMonths, r =
|
|
1557
|
-
var d =
|
|
1556
|
+
function ua(e, t) {
|
|
1557
|
+
for (var n = t.reverseMonths, a = t.numberOfMonths, r = S(e), o = S(Y(r, a)), i = z(o, r), s = [], l = 0; l < i; l++) {
|
|
1558
|
+
var d = Y(r, l);
|
|
1558
1559
|
s.push(d);
|
|
1559
1560
|
}
|
|
1560
1561
|
return n && (s = s.reverse()), s;
|
|
1561
1562
|
}
|
|
1562
|
-
function
|
|
1563
|
+
function ca(e, t) {
|
|
1563
1564
|
if (!t.disableNavigation) {
|
|
1564
|
-
var n = t.toDate, a = t.pagedNavigation, r = t.numberOfMonths, o = r === void 0 ? 1 : r, i = a ? o : 1, s =
|
|
1565
|
+
var n = t.toDate, a = t.pagedNavigation, r = t.numberOfMonths, o = r === void 0 ? 1 : r, i = a ? o : 1, s = S(e);
|
|
1565
1566
|
if (!n)
|
|
1566
|
-
return
|
|
1567
|
-
var
|
|
1568
|
-
if (!(
|
|
1569
|
-
return
|
|
1567
|
+
return Y(s, i);
|
|
1568
|
+
var l = z(n, e);
|
|
1569
|
+
if (!(l < o))
|
|
1570
|
+
return Y(s, i);
|
|
1570
1571
|
}
|
|
1571
1572
|
}
|
|
1572
|
-
function
|
|
1573
|
+
function da(e, t) {
|
|
1573
1574
|
if (!t.disableNavigation) {
|
|
1574
|
-
var n = t.fromDate, a = t.pagedNavigation, r = t.numberOfMonths, o = r === void 0 ? 1 : r, i = a ? o : 1, s =
|
|
1575
|
+
var n = t.fromDate, a = t.pagedNavigation, r = t.numberOfMonths, o = r === void 0 ? 1 : r, i = a ? o : 1, s = S(e);
|
|
1575
1576
|
if (!n)
|
|
1576
|
-
return
|
|
1577
|
-
var
|
|
1578
|
-
if (!(
|
|
1579
|
-
return
|
|
1577
|
+
return Y(s, -i);
|
|
1578
|
+
var l = z(s, n);
|
|
1579
|
+
if (!(l <= 0))
|
|
1580
|
+
return Y(s, -i);
|
|
1580
1581
|
}
|
|
1581
1582
|
}
|
|
1582
|
-
var
|
|
1583
|
-
function
|
|
1584
|
-
var t =
|
|
1583
|
+
var rt = q(void 0);
|
|
1584
|
+
function fa(e) {
|
|
1585
|
+
var t = k(), n = la(), a = n[0], r = n[1], o = ua(a, t), i = ca(a, t), s = da(a, t), l = function(f) {
|
|
1585
1586
|
return o.some(function(h) {
|
|
1586
|
-
return
|
|
1587
|
+
return Ne(f, h);
|
|
1587
1588
|
});
|
|
1588
1589
|
}, d = function(f, h) {
|
|
1589
|
-
|
|
1590
|
-
},
|
|
1590
|
+
l(f) || (h && Ze(f, h) ? r(Y(f, 1 + t.numberOfMonths * -1)) : r(f));
|
|
1591
|
+
}, u = {
|
|
1591
1592
|
currentMonth: a,
|
|
1592
1593
|
displayMonths: o,
|
|
1593
1594
|
goToMonth: r,
|
|
1594
1595
|
goToDate: d,
|
|
1595
1596
|
previousMonth: s,
|
|
1596
1597
|
nextMonth: i,
|
|
1597
|
-
isDateDisplayed:
|
|
1598
|
+
isDateDisplayed: l
|
|
1598
1599
|
};
|
|
1599
|
-
return
|
|
1600
|
+
return c(rt.Provider, { value: u, children: e.children });
|
|
1600
1601
|
}
|
|
1601
|
-
function
|
|
1602
|
-
var e =
|
|
1602
|
+
function ne() {
|
|
1603
|
+
var e = Q(rt);
|
|
1603
1604
|
if (!e)
|
|
1604
1605
|
throw new Error("useNavigation must be used within a NavigationProvider");
|
|
1605
1606
|
return e;
|
|
1606
1607
|
}
|
|
1607
|
-
function
|
|
1608
|
-
var t, n =
|
|
1609
|
-
i(
|
|
1610
|
-
},
|
|
1611
|
-
return
|
|
1608
|
+
function He(e) {
|
|
1609
|
+
var t, n = k(), a = n.classNames, r = n.styles, o = n.components, i = ne().goToMonth, s = function(u) {
|
|
1610
|
+
i(Y(u, e.displayIndex ? -e.displayIndex : 0));
|
|
1611
|
+
}, l = (t = o == null ? void 0 : o.CaptionLabel) !== null && t !== void 0 ? t : nt, d = c(l, { id: e.id, displayMonth: e.displayMonth });
|
|
1612
|
+
return O("div", { className: a.caption_dropdowns, style: r.caption_dropdowns, children: [c("div", { className: a.vhidden, children: d }), c(ra, { onChange: s, displayMonth: e.displayMonth }), c(oa, { onChange: s, displayMonth: e.displayMonth })] });
|
|
1612
1613
|
}
|
|
1613
|
-
function
|
|
1614
|
-
return
|
|
1614
|
+
function ha(e) {
|
|
1615
|
+
return c("svg", b({ width: "16px", height: "16px", viewBox: "0 0 120 120" }, e, { children: c("path", { d: "M69.490332,3.34314575 C72.6145263,0.218951416 77.6798462,0.218951416 80.8040405,3.34314575 C83.8617626,6.40086786 83.9268205,11.3179931 80.9992143,14.4548388 L80.8040405,14.6568542 L35.461,60 L80.8040405,105.343146 C83.8617626,108.400868 83.9268205,113.317993 80.9992143,116.454839 L80.8040405,116.656854 C77.7463184,119.714576 72.8291931,119.779634 69.6923475,116.852028 L69.490332,116.656854 L18.490332,65.6568542 C15.4326099,62.5991321 15.367552,57.6820069 18.2951583,54.5451612 L18.490332,54.3431458 L69.490332,3.34314575 Z", fill: "currentColor", fillRule: "nonzero" }) }));
|
|
1615
1616
|
}
|
|
1616
|
-
function
|
|
1617
|
-
return
|
|
1617
|
+
function ma(e) {
|
|
1618
|
+
return c("svg", b({ width: "16px", height: "16px", viewBox: "0 0 120 120" }, e, { children: c("path", { d: "M49.8040405,3.34314575 C46.6798462,0.218951416 41.6145263,0.218951416 38.490332,3.34314575 C35.4326099,6.40086786 35.367552,11.3179931 38.2951583,14.4548388 L38.490332,14.6568542 L83.8333725,60 L38.490332,105.343146 C35.4326099,108.400868 35.367552,113.317993 38.2951583,116.454839 L38.490332,116.656854 C41.5480541,119.714576 46.4651794,119.779634 49.602025,116.852028 L49.8040405,116.656854 L100.804041,65.6568542 C103.861763,62.5991321 103.926821,57.6820069 100.999214,54.5451612 L100.804041,54.3431458 L49.8040405,3.34314575 Z", fill: "currentColor" }) }));
|
|
1618
1619
|
}
|
|
1619
|
-
var
|
|
1620
|
-
var n =
|
|
1620
|
+
var oe = Nt(function(e, t) {
|
|
1621
|
+
var n = k(), a = n.classNames, r = n.styles, o = [a.button_reset, a.button];
|
|
1621
1622
|
e.className && o.push(e.className);
|
|
1622
|
-
var i = o.join(" "), s =
|
|
1623
|
-
return e.style && Object.assign(s, e.style),
|
|
1623
|
+
var i = o.join(" "), s = b(b({}, r.button_reset), r.button);
|
|
1624
|
+
return e.style && Object.assign(s, e.style), c("button", b({}, e, { ref: t, type: "button", className: i, style: s }));
|
|
1624
1625
|
});
|
|
1625
|
-
function
|
|
1626
|
-
var t, n, a =
|
|
1626
|
+
function va(e) {
|
|
1627
|
+
var t, n, a = k(), r = a.dir, o = a.locale, i = a.classNames, s = a.styles, l = a.labels, d = l.labelPrevious, u = l.labelNext, f = a.components;
|
|
1627
1628
|
if (!e.nextMonth && !e.previousMonth)
|
|
1628
|
-
return
|
|
1629
|
+
return c(T, {});
|
|
1629
1630
|
var h = d(e.previousMonth, { locale: o }), m = [
|
|
1630
1631
|
i.nav_button,
|
|
1631
1632
|
i.nav_button_previous
|
|
1632
|
-
].join(" "), y =
|
|
1633
|
+
].join(" "), y = u(e.nextMonth, { locale: o }), D = [
|
|
1633
1634
|
i.nav_button,
|
|
1634
1635
|
i.nav_button_next
|
|
1635
|
-
].join(" "), w = (t = f == null ? void 0 : f.IconRight) !== null && t !== void 0 ? t :
|
|
1636
|
-
return
|
|
1636
|
+
].join(" "), w = (t = f == null ? void 0 : f.IconRight) !== null && t !== void 0 ? t : ma, N = (n = f == null ? void 0 : f.IconLeft) !== null && n !== void 0 ? n : ha;
|
|
1637
|
+
return O("div", { className: i.nav, style: s.nav, children: [!e.hidePrevious && c(oe, { name: "previous-month", "aria-label": h, className: m, style: s.nav_button_previous, disabled: !e.previousMonth, onClick: e.onPreviousClick, children: r === "rtl" ? c(w, { className: i.nav_icon, style: s.nav_icon }) : c(N, { className: i.nav_icon, style: s.nav_icon }) }), !e.hideNext && c(oe, { name: "next-month", "aria-label": y, className: D, style: s.nav_button_next, disabled: !e.nextMonth, onClick: e.onNextClick, children: r === "rtl" ? c(N, { className: i.nav_icon, style: s.nav_icon }) : c(w, { className: i.nav_icon, style: s.nav_icon }) })] });
|
|
1637
1638
|
}
|
|
1638
|
-
function
|
|
1639
|
-
var t =
|
|
1640
|
-
return
|
|
1641
|
-
}),
|
|
1639
|
+
function Ae(e) {
|
|
1640
|
+
var t = k().numberOfMonths, n = ne(), a = n.previousMonth, r = n.nextMonth, o = n.goToMonth, i = n.displayMonths, s = i.findIndex(function(y) {
|
|
1641
|
+
return Ne(e.displayMonth, y);
|
|
1642
|
+
}), l = s === 0, d = s === i.length - 1, u = t > 1 && (l || !d), f = t > 1 && (d || !l), h = function() {
|
|
1642
1643
|
a && o(a);
|
|
1643
1644
|
}, m = function() {
|
|
1644
1645
|
r && o(r);
|
|
1645
1646
|
};
|
|
1646
|
-
return
|
|
1647
|
+
return c(va, { displayMonth: e.displayMonth, hideNext: u, hidePrevious: f, nextMonth: r, previousMonth: a, onPreviousClick: h, onNextClick: m });
|
|
1647
1648
|
}
|
|
1648
|
-
function
|
|
1649
|
-
var t, n =
|
|
1650
|
-
return r ? d = l
|
|
1649
|
+
function ya(e) {
|
|
1650
|
+
var t, n = k(), a = n.classNames, r = n.disableNavigation, o = n.styles, i = n.captionLayout, s = n.components, l = (t = s == null ? void 0 : s.CaptionLabel) !== null && t !== void 0 ? t : nt, d;
|
|
1651
|
+
return r ? d = c(l, { id: e.id, displayMonth: e.displayMonth }) : i === "dropdown" ? d = c(He, { displayMonth: e.displayMonth, id: e.id }) : i === "dropdown-buttons" ? d = O(T, { children: [c(He, { displayMonth: e.displayMonth, displayIndex: e.displayIndex, id: e.id }), c(Ae, { displayMonth: e.displayMonth, displayIndex: e.displayIndex, id: e.id })] }) : d = O(T, { children: [c(l, { id: e.id, displayMonth: e.displayMonth, displayIndex: e.displayIndex }), c(Ae, { displayMonth: e.displayMonth, id: e.id })] }), c("div", { className: a.caption, style: o.caption, children: d });
|
|
1651
1652
|
}
|
|
1652
|
-
function
|
|
1653
|
-
var t =
|
|
1654
|
-
return n ?
|
|
1653
|
+
function ba(e) {
|
|
1654
|
+
var t = k(), n = t.footer, a = t.styles, r = t.classNames.tfoot;
|
|
1655
|
+
return n ? c("tfoot", { className: r, style: a.tfoot, children: c("tr", { children: c("td", { colSpan: 8, children: n }) }) }) : c(T, {});
|
|
1655
1656
|
}
|
|
1656
|
-
function
|
|
1657
|
-
for (var a = n ?
|
|
1657
|
+
function ga(e, t, n) {
|
|
1658
|
+
for (var a = n ? A(/* @__PURE__ */ new Date()) : I(/* @__PURE__ */ new Date(), { locale: e, weekStartsOn: t }), r = [], o = 0; o < 7; o++) {
|
|
1658
1659
|
var i = P(a, o);
|
|
1659
1660
|
r.push(i);
|
|
1660
1661
|
}
|
|
1661
1662
|
return r;
|
|
1662
1663
|
}
|
|
1663
|
-
function
|
|
1664
|
-
var e =
|
|
1665
|
-
return
|
|
1666
|
-
return
|
|
1664
|
+
function wa() {
|
|
1665
|
+
var e = k(), t = e.classNames, n = e.styles, a = e.showWeekNumber, r = e.locale, o = e.weekStartsOn, i = e.ISOWeek, s = e.formatters.formatWeekdayName, l = e.labels.labelWeekday, d = ga(r, o, i);
|
|
1666
|
+
return O("tr", { style: n.head_row, className: t.head_row, children: [a && c("td", { style: n.head_cell, className: t.head_cell }), d.map(function(u, f) {
|
|
1667
|
+
return c("th", { scope: "col", className: t.head_cell, style: n.head_cell, "aria-label": l(u, { locale: r }), children: s(u, { locale: r }) }, f);
|
|
1667
1668
|
})] });
|
|
1668
1669
|
}
|
|
1669
|
-
function
|
|
1670
|
-
var e, t =
|
|
1671
|
-
return
|
|
1670
|
+
function pa() {
|
|
1671
|
+
var e, t = k(), n = t.classNames, a = t.styles, r = t.components, o = (e = r == null ? void 0 : r.HeadRow) !== null && e !== void 0 ? e : wa;
|
|
1672
|
+
return c("thead", { style: a.head, className: n.head, children: c(o, {}) });
|
|
1672
1673
|
}
|
|
1673
|
-
function
|
|
1674
|
-
var t =
|
|
1675
|
-
return
|
|
1674
|
+
function Da(e) {
|
|
1675
|
+
var t = k(), n = t.locale, a = t.formatters.formatDay;
|
|
1676
|
+
return c(T, { children: a(e.date, { locale: n }) });
|
|
1676
1677
|
}
|
|
1677
|
-
var
|
|
1678
|
-
function
|
|
1679
|
-
if (!
|
|
1678
|
+
var xe = q(void 0);
|
|
1679
|
+
function Ma(e) {
|
|
1680
|
+
if (!ee(e.initialProps)) {
|
|
1680
1681
|
var t = {
|
|
1681
1682
|
selected: void 0,
|
|
1682
1683
|
modifiers: {
|
|
1683
1684
|
disabled: []
|
|
1684
1685
|
}
|
|
1685
1686
|
};
|
|
1686
|
-
return
|
|
1687
|
+
return c(xe.Provider, { value: t, children: e.children });
|
|
1687
1688
|
}
|
|
1688
|
-
return
|
|
1689
|
+
return c(_a, { initialProps: e.initialProps, children: e.children });
|
|
1689
1690
|
}
|
|
1690
|
-
function
|
|
1691
|
-
var t = e.initialProps, n = e.children, a = t.selected, r = t.min, o = t.max, i = function(d,
|
|
1691
|
+
function _a(e) {
|
|
1692
|
+
var t = e.initialProps, n = e.children, a = t.selected, r = t.min, o = t.max, i = function(d, u, f) {
|
|
1692
1693
|
var h, m;
|
|
1693
|
-
(h = t.onDayClick) === null || h === void 0 || h.call(t, d,
|
|
1694
|
-
var y = !!(
|
|
1694
|
+
(h = t.onDayClick) === null || h === void 0 || h.call(t, d, u, f);
|
|
1695
|
+
var y = !!(u.selected && r && (a == null ? void 0 : a.length) === r);
|
|
1695
1696
|
if (!y) {
|
|
1696
|
-
var
|
|
1697
|
-
if (!
|
|
1698
|
-
var w = a ?
|
|
1699
|
-
if (
|
|
1700
|
-
var
|
|
1701
|
-
return
|
|
1697
|
+
var D = !!(!u.selected && o && (a == null ? void 0 : a.length) === o);
|
|
1698
|
+
if (!D) {
|
|
1699
|
+
var w = a ? et([], a, !0) : [];
|
|
1700
|
+
if (u.selected) {
|
|
1701
|
+
var N = w.findIndex(function(p) {
|
|
1702
|
+
return C(d, p);
|
|
1702
1703
|
});
|
|
1703
|
-
w.splice(
|
|
1704
|
+
w.splice(N, 1);
|
|
1704
1705
|
} else
|
|
1705
1706
|
w.push(d);
|
|
1706
|
-
(m = t.onSelect) === null || m === void 0 || m.call(t, w, d,
|
|
1707
|
+
(m = t.onSelect) === null || m === void 0 || m.call(t, w, d, u, f);
|
|
1707
1708
|
}
|
|
1708
1709
|
}
|
|
1709
1710
|
}, s = {
|
|
1710
1711
|
disabled: []
|
|
1711
1712
|
};
|
|
1712
1713
|
a && s.disabled.push(function(d) {
|
|
1713
|
-
var
|
|
1714
|
-
return
|
|
1714
|
+
var u = o && a.length > o - 1, f = a.some(function(h) {
|
|
1715
|
+
return C(h, d);
|
|
1715
1716
|
});
|
|
1716
|
-
return !!(
|
|
1717
|
+
return !!(u && !f);
|
|
1717
1718
|
});
|
|
1718
|
-
var
|
|
1719
|
+
var l = {
|
|
1719
1720
|
selected: a,
|
|
1720
1721
|
onDayClick: i,
|
|
1721
1722
|
modifiers: s
|
|
1722
1723
|
};
|
|
1723
|
-
return
|
|
1724
|
+
return c(xe.Provider, { value: l, children: n });
|
|
1724
1725
|
}
|
|
1725
|
-
function
|
|
1726
|
-
var e =
|
|
1726
|
+
function Pe() {
|
|
1727
|
+
var e = Q(xe);
|
|
1727
1728
|
if (!e)
|
|
1728
1729
|
throw new Error("useSelectMultiple must be used within a SelectMultipleProvider");
|
|
1729
1730
|
return e;
|
|
1730
1731
|
}
|
|
1731
|
-
function
|
|
1732
|
+
function ka(e, t) {
|
|
1732
1733
|
var n = t || {}, a = n.from, r = n.to;
|
|
1733
|
-
return a && r ?
|
|
1734
|
+
return a && r ? C(r, e) && C(a, e) ? void 0 : C(r, e) ? { from: r, to: void 0 } : C(a, e) ? void 0 : pe(a, e) ? { from: e, to: r } : { from: a, to: e } : r ? pe(e, r) ? { from: r, to: e } : { from: e, to: r } : a ? Ze(e, a) ? { from: e, to: a } : { from: a, to: e } : { from: e, to: void 0 };
|
|
1734
1735
|
}
|
|
1735
|
-
var
|
|
1736
|
-
function
|
|
1737
|
-
if (!
|
|
1736
|
+
var Oe = q(void 0);
|
|
1737
|
+
function Na(e) {
|
|
1738
|
+
if (!te(e.initialProps)) {
|
|
1738
1739
|
var t = {
|
|
1739
1740
|
selected: void 0,
|
|
1740
1741
|
modifiers: {
|
|
@@ -1744,156 +1745,156 @@ function Ma(e) {
|
|
|
1744
1745
|
disabled: []
|
|
1745
1746
|
}
|
|
1746
1747
|
};
|
|
1747
|
-
return
|
|
1748
|
+
return c(Oe.Provider, { value: t, children: e.children });
|
|
1748
1749
|
}
|
|
1749
|
-
return
|
|
1750
|
+
return c(xa, { initialProps: e.initialProps, children: e.children });
|
|
1750
1751
|
}
|
|
1751
|
-
function
|
|
1752
|
-
var t = e.initialProps, n = e.children, a = t.selected, r = a || {}, o = r.from, i = r.to, s = t.min,
|
|
1753
|
-
var w,
|
|
1754
|
-
(w = t.onDayClick) === null || w === void 0 || w.call(t, m, y,
|
|
1755
|
-
var p =
|
|
1756
|
-
(
|
|
1757
|
-
},
|
|
1752
|
+
function xa(e) {
|
|
1753
|
+
var t = e.initialProps, n = e.children, a = t.selected, r = a || {}, o = r.from, i = r.to, s = t.min, l = t.max, d = function(m, y, D) {
|
|
1754
|
+
var w, N;
|
|
1755
|
+
(w = t.onDayClick) === null || w === void 0 || w.call(t, m, y, D);
|
|
1756
|
+
var p = ka(m, a);
|
|
1757
|
+
(N = t.onSelect) === null || N === void 0 || N.call(t, p, m, y, D);
|
|
1758
|
+
}, u = {
|
|
1758
1759
|
range_start: [],
|
|
1759
1760
|
range_end: [],
|
|
1760
1761
|
range_middle: [],
|
|
1761
1762
|
disabled: []
|
|
1762
1763
|
};
|
|
1763
|
-
if (o ? (
|
|
1764
|
+
if (o ? (u.range_start = [o], i ? (u.range_end = [i], C(o, i) || (u.range_middle = [
|
|
1764
1765
|
{
|
|
1765
1766
|
after: o,
|
|
1766
1767
|
before: i
|
|
1767
1768
|
}
|
|
1768
|
-
])) :
|
|
1769
|
-
after:
|
|
1769
|
+
])) : u.range_end = [o]) : i && (u.range_start = [i], u.range_end = [i]), s && (o && !i && u.disabled.push({
|
|
1770
|
+
after: he(o, s - 1),
|
|
1770
1771
|
before: P(o, s - 1)
|
|
1771
|
-
}), o && i &&
|
|
1772
|
+
}), o && i && u.disabled.push({
|
|
1772
1773
|
after: o,
|
|
1773
1774
|
before: P(o, s - 1)
|
|
1774
|
-
}), !o && i &&
|
|
1775
|
-
after:
|
|
1775
|
+
}), !o && i && u.disabled.push({
|
|
1776
|
+
after: he(i, s - 1),
|
|
1776
1777
|
before: P(i, s - 1)
|
|
1777
|
-
})),
|
|
1778
|
-
if (o && !i && (
|
|
1779
|
-
before: P(o, -
|
|
1780
|
-
}),
|
|
1781
|
-
after: P(o,
|
|
1778
|
+
})), l) {
|
|
1779
|
+
if (o && !i && (u.disabled.push({
|
|
1780
|
+
before: P(o, -l + 1)
|
|
1781
|
+
}), u.disabled.push({
|
|
1782
|
+
after: P(o, l - 1)
|
|
1782
1783
|
})), o && i) {
|
|
1783
|
-
var f =
|
|
1784
|
-
|
|
1785
|
-
before:
|
|
1786
|
-
}),
|
|
1784
|
+
var f = L(i, o) + 1, h = l - f;
|
|
1785
|
+
u.disabled.push({
|
|
1786
|
+
before: he(o, h)
|
|
1787
|
+
}), u.disabled.push({
|
|
1787
1788
|
after: P(i, h)
|
|
1788
1789
|
});
|
|
1789
1790
|
}
|
|
1790
|
-
!o && i && (
|
|
1791
|
-
before: P(i, -
|
|
1792
|
-
}),
|
|
1793
|
-
after: P(i,
|
|
1791
|
+
!o && i && (u.disabled.push({
|
|
1792
|
+
before: P(i, -l + 1)
|
|
1793
|
+
}), u.disabled.push({
|
|
1794
|
+
after: P(i, l - 1)
|
|
1794
1795
|
}));
|
|
1795
1796
|
}
|
|
1796
|
-
return
|
|
1797
|
+
return c(Oe.Provider, { value: { selected: a, onDayClick: d, modifiers: u }, children: n });
|
|
1797
1798
|
}
|
|
1798
|
-
function
|
|
1799
|
-
var e =
|
|
1799
|
+
function Ce() {
|
|
1800
|
+
var e = Q(Oe);
|
|
1800
1801
|
if (!e)
|
|
1801
1802
|
throw new Error("useSelectRange must be used within a SelectRangeProvider");
|
|
1802
1803
|
return e;
|
|
1803
1804
|
}
|
|
1804
|
-
function
|
|
1805
|
-
return Array.isArray(e) ?
|
|
1805
|
+
function ae(e) {
|
|
1806
|
+
return Array.isArray(e) ? et([], e, !0) : e !== void 0 ? [e] : [];
|
|
1806
1807
|
}
|
|
1807
|
-
function
|
|
1808
|
+
function Pa(e) {
|
|
1808
1809
|
var t = {};
|
|
1809
1810
|
return Object.entries(e).forEach(function(n) {
|
|
1810
1811
|
var a = n[0], r = n[1];
|
|
1811
|
-
t[a] =
|
|
1812
|
+
t[a] = ae(r);
|
|
1812
1813
|
}), t;
|
|
1813
1814
|
}
|
|
1814
|
-
var
|
|
1815
|
+
var F;
|
|
1815
1816
|
(function(e) {
|
|
1816
1817
|
e.Outside = "outside", e.Disabled = "disabled", e.Selected = "selected", e.Hidden = "hidden", e.Today = "today", e.RangeStart = "range_start", e.RangeEnd = "range_end", e.RangeMiddle = "range_middle";
|
|
1817
|
-
})(
|
|
1818
|
-
var
|
|
1819
|
-
function
|
|
1820
|
-
var a, r = (a = {}, a[
|
|
1821
|
-
return e.fromDate && r[
|
|
1822
|
-
}
|
|
1823
|
-
var
|
|
1824
|
-
function
|
|
1825
|
-
var t =
|
|
1826
|
-
return
|
|
1827
|
-
}
|
|
1828
|
-
function
|
|
1829
|
-
var e =
|
|
1818
|
+
})(F || (F = {}));
|
|
1819
|
+
var Oa = F.Selected, R = F.Disabled, Ca = F.Hidden, Sa = F.Today, ve = F.RangeEnd, ye = F.RangeMiddle, be = F.RangeStart, Wa = F.Outside;
|
|
1820
|
+
function Ta(e, t, n) {
|
|
1821
|
+
var a, r = (a = {}, a[Oa] = ae(e.selected), a[R] = ae(e.disabled), a[Ca] = ae(e.hidden), a[Sa] = [e.today], a[ve] = [], a[ye] = [], a[be] = [], a[Wa] = [], a);
|
|
1822
|
+
return e.fromDate && r[R].push({ before: e.fromDate }), e.toDate && r[R].push({ after: e.toDate }), ee(e) ? r[R] = r[R].concat(t.modifiers[R]) : te(e) && (r[R] = r[R].concat(n.modifiers[R]), r[be] = n.modifiers[be], r[ye] = n.modifiers[ye], r[ve] = n.modifiers[ve]), r;
|
|
1823
|
+
}
|
|
1824
|
+
var ot = q(void 0);
|
|
1825
|
+
function Ya(e) {
|
|
1826
|
+
var t = k(), n = Pe(), a = Ce(), r = Ta(t, n, a), o = Pa(t.modifiers), i = b(b({}, r), o);
|
|
1827
|
+
return c(ot.Provider, { value: i, children: e.children });
|
|
1828
|
+
}
|
|
1829
|
+
function it() {
|
|
1830
|
+
var e = Q(ot);
|
|
1830
1831
|
if (!e)
|
|
1831
1832
|
throw new Error("useModifiers must be used within a ModifiersProvider");
|
|
1832
1833
|
return e;
|
|
1833
1834
|
}
|
|
1834
|
-
function
|
|
1835
|
+
function Fa(e) {
|
|
1835
1836
|
return !!(e && typeof e == "object" && "before" in e && "after" in e);
|
|
1836
1837
|
}
|
|
1837
|
-
function
|
|
1838
|
+
function La(e) {
|
|
1838
1839
|
return !!(e && typeof e == "object" && "from" in e);
|
|
1839
1840
|
}
|
|
1840
|
-
function
|
|
1841
|
+
function Ea(e) {
|
|
1841
1842
|
return !!(e && typeof e == "object" && "after" in e);
|
|
1842
1843
|
}
|
|
1843
|
-
function
|
|
1844
|
+
function Ia(e) {
|
|
1844
1845
|
return !!(e && typeof e == "object" && "before" in e);
|
|
1845
1846
|
}
|
|
1846
|
-
function
|
|
1847
|
+
function Ra(e) {
|
|
1847
1848
|
return !!(e && typeof e == "object" && "dayOfWeek" in e);
|
|
1848
1849
|
}
|
|
1849
|
-
function
|
|
1850
|
+
function Ba(e, t) {
|
|
1850
1851
|
var n, a = t.from, r = t.to;
|
|
1851
1852
|
if (a && r) {
|
|
1852
|
-
var o =
|
|
1853
|
+
var o = L(r, a) < 0;
|
|
1853
1854
|
o && (n = [r, a], a = n[0], r = n[1]);
|
|
1854
|
-
var i =
|
|
1855
|
+
var i = L(e, a) >= 0 && L(r, e) >= 0;
|
|
1855
1856
|
return i;
|
|
1856
1857
|
}
|
|
1857
|
-
return r ?
|
|
1858
|
+
return r ? C(r, e) : a ? C(a, e) : !1;
|
|
1858
1859
|
}
|
|
1859
|
-
function
|
|
1860
|
-
return
|
|
1860
|
+
function ja(e) {
|
|
1861
|
+
return Me(e);
|
|
1861
1862
|
}
|
|
1862
|
-
function
|
|
1863
|
-
return Array.isArray(e) && e.every(
|
|
1863
|
+
function Ha(e) {
|
|
1864
|
+
return Array.isArray(e) && e.every(Me);
|
|
1864
1865
|
}
|
|
1865
|
-
function
|
|
1866
|
+
function Aa(e, t) {
|
|
1866
1867
|
return t.some(function(n) {
|
|
1867
1868
|
if (typeof n == "boolean")
|
|
1868
1869
|
return n;
|
|
1869
|
-
if (
|
|
1870
|
-
return
|
|
1871
|
-
if (
|
|
1870
|
+
if (ja(n))
|
|
1871
|
+
return C(e, n);
|
|
1872
|
+
if (Ha(n))
|
|
1872
1873
|
return n.includes(e);
|
|
1873
|
-
if (Ta(n))
|
|
1874
|
-
return Ea(e, n);
|
|
1875
1874
|
if (La(n))
|
|
1875
|
+
return Ba(e, n);
|
|
1876
|
+
if (Ra(n))
|
|
1876
1877
|
return n.dayOfWeek.includes(e.getDay());
|
|
1877
|
-
if (
|
|
1878
|
-
var a =
|
|
1878
|
+
if (Fa(n)) {
|
|
1879
|
+
var a = L(n.before, e), r = L(n.after, e), o = a > 0, i = r < 0, s = pe(n.before, n.after);
|
|
1879
1880
|
return s ? i && o : o || i;
|
|
1880
1881
|
}
|
|
1881
|
-
return
|
|
1882
|
+
return Ea(n) ? L(e, n.after) > 0 : Ia(n) ? L(n.before, e) > 0 : typeof n == "function" ? n(e) : !1;
|
|
1882
1883
|
});
|
|
1883
1884
|
}
|
|
1884
|
-
function
|
|
1885
|
+
function Se(e, t, n) {
|
|
1885
1886
|
var a = Object.keys(t).reduce(function(o, i) {
|
|
1886
1887
|
var s = t[i];
|
|
1887
|
-
return
|
|
1888
|
+
return Aa(e, s) && o.push(i), o;
|
|
1888
1889
|
}, []), r = {};
|
|
1889
1890
|
return a.forEach(function(o) {
|
|
1890
1891
|
return r[o] = !0;
|
|
1891
|
-
}), n && !
|
|
1892
|
+
}), n && !Ne(e, n) && (r.outside = !0), r;
|
|
1892
1893
|
}
|
|
1893
|
-
function
|
|
1894
|
-
for (var n =
|
|
1895
|
-
var s =
|
|
1896
|
-
if (!
|
|
1894
|
+
function qa(e, t) {
|
|
1895
|
+
for (var n = S(e[0]), a = _e(e[e.length - 1]), r, o, i = n; i <= a; ) {
|
|
1896
|
+
var s = Se(i, t), l = !s.disabled && !s.hidden;
|
|
1897
|
+
if (!l) {
|
|
1897
1898
|
i = P(i, 1);
|
|
1898
1899
|
continue;
|
|
1899
1900
|
}
|
|
@@ -1903,53 +1904,53 @@ function Ha(e, t) {
|
|
|
1903
1904
|
}
|
|
1904
1905
|
return o || r;
|
|
1905
1906
|
}
|
|
1906
|
-
var
|
|
1907
|
-
function
|
|
1908
|
-
var n = t.moveBy, a = t.direction, r = t.context, o = t.modifiers, i = t.retry, s = i === void 0 ? { count: 0, lastFocused: e } : i,
|
|
1907
|
+
var Qa = 365;
|
|
1908
|
+
function st(e, t) {
|
|
1909
|
+
var n = t.moveBy, a = t.direction, r = t.context, o = t.modifiers, i = t.retry, s = i === void 0 ? { count: 0, lastFocused: e } : i, l = r.weekStartsOn, d = r.fromDate, u = r.toDate, f = r.locale, h = {
|
|
1909
1910
|
day: P,
|
|
1910
|
-
week:
|
|
1911
|
-
month:
|
|
1912
|
-
year:
|
|
1911
|
+
week: we,
|
|
1912
|
+
month: Y,
|
|
1913
|
+
year: Wt,
|
|
1913
1914
|
startOfWeek: function(w) {
|
|
1914
|
-
return r.ISOWeek ?
|
|
1915
|
+
return r.ISOWeek ? A(w) : I(w, { locale: f, weekStartsOn: l });
|
|
1915
1916
|
},
|
|
1916
1917
|
endOfWeek: function(w) {
|
|
1917
|
-
return r.ISOWeek ?
|
|
1918
|
+
return r.ISOWeek ? Ve(w) : ke(w, { locale: f, weekStartsOn: l });
|
|
1918
1919
|
}
|
|
1919
1920
|
}, m = h[n](e, a === "after" ? 1 : -1);
|
|
1920
|
-
a === "before" && d ? m =
|
|
1921
|
+
a === "before" && d ? m = Tt([d, m]) : a === "after" && u && (m = Yt([u, m]));
|
|
1921
1922
|
var y = !0;
|
|
1922
1923
|
if (o) {
|
|
1923
|
-
var
|
|
1924
|
-
y = !
|
|
1924
|
+
var D = Se(m, o);
|
|
1925
|
+
y = !D.disabled && !D.hidden;
|
|
1925
1926
|
}
|
|
1926
|
-
return y ? m : s.count >
|
|
1927
|
+
return y ? m : s.count > Qa ? s.lastFocused : st(m, {
|
|
1927
1928
|
moveBy: n,
|
|
1928
1929
|
direction: a,
|
|
1929
1930
|
context: r,
|
|
1930
1931
|
modifiers: o,
|
|
1931
|
-
retry:
|
|
1932
|
+
retry: b(b({}, s), { count: s.count + 1 })
|
|
1932
1933
|
});
|
|
1933
1934
|
}
|
|
1934
|
-
var
|
|
1935
|
-
function
|
|
1936
|
-
var t =
|
|
1937
|
-
|
|
1935
|
+
var lt = q(void 0);
|
|
1936
|
+
function Xa(e) {
|
|
1937
|
+
var t = ne(), n = it(), a = K(), r = a[0], o = a[1], i = K(), s = i[0], l = i[1], d = qa(t.displayMonths, n), u = r ?? (s && t.isDateDisplayed(s)) ? s : d, f = function() {
|
|
1938
|
+
l(r), o(void 0);
|
|
1938
1939
|
}, h = function(w) {
|
|
1939
1940
|
o(w);
|
|
1940
|
-
}, m =
|
|
1941
|
+
}, m = k(), y = function(w, N) {
|
|
1941
1942
|
if (r) {
|
|
1942
|
-
var p =
|
|
1943
|
+
var p = st(r, {
|
|
1943
1944
|
moveBy: w,
|
|
1944
|
-
direction:
|
|
1945
|
+
direction: N,
|
|
1945
1946
|
context: m,
|
|
1946
1947
|
modifiers: n
|
|
1947
1948
|
});
|
|
1948
|
-
|
|
1949
|
+
C(r, p) || (t.goToDate(p, r), h(p));
|
|
1949
1950
|
}
|
|
1950
|
-
},
|
|
1951
|
+
}, D = {
|
|
1951
1952
|
focusedDay: r,
|
|
1952
|
-
focusTarget:
|
|
1953
|
+
focusTarget: u,
|
|
1953
1954
|
blur: f,
|
|
1954
1955
|
focus: h,
|
|
1955
1956
|
focusDayAfter: function() {
|
|
@@ -1983,296 +1984,296 @@ function qa(e) {
|
|
|
1983
1984
|
return y("endOfWeek", "after");
|
|
1984
1985
|
}
|
|
1985
1986
|
};
|
|
1986
|
-
return
|
|
1987
|
+
return c(lt.Provider, { value: D, children: e.children });
|
|
1987
1988
|
}
|
|
1988
|
-
function
|
|
1989
|
-
var e =
|
|
1989
|
+
function We() {
|
|
1990
|
+
var e = Q(lt);
|
|
1990
1991
|
if (!e)
|
|
1991
1992
|
throw new Error("useFocusContext must be used within a FocusProvider");
|
|
1992
1993
|
return e;
|
|
1993
1994
|
}
|
|
1994
|
-
function
|
|
1995
|
-
var n =
|
|
1995
|
+
function Ga(e, t) {
|
|
1996
|
+
var n = it(), a = Se(e, n, t);
|
|
1996
1997
|
return a;
|
|
1997
1998
|
}
|
|
1998
|
-
var
|
|
1999
|
-
function
|
|
2000
|
-
if (!
|
|
1999
|
+
var Te = q(void 0);
|
|
2000
|
+
function Va(e) {
|
|
2001
|
+
if (!se(e.initialProps)) {
|
|
2001
2002
|
var t = {
|
|
2002
2003
|
selected: void 0
|
|
2003
2004
|
};
|
|
2004
|
-
return
|
|
2005
|
+
return c(Te.Provider, { value: t, children: e.children });
|
|
2005
2006
|
}
|
|
2006
|
-
return
|
|
2007
|
+
return c($a, { initialProps: e.initialProps, children: e.children });
|
|
2007
2008
|
}
|
|
2008
|
-
function
|
|
2009
|
+
function $a(e) {
|
|
2009
2010
|
var t = e.initialProps, n = e.children, a = function(o, i, s) {
|
|
2010
|
-
var
|
|
2011
|
-
if ((
|
|
2011
|
+
var l, d, u;
|
|
2012
|
+
if ((l = t.onDayClick) === null || l === void 0 || l.call(t, o, i, s), i.selected && !t.required) {
|
|
2012
2013
|
(d = t.onSelect) === null || d === void 0 || d.call(t, void 0, o, i, s);
|
|
2013
2014
|
return;
|
|
2014
2015
|
}
|
|
2015
|
-
(
|
|
2016
|
+
(u = t.onSelect) === null || u === void 0 || u.call(t, o, o, i, s);
|
|
2016
2017
|
}, r = {
|
|
2017
2018
|
selected: t.selected,
|
|
2018
2019
|
onDayClick: a
|
|
2019
2020
|
};
|
|
2020
|
-
return
|
|
2021
|
+
return c(Te.Provider, { value: r, children: n });
|
|
2021
2022
|
}
|
|
2022
|
-
function
|
|
2023
|
-
var e =
|
|
2023
|
+
function ut() {
|
|
2024
|
+
var e = Q(Te);
|
|
2024
2025
|
if (!e)
|
|
2025
2026
|
throw new Error("useSelectSingle must be used within a SelectSingleProvider");
|
|
2026
2027
|
return e;
|
|
2027
2028
|
}
|
|
2028
|
-
function
|
|
2029
|
-
var n =
|
|
2030
|
-
var v,
|
|
2031
|
-
|
|
2032
|
-
},
|
|
2029
|
+
function Ua(e, t) {
|
|
2030
|
+
var n = k(), a = ut(), r = Pe(), o = Ce(), i = We(), s = i.focusDayAfter, l = i.focusDayBefore, d = i.focusWeekAfter, u = i.focusWeekBefore, f = i.blur, h = i.focus, m = i.focusMonthBefore, y = i.focusMonthAfter, D = i.focusYearBefore, w = i.focusYearAfter, N = i.focusStartOfWeek, p = i.focusEndOfWeek, x = function(g) {
|
|
2031
|
+
var v, ue, ce, de;
|
|
2032
|
+
se(n) ? (v = a.onDayClick) === null || v === void 0 || v.call(a, e, t, g) : ee(n) ? (ue = r.onDayClick) === null || ue === void 0 || ue.call(r, e, t, g) : te(n) ? (ce = o.onDayClick) === null || ce === void 0 || ce.call(o, e, t, g) : (de = n.onDayClick) === null || de === void 0 || de.call(n, e, t, g);
|
|
2033
|
+
}, j = function(g) {
|
|
2033
2034
|
var v;
|
|
2034
|
-
h(e), (v = n.onDayFocus) === null || v === void 0 || v.call(n, e, t,
|
|
2035
|
-
},
|
|
2035
|
+
h(e), (v = n.onDayFocus) === null || v === void 0 || v.call(n, e, t, g);
|
|
2036
|
+
}, le = function(g) {
|
|
2036
2037
|
var v;
|
|
2037
|
-
f(), (v = n.onDayBlur) === null || v === void 0 || v.call(n, e, t,
|
|
2038
|
-
},
|
|
2038
|
+
f(), (v = n.onDayBlur) === null || v === void 0 || v.call(n, e, t, g);
|
|
2039
|
+
}, V = function(g) {
|
|
2039
2040
|
var v;
|
|
2040
|
-
(v = n.onDayMouseEnter) === null || v === void 0 || v.call(n, e, t,
|
|
2041
|
-
},
|
|
2041
|
+
(v = n.onDayMouseEnter) === null || v === void 0 || v.call(n, e, t, g);
|
|
2042
|
+
}, dt = function(g) {
|
|
2042
2043
|
var v;
|
|
2043
|
-
(v = n.onDayMouseLeave) === null || v === void 0 || v.call(n, e, t,
|
|
2044
|
-
},
|
|
2044
|
+
(v = n.onDayMouseLeave) === null || v === void 0 || v.call(n, e, t, g);
|
|
2045
|
+
}, ft = function(g) {
|
|
2045
2046
|
var v;
|
|
2046
|
-
(v = n.onDayPointerEnter) === null || v === void 0 || v.call(n, e, t,
|
|
2047
|
-
},
|
|
2047
|
+
(v = n.onDayPointerEnter) === null || v === void 0 || v.call(n, e, t, g);
|
|
2048
|
+
}, ht = function(g) {
|
|
2048
2049
|
var v;
|
|
2049
|
-
(v = n.onDayPointerLeave) === null || v === void 0 || v.call(n, e, t,
|
|
2050
|
-
},
|
|
2050
|
+
(v = n.onDayPointerLeave) === null || v === void 0 || v.call(n, e, t, g);
|
|
2051
|
+
}, mt = function(g) {
|
|
2051
2052
|
var v;
|
|
2052
|
-
(v = n.onDayTouchCancel) === null || v === void 0 || v.call(n, e, t,
|
|
2053
|
-
},
|
|
2053
|
+
(v = n.onDayTouchCancel) === null || v === void 0 || v.call(n, e, t, g);
|
|
2054
|
+
}, vt = function(g) {
|
|
2054
2055
|
var v;
|
|
2055
|
-
(v = n.onDayTouchEnd) === null || v === void 0 || v.call(n, e, t,
|
|
2056
|
-
},
|
|
2056
|
+
(v = n.onDayTouchEnd) === null || v === void 0 || v.call(n, e, t, g);
|
|
2057
|
+
}, yt = function(g) {
|
|
2057
2058
|
var v;
|
|
2058
|
-
(v = n.onDayTouchMove) === null || v === void 0 || v.call(n, e, t,
|
|
2059
|
-
},
|
|
2059
|
+
(v = n.onDayTouchMove) === null || v === void 0 || v.call(n, e, t, g);
|
|
2060
|
+
}, bt = function(g) {
|
|
2060
2061
|
var v;
|
|
2061
|
-
(v = n.onDayTouchStart) === null || v === void 0 || v.call(n, e, t,
|
|
2062
|
-
},
|
|
2062
|
+
(v = n.onDayTouchStart) === null || v === void 0 || v.call(n, e, t, g);
|
|
2063
|
+
}, gt = function(g) {
|
|
2063
2064
|
var v;
|
|
2064
|
-
(v = n.onDayKeyUp) === null || v === void 0 || v.call(n, e, t,
|
|
2065
|
-
},
|
|
2065
|
+
(v = n.onDayKeyUp) === null || v === void 0 || v.call(n, e, t, g);
|
|
2066
|
+
}, wt = function(g) {
|
|
2066
2067
|
var v;
|
|
2067
|
-
switch (
|
|
2068
|
+
switch (g.key) {
|
|
2068
2069
|
case "ArrowLeft":
|
|
2069
|
-
|
|
2070
|
+
g.preventDefault(), g.stopPropagation(), n.dir === "rtl" ? s() : l();
|
|
2070
2071
|
break;
|
|
2071
2072
|
case "ArrowRight":
|
|
2072
|
-
|
|
2073
|
+
g.preventDefault(), g.stopPropagation(), n.dir === "rtl" ? l() : s();
|
|
2073
2074
|
break;
|
|
2074
2075
|
case "ArrowDown":
|
|
2075
|
-
|
|
2076
|
+
g.preventDefault(), g.stopPropagation(), d();
|
|
2076
2077
|
break;
|
|
2077
2078
|
case "ArrowUp":
|
|
2078
|
-
|
|
2079
|
+
g.preventDefault(), g.stopPropagation(), u();
|
|
2079
2080
|
break;
|
|
2080
2081
|
case "PageUp":
|
|
2081
|
-
|
|
2082
|
+
g.preventDefault(), g.stopPropagation(), g.shiftKey ? D() : m();
|
|
2082
2083
|
break;
|
|
2083
2084
|
case "PageDown":
|
|
2084
|
-
|
|
2085
|
+
g.preventDefault(), g.stopPropagation(), g.shiftKey ? w() : y();
|
|
2085
2086
|
break;
|
|
2086
2087
|
case "Home":
|
|
2087
|
-
|
|
2088
|
+
g.preventDefault(), g.stopPropagation(), N();
|
|
2088
2089
|
break;
|
|
2089
2090
|
case "End":
|
|
2090
|
-
|
|
2091
|
+
g.preventDefault(), g.stopPropagation(), p();
|
|
2091
2092
|
break;
|
|
2092
2093
|
}
|
|
2093
|
-
(v = n.onDayKeyDown) === null || v === void 0 || v.call(n, e, t,
|
|
2094
|
-
},
|
|
2095
|
-
onClick:
|
|
2096
|
-
onFocus:
|
|
2097
|
-
onBlur:
|
|
2098
|
-
onKeyDown:
|
|
2099
|
-
onKeyUp:
|
|
2100
|
-
onMouseEnter:
|
|
2101
|
-
onMouseLeave:
|
|
2102
|
-
onPointerEnter:
|
|
2103
|
-
onPointerLeave:
|
|
2104
|
-
onTouchCancel:
|
|
2105
|
-
onTouchEnd:
|
|
2106
|
-
onTouchMove:
|
|
2107
|
-
onTouchStart:
|
|
2094
|
+
(v = n.onDayKeyDown) === null || v === void 0 || v.call(n, e, t, g);
|
|
2095
|
+
}, pt = {
|
|
2096
|
+
onClick: x,
|
|
2097
|
+
onFocus: j,
|
|
2098
|
+
onBlur: le,
|
|
2099
|
+
onKeyDown: wt,
|
|
2100
|
+
onKeyUp: gt,
|
|
2101
|
+
onMouseEnter: V,
|
|
2102
|
+
onMouseLeave: dt,
|
|
2103
|
+
onPointerEnter: ft,
|
|
2104
|
+
onPointerLeave: ht,
|
|
2105
|
+
onTouchCancel: mt,
|
|
2106
|
+
onTouchEnd: vt,
|
|
2107
|
+
onTouchMove: yt,
|
|
2108
|
+
onTouchStart: bt
|
|
2108
2109
|
};
|
|
2109
|
-
return
|
|
2110
|
+
return pt;
|
|
2110
2111
|
}
|
|
2111
|
-
function
|
|
2112
|
-
var e =
|
|
2112
|
+
function Ja() {
|
|
2113
|
+
var e = k(), t = ut(), n = Pe(), a = Ce(), r = se(e) ? t.selected : ee(e) ? n.selected : te(e) ? a.selected : void 0;
|
|
2113
2114
|
return r;
|
|
2114
2115
|
}
|
|
2115
|
-
function
|
|
2116
|
-
return Object.values(
|
|
2116
|
+
function Ka(e) {
|
|
2117
|
+
return Object.values(F).includes(e);
|
|
2117
2118
|
}
|
|
2118
|
-
function
|
|
2119
|
+
function za(e, t) {
|
|
2119
2120
|
var n = [e.classNames.day];
|
|
2120
2121
|
return Object.keys(t).forEach(function(a) {
|
|
2121
2122
|
var r = e.modifiersClassNames[a];
|
|
2122
2123
|
if (r)
|
|
2123
2124
|
n.push(r);
|
|
2124
|
-
else if (
|
|
2125
|
+
else if (Ka(a)) {
|
|
2125
2126
|
var o = e.classNames["day_".concat(a)];
|
|
2126
2127
|
o && n.push(o);
|
|
2127
2128
|
}
|
|
2128
2129
|
}), n;
|
|
2129
2130
|
}
|
|
2130
|
-
function
|
|
2131
|
-
var n =
|
|
2131
|
+
function Za(e, t) {
|
|
2132
|
+
var n = b({}, e.styles.day);
|
|
2132
2133
|
return Object.keys(t).forEach(function(a) {
|
|
2133
2134
|
var r;
|
|
2134
|
-
n =
|
|
2135
|
+
n = b(b({}, n), (r = e.modifiersStyles) === null || r === void 0 ? void 0 : r[a]);
|
|
2135
2136
|
}), n;
|
|
2136
2137
|
}
|
|
2137
|
-
function
|
|
2138
|
-
var a, r, o, i =
|
|
2139
|
-
|
|
2140
|
-
var
|
|
2141
|
-
|
|
2138
|
+
function er(e, t, n) {
|
|
2139
|
+
var a, r, o, i = k(), s = We(), l = Ga(e, t), d = Ua(e, l), u = Ja(), f = !!(i.onDayClick || i.mode !== "default");
|
|
2140
|
+
ie(function() {
|
|
2141
|
+
var V;
|
|
2142
|
+
l.outside || s.focusedDay && f && C(s.focusedDay, e) && ((V = n.current) === null || V === void 0 || V.focus());
|
|
2142
2143
|
}, [
|
|
2143
2144
|
s.focusedDay,
|
|
2144
2145
|
e,
|
|
2145
2146
|
n,
|
|
2146
2147
|
f,
|
|
2147
|
-
|
|
2148
|
+
l.outside
|
|
2148
2149
|
]);
|
|
2149
|
-
var h =
|
|
2150
|
+
var h = za(i, l).join(" "), m = Za(i, l), y = !!(l.outside && !i.showOutsideDays || l.hidden), D = (o = (r = i.components) === null || r === void 0 ? void 0 : r.DayContent) !== null && o !== void 0 ? o : Da, w = c(D, { date: e, displayMonth: t, activeModifiers: l }), N = {
|
|
2150
2151
|
style: m,
|
|
2151
2152
|
className: h,
|
|
2152
2153
|
children: w,
|
|
2153
2154
|
role: "gridcell"
|
|
2154
|
-
}, p = s.focusTarget &&
|
|
2155
|
+
}, p = s.focusTarget && C(s.focusTarget, e) && !l.outside, x = s.focusedDay && C(s.focusedDay, e), j = b(b(b({}, N), (a = { disabled: l.disabled, role: "gridcell" }, a["aria-selected"] = l.selected, a.tabIndex = x || p ? 0 : -1, a)), d), le = {
|
|
2155
2156
|
isButton: f,
|
|
2156
2157
|
isHidden: y,
|
|
2157
|
-
activeModifiers:
|
|
2158
|
-
selectedDays:
|
|
2159
|
-
buttonProps:
|
|
2160
|
-
divProps:
|
|
2158
|
+
activeModifiers: l,
|
|
2159
|
+
selectedDays: u,
|
|
2160
|
+
buttonProps: j,
|
|
2161
|
+
divProps: N
|
|
2161
2162
|
};
|
|
2162
|
-
return
|
|
2163
|
+
return le;
|
|
2163
2164
|
}
|
|
2164
|
-
function
|
|
2165
|
-
var t =
|
|
2166
|
-
return n.isHidden ?
|
|
2165
|
+
function tr(e) {
|
|
2166
|
+
var t = Pt(null), n = er(e.date, e.displayMonth, t);
|
|
2167
|
+
return n.isHidden ? c("div", { role: "gridcell" }) : n.isButton ? c(oe, b({ name: "day", ref: t }, n.buttonProps)) : c("div", b({}, n.divProps));
|
|
2167
2168
|
}
|
|
2168
|
-
function
|
|
2169
|
-
var t = e.number, n = e.dates, a =
|
|
2169
|
+
function nr(e) {
|
|
2170
|
+
var t = e.number, n = e.dates, a = k(), r = a.onWeekNumberClick, o = a.styles, i = a.classNames, s = a.locale, l = a.labels.labelWeekNumber, d = a.formatters.formatWeekNumber, u = d(Number(t), { locale: s });
|
|
2170
2171
|
if (!r)
|
|
2171
|
-
return
|
|
2172
|
-
var f =
|
|
2172
|
+
return c("span", { className: i.weeknumber, style: o.weeknumber, children: u });
|
|
2173
|
+
var f = l(Number(t), { locale: s }), h = function(m) {
|
|
2173
2174
|
r(t, n, m);
|
|
2174
2175
|
};
|
|
2175
|
-
return
|
|
2176
|
+
return c(oe, { name: "week-number", "aria-label": f, className: i.weeknumber, style: o.weeknumber, onClick: h, children: u });
|
|
2176
2177
|
}
|
|
2177
|
-
function
|
|
2178
|
-
var t, n, a =
|
|
2179
|
-
return i && (
|
|
2180
|
-
return
|
|
2178
|
+
function ar(e) {
|
|
2179
|
+
var t, n, a = k(), r = a.styles, o = a.classNames, i = a.showWeekNumber, s = a.components, l = (t = s == null ? void 0 : s.Day) !== null && t !== void 0 ? t : tr, d = (n = s == null ? void 0 : s.WeekNumber) !== null && n !== void 0 ? n : nr, u;
|
|
2180
|
+
return i && (u = c("td", { className: o.cell, style: r.cell, children: c(d, { number: e.weekNumber, dates: e.dates }) })), O("tr", { className: o.row, style: r.row, children: [u, e.dates.map(function(f) {
|
|
2181
|
+
return c("td", { className: o.cell, style: r.cell, role: "presentation", children: c(l, { displayMonth: e.displayMonth, date: f }) }, Yn(f));
|
|
2181
2182
|
})] });
|
|
2182
2183
|
}
|
|
2183
|
-
function
|
|
2184
|
-
for (var a = n != null && n.ISOWeek ?
|
|
2184
|
+
function qe(e, t, n) {
|
|
2185
|
+
for (var a = n != null && n.ISOWeek ? Ve(t) : ke(t, n), r = n != null && n.ISOWeek ? A(e) : I(e, n), o = L(a, r), i = [], s = 0; s <= o; s++)
|
|
2185
2186
|
i.push(P(r, s));
|
|
2186
|
-
var
|
|
2187
|
-
var f = n != null && n.ISOWeek ?
|
|
2187
|
+
var l = i.reduce(function(d, u) {
|
|
2188
|
+
var f = n != null && n.ISOWeek ? Ue(u) : Ke(u, n), h = d.find(function(m) {
|
|
2188
2189
|
return m.weekNumber === f;
|
|
2189
2190
|
});
|
|
2190
|
-
return h ? (h.dates.push(
|
|
2191
|
+
return h ? (h.dates.push(u), d) : (d.push({
|
|
2191
2192
|
weekNumber: f,
|
|
2192
|
-
dates: [
|
|
2193
|
+
dates: [u]
|
|
2193
2194
|
}), d);
|
|
2194
2195
|
}, []);
|
|
2195
|
-
return
|
|
2196
|
+
return l;
|
|
2196
2197
|
}
|
|
2197
|
-
function
|
|
2198
|
-
var n =
|
|
2198
|
+
function rr(e, t) {
|
|
2199
|
+
var n = qe(S(e), _e(e), t);
|
|
2199
2200
|
if (t != null && t.useFixedWeeks) {
|
|
2200
|
-
var a =
|
|
2201
|
+
var a = Ln(e, t);
|
|
2201
2202
|
if (a < 6) {
|
|
2202
|
-
var r = n[n.length - 1], o = r.dates[r.dates.length - 1], i =
|
|
2203
|
+
var r = n[n.length - 1], o = r.dates[r.dates.length - 1], i = we(o, 6 - a), s = qe(we(o, 1), i, t);
|
|
2203
2204
|
n.push.apply(n, s);
|
|
2204
2205
|
}
|
|
2205
2206
|
}
|
|
2206
2207
|
return n;
|
|
2207
2208
|
}
|
|
2208
|
-
function
|
|
2209
|
-
var t, n, a, r =
|
|
2209
|
+
function or(e) {
|
|
2210
|
+
var t, n, a, r = k(), o = r.locale, i = r.classNames, s = r.styles, l = r.hideHead, d = r.fixedWeeks, u = r.components, f = r.weekStartsOn, h = r.firstWeekContainsDate, m = r.ISOWeek, y = rr(e.displayMonth, {
|
|
2210
2211
|
useFixedWeeks: !!d,
|
|
2211
2212
|
ISOWeek: m,
|
|
2212
2213
|
locale: o,
|
|
2213
2214
|
weekStartsOn: f,
|
|
2214
2215
|
firstWeekContainsDate: h
|
|
2215
|
-
}),
|
|
2216
|
-
return
|
|
2217
|
-
return
|
|
2218
|
-
}) }),
|
|
2216
|
+
}), D = (t = u == null ? void 0 : u.Head) !== null && t !== void 0 ? t : pa, w = (n = u == null ? void 0 : u.Row) !== null && n !== void 0 ? n : ar, N = (a = u == null ? void 0 : u.Footer) !== null && a !== void 0 ? a : ba;
|
|
2217
|
+
return O("table", { id: e.id, className: i.table, style: s.table, role: "grid", "aria-labelledby": e["aria-labelledby"], children: [!l && c(D, {}), c("tbody", { className: i.tbody, style: s.tbody, children: y.map(function(p) {
|
|
2218
|
+
return c(w, { displayMonth: e.displayMonth, dates: p.dates, weekNumber: p.weekNumber }, p.weekNumber);
|
|
2219
|
+
}) }), c(N, { displayMonth: e.displayMonth })] });
|
|
2219
2220
|
}
|
|
2220
|
-
function
|
|
2221
|
+
function ir() {
|
|
2221
2222
|
return !!(typeof window < "u" && window.document && window.document.createElement);
|
|
2222
2223
|
}
|
|
2223
|
-
var
|
|
2224
|
-
function
|
|
2225
|
-
return "react-day-picker-".concat(++
|
|
2224
|
+
var sr = ir() ? xt : ie, ge = !1, lr = 0;
|
|
2225
|
+
function Qe() {
|
|
2226
|
+
return "react-day-picker-".concat(++lr);
|
|
2226
2227
|
}
|
|
2227
|
-
function
|
|
2228
|
-
var t, n = e ?? (
|
|
2229
|
-
return
|
|
2230
|
-
r === null && o(
|
|
2231
|
-
}, []),
|
|
2232
|
-
|
|
2228
|
+
function ur(e) {
|
|
2229
|
+
var t, n = e ?? (ge ? Qe() : null), a = K(n), r = a[0], o = a[1];
|
|
2230
|
+
return sr(function() {
|
|
2231
|
+
r === null && o(Qe());
|
|
2232
|
+
}, []), ie(function() {
|
|
2233
|
+
ge === !1 && (ge = !0);
|
|
2233
2234
|
}, []), (t = e ?? r) !== null && t !== void 0 ? t : void 0;
|
|
2234
2235
|
}
|
|
2235
|
-
function
|
|
2236
|
-
var t, n, a =
|
|
2237
|
-
r === "rtl" && (t = [m, y], y = t[0], m = t[1]), m && (f.push(o.caption_start), h =
|
|
2238
|
-
var w = (n = s == null ? void 0 : s.Caption) !== null && n !== void 0 ? n :
|
|
2239
|
-
return
|
|
2236
|
+
function cr(e) {
|
|
2237
|
+
var t, n, a = k(), r = a.dir, o = a.classNames, i = a.styles, s = a.components, l = ne().displayMonths, d = ur(a.id ? "".concat(a.id, "-").concat(e.displayIndex) : void 0), u = a.id ? "".concat(a.id, "-grid-").concat(e.displayIndex) : void 0, f = [o.month], h = i.month, m = e.displayIndex === 0, y = e.displayIndex === l.length - 1, D = !m && !y;
|
|
2238
|
+
r === "rtl" && (t = [m, y], y = t[0], m = t[1]), m && (f.push(o.caption_start), h = b(b({}, h), i.caption_start)), y && (f.push(o.caption_end), h = b(b({}, h), i.caption_end)), D && (f.push(o.caption_between), h = b(b({}, h), i.caption_between));
|
|
2239
|
+
var w = (n = s == null ? void 0 : s.Caption) !== null && n !== void 0 ? n : ya;
|
|
2240
|
+
return O("div", { className: f.join(" "), style: h, children: [c(w, { id: d, displayMonth: e.displayMonth, displayIndex: e.displayIndex }), c(or, { id: u, "aria-labelledby": d, displayMonth: e.displayMonth })] }, e.displayIndex);
|
|
2240
2241
|
}
|
|
2241
|
-
function
|
|
2242
|
-
var t =
|
|
2243
|
-
return
|
|
2242
|
+
function dr(e) {
|
|
2243
|
+
var t = k(), n = t.classNames, a = t.styles;
|
|
2244
|
+
return c("div", { className: n.months, style: a.months, children: e.children });
|
|
2244
2245
|
}
|
|
2245
|
-
function
|
|
2246
|
-
var t, n, a = e.initialProps, r =
|
|
2247
|
-
|
|
2248
|
-
r.initialFocus && o.focusTarget && (
|
|
2246
|
+
function fr(e) {
|
|
2247
|
+
var t, n, a = e.initialProps, r = k(), o = We(), i = ne(), s = K(!1), l = s[0], d = s[1];
|
|
2248
|
+
ie(function() {
|
|
2249
|
+
r.initialFocus && o.focusTarget && (l || (o.focus(o.focusTarget), d(!0)));
|
|
2249
2250
|
}, [
|
|
2250
2251
|
r.initialFocus,
|
|
2251
|
-
|
|
2252
|
+
l,
|
|
2252
2253
|
o.focus,
|
|
2253
2254
|
o.focusTarget,
|
|
2254
2255
|
o
|
|
2255
2256
|
]);
|
|
2256
|
-
var
|
|
2257
|
-
r.numberOfMonths > 1 &&
|
|
2258
|
-
var f =
|
|
2257
|
+
var u = [r.classNames.root, r.className];
|
|
2258
|
+
r.numberOfMonths > 1 && u.push(r.classNames.multiple_months), r.showWeekNumber && u.push(r.classNames.with_weeknumber);
|
|
2259
|
+
var f = b(b({}, r.styles.root), r.style), h = Object.keys(a).filter(function(y) {
|
|
2259
2260
|
return y.startsWith("data-");
|
|
2260
|
-
}).reduce(function(y,
|
|
2261
|
+
}).reduce(function(y, D) {
|
|
2261
2262
|
var w;
|
|
2262
|
-
return
|
|
2263
|
-
}, {}), m = (n = (t = a.components) === null || t === void 0 ? void 0 : t.Months) !== null && n !== void 0 ? n :
|
|
2264
|
-
return
|
|
2265
|
-
return
|
|
2263
|
+
return b(b({}, y), (w = {}, w[D] = a[D], w));
|
|
2264
|
+
}, {}), m = (n = (t = a.components) === null || t === void 0 ? void 0 : t.Months) !== null && n !== void 0 ? n : dr;
|
|
2265
|
+
return c("div", b({ className: u.join(" "), style: f, dir: r.dir, id: r.id, nonce: a.nonce, title: a.title, lang: a.lang }, h, { children: c(m, { children: i.displayMonths.map(function(y, D) {
|
|
2266
|
+
return c(cr, { displayIndex: D, displayMonth: y }, D);
|
|
2266
2267
|
}) }) }));
|
|
2267
2268
|
}
|
|
2268
|
-
function
|
|
2269
|
-
var t = e.children, n =
|
|
2270
|
-
return
|
|
2269
|
+
function hr(e) {
|
|
2270
|
+
var t = e.children, n = In(e, ["children"]);
|
|
2271
|
+
return c(na, { initialProps: n, children: c(fa, { children: c(Va, { initialProps: n, children: c(Ma, { initialProps: n, children: c(Na, { initialProps: n, children: c(Ya, { children: c(Xa, { children: t }) }) }) }) }) }) });
|
|
2271
2272
|
}
|
|
2272
|
-
function
|
|
2273
|
-
return
|
|
2273
|
+
function mr(e) {
|
|
2274
|
+
return c(hr, b({}, e, { children: c(fr, { initialProps: e }) }));
|
|
2274
2275
|
}
|
|
2275
|
-
function
|
|
2276
|
+
function ct({
|
|
2276
2277
|
className: e,
|
|
2277
2278
|
classNames: t,
|
|
2278
2279
|
fromDate: n,
|
|
@@ -2280,13 +2281,13 @@ function lt({
|
|
|
2280
2281
|
showOutsideDays: r = !0,
|
|
2281
2282
|
...o
|
|
2282
2283
|
}) {
|
|
2283
|
-
return /* @__PURE__ */
|
|
2284
|
-
|
|
2284
|
+
return /* @__PURE__ */ c(
|
|
2285
|
+
mr,
|
|
2285
2286
|
{
|
|
2286
2287
|
fromDate: n,
|
|
2287
2288
|
toDate: a || void 0,
|
|
2288
2289
|
showOutsideDays: r,
|
|
2289
|
-
className:
|
|
2290
|
+
className: J("p-3", e),
|
|
2290
2291
|
classNames: {
|
|
2291
2292
|
months: "flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",
|
|
2292
2293
|
month: "space-y-4",
|
|
@@ -2296,12 +2297,12 @@ function lt({
|
|
|
2296
2297
|
head: "",
|
|
2297
2298
|
head_row: "flex w-full items-center justify-between",
|
|
2298
2299
|
head_cell: "w-8 md:w-11 h-8 text-sm font-medium text-default",
|
|
2299
|
-
nav_button:
|
|
2300
|
+
nav_button: J(Ye({ color: "minimal", variant: "icon" })),
|
|
2300
2301
|
table: "w-full border-collapse space-y-1",
|
|
2301
2302
|
row: "flex w-full mt-2 gap-0.5",
|
|
2302
2303
|
cell: "h-8 w-8 md:h-11 md:w-11 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",
|
|
2303
|
-
day:
|
|
2304
|
-
|
|
2304
|
+
day: J(
|
|
2305
|
+
Ye({ color: "minimal" }),
|
|
2305
2306
|
"w-8 h-8 md:h-11 md:w-11 p-0 text-sm font-medium aria-selected:opacity-100 inline-flex items-center justify-center"
|
|
2306
2307
|
),
|
|
2307
2308
|
day_range_end: "hover:!bg-inverted hover:!text-inverted",
|
|
@@ -2315,22 +2316,22 @@ function lt({
|
|
|
2315
2316
|
...t
|
|
2316
2317
|
},
|
|
2317
2318
|
components: {
|
|
2318
|
-
CaptionLabel: (i) => /* @__PURE__ */
|
|
2319
|
-
/* @__PURE__ */
|
|
2320
|
-
|
|
2319
|
+
CaptionLabel: (i) => /* @__PURE__ */ O("div", { className: "px-2", children: [
|
|
2320
|
+
/* @__PURE__ */ O("span", { className: "text-emphasis font-semibold leading-none", children: [
|
|
2321
|
+
Fe(i.displayMonth).format("MMMM"),
|
|
2321
2322
|
" "
|
|
2322
2323
|
] }),
|
|
2323
|
-
/* @__PURE__ */
|
|
2324
|
+
/* @__PURE__ */ c("span", { className: "text-subtle font-medium leading-none", children: Fe(i.displayMonth).format("YYYY") })
|
|
2324
2325
|
] }),
|
|
2325
|
-
IconLeft: () => /* @__PURE__ */
|
|
2326
|
-
IconRight: () => /* @__PURE__ */
|
|
2326
|
+
IconLeft: () => /* @__PURE__ */ c(Le, { name: "chevron-left", className: "h-4 w-4 stroke-2" }),
|
|
2327
|
+
IconRight: () => /* @__PURE__ */ c(Le, { name: "chevron-right", className: "h-4 w-4 stroke-2" })
|
|
2327
2328
|
},
|
|
2328
2329
|
...o
|
|
2329
2330
|
}
|
|
2330
2331
|
);
|
|
2331
2332
|
}
|
|
2332
|
-
|
|
2333
|
-
function
|
|
2333
|
+
ct.displayName = "Calendar";
|
|
2334
|
+
function gr({
|
|
2334
2335
|
className: e,
|
|
2335
2336
|
dates: t,
|
|
2336
2337
|
minDate: n,
|
|
@@ -2339,7 +2340,7 @@ function vr({
|
|
|
2339
2340
|
disabled: o,
|
|
2340
2341
|
withoutPopover: i,
|
|
2341
2342
|
"data-testid": s,
|
|
2342
|
-
strictlyBottom:
|
|
2343
|
+
strictlyBottom: l
|
|
2343
2344
|
}) {
|
|
2344
2345
|
function d(h) {
|
|
2345
2346
|
if (t != null && t.endDate)
|
|
@@ -2349,11 +2350,11 @@ function vr({
|
|
|
2349
2350
|
r({ startDate: m, endDate: y });
|
|
2350
2351
|
}
|
|
2351
2352
|
}
|
|
2352
|
-
const
|
|
2353
|
-
|
|
2353
|
+
const f = /* @__PURE__ */ c(
|
|
2354
|
+
ct,
|
|
2354
2355
|
{
|
|
2355
2356
|
initialFocus: !0,
|
|
2356
|
-
fromDate: n === null ? void 0 :
|
|
2357
|
+
fromDate: n === null ? void 0 : n ?? /* @__PURE__ */ new Date(),
|
|
2357
2358
|
toDate: a,
|
|
2358
2359
|
mode: "range",
|
|
2359
2360
|
defaultMonth: t == null ? void 0 : t.startDate,
|
|
@@ -2364,37 +2365,37 @@ function vr({
|
|
|
2364
2365
|
"data-testid": s
|
|
2365
2366
|
}
|
|
2366
2367
|
);
|
|
2367
|
-
return i ? f : /* @__PURE__ */
|
|
2368
|
-
/* @__PURE__ */
|
|
2369
|
-
|
|
2368
|
+
return i ? f : /* @__PURE__ */ c("div", { className: J("grid gap-2", e), children: /* @__PURE__ */ O(Dt, { children: [
|
|
2369
|
+
/* @__PURE__ */ c(Mt, { asChild: !0, children: /* @__PURE__ */ c(
|
|
2370
|
+
_t,
|
|
2370
2371
|
{
|
|
2371
2372
|
"data-testid": "date-range",
|
|
2372
2373
|
color: "secondary",
|
|
2373
2374
|
EndIcon: "calendar",
|
|
2374
|
-
className:
|
|
2375
|
-
children: t != null && t.startDate ? t != null && t.endDate ? /* @__PURE__ */
|
|
2376
|
-
|
|
2375
|
+
className: J("justify-between text-left font-normal", !t && "text-subtle"),
|
|
2376
|
+
children: t != null && t.startDate ? t != null && t.endDate ? /* @__PURE__ */ O(T, { children: [
|
|
2377
|
+
E(t.startDate, "LLL dd, y"),
|
|
2377
2378
|
" - ",
|
|
2378
|
-
|
|
2379
|
-
] }) : /* @__PURE__ */
|
|
2380
|
-
|
|
2379
|
+
E(t.endDate, "LLL dd, y")
|
|
2380
|
+
] }) : /* @__PURE__ */ O(T, { children: [
|
|
2381
|
+
E(t.startDate, "LLL dd, y"),
|
|
2381
2382
|
" - End"
|
|
2382
|
-
] }) : /* @__PURE__ */
|
|
2383
|
+
] }) : /* @__PURE__ */ c("span", { children: "Pick a date" })
|
|
2383
2384
|
}
|
|
2384
2385
|
) }),
|
|
2385
|
-
/* @__PURE__ */
|
|
2386
|
-
|
|
2386
|
+
/* @__PURE__ */ c(
|
|
2387
|
+
kt,
|
|
2387
2388
|
{
|
|
2388
2389
|
className: "bg-default text-emphasis z-50 w-auto rounded-md border p-0 outline-none",
|
|
2389
2390
|
align: "start",
|
|
2390
2391
|
sideOffset: 4,
|
|
2391
|
-
side:
|
|
2392
|
-
avoidCollisions: !
|
|
2392
|
+
side: l ? "bottom" : void 0,
|
|
2393
|
+
avoidCollisions: !l,
|
|
2393
2394
|
children: f
|
|
2394
2395
|
}
|
|
2395
2396
|
)
|
|
2396
2397
|
] }) });
|
|
2397
2398
|
}
|
|
2398
2399
|
export {
|
|
2399
|
-
|
|
2400
|
+
gr as DatePickerWithRange
|
|
2400
2401
|
};
|