@krosoft/react 0.0.261 → 0.0.262

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 (106) hide show
  1. package/dist/AppActions-D8KKXpq-.js +60 -0
  2. package/dist/{AppSubTitle-C8zoMJo_.js → AppSubTitle-CVhjWRBp.js} +7 -7
  3. package/dist/{AppTitle-BR4JFZfp.js → AppTitle-DBGJRsjU.js} +6 -6
  4. package/dist/{ErrorAlert-DClCk3Ey.js → ErrorAlert-6ECy_Dox.js} +5 -5
  5. package/dist/{GenericForm-JqObtUCQ.js → GenericForm-C86_Jk7X.js} +104 -105
  6. package/dist/{ImageInput-BLIo5LYH.js → ImageInput-DvHgBYsy.js} +5 -5
  7. package/dist/{MultiSelect-B0Ke0cfS.js → MultiSelect-TGu_k3KM.js} +7 -7
  8. package/dist/{SearchInput-CXZd2rSc.js → SearchInput-Csflv8Az.js} +31 -31
  9. package/dist/{behavior-DDtrNBAq.js → behavior-C4WdfbR1.js} +1 -1
  10. package/dist/{cards-Ct4wFYa8.js → cards-nqZOcSkh.js} +42 -42
  11. package/dist/{charts-CwT9AFWj.js → charts-BfeSrTmX.js} +1 -1
  12. package/dist/components/core/cards/index.js +1 -1
  13. package/dist/components/core/charts/index.js +1 -1
  14. package/dist/components/core/dialogs/index.js +3 -3
  15. package/dist/components/core/filters/ActiveFilters.d.ts +2 -2
  16. package/dist/components/core/filters/ActiveFilters.d.ts.map +1 -1
  17. package/dist/components/core/filters/SearchableFilterPill.d.ts +2 -2
  18. package/dist/components/core/filters/SearchableFilterPill.d.ts.map +1 -1
  19. package/dist/components/core/filters/TableFilter.d.ts.map +1 -1
  20. package/dist/components/core/filters/index.js +127 -127
  21. package/dist/components/core/forms/GenericForm.d.ts.map +1 -1
  22. package/dist/components/core/forms/index.js +1 -1
  23. package/dist/components/core/index.js +19 -19
  24. package/dist/components/core/inputs/index.js +4 -4
  25. package/dist/components/core/language/index.js +1 -1
  26. package/dist/components/core/layouts/index.js +26 -26
  27. package/dist/components/core/navbar/NotificationsBell.d.ts +8 -2
  28. package/dist/components/core/navbar/NotificationsBell.d.ts.map +1 -1
  29. package/dist/components/core/navbar/index.js +1 -1
  30. package/dist/components/core/states/index.js +2 -2
  31. package/dist/components/core/table/DataTable.d.ts +4 -19
  32. package/dist/components/core/table/DataTable.d.ts.map +1 -1
  33. package/dist/components/core/table/TableActions.d.ts +2 -2
  34. package/dist/components/core/table/TableActions.d.ts.map +1 -1
  35. package/dist/components/core/table/TableBody.d.ts +6 -6
  36. package/dist/components/core/table/TableBody.d.ts.map +1 -1
  37. package/dist/components/core/table/TableBulkActions.d.ts +2 -2
  38. package/dist/components/core/table/TableBulkActions.d.ts.map +1 -1
  39. package/dist/components/core/table/TableHeader.d.ts +2 -2
  40. package/dist/components/core/table/TableHeader.d.ts.map +1 -1
  41. package/dist/components/core/table/TablePagination.d.ts.map +1 -1
  42. package/dist/components/core/table/TableSettings.d.ts +2 -2
  43. package/dist/components/core/table/TableSettings.d.ts.map +1 -1
  44. package/dist/components/core/table/index.js +1 -1
  45. package/dist/components/core/tabs/AppVerticalTabs.d.ts.map +1 -1
  46. package/dist/components/core/tabs/index.js +39 -40
  47. package/dist/components/core/theme/index.js +1 -1
  48. package/dist/components/index.js +19 -19
  49. package/dist/components/ui/index.js +2 -2
  50. package/dist/constants/datatable.d.ts +1 -1
  51. package/dist/dialogs-BiPcEbRx.js +207 -0
  52. package/dist/helpers/table.helper.d.ts +4 -4
  53. package/dist/helpers/table.helper.d.ts.map +1 -1
  54. package/dist/hooks/behavior/index.js +1 -1
  55. package/dist/hooks/index.js +6 -6
  56. package/dist/hooks/ui/index.js +5 -5
  57. package/dist/hooks/ui/useDataTable.d.ts +1 -1
  58. package/dist/hooks/ui/useDataTable.d.ts.map +1 -1
  59. package/dist/i18n/index.js +1 -1
  60. package/dist/i18n/krosoftLocales.d.ts +22 -0
  61. package/dist/i18n/krosoftLocales.d.ts.map +1 -1
  62. package/dist/i18n/useKrosoftTranslation.d.ts +9 -6
  63. package/dist/i18n/useKrosoftTranslation.d.ts.map +1 -1
  64. package/dist/{i18n-DW5zKBEK.js → i18n-CevI9Cgk.js} +35 -13
  65. package/dist/{inputs-CNDApo_M.js → inputs-BUXmTc40.js} +3 -3
  66. package/dist/{language-CK_kDejF.js → language-DeQC57bX.js} +9 -9
  67. package/dist/{navbar-UsCqs4DK.js → navbar-Cl4welok.js} +75 -62
  68. package/dist/pwa/index.js +4 -4
  69. package/dist/{sheet-_rrCMue7.js → sheet-RYwa4-Nl.js} +7 -7
  70. package/dist/{states-BusGNKku.js → states-C6lWnADN.js} +2 -2
  71. package/dist/{table-CZ5Ogd4w.js → table-BWEBIVqj.js} +235 -242
  72. package/dist/{theme-QayeX440.js → theme-Dwc4zNXG.js} +9 -9
  73. package/dist/types/AppAction.d.ts +1 -1
  74. package/dist/types/AppAction.d.ts.map +1 -1
  75. package/dist/types/{BulkAction.d.ts → DataTableBulkAction.d.ts} +3 -3
  76. package/dist/types/DataTableBulkAction.d.ts.map +1 -0
  77. package/dist/types/{ColumnDef.d.ts → DataTableColumn.d.ts} +3 -3
  78. package/dist/types/DataTableColumn.d.ts.map +1 -0
  79. package/dist/types/DataTableConfig.d.ts +21 -5
  80. package/dist/types/DataTableConfig.d.ts.map +1 -1
  81. package/dist/types/{RowAction.d.ts → DataTableRowAction.d.ts} +3 -3
  82. package/dist/types/DataTableRowAction.d.ts.map +1 -0
  83. package/dist/types/DataTableServerState.d.ts +20 -0
  84. package/dist/types/DataTableServerState.d.ts.map +1 -0
  85. package/dist/types/FilterFieldConfig.d.ts +2 -2
  86. package/dist/types/FilterFieldConfig.d.ts.map +1 -1
  87. package/dist/types/FilterSection.d.ts +1 -1
  88. package/dist/types/FilterSection.d.ts.map +1 -1
  89. package/dist/types/UseDataTableProps.d.ts +10 -16
  90. package/dist/types/UseDataTableProps.d.ts.map +1 -1
  91. package/dist/types/UseDataTableResult.d.ts +3 -3
  92. package/dist/types/UseDataTableResult.d.ts.map +1 -1
  93. package/dist/types/index.d.ts +4 -3
  94. package/dist/types/index.d.ts.map +1 -1
  95. package/dist/{ui-hnbBp9RZ.js → ui-D7YSs2kF.js} +1 -1
  96. package/dist/{ui-Dg7lq9J8.js → ui-IEH46J4v.js} +4 -4
  97. package/dist/{useDocumentTitle-D7MywIeB.js → useDocumentTitle-C5TsEDqh.js} +4 -4
  98. package/dist/{useFixedColumns-DnzqhbfT.js → useFixedColumns-BVZs3wbh.js} +27 -27
  99. package/dist/{useLanguage-B1dusDJk.js → useLanguage-DdVIzhME.js} +1 -1
  100. package/dist/{useTheme-D1APOG9I.js → useTheme-ZzPZl0MM.js} +1 -1
  101. package/package.json +1 -1
  102. package/dist/AppActions-CcU3ClFS.js +0 -60
  103. package/dist/dialogs-BDtZIxQa.js +0 -208
  104. package/dist/types/BulkAction.d.ts.map +0 -1
  105. package/dist/types/ColumnDef.d.ts.map +0 -1
  106. package/dist/types/RowAction.d.ts.map +0 -1
