@devtable/settings-form 10.44.1 → 10.44.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
1
  import K, { useEffect as yt, forwardRef as Je, useState as Ht, Component as kr } from "react";
2
- import { Box as se, TextInput as ue, Divider as et, Group as Q, NumberInput as Tr, PasswordInput as tt, Button as V, Modal as Ae, Stack as je, Alert as Rr, SegmentedControl as xr, Tooltip as Ke, Text as Re, ActionIcon as vt, LoadingOverlay as rt, Table as nt, Select as Or, Switch as Cr, createStyles as qt, rem as Me, useComponentDefaultProps as Ir, useMantineTheme as Dr, ScrollArea as Yt, Tabs as at, HoverCard as gt } from "@mantine/core";
3
- import { showNotification as be, updateNotification as J } from "@mantine/notifications";
2
+ import { Box as le, TextInput as ue, Divider as et, Group as Q, NumberInput as Tr, PasswordInput as tt, Button as Y, Modal as Ae, Stack as je, Alert as Rr, SegmentedControl as xr, Tooltip as Ke, Text as Re, ActionIcon as vt, LoadingOverlay as rt, Table as nt, Select as Or, Switch as Cr, createStyles as qt, rem as Me, useComponentDefaultProps as Ir, useMantineTheme as Dr, ScrollArea as Yt, Tabs as at, HoverCard as gt } from "@mantine/core";
3
+ import { showNotification as ye, updateNotification as J } from "@mantine/notifications";
4
4
  import { Recycle as Lr, AlertCircle as Fr, PlaylistAdd as it, Trash as ot, Edit as Nr } from "tabler-icons-react";
5
5
  import * as $r from "crypto-js";
6
6
  import zr from "axios";
7
- import { useForm as Ee, Controller as q } from "react-hook-form";
7
+ import { useForm as Ee, Controller as H } from "react-hook-form";
8
8
  import { useBoolean as Pr, useRequest as xe } from "ahooks";
9
9
  import Vt, { loader as ft } from "@monaco-editor/react";
10
10
  import { useModals as Ge, closeAllModals as Mr } from "@mantine/modals";
@@ -70,10 +70,10 @@ function Wr() {
70
70
  {
71
71
  for (var v = arguments.length, T = new Array(v > 1 ? v - 1 : 0), D = 1; D < v; D++)
72
72
  T[D - 1] = arguments[D];
73
- $("error", i, T);
73
+ N("error", i, T);
74
74
  }
75
75
  }
