@archbase/template 3.0.0 → 3.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,15 +1,15 @@
1
- import { jsx as e, Fragment as Fe, jsxs as C } from "react/jsx-runtime";
2
- import { Button as Pe, Paper as Je, Box as Se, ScrollArea as it, LoadingOverlay as ot, Group as ge, useMantineColorScheme as He, Modal as lt, Flex as ce, px as vt, Text as bt, Grid as he, Pagination as st } from "@mantine/core";
3
- import { useForceUpdate as at, useUncontrolled as wt, useHotkeys as At } from "@mantine/hooks";
4
- import { IconBug as Ge, IconDeviceFloppy as yt, IconX as Te, IconCheck as ct, IconPlus as We, IconEdit as Ke, IconTrash as Qe, IconEye as Xe } from "@tabler/icons-react";
5
- import { useArchbaseAppContext as xe, useValidationErrors as Ct, ValidationErrorsProvider as dt, getI18nextInstance as p, processErrorMessage as ae, useArchbaseTheme as Ye, emit as Ft, useArchbaseTranslation as Rt } from "@archbase/core";
6
- import Ie, { useMemo as Ce, useState as te, forwardRef as Et, useRef as se, useImperativeHandle as It, useEffect as ut, Fragment as Tt, Profiler as Dt, createContext as Vt, useCallback as Be, useContext as ht } from "react";
7
- import { useArchbaseV1V2Compatibility as De, useArchbaseDataSourceListener as Ze, DataSourceEventNames as fe } from "@archbase/data";
8
- import { ArchbaseAlert as $e, ArchbaseDialog as ft, ArchbaseDataGrid as St, GridToolBarActions as Bt, ArchbaseDebugInspector as Nt, ArchbaseMasonryProvider as Pt, ArchbaseMasonryResponsive as Gt, ArchbaseMasonry as $t, ArchbaseActionButtons as mt } from "@archbase/components";
9
- import { ArchbaseSpaceFixed as Oe, ArchbaseSpaceTop as pt, ArchbaseSpaceFill as et, ArchbaseForm as gt, ArchbaseSpaceBottom as tt } from "@archbase/layout";
10
- import { ArchbaseQueryBuilder as rt, buildFrom as Ut, ArchbaseGlobalFilter as jt } from "@archbase/advanced";
11
- import Ne from "@rehooks/component-size";
12
- import { uniqueId as Lt } from "lodash";
1
+ import { jsx as e, Fragment as Re, jsxs as C } from "react/jsx-runtime";
2
+ import { Button as Ge, Paper as Je, Box as Be, ScrollArea as ot, LoadingOverlay as lt, Group as ve, useMantineColorScheme as He, Modal as st, Flex as de, px as bt, Text as wt, Grid as me, Pagination as at } from "@mantine/core";
3
+ import { useForceUpdate as ct, useUncontrolled as At, useHotkeys as yt } from "@mantine/hooks";
4
+ import { IconBug as $e, IconDeviceFloppy as Ct, IconX as De, IconCheck as dt, IconPlus as We, IconEdit as Ke, IconTrash as Qe, IconEye as Xe } from "@tabler/icons-react";
5
+ import { useArchbaseAppContext as we, useValidationErrors as Ft, ValidationErrorsProvider as ut, getI18nextInstance as m, processErrorMessage as ce, useArchbaseTheme as Ye, emit as Rt, useArchbaseTranslation as Et } from "@archbase/core";
6
+ import Ve, { useMemo as be, useState as ne, forwardRef as It, useRef as ae, useImperativeHandle as Tt, useEffect as ht, Fragment as Vt, Profiler as Dt, createContext as St, useCallback as Ne, useContext as ft } from "react";
7
+ import { useArchbaseV1V2Compatibility as Se, useArchbaseDataSourceListener as Ze, DataSourceEventNames as pe } from "@archbase/data";
8
+ import { ArchbaseAlert as Ue, ArchbaseDialog as mt, ArchbaseDataGrid as Bt, GridToolBarActions as Nt, ArchbaseDebugInspector as Pt, ArchbaseMasonryProvider as Gt, ArchbaseMasonryResponsive as $t, ArchbaseMasonry as Ut, ArchbaseActionButtons as pt } from "@archbase/components";
9
+ import { ArchbaseSpaceFixed as Oe, ArchbaseSpaceTop as gt, ArchbaseSpaceFill as et, ArchbaseForm as xt, ArchbaseSpaceBottom as tt } from "@archbase/layout";
10
+ import { ArchbaseQueryBuilder as rt, buildFrom as jt, ArchbaseGlobalFilter as Lt } from "@archbase/advanced";
11
+ import Pe from "@rehooks/component-size";
12
+ import { uniqueId as Mt } from "lodash";
13
13
  const kt = {
14
14
  isAvailable: !1,
15
15
  hasPermission: () => !0,
@@ -21,20 +21,20 @@ const kt = {
21
21
  canEdit: !0,
22
22
  canDelete: !0,
23
23
  canView: !0
24
- }, me = (t) => Ce(() => kt, []), lr = () => !1, ie = ({
24
+ }, ge = (t) => be(() => kt, []), sr = () => !1, oe = ({
25
25
  actionName: t,
26
26
  actionDescription: r,
27
27
  children: a,
28
28
  fallback: d = null,
29
29
  autoRegister: n = !0,
30
30
  onClick: o,
31
- ...h
31
+ ...u
32
32
  }) => {
33
- const m = me();
34
- return Ie.useEffect(() => {
35
- n && t && r && m.isAvailable && m.registerAction();
36
- }, [t, r, n, m.isAvailable, m.registerAction]), !t || !m.isAvailable ? /* @__PURE__ */ e(Pe, { onClick: o, ...h, children: a }) : m.hasPermission() ? /* @__PURE__ */ e(Pe, { onClick: o, ...h, children: a }) : /* @__PURE__ */ e(Fe, { children: d });
37
- }, sr = ({
33
+ const f = ge();
34
+ return Ve.useEffect(() => {
35
+ n && t && r && f.isAvailable && f.registerAction();
36
+ }, [t, r, n, f.isAvailable, f.registerAction]), !t || !f.isAvailable ? /* @__PURE__ */ e(Ge, { onClick: o, ...u, children: a }) : f.hasPermission() ? /* @__PURE__ */ e(Ge, { onClick: o, ...u, children: a }) : /* @__PURE__ */ e(Re, { children: d });
37
+ }, ar = ({
38
38
  actionName: t,
39
39
  actionDescription: r,
40
40
  children: a,
@@ -42,42 +42,42 @@ const kt = {
42
42
  onClick: n,
43
43
  ...o
44
44
  }) => {
45
- const [h, m] = Ie.useState(null), [T, v] = Ie.useState(!1);
46
- return Ie.useEffect(() => {
45
+ const [u, f] = Ve.useState(null), [T, v] = Ve.useState(!1);
46
+ return Ve.useEffect(() => {
47
47
  if (!t) {
48
- m(/* @__PURE__ */ e(Pe, { onClick: n, ...o, children: a }));
48
+ f(/* @__PURE__ */ e(Ge, { onClick: n, ...o, children: a }));
49
49
  return;
50
50
  }
51
- v(!1), m(/* @__PURE__ */ e(Pe, { onClick: n, ...o, children: a }));
52
- }, [t, r, a, d, o]), /* @__PURE__ */ e(Fe, { children: h });
53
- }, ve = ({
51
+ v(!1), f(/* @__PURE__ */ e(Ge, { onClick: n, ...o, children: a }));
52
+ }, [t, r, a, d, o]), /* @__PURE__ */ e(Re, { children: u });
53
+ }, Ae = ({
54
54
  children: t
55
- }) => /* @__PURE__ */ e(Fe, { children: t }), ar = (t) => Ce(() => ({
55
+ }) => /* @__PURE__ */ e(Re, { children: t }), cr = (t) => be(() => ({
56
56
  shouldWrap: !1,
57
57
  isSecurityAvailable: !1,
58
58
  hasResourceName: !!t
59
59
  }), [t]);
60
- function cr({
60
+ function dr({
61
61
  innerRef: t,
62
62
  title: r,
63
63
  isError: a = !1,
64
64
  isCanceling: d = !1,
65
65
  isSaving: n = !1,
66
66
  error: o = "",
67
- clearError: h = () => {
67
+ clearError: u = () => {
68
68
  },
69
- autoCloseAlertError: m = 15e3,
69
+ autoCloseAlertError: f = 15e3,
70
70
  width: T = "100%",
71
71
  height: v = "100%",
72
- withBorder: O = !0,
72
+ withBorder: te = !0,
73
73
  children: l,
74
74
  radius: c,
75
- variant: q,
75
+ variant: L,
76
76
  footerAlign: A = "left",
77
- footerContent: D,
78
- dataSource: f,
77
+ footerContent: V,
78
+ dataSource: h,
79
79
  onSave: B,
80
- onCancel: W,
80
+ onCancel: _,
81
81
  onBeforeSave: N,
82
82
  onAfterSave: Y,
83
83
  onBeforeCancel: b,
@@ -85,61 +85,61 @@ function cr({
85
85
  onError: y,
86
86
  // Props de segurança (opcionais)
87
87
  resourceName: Z,
88
- resourceDescription: K,
88
+ resourceDescription: J,
89
89
  requiredPermissions: P,
90
- fallbackComponent: E,
90
+ fallbackComponent: I,
91
91
  securityOptions: F,
92
92
  ...G
93
93
  }) {
94
- const w = xe(), [$, R] = te(a), [re, Q] = te(o), M = at();
95
- me({
94
+ const w = we(), [$, R] = ne(a), [ie, H] = ne(o), M = ct();
95
+ ge({
96
96
  autoRegisterActions: F?.autoRegisterActions ?? !0
97
97
  });
98
- const V = De(
98
+ const S = Se(
99
99
  "ArchbaseFormTemplate",
100
- f,
100
+ h,
101
101
  void 0,
102
102
  void 0
103
103
  );
104
104
  Ze({
105
- dataSource: f,
106
- listener: (I) => {
107
- I.type === fe.onError && (R(!0), Q(I.error)), (I.type === fe.afterEdit || I.type === fe.afterInsert) && (V.isDataSourceV2 || M());
105
+ dataSource: h,
106
+ listener: (E) => {
107
+ E.type === pe.onError && (R(!0), H(E.error)), (E.type === pe.afterEdit || E.type === pe.afterInsert) && (S.isDataSourceV2 || M());
108
108
  }
109
109
  });
110
- const U = Ct(), _ = async (I) => {
110
+ const U = Ft(), k = async (E) => {
111
111
  try {
112
- B ? B(I) : (N && await N(I), f.isBrowsing() || f.save().then(() => {
113
- U?.clearAll(), Y && Y(I);
114
- }).catch((ee) => {
115
- y && y(ae(ee)), R(!0), Q(ae(ee));
112
+ B ? B(E) : (N && await N(E), h.isBrowsing() || h.save().then(() => {
113
+ U?.clearAll(), Y && Y(E);
114
+ }).catch((re) => {
115
+ y && y(ce(re)), R(!0), H(ce(re));
116
116
  }));
117
- } catch (ee) {
118
- y && y(ae(ee)), R(!0), Q(ae(ee));
117
+ } catch (re) {
118
+ y && y(ce(re)), R(!0), H(ce(re));
119
119
  }
120
- }, J = () => {
120
+ }, z = () => {
121
121
  try {
122
- W ? W() : (b && b(), f.isBrowsing() || f.cancel(), U?.clearAll(), x && x());
123
- } catch (I) {
124
- y && y(ae(I)), R(!0), Q(ae(I));
122
+ _ ? _() : (b && b(), h.isBrowsing() || h.cancel(), U?.clearAll(), x && x());
123
+ } catch (E) {
124
+ y && y(ce(E)), R(!0), H(ce(E));
125
125
  }
126
- }, X = () => {
127
- h && h(), R(!1), Q("");
126
+ }, W = () => {
127
+ u && u(), R(!1), H("");
128
128
  };
129
129
  return /* @__PURE__ */ e(
130
- ve,
130
+ Ae,
131
131
  {
132
132
  resourceName: Z,
133
- resourceDescription: K,
133
+ resourceDescription: J,
134
134
  requiredPermissions: P,
135
- fallbackComponent: E,
135
+ fallbackComponent: I,
136
136
  onSecurityReady: F?.onSecurityReady,
137
137
  onAccessDenied: F?.onAccessDenied,
138
- children: /* @__PURE__ */ e(dt, { children: /* @__PURE__ */ C(
138
+ children: /* @__PURE__ */ e(ut, { children: /* @__PURE__ */ C(
139
139
  Je,
140
140
  {
141
141
  ref: t,
142
- withBorder: O,
142
+ withBorder: te,
143
143
  radius: c,
144
144
  style: {
145
145
  width: T,
@@ -149,22 +149,22 @@ function cr({
149
149
  padding: 4
150
150
  },
151
151
  children: [
152
- $ && /* @__PURE__ */ e(Se, { style: { flexShrink: 0 }, children: /* @__PURE__ */ e(
153
- $e,
152
+ $ && /* @__PURE__ */ e(Be, { style: { flexShrink: 0 }, children: /* @__PURE__ */ e(
153
+ Ue,
154
154
  {
155
- autoClose: m,
155
+ autoClose: f,
156
156
  withCloseButton: !0,
157
157
  withBorder: !0,
158
- icon: /* @__PURE__ */ e(Ge, { size: "1.4rem" }),
159
- title: p().t("WARNING"),
158
+ icon: /* @__PURE__ */ e($e, { size: "1.4rem" }),
159
+ title: m().t("WARNING"),
160
160
  titleColor: "rgb(250, 82, 82)",
161
- variant: q ?? w.variant,
162
- onClose: X,
163
- children: /* @__PURE__ */ e("span", { children: re })
161
+ variant: L ?? w.variant,
162
+ onClose: W,
163
+ children: /* @__PURE__ */ e("span", { children: ie })
164
164
  }
165
165
  ) }),
166
166
  /* @__PURE__ */ C(
167
- it,
167
+ ot,
168
168
  {
169
169
  style: {
170
170
  flex: 1,
@@ -173,13 +173,13 @@ function cr({
173
173
  padding: "calc(0.625rem / 2)"
174
174
  },
175
175
  children: [
176
- /* @__PURE__ */ e(ot, { visible: d || n, opacity: 0.3 }),
176
+ /* @__PURE__ */ e(lt, { visible: d || n, opacity: 0.3 }),
177
177
  l
178
178
  ]
179
179
  }
180
180
  ),
181
181
  /* @__PURE__ */ C(
182
- Se,
182
+ Be,
183
183
  {
184
184
  style: {
185
185
  flexShrink: 0,
@@ -190,46 +190,46 @@ function cr({
190
190
  gap: "1rem"
191
191
  },
192
192
  children: [
193
- A === "right" && D && /* @__PURE__ */ e(Se, { style: { flex: 1 }, children: D }),
194
- f && !f.isBrowsing() ? /* @__PURE__ */ C(ge, { gap: "md", children: [
193
+ A === "right" && V && /* @__PURE__ */ e(Be, { style: { flex: 1 }, children: V }),
194
+ h && !h.isBrowsing() ? /* @__PURE__ */ C(ve, { gap: "md", children: [
195
195
  /* @__PURE__ */ e(
196
- ie,
196
+ oe,
197
197
  {
198
198
  actionName: "save",
199
- actionDescription: `Salvar ${K || "registro"}`,
200
- leftSection: /* @__PURE__ */ e(yt, {}),
201
- onClick: () => _(f.getCurrentRecord()),
202
- disabled: f && f.isBrowsing(),
203
- variant: q ?? w.variant,
199
+ actionDescription: `Salvar ${J || "registro"}`,
200
+ leftSection: /* @__PURE__ */ e(Ct, {}),
201
+ onClick: () => k(h.getCurrentRecord()),
202
+ disabled: h && h.isBrowsing(),
203
+ variant: L ?? w.variant,
204
204
  color: "green",
205
- children: `${p().t("Ok")}`
205
+ children: `${m().t("Ok")}`
206
206
  }
207
207
  ),
208
208
  /* @__PURE__ */ e(
209
- ie,
209
+ oe,
210
210
  {
211
211
  actionName: "cancel",
212
212
  actionDescription: "Cancelar operação",
213
- leftSection: /* @__PURE__ */ e(Te, {}),
214
- onClick: J,
215
- disabled: f && f.isBrowsing(),
216
- variant: q ?? w.variant,
213
+ leftSection: /* @__PURE__ */ e(De, {}),
214
+ onClick: z,
215
+ disabled: h && h.isBrowsing(),
216
+ variant: L ?? w.variant,
217
217
  color: "red",
218
- children: `${p().t("Cancel")}`
218
+ children: `${m().t("Cancel")}`
219
219
  }
220
220
  )
221
- ] }) : /* @__PURE__ */ e(ge, { gap: "md", children: /* @__PURE__ */ e(
222
- ie,
221
+ ] }) : /* @__PURE__ */ e(ve, { gap: "md", children: /* @__PURE__ */ e(
222
+ oe,
223
223
  {
224
224
  actionName: "close",
225
225
  actionDescription: "Fechar formulário",
226
- leftSection: /* @__PURE__ */ e(Te, {}),
227
- onClick: J,
228
- variant: q ?? w.variant,
229
- children: `${p().t("Close")}`
226
+ leftSection: /* @__PURE__ */ e(De, {}),
227
+ onClick: z,
228
+ variant: L ?? w.variant,
229
+ children: `${m().t("Close")}`
230
230
  }
231
231
  ) }),
232
- (A === "left" || A === "center") && D && /* @__PURE__ */ e(Se, { style: { flex: A === "left" ? 1 : 0, textAlign: "right" }, children: D })
232
+ (A === "left" || A === "center") && V && /* @__PURE__ */ e(Be, { style: { flex: A === "left" ? 1 : 0, textAlign: "right" }, children: V })
233
233
  ]
234
234
  }
235
235
  )
@@ -239,26 +239,26 @@ function cr({
239
239
  }
240
240
  );
241
241
  }
242
- function dr({
242
+ function ur({
243
243
  title: t,
244
244
  withOverlay: r = !0,
245
245
  overlayProps: a,
246
246
  children: d,
247
247
  withCloseButton: n = !0,
248
248
  closeButtonProps: o,
249
- opened: h,
250
- fullScreen: m,
249
+ opened: u,
250
+ fullScreen: f,
251
251
  centered: T,
252
252
  variant: v,
253
- closeOnEscape: O = !0,
253
+ closeOnEscape: te = !0,
254
254
  size: l,
255
255
  dataSource: c,
256
- height: q,
256
+ height: L,
257
257
  userActions: A,
258
- onAfterSave: D,
259
- onClickOk: f,
258
+ onAfterSave: V,
259
+ onClickOk: h,
260
260
  onClickCancel: B,
261
- onBeforeOk: W,
261
+ onBeforeOk: _,
262
262
  onCustomSave: N,
263
263
  isError: Y,
264
264
  error: b = "",
@@ -266,21 +266,21 @@ function dr({
266
266
  },
267
267
  onError: y,
268
268
  autoCloseAlertError: Z = 15e3,
269
- loadingOverlayStyles: K,
269
+ loadingOverlayStyles: J,
270
270
  // Props de segurança (opcionais)
271
271
  resourceName: P,
272
- resourceDescription: E,
272
+ resourceDescription: I,
273
273
  requiredPermissions: F,
274
274
  fallbackComponent: G,
275
275
  securityOptions: w,
276
276
  ...$
277
277
  }) {
278
- const R = xe(), re = Ye(), { colorScheme: Q } = He(), [M, V] = te(Y), [U, _] = te(b), [J, X] = te(!1), I = at();
279
- me({
280
- resourceDescription: E || t?.toString(),
278
+ const R = we(), ie = Ye(), { colorScheme: H } = He(), [M, S] = ne(Y), [U, k] = ne(b), [z, W] = ne(!1), E = ct();
279
+ ge({
280
+ resourceDescription: I || t?.toString(),
281
281
  autoRegisterActions: w?.autoRegisterActions ?? !0
282
282
  });
283
- const ee = De(
283
+ const re = Se(
284
284
  "ArchbaseFormModalTemplate",
285
285
  c,
286
286
  void 0,
@@ -288,128 +288,128 @@ function dr({
288
288
  );
289
289
  Ze({
290
290
  dataSource: c,
291
- listener: (j) => {
292
- j.type === fe.onError && (V(!0), _(j.error)), (j.type === fe.afterEdit || j.type === fe.afterInsert) && (ee.isDataSourceV2 || I());
291
+ listener: (Q) => {
292
+ Q.type === pe.onError && (S(!0), k(Q.error)), (Q.type === pe.afterEdit || Q.type === pe.afterInsert) && (re.isDataSourceV2 || E());
293
293
  }
294
294
  });
295
- const ue = async () => {
295
+ const he = async () => {
296
296
  if (c && !c.isBrowsing())
297
297
  try {
298
- X(!0), await c.save(), D && D(c.getCurrentRecord());
299
- } catch (j) {
300
- return y && y(ae(j)), V(!0), _(ae(j)), X(!1), !1;
298
+ W(!0), await c.save(), V && V(c.getCurrentRecord());
299
+ } catch (Q) {
300
+ return y && y(ce(Q)), S(!0), k(ce(Q)), W(!1), !1;
301
301
  }
302
- return X(!1), !0;
302
+ return W(!1), !0;
303
303
  }, s = () => {
304
304
  if (c && !c.isBrowsing())
305
305
  try {
306
306
  c.cancel();
307
307
  } catch {
308
308
  }
309
- }, H = async () => {
309
+ }, q = async () => {
310
310
  if (N)
311
311
  c && N(c.getCurrentRecord(), () => {
312
- f && f();
312
+ h && h();
313
313
  });
314
- else if (W) {
315
- const j = W(c.getCurrentRecord());
316
- j instanceof Promise && j.then(async () => {
317
- await ue() && f && f();
318
- }).catch((be) => {
319
- y && y(ae(be)), V(!0), _(ae(be));
314
+ else if (_) {
315
+ const Q = _(c.getCurrentRecord());
316
+ Q instanceof Promise && Q.then(async () => {
317
+ await he() && h && h();
318
+ }).catch((fe) => {
319
+ y && y(ce(fe)), S(!0), k(ce(fe));
320
320
  });
321
321
  } else
322
- await ue() && f && f();
323
- }, S = () => {
322
+ await he() && h && h();
323
+ }, O = () => {
324
324
  s(), B && B();
325
- }, oe = () => {
326
- ft.showWarning(p().t("archbase:Click on Ok or Cancel to close"));
327
- }, pe = () => {
328
- x && x(), V(!1), _("");
325
+ }, K = () => {
326
+ mt.showWarning(m().t("archbase:Click on Ok or Cancel to close"));
327
+ }, xe = () => {
328
+ x && x(), S(!1), k("");
329
329
  };
330
330
  return /* @__PURE__ */ e(
331
- ve,
331
+ Ae,
332
332
  {
333
333
  resourceName: P,
334
- resourceDescription: E,
334
+ resourceDescription: I,
335
335
  requiredPermissions: F,
336
336
  fallbackComponent: G,
337
337
  onSecurityReady: w?.onSecurityReady,
338
338
  onAccessDenied: w?.onAccessDenied,
339
339
  children: /* @__PURE__ */ e(
340
- lt,
340
+ st,
341
341
  {
342
342
  title: t,
343
343
  withOverlay: r,
344
344
  overlayProps: a || {
345
- color: Q === "dark" ? re.colors.dark[7] : re.colors.gray[6],
345
+ color: H === "dark" ? ie.colors.dark[7] : ie.colors.gray[6],
346
346
  opacity: 0.25
347
347
  },
348
348
  withCloseButton: n,
349
349
  closeButtonProps: o,
350
- onClose: oe,
351
- opened: h,
352
- fullScreen: m,
350
+ onClose: K,
351
+ opened: u,
352
+ fullScreen: f,
353
353
  centered: T,
354
- closeOnEscape: O,
354
+ closeOnEscape: te,
355
355
  size: l,
356
356
  ...$,
357
- children: /* @__PURE__ */ C(dt, { children: [
358
- /* @__PURE__ */ e(ot, { styles: K, visible: J, opacity: 0.8 }),
359
- /* @__PURE__ */ C(Oe, { height: q, children: [
360
- M ? /* @__PURE__ */ e(pt, { size: "100px", children: /* @__PURE__ */ e(
361
- $e,
357
+ children: /* @__PURE__ */ C(ut, { children: [
358
+ /* @__PURE__ */ e(lt, { styles: J, visible: z, opacity: 0.8 }),
359
+ /* @__PURE__ */ C(Oe, { height: L, children: [
360
+ M ? /* @__PURE__ */ e(gt, { size: "100px", children: /* @__PURE__ */ e(
361
+ Ue,
362
362
  {
363
363
  autoClose: Z,
364
364
  withCloseButton: !0,
365
365
  withBorder: !0,
366
- icon: /* @__PURE__ */ e(Ge, { size: "1.4rem" }),
367
- title: p().t("WARNING"),
366
+ icon: /* @__PURE__ */ e($e, { size: "1.4rem" }),
367
+ title: m().t("WARNING"),
368
368
  titleColor: "rgb(250, 82, 82)",
369
369
  variant: v ?? R.variant,
370
- onClose: pe,
370
+ onClose: xe,
371
371
  children: /* @__PURE__ */ e("span", { children: U })
372
372
  }
373
373
  ) }) : null,
374
- /* @__PURE__ */ e(et, { children: /* @__PURE__ */ e(gt, { children: d }) }),
375
- /* @__PURE__ */ e(tt, { size: "40px", children: /* @__PURE__ */ C(ce, { justify: "space-between", align: "center", children: [
376
- /* @__PURE__ */ e(ge, { children: A }),
377
- c && !c.isBrowsing() ? /* @__PURE__ */ C(ge, { gap: "md", children: [
374
+ /* @__PURE__ */ e(et, { children: /* @__PURE__ */ e(xt, { children: d }) }),
375
+ /* @__PURE__ */ e(tt, { size: "40px", children: /* @__PURE__ */ C(de, { justify: "space-between", align: "center", children: [
376
+ /* @__PURE__ */ e(ve, { children: A }),
377
+ c && !c.isBrowsing() ? /* @__PURE__ */ C(ve, { gap: "md", children: [
378
378
  /* @__PURE__ */ e(
379
- ie,
379
+ oe,
380
380
  {
381
381
  actionName: "save",
382
- actionDescription: `Salvar ${E || t || "registro"}`,
383
- leftSection: /* @__PURE__ */ e(ct, {}),
384
- onClick: H,
382
+ actionDescription: `Salvar ${I || t || "registro"}`,
383
+ leftSection: /* @__PURE__ */ e(dt, {}),
384
+ onClick: q,
385
385
  disabled: c && c.isBrowsing(),
386
386
  variant: v ?? R.variant,
387
387
  color: "green",
388
- children: `${p().t("Ok")}`
388
+ children: `${m().t("Ok")}`
389
389
  }
390
390
  ),
391
391
  /* @__PURE__ */ e(
392
- ie,
392
+ oe,
393
393
  {
394
394
  actionName: "cancel",
395
395
  actionDescription: "Cancelar operação",
396
- leftSection: /* @__PURE__ */ e(Te, {}),
397
- onClick: S,
396
+ leftSection: /* @__PURE__ */ e(De, {}),
397
+ onClick: O,
398
398
  disabled: c && c.isBrowsing(),
399
399
  variant: v ?? R.variant,
400
400
  color: "red",
401
- children: `${p().t("Cancel")}`
401
+ children: `${m().t("Cancel")}`
402
402
  }
403
403
  )
404
- ] }) : /* @__PURE__ */ e(ge, { gap: "md", children: /* @__PURE__ */ e(
405
- ie,
404
+ ] }) : /* @__PURE__ */ e(ve, { gap: "md", children: /* @__PURE__ */ e(
405
+ oe,
406
406
  {
407
407
  actionName: "close",
408
408
  actionDescription: "Fechar janela",
409
- leftSection: /* @__PURE__ */ e(Te, {}),
410
- onClick: S,
409
+ leftSection: /* @__PURE__ */ e(De, {}),
410
+ onClick: O,
411
411
  variant: v ?? R.variant,
412
- children: `${p().t("Close")}`
412
+ children: `${m().t("Close")}`
413
413
  }
414
414
  ) })
415
415
  ] }) })
@@ -420,96 +420,96 @@ function dr({
420
420
  }
421
421
  );
422
422
  }
423
- function ur({
423
+ function hr({
424
424
  title: t,
425
425
  withOverlay: r = !0,
426
426
  overlayProps: a,
427
427
  children: d,
428
428
  withCloseButton: n = !0,
429
429
  closeButtonProps: o,
430
- opened: h,
431
- fullScreen: m,
430
+ opened: u,
431
+ fullScreen: f,
432
432
  centered: T,
433
433
  variant: v,
434
- closeOnEscape: O = !0,
434
+ closeOnEscape: te = !0,
435
435
  size: l,
436
436
  height: c,
437
- onlyOkButton: q = !1,
437
+ onlyOkButton: L = !1,
438
438
  onClose: A,
439
- onClickOk: D,
440
- onClickCancel: f,
439
+ onClickOk: V,
440
+ onClickCancel: h,
441
441
  userActions: B,
442
442
  // Props de segurança (opcionais)
443
- resourceName: W,
443
+ resourceName: _,
444
444
  resourceDescription: N,
445
445
  requiredPermissions: Y,
446
446
  fallbackComponent: b,
447
447
  securityOptions: x
448
448
  }) {
449
- const y = xe(), Z = Ye(), { colorScheme: K } = He();
450
- me({
449
+ const y = we(), Z = Ye(), { colorScheme: J } = He();
450
+ ge({
451
451
  autoRegisterActions: x?.autoRegisterActions ?? !0
452
452
  });
453
453
  const P = () => {
454
- D && D(), A();
455
- }, E = () => {
456
- f && f(), A();
454
+ V && V(), A();
455
+ }, I = () => {
456
+ h && h(), A();
457
457
  }, F = () => {
458
- ft.showWarning(p().t("Click on Ok or Cancel to close"));
458
+ mt.showWarning(m().t("Click on Ok or Cancel to close"));
459
459
  };
460
460
  return /* @__PURE__ */ e(
461
- ve,
461
+ Ae,
462
462
  {
463
- resourceName: W,
463
+ resourceName: _,
464
464
  resourceDescription: N,
465
465
  requiredPermissions: Y,
466
466
  fallbackComponent: b,
467
467
  onSecurityReady: x?.onSecurityReady,
468
468
  onAccessDenied: x?.onAccessDenied,
469
469
  children: /* @__PURE__ */ e(
470
- lt,
470
+ st,
471
471
  {
472
472
  title: t,
473
473
  withOverlay: r,
474
474
  overlayProps: a || {
475
- color: K === "dark" ? Z.colors.dark[7] : Z.colors.gray[6],
475
+ color: J === "dark" ? Z.colors.dark[7] : Z.colors.gray[6],
476
476
  opacity: 0.25
477
477
  },
478
478
  withCloseButton: n,
479
479
  closeButtonProps: o,
480
480
  onClose: F,
481
- opened: h,
482
- fullScreen: m,
481
+ opened: u,
482
+ fullScreen: f,
483
483
  centered: T,
484
- closeOnEscape: O,
484
+ closeOnEscape: te,
485
485
  size: l,
486
486
  children: /* @__PURE__ */ C(Oe, { height: c, children: [
487
- /* @__PURE__ */ e(et, { children: /* @__PURE__ */ e(gt, { children: d }) }),
488
- /* @__PURE__ */ e(tt, { size: "40px", children: /* @__PURE__ */ C(ce, { justify: "space-between", align: "center", children: [
489
- /* @__PURE__ */ e(ge, { children: B }),
490
- /* @__PURE__ */ C(ge, { gap: "md", children: [
487
+ /* @__PURE__ */ e(et, { children: /* @__PURE__ */ e(xt, { children: d }) }),
488
+ /* @__PURE__ */ e(tt, { size: "40px", children: /* @__PURE__ */ C(de, { justify: "space-between", align: "center", children: [
489
+ /* @__PURE__ */ e(ve, { children: B }),
490
+ /* @__PURE__ */ C(ve, { gap: "md", children: [
491
491
  /* @__PURE__ */ e(
492
- ie,
492
+ oe,
493
493
  {
494
494
  actionName: "save",
495
495
  actionDescription: `Salvar ${N || "registro"}`,
496
- leftSection: /* @__PURE__ */ e(ct, {}),
496
+ leftSection: /* @__PURE__ */ e(dt, {}),
497
497
  onClick: P,
498
498
  variant: v ?? y.variant,
499
499
  color: "green",
500
- children: `${p().t("Ok")}`
500
+ children: `${m().t("Ok")}`
501
501
  }
502
502
  ),
503
- q ? null : /* @__PURE__ */ e(
504
- ie,
503
+ L ? null : /* @__PURE__ */ e(
504
+ oe,
505
505
  {
506
506
  actionName: "cancel",
507
507
  actionDescription: "Cancelar operação",
508
- leftSection: /* @__PURE__ */ e(Te, {}),
509
- onClick: E,
508
+ leftSection: /* @__PURE__ */ e(De, {}),
509
+ onClick: I,
510
510
  variant: v ?? y.variant,
511
511
  color: "red",
512
- children: f ? `${p().t("Cancel")}` : `${p().t("Close")}`
512
+ children: h ? `${m().t("Cancel")}` : `${m().t("Close")}`
513
513
  }
514
514
  )
515
515
  ] })
@@ -537,19 +537,19 @@ function qt(t, r) {
537
537
  printTitle: d,
538
538
  dataSource: n,
539
539
  filterOptions: o,
540
- pageSize: h = 15,
541
- pageIndex: m = 0,
540
+ pageSize: u = 15,
541
+ pageIndex: f = 0,
542
542
  columns: T,
543
543
  filterFields: v,
544
- logoPrint: O,
544
+ logoPrint: te,
545
545
  userActions: l,
546
546
  userRowActions: c,
547
- customRenderRowActions: q,
547
+ customRenderRowActions: L,
548
548
  innerRef: A,
549
- isLoading: D = !1,
550
- isLoadingFilter: f = !1,
549
+ isLoading: V = !1,
550
+ isLoadingFilter: h = !1,
551
551
  isError: B = !1,
552
- enableTopToolbar: W = !0,
552
+ enableTopToolbar: _ = !0,
553
553
  enableTopToolbarActions: N = !0,
554
554
  error: Y = "",
555
555
  clearError: b = () => {
@@ -557,143 +557,145 @@ function qt(t, r) {
557
557
  filterType: x,
558
558
  width: y = "100%",
559
559
  height: Z = "100%",
560
- onSearchByFilter: K,
560
+ onSearchByFilter: J,
561
561
  getRowId: P,
562
- withBorder: E = !0,
562
+ withBorder: I = !0,
563
563
  filterPersistenceDelegator: F,
564
564
  variant: G,
565
565
  store: w,
566
566
  cellPadding: $,
567
567
  bottomToolbarMinHeight: R,
568
- enableRowSelection: re = !0,
569
- enableRowNumbers: Q = !0,
568
+ enableRowSelection: ie = !0,
569
+ enableRowNumbers: H = !0,
570
570
  enableRowActions: M = !0,
571
- positionActionsColumn: V = "first",
571
+ positionActionsColumn: S = "first",
572
572
  tableHeadCellPadding: U,
573
- renderDetailPanel: _,
574
- renderTopToolbar: J,
575
- toolbarAlignment: X = "right",
576
- toolbarLeftContent: I,
577
- onSelectedRowsChanged: ee,
578
- onCellDoubleClick: ue,
579
- paginationLabels: s,
573
+ renderDetailPanel: k,
574
+ renderTopToolbar: z,
575
+ toolbarAlignment: W = "right",
576
+ toolbarLeftContent: E,
577
+ onSelectedRowsChanged: re,
578
+ onCellDoubleClick: he,
579
+ onFilterModelChange: s,
580
+ paginationLabels: q,
580
581
  // Props de segurança (opcionais)
581
- resourceName: H,
582
- resourceDescription: S,
583
- requiredPermissions: oe,
584
- fallbackComponent: pe,
585
- securityOptions: j
586
- } = t, be = se(null), L = se(null);
582
+ resourceName: O,
583
+ resourceDescription: K,
584
+ requiredPermissions: xe,
585
+ fallbackComponent: Q,
586
+ securityOptions: fe
587
+ } = t, Ee = ae(null), D = ae(null);
587
588
  Ye();
588
- const { colorScheme: Ve } = He();
589
- me({
590
- autoRegisterActions: j?.autoRegisterActions ?? !0
589
+ const { colorScheme: it } = He();
590
+ ge({
591
+ autoRegisterActions: fe?.autoRegisterActions ?? !0
591
592
  });
592
- const we = De(
593
+ const ye = Se(
593
594
  "ArchbaseGridTemplate",
594
595
  n,
595
596
  void 0,
596
597
  void 0
597
598
  );
598
- It(r, () => ({
599
+ Tt(r, () => ({
599
600
  refreshData: () => {
600
- L.current && L.current.refreshData();
601
+ D.current && D.current.refreshData();
601
602
  },
602
- getSelectedRows: () => L.current ? L.current.getSelectedRows() : [],
603
+ getSelectedRows: () => D.current ? D.current.getSelectedRows() : [],
603
604
  clearSelection: () => {
604
- L.current && L.current.clearSelection();
605
+ D.current && D.current.clearSelection();
605
606
  },
606
607
  exportData: () => {
607
- L.current && L.current.exportData();
608
+ D.current && D.current.exportData();
608
609
  },
609
610
  printData: () => {
610
- L.current && L.current.printData();
611
+ D.current && D.current.printData();
611
612
  },
612
- getDataGridRef: () => L
613
- }), [L]);
614
- const [k, Ae] = te({
613
+ getDataGridRef: () => D,
614
+ getFilterModel: () => D.current ? D.current.getFilterModel() : { items: [], quickFilterValues: [] }
615
+ }), [D]);
616
+ const [j, Ce] = ne({
615
617
  activeFilterIndex: -1,
616
618
  currentFilter: void 0,
617
619
  expandedFilter: !1
618
620
  });
619
- ut(() => {
620
- const u = zt(o, w, F);
621
- Ae(u);
622
- }, [f]);
623
- const Ue = (u) => {
624
- if (q)
625
- return q(u);
621
+ ht(() => {
622
+ const p = zt(o, w, F);
623
+ Ce(p);
624
+ }, [h]);
625
+ const je = (p) => {
626
+ if (L)
627
+ return L(p);
626
628
  if (!c || !c.actions)
627
629
  return;
628
- const ne = c.actions;
630
+ const ee = c.actions;
629
631
  return /* @__PURE__ */ e(
630
- ne,
632
+ ee,
631
633
  {
632
- onEditRow: c.onEditRow ? (z) => c.onEditRow && c.onEditRow(z) : void 0,
633
- onRemoveRow: c.onRemoveRow ? (z) => c.onRemoveRow && c.onRemoveRow(z) : void 0,
634
- onViewRow: c.onViewRow ? (z) => c.onViewRow && c.onViewRow(z) : void 0,
635
- row: u,
636
- variant: G ?? de.variant
634
+ onEditRow: c.onEditRow ? (X) => c.onEditRow && c.onEditRow(X) : void 0,
635
+ onRemoveRow: c.onRemoveRow ? (X) => c.onRemoveRow && c.onRemoveRow(X) : void 0,
636
+ onViewRow: c.onViewRow ? (X) => c.onViewRow && c.onViewRow(X) : void 0,
637
+ row: p,
638
+ variant: G ?? ue.variant
637
639
  }
638
640
  );
639
- }, de = xe(), ye = se(null);
640
- Ie.useEffect(() => {
641
- A && A.current !== ye.current && A.current && ye.current && (A.current = ye.current);
641
+ }, ue = we(), Fe = ae(null), Le = be(() => E, [E]);
642
+ Ve.useEffect(() => {
643
+ A && A.current !== Fe.current && A.current && Fe.current && (A.current = Fe.current);
642
644
  }, [A]);
643
- const je = (u, ne) => {
644
- const z = { ...k, currentFilter: u, activeFilterIndex: ne };
645
- Ae(z), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, z);
646
- }, Le = (u) => {
647
- const ne = { ...k, expandedFilter: u };
648
- Ae(ne), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, ne);
649
- }, ke = (u, ne) => {
650
- const z = { ...k, currentFilter: u, activeFilterIndex: ne };
651
- Ae(z), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, z);
652
- }, ze = () => {
653
- if (k.currentFilter)
654
- if (K)
655
- K();
656
- else if (k.currentFilter.filter.filterType === "quick") {
657
- const u = n.getOptions();
658
- k.currentFilter.filter.quickFilterText && k.currentFilter.filter.quickFilterText !== "" ? (u.filter = JSON.stringify({
659
- search: k.currentFilter.filter.quickFilterText,
660
- fields: k.currentFilter.filter.quickFilterFieldsText
661
- }), u.sort = k.currentFilter.sort.quickFilterSort ? k.currentFilter.sort.quickFilterSort.split(",") : []) : (u.filter = void 0, u.sort = void 0), n.refreshData(u), we.isDataSourceV2 || we.v1State.forceUpdate();
645
+ const Me = (p, ee) => {
646
+ const X = { ...j, currentFilter: p, activeFilterIndex: ee };
647
+ Ce(X), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, X);
648
+ }, ke = (p) => {
649
+ const ee = { ...j, expandedFilter: p };
650
+ Ce(ee), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, ee);
651
+ }, ze = (p, ee) => {
652
+ const X = { ...j, currentFilter: p, activeFilterIndex: ee };
653
+ Ce(X), w && o && w?.setValue(`${o.viewName}_${o.componentName}`, X);
654
+ }, qe = () => {
655
+ if (j.currentFilter)
656
+ if (J)
657
+ J();
658
+ else if (j.currentFilter.filter.filterType === "quick") {
659
+ const p = n.getOptions();
660
+ j.currentFilter.filter.quickFilterText && j.currentFilter.filter.quickFilterText !== "" ? (p.filter = JSON.stringify({
661
+ search: j.currentFilter.filter.quickFilterText,
662
+ fields: j.currentFilter.filter.quickFilterFieldsText
663
+ }), p.sort = j.currentFilter.sort.quickFilterSort ? j.currentFilter.sort.quickFilterSort.split(",") : []) : (p.filter = void 0, p.sort = void 0), n.refreshData(p), ye.isDataSourceV2 || ye.v1State.forceUpdate();
662
664
  } else {
663
- const u = Ut(k.currentFilter);
664
- if (u && u.expressionNode) {
665
- const ne = Ft(u.expressionNode), z = n.getOptions();
666
- z.filter = ne, z.sort = u?.sortStrings, n.refreshData(z), we.isDataSourceV2 || we.v1State.forceUpdate();
665
+ const p = jt(j.currentFilter);
666
+ if (p && p.expressionNode) {
667
+ const ee = Rt(p.expressionNode), X = n.getOptions();
668
+ X.filter = ee, X.sort = p?.sortStrings, n.refreshData(X), ye.isDataSourceV2 || ye.v1State.forceUpdate();
667
669
  }
668
670
  }
669
671
  };
670
- let Re, Ee;
671
- const qe = (u) => {
672
- Re = u;
673
- }, Me = (u) => {
674
- Ee = u;
675
- }, i = () => {
676
- Ee && Ee();
677
- }, g = () => {
678
- Re && Re();
679
- }, le = () => x === "none" ? /* @__PURE__ */ e("div", {}) : x === "advanced" ? /* @__PURE__ */ e(
672
+ let Ie, Te;
673
+ const i = (p) => {
674
+ Ie = p;
675
+ }, g = (p) => {
676
+ Te = p;
677
+ }, le = () => {
678
+ Te && Te();
679
+ }, se = () => {
680
+ Ie && Ie();
681
+ }, _e = () => x === "none" ? /* @__PURE__ */ e("div", {}) : x === "advanced" ? /* @__PURE__ */ e(
680
682
  rt,
681
683
  {
682
684
  id: o?.componentName,
683
685
  viewName: o?.viewName,
684
686
  apiVersion: o?.apiVersion,
685
- ref: be,
686
- variant: G ?? de.variant,
687
- expandedFilter: k.expandedFilter,
687
+ ref: Ee,
688
+ variant: G ?? ue.variant,
689
+ expandedFilter: j.expandedFilter,
688
690
  persistenceDelegator: F,
689
- currentFilter: k.currentFilter,
690
- activeFilterIndex: k.activeFilterIndex,
691
- onSelectedFilter: ke,
692
- onFilterChanged: je,
693
- onSearchByFilter: ze,
694
- onToggleExpandedFilter: Le,
695
- onExport: i,
696
- onPrint: g,
691
+ currentFilter: j.currentFilter,
692
+ activeFilterIndex: j.activeFilterIndex,
693
+ onSelectedFilter: ze,
694
+ onFilterChanged: Me,
695
+ onSearchByFilter: qe,
696
+ onToggleExpandedFilter: ke,
697
+ onExport: le,
698
+ onPrint: se,
697
699
  showExportButton: !0,
698
700
  showPrintButton: !0,
699
701
  width: "560px",
@@ -702,127 +704,128 @@ function qt(t, r) {
702
704
  }
703
705
  ) : x === "normal" ? /* @__PURE__ */ e("div", {}) : /* @__PURE__ */ e("div", {});
704
706
  return /* @__PURE__ */ e(
705
- ve,
707
+ Ae,
706
708
  {
707
- resourceName: H,
708
- resourceDescription: S,
709
- requiredPermissions: oe,
710
- fallbackComponent: pe,
711
- onSecurityReady: j?.onSecurityReady,
712
- onAccessDenied: j?.onAccessDenied,
713
- children: /* @__PURE__ */ C(Je, { withBorder: E, ref: ye, style: { overflow: "none", height: "calc(100% - 4px)" }, children: [
709
+ resourceName: O,
710
+ resourceDescription: K,
711
+ requiredPermissions: xe,
712
+ fallbackComponent: Q,
713
+ onSecurityReady: fe?.onSecurityReady,
714
+ onAccessDenied: fe?.onAccessDenied,
715
+ children: /* @__PURE__ */ C(Je, { withBorder: I, ref: Fe, style: { height: "calc(100% - 4px)" }, children: [
714
716
  B ? /* @__PURE__ */ e(
715
- $e,
717
+ Ue,
716
718
  {
717
719
  autoClose: 2e4,
718
720
  withCloseButton: !0,
719
721
  withBorder: !0,
720
- icon: /* @__PURE__ */ e(Ge, { size: "1.4rem" }),
721
- title: p().t("archbase:WARNING"),
722
+ icon: /* @__PURE__ */ e($e, { size: "1.4rem" }),
723
+ title: m().t("archbase:WARNING"),
722
724
  titleColor: "rgb(250, 82, 82)",
723
- variant: G ?? de.variant,
725
+ variant: G ?? ue.variant,
724
726
  onClose: () => b && b(),
725
727
  children: /* @__PURE__ */ e("span", { children: Y })
726
728
  }
727
729
  ) : null,
728
730
  /* @__PURE__ */ C(
729
- St,
731
+ Bt,
730
732
  {
731
- gridRef: L,
733
+ gridRef: D,
732
734
  printTitle: d || a,
733
- logoPrint: O,
735
+ logoPrint: te,
734
736
  width: y,
735
737
  height: Z,
736
- withBorder: E,
738
+ withBorder: I,
737
739
  dataSource: n,
738
740
  enableColumnResizing: !0,
739
- enableRowNumbers: Q,
740
- enableRowSelection: re,
741
+ enableRowNumbers: H,
742
+ enableRowSelection: ie,
741
743
  enableRowActions: M,
742
- enableTopToolbar: W,
744
+ enableTopToolbar: _,
743
745
  enableTopToolbarActions: N,
744
746
  manualPagination: !0,
745
747
  manualSorting: !0,
746
- isLoading: D,
747
- pageSize: h,
748
- pageIndex: m,
748
+ isLoading: V,
749
+ pageSize: u,
750
+ pageIndex: f,
749
751
  allowColumnFilters: x !== "none",
750
752
  enableGlobalFilter: x !== "none",
751
753
  renderToolbarInternalActions: x == "none" ? () => /* @__PURE__ */ e("div", {}) : void 0,
752
754
  allowExportData: !0,
753
755
  allowPrintData: !0,
754
- onSelectedRowsChanged: ee,
755
- onCellDoubleClick: ue,
756
- renderRowActions: M ? Ue : void 0,
757
- positionActionsColumn: V,
758
- toolbarAlignment: X,
759
- toolbarLeftContent: I,
760
- renderToolbarActions: x === "advanced" || x === "none" ? le : void 0,
761
- paginationLabels: s,
756
+ onSelectedRowsChanged: re,
757
+ onCellDoubleClick: he,
758
+ onFilterModelChange: s,
759
+ renderRowActions: M ? je : void 0,
760
+ positionActionsColumn: S,
761
+ toolbarAlignment: W,
762
+ toolbarLeftContent: Le,
763
+ renderToolbarActions: x === "advanced" || x === "none" ? _e : void 0,
764
+ paginationLabels: q,
762
765
  cellPadding: $,
763
766
  bottomToolbarMinHeight: R,
764
767
  tableHeadCellPadding: U,
765
768
  getRowId: P,
766
- renderDetailPanel: _ ? ({ row: u }) => _({ row: u }) : void 0,
767
- renderTopToolbar: J,
768
- onExport: Me,
769
- onPrint: qe,
769
+ renderDetailPanel: k ? ({ row: p }) => k({ row: p }) : void 0,
770
+ renderTopToolbar: z,
771
+ onExport: g,
772
+ onPrint: i,
770
773
  variant: G,
771
774
  children: [
772
775
  T,
773
- l?.visible ? /* @__PURE__ */ e(Bt, { children: /* @__PURE__ */ C(Fe, { children: [
776
+ l?.visible ? /* @__PURE__ */ e(Nt, { children: /* @__PURE__ */ C(Re, { children: [
774
777
  /* @__PURE__ */ e("h3", { className: "only-print", children: d || a }),
775
- /* @__PURE__ */ e("div", { className: "no-print", children: /* @__PURE__ */ C(ce, { gap: "8px", rowGap: "8px", children: [
778
+ /* @__PURE__ */ e("div", { className: "no-print", children: /* @__PURE__ */ C(de, { gap: "8px", rowGap: "8px", children: [
776
779
  l.customUserActions && l.customUserActionsPosition === "left" ? l.customUserActions : null,
777
780
  l.onAddExecute ? /* @__PURE__ */ e(
778
- ie,
781
+ oe,
779
782
  {
780
783
  actionName: "add",
781
- actionDescription: `Adicionar novo ${S || "registro"}`,
784
+ actionDescription: `Adicionar novo ${K || "registro"}`,
782
785
  color: "green",
783
- variant: G ?? de.variant,
786
+ variant: G ?? ue.variant,
784
787
  leftSection: /* @__PURE__ */ e(We, {}),
785
788
  onClick: () => l && l.onAddExecute && l.onAddExecute(),
786
- children: l.labelAdd || p().t("archbase:New")
789
+ children: l.labelAdd || m().t("archbase:New")
787
790
  }
788
791
  ) : null,
789
792
  l.onEditExecute ? /* @__PURE__ */ e(
790
- ie,
793
+ oe,
791
794
  {
792
795
  actionName: "edit",
793
- actionDescription: `Editar ${S || "registro"}`,
796
+ actionDescription: `Editar ${K || "registro"}`,
794
797
  color: "blue",
795
798
  leftSection: /* @__PURE__ */ e(Ke, {}),
796
799
  disabled: !n.isBrowsing() || n.isEmpty(),
797
- variant: G ?? de.variant,
800
+ variant: G ?? ue.variant,
798
801
  onClick: () => l && l.onEditExecute && l.onEditExecute(),
799
- children: l.labelEdit || p().t("archbase:Edit")
802
+ children: l.labelEdit || m().t("archbase:Edit")
800
803
  }
801
804
  ) : null,
802
805
  l.onRemoveExecute ? /* @__PURE__ */ e(
803
- ie,
806
+ oe,
804
807
  {
805
808
  actionName: "delete",
806
- actionDescription: `Remover ${S || "registro"}`,
809
+ actionDescription: `Remover ${K || "registro"}`,
807
810
  color: "red",
808
811
  leftSection: /* @__PURE__ */ e(Qe, {}),
809
812
  disabled: !l?.allowRemove || !n.isBrowsing() || n.isEmpty(),
810
- variant: G ?? de.variant,
813
+ variant: G ?? ue.variant,
811
814
  onClick: () => l && l.onRemoveExecute && l.onRemoveExecute(),
812
- children: l.labelRemove || p().t("archbase:Remove")
815
+ children: l.labelRemove || m().t("archbase:Remove")
813
816
  }
814
817
  ) : null,
815
818
  l.onViewExecute ? /* @__PURE__ */ e(
816
- ie,
819
+ oe,
817
820
  {
818
821
  actionName: "view",
819
- actionDescription: `Visualizar ${S || "registro"}`,
822
+ actionDescription: `Visualizar ${K || "registro"}`,
820
823
  color: "gray.7",
821
824
  leftSection: /* @__PURE__ */ e(Xe, {}),
822
825
  disabled: !n.isBrowsing() || n.isEmpty(),
823
- variant: G ?? de.variant,
826
+ variant: G ?? ue.variant,
824
827
  onClick: () => l && l.onViewExecute && l.onViewExecute(),
825
- children: l.labelView || p().t("archbase:View")
828
+ children: l.labelView || m().t("archbase:View")
826
829
  }
827
830
  ) : null,
828
831
  l.customUserActions && l.customUserActionsPosition === "right" ? l.customUserActions : null
@@ -835,13 +838,13 @@ function qt(t, r) {
835
838
  }
836
839
  );
837
840
  }
838
- const hr = Et(qt);
839
- function Mt(t, r, a, d) {
841
+ const fr = It(qt);
842
+ function _t(t, r, a, d) {
840
843
  if (t && t.headerGridColumns) {
841
- const n = t.headerGridColumns.left ? t.headerGridColumns.left : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, o = t.headerGridColumns.middle ? t.headerGridColumns.middle : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, h = t.headerGridColumns.right ? t.headerGridColumns.right : { xs: "auto", sm: "auto", md: "auto", lg: "auto" };
842
- return /* @__PURE__ */ C(he, { m: 0, gutter: "xs", justify: "center", align: "center", grow: !0, children: [
844
+ const n = t.headerGridColumns.left ? t.headerGridColumns.left : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, o = t.headerGridColumns.middle ? t.headerGridColumns.middle : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, u = t.headerGridColumns.right ? t.headerGridColumns.right : { xs: "auto", sm: "auto", md: "auto", lg: "auto" };
845
+ return /* @__PURE__ */ C(me, { m: 0, gutter: "xs", justify: "center", align: "center", grow: !0, children: [
843
846
  /* @__PURE__ */ e(
844
- he.Col,
847
+ me.Col,
845
848
  {
846
849
  span: {
847
850
  xs: n.xs,
@@ -859,7 +862,7 @@ function Mt(t, r, a, d) {
859
862
  }
860
863
  ),
861
864
  /* @__PURE__ */ e(
862
- he.Col,
865
+ me.Col,
863
866
  {
864
867
  span: {
865
868
  xs: o.xs,
@@ -876,13 +879,13 @@ function Mt(t, r, a, d) {
876
879
  }
877
880
  ),
878
881
  /* @__PURE__ */ e(
879
- he.Col,
882
+ me.Col,
880
883
  {
881
884
  span: {
882
- xs: h.xs,
883
- sm: h.sm,
884
- md: h.md,
885
- lg: h.lg
885
+ xs: u.xs,
886
+ sm: u.sm,
887
+ md: u.md,
888
+ lg: u.lg
886
889
  },
887
890
  style: {
888
891
  border: d ? "1px dashed" : "",
@@ -895,15 +898,15 @@ function Mt(t, r, a, d) {
895
898
  )
896
899
  ] });
897
900
  } else {
898
- const n = t && t.headerFlexGrow ? t.headerFlexGrow : "even", o = t && t.headerFlexRightJustifyContent ? t.headerFlexRightJustifyContent : "flex-end", h = t && t.headerFlexLeftJustifyContent ? t.headerFlexLeftJustifyContent : "flex-start";
899
- return /* @__PURE__ */ C(ce, { justify: "space-between", children: [
901
+ const n = t && t.headerFlexGrow ? t.headerFlexGrow : "even", o = t && t.headerFlexRightJustifyContent ? t.headerFlexRightJustifyContent : "flex-end", u = t && t.headerFlexLeftJustifyContent ? t.headerFlexLeftJustifyContent : "flex-start";
902
+ return /* @__PURE__ */ C(de, { justify: "space-between", children: [
900
903
  /* @__PURE__ */ e(
901
- ce,
904
+ de,
902
905
  {
903
906
  w: n === "left" || n === "even" ? "100%" : void 0,
904
907
  maw: n === "left" || n === "even" ? void 0 : "100%",
905
908
  align: "center",
906
- justify: h,
909
+ justify: u,
907
910
  style: {
908
911
  border: d ? "1px dashed" : ""
909
912
  },
@@ -911,7 +914,7 @@ function Mt(t, r, a, d) {
911
914
  }
912
915
  ),
913
916
  /* @__PURE__ */ e(
914
- ce,
917
+ de,
915
918
  {
916
919
  w: n === "right" || n === "even" ? "100%" : void 0,
917
920
  maw: n === "right" || n === "even" ? void 0 : "100%",
@@ -926,12 +929,12 @@ function Mt(t, r, a, d) {
926
929
  ] });
927
930
  }
928
931
  }
929
- function _t(t, r, a, d) {
932
+ function Jt(t, r, a, d) {
930
933
  if (t && t.footerGridColumns) {
931
- const n = t.footerGridColumns.left ? t.footerGridColumns.left : { xs: "content", sm: "content", md: "content", lg: "content" }, o = t.footerGridColumns.middle ? t.footerGridColumns.middle : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, h = t.footerGridColumns.right ? t.footerGridColumns.right : { xs: "content", sm: "content", md: "content", lg: "content" };
932
- return /* @__PURE__ */ C(he, { m: 0, gutter: "xs", justify: "center", align: "center", grow: !0, children: [
934
+ const n = t.footerGridColumns.left ? t.footerGridColumns.left : { xs: "content", sm: "content", md: "content", lg: "content" }, o = t.footerGridColumns.middle ? t.footerGridColumns.middle : { xs: "auto", sm: "auto", md: "auto", lg: "auto" }, u = t.footerGridColumns.right ? t.footerGridColumns.right : { xs: "content", sm: "content", md: "content", lg: "content" };
935
+ return /* @__PURE__ */ C(me, { m: 0, gutter: "xs", justify: "center", align: "center", grow: !0, children: [
933
936
  /* @__PURE__ */ e(
934
- he.Col,
937
+ me.Col,
935
938
  {
936
939
  span: {
937
940
  xs: n.xs,
@@ -949,7 +952,7 @@ function _t(t, r, a, d) {
949
952
  }
950
953
  ),
951
954
  /* @__PURE__ */ e(
952
- he.Col,
955
+ me.Col,
953
956
  {
954
957
  span: {
955
958
  xs: o.xs,
@@ -966,13 +969,13 @@ function _t(t, r, a, d) {
966
969
  }
967
970
  ),
968
971
  /* @__PURE__ */ e(
969
- he.Col,
972
+ me.Col,
970
973
  {
971
974
  span: {
972
- xs: h.xs,
973
- sm: h.sm,
974
- md: h.md,
975
- lg: h.lg
975
+ xs: u.xs,
976
+ sm: u.sm,
977
+ md: u.md,
978
+ lg: u.lg
976
979
  },
977
980
  style: {
978
981
  border: d ? "1px dashed" : "",
@@ -985,15 +988,15 @@ function _t(t, r, a, d) {
985
988
  )
986
989
  ] });
987
990
  } else {
988
- const n = t && t.footerFlexGrow ? t.footerFlexGrow : "even", o = t && t.footerFlexRightJustifyContent ? t.footerFlexRightJustifyContent : "flex-end", h = t && t.footerFlexLeftJustifyContent ? t.footerFlexLeftJustifyContent : "flex-start";
989
- return /* @__PURE__ */ C(ce, { justify: "space-between", children: [
991
+ const n = t && t.footerFlexGrow ? t.footerFlexGrow : "even", o = t && t.footerFlexRightJustifyContent ? t.footerFlexRightJustifyContent : "flex-end", u = t && t.footerFlexLeftJustifyContent ? t.footerFlexLeftJustifyContent : "flex-start";
992
+ return /* @__PURE__ */ C(de, { justify: "space-between", children: [
990
993
  /* @__PURE__ */ e(
991
- ce,
994
+ de,
992
995
  {
993
996
  w: n === "left" || n === "even" ? "100%" : void 0,
994
997
  maw: n === "left" || n === "even" ? void 0 : "100%",
995
998
  align: "center",
996
- justify: h,
999
+ justify: u,
997
1000
  style: {
998
1001
  border: d ? "1px dashed" : "",
999
1002
  height: "auto",
@@ -1003,7 +1006,7 @@ function _t(t, r, a, d) {
1003
1006
  }
1004
1007
  ),
1005
1008
  /* @__PURE__ */ e(
1006
- ce,
1009
+ de,
1007
1010
  {
1008
1011
  w: n === "right" || n === "even" ? "100%" : void 0,
1009
1012
  maw: n === "right" || n === "even" ? void 0 : "100%",
@@ -1020,26 +1023,26 @@ function _t(t, r, a, d) {
1020
1023
  ] });
1021
1024
  }
1022
1025
  }
1023
- function xt({
1026
+ function vt({
1024
1027
  title: t,
1025
1028
  innerRef: r,
1026
1029
  isError: a = !1,
1027
1030
  error: d = "",
1028
1031
  clearError: n,
1029
1032
  width: o = "100%",
1030
- height: h = "100%",
1031
- withBorder: m = !0,
1033
+ height: u = "100%",
1034
+ withBorder: f = !0,
1032
1035
  children: T,
1033
1036
  radius: v,
1034
- debug: O,
1037
+ debug: te,
1035
1038
  defaultDebug: l,
1036
1039
  headerLeft: c,
1037
- headerMiddle: q,
1040
+ headerMiddle: L,
1038
1041
  headerRight: A,
1039
- footerLeft: D,
1040
- footerMiddle: f,
1042
+ footerLeft: V,
1043
+ footerMiddle: h,
1041
1044
  footerRight: B,
1042
- variant: W,
1045
+ variant: _,
1043
1046
  options: N = {},
1044
1047
  style: Y,
1045
1048
  debugOptions: b = {
@@ -1051,69 +1054,69 @@ function xt({
1051
1054
  resourceName: x,
1052
1055
  resourceDescription: y,
1053
1056
  requiredPermissions: Z,
1054
- fallbackComponent: K,
1057
+ fallbackComponent: J,
1055
1058
  securityOptions: P
1056
1059
  }) {
1057
- const [E, F] = wt({
1058
- value: O,
1060
+ const [I, F] = At({
1061
+ value: te,
1059
1062
  defaultValue: l,
1060
1063
  finalValue: !1
1061
1064
  });
1062
- At([[b && b.debugLayoutHotKey, () => F(!E)]]);
1063
- const G = xe(), { t: w } = Rt();
1064
- me({
1065
+ yt([[b && b.debugLayoutHotKey, () => F(!I)]]);
1066
+ const G = we(), { t: w } = Et();
1067
+ ge({
1065
1068
  autoRegisterActions: P?.autoRegisterActions ?? !0
1066
1069
  });
1067
- const $ = se(null), R = r || $, re = se(null), Q = se(null), M = Ne(re), V = Ne(Q), U = Ne(R), _ = Ce(() => ({
1068
- height: U.height - M.height - V.height - Number(vt("0.625rem")),
1069
- width: U.width - M.width - V.width
1070
- }), [U.height, U.width, M.height, M.width, V.height, V.width]), J = se(l);
1071
- ut(() => {
1072
- l !== J.current && (F(l), J.current = l);
1070
+ const $ = ae(null), R = r || $, ie = ae(null), H = ae(null), M = Pe(ie), S = Pe(H), U = Pe(R), k = be(() => ({
1071
+ height: U.height - M.height - S.height - Number(bt("0.625rem")),
1072
+ width: U.width - M.width - S.width
1073
+ }), [U.height, U.width, M.height, M.width, S.height, S.width]), z = ae(l);
1074
+ ht(() => {
1075
+ l !== z.current && (F(l), z.current = l);
1073
1076
  }, [l, F]);
1074
- const X = /* @__PURE__ */ C(Fe, { children: [
1077
+ const W = /* @__PURE__ */ C(Re, { children: [
1075
1078
  /* @__PURE__ */ e(
1076
1079
  Je,
1077
1080
  {
1078
1081
  ref: R,
1079
- withBorder: m,
1082
+ withBorder: f,
1080
1083
  radius: v,
1081
- style: { width: o, height: h, padding: 4, ...Y },
1084
+ style: { width: o, height: u, padding: 4, ...Y },
1082
1085
  children: /* @__PURE__ */ C(Oe, { height: "100%", children: [
1083
- /* @__PURE__ */ e(pt, { size: M.height, children: /* @__PURE__ */ e("div", { ref: re, children: Mt(N, c, A, E) }) }),
1086
+ /* @__PURE__ */ e(gt, { size: M.height, children: /* @__PURE__ */ e("div", { ref: ie, children: _t(N, c, A, I) }) }),
1084
1087
  /* @__PURE__ */ e(et, { children: /* @__PURE__ */ e(
1085
- it,
1088
+ ot,
1086
1089
  {
1087
- h: _.height,
1090
+ h: k.height,
1088
1091
  style: {
1089
- border: E ? "1px dashed" : "",
1092
+ border: I ? "1px dashed" : "",
1090
1093
  padding: "calc(0.625rem / 2)"
1091
1094
  },
1092
- children: T ? /* @__PURE__ */ C(Tt, { children: [
1095
+ children: T ? /* @__PURE__ */ C(Vt, { children: [
1093
1096
  a && /* @__PURE__ */ e(
1094
- $e,
1097
+ Ue,
1095
1098
  {
1096
1099
  autoClose: 2e4,
1097
1100
  withCloseButton: !0,
1098
1101
  withBorder: !0,
1099
- icon: /* @__PURE__ */ e(Ge, { size: "1.4rem" }),
1102
+ icon: /* @__PURE__ */ e($e, { size: "1.4rem" }),
1100
1103
  title: `${w("WARNING")}`,
1101
1104
  titleColor: "rgb(250, 82, 82)",
1102
- variant: W ?? G.variant,
1105
+ variant: _ ?? G.variant,
1103
1106
  onClose: () => n && n(),
1104
1107
  children: /* @__PURE__ */ e("span", { children: d })
1105
1108
  }
1106
1109
  ),
1107
1110
  T
1108
- ] }) : E && /* @__PURE__ */ e(ce, { h: _.height + 80, justify: "center", align: "center", wrap: "wrap", children: /* @__PURE__ */ e(bt, { size: "lg", children: "INSIRA O CONTEÚDO DO PAINEL AQUI." }) })
1111
+ ] }) : I && /* @__PURE__ */ e(de, { h: k.height + 80, justify: "center", align: "center", wrap: "wrap", children: /* @__PURE__ */ e(wt, { size: "lg", children: "INSIRA O CONTEÚDO DO PAINEL AQUI." }) })
1109
1112
  }
1110
1113
  ) }),
1111
- /* @__PURE__ */ e(tt, { size: V.height, children: /* @__PURE__ */ e("div", { ref: Q, children: _t(N, D, B, E) }) })
1114
+ /* @__PURE__ */ e(tt, { size: S.height, children: /* @__PURE__ */ e("div", { ref: H, children: Jt(N, V, B, I) }) })
1112
1115
  ] })
1113
1116
  }
1114
1117
  ),
1115
1118
  /* @__PURE__ */ e(
1116
- Nt,
1119
+ Pt,
1117
1120
  {
1118
1121
  debugObjectInspectorHotKey: b && b.debugObjectInspectorHotKey,
1119
1122
  objectsToInspect: b && b.objectsToInspect
@@ -1121,19 +1124,19 @@ function xt({
1121
1124
  )
1122
1125
  ] });
1123
1126
  return /* @__PURE__ */ e(
1124
- ve,
1127
+ Ae,
1125
1128
  {
1126
1129
  resourceName: x,
1127
1130
  resourceDescription: y,
1128
1131
  requiredPermissions: Z,
1129
- fallbackComponent: K,
1132
+ fallbackComponent: J,
1130
1133
  onSecurityReady: P?.onSecurityReady,
1131
1134
  onAccessDenied: P?.onAccessDenied,
1132
- children: X
1135
+ children: W
1133
1136
  }
1134
1137
  );
1135
1138
  }
1136
- const Jt = {
1139
+ const Ht = {
1137
1140
  visible: !0,
1138
1141
  allowAdd: !0,
1139
1142
  allowEdit: !0,
@@ -1141,10 +1144,10 @@ const Jt = {
1141
1144
  allowRemove: !0,
1142
1145
  positionCustomUserActions: "after"
1143
1146
  };
1144
- function Ht(t, r, a, d, n, o) {
1147
+ function Wt(t, r, a, d, n, o) {
1145
1148
  console.log(`Render de "${t}" na fase "${r}": ${a}ms`);
1146
1149
  }
1147
- function fr({
1150
+ function mr({
1148
1151
  title: t,
1149
1152
  dataSource: r,
1150
1153
  // dataSourceEdition,
@@ -1154,222 +1157,222 @@ function fr({
1154
1157
  filterFields: n,
1155
1158
  innerRef: o,
1156
1159
  //isLoading = false,
1157
- debug: h = !1,
1158
- filterType: m = "normal",
1160
+ debug: u = !1,
1161
+ filterType: f = "normal",
1159
1162
  isError: T = !1,
1160
1163
  error: v = "",
1161
- clearError: O = () => {
1164
+ clearError: te = () => {
1162
1165
  },
1163
1166
  width: l = "100%",
1164
1167
  height: c = "100%",
1165
- withBorder: q = !0,
1168
+ withBorder: L = !0,
1166
1169
  filterPersistenceDelegator: A,
1167
- withPagination: D = !0,
1168
- radius: f,
1170
+ withPagination: V = !0,
1171
+ radius: h,
1169
1172
  userActions: B,
1170
- columnsCountBreakPoints: W,
1173
+ columnsCountBreakPoints: _,
1171
1174
  columnsCount: N,
1172
1175
  gutter: Y,
1173
1176
  component: b,
1174
1177
  activeIndex: x,
1175
1178
  activeBackgroundColor: y,
1176
1179
  activeColor: Z,
1177
- onItemEnter: K,
1180
+ onItemEnter: J,
1178
1181
  onItemLeave: P,
1179
- style: E,
1182
+ style: I,
1180
1183
  actionsButtonsOptions: F,
1181
1184
  spaceOptions: G,
1182
1185
  variant: w,
1183
- id: $ = Lt("masonry"),
1186
+ id: $ = Mt("masonry"),
1184
1187
  debugOptions: R,
1185
1188
  // Props de segurança (opcionais)
1186
- resourceName: re,
1187
- resourceDescription: Q,
1189
+ resourceName: ie,
1190
+ resourceDescription: H,
1188
1191
  requiredPermissions: M,
1189
- fallbackComponent: V,
1192
+ fallbackComponent: S,
1190
1193
  securityOptions: U
1191
1194
  }) {
1192
- const _ = xe(), J = me({
1195
+ const k = we(), z = ge({
1193
1196
  autoRegisterActions: U?.autoRegisterActions ?? !0
1194
- }), [X] = te($), I = o || se(null), ee = se(null), [ue, s] = te(r.getCurrentPage()), [H, S] = te(
1197
+ }), [W] = ne($), E = o || ae(null), re = ae(null), [he, s] = ne(r.getCurrentPage()), [q, O] = ne(
1195
1198
  x || (r && r.getTotalRecords() > 0 ? 0 : -1)
1196
1199
  );
1197
- Ne(I);
1198
- const [oe, pe] = te({
1200
+ Pe(E);
1201
+ const [K, xe] = ne({
1199
1202
  activeFilterIndex: -1,
1200
1203
  expandedFilter: !1
1201
- }), [j, be] = te(0), {
1202
- isDataSourceV2: L,
1203
- v1State: { forceUpdate: Ve }
1204
- } = De(
1204
+ }), [Q, fe] = ne(0), {
1205
+ isDataSourceV2: Ee,
1206
+ v1State: { forceUpdate: D }
1207
+ } = Se(
1205
1208
  "ArchbaseMasonryTemplate",
1206
1209
  r
1207
1210
  );
1208
1211
  Ze({
1209
1212
  dataSource: r,
1210
1213
  listener: (i) => {
1211
- (i.type === fe.afterRemove || i.type === fe.refreshData) && (be((g) => g + 1), L || Ve());
1214
+ (i.type === pe.afterRemove || i.type === pe.refreshData) && (fe((g) => g + 1), Ee || D());
1212
1215
  }
1213
1216
  });
1214
- const we = Ce(() => {
1215
- const i = { ...Jt, ...B }, g = [], le = (u) => J.isAvailable ? (J.registerAction(), J.hasPermission()) : !0;
1217
+ const it = be(() => {
1218
+ const i = { ...Ht, ...B }, g = [], le = (se) => z.isAvailable ? (z.registerAction(), z.hasPermission()) : !0;
1216
1219
  return i.allowAdd && i.onAddExecute && le() && g.push({
1217
1220
  id: "actAdd",
1218
1221
  icon: /* @__PURE__ */ e(We, {}),
1219
1222
  color: "green",
1220
- label: i.labelAdd ? i.labelAdd : p().t("archbase:New"),
1223
+ label: i.labelAdd ? i.labelAdd : m().t("archbase:New"),
1221
1224
  executeAction: () => {
1222
1225
  i && i.onAddExecute && i.onAddExecute();
1223
1226
  },
1224
1227
  enabled: !0,
1225
- hint: `${p().t("archbase:Clique para criar um novo registro")}`
1228
+ hint: `${m().t("archbase:Clique para criar um novo registro")}`
1226
1229
  }), i.allowEdit && i.onEditExecute && le() && g.push({
1227
1230
  id: "actEdit",
1228
1231
  icon: /* @__PURE__ */ e(Ke, {}),
1229
1232
  color: "blue",
1230
- label: i.labelEdit ? i.labelEdit : p().t("archbase:Edit"),
1233
+ label: i.labelEdit ? i.labelEdit : m().t("archbase:Edit"),
1231
1234
  executeAction: () => {
1232
1235
  i && i.onEditExecute && i.onEditExecute();
1233
1236
  },
1234
1237
  enabled: !r.isEmpty() && r.isBrowsing(),
1235
- hint: `${p().t("archbase:Clique para editar o registro")}`
1238
+ hint: `${m().t("archbase:Clique para editar o registro")}`
1236
1239
  }), i.allowRemove && i.onRemoveExecute && le() && g.push({
1237
1240
  id: "actRemove",
1238
1241
  icon: /* @__PURE__ */ e(Qe, {}),
1239
1242
  color: "red",
1240
- label: i.labelRemove ? i.labelRemove : p().t("archbase:Remove"),
1243
+ label: i.labelRemove ? i.labelRemove : m().t("archbase:Remove"),
1241
1244
  executeAction: () => {
1242
1245
  i && i.onRemoveExecute && i.onRemoveExecute();
1243
1246
  },
1244
1247
  enabled: !r.isEmpty() && r.isBrowsing(),
1245
- hint: `${p().t("archbase:Clique para remover o registro")}`
1248
+ hint: `${m().t("archbase:Clique para remover o registro")}`
1246
1249
  }), i.allowView && i.onViewExecute && le() && g.push({
1247
1250
  id: "actView",
1248
1251
  icon: /* @__PURE__ */ e(Xe, {}),
1249
- label: i.labelView ? i.labelView : p().t("archbase:View"),
1252
+ label: i.labelView ? i.labelView : m().t("archbase:View"),
1250
1253
  executeAction: () => {
1251
1254
  i && i.onViewExecute && i.onViewExecute();
1252
1255
  },
1253
1256
  enabled: !r.isEmpty() && r.isBrowsing(),
1254
- hint: `${p().t("archbase:Clique para visualizar o registro")}`
1257
+ hint: `${m().t("archbase:Clique para visualizar o registro")}`
1255
1258
  }), i.customUserActions && i.positionCustomUserActions === "before" ? [...i.customUserActions, ...g] : i.customUserActions && i.positionCustomUserActions === "after" ? [...g, ...i.customUserActions] : g;
1256
- }, [B, r, J]), k = Ce(() => {
1259
+ }, [B, r, z]), ye = be(() => {
1257
1260
  if (b) {
1258
1261
  const i = b.type;
1259
1262
  let g = {};
1260
- return b.props && (g = b.props), r.browseRecords().map((le, u) => {
1261
- const ne = `${X}_${u}`, z = `${X}_${u}`;
1262
- let _e = le.active === void 0 ? !1 : le.active;
1263
- return H >= 0 && (_e = !1, H === u && (_e = !0)), /* @__PURE__ */ e(
1263
+ return b.props && (g = b.props), r.browseRecords().map((le, se) => {
1264
+ const _e = `${W}_${se}`, p = `${W}_${se}`;
1265
+ let ee = le.active === void 0 ? !1 : le.active;
1266
+ return q >= 0 && (ee = !1, q === se && (ee = !0)), /* @__PURE__ */ e(
1264
1267
  i,
1265
1268
  {
1266
- id: z,
1267
- active: _e,
1268
- index: u,
1269
+ id: p,
1270
+ active: ee,
1271
+ index: se,
1269
1272
  dataSource: r,
1270
1273
  recordData: le,
1271
1274
  disabled: le.disabled,
1272
1275
  ...g
1273
1276
  },
1274
- ne
1277
+ _e
1275
1278
  );
1276
1279
  });
1277
1280
  }
1278
1281
  return [];
1279
- }, [H, b, X, r, j]), Ae = (i, g) => {
1280
- pe({ ...oe, currentFilter: i, activeFilterIndex: g });
1281
- }, Ue = (i) => {
1282
- pe({ ...oe, expandedFilter: i });
1283
- }, de = (i, g) => {
1284
- pe({ ...oe, currentFilter: i, activeFilterIndex: g });
1285
- }, ye = () => {
1282
+ }, [q, b, W, r, Q]), j = (i, g) => {
1283
+ xe({ ...K, currentFilter: i, activeFilterIndex: g });
1284
+ }, Ce = (i) => {
1285
+ xe({ ...K, expandedFilter: i });
1286
1286
  }, je = (i, g) => {
1287
- S(i), r && r.gotoRecordByData(g);
1287
+ xe({ ...K, currentFilter: i, activeFilterIndex: g });
1288
+ }, ue = () => {
1289
+ }, Fe = (i, g) => {
1290
+ O(i), r && r.gotoRecordByData(g);
1288
1291
  }, Le = (i) => {
1289
1292
  if (r) {
1290
1293
  const g = r.getOptions();
1291
- g.filter = i, g.currentPage = ue, r.refreshData(g), L || Ve();
1294
+ g.filter = i, g.currentPage = he, r.refreshData(g), Ee || D();
1292
1295
  }
1293
- }, ke = (i) => {
1296
+ }, Me = (i) => {
1294
1297
  if (r) {
1295
1298
  const g = r.getOptions();
1296
- g.currentPage = i, r.refreshData(g), L || Ve();
1299
+ g.currentPage = i, r.refreshData(g), Ee || D();
1297
1300
  }
1298
- }, ze = () => m === "normal" && d ? /* @__PURE__ */ e(
1299
- jt,
1301
+ }, ke = () => f === "normal" && d ? /* @__PURE__ */ e(
1302
+ Lt,
1300
1303
  {
1301
1304
  searchableFields: d,
1302
1305
  onFilter: Le,
1303
1306
  minFilterValueLength: 1
1304
1307
  }
1305
- ) : m === "advanced" ? /* @__PURE__ */ e(Dt, { id: `profile_${a.componentName}`, onRender: Ht, children: /* @__PURE__ */ e(
1308
+ ) : f === "advanced" ? /* @__PURE__ */ e(Dt, { id: `profile_${a.componentName}`, onRender: Wt, children: /* @__PURE__ */ e(
1306
1309
  rt,
1307
1310
  {
1308
1311
  id: a.componentName,
1309
1312
  viewName: a.viewName,
1310
1313
  apiVersion: a.apiVersion,
1311
- ref: ee,
1312
- variant: w || _.variant,
1313
- expandedFilter: oe.expandedFilter,
1314
+ ref: re,
1315
+ variant: w || k.variant,
1316
+ expandedFilter: K.expandedFilter,
1314
1317
  persistenceDelegator: A,
1315
- currentFilter: oe.currentFilter,
1316
- activeFilterIndex: oe.activeFilterIndex,
1317
- onSelectedFilter: de,
1318
- onFilterChanged: Ae,
1319
- onSearchByFilter: ye,
1320
- onToggleExpandedFilter: Ue,
1318
+ currentFilter: K.currentFilter,
1319
+ activeFilterIndex: K.activeFilterIndex,
1320
+ onSelectedFilter: je,
1321
+ onFilterChanged: j,
1322
+ onSearchByFilter: ue,
1323
+ onToggleExpandedFilter: Ce,
1321
1324
  width: "660px",
1322
1325
  height: "170px",
1323
1326
  children: n
1324
1327
  }
1325
- ) }) : /* @__PURE__ */ e(Fe, {}), Re = {
1328
+ ) }) : /* @__PURE__ */ e(Re, {}), ze = {
1326
1329
  menuButtonColor: "blue.5",
1327
1330
  menuPosition: "left"
1328
- }, Ee = {
1331
+ }, qe = {
1329
1332
  headerFlexGrow: "left",
1330
1333
  footerGridColumns: {}
1331
- }, qe = { ...Re, ...F }, Me = { ...Ee, ...G };
1334
+ }, Ie = { ...ze, ...F }, Te = { ...qe, ...G };
1332
1335
  return /* @__PURE__ */ e(
1333
- ve,
1336
+ Ae,
1334
1337
  {
1335
- resourceName: re,
1336
- resourceDescription: Q,
1338
+ resourceName: ie,
1339
+ resourceDescription: H,
1337
1340
  requiredPermissions: M,
1338
- fallbackComponent: V,
1341
+ fallbackComponent: S,
1339
1342
  onSecurityReady: U?.onSecurityReady,
1340
1343
  onAccessDenied: U?.onAccessDenied,
1341
1344
  children: /* @__PURE__ */ e(
1342
- xt,
1345
+ vt,
1343
1346
  {
1344
- innerRef: I,
1347
+ innerRef: E,
1345
1348
  width: l,
1346
1349
  height: c,
1347
- radius: f,
1348
- withBorder: q,
1350
+ radius: h,
1351
+ withBorder: L,
1349
1352
  isError: T,
1350
1353
  error: v,
1351
- clearError: O,
1354
+ clearError: te,
1352
1355
  title: t,
1353
- defaultDebug: h,
1356
+ defaultDebug: u,
1354
1357
  debugOptions: R,
1355
- style: E,
1356
- options: Me,
1357
- headerLeft: /* @__PURE__ */ e(mt, { actions: we, options: qe }),
1358
- headerRight: ze(),
1359
- footerRight: D ? /* @__PURE__ */ e(st, { total: r.getTotalPages(), onChange: ke }) : void 0,
1358
+ style: I,
1359
+ options: Te,
1360
+ headerLeft: /* @__PURE__ */ e(pt, { actions: it, options: Ie }),
1361
+ headerRight: ke(),
1362
+ footerRight: V ? /* @__PURE__ */ e(at, { total: r.getTotalPages(), onChange: Me }) : void 0,
1360
1363
  children: /* @__PURE__ */ e(
1361
- Pt,
1364
+ Gt,
1362
1365
  {
1363
1366
  value: {
1364
1367
  dataSource: r,
1365
1368
  ownerId: $,
1366
- handleSelectItem: je,
1369
+ handleSelectItem: Fe,
1367
1370
  activeBackgroundColor: y,
1368
1371
  activeColor: Z,
1369
- onItemEnter: K,
1372
+ onItemEnter: J,
1370
1373
  onItemLeave: P
1371
1374
  },
1372
- children: /* @__PURE__ */ e(Gt, { columnsCountBreakPoints: W, children: /* @__PURE__ */ e($t, { gutter: Y, columnsCount: N, children: k }) })
1375
+ children: /* @__PURE__ */ e($t, { columnsCountBreakPoints: _, children: /* @__PURE__ */ e(Ut, { gutter: Y, columnsCount: N, children: ye }) })
1373
1376
  }
1374
1377
  )
1375
1378
  }
@@ -1377,7 +1380,7 @@ function fr({
1377
1380
  }
1378
1381
  );
1379
1382
  }
1380
- const Wt = {
1383
+ const Kt = {
1381
1384
  visible: !0,
1382
1385
  allowAdd: !0,
1383
1386
  allowEdit: !0,
@@ -1385,7 +1388,7 @@ const Wt = {
1385
1388
  allowRemove: !0,
1386
1389
  positionCustomUserActions: "after"
1387
1390
  };
1388
- function mr({
1391
+ function pr({
1389
1392
  title: t,
1390
1393
  dataSource: r,
1391
1394
  // dataSourceEdition,
@@ -1395,20 +1398,20 @@ function mr({
1395
1398
  innerRef: n,
1396
1399
  //isLoading = false,
1397
1400
  isError: o = !1,
1398
- error: h = "",
1399
- clearError: m = () => {
1401
+ error: u = "",
1402
+ clearError: f = () => {
1400
1403
  },
1401
1404
  width: T = "100%",
1402
1405
  height: v = "100%",
1403
- withBorder: O = !0,
1406
+ withBorder: te = !0,
1404
1407
  filterPersistenceDelegator: l,
1405
1408
  withPagination: c = !0,
1406
- children: q,
1409
+ children: L,
1407
1410
  radius: A,
1408
- userActions: D,
1409
- debug: f = !1,
1411
+ userActions: V,
1412
+ debug: h = !1,
1410
1413
  variant: B,
1411
- actionsButtonsOptions: W,
1414
+ actionsButtonsOptions: _,
1412
1415
  spaceOptions: N,
1413
1416
  style: Y,
1414
1417
  debugOptions: b,
@@ -1416,104 +1419,104 @@ function mr({
1416
1419
  resourceName: x,
1417
1420
  resourceDescription: y,
1418
1421
  requiredPermissions: Z,
1419
- fallbackComponent: K,
1422
+ fallbackComponent: J,
1420
1423
  securityOptions: P
1421
1424
  }) {
1422
- const E = xe(), F = me({
1425
+ const I = we(), F = ge({
1423
1426
  autoRegisterActions: P?.autoRegisterActions ?? !0
1424
- }), G = n || se(null), w = se(null), [$, R] = te({
1427
+ }), G = n || ae(null), w = ae(null), [$, R] = ne({
1425
1428
  activeFilterIndex: -1,
1426
1429
  expandedFilter: !1
1427
1430
  }), {
1428
- isDataSourceV2: re,
1429
- v1State: { forceUpdate: Q }
1430
- } = De(
1431
+ isDataSourceV2: ie,
1432
+ v1State: { forceUpdate: H }
1433
+ } = Se(
1431
1434
  "ArchbasePanelTemplate",
1432
1435
  r
1433
- ), M = Ce(() => {
1434
- const s = { ...Wt, ...D }, H = (oe) => F.isAvailable ? (F.registerAction(), F.hasPermission()) : !0, S = [];
1435
- return s.allowAdd && s.onAddExecute && H() && S.push({
1436
+ ), M = be(() => {
1437
+ const s = { ...Kt, ...V }, q = (K) => F.isAvailable ? (F.registerAction(), F.hasPermission()) : !0, O = [];
1438
+ return s.allowAdd && s.onAddExecute && q() && O.push({
1436
1439
  id: "1",
1437
1440
  icon: /* @__PURE__ */ e(We, {}),
1438
1441
  color: "green",
1439
- label: s.labelAdd ? s.labelAdd : p().t("archbase:New"),
1442
+ label: s.labelAdd ? s.labelAdd : m().t("archbase:New"),
1440
1443
  executeAction: () => {
1441
1444
  s && s.onAddExecute && s.onAddExecute();
1442
1445
  },
1443
1446
  enabled: !0,
1444
1447
  hint: "Clique para criar."
1445
- }), s.allowEdit && s.onEditExecute && H() && S.push({
1448
+ }), s.allowEdit && s.onEditExecute && q() && O.push({
1446
1449
  id: "2",
1447
1450
  icon: /* @__PURE__ */ e(Ke, {}),
1448
1451
  color: "blue",
1449
- label: s.labelEdit ? s.labelEdit : p().t("archbase:Edit"),
1452
+ label: s.labelEdit ? s.labelEdit : m().t("archbase:Edit"),
1450
1453
  executeAction: () => {
1451
1454
  s && s.onEditExecute && s.onEditExecute();
1452
1455
  },
1453
1456
  enabled: !r.isEmpty() && r.isBrowsing(),
1454
1457
  hint: "Clique para editar."
1455
- }), s.allowRemove && s.onRemoveExecute && H() && S.push({
1458
+ }), s.allowRemove && s.onRemoveExecute && q() && O.push({
1456
1459
  id: "3",
1457
1460
  icon: /* @__PURE__ */ e(Qe, {}),
1458
1461
  color: "red",
1459
- label: s.labelRemove ? s.labelRemove : p().t("archbase:Remove"),
1462
+ label: s.labelRemove ? s.labelRemove : m().t("archbase:Remove"),
1460
1463
  executeAction: () => {
1461
1464
  s && s.onRemoveExecute && s.onRemoveExecute();
1462
1465
  },
1463
1466
  enabled: !r.isEmpty() && r.isBrowsing(),
1464
1467
  hint: "Clique para remover."
1465
- }), s.allowView && s.onView && H() && S.push({
1468
+ }), s.allowView && s.onView && q() && O.push({
1466
1469
  id: "4",
1467
1470
  icon: /* @__PURE__ */ e(Xe, {}),
1468
1471
  color: "green",
1469
- label: s.labelView ? s.labelView : p().t("archbase:View"),
1472
+ label: s.labelView ? s.labelView : m().t("archbase:View"),
1470
1473
  executeAction: () => {
1471
1474
  s && s.onView && s.onView();
1472
1475
  },
1473
1476
  enabled: !r.isEmpty() && r.isBrowsing(),
1474
1477
  hint: "Clique para visualizar."
1475
- }), s.customUserActions && s.positionCustomUserActions === "before" ? [...s.customUserActions, ...S] : s.customUserActions && s.positionCustomUserActions === "after" ? [...S, ...s.customUserActions] : S;
1476
- }, [D, r, F]), V = (s, H) => {
1477
- R({ ...$, currentFilter: s, activeFilterIndex: H });
1478
+ }), s.customUserActions && s.positionCustomUserActions === "before" ? [...s.customUserActions, ...O] : s.customUserActions && s.positionCustomUserActions === "after" ? [...O, ...s.customUserActions] : O;
1479
+ }, [V, r, F]), S = (s, q) => {
1480
+ R({ ...$, currentFilter: s, activeFilterIndex: q });
1478
1481
  }, U = (s) => {
1479
1482
  R({ ...$, expandedFilter: s });
1480
- }, _ = (s, H) => {
1481
- R({ ...$, currentFilter: s, activeFilterIndex: H });
1482
- }, J = () => {
1483
- }, X = {
1483
+ }, k = (s, q) => {
1484
+ R({ ...$, currentFilter: s, activeFilterIndex: q });
1485
+ }, z = () => {
1486
+ }, W = {
1484
1487
  menuButtonColor: "blue.5",
1485
1488
  menuPosition: "left"
1486
- }, I = {
1489
+ }, E = {
1487
1490
  headerFlexGrow: "left",
1488
1491
  footerFlexGrow: "right"
1489
1492
  // footerGridColumns: {},
1490
- }, ee = { ...X, ...W }, ue = { ...I, ...N };
1493
+ }, re = { ...W, ..._ }, he = { ...E, ...N };
1491
1494
  return /* @__PURE__ */ e(
1492
- ve,
1495
+ Ae,
1493
1496
  {
1494
1497
  resourceName: x,
1495
1498
  resourceDescription: y,
1496
1499
  requiredPermissions: Z,
1497
- fallbackComponent: K,
1500
+ fallbackComponent: J,
1498
1501
  onSecurityReady: P?.onSecurityReady,
1499
1502
  onAccessDenied: P?.onAccessDenied,
1500
1503
  children: /* @__PURE__ */ e(
1501
- xt,
1504
+ vt,
1502
1505
  {
1503
1506
  innerRef: G,
1504
1507
  width: T,
1505
1508
  height: v,
1506
1509
  radius: A,
1507
- withBorder: O,
1510
+ withBorder: te,
1508
1511
  isError: o,
1509
- error: h,
1510
- clearError: m,
1512
+ error: u,
1513
+ clearError: f,
1511
1514
  title: t,
1512
- defaultDebug: f,
1515
+ defaultDebug: h,
1513
1516
  debugOptions: b,
1514
1517
  style: Y,
1515
- options: ue,
1516
- headerLeft: /* @__PURE__ */ e(mt, { actions: M, options: ee }),
1518
+ options: he,
1519
+ headerLeft: /* @__PURE__ */ e(pt, { actions: M, options: re }),
1517
1520
  headerRight: /* @__PURE__ */ e(
1518
1521
  rt,
1519
1522
  {
@@ -1521,69 +1524,69 @@ function mr({
1521
1524
  viewName: a.viewName,
1522
1525
  apiVersion: a.apiVersion,
1523
1526
  ref: w,
1524
- variant: B || E.variant,
1527
+ variant: B || I.variant,
1525
1528
  expandedFilter: $.expandedFilter,
1526
1529
  persistenceDelegator: l,
1527
1530
  currentFilter: $.currentFilter,
1528
1531
  activeFilterIndex: $.activeFilterIndex,
1529
- onSelectedFilter: _,
1530
- onFilterChanged: V,
1531
- onSearchByFilter: J,
1532
+ onSelectedFilter: k,
1533
+ onFilterChanged: S,
1534
+ onSearchByFilter: z,
1532
1535
  onToggleExpandedFilter: U,
1533
1536
  width: "660px",
1534
1537
  height: "170px",
1535
1538
  children: d
1536
1539
  }
1537
1540
  ),
1538
- footerRight: c && /* @__PURE__ */ e(st, { total: 10 }),
1539
- children: q
1541
+ footerRight: c && /* @__PURE__ */ e(at, { total: 10 }),
1542
+ children: L
1540
1543
  }
1541
1544
  )
1542
1545
  }
1543
1546
  );
1544
1547
  }
1545
- function pr() {
1548
+ function gr() {
1546
1549
  return /* @__PURE__ */ e("div", { children: "SEARCH TEMPLATE" });
1547
1550
  }
1548
- const nt = Vt(void 0);
1549
- function gr({ children: t }) {
1550
- const [r, a] = te({}), d = Be((m, T) => {
1551
- a((v) => ({ ...v, [m]: T }));
1552
- }, []), n = Be((m) => {
1551
+ const nt = St(void 0);
1552
+ function xr({ children: t }) {
1553
+ const [r, a] = ne({}), d = Ne((f, T) => {
1554
+ a((v) => ({ ...v, [f]: T }));
1555
+ }, []), n = Ne((f) => {
1553
1556
  a((T) => {
1554
1557
  const v = { ...T };
1555
- return delete v[m], v;
1558
+ return delete v[f], v;
1556
1559
  });
1557
- }, []), o = Be(() => {
1560
+ }, []), o = Ne(() => {
1558
1561
  a({});
1559
- }, []), h = Be((m) => r[m], [r]);
1560
- return /* @__PURE__ */ e(nt.Provider, { value: { errors: r, setError: d, clearError: n, clearAll: o, getError: h }, children: t });
1561
- }
1562
- function xr() {
1563
- return ht(nt);
1562
+ }, []), u = Ne((f) => r[f], [r]);
1563
+ return /* @__PURE__ */ e(nt.Provider, { value: { errors: r, setError: d, clearError: n, clearAll: o, getError: u }, children: t });
1564
1564
  }
1565
1565
  function vr() {
1566
- const t = ht(nt);
1566
+ return ft(nt);
1567
+ }
1568
+ function br() {
1569
+ const t = ft(nt);
1567
1570
  if (!t)
1568
1571
  throw new Error("useRequiredValidationErrors must be used within ValidationErrorsProvider");
1569
1572
  return t;
1570
1573
  }
1571
1574
  export {
1572
- sr as ArchbaseAdvancedSmartButton,
1573
- ve as ArchbaseConditionalSecurityWrapper,
1574
- dr as ArchbaseFormModalTemplate,
1575
- cr as ArchbaseFormTemplate,
1576
- hr as ArchbaseGridTemplate,
1577
- fr as ArchbaseMasonryTemplate,
1578
- ur as ArchbaseModalTemplate,
1579
- mr as ArchbasePanelTemplate,
1580
- pr as ArchbaseSearchTemplate,
1581
- ie as ArchbaseSmartActionButton,
1582
- xt as ArchbaseSpaceTemplate,
1583
- gr as ValidationErrorsProvider,
1584
- ar as useConditionalSecurity,
1585
- me as useOptionalTemplateSecurity,
1586
- vr as useRequiredValidationErrors,
1587
- lr as useTemplateSecurityAvailable,
1588
- xr as useValidationErrors
1575
+ ar as ArchbaseAdvancedSmartButton,
1576
+ Ae as ArchbaseConditionalSecurityWrapper,
1577
+ ur as ArchbaseFormModalTemplate,
1578
+ dr as ArchbaseFormTemplate,
1579
+ fr as ArchbaseGridTemplate,
1580
+ mr as ArchbaseMasonryTemplate,
1581
+ hr as ArchbaseModalTemplate,
1582
+ pr as ArchbasePanelTemplate,
1583
+ gr as ArchbaseSearchTemplate,
1584
+ oe as ArchbaseSmartActionButton,
1585
+ vt as ArchbaseSpaceTemplate,
1586
+ xr as ValidationErrorsProvider,
1587
+ cr as useConditionalSecurity,
1588
+ ge as useOptionalTemplateSecurity,
1589
+ br as useRequiredValidationErrors,
1590
+ sr as useTemplateSecurityAvailable,
1591
+ vr as useValidationErrors
1589
1592
  };