shadcn-ui-react 0.4.1 → 0.5.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.
package/dist/index.js CHANGED
@@ -400,9 +400,6 @@ var Button = React5.forwardRef(
400
400
  );
401
401
  Button.displayName = "Button";
402
402
 
403
- // node_modules/@date-fns/tz/constants/index.js
404
- var constructFromSymbol = Symbol.for("constructDateFrom");
405
-
406
403
  // node_modules/@date-fns/tz/tzName/index.js
407
404
  function tzName(timeZone, date, format2 = "long") {
408
405
  return new Intl.DateTimeFormat("en-US", {
@@ -488,7 +485,7 @@ var TZDateMini = class _TZDateMini extends Date {
488
485
  }
489
486
  //#endregion
490
487
  //#region date-fns integration
491
- [Symbol.for("constructDateFrom")](date) {
488
+ [/* @__PURE__ */ Symbol.for("constructDateFrom")](date) {
492
489
  return new _TZDateMini(+new Date(date), this.timeZone);
493
490
  }
494
491
  //#endregion
@@ -616,7 +613,7 @@ var TZDate = class _TZDate extends TZDateMini {
616
613
  return new _TZDate(+this, timeZone);
617
614
  }
618
615
  //#region date-fns integration
619
- [Symbol.for("constructDateFrom")](date) {
616
+ [/* @__PURE__ */ Symbol.for("constructDateFrom")](date) {
620
617
  return new _TZDate(+new Date(date), this.timeZone);
621
618
  }
622
619
  //#endregion
@@ -634,13 +631,13 @@ var secondsInWeek = secondsInDay * 7;
634
631
  var secondsInYear = secondsInDay * daysInYear;
635
632
  var secondsInMonth = secondsInYear / 12;
636
633
  var secondsInQuarter = secondsInMonth * 3;
637
- var constructFromSymbol2 = Symbol.for("constructDateFrom");
634
+ var constructFromSymbol = /* @__PURE__ */ Symbol.for("constructDateFrom");
638
635
 
639
636
  // node_modules/date-fns/constructFrom.js
640
637
  function constructFrom(date, value) {
641
638
  if (typeof date === "function") return date(value);
642
- if (date && typeof date === "object" && constructFromSymbol2 in date)
643
- return date[constructFromSymbol2](value);
639
+ if (date && typeof date === "object" && constructFromSymbol in date)
640
+ return date[constructFromSymbol](value);
644
641
  if (date instanceof Date) return new date.constructor(value);
645
642
  return new Date(value);
646
643
  }
@@ -915,6 +912,29 @@ function startOfYear(date, options) {
915
912
  return date_;
916
913
  }
917
914
 
915
+ // node_modules/date-fns/eachYearOfInterval.js
916
+ function eachYearOfInterval(interval, options) {
917
+ var _a;
918
+ const { start, end } = normalizeInterval(options == null ? void 0 : options.in, interval);
919
+ let reversed = +start > +end;
920
+ const endTime = reversed ? +start : +end;
921
+ const date = reversed ? end : start;
922
+ date.setHours(0, 0, 0, 0);
923
+ date.setMonth(0, 1);
924
+ let step = (_a = options == null ? void 0 : options.step) != null ? _a : 1;
925
+ if (!step) return [];
926
+ if (step < 0) {
927
+ step = -step;
928
+ reversed = !reversed;
929
+ }
930
+ const dates = [];
931
+ while (+date <= endTime) {
932
+ dates.push(constructFrom(start, date));
933
+ date.setFullYear(date.getFullYear() + step);
934
+ }
935
+ return reversed ? dates.reverse() : dates;
936
+ }
937
+
918
938
  // node_modules/date-fns/endOfWeek.js
919
939
  function endOfWeek(date, options) {
920
940
  var _a, _b, _c, _d, _e, _f, _g, _h;
@@ -2463,8 +2483,66 @@ function endOfBroadcastWeek(date, dateLib) {
2463
2483
  return endDate;
2464
2484
  }
2465
2485
 
2486
+ // node_modules/react-day-picker/dist/esm/locale/en-US.js
2487
+ var enUS2 = __spreadProps(__spreadValues({}, enUS), {
2488
+ labels: {
2489
+ labelDayButton: (date, modifiers, options, dateLib) => {
2490
+ let formatDate;
2491
+ if (dateLib && typeof dateLib.format === "function") {
2492
+ formatDate = dateLib.format.bind(dateLib);
2493
+ } else {
2494
+ formatDate = (d, pattern) => format(d, pattern, __spreadValues({ locale: enUS }, options));
2495
+ }
2496
+ let label = formatDate(date, "PPPP");
2497
+ if (modifiers.today)
2498
+ label = `Today, ${label}`;
2499
+ if (modifiers.selected)
2500
+ label = `${label}, selected`;
2501
+ return label;
2502
+ },
2503
+ labelMonthDropdown: "Choose the Month",
2504
+ labelNext: "Go to the Next Month",
2505
+ labelPrevious: "Go to the Previous Month",
2506
+ labelWeekNumber: (weekNumber) => `Week ${weekNumber}`,
2507
+ labelYearDropdown: "Choose the Year",
2508
+ labelGrid: (date, options, dateLib) => {
2509
+ let formatDate;
2510
+ if (dateLib && typeof dateLib.format === "function") {
2511
+ formatDate = dateLib.format.bind(dateLib);
2512
+ } else {
2513
+ formatDate = (d, pattern) => format(d, pattern, __spreadValues({ locale: enUS }, options));
2514
+ }
2515
+ return formatDate(date, "LLLL yyyy");
2516
+ },
2517
+ labelGridcell: (date, modifiers, options, dateLib) => {
2518
+ let formatDate;
2519
+ if (dateLib && typeof dateLib.format === "function") {
2520
+ formatDate = dateLib.format.bind(dateLib);
2521
+ } else {
2522
+ formatDate = (d, pattern) => format(d, pattern, __spreadValues({ locale: enUS }, options));
2523
+ }
2524
+ let label = formatDate(date, "PPPP");
2525
+ if (modifiers == null ? void 0 : modifiers.today) {
2526
+ label = `Today, ${label}`;
2527
+ }
2528
+ return label;
2529
+ },
2530
+ labelNav: "Navigation bar",
2531
+ labelWeekNumberHeader: "Week Number",
2532
+ labelWeekday: (date, options, dateLib) => {
2533
+ let formatDate;
2534
+ if (dateLib && typeof dateLib.format === "function") {
2535
+ formatDate = dateLib.format.bind(dateLib);
2536
+ } else {
2537
+ formatDate = (d, pattern) => format(d, pattern, __spreadValues({ locale: enUS }, options));
2538
+ }
2539
+ return formatDate(date, "cccc");
2540
+ }
2541
+ }
2542
+ });
2543
+
2466
2544
  // node_modules/react-day-picker/dist/esm/classes/DateLib.js
2467
- var DateLib = class {
2545
+ var DateLib = class _DateLib {
2468
2546
  /**
2469
2547
  * Creates an instance of `DateLib`.
2470
2548
  *
@@ -2521,6 +2599,19 @@ var DateLib = class {
2521
2599
  var _a;
2522
2600
  return ((_a = this.overrides) == null ? void 0 : _a.eachMonthOfInterval) ? this.overrides.eachMonthOfInterval(interval) : eachMonthOfInterval(interval);
2523
2601
  };
2602
+ this.eachYearOfInterval = (interval) => {
2603
+ var _a;
2604
+ const years = ((_a = this.overrides) == null ? void 0 : _a.eachYearOfInterval) ? this.overrides.eachYearOfInterval(interval) : eachYearOfInterval(interval);
2605
+ const uniqueYears = new Set(years.map((d) => this.getYear(d)));
2606
+ if (uniqueYears.size === years.length) {
2607
+ return years;
2608
+ }
2609
+ const yearsArray = [];
2610
+ uniqueYears.forEach((y) => {
2611
+ yearsArray.push(new Date(y, 0, 1));
2612
+ });
2613
+ return yearsArray;
2614
+ };
2524
2615
  this.endOfBroadcastWeek = (date) => {
2525
2616
  var _a;
2526
2617
  return ((_a = this.overrides) == null ? void 0 : _a.endOfBroadcastWeek) ? this.overrides.endOfBroadcastWeek(date) : endOfBroadcastWeek(date, this);
@@ -2629,7 +2720,7 @@ var DateLib = class {
2629
2720
  var _a;
2630
2721
  return ((_a = this.overrides) == null ? void 0 : _a.startOfYear) ? this.overrides.startOfYear(date) : startOfYear(date);
2631
2722
  };
2632
- this.options = __spreadValues({ locale: enUS }, options);
2723
+ this.options = __spreadValues({ locale: enUS2 }, options);
2633
2724
  this.overrides = overrides;
2634
2725
  }
2635
2726
  /**
@@ -2671,7 +2762,62 @@ var DateLib = class {
2671
2762
  formatNumber(value) {
2672
2763
  return this.replaceDigits(value.toString());
2673
2764
  }
2765
+ /**
2766
+ * Returns the preferred ordering for month and year labels for the current
2767
+ * locale.
2768
+ */
2769
+ getMonthYearOrder() {
2770
+ var _a;
2771
+ const code = (_a = this.options.locale) == null ? void 0 : _a.code;
2772
+ if (!code) {
2773
+ return "month-first";
2774
+ }
2775
+ return _DateLib.yearFirstLocales.has(code) ? "year-first" : "month-first";
2776
+ }
2777
+ /**
2778
+ * Formats the month/year pair respecting locale conventions.
2779
+ *
2780
+ * @since 9.11.0
2781
+ */
2782
+ formatMonthYear(date) {
2783
+ const { locale, timeZone, numerals } = this.options;
2784
+ const localeCode = locale == null ? void 0 : locale.code;
2785
+ if (localeCode && _DateLib.yearFirstLocales.has(localeCode)) {
2786
+ try {
2787
+ const intl = new Intl.DateTimeFormat(localeCode, {
2788
+ month: "long",
2789
+ year: "numeric",
2790
+ timeZone,
2791
+ numberingSystem: numerals
2792
+ });
2793
+ const formatted = intl.format(date);
2794
+ return formatted;
2795
+ } catch (e) {
2796
+ }
2797
+ }
2798
+ const pattern = this.getMonthYearOrder() === "year-first" ? "y LLLL" : "LLLL y";
2799
+ return this.format(date, pattern);
2800
+ }
2674
2801
  };
2802
+ DateLib.yearFirstLocales = /* @__PURE__ */ new Set([
2803
+ "eu",
2804
+ "hu",
2805
+ "ja",
2806
+ "ja-Hira",
2807
+ "ja-JP",
2808
+ "ko",
2809
+ "ko-KR",
2810
+ "lt",
2811
+ "lt-LT",
2812
+ "lv",
2813
+ "lv-LV",
2814
+ "mn",
2815
+ "mn-MN",
2816
+ "zh",
2817
+ "zh-CN",
2818
+ "zh-HK",
2819
+ "zh-TW"
2820
+ ]);
2675
2821
  var defaultDateLib = new DateLib();
2676
2822
 
2677
2823
  // node_modules/react-day-picker/dist/esm/classes/CalendarDay.js
@@ -2681,6 +2827,9 @@ var CalendarDay = class {
2681
2827
  this.displayMonth = displayMonth;
2682
2828
  this.outside = Boolean(displayMonth && !dateLib.isSameMonth(date, displayMonth));
2683
2829
  this.dateLib = dateLib;
2830
+ this.isoDate = dateLib.format(date, "yyyy-MM-dd");
2831
+ this.displayMonthId = dateLib.format(displayMonth, "yyyy-MM");
2832
+ this.dateMonthId = dateLib.format(date, "yyyy-MM");
2684
2833
  }
2685
2834
  /**
2686
2835
  * Checks if this day is equal to another `CalendarDay`, considering both the
@@ -3038,7 +3187,7 @@ function YearsDropdown(props) {
3038
3187
  }
3039
3188
 
3040
3189
  // node_modules/react-day-picker/dist/esm/DayPicker.js
3041
- import React32, { useCallback as useCallback2, useMemo, useRef as useRef2 } from "react";
3190
+ import React32, { useCallback as useCallback2, useMemo as useMemo2, useRef as useRef2 } from "react";
3042
3191
 
3043
3192
  // node_modules/react-day-picker/dist/esm/utils/rangeIncludesDate.js
3044
3193
  function rangeIncludesDate(range, date, excludeEnds = false, dateLib = defaultDateLib) {
@@ -3093,7 +3242,7 @@ function dateMatchModifiers(date, matchers, dateLib = defaultDateLib) {
3093
3242
  return isSameDay2(date, matcher);
3094
3243
  }
3095
3244
  if (isDatesArray(matcher, dateLib)) {
3096
- return matcher.includes(date);
3245
+ return matcher.some((matcherDate) => isSameDay2(date, matcherDate));
3097
3246
  }
3098
3247
  if (isDateRange(matcher)) {
3099
3248
  return rangeIncludesDate(matcher, date, false, dateLib);
@@ -3131,7 +3280,7 @@ function dateMatchModifiers(date, matchers, dateLib = defaultDateLib) {
3131
3280
 
3132
3281
  // node_modules/react-day-picker/dist/esm/helpers/createGetModifiers.js
3133
3282
  function createGetModifiers(days, props, navStart, navEnd, dateLib) {
3134
- const { disabled, hidden, modifiers, showOutsideDays, broadcastCalendar, today } = props;
3283
+ const { disabled, hidden, modifiers, showOutsideDays, broadcastCalendar, today = dateLib.today() } = props;
3135
3284
  const { isSameDay: isSameDay2, isSameMonth: isSameMonth2, startOfMonth: startOfMonth2, isBefore: isBefore2, endOfMonth: endOfMonth2, isAfter: isAfter2 } = dateLib;
3136
3285
  const computedNavStart = navStart && startOfMonth2(navStart);
3137
3286
  const computedNavEnd = navEnd && endOfMonth2(navEnd);
@@ -3151,7 +3300,7 @@ function createGetModifiers(days, props, navStart, navEnd, dateLib) {
3151
3300
  const isDisabled = Boolean(disabled && dateMatchModifiers(date, disabled, dateLib));
3152
3301
  const isHidden = Boolean(hidden && dateMatchModifiers(date, hidden, dateLib)) || isBeforeNavStart || isAfterNavEnd || // Broadcast calendar will show outside days as default
3153
3302
  !broadcastCalendar && !showOutsideDays && isOutside || broadcastCalendar && showOutsideDays === false && isOutside;
3154
- const isToday = isSameDay2(date, today != null ? today : dateLib.today());
3303
+ const isToday = isSameDay2(date, today);
3155
3304
  if (isOutside)
3156
3305
  internalModifiersMap.outside.push(day);
3157
3306
  if (isDisabled)
@@ -3267,7 +3416,8 @@ __export(formatters_exports, {
3267
3416
 
3268
3417
  // node_modules/react-day-picker/dist/esm/formatters/formatCaption.js
3269
3418
  function formatCaption(month, options, dateLib) {
3270
- return (dateLib != null ? dateLib : new DateLib(options)).format(month, "LLLL y");
3419
+ const lib = dateLib != null ? dateLib : new DateLib(options);
3420
+ return lib.formatMonthYear(month);
3271
3421
  }
3272
3422
  var formatMonthCaption = formatCaption;
3273
3423
 
@@ -3316,70 +3466,6 @@ function getFormatters(customFormatters) {
3316
3466
  return __spreadValues(__spreadValues({}, formatters_exports), customFormatters);
3317
3467
  }
3318
3468
 
3319
- // node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js
3320
- function getMonthOptions(displayMonth, navStart, navEnd, formatters2, dateLib) {
3321
- const { startOfMonth: startOfMonth2, startOfYear: startOfYear2, endOfYear: endOfYear2, eachMonthOfInterval: eachMonthOfInterval2, getMonth: getMonth2 } = dateLib;
3322
- const months = eachMonthOfInterval2({
3323
- start: startOfYear2(displayMonth),
3324
- end: endOfYear2(displayMonth)
3325
- });
3326
- const options = months.map((month) => {
3327
- const label = formatters2.formatMonthDropdown(month, dateLib);
3328
- const value = getMonth2(month);
3329
- const disabled = navStart && month < startOfMonth2(navStart) || navEnd && month > startOfMonth2(navEnd) || false;
3330
- return { value, label, disabled };
3331
- });
3332
- return options;
3333
- }
3334
-
3335
- // node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js
3336
- function getStyleForModifiers(dayModifiers, styles = {}, modifiersStyles = {}) {
3337
- let style = __spreadValues({}, styles == null ? void 0 : styles[UI.Day]);
3338
- Object.entries(dayModifiers).filter(([, active]) => active === true).forEach(([modifier]) => {
3339
- style = __spreadValues(__spreadValues({}, style), modifiersStyles == null ? void 0 : modifiersStyles[modifier]);
3340
- });
3341
- return style;
3342
- }
3343
-
3344
- // node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js
3345
- function getWeekdays(dateLib, ISOWeek, broadcastCalendar) {
3346
- const today = dateLib.today();
3347
- const start = broadcastCalendar ? dateLib.startOfBroadcastWeek(today, dateLib) : ISOWeek ? dateLib.startOfISOWeek(today) : dateLib.startOfWeek(today);
3348
- const days = [];
3349
- for (let i = 0; i < 7; i++) {
3350
- const day = dateLib.addDays(start, i);
3351
- days.push(day);
3352
- }
3353
- return days;
3354
- }
3355
-
3356
- // node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js
3357
- function getYearOptions(navStart, navEnd, formatters2, dateLib, reverse = false) {
3358
- if (!navStart)
3359
- return void 0;
3360
- if (!navEnd)
3361
- return void 0;
3362
- const { startOfYear: startOfYear2, endOfYear: endOfYear2, addYears: addYears2, getYear: getYear2, isBefore: isBefore2, isSameYear: isSameYear2 } = dateLib;
3363
- const firstNavYear = startOfYear2(navStart);
3364
- const lastNavYear = endOfYear2(navEnd);
3365
- const years = [];
3366
- let year = firstNavYear;
3367
- while (isBefore2(year, lastNavYear) || isSameYear2(year, lastNavYear)) {
3368
- years.push(year);
3369
- year = addYears2(year, 1);
3370
- }
3371
- if (reverse)
3372
- years.reverse();
3373
- return years.map((year2) => {
3374
- const label = formatters2.formatYearDropdown(year2, dateLib);
3375
- return {
3376
- value: getYear2(year2),
3377
- label,
3378
- disabled: false
3379
- };
3380
- });
3381
- }
3382
-
3383
3469
  // node_modules/react-day-picker/dist/esm/labels/index.js
3384
3470
  var labels_exports = {};
3385
3471
  __export(labels_exports, {
@@ -3411,7 +3497,8 @@ var labelDay = labelDayButton;
3411
3497
 
3412
3498
  // node_modules/react-day-picker/dist/esm/labels/labelGrid.js
3413
3499
  function labelGrid(date, options, dateLib) {
3414
- return (dateLib != null ? dateLib : new DateLib(options)).format(date, "LLLL y");
3500
+ const lib = dateLib != null ? dateLib : new DateLib(options);
3501
+ return lib.formatMonthYear(date);
3415
3502
  }
3416
3503
  var labelCaption = labelGrid;
3417
3504
 
@@ -3435,8 +3522,9 @@ function labelNav() {
3435
3522
  }
3436
3523
 
3437
3524
  // node_modules/react-day-picker/dist/esm/labels/labelNext.js
3438
- function labelNext(_month) {
3439
- return "Go to the Next Month";
3525
+ var defaultLabel = "Go to the Next Month";
3526
+ function labelNext(_month, _options) {
3527
+ return defaultLabel;
3440
3528
  }
3441
3529
 
3442
3530
  // node_modules/react-day-picker/dist/esm/labels/labelPrevious.js
@@ -3464,6 +3552,92 @@ function labelYearDropdown(_options) {
3464
3552
  return "Choose the Year";
3465
3553
  }
3466
3554
 
3555
+ // node_modules/react-day-picker/dist/esm/helpers/getLabels.js
3556
+ var resolveLabel = (defaultLabel2, customLabel, localeLabel) => {
3557
+ if (customLabel)
3558
+ return customLabel;
3559
+ if (localeLabel) {
3560
+ return typeof localeLabel === "function" ? localeLabel : (..._args) => localeLabel;
3561
+ }
3562
+ return defaultLabel2;
3563
+ };
3564
+ function getLabels(customLabels, options) {
3565
+ var _a, _b;
3566
+ const localeLabels = (_b = (_a = options.locale) == null ? void 0 : _a.labels) != null ? _b : {};
3567
+ return __spreadProps(__spreadValues(__spreadValues({}, labels_exports), customLabels != null ? customLabels : {}), {
3568
+ labelDayButton: resolveLabel(labelDayButton, customLabels == null ? void 0 : customLabels.labelDayButton, localeLabels.labelDayButton),
3569
+ labelMonthDropdown: resolveLabel(labelMonthDropdown, customLabels == null ? void 0 : customLabels.labelMonthDropdown, localeLabels.labelMonthDropdown),
3570
+ labelNext: resolveLabel(labelNext, customLabels == null ? void 0 : customLabels.labelNext, localeLabels.labelNext),
3571
+ labelPrevious: resolveLabel(labelPrevious, customLabels == null ? void 0 : customLabels.labelPrevious, localeLabels.labelPrevious),
3572
+ labelWeekNumber: resolveLabel(labelWeekNumber, customLabels == null ? void 0 : customLabels.labelWeekNumber, localeLabels.labelWeekNumber),
3573
+ labelYearDropdown: resolveLabel(labelYearDropdown, customLabels == null ? void 0 : customLabels.labelYearDropdown, localeLabels.labelYearDropdown),
3574
+ labelGrid: resolveLabel(labelGrid, customLabels == null ? void 0 : customLabels.labelGrid, localeLabels.labelGrid),
3575
+ labelGridcell: resolveLabel(labelGridcell, customLabels == null ? void 0 : customLabels.labelGridcell, localeLabels.labelGridcell),
3576
+ labelNav: resolveLabel(labelNav, customLabels == null ? void 0 : customLabels.labelNav, localeLabels.labelNav),
3577
+ labelWeekNumberHeader: resolveLabel(labelWeekNumberHeader, customLabels == null ? void 0 : customLabels.labelWeekNumberHeader, localeLabels.labelWeekNumberHeader),
3578
+ labelWeekday: resolveLabel(labelWeekday, customLabels == null ? void 0 : customLabels.labelWeekday, localeLabels.labelWeekday)
3579
+ });
3580
+ }
3581
+
3582
+ // node_modules/react-day-picker/dist/esm/helpers/getMonthOptions.js
3583
+ function getMonthOptions(displayMonth, navStart, navEnd, formatters2, dateLib) {
3584
+ const { startOfMonth: startOfMonth2, startOfYear: startOfYear2, endOfYear: endOfYear2, eachMonthOfInterval: eachMonthOfInterval2, getMonth: getMonth2 } = dateLib;
3585
+ const months = eachMonthOfInterval2({
3586
+ start: startOfYear2(displayMonth),
3587
+ end: endOfYear2(displayMonth)
3588
+ });
3589
+ const options = months.map((month) => {
3590
+ const label = formatters2.formatMonthDropdown(month, dateLib);
3591
+ const value = getMonth2(month);
3592
+ const disabled = navStart && month < startOfMonth2(navStart) || navEnd && month > startOfMonth2(navEnd) || false;
3593
+ return { value, label, disabled };
3594
+ });
3595
+ return options;
3596
+ }
3597
+
3598
+ // node_modules/react-day-picker/dist/esm/helpers/getStyleForModifiers.js
3599
+ function getStyleForModifiers(dayModifiers, styles = {}, modifiersStyles = {}) {
3600
+ let style = __spreadValues({}, styles == null ? void 0 : styles[UI.Day]);
3601
+ Object.entries(dayModifiers).filter(([, active]) => active === true).forEach(([modifier]) => {
3602
+ style = __spreadValues(__spreadValues({}, style), modifiersStyles == null ? void 0 : modifiersStyles[modifier]);
3603
+ });
3604
+ return style;
3605
+ }
3606
+
3607
+ // node_modules/react-day-picker/dist/esm/helpers/getWeekdays.js
3608
+ function getWeekdays(dateLib, ISOWeek, broadcastCalendar, today) {
3609
+ const referenceToday = today != null ? today : dateLib.today();
3610
+ const start = broadcastCalendar ? dateLib.startOfBroadcastWeek(referenceToday, dateLib) : ISOWeek ? dateLib.startOfISOWeek(referenceToday) : dateLib.startOfWeek(referenceToday);
3611
+ const days = [];
3612
+ for (let i = 0; i < 7; i++) {
3613
+ const day = dateLib.addDays(start, i);
3614
+ days.push(day);
3615
+ }
3616
+ return days;
3617
+ }
3618
+
3619
+ // node_modules/react-day-picker/dist/esm/helpers/getYearOptions.js
3620
+ function getYearOptions(navStart, navEnd, formatters2, dateLib, reverse = false) {
3621
+ if (!navStart)
3622
+ return void 0;
3623
+ if (!navEnd)
3624
+ return void 0;
3625
+ const { startOfYear: startOfYear2, endOfYear: endOfYear2, eachYearOfInterval: eachYearOfInterval2, getYear: getYear2 } = dateLib;
3626
+ const firstNavYear = startOfYear2(navStart);
3627
+ const lastNavYear = endOfYear2(navEnd);
3628
+ const years = eachYearOfInterval2({ start: firstNavYear, end: lastNavYear });
3629
+ if (reverse)
3630
+ years.reverse();
3631
+ return years.map((year) => {
3632
+ const label = formatters2.formatYearDropdown(year, dateLib);
3633
+ return {
3634
+ value: getYear2(year),
3635
+ label,
3636
+ disabled: false
3637
+ };
3638
+ });
3639
+ }
3640
+
3467
3641
  // node_modules/react-day-picker/dist/esm/useAnimation.js
3468
3642
  import { useLayoutEffect, useRef } from "react";
3469
3643
  var asHtmlElement = (element) => {
@@ -3596,7 +3770,7 @@ function useAnimation(rootElRef, enabled, { classNames, months, focused, dateLib
3596
3770
  }
3597
3771
 
3598
3772
  // node_modules/react-day-picker/dist/esm/useCalendar.js
3599
- import { useEffect } from "react";
3773
+ import { useEffect, useMemo } from "react";
3600
3774
 
3601
3775
  // node_modules/react-day-picker/dist/esm/helpers/getDates.js
3602
3776
  function getDates(displayMonths, maxDate, props, dateLib) {
@@ -3605,15 +3779,14 @@ function getDates(displayMonths, maxDate, props, dateLib) {
3605
3779
  const { ISOWeek, fixedWeeks, broadcastCalendar } = props != null ? props : {};
3606
3780
  const { addDays: addDays2, differenceInCalendarDays: differenceInCalendarDays2, differenceInCalendarMonths: differenceInCalendarMonths2, endOfBroadcastWeek: endOfBroadcastWeek2, endOfISOWeek: endOfISOWeek2, endOfMonth: endOfMonth2, endOfWeek: endOfWeek2, isAfter: isAfter2, startOfBroadcastWeek: startOfBroadcastWeek2, startOfISOWeek: startOfISOWeek2, startOfWeek: startOfWeek2 } = dateLib;
3607
3781
  const startWeekFirstDate = broadcastCalendar ? startOfBroadcastWeek2(firstMonth, dateLib) : ISOWeek ? startOfISOWeek2(firstMonth) : startOfWeek2(firstMonth);
3608
- const endWeekLastDate = broadcastCalendar ? endOfBroadcastWeek2(lastMonth) : ISOWeek ? endOfISOWeek2(endOfMonth2(lastMonth)) : endOfWeek2(endOfMonth2(lastMonth));
3609
- const nOfDays = differenceInCalendarDays2(endWeekLastDate, startWeekFirstDate);
3782
+ const displayMonthsWeekEnd = broadcastCalendar ? endOfBroadcastWeek2(lastMonth) : ISOWeek ? endOfISOWeek2(endOfMonth2(lastMonth)) : endOfWeek2(endOfMonth2(lastMonth));
3783
+ const constraintWeekEnd = maxDate && (broadcastCalendar ? endOfBroadcastWeek2(maxDate) : ISOWeek ? endOfISOWeek2(maxDate) : endOfWeek2(maxDate));
3784
+ const gridEndDate = constraintWeekEnd && isAfter2(displayMonthsWeekEnd, constraintWeekEnd) ? constraintWeekEnd : displayMonthsWeekEnd;
3785
+ const nOfDays = differenceInCalendarDays2(gridEndDate, startWeekFirstDate);
3610
3786
  const nOfMonths = differenceInCalendarMonths2(lastMonth, firstMonth) + 1;
3611
3787
  const dates = [];
3612
3788
  for (let i = 0; i <= nOfDays; i++) {
3613
3789
  const date = addDays2(startWeekFirstDate, i);
3614
- if (maxDate && isAfter2(date, maxDate)) {
3615
- break;
3616
- }
3617
3790
  dates.push(date);
3618
3791
  }
3619
3792
  const nrOfDaysWithFixedWeeks = broadcastCalendar ? 35 : 42;
@@ -3802,6 +3975,7 @@ function useControlledValue(defaultValue, controlledValue) {
3802
3975
 
3803
3976
  // node_modules/react-day-picker/dist/esm/useCalendar.js
3804
3977
  function useCalendar(props, dateLib) {
3978
+ var _a;
3805
3979
  const [navStart, navEnd] = getNavMonths(props, dateLib);
3806
3980
  const { startOfMonth: startOfMonth2, endOfMonth: endOfMonth2 } = dateLib;
3807
3981
  const initialMonth = getInitialMonth(props, navStart, navEnd, dateLib);
@@ -3814,13 +3988,44 @@ function useCalendar(props, dateLib) {
3814
3988
  const newInitialMonth = getInitialMonth(props, navStart, navEnd, dateLib);
3815
3989
  setFirstMonth(newInitialMonth);
3816
3990
  }, [props.timeZone]);
3817
- const displayMonths = getDisplayMonths(firstMonth, navEnd, props, dateLib);
3818
- const dates = getDates(displayMonths, props.endMonth ? endOfMonth2(props.endMonth) : void 0, props, dateLib);
3819
- const months = getMonths(displayMonths, dates, props, dateLib);
3820
- const weeks = getWeeks(months);
3821
- const days = getDays(months);
3822
- const previousMonth = getPreviousMonth(firstMonth, navStart, props, dateLib);
3823
- const nextMonth = getNextMonth(firstMonth, navEnd, props, dateLib);
3991
+ const { months, weeks, days, previousMonth, nextMonth } = useMemo(() => {
3992
+ const displayMonths = getDisplayMonths(firstMonth, navEnd, { numberOfMonths: props.numberOfMonths }, dateLib);
3993
+ const dates = getDates(displayMonths, props.endMonth ? endOfMonth2(props.endMonth) : void 0, {
3994
+ ISOWeek: props.ISOWeek,
3995
+ fixedWeeks: props.fixedWeeks,
3996
+ broadcastCalendar: props.broadcastCalendar
3997
+ }, dateLib);
3998
+ const months2 = getMonths(displayMonths, dates, {
3999
+ broadcastCalendar: props.broadcastCalendar,
4000
+ fixedWeeks: props.fixedWeeks,
4001
+ ISOWeek: props.ISOWeek,
4002
+ reverseMonths: props.reverseMonths
4003
+ }, dateLib);
4004
+ const weeks2 = getWeeks(months2);
4005
+ const days2 = getDays(months2);
4006
+ const previousMonth2 = getPreviousMonth(firstMonth, navStart, props, dateLib);
4007
+ const nextMonth2 = getNextMonth(firstMonth, navEnd, props, dateLib);
4008
+ return {
4009
+ months: months2,
4010
+ weeks: weeks2,
4011
+ days: days2,
4012
+ previousMonth: previousMonth2,
4013
+ nextMonth: nextMonth2
4014
+ };
4015
+ }, [
4016
+ dateLib,
4017
+ firstMonth.getTime(),
4018
+ navEnd == null ? void 0 : navEnd.getTime(),
4019
+ navStart == null ? void 0 : navStart.getTime(),
4020
+ props.disableNavigation,
4021
+ props.broadcastCalendar,
4022
+ (_a = props.endMonth) == null ? void 0 : _a.getTime(),
4023
+ props.fixedWeeks,
4024
+ props.ISOWeek,
4025
+ props.numberOfMonths,
4026
+ props.pagedNavigation,
4027
+ props.reverseMonths
4028
+ ]);
3824
4029
  const { disableNavigation, onMonthChange } = props;
3825
4030
  const isDayInCalendar = (day) => weeks.some((week) => week.days.some((d) => d.isEqualTo(day)));
3826
4031
  const goToMonth = (date) => {
@@ -3951,6 +4156,12 @@ function useFocus(props, calendar, getModifiers, isSelected, dateLib) {
3951
4156
  const nextFocus = getNextFocus(moveBy, moveDir, focusedDay, calendar.navStart, calendar.navEnd, props, dateLib);
3952
4157
  if (!nextFocus)
3953
4158
  return;
4159
+ if (props.disableNavigation) {
4160
+ const isNextInCalendar = calendar.days.some((day) => day.isEqualTo(nextFocus));
4161
+ if (!isNextInCalendar) {
4162
+ return;
4163
+ }
4164
+ }
3954
4165
  calendar.goToDay(nextFocus);
3955
4166
  setFocused(nextFocus);
3956
4167
  };
@@ -4211,40 +4422,110 @@ function useSelection(props, dateLib) {
4211
4422
  }
4212
4423
  }
4213
4424
 
4425
+ // node_modules/react-day-picker/dist/esm/utils/toTimeZone.js
4426
+ function toTimeZone(date, timeZone) {
4427
+ if (date instanceof TZDate && date.timeZone === timeZone) {
4428
+ return date;
4429
+ }
4430
+ return new TZDate(date, timeZone);
4431
+ }
4432
+
4433
+ // node_modules/react-day-picker/dist/esm/utils/convertMatchersToTimeZone.js
4434
+ function convertMatcher(matcher, timeZone) {
4435
+ if (typeof matcher === "boolean" || typeof matcher === "function") {
4436
+ return matcher;
4437
+ }
4438
+ if (matcher instanceof Date) {
4439
+ return toTimeZone(matcher, timeZone);
4440
+ }
4441
+ if (Array.isArray(matcher)) {
4442
+ return matcher.map((value) => value instanceof Date ? toTimeZone(value, timeZone) : value);
4443
+ }
4444
+ if (isDateRange(matcher)) {
4445
+ return __spreadProps(__spreadValues({}, matcher), {
4446
+ from: matcher.from ? toTimeZone(matcher.from, timeZone) : matcher.from,
4447
+ to: matcher.to ? toTimeZone(matcher.to, timeZone) : matcher.to
4448
+ });
4449
+ }
4450
+ if (isDateInterval(matcher)) {
4451
+ return {
4452
+ before: toTimeZone(matcher.before, timeZone),
4453
+ after: toTimeZone(matcher.after, timeZone)
4454
+ };
4455
+ }
4456
+ if (isDateAfterType(matcher)) {
4457
+ return {
4458
+ after: toTimeZone(matcher.after, timeZone)
4459
+ };
4460
+ }
4461
+ if (isDateBeforeType(matcher)) {
4462
+ return {
4463
+ before: toTimeZone(matcher.before, timeZone)
4464
+ };
4465
+ }
4466
+ return matcher;
4467
+ }
4468
+ function convertMatchersToTimeZone(matchers, timeZone) {
4469
+ if (!matchers) {
4470
+ return matchers;
4471
+ }
4472
+ if (Array.isArray(matchers)) {
4473
+ return matchers.map((matcher) => convertMatcher(matcher, timeZone));
4474
+ }
4475
+ return convertMatcher(matchers, timeZone);
4476
+ }
4477
+
4214
4478
  // node_modules/react-day-picker/dist/esm/DayPicker.js
4215
4479
  function DayPicker(initialProps) {
4216
4480
  var _a, _b;
4217
4481
  let props = initialProps;
4218
- if (props.timeZone) {
4219
- props = __spreadValues({}, initialProps);
4482
+ const timeZone = props.timeZone;
4483
+ if (timeZone) {
4484
+ props = __spreadProps(__spreadValues({}, initialProps), {
4485
+ timeZone
4486
+ });
4220
4487
  if (props.today) {
4221
- props.today = new TZDate(props.today, props.timeZone);
4488
+ props.today = toTimeZone(props.today, timeZone);
4222
4489
  }
4223
4490
  if (props.month) {
4224
- props.month = new TZDate(props.month, props.timeZone);
4491
+ props.month = toTimeZone(props.month, timeZone);
4225
4492
  }
4226
4493
  if (props.defaultMonth) {
4227
- props.defaultMonth = new TZDate(props.defaultMonth, props.timeZone);
4494
+ props.defaultMonth = toTimeZone(props.defaultMonth, timeZone);
4228
4495
  }
4229
4496
  if (props.startMonth) {
4230
- props.startMonth = new TZDate(props.startMonth, props.timeZone);
4497
+ props.startMonth = toTimeZone(props.startMonth, timeZone);
4231
4498
  }
4232
4499
  if (props.endMonth) {
4233
- props.endMonth = new TZDate(props.endMonth, props.timeZone);
4500
+ props.endMonth = toTimeZone(props.endMonth, timeZone);
4234
4501
  }
4235
4502
  if (props.mode === "single" && props.selected) {
4236
- props.selected = new TZDate(props.selected, props.timeZone);
4503
+ props.selected = toTimeZone(props.selected, timeZone);
4237
4504
  } else if (props.mode === "multiple" && props.selected) {
4238
- props.selected = (_a = props.selected) == null ? void 0 : _a.map((date) => new TZDate(date, props.timeZone));
4505
+ props.selected = (_a = props.selected) == null ? void 0 : _a.map((date) => toTimeZone(date, timeZone));
4239
4506
  } else if (props.mode === "range" && props.selected) {
4240
4507
  props.selected = {
4241
- from: props.selected.from ? new TZDate(props.selected.from, props.timeZone) : void 0,
4242
- to: props.selected.to ? new TZDate(props.selected.to, props.timeZone) : void 0
4508
+ from: props.selected.from ? toTimeZone(props.selected.from, timeZone) : props.selected.from,
4509
+ to: props.selected.to ? toTimeZone(props.selected.to, timeZone) : props.selected.to
4243
4510
  };
4244
4511
  }
4512
+ if (props.disabled !== void 0) {
4513
+ props.disabled = convertMatchersToTimeZone(props.disabled, timeZone);
4514
+ }
4515
+ if (props.hidden !== void 0) {
4516
+ props.hidden = convertMatchersToTimeZone(props.hidden, timeZone);
4517
+ }
4518
+ if (props.modifiers) {
4519
+ const nextModifiers = {};
4520
+ Object.keys(props.modifiers).forEach((key) => {
4521
+ var _a2;
4522
+ nextModifiers[key] = convertMatchersToTimeZone((_a2 = props.modifiers) == null ? void 0 : _a2[key], timeZone);
4523
+ });
4524
+ props.modifiers = nextModifiers;
4525
+ }
4245
4526
  }
4246
- const { components, formatters: formatters2, labels, dateLib, locale, classNames } = useMemo(() => {
4247
- const locale2 = __spreadValues(__spreadValues({}, enUS), props.locale);
4527
+ const { components, formatters: formatters2, labels, dateLib, locale, classNames } = useMemo2(() => {
4528
+ const locale2 = __spreadValues(__spreadValues({}, enUS2), props.locale);
4248
4529
  const dateLib2 = new DateLib({
4249
4530
  locale: locale2,
4250
4531
  weekStartsOn: props.broadcastCalendar ? 1 : props.weekStartsOn,
@@ -4258,7 +4539,7 @@ function DayPicker(initialProps) {
4258
4539
  dateLib: dateLib2,
4259
4540
  components: getComponents(props.components),
4260
4541
  formatters: getFormatters(props.formatters),
4261
- labels: __spreadValues(__spreadValues({}, labels_exports), props.labels),
4542
+ labels: getLabels(props.labels, dateLib2.options),
4262
4543
  locale: locale2,
4263
4544
  classNames: __spreadValues(__spreadValues({}, getDefaultClassNames()), props.classNames)
4264
4545
  };
@@ -4277,15 +4558,18 @@ function DayPicker(initialProps) {
4277
4558
  props.labels,
4278
4559
  props.classNames
4279
4560
  ]);
4561
+ if (!props.today) {
4562
+ props = __spreadProps(__spreadValues({}, props), { today: dateLib.today() });
4563
+ }
4280
4564
  const { captionLayout, mode, navLayout, numberOfMonths = 1, onDayBlur, onDayClick, onDayFocus, onDayKeyDown, onDayMouseEnter, onDayMouseLeave, onNextClick, onPrevClick, showWeekNumber, styles } = props;
4281
4565
  const { formatCaption: formatCaption2, formatDay: formatDay2, formatMonthDropdown: formatMonthDropdown2, formatWeekNumber: formatWeekNumber2, formatWeekNumberHeader: formatWeekNumberHeader2, formatWeekdayName: formatWeekdayName2, formatYearDropdown: formatYearDropdown2 } = formatters2;
4282
4566
  const calendar = useCalendar(props, dateLib);
4283
4567
  const { days, months, navStart, navEnd, previousMonth, nextMonth, goToMonth } = calendar;
4284
4568
  const getModifiers = createGetModifiers(days, props, navStart, navEnd, dateLib);
4285
4569
  const { isSelected, select, selected: selectedValue } = (_b = useSelection(props, dateLib)) != null ? _b : {};
4286
- const { blur, focused, isFocusTarget, moveFocus, setFocused } = useFocus(props, calendar, getModifiers, isSelected != null ? isSelected : () => false, dateLib);
4570
+ const { blur, focused, isFocusTarget, moveFocus, setFocused } = useFocus(props, calendar, getModifiers, isSelected != null ? isSelected : (() => false), dateLib);
4287
4571
  const { labelDayButton: labelDayButton2, labelGridcell: labelGridcell2, labelGrid: labelGrid2, labelMonthDropdown: labelMonthDropdown2, labelNav: labelNav2, labelPrevious: labelPrevious2, labelNext: labelNext2, labelWeekday: labelWeekday2, labelWeekNumber: labelWeekNumber2, labelWeekNumberHeader: labelWeekNumberHeader2, labelYearDropdown: labelYearDropdown2 } = labels;
4288
- const weekdays = useMemo(() => getWeekdays(dateLib, props.ISOWeek), [dateLib, props.ISOWeek]);
4572
+ const weekdays = useMemo2(() => getWeekdays(dateLib, props.ISOWeek, props.broadcastCalendar, props.today), [dateLib, props.ISOWeek, props.broadcastCalendar, props.today]);
4289
4573
  const isInteractive = mode !== void 0 || onDayClick !== void 0;
4290
4574
  const handlePreviousClick = useCallback2(() => {
4291
4575
  if (!previousMonth)
@@ -4303,6 +4587,9 @@ function DayPicker(initialProps) {
4303
4587
  e.preventDefault();
4304
4588
  e.stopPropagation();
4305
4589
  setFocused(day);
4590
+ if (m.disabled) {
4591
+ return;
4592
+ }
4306
4593
  select == null ? void 0 : select(day.date, m, e);
4307
4594
  onDayClick == null ? void 0 : onDayClick(day.date, m, e);
4308
4595
  }, [select, onDayClick, setFocused]);
@@ -4355,7 +4642,7 @@ function DayPicker(initialProps) {
4355
4642
  const month = dateLib.setYear(dateLib.startOfMonth(date), selectedYear);
4356
4643
  goToMonth(month);
4357
4644
  }, [dateLib, goToMonth]);
4358
- const { className, style } = useMemo(() => ({
4645
+ const { className, style } = useMemo2(() => ({
4359
4646
  className: [classNames[UI.Root], props.className].filter(Boolean).join(" "),
4360
4647
  style: __spreadValues(__spreadValues({}, styles == null ? void 0 : styles[UI.Root]), props.style)
4361
4648
  }), [classNames, props.className, props.style, styles]);
@@ -4388,7 +4675,7 @@ function DayPicker(initialProps) {
4388
4675
  { value: contextValue },
4389
4676
  React32.createElement(
4390
4677
  components.Root,
4391
- __spreadValues({ rootRef: props.animate ? rootElRef : void 0, className, style, dir: props.dir, id: props.id, lang: props.lang, nonce: props.nonce, title: props.title, role: props.role, "aria-label": props["aria-label"] }, dataAttributes),
4678
+ __spreadValues({ rootRef: props.animate ? rootElRef : void 0, className, style, dir: props.dir, id: props.id, lang: props.lang, nonce: props.nonce, title: props.title, role: props.role, "aria-label": props["aria-label"], "aria-labelledby": props["aria-labelledby"] }, dataAttributes),
4392
4679
  React32.createElement(
4393
4680
  components.Months,
4394
4681
  { className: classNames[UI.Months], style: styles == null ? void 0 : styles[UI.Months] },
@@ -4413,8 +4700,12 @@ function DayPicker(initialProps) {
4413
4700
  React32.createElement(components.MonthCaption, { "data-animated-caption": props.animate ? "true" : void 0, className: classNames[UI.MonthCaption], style: styles == null ? void 0 : styles[UI.MonthCaption], calendarMonth, displayIndex }, (captionLayout == null ? void 0 : captionLayout.startsWith("dropdown")) ? React32.createElement(
4414
4701
  components.DropdownNav,
4415
4702
  { className: classNames[UI.Dropdowns], style: styles == null ? void 0 : styles[UI.Dropdowns] },
4416
- captionLayout === "dropdown" || captionLayout === "dropdown-months" ? React32.createElement(components.MonthsDropdown, { className: classNames[UI.MonthsDropdown], "aria-label": labelMonthDropdown2(), classNames, components, disabled: Boolean(props.disableNavigation), onChange: handleMonthChange(calendarMonth.date), options: getMonthOptions(calendarMonth.date, navStart, navEnd, formatters2, dateLib), style: styles == null ? void 0 : styles[UI.Dropdown], value: dateLib.getMonth(calendarMonth.date) }) : React32.createElement("span", null, formatMonthDropdown2(calendarMonth.date, dateLib)),
4417
- captionLayout === "dropdown" || captionLayout === "dropdown-years" ? React32.createElement(components.YearsDropdown, { className: classNames[UI.YearsDropdown], "aria-label": labelYearDropdown2(dateLib.options), classNames, components, disabled: Boolean(props.disableNavigation), onChange: handleYearChange(calendarMonth.date), options: getYearOptions(navStart, navEnd, formatters2, dateLib, Boolean(props.reverseYears)), style: styles == null ? void 0 : styles[UI.Dropdown], value: dateLib.getYear(calendarMonth.date) }) : React32.createElement("span", null, formatYearDropdown2(calendarMonth.date, dateLib)),
4703
+ (() => {
4704
+ const monthControl = captionLayout === "dropdown" || captionLayout === "dropdown-months" ? React32.createElement(components.MonthsDropdown, { key: "month", className: classNames[UI.MonthsDropdown], "aria-label": labelMonthDropdown2(), classNames, components, disabled: Boolean(props.disableNavigation), onChange: handleMonthChange(calendarMonth.date), options: getMonthOptions(calendarMonth.date, navStart, navEnd, formatters2, dateLib), style: styles == null ? void 0 : styles[UI.Dropdown], value: dateLib.getMonth(calendarMonth.date) }) : React32.createElement("span", { key: "month" }, formatMonthDropdown2(calendarMonth.date, dateLib));
4705
+ const yearControl = captionLayout === "dropdown" || captionLayout === "dropdown-years" ? React32.createElement(components.YearsDropdown, { key: "year", className: classNames[UI.YearsDropdown], "aria-label": labelYearDropdown2(dateLib.options), classNames, components, disabled: Boolean(props.disableNavigation), onChange: handleYearChange(calendarMonth.date), options: getYearOptions(navStart, navEnd, formatters2, dateLib, Boolean(props.reverseYears)), style: styles == null ? void 0 : styles[UI.Dropdown], value: dateLib.getYear(calendarMonth.date) }) : React32.createElement("span", { key: "year" }, formatYearDropdown2(calendarMonth.date, dateLib));
4706
+ const controls = dateLib.getMonthYearOrder() === "year-first" ? [yearControl, monthControl] : [monthControl, yearControl];
4707
+ return controls;
4708
+ })(),
4418
4709
  React32.createElement("span", { role: "status", "aria-live": "polite", style: {
4419
4710
  border: 0,
4420
4711
  clip: "rect(0 0 0 0)",
@@ -4427,10 +4718,7 @@ function DayPicker(initialProps) {
4427
4718
  whiteSpace: "nowrap",
4428
4719
  wordWrap: "normal"
4429
4720
  } }, formatCaption2(calendarMonth.date, dateLib.options, dateLib))
4430
- ) : (
4431
- // biome-ignore lint/a11y/useSemanticElements: breaking change
4432
- React32.createElement(components.CaptionLabel, { className: classNames[UI.CaptionLabel], role: "status", "aria-live": "polite" }, formatCaption2(calendarMonth.date, dateLib.options, dateLib))
4433
- )),
4721
+ ) : React32.createElement(components.CaptionLabel, { className: classNames[UI.CaptionLabel], role: "status", "aria-live": "polite" }, formatCaption2(calendarMonth.date, dateLib.options, dateLib))),
4434
4722
  navLayout === "around" && !props.hideNavigation && displayIndex === numberOfMonths - 1 && React32.createElement(
4435
4723
  components.NextMonthButton,
4436
4724
  { type: "button", className: classNames[UI.NextMonthButton], tabIndex: nextMonth ? void 0 : -1, "aria-disabled": nextMonth ? void 0 : true, "aria-label": labelNext2(nextMonth), onClick: handleNextClick, "data-animated-button": props.animate ? "true" : void 0 },
@@ -4450,8 +4738,7 @@ function DayPicker(initialProps) {
4450
4738
  return React32.createElement(
4451
4739
  components.Week,
4452
4740
  { className: classNames[UI.Week], key: week.weekNumber, style: styles == null ? void 0 : styles[UI.Week], week },
4453
- showWeekNumber && // biome-ignore lint/a11y/useSemanticElements: react component
4454
- React32.createElement(components.WeekNumber, { week, style: styles == null ? void 0 : styles[UI.WeekNumber], "aria-label": labelWeekNumber2(week.weekNumber, {
4741
+ showWeekNumber && React32.createElement(components.WeekNumber, { week, style: styles == null ? void 0 : styles[UI.WeekNumber], "aria-label": labelWeekNumber2(week.weekNumber, {
4455
4742
  locale
4456
4743
  }), className: classNames[UI.WeekNumber], scope: "row", role: "rowheader" }, formatWeekNumber2(week.weekNumber, dateLib)),
4457
4744
  week.days.map((day) => {
@@ -4468,10 +4755,7 @@ function DayPicker(initialProps) {
4468
4755
  const style2 = getStyleForModifiers(modifiers, styles, props.modifiersStyles);
4469
4756
  const className2 = getClassNamesForModifiers(modifiers, classNames, props.modifiersClassNames);
4470
4757
  const ariaLabel = !isInteractive && !modifiers.hidden ? labelGridcell2(date, modifiers, dateLib.options, dateLib) : void 0;
4471
- return (
4472
- // biome-ignore lint/a11y/useSemanticElements: react component
4473
- React32.createElement(components.Day, { key: `${dateLib.format(date, "yyyy-MM-dd")}_${dateLib.format(day.displayMonth, "yyyy-MM")}`, day, modifiers, className: className2.join(" "), style: style2, role: "gridcell", "aria-selected": modifiers.selected || void 0, "aria-label": ariaLabel, "data-day": dateLib.format(date, "yyyy-MM-dd"), "data-month": day.outside ? dateLib.format(date, "yyyy-MM") : void 0, "data-selected": modifiers.selected || void 0, "data-disabled": modifiers.disabled || void 0, "data-hidden": modifiers.hidden || void 0, "data-outside": day.outside || void 0, "data-focused": modifiers.focused || void 0, "data-today": modifiers.today || void 0 }, !modifiers.hidden && isInteractive ? React32.createElement(components.DayButton, { className: classNames[UI.DayButton], style: styles == null ? void 0 : styles[UI.DayButton], type: "button", day, modifiers, disabled: modifiers.disabled || void 0, tabIndex: isFocusTarget(day) ? 0 : -1, "aria-label": labelDayButton2(date, modifiers, dateLib.options, dateLib), onClick: handleDayClick(day, modifiers), onBlur: handleDayBlur(day, modifiers), onFocus: handleDayFocus(day, modifiers), onKeyDown: handleDayKeyDown(day, modifiers), onMouseEnter: handleDayMouseEnter(day, modifiers), onMouseLeave: handleDayMouseLeave(day, modifiers) }, formatDay2(date, dateLib.options, dateLib)) : !modifiers.hidden && formatDay2(day.date, dateLib.options, dateLib))
4474
- );
4758
+ return React32.createElement(components.Day, { key: `${day.isoDate}_${day.displayMonthId}`, day, modifiers, className: className2.join(" "), style: style2, role: "gridcell", "aria-selected": modifiers.selected || void 0, "aria-label": ariaLabel, "data-day": day.isoDate, "data-month": day.outside ? day.dateMonthId : void 0, "data-selected": modifiers.selected || void 0, "data-disabled": modifiers.disabled || void 0, "data-hidden": modifiers.hidden || void 0, "data-outside": day.outside || void 0, "data-focused": modifiers.focused || void 0, "data-today": modifiers.today || void 0 }, !modifiers.hidden && isInteractive ? React32.createElement(components.DayButton, { className: classNames[UI.DayButton], style: styles == null ? void 0 : styles[UI.DayButton], type: "button", day, modifiers, disabled: !modifiers.focused && modifiers.disabled || void 0, "aria-disabled": modifiers.focused && modifiers.disabled || void 0, tabIndex: isFocusTarget(day) ? 0 : -1, "aria-label": labelDayButton2(date, modifiers, dateLib.options, dateLib), onClick: handleDayClick(day, modifiers), onBlur: handleDayBlur(day, modifiers), onFocus: handleDayFocus(day, modifiers), onKeyDown: handleDayKeyDown(day, modifiers), onMouseEnter: handleDayMouseEnter(day, modifiers), onMouseLeave: handleDayMouseLeave(day, modifiers) }, formatDay2(date, dateLib.options, dateLib)) : !modifiers.hidden && formatDay2(day.date, dateLib.options, dateLib));
4475
4759
  })
4476
4760
  );
4477
4761
  }))
@@ -4479,8 +4763,7 @@ function DayPicker(initialProps) {
4479
4763
  );
4480
4764
  })
4481
4765
  ),
4482
- props.footer && // biome-ignore lint/a11y/useSemanticElements: react component
4483
- React32.createElement(components.Footer, { className: classNames[UI.Footer], style: styles == null ? void 0 : styles[UI.Footer], role: "status", "aria-live": "polite" }, props.footer)
4766
+ props.footer && React32.createElement(components.Footer, { className: classNames[UI.Footer], style: styles == null ? void 0 : styles[UI.Footer], role: "status", "aria-live": "polite" }, props.footer)
4484
4767
  )
4485
4768
  );
4486
4769
  }
@@ -5518,7 +5801,6 @@ import { Asterisk } from "lucide-react";
5518
5801
 
5519
5802
  // src/components/input.tsx
5520
5803
  import * as React41 from "react";
5521
- import { Mail, Search, Eye, EyeOff } from "lucide-react";
5522
5804
  import { jsx as jsx17, jsxs as jsxs10 } from "react/jsx-runtime";
5523
5805
  var Input = React41.forwardRef(
5524
5806
  (_a, ref) => {
@@ -5528,6 +5810,7 @@ var Input = React41.forwardRef(
5528
5810
  size = "md",
5529
5811
  leading,
5530
5812
  trailing,
5813
+ classNameDefault = true,
5531
5814
  invalid = false,
5532
5815
  disabled
5533
5816
  } = _b, props = __objRest(_b, [
@@ -5536,6 +5819,7 @@ var Input = React41.forwardRef(
5536
5819
  "size",
5537
5820
  "leading",
5538
5821
  "trailing",
5822
+ "classNameDefault",
5539
5823
  "invalid",
5540
5824
  "disabled"
5541
5825
  ]);
@@ -5571,7 +5855,6 @@ var Input = React41.forwardRef(
5571
5855
  className: cn(
5572
5856
  "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 opacity-60",
5573
5857
  size === "lg" ? "text-[1.15rem]" : "text-[1rem]",
5574
- // no desplazamos visualmente en variantes sin padding
5575
5858
  variant === "flushed" || variant === "link" ? "hidden" : ""
5576
5859
  ),
5577
5860
  children: leading
@@ -5583,7 +5866,7 @@ var Input = React41.forwardRef(
5583
5866
  ref,
5584
5867
  "aria-invalid": invalid || void 0,
5585
5868
  disabled,
5586
- className: cn(
5869
+ className: classNameDefault ? cn(
5587
5870
  base,
5588
5871
  variants2[variant],
5589
5872
  variant === "flushed" ? specialSizeForFlushed : variant === "link" ? specialSizeForLink : sizeCls,
@@ -5591,7 +5874,8 @@ var Input = React41.forwardRef(
5591
5874
  iconPadLeft,
5592
5875
  iconPadRight,
5593
5876
  className
5594
- )
5877
+ ) : className,
5878
+ "data-private": true
5595
5879
  }, props)
5596
5880
  ),
5597
5881
  trailing ? /* @__PURE__ */ jsx17(
@@ -5609,7 +5893,6 @@ var Input = React41.forwardRef(
5609
5893
  }
5610
5894
  );
5611
5895
  Input.displayName = "Input";
5612
- Input.displayName = "Input";
5613
5896
 
5614
5897
  // src/components/Form/form-field.tsx
5615
5898
  import { jsx as jsx18, jsxs as jsxs11 } from "react/jsx-runtime";
@@ -5709,7 +5992,7 @@ var FormField = (_a) => {
5709
5992
  },
5710
5993
  placeholder,
5711
5994
  className: cn("bg-input px-[0.9rem] py-5", className),
5712
- classNameDefault: classNameDefault != null ? classNameDefault : true
5995
+ classNameDefault
5713
5996
  })
5714
5997
  ) }),
5715
5998
  fieldError && /* @__PURE__ */ jsx18(FormMessage, { className: messageClassName, children: fieldError })
@@ -6102,7 +6385,8 @@ var InputOTPSlot = React44.forwardRef((_a, ref) => {
6102
6385
  "relative flex h-9 w-9 items-center justify-center border-y border-r border-input text-sm shadow-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md",
6103
6386
  isActive && "z-10 ring-1 ring-ring",
6104
6387
  className
6105
- )
6388
+ ),
6389
+ "data-private": true
6106
6390
  }, props), {
6107
6391
  children: [
6108
6392
  char,
@@ -6832,7 +7116,7 @@ function SearchInput({
6832
7116
  value: searchTerm,
6833
7117
  onChange: (event) => setSearchTerm(event.target.value),
6834
7118
  className: cn("w-full md:max-w-sm", className),
6835
- classNameDefault: classNameDefault != null ? classNameDefault : true
7119
+ classNameDefault
6836
7120
  }
6837
7121
  );
6838
7122
  }
@@ -7755,7 +8039,7 @@ import {
7755
8039
  useReactTable
7756
8040
  } from "@tanstack/react-table";
7757
8041
  import { ChevronLeftIcon as ChevronLeftIcon2, ChevronRightIcon as ChevronRightIcon6 } from "lucide-react";
7758
- import { Fragment as Fragment2, jsx as jsx48, jsxs as jsxs23 } from "react/jsx-runtime";
8042
+ import { jsx as jsx48, jsxs as jsxs23 } from "react/jsx-runtime";
7759
8043
  function DataTable({
7760
8044
  columns,
7761
8045
  data,
@@ -7805,9 +8089,9 @@ function DataTable({
7805
8089
  if (onPageChange) {
7806
8090
  onPageChange(pagination.pageIndex + 1);
7807
8091
  }
7808
- }, [pagination]);
7809
- return /* @__PURE__ */ jsxs23(Fragment2, { children: [
7810
- /* @__PURE__ */ jsx48("div", { className: cn("rounded-md border", className), children: /* @__PURE__ */ jsxs23(ScrollArea, { className: "h-[calc(80vh-220px)] md:h-[calc(80dvh-80px)]", children: [
8092
+ }, [pagination, onPageChange]);
8093
+ return /* @__PURE__ */ jsxs23("div", { className: cn("rounded-md border bg-background flex flex-col", className), children: [
8094
+ /* @__PURE__ */ jsxs23(ScrollArea, { className: "h-[calc(80vh-220px)] md:h-[calc(80dvh-80px)]", children: [
7811
8095
  /* @__PURE__ */ jsxs23(Table, { className: cn("relative", tableClassName), children: [
7812
8096
  /* @__PURE__ */ jsx48(TableHeader, { className: headerClassName, children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ jsx48(TableRow, { className: rowClassName, children: headerGroup.headers.map((header) => /* @__PURE__ */ jsx48(TableHead, { className: headerClassName, children: header.isPlaceholder ? null : flexRender(
7813
8097
  header.column.columnDef.header,
@@ -7835,23 +8119,26 @@ function DataTable({
7835
8119
  ) }) })
7836
8120
  ] }),
7837
8121
  /* @__PURE__ */ jsx48(ScrollBar, { orientation: "horizontal" })
7838
- ] }) }),
7839
- /* @__PURE__ */ jsxs23("div", { className: "flex flex-col items-center justify-end gap-2 space-x-2 py-4 sm:flex-row", children: [
7840
- /* @__PURE__ */ jsxs23("div", { className: "flex w-full items-center justify-between", children: [
7841
- isRowsSelected ? /* @__PURE__ */ jsxs23("div", { className: "text-muted-foreground flex-1 text-sm", children: [
8122
+ ] }),
8123
+ /* @__PURE__ */ jsxs23("div", { className: "border-t px-4 py-4 flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between", children: [
8124
+ /* @__PURE__ */ jsxs23("div", { className: "flex flex-1 flex-wrap items-center gap-2", children: [
8125
+ isRowsSelected && /* @__PURE__ */ jsxs23("div", { className: "text-muted-foreground text-sm", children: [
7842
8126
  table.getFilteredSelectedRowModel().rows.length,
7843
8127
  " ",
7844
8128
  ofLabel,
7845
8129
  " ",
7846
8130
  table.getFilteredRowModel().rows.length,
7847
- " " + rowsSelectedLabel
7848
- ] }) : null,
8131
+ " ",
8132
+ rowsSelectedLabel
8133
+ ] }),
7849
8134
  totalRows ? /* @__PURE__ */ jsxs23("div", { className: "text-sm text-muted-foreground", children: [
7850
8135
  "Total: ",
7851
8136
  totalRows,
7852
8137
  " registros"
7853
- ] }) : null,
7854
- /* @__PURE__ */ jsxs23("div", { className: "flex items-center space-x-2", children: [
8138
+ ] }) : null
8139
+ ] }),
8140
+ /* @__PURE__ */ jsxs23("div", { className: "flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-end", children: [
8141
+ /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2", children: [
7855
8142
  /* @__PURE__ */ jsx48("p", { className: "text-sm font-medium whitespace-nowrap", children: rowPerPageLabel }),
7856
8143
  /* @__PURE__ */ jsxs23(
7857
8144
  Select2,
@@ -7871,19 +8158,17 @@ function DataTable({
7871
8158
  ]
7872
8159
  }
7873
8160
  )
7874
- ] })
7875
- ] }),
7876
- /* @__PURE__ */ jsxs23("div", { className: "flex w-full items-center justify-between gap-2 sm:justify-end", children: [
7877
- /* @__PURE__ */ jsxs23("div", { className: "flex w-[100px] items-center justify-center text-sm font-medium", children: [
7878
- pageLabel,
7879
- " ",
7880
- pagination.pageIndex + 1,
7881
- " ",
7882
- ofLabel,
7883
- " ",
7884
- pageCount
7885
8161
  ] }),
7886
- /* @__PURE__ */ jsxs23("div", { className: "flex items-center space-x-2", children: [
8162
+ /* @__PURE__ */ jsxs23("div", { className: "flex items-center gap-2", children: [
8163
+ /* @__PURE__ */ jsxs23("div", { className: "flex w-[110px] items-center justify-center text-sm font-medium", children: [
8164
+ pageLabel,
8165
+ " ",
8166
+ pagination.pageIndex + 1,
8167
+ " ",
8168
+ ofLabel,
8169
+ " ",
8170
+ pageCount
8171
+ ] }),
7887
8172
  /* @__PURE__ */ jsx48(
7888
8173
  Button,
7889
8174
  {
@@ -7981,7 +8266,7 @@ function DataTableSkeleton({
7981
8266
  // src/shared/fileupload.tsx
7982
8267
  import { AvatarIcon } from "@radix-ui/react-icons";
7983
8268
  import { CameraIcon } from "lucide-react";
7984
- import { useEffect as useEffect5, useState as useState6 } from "react";
8269
+ import { useEffect as useEffect5, useState as useState5 } from "react";
7985
8270
  import { useDropzone } from "react-dropzone";
7986
8271
  import { jsx as jsx50, jsxs as jsxs25 } from "react/jsx-runtime";
7987
8272
  function FileUpload({
@@ -8019,7 +8304,7 @@ function FileUpload({
8019
8304
  ) });
8020
8305
  }
8021
8306
  function ImagePreview({ file }) {
8022
- const [objectUrl, setObjectUrl] = useState6(null);
8307
+ const [objectUrl, setObjectUrl] = useState5(null);
8023
8308
  useEffect5(() => {
8024
8309
  const url = URL.createObjectURL(file);
8025
8310
  setObjectUrl(url);