@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
@@ -1,13 +1,13 @@
1
- import { jsxs as m, jsx as r } from "react/jsx-runtime";
1
+ import { jsxs as p, jsx as r } from "react/jsx-runtime";
2
2
  import { useState as k, useEffect as M, useMemo as A } from "react";
3
- import { M as O, a as $, D as I, b as R, c as _, S as j } from "./SearchInput-D_SLIZ2y.js";
4
- import { a6 as C, I as E, K as z, W as Q, N as V, R as B, V as H, L as G, Q as K, E as W, G as X, F as J, l as P } from "./tabs-BYqvMsA6.js";
5
- import { B as w, C as U } from "./tooltip-BzTGwm2E.js";
6
- import "./card-7XPLAra3.js";
7
- import { S as Y, h as Z, i as q, a as ee, c as re } from "./select-B5wF6jxC.js";
8
- import { B as L } from "./badge-DyRSpnOb.js";
3
+ import { M as O, a as $, D as z, b as _, S as j } from "./SearchInput-DpOuKSIf.js";
4
+ import { c7 as C, aQ as P, bx as B, bG as I, bz as Q, bC as R, bF as V, aV as H, bB as G, bp as U, br as X, bq as J, c8 as K, U as E } from "./toggle-group-VJoGbVQm.js";
5
+ import "./card-Bn3Y7DHQ.js";
6
+ import { B as w, C as W } from "./tooltip-CAu4DEhc.js";
7
+ import { S as Y, h as Z, i as q, a as ee, c as re } from "./select-D6_XPD6x.js";
8
+ import { B as L } from "./badge-C09fRxvd.js";
9
9
  import { c as te } from "./index-gWiv5-6R.js";