76
- function $(i, v, T) {
76
+ function N(i, v, T) {
77
77
  {
78
78
  var D = A.ReactDebugCurrentFrame, U = D.getStackAddendum();
79
79
  U !== "" && (v += "%s", T = T.concat([U]));
@@ -83,10 +83,10 @@ function Wr() {
83
83
  W.unshift("Warning: " + v), Function.prototype.apply.call(console[i], console, W);
84
84
  }
85
85
  }
86
- var M = !1, te = !1, X = !1, Y = !1, Z = !1, F;
86
+ var M = !1, re = !1, X = !1, q = !1, Z = !1, F;
87
87
  F = Symbol.for("react.module.reference");
88
88
  function L(i) {
89
- return !!(typeof i == "string" || typeof i == "function" || i === n || i === o || Z || i === s || i === f || i === b || Y || i === g || M || te || X || typeof i == "object" && i !== null && (i.$$typeof === c || i.$$typeof === u || i.$$typeof === l || i.$$typeof === p || i.$$typeof === d || // This needs to include all possible module reference object
89
+ return !!(typeof i == "string" || typeof i == "function" || i === n || i === o || Z || i === s || i === f || i === b || q || i === g || M || re || X || typeof i == "object" && i !== null && (i.$$typeof === c || i.$$typeof === u || i.$$typeof === l || i.$$typeof === p || i.$$typeof === d || // This needs to include all possible module reference object
90
90
  // types supported by any Flight configuration anywhere since
91
91
  // we don't know which Flight build this will end up being used
92
92
  // with.
@@ -102,7 +102,7 @@ function Wr() {
102
102
  function ee(i) {
103
103
  return i.displayName || "Context";
104
104
  }
105
- function R(i) {
105
+ function x(i) {
106
106
  if (i == null)
107
107
  return null;
108
108
  if (typeof i.tag == "number" && k("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof i == "function")
@@ -135,11 +135,11 @@ function Wr() {
135
135
  return B(i, i.render, "ForwardRef");
136
136
  case u:
137
137
  var D = i.displayName || null;
138
- return D !== null ? D : R(i.type) || "Memo";
138
+ return D !== null ? D : x(i.type) || "Memo";
139
139
  case c: {
140
140
  var U = i, W = U._payload, P = U._init;
141
141
  try {
142
- return R(P(W));
142
+ return x(P(W));
143
143
  } catch {
144
144
  return null;
145
145
  }
@@ -147,14 +147,14 @@ function Wr() {
147
147
  }
148
148
  return null;
149
149
  }
150
- var E = Object.assign, S = 0, x, w, O, I, N, H, j;
150
+ var E = Object.assign, S = 0, R, w, O, I, $, j, V;
151
151
  function G() {
152
152
  }
153
153
  G.__reactDisabledLog = !0;
154
- function le() {
154
+ function te() {
155
155
  {
156
156
  if (S === 0) {
157
- x = console.log, w = console.info, O = console.warn, I = console.error, N = console.group, H = console.groupCollapsed, j = console.groupEnd;
157
+ R = console.log, w = console.info, O = console.warn, I = console.error, $ = console.group, j = console.groupCollapsed, V = console.groupEnd;
158
158
  var i = {
159
159
  configurable: !0,
160
160
  enumerable: !0,
@@ -174,7 +174,7 @@ function Wr() {
174
174
  S++;
175
175
  }
176
176
  }
177
- function ce() {
177
+ function ge() {
178
178
  {
179
179
  if (S--, S === 0) {
180
180
  var i = {
@@ -184,7 +184,7 @@ function Wr() {
184
184
  };
185
185
  Object.defineProperties(console, {
186
186
  log: E({}, i, {
187
- value: x
187
+ value: R
188
188
  }),
189
189
  info: E({}, i, {
190
190
  value: w
@@ -196,40 +196,40 @@ function Wr() {
196
196
  value: I
197
197
  }),
198
198
  group: E({}, i, {
199
- value: N
199
+ value: $
200
200
  }),
201
201
  groupCollapsed: E({}, i, {
202
- value: H
202
+ value: j
203
203
  }),
204
204
  groupEnd: E({}, i, {
205
- value: j
205
+ value: V
206
206
  })
207
207
  });
208
208
  }
209
209
  S < 0 && k("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
210
210
  }
211
211
  }
212
- var pe = A.ReactCurrentDispatcher, ye;
212
+ var ce = A.ReactCurrentDispatcher, ve;
213
213
  function fe(i, v, T) {
214
214
  {
215
- if (ye === void 0)
215
+ if (ve === void 0)
216
216
  try {
217
217
  throw Error();
218
218
  } catch (U) {
219
219
  var D = U.stack.trim().match(/\n( *(at )?)/);
220
- ye = D && D[1] || "";
220
+ ve = D && D[1] || "";
221
221
  }
222
222
  return `
223
- ` + ye + i;
223
+ ` + ve + i;
224
224
  }
225
225
  }
226
- var re = !1, de;
226
+ var ne = !1, de;
227
227
  {
228
- var ve = typeof WeakMap == "function" ? WeakMap : Map;
229
- de = new ve();
228
+ var me = typeof WeakMap == "function" ? WeakMap : Map;
229
+ de = new me();
230
230
  }
231
231
  function Te(i, v) {
232
- if (!i || re)
232
+ if (!i || ne)
233
233
  return "";
234
234
  {
235
235
  var T = de.get(i);
@@ -237,11 +237,11 @@ function Wr() {
237
237
  return T;
238
238
  }
239
239
  var D;
240
- re = !0;
240
+ ne = !0;
241
241
  var U = Error.prepareStackTrace;
242
242
  Error.prepareStackTrace = void 0;
243
243
  var W;
244
- W = pe.current, pe.current = null, le();
244
+ W = ce.current, ce.current = null, te();
245
245
  try {
246
246
  if (v) {
247
247
  var P = function() {
@@ -277,24 +277,24 @@ function Wr() {
277
277
  } catch (we) {
278
278
  if (we && D && typeof we.stack == "string") {
279
279
  for (var z = we.stack.split(`
280
- `), ge = D.stack.split(`
281
- `), ne = z.length - 1, ie = ge.length - 1; ne >= 1 && ie >= 0 && z[ne] !== ge[ie]; )
282
- ie--;
283
- for (; ne >= 1 && ie >= 0; ne--, ie--)
284
- if (z[ne] !== ge[ie]) {
285
- if (ne !== 1 || ie !== 1)
280
+ `), pe = D.stack.split(`
281
+ `), ae = z.length - 1, oe = pe.length - 1; ae >= 1 && oe >= 0 && z[ae] !== pe[oe]; )
282
+ oe--;
283
+ for (; ae >= 1 && oe >= 0; ae--, oe--)
284
+ if (z[ae] !== pe[oe]) {
285
+ if (ae !== 1 || oe !== 1)
286
286
  do
287
- if (ne--, ie--, ie < 0 || z[ne] !== ge[ie]) {
288
- var me = `
289
- ` + z[ne].replace(" at new ", " at ");
290
- return i.displayName && me.includes("<anonymous>") && (me = me.replace("<anonymous>", i.displayName)), typeof i == "function" && de.set(i, me), me;
287
+ if (ae--, oe--, oe < 0 || z[ae] !== pe[oe]) {
288
+ var be = `
289
+ ` + z[ae].replace(" at new ", " at ");
290
+ return i.displayName && be.includes("<anonymous>") && (be = be.replace("<anonymous>", i.displayName)), typeof i == "function" && de.set(i, be), be;
291
291
  }
292
- while (ne >= 1 && ie >= 0);
292
+ while (ae >= 1 && oe >= 0);
293
293
  break;
294
294
  }
295
295
  }
296
296
  } finally {
297
- re = !1, pe.current = W, ce(), Error.prepareStackTrace = U;
297
+ ne = !1, ce.current = W, ge(), Error.prepareStackTrace = U;
298
298
  }
299
299
  var Ce = i ? i.displayName || i.name : "", Ft = Ce ? fe(Ce) : "";
300
300
  return typeof i == "function" && de.set(i, Ft), Ft;
@@ -351,12 +351,12 @@ function Wr() {
351
351
  var z = void 0;
352
352
  try {
353
353
  if (typeof i[P] != "function") {
354
- var ge = Error((D || "React class") + ": " + T + " type `" + P + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[P] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
355
- throw ge.name = "Invariant Violation", ge;
354
+ var pe = Error((D || "React class") + ": " + T + " type `" + P + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[P] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
355
+ throw pe.name = "Invariant Violation", pe;
356
356
  }
357
357
  z = i[P](v, P, D, T, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
358
- } catch (ne) {
359
- z = ne;
358
+ } catch (ae) {
359
+ z = ae;
360
360
  }
361
361
  z && !(z instanceof Error) && (Ve(U), k("%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).", D || "React class", T, P, typeof z), Ve(null)), z instanceof Error && !(z.message in Et) && (Et[z.message] = !0, Ve(U), k("Failed %s type: %s", T, z.message), Ve(null));
362
362
  }
@@ -411,8 +411,8 @@ function Wr() {
411
411
  }
412
412
  function pr(i, v) {
413
413
  if (typeof i.ref == "string" && Le.current && v && Le.current.stateNode !== v) {
414
- var T = R(Le.current.type);
415
- ut[T] || (k('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', R(Le.current.type), i.ref), ut[T] = !0);
414
+ var T = x(Le.current.type);
415
+ ut[T] || (k('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', x(Le.current.type), i.ref), ut[T] = !0);
416
416
  }
417
417
  }
418
418
  function gr(i, v) {
@@ -468,20 +468,20 @@ function Wr() {
468
468
  };
469
469
  function mr(i, v, T, D, U) {
470
470
  {
471
- var W, P = {}, z = null, ge = null;
472
- T !== void 0 && (kt(T), z = "" + T), dr(v) && (kt(v.key), z = "" + v.key), cr(v) && (ge = v.ref, pr(v, U));
471
+ var W, P = {}, z = null, pe = null;
472
+ T !== void 0 && (kt(T), z = "" + T), dr(v) && (kt(v.key), z = "" + v.key), cr(v) && (pe = v.ref, pr(v, U));
473
473
  for (W in v)
474
474
  Ye.call(v, W) && !ur.hasOwnProperty(W) && (P[W] = v[W]);
475
475
  if (i && i.defaultProps) {
476
- var ne = i.defaultProps;
477
- for (W in ne)
478
- P[W] === void 0 && (P[W] = ne[W]);
476
+ var ae = i.defaultProps;
477
+ for (W in ae)
478
+ P[W] === void 0 && (P[W] = ae[W]);
479
479
  }
480
- if (z || ge) {
481
- var ie = typeof i == "function" ? i.displayName || i.name || "Unknown" : i;
482
- z && gr(P, ie), ge && fr(P, ie);
480
+ if (z || pe) {
481
+ var oe = typeof i == "function" ? i.displayName || i.name || "Unknown" : i;
482
+ z && gr(P, oe), pe && fr(P, oe);
483
483
  }
484
- return hr(i, z, ge, U, D, Le.current, P);
484
+ return hr(i, z, pe, U, D, Le.current, P);
485
485
  }
486
486
  }
487
487
  var ct = A.ReactCurrentOwner, xt = A.ReactDebugCurrentFrame;
@@ -500,7 +500,7 @@ function Wr() {
500
500
  function Ot() {
501
501
  {
502
502
  if (ct.current) {
503
- var i = R(ct.current.type);
503
+ var i = x(ct.current.type);
504
504
  if (i)
505
505
  return `
506
506
 
@@ -543,7 +543,7 @@ Check the top-level render call using <` + T + ">.");
543
543
  return;
544
544
  Ct[T] = !0;
545
545
  var D = "";
546
- i && i._owner && i._owner !== ct.current && (D = " It was passed a child from " + R(i._owner.type) + "."), Oe(i), k('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', T, D), Oe(null);
546
+ i && i._owner && i._owner !== ct.current && (D = " It was passed a child from " + x(i._owner.type) + "."), Oe(i), k('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', T, D), Oe(null);
547
547
  }
548
548
  }
549
549
  function Dt(i, v) {
@@ -580,11 +580,11 @@ Check the top-level render call using <` + T + ">.");
580
580
  else
581
581
  return;
582
582
  if (T) {
583
- var D = R(v);
583
+ var D = x(v);
584
584
  ir(T, i.props, "prop", D, i);
585
585
  } else if (v.PropTypes !== void 0 && !dt) {
586
586
  dt = !0;
587
- var U = R(v);
587
+ var U = x(v);
588
588
  k("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", U || "Unknown");
589
589
  }
590
590
  typeof v.getDefaultProps == "function" && !v.getDefaultProps.isReactClassApproved && k("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
@@ -608,28 +608,28 @@ Check the top-level render call using <` + T + ">.");
608
608
  if (!P) {
609
609
  var z = "";
610
610
  (i === void 0 || typeof i == "object" && i !== null && Object.keys(i).length === 0) && (z += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
611
- var ge = br(U);
612
- ge ? z += ge : z += Ot();
613
- var ne;
614
- i === null ? ne = "null" : lt(i) ? ne = "array" : i !== void 0 && i.$$typeof === t ? (ne = "<" + (R(i.type) || "Unknown") + " />", z = " Did you accidentally export a JSX literal instead of a component?") : ne = typeof i, k("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ne, z);
611
+ var pe = br(U);
612
+ pe ? z += pe : z += Ot();
613
+ var ae;
614
+ i === null ? ae = "null" : lt(i) ? ae = "array" : i !== void 0 && i.$$typeof === t ? (ae = "<" + (x(i.type) || "Unknown") + " />", z = " Did you accidentally export a JSX literal instead of a component?") : ae = typeof i, k("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ae, z);
615
615
  }
616
- var ie = mr(i, v, T, U, W);
617
- if (ie == null)
618
- return ie;
616
+ var oe = mr(i, v, T, U, W);
617
+ if (oe == null)
618
+ return oe;
619
619
  if (P) {
620
- var me = v.children;
621
- if (me !== void 0)
620
+ var be = v.children;
621
+ if (be !== void 0)
622
622
  if (D)
623
- if (lt(me)) {
624
- for (var Ce = 0; Ce < me.length; Ce++)
625
- Dt(me[Ce], i);
626
- Object.freeze && Object.freeze(me);
623
+ if (lt(be)) {
624
+ for (var Ce = 0; Ce < be.length; Ce++)
625
+ Dt(be[Ce], i);
626
+ Object.freeze && Object.freeze(be);
627
627
  } else
628
628
  k("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
629
629
  else
630
- Dt(me, i);
630
+ Dt(be, i);
631
631
  }
632
- return i === n ? Sr(ie) : vr(ie), ie;
632
+ return i === n ? Sr(oe) : vr(oe), oe;
633
633
  }
634
634
  }
635
635
  function wr(i, v, T) {
@@ -743,7 +743,7 @@ class Qr {
743
743
  return this.getRequest("PUT", t);
744
744
  }
745
745
  }
746
- const Pe = new Xr(), Jr = new Qr(Pe), ae = Jr;
746
+ const Pe = new Xr(), Jr = new Qr(Pe), ie = Jr;
747
747
  function Ue(e) {
748
748
  Pe.baseURL !== e.apiBaseURL && (Pe.baseURL = e.apiBaseURL), e.app_id && (Pe.app_id = e.app_id), e.app_secret && (Pe.app_secret = e.app_secret);
749
749
  }
@@ -753,9 +753,9 @@ const en = {
753
753
  name: e,
754
754
  password: t
755
755
  };
756
- return await ae.post()("/account/login", r, {});
756
+ return await ie.post()("/account/login", r, {});
757
757
  },
758
- list: async () => await ae.post()("/account/list", {
758
+ list: async () => await ie.post()("/account/list", {
759
759
  filter: {},
760
760
  sort: [{
761
761
  field: "name",
@@ -769,7 +769,7 @@ const en = {
769
769
  /**
770
770
  * get current account
771
771
  */
772
- get: async () => await ae.get()("/account/get", {}, {}),
772
+ get: async () => await ie.get()("/account/get", {}, {}),
773
773
  /**
774
774
  * update current account
775
775
  */
@@ -778,7 +778,7 @@ const en = {
778
778
  name: e.trim(),
779
779
  email: t.trim()
780
780
  };
781
- return await ae.put()("/account/update", r, {});
781
+ return await ie.put()("/account/update", r, {});
782
782
  },
783
783
  /**
784
784
  * change current account's password
@@ -788,23 +788,23 @@ const en = {
788
788
  old_password: e.trim(),
789
789
  new_password: t.trim()
790
790
  };
791
- return await ae.post()("/account/changepassword", r, {});
791
+ return await ie.post()("/account/changepassword", r, {});
792
792
  },
793
- create: async (e, t, r, n) => await ae.post()("/account/create", {
793
+ create: async (e, t, r, n) => await ie.post()("/account/create", {
794
794
  name: e.trim(),
795
795
  email: t.trim(),
796
796
  password: r.trim(),
797
797
  role_id: n
798
798
  }, {}),
799
- edit: async (e) => (e.reset_password || (e.new_password = void 0), await ae.put()("/account/edit", e, {})),
799
+ edit: async (e) => (e.reset_password || (e.new_password = void 0), await ie.put()("/account/edit", e, {})),
800
800
  delete: async (e) => {
801
801
  if (e)
802
- return ae.post()("/account/delete", {
802
+ return ie.post()("/account/delete", {
803
803
  id: e
804
804
  }, {});
805
805
  }
806
806
  }, tn = {
807
- list: async () => await ae.post()("/api/key/list", {
807
+ list: async () => await ie.post()("/api/key/list", {
808
808
  filter: {
809
809
  search: ""
810
810
  },
@@ -817,18 +817,18 @@ const en = {
817
817
  pagesize: 100
818
818
  }
819
819
  }, {}),
820
- create: async (e, t) => ae.post()("/api/key/create", {
820
+ create: async (e, t) => ie.post()("/api/key/create", {
821
821
  name: e,
822
822
  role_id: t
823
823
  }, {}),
824
824
  delete: async (e) => {
825
825
  if (e)
826
- return ae.post()("/api/key/delete", {
826
+ return ie.post()("/api/key/delete", {
827
827
  id: e
828
828
  }, {});
829
829
  }
830
830
  }, rn = {
831
- list: async () => await ae.post()("/datasource/list", {
831
+ list: async () => await ie.post()("/datasource/list", {
832
832
  filter: {},
833
833
  sort: [{
834
834
  field: "create_time",
@@ -839,22 +839,22 @@ const en = {
839
839
  pagesize: 100
840
840
  }
841
841
  }, {}),
842
- create: async (e, t, r) => await ae.post()("/datasource/create", {
842
+ create: async (e, t, r) => await ie.post()("/datasource/create", {
843
843
  type: e,
844
844
  key: t,
845
845
  config: r
846
846
  }, {}),
847
- update: async (e, t) => await ae.put()("/datasource/update", {
847
+ update: async (e, t) => await ie.put()("/datasource/update", {
848
848
  id: e,
849
849
  config: t
850
850
  }, {}),
851
851
  delete: async (e) => {
852
- await ae.post()("/datasource/delete", {
852
+ await ie.post()("/datasource/delete", {
853
853
  id: e
854
854
  }, {});
855
855
  }
856
856
  }, nn = {
857
- list: async () => await ae.get()("/role/list", {}, {})
857
+ list: async () => await ie.get()("/role/list", {}, {})
858
858
  };
859
859
  var mt = {}, an = {
860
860
  get exports() {
@@ -868,62 +868,62 @@ var mt = {}, an = {
868
868
  (function(r, n) {
869
869
  e.exports = n();
870
870
  })(qr, function() {
871
- var r = 1e3, n = 6e4, s = 36e5, o = "millisecond", l = "second", p = "minute", d = "hour", f = "day", b = "week", u = "month", c = "quarter", g = "year", y = "date", h = "Invalid Date", _ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, A = /\[([^\]]+)]|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, k = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(R) {
872
- var E = ["th", "st", "nd", "rd"], S = R % 100;
873
- return "[" + R + (E[(S - 20) % 10] || E[S] || E[0]) + "]";
874
- } }, $ = function(R, E, S) {
875
- var x = String(R);
876
- return !x || x.length >= E ? R : "" + Array(E + 1 - x.length).join(S) + R;
877
- }, M = { s: $, z: function(R) {
878
- var E = -R.utcOffset(), S = Math.abs(E), x = Math.floor(S / 60), w = S % 60;
879
- return (E <= 0 ? "+" : "-") + $(x, 2, "0") + ":" + $(w, 2, "0");
880
- }, m: function R(E, S) {
871
+ var r = 1e3, n = 6e4, s = 36e5, o = "millisecond", l = "second", p = "minute", d = "hour", f = "day", b = "week", u = "month", c = "quarter", g = "year", y = "date", h = "Invalid Date", _ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, A = /\[([^\]]+)]|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, k = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(x) {
872
+ var E = ["th", "st", "nd", "rd"], S = x % 100;
873
+ return "[" + x + (E[(S - 20) % 10] || E[S] || E[0]) + "]";
874
+ } }, N = function(x, E, S) {
875
+ var R = String(x);
876
+ return !R || R.length >= E ? x : "" + Array(E + 1 - R.length).join(S) + x;
877
+ }, M = { s: N, z: function(x) {
878
+ var E = -x.utcOffset(), S = Math.abs(E), R = Math.floor(S / 60), w = S % 60;
879
+ return (E <= 0 ? "+" : "-") + N(R, 2, "0") + ":" + N(w, 2, "0");
880
+ }, m: function x(E, S) {
881
881
  if (E.date() < S.date())
882
- return -R(S, E);
883
- var x = 12 * (S.year() - E.year()) + (S.month() - E.month()), w = E.clone().add(x, u), O = S - w < 0, I = E.clone().add(x + (O ? -1 : 1), u);
884
- return +(-(x + (S - w) / (O ? w - I : I - w)) || 0);
885
- }, a: function(R) {
886
- return R < 0 ? Math.ceil(R) || 0 : Math.floor(R);
887
- }, p: function(R) {
888
- return { M: u, y: g, w: b, d: f, D: y, h: d, m: p, s: l, ms: o, Q: c }[R] || String(R || "").toLowerCase().replace(/s$/, "");
889
- }, u: function(R) {
890
- return R === void 0;
891
- } }, te = "en", X = {};
892
- X[te] = k;
893
- var Y = function(R) {
894
- return R instanceof B;
895
- }, Z = function R(E, S, x) {
882
+ return -x(S, E);
883
+ var R = 12 * (S.year() - E.year()) + (S.month() - E.month()), w = E.clone().add(R, u), O = S - w < 0, I = E.clone().add(R + (O ? -1 : 1), u);
884
+ return +(-(R + (S - w) / (O ? w - I : I - w)) || 0);
885
+ }, a: function(x) {
886
+ return x < 0 ? Math.ceil(x) || 0 : Math.floor(x);
887
+ }, p: function(x) {
888
+ return { M: u, y: g, w: b, d: f, D: y, h: d, m: p, s: l, ms: o, Q: c }[x] || String(x || "").toLowerCase().replace(/s$/, "");
889
+ }, u: function(x) {
890
+ return x === void 0;
891
+ } }, re = "en", X = {};
892
+ X[re] = k;
893
+ var q = function(x) {
894
+ return x instanceof B;
895
+ }, Z = function x(E, S, R) {
896
896
  var w;
897
897
  if (!E)
898
- return te;
898
+ return re;
899
899
  if (typeof E == "string") {
900
900
  var O = E.toLowerCase();
901
901
  X[O] && (w = O), S && (X[O] = S, w = O);
902
902
  var I = E.split("-");
903
903
  if (!w && I.length > 1)
904
- return R(I[0]);
904
+ return x(I[0]);
905
905
  } else {
906
- var N = E.name;
907
- X[N] = E, w = N;
906
+ var $ = E.name;
907
+ X[$] = E, w = $;
908
908
  }
909
- return !x && w && (te = w), w || !x && te;
910
- }, F = function(R, E) {
911
- if (Y(R))
912
- return R.clone();
909
+ return !R && w && (re = w), w || !R && re;
910
+ }, F = function(x, E) {
911
+ if (q(x))
912
+ return x.clone();
913
913
  var S = typeof E == "object" ? E : {};
914
- return S.date = R, S.args = arguments, new B(S);
914
+ return S.date = x, S.args = arguments, new B(S);
915
915
  }, L = M;
916
- L.l = Z, L.i = Y, L.w = function(R, E) {
917
- return F(R, { locale: E.$L, utc: E.$u, x: E.$x, $offset: E.$offset });
916
+ L.l = Z, L.i = q, L.w = function(x, E) {
917
+ return F(x, { locale: E.$L, utc: E.$u, x: E.$x, $offset: E.$offset });
918
918
  };
919
919
  var B = function() {
920
- function R(S) {
920
+ function x(S) {
921
921
  this.$L = Z(S.locale, null, !0), this.parse(S);
922
922
  }
923
- var E = R.prototype;
923
+ var E = x.prototype;
924
924
  return E.parse = function(S) {
925
- this.$d = function(x) {
926
- var w = x.date, O = x.utc;
925
+ this.$d = function(R) {
926
+ var w = R.date, O = R.utc;
927
927
  if (w === null)
928
928
  return /* @__PURE__ */ new Date(NaN);
929
929
  if (L.u(w))
@@ -933,8 +933,8 @@ var mt = {}, an = {
933
933
  if (typeof w == "string" && !/Z$/i.test(w)) {
934
934
  var I = w.match(_);
935
935
  if (I) {
936
- var N = I[2] - 1 || 0, H = (I[7] || "0").substring(0, 3);
937
- return O ? new Date(Date.UTC(I[1], N, I[3] || 1, I[4] || 0, I[5] || 0, I[6] || 0, H)) : new Date(I[1], N, I[3] || 1, I[4] || 0, I[5] || 0, I[6] || 0, H);
936
+ var $ = I[2] - 1 || 0, j = (I[7] || "0").substring(0, 3);
937
+ return O ? new Date(Date.UTC(I[1], $, I[3] || 1, I[4] || 0, I[5] || 0, I[6] || 0, j)) : new Date(I[1], $, I[3] || 1, I[4] || 0, I[5] || 0, I[6] || 0, j);
938
938
  }
939
939
  }
940
940
  return new Date(w);
@@ -946,107 +946,189 @@ var mt = {}, an = {
946
946
  return L;
947
947
  }, E.isValid = function() {
948
948
  return this.$d.toString() !== h;
949
- }, E.isSame = function(S, x) {
949
+ }, E.isSame = function(S, R) {
950
950
  var w = F(S);
951
- return this.startOf(x) <= w && w <= this.endOf(x);
952
- }, E.isAfter = function(S, x) {
953
- return F(S) < this.startOf(x);
954
- }, E.isBefore = function(S, x) {
955
- return this.endOf(x) < F(S);
956
- }, E.$g = function(S, x, w) {
957
- return L.u(S) ? this[x] : this.set(w, S);
951
+ return this.startOf(R) <= w && w <= this.endOf(R);
952
+ }, E.isAfter = function(S, R) {
953
+ return F(S) < this.startOf(R);
954
+ }, E.isBefore = function(S, R) {
955
+ return this.endOf(R) < F(S);
956
+ }, E.$g = function(S, R, w) {
957
+ return L.u(S) ? this[R] : this.set(w, S);
958
958
  }, E.unix = function() {
959
959
  return Math.floor(this.valueOf() / 1e3);
960
960
  }, E.valueOf = function() {
961
961
  return this.$d.getTime();
962
- }, E.startOf = function(S, x) {
963
- var w = this, O = !!L.u(x) || x, I = L.p(S), N = function(fe, re) {
964
- var de = L.w(w.$u ? Date.UTC(w.$y, re, fe) : new Date(w.$y, re, fe), w);
962
+ }, E.startOf = function(S, R) {
963
+ var w = this, O = !!L.u(R) || R, I = L.p(S), $ = function(fe, ne) {
964
+ var de = L.w(w.$u ? Date.UTC(w.$y, ne, fe) : new Date(w.$y, ne, fe), w);
965
965
  return O ? de : de.endOf(f);
966
- }, H = function(fe, re) {
967
- return L.w(w.toDate()[fe].apply(w.toDate("s"), (O ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(re)), w);
968
- }, j = this.$W, G = this.$M, le = this.$D, ce = "set" + (this.$u ? "UTC" : "");
966
+ }, j = function(fe, ne) {
967
+ return L.w(w.toDate()[fe].apply(w.toDate("s"), (O ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(ne)), w);
968
+ }, V = this.$W, G = this.$M, te = this.$D, ge = "set" + (this.$u ? "UTC" : "");
969
969
  switch (I) {
970
970
  case g:
971
- return O ? N(1, 0) : N(31, 11);
971
+ return O ? $(1, 0) : $(31, 11);
972
972
  case u:
973
- return O ? N(1, G) : N(0, G + 1);
973
+ return O ? $(1, G) : $(0, G + 1);
974
974
  case b:
975
- var pe = this.$locale().weekStart || 0, ye = (j < pe ? j + 7 : j) - pe;
976
- return N(O ? le - ye : le + (6 - ye), G);
975
+ var ce = this.$locale().weekStart || 0, ve = (V < ce ? V + 7 : V) - ce;
976
+ return $(O ? te - ve : te + (6 - ve), G);
977
977
  case f:
978
978
  case y:
979
- return H(ce + "Hours", 0);
979
+ return j(ge + "Hours", 0);
980
980
  case d:
981
- return H(ce + "Minutes", 1);
981
+ return j(ge + "Minutes", 1);
982
982
  case p:
983
- return H(ce + "Seconds", 2);
983
+ return j(ge + "Seconds", 2);
984
984
  case l:
985
- return H(ce + "Milliseconds", 3);
985
+ return j(ge + "Milliseconds", 3);
986
986
  default:
987
987
  return this.clone();
988
988
  }
989
989
  }, E.endOf = function(S) {
990
990
  return this.startOf(S, !1);
991
- }, E.$set = function(S, x) {
992
- var w, O = L.p(S), I = "set" + (this.$u ? "UTC" : ""), N = (w = {}, w[f] = I + "Date", w[y] = I + "Date", w[u] = I + "Month", w[g] = I + "FullYear", w[d] = I + "Hours", w[p] = I + "Minutes", w[l] = I + "Seconds", w[o] = I + "Milliseconds", w)[O], H = O === f ? this.$D + (x - this.$W) : x;
991
+ }, E.$set = function(S, R) {
992
+ var w, O = L.p(S), I = "set" + (this.$u ? "UTC" : ""), $ = (w = {}, w[f] = I + "Date", w[y] = I + "Date", w[u] = I + "Month", w[g] = I + "FullYear", w[d] = I + "Hours", w[p] = I + "Minutes", w[l] = I + "Seconds", w[o] = I + "Milliseconds", w)[O], j = O === f ? this.$D + (R - this.$W) : R;
993
993
  if (O === u || O === g) {
994
- var j = this.clone().set(y, 1);
995
- j.$d[N](H), j.init(), this.$d = j.set(y, Math.min(this.$D, j.daysInMonth())).$d;
994
+ var V = this.clone().set(y, 1);
995
+ V.$d[$](j), V.init(), this.$d = V.set(y, Math.min(this.$D, V.daysInMonth())).$d;
996
996
  } else
997
- N && this.$d[N](H);
997
+ $ && this.$d[$](j);
998
998
  return this.init(), this;
999
- }, E.set = function(S, x) {
1000
- return this.clone().$set(S, x);
999
+ }, E.set = function(S, R) {
1000
+ return this.clone().$set(S, R);
1001
1001
  }, E.get = function(S) {
1002
1002
  return this[L.p(S)]();
1003
- }, E.add = function(S, x) {
1003
+ }, E.add = function(S, R) {
1004
1004
  var w, O = this;
1005
1005
  S = Number(S);
1006
- var I = L.p(x), N = function(G) {
1007
- var le = F(O);
1008
- return L.w(le.date(le.date() + Math.round(G * S)), O);
1006
+ var I = L.p(R), $ = function(G) {
1007
+ var te = F(O);
1008
+ return L.w(te.date(te.date() + Math.round(G * S)), O);
1009
1009
  };
1010
1010
  if (I === u)
1011
1011
  return this.set(u, this.$M + S);
1012
1012
  if (I === g)
1013
1013
  return this.set(g, this.$y + S);
1014
1014
  if (I === f)
1015
- return N(1);
1015
+ return $(1);
1016
1016
  if (I === b)
1017
- return N(7);
1018
- var H = (w = {}, w[p] = n, w[d] = s, w[l] = r, w)[I] || 1, j = this.$d.getTime() + S * H;
1019
- return L.w(j, this);
1020
- }, E.subtract = function(S, x) {
1021
- return this.add(-1 * S, x);
1017
+ return $(7);
1018
+ var j = (w = {}, w[p] = n, w[d] = s, w[l] = r, w)[I] || 1, V = this.$d.getTime() + S * j;
1019
+ return L.w(V, this);
1020
+ }, E.subtract = function(S, R) {
1021
+ return this.add(-1 * S, R);
1022
1022
  }, E.format = function(S) {
1023
- var x = this, w = this.$locale();
1023
+ var R = this, w = this.$locale();
1024
1024
  if (!this.isValid())
1025
1025
  return w.invalidDate || h;
1026
- var O = S || "YYYY-MM-DDTHH:mm:ssZ", I = L.z(this), N = this.$H, H = this.$m, j = this.$M, G = w.weekdays, le = w.months, ce = function(re, de, ve, Te) {
1027
- return re && (re[de] || re(x, O)) || ve[de].slice(0, Te);
1028
- }, pe = function(re) {
1029
- return L.s(N % 12 || 12, re, "0");
1030
- }, ye = w.meridiem || function(re, de, ve) {
1031
- var Te = re < 12 ? "AM" : "PM";
1032
- return ve ? Te.toLowerCase() : Te;
1033
- }, fe = { YY: String(this.$y).slice(-2), YYYY: this.$y, M: j + 1, MM: L.s(j + 1, 2, "0"), MMM: ce(w.monthsShort, j, le, 3), MMMM: ce(le, j), D: this.$D, DD: L.s(this.$D, 2, "0"), d: String(this.$W), dd: ce(w.weekdaysMin, this.$W, G, 2), ddd: ce(w.weekdaysShort, this.$W, G, 3), dddd: G[this.$W], H: String(N), HH: L.s(N, 2, "0"), h: pe(1), hh: pe(2), a: ye(N, H, !0), A: ye(N, H, !1), m: String(H), mm: L.s(H, 2, "0"), s: String(this.$s), ss: L.s(this.$s, 2, "0"), SSS: L.s(this.$ms, 3, "0"), Z: I };
1034
- return O.replace(A, function(re, de) {
1035
- return de || fe[re] || I.replace(":", "");
1026
+ var O = S || "YYYY-MM-DDTHH:mm:ssZ", I = L.z(this), $ = this.$H, j = this.$m, V = this.$M, G = w.weekdays, te = w.months, ge = w.meridiem, ce = function(ne, de, me, Te) {
1027
+ return ne && (ne[de] || ne(R, O)) || me[de].slice(0, Te);
1028
+ }, ve = function(ne) {
1029
+ return L.s($ % 12 || 12, ne, "0");
1030
+ }, fe = ge || function(ne, de, me) {
1031
+ var Te = ne < 12 ? "AM" : "PM";
1032
+ return me ? Te.toLowerCase() : Te;
1033
+ };
1034
+ return O.replace(A, function(ne, de) {
1035
+ return de || function(me) {
1036
+ switch (me) {
1037
+ case "YY":
1038
+ return String(R.$y).slice(-2);
1039
+ case "YYYY":
1040
+ return L.s(R.$y, 4, "0");
1041
+ case "M":
1042
+ return V + 1;
1043
+ case "MM":
1044
+ return L.s(V + 1, 2, "0");
1045
+ case "MMM":
1046
+ return ce(w.monthsShort, V, te, 3);
1047
+ case "MMMM":
1048
+ return ce(te, V);
1049
+ case "D":
1050
+ return R.$D;
1051
+ case "DD":
1052
+ return L.s(R.$D, 2, "0");
1053
+ case "d":
1054
+ return String(R.$W);
1055
+ case "dd":
1056
+ return ce(w.weekdaysMin, R.$W, G, 2);
1057
+ case "ddd":
1058
+ return ce(w.weekdaysShort, R.$W, G, 3);
1059
+ case "dddd":
1060
+ return G[R.$W];
1061
+ case "H":
1062
+ return String($);
1063
+ case "HH":
1064
+ return L.s($, 2, "0");
1065
+ case "h":
1066
+ return ve(1);
1067
+ case "hh":
1068
+ return ve(2);
1069
+ case "a":
1070
+ return fe($, j, !0);
1071
+ case "A":
1072
+ return fe($, j, !1);
1073
+ case "m":
1074
+ return String(j);
1075
+ case "mm":
1076
+ return L.s(j, 2, "0");
1077
+ case "s":
1078
+ return String(R.$s);
1079
+ case "ss":
1080
+ return L.s(R.$s, 2, "0");
1081
+ case "SSS":
1082
+ return L.s(R.$ms, 3, "0");
1083
+ case "Z":
1084
+ return I;
1085
+ }
1086
+ return null;
1087
+ }(ne) || I.replace(":", "");
1036
1088
  });
1037
1089
  }, E.utcOffset = function() {
1038
1090
  return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
1039
- }, E.diff = function(S, x, w) {
1040
- var O, I = L.p(x), N = F(S), H = (N.utcOffset() - this.utcOffset()) * n, j = this - N, G = L.m(this, N);
1041
- return G = (O = {}, O[g] = G / 12, O[u] = G, O[c] = G / 3, O[b] = (j - H) / 6048e5, O[f] = (j - H) / 864e5, O[d] = j / s, O[p] = j / n, O[l] = j / r, O)[I] || j, w ? G : L.a(G);
1091
+ }, E.diff = function(S, R, w) {
1092
+ var O, I = this, $ = L.p(R), j = F(S), V = (j.utcOffset() - this.utcOffset()) * n, G = this - j, te = function() {
1093
+ return L.m(I, j);
1094
+ };
1095
+ switch ($) {
1096
+ case g:
1097
+ O = te() / 12;
1098
+ break;
1099
+ case u:
1100
+ O = te();
1101
+ break;
1102
+ case c:
1103
+ O = te() / 3;
1104
+ break;
1105
+ case b:
1106
+ O = (G - V) / 6048e5;
1107
+ break;
1108
+ case f:
1109
+ O = (G - V) / 864e5;
1110
+ break;
1111
+ case d:
1112
+ O = G / s;
1113
+ break;
1114
+ case p:
1115
+ O = G / n;
1116
+ break;
1117
+ case l:
1118
+ O = G / r;
1119
+ break;
1120
+ default:
1121
+ O = G;
1122
+ }
1123
+ return w ? O : L.a(O);
1042
1124
  }, E.daysInMonth = function() {
1043
1125
  return this.endOf(u).$D;
1044
1126
  }, E.$locale = function() {
1045
1127
  return X[this.$L];
1046
- }, E.locale = function(S, x) {
1128
+ }, E.locale = function(S, R) {
1047
1129
  if (!S)
1048
1130
  return this.$L;
1049
- var w = this.clone(), O = Z(S, x, !0);
1131
+ var w = this.clone(), O = Z(S, R, !0);
1050
1132
  return O && (w.$L = O), w;
1051
1133
  }, E.clone = function() {
1052
1134
  return L.w(this.$d, this);
@@ -1058,24 +1140,24 @@ var mt = {}, an = {
1058
1140
  return this.$d.toISOString();
1059
1141
  }, E.toString = function() {
1060
1142
  return this.$d.toUTCString();
1061
- }, R;
1143
+ }, x;
1062
1144
  }(), ee = B.prototype;
1063
- return F.prototype = ee, [["$ms", o], ["$s", l], ["$m", p], ["$H", d], ["$W", f], ["$M", u], ["$y", g], ["$D", y]].forEach(function(R) {
1064
- ee[R[1]] = function(E) {
1065
- return this.$g(E, R[0], R[1]);
1145
+ return F.prototype = ee, [["$ms", o], ["$s", l], ["$m", p], ["$H", d], ["$W", f], ["$M", u], ["$y", g], ["$D", y]].forEach(function(x) {
1146
+ ee[x[1]] = function(E) {
1147
+ return this.$g(E, x[0], x[1]);
1066
1148
  };
1067
- }), F.extend = function(R, E) {
1068
- return R.$i || (R(E, B, F), R.$i = !0), F;
1069
- }, F.locale = Z, F.isDayjs = Y, F.unix = function(R) {
1070
- return F(1e3 * R);
1071
- }, F.en = X[te], F.Ls = X, F.p = {}, F;
1149
+ }), F.extend = function(x, E) {
1150
+ return x.$i || (x(E, B, F), x.$i = !0), F;
1151
+ }, F.locale = Z, F.isDayjs = q, F.unix = function(x) {
1152
+ return F(1e3 * x);
1153
+ }, F.en = X[re], F.Ls = X, F.p = {}, F;
1072
1154
  });
1073
1155
  })(an);
1074
1156
  const zt = mt, on = {
1075
1157
  list: async ({
1076
1158
  pagination: e
1077
1159
  }, t) => {
1078
- const r = await ae.post(t)("/sql_snippet/list", {
1160
+ const r = await ie.post(t)("/sql_snippet/list", {
1079
1161
  sort: [{
1080
1162
  field: "update_time",
1081
1163
  order: "DESC"
@@ -1086,15 +1168,15 @@ const zt = mt, on = {
1086
1168
  n.create_time = zt(n.create_time).format("YYYY-MM-DD HH:mm:ss"), n.update_time = zt(n.update_time).format("YYYY-MM-DD HH:mm:ss");
1087
1169
  }), r;
1088
1170
  },
1089
- get: async (e, t) => await ae.post(t)("/sql_snippet/get", {
1171
+ get: async (e, t) => await ie.post(t)("/sql_snippet/get", {
1090
1172
  id: e
1091
1173
  }, {}),
1092
- create: async (e, t) => await ae.post(t)("/sql_snippet/create", e, {}),
1093
- update: async (e, t) => await ae.put(t)("/sql_snippet/update", e, {}),
1094
- delete: async (e, t) => ae.post(t)("/sql_snippet/delete", {
1174
+ create: async (e, t) => await ie.post(t)("/sql_snippet/create", e, {}),
1175
+ update: async (e, t) => await ie.put(t)("/sql_snippet/update", e, {}),
1176
+ delete: async (e, t) => ie.post(t)("/sql_snippet/delete", {
1095
1177
  id: e
1096
1178
  }, {})
1097
- }, oe = {
1179
+ }, se = {
1098
1180
  datasource: rn,
1099
1181
  account: en,
1100
1182
  role: nn,
@@ -1131,18 +1213,18 @@ function sn({
1131
1213
  });
1132
1214
  return yt(() => {
1133
1215
  s("type", r);
1134
- }, [s, r]), /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(e), children: [
1135
- /* @__PURE__ */ a(q, { name: "key", control: n, render: ({
1216
+ }, [s, r]), /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(e), children: [
1217
+ /* @__PURE__ */ a(H, { name: "key", control: n, render: ({
1136
1218
  field: l
1137
1219
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Name", placeholder: "A unique name", ...l }) }),
1138
1220
  /* @__PURE__ */ a(et, { label: "Connection Info", labelPosition: "center" }),
1139
1221
  /* @__PURE__ */ C(Q, { grow: !0, children: [
1140
- /* @__PURE__ */ a(q, { name: "config.host", control: n, render: ({
1222
+ /* @__PURE__ */ a(H, { name: "config.host", control: n, render: ({
1141
1223
  field: l
1142
1224
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Host", sx: {
1143
1225
  flexGrow: 1
1144
1226
  }, ...l }) }),
1145
- /* @__PURE__ */ a(q, { name: "config.port", control: n, render: ({
1227
+ /* @__PURE__ */ a(H, { name: "config.port", control: n, render: ({
1146
1228
  field: l
1147
1229
  }) => (
1148
1230
  // @ts-expect-error type of onChange
@@ -1151,22 +1233,22 @@ function sn({
1151
1233
  }, ...l })
1152
1234
  ) })
1153
1235
  ] }),
1154
- /* @__PURE__ */ a(q, { name: "config.username", control: n, render: ({
1236
+ /* @__PURE__ */ a(H, { name: "config.username", control: n, render: ({
1155
1237
  field: l
1156
1238
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...l }) }),
1157
- /* @__PURE__ */ a(q, { name: "config.password", control: n, render: ({
1239
+ /* @__PURE__ */ a(H, { name: "config.password", control: n, render: ({
1158
1240
  field: l
1159
1241
  }) => /* @__PURE__ */ a(tt, { mb: t.spacing, size: t.size, required: !0, label: "Password", ...l }) }),
1160
- /* @__PURE__ */ a(q, { name: "config.database", control: n, render: ({
1242
+ /* @__PURE__ */ a(H, { name: "config.database", control: n, render: ({
1161
1243
  field: l
1162
1244
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Database", ...l }) }),
1163
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
1245
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
1164
1246
  ] }) });
1165
1247
  }
1166
1248
  const ln = ({
1167
1249
  value: e,
1168
1250
  onChange: t
1169
- }) => /* @__PURE__ */ a(se, { sx: {
1251
+ }) => /* @__PURE__ */ a(le, { sx: {
1170
1252
  position: "relative"
1171
1253
  }, children: /* @__PURE__ */ a(Vt, { height: "500px", defaultLanguage: "javascript", value: e, onChange: (n) => {
1172
1254
  n && t(n);
@@ -1195,16 +1277,16 @@ const ln = ({
1195
1277
  return yt(() => {
1196
1278
  u(e);
1197
1279
  }, [e]), /* @__PURE__ */ C(he, { children: [
1198
- /* @__PURE__ */ a(V, { variant: "filled", size: o.button.size, onClick: d, sx: {
1280
+ /* @__PURE__ */ a(Y, { variant: "filled", size: o.button.size, onClick: d, sx: {
1199
1281
  flexGrow: 1
1200
1282
  }, children: r }),
1201
1283
  /* @__PURE__ */ a(Ae, { size: 800, title: n, opened: p, onClose: f, closeOnClickOutside: !1, withCloseButton: !1, children: p && /* @__PURE__ */ C(je, { children: [
1202
1284
  /* @__PURE__ */ a(ln, { value: b, onChange: u }),
1203
1285
  /* @__PURE__ */ C(Q, { position: "apart", children: [
1204
- /* @__PURE__ */ a(V, { onClick: y, color: "red", leftIcon: /* @__PURE__ */ a(Lr, { size: 20 }), children: "Reset" }),
1286
+ /* @__PURE__ */ a(Y, { onClick: y, color: "red", leftIcon: /* @__PURE__ */ a(Lr, { size: 20 }), children: "Reset" }),
1205
1287
  /* @__PURE__ */ C(Q, { position: "right", children: [
1206
- /* @__PURE__ */ a(V, { onClick: g, variant: "subtle", children: "Cancel" }),
1207
- /* @__PURE__ */ a(V, { onClick: c, children: "OK" })
1288
+ /* @__PURE__ */ a(Y, { onClick: g, variant: "subtle", children: "Cancel" }),
1289
+ /* @__PURE__ */ a(Y, { onClick: c, children: "OK" })
1208
1290
  ] })
1209
1291
  ] })
1210
1292
  ] }) })
@@ -1236,31 +1318,31 @@ function un({
1236
1318
  }
1237
1319
  }
1238
1320
  });
1239
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: s(e), children: [
1240
- /* @__PURE__ */ a(q, { name: "key", control: r, render: ({
1321
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: s(e), children: [
1322
+ /* @__PURE__ */ a(H, { name: "key", control: r, render: ({
1241
1323
  field: o
1242
1324
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Name", placeholder: "A unique name", ...o }) }),
1243
1325
  /* @__PURE__ */ a(et, { label: "Connection Info", labelPosition: "center" }),
1244
- /* @__PURE__ */ a(q, { name: "config.host", control: r, render: ({
1326
+ /* @__PURE__ */ a(H, { name: "config.host", control: r, render: ({
1245
1327
  field: o
1246
1328
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, label: "Base URL", sx: {
1247
1329
  flexGrow: 1
1248
1330
  }, ...o }) }),
1249
1331
  /* @__PURE__ */ C(Q, { grow: !0, children: [
1250
- /* @__PURE__ */ a(q, { name: "config.processing.pre", control: r, render: ({
1332
+ /* @__PURE__ */ a(H, { name: "config.processing.pre", control: r, render: ({
1251
1333
  field: o
1252
1334
  }) => /* @__PURE__ */ a(Ze, { label: "Pre Processing", modalTitle: "This function will run before sending the request (for scenarios like encryption)", defaultValue: We.pre, ...o, styles: t }) }),
1253
- /* @__PURE__ */ a(q, { name: "config.processing.post", control: r, render: ({
1335
+ /* @__PURE__ */ a(H, { name: "config.processing.post", control: r, render: ({
1254
1336
  field: o
1255
1337
  }) => /* @__PURE__ */ a(Ze, { label: "Post Processing", modalTitle: "This function will run after sending the request (for scenarios like decryption)", defaultValue: We.post, ...o, styles: t }) })
1256
1338
  ] }),
1257
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
1339
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
1258
1340
  ] }) });
1259
1341
  }
1260
1342
  function cn({
1261
1343
  styles: e = Se
1262
1344
  }) {
1263
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C(Rr, { mt: e.spacing, icon: /* @__PURE__ */ a(Fr, { size: 16 }), children: [
1345
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C(Rr, { mt: e.spacing, icon: /* @__PURE__ */ a(Fr, { size: 16 }), children: [
1264
1346
  "Only ",
1265
1347
  /* @__PURE__ */ a("b", { children: "SELECT" }),
1266
1348
  " privilege is needed."
@@ -1275,7 +1357,7 @@ function dn({
1275
1357
  key: d,
1276
1358
  config: f
1277
1359
  }) => {
1278
- be({
1360
+ ye({
1279
1361
  id: "for-creating",
1280
1362
  title: "Pending",
1281
1363
  message: "Adding data source...",
@@ -1286,7 +1368,7 @@ function dn({
1286
1368
  type: p,
1287
1369
  key: d,
1288
1370
  config: f
1289
- }), await oe.datasource.create(p, d, f), J({
1371
+ }), await se.datasource.create(p, d, f), J({
1290
1372
  id: "for-creating",
1291
1373
  title: "Successful",
1292
1374
  message: "Data source is added",
@@ -1301,7 +1383,7 @@ function dn({
1301
1383
  });
1302
1384
  }
1303
1385
  }, o = r === "postgresql" || r === "mysql", l = r === "http";
1304
- return /* @__PURE__ */ C(se, { mx: "auto", children: [
1386
+ return /* @__PURE__ */ C(le, { mx: "auto", children: [
1305
1387
  /* @__PURE__ */ a(xr, { fullWidth: !0, mb: t.spacing, size: t.size, data: [{
1306
1388
  label: "PostgreSQL",
1307
1389
  value: "postgresql"
@@ -1328,7 +1410,7 @@ function pn({
1328
1410
  }, children: /* @__PURE__ */ a(dn, { postSubmit: () => {
1329
1411
  e(), o();
1330
1412
  }, styles: t }) }),
1331
- /* @__PURE__ */ a(V, { size: t.button.size, onClick: s, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add a Data Source" })
1413
+ /* @__PURE__ */ a(Y, { size: t.button.size, onClick: s, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add a Data Source" })
1332
1414
  ] });
1333
1415
  }
1334
1416
  const gn = (e) => e.replace(/([^:])(\/\/+)/g, "$1/");
@@ -1353,12 +1435,12 @@ function hn({
1353
1435
  styles: s = Se
1354
1436
  }) {
1355
1437
  const o = Ge(), l = async () => {
1356
- e && (be({
1438
+ e && (ye({
1357
1439
  id: "for-deleting",
1358
1440
  title: "Pending",
1359
1441
  message: "Deleting data source...",
1360
1442
  loading: !0
1361
- }), await oe.datasource.delete(e), J({
1443
+ }), await se.datasource.delete(e), J({
1362
1444
  id: "for-deleting",
1363
1445
  title: "Successful",
1364
1446
  message: `Data source [${t}] is deleted`,
@@ -1378,9 +1460,9 @@ function hn({
1378
1460
  hover: !0,
1379
1461
  touch: !1,
1380
1462
  focus: !1
1381
- }, label: "This is a preset datasource, it can not be deleted", children: /* @__PURE__ */ a(V, { size: s.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(Wt, { size: 16 }), sx: {
1463
+ }, label: "This is a preset datasource, it can not be deleted", children: /* @__PURE__ */ a(Y, { size: s.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(Wt, { size: 16 }), sx: {
1382
1464
  transform: "none !important"
1383
- }, children: "Delete" }) }) : /* @__PURE__ */ a(V, { size: s.button.size, color: "red", onClick: p, leftIcon: /* @__PURE__ */ a(ot, { size: 16 }), children: "Delete" });
1465
+ }, children: "Delete" }) }) : /* @__PURE__ */ a(Y, { size: s.button.size, color: "red", onClick: p, leftIcon: /* @__PURE__ */ a(ot, { size: 16 }), children: "Delete" });
1384
1466
  }
1385
1467
  const Pt = {
1386
1468
  pre: ["function pre_process({ method, url, params, headers, data }, utils) {", " // your code goes here", " return { method, url, params, headers, data }", "}"].join(`
@@ -1402,23 +1484,23 @@ function mn({
1402
1484
  config: t
1403
1485
  }
1404
1486
  });
1405
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(r), children: [
1487
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(r), children: [
1406
1488
  /* @__PURE__ */ a(ue, { mb: n.spacing, size: n.size, required: !0, label: "Name", value: e, readOnly: !0 }),
1407
1489
  /* @__PURE__ */ a(et, { label: "Connection Info", labelPosition: "center" }),
1408
- /* @__PURE__ */ a(q, { name: "config.host", control: s, render: ({
1490
+ /* @__PURE__ */ a(H, { name: "config.host", control: s, render: ({
1409
1491
  field: l
1410
1492
  }) => /* @__PURE__ */ a(ue, { mb: n.spacing, size: n.size, label: "Base URL", sx: {
1411
1493
  flexGrow: 1
1412
1494
  }, ...l }) }),
1413
1495
  /* @__PURE__ */ C(Q, { grow: !0, children: [
1414
- /* @__PURE__ */ a(q, { name: "config.processing.pre", control: s, render: ({
1496
+ /* @__PURE__ */ a(H, { name: "config.processing.pre", control: s, render: ({
1415
1497
  field: l
1416
1498
  }) => /* @__PURE__ */ a(Ze, { label: "Pre Processing", modalTitle: "This function will run before sending the request (for scenarios like encryption)", defaultValue: Pt.pre, ...l, styles: n }) }),
1417
- /* @__PURE__ */ a(q, { name: "config.processing.post", control: s, render: ({
1499
+ /* @__PURE__ */ a(H, { name: "config.processing.post", control: s, render: ({
1418
1500
  field: l
1419
1501
  }) => /* @__PURE__ */ a(Ze, { label: "Post Processing", modalTitle: "This function will run after sending the request (for scenarios like decryption)", defaultValue: Pt.post, ...l, styles: n }) })
1420
1502
  ] }),
1421
- /* @__PURE__ */ a(Q, { position: "right", mt: n.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: n.button.size, children: "Save" }) })
1503
+ /* @__PURE__ */ a(Q, { position: "right", mt: n.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: n.button.size, children: "Save" }) })
1422
1504
  ] }) });
1423
1505
  }
1424
1506
  function bn({
@@ -1429,7 +1511,7 @@ function bn({
1429
1511
  const n = async ({
1430
1512
  config: s
1431
1513
  }) => {
1432
- be({
1514
+ ye({
1433
1515
  id: "for-updating",
1434
1516
  title: "Pending",
1435
1517
  message: "Editing data source...",
@@ -1438,7 +1520,7 @@ function bn({
1438
1520
  try {
1439
1521
  console.log({
1440
1522
  config: s
1441
- }), await oe.datasource.update(e.id, s), J({
1523
+ }), await se.datasource.update(e.id, s), J({
1442
1524
  id: "for-updating",
1443
1525
  title: "Successful",
1444
1526
  message: "Data source is updated",
@@ -1453,7 +1535,7 @@ function bn({
1453
1535
  });
1454
1536
  }
1455
1537
  };
1456
- return e.config ? /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ a(mn, { name: e.key, config: e.config, submit: n, styles: r }) }) : (console.error(new Error("unexpected empty config of a http datasource")), null);
1538
+ return e.config ? /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ a(mn, { name: e.key, config: e.config, submit: n, styles: r }) }) : (console.error(new Error("unexpected empty config of a http datasource")), null);
1457
1539
  }
1458
1540
  function yn({
1459
1541
  dataSource: e,
@@ -1467,19 +1549,19 @@ function yn({
1467
1549
  hover: !0,
1468
1550
  touch: !1,
1469
1551
  focus: !1
1470
- }, label: "This is a preset datasource, it can not be changed", children: /* @__PURE__ */ a(V, { size: r.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(Wt, { size: 16 }), sx: {
1552
+ }, label: "This is a preset datasource, it can not be changed", children: /* @__PURE__ */ a(Y, { size: r.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(Wt, { size: 16 }), sx: {
1471
1553
  transform: "none !important"
1472
1554
  }, children: "Edit" }) }) : e.type !== "http" ? /* @__PURE__ */ a(Ke, { withArrow: !0, events: {
1473
1555
  hover: !0,
1474
1556
  touch: !1,
1475
1557
  focus: !1
1476
- }, label: "Only HTTP datasources can be edited", children: /* @__PURE__ */ a(V, { size: r.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(ht, { size: 16 }), sx: {
1558
+ }, label: "Only HTTP datasources can be edited", children: /* @__PURE__ */ a(Y, { size: r.button.size, color: "gray", variant: "light", leftIcon: /* @__PURE__ */ a(ht, { size: 16 }), sx: {
1477
1559
  transform: "none !important"
1478
1560
  }, children: "Edit" }) }) : /* @__PURE__ */ C(he, { children: [
1479
1561
  /* @__PURE__ */ a(Ae, { opened: n, onClose: () => s(!1), title: "Add a data source", trapFocus: !0, onDragStart: (d) => {
1480
1562
  d.stopPropagation();
1481
1563
  }, children: /* @__PURE__ */ a(bn, { dataSource: e, postSubmit: p, styles: r }) }),
1482
- /* @__PURE__ */ a(V, { size: r.button.size, color: "blue", onClick: o, leftIcon: /* @__PURE__ */ a(ht, { size: 16 }), children: "Edit" })
1564
+ /* @__PURE__ */ a(Y, { size: r.button.size, color: "blue", onClick: o, leftIcon: /* @__PURE__ */ a(ht, { size: 16 }), children: "Edit" })
1483
1565
  ] });
1484
1566
  }
1485
1567
  const vn = {
@@ -1516,14 +1598,14 @@ function Ea({
1516
1598
  } = xe(async () => {
1517
1599
  const {
1518
1600
  data: o
1519
- } = await oe.datasource.list();
1601
+ } = await se.datasource.list();
1520
1602
  return o;
1521
1603
  }, {
1522
1604
  refreshDeps: []
1523
1605
  });
1524
1606
  return /* @__PURE__ */ C(he, { children: [
1525
1607
  /* @__PURE__ */ a(Q, { pt: e.spacing, position: "right", children: /* @__PURE__ */ a(pn, { onSuccess: s }) }),
1526
- /* @__PURE__ */ C(se, { mt: e.spacing, sx: {
1608
+ /* @__PURE__ */ C(le, { mt: e.spacing, sx: {
1527
1609
  position: "relative"
1528
1610
  }, children: [
1529
1611
  /* @__PURE__ */ a(rt, { visible: n }),
@@ -1569,7 +1651,7 @@ const En = Je(({
1569
1651
  const {
1570
1652
  data: s = [],
1571
1653
  loading: o
1572
- } = xe(async () => (await oe.role.list()).map((p) => ({
1654
+ } = xe(async () => (await se.role.list()).map((p) => ({
1573
1655
  label: p.id,
1574
1656
  value: p.id,
1575
1657
  description: p.description,
@@ -1611,19 +1693,19 @@ function _n({
1611
1693
  password: ""
1612
1694
  }
1613
1695
  });
1614
- return /* @__PURE__ */ a(se, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: s(async ({
1696
+ return /* @__PURE__ */ a(le, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: s(async ({
1615
1697
  name: l,
1616
1698
  email: p,
1617
1699
  password: d,
1618
1700
  role_id: f
1619
1701
  }) => {
1620
1702
  try {
1621
- be({
1703
+ ye({
1622
1704
  id: "for-creating",
1623
1705
  title: "Pending",
1624
1706
  message: "Adding account...",
1625
1707
  loading: !0
1626
- }), await oe.account.create(l, p, d, f), J({
1708
+ }), await se.account.create(l, p, d, f), J({
1627
1709
  id: "for-creating",
1628
1710
  title: "Successful",
1629
1711
  message: "Account is added",
@@ -1638,19 +1720,19 @@ function _n({
1638
1720
  });
1639
1721
  }
1640
1722
  }), children: [
1641
- /* @__PURE__ */ a(q, { name: "name", control: n, render: ({
1723
+ /* @__PURE__ */ a(H, { name: "name", control: n, render: ({
1642
1724
  field: l
1643
1725
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...l }) }),
1644
- /* @__PURE__ */ a(q, { name: "email", control: n, render: ({
1726
+ /* @__PURE__ */ a(H, { name: "email", control: n, render: ({
1645
1727
  field: l
1646
1728
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Email", ...l }) }),
1647
- /* @__PURE__ */ a(q, { name: "password", control: n, render: ({
1729
+ /* @__PURE__ */ a(H, { name: "password", control: n, render: ({
1648
1730
  field: l
1649
1731
  }) => /* @__PURE__ */ a(tt, { mb: t.spacing, size: t.size, required: !0, label: "Password", description: "Password must be at least 8 characters long", ...l }) }),
1650
- /* @__PURE__ */ a(q, { name: "role_id", control: n, render: ({
1732
+ /* @__PURE__ */ a(H, { name: "role_id", control: n, render: ({
1651
1733
  field: l
1652
1734
  }) => /* @__PURE__ */ a(St, { styles: t, ...l }) }),
1653
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
1735
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
1654
1736
  ] }) });
1655
1737
  }
1656
1738
  function An({
@@ -1665,7 +1747,7 @@ function An({
1665
1747
  }, children: /* @__PURE__ */ a(_n, { postSubmit: () => {
1666
1748
  e(), l();
1667
1749
  }, styles: t, initialRoleID: r }) }),
1668
- /* @__PURE__ */ a(V, { size: t.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add an Account" })
1750
+ /* @__PURE__ */ a(Y, { size: t.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add an Account" })
1669
1751
  ] });
1670
1752
  }
1671
1753
  function kn({
@@ -1676,14 +1758,14 @@ function kn({
1676
1758
  }) {
1677
1759
  const s = Ge(), o = async () => {
1678
1760
  if (e) {
1679
- be({
1761
+ ye({
1680
1762
  id: "for-deleting",
1681
1763
  title: "Pending",
1682
1764
  message: "Deleting account...",
1683
1765
  loading: !0
1684
1766
  });
1685
1767
  try {
1686
- await oe.account.delete(e), J({
1768
+ await se.account.delete(e), J({
1687
1769
  id: "for-deleting",
1688
1770
  title: "Successful",
1689
1771
  message: `Account [${t}] is deleted`,
@@ -1707,7 +1789,7 @@ function kn({
1707
1789
  onCancel: () => console.log("Cancel"),
1708
1790
  onConfirm: o
1709
1791
  });
1710
- return /* @__PURE__ */ a(V, { size: n.button.size, color: "red", onClick: l, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
1792
+ return /* @__PURE__ */ a(Y, { size: n.button.size, color: "red", onClick: l, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
1711
1793
  }
1712
1794
  function Tn({
1713
1795
  id: e,
@@ -1737,12 +1819,12 @@ function Tn({
1737
1819
  new_password: _
1738
1820
  }) => {
1739
1821
  try {
1740
- be({
1822
+ ye({
1741
1823
  id: "for-updating",
1742
1824
  title: "Pending",
1743
1825
  message: "Updating account...",
1744
1826
  loading: !0
1745
- }), await oe.account.edit({
1827
+ }), await se.account.edit({
1746
1828
  id: e,
1747
1829
  name: c.trim(),
1748
1830
  email: g.trim(),
@@ -1764,18 +1846,18 @@ function Tn({
1764
1846
  });
1765
1847
  }
1766
1848
  }, [b, u] = d(["reset_password", "new_password"]);
1767
- return /* @__PURE__ */ a(se, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: p(f), children: [
1768
- /* @__PURE__ */ a(q, { name: "name", control: l, render: ({
1849
+ return /* @__PURE__ */ a(le, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: p(f), children: [
1850
+ /* @__PURE__ */ a(H, { name: "name", control: l, render: ({
1769
1851
  field: c
1770
1852
  }) => /* @__PURE__ */ a(ue, { mb: o.spacing, size: o.size, required: !0, label: "Username", ...c }) }),
1771
- /* @__PURE__ */ a(q, { name: "email", control: l, render: ({
1853
+ /* @__PURE__ */ a(H, { name: "email", control: l, render: ({
1772
1854
  field: c
1773
1855
  }) => /* @__PURE__ */ a(ue, { mb: o.spacing, size: o.size, required: !0, label: "Email", ...c }) }),
1774
- /* @__PURE__ */ a(q, { name: "role_id", control: l, render: ({
1856
+ /* @__PURE__ */ a(H, { name: "role_id", control: l, render: ({
1775
1857
  field: c
1776
1858
  }) => /* @__PURE__ */ a(St, { styles: o, ...c }) }),
1777
1859
  /* @__PURE__ */ a(et, { my: 20, variant: "dashed", label: "", labelPosition: "center" }),
1778
- /* @__PURE__ */ a(q, { name: "reset_password", control: l, render: ({
1860
+ /* @__PURE__ */ a(H, { name: "reset_password", control: l, render: ({
1779
1861
  field: c
1780
1862
  }) => /* @__PURE__ */ a(Cr, { mb: o.spacing, size: o.size, label: "Reset password", checked: c.value, onChange: (g) => c.onChange(g.currentTarget.checked), styles: {
1781
1863
  label: {
@@ -1783,7 +1865,7 @@ function Tn({
1783
1865
  }
1784
1866
  } }) }),
1785
1867
  b && /* @__PURE__ */ a(
1786
- q,
1868
+ H,
1787
1869
  {
1788
1870
  name: "new_password",
1789
1871
  control: l,
@@ -1792,7 +1874,7 @@ function Tn({
1792
1874
  }) => /* @__PURE__ */ a(tt, { autoComplete: "off", mb: o.spacing, size: o.size, required: !0, description: "Password must be at least 8 characters long", label: "New Password", ...c })
1793
1875
  }
1794
1876
  ),
1795
- /* @__PURE__ */ a(Q, { position: "right", mt: o.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: o.button.size, children: "Submit" }) })
1877
+ /* @__PURE__ */ a(Q, { position: "right", mt: o.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: o.button.size, children: "Submit" }) })
1796
1878
  ] }) });
1797
1879
  }
1798
1880
  function Rn({
@@ -1807,7 +1889,7 @@ function Rn({
1807
1889
  /* @__PURE__ */ a(Ae, { opened: n, onClose: () => s(!1), title: `Editing ${e.name}`, trapFocus: !0, onDragStart: (d) => {
1808
1890
  d.stopPropagation();
1809
1891
  }, children: /* @__PURE__ */ a(Tn, { ...e, postSubmit: p, styles: r }) }),
1810
- /* @__PURE__ */ a(V, { size: r.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(Nr, { size: 20 }), children: "Edit" })
1892
+ /* @__PURE__ */ a(Y, { size: r.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(Nr, { size: 20 }), children: "Edit" })
1811
1893
  ] });
1812
1894
  }
1813
1895
  function _a({
@@ -1823,14 +1905,14 @@ function _a({
1823
1905
  } = xe(async () => {
1824
1906
  const {
1825
1907
  data: d
1826
- } = await oe.account.list();
1908
+ } = await se.account.list();
1827
1909
  return d;
1828
1910
  }, {
1829
1911
  refreshDeps: []
1830
1912
  }), {
1831
1913
  data: o = [],
1832
1914
  loading: l
1833
- } = xe(async () => (await oe.role.list()).map((f) => ({
1915
+ } = xe(async () => (await se.role.list()).map((f) => ({
1834
1916
  label: f.id,
1835
1917
  value: f.id,
1836
1918
  description: f.description,
@@ -1840,7 +1922,7 @@ function _a({
1840
1922
  });
1841
1923
  return /* @__PURE__ */ C(he, { children: [
1842
1924
  /* @__PURE__ */ a(Q, { pt: e.spacing, position: "right", children: /* @__PURE__ */ a(An, { onSuccess: s, initialRoleID: ((p = o == null ? void 0 : o[0]) == null ? void 0 : p.value) ?? "INACTIVE" }) }),
1843
- /* @__PURE__ */ C(se, { mt: e.spacing, sx: {
1925
+ /* @__PURE__ */ C(le, { mt: e.spacing, sx: {
1844
1926
  position: "relative"
1845
1927
  }, children: [
1846
1928
  /* @__PURE__ */ a(rt, { visible: n || l }),
@@ -1885,18 +1967,18 @@ function xn({
1885
1967
  password: ""
1886
1968
  }
1887
1969
  });
1888
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: n(async ({
1970
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: n(async ({
1889
1971
  name: o,
1890
1972
  password: l
1891
1973
  }) => {
1892
1974
  try {
1893
- be({
1975
+ ye({
1894
1976
  id: "for-login",
1895
1977
  title: "Pending",
1896
1978
  message: "Loggin in...",
1897
1979
  loading: !0
1898
1980
  });
1899
- const p = await oe.account.login(o.trim(), l.trim());
1981
+ const p = await se.account.login(o.trim(), l.trim());
1900
1982
  window.localStorage.setItem("token", p.token), J({
1901
1983
  id: "for-login",
1902
1984
  title: "Successful",
@@ -1912,13 +1994,13 @@ function xn({
1912
1994
  });
1913
1995
  }
1914
1996
  }), children: [
1915
- /* @__PURE__ */ a(q, { name: "name", control: r, render: ({
1997
+ /* @__PURE__ */ a(H, { name: "name", control: r, render: ({
1916
1998
  field: o
1917
1999
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Username", ...o }) }),
1918
- /* @__PURE__ */ a(q, { name: "password", control: r, render: ({
2000
+ /* @__PURE__ */ a(H, { name: "password", control: r, render: ({
1919
2001
  field: o
1920
2002
  }) => /* @__PURE__ */ a(tt, { mb: t.spacing, size: t.size, required: !0, label: "Password", ...o }) }),
1921
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Submit" }) })
2003
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Submit" }) })
1922
2004
  ] }) });
1923
2005
  }
1924
2006
  function Aa({
@@ -1926,7 +2008,7 @@ function Aa({
1926
2008
  config: t,
1927
2009
  onSuccess: r
1928
2010
  }) {
1929
- return Ue(t), /* @__PURE__ */ a(he, { children: /* @__PURE__ */ a(se, { mt: e.spacing, sx: {
2011
+ return Ue(t), /* @__PURE__ */ a(he, { children: /* @__PURE__ */ a(le, { mt: e.spacing, sx: {
1930
2012
  position: "relative"
1931
2013
  }, children: /* @__PURE__ */ a(xn, { styles: e, postSubmit: r }) }) });
1932
2014
  }
@@ -1951,12 +2033,12 @@ function On({
1951
2033
  role_id: r
1952
2034
  }
1953
2035
  });
1954
- return /* @__PURE__ */ a(se, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: s(async ({
2036
+ return /* @__PURE__ */ a(le, { mx: "auto", mb: 10, children: /* @__PURE__ */ C("form", { onSubmit: s(async ({
1955
2037
  name: l,
1956
2038
  role_id: p
1957
2039
  }) => {
1958
2040
  try {
1959
- be({
2041
+ ye({
1960
2042
  id: "for-creating",
1961
2043
  title: "Pending",
1962
2044
  message: "Adding API Key...",
@@ -1965,7 +2047,7 @@ function On({
1965
2047
  const {
1966
2048
  app_id: d,
1967
2049
  app_secret: f
1968
- } = await oe.api_key.create(l, p);
2050
+ } = await se.api_key.create(l, p);
1969
2051
  J({
1970
2052
  id: "for-creating",
1971
2053
  title: "Successful",
@@ -1981,13 +2063,13 @@ function On({
1981
2063
  });
1982
2064
  }
1983
2065
  }), children: [
1984
- /* @__PURE__ */ a(q, { name: "name", control: n, render: ({
2066
+ /* @__PURE__ */ a(H, { name: "name", control: n, render: ({
1985
2067
  field: l
1986
2068
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...l }) }),
1987
- /* @__PURE__ */ a(q, { name: "role_id", control: n, render: ({
2069
+ /* @__PURE__ */ a(H, { name: "role_id", control: n, render: ({
1988
2070
  field: l
1989
2071
  }) => /* @__PURE__ */ a(St, { styles: t, ...l }) }),
1990
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
2072
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
1991
2073
  ] }) });
1992
2074
  }
1993
2075
  function Cn({
@@ -2014,7 +2096,7 @@ function Cn({
2014
2096
  cursor: "text !important"
2015
2097
  }
2016
2098
  } }),
2017
- /* @__PURE__ */ a(V, { size: "sm", onClick: () => {
2099
+ /* @__PURE__ */ a(Y, { size: "sm", onClick: () => {
2018
2100
  Mr();
2019
2101
  }, children: "I've saved this API Key" })
2020
2102
  ] }),
@@ -2023,7 +2105,7 @@ function Cn({
2023
2105
  }
2024
2106
  });
2025
2107
  }, styles: t, initialRoleID: r }) }),
2026
- /* @__PURE__ */ a(V, { size: t.button.size, onClick: l, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add an API Key" })
2108
+ /* @__PURE__ */ a(Y, { size: t.button.size, onClick: l, leftIcon: /* @__PURE__ */ a(it, { size: 20 }), children: "Add an API Key" })
2027
2109
  ] });
2028
2110
  }
2029
2111
  function In({
@@ -2034,14 +2116,14 @@ function In({
2034
2116
  }) {
2035
2117
  const s = Ge(), o = async () => {
2036
2118
  if (e) {
2037
- be({
2119
+ ye({
2038
2120
  id: "for-deleting",
2039
2121
  title: "Pending",
2040
2122
  message: "Deleting API Key...",
2041
2123
  loading: !0
2042
2124
  });
2043
2125
  try {
2044
- await oe.api_key.delete(e), J({
2126
+ await se.api_key.delete(e), J({
2045
2127
  id: "for-deleting",
2046
2128
  title: "Successful",
2047
2129
  message: `API Key [${t}] is deleted`,
@@ -2065,7 +2147,7 @@ function In({
2065
2147
  onCancel: () => console.log("Cancel"),
2066
2148
  onConfirm: o
2067
2149
  });
2068
- return /* @__PURE__ */ a(V, { size: n.button.size, color: "red", onClick: l, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
2150
+ return /* @__PURE__ */ a(Y, { size: n.button.size, color: "red", onClick: l, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
2069
2151
  }
2070
2152
  function ka({
2071
2153
  styles: e = st,
@@ -2080,14 +2162,14 @@ function ka({
2080
2162
  } = xe(async () => {
2081
2163
  const {
2082
2164
  data: d
2083
- } = await oe.api_key.list();
2165
+ } = await se.api_key.list();
2084
2166
  return d;
2085
2167
  }, {
2086
2168
  refreshDeps: []
2087
2169
  }), {
2088
2170
  data: o = [],
2089
2171
  loading: l
2090
- } = xe(async () => (await oe.role.list()).map((f) => ({
2172
+ } = xe(async () => (await se.role.list()).map((f) => ({
2091
2173
  label: f.id,
2092
2174
  value: f.id,
2093
2175
  description: f.description,
@@ -2097,7 +2179,7 @@ function ka({
2097
2179
  });
2098
2180
  return /* @__PURE__ */ C(he, { children: [
2099
2181
  /* @__PURE__ */ a(Q, { pt: e.spacing, position: "right", children: /* @__PURE__ */ a(Cn, { onSuccess: s, initialRoleID: ((p = o == null ? void 0 : o[0]) == null ? void 0 : p.value) ?? "INACTIVE" }) }),
2100
- /* @__PURE__ */ C(se, { mt: e.spacing, sx: {
2182
+ /* @__PURE__ */ C(le, { mt: e.spacing, sx: {
2101
2183
  position: "relative"
2102
2184
  }, children: [
2103
2185
  /* @__PURE__ */ a(rt, { visible: n || l }),
@@ -2166,14 +2248,14 @@ function Dn({
2166
2248
  content: ""
2167
2249
  }
2168
2250
  });
2169
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: n(async (o) => {
2251
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: n(async (o) => {
2170
2252
  try {
2171
- be({
2253
+ ye({
2172
2254
  id: "for-creating",
2173
2255
  title: "Pending",
2174
2256
  message: "Adding SQL Snippet...",
2175
2257
  loading: !0
2176
- }), await oe.sql_snippet.create(o), J({
2258
+ }), await se.sql_snippet.create(o), J({
2177
2259
  id: "for-creating",
2178
2260
  title: "Successful",
2179
2261
  message: "SQL Snippet is added",
@@ -2188,10 +2270,10 @@ function Dn({
2188
2270
  });
2189
2271
  }
2190
2272
  }), children: [
2191
- /* @__PURE__ */ a(q, { name: "id", control: r, render: ({
2273
+ /* @__PURE__ */ a(H, { name: "id", control: r, render: ({
2192
2274
  field: o
2193
2275
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...o }) }),
2194
- /* @__PURE__ */ a(q, { name: "content", control: r, render: ({
2276
+ /* @__PURE__ */ a(H, { name: "content", control: r, render: ({
2195
2277
  field: o
2196
2278
  }) => /* @__PURE__ */ C(je, { spacing: 4, children: [
2197
2279
  /* @__PURE__ */ a(Re, { size: 14, fw: 500, color: "#212529", sx: {
@@ -2199,7 +2281,7 @@ function Dn({
2199
2281
  }, children: "Content" }),
2200
2282
  /* @__PURE__ */ a(Kt, { height: "600px", ...o })
2201
2283
  ] }) }),
2202
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
2284
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
2203
2285
  ] }) });
2204
2286
  }
2205
2287
  function Ln({
@@ -2213,7 +2295,7 @@ function Ln({
2213
2295
  }, size: "80vw", children: /* @__PURE__ */ a(Dn, { postSubmit: () => {
2214
2296
  o(), e();
2215
2297
  }, styles: t }) }),
2216
- /* @__PURE__ */ a(V, { size: t.button.size, onClick: s, leftIcon: /* @__PURE__ */ a(it, { size: 18 }), children: "Add a SQL Snippet" })
2298
+ /* @__PURE__ */ a(Y, { size: t.button.size, onClick: s, leftIcon: /* @__PURE__ */ a(it, { size: 18 }), children: "Add a SQL Snippet" })
2217
2299
  ] });
2218
2300
  }
2219
2301
  function Fn({
@@ -2231,14 +2313,14 @@ function Fn({
2231
2313
  content: n
2232
2314
  }
2233
2315
  });
2234
- return /* @__PURE__ */ a(se, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(async (p) => {
2316
+ return /* @__PURE__ */ a(le, { mx: "auto", children: /* @__PURE__ */ C("form", { onSubmit: o(async (p) => {
2235
2317
  try {
2236
- be({
2318
+ ye({
2237
2319
  id: "for-updating",
2238
2320
  title: "Pending",
2239
2321
  message: "Updating SQL Snippet...",
2240
2322
  loading: !0
2241
- }), await oe.sql_snippet.update(p), J({
2323
+ }), await se.sql_snippet.update(p), J({
2242
2324
  id: "for-updating",
2243
2325
  title: "Successful",
2244
2326
  message: "SQL Snippet is updated",
@@ -2253,10 +2335,10 @@ function Fn({
2253
2335
  });
2254
2336
  }
2255
2337
  }), children: [
2256
- /* @__PURE__ */ a(q, { name: "id", control: s, render: ({
2338
+ /* @__PURE__ */ a(H, { name: "id", control: s, render: ({
2257
2339
  field: p
2258
2340
  }) => /* @__PURE__ */ a(ue, { mb: t.spacing, size: t.size, required: !0, label: "Name", ...p }) }),
2259
- /* @__PURE__ */ a(q, { name: "content", control: s, render: ({
2341
+ /* @__PURE__ */ a(H, { name: "content", control: s, render: ({
2260
2342
  field: p
2261
2343
  }) => /* @__PURE__ */ C(je, { spacing: 4, children: [
2262
2344
  /* @__PURE__ */ a(Re, { size: 14, fw: 500, color: "#212529", sx: {
@@ -2264,7 +2346,7 @@ function Fn({
2264
2346
  }, children: "Content" }),
2265
2347
  /* @__PURE__ */ a(Kt, { height: "600px", ...p })
2266
2348
  ] }) }),
2267
- /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(V, { type: "submit", size: t.button.size, children: "Save" }) })
2349
+ /* @__PURE__ */ a(Q, { position: "right", mt: t.spacing, children: /* @__PURE__ */ a(Y, { type: "submit", size: t.button.size, children: "Save" }) })
2268
2350
  ] }) });
2269
2351
  }
2270
2352
  function Nn({
@@ -2279,7 +2361,7 @@ function Nn({
2279
2361
  }, size: "80vw", children: /* @__PURE__ */ a(Fn, { postSubmit: () => {
2280
2362
  l(), e();
2281
2363
  }, styles: t, ...r }) }),
2282
- /* @__PURE__ */ a(V, { size: t.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(ht, { size: 18 }), children: "Edit" })
2364
+ /* @__PURE__ */ a(Y, { size: t.button.size, onClick: o, leftIcon: /* @__PURE__ */ a(ht, { size: 18 }), children: "Edit" })
2283
2365
  ] });
2284
2366
  }
2285
2367
  /**
@@ -2562,9 +2644,9 @@ var bt = function() {
2562
2644
  g.hasOwnProperty(k) && (_[k] = g[k]);
2563
2645
  g.hasOwnProperty(A) || (_[A] = h[A]);
2564
2646
  }
2565
- var $ = y[u];
2566
- return y[u] = _, n.languages.DFS(n.languages, function(M, te) {
2567
- te === $ && M != u && (this[M] = _);
2647
+ var N = y[u];
2648
+ return y[u] = _, n.languages.DFS(n.languages, function(M, re) {
2649
+ re === N && M != u && (this[M] = _);
2568
2650
  }), _;
2569
2651
  },
2570
2652
  // Traverse a language definition with Depth First Search
@@ -2574,8 +2656,8 @@ var bt = function() {
2574
2656
  for (var A in c)
2575
2657
  if (c.hasOwnProperty(A)) {
2576
2658
  g.call(c, A, c[A], y || A);
2577
- var k = c[A], $ = n.util.type(k);
2578
- $ === "Object" && !h[_(k)] ? (h[_(k)] = !0, u(k, g, null, h)) : $ === "Array" && !h[_(k)] && (h[_(k)] = !0, u(k, g, A, h));
2659
+ var k = c[A], N = n.util.type(k);
2660
+ N === "Object" && !h[_(k)] ? (h[_(k)] = !0, u(k, g, null, h)) : N === "Array" && !h[_(k)] && (h[_(k)] = !0, u(k, g, A, h));
2579
2661
  }
2580
2662
  }
2581
2663
  },
@@ -2691,8 +2773,8 @@ var bt = function() {
2691
2773
  return c;
2692
2774
  if (Array.isArray(c)) {
2693
2775
  var y = "";
2694
- return c.forEach(function($) {
2695
- y += u($, g);
2776
+ return c.forEach(function(N) {
2777
+ y += u(N, g);
2696
2778
  }), y;
2697
2779
  }
2698
2780
  var h = {
@@ -2723,44 +2805,44 @@ var bt = function() {
2723
2805
  if (!(!g.hasOwnProperty(A) || !g[A])) {
2724
2806
  var k = g[A];
2725
2807
  k = Array.isArray(k) ? k : [k];
2726
- for (var $ = 0; $ < k.length; ++$) {
2727
- if (_ && _.cause == A + "," + $)
2808
+ for (var N = 0; N < k.length; ++N) {
2809
+ if (_ && _.cause == A + "," + N)
2728
2810
  return;
2729
- var M = k[$], te = M.inside, X = !!M.lookbehind, Y = !!M.greedy, Z = M.alias;
2730
- if (Y && !M.pattern.global) {
2811
+ var M = k[N], re = M.inside, X = !!M.lookbehind, q = !!M.greedy, Z = M.alias;
2812
+ if (q && !M.pattern.global) {
2731
2813
  var F = M.pattern.toString().match(/[imsuy]*$/)[0];
2732
2814
  M.pattern = RegExp(M.pattern.source, F + "g");
2733
2815
  }
2734
2816
  for (var L = M.pattern || M, B = y.next, ee = h; B !== c.tail && !(_ && ee >= _.reach); ee += B.value.length, B = B.next) {
2735
- var R = B.value;
2817
+ var x = B.value;
2736
2818
  if (c.length > u.length)
2737
2819
  return;
2738
- if (!(R instanceof s)) {
2820
+ if (!(x instanceof s)) {
2739
2821
  var E = 1, S;
2740
- if (Y) {
2822
+ if (q) {
2741
2823
  if (S = o(L, ee, u, X), !S || S.index >= u.length)
2742
2824
  break;
2743
- var I = S.index, x = S.index + S[0].length, w = ee;
2825
+ var I = S.index, R = S.index + S[0].length, w = ee;
2744
2826
  for (w += B.value.length; I >= w; )
2745
2827
  B = B.next, w += B.value.length;
2746
2828
  if (w -= B.value.length, ee = w, B.value instanceof s)
2747
2829
  continue;
2748
- for (var O = B; O !== c.tail && (w < x || typeof O.value == "string"); O = O.next)
2830
+ for (var O = B; O !== c.tail && (w < R || typeof O.value == "string"); O = O.next)
2749
2831
  E++, w += O.value.length;
2750
- E--, R = u.slice(ee, w), S.index -= ee;
2751
- } else if (S = o(L, 0, R, X), !S)
2832
+ E--, x = u.slice(ee, w), S.index -= ee;
2833
+ } else if (S = o(L, 0, x, X), !S)
2752
2834
  continue;
2753
- var I = S.index, N = S[0], H = R.slice(0, I), j = R.slice(I + N.length), G = ee + R.length;
2835
+ var I = S.index, $ = S[0], j = x.slice(0, I), V = x.slice(I + $.length), G = ee + x.length;
2754
2836
  _ && G > _.reach && (_.reach = G);
2755
- var le = B.prev;
2756
- H && (le = d(c, le, H), ee += H.length), f(c, le, E);
2757
- var ce = new s(A, te ? n.tokenize(N, te) : N, Z, N);
2758
- if (B = d(c, le, ce), j && d(c, B, j), E > 1) {
2759
- var pe = {
2760
- cause: A + "," + $,
2837
+ var te = B.prev;
2838
+ j && (te = d(c, te, j), ee += j.length), f(c, te, E);
2839
+ var ge = new s(A, re ? n.tokenize($, re) : $, Z, $);
2840
+ if (B = d(c, te, ge), V && d(c, B, V), E > 1) {
2841
+ var ce = {
2842
+ cause: A + "," + N,
2761
2843
  reach: G
2762
2844
  };
2763
- l(u, c, g, B.prev, ee, pe), _ && pe.reach > _.reach && (_.reach = pe.reach);
2845
+ l(u, c, g, B.prev, ee, ce), _ && ce.reach > _.reach && (_.reach = ce.reach);
2764
2846
  }
2765
2847
  }
2766
2848
  }
@@ -3972,8 +4054,8 @@ m.languages.js = m.languages.javascript;
3972
4054
  if (_ && A && _.type === "code-language" && A.type === "code-block" && typeof _.content == "string") {
3973
4055
  var k = _.content.replace(/\b#/g, "sharp").replace(/\b\+\+/g, "pp");
3974
4056
  k = (/[a-z][\w-]*/i.exec(k) || [""])[0].toLowerCase();
3975
- var $ = "language-" + k;
3976
- A.alias ? typeof A.alias == "string" ? A.alias = [A.alias, $] : A.alias.push($) : A.alias = [$];
4057
+ var N = "language-" + k;
4058
+ A.alias ? typeof A.alias == "string" ? A.alias = [A.alias, N] : A.alias.push(N) : A.alias = [N];
3977
4059
  }
3978
4060
  }
3979
4061
  }
@@ -4100,8 +4182,8 @@ m.hooks.add("after-tokenize", function(t) {
4100
4182
  }
4101
4183
  function l(h, _) {
4102
4184
  for (var A = 1, k = n; k < r.length; k++) {
4103
- var $ = r[k], M = $.content;
4104
- if ($.type === "punctuation" && typeof M == "string") {
4185
+ var N = r[k], M = N.content;
4186
+ if (N.type === "punctuation" && typeof M == "string") {
4105
4187
  if (h.test(M))
4106
4188
  A++;
4107
4189
  else if (_.test(M) && (A--, A === 0))
@@ -4238,32 +4320,32 @@ m.languages.sql = {
4238
4320
  pattern: RegExp(o),
4239
4321
  lookbehind: !0
4240
4322
  }
4241
- }), A = 0, k = {}, $ = _.map(function(Y) {
4242
- if (typeof Y == "string")
4243
- return Y;
4244
- for (var Z = Y.content, F; g.indexOf(F = p(A++, h)) !== -1; )
4323
+ }), A = 0, k = {}, N = _.map(function(q) {
4324
+ if (typeof q == "string")
4325
+ return q;
4326
+ for (var Z = q.content, F; g.indexOf(F = p(A++, h)) !== -1; )
4245
4327
  ;
4246
4328
  return k[F] = Z, F;
4247
- }).join(""), M = d($, y, h), te = Object.keys(k);
4329
+ }).join(""), M = d(N, y, h), re = Object.keys(k);
4248
4330
  A = 0;
4249
- function X(Y) {
4250
- for (var Z = 0; Z < Y.length; Z++) {
4251
- if (A >= te.length)
4331
+ function X(q) {
4332
+ for (var Z = 0; Z < q.length; Z++) {
4333
+ if (A >= re.length)
4252
4334
  return;
4253
- var F = Y[Z];
4335
+ var F = q[Z];
4254
4336
  if (typeof F == "string" || typeof F.content == "string") {
4255
- var L = te[A], B = typeof F == "string" ? F : (
4337
+ var L = re[A], B = typeof F == "string" ? F : (
4256
4338
  /** @type {string} */
4257
4339
  F.content
4258
4340
  ), ee = B.indexOf(L);
4259
4341
  if (ee !== -1) {
4260
4342
  ++A;
4261
- var R = B.substring(0, ee), E = f(k[L]), S = B.substring(ee + L.length), x = [];
4262
- if (R && x.push(R), x.push(E), S) {
4343
+ var x = B.substring(0, ee), E = f(k[L]), S = B.substring(ee + L.length), R = [];
4344
+ if (x && R.push(x), R.push(E), S) {
4263
4345
  var w = [S];
4264
- X(w), x.push.apply(x, w);
4346
+ X(w), R.push.apply(R, w);
4265
4347
  }
4266
- typeof F == "string" ? (Y.splice.apply(Y, [Z, 1].concat(x)), Z += x.length - 1) : F.content = x;
4348
+ typeof F == "string" ? (q.splice.apply(q, [Z, 1].concat(R)), Z += R.length - 1) : F.content = R;
4267
4349
  }
4268
4350
  } else {
4269
4351
  var O = F.content;
@@ -4288,21 +4370,21 @@ m.languages.sql = {
4288
4370
  for (var _ = 0, A = h.length; _ < A; _++) {
4289
4371
  var k = h[_];
4290
4372
  if (typeof k != "string") {
4291
- var $ = k.content;
4292
- if (!Array.isArray($)) {
4293
- typeof $ != "string" && y([$]);
4373
+ var N = k.content;
4374
+ if (!Array.isArray(N)) {
4375
+ typeof N != "string" && y([N]);
4294
4376
  continue;
4295
4377
  }
4296
4378
  if (k.type === "template-string") {
4297
- var M = $[1];
4298
- if ($.length === 3 && typeof M != "string" && M.type === "embedded-code") {
4299
- var te = c(M), X = M.alias, Y = Array.isArray(X) ? X[0] : X, Z = e.languages[Y];
4379
+ var M = N[1];
4380
+ if (N.length === 3 && typeof M != "string" && M.type === "embedded-code") {
4381
+ var re = c(M), X = M.alias, q = Array.isArray(X) ? X[0] : X, Z = e.languages[q];
4300
4382
  if (!Z)
4301
4383
  continue;
4302
- $[1] = b(te, Z, Y);
4384
+ N[1] = b(re, Z, q);
4303
4385
  }
4304
4386
  } else
4305
- y($);
4387
+ y(N);
4306
4388
  }
4307
4389
  }
4308
4390
  }
@@ -5751,7 +5833,7 @@ const ea = {
5751
5833
  unstyled: _,
5752
5834
  radius: A,
5753
5835
  getPrismTheme: k,
5754
- variant: $
5836
+ variant: N
5755
5837
  } = r, M = Jn(r, [
5756
5838
  "className",
5757
5839
  "children",
@@ -5770,14 +5852,14 @@ const ea = {
5770
5852
  "radius",
5771
5853
  "getPrismTheme",
5772
5854
  "variant"
5773
- ]), te = h && typeof s == "string" ? s.trim() : s, X = te.split(`
5774
- `).length.toString().length, Y = Dr(), Z = Hr(), F = y || Y.colorScheme, { classes: L, cx: B } = Kn({
5855
+ ]), re = h && typeof s == "string" ? s.trim() : s, X = re.split(`
5856
+ `).length.toString().length, q = Dr(), Z = Hr(), F = y || q.colorScheme, { classes: L, cx: B } = Kn({
5775
5857
  colorScheme: F,
5776
5858
  native: g !== Yt,
5777
5859
  maxLineSize: X,
5778
5860
  radius: A
5779
- }, { name: "Prism", classNames: p, styles: d, unstyled: _, variant: $ });
5780
- return /* @__PURE__ */ K.createElement(se, ze(Ie({
5861
+ }, { name: "Prism", classNames: p, styles: d, unstyled: _, variant: N });
5862
+ return /* @__PURE__ */ K.createElement(le, ze(Ie({
5781
5863
  className: B(L.root, n),
5782
5864
  ref: t
5783
5865
  }, M), {
@@ -5793,49 +5875,49 @@ const ea = {
5793
5875
  }, /* @__PURE__ */ K.createElement(vt, {
5794
5876
  className: L.copy,
5795
5877
  "aria-label": Z.copied ? b : f,
5796
- onClick: () => Z.copy(te),
5878
+ onClick: () => Z.copy(re),
5797
5879
  unstyled: _
5798
5880
  }, /* @__PURE__ */ K.createElement(Zt, {
5799
5881
  copied: Z.copied
5800
5882
  }))), /* @__PURE__ */ K.createElement(Hn, ze(Ie({}, Mn), {
5801
- theme: k(Y, F),
5802
- code: te,
5883
+ theme: k(q, F),
5884
+ code: re,
5803
5885
  language: o
5804
5886
  }), ({
5805
5887
  className: ee,
5806
- style: R,
5888
+ style: x,
5807
5889
  tokens: E,
5808
5890
  getLineProps: S,
5809
- getTokenProps: x
5891
+ getTokenProps: R
5810
5892
  }) => /* @__PURE__ */ K.createElement(g, {
5811
5893
  className: L.scrollArea,
5812
5894
  dir: "ltr"
5813
5895
  }, /* @__PURE__ */ K.createElement("pre", {
5814
5896
  className: B(L.code, ee),
5815
- style: R,
5897
+ style: x,
5816
5898
  dir: "ltr"
5817
5899
  }, E.map((w, O) => {
5818
- var I, N, H, j;
5900
+ var I, $, j, V;
5819
5901
  if (O === E.length - 1 && w.length === 1 && w[0].content === `
5820
5902
  `)
5821
5903
  return null;
5822
- const G = O + 1, le = S({ line: w, key: O }), ce = G in c, pe = F === "dark" ? Y.fn.rgba(Y.fn.themeColor((I = c[G]) == null ? void 0 : I.color, 9), 0.25) : Y.fn.themeColor((N = c[G]) == null ? void 0 : N.color, 0);
5823
- return /* @__PURE__ */ K.createElement("div", ze(Ie({}, le), {
5824
- className: B(L.line, le.className),
5825
- style: Ie({}, ce ? { backgroundColor: pe } : null)
5904
+ const G = O + 1, te = S({ line: w, key: O }), ge = G in c, ce = F === "dark" ? q.fn.rgba(q.fn.themeColor((I = c[G]) == null ? void 0 : I.color, 9), 0.25) : q.fn.themeColor(($ = c[G]) == null ? void 0 : $.color, 0);
5905
+ return /* @__PURE__ */ K.createElement("div", ze(Ie({}, te), {
5906
+ className: B(L.line, te.className),
5907
+ style: Ie({}, ge ? { backgroundColor: ce } : null)
5826
5908
  }), u && /* @__PURE__ */ K.createElement("div", {
5827
5909
  className: L.lineNumber,
5828
5910
  style: {
5829
- color: ce ? Y.fn.themeColor((H = c[G]) == null ? void 0 : H.color, F === "dark" ? 5 : 8) : void 0
5911
+ color: ge ? q.fn.themeColor((j = c[G]) == null ? void 0 : j.color, F === "dark" ? 5 : 8) : void 0
5830
5912
  }
5831
- }, ((j = c[G]) == null ? void 0 : j.label) || G), /* @__PURE__ */ K.createElement("div", {
5913
+ }, ((V = c[G]) == null ? void 0 : V.label) || G), /* @__PURE__ */ K.createElement("div", {
5832
5914
  className: L.lineContent
5833
- }, w.map((ye, fe) => {
5834
- var re, de;
5835
- const ve = x({ token: ye, key: fe });
5836
- return /* @__PURE__ */ K.createElement("span", ze(Ie({}, ve), {
5837
- style: ze(Ie({}, ve.style), {
5838
- color: ce ? Y.fn.themeColor((re = c[G]) == null ? void 0 : re.color, F === "dark" ? 5 : 8) : (de = ve == null ? void 0 : ve.style) == null ? void 0 : de.color
5915
+ }, w.map((ve, fe) => {
5916
+ var ne, de;
5917
+ const me = R({ token: ve, key: fe });
5918
+ return /* @__PURE__ */ K.createElement("span", ze(Ie({}, me), {
5919
+ style: ze(Ie({}, me.style), {
5920
+ color: ge ? q.fn.themeColor((ne = c[G]) == null ? void 0 : ne.color, F === "dark" ? 5 : 8) : (de = me == null ? void 0 : me.style) == null ? void 0 : de.color
5839
5921
  })
5840
5922
  }));
5841
5923
  })));
@@ -5971,14 +6053,14 @@ function ua({
5971
6053
  }) {
5972
6054
  const n = Ge(), s = async () => {
5973
6055
  if (e) {
5974
- be({
6056
+ ye({
5975
6057
  id: "for-deleting",
5976
6058
  title: "Pending",
5977
6059
  message: "Deleting SQL Snippet...",
5978
6060
  loading: !0
5979
6061
  });
5980
6062
  try {
5981
- await oe.sql_snippet.delete(e), J({
6063
+ await se.sql_snippet.delete(e), J({
5982
6064
  id: "for-deleting",
5983
6065
  title: "Successful",
5984
6066
  message: `SQL Snippet [${e}] is deleted`,
@@ -6005,7 +6087,7 @@ function ua({
6005
6087
  color: "red"
6006
6088
  }
6007
6089
  });
6008
- return /* @__PURE__ */ a(V, { size: r.button.size, color: "red", onClick: o, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
6090
+ return /* @__PURE__ */ a(Y, { size: r.button.size, color: "red", onClick: o, leftIcon: /* @__PURE__ */ a(ot, { size: 20 }), children: "Delete" });
6009
6091
  }
6010
6092
  function ca({
6011
6093
  content: e
@@ -6027,7 +6109,7 @@ function Ta({
6027
6109
  } = xe(async () => {
6028
6110
  const {
6029
6111
  data: o
6030
- } = await oe.sql_snippet.list({
6112
+ } = await se.sql_snippet.list({
6031
6113
  pagination: {
6032
6114
  page: 1,
6033
6115
  pagesize: 10
@@ -6039,7 +6121,7 @@ function Ta({
6039
6121
  });
6040
6122
  return /* @__PURE__ */ C(he, { children: [
6041
6123
  /* @__PURE__ */ a(Q, { pt: e.spacing, position: "right", children: /* @__PURE__ */ a(Ln, { onSuccess: s }) }),
6042
- /* @__PURE__ */ C(se, { mt: e.spacing, sx: {
6124
+ /* @__PURE__ */ C(le, { mt: e.spacing, sx: {
6043
6125
  position: "relative"
6044
6126
  }, children: [
6045
6127
  /* @__PURE__ */ a(rt, { visible: n }),
@@ -6073,11 +6155,11 @@ function Ta({
6073
6155
  ] })
6074
6156
  ] });
6075
6157
  }
6076
- const Ra = () => import("./package-1c105a67.mjs").then(({
6158
+ const Ra = () => import("./package-42274ce9.mjs").then(({
6077
6159
  version: e
6078
6160
  }) => (console.log(`[@devtable/dashboard] version: ${e}`), e));
6079
6161
  export {
6080
- ae as APIClient,
6162
+ ie as APIClient,
6081
6163
  ka as APIKeyList,
6082
6164
  _a as AccountList,
6083
6165
  Cn as AddAPIKey,