@@ -1,14 +1,13 @@
1
1
  import { ACTIONS_COLUMN_KEY as e, SELECTION_COLUMN_KEY as t, getAlignmentClass as n, getColumnAlignment as r, getFixedCellProps as i } from "./helpers/index.js";
2
- import { At as a, C as o, D as s, Ft as c, Gt as l, Mt as u, Nt as d, O as f, S as p, T as m, bn as h, jt as g, k as _, v } from "./ui-hnbBp9RZ.js";
3
- import { s as y } from "./tooltip-BmZ9Bfou.js";
4
- import { t as b } from "./i18n-DW5zKBEK.js";
2
+ import { t as a } from "./i18n-CevI9Cgk.js";
3
+ import { At as o, C as s, D as c, Ft as l, Gt as u, Mt as d, Nt as f, O as p, S as m, T as h, bn as g, jt as _, k as v, v as y } from "./ui-D7YSs2kF.js";
4
+ import { s as b } from "./tooltip-BmZ9Bfou.js";
5
5
  import { i as x, l as S, n as C, t as w, u as T } from "./select-DmLScQKX.js";
6
- import { n as E, t as D } from "./useFixedColumns-DnzqhbfT.js";
6
+ import { n as E, t as D } from "./useFixedColumns-BVZs3wbh.js";
7
7
  import { useState as O } from "react";
8
8
  import { Fragment as k, jsx as A, jsxs as j } from "react/jsx-runtime";
9
- import { useTranslation as M } from "react-i18next";
10
- import { formatJsonValue as N, isRecord as P, tryParseJson as F } from "@krosoft/core/helpers";
11
- import { AlertTriangleIcon as ee, ArrowDownIcon as I, ArrowUpDownIcon as L, ArrowUpIcon as R, ChevronLeftIcon as z, ChevronRightIcon as B, GripVerticalIcon as V, Loader2Icon as H, MoreVerticalIcon as U, SettingsIcon as W } from "lucide-react";
9
+ import { formatJsonValue as M, isRecord as N, tryParseJson as P } from "@krosoft/core/helpers";
10
+ import { AlertTriangleIcon as F, ArrowDownIcon as I, ArrowUpDownIcon as L, ArrowUpIcon as R, ChevronLeftIcon as z, ChevronRightIcon as B, GripVerticalIcon as V, Loader2Icon as H, MoreVerticalIcon as U, SettingsIcon as W } from "lucide-react";
12
11
  import { useNavigate as G } from "react-router-dom";
13
12
  //#region src/constants/datatable.ts
14
13
  var K = [
@@ -17,18 +16,18 @@ var K = [
17
16
  30,
18
17
  50,
19
18
  100
20
- ], te = K[1];
19
+ ], ee = K[1];
21
20
  //#endregion
22
21
  //#region src/components/core/table/TableActions.tsx
