@krosoft/react 0.0.89 → 0.0.91

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.
Files changed (117) hide show
  1. package/dist/{AppSubTitle-RKbtrPJr.js → AppSubTitle-CvJlatS9.js} +1 -1
  2. package/dist/{AppTitle-DCQpP2qE.js → AppTitle-LIQCjpo5.js} +26 -25
  3. package/dist/{AppVerticalTabs-pK3i9ZTD.js → AppVerticalTabs-BHrad7wu.js} +23 -23
  4. package/dist/ConfirmationDialog-BlRXnFH5.js +321 -0
  5. package/dist/ErrorAlert-BITMD2I5.js +33 -0
  6. package/dist/{LoadingState-DQjGcT2l.js → LoadingState-COf3KhOP.js} +6 -6
  7. package/dist/{MetricCard-DB1ME6tD.js → MetricCard-BGT2QRn0.js} +14 -13
  8. package/dist/{SearchInput-D_SLIZ2y.js → SearchInput-DpOuKSIf.js} +115 -126
  9. package/dist/{TableFilter-DXTOY-oa.js → TableFilter-DFtN_-Bg.js} +51 -51
  10. package/dist/{TableSettings-CBtuAPgM.js → TableSettings-m2q3s0wU.js} +68 -80
  11. package/dist/{ThemeSelector-CU8JmN2b.js → ThemeSelector-D9KTJAWz.js} +3 -3
  12. package/dist/{Topbar-BzZxu1Zi.js → Topbar-QKCJiWdO.js} +2 -2
  13. package/dist/{badge-DyRSpnOb.js → badge-C09fRxvd.js} +1 -1
  14. package/dist/card-Bn3Y7DHQ.js +48 -0
  15. package/dist/components/core/cards/index.js +1 -1
  16. package/dist/components/core/dialogs/ConfirmDeleteDialog.d.ts +10 -0
  17. package/dist/components/core/dialogs/ConfirmDeleteDialog.d.ts.map +1 -0
  18. package/dist/components/core/dialogs/ConfirmationDialog.d.ts +13 -0
  19. package/dist/components/core/dialogs/ConfirmationDialog.d.ts.map +1 -0
  20. package/dist/components/core/dialogs/index.d.ts +3 -0
  21. package/dist/components/core/dialogs/index.d.ts.map +1 -1
  22. package/dist/components/core/dialogs/index.js +15 -13
  23. package/dist/components/core/filters/index.js +1 -1
  24. package/dist/components/core/index.js +60 -56
  25. package/dist/components/core/inputs/index.js +1 -1
  26. package/dist/components/core/layouts/index.js +2 -2
  27. package/dist/components/core/navbar/index.js +1 -1
  28. package/dist/components/core/states/ErrorAlert.d.ts +7 -0
  29. package/dist/components/core/states/ErrorAlert.d.ts.map +1 -0
  30. package/dist/components/core/states/index.d.ts +1 -0
  31. package/dist/components/core/states/index.d.ts.map +1 -1
  32. package/dist/components/core/states/index.js +6 -4
  33. package/dist/components/core/table/index.js +1 -1
  34. package/dist/components/core/tabs/index.js +1 -1
  35. package/dist/components/core/theme/index.js +1 -1
  36. package/dist/components/index.js +280 -136
  37. package/dist/components/ui/accordion.d.ts +8 -0
  38. package/dist/components/ui/accordion.d.ts.map +1 -0
  39. package/dist/components/ui/alert-dialog.d.ts +21 -0
  40. package/dist/components/ui/alert-dialog.d.ts.map +1 -0
  41. package/dist/components/ui/aspect-ratio.d.ts +4 -0
  42. package/dist/components/ui/aspect-ratio.d.ts.map +1 -0
  43. package/dist/components/ui/avatar.d.ts +7 -0
  44. package/dist/components/ui/avatar.d.ts.map +1 -0
  45. package/dist/components/ui/breadcrumb.d.ts +20 -0
  46. package/dist/components/ui/breadcrumb.d.ts.map +1 -0
  47. package/dist/components/ui/button.d.ts +1 -1
  48. package/dist/components/ui/carousel.d.ts +19 -0
  49. package/dist/components/ui/carousel.d.ts.map +1 -0
  50. package/dist/components/ui/chart.d.ts +50 -0
  51. package/dist/components/ui/chart.d.ts.map +1 -0
  52. package/dist/components/ui/collapsible.d.ts +6 -0
  53. package/dist/components/ui/collapsible.d.ts.map +1 -0
  54. package/dist/components/ui/command.d.ts +83 -0
  55. package/dist/components/ui/command.d.ts.map +1 -0
  56. package/dist/components/ui/context-menu.d.ts +28 -0
  57. package/dist/components/ui/context-menu.d.ts.map +1 -0
  58. package/dist/components/ui/drawer.d.ts +23 -0
  59. package/dist/components/ui/drawer.d.ts.map +1 -0
  60. package/dist/components/ui/form.d.ts +24 -0
  61. package/dist/components/ui/form.d.ts.map +1 -0
  62. package/dist/components/ui/hover-card.d.ts +7 -0
  63. package/dist/components/ui/hover-card.d.ts.map +1 -0
  64. package/dist/components/ui/index.d.ts +42 -16
  65. package/dist/components/ui/index.d.ts.map +1 -1
  66. package/dist/components/ui/index.js +231 -91
  67. package/dist/components/ui/input-otp.d.ts +35 -0
  68. package/dist/components/ui/input-otp.d.ts.map +1 -0
  69. package/dist/components/ui/menubar.d.ts +34 -0
  70. package/dist/components/ui/menubar.d.ts.map +1 -0
  71. package/dist/components/ui/navigation-menu.d.ts +13 -0
  72. package/dist/components/ui/navigation-menu.d.ts.map +1 -0
  73. package/dist/components/ui/pagination.d.ts +33 -0
  74. package/dist/components/ui/pagination.d.ts.map +1 -0
  75. package/dist/components/ui/radio-group.d.ts +6 -0
  76. package/dist/components/ui/radio-group.d.ts.map +1 -0
  77. package/dist/components/ui/resizable.d.ts +8 -0
  78. package/dist/components/ui/resizable.d.ts.map +1 -0
  79. package/dist/components/ui/sheet.d.ts +1 -1
  80. package/dist/components/ui/sidebar.d.ts +67 -0
  81. package/dist/components/ui/sidebar.d.ts.map +1 -0
  82. package/dist/components/ui/simple-table.d.ts +11 -0
  83. package/dist/components/ui/simple-table.d.ts.map +1 -0
  84. package/dist/components/ui/slider.d.ts +5 -0
  85. package/dist/components/ui/slider.d.ts.map +1 -0
  86. package/dist/components/ui/sonner.d.ts +5 -0
  87. package/dist/components/ui/sonner.d.ts.map +1 -0
  88. package/dist/components/ui/switch.d.ts +5 -0
  89. package/dist/components/ui/switch.d.ts.map +1 -0
  90. package/dist/components/ui/textarea.d.ts +6 -0
  91. package/dist/components/ui/textarea.d.ts.map +1 -0
  92. package/dist/components/ui/toaster.d.ts +2 -0
  93. package/dist/components/ui/toaster.d.ts.map +1 -0
  94. package/dist/components/ui/toggle-group.d.ts +13 -0
  95. package/dist/components/ui/toggle-group.d.ts.map +1 -0
  96. package/dist/components/ui/toggle.d.ts +13 -0
  97. package/dist/components/ui/toggle.d.ts.map +1 -0
  98. package/dist/{ellipsis-vertical-CqrunffH.js → ellipsis-vertical-BVxSFNOa.js} +1 -1
  99. package/dist/grip-vertical-CJ07_87Y.js +18 -0
  100. package/dist/hooks/index.js +6 -5
  101. package/dist/index-DSyPHOLE.js +147 -0
  102. package/dist/{loader-circle-BhJXKs31.js → loader-circle-GAYBtm3z.js} +1 -1
  103. package/dist/{select-B5wF6jxC.js → select-D6_XPD6x.js} +309 -308
  104. package/dist/toaster-D6ND7OTk.js +113 -0
  105. package/dist/toggle-group-VJoGbVQm.js +19987 -0
  106. package/dist/{tooltip-BzTGwm2E.js → tooltip-CAu4DEhc.js} +767 -796
  107. package/dist/types/ConfirmDialogConfig.d.ts +11 -0
  108. package/dist/types/ConfirmDialogConfig.d.ts.map +1 -0
  109. package/dist/useTheme-Bn8z_uxy.js +31 -0
  110. package/dist/useToast-BFTk4lWz.js +100 -0
  111. package/package.json +29 -7
  112. package/dist/FormDialog-CXLQG83d.js +0 -250
  113. package/dist/card-7XPLAra3.js +0 -23
  114. package/dist/createLucideIcon-CRdjzt2A.js +0 -116
  115. package/dist/skeleton-CJ1F2tD3.js +0 -8
  116. package/dist/tabs-BYqvMsA6.js +0 -6628
  117. package/dist/useTheme-CvNYmhjo.js +0 -128
