@devtable/settings-form 12.10.1 → 12.10.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.
@@ -1,10 +1,10 @@
1
- import F, { useEffect as Ct, forwardRef as ut, useState as or, Component as Vr } from "react";
1
+ import F, { useEffect as Ot, forwardRef as ut, useState as or, Component as Vr } from "react";
2
2
  import { Box as X, TextInput as Q, Divider as ct, Group as z, NumberInput as Wr, PasswordInput as dt, Button as D, Modal as xe, Stack as Ke, Alert as Kr, SegmentedControl as Zr, Tooltip as at, Text as ke, ActionIcon as Dt, LoadingOverlay as pt, Table as ft, Select as Xr, Switch as Qr, createStyles as lr, rem as Ve, useComponentDefaultProps as Jr, useMantineTheme as en, ScrollArea as ur, Tabs as gt, HoverCard as _t } from "@mantine/core";
3
3
  import { showNotification as oe, updateNotification as P } from "@mantine/notifications";
4
4
  import { Recycle as tn, AlertCircle as rn, PlaylistAdd as ht, Trash as mt, Edit as nn } from "tabler-icons-react";
5
5
  import * as an from "crypto-js";
6
6
  import sn from "axios";
7
- import { useForm as me, Controller as O } from "react-hook-form";
7
+ import { useForm as me, Controller as R } from "react-hook-form";
8
8
  import { useBoolean as on, useRequest as Te } from "ahooks";
9
9
  import cr, { loader as At } from "@monaco-editor/react";
10
10
  import { useModals as Ze, closeAllModals as ln } from "@mantine/modals";
@@ -68,8 +68,8 @@ function hn() {
68
68
  }