10
- import { c as le } from "./createLucideIcon-CRdjzt2A.js";
10
+ import { c as le } from "./index-DSyPHOLE.js";
11
11
  /**
12
12
  * @license lucide-react v1.16.0 - ISC
13
13
  *
@@ -29,15 +29,15 @@ const ae = [
29
29
  return i !== void 0 ? i : s.includes("ok") || l === "true" || l === "false" ? l === "true" ? "Oui" : "Non" : o;
30
30
  };
31
31
  function ce({ filters: s, onRemoveFilter: l, onClearAll: a, filterLabels: o = {}, optionLabels: i = {} }) {
32
- const d = Object.entries(s).filter(([n, p]) => !(p == null || p === "" || Array.isArray(p) && p.length === 0));
33
- return d.length === 0 ? null : /* @__PURE__ */ m("div", { className: "flex flex-wrap items-center gap-2 mb-4", children: [
32
+ const d = Object.entries(s).filter(([n, m]) => !(m == null || m === "" || Array.isArray(m) && m.length === 0));
33
+ return d.length === 0 ? null : /* @__PURE__ */ p("div", { className: "flex flex-wrap items-center gap-2 mb-4", children: [
34
34
  /* @__PURE__ */ r("span", { className: "text-sm text-gray-600 font-medium", children: "Filtres actifs :" }),
35
- d.flatMap(([n, p]) => {
35
+ d.flatMap(([n, m]) => {
36
36
  const f = o[n] ?? n;
37
- if (Array.isArray(p))
38
- return p.map((v) => {
37
+ if (Array.isArray(m))
38
+ return m.map((v) => {
39
39
  const b = T(n, v, i);
40
- return /* @__PURE__ */ m(
40
+ return /* @__PURE__ */ p(
41
41
  L,
42
42
  {
43
43
  variant: "secondary",
@@ -61,8 +61,8 @@ function ce({ filters: s, onRemoveFilter: l, onClearAll: a, filterLabels: o = {}
61
61
  `${n}_${String(v)}`
62
62
  );
63
63
  });
64
- const x = T(n, p, i);
65
- return /* @__PURE__ */ m(L, { variant: "secondary", className: "flex items-center gap-1 px-3 py-1 bg-blue-50 text-blue-700 border border-blue-200 hover:bg-blue-100", children: [
64
+ const x = T(n, m, i);
65
+ return /* @__PURE__ */ p(L, { variant: "secondary", className: "flex items-center gap-1 px-3 py-1 bg-blue-50 text-blue-700 border border-blue-200 hover:bg-blue-100", children: [
66
66
  f,
67
67
  ": ",
68
68
  x,
@@ -86,7 +86,7 @@ const ne = ({ field: s, value: l, onChange: a, onToggleMultiSelect: o }) => {
86
86
  switch (s.type) {
87
87
  case "text":
88
88
  return /* @__PURE__ */ r(
89
- E,
89
+ P,
90
90
  {
91
91
  placeholder: s.placeholder,
92
92
  value: l ?? "",
@@ -97,7 +97,7 @@ const ne = ({ field: s, value: l, onChange: a, onToggleMultiSelect: o }) => {
97
97
  );
98
98
  case "number":
99
99
  return /* @__PURE__ */ r(
100
- E,
100
+ P,
101
101
  {
102
102
  type: "number",
103
103
  placeholder: s.placeholder,
@@ -111,7 +111,7 @@ const ne = ({ field: s, value: l, onChange: a, onToggleMultiSelect: o }) => {
111
111
  );
112
112
  case "select":
113
113
  return s.searchable === !0 ? /* @__PURE__ */ r(
114
- R,
114
+ _,
115
115
  {
116
116
  options: s.options ?? [],
117
117
  value: l,
@@ -119,12 +119,12 @@ const ne = ({ field: s, value: l, onChange: a, onToggleMultiSelect: o }) => {
119
119
  placeholder: s.placeholder,
120
120
  searchPlaceholder: s.searchPlaceholder
121
121
  }
122
- ) : /* @__PURE__ */ m(Y, { value: l ?? "", onValueChange: a, children: [
122
+ ) : /* @__PURE__ */ p(Y, { value: l ?? "", onValueChange: a, children: [
123
123
  /* @__PURE__ */ r(Z, { className: te((l === void 0 || l === "") && "text-muted-foreground"), children: /* @__PURE__ */ r(q, { placeholder: s.placeholder }) }),
124
124
  /* @__PURE__ */ r(ee, { children: (i = s.options) == null ? void 0 : i.map((d) => /* @__PURE__ */ r(re, { value: d.value, children: d.label }, d.value)) })
125
125
  ] });
126
126
  case "date":
127
- return /* @__PURE__ */ r(I, { date: l, onDateChange: a, placeholder: s.placeholder ?? "Sélectionner une date" });
127
+ return /* @__PURE__ */ r(z, { date: l, onDateChange: a, placeholder: s.placeholder ?? "Sélectionner une date" });
128
128
  case "date-range":
129
129
  return /* @__PURE__ */ r($, { value: l, onChange: a, placeholder: s.placeholder });
130
130
  case "multi-select":
@@ -154,36 +154,36 @@ function oe({
154
154
  buttonText: o = "Plus de filtres",
155
155
  sheetTitle: i = "Filtres avancés"
156
156
  }) {
157
- const [d, n] = k(!1), [p, f] = k(l);
157
+ const [d, n] = k(!1), [m, f] = k(l);
158
158
  M(() => {
159
159
  f(l);
160
160
  }, [l, d]);
161
161
  const x = (g, t) => {
162
162
  f((h) => ({ ...h, [g]: t }));
163
163
  }, v = (g, t) => {
164
- const h = p[g], e = Array.isArray(h) ? h : [], u = e.includes(t) ? e.filter((c) => c !== t) : [...e, t];
164
+ const h = m[g], e = Array.isArray(h) ? h : [], u = e.includes(t) ? e.filter((c) => c !== t) : [...e, t];
165
165
  x(g, u);
166
166
  }, b = () => {
167
- a(p), n(!1);
167
+ a(m), n(!1);
168
168
  }, N = () => {
169
169
  f({}), a({}), n(!1);
170
170
  };
171
- return /* @__PURE__ */ m(z, { open: d, onOpenChange: n, children: [
172
- /* @__PURE__ */ r(Q, { asChild: !0, children: /* @__PURE__ */ m(w, { variant: "outline", className: "gap-2", children: [
171
+ return /* @__PURE__ */ p(B, { open: d, onOpenChange: n, children: [
172
+ /* @__PURE__ */ r(I, { asChild: !0, children: /* @__PURE__ */ p(w, { variant: "outline", className: "gap-2", children: [
173
173
  /* @__PURE__ */ r(se, { className: "size-4 shrink-0" }),
174
174
  o
175
175
  ] }) }),
176
- /* @__PURE__ */ m(V, { side: "right", className: "w-[400px] sm:w-[500px] flex flex-col p-0", children: [
177
- /* @__PURE__ */ r(B, { className: "p-6 pb-0", children: /* @__PURE__ */ r(H, { children: i }) }),
178
- /* @__PURE__ */ r("div", { className: "flex-1 overflow-y-auto p-6 pt-6", children: /* @__PURE__ */ r("div", { className: "space-y-6", children: s.map((g, t) => /* @__PURE__ */ m("div", { className: "space-y-4", children: [
176
+ /* @__PURE__ */ p(Q, { side: "right", className: "w-[400px] sm:w-[500px] flex flex-col p-0", children: [
177
+ /* @__PURE__ */ r(R, { className: "p-6 pb-0", children: /* @__PURE__ */ r(V, { children: i }) }),
178
+ /* @__PURE__ */ r("div", { className: "flex-1 overflow-y-auto p-6 pt-6", children: /* @__PURE__ */ r("div", { className: "space-y-6", children: s.map((g, t) => /* @__PURE__ */ p("div", { className: "space-y-4", children: [
179
179
  /* @__PURE__ */ r("h3", { className: "font-semibold text-sm text-gray-900 dark:text-gray-100 border-b pb-2", children: g.title }),
180
- g.filters.map((h) => /* @__PURE__ */ m("div", { className: "space-y-2", children: [
181
- /* @__PURE__ */ r(G, { htmlFor: h.key, children: h.label }),
180
+ g.filters.map((h) => /* @__PURE__ */ p("div", { className: "space-y-2", children: [
181
+ /* @__PURE__ */ r(H, { htmlFor: h.key, children: h.label }),
182
182
  /* @__PURE__ */ r(
183
183
  ne,
184
184
  {
185
185
  field: h,
186
- value: p[h.key],
186
+ value: m[h.key],
187
187
  onChange: (e) => {
188
188
  x(h.key, e);
189
189
  },
@@ -194,7 +194,7 @@ function oe({
194
194
  )
195
195
  ] }, h.key))
196
196
  ] }, t)) }) }),
197
- /* @__PURE__ */ m(K, { className: "gap-2 p-6 border-t bg-white dark:bg-gray-950", children: [
197
+ /* @__PURE__ */ p(G, { className: "gap-2 p-6 border-t bg-white dark:bg-gray-950", children: [
198
198
  /* @__PURE__ */ r(w, { variant: "outline", className: "flex-1", onClick: N, children: "Effacer les filtres" }),
199
199
  /* @__PURE__ */ r(w, { className: "flex-1 bg-orange-500 hover:bg-orange-600 text-white", onClick: b, children: "Rechercher" })
200
200
  ] })
@@ -209,7 +209,7 @@ function ie({
209
209
  onClear: i,
210
210
  onSelectAll: d,
211
211
  searchable: n = !1,
212
- searchPlaceholder: p = "Rechercher..."
212
+ searchPlaceholder: m = "Rechercher..."
213
213
  }) {
214
214
  const [f, x] = k(""), v = a.length > 0, b = A(() => f === "" ? l : l.filter((t) => t.label.toLowerCase().includes(f.toLowerCase())), [l, f]), N = A(() => b.length === 0 ? !1 : b.every((t) => a.includes(t.value)), [b, a]), g = () => {
215
215
  if (N)
@@ -229,32 +229,32 @@ function ie({
229
229
  a.includes(t.value) || o(t.value);
230
230
  });
231
231
  };
232
- return /* @__PURE__ */ m(
233
- W,
232
+ return /* @__PURE__ */ p(
233
+ U,
234
234
  {
235
235
  onOpenChange: () => {
236
236
  x("");
237
237
  },
238
238
  children: [
239
- /* @__PURE__ */ r(X, { asChild: !0, children: /* @__PURE__ */ m(
239
+ /* @__PURE__ */ r(X, { asChild: !0, children: /* @__PURE__ */ p(
240
240
  "button",
241
241
  {
242
242
  className: `inline-flex items-center gap-1.5 rounded-full border px-3 py-1.5 text-sm transition-colors whitespace-nowrap ${v ? "border-primary bg-primary/10 text-primary font-medium" : "border-border bg-card text-card-foreground hover:bg-muted"}`,
243
243
  children: [
244
244
  s,
245
245
  a.length > 0 && /* @__PURE__ */ r("span", { className: "flex h-4 min-w-[16px] items-center justify-center rounded-full bg-primary px-1 text-[10px] font-bold text-primary-foreground", children: a.length }),
246
- /* @__PURE__ */ r(U, { className: "size-3.5 opacity-60" })
246
+ /* @__PURE__ */ r(W, { className: "size-3.5 opacity-60" })
247
247
  ]
248
248
  }
249
249
  ) }),
250
- /* @__PURE__ */ m(J, { className: "w-56 p-0", align: "start", children: [
251
- n ? /* @__PURE__ */ r("div", { className: "border-b border-border p-2", children: /* @__PURE__ */ m("div", { className: "relative", children: [
252
- /* @__PURE__ */ r(_, { className: "absolute left-2 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-muted-foreground" }),
250
+ /* @__PURE__ */ p(J, { className: "w-56 p-0", align: "start", children: [
251
+ n ? /* @__PURE__ */ r("div", { className: "border-b border-border p-2", children: /* @__PURE__ */ p("div", { className: "relative", children: [
252
+ /* @__PURE__ */ r(K, { className: "absolute left-2 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-muted-foreground" }),
253
253
  /* @__PURE__ */ r(
254
254
  "input",
255
255
  {
256
256
  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",
257
- placeholder: p,
257
+ placeholder: m,
258
258
  value: f,
259
259
  onChange: (t) => {
260
260
  x(t.target.value);
@@ -263,15 +263,15 @@ function ie({
263
263
  }
264
264
  )
265
265
  ] }) }) : null,
266
- /* @__PURE__ */ m("div", { className: "flex flex-col gap-0.5 max-h-56 overflow-y-auto p-1.5", children: [
267
- b.length > 0 && /* @__PURE__ */ m("label", { className: "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors", children: [
268
- /* @__PURE__ */ r(P, { checked: N, onCheckedChange: g }),
266
+ /* @__PURE__ */ p("div", { className: "flex flex-col gap-0.5 max-h-56 overflow-y-auto p-1.5", children: [
267
+ b.length > 0 && /* @__PURE__ */ p("label", { className: "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors", children: [
268
+ /* @__PURE__ */ r(E, { checked: N, onCheckedChange: g }),
269
269
  "Tout sélectionner"
270
270
  ] }),
271
271
  b.length === 0 && /* @__PURE__ */ r("p", { className: "px-2 py-3 text-center text-xs text-muted-foreground", children: "Aucun résultat" }),
272
- b.map((t) => /* @__PURE__ */ m("label", { className: "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors", children: [
272
+ b.map((t) => /* @__PURE__ */ p("label", { className: "flex items-center gap-2.5 rounded-md px-2 py-2 text-sm hover:bg-muted cursor-pointer transition-colors", children: [
273
273
  /* @__PURE__ */ r(
274
- P,
274
+ E,
275
275
  {
276
276
  checked: a.includes(t.value),
277
277
  onCheckedChange: () => {
@@ -307,7 +307,7 @@ function ye({
307
307
  onFiltersChange: i,
308
308
  filterLabels: d = {},
309
309
  sections: n,
310
- advancedButtonText: p = "Filtres",
310
+ advancedButtonText: m = "Filtres",
311
311
  sheetTitle: f = "Filtres avancés"
312
312
  }) {
313
313
  const x = (e, u) => {
@@ -351,8 +351,8 @@ function ye({
351
351
  });
352
352
  }), e;
353
353
  }, [n]);
354
- return /* @__PURE__ */ m("div", { className: "space-y-4 w-full", children: [
355
- /* @__PURE__ */ r("div", { className: "flex flex-wrap items-center gap-3 justify-between", children: /* @__PURE__ */ m("div", { className: "flex flex-wrap items-center gap-3", children: [
354
+ return /* @__PURE__ */ p("div", { className: "space-y-4 w-full", children: [
355
+ /* @__PURE__ */ r("div", { className: "flex flex-wrap items-center gap-3 justify-between", children: /* @__PURE__ */ p("div", { className: "flex flex-wrap items-center gap-3", children: [
356
356
  l !== void 0 ? /* @__PURE__ */ r(
357
357
  j,
358
358
  {
@@ -384,7 +384,7 @@ function ye({
384
384
  },
385
385
  e.key
386
386
  )),
387
- n.length > 0 && /* @__PURE__ */ r(oe, { sections: n, filters: o, onFiltersChange: i, buttonText: p, sheetTitle: f })
387
+ n.length > 0 && /* @__PURE__ */ r(oe, { sections: n, filters: o, onFiltersChange: i, buttonText: m, sheetTitle: f })
388
388
  ] }) }),
389
389
  /* @__PURE__ */ r(
390
390
  ce,
@@ -1,11 +1,13 @@
1
1
  import { jsxs as t, jsx as e } from "react/jsx-runtime";
2
- import { m as j, B as M, o as D, q as A, l as _, a7 as B, a8 as L, n as I } from "./tabs-BYqvMsA6.js";
3
- import { B as x } from "./tooltip-BzTGwm2E.js";
4
- import "./card-7XPLAra3.js";
5
- import "./select-B5wF6jxC.js";
6
- import { E as V } from "./ellipsis-vertical-CqrunffH.js";
7
- import { L as q } from "./loader-circle-BhJXKs31.js";
8
- import { c as b } from "./createLucideIcon-CRdjzt2A.js";
2
+ import { ar as M, aF as j, at as D, av as A, U as S, cf as L, cg as B, as as I } from "./toggle-group-VJoGbVQm.js";
3
+ import "./card-Bn3Y7DHQ.js";
4
+ import { B as x } from "./tooltip-CAu4DEhc.js";
5
+ import "./select-D6_XPD6x.js";
6
+ import "react";
7
+ import { E as V } from "./ellipsis-vertical-BVxSFNOa.js";
8
+ import { L as q } from "./loader-circle-GAYBtm3z.js";
9
+ import { G as U } from "./grip-vertical-CJ07_87Y.js";
10
+ import { c as f } from "./index-DSyPHOLE.js";
9
11
  /**
10
12
  * @license lucide-react v1.16.0 - ISC
11
13
  *
@@ -15,19 +17,19 @@ import { c as b } from "./createLucideIcon-CRdjzt2A.js";
15
17
  const E = [
16
18
  ["path", { d: "M12 5v14", key: "s699le" }],
17
19
  ["path", { d: "m19 12-7 7-7-7", key: "1idqje" }]
18
- ], H = b("arrow-down", E);
20
+ ], G = f("arrow-down", E);
19
21
  /**
20
22
  * @license lucide-react v1.16.0 - ISC
21
23
  *
22
24
  * This source code is licensed under the ISC license.
23
25
  * See the LICENSE file in the root directory of this source tree.
24
26
  */
25
- const U = [
27
+ const H = [
26
28
  ["path", { d: "m21 16-4 4-4-4", key: "f6ql7i" }],
27
29
  ["path", { d: "M17 20V4", key: "1ejh1v" }],
28
30
  ["path", { d: "m3 8 4-4 4 4", key: "11wl7u" }],
29
31
  ["path", { d: "M7 4v16", key: "1glfcx" }]
30
- ], G = b("arrow-up-down", U);
32
+ ], F = f("arrow-up-down", H);
31
33
  /**
32
34
  * @license lucide-react v1.16.0 - ISC
33
35
  *
@@ -37,28 +39,14 @@ const U = [
37
39
  const O = [
38
40
  ["path", { d: "m5 12 7-7 7 7", key: "hav0vg" }],
39
41
  ["path", { d: "M12 19V5", key: "x0mq9r" }]
40
- ], F = b("arrow-up", O);
42
+ ], J = f("arrow-up", O);
41
43
  /**
42
44
  * @license lucide-react v1.16.0 - ISC
43
45
  *
44
46
  * This source code is licensed under the ISC license.
45
47
  * See the LICENSE file in the root directory of this source tree.
46
48
  */
47
- const J = [
48
- ["circle", { cx: "9", cy: "12", r: "1", key: "1vctgf" }],
49
- ["circle", { cx: "9", cy: "5", r: "1", key: "hp0tcf" }],
50
- ["circle", { cx: "9", cy: "19", r: "1", key: "fkjjf6" }],
51
- ["circle", { cx: "15", cy: "12", r: "1", key: "1tmaij" }],
52
- ["circle", { cx: "15", cy: "5", r: "1", key: "19l28e" }],
53
- ["circle", { cx: "15", cy: "19", r: "1", key: "f4zoj3" }]
54
- ], Q = b("grip-vertical", J);
55
- /**
56
- * @license lucide-react v1.16.0 - ISC
57
- *
58
- * This source code is licensed under the ISC license.
59
- * See the LICENSE file in the root directory of this source tree.
60
- */
61
- const W = [
49
+ const Q = [
62
50
  [
63
51
  "path",
64
52
  {
@@ -67,10 +55,10 @@ const W = [
67
55
  }
68
56
  ],
69
57
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
70
- ], X = b("settings", W);
71
- function Y({ actions: c, row: n }) {
72
- return /* @__PURE__ */ t(j, { children: [
73
- /* @__PURE__ */ e(M, { asChild: !0, children: /* @__PURE__ */ e(x, { variant: "ghost", size: "icon", className: "h-8 w-8 text-muted-foreground hover:text-foreground", children: /* @__PURE__ */ e(V, { className: "size-4" }) }) }),
58
+ ], W = f("settings", Q);
59
+ function X({ actions: l, row: n }) {
60
+ return /* @__PURE__ */ t(M, { children: [
61
+ /* @__PURE__ */ e(j, { asChild: !0, children: /* @__PURE__ */ e(x, { variant: "ghost", size: "icon", className: "h-8 w-8 text-muted-foreground hover:text-foreground", children: /* @__PURE__ */ e(V, { className: "size-4" }) }) }),
74
62
  /* @__PURE__ */ e(
75
63
  D,
76
64
  {
@@ -78,7 +66,7 @@ function Y({ actions: c, row: n }) {
78
66
  onClick: (s) => {
79
67
  s.stopPropagation();
80
68
  },
81
- children: c.map((s, a) => {
69
+ children: l.map((s, a) => {
82
70
  const o = s.icon;
83
71
  return /* @__PURE__ */ t(
84
72
  A,
@@ -99,15 +87,15 @@ function Y({ actions: c, row: n }) {
99
87
  )
100
88
  ] });
101
89
  }
102
- function se({
103
- isLoading: c,
90
+ function ne({
91
+ isLoading: l,
104
92
  colSpanCount: n,
105
93
  noDataMessage: s,
106
94
  paginatedData: a,
107
95
  getRowId: o,
108
- onRowClick: l,
96
+ onRowClick: c,
109
97
  hasBulkActions: u,
110
- selectedRows: f,
98
+ selectedRows: b,
111
99
  toggleRowSelection: g,
112
100
  visibleColumnsArray: i,
113
101
  columnWidths: k,
@@ -122,7 +110,7 @@ function se({
122
110
  const y = h[m];
123
111
  return /* @__PURE__ */ e("span", { className: "text-sm truncate", children: y != null ? String(y) : "-" });
124
112
  };
125
- return c ? /* @__PURE__ */ e("tbody", { className: "divide-y divide-gray-200 dark:divide-gray-800", children: /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e("td", { colSpan: n, className: "py-8 text-center", children: /* @__PURE__ */ t("div", { className: "flex flex-col items-center justify-center gap-2 text-muted-foreground", children: [
113
+ return l ? /* @__PURE__ */ e("tbody", { className: "divide-y divide-gray-200 dark:divide-gray-800", children: /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e("td", { colSpan: n, className: "py-8 text-center", children: /* @__PURE__ */ t("div", { className: "flex flex-col items-center justify-center gap-2 text-muted-foreground", children: [
126
114
  /* @__PURE__ */ e(q, { className: "h-6 w-6 animate-spin text-primary" }),
127
115
  /* @__PURE__ */ e("span", { className: "text-sm", children: "Chargement..." })
128
116
  ] }) }) }) }) : a.length === 0 ? /* @__PURE__ */ e("tbody", { className: "divide-y divide-gray-200 dark:divide-gray-800", children: /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e("td", { colSpan: n, className: "py-8 text-center text-sm text-muted-foreground", children: s }) }) }) : /* @__PURE__ */ e("tbody", { className: "divide-y divide-gray-200 dark:divide-gray-800", children: a.map((h) => {
@@ -130,8 +118,8 @@ function se({
130
118
  return /* @__PURE__ */ t(
131
119
  "tr",
132
120
  {
133
- className: `group hover:bg-muted/50 dark:hover:bg-gray-900/50 transition-colors ${l !== void 0 ? "cursor-pointer" : ""}`,
134
- onClick: () => l == null ? void 0 : l(h),
121
+ className: `group hover:bg-muted/50 dark:hover:bg-gray-900/50 transition-colors ${c !== void 0 ? "cursor-pointer" : ""}`,
122
+ onClick: () => c == null ? void 0 : c(h),
135
123
  children: [
136
124
  u ? /* @__PURE__ */ e(
137
125
  "td",
@@ -141,9 +129,9 @@ function se({
141
129
  d.stopPropagation();
142
130
  },
143
131
  children: /* @__PURE__ */ e(
144
- _,
132
+ S,
145
133
  {
146
- checked: f.includes(m),
134
+ checked: b.includes(m),
147
135
  onCheckedChange: () => {
148
136
  g(m);
149
137
  }
@@ -170,7 +158,7 @@ function se({
170
158
  onClick: (d) => {
171
159
  d.stopPropagation();
172
160
  },
173
- children: /* @__PURE__ */ e(Y, { actions: v, row: h })
161
+ children: /* @__PURE__ */ e(X, { actions: v, row: h })
174
162
  }
175
163
  ) : null
176
164
  ]
@@ -179,28 +167,28 @@ function se({
179
167
  );
180
168
  }) });
181
169
  }
182
- function ne({ selectedRows: c, setSelectedRows: n, bulkActions: s }) {
170
+ function ie({ selectedRows: l, setSelectedRows: n, bulkActions: s }) {
183
171
  return /* @__PURE__ */ t("div", { className: "bg-muted/60 dark:bg-gray-900/60 border border-border px-3 py-1.5 flex items-center justify-between rounded-lg", children: [
184
172
  /* @__PURE__ */ t("div", { className: "flex items-center gap-4", children: [
185
173
  /* @__PURE__ */ t("span", { className: "text-sm font-medium text-primary ml-1", children: [
186
- c.length,
174
+ l.length,
187
175
  " sélectionné(s)"
188
176
  ] }),
189
177
  /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: s.map((a, o) => {
190
- const l = a.icon;
178
+ const c = a.icon;
191
179
  return /* @__PURE__ */ t(
192
180
  x,
193
181
  {
194
182
  variant: "outline",
195
183
  size: "sm",
196
184
  onClick: () => {
197
- a.onClick(c, () => {
185
+ a.onClick(l, () => {
198
186
  n([]);
199
187
  });
200
188
  },
201
189
  className: `h-7 bg-background shadow-sm text-xs px-2.5 ${a.variant === "destructive" ? "text-destructive border-destructive/30 hover:bg-destructive/10 hover:text-destructive" : "text-foreground"}`,
202
190
  children: [
203
- l !== void 0 && /* @__PURE__ */ e("span", { className: "mr-1.5 flex items-center justify-center", children: /* @__PURE__ */ e(l, { className: "h-3.5 w-3.5" }) }),
191
+ c !== void 0 && /* @__PURE__ */ e("span", { className: "mr-1.5 flex items-center justify-center", children: /* @__PURE__ */ e(c, { className: "h-3.5 w-3.5" }) }),
204
192
  a.label
205
193
  ]
206
194
  },
@@ -222,15 +210,15 @@ function ne({ selectedRows: c, setSelectedRows: n, bulkActions: s }) {
222
210
  )
223
211
  ] });
224
212
  }
225
- function ie({
226
- hasBulkActions: c,
213
+ function de({
214
+ hasBulkActions: l,
227
215
  selectedRows: n,
228
216
  totalItems: s,
229
217
  toggleSelectAll: a,
230
218
  visibleColumnsArray: o,
231
- draggableColumns: l,
219
+ draggableColumns: c,
232
220
  resizableColumns: u,
233
- columnWidths: f,
221
+ columnWidths: b,
234
222
  sortColumn: g,
235
223
  sortDirection: i,
236
224
  handleSort: k,
@@ -241,17 +229,17 @@ function ie({
241
229
  hasActions: h,
242
230
  settingsNode: m
243
231
  }) {
244
- const d = (r) => r.sortable !== !0 ? null : g === r.key ? i === "asc" ? /* @__PURE__ */ e(F, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ e(H, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ e(G, { className: "size-3.5 text-muted-foreground/50 group-hover:text-muted-foreground transition-colors" }), y = (r, S) => {
245
- const z = S !== !1, $ = r.sortable === !0, T = g === r.key;
232
+ const d = (r) => r.sortable !== !0 ? null : g === r.key ? i === "asc" ? /* @__PURE__ */ e(J, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ e(G, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ e(F, { className: "size-3.5 text-muted-foreground/50 group-hover:text-muted-foreground transition-colors" }), y = (r, T) => {
233
+ const z = T !== !1, _ = r.sortable === !0, $ = g === r.key;
246
234
  return /* @__PURE__ */ t(
247
235
  "th",
248
236
  {
249
237
  className: [
250
238
  "px-2 py-2 text-left text-sm font-medium text-gray-900 dark:text-gray-100 relative group border-r border-gray-200 dark:border-gray-800",
251
- $ ? "cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-800 select-none" : "",
252
- T ? "bg-gray-100/80 dark:bg-gray-800/80" : ""
239
+ _ ? "cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-800 select-none" : "",
240
+ $ ? "bg-gray-100/80 dark:bg-gray-800/80" : ""
253
241
  ].filter(Boolean).join(" "),
254
- style: { width: f[r.key] },
242
+ style: { width: b[r.key] },
255
243
  draggable: z,
256
244
  onClick: () => {
257
245
  k(r.key);
@@ -268,7 +256,7 @@ function ie({
268
256
  children: [
269
257
  /* @__PURE__ */ t("div", { className: "flex items-center justify-between pr-2", children: [
270
258
  /* @__PURE__ */ t("div", { className: "flex items-center gap-1", children: [
271
- z ? /* @__PURE__ */ e(Q, { className: "size-4 text-gray-400 cursor-grab dark:text-gray-300 shrink-0" }) : null,
259
+ z ? /* @__PURE__ */ e(U, { className: "size-4 text-gray-400 cursor-grab dark:text-gray-300 shrink-0" }) : null,
272
260
  /* @__PURE__ */ e("span", { className: "truncate", children: r.label })
273
261
  ] }),
274
262
  /* @__PURE__ */ e("div", { className: "ml-1 shrink-0", children: d(r) })
@@ -288,33 +276,33 @@ function ie({
288
276
  );
289
277
  };
290
278
  return /* @__PURE__ */ e("thead", { className: "bg-muted/50 dark:bg-gray-900/50 border-b border-gray-200 dark:border-gray-800", children: /* @__PURE__ */ t("tr", { children: [
291
- c ? /* @__PURE__ */ e("th", { className: "px-4 py-2 w-12 flex-shrink-0 text-left", children: /* @__PURE__ */ e(
292
- _,
279
+ l ? /* @__PURE__ */ e("th", { className: "px-4 py-2 w-12 flex-shrink-0 text-left", children: /* @__PURE__ */ e(
280
+ S,
293
281
  {
294
282
  checked: n.length === s && s > 0 ? !0 : n.length > 0 ? "indeterminate" : !1,
295
283
  onCheckedChange: a
296
284
  }
297
285
  ) }) : null,
298
- o.map((r) => y(r, l)),
286
+ o.map((r) => y(r, c)),
299
287
  h || m !== void 0 ? /* @__PURE__ */ e("th", { className: "w-12 px-2 py-2 text-center align-middle", children: m }) : null
300
288
  ] }) });
301
289
  }
302
- function de({
303
- totalItems: c,
290
+ function le({
291
+ totalItems: l,
304
292
  startIndex: n,
305
293
  endIndex: s,
306
294
  pageSize: a,
307
295
  setPageSize: o,
308
- currentPage: l,
296
+ currentPage: c,
309
297
  setCurrentPage: u,
310
- pageSizeOptions: f,
298
+ pageSizeOptions: b,
311
299
  totalPages: g
312
300
  }) {
313
301
  return /* @__PURE__ */ t("div", { className: "px-4 py-2 border-t border-border flex items-center justify-between bg-card flex-wrap gap-2", children: [
314
302
  /* @__PURE__ */ t("div", { className: "text-sm text-muted-foreground", children: [
315
- c === 0 ? "0" : `${String(n + 1)} - ${String(s)}`,
303
+ l === 0 ? "0" : `${String(n + 1)} - ${String(s)}`,
316
304
  " sur ",
317
- c
305
+ l
318
306
  ] }),
319
307
  /* @__PURE__ */ t("div", { className: "flex items-center gap-4", children: [
320
308
  /* @__PURE__ */ t("div", { className: "flex items-center gap-2", children: [
@@ -327,7 +315,7 @@ function de({
327
315
  o(Number(i.target.value)), u(1);
328
316
  },
329
317
  className: "border border-input bg-background rounded px-2 py-1 text-sm text-foreground",
330
- children: f.map((i) => /* @__PURE__ */ e("option", { value: i, children: i }, i))
318
+ children: b.map((i) => /* @__PURE__ */ e("option", { value: i, children: i }, i))
331
319
  }
332
320
  )
333
321
  ] }),
@@ -341,13 +329,13 @@ function de({
341
329
  onClick: () => {
342
330
  u((i) => Math.max(1, i - 1));
343
331
  },
344
- disabled: l === 1,
345
- children: /* @__PURE__ */ e(B, { className: "size-4" })
332
+ disabled: c === 1,
333
+ children: /* @__PURE__ */ e(L, { className: "size-4" })
346
334
  }
347
335
  ),
348
336
  /* @__PURE__ */ t("span", { className: "text-sm text-muted-foreground", children: [
349
337
  "Page ",
350
- l,
338
+ c,
351
339
  " sur ",
352
340
  g
353
341
  ] }),
@@ -360,18 +348,18 @@ function de({
360
348
  onClick: () => {
361
349
  u((i) => Math.min(g, i + 1));
362
350
  },
363
- disabled: l === g,
364
- children: /* @__PURE__ */ e(L, { className: "size-4" })
351
+ disabled: c === g,
352
+ children: /* @__PURE__ */ e(B, { className: "size-4" })
365
353
  }
366
354
  )
367
355
  ] })
368
356
  ] })
369
357
  ] });
370
358
  }
371
- function ce({ columns: c, visibleColumns: n, toggleColumnVisibility: s }) {
372
- return /* @__PURE__ */ t(j, { children: [
373
- /* @__PURE__ */ e(M, { asChild: !0, children: /* @__PURE__ */ e(x, { variant: "outline", size: "sm", className: "size-8 p-0 bg-white hover:bg-gray-100 dark:bg-gray-900 shadow-sm border-gray-200 dark:border-gray-800", children: /* @__PURE__ */ e(X, { className: "size-4 text-gray-600 dark:text-gray-300" }) }) }),
374
- /* @__PURE__ */ e(D, { align: "end", className: "w-56", children: c.map((a) => /* @__PURE__ */ e(
359
+ function ce({ columns: l, visibleColumns: n, toggleColumnVisibility: s }) {
360
+ return /* @__PURE__ */ t(M, { children: [
361
+ /* @__PURE__ */ e(j, { asChild: !0, children: /* @__PURE__ */ e(x, { variant: "outline", size: "sm", className: "size-8 p-0 bg-white hover:bg-gray-100 dark:bg-gray-900 shadow-sm border-gray-200 dark:border-gray-800", children: /* @__PURE__ */ e(W, { className: "size-4 text-gray-600 dark:text-gray-300" }) }) }),
362
+ /* @__PURE__ */ e(D, { align: "end", className: "w-56", children: l.map((a) => /* @__PURE__ */ e(
375
363
  I,
376
364
  {
377
365
  checked: n.has(a.key),
@@ -385,10 +373,10 @@ function ce({ columns: c, visibleColumns: n, toggleColumnVisibility: s }) {
385
373
  ] });
386
374
  }
387
375
  export {
388
- Y as T,
389
- se as a,
390
- ne as b,
391
- ie as c,
392
- de as d,
376
+ X as T,
377
+ ne as a,
378
+ ie as b,
379
+ de as c,
380
+ le as d,
393
381
  ce as e
394
382
  };
@@ -1,7 +1,7 @@
1
1
  import { jsx as a, jsxs as s } from "react/jsx-runtime";
2
- import { b as m, T as h, c as u, B as g, a as f } from "./tooltip-BzTGwm2E.js";
3
- import { S as v, h as b, i as N, a as S, c as x } from "./select-B5wF6jxC.js";
4
- import { a as C } from "./useTheme-CvNYmhjo.js";
2
+ import { b as m, T as h, c as u, B as g, a as f } from "./tooltip-CAu4DEhc.js";
3
+ import { S as v, h as b, i as N, a as S, c as x } from "./select-D6_XPD6x.js";
4
+ import { a as C } from "./useTheme-Bn8z_uxy.js";
5
5
  function I({ themeOptions: r, variant: i = "select" }) {
6
6
  const { theme: n, handleThemeChange: t, currentThemeOption: e, nextThemeOption: c, cycleTheme: o } = C(r);
7
7
  if (i === "mini") {
@@ -1,8 +1,8 @@
1
1
  import { jsxs as i, jsx as e, Fragment as y } from "react/jsx-runtime";
2
- import { C as k, T as C, c as j, a as T, b as z, B as S } from "./tooltip-BzTGwm2E.js";
2
+ import { C as k, T as C, c as j, a as T, b as z, B as S } from "./tooltip-CAu4DEhc.js";
3
3
  import { c as o } from "./index-gWiv5-6R.js";
4
4
  import * as D from "react";
5
- import { c as W } from "./createLucideIcon-CRdjzt2A.js";
5
+ import { c as W } from "./index-DSyPHOLE.js";
6
6
  /**
7
7
  * @license lucide-react v1.16.0 - ISC
8
8
  *
@@ -1,5 +1,5 @@
1
1
  import { jsx as o } from "react/jsx-runtime";
2
- import { e as n } from "./tooltip-BzTGwm2E.js";
2
+ import { a as n } from "./index-DSyPHOLE.js";
3
3
  import { c as a } from "./index-gWiv5-6R.js";
4
4
  const s = n(
5
5
  "inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",