@@ -2,10 +2,11 @@ import { jsxs as s, jsx as e } from "react/jsx-runtime";
2
2
  import { formatNumber as h } from "@krosoft/core/helpers";
3
3
  import { useTranslation as b } from "react-i18next";
4
4
  import { c as d } from "./index-gWiv5-6R.js";
5
- import "./tabs-BYqvMsA6.js";
6
- import "./tooltip-BzTGwm2E.js";
7
- import { C as x, d as N, e as g, a as f } from "./card-7XPLAra3.js";
8
- import "./select-B5wF6jxC.js";
5
+ import "./toggle-group-VJoGbVQm.js";
6
+ import { C as u, f as N, g as x, c as f } from "./card-Bn3Y7DHQ.js";
7
+ import "./tooltip-CAu4DEhc.js";
8
+ import "./select-D6_XPD6x.js";
9
+ import "react";
9
10
  const v = ({
10
11
  titleKey: r,
11
12
  value: t,
@@ -17,9 +18,9 @@ const v = ({
17
18
  onClick: o
18
19
  }) => {
19
20
  const { t: m } = b();
20
- return /* @__PURE__ */ s(x, { className: d(o !== void 0 ? "hover:border-primary cursor-pointer" : ""), onClick: o, children: [
21
+ return /* @__PURE__ */ s(u, { className: d(o !== void 0 ? "hover:border-primary cursor-pointer" : ""), onClick: o, children: [
21
22
  /* @__PURE__ */ s(N, { className: "flex flex-row items-center justify-between space-y-0 pb-2", children: [
22
- /* @__PURE__ */ e(g, { className: "text-sm font-medium", children: m(r) }),
23
+ /* @__PURE__ */ e(x, { className: "text-sm font-medium", children: m(r) }),
23
24
  /* @__PURE__ */ e(a, { className: d("size-6 text-muted-foreground", c) })
24
25
  ] }),
25
26
  /* @__PURE__ */ s(f, { children: [
@@ -27,7 +28,7 @@ const v = ({
27
28
  /* @__PURE__ */ e("p", { className: d("text-xs text-muted-foreground", i), children: l })
28
29
  ] })
29
30
  ] });
30
- }, H = ({ stats: r }) => /* @__PURE__ */ e("div", { className: "grid gap-6 md:grid-cols-2 lg:grid-cols-4", children: r.map((t) => /* @__PURE__ */ e(
31
+ }, S = ({ stats: r }) => /* @__PURE__ */ e("div", { className: "grid gap-6 md:grid-cols-2 lg:grid-cols-4", children: r.map((t) => /* @__PURE__ */ e(
31
32
  v,
32
33
  {
33
34
  titleKey: t.titleKey,
@@ -55,12 +56,12 @@ const v = ({
55
56
  sm: "size-4",
56
57
  md: "size-5",
57
58
  lg: "size-6"
58
- }, y = (r) => r === "up" ? "↑" : r === "down" ? "↓" : "", K = (r) => r === "up" ? "text-green-600" : r === "down" ? "text-red-600" : "text-muted-foreground", S = ({ title: r, value: t, unit: n, subtitle: a, icon: c, iconSize: l = "md", trend: i, trendValue: o, color: m = "blue", children: u }) => {
59
+ }, y = (r) => r === "up" ? "↑" : r === "down" ? "↓" : "", K = (r) => r === "up" ? "text-green-600" : r === "down" ? "text-red-600" : "text-muted-foreground", q = ({ title: r, value: t, unit: n, subtitle: a, icon: c, iconSize: l = "md", trend: i, trendValue: o, color: m = "blue", children: g }) => {
59
60
  const p = c;
60
- return /* @__PURE__ */ e(x, { className: "relative overflow-hidden bg-card border shadow-lg hover:shadow-xl transition-all duration-300", children: /* @__PURE__ */ s(f, { className: "pt-6", children: [
61
+ return /* @__PURE__ */ e(u, { className: "relative overflow-hidden bg-card border shadow-lg hover:shadow-xl transition-all duration-300", children: /* @__PURE__ */ s(f, { className: "pt-6", children: [
61
62
  /* @__PURE__ */ s("div", { className: "flex items-start justify-between", children: [
62
63
  /* @__PURE__ */ s("div", { children: [
63
- /* @__PURE__ */ e(g, { className: "text-sm font-medium text-muted-foreground", children: r }),
64
+ /* @__PURE__ */ e(x, { className: "text-sm font-medium text-muted-foreground", children: r }),
64
65
  /* @__PURE__ */ s("div", { className: "flex items-baseline space-x-2 mt-1", children: [
65
66
  /* @__PURE__ */ e("div", { className: "text-2xl font-bold text-card-foreground", children: typeof t == "number" ? t.toFixed(1) : t }),
66
67
  n && /* @__PURE__ */ e("div", { className: "text-sm text-muted-foreground font-medium", children: n })
@@ -73,11 +74,11 @@ const v = ({
73
74
  ] }),
74
75
  /* @__PURE__ */ e("div", { className: `p-2 rounded-lg ${C[m]} shadow-lg`, children: /* @__PURE__ */ e(p, { className: w[l] }) })
75
76
  ] }),
76
- u && /* @__PURE__ */ e("div", { className: "mt-4", children: u })
77
+ g && /* @__PURE__ */ e("div", { className: "mt-4", children: g })
77
78
  ] }) });
78
79
  };
79
80
  export {
80
81
  v as K,
81
- S as M,
82
- H as a
82
+ q as M,
83
+ S as a
83
84
  };
@@ -1,12 +1,12 @@
1
1
  import { jsxs as d, jsx as n } from "react/jsx-runtime";
2
2
  import * as L from "react";
3
3
  import { useState as P, useRef as j, useEffect as T, useMemo as z } from "react";
4
- import { a9 as E, aa as C, ab as k, ac as q, ad as S, C as R, E as X, G as _, a6 as D, F as V, l as O, I } from "./tabs-BYqvMsA6.js";
5
- import { B as y, C as A } from "./tooltip-BzTGwm2E.js";
6
- import "./card-7XPLAra3.js";
4
+ import { ch as D, ci as C, cj as k, ck as q, cl as S, H as R, bp as F, br as X, c7 as E, bq as V, c8 as J, U as O, aQ as _ } from "./toggle-group-VJoGbVQm.js";
5
+ import "./card-Bn3Y7DHQ.js";
7
6
  import { c as b } from "./index-gWiv5-6R.js";
8
- import { C as Q } from "./select-B5wF6jxC.js";
9
- import { c as F } from "./createLucideIcon-CRdjzt2A.js";
7
+ import { B as y, C as A } from "./tooltip-CAu4DEhc.js";
8
+ import { C as I } from "./select-D6_XPD6x.js";
9
+ import { c as Q } from "./index-DSyPHOLE.js";
10
10
  /**
11
11
  * @license lucide-react v1.16.0 - ISC
12
12
  *
@@ -18,17 +18,7 @@ const Y = [
18
18
  ["path", { d: "M16 2v4", key: "4m81vk" }],
19
19
  ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
20
20
  ["path", { d: "M3 10h18", key: "8toen8" }]
21
- ], H = F("calendar", Y);
22
- /**
23
- * @license lucide-react v1.16.0 - ISC
24
- *
25
- * This source code is licensed under the ISC license.
26
- * See the LICENSE file in the root directory of this source tree.
27
- */
28
- const $ = [
29
- ["path", { d: "m21 21-4.34-4.34", key: "14j7rj" }],
30
- ["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }]
31
- ], J = F("search", $), B = {
21
+ ], H = Q("calendar", Y), $ = {
32
22
  lessThanXSeconds: {
33
23
  one: "moins d’une seconde",
34
24
  other: "moins de {{count}} secondes"
@@ -90,10 +80,10 @@ const $ = [
90
80
  one: "presqu’un an",
91
81
  other: "presque {{count}} ans"
92
82
  }
93
- }, G = (e, t, s) => {
83
+ }, B = (e, t, s) => {
94
84
  let r;
95
- const i = B[e];
96
- return typeof i == "string" ? r = i : t === 1 ? r = i.one : r = i.other.replace("{{count}}", String(t)), s != null && s.addSuffix ? s.comparison && s.comparison > 0 ? "dans " + r : "il y a " + r : r;
85
+ const o = $[e];
86
+ return typeof o == "string" ? r = o : t === 1 ? r = o.one : r = o.other.replace("{{count}}", String(t)), s != null && s.addSuffix ? s.comparison && s.comparison > 0 ? "dans " + r : "il y a " + r : r;
97
87
  }, K = {
98
88
  full: "EEEE d MMMM y",
99
89
  long: "d MMMM y",
@@ -104,40 +94,40 @@ const $ = [
104
94
  long: "HH:mm:ss z",
105
95
  medium: "HH:mm:ss",
106
96
  short: "HH:mm"
107
- }, Z = {
97
+ }, G = {
108
98
  full: "{{date}} 'à' {{time}}",
109
99
  long: "{{date}} 'à' {{time}}",
110
100
  medium: "{{date}}, {{time}}",
111
101
  short: "{{date}}, {{time}}"
112
- }, ee = {
113
- date: E({
102
+ }, Z = {
103
+ date: D({
114
104
  formats: K,
115
105
  defaultWidth: "full"
116
106
  }),
117
- time: E({
107
+ time: D({
118
108
  formats: U,
119
109
  defaultWidth: "full"
120
110
  }),
121
- dateTime: E({
122
- formats: Z,
111
+ dateTime: D({
112
+ formats: G,
123
113
  defaultWidth: "full"
124
114
  })
125
- }, te = {
115
+ }, ee = {
126
116
  lastWeek: "eeee 'dernier à' p",
127
117
  yesterday: "'hier à' p",
128
118
  today: "'aujourd’hui à' p",
129
119
  tomorrow: "'demain à' p'",
130
120
  nextWeek: "eeee 'prochain à' p",
131
121
  other: "P"
132
- }, ne = (e, t, s, r) => te[e], re = {
122
+ }, te = (e, t, s, r) => ee[e], ne = {
133
123
  narrow: ["av. J.-C", "ap. J.-C"],
134
124
  abbreviated: ["av. J.-C", "ap. J.-C"],
135
125
  wide: ["avant Jésus-Christ", "après Jésus-Christ"]
136
- }, ae = {
126
+ }, re = {
137
127
  narrow: ["T1", "T2", "T3", "T4"],
138
128
  abbreviated: ["1er trim.", "2ème trim.", "3ème trim.", "4ème trim."],
139
129
  wide: ["1er trimestre", "2ème trimestre", "3ème trimestre", "4ème trimestre"]
140
- }, oe = {
130
+ }, ae = {
141
131
  narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
142
132
  abbreviated: [
143
133
  "janv.",
@@ -180,7 +170,7 @@ const $ = [
180
170
  "vendredi",
181
171
  "samedi"
182
172
  ]
183
- }, se = {
173
+ }, oe = {
184
174
  narrow: {
185
175
  am: "AM",
186
176
  pm: "PM",
@@ -211,30 +201,30 @@ const $ = [
211
201
  evening: "du soir",
212
202
  night: "du matin"
213
203
  }
214
- }, le = (e, t) => {
204
+ }, se = (e, t) => {
215
205
  const s = Number(e), r = t == null ? void 0 : t.unit;
216
206
  if (s === 0) return "0";
217
- const i = ["year", "week", "hour", "minute", "second"];
207
+ const o = ["year", "week", "hour", "minute", "second"];
218
208
  let l;
219
- return s === 1 ? l = r && i.includes(r) ? "ère" : "er" : l = "ème", s + l;
220
- }, de = ["MMM", "MMMM"], ce = {
209
+ return s === 1 ? l = r && o.includes(r) ? "ère" : "er" : l = "ème", s + l;
210
+ }, le = ["MMM", "MMMM"], de = {
221
211
  preprocessor: (e, t) => e.getDate() === 1 || !t.some(
222
- (r) => r.isToken && de.includes(r.value)
212
+ (r) => r.isToken && le.includes(r.value)
223
213
  ) ? t : t.map(
224
214
  (r) => r.isToken && r.value === "do" ? { isToken: !0, value: "d" } : r
225
215
  ),
226
- ordinalNumber: le,
216
+ ordinalNumber: se,
227
217
  era: C({
228
- values: re,
218
+ values: ne,
229
219
  defaultWidth: "wide"
230
220
  }),
231
221
  quarter: C({
232
- values: ae,
222
+ values: re,
233
223
  defaultWidth: "wide",
234
224
  argumentCallback: (e) => e - 1
235
225
  }),
236
226
  month: C({
237
- values: oe,
227
+ values: ae,
238
228
  defaultWidth: "wide"
239
229
  }),
240
230
  day: C({
@@ -242,26 +232,26 @@ const $ = [
242
232
  defaultWidth: "wide"
243
233
  }),
244
234
  dayPeriod: C({
245
- values: se,
235
+ values: oe,
246
236
  defaultWidth: "wide"
247
237
  })
248
- }, ue = /^(\d+)(ième|ère|ème|er|e)?/i, me = /\d+/i, fe = {
238
+ }, ce = /^(\d+)(ième|ère|ème|er|e)?/i, ue = /\d+/i, me = {
249
239
  narrow: /^(av\.J\.C|ap\.J\.C|ap\.J\.-C)/i,
250
240
  abbreviated: /^(av\.J\.-C|av\.J-C|apr\.J\.-C|apr\.J-C|ap\.J-C)/i,
251
241
  wide: /^(avant Jésus-Christ|après Jésus-Christ)/i
252
- }, he = {
242
+ }, fe = {
253
243
  any: [/^av/i, /^ap/i]
254
- }, pe = {
244
+ }, he = {
255
245
  narrow: /^T?[1234]/i,
256
246
  abbreviated: /^[1234](er|ème|e)? trim\.?/i,
257
247
  wide: /^[1234](er|ème|e)? trimestre/i
258
- }, ve = {
248
+ }, pe = {
259
249
  any: [/1/i, /2/i, /3/i, /4/i]
260
- }, ge = {
250
+ }, ve = {
261
251
  narrow: /^[jfmasond]/i,
262
252
  abbreviated: /^(janv|févr|mars|avr|mai|juin|juill|juil|août|sept|oct|nov|déc)\.?/i,
263
253
  wide: /^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i
264
- }, be = {
254
+ }, ge = {
265
255
  narrow: [
266
256
  /^j/i,
267
257
  /^f/i,
@@ -290,18 +280,18 @@ const $ = [
290
280
  /^n/i,
291
281
  /^d/i
292
282
  ]
293
- }, ye = {
283
+ }, be = {
294
284
  narrow: /^[lmjvsd]/i,
295
285
  short: /^(di|lu|ma|me|je|ve|sa)/i,
296
286
  abbreviated: /^(dim|lun|mar|mer|jeu|ven|sam)\.?/i,
297
287
  wide: /^(dimanche|lundi|mardi|mercredi|jeudi|vendredi|samedi)/i
298
- }, xe = {
288
+ }, ye = {
299
289
  narrow: [/^d/i, /^l/i, /^m/i, /^m/i, /^j/i, /^v/i, /^s/i],
300
290
  any: [/^di/i, /^lu/i, /^ma/i, /^me/i, /^je/i, /^ve/i, /^sa/i]
301
291
  }, we = {
302
292
  narrow: /^(a|p|minuit|midi|mat\.?|ap\.?m\.?|soir|nuit)/i,
303
293
  any: /^([ap]\.?\s?m\.?|du matin|de l'après[-\s]midi|du soir|de la nuit)/i
304
- }, Me = {
294
+ }, xe = {
305
295
  any: {
306
296
  am: /^a/i,
307
297
  pm: /^p/i,
@@ -312,69 +302,69 @@ const $ = [
312
302
  evening: /soir/i,
313
303
  night: /nuit/i
314
304
  }
315
- }, Ne = {
305
+ }, Me = {
316
306
  ordinalNumber: q({
317
- matchPattern: ue,
318
- parsePattern: me,
307
+ matchPattern: ce,
308
+ parsePattern: ue,
319
309
  valueCallback: (e) => parseInt(e)
320
310
  }),
321
311
  era: k({
322
- matchPatterns: fe,
312
+ matchPatterns: me,
323
313
  defaultMatchWidth: "wide",
324
- parsePatterns: he,
314
+ parsePatterns: fe,
325
315
  defaultParseWidth: "any"
326
316
  }),
327
317
  quarter: k({
328
- matchPatterns: pe,
318
+ matchPatterns: he,
329
319
  defaultMatchWidth: "wide",
330
- parsePatterns: ve,
320
+ parsePatterns: pe,
331
321
  defaultParseWidth: "any",
332
322
  valueCallback: (e) => e + 1
333
323
  }),
334
324
  month: k({
335
- matchPatterns: ge,
325
+ matchPatterns: ve,
336
326
  defaultMatchWidth: "wide",
337
- parsePatterns: be,
327
+ parsePatterns: ge,
338
328
  defaultParseWidth: "any"
339
329
  }),
340
330
  day: k({
341
- matchPatterns: ye,
331
+ matchPatterns: be,
342
332
  defaultMatchWidth: "wide",
343
- parsePatterns: xe,
333
+ parsePatterns: ye,
344
334
  defaultParseWidth: "any"
345
335
  }),
346
336
  dayPeriod: k({
347
337
  matchPatterns: we,
348
338
  defaultMatchWidth: "any",
349
- parsePatterns: Me,
339
+ parsePatterns: xe,
350
340
  defaultParseWidth: "any"
351
341
  })
352
342
  }, W = {
353
343
  code: "fr",
354
- formatDistance: G,
355
- formatLong: ee,
356
- formatRelative: ne,
357
- localize: ce,
358
- match: Ne,
344
+ formatDistance: B,
345
+ formatLong: Z,
346
+ formatRelative: te,
347
+ localize: de,
348
+ match: Me,
359
349
  options: {
360
350
  weekStartsOn: 1,
361
351
  firstWeekContainsDate: 4
362
352
  }
363
- }, Ee = ({ date: e, onDateChange: t, placeholder: s }) => {
364
- const [r, i] = P(!1), l = j(null);
353
+ }, Le = ({ date: e, onDateChange: t, placeholder: s }) => {
354
+ const [r, o] = P(!1), l = j(null);
365
355
  T(() => {
366
356
  if (!r) return;
367
357
  const u = (f) => {
368
- l.current !== null && !l.current.contains(f.target) && i(!1);
358
+ l.current !== null && !l.current.contains(f.target) && o(!1);
369
359
  };
370
360
  return document.addEventListener("mousedown", u), () => {
371
361
  document.removeEventListener("mousedown", u);
372
362
  };
373
363
  }, [r]);
374
364
  const m = () => {
375
- i((u) => !u);
365
+ o((u) => !u);
376
366
  }, c = (u) => {
377
- t(u), i(!1);
367
+ t(u), o(!1);
378
368
  };
379
369
  return /* @__PURE__ */ d("div", { ref: l, className: "relative w-full", children: [
380
370
  /* @__PURE__ */ d(
@@ -397,23 +387,23 @@ const $ = [
397
387
  r ? /* @__PURE__ */ n("div", { className: "absolute left-0 top-[calc(100%+4px)] z-[100] rounded-md border bg-popover text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 slide-in-from-top-2", children: /* @__PURE__ */ n(R, { mode: "single", selected: e, onSelect: c }) }) : null
398
388
  ] });
399
389
  }, De = ({ value: e, onChange: t, placeholder: s = "Selectionner une periode", className: r }) => {
400
- const [i, l] = L.useState(!1), [m, c] = L.useState(e);
390
+ const [o, l] = L.useState(!1), [m, c] = L.useState(e);
401
391
  L.useEffect(() => {
402
- i && c(e);
403
- }, [i, e]);
392
+ o && c(e);
393
+ }, [o, e]);
404
394
  const u = (h) => {
405
395
  h.stopPropagation(), t(void 0), l(!1);
406
396
  }, f = () => {
407
397
  t(m), l(!1);
408
398
  }, p = () => {
409
399
  c(e), l(!1);
410
- }, x = () => {
400
+ }, w = () => {
411
401
  c(void 0);
412
- }, w = (h) => h != null && h.from ? !h.to || h.from.getTime() === h.to.getTime() ? S(h.from, "dd MMM yyyy", { locale: W }) : `${S(h.from, "dd MMM yyyy", { locale: W })} - ${S(h.to, "dd MMM yyyy", { locale: W })}` : s;
413
- return /* @__PURE__ */ n("div", { className: b("grid gap-2", r), children: /* @__PURE__ */ d(X, { open: i, onOpenChange: l, children: [
414
- /* @__PURE__ */ n(_, { asChild: !0, children: /* @__PURE__ */ d(y, { id: "date", variant: "outline", className: b("w-[300px] justify-start text-left font-normal", !(e != null && e.from) && "text-muted-foreground"), children: [
402
+ }, x = (h) => h != null && h.from ? !h.to || h.from.getTime() === h.to.getTime() ? S(h.from, "dd MMM yyyy", { locale: W }) : `${S(h.from, "dd MMM yyyy", { locale: W })} - ${S(h.to, "dd MMM yyyy", { locale: W })}` : s;
403
+ return /* @__PURE__ */ n("div", { className: b("grid gap-2", r), children: /* @__PURE__ */ d(F, { open: o, onOpenChange: l, children: [
404
+ /* @__PURE__ */ n(X, { asChild: !0, children: /* @__PURE__ */ d(y, { id: "date", variant: "outline", className: b("w-[300px] justify-start text-left font-normal", !(e != null && e.from) && "text-muted-foreground"), children: [
415
405
  /* @__PURE__ */ n(H, { className: "mr-2 size-4" }),
416
- w(e),
406
+ x(e),
417
407
  (e == null ? void 0 : e.from) && /* @__PURE__ */ n(
418
408
  y,
419
409
  {
@@ -423,7 +413,7 @@ const $ = [
423
413
  "aria-label": "Effacer la periode selectionnee",
424
414
  className: "ml-auto h-5 w-5 opacity-50 hover:opacity-100",
425
415
  onClick: u,
426
- children: /* @__PURE__ */ n(D, { className: "size-4" })
416
+ children: /* @__PURE__ */ n(E, { className: "size-4" })
427
417
  }
428
418
  )
429
419
  ] }) }),
@@ -441,7 +431,7 @@ const $ = [
441
431
  }
442
432
  ),
443
433
  /* @__PURE__ */ d("div", { className: "flex items-center justify-between border-t border-border px-3 py-2", children: [
444
- /* @__PURE__ */ n(y, { variant: "ghost", size: "sm", onClick: x, children: "Effacer" }),
434
+ /* @__PURE__ */ n(y, { variant: "ghost", size: "sm", onClick: w, children: "Effacer" }),
445
435
  /* @__PURE__ */ d("div", { className: "flex gap-2", children: [
446
436
  /* @__PURE__ */ n(y, { variant: "ghost", size: "sm", onClick: p, children: "Annuler" }),
447
437
  /* @__PURE__ */ n(y, { size: "sm", onClick: f, children: "Appliquer" })
@@ -449,17 +439,17 @@ const $ = [
449
439
  ] })
450
440
  ] })
451
441
  ] }) });
452
- }, Je = ({
442
+ }, Ee = ({
453
443
  options: e,
454
444
  selected: t,
455
445
  onToggle: s,
456
446
  onClear: r,
457
- onSelectAll: i,
447
+ onSelectAll: o,
458
448
  placeholder: l = "Sélectionner...",
459
449
  searchable: m = !1,
460
450
  searchPlaceholder: c = "Rechercher..."
461
451
  }) => {
462
- const [u, f] = P(""), [p, x] = P(!1), w = j(null), h = j(null), g = z(() => u === "" ? e : e.filter((a) => a.label.toLowerCase().includes(u.toLowerCase())), [e, u]), o = z(() => g.length === 0 ? !1 : g.every((a) => t.includes(a.value)), [g, t]);
452
+ const [u, f] = P(""), [p, w] = P(!1), x = j(null), h = j(null), g = z(() => u === "" ? e : e.filter((a) => a.label.toLowerCase().includes(u.toLowerCase())), [e, u]), i = z(() => g.length === 0 ? !1 : g.every((a) => t.includes(a.value)), [g, t]);
463
453
  T(() => {
464
454
  p && m && requestAnimationFrame(() => {
465
455
  var a;
@@ -468,33 +458,33 @@ const $ = [
468
458
  }, [p, m]), T(() => {
469
459
  if (!p) return;
470
460
  const a = (v) => {
471
- w.current !== null && !w.current.contains(v.target) && (x(!1), f(""));
461
+ x.current !== null && !x.current.contains(v.target) && (w(!1), f(""));
472
462
  };
473
463
  return document.addEventListener("mousedown", a), () => {
474
464
  document.removeEventListener("mousedown", a);
475
465
  };
476
466
  }, [p]);
477
467
  const M = () => {
478
- if (o) {
468
+ if (i) {
479
469
  const a = g.map((N) => N.value), v = t.filter((N) => !a.includes(N));
480
- i !== void 0 ? i(v) : r();
470
+ o !== void 0 ? o(v) : r();
481
471
  } else {
482
472
  const a = [...t];
483
473
  g.forEach((v) => {
484
474
  a.includes(v.value) || a.push(v.value);
485
- }), i !== void 0 ? i(a) : g.forEach((v) => {
475
+ }), o !== void 0 ? o(a) : g.forEach((v) => {
486
476
  t.includes(v.value) || s(v.value);
487
477
  });
488
478
  }
489
479
  };
490
- return /* @__PURE__ */ d("div", { ref: w, className: "relative w-full", children: [
480
+ return /* @__PURE__ */ d("div", { ref: x, className: "relative w-full", children: [
491
481
  /* @__PURE__ */ d(
492
482
  y,
493
483
  {
494
484
  variant: "outline",
495
485
  type: "button",
496
486
  onClick: () => {
497
- x((a) => (a && f(""), !a));
487
+ w((a) => (a && f(""), !a));
498
488
  },
499
489
  className: b(
500
490
  "w-full justify-between text-left font-normal focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
@@ -515,7 +505,7 @@ const $ = [
515
505
  a.stopPropagation(), r();
516
506
  },
517
507
  className: "rounded-full p-0.5 opacity-50 transition-opacity hover:opacity-100",
518
- children: /* @__PURE__ */ n(D, { className: "h-3.5 w-3.5" })
508
+ children: /* @__PURE__ */ n(E, { className: "h-3.5 w-3.5" })
519
509
  }
520
510
  ),
521
511
  /* @__PURE__ */ n(A, { className: b("h-4 w-4 opacity-50 transition-transform", p && "rotate-180") })
@@ -541,7 +531,7 @@ const $ = [
541
531
  ] }) }) : null,
542
532
  /* @__PURE__ */ d("div", { className: "flex flex-col gap-0.5 max-h-56 overflow-y-auto p-1.5", children: [
543
533
  g.length > 0 && /* @__PURE__ */ d("label", { className: "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors", children: [
544
- /* @__PURE__ */ n(O, { checked: o, onCheckedChange: M }),
534
+ /* @__PURE__ */ n(O, { checked: i, onCheckedChange: M }),
545
535
  "Tout sélectionner"
546
536
  ] }),
547
537
  g.length === 0 && /* @__PURE__ */ n("p", { className: "px-2 py-3 text-center text-xs text-muted-foreground", children: "Aucun résultat" }),
@@ -569,34 +559,34 @@ const $ = [
569
559
  ) })
570
560
  ] }) : null
571
561
  ] });
572
- }, Oe = ({
562
+ }, Je = ({
573
563
  options: e,
574
564
  value: t,
575
565
  onChange: s,
576
566
  placeholder: r = "Sélectionner...",
577
- searchPlaceholder: i = "Rechercher..."
567
+ searchPlaceholder: o = "Rechercher..."
578
568
  }) => {
579
- const [l, m] = P(""), [c, u] = P(!1), f = j(null), p = j(null), x = z(() => l === "" ? e : e.filter((o) => o.label.toLowerCase().includes(l.toLowerCase())), [e, l]), w = z(() => {
580
- var o;
569
+ const [l, m] = P(""), [c, u] = P(!1), f = j(null), p = j(null), w = z(() => l === "" ? e : e.filter((i) => i.label.toLowerCase().includes(l.toLowerCase())), [e, l]), x = z(() => {
570
+ var i;
581
571
  if (!(t === void 0 || t === ""))
582
- return ((o = e.find((M) => M.value === t)) == null ? void 0 : o.label) ?? t;
572
+ return ((i = e.find((M) => M.value === t)) == null ? void 0 : i.label) ?? t;
583
573
  }, [e, t]);
584
574
  T(() => {
585
575
  c && requestAnimationFrame(() => {
586
- var o;
587
- (o = p.current) == null || o.focus();
576
+ var i;
577
+ (i = p.current) == null || i.focus();
588
578
  });
589
579
  }, [c]), T(() => {
590
580
  if (!c) return;
591
- const o = (M) => {
581
+ const i = (M) => {
592
582
  f.current !== null && !f.current.contains(M.target) && (u(!1), m(""));
593
583
  };
594
- return document.addEventListener("mousedown", o), () => {
595
- document.removeEventListener("mousedown", o);
584
+ return document.addEventListener("mousedown", i), () => {
585
+ document.removeEventListener("mousedown", i);
596
586
  };
597
587
  }, [c]);
598
- const h = (o) => {
599
- s(o), u(!1), m("");
588
+ const h = (i) => {
589
+ s(i), u(!1), m("");
600
590
  };
601
591
  return /* @__PURE__ */ d("div", { ref: f, className: "relative w-full", children: [
602
592
  /* @__PURE__ */ d(
@@ -605,7 +595,7 @@ const $ = [
605
595
  variant: "outline",
606
596
  type: "button",
607
597
  onClick: () => {
608
- u((o) => (o && m(""), !o));
598
+ u((i) => (i && m(""), !i));
609
599
  },
610
600
  className: b(
611
601
  "w-full justify-between text-left font-normal focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
@@ -613,7 +603,7 @@ const $ = [
613
603
  (t === void 0 || t === "") && "text-muted-foreground"
614
604
  ),
615
605
  children: [
616
- /* @__PURE__ */ n("span", { className: "truncate", children: w ?? r }),
606
+ /* @__PURE__ */ n("span", { className: "truncate", children: x ?? r }),
617
607
  /* @__PURE__ */ n(A, { className: b("h-4 w-4 opacity-50 shrink-0 transition-transform", c && "rotate-180") })
618
608
  ]
619
609
  }
@@ -626,43 +616,43 @@ const $ = [
626
616
  {
627
617
  ref: p,
628
618
  className: "w-full rounded-md bg-muted/50 py-1.5 pl-7 pr-2 text-sm text-foreground placeholder:text-muted-foreground outline-none focus:ring-1 focus:ring-ring",
629
- placeholder: i,
619
+ placeholder: o,
630
620
  value: l,
631
- onChange: (o) => {
632
- m(o.target.value);
621
+ onChange: (i) => {
622
+ m(i.target.value);
633
623
  }
634
624
  }
635
625
  )
636
626
  ] }) }),
637
627
  /* @__PURE__ */ d("div", { className: "flex flex-col gap-0.5 max-h-56 overflow-y-auto p-1.5", children: [
638
- x.length === 0 && /* @__PURE__ */ n("p", { className: "px-2 py-3 text-center text-xs text-muted-foreground", children: "Aucun résultat" }),
639
- x.map((o) => /* @__PURE__ */ d(
628
+ w.length === 0 && /* @__PURE__ */ n("p", { className: "px-2 py-3 text-center text-xs text-muted-foreground", children: "Aucun résultat" }),
629
+ w.map((i) => /* @__PURE__ */ d(
640
630
  "button",
641
631
  {
642
632
  type: "button",
643
633
  onClick: () => {
644
- h(o.value);
634
+ h(i.value);
645
635
  },
646
636
  className: b(
647
637
  "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors text-left w-full",
648
- t === o.value && "bg-muted font-medium"
638
+ t === i.value && "bg-muted font-medium"
649
639
  ),
650
640
  children: [
651
- /* @__PURE__ */ n(Q, { className: b("size-3.5 shrink-0", t === o.value ? "opacity-100" : "opacity-0") }),
652
- o.label
641
+ /* @__PURE__ */ n(I, { className: b("size-3.5 shrink-0", t === i.value ? "opacity-100" : "opacity-0") }),
642
+ i.label
653
643
  ]
654
644
  },
655
- o.value
645
+ i.value
656
646
  ))
657
647
  ] })
658
648
  ] }) : null
659
649
  ] });
660
- }, Re = ({
650
+ }, Oe = ({
661
651
  searchQuery: e,
662
652
  search: t,
663
653
  placeholder: s = "Rechercher...",
664
654
  onSearch: r,
665
- onSubmit: i,
655
+ onSubmit: o,
666
656
  onClear: l,
667
657
  className: m
668
658
  }) => {
@@ -672,7 +662,7 @@ const $ = [
672
662
  return /* @__PURE__ */ d("div", { className: b("relative h-fit w-full md:w-64", m), children: [
673
663
  /* @__PURE__ */ n(J, { className: "absolute left-3 top-1/2 transform -translate-y-1/2 text-muted-foreground w-4 h-4" }),
674
664
  /* @__PURE__ */ n(
675
- I,
665
+ _,
676
666
  {
677
667
  placeholder: s,
678
668
  value: c,
@@ -681,18 +671,17 @@ const $ = [
681
671
  },
682
672
  className: "pl-8",
683
673
  onKeyDown: (f) => {
684
- f.key === "Enter" && i !== void 0 && (f.preventDefault(), i());
674
+ f.key === "Enter" && o !== void 0 && (f.preventDefault(), o());
685
675
  }
686
676
  }
687
677
  ),
688
- c !== "" ? /* @__PURE__ */ n("button", { onClick: u, className: "absolute right-3 top-1/2 -translate-y-1/2 text-gray-500 hover:text-gray-700", type: "button", children: /* @__PURE__ */ n(D, { className: "size-4" }) }) : null
678
+ c !== "" ? /* @__PURE__ */ n("button", { onClick: u, className: "absolute right-3 top-1/2 -translate-y-1/2 text-gray-500 hover:text-gray-700", type: "button", children: /* @__PURE__ */ n(E, { className: "size-4" }) }) : null
689
679
  ] });
690
680
  };
691
681
  export {
692
- Ee as D,
693
- Je as M,
694
- Re as S,
682
+ Le as D,
683
+ Ee as M,
684
+ Oe as S,
695
685
  De as a,
696
- Oe as b,
697
- J as c
686
+ Je as b
698
687
  };