69
69
  function _(o, y, E) {
70
70
  {
71
- var A = w.ReactDebugCurrentFrame, R = A.getStackAddendum();
72
- R !== "" && (y += "%s", E = E.concat([R]));
71
+ var A = w.ReactDebugCurrentFrame, C = A.getStackAddendum();
72
+ C !== "" && (y += "%s", E = E.concat([C]));
73
73
  var I = E.map(function(j) {
74
74
  return String(j);
75
75
  });
@@ -89,8 +89,8 @@ function hn() {
89
89
  var A = o.displayName;
90
90
  if (A)
91
91
  return A;
92
- var R = y.displayName || y.name || "";
93
- return R !== "" ? E + "(" + R + ")" : E;
92
+ var C = y.displayName || y.name || "";
93
+ return C !== "" ? E + "(" + C + ")" : E;
94
94
  }
95
95
  function V(o) {
96
96
  return o.displayName || "Context";
@@ -130,7 +130,7 @@ function hn() {
130
130
  var A = o.displayName || null;
131
131
  return A !== null ? A : B(o.type) || "Memo";
132
132
  case u: {
133
- var R = o, I = R._payload, j = R._init;
133
+ var C = o, I = C._payload, j = C._init;
134
134
  try {
135
135
  return B(j(I));
136
136
  } catch {
@@ -208,21 +208,21 @@ function hn() {
208
208
  if (Me === void 0)
209
209
  try {
210
210
  throw Error();
211
- } catch (R) {
212
- var A = R.stack.trim().match(/\n( *(at )?)/);
211
+ } catch (C) {
212
+ var A = C.stack.trim().match(/\n( *(at )?)/);
213
213
  Me = A && A[1] || "";
214
214
  }
215
215
  return `
216
216
  ` + Me + o;
217
217
  }
218
218
  }
219
- var Re = !1, _e;
219
+ var Ce = !1, _e;
220
220
  {
221
- var Oe = typeof WeakMap == "function" ? WeakMap : Map;
222
- _e = new Oe();
221
+ var Re = typeof WeakMap == "function" ? WeakMap : Map;
222
+ _e = new Re();
223
223
  }
224
224
  function $t(o, y) {
225
- if (!o || Re)
225
+ if (!o || Ce)
226
226
  return "";
227
227
  {
228
228
  var E = _e.get(o);
@@ -230,8 +230,8 @@ function hn() {
230
230
  return E;
231
231
  }
232
232
  var A;
233
- Re = !0;
234
- var R = Error.prepareStackTrace;
233
+ Ce = !0;
234
+ var C = Error.prepareStackTrace;
235
235
  Error.prepareStackTrace = void 0;
236
236
  var I;
237
237
  I = ge.current, ge.current = null, fe();
@@ -287,7 +287,7 @@ function hn() {
287
287
  }
288
288
  }
289
289
  } finally {
290
- Re = !1, ge.current = I, Ee(), Error.prepareStackTrace = R;
290
+ Ce = !1, ge.current = I, Ee(), Error.prepareStackTrace = C;
291
291
  }
292
292
  var De = o ? o.displayName || o.name : "", Zt = De ? je(De) : "";
293
293
  return typeof o == "function" && _e.set(o, Zt), Zt;
@@ -319,9 +319,9 @@ function hn() {
319
319
  case c:
320
320
  return Je(o.type, y, E);
321
321
  case u: {
322
- var A = o, R = A._payload, I = A._init;
322
+ var A = o, C = A._payload, I = A._init;
323
323
  try {
324
- return Je(I(R), y, E);
324
+ return Je(I(C), y, E);
325
325
  } catch {
326
326
  }
327
327
  }
@@ -336,7 +336,7 @@ function hn() {
336
336
  } else
337
337
  Pt.setExtraStackFrame(null);
338
338
  }
339
- function Tr(o, y, E, A, R) {
339
+ function Tr(o, y, E, A, C) {
340
340
  {
341
341
  var I = Function.call.bind(et);
342
342
  for (var j in o)
@@ -351,7 +351,7 @@ function hn() {
351
351
  } catch (U) {
352
352
  T = U;
353
353
  }
354
- T && !(T instanceof Error) && (tt(R), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", A || "React class", E, j, typeof T), tt(null)), T instanceof Error && !(T.message in zt) && (zt[T.message] = !0, tt(R), S("Failed %s type: %s", E, T.message), tt(null));
354
+ T && !(T instanceof Error) && (tt(C), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", A || "React class", E, j, typeof T), tt(null)), T instanceof Error && !(T.message in zt) && (zt[T.message] = !0, tt(C), S("Failed %s type: %s", E, T.message), tt(null));
355
355
  }
356
356
  }
357
357
  }
@@ -359,13 +359,13 @@ function hn() {
359
359
  function yt(o) {
360
360
  return jr(o);
361
361
  }
362
- function Rr(o) {
362
+ function Cr(o) {
363
363
  {
364
364
  var y = typeof Symbol == "function" && Symbol.toStringTag, E = y && o[Symbol.toStringTag] || o.constructor.name || "Object";
365
365
  return E;
366
366
  }
367
367
  }
368
- function Or(o) {
368
+ function Rr(o) {
369
369
  try {
370
370
  return Mt(o), !1;
371
371
  } catch {
@@ -376,10 +376,10 @@ function hn() {
376
376
  return "" + o;
377
377
  }
378
378
  function Bt(o) {
379
- if (Or(o))
380
- return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Rr(o)), Mt(o);
379
+ if (Rr(o))
380
+ return S("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Cr(o)), Mt(o);
381
381
  }
382
- var Be = w.ReactCurrentOwner, Cr = {
382
+ var Be = w.ReactCurrentOwner, Or = {
383
383
  key: !0,
384
384
  ref: !0,
385
385
  __self: !0,
@@ -430,7 +430,7 @@ function hn() {
430
430
  });
431
431
  }
432
432
  }
433
- var $r = function(o, y, E, A, R, I, j) {
433
+ var $r = function(o, y, E, A, C, I, j) {
434
434
  var T = {
435
435
  // This tag allows us to uniquely identify this as a React Element
436
436
  $$typeof: t,
@@ -456,15 +456,15 @@ function hn() {
456
456
  configurable: !1,
457
457
  enumerable: !1,
458
458
  writable: !1,
459
- value: R
459
+ value: C
460
460
  }), Object.freeze && (Object.freeze(T.props), Object.freeze(T)), T;
461
461
  };
462
- function zr(o, y, E, A, R) {
462
+ function zr(o, y, E, A, C) {
463
463
  {
464
464
  var I, j = {}, T = null, ne = null;
465
- E !== void 0 && (Bt(E), T = "" + E), Ir(y) && (Bt(y.key), T = "" + y.key), Dr(y) && (ne = y.ref, Lr(y, R));
465
+ E !== void 0 && (Bt(E), T = "" + E), Ir(y) && (Bt(y.key), T = "" + y.key), Dr(y) && (ne = y.ref, Lr(y, C));
466
466
  for (I in y)
467
- et.call(y, I) && !Cr.hasOwnProperty(I) && (j[I] = y[I]);
467
+ et.call(y, I) && !Or.hasOwnProperty(I) && (j[I] = y[I]);
468
468
  if (o && o.defaultProps) {
469
469
  var U = o.defaultProps;
470
470
  for (I in U)
@@ -474,11 +474,11 @@ function hn() {
474
474
  var Y = typeof o == "function" ? o.displayName || o.name || "Unknown" : o;
475
475
  T && Fr(j, Y), ne && Nr(j, Y);
476
476
  }
477
- return $r(o, T, ne, R, A, Be.current, j);
477
+ return $r(o, T, ne, C, A, Be.current, j);
478
478
  }
479
479
  }
480
480
  var xt = w.ReactCurrentOwner, Ht = w.ReactDebugCurrentFrame;
481
- function Ce(o) {
481
+ function Oe(o) {
482
482
  if (o) {
483
483
  var y = o._owner, E = Je(o.type, o._source, y ? y.type : null);
484
484
  Ht.setExtraStackFrame(E);
@@ -536,7 +536,7 @@ Check the top-level render call using <` + E + ">.");
536
536
  return;
537
537
  Yt[E] = !0;
538
538
  var A = "";
539
- o && o._owner && o._owner !== xt.current && (A = " It was passed a child from " + B(o._owner.type) + "."), Ce(o), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', E, A), Ce(null);
539
+ o && o._owner && o._owner !== xt.current && (A = " It was passed a child from " + B(o._owner.type) + "."), Oe(o), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', E, A), Oe(null);
540
540
  }
541
541
  }
542
542
  function Wt(o, y) {
@@ -551,9 +551,9 @@ Check the top-level render call using <` + E + ">.");
551
551
  else if (Et(o))
552
552
  o._store && (o._store.validated = !0);
553
553
  else if (o) {
554
- var R = x(o);
555
- if (typeof R == "function" && R !== o.entries)
556
- for (var I = R.call(o), j; !(j = I.next()).done; )
554
+ var C = x(o);
555
+ if (typeof C == "function" && C !== o.entries)
556
+ for (var I = C.call(o), j; !(j = I.next()).done; )
557
557
  Et(j.value) && Vt(j.value, y);
558
558
  }
559
559
  }
@@ -577,8 +577,8 @@ Check the top-level render call using <` + E + ">.");
577
577
  Tr(E, o.props, "prop", A, o);
578
578
  } else if (y.PropTypes !== void 0 && !wt) {
579
579
  wt = !0;
580
- var R = B(y);
581
- S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", R || "Unknown");
580
+ var C = B(y);
581
+ S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", C || "Unknown");
582
582
  }
583
583
  typeof y.getDefaultProps == "function" && !y.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
584
584
  }
@@ -588,25 +588,25 @@ Check the top-level render call using <` + E + ">.");
588
588
  for (var y = Object.keys(o.props), E = 0; E < y.length; E++) {
589
589
  var A = y[E];
590
590
  if (A !== "children" && A !== "key") {
591
- Ce(o), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", A), Ce(null);
591
+ Oe(o), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", A), Oe(null);
592
592
  break;
593
593
  }
594
594
  }
595
- o.ref !== null && (Ce(o), S("Invalid attribute `ref` supplied to `React.Fragment`."), Ce(null));
595
+ o.ref !== null && (Oe(o), S("Invalid attribute `ref` supplied to `React.Fragment`."), Oe(null));
596
596
  }
597
597
  }
598
- function Kt(o, y, E, A, R, I) {
598
+ function Kt(o, y, E, A, C, I) {
599
599
  {
600
600
  var j = te(o);
601
601
  if (!j) {
602
602
  var T = "";
603
603
  (o === void 0 || typeof o == "object" && o !== null && Object.keys(o).length === 0) && (T += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
604
- var ne = Pr(R);
604
+ var ne = Pr(C);
605
605
  ne ? T += ne : T += qt();
606
606
  var U;
607
607
  o === null ? U = "null" : yt(o) ? U = "array" : o !== void 0 && o.$$typeof === t ? (U = "<" + (B(o.type) || "Unknown") + " />", T = " Did you accidentally export a JSX literal instead of a component?") : U = typeof o, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", U, T);
608
608
  }
609
- var Y = zr(o, y, E, R, I);
609
+ var Y = zr(o, y, E, C, I);
610
610
  if (Y == null)
611
611
  return Y;
612
612
  if (j) {
@@ -842,8 +842,8 @@ const xn = {
842
842
  }, _n = {
843
843
  list: async () => await G.get()("/role/list", {}, {})
844
844
  };
845
- var pr = 60, fr = pr * 60, gr = fr * 24, An = gr * 7, ze = 1e3, kt = pr * ze, Jt = fr * ze, kn = gr * ze, Tn = An * ze, It = "millisecond", Le = "second", Fe = "minute", Ne = "hour", ve = "day", nt = "week", le = "month", hr = "quarter", ye = "year", $e = "date", jn = "YYYY-MM-DDTHH:mm:ssZ", er = "Invalid Date", Rn = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, On = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g;
846
- const Cn = {
845
+ var pr = 60, fr = pr * 60, gr = fr * 24, An = gr * 7, ze = 1e3, kt = pr * ze, Jt = fr * ze, kn = gr * ze, Tn = An * ze, It = "millisecond", Le = "second", Fe = "minute", Ne = "hour", ve = "day", nt = "week", le = "month", hr = "quarter", ye = "year", $e = "date", jn = "YYYY-MM-DDTHH:mm:ssZ", er = "Invalid Date", Cn = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, Rn = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g;
846
+ const On = {
847
847
  name: "en",
848
848
  weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),
849
849
  months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"),
@@ -852,12 +852,12 @@ const Cn = {
852
852
  return "[" + t + (r[(n - 20) % 10] || r[n] || r[0]) + "]";
853
853
  }
854
854
  };
855
- var Rt = function(t, r, n) {
855
+ var Ct = function(t, r, n) {
856
856
  var i = String(t);
857
857
  return !i || i.length >= r ? t : "" + Array(r + 1 - i.length).join(n) + t;
858
858
  }, Dn = function(t) {
859
859
  var r = -t.utcOffset(), n = Math.abs(r), i = Math.floor(n / 60), s = n % 60;
860
- return (r <= 0 ? "+" : "-") + Rt(i, 2, "0") + ":" + Rt(s, 2, "0");
860
+ return (r <= 0 ? "+" : "-") + Ct(i, 2, "0") + ":" + Ct(s, 2, "0");
861
861
  }, In = function e(t, r) {
862
862
  if (t.date() < r.date())
863
863
  return -e(r, t);
@@ -883,7 +883,7 @@ var Rt = function(t, r, n) {
883
883
  return t === void 0;
884
884
  };
885
885
  const $n = {
886
- s: Rt,
886
+ s: Ct,
887
887
  z: Dn,
888
888
  m: In,
889
889
  a: Ln,
@@ -891,7 +891,7 @@ const $n = {
891
891
  u: Nn
892
892
  };
893
893
  var We = "en", Ae = {};
894
- Ae[We] = Cn;
894
+ Ae[We] = On;
895
895
  var Lt = function(t) {
896
896
  return t instanceof bt;
897
897
  }, it = function e(t, r, n) {
@@ -922,20 +922,20 @@ var Lt = function(t) {
922
922
  $offset: r.$offset
923
923
  // todo: refactor; do not use this.$offset in you code
924
924
  });
925
- }, C = $n;
926
- C.l = it;
927
- C.i = Lt;
928
- C.w = zn;
925
+ }, O = $n;
926
+ O.l = it;
927
+ O.i = Lt;
928
+ O.w = zn;
929
929
  var Pn = function(t) {
930
930
  var r = t.date, n = t.utc;
931
931
  if (r === null)
932
932
  return /* @__PURE__ */ new Date(NaN);
933
- if (C.u(r))
933
+ if (O.u(r))
934
934
  return /* @__PURE__ */ new Date();
935
935
  if (r instanceof Date)
936
936
  return new Date(r);
937
937
  if (typeof r == "string" && !/Z$/i.test(r)) {
938
- var i = r.match(Rn);
938
+ var i = r.match(Cn);
939
939
  if (i) {
940
940
  var s = i[2] - 1 || 0, l = (i[7] || "0").substring(0, 3);
941
941
  return n ? new Date(Date.UTC(i[1], s, i[3] || 1, i[4] || 0, i[5] || 0, i[6] || 0, l)) : new Date(i[1], s, i[3] || 1, i[4] || 0, i[5] || 0, i[6] || 0, l);
@@ -953,7 +953,7 @@ var Pn = function(t) {
953
953
  var n = this.$d;
954
954
  this.$y = n.getFullYear(), this.$M = n.getMonth(), this.$D = n.getDate(), this.$W = n.getDay(), this.$H = n.getHours(), this.$m = n.getMinutes(), this.$s = n.getSeconds(), this.$ms = n.getMilliseconds();
955
955
  }, t.$utils = function() {
956
- return C;
956
+ return O;
957
957
  }, t.isValid = function() {
958
958
  return this.$d.toString() !== er;
959
959
  }, t.isSame = function(n, i) {
@@ -964,18 +964,18 @@ var Pn = function(t) {
964
964
  }, t.isBefore = function(n, i) {
965
965
  return this.endOf(i) < K(n);
966
966
  }, t.$g = function(n, i, s) {
967
- return C.u(n) ? this[i] : this.set(s, n);
967
+ return O.u(n) ? this[i] : this.set(s, n);
968
968
  }, t.unix = function() {
969
969
  return Math.floor(this.valueOf() / 1e3);
970
970
  }, t.valueOf = function() {
971
971
  return this.$d.getTime();
972
972
  }, t.startOf = function(n, i) {
973
- var s = this, l = C.u(i) ? !0 : i, d = C.p(n), p = function(w, S) {
974
- var _ = C.w(s.$u ? Date.UTC(s.$y, S, w) : new Date(s.$y, S, w), s);
973
+ var s = this, l = O.u(i) ? !0 : i, d = O.p(n), p = function(w, S) {
974
+ var _ = O.w(s.$u ? Date.UTC(s.$y, S, w) : new Date(s.$y, S, w), s);
975
975
  return l ? _ : _.endOf(ve);
976
976
  }, f = function(w, S) {
977
977
  var _ = [0, 0, 0, 0], k = [23, 59, 59, 999];
978
- return C.w(s.toDate()[w].apply(
978
+ return O.w(s.toDate()[w].apply(
979
979
  // eslint-disable-line prefer-spread
980
980
  s.toDate("s"),
981
981
  (l ? _ : k).slice(S)
@@ -1005,7 +1005,7 @@ var Pn = function(t) {
1005
1005
  }, t.endOf = function(n) {
1006
1006
  return this.startOf(n, !1);
1007
1007
  }, t.$set = function(n, i) {
1008
- var s, l = C.p(n), d = "set" + (this.$u ? "UTC" : ""), p = (s = {}, s[ve] = d + "Date", s[$e] = d + "Date", s[le] = d + "Month", s[ye] = d + "FullYear", s[Ne] = d + "Hours", s[Fe] = d + "Minutes", s[Le] = d + "Seconds", s[It] = d + "Milliseconds", s)[l], f = l === ve ? this.$D + (i - this.$W) : i;
1008
+ var s, l = O.p(n), d = "set" + (this.$u ? "UTC" : ""), p = (s = {}, s[ve] = d + "Date", s[$e] = d + "Date", s[le] = d + "Month", s[ye] = d + "FullYear", s[Ne] = d + "Hours", s[Fe] = d + "Minutes", s[Le] = d + "Seconds", s[It] = d + "Milliseconds", s)[l], f = l === ve ? this.$D + (i - this.$W) : i;
1009
1009
  if (l === le || l === ye) {
1010
1010
  var h = this.clone().set($e, 1);
1011
1011
  h.$d[p](f), h.init(), this.$d = h.set($e, Math.min(this.$D, h.daysInMonth())).$d;
@@ -1015,13 +1015,13 @@ var Pn = function(t) {
1015
1015
  }, t.set = function(n, i) {
1016
1016
  return this.clone().$set(n, i);
1017
1017
  }, t.get = function(n) {
1018
- return this[C.p(n)]();
1018
+ return this[O.p(n)]();
1019
1019
  }, t.add = function(n, i) {
1020
1020
  var s = this, l;
1021
1021
  n = Number(n);
1022
- var d = C.p(i), p = function(u) {
1022
+ var d = O.p(i), p = function(u) {
1023
1023
  var g = K(s);
1024
- return C.w(g.date(g.date() + Math.round(u * n)), s);
1024
+ return O.w(g.date(g.date() + Math.round(u * n)), s);
1025
1025
  };
1026
1026
  if (d === le)
1027
1027
  return this.set(le, this.$M + n);
@@ -1032,17 +1032,17 @@ var Pn = function(t) {
1032
1032
  if (d === nt)
1033
1033
  return p(7);
1034
1034
  var f = (l = {}, l[Fe] = kt, l[Ne] = Jt, l[Le] = ze, l)[d] || 1, h = this.$d.getTime() + n * f;
1035
- return C.w(h, this);
1035
+ return O.w(h, this);
1036
1036
  }, t.subtract = function(n, i) {
1037
1037
  return this.add(n * -1, i);
1038
1038
  }, t.format = function(n) {
1039
1039
  var i = this, s = this.$locale();
1040
1040
  if (!this.isValid())
1041
1041
  return s.invalidDate || er;
1042
- var l = n || jn, d = C.z(this), p = this.$H, f = this.$m, h = this.$M, c = s.weekdays, u = s.months, g = s.meridiem, v = function(_, k, H, J) {
1042
+ var l = n || jn, d = O.z(this), p = this.$H, f = this.$m, h = this.$M, c = s.weekdays, u = s.months, g = s.meridiem, v = function(_, k, H, J) {
1043
1043
  return _ && (_[k] || _(i, l)) || H[k].slice(0, J);
1044
1044
  }, m = function(_) {
1045
- return C.s(p % 12 || 12, _, "0");
1045
+ return O.s(p % 12 || 12, _, "0");
1046
1046
  }, x = g || function(S, _, k) {
1047
1047
  var H = S < 12 ? "AM" : "PM";
1048
1048
  return k ? H.toLowerCase() : H;
@@ -1051,11 +1051,11 @@ var Pn = function(t) {
1051
1051
  case "YY":
1052
1052
  return String(i.$y).slice(-2);
1053
1053
  case "YYYY":
1054
- return C.s(i.$y, 4, "0");
1054
+ return O.s(i.$y, 4, "0");
1055
1055
  case "M":
1056
1056
  return h + 1;
1057
1057
  case "MM":
1058
- return C.s(h + 1, 2, "0");
1058
+ return O.s(h + 1, 2, "0");
1059
1059
  case "MMM":
1060
1060
  return v(s.monthsShort, h, u, 3);
1061
1061
  case "MMMM":
@@ -1063,7 +1063,7 @@ var Pn = function(t) {
1063
1063
  case "D":
1064
1064
  return i.$D;
1065
1065
  case "DD":
1066
- return C.s(i.$D, 2, "0");
1066
+ return O.s(i.$D, 2, "0");
1067
1067
  case "d":
1068
1068
  return String(i.$W);
1069
1069
  case "dd":
@@ -1075,7 +1075,7 @@ var Pn = function(t) {
1075
1075
  case "H":
1076
1076
  return String(p);
1077
1077
  case "HH":
1078
- return C.s(p, 2, "0");
1078
+ return O.s(p, 2, "0");
1079
1079
  case "h":
1080
1080
  return m(1);
1081
1081
  case "hh":
@@ -1087,26 +1087,26 @@ var Pn = function(t) {
1087
1087
  case "m":
1088
1088
  return String(f);
1089
1089
  case "mm":
1090
- return C.s(f, 2, "0");
1090
+ return O.s(f, 2, "0");
1091
1091
  case "s":
1092
1092
  return String(i.$s);
1093
1093
  case "ss":
1094
- return C.s(i.$s, 2, "0");
1094
+ return O.s(i.$s, 2, "0");
1095
1095
  case "SSS":
1096
- return C.s(i.$ms, 3, "0");
1096
+ return O.s(i.$ms, 3, "0");
1097
1097
  case "Z":
1098
1098
  return d;
1099
1099
  }
1100
1100
  return null;
1101
1101
  };
1102
- return l.replace(On, function(S, _) {
1102
+ return l.replace(Rn, function(S, _) {
1103
1103
  return _ || w(S) || d.replace(":", "");
1104
1104
  });
1105
1105
  }, t.utcOffset = function() {
1106
1106
  return -Math.round(this.$d.getTimezoneOffset() / 15) * 15;
1107
1107
  }, t.diff = function(n, i, s) {
1108
- var l = this, d = C.p(i), p = K(n), f = (p.utcOffset() - this.utcOffset()) * kt, h = this - p, c = function() {
1109
- return C.m(l, p);
1108
+ var l = this, d = O.p(i), p = K(n), f = (p.utcOffset() - this.utcOffset()) * kt, h = this - p, c = function() {
1109
+ return O.m(l, p);
1110
1110
  }, u;
1111
1111
  switch (d) {
1112
1112
  case ye:
@@ -1137,7 +1137,7 @@ var Pn = function(t) {
1137
1137
  u = h;
1138
1138
  break;
1139
1139
  }
1140
- return s ? u : C.a(u);
1140
+ return s ? u : O.a(u);
1141
1141
  }, t.daysInMonth = function() {
1142
1142
  return this.endOf(le).$D;
1143
1143
  }, t.$locale = function() {
@@ -1148,7 +1148,7 @@ var Pn = function(t) {
1148
1148
  var s = this.clone(), l = it(n, i, !0);
1149
1149
  return l && (s.$L = l), s;
1150
1150
  }, t.clone = function() {
1151
- return C.w(this.$d, this);
1151
+ return O.w(this.$d, this);
1152
1152
  }, t.toDate = function() {
1153
1153
  return new Date(this.valueOf());
1154
1154
  }, t.toJSON = function() {
@@ -1234,20 +1234,20 @@ function Bn({
1234
1234
  }
1235
1235
  }
1236
1236
  });
1237
- return Ct(() => {
1237
+ return Ot(() => {
1238
1238
  i("type", r);
1239
1239
  }, [i, r]), /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: s(e), children: [
1240
- /* @__PURE__ */ a.jsx(O, { name: "key", control: n, render: ({
1240
+ /* @__PURE__ */ a.jsx(R, { name: "key", control: n, render: ({
1241
1241
  field: l
1242
1242
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Name", placeholder: "A unique name", ...l }) }),
1243
1243
  /* @__PURE__ */ a.jsx(ct, { label: "Connection Info", labelPosition: "center" }),
1244
1244
  /* @__PURE__ */ a.jsxs(z, { grow: !0, children: [
1245
- /* @__PURE__ */ a.jsx(O, { name: "config.host", control: n, render: ({
1245
+ /* @__PURE__ */ a.jsx(R, { name: "config.host", control: n, render: ({
1246
1246
  field: l
1247
1247
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Host", sx: {
1248
1248
  flexGrow: 1
1249
1249
  }, ...l }) }),
1250
- /* @__PURE__ */ a.jsx(O, { name: "config.port", control: n, render: ({
1250
+ /* @__PURE__ */ a.jsx(R, { name: "config.port", control: n, render: ({
1251
1251
  field: l
1252
1252
  }) => (
1253
1253
  // @ts-expect-error type of onChange
@@ -1256,13 +1256,13 @@ function Bn({
1256
1256
  }, ...l })
1257
1257
  ) })
1258
1258
  ] }),
1259
- /* @__PURE__ */ a.jsx(O, { name: "config.username", control: n, render: ({
1259
+ /* @__PURE__ */ a.jsx(R, { name: "config.username", control: n, render: ({
1260
1260
  field: l
1261
1261
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...l }) }),
1262
- /* @__PURE__ */ a.jsx(O, { name: "config.password", control: n, render: ({
1262
+ /* @__PURE__ */ a.jsx(R, { name: "config.password", control: n, render: ({
1263
1263
  field: l
1264
1264
  }) => /* @__PURE__ */ a.jsx(dt, { mb: t.spacing, size: t.size, required: !0, label: "Password", ...l }) }),
1265
- /* @__PURE__ */ a.jsx(O, { name: "config.database", control: n, render: ({
1265
+ /* @__PURE__ */ a.jsx(R, { name: "config.database", control: n, render: ({
1266
1266
  field: l
1267
1267
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Database", ...l }) }),
1268
1268
  /* @__PURE__ */ a.jsx(z, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a.jsx(D, { type: "submit", size: t.button.size, children: "Save" }) })
@@ -1300,7 +1300,7 @@ const Un = ({
1300
1300
  }, v = () => {
1301
1301
  c(i);
1302
1302
  };
1303
- return Ct(() => {
1303
+ return Ot(() => {
1304
1304
  c(e);
1305
1305
  }, [e]), /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
1306
1306
  /* @__PURE__ */ a.jsx(D, { variant: "filled", size: s.button.size, onClick: p, sx: {
@@ -1345,20 +1345,20 @@ function Gn({
1345
1345
  }
1346
1346
  });
1347
1347
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: i(e), children: [
1348
- /* @__PURE__ */ a.jsx(O, { name: "key", control: r, render: ({
1348
+ /* @__PURE__ */ a.jsx(R, { name: "key", control: r, render: ({
1349
1349
  field: s
1350
1350
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Name", placeholder: "A unique name", ...s }) }),
1351
1351
  /* @__PURE__ */ a.jsx(ct, { label: "Connection Info", labelPosition: "center" }),
1352
- /* @__PURE__ */ a.jsx(O, { name: "config.host", control: r, render: ({
1352
+ /* @__PURE__ */ a.jsx(R, { name: "config.host", control: r, render: ({
1353
1353
  field: s
1354
1354
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, label: "Base URL", sx: {
1355
1355
  flexGrow: 1
1356
1356
  }, ...s }) }),
1357
1357
  /* @__PURE__ */ a.jsxs(z, { grow: !0, children: [
1358
- /* @__PURE__ */ a.jsx(O, { name: "config.processing.pre", control: r, render: ({
1358
+ /* @__PURE__ */ a.jsx(R, { name: "config.processing.pre", control: r, render: ({
1359
1359
  field: s
1360
1360
  }) => /* @__PURE__ */ a.jsx(st, { label: "Pre Processing", modalTitle: "This function will run before sending the request (for scenarios like encryption)", defaultValue: rt.pre, ...s, styles: t }) }),
1361
- /* @__PURE__ */ a.jsx(O, { name: "config.processing.post", control: r, render: ({
1361
+ /* @__PURE__ */ a.jsx(R, { name: "config.processing.post", control: r, render: ({
1362
1362
  field: s
1363
1363
  }) => /* @__PURE__ */ a.jsx(st, { label: "Post Processing", modalTitle: "This function will run after sending the request (for scenarios like decryption)", defaultValue: rt.post, ...s, styles: t }) })
1364
1364
  ] }),
@@ -1387,7 +1387,8 @@ function qn({
1387
1387
  id: "for-creating",
1388
1388
  title: "Pending",
1389
1389
  message: "Adding data source...",
1390
- loading: !0
1390
+ loading: !0,
1391
+ autoClose: !1
1391
1392
  });
1392
1393
  try {
1393
1394
  console.log({
@@ -1398,14 +1399,16 @@ function qn({
1398
1399
  id: "for-creating",
1399
1400
  title: "Successful",
1400
1401
  message: "Data source is added",
1401
- color: "green"
1402
+ color: "green",
1403
+ autoClose: !0
1402
1404
  }), e();
1403
1405
  } catch (h) {
1404
- P({
1406
+ console.error(h), P({
1405
1407
  id: "for-creating",
1406
1408
  title: "Failed",
1407
1409
  message: h.message,
1408
- color: "red"
1410
+ color: "red",
1411
+ autoClose: !0
1409
1412
  });
1410
1413
  }
1411
1414
  }, s = r === "postgresql" || r === "mysql", l = r === "http";
@@ -1441,7 +1444,7 @@ function Yn({
1441
1444
  }
1442
1445
  const Vn = (e) => e.replace(/([^:])(\/\/+)/g, "$1/");
1443
1446
  function Wn(e) {
1444
- Ct(() => {
1447
+ Ot(() => {
1445
1448
  if (At.__getMonacoInstance())
1446
1449
  return;
1447
1450
  console.log("loading monaco for @devtable/settings-form");
@@ -1465,12 +1468,14 @@ function Kn({
1465
1468
  id: "for-deleting",
1466
1469
  title: "Pending",
1467
1470
  message: "Deleting data source...",
1468
- loading: !0
1471
+ loading: !0,
1472
+ autoClose: !1
1469
1473
  }), await Z.datasource.delete(e), P({
1470
1474
  id: "for-deleting",
1471
1475
  title: "Successful",
1472
1476
  message: `Data source [${t}] is deleted`,
1473
- color: "green"
1477
+ color: "green",
1478
+ autoClose: !0
1474
1479
  }), n());
1475
1480
  }, d = () => s.openConfirmModal({
1476
1481
  title: "Delete this data source?",
@@ -1513,16 +1518,16 @@ function Zn({
1513
1518
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: s(r), children: [
1514
1519
  /* @__PURE__ */ a.jsx(Q, { mb: n.spacing, size: n.size, required: !0, label: "Name", value: e, readOnly: !0 }),
1515
1520
  /* @__PURE__ */ a.jsx(ct, { label: "Connection Info", labelPosition: "center" }),
1516
- /* @__PURE__ */ a.jsx(O, { name: "config.host", control: i, render: ({
1521
+ /* @__PURE__ */ a.jsx(R, { name: "config.host", control: i, render: ({
1517
1522
  field: l
1518
1523
  }) => /* @__PURE__ */ a.jsx(Q, { mb: n.spacing, size: n.size, label: "Base URL", sx: {
1519
1524
  flexGrow: 1
1520
1525
  }, ...l }) }),
1521
1526
  /* @__PURE__ */ a.jsxs(z, { grow: !0, children: [
1522
- /* @__PURE__ */ a.jsx(O, { name: "config.processing.pre", control: i, render: ({
1527
+ /* @__PURE__ */ a.jsx(R, { name: "config.processing.pre", control: i, render: ({
1523
1528
  field: l
1524
1529
  }) => /* @__PURE__ */ a.jsx(st, { label: "Pre Processing", modalTitle: "This function will run before sending the request (for scenarios like encryption)", defaultValue: tr.pre, ...l, styles: n }) }),
1525
- /* @__PURE__ */ a.jsx(O, { name: "config.processing.post", control: i, render: ({
1530
+ /* @__PURE__ */ a.jsx(R, { name: "config.processing.post", control: i, render: ({
1526
1531
  field: l
1527
1532
  }) => /* @__PURE__ */ a.jsx(st, { label: "Post Processing", modalTitle: "This function will run after sending the request (for scenarios like decryption)", defaultValue: tr.post, ...l, styles: n }) })
1528
1533
  ] }),
@@ -1541,7 +1546,8 @@ function Xn({
1541
1546
  id: "for-updating",
1542
1547
  title: "Pending",
1543
1548
  message: "Editing data source...",
1544
- loading: !0
1549
+ loading: !0,
1550
+ autoClose: !1
1545
1551
  });
1546
1552
  try {
1547
1553
  console.log({
@@ -1550,14 +1556,16 @@ function Xn({
1550
1556
  id: "for-updating",
1551
1557
  title: "Successful",
1552
1558
  message: "Data source is updated",
1553
- color: "green"
1559
+ color: "green",
1560
+ autoClose: !0
1554
1561
  }), t();
1555
1562
  } catch (s) {
1556
1563
  P({
1557
1564
  id: "for-updating",
1558
1565
  title: "Failed",
1559
1566
  message: s.message,
1560
- color: "red"
1567
+ color: "red",
1568
+ autoClose: !0
1561
1569
  });
1562
1570
  }
1563
1571
  };
@@ -1729,33 +1737,36 @@ function na({
1729
1737
  id: "for-creating",
1730
1738
  title: "Pending",
1731
1739
  message: "Adding account...",
1732
- loading: !0
1740
+ loading: !0,
1741
+ autoClose: !1
1733
1742
  }), await Z.account.create(l, d, p, f), P({
1734
1743
  id: "for-creating",
1735
1744
  title: "Successful",
1736
1745
  message: "Account is added",
1737
- color: "green"
1746
+ color: "green",
1747
+ autoClose: !0
1738
1748
  }), e();
1739
1749
  } catch (h) {
1740
1750
  P({
1741
1751
  id: "for-creating",
1742
1752
  title: "Failed",
1743
1753
  message: h.message,
1744
- color: "red"
1754
+ color: "red",
1755
+ autoClose: !0
1745
1756
  });
1746
1757
  }
1747
1758
  };
1748
1759
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", mb: 10, children: /* @__PURE__ */ a.jsxs("form", { onSubmit: i(s), children: [
1749
- /* @__PURE__ */ a.jsx(O, { name: "name", control: n, render: ({
1760
+ /* @__PURE__ */ a.jsx(R, { name: "name", control: n, render: ({
1750
1761
  field: l
1751
1762
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...l }) }),
1752
- /* @__PURE__ */ a.jsx(O, { name: "email", control: n, render: ({
1763
+ /* @__PURE__ */ a.jsx(R, { name: "email", control: n, render: ({
1753
1764
  field: l
1754
1765
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Email", ...l }) }),
1755
- /* @__PURE__ */ a.jsx(O, { name: "password", control: n, render: ({
1766
+ /* @__PURE__ */ a.jsx(R, { name: "password", control: n, render: ({
1756
1767
  field: l
1757
1768
  }) => /* @__PURE__ */ a.jsx(dt, { mb: t.spacing, size: t.size, required: !0, label: "Password", description: "Password must be at least 8 characters long", ...l }) }),
1758
- /* @__PURE__ */ a.jsx(O, { name: "role_id", control: n, render: ({
1769
+ /* @__PURE__ */ a.jsx(R, { name: "role_id", control: n, render: ({
1759
1770
  field: l
1760
1771
  }) => /* @__PURE__ */ a.jsx(Ft, { styles: t, ...l }) }),
1761
1772
  /* @__PURE__ */ a.jsx(z, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a.jsx(D, { type: "submit", size: t.button.size, children: "Save" }) })
@@ -1788,21 +1799,24 @@ function ia({
1788
1799
  id: "for-deleting",
1789
1800
  title: "Pending",
1790
1801
  message: "Deleting account...",
1791
- loading: !0
1802
+ loading: !0,
1803
+ autoClose: !1
1792
1804
  });
1793
1805
  try {
1794
1806
  await Z.account.delete(e), P({
1795
1807
  id: "for-deleting",
1796
1808
  title: "Successful",
1797
1809
  message: `Account [${t}] is deleted`,
1798
- color: "green"
1810
+ color: "green",
1811
+ autoClose: !0
1799
1812
  }), r();
1800
1813
  } catch (d) {
1801
1814
  P({
1802
1815
  id: "for-deleting",
1803
1816
  title: "Failed",
1804
1817
  message: d.message,
1805
- color: "red"
1818
+ color: "red",
1819
+ autoClose: !0
1806
1820
  });
1807
1821
  }
1808
1822
  }
@@ -1849,7 +1863,8 @@ function sa({
1849
1863
  id: "for-updating",
1850
1864
  title: "Pending",
1851
1865
  message: "Updating account...",
1852
- loading: !0
1866
+ loading: !0,
1867
+ autoClose: !1
1853
1868
  }), await Z.account.edit({
1854
1869
  id: e,
1855
1870
  name: u.trim(),
@@ -1861,29 +1876,31 @@ function sa({
1861
1876
  id: "for-updating",
1862
1877
  title: "Successful",
1863
1878
  message: "Account is updated",
1864
- color: "green"
1879
+ color: "green",
1880
+ autoClose: !0
1865
1881
  }), i();
1866
1882
  } catch (w) {
1867
1883
  P({
1868
1884
  id: "for-updating",
1869
1885
  title: "Failed",
1870
1886
  message: w.message,
1871
- color: "red"
1887
+ color: "red",
1888
+ autoClose: !0
1872
1889
  });
1873
1890
  }
1874
1891
  }, [h, c] = p(["reset_password", "new_password"]);
1875
1892
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", mb: 10, children: /* @__PURE__ */ a.jsxs("form", { onSubmit: d(f), children: [
1876
- /* @__PURE__ */ a.jsx(O, { name: "name", control: l, render: ({
1893
+ /* @__PURE__ */ a.jsx(R, { name: "name", control: l, render: ({
1877
1894
  field: u
1878
1895
  }) => /* @__PURE__ */ a.jsx(Q, { mb: s.spacing, size: s.size, required: !0, label: "Username", ...u }) }),
1879
- /* @__PURE__ */ a.jsx(O, { name: "email", control: l, render: ({
1896
+ /* @__PURE__ */ a.jsx(R, { name: "email", control: l, render: ({
1880
1897
  field: u
1881
1898
  }) => /* @__PURE__ */ a.jsx(Q, { mb: s.spacing, size: s.size, required: !0, label: "Email", ...u }) }),
1882
- /* @__PURE__ */ a.jsx(O, { name: "role_id", control: l, render: ({
1899
+ /* @__PURE__ */ a.jsx(R, { name: "role_id", control: l, render: ({
1883
1900
  field: u
1884
1901
  }) => /* @__PURE__ */ a.jsx(Ft, { styles: s, ...u }) }),
1885
1902
  /* @__PURE__ */ a.jsx(ct, { my: 20, variant: "dashed", label: "", labelPosition: "center" }),
1886
- /* @__PURE__ */ a.jsx(O, { name: "reset_password", control: l, render: ({
1903
+ /* @__PURE__ */ a.jsx(R, { name: "reset_password", control: l, render: ({
1887
1904
  field: u
1888
1905
  }) => /* @__PURE__ */ a.jsx(Qr, { mb: s.spacing, size: s.size, label: "Reset password", checked: u.value, onChange: (g) => u.onChange(g.currentTarget.checked), styles: {
1889
1906
  label: {
@@ -1891,7 +1908,7 @@ function sa({
1891
1908
  }
1892
1909
  } }) }),
1893
1910
  h && /* @__PURE__ */ a.jsx(
1894
- O,
1911
+ R,
1895
1912
  {
1896
1913
  name: "new_password",
1897
1914
  control: l,
@@ -2001,29 +2018,32 @@ function la({
2001
2018
  id: "for-login",
2002
2019
  title: "Pending",
2003
2020
  message: "Loggin in...",
2004
- loading: !0
2021
+ loading: !0,
2022
+ autoClose: !1
2005
2023
  });
2006
2024
  const d = await Z.account.login(s.trim(), l.trim());
2007
2025
  window.localStorage.setItem("token", d.token), P({
2008
2026
  id: "for-login",
2009
2027
  title: "Successful",
2010
2028
  message: "Logged in",
2011
- color: "green"
2029
+ color: "green",
2030
+ autoClose: !0
2012
2031
  }), e(d);
2013
2032
  } catch (d) {
2014
2033
  P({
2015
2034
  id: "for-login",
2016
2035
  title: "Login Failed",
2017
2036
  message: d.message,
2018
- color: "red"
2037
+ color: "red",
2038
+ autoClose: !0
2019
2039
  });
2020
2040
  }
2021
2041
  };
2022
2042
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: n(i), children: [
2023
- /* @__PURE__ */ a.jsx(O, { name: "name", control: r, render: ({
2043
+ /* @__PURE__ */ a.jsx(R, { name: "name", control: r, render: ({
2024
2044
  field: s
2025
2045
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...s }) }),
2026
- /* @__PURE__ */ a.jsx(O, { name: "password", control: r, render: ({
2046
+ /* @__PURE__ */ a.jsx(R, { name: "password", control: r, render: ({
2027
2047
  field: s
2028
2048
  }) => /* @__PURE__ */ a.jsx(dt, { mb: t.spacing, size: t.size, required: !0, label: "Password", ...s }) }),
2029
2049
  /* @__PURE__ */ a.jsx(z, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a.jsx(D, { type: "submit", size: t.button.size, children: "Submit" }) })
@@ -2067,7 +2087,8 @@ function ua({
2067
2087
  id: "for-creating",
2068
2088
  title: "Pending",
2069
2089
  message: "Adding API Key...",
2070
- loading: !0
2090
+ loading: !0,
2091
+ autoClose: !1
2071
2092
  });
2072
2093
  const {
2073
2094
  app_id: p,
@@ -2077,22 +2098,24 @@ function ua({
2077
2098
  id: "for-creating",
2078
2099
  title: "Successful",
2079
2100
  message: "API Key is added",
2080
- color: "green"
2101
+ color: "green",
2102
+ autoClose: !0
2081
2103
  }), e(p, f);
2082
2104
  } catch (p) {
2083
2105
  P({
2084
2106
  id: "for-creating",
2085
2107
  title: "Failed",
2086
2108
  message: p.message,
2087
- color: "red"
2109
+ color: "red",
2110
+ autoClose: !0
2088
2111
  });
2089
2112
  }
2090
2113
  };
2091
2114
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", mb: 10, children: /* @__PURE__ */ a.jsxs("form", { onSubmit: i(s), children: [
2092
- /* @__PURE__ */ a.jsx(O, { name: "name", control: n, render: ({
2115
+ /* @__PURE__ */ a.jsx(R, { name: "name", control: n, render: ({
2093
2116
  field: l
2094
2117
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...l }) }),
2095
- /* @__PURE__ */ a.jsx(O, { name: "role_id", control: n, render: ({
2118
+ /* @__PURE__ */ a.jsx(R, { name: "role_id", control: n, render: ({
2096
2119
  field: l
2097
2120
  }) => /* @__PURE__ */ a.jsx(Ft, { styles: t, ...l }) }),
2098
2121
  /* @__PURE__ */ a.jsx(z, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a.jsx(D, { type: "submit", size: t.button.size, children: "Save" }) })
@@ -2146,21 +2169,24 @@ function da({
2146
2169
  id: "for-deleting",
2147
2170
  title: "Pending",
2148
2171
  message: "Deleting API Key...",
2149
- loading: !0
2172
+ loading: !0,
2173
+ autoClose: !1
2150
2174
  });
2151
2175
  try {
2152
2176
  await Z.api_key.delete(e), P({
2153
2177
  id: "for-deleting",
2154
2178
  title: "Successful",
2155
2179
  message: `API Key [${t}] is deleted`,
2156
- color: "green"
2180
+ color: "green",
2181
+ autoClose: !0
2157
2182
  }), r();
2158
2183
  } catch (d) {
2159
2184
  P({
2160
2185
  id: "for-deleting",
2161
2186
  title: "Failed",
2162
2187
  message: d.message,
2163
- color: "red"
2188
+ color: "red",
2189
+ autoClose: !0
2164
2190
  });
2165
2191
  }
2166
2192
  }
@@ -2279,27 +2305,30 @@ function pa({
2279
2305
  id: "for-creating",
2280
2306
  title: "Pending",
2281
2307
  message: "Adding SQL Snippet...",
2282
- loading: !0
2308
+ loading: !0,
2309
+ autoClose: !1
2283
2310
  }), await Z.sql_snippet.create(s), P({
2284
2311
  id: "for-creating",
2285
2312
  title: "Successful",
2286
2313
  message: "SQL Snippet is added",
2287
- color: "green"
2314
+ color: "green",
2315
+ autoClose: !0
2288
2316
  }), e();
2289
2317
  } catch (l) {
2290
2318
  P({
2291
2319
  id: "for-creating",
2292
2320
  title: "Failed",
2293
2321
  message: l.message,
2294
- color: "red"
2322
+ color: "red",
2323
+ autoClose: !0
2295
2324
  });
2296
2325
  }
2297
2326
  };
2298
2327
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: n(i), children: [
2299
- /* @__PURE__ */ a.jsx(O, { name: "id", control: r, render: ({
2328
+ /* @__PURE__ */ a.jsx(R, { name: "id", control: r, render: ({
2300
2329
  field: s
2301
2330
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...s }) }),
2302
- /* @__PURE__ */ a.jsx(O, { name: "content", control: r, render: ({
2331
+ /* @__PURE__ */ a.jsx(R, { name: "content", control: r, render: ({
2303
2332
  field: s
2304
2333
  }) => /* @__PURE__ */ a.jsxs(Ke, { spacing: 4, children: [
2305
2334
  /* @__PURE__ */ a.jsx(ke, { size: 14, fw: 500, color: "#212529", sx: {
@@ -2344,27 +2373,30 @@ function ga({
2344
2373
  id: "for-updating",
2345
2374
  title: "Pending",
2346
2375
  message: "Updating SQL Snippet...",
2347
- loading: !0
2376
+ loading: !0,
2377
+ autoClose: !1
2348
2378
  }), await Z.sql_snippet.update(d), P({
2349
2379
  id: "for-updating",
2350
2380
  title: "Successful",
2351
2381
  message: "SQL Snippet is updated",
2352
- color: "green"
2382
+ color: "green",
2383
+ autoClose: !0
2353
2384
  }), e();
2354
2385
  } catch (p) {
2355
2386
  P({
2356
2387
  id: "for-updating",
2357
2388
  title: "Failed",
2358
2389
  message: p.message,
2359
- color: "red"
2390
+ color: "red",
2391
+ autoClose: !0
2360
2392
  });
2361
2393
  }
2362
2394
  };
2363
2395
  return /* @__PURE__ */ a.jsx(X, { mx: "auto", children: /* @__PURE__ */ a.jsxs("form", { onSubmit: s(l), children: [
2364
- /* @__PURE__ */ a.jsx(O, { name: "id", control: i, render: ({
2396
+ /* @__PURE__ */ a.jsx(R, { name: "id", control: i, render: ({
2365
2397
  field: d
2366
2398
  }) => /* @__PURE__ */ a.jsx(Q, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...d }) }),
2367
- /* @__PURE__ */ a.jsx(O, { name: "content", control: i, render: ({
2399
+ /* @__PURE__ */ a.jsx(R, { name: "content", control: i, render: ({
2368
2400
  field: d
2369
2401
  }) => /* @__PURE__ */ a.jsxs(Ke, { spacing: 4, children: [
2370
2402
  /* @__PURE__ */ a.jsx(ke, { size: 14, fw: 500, color: "#212529", sx: {
@@ -2398,7 +2430,7 @@ function ha({
2398
2430
  * @namespace
2399
2431
  * @public
2400
2432
  */
2401
- var Ot = function() {
2433
+ var Rt = function() {
2402
2434
  var e = /(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i, t = 0, r = {}, n = {
2403
2435
  /**
2404
2436
  * A namespace for utility methods.
@@ -2894,8 +2926,8 @@ var Ot = function() {
2894
2926
  return u;
2895
2927
  }
2896
2928
  return n;
2897
- }(), b = Ot;
2898
- Ot.default = Ot;
2929
+ }(), b = Rt;
2930
+ Rt.default = Rt;
2899
2931
  b.languages.markup = {
2900
2932
  comment: {
2901
2933
  pattern: /<!--(?:(?!<!--)[\s\S])*?-->/,
@@ -5815,14 +5847,14 @@ var Ta = lr((e, { colorScheme: t, native: r, maxLineSize: n, radius: i }) => ({
5815
5847
  }
5816
5848
  }));
5817
5849
  const ja = Ta;
5818
- var Ra = Object.defineProperty, Oa = Object.defineProperties, Ca = Object.getOwnPropertyDescriptors, ot = Object.getOwnPropertySymbols, yr = Object.prototype.hasOwnProperty, Sr = Object.prototype.propertyIsEnumerable, ir = (e, t, r) => t in e ? Ra(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, Ie = (e, t) => {
5850
+ var Ca = Object.defineProperty, Ra = Object.defineProperties, Oa = Object.getOwnPropertyDescriptors, ot = Object.getOwnPropertySymbols, yr = Object.prototype.hasOwnProperty, Sr = Object.prototype.propertyIsEnumerable, ir = (e, t, r) => t in e ? Ca(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, Ie = (e, t) => {
5819
5851
  for (var r in t || (t = {}))
5820
5852
  yr.call(t, r) && ir(e, r, t[r]);
5821
5853
  if (ot)
5822
5854
  for (var r of ot(t))
5823
5855
  Sr.call(t, r) && ir(e, r, t[r]);
5824
5856
  return e;
5825
- }, qe = (e, t) => Oa(e, Ca(t)), Da = (e, t) => {
5857
+ }, qe = (e, t) => Ra(e, Oa(t)), Da = (e, t) => {
5826
5858
  var r = {};
5827
5859
  for (var n in e)
5828
5860
  yr.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
@@ -5938,11 +5970,11 @@ const Ia = {
5938
5970
  }, ((be = u[ie]) == null ? void 0 : be.label) || ie), /* @__PURE__ */ F.createElement("div", {
5939
5971
  className: te.lineContent
5940
5972
  }, W.map((Me, je) => {
5941
- var Re, _e;
5942
- const Oe = ae({ token: Me, key: je });
5943
- return /* @__PURE__ */ F.createElement("span", qe(Ie({}, Oe), {
5944
- style: qe(Ie({}, Oe.style), {
5945
- color: Ee ? N.fn.themeColor((Re = u[ie]) == null ? void 0 : Re.color, $ === "dark" ? 5 : 8) : (_e = Oe == null ? void 0 : Oe.style) == null ? void 0 : _e.color
5973
+ var Ce, _e;
5974
+ const Re = ae({ token: Me, key: je });
5975
+ return /* @__PURE__ */ F.createElement("span", qe(Ie({}, Re), {
5976
+ style: qe(Ie({}, Re.style), {
5977
+ color: Ee ? N.fn.themeColor((Ce = u[ie]) == null ? void 0 : Ce.color, $ === "dark" ? 5 : 8) : (_e = Re == null ? void 0 : Re.style) == null ? void 0 : _e.color
5946
5978
  })
5947
5979
  }));
5948
5980
  })));
@@ -6082,21 +6114,24 @@ function Ua({
6082
6114
  id: "for-deleting",
6083
6115
  title: "Pending",
6084
6116
  message: "Deleting SQL Snippet...",
6085
- loading: !0
6117
+ loading: !0,
6118
+ autoClose: !1
6086
6119
  });
6087
6120
  try {
6088
6121
  await Z.sql_snippet.delete(e), P({
6089
6122
  id: "for-deleting",
6090
6123
  title: "Successful",
6091
6124
  message: `SQL Snippet [${e}] is deleted`,
6092
- color: "green"
6125
+ color: "green",
6126
+ autoClose: !0
6093
6127
  }), t();
6094
6128
  } catch (l) {
6095
6129
  P({
6096
6130
  id: "for-deleting",
6097
6131
  title: "Failed",
6098
6132
  message: l.message,
6099
- color: "red"
6133
+ color: "red",
6134
+ autoClose: !0
6100
6135
  });
6101
6136
  }
6102
6137
  }
@@ -6180,7 +6215,7 @@ function ii({
6180
6215
  ] })
6181
6216
  ] });
6182
6217
  }
6183
- const si = () => import("./package-10c53529.mjs").then(({
6218
+ const si = () => import("./package-10cf4bd1.mjs").then(({
6184
6219
  version: e
6185
6220
  }) => (console.log(`[@devtable/dashboard] version: ${e}`), e));
6186
6221
  export {