@react-aria/datepicker 3.2.1 → 3.4.0

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.
@@ -0,0 +1,1628 @@
1
+ import {createFocusManager as $cIPI0$createFocusManager, getFocusableTreeWalker as $cIPI0$getFocusableTreeWalker} from "@react-aria/focus";
2
+ import {useId as $cIPI0$useId, useDescription as $cIPI0$useDescription, filterDOMProps as $cIPI0$filterDOMProps, mergeProps as $cIPI0$mergeProps, isMac as $cIPI0$isMac, scrollIntoViewport as $cIPI0$scrollIntoViewport, getScrollParent as $cIPI0$getScrollParent, useEvent as $cIPI0$useEvent, useLayoutEffect as $cIPI0$useLayoutEffect, isIOS as $cIPI0$isIOS, useLabels as $cIPI0$useLabels} from "@react-aria/utils";
3
+ import $cIPI0$react, {useMemo as $cIPI0$useMemo, useRef as $cIPI0$useRef, useEffect as $cIPI0$useEffect} from "react";
4
+ import {useField as $cIPI0$useField} from "@react-aria/label";
5
+ import {useFocusWithin as $cIPI0$useFocusWithin, usePress as $cIPI0$usePress} from "@react-aria/interactions";
6
+ import {useLocalizedStringFormatter as $cIPI0$useLocalizedStringFormatter, useLocale as $cIPI0$useLocale, useDateFormatter as $cIPI0$useDateFormatter, useFilter as $cIPI0$useFilter} from "@react-aria/i18n";
7
+ import {toCalendar as $cIPI0$toCalendar, CalendarDate as $cIPI0$CalendarDate} from "@internationalized/date";
8
+ import {NumberParser as $cIPI0$NumberParser} from "@internationalized/number";
9
+ import {useSpinButton as $cIPI0$useSpinButton} from "@react-aria/spinbutton";
10
+ import {LocalizedStringDictionary as $cIPI0$LocalizedStringDictionary} from "@internationalized/string";
11
+
12
+ function $parcel$interopDefault(a) {
13
+ return a && a.__esModule ? a.default : a;
14
+ }
15
+ /*
16
+ * Copyright 2020 Adobe. All rights reserved.
17
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
18
+ * you may not use this file except in compliance with the License. You may obtain a copy
19
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
20
+ *
21
+ * Unless required by applicable law or agreed to in writing, software distributed under
22
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
23
+ * OF ANY KIND, either express or implied. See the License for the specific language
24
+ * governing permissions and limitations under the License.
25
+ */ /*
26
+ * Copyright 2020 Adobe. All rights reserved.
27
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
28
+ * you may not use this file except in compliance with the License. You may obtain a copy
29
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
30
+ *
31
+ * Unless required by applicable law or agreed to in writing, software distributed under
32
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
33
+ * OF ANY KIND, either express or implied. See the License for the specific language
34
+ * governing permissions and limitations under the License.
35
+ */
36
+
37
+ var $204383cf4f6b0d06$exports = {};
38
+ var $f23889fffbde9058$exports = {};
39
+ $f23889fffbde9058$exports = {
40
+ "calendar": `التقويم`,
41
+ "day": `يوم`,
42
+ "dayPeriod": `ص/م`,
43
+ "endDate": `تاريخ الانتهاء`,
44
+ "era": `العصر`,
45
+ "hour": `الساعات`,
46
+ "minute": `الدقائق`,
47
+ "month": `الشهر`,
48
+ "second": `الثواني`,
49
+ "selectedDateDescription": (args)=>`تاريخ محدد: ${args.date}`,
50
+ "selectedRangeDescription": (args)=>`المدى الزمني المحدد: ${args.startDate} إلى ${args.endDate}`,
51
+ "selectedTimeDescription": (args)=>`الوقت المحدد: ${args.time}`,
52
+ "startDate": `تاريخ البدء`,
53
+ "timeZoneName": `التوقيت`,
54
+ "weekday": `اليوم`,
55
+ "year": `السنة`
56
+ };
57
+
58
+
59
+ var $09d9badaa8903929$exports = {};
60
+ $09d9badaa8903929$exports = {
61
+ "calendar": `Календар`,
62
+ "day": `ден`,
63
+ "dayPeriod": `пр.об./сл.об.`,
64
+ "endDate": `Крайна дата`,
65
+ "era": `ера`,
66
+ "hour": `час`,
67
+ "minute": `минута`,
68
+ "month": `месец`,
69
+ "second": `секунда`,
70
+ "selectedDateDescription": (args)=>`Избрана дата: ${args.date}`,
71
+ "selectedRangeDescription": (args)=>`Избран диапазон: ${args.startDate} до ${args.endDate}`,
72
+ "selectedTimeDescription": (args)=>`Избрано време: ${args.time}`,
73
+ "startDate": `Начална дата`,
74
+ "timeZoneName": `часова зона`,
75
+ "weekday": `ден от седмицата`,
76
+ "year": `година`
77
+ };
78
+
79
+
80
+ var $151b77e0fd711730$exports = {};
81
+ $151b77e0fd711730$exports = {
82
+ "calendar": `Kalendář`,
83
+ "day": `den`,
84
+ "dayPeriod": `část dne`,
85
+ "endDate": `Konečné datum`,
86
+ "era": `letopočet`,
87
+ "hour": `hodina`,
88
+ "minute": `minuta`,
89
+ "month": `měsíc`,
90
+ "second": `sekunda`,
91
+ "selectedDateDescription": (args)=>`Vybrané datum: ${args.date}`,
92
+ "selectedRangeDescription": (args)=>`Vybrané období: ${args.startDate} až ${args.endDate}`,
93
+ "selectedTimeDescription": (args)=>`Vybraný čas: ${args.time}`,
94
+ "startDate": `Počáteční datum`,
95
+ "timeZoneName": `časové pásmo`,
96
+ "weekday": `den v týdnu`,
97
+ "year": `rok`
98
+ };
99
+
100
+
101
+ var $61915aa8630b90a2$exports = {};
102
+ $61915aa8630b90a2$exports = {
103
+ "calendar": `Kalender`,
104
+ "day": `dag`,
105
+ "dayPeriod": `AM/PM`,
106
+ "endDate": `Slutdato`,
107
+ "era": `æra`,
108
+ "hour": `time`,
109
+ "minute": `minut`,
110
+ "month": `måned`,
111
+ "second": `sekund`,
112
+ "selectedDateDescription": (args)=>`Valgt dato: ${args.date}`,
113
+ "selectedRangeDescription": (args)=>`Valgt interval: ${args.startDate} til ${args.endDate}`,
114
+ "selectedTimeDescription": (args)=>`Valgt tidspunkt: ${args.time}`,
115
+ "startDate": `Startdato`,
116
+ "timeZoneName": `tidszone`,
117
+ "weekday": `ugedag`,
118
+ "year": `år`
119
+ };
120
+
121
+
122
+ var $35cea00159787840$exports = {};
123
+ $35cea00159787840$exports = {
124
+ "calendar": `Kalender`,
125
+ "day": `Tag`,
126
+ "dayPeriod": `Tageshälfte`,
127
+ "endDate": `Enddatum`,
128
+ "era": `Epoche`,
129
+ "hour": `Stunde`,
130
+ "minute": `Minute`,
131
+ "month": `Monat`,
132
+ "second": `Sekunde`,
133
+ "selectedDateDescription": (args)=>`Ausgewähltes Datum: ${args.date}`,
134
+ "selectedRangeDescription": (args)=>`Ausgewählter Bereich: ${args.startDate} bis ${args.endDate}`,
135
+ "selectedTimeDescription": (args)=>`Ausgewählte Zeit: ${args.time}`,
136
+ "startDate": `Anfangsdatum`,
137
+ "timeZoneName": `Zeitzone`,
138
+ "weekday": `Wochentag`,
139
+ "year": `Jahr`
140
+ };
141
+
142
+
143
+ var $518b4e82b9eacafd$exports = {};
144
+ $518b4e82b9eacafd$exports = {
145
+ "calendar": `Ημερολόγιο`,
146
+ "day": `ημέρα`,
147
+ "dayPeriod": `π.μ./μ.μ.`,
148
+ "endDate": `Ημερομηνία λήξης`,
149
+ "era": `περίοδος`,
150
+ "hour": `ώρα`,
151
+ "minute": `λεπτό`,
152
+ "month": `μήνας`,
153
+ "second": `δευτερόλεπτο`,
154
+ "selectedDateDescription": (args)=>`Επιλεγμένη ημερομηνία: ${args.date}`,
155
+ "selectedRangeDescription": (args)=>`Επιλεγμένο εύρος: ${args.startDate} έως ${args.endDate}`,
156
+ "selectedTimeDescription": (args)=>`Επιλεγμένη ώρα: ${args.time}`,
157
+ "startDate": `Ημερομηνία έναρξης`,
158
+ "timeZoneName": `ζώνη ώρας`,
159
+ "weekday": `καθημερινή`,
160
+ "year": `έτος`
161
+ };
162
+
163
+
164
+ var $1c2b297f7e2cf474$exports = {};
165
+ $1c2b297f7e2cf474$exports = {
166
+ "era": `era`,
167
+ "year": `year`,
168
+ "month": `month`,
169
+ "day": `day`,
170
+ "hour": `hour`,
171
+ "minute": `minute`,
172
+ "second": `second`,
173
+ "dayPeriod": `AM/PM`,
174
+ "calendar": `Calendar`,
175
+ "startDate": `Start Date`,
176
+ "endDate": `End Date`,
177
+ "weekday": `day of the week`,
178
+ "timeZoneName": `time zone`,
179
+ "selectedDateDescription": (args)=>`Selected Date: ${args.date}`,
180
+ "selectedRangeDescription": (args)=>`Selected Range: ${args.startDate} to ${args.endDate}`,
181
+ "selectedTimeDescription": (args)=>`Selected Time: ${args.time}`
182
+ };
183
+
184
+
185
+ var $07f628a707cf9b18$exports = {};
186
+ $07f628a707cf9b18$exports = {
187
+ "calendar": `Calendario`,
188
+ "day": `día`,
189
+ "dayPeriod": `a. m./p. m.`,
190
+ "endDate": `Fecha final`,
191
+ "era": `era`,
192
+ "hour": `hora`,
193
+ "minute": `minuto`,
194
+ "month": `mes`,
195
+ "second": `segundo`,
196
+ "selectedDateDescription": (args)=>`Fecha seleccionada: ${args.date}`,
197
+ "selectedRangeDescription": (args)=>`Rango seleccionado: ${args.startDate} a ${args.endDate}`,
198
+ "selectedTimeDescription": (args)=>`Hora seleccionada: ${args.time}`,
199
+ "startDate": `Fecha de inicio`,
200
+ "timeZoneName": `zona horaria`,
201
+ "weekday": `día de la semana`,
202
+ "year": `año`
203
+ };
204
+
205
+
206
+ var $db553ffe17c7f4db$exports = {};
207
+ $db553ffe17c7f4db$exports = {
208
+ "calendar": `Kalender`,
209
+ "day": `päev`,
210
+ "dayPeriod": `enne/pärast lõunat`,
211
+ "endDate": `Lõppkuupäev`,
212
+ "era": `ajastu`,
213
+ "hour": `tund`,
214
+ "minute": `minut`,
215
+ "month": `kuu`,
216
+ "second": `sekund`,
217
+ "selectedDateDescription": (args)=>`Valitud kuupäev: ${args.date}`,
218
+ "selectedRangeDescription": (args)=>`Valitud vahemik: ${args.startDate} kuni ${args.endDate}`,
219
+ "selectedTimeDescription": (args)=>`Valitud aeg: ${args.time}`,
220
+ "startDate": `Alguskuupäev`,
221
+ "timeZoneName": `ajavöönd`,
222
+ "weekday": `nädalapäev`,
223
+ "year": `aasta`
224
+ };
225
+
226
+
227
+ var $4afcfe00cd703f83$exports = {};
228
+ $4afcfe00cd703f83$exports = {
229
+ "calendar": `Kalenteri`,
230
+ "day": `päivä`,
231
+ "dayPeriod": `vuorokaudenaika`,
232
+ "endDate": `Päättymispäivä`,
233
+ "era": `aikakausi`,
234
+ "hour": `tunti`,
235
+ "minute": `minuutti`,
236
+ "month": `kuukausi`,
237
+ "second": `sekunti`,
238
+ "selectedDateDescription": (args)=>`Valittu päivämäärä: ${args.date}`,
239
+ "selectedRangeDescription": (args)=>`Valittu aikaväli: ${args.startDate} – ${args.endDate}`,
240
+ "selectedTimeDescription": (args)=>`Valittu aika: ${args.time}`,
241
+ "startDate": `Alkamispäivä`,
242
+ "timeZoneName": `aikavyöhyke`,
243
+ "weekday": `viikonpäivä`,
244
+ "year": `vuosi`
245
+ };
246
+
247
+
248
+ var $1d2645d18d4c5be0$exports = {};
249
+ $1d2645d18d4c5be0$exports = {
250
+ "calendar": `Calendrier`,
251
+ "day": `jour`,
252
+ "dayPeriod": `cadran`,
253
+ "endDate": `Date de fin`,
254
+ "era": `ère`,
255
+ "hour": `heure`,
256
+ "minute": `minute`,
257
+ "month": `mois`,
258
+ "second": `seconde`,
259
+ "selectedDateDescription": (args)=>`Date sélectionnée : ${args.date}`,
260
+ "selectedRangeDescription": (args)=>`Plage sélectionnée : ${args.startDate} au ${args.endDate}`,
261
+ "selectedTimeDescription": (args)=>`Heure choisie : ${args.time}`,
262
+ "startDate": `Date de début`,
263
+ "timeZoneName": `fuseau horaire`,
264
+ "weekday": `jour de la semaine`,
265
+ "year": `année`
266
+ };
267
+
268
+
269
+ var $64cb6a9be1f6fa48$exports = {};
270
+ $64cb6a9be1f6fa48$exports = {
271
+ "calendar": `לוח שנה`,
272
+ "day": `יום`,
273
+ "dayPeriod": `לפנה״צ/אחה״צ`,
274
+ "endDate": `תאריך סיום`,
275
+ "era": `תקופה`,
276
+ "hour": `שעה`,
277
+ "minute": `דקה`,
278
+ "month": `חודש`,
279
+ "second": `שנייה`,
280
+ "selectedDateDescription": (args)=>`תאריך נבחר: ${args.date}`,
281
+ "selectedRangeDescription": (args)=>`טווח נבחר: ${args.startDate} עד ${args.endDate}`,
282
+ "selectedTimeDescription": (args)=>`זמן נבחר: ${args.time}`,
283
+ "startDate": `תאריך התחלה`,
284
+ "timeZoneName": `אזור זמן`,
285
+ "weekday": `יום בשבוע`,
286
+ "year": `שנה`
287
+ };
288
+
289
+
290
+ var $2a1ef2e8050be27a$exports = {};
291
+ $2a1ef2e8050be27a$exports = {
292
+ "calendar": `Kalendar`,
293
+ "day": `dan`,
294
+ "dayPeriod": `AM/PM`,
295
+ "endDate": `Datum završetka`,
296
+ "era": `era`,
297
+ "hour": `sat`,
298
+ "minute": `minuta`,
299
+ "month": `mjesec`,
300
+ "second": `sekunda`,
301
+ "selectedDateDescription": (args)=>`Odabrani datum: ${args.date}`,
302
+ "selectedRangeDescription": (args)=>`Odabrani raspon: ${args.startDate} do ${args.endDate}`,
303
+ "selectedTimeDescription": (args)=>`Odabrano vrijeme: ${args.time}`,
304
+ "startDate": `Datum početka`,
305
+ "timeZoneName": `vremenska zona`,
306
+ "weekday": `dan u tjednu`,
307
+ "year": `godina`
308
+ };
309
+
310
+
311
+ var $ad429dca102acd0e$exports = {};
312
+ $ad429dca102acd0e$exports = {
313
+ "calendar": `Naptár`,
314
+ "day": `nap`,
315
+ "dayPeriod": `napszak`,
316
+ "endDate": `Befejező dátum`,
317
+ "era": `éra`,
318
+ "hour": `óra`,
319
+ "minute": `perc`,
320
+ "month": `hónap`,
321
+ "second": `másodperc`,
322
+ "selectedDateDescription": (args)=>`Kijelölt dátum: ${args.date}`,
323
+ "selectedRangeDescription": (args)=>`Kijelölt tartomány: ${args.startDate}–${args.endDate}`,
324
+ "selectedTimeDescription": (args)=>`Kijelölt idő: ${args.time}`,
325
+ "startDate": `Kezdő dátum`,
326
+ "timeZoneName": `időzóna`,
327
+ "weekday": `hét napja`,
328
+ "year": `év`
329
+ };
330
+
331
+
332
+ var $6e68cb5d1cb97bd2$exports = {};
333
+ $6e68cb5d1cb97bd2$exports = {
334
+ "calendar": `Calendario`,
335
+ "day": `giorno`,
336
+ "dayPeriod": `AM/PM`,
337
+ "endDate": `Data finale`,
338
+ "era": `era`,
339
+ "hour": `ora`,
340
+ "minute": `minuto`,
341
+ "month": `mese`,
342
+ "second": `secondo`,
343
+ "selectedDateDescription": (args)=>`Data selezionata: ${args.date}`,
344
+ "selectedRangeDescription": (args)=>`Intervallo selezionato: da ${args.startDate} a ${args.endDate}`,
345
+ "selectedTimeDescription": (args)=>`Ora selezionata: ${args.time}`,
346
+ "startDate": `Data iniziale`,
347
+ "timeZoneName": `fuso orario`,
348
+ "weekday": `giorno della settimana`,
349
+ "year": `anno`
350
+ };
351
+
352
+
353
+ var $a82ee9af063ee069$exports = {};
354
+ $a82ee9af063ee069$exports = {
355
+ "calendar": `カレンダー`,
356
+ "day": `日`,
357
+ "dayPeriod": `午前/午後`,
358
+ "endDate": `終了日`,
359
+ "era": `時代`,
360
+ "hour": `時`,
361
+ "minute": `分`,
362
+ "month": `月`,
363
+ "second": `秒`,
364
+ "selectedDateDescription": (args)=>`選択した日付 : ${args.date}`,
365
+ "selectedRangeDescription": (args)=>`選択範囲 : ${args.startDate} から ${args.endDate}`,
366
+ "selectedTimeDescription": (args)=>`選択した時間 : ${args.time}`,
367
+ "startDate": `開始日`,
368
+ "timeZoneName": `タイムゾーン`,
369
+ "weekday": `曜日`,
370
+ "year": `年`
371
+ };
372
+
373
+
374
+ var $67e9091dbf37d4eb$exports = {};
375
+ $67e9091dbf37d4eb$exports = {
376
+ "calendar": `달력`,
377
+ "day": `일`,
378
+ "dayPeriod": `오전/오후`,
379
+ "endDate": `종료 날짜`,
380
+ "era": `연호`,
381
+ "hour": `시`,
382
+ "minute": `분`,
383
+ "month": `월`,
384
+ "second": `초`,
385
+ "selectedDateDescription": (args)=>`선택 일자: ${args.date}`,
386
+ "selectedRangeDescription": (args)=>`선택 범위: ${args.startDate} ~ ${args.endDate}`,
387
+ "selectedTimeDescription": (args)=>`선택 시간: ${args.time}`,
388
+ "startDate": `시작 날짜`,
389
+ "timeZoneName": `시간대`,
390
+ "weekday": `요일`,
391
+ "year": `년`
392
+ };
393
+
394
+
395
+ var $75834f9729f653d1$exports = {};
396
+ $75834f9729f653d1$exports = {
397
+ "calendar": `Kalendorius`,
398
+ "day": `diena`,
399
+ "dayPeriod": `iki pietų / po pietų`,
400
+ "endDate": `Pabaigos data`,
401
+ "era": `era`,
402
+ "hour": `valanda`,
403
+ "minute": `minutė`,
404
+ "month": `mėnuo`,
405
+ "second": `sekundė`,
406
+ "selectedDateDescription": (args)=>`Pasirinkta data: ${args.date}`,
407
+ "selectedRangeDescription": (args)=>`Pasirinktas intervalas: nuo ${args.startDate} iki ${args.endDate}`,
408
+ "selectedTimeDescription": (args)=>`Pasirinktas laikas: ${args.time}`,
409
+ "startDate": `Pradžios data`,
410
+ "timeZoneName": `laiko juosta`,
411
+ "weekday": `savaitės diena`,
412
+ "year": `metai`
413
+ };
414
+
415
+
416
+ var $a2df2c2520b4a7f0$exports = {};
417
+ $a2df2c2520b4a7f0$exports = {
418
+ "calendar": `Kalendārs`,
419
+ "day": `diena`,
420
+ "dayPeriod": `priekšpusdienā/pēcpusdienā`,
421
+ "endDate": `Beigu datums`,
422
+ "era": `ēra`,
423
+ "hour": `stundas`,
424
+ "minute": `minūtes`,
425
+ "month": `mēnesis`,
426
+ "second": `sekundes`,
427
+ "selectedDateDescription": (args)=>`Atlasītais datums: ${args.date}`,
428
+ "selectedRangeDescription": (args)=>`Atlasītais diapazons: no ${args.startDate} līdz ${args.endDate}`,
429
+ "selectedTimeDescription": (args)=>`Atlasītais laiks: ${args.time}`,
430
+ "startDate": `Sākuma datums`,
431
+ "timeZoneName": `laika josla`,
432
+ "weekday": `nedēļas diena`,
433
+ "year": `gads`
434
+ };
435
+
436
+
437
+ var $aedcd71db4933ed5$exports = {};
438
+ $aedcd71db4933ed5$exports = {
439
+ "calendar": `Kalender`,
440
+ "day": `dag`,
441
+ "dayPeriod": `a.m./p.m.`,
442
+ "endDate": `Sluttdato`,
443
+ "era": `tidsalder`,
444
+ "hour": `time`,
445
+ "minute": `minutt`,
446
+ "month": `måned`,
447
+ "second": `sekund`,
448
+ "selectedDateDescription": (args)=>`Valgt dato: ${args.date}`,
449
+ "selectedRangeDescription": (args)=>`Valgt område: ${args.startDate} til ${args.endDate}`,
450
+ "selectedTimeDescription": (args)=>`Valgt tid: ${args.time}`,
451
+ "startDate": `Startdato`,
452
+ "timeZoneName": `tidssone`,
453
+ "weekday": `ukedag`,
454
+ "year": `år`
455
+ };
456
+
457
+
458
+ var $3b2df9e54353046c$exports = {};
459
+ $3b2df9e54353046c$exports = {
460
+ "calendar": `Kalender`,
461
+ "day": `dag`,
462
+ "dayPeriod": `a.m./p.m.`,
463
+ "endDate": `Einddatum`,
464
+ "era": `tijdperk`,
465
+ "hour": `uur`,
466
+ "minute": `minuut`,
467
+ "month": `maand`,
468
+ "second": `seconde`,
469
+ "selectedDateDescription": (args)=>`Geselecteerde datum: ${args.date}`,
470
+ "selectedRangeDescription": (args)=>`Geselecteerd bereik: ${args.startDate} tot ${args.endDate}`,
471
+ "selectedTimeDescription": (args)=>`Geselecteerde tijd: ${args.time}`,
472
+ "startDate": `Startdatum`,
473
+ "timeZoneName": `tijdzone`,
474
+ "weekday": `dag van de week`,
475
+ "year": `jaar`
476
+ };
477
+
478
+
479
+ var $c03fe977fcfafe93$exports = {};
480
+ $c03fe977fcfafe93$exports = {
481
+ "calendar": `Kalendarz`,
482
+ "day": `dzień`,
483
+ "dayPeriod": `rano / po południu / wieczorem`,
484
+ "endDate": `Data końcowa`,
485
+ "era": `era`,
486
+ "hour": `godzina`,
487
+ "minute": `minuta`,
488
+ "month": `miesiąc`,
489
+ "second": `sekunda`,
490
+ "selectedDateDescription": (args)=>`Wybrana data: ${args.date}`,
491
+ "selectedRangeDescription": (args)=>`Wybrany zakres: ${args.startDate} do ${args.endDate}`,
492
+ "selectedTimeDescription": (args)=>`Wybrany czas: ${args.time}`,
493
+ "startDate": `Data początkowa`,
494
+ "timeZoneName": `strefa czasowa`,
495
+ "weekday": `dzień tygodnia`,
496
+ "year": `rok`
497
+ };
498
+
499
+
500
+ var $569f006fc292345f$exports = {};
501
+ $569f006fc292345f$exports = {
502
+ "calendar": `Calendário`,
503
+ "day": `dia`,
504
+ "dayPeriod": `AM/PM`,
505
+ "endDate": `Data final`,
506
+ "era": `era`,
507
+ "hour": `hora`,
508
+ "minute": `minuto`,
509
+ "month": `mês`,
510
+ "second": `segundo`,
511
+ "selectedDateDescription": (args)=>`Data selecionada: ${args.date}`,
512
+ "selectedRangeDescription": (args)=>`Intervalo selecionado: ${args.startDate} a ${args.endDate}`,
513
+ "selectedTimeDescription": (args)=>`Hora selecionada: ${args.time}`,
514
+ "startDate": `Data inicial`,
515
+ "timeZoneName": `fuso horário`,
516
+ "weekday": `dia da semana`,
517
+ "year": `ano`
518
+ };
519
+
520
+
521
+ var $7c2494e14452f2dd$exports = {};
522
+ $7c2494e14452f2dd$exports = {
523
+ "calendar": `Calendário`,
524
+ "day": `dia`,
525
+ "dayPeriod": `am/pm`,
526
+ "endDate": `Data de Término`,
527
+ "era": `era`,
528
+ "hour": `hora`,
529
+ "minute": `minuto`,
530
+ "month": `mês`,
531
+ "second": `segundo`,
532
+ "selectedDateDescription": (args)=>`Data selecionada: ${args.date}`,
533
+ "selectedRangeDescription": (args)=>`Intervalo selecionado: ${args.startDate} a ${args.endDate}`,
534
+ "selectedTimeDescription": (args)=>`Hora selecionada: ${args.time}`,
535
+ "startDate": `Data de Início`,
536
+ "timeZoneName": `fuso horário`,
537
+ "weekday": `dia da semana`,
538
+ "year": `ano`
539
+ };
540
+
541
+
542
+ var $eb82ef981b5592bf$exports = {};
543
+ $eb82ef981b5592bf$exports = {
544
+ "calendar": `Calendar`,
545
+ "day": `zi`,
546
+ "dayPeriod": `a.m/p.m.`,
547
+ "endDate": `Dată final`,
548
+ "era": `eră`,
549
+ "hour": `oră`,
550
+ "minute": `minut`,
551
+ "month": `lună`,
552
+ "second": `secundă`,
553
+ "selectedDateDescription": (args)=>`Dată selectată: ${args.date}`,
554
+ "selectedRangeDescription": (args)=>`Interval selectat: de la ${args.startDate} până la ${args.endDate}`,
555
+ "selectedTimeDescription": (args)=>`Ora selectată: ${args.time}`,
556
+ "startDate": `Dată început`,
557
+ "timeZoneName": `fus orar`,
558
+ "weekday": `ziua din săptămână`,
559
+ "year": `an`
560
+ };
561
+
562
+
563
+ var $6efa0e119f396950$exports = {};
564
+ $6efa0e119f396950$exports = {
565
+ "calendar": `Календарь`,
566
+ "day": `день`,
567
+ "dayPeriod": `AM/PM`,
568
+ "endDate": `Дата окончания`,
569
+ "era": `эра`,
570
+ "hour": `час`,
571
+ "minute": `минута`,
572
+ "month": `месяц`,
573
+ "second": `секунда`,
574
+ "selectedDateDescription": (args)=>`Выбранная дата: ${args.date}`,
575
+ "selectedRangeDescription": (args)=>`Выбранный диапазон: с ${args.startDate} по ${args.endDate}`,
576
+ "selectedTimeDescription": (args)=>`Выбранное время: ${args.time}`,
577
+ "startDate": `Дата начала`,
578
+ "timeZoneName": `часовой пояс`,
579
+ "weekday": `день недели`,
580
+ "year": `год`
581
+ };
582
+
583
+
584
+ var $7f5e57085d7f5049$exports = {};
585
+ $7f5e57085d7f5049$exports = {
586
+ "calendar": `Kalendár`,
587
+ "day": `deň`,
588
+ "dayPeriod": `AM/PM`,
589
+ "endDate": `Dátum ukončenia`,
590
+ "era": `letopočet`,
591
+ "hour": `hodina`,
592
+ "minute": `minúta`,
593
+ "month": `mesiac`,
594
+ "second": `sekunda`,
595
+ "selectedDateDescription": (args)=>`Vybratý dátum: ${args.date}`,
596
+ "selectedRangeDescription": (args)=>`Vybratý rozsah: od ${args.startDate} do ${args.endDate}`,
597
+ "selectedTimeDescription": (args)=>`Vybratý čas: ${args.time}`,
598
+ "startDate": `Dátum začatia`,
599
+ "timeZoneName": `časové pásmo`,
600
+ "weekday": `deň týždňa`,
601
+ "year": `rok`
602
+ };
603
+
604
+
605
+ var $578ee7c11dcdde7a$exports = {};
606
+ $578ee7c11dcdde7a$exports = {
607
+ "calendar": `Koledar`,
608
+ "day": `dan`,
609
+ "dayPeriod": `dop/pop`,
610
+ "endDate": `Datum konca`,
611
+ "era": `doba`,
612
+ "hour": `ura`,
613
+ "minute": `minuta`,
614
+ "month": `mesec`,
615
+ "second": `sekunda`,
616
+ "selectedDateDescription": (args)=>`Izbrani datum: ${args.date}`,
617
+ "selectedRangeDescription": (args)=>`Izbrano območje: ${args.startDate} do ${args.endDate}`,
618
+ "selectedTimeDescription": (args)=>`Izbrani čas: ${args.time}`,
619
+ "startDate": `Datum začetka`,
620
+ "timeZoneName": `časovni pas`,
621
+ "weekday": `dan v tednu`,
622
+ "year": `leto`
623
+ };
624
+
625
+
626
+ var $bbc3fd6cd0bc9d50$exports = {};
627
+ $bbc3fd6cd0bc9d50$exports = {
628
+ "calendar": `Kalendar`,
629
+ "day": `дан`,
630
+ "dayPeriod": `пре подне/по подне`,
631
+ "endDate": `Datum završetka`,
632
+ "era": `ера`,
633
+ "hour": `сат`,
634
+ "minute": `минут`,
635
+ "month": `месец`,
636
+ "second": `секунд`,
637
+ "selectedDateDescription": (args)=>`Izabrani datum: ${args.date}`,
638
+ "selectedRangeDescription": (args)=>`Izabrani opseg: od ${args.startDate} do ${args.endDate}`,
639
+ "selectedTimeDescription": (args)=>`Izabrano vreme: ${args.time}`,
640
+ "startDate": `Datum početka`,
641
+ "timeZoneName": `временска зона`,
642
+ "weekday": `дан у недељи`,
643
+ "year": `година`
644
+ };
645
+
646
+
647
+ var $0b04512118591d2a$exports = {};
648
+ $0b04512118591d2a$exports = {
649
+ "calendar": `Kalender`,
650
+ "day": `dag`,
651
+ "dayPeriod": `fm/em`,
652
+ "endDate": `Slutdatum`,
653
+ "era": `era`,
654
+ "hour": `timme`,
655
+ "minute": `minut`,
656
+ "month": `månad`,
657
+ "second": `sekund`,
658
+ "selectedDateDescription": (args)=>`Valt datum: ${args.date}`,
659
+ "selectedRangeDescription": (args)=>`Valt intervall: ${args.startDate} till ${args.endDate}`,
660
+ "selectedTimeDescription": (args)=>`Vald tid: ${args.time}`,
661
+ "startDate": `Startdatum`,
662
+ "timeZoneName": `tidszon`,
663
+ "weekday": `veckodag`,
664
+ "year": `år`
665
+ };
666
+
667
+
668
+ var $3a49d121fe4c9e1d$exports = {};
669
+ $3a49d121fe4c9e1d$exports = {
670
+ "calendar": `Takvim`,
671
+ "day": `gün`,
672
+ "dayPeriod": `ÖÖ/ÖS`,
673
+ "endDate": `Bitiş Tarihi`,
674
+ "era": `çağ`,
675
+ "hour": `saat`,
676
+ "minute": `dakika`,
677
+ "month": `ay`,
678
+ "second": `saniye`,
679
+ "selectedDateDescription": (args)=>`Seçilen Tarih: ${args.date}`,
680
+ "selectedRangeDescription": (args)=>`Seçilen Aralık: ${args.startDate} - ${args.endDate}`,
681
+ "selectedTimeDescription": (args)=>`Seçilen Zaman: ${args.time}`,
682
+ "startDate": `Başlangıç Tarihi`,
683
+ "timeZoneName": `saat dilimi`,
684
+ "weekday": `haftanın günü`,
685
+ "year": `yıl`
686
+ };
687
+
688
+
689
+ var $5ba21dbb8914919d$exports = {};
690
+ $5ba21dbb8914919d$exports = {
691
+ "calendar": `Календар`,
692
+ "day": `день`,
693
+ "dayPeriod": `дп/пп`,
694
+ "endDate": `Дата завершення`,
695
+ "era": `ера`,
696
+ "hour": `година`,
697
+ "minute": `хвилина`,
698
+ "month": `місяць`,
699
+ "second": `секунда`,
700
+ "selectedDateDescription": (args)=>`Вибрана дата: ${args.date}`,
701
+ "selectedRangeDescription": (args)=>`Вибраний діапазон: ${args.startDate} — ${args.endDate}`,
702
+ "selectedTimeDescription": (args)=>`Вибраний час: ${args.time}`,
703
+ "startDate": `Дата початку`,
704
+ "timeZoneName": `часовий пояс`,
705
+ "weekday": `день тижня`,
706
+ "year": `рік`
707
+ };
708
+
709
+
710
+ var $51078838e1b16cd7$exports = {};
711
+ $51078838e1b16cd7$exports = {
712
+ "calendar": `日历`,
713
+ "day": `日`,
714
+ "dayPeriod": `上午/下午`,
715
+ "endDate": `结束日期`,
716
+ "era": `纪元`,
717
+ "hour": `小时`,
718
+ "minute": `分钟`,
719
+ "month": `月`,
720
+ "second": `秒`,
721
+ "selectedDateDescription": (args)=>`选定的日期:${args.date}`,
722
+ "selectedRangeDescription": (args)=>`选定的范围:${args.startDate} 至 ${args.endDate}`,
723
+ "selectedTimeDescription": (args)=>`选定的时间:${args.time}`,
724
+ "startDate": `开始日期`,
725
+ "timeZoneName": `时区`,
726
+ "weekday": `工作日`,
727
+ "year": `年`
728
+ };
729
+
730
+
731
+ var $33fab8219207655a$exports = {};
732
+ $33fab8219207655a$exports = {
733
+ "calendar": `日曆`,
734
+ "day": `日`,
735
+ "dayPeriod": `上午/下午`,
736
+ "endDate": `結束日期`,
737
+ "era": `纪元`,
738
+ "hour": `小时`,
739
+ "minute": `分钟`,
740
+ "month": `月`,
741
+ "second": `秒`,
742
+ "selectedDateDescription": (args)=>`選定的日期:${args.date}`,
743
+ "selectedRangeDescription": (args)=>`選定的範圍:${args.startDate} 至 ${args.endDate}`,
744
+ "selectedTimeDescription": (args)=>`選定的時間:${args.time}`,
745
+ "startDate": `開始日期`,
746
+ "timeZoneName": `时区`,
747
+ "weekday": `工作日`,
748
+ "year": `年`
749
+ };
750
+
751
+
752
+ $204383cf4f6b0d06$exports = {
753
+ "ar-AE": $f23889fffbde9058$exports,
754
+ "bg-BG": $09d9badaa8903929$exports,
755
+ "cs-CZ": $151b77e0fd711730$exports,
756
+ "da-DK": $61915aa8630b90a2$exports,
757
+ "de-DE": $35cea00159787840$exports,
758
+ "el-GR": $518b4e82b9eacafd$exports,
759
+ "en-US": $1c2b297f7e2cf474$exports,
760
+ "es-ES": $07f628a707cf9b18$exports,
761
+ "et-EE": $db553ffe17c7f4db$exports,
762
+ "fi-FI": $4afcfe00cd703f83$exports,
763
+ "fr-FR": $1d2645d18d4c5be0$exports,
764
+ "he-IL": $64cb6a9be1f6fa48$exports,
765
+ "hr-HR": $2a1ef2e8050be27a$exports,
766
+ "hu-HU": $ad429dca102acd0e$exports,
767
+ "it-IT": $6e68cb5d1cb97bd2$exports,
768
+ "ja-JP": $a82ee9af063ee069$exports,
769
+ "ko-KR": $67e9091dbf37d4eb$exports,
770
+ "lt-LT": $75834f9729f653d1$exports,
771
+ "lv-LV": $a2df2c2520b4a7f0$exports,
772
+ "nb-NO": $aedcd71db4933ed5$exports,
773
+ "nl-NL": $3b2df9e54353046c$exports,
774
+ "pl-PL": $c03fe977fcfafe93$exports,
775
+ "pt-BR": $569f006fc292345f$exports,
776
+ "pt-PT": $7c2494e14452f2dd$exports,
777
+ "ro-RO": $eb82ef981b5592bf$exports,
778
+ "ru-RU": $6efa0e119f396950$exports,
779
+ "sk-SK": $7f5e57085d7f5049$exports,
780
+ "sl-SI": $578ee7c11dcdde7a$exports,
781
+ "sr-SP": $bbc3fd6cd0bc9d50$exports,
782
+ "sv-SE": $0b04512118591d2a$exports,
783
+ "tr-TR": $3a49d121fe4c9e1d$exports,
784
+ "uk-UA": $5ba21dbb8914919d$exports,
785
+ "zh-CN": $51078838e1b16cd7$exports,
786
+ "zh-TW": $33fab8219207655a$exports
787
+ };
788
+
789
+
790
+
791
+ /*
792
+ * Copyright 2020 Adobe. All rights reserved.
793
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
794
+ * you may not use this file except in compliance with the License. You may obtain a copy
795
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
796
+ *
797
+ * Unless required by applicable law or agreed to in writing, software distributed under
798
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
799
+ * OF ANY KIND, either express or implied. See the License for the specific language
800
+ * governing permissions and limitations under the License.
801
+ */
802
+
803
+
804
+
805
+
806
+
807
+
808
+
809
+
810
+ function $3dfb0f96be0d6a08$export$4a931266a3838b86(state, ref, disableArrowNavigation) {
811
+ let { direction: direction } = (0, $cIPI0$useLocale)();
812
+ let focusManager = (0, $cIPI0$useMemo)(()=>(0, $cIPI0$createFocusManager)(ref), [
813
+ ref
814
+ ]);
815
+ // Open the popover on alt + arrow down
816
+ let onKeyDown = (e)=>{
817
+ if (e.altKey && (e.key === "ArrowDown" || e.key === "ArrowUp") && "setOpen" in state) {
818
+ e.preventDefault();
819
+ e.stopPropagation();
820
+ state.setOpen(true);
821
+ }
822
+ if (disableArrowNavigation) return;
823
+ switch(e.key){
824
+ case "ArrowLeft":
825
+ e.preventDefault();
826
+ e.stopPropagation();
827
+ if (direction === "rtl") focusManager.focusNext();
828
+ else focusManager.focusPrevious();
829
+ break;
830
+ case "ArrowRight":
831
+ e.preventDefault();
832
+ e.stopPropagation();
833
+ if (direction === "rtl") focusManager.focusPrevious();
834
+ else focusManager.focusNext();
835
+ break;
836
+ }
837
+ };
838
+ // Focus the first placeholder segment from the end on mouse down/touch up in the field.
839
+ let focusLast = ()=>{
840
+ var _window_event;
841
+ // Try to find the segment prior to the element that was clicked on.
842
+ let target = (_window_event = window.event) === null || _window_event === void 0 ? void 0 : _window_event.target;
843
+ let walker = (0, $cIPI0$getFocusableTreeWalker)(ref.current, {
844
+ tabbable: true
845
+ });
846
+ if (target) {
847
+ walker.currentNode = target;
848
+ target = walker.previousNode();
849
+ }
850
+ // If no target found, find the last element from the end.
851
+ if (!target) {
852
+ let last;
853
+ do {
854
+ last = walker.lastChild();
855
+ if (last) target = last;
856
+ }while (last);
857
+ }
858
+ // Now go backwards until we find an element that is not a placeholder.
859
+ while(target === null || target === void 0 ? void 0 : target.hasAttribute("data-placeholder")){
860
+ let prev = walker.previousNode();
861
+ if (prev && prev.hasAttribute("data-placeholder")) target = prev;
862
+ else break;
863
+ }
864
+ if (target) target.focus();
865
+ };
866
+ let { pressProps: pressProps } = (0, $cIPI0$usePress)({
867
+ preventFocusOnPress: true,
868
+ allowTextSelectionOnPress: true,
869
+ onPressStart (e) {
870
+ if (e.pointerType === "mouse") focusLast();
871
+ },
872
+ onPress (e) {
873
+ if (e.pointerType !== "mouse") focusLast();
874
+ }
875
+ });
876
+ return (0, $cIPI0$mergeProps)(pressProps, {
877
+ onKeyDown: onKeyDown
878
+ });
879
+ }
880
+
881
+
882
+
883
+
884
+
885
+ const $16f0b7bb276bc17e$export$653eddfc964b0f8a = new WeakMap();
886
+ const $16f0b7bb276bc17e$export$300019f83c56d282 = "__role_" + Date.now();
887
+ const $16f0b7bb276bc17e$export$7b3062cd49e80452 = "__focusManager_" + Date.now();
888
+ function $16f0b7bb276bc17e$export$5591b0b878c1a989(props, state, ref) {
889
+ let { labelProps: labelProps , fieldProps: fieldProps , descriptionProps: descriptionProps , errorMessageProps: errorMessageProps } = (0, $cIPI0$useField)({
890
+ ...props,
891
+ labelElementType: "span"
892
+ });
893
+ let { focusWithinProps: focusWithinProps } = (0, $cIPI0$useFocusWithin)({
894
+ ...props,
895
+ onBlurWithin: (e)=>{
896
+ state.confirmPlaceholder();
897
+ if (props.onBlur) props.onBlur(e);
898
+ },
899
+ onFocusWithin: props.onFocus,
900
+ onFocusWithinChange: props.onFocusChange
901
+ });
902
+ let stringFormatter = (0, $cIPI0$useLocalizedStringFormatter)((0, (/*@__PURE__*/$parcel$interopDefault($204383cf4f6b0d06$exports))));
903
+ let message = state.maxGranularity === "hour" ? "selectedTimeDescription" : "selectedDateDescription";
904
+ let field = state.maxGranularity === "hour" ? "time" : "date";
905
+ let description = state.value ? stringFormatter.format(message, {
906
+ [field]: state.formatValue({
907
+ month: "long"
908
+ })
909
+ }) : "";
910
+ let descProps = (0, $cIPI0$useDescription)(description);
911
+ // If within a date picker or date range picker, the date field will have role="presentation" and an aria-describedby
912
+ // will be passed in that references the value (e.g. entire range). Otherwise, add the field's value description.
913
+ let describedBy = props[$16f0b7bb276bc17e$export$300019f83c56d282] === "presentation" ? fieldProps["aria-describedby"] : [
914
+ descProps["aria-describedby"],
915
+ fieldProps["aria-describedby"]
916
+ ].filter(Boolean).join(" ") || undefined;
917
+ let propsFocusManager = props[$16f0b7bb276bc17e$export$7b3062cd49e80452];
918
+ let focusManager = (0, $cIPI0$useMemo)(()=>propsFocusManager || (0, $cIPI0$createFocusManager)(ref), [
919
+ propsFocusManager,
920
+ ref
921
+ ]);
922
+ let groupProps = (0, $3dfb0f96be0d6a08$export$4a931266a3838b86)(state, ref, props[$16f0b7bb276bc17e$export$300019f83c56d282] === "presentation");
923
+ // Pass labels and other information to segments.
924
+ $16f0b7bb276bc17e$export$653eddfc964b0f8a.set(state, {
925
+ ariaLabel: props["aria-label"],
926
+ ariaLabelledBy: [
927
+ props["aria-labelledby"],
928
+ labelProps.id
929
+ ].filter(Boolean).join(" ") || undefined,
930
+ ariaDescribedBy: describedBy,
931
+ focusManager: focusManager
932
+ });
933
+ let autoFocusRef = (0, $cIPI0$useRef)(props.autoFocus);
934
+ // When used within a date picker or date range picker, the field gets role="presentation"
935
+ // rather than role="group". Since the date picker/date range picker already has a role="group"
936
+ // with a label and description, and the segments are already labeled by this as well, this
937
+ // avoids very verbose duplicate announcements.
938
+ let fieldDOMProps;
939
+ if (props[$16f0b7bb276bc17e$export$300019f83c56d282] === "presentation") fieldDOMProps = {
940
+ role: "presentation"
941
+ };
942
+ else fieldDOMProps = (0, $cIPI0$mergeProps)(fieldProps, {
943
+ role: "group",
944
+ "aria-disabled": props.isDisabled || undefined,
945
+ "aria-describedby": describedBy
946
+ });
947
+ (0, $cIPI0$useEffect)(()=>{
948
+ if (autoFocusRef.current) focusManager.focusFirst();
949
+ autoFocusRef.current = false;
950
+ }, [
951
+ focusManager
952
+ ]);
953
+ let domProps = (0, $cIPI0$filterDOMProps)(props);
954
+ return {
955
+ labelProps: {
956
+ ...labelProps,
957
+ onClick: ()=>{
958
+ focusManager.focusFirst();
959
+ }
960
+ },
961
+ fieldProps: (0, $cIPI0$mergeProps)(domProps, fieldDOMProps, groupProps, focusWithinProps, {
962
+ onKeyDown (e) {
963
+ if (props.onKeyDown) props.onKeyDown(e);
964
+ },
965
+ onKeyUp (e) {
966
+ if (props.onKeyUp) props.onKeyUp(e);
967
+ }
968
+ }),
969
+ descriptionProps: descriptionProps,
970
+ errorMessageProps: errorMessageProps
971
+ };
972
+ }
973
+ function $16f0b7bb276bc17e$export$4c842f6a241dc825(props, state, ref) {
974
+ return $16f0b7bb276bc17e$export$5591b0b878c1a989(props, state, ref);
975
+ }
976
+
977
+
978
+
979
+
980
+
981
+
982
+ function $6057a3d2a53a12fd$export$42df105a73306d51(props, state, ref) {
983
+ let buttonId = (0, $cIPI0$useId)();
984
+ let dialogId = (0, $cIPI0$useId)();
985
+ let fieldId = (0, $cIPI0$useId)();
986
+ let stringFormatter = (0, $cIPI0$useLocalizedStringFormatter)((0, (/*@__PURE__*/$parcel$interopDefault($204383cf4f6b0d06$exports))));
987
+ let { labelProps: labelProps , fieldProps: fieldProps , descriptionProps: descriptionProps , errorMessageProps: errorMessageProps } = (0, $cIPI0$useField)({
988
+ ...props,
989
+ labelElementType: "span"
990
+ });
991
+ let groupProps = (0, $3dfb0f96be0d6a08$export$4a931266a3838b86)(state, ref);
992
+ let labelledBy = fieldProps["aria-labelledby"] || fieldProps.id;
993
+ let { locale: locale } = (0, $cIPI0$useLocale)();
994
+ let date = state.formatValue(locale, {
995
+ month: "long"
996
+ });
997
+ let description = date ? stringFormatter.format("selectedDateDescription", {
998
+ date: date
999
+ }) : "";
1000
+ let descProps = (0, $cIPI0$useDescription)(description);
1001
+ let ariaDescribedBy = [
1002
+ descProps["aria-describedby"],
1003
+ fieldProps["aria-describedby"]
1004
+ ].filter(Boolean).join(" ") || undefined;
1005
+ let domProps = (0, $cIPI0$filterDOMProps)(props);
1006
+ let focusManager = (0, $cIPI0$useMemo)(()=>(0, $cIPI0$createFocusManager)(ref), [
1007
+ ref
1008
+ ]);
1009
+ let { focusWithinProps: focusWithinProps } = (0, $cIPI0$useFocusWithin)({
1010
+ ...props,
1011
+ isDisabled: state.isOpen,
1012
+ onBlurWithin: props.onBlur,
1013
+ onFocusWithin: props.onFocus,
1014
+ onFocusWithinChange: props.onFocusChange
1015
+ });
1016
+ return {
1017
+ groupProps: (0, $cIPI0$mergeProps)(domProps, groupProps, fieldProps, descProps, focusWithinProps, {
1018
+ role: "group",
1019
+ "aria-disabled": props.isDisabled || null,
1020
+ "aria-labelledby": labelledBy,
1021
+ "aria-describedby": ariaDescribedBy,
1022
+ onKeyDown (e) {
1023
+ if (state.isOpen) return;
1024
+ if (props.onKeyDown) props.onKeyDown(e);
1025
+ },
1026
+ onKeyUp (e) {
1027
+ if (state.isOpen) return;
1028
+ if (props.onKeyUp) props.onKeyUp(e);
1029
+ }
1030
+ }),
1031
+ labelProps: {
1032
+ ...labelProps,
1033
+ onClick: ()=>{
1034
+ focusManager.focusFirst();
1035
+ }
1036
+ },
1037
+ fieldProps: {
1038
+ ...fieldProps,
1039
+ id: fieldId,
1040
+ [(0, $16f0b7bb276bc17e$export$300019f83c56d282)]: "presentation",
1041
+ "aria-describedby": ariaDescribedBy,
1042
+ value: state.value,
1043
+ onChange: state.setValue,
1044
+ minValue: props.minValue,
1045
+ maxValue: props.maxValue,
1046
+ placeholderValue: props.placeholderValue,
1047
+ hideTimeZone: props.hideTimeZone,
1048
+ hourCycle: props.hourCycle,
1049
+ granularity: props.granularity,
1050
+ isDisabled: props.isDisabled,
1051
+ isReadOnly: props.isReadOnly,
1052
+ isRequired: props.isRequired,
1053
+ validationState: state.validationState,
1054
+ autoFocus: props.autoFocus
1055
+ },
1056
+ descriptionProps: descriptionProps,
1057
+ errorMessageProps: errorMessageProps,
1058
+ buttonProps: {
1059
+ ...descProps,
1060
+ id: buttonId,
1061
+ "aria-haspopup": "dialog",
1062
+ "aria-label": stringFormatter.format("calendar"),
1063
+ "aria-labelledby": `${labelledBy} ${buttonId}`,
1064
+ "aria-describedby": ariaDescribedBy,
1065
+ "aria-expanded": state.isOpen || undefined,
1066
+ onPress: ()=>state.setOpen(true)
1067
+ },
1068
+ dialogProps: {
1069
+ id: dialogId,
1070
+ "aria-labelledby": `${labelledBy} ${buttonId}`
1071
+ },
1072
+ calendarProps: {
1073
+ autoFocus: true,
1074
+ value: state.dateValue,
1075
+ onChange: state.setDateValue,
1076
+ minValue: props.minValue,
1077
+ maxValue: props.maxValue,
1078
+ isDisabled: props.isDisabled,
1079
+ isReadOnly: props.isReadOnly,
1080
+ isDateUnavailable: props.isDateUnavailable,
1081
+ defaultFocusedValue: state.dateValue ? undefined : props.placeholderValue,
1082
+ validationState: state.validationState,
1083
+ errorMessage: props.errorMessage
1084
+ }
1085
+ };
1086
+ }
1087
+
1088
+
1089
+ /*
1090
+ * Copyright 2020 Adobe. All rights reserved.
1091
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
1092
+ * you may not use this file except in compliance with the License. You may obtain a copy
1093
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
1094
+ *
1095
+ * Unless required by applicable law or agreed to in writing, software distributed under
1096
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
1097
+ * OF ANY KIND, either express or implied. See the License for the specific language
1098
+ * governing permissions and limitations under the License.
1099
+ */
1100
+
1101
+
1102
+
1103
+
1104
+
1105
+ /*
1106
+ * Copyright 2020 Adobe. All rights reserved.
1107
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
1108
+ * you may not use this file except in compliance with the License. You may obtain a copy
1109
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
1110
+ *
1111
+ * Unless required by applicable law or agreed to in writing, software distributed under
1112
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
1113
+ * OF ANY KIND, either express or implied. See the License for the specific language
1114
+ * governing permissions and limitations under the License.
1115
+ */ // @ts-ignore
1116
+
1117
+
1118
+
1119
+
1120
+ function $3aeceb3a64eb8358$export$d42c60378c8168f8() {
1121
+ let { locale: locale } = (0, $cIPI0$useLocale)();
1122
+ return (0, $cIPI0$useMemo)(()=>{
1123
+ // Try to use Intl.DisplayNames if possible. It may be supported in browsers, but not support the dateTimeField
1124
+ // type as that was only added in v2. https://github.com/tc39/intl-displaynames-v2
1125
+ try {
1126
+ // @ts-ignore
1127
+ return new Intl.DisplayNames(locale, {
1128
+ type: "dateTimeField"
1129
+ });
1130
+ } catch (err) {
1131
+ return new $3aeceb3a64eb8358$var$DisplayNamesPolyfill(locale);
1132
+ }
1133
+ }, [
1134
+ locale
1135
+ ]);
1136
+ }
1137
+ class $3aeceb3a64eb8358$var$DisplayNamesPolyfill {
1138
+ of(field) {
1139
+ return this.dictionary.getStringForLocale(field, this.locale);
1140
+ }
1141
+ constructor(locale){
1142
+ this.locale = locale;
1143
+ this.dictionary = new (0, $cIPI0$LocalizedStringDictionary)((0, (/*@__PURE__*/$parcel$interopDefault($204383cf4f6b0d06$exports))));
1144
+ }
1145
+ }
1146
+
1147
+
1148
+
1149
+ function $32489daedd52963e$export$1315d136e6f7581(segment, state, ref) {
1150
+ let enteredKeys = (0, $cIPI0$useRef)("");
1151
+ let { locale: locale } = (0, $cIPI0$useLocale)();
1152
+ let displayNames = (0, $3aeceb3a64eb8358$export$d42c60378c8168f8)();
1153
+ let { ariaLabel: ariaLabel , ariaLabelledBy: ariaLabelledBy , ariaDescribedBy: ariaDescribedBy , focusManager: focusManager } = (0, $16f0b7bb276bc17e$export$653eddfc964b0f8a).get(state);
1154
+ let textValue = segment.isPlaceholder ? "" : segment.text;
1155
+ let options = (0, $cIPI0$useMemo)(()=>state.dateFormatter.resolvedOptions(), [
1156
+ state.dateFormatter
1157
+ ]);
1158
+ let monthDateFormatter = (0, $cIPI0$useDateFormatter)({
1159
+ month: "long",
1160
+ timeZone: options.timeZone
1161
+ });
1162
+ let hourDateFormatter = (0, $cIPI0$useDateFormatter)({
1163
+ hour: "numeric",
1164
+ hour12: options.hour12,
1165
+ timeZone: options.timeZone
1166
+ });
1167
+ if (segment.type === "month" && !segment.isPlaceholder) {
1168
+ let monthTextValue = monthDateFormatter.format(state.dateValue);
1169
+ textValue = monthTextValue !== textValue ? `${textValue} – ${monthTextValue}` : monthTextValue;
1170
+ } else if (segment.type === "hour" && !segment.isPlaceholder) textValue = hourDateFormatter.format(state.dateValue);
1171
+ let { spinButtonProps: spinButtonProps } = (0, $cIPI0$useSpinButton)({
1172
+ // The ARIA spec says aria-valuenow is optional if there's no value, but aXe seems to require it.
1173
+ // This doesn't seem to have any negative effects with real AT since we also use aria-valuetext.
1174
+ // https://github.com/dequelabs/axe-core/issues/3505
1175
+ value: segment.value,
1176
+ textValue: textValue,
1177
+ minValue: segment.minValue,
1178
+ maxValue: segment.maxValue,
1179
+ isDisabled: state.isDisabled,
1180
+ isReadOnly: state.isReadOnly || !segment.isEditable,
1181
+ isRequired: state.isRequired,
1182
+ onIncrement: ()=>{
1183
+ enteredKeys.current = "";
1184
+ state.increment(segment.type);
1185
+ },
1186
+ onDecrement: ()=>{
1187
+ enteredKeys.current = "";
1188
+ state.decrement(segment.type);
1189
+ },
1190
+ onIncrementPage: ()=>{
1191
+ enteredKeys.current = "";
1192
+ state.incrementPage(segment.type);
1193
+ },
1194
+ onDecrementPage: ()=>{
1195
+ enteredKeys.current = "";
1196
+ state.decrementPage(segment.type);
1197
+ },
1198
+ onIncrementToMax: ()=>{
1199
+ enteredKeys.current = "";
1200
+ state.setSegment(segment.type, segment.maxValue);
1201
+ },
1202
+ onDecrementToMin: ()=>{
1203
+ enteredKeys.current = "";
1204
+ state.setSegment(segment.type, segment.minValue);
1205
+ }
1206
+ });
1207
+ let parser = (0, $cIPI0$useMemo)(()=>new (0, $cIPI0$NumberParser)(locale, {
1208
+ maximumFractionDigits: 0
1209
+ }), [
1210
+ locale
1211
+ ]);
1212
+ let backspace = ()=>{
1213
+ if (parser.isValidPartialNumber(segment.text) && !state.isReadOnly && !segment.isPlaceholder) {
1214
+ let newValue = segment.text.slice(0, -1);
1215
+ let parsed = parser.parse(newValue);
1216
+ if (newValue.length === 0 || parsed === 0) state.clearSegment(segment.type);
1217
+ else state.setSegment(segment.type, parsed);
1218
+ enteredKeys.current = newValue;
1219
+ } else if (segment.type === "dayPeriod") state.clearSegment(segment.type);
1220
+ };
1221
+ let onKeyDown = (e)=>{
1222
+ // Firefox does not fire selectstart for Ctrl/Cmd + A
1223
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=1742153
1224
+ if (e.key === "a" && ((0, $cIPI0$isMac)() ? e.metaKey : e.ctrlKey)) e.preventDefault();
1225
+ if (e.ctrlKey || e.metaKey || e.shiftKey || e.altKey) return;
1226
+ switch(e.key){
1227
+ case "Backspace":
1228
+ case "Delete":
1229
+ // Safari on iOS does not fire beforeinput for the backspace key because the cursor is at the start.
1230
+ e.preventDefault();
1231
+ e.stopPropagation();
1232
+ backspace();
1233
+ break;
1234
+ }
1235
+ };
1236
+ // Safari dayPeriod option doesn't work...
1237
+ let { startsWith: startsWith } = (0, $cIPI0$useFilter)({
1238
+ sensitivity: "base"
1239
+ });
1240
+ let amPmFormatter = (0, $cIPI0$useDateFormatter)({
1241
+ hour: "numeric",
1242
+ hour12: true
1243
+ });
1244
+ let am = (0, $cIPI0$useMemo)(()=>{
1245
+ let date = new Date();
1246
+ date.setHours(0);
1247
+ return amPmFormatter.formatToParts(date).find((part)=>part.type === "dayPeriod").value;
1248
+ }, [
1249
+ amPmFormatter
1250
+ ]);
1251
+ let pm = (0, $cIPI0$useMemo)(()=>{
1252
+ let date = new Date();
1253
+ date.setHours(12);
1254
+ return amPmFormatter.formatToParts(date).find((part)=>part.type === "dayPeriod").value;
1255
+ }, [
1256
+ amPmFormatter
1257
+ ]);
1258
+ // Get a list of formatted era names so users can type the first character to choose one.
1259
+ let eraFormatter = (0, $cIPI0$useDateFormatter)({
1260
+ year: "numeric",
1261
+ era: "narrow",
1262
+ timeZone: "UTC"
1263
+ });
1264
+ let eras = (0, $cIPI0$useMemo)(()=>{
1265
+ if (segment.type !== "era") return [];
1266
+ let date = (0, $cIPI0$toCalendar)(new (0, $cIPI0$CalendarDate)(1, 1, 1), state.calendar);
1267
+ let eras = state.calendar.getEras().map((era)=>{
1268
+ let eraDate = date.set({
1269
+ year: 1,
1270
+ month: 1,
1271
+ day: 1,
1272
+ era: era
1273
+ }).toDate("UTC");
1274
+ let parts = eraFormatter.formatToParts(eraDate);
1275
+ let formatted = parts.find((p)=>p.type === "era").value;
1276
+ return {
1277
+ era: era,
1278
+ formatted: formatted
1279
+ };
1280
+ });
1281
+ // Remove the common prefix from formatted values. This is so that in calendars with eras like
1282
+ // ERA0 and ERA1 (e.g. Ethiopic), users can press "0" and "1" to select an era. In other cases,
1283
+ // the first letter is used.
1284
+ let prefixLength = $32489daedd52963e$var$commonPrefixLength(eras.map((era)=>era.formatted));
1285
+ if (prefixLength) for (let era of eras)era.formatted = era.formatted.slice(prefixLength);
1286
+ return eras;
1287
+ }, [
1288
+ eraFormatter,
1289
+ state.calendar,
1290
+ segment.type
1291
+ ]);
1292
+ let onInput = (key)=>{
1293
+ if (state.isDisabled || state.isReadOnly) return;
1294
+ let newValue = enteredKeys.current + key;
1295
+ switch(segment.type){
1296
+ case "dayPeriod":
1297
+ if (startsWith(am, key)) state.setSegment("dayPeriod", 0);
1298
+ else if (startsWith(pm, key)) state.setSegment("dayPeriod", 12);
1299
+ else break;
1300
+ focusManager.focusNext();
1301
+ break;
1302
+ case "era":
1303
+ {
1304
+ let matched = eras.find((e)=>startsWith(e.formatted, key));
1305
+ if (matched) {
1306
+ state.setSegment("era", matched.era);
1307
+ focusManager.focusNext();
1308
+ }
1309
+ break;
1310
+ }
1311
+ case "day":
1312
+ case "hour":
1313
+ case "minute":
1314
+ case "second":
1315
+ case "month":
1316
+ case "year":
1317
+ {
1318
+ if (!parser.isValidPartialNumber(newValue)) return;
1319
+ let numberValue = parser.parse(newValue);
1320
+ let segmentValue = numberValue;
1321
+ let allowsZero = segment.minValue === 0;
1322
+ if (segment.type === "hour" && state.dateFormatter.resolvedOptions().hour12) {
1323
+ switch(state.dateFormatter.resolvedOptions().hourCycle){
1324
+ case "h11":
1325
+ if (numberValue > 11) segmentValue = parser.parse(key);
1326
+ break;
1327
+ case "h12":
1328
+ allowsZero = false;
1329
+ if (numberValue > 12) segmentValue = parser.parse(key);
1330
+ break;
1331
+ }
1332
+ if (segment.value >= 12 && numberValue > 1) numberValue += 12;
1333
+ } else if (numberValue > segment.maxValue) segmentValue = parser.parse(key);
1334
+ if (isNaN(numberValue)) return;
1335
+ let shouldSetValue = segmentValue !== 0 || allowsZero;
1336
+ if (shouldSetValue) state.setSegment(segment.type, segmentValue);
1337
+ if (Number(numberValue + "0") > segment.maxValue || newValue.length >= String(segment.maxValue).length) {
1338
+ enteredKeys.current = "";
1339
+ if (shouldSetValue) focusManager.focusNext();
1340
+ } else enteredKeys.current = newValue;
1341
+ break;
1342
+ }
1343
+ }
1344
+ };
1345
+ let onFocus = ()=>{
1346
+ enteredKeys.current = "";
1347
+ (0, $cIPI0$scrollIntoViewport)(ref.current, {
1348
+ containingElement: (0, $cIPI0$getScrollParent)(ref.current)
1349
+ });
1350
+ // Collapse selection to start or Chrome won't fire input events.
1351
+ let selection = window.getSelection();
1352
+ selection.collapse(ref.current);
1353
+ };
1354
+ let compositionRef = (0, $cIPI0$useRef)("");
1355
+ // @ts-ignore - TODO: possibly old TS version? doesn't fail in my editor...
1356
+ (0, $cIPI0$useEvent)(ref, "beforeinput", (e)=>{
1357
+ e.preventDefault();
1358
+ switch(e.inputType){
1359
+ case "deleteContentBackward":
1360
+ case "deleteContentForward":
1361
+ if (parser.isValidPartialNumber(segment.text) && !state.isReadOnly) backspace();
1362
+ break;
1363
+ case "insertCompositionText":
1364
+ // insertCompositionText cannot be canceled.
1365
+ // Record the current state of the element so we can restore it in the `input` event below.
1366
+ compositionRef.current = ref.current.textContent;
1367
+ // Safari gets stuck in a composition state unless we also assign to the value here.
1368
+ // eslint-disable-next-line no-self-assign
1369
+ ref.current.textContent = ref.current.textContent;
1370
+ break;
1371
+ default:
1372
+ if (e.data != null) onInput(e.data);
1373
+ break;
1374
+ }
1375
+ });
1376
+ (0, $cIPI0$useEvent)(ref, "input", (e)=>{
1377
+ let { inputType: inputType , data: data } = e;
1378
+ switch(inputType){
1379
+ case "insertCompositionText":
1380
+ // Reset the DOM to how it was in the beforeinput event.
1381
+ ref.current.textContent = compositionRef.current;
1382
+ // Android sometimes fires key presses of letters as composition events. Need to handle am/pm keys here too.
1383
+ // Can also happen e.g. with Pinyin keyboard on iOS.
1384
+ if (startsWith(am, data) || startsWith(pm, data)) onInput(data);
1385
+ break;
1386
+ }
1387
+ });
1388
+ (0, $cIPI0$useLayoutEffect)(()=>{
1389
+ let element = ref.current;
1390
+ return ()=>{
1391
+ // If the focused segment is removed, focus the previous one, or the next one if there was no previous one.
1392
+ if (document.activeElement === element) {
1393
+ let prev = focusManager.focusPrevious();
1394
+ if (!prev) focusManager.focusNext();
1395
+ }
1396
+ };
1397
+ }, [
1398
+ ref,
1399
+ focusManager
1400
+ ]);
1401
+ // spinbuttons cannot be focused with VoiceOver on iOS.
1402
+ let touchPropOverrides = (0, $cIPI0$isIOS)() || segment.type === "timeZoneName" ? {
1403
+ role: "textbox",
1404
+ "aria-valuemax": null,
1405
+ "aria-valuemin": null,
1406
+ "aria-valuetext": null,
1407
+ "aria-valuenow": null
1408
+ } : {};
1409
+ // Only apply aria-describedby to the first segment, unless the field is invalid. This avoids it being
1410
+ // read every time the user navigates to a new segment.
1411
+ let firstSegment = (0, $cIPI0$useMemo)(()=>state.segments.find((s)=>s.isEditable), [
1412
+ state.segments
1413
+ ]);
1414
+ if (segment !== firstSegment && state.validationState !== "invalid") ariaDescribedBy = undefined;
1415
+ let id = (0, $cIPI0$useId)();
1416
+ let isEditable = !state.isDisabled && !state.isReadOnly && segment.isEditable;
1417
+ // Prepend the label passed from the field to each segment name.
1418
+ // This is needed because VoiceOver on iOS does not announce groups.
1419
+ let name = segment.type === "literal" ? "" : displayNames.of(segment.type);
1420
+ let labelProps = (0, $cIPI0$useLabels)({
1421
+ "aria-label": (ariaLabel ? ariaLabel + " " : "") + name,
1422
+ "aria-labelledby": ariaLabelledBy
1423
+ });
1424
+ // Literal segments should not be visible to screen readers. We don't really need any of the above,
1425
+ // but the rules of hooks mean hooks cannot be conditional so we have to put this condition here.
1426
+ if (segment.type === "literal") return {
1427
+ segmentProps: {
1428
+ "aria-hidden": true
1429
+ }
1430
+ };
1431
+ return {
1432
+ segmentProps: (0, $cIPI0$mergeProps)(spinButtonProps, labelProps, {
1433
+ id: id,
1434
+ ...touchPropOverrides,
1435
+ "aria-invalid": state.validationState === "invalid" ? "true" : undefined,
1436
+ "aria-describedby": ariaDescribedBy,
1437
+ "aria-readonly": state.isReadOnly || !segment.isEditable ? "true" : undefined,
1438
+ "data-placeholder": segment.isPlaceholder || undefined,
1439
+ contentEditable: isEditable,
1440
+ suppressContentEditableWarning: isEditable,
1441
+ spellCheck: isEditable ? "false" : undefined,
1442
+ autoCapitalize: isEditable ? "off" : undefined,
1443
+ autoCorrect: isEditable ? "off" : undefined,
1444
+ // Capitalization was changed in React 17...
1445
+ [parseInt((0, $cIPI0$react).version, 10) >= 17 ? "enterKeyHint" : "enterkeyhint"]: isEditable ? "next" : undefined,
1446
+ inputMode: state.isDisabled || segment.type === "dayPeriod" || segment.type === "era" || !isEditable ? undefined : "numeric",
1447
+ tabIndex: state.isDisabled ? undefined : 0,
1448
+ onKeyDown: onKeyDown,
1449
+ onFocus: onFocus,
1450
+ style: {
1451
+ caretColor: "transparent"
1452
+ },
1453
+ // Prevent pointer events from reaching useDatePickerGroup, and allow native browser behavior to focus the segment.
1454
+ onPointerDown (e) {
1455
+ e.stopPropagation();
1456
+ },
1457
+ onMouseDown (e) {
1458
+ e.stopPropagation();
1459
+ }
1460
+ })
1461
+ };
1462
+ }
1463
+ function $32489daedd52963e$var$commonPrefixLength(strings) {
1464
+ // Sort the strings, and compare the characters in the first and last to find the common prefix.
1465
+ strings.sort();
1466
+ let first = strings[0];
1467
+ let last = strings[strings.length - 1];
1468
+ for(let i = 0; i < first.length; i++){
1469
+ if (first[i] !== last[i]) return i;
1470
+ }
1471
+ return 0;
1472
+ }
1473
+
1474
+
1475
+
1476
+ /*
1477
+ * Copyright 2020 Adobe. All rights reserved.
1478
+ * This file is licensed to you under the Apache License, Version 2.0 (the "License");
1479
+ * you may not use this file except in compliance with the License. You may obtain a copy
1480
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
1481
+ *
1482
+ * Unless required by applicable law or agreed to in writing, software distributed under
1483
+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
1484
+ * OF ANY KIND, either express or implied. See the License for the specific language
1485
+ * governing permissions and limitations under the License.
1486
+ */
1487
+
1488
+
1489
+
1490
+
1491
+
1492
+
1493
+
1494
+
1495
+ function $887cac91b7cc8801$export$12fd5f0e9f4bb192(props, state, ref) {
1496
+ var _state_value, _state_value1;
1497
+ let stringFormatter = (0, $cIPI0$useLocalizedStringFormatter)((0, (/*@__PURE__*/$parcel$interopDefault($204383cf4f6b0d06$exports))));
1498
+ let { labelProps: labelProps , fieldProps: fieldProps , descriptionProps: descriptionProps , errorMessageProps: errorMessageProps } = (0, $cIPI0$useField)({
1499
+ ...props,
1500
+ labelElementType: "span"
1501
+ });
1502
+ let labelledBy = fieldProps["aria-labelledby"] || fieldProps.id;
1503
+ let { locale: locale } = (0, $cIPI0$useLocale)();
1504
+ let range = state.formatValue(locale, {
1505
+ month: "long"
1506
+ });
1507
+ let description = range ? stringFormatter.format("selectedRangeDescription", {
1508
+ startDate: range.start,
1509
+ endDate: range.end
1510
+ }) : "";
1511
+ let descProps = (0, $cIPI0$useDescription)(description);
1512
+ let startFieldProps = {
1513
+ "aria-label": stringFormatter.format("startDate"),
1514
+ "aria-labelledby": labelledBy
1515
+ };
1516
+ let endFieldProps = {
1517
+ "aria-label": stringFormatter.format("endDate"),
1518
+ "aria-labelledby": labelledBy
1519
+ };
1520
+ let buttonId = (0, $cIPI0$useId)();
1521
+ let dialogId = (0, $cIPI0$useId)();
1522
+ let groupProps = (0, $3dfb0f96be0d6a08$export$4a931266a3838b86)(state, ref);
1523
+ let ariaDescribedBy = [
1524
+ descProps["aria-describedby"],
1525
+ fieldProps["aria-describedby"]
1526
+ ].filter(Boolean).join(" ") || undefined;
1527
+ let focusManager = (0, $cIPI0$useMemo)(()=>(0, $cIPI0$createFocusManager)(ref, {
1528
+ // Exclude the button from the focus manager.
1529
+ accept: (element)=>element.id !== buttonId
1530
+ }), [
1531
+ ref,
1532
+ buttonId
1533
+ ]);
1534
+ let commonFieldProps = {
1535
+ [(0, $16f0b7bb276bc17e$export$7b3062cd49e80452)]: focusManager,
1536
+ [(0, $16f0b7bb276bc17e$export$300019f83c56d282)]: "presentation",
1537
+ "aria-describedby": ariaDescribedBy,
1538
+ minValue: props.minValue,
1539
+ maxValue: props.maxValue,
1540
+ placeholderValue: props.placeholderValue,
1541
+ hideTimeZone: props.hideTimeZone,
1542
+ hourCycle: props.hourCycle,
1543
+ granularity: props.granularity,
1544
+ isDisabled: props.isDisabled,
1545
+ isReadOnly: props.isReadOnly,
1546
+ isRequired: props.isRequired,
1547
+ validationState: state.validationState
1548
+ };
1549
+ let domProps = (0, $cIPI0$filterDOMProps)(props);
1550
+ let { focusWithinProps: focusWithinProps } = (0, $cIPI0$useFocusWithin)({
1551
+ ...props,
1552
+ isDisabled: state.isOpen,
1553
+ onBlurWithin: props.onBlur,
1554
+ onFocusWithin: props.onFocus,
1555
+ onFocusWithinChange: props.onFocusChange
1556
+ });
1557
+ return {
1558
+ groupProps: (0, $cIPI0$mergeProps)(domProps, groupProps, fieldProps, descProps, focusWithinProps, {
1559
+ role: "group",
1560
+ "aria-disabled": props.isDisabled || null,
1561
+ "aria-describedby": ariaDescribedBy,
1562
+ onKeyDown (e) {
1563
+ if (state.isOpen) return;
1564
+ if (props.onKeyDown) props.onKeyDown(e);
1565
+ },
1566
+ onKeyUp (e) {
1567
+ if (state.isOpen) return;
1568
+ if (props.onKeyUp) props.onKeyUp(e);
1569
+ }
1570
+ }),
1571
+ labelProps: {
1572
+ ...labelProps,
1573
+ onClick: ()=>{
1574
+ focusManager.focusFirst();
1575
+ }
1576
+ },
1577
+ buttonProps: {
1578
+ ...descProps,
1579
+ id: buttonId,
1580
+ "aria-haspopup": "dialog",
1581
+ "aria-label": stringFormatter.format("calendar"),
1582
+ "aria-labelledby": `${labelledBy} ${buttonId}`,
1583
+ "aria-describedby": ariaDescribedBy,
1584
+ "aria-expanded": state.isOpen || undefined,
1585
+ onPress: ()=>state.setOpen(true)
1586
+ },
1587
+ dialogProps: {
1588
+ id: dialogId,
1589
+ "aria-labelledby": `${labelledBy} ${buttonId}`
1590
+ },
1591
+ startFieldProps: {
1592
+ ...startFieldProps,
1593
+ ...commonFieldProps,
1594
+ value: (_state_value = state.value) === null || _state_value === void 0 ? void 0 : _state_value.start,
1595
+ onChange: (start)=>state.setDateTime("start", start),
1596
+ autoFocus: props.autoFocus
1597
+ },
1598
+ endFieldProps: {
1599
+ ...endFieldProps,
1600
+ ...commonFieldProps,
1601
+ value: (_state_value1 = state.value) === null || _state_value1 === void 0 ? void 0 : _state_value1.end,
1602
+ onChange: (end)=>state.setDateTime("end", end)
1603
+ },
1604
+ descriptionProps: descriptionProps,
1605
+ errorMessageProps: errorMessageProps,
1606
+ calendarProps: {
1607
+ autoFocus: true,
1608
+ value: state.dateRange,
1609
+ onChange: state.setDateRange,
1610
+ minValue: props.minValue,
1611
+ maxValue: props.maxValue,
1612
+ isDisabled: props.isDisabled,
1613
+ isReadOnly: props.isReadOnly,
1614
+ isDateUnavailable: props.isDateUnavailable,
1615
+ allowsNonContiguousRanges: props.allowsNonContiguousRanges,
1616
+ defaultFocusedValue: state.dateRange ? undefined : props.placeholderValue,
1617
+ validationState: state.validationState,
1618
+ errorMessage: props.errorMessage
1619
+ }
1620
+ };
1621
+ }
1622
+
1623
+
1624
+
1625
+
1626
+
1627
+ export {$6057a3d2a53a12fd$export$42df105a73306d51 as useDatePicker, $32489daedd52963e$export$1315d136e6f7581 as useDateSegment, $16f0b7bb276bc17e$export$5591b0b878c1a989 as useDateField, $16f0b7bb276bc17e$export$4c842f6a241dc825 as useTimeField, $887cac91b7cc8801$export$12fd5f0e9f4bb192 as useDateRangePicker, $3aeceb3a64eb8358$export$d42c60378c8168f8 as useDisplayNames};
1628
+ //# sourceMappingURL=module.js.map