23
22
  function q({ actions: e, row: t }) {
24
- let n = e.filter((e) => e.visible === void 0 || e.visible(t));
25
- if (n.length === 0) return null;
26
- let r = n.filter((e) => e.overflow !== !0), i = n.filter((e) => e.overflow === !0);
23
+ let { t: n } = a(), r = e.filter((e) => e.visible === void 0 || e.visible(t));
24
+ if (r.length === 0) return null;
25
+ let i = r.filter((e) => e.overflow !== !0), o = r.filter((e) => e.overflow === !0);
27
26
  return /* @__PURE__ */ j("div", {
28
27
  className: "flex items-center justify-end gap-1",
29
- children: [r.map((e, n) => {
30
- let r = e.icon;
31
- return /* @__PURE__ */ j(y, {
28
+ children: [i.map((e, r) => {
29
+ let i = e.icon;
30
+ return /* @__PURE__ */ j(b, {
32
31
  variant: e.variant ?? "ghost",
33
32
  size: "sm",
34
33
  disabled: e.disabled?.(t) ?? !1,
@@ -36,42 +35,42 @@ function q({ actions: e, row: t }) {
36
35
  onClick: (n) => {
37
36
  n.stopPropagation(), e.onClick(t);
38
37
  },
39
- children: [r !== void 0 && /* @__PURE__ */ A(r, { className: "size-3.5" }), e.label]
40
- }, n);
41
- }), i.length > 0 && /* @__PURE__ */ j(g, { children: [/* @__PURE__ */ A(l, {
38
+ children: [i !== void 0 && /* @__PURE__ */ A(i, { className: "size-3.5" }), n(e.labelKey)]
39
+ }, r);
40
+ }), o.length > 0 && /* @__PURE__ */ j(_, { children: [/* @__PURE__ */ A(u, {
42
41
  asChild: !0,
43
- children: /* @__PURE__ */ A(y, {
42
+ children: /* @__PURE__ */ A(b, {
44
43
  variant: "ghost",
45
44
  size: "icon",
46
45
  className: "h-7 w-7 text-muted-foreground hover:text-foreground",
47
46
  children: /* @__PURE__ */ A(U, { className: "size-3.5" })
48
47
  })
49
- }), /* @__PURE__ */ A(d, {
48
+ }), /* @__PURE__ */ A(f, {
50
49
  align: "end",
51
50
  onClick: (e) => {
52
51
  e.stopPropagation();
53
52
  },
54
- children: i.map((e, n) => {
55
- let r = e.icon;
56
- return /* @__PURE__ */ j(c, {
53
+ children: o.map((e, r) => {
54
+ let i = e.icon;
55
+ return /* @__PURE__ */ j(l, {
57
56
  disabled: e.disabled?.(t) ?? !1,
58
57
  onClick: () => {
59
58
  e.onClick(t);
60
59
  },
61
60
  className: e.className,
62
- children: [r !== void 0 && /* @__PURE__ */ A("span", {
61
+ children: [i !== void 0 && /* @__PURE__ */ A("span", {
63
62
  className: "mr-2 size-4 flex items-center justify-center",
64
- children: /* @__PURE__ */ A(r, { className: "size-4" })
65
- }), e.label]
66
- }, n);
63
+ children: /* @__PURE__ */ A(i, { className: "size-4" })
64
+ }), n(e.labelKey)]
65
+ }, r);
67
66
  })
68
67
  })] })]
69
68
  });
70
69
  }
71
70
  //#endregion
72
71
  //#region src/components/core/table/TableBody.tsx
73
- function J({ isLoading: a, error: o, colSpanCount: s, messages: c, paginatedData: l, getRowId: u, onRowClick: d, onRowNavigate: f, hasBulkActions: p, selectedRows: m, toggleRowSelection: g, visibleColumnsArray: _, columnWidths: v, hasActions: y, actions: x, columns: S, bordered: C = !1, dense: w = !1, resizableColumns: T = !1, fixedColumns: E = {} }) {
74
- let { t: D } = b(), { t: O } = M(), k = c?.loadingKey ? O(c.loadingKey) : D("states.loading"), N = c?.emptyKey ? O(c.emptyKey) : D("states.noResult"), P = G(), F = (e, t) => {
72
+ function J({ isLoading: o, error: s, colSpanCount: c, messages: l, paginatedData: u, rowKey: d, onRowClick: f, onRowNavigate: p, hasBulkActions: m, selectedRows: h, toggleRowSelection: _, visibleColumnsArray: v, columnWidths: y, hasActions: b, actions: x, columns: S, bordered: C = !1, dense: w = !1, resizableColumns: T = !1, fixedColumns: E = {} }) {
73
+ let { t: D } = a(), O = D(l?.loadingKey ?? "states.loading"), k = D(l?.emptyKey ?? "states.noResult"), M = G(), N = (e, t) => {
75
74
  let n = S.find((e) => e.key === t);
76
75
  if (n?.renderCell !== void 0) return n.renderCell(e);
77
76
  let r = e[t];
@@ -80,98 +79,98 @@ function J({ isLoading: a, error: o, colSpanCount: s, messages: c, paginatedData
80
79
  children: r == null ? "-" : String(r)
81
80
  });
82
81
  };
83
- if (a) return /* @__PURE__ */ A("tbody", {
82
+ if (o) return /* @__PURE__ */ A("tbody", {
84
83
  className: "divide-y divide-border",
85
84
  children: /* @__PURE__ */ A("tr", { children: /* @__PURE__ */ A("td", {
86
- colSpan: s,
85
+ colSpan: c,
87
86
  className: "py-8 text-center",
88
87
  children: /* @__PURE__ */ j("div", {
89
88
  className: "flex flex-col items-center justify-center gap-2 text-muted-foreground",
90
89
  children: [/* @__PURE__ */ A(H, { className: "h-6 w-6 animate-spin text-primary" }), /* @__PURE__ */ A("span", {
91
90
  className: "text-sm",
92
- children: k
91
+ children: O
93
92
  })]
94
93
  })
95
94
  }) })
96
95
  });
97
- if (o) return /* @__PURE__ */ A("tbody", {
96
+ if (s) return /* @__PURE__ */ A("tbody", {
98
97
  className: "divide-y divide-border",
99
98
  children: /* @__PURE__ */ A("tr", { children: /* @__PURE__ */ A("td", {
100
- colSpan: s,
99
+ colSpan: c,
101
100
  className: "py-8 text-center",
102
101
  children: /* @__PURE__ */ j("div", {
103
102
  className: "flex flex-col items-center justify-center gap-2 text-destructive",
104
- children: [/* @__PURE__ */ A(ee, { className: "h-6 w-6" }), /* @__PURE__ */ A("span", {
103
+ children: [/* @__PURE__ */ A(F, { className: "h-6 w-6" }), /* @__PURE__ */ A("span", {
105
104
  className: "text-sm",
106
- children: o
105
+ children: s
107
106
  })]
108
107
  })
109
108
  }) })
110
109
  });
111
- if (l.length === 0) return /* @__PURE__ */ A("tbody", {
110
+ if (u.length === 0) return /* @__PURE__ */ A("tbody", {
112
111
  className: "divide-y divide-border",
113
112
  children: /* @__PURE__ */ A("tr", { children: /* @__PURE__ */ A("td", {
114
- colSpan: s,
113
+ colSpan: c,
115
114
  className: "py-8 text-center text-sm text-muted-foreground",
116
- children: N
115
+ children: k
117
116
  }) })
118
117
  });
119
- let I = i(E[t], "body"), L = i(E[e], "body"), R = f !== void 0 || d !== void 0, z = (e, t) => {
120
- if (f !== void 0) {
121
- let n = f(e);
122
- t.ctrlKey || t.metaKey ? window.open(n, "_blank") : P(n);
123
- } else d?.(e, t);
118
+ let P = i(E[t], "body"), I = i(E[e], "body"), L = p !== void 0 || f !== void 0, R = (e, t) => {
119
+ if (p !== void 0) {
120
+ let n = p(e);
121
+ t.ctrlKey || t.metaKey ? window.open(n, "_blank") : M(n);
122
+ } else f?.(e, t);
124
123
  };
125
124
  return /* @__PURE__ */ A("tbody", {
126
125
  className: "divide-y divide-border",
127
- children: l.map((e) => {
128
- let t = u(e);
126
+ children: u.map((e) => {
127
+ let t = d(e);
129
128
  return /* @__PURE__ */ j("tr", {
130
- className: `group hover:bg-muted/50 transition-colors ${R ? "cursor-pointer" : ""}`,
129
+ className: `group hover:bg-muted/50 transition-colors ${L ? "cursor-pointer" : ""}`,
131
130
  onClick: (t) => {
132
- z(e, t);
131
+ R(e, t);
133
132
  },
134
133
  children: [
135
- p ? /* @__PURE__ */ A("td", {
136
- className: `p-1 text-center align-middle ${I.className}`,
134
+ m ? /* @__PURE__ */ A("td", {
135
+ className: `p-1 text-center align-middle ${P.className}`,
137
136
  style: {
138
137
  width: "48px",
139
138
  minWidth: "48px",
140
139
  maxWidth: "48px",
141
- ...I.style
140
+ ...P.style
142
141
  },
143
142
  onClick: (e) => {
144
143
  e.stopPropagation();
145
144
  },
146
145
  children: /* @__PURE__ */ A("div", {
147
146
  className: "flex items-center justify-center",
148
- children: /* @__PURE__ */ A(h, {
149
- checked: m.includes(t),
147
+ children: /* @__PURE__ */ A(g, {
148
+ checked: h.includes(t),
150
149
  onCheckedChange: () => {
151
- g(t);
150
+ _(t);
152
151
  }
153
152
  })
154
153
  })
155
154
  }) : null,
156
- _.map((t, a) => {
157
- let o = a === _.length - 1, s = i(E[t.key], "body");
155
+ v.map((t, a) => {
156
+ let o = a === v.length - 1, s = i(E[t.key], "body");
158
157
  return /* @__PURE__ */ A("td", {
159
- className: `${`${a === 0 && !p ? "pl-4" : "pl-2"} ${o && !y ? "pr-4" : "pr-2"}`} ${w ? "py-2" : "py-4"} text-sm ${n(r(t))} ${s.className} ${C && !o ? "border-r border-border" : ""} ${t.className ?? ""}`,
158
+ className: `${`${a === 0 && !m ? "pl-4" : "pl-2"} ${o && !b ? "pr-4" : "pr-2"}`} ${w ? "py-2" : "py-4"} text-sm ${n(r(t))} ${s.className} ${C && !o ? "border-r border-border" : ""} ${t.className ?? ""}`,
160
159
  style: {
161
- ...T ? { width: v[t.key] } : { minWidth: v[t.key] },
160
+ ...T ? { width: y[t.key] } : { minWidth: y[t.key] },
162
161
  ...s.style
163
162
  },
164
163
  children: /* @__PURE__ */ A("div", {
165
164
  className: "w-full h-full",
166
- children: F(e, t.key)
165
+ children: N(e, t.key)
167
166
  })
168
167
  }, t.key);
169
168
  }),
170
- y ? /* @__PURE__ */ A("td", {
171
- className: `py-1 pl-1 pr-4 text-right align-middle whitespace-nowrap ${L.className}`,
169
+ b ? /* @__PURE__ */ A("td", {
170
+ className: `py-1 pl-1 pr-4 text-right align-middle whitespace-nowrap ${I.className}`,
172
171
  style: {
173
172
  minWidth: "32px",
174
- ...L.style
173
+ ...I.style
175
174
  },
176
175
  onClick: (e) => {
177
176
  e.stopPropagation();
@@ -192,18 +191,19 @@ function J({ isLoading: a, error: o, colSpanCount: s, messages: c, paginatedData
192
191
  //#endregion
193
192
  //#region src/components/core/table/TableBulkActions.tsx
194
193
  function Y({ selectedRows: e, setSelectedRows: t, bulkActions: n }) {
194
+ let { t: r } = a();
195
195
  return /* @__PURE__ */ j("div", {
196
196
  className: "bg-muted/60 border border-border px-3 py-1.5 flex items-center justify-between rounded-surface",
197
197
  children: [/* @__PURE__ */ j("div", {
198
198
  className: "flex items-center gap-4",
199
- children: [/* @__PURE__ */ j("span", {
199
+ children: [/* @__PURE__ */ A("span", {
200
200
  className: "text-sm font-medium text-primary ml-1",
201
- children: [e.length, " sélectionné(s)"]
201
+ children: r("table.selectedCount", { count: e.length })
202
202
  }), /* @__PURE__ */ A("div", {
203
203
  className: "flex items-center gap-2",
204
- children: n.map((n, r) => {
205
- let i = n.icon;
206
- return /* @__PURE__ */ j(y, {
204
+ children: n.map((n, i) => {
205
+ let a = n.icon;
206
+ return /* @__PURE__ */ j(b, {
207
207
  variant: "outline",
208
208
  size: "sm",
209
209
  onClick: () => {
@@ -212,21 +212,21 @@ function Y({ selectedRows: e, setSelectedRows: t, bulkActions: n }) {
212
212
  });
213
213
  },
214
214
  className: `h-7 bg-background shadow-sm text-xs px-2.5 ${n.variant === "destructive" ? "text-destructive border-destructive/30 hover:bg-destructive/10 hover:text-destructive" : "text-foreground"}`,
215
- children: [i !== void 0 && /* @__PURE__ */ A("span", {
215
+ children: [a !== void 0 && /* @__PURE__ */ A("span", {
216
216
  className: "mr-1.5 flex items-center justify-center",
217
- children: /* @__PURE__ */ A(i, { className: "h-3.5 w-3.5" })
218
- }), n.label]
219
- }, r);
217
+ children: /* @__PURE__ */ A(a, { className: "h-3.5 w-3.5" })
218
+ }), r(n.labelKey)]
219
+ }, i);
220
220
  })
221
221
  })]
222
- }), /* @__PURE__ */ A(y, {
222
+ }), /* @__PURE__ */ A(b, {
223
223
  variant: "ghost",
224
224
  size: "sm",
225
225
  onClick: () => {
226
226
  t([]);
227
227
  },
228
228
  className: "text-xs text-muted-foreground hover:text-foreground h-7 px-2",
229
- children: "Désélectionner"
229
+ children: r("table.clearSelection")
230
230
  })]
231
231
  });
232
232
  }
@@ -237,169 +237,168 @@ var X = {
237
237
  center: "justify-center",
238
238
  right: "justify-end"
239
239
  };
240
- function Z({ hasBulkActions: a, selectedRows: o, totalItems: s, toggleSelectAll: c, visibleColumnsArray: l, draggableColumns: u, resizableColumns: d, columnWidths: f, sortColumn: p, sortDirection: m, handleSort: g, handleDragStart: _, handleDragOver: v, handleDrop: y, handleMouseDown: b, hasActions: x, settingsNode: S, bordered: C = !1, dense: w = !1, fixedColumns: T = {}, fixedSelection: E = !1, fixedActions: D = !1 }) {
241
- let O = !1;
242
- o.length === s && s > 0 ? O = !0 : o.length > 0 && (O = "indeterminate");
243
- let k = (e) => e.sortable === !0 ? p === e.key ? A(m === "asc" ? R : I, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ A(L, { className: "size-3.5 text-muted-foreground/50 group-hover:text-muted-foreground transition-colors" }) : null, M = (e, t, o) => {
244
- let s = o !== !1 && e.fixed === void 0, c = e.sortable === !0, u = i(T[e.key], "header"), p = r(e), m = k(e), h = t === 0 && !a, E = t === l.length - 1 && !(x || S !== void 0), D = `${h ? "pl-4" : "pl-2"} ${E ? "pr-4" : "pr-2"}`;
240
+ function te({ hasBulkActions: o, selectedRows: s, totalItems: c, toggleSelectAll: l, visibleColumnsArray: u, draggableColumns: d, resizableColumns: f, columnWidths: p, sortColumn: m, sortDirection: h, handleSort: _, handleDragStart: v, handleDragOver: y, handleDrop: b, handleMouseDown: x, hasActions: S, settingsNode: C, bordered: w = !1, dense: T = !1, fixedColumns: E = {}, fixedSelection: D = !1, fixedActions: O = !1 }) {
241
+ let { t: k } = a(), M = !1;
242
+ s.length === c && c > 0 ? M = !0 : s.length > 0 && (M = "indeterminate");
243
+ let N = (e) => e.sortable === !0 ? m === e.key ? A(h === "asc" ? R : I, { className: "size-3.5 text-foreground" }) : /* @__PURE__ */ A(L, { className: "size-3.5 text-muted-foreground/50 group-hover:text-muted-foreground transition-colors" }) : null, P = (e, t, a) => {
244
+ let s = a !== !1 && e.fixed === void 0, c = e.sortable === !0, l = i(E[e.key], "header"), d = r(e), m = N(e), h = t === 0 && !o, g = t === u.length - 1 && !(S || C !== void 0), D = `${h ? "pl-4" : "pl-2"} ${g ? "pr-4" : "pr-2"}`;
245
245
  return /* @__PURE__ */ j("th", {
246
246
  "data-column-key": e.key,
247
247
  "data-fixed-side": e.fixed,
248
248
  className: [
249
- `${D} ${w ? "py-2" : "py-4"} text-sm font-medium text-foreground group`,
250
- n(p),
251
- u.className,
252
- C ? "border-r border-border" : "",
249
+ `${D} ${T ? "py-2" : "py-4"} text-sm font-medium text-foreground group`,
250
+ n(d),
251
+ l.className,
252
+ w ? "border-r border-border" : "",
253
253
  c ? "cursor-pointer select-none" : "",
254
254
  e.className ?? ""
255
255
  ].filter(Boolean).join(" "),
256
256
  style: {
257
- ...d ? { width: f[e.key] } : { minWidth: f[e.key] },
258
- ...u.style
257
+ ...f ? { width: p[e.key] } : { minWidth: p[e.key] },
258
+ ...l.style
259
259
  },
260
260
  draggable: s,
261
261
  onClick: () => {
262
- g(e.key);
262
+ _(e.key);
263
263
  },
264
264
  onDragStart: (t) => {
265
- s ? _(t, e.key) : t.preventDefault();
265
+ s ? v(t, e.key) : t.preventDefault();
266
266
  },
267
267
  onDragOver: (t) => {
268
- v(t, e.key);
268
+ y(t, e.key);
269
269
  },
270
270
  onDrop: (t) => {
271
- y(t, e.key);
271
+ b(t, e.key);
272
272
  },
273
273
  children: [/* @__PURE__ */ j("div", {
274
- className: `flex items-center gap-1 ${X[p]} ${d ? "pr-2" : ""}`,
274
+ className: `flex items-center gap-1 ${X[d]} ${f ? "pr-2" : ""}`,
275
275
  children: [
276
276
  s ? /* @__PURE__ */ A(V, { className: "size-4 text-muted-foreground cursor-grab shrink-0" }) : null,
277
277
  /* @__PURE__ */ A("span", {
278
278
  className: "truncate",
279
- children: e.label
279
+ children: k(e.headerKey)
280
280
  }),
281
281
  m === null ? null : /* @__PURE__ */ A("span", {
282
282
  className: "ml-1 shrink-0",
283
283
  children: m
284
284
  })
285
285
  ]
286
- }), d ? /* @__PURE__ */ A("div", {
286
+ }), f ? /* @__PURE__ */ A("div", {
287
287
  className: "absolute right-0 top-0 bottom-0 w-2 cursor-col-resize hover:bg-blue-500 opacity-0 group-hover:opacity-50 transition-opacity",
288
288
  onMouseDown: (t) => {
289
- b(t, e.key);
289
+ x(t, e.key);
290
290
  }
291
291
  }) : null]
292
292
  }, e.key);
293
- }, N = i(T[t], "header"), P = i(T[e], "header");
293
+ }, F = i(E[t], "header"), z = i(E[e], "header");
294
294
  return /* @__PURE__ */ A("thead", {
295
295
  className: "bg-muted/50 border-b border-border",
296
296
  children: /* @__PURE__ */ j("tr", { children: [
297
- a ? /* @__PURE__ */ A("th", {
297
+ o ? /* @__PURE__ */ A("th", {
298
298
  "data-column-key": t,
299
- "data-fixed-side": E ? "left" : void 0,
300
- className: `p-1 text-center align-middle ${N.className}`,
299
+ "data-fixed-side": D ? "left" : void 0,
300
+ className: `p-1 text-center align-middle ${F.className}`,
301
301
  style: {
302
302
  width: "48px",
303
303
  minWidth: "48px",
304
304
  maxWidth: "48px",
305
- ...N.style
305
+ ...F.style
306
306
  },
307
307
  children: /* @__PURE__ */ A("div", {
308
308
  className: "flex items-center justify-center",
309
- children: /* @__PURE__ */ A(h, {
310
- checked: O,
311
- onCheckedChange: c
309
+ children: /* @__PURE__ */ A(g, {
310
+ checked: M,
311
+ onCheckedChange: l
312
312
  })
313
313
  })
314
314
  }) : null,
315
- l.map((e, t) => M(e, t, u)),
316
- x || S !== void 0 ? /* @__PURE__ */ A("th", {
315
+ u.map((e, t) => P(e, t, d)),
316
+ S || C !== void 0 ? /* @__PURE__ */ A("th", {
317
317
  "data-column-key": e,
318
- "data-fixed-side": D ? "right" : void 0,
319
- className: `py-1 pl-1 pr-4 text-right align-middle ${P.className}`,
318
+ "data-fixed-side": O ? "right" : void 0,
319
+ className: `py-1 pl-1 pr-4 text-right align-middle ${z.className}`,
320
320
  style: {
321
321
  minWidth: "32px",
322
- ...P.style
322
+ ...z.style
323
323
  },
324
- children: S
324
+ children: C
325
325
  }) : null
326
326
  ] })
327
327
  });
328
328
  }
329
329
  //#endregion
330
330
  //#region src/components/core/table/TablePagination.tsx
331
- var Q = "…";
332
- function $(e, t) {
331
+ var Z = "…";
332
+ function Q(e, t) {
333
333
  return Array.from({ length: t - e + 1 }, (t, n) => e + n);
334
334
  }
335
335
  function ne(e, t, n = 1) {
336
- if (n * 2 + 5 >= t) return $(1, t);
336
+ if (n * 2 + 5 >= t) return Q(1, t);
337
337
  let r = Math.max(e - n, 1), i = Math.min(e + n, t), a = r > 2, o = i < t - 1;
338
338
  return !a && o ? [
339
- ...$(1, n + 2),
340
- Q,
339
+ ...Q(1, n + 2),
340
+ Z,
341
341
  t
342
342
  ] : a && !o ? [
343
343
  1,
344
- Q,
345
- ...$(t - (n + 2) + 1, t)
344
+ Z,
345
+ ...Q(t - (n + 2) + 1, t)
346
346
  ] : [
347
347
  1,
348
- Q,
349
- ...$(r, i),
350
- Q,
348
+ Z,
349
+ ...Q(r, i),
350
+ Z,
351
351
  t
352
352
  ];
353
353
  }
354
- function re({ totalItems: e, startIndex: t, endIndex: n, pageSize: r, setPageSize: i, currentPage: a, setCurrentPage: o, pageSizeOptions: s, totalPages: c }) {
355
- let { t: l } = b(), u = ne(a, c);
354
+ function re({ totalItems: e, startIndex: t, endIndex: n, pageSize: r, setPageSize: i, currentPage: o, setCurrentPage: s, pageSizeOptions: c, totalPages: l }) {
355
+ let { t: u } = a(), d = ne(o, l);
356
356
  return /* @__PURE__ */ j("div", {
357
357
  className: "px-4 py-2 border-t border-border flex flex-col sm:grid sm:grid-cols-3 items-center gap-2 bg-muted/50",
358
358
  children: [
359
- /* @__PURE__ */ j("div", {
359
+ /* @__PURE__ */ A("div", {
360
360
  className: "text-sm text-muted-foreground justify-self-start",
361
- children: [
362
- e === 0 ? "0" : `${String(t + 1)} - ${String(n)}`,
363
- " sur ",
364
- e
365
- ]
361
+ children: u("table.rangeOfTotal", {
362
+ range: e === 0 ? "0" : `${String(t + 1)} - ${String(n)}`,
363
+ total: e
364
+ })
366
365
  }),
367
366
  /* @__PURE__ */ A("div", {
368
367
  className: "flex items-center justify-center gap-1",
369
- children: c > 1 && /* @__PURE__ */ j(k, { children: [
370
- /* @__PURE__ */ A(y, {
368
+ children: l > 1 && /* @__PURE__ */ j(k, { children: [
369
+ /* @__PURE__ */ A(b, {
371
370
  variant: "ghost",
372
371
  size: "icon",
373
372
  className: "h-8 w-8 rounded-control",
374
373
  onClick: () => {
375
- o((e) => Math.max(1, e - 1));
374
+ s((e) => Math.max(1, e - 1));
376
375
  },
377
- disabled: a === 1,
378
- "aria-label": l("table.previousPage"),
376
+ disabled: o === 1,
377
+ "aria-label": u("table.previousPage"),
379
378
  children: /* @__PURE__ */ A(z, { className: "size-4" })
380
379
  }),
381
- u.map((e, t) => e === Q ? /* @__PURE__ */ A("span", {
380
+ d.map((e, t) => e === Z ? /* @__PURE__ */ A("span", {
382
381
  className: "flex h-8 w-8 items-center justify-center text-sm text-muted-foreground",
383
- children: Q
384
- }, `dots-${String(t)}`) : /* @__PURE__ */ A(y, {
385
- variant: e === a ? "default" : "ghost",
382
+ children: Z
383
+ }, `dots-${String(t)}`) : /* @__PURE__ */ A(b, {
384
+ variant: e === o ? "default" : "ghost",
386
385
  size: "icon",
387
386
  className: "h-8 w-8 rounded-control text-sm",
388
387
  onClick: () => {
389
- o(e);
388
+ s(e);
390
389
  },
391
- "aria-current": e === a ? "page" : void 0,
390
+ "aria-current": e === o ? "page" : void 0,
392
391
  children: e
393
392
  }, e)),
394
- /* @__PURE__ */ A(y, {
393
+ /* @__PURE__ */ A(b, {
395
394
  variant: "ghost",
396
395
  size: "icon",
397
396
  className: "h-8 w-8 rounded-control",
398
397
  onClick: () => {
399
- o((e) => Math.min(c, e + 1));
398
+ s((e) => Math.min(l, e + 1));
400
399
  },
401
- disabled: a === c,
402
- "aria-label": l("table.nextPage"),
400
+ disabled: o === l,
401
+ "aria-label": u("table.nextPage"),
403
402
  children: /* @__PURE__ */ A(B, { className: "size-4" })
404
403
  })
405
404
  ] })
@@ -409,14 +408,14 @@ function re({ totalItems: e, startIndex: t, endIndex: n, pageSize: r, setPageSiz
409
408
  children: /* @__PURE__ */ j(w, {
410
409
  value: String(r),
411
410
  onValueChange: (e) => {
412
- i(Number(e)), o(1);
411
+ i(Number(e)), s(1);
413
412
  },
414
413
  children: [/* @__PURE__ */ A(S, {
415
414
  className: "h-8 w-[110px] text-sm",
416
415
  children: /* @__PURE__ */ A(T, {})
417
- }), /* @__PURE__ */ A(C, { children: s.map((e) => /* @__PURE__ */ j(x, {
416
+ }), /* @__PURE__ */ A(C, { children: c.map((e) => /* @__PURE__ */ A(x, {
418
417
  value: String(e),
419
- children: [e, " / page"]
418
+ children: u("table.perPage", { count: e })
420
419
  }, e)) })]
421
420
  })
422
421
  })
@@ -426,138 +425,132 @@ function re({ totalItems: e, startIndex: t, endIndex: n, pageSize: r, setPageSiz
426
425
  //#endregion
427
426
  //#region src/components/core/table/TableSettings.tsx
428
427
  function ie({ columns: e, visibleColumns: t, toggleColumnVisibility: n }) {
429
- return /* @__PURE__ */ j(g, { children: [/* @__PURE__ */ A(l, {
428
+ let { t: r } = a();
429
+ return /* @__PURE__ */ j(_, { children: [/* @__PURE__ */ A(u, {
430
430
  asChild: !0,
431
- children: /* @__PURE__ */ A(y, {
431
+ children: /* @__PURE__ */ A(b, {
432
432
  variant: "outline",
433
433
  size: "sm",
434
434
  className: "size-7 p-0 bg-background hover:bg-muted shadow-sm border-border",
435
435
  children: /* @__PURE__ */ A(W, { className: "size-3.5 text-muted-foreground" })
436
436
  })
437
- }), /* @__PURE__ */ A(d, {
437
+ }), /* @__PURE__ */ A(f, {
438
438
  align: "end",
439
439
  className: "w-56",
440
- children: e.map((e) => /* @__PURE__ */ A(u, {
440
+ children: e.map((e) => /* @__PURE__ */ A(d, {
441
441
  checked: t.has(e.key),
442
442
  onCheckedChange: () => {
443
443
  n(e.key);
444
444
  },
445
- children: e.label
445
+ children: r(e.headerKey)
446
446
  }, e.key))
447
447
  })] });
448
448
  }
449
449
  //#endregion
450
450
  //#region src/components/core/table/DataTable.tsx
451
- function ae({ data: e, columns: t, getRowId: n, onRowClick: r, onRowNavigate: i, actions: a, bulkActions: o, isLoading: s = !1, error: c = null, config: l, defaultPageSize: u = te, pageSizeOptions: d = K, totalRows: f, currentPage: p, pageSize: m, onPageChange: h, onPageSizeChange: g, sortColumn: _, sortDirection: v, onSortChange: y }) {
452
- let b = l?.dense ?? !1, x = l?.bordered ?? !1, S = l?.draggableColumns ?? !1, C = l?.resizableColumns ?? !1, w = l?.columnVisibility ?? !1, T = l?.fixedActions ?? !1, { sortColumn: O, sortDirection: k, selectedRows: M, setSelectedRows: N, visibleColumns: P, columnWidths: F, safeCurrentPage: ee, totalPages: I, startIndex: L, endIndex: R, tableRef: z, hasActions: B, hasBulkActions: V, visibleColumnsArray: H, colSpanCount: U, paginatedData: W, handleSort: G, handleMouseDown: q, handleDragStart: X, handleDragOver: Q, handleDrop: $, toggleColumnVisibility: ne, toggleRowSelection: ae, toggleSelectAll: oe, pageSize: se, setPageSize: ce, setCurrentPage: le } = E({
451
+ function $({ data: e, isLoading: t = !1, error: n = null, config: r, server: i }) {
452
+ let { columns: a, rowKey: o, onRowClick: s, onRowNavigate: c, actions: l, bulkActions: u } = r, d = r.pageSizeDefault ?? ee, f = r.pageSizeOptions ?? K, p = r.dense ?? !1, m = r.bordered ?? !1, h = r.draggableColumns ?? !1, g = r.resizableColumns ?? !1, _ = r.columnVisibility ?? !1, v = r.fixedActions ?? !1, { sortColumn: y, sortDirection: b, selectedRows: x, setSelectedRows: S, visibleColumns: C, columnWidths: w, safeCurrentPage: T, totalPages: O, startIndex: k, endIndex: M, tableRef: N, hasActions: P, hasBulkActions: F, visibleColumnsArray: I, colSpanCount: L, paginatedData: R, handleSort: z, handleMouseDown: B, handleDragStart: V, handleDragOver: H, handleDrop: U, toggleColumnVisibility: W, toggleRowSelection: G, toggleSelectAll: q, pageSize: X, setPageSize: Z, setCurrentPage: Q } = E({
453
453
  data: e,
454
- columns: t,
455
- getRowId: n,
456
- defaultPageSize: u,
457
- actions: a,
458
- bulkActions: o,
459
- columnVisibility: w,
460
- totalRows: f,
461
- currentPage: p,
462
- pageSize: m,
463
- onPageChange: h,
464
- onPageSizeChange: g,
465
- sortColumn: _,
466
- sortDirection: v,
467
- onSortChange: y
468
- }), ue = V && H.some((e) => e.fixed === "left"), de = D(z);
454
+ columns: a,
455
+ rowKey: o,
456
+ pageSizeDefault: d,
457
+ actions: l,
458
+ bulkActions: u,
459
+ columnVisibility: _,
460
+ server: i
461
+ }), ne = F && I.some((e) => e.fixed === "left"), $ = D(N);
469
462
  return /* @__PURE__ */ j("div", {
470
463
  className: "space-y-4 [--k-radius-control:var(--k-radius-control-dense,0.5rem)] [--k-radius-surface:var(--k-radius-surface-dense,0.75rem)]",
471
- children: [M.length > 0 && o !== void 0 && o.length > 0 && /* @__PURE__ */ A(Y, {
472
- selectedRows: M,
473
- setSelectedRows: N,
474
- bulkActions: o
464
+ children: [x.length > 0 && u !== void 0 && u.length > 0 && /* @__PURE__ */ A(Y, {
465
+ selectedRows: x,
466
+ setSelectedRows: S,
467
+ bulkActions: u
475
468
  }), /* @__PURE__ */ j("div", {
476
469
  className: "w-full bg-card rounded-surface border border-border overflow-hidden",
477
470
  children: [/* @__PURE__ */ A("div", {
478
471
  className: "overflow-x-auto",
479
472
  children: /* @__PURE__ */ j("table", {
480
- ref: z,
473
+ ref: N,
481
474
  className: "w-full",
482
- children: [/* @__PURE__ */ A(Z, {
483
- hasBulkActions: V,
484
- selectedRows: M,
475
+ children: [/* @__PURE__ */ A(te, {
476
+ hasBulkActions: F,
477
+ selectedRows: x,
485
478
  totalItems: e.length,
486
- toggleSelectAll: oe,
487
- visibleColumnsArray: H,
488
- draggableColumns: S,
489
- resizableColumns: C,
490
- columnWidths: F,
491
- sortColumn: O,
492
- sortDirection: k,
493
- handleSort: G,
494
- handleDragStart: X,
495
- handleDragOver: Q,
496
- handleDrop: $,
497
- handleMouseDown: q,
498
- hasActions: B,
499
- bordered: x,
500
- dense: b,
501
- fixedColumns: de,
502
- fixedSelection: ue,
503
- fixedActions: T,
504
- settingsNode: w ? /* @__PURE__ */ A(ie, {
505
- columns: t,
506
- visibleColumns: P,
507
- toggleColumnVisibility: ne
479
+ toggleSelectAll: q,
480
+ visibleColumnsArray: I,
481
+ draggableColumns: h,
482
+ resizableColumns: g,
483
+ columnWidths: w,
484
+ sortColumn: y,
485
+ sortDirection: b,
486
+ handleSort: z,
487
+ handleDragStart: V,
488
+ handleDragOver: H,
489
+ handleDrop: U,
490
+ handleMouseDown: B,
491
+ hasActions: P,
492
+ bordered: m,
493
+ dense: p,
494
+ fixedColumns: $,
495
+ fixedSelection: ne,
496
+ fixedActions: v,
497
+ settingsNode: _ ? /* @__PURE__ */ A(ie, {
498
+ columns: a,
499
+ visibleColumns: C,
500
+ toggleColumnVisibility: W
508
501
  }) : void 0
509
502
  }), /* @__PURE__ */ A(J, {
510
- bordered: x,
511
- dense: b,
512
- isLoading: s,
513
- error: c,
514
- colSpanCount: U,
515
- messages: l?.messages,
516
- paginatedData: W,
517
- getRowId: n,
518
- onRowClick: r,
519
- onRowNavigate: i,
520
- hasBulkActions: V,
521
- selectedRows: M,
522
- toggleRowSelection: ae,
523
- visibleColumnsArray: H,
524
- columnWidths: F,
525
- hasActions: B || w,
526
- actions: a,
527
- columns: t,
528
- resizableColumns: C,
529
- fixedColumns: de
503
+ bordered: m,
504
+ dense: p,
505
+ isLoading: t,
506
+ error: n,
507
+ colSpanCount: L,
508
+ messages: r.messages,
509
+ paginatedData: R,
510
+ rowKey: o,
511
+ onRowClick: s,
512
+ onRowNavigate: c,
513
+ hasBulkActions: F,
514
+ selectedRows: x,
515
+ toggleRowSelection: G,
516
+ visibleColumnsArray: I,
517
+ columnWidths: w,
518
+ hasActions: P || _,
519
+ actions: l,
520
+ columns: a,
521
+ resizableColumns: g,
522
+ fixedColumns: $
530
523
  })]
531
524
  })
532
525
  }), /* @__PURE__ */ A(re, {
533
- totalItems: f ?? e.length,
534
- startIndex: L,
535
- endIndex: R,
536
- pageSize: se,
537
- setPageSize: ce,
538
- currentPage: ee,
539
- setCurrentPage: le,
540
- pageSizeOptions: d,
541
- totalPages: I
526
+ totalItems: i?.totalRows ?? e.length,
527
+ startIndex: k,
528
+ endIndex: M,
529
+ pageSize: X,
530
+ setPageSize: Z,
531
+ currentPage: T,
532
+ setCurrentPage: Q,
533
+ pageSizeOptions: f,
534
+ totalPages: O
542
535
  })]
543
536
  })]
544
537
  });
545
538
  }
546
539
  //#endregion
547
540
  //#region src/components/core/table/JsonTableOutput.tsx
548
- var oe = ({ header: e, output: t }) => {
549
- let [n, r] = O(!0), i = F(t), c = i !== null, l = () => /* @__PURE__ */ j("div", {
541
+ var ae = ({ header: e, output: t }) => {
542
+ let [n, r] = O(!0), i = P(t), a = i !== null, l = () => /* @__PURE__ */ j("div", {
550
543
  className: "flex items-center justify-between mb-2",
551
544
  children: [/* @__PURE__ */ A("span", {
552
545
  className: "font-medium text-sm",
553
546
  children: e
554
547
  }), /* @__PURE__ */ j("div", {
555
548
  className: "flex items-center gap-2",
556
- children: [/* @__PURE__ */ A(v, {
549
+ children: [/* @__PURE__ */ A(y, {
557
550
  id: "table-mode",
558
551
  checked: n,
559
552
  onCheckedChange: r
560
- }), /* @__PURE__ */ A(a, {
553
+ }), /* @__PURE__ */ A(o, {
561
554
  htmlFor: "table-mode",
562
555
  className: "text-xs",
563
556
  children: "Mode tableau"
@@ -565,45 +558,45 @@ var oe = ({ header: e, output: t }) => {
565
558
  })]
566
559
  }), u = ({ children: e }) => /* @__PURE__ */ A("div", {
567
560
  className: "border rounded min-w-0 w-full",
568
- children: /* @__PURE__ */ A(p, { children: e })
561
+ children: /* @__PURE__ */ A(m, { children: e })
569
562
  }), d = () => /* @__PURE__ */ A("pre", {
570
563
  className: "text-xs bg-muted p-4 rounded overflow-x-auto whitespace-pre-wrap",
571
- children: c && !n ? JSON.stringify(i, null, 2) : t
564
+ children: a && !n ? JSON.stringify(i, null, 2) : t
572
565
  });
573
566
  return t ? /* @__PURE__ */ j("div", {
574
567
  className: "min-w-0 w-full",
575
568
  children: [l(), (() => {
576
- if (!c || !n) return /* @__PURE__ */ A(d, {});
577
- if (Array.isArray(i) && i.length > 0 && P(i[0])) {
569
+ if (!a || !n) return /* @__PURE__ */ A(d, {});
570
+ if (Array.isArray(i) && i.length > 0 && N(i[0])) {
578
571
  let e = i, t = Object.keys(e[0]);
579
- return /* @__PURE__ */ j(u, { children: [/* @__PURE__ */ A(f, {
572
+ return /* @__PURE__ */ j(u, { children: [/* @__PURE__ */ A(p, {
580
573
  className: "bg-muted/50",
581
- children: /* @__PURE__ */ A(_, { children: t.map((e) => /* @__PURE__ */ A(s, {
574
+ children: /* @__PURE__ */ A(v, { children: t.map((e) => /* @__PURE__ */ A(c, {
582
575
  className: "font-medium",
583
576
  children: e
584
577
  }, e)) })
585
- }), /* @__PURE__ */ A(o, { children: e.map((e, n) => /* @__PURE__ */ A(_, { children: t.map((t) => /* @__PURE__ */ A(m, {
578
+ }), /* @__PURE__ */ A(s, { children: e.map((e, n) => /* @__PURE__ */ A(v, { children: t.map((t) => /* @__PURE__ */ A(h, {
586
579
  className: "text-sm whitespace-pre-wrap",
587
- children: N(e[t])
580
+ children: M(e[t])
588
581
  }, t)) }, n)) })] });
589
582
  }
590
- if (P(i)) {
583
+ if (N(i)) {
591
584
  let e = Object.entries(i);
592
- return /* @__PURE__ */ j(u, { children: [/* @__PURE__ */ A(f, {
585
+ return /* @__PURE__ */ j(u, { children: [/* @__PURE__ */ A(p, {
593
586
  className: "bg-muted/50",
594
- children: /* @__PURE__ */ j(_, { children: [/* @__PURE__ */ A(s, {
587
+ children: /* @__PURE__ */ j(v, { children: [/* @__PURE__ */ A(c, {
595
588
  className: "font-medium",
596
589
  children: "Propriété"
597
- }), /* @__PURE__ */ A(s, {
590
+ }), /* @__PURE__ */ A(c, {
598
591
  className: "font-medium",
599
592
  children: "Valeur"
600
593
  })] })
601
- }), /* @__PURE__ */ A(o, { children: e.map(([e, t]) => /* @__PURE__ */ j(_, { children: [/* @__PURE__ */ A(m, {
594
+ }), /* @__PURE__ */ A(s, { children: e.map(([e, t]) => /* @__PURE__ */ j(v, { children: [/* @__PURE__ */ A(h, {
602
595
  className: "font-medium text-sm",
603
596
  children: e
604
- }), /* @__PURE__ */ A(m, {
597
+ }), /* @__PURE__ */ A(h, {
605
598
  className: "text-sm whitespace-pre-wrap",
606
- children: N(t)
599
+ children: M(t)
607
600
  })] }, e)) })] });
608
601
  }
609
602
  return /* @__PURE__ */ A(d, {});
@@ -611,4 +604,4 @@ var oe = ({ header: e, output: t }) => {
611
604
  }) : null;
612
605
  };
613
606
  //#endregion
614
- export { Z as a, q as c, re as i, ae as n, Y as o, ie as r, J as s, oe as t };
607
+ export { te as a, q as c, re as i, $ as n, Y as o, ie as r, J as s, ae as t };