@arcblock/ux 3.0.10 → 3.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. package/lib/ActivityIndicator/index.js +16 -16
  2. package/lib/Alert/index.js +17 -17
  3. package/lib/AnimationWaiter/index.js +13 -13
  4. package/lib/Blocklet/blocklet.js +15 -15
  5. package/lib/Blocklet/utils.d.ts +1 -1
  6. package/lib/Blocklet/utils.js +6 -5
  7. package/lib/BlockletNFT/index.js +23 -23
  8. package/lib/BlockletV2/utils.d.ts +1 -1
  9. package/lib/BlockletV2/utils.js +7 -6
  10. package/lib/Center/index.js +7 -6
  11. package/lib/CodeBlock/LightBox.d.ts +2 -3
  12. package/lib/CodeBlock/LightBox.js +3 -2
  13. package/lib/CookieConsent/index.js +1 -1
  14. package/lib/CountDown/index.js +24 -23
  15. package/lib/Datatable/CustomToolbar.js +71 -71
  16. package/lib/Datatable/TableSearch.js +18 -18
  17. package/lib/Datatable/index.js +77 -77
  18. package/lib/Earth/index.js +47 -46
  19. package/lib/Footer/index.js +8 -8
  20. package/lib/Icon/image.js +17 -16
  21. package/lib/InfoRow/index.js +11 -11
  22. package/lib/Layout/dashboard/index.js +2 -2
  23. package/lib/Layout/dashboard/sidebar.js +12 -12
  24. package/lib/Layout/dashboard-legacy/index.js +20 -20
  25. package/lib/Layout/dashboard-legacy/sidebar.js +16 -16
  26. package/lib/Layout/index.js +29 -29
  27. package/lib/Metric/index.js +9 -9
  28. package/lib/NFTDisplay/svg-embedder/inline-svg.js +7 -6
  29. package/lib/PricingTable/index.js +9 -9
  30. package/lib/Result/result.js +14 -14
  31. package/lib/Screenshot/BaseScreenshot/index.js +10 -9
  32. package/lib/Screenshot/index.js +27 -26
  33. package/lib/Video/index.js +11 -11
  34. package/lib/Wallet/Action.js +12 -12
  35. package/lib/Wallet/Download.js +11 -11
  36. package/lib/WechatPrompt/index.js +1 -1
  37. package/package.json +8 -8
  38. package/src/ActivityIndicator/index.jsx +3 -2
  39. package/src/Address/Address.stories.jsx +2 -1
  40. package/src/Alert/index.jsx +2 -2
  41. package/src/AnimationWaiter/index.jsx +2 -2
  42. package/src/Blocklet/blocklet.jsx +2 -2
  43. package/src/Blocklet/utils.jsx +2 -1
  44. package/src/BlockletNFT/index.jsx +2 -2
  45. package/src/BlockletV2/utils.js +2 -1
  46. package/src/Center/index.tsx +2 -1
  47. package/src/CodeBlock/LightBox.tsx +2 -1
  48. package/src/Colors/Colors.stories.jsx +1 -1
  49. package/src/CookieConsent/index.tsx +1 -1
  50. package/src/CountDown/index.tsx +2 -2
  51. package/src/DID/DID.stories.jsx +2 -1
  52. package/src/Datatable/CustomToolbar.jsx +3 -2
  53. package/src/Datatable/TableSearch.jsx +2 -2
  54. package/src/Datatable/index.jsx +4 -4
  55. package/src/Earth/index.tsx +3 -2
  56. package/src/Footer/index.tsx +1 -1
  57. package/src/Icon/image.tsx +2 -1
  58. package/src/InfoRow/index.tsx +2 -2
  59. package/src/Layout/dashboard/index.tsx +1 -1
  60. package/src/Layout/dashboard/sidebar.tsx +2 -2
  61. package/src/Layout/dashboard-legacy/index.tsx +1 -1
  62. package/src/Layout/dashboard-legacy/sidebar.tsx +2 -2
  63. package/src/Layout/index.tsx +2 -1
  64. package/src/Metric/index.tsx +2 -2
  65. package/src/NFTDisplay/svg-embedder/inline-svg.tsx +2 -2
  66. package/src/PricingTable/index.tsx +2 -2
  67. package/src/Result/result.tsx +1 -1
  68. package/src/Screenshot/BaseScreenshot/index.tsx +2 -2
  69. package/src/Screenshot/index.tsx +3 -3
  70. package/src/Video/index.tsx +2 -2
  71. package/src/Wallet/Action.tsx +2 -2
  72. package/src/Wallet/Download.tsx +2 -2
  73. package/src/WechatPrompt/index.tsx +1 -1
@@ -1,14 +1,15 @@
1
- import { jsxs as m, jsx as n } from "react/jsx-runtime";
2
- import { useReducer as U, useRef as w, useEffect as H } from "react";
3
- import J from "react-use/lib/useSpring";
1
+ import { jsxs as u, jsx as n } from "react/jsx-runtime";
2
+ import { useReducer as H, useRef as w, useEffect as J } from "react";
3
+ import V from "react-use/lib/useSpring";
4
4
  import * as N from "d3-geo";
5
- import * as V from "topojson-client";
5
+ import * as X from "topojson-client";
6
6
  import D from "versor";
7
- import R from "./countries.json.js";
8
- import X from "./util.js";
9
- import { withDeprecated as Y } from "../Util/deprecate.js";
10
- import { styled as B } from "../Theme/index.js";
11
- const F = V.feature(R, R.objects.ne_110m_admin_0_countries), K = {
7
+ import { Box as R } from "@mui/material";
8
+ import B from "./countries.json.js";
9
+ import Y from "./util.js";
10
+ import { withDeprecated as K } from "../Util/deprecate.js";
11
+ import { styled as I } from "../Theme/index.js";
12
+ const F = X.feature(B, B.objects.ne_110m_admin_0_countries), Q = {
12
13
  light: {
13
14
  ocean: "#EDF4F4",
14
15
  graticule: "#EDF4F4",
@@ -28,7 +29,7 @@ const F = V.feature(R, R.objects.ne_110m_admin_0_countries), K = {
28
29
  activeMarker: "#FFD159"
29
30
  }
30
31
  };
31
- function Q(e, s) {
32
+ function W(e, s) {
32
33
  switch (s.type) {
33
34
  case "dragEnd":
34
35
  return { ...e, isDragging: !1 };
@@ -46,17 +47,17 @@ function Q(e, s) {
46
47
  return e;
47
48
  }
48
49
  }
49
- function W({
50
+ function Z({
50
51
  theme: e = "dark",
51
52
  width: s = 1200,
52
53
  height: g = 600,
53
- enableRotation: I = !1,
54
- rotationSpeed: M = 5,
54
+ enableRotation: M = !1,
55
+ rotationSpeed: L = 5,
55
56
  activeMarkerId: i = void 0,
56
57
  markers: y = [],
57
- colors: L = {}
58
+ colors: S = {}
58
59
  }) {
59
- const $ = Object.assign(L, K[e]), [r, d] = U(Q, {
60
+ const $ = Object.assign(S, Q[e]), [r, d] = H(W, {
60
61
  rotation: [0, 0, 0],
61
62
  isDragging: !1,
62
63
  animateDuration: 1,
@@ -70,7 +71,7 @@ function W({
70
71
  step: 0,
71
72
  markerId: null,
72
73
  iv: null
73
- }), C = J(r.animateDuration, 170, 26), S = i && k.current.markerId !== i && y.some((t) => t.id === i), p = N.geoOrthographic().fitExtent(
74
+ }), C = V(r.animateDuration, 170, 26), T = i && k.current.markerId !== i && y.some((t) => t.id === i), p = N.geoOrthographic().fitExtent(
74
75
  [
75
76
  [30, 30],
76
77
  [s - 30, g - 30]
@@ -79,18 +80,18 @@ function W({
79
80
  ).rotate(
80
81
  C <= 1 || r.isDragging || !i ? r.rotation : k.current.iv(C / r.animateDuration)
81
82
  ), P = N.geoPath().projection(p).pointRadius(2);
82
- H(() => {
83
- if (S) {
84
- let { p1: t, p2: o, r1: a, r2: u, markerId: c } = k.current;
83
+ J(() => {
84
+ if (T) {
85
+ let { p1: t, p2: o, r1: a, r2: m, markerId: c } = k.current;
85
86
  if (c !== i && !r.isDragging) {
86
87
  const l = y.find((v) => v.id === i);
87
- t = o, o = [l.longitude, l.latitude], a = u, u = [-o[0], 20 - o[1], p.rotate()[2]];
88
- const h = X.interpolateAngles(a, u);
88
+ t = o, o = [l.longitude, l.latitude], a = m, m = [-o[0], 20 - o[1], p.rotate()[2]];
89
+ const h = Y.interpolateAngles(a, m);
89
90
  Object.assign(k.current, {
90
91
  p1: t,
91
92
  p2: o,
92
93
  r1: a,
93
- r2: u,
94
+ r2: m,
94
95
  iv: h,
95
96
  markerId: i
96
97
  });
@@ -102,9 +103,9 @@ function W({
102
103
  }
103
104
  });
104
105
  }
105
- } else if (I) {
106
+ } else if (M) {
106
107
  const t = window.requestAnimationFrame(() => {
107
- const o = [r.rotation[0] + 2 / M, r.rotation[1], r.rotation[2]];
108
+ const o = [r.rotation[0] + 2 / L, r.rotation[1], r.rotation[2]];
108
109
  d({ type: "rotate", payload: { rotation: o } });
109
110
  });
110
111
  return function() {
@@ -115,13 +116,13 @@ function W({
115
116
  const b = (t) => {
116
117
  const o = E.current, a = o?.getBoundingClientRect();
117
118
  return [t.clientX - a.left - o.clientLeft, t.clientY - a.top - o.clientTop];
118
- }, T = (t) => {
119
+ }, z = (t) => {
119
120
  const o = b(t);
120
121
  o[0] && (x.current.v0 = D.cartesian(p.invert(o)), x.current.r0 = p.rotate(), x.current.q0 = D(x.current.r0), d({ type: "dragStart", payload: { mousePosition: o } }));
121
- }, z = (t) => {
122
+ }, G = (t) => {
122
123
  if (r.isDragging === !1)
123
124
  return;
124
- const o = b(t), { r0: a, v0: u, q0: c } = x.current, l = D.cartesian(p.rotate(a).invert(o)), h = D.multiply(c, D.delta(u, l)), f = D.rotation(h);
125
+ const o = b(t), { r0: a, v0: m, q0: c } = x.current, l = D.cartesian(p.rotate(a).invert(o)), h = D.multiply(c, D.delta(m, l)), f = D.rotation(h);
125
126
  d({ type: "rotate", payload: { rotation: f, mousePosition: o } });
126
127
  }, j = () => {
127
128
  setTimeout(() => {
@@ -130,9 +131,9 @@ function W({
130
131
  }, A = (t, o) => d({
131
132
  type: "tooltip",
132
133
  payload: { tooltipIndex: o, mousePosition: b(t) }
133
- }), O = () => d({ type: "tooltip", payload: { tooltipIndex: -1, mousePosition: null } }), G = () => y.map((t, o) => {
134
- const a = [t.longitude, t.latitude], u = N.geoDistance(a, p.invert([s / 2, g / 2])), c = p(a), l = i === t.id, h = u > 1.57 ? "none" : l ? $.activeMarker : $.marker, f = l ? 9 : 6;
135
- return /* @__PURE__ */ m(
134
+ }), O = () => d({ type: "tooltip", payload: { tooltipIndex: -1, mousePosition: null } }), q = () => y.map((t, o) => {
135
+ const a = [t.longitude, t.latitude], m = N.geoDistance(a, p.invert([s / 2, g / 2])), c = p(a), l = i === t.id, h = m > 1.57 ? "none" : l ? $.activeMarker : $.marker, f = l ? 9 : 6;
136
+ return /* @__PURE__ */ u(
136
137
  "g",
137
138
  {
138
139
  className: `marker ${l ? "marker--active" : ""}`,
@@ -173,13 +174,13 @@ function W({
173
174
  },
174
175
  t.id
175
176
  );
176
- }), q = () => {
177
+ }), U = () => {
177
178
  if (r.tooltipIndex >= 0) {
178
179
  const t = y[r.tooltipIndex];
179
- return /* @__PURE__ */ m(oo, { style: { left: r.mousePosition?.[0] ?? 0, top: r.mousePosition?.[1] ?? 0 }, children: [
180
+ return /* @__PURE__ */ u(to, { style: { left: r.mousePosition?.[0] ?? 0, top: r.mousePosition?.[1] ?? 0 }, children: [
180
181
  /* @__PURE__ */ n("p", { className: "title", children: t.title }),
181
182
  /* @__PURE__ */ n("p", { className: "description", children: t.description }),
182
- /* @__PURE__ */ m("p", { className: "description", children: [
183
+ /* @__PURE__ */ u("p", { className: "description", children: [
183
184
  "ID: ",
184
185
  t.id
185
186
  ] })
@@ -193,16 +194,16 @@ function W({
193
194
  (o) => o.properties && o.properties.name && o.properties.name === t.country
194
195
  );
195
196
  }
196
- return /* @__PURE__ */ m(Z, { width: s, height: g, $theme: e, colors: $, onMouseLeave: j, children: [
197
- q(),
198
- /* @__PURE__ */ m(
197
+ return /* @__PURE__ */ u(oo, { width: s, height: g, $theme: e, colors: $, onMouseLeave: j, children: [
198
+ U(),
199
+ /* @__PURE__ */ u(
199
200
  "svg",
200
201
  {
201
202
  className: "earth",
202
203
  width: s,
203
204
  height: g,
204
- onMouseDown: T,
205
- onMouseMove: z,
205
+ onMouseDown: z,
206
+ onMouseMove: G,
206
207
  onMouseUp: j,
207
208
  ref: E,
208
209
  children: [
@@ -217,7 +218,7 @@ function W({
217
218
  },
218
219
  t.properties.name
219
220
  )) }),
220
- /* @__PURE__ */ n("g", { className: "markers", children: G() }),
221
+ /* @__PURE__ */ n("g", { className: "markers", children: q() }),
221
222
  r.isDragging && r.mousePosition && /* @__PURE__ */ n(
222
223
  "path",
223
224
  {
@@ -231,12 +232,12 @@ function W({
231
232
  ]
232
233
  }
233
234
  ),
234
- /* @__PURE__ */ n("svg", { className: "defs", children: /* @__PURE__ */ m("defs", { children: [
235
- /* @__PURE__ */ m("linearGradient", { id: "gradBlue", x1: "0%", y1: "0%", x2: "100%", y2: "0%", children: [
235
+ /* @__PURE__ */ n("svg", { className: "defs", children: /* @__PURE__ */ u("defs", { children: [
236
+ /* @__PURE__ */ u("linearGradient", { id: "gradBlue", x1: "0%", y1: "0%", x2: "100%", y2: "0%", children: [
236
237
  /* @__PURE__ */ n("stop", { offset: "0%", style: { stopColor: "#005C99", stopOpacity: 1 } }),
237
238
  /* @__PURE__ */ n("stop", { offset: "100%", style: { stopColor: "#0099FF", stopOpacity: 1 } })
238
239
  ] }),
239
- /* @__PURE__ */ m("filter", { id: "glow", children: [
240
+ /* @__PURE__ */ u("filter", { id: "glow", children: [
240
241
  /* @__PURE__ */ n(
241
242
  "feColorMatrix",
242
243
  {
@@ -248,7 +249,7 @@ function W({
248
249
  }
249
250
  ),
250
251
  /* @__PURE__ */ n("feGaussianBlur", { stdDeviation: "5.5", result: "coloredBlur" }),
251
- /* @__PURE__ */ m("feMerge", { children: [
252
+ /* @__PURE__ */ u("feMerge", { children: [
252
253
  /* @__PURE__ */ n("feMergeNode", { in: "coloredBlur" }),
253
254
  /* @__PURE__ */ n("feMergeNode", { in: "SourceGraphic" })
254
255
  ] })
@@ -256,7 +257,7 @@ function W({
256
257
  ] }) })
257
258
  ] });
258
259
  }
259
- const lo = Y(W, { name: "Earth" }), Z = B("div")`
260
+ const mo = K(Z, { name: "Earth" }), oo = I(R)`
260
261
  background-color: ${(e) => e.$theme === "light" ? "#f7f7f7" : "#222"};
261
262
  width: ${(e) => e.width}px;
262
263
  height: ${(e) => e.height}px;
@@ -337,7 +338,7 @@ const lo = Y(W, { name: "Earth" }), Z = B("div")`
337
338
  transform: scale3d(1.5, 1.5, 1.5);
338
339
  }
339
340
  }
340
- `, oo = B("div")`
341
+ `, to = I(R)`
341
342
  position: absolute;
342
343
  width: auto;
343
344
  min-width: 90px;
@@ -375,5 +376,5 @@ const lo = Y(W, { name: "Earth" }), Z = B("div")`
375
376
  }
376
377
  `;
377
378
  export {
378
- lo as default
379
+ mo as default
379
380
  };
@@ -1,19 +1,19 @@
1
1
  import { jsxs as o, jsx as t } from "react/jsx-runtime";
2
- import { Container as f, Typography as r, Box as h } from "@mui/material";
2
+ import { Box as s, Container as h, Typography as r } from "@mui/material";
3
3
  import { mergeProps as g } from "../Util/index.js";
4
4
  import w from "../Logo/index.js";
5
5
  import { styled as y } from "../Theme/index.js";
6
6
  function u({ ...e }) {
7
- const s = g(e, u, ["dark", "style"]), { className: p = "", copyStart: d = "2017", style: m = {}, brand: c = "ArcBlock", dark: n = !1, addon: a = null } = s, i = `${(/* @__PURE__ */ new Date()).getFullYear()}`, l = `${d}`, x = i === l ? i : `${l}-${i}`;
8
- return /* @__PURE__ */ o(b, { className: p, style: m, dark: n, children: [
9
- /* @__PURE__ */ t(f, { maxWidth: !1, children: /* @__PURE__ */ o(r, { component: "div", className: "footer", children: [
7
+ const p = g(e, u, ["dark", "style"]), { className: d = "", copyStart: m = "2017", style: c = {}, brand: x = "ArcBlock", dark: n = !1, addon: a = null } = p, i = `${(/* @__PURE__ */ new Date()).getFullYear()}`, l = `${m}`, f = i === l ? i : `${l}-${i}`;
8
+ return /* @__PURE__ */ o(b, { className: d, style: c, dark: n, children: [
9
+ /* @__PURE__ */ t(h, { maxWidth: !1, children: /* @__PURE__ */ o(r, { component: "div", className: "footer", children: [
10
10
  /* @__PURE__ */ o(r, { component: "p", className: "footer-item", children: [
11
11
  /* @__PURE__ */ o("span", { className: "footer-copy", children: [
12
12
  "Copyright © ",
13
- x,
13
+ f,
14
14
  " "
15
15
  ] }),
16
- /* @__PURE__ */ t("span", { className: "footer-brand", children: c })
16
+ /* @__PURE__ */ t("span", { className: "footer-brand", children: x })
17
17
  ] }),
18
18
  a && /* @__PURE__ */ t(
19
19
  r,
@@ -30,7 +30,7 @@ function u({ ...e }) {
30
30
  ] })
31
31
  ] }) }),
32
32
  /* @__PURE__ */ t(
33
- h,
33
+ s,
34
34
  {
35
35
  sx: {
36
36
  position: "absolute",
@@ -45,7 +45,7 @@ function u({ ...e }) {
45
45
  )
46
46
  ] });
47
47
  }
48
- const b = y("div", {
48
+ const b = y(s, {
49
49
  shouldForwardProp: (e) => e !== "dark"
50
50
  })`
51
51
  position: relative;
package/lib/Icon/image.js CHANGED
@@ -1,33 +1,34 @@
1
- import { jsxs as x, jsx as i } from "react/jsx-runtime";
2
- import h from "../Img/index.js";
3
- import { styled as n } from "../Theme/index.js";
4
- function f({
1
+ import { jsxs as d, jsx as r } from "react/jsx-runtime";
2
+ import { Box as h } from "@mui/material";
3
+ import n from "../Img/index.js";
4
+ import { styled as l } from "../Theme/index.js";
5
+ function w({
5
6
  name: o,
6
7
  size: t = 36,
7
- alt: p = "",
8
- color: r = "#000000",
8
+ alt: i = "",
9
+ color: p = "#000000",
9
10
  prefix: e = "/images",
10
11
  showBadge: a = !1,
11
12
  style: s = {},
12
- ...d
13
+ ...x
13
14
  }) {
14
- const g = `${e}/${o}-${r.replace(/^#/, "")}.png`;
15
- return /* @__PURE__ */ x(l, { style: { width: t, height: t }, children: [
16
- /* @__PURE__ */ i(
17
- h,
15
+ const g = `${e}/${o}-${p.replace(/^#/, "")}.png`;
16
+ return /* @__PURE__ */ d(c, { style: { width: t, height: t }, children: [
17
+ /* @__PURE__ */ r(
18
+ n,
18
19
  {
19
20
  width: t,
20
21
  height: t,
21
- alt: p || o,
22
+ alt: i || o,
22
23
  src: g,
23
24
  style: Object.assign({ width: t }, s),
24
- ...d
25
+ ...x
25
26
  }
26
27
  ),
27
- a && /* @__PURE__ */ i("i", { className: "badge-point" })
28
+ a && /* @__PURE__ */ r("i", { className: "badge-point" })
28
29
  ] });
29
30
  }
30
- const l = n("div")`
31
+ const c = l(h)`
31
32
  position: relative;
32
33
  .badge-point {
33
34
  position: absolute;
@@ -43,5 +44,5 @@ const l = n("div")`
43
44
  }
44
45
  `;
45
46
  export {
46
- f as default
47
+ w as default
47
48
  };
@@ -1,23 +1,23 @@
1
- import { jsxs as p, jsx as i } from "react/jsx-runtime";
2
- import c from "lodash/camelCase";
3
- import x from "lodash/upperFirst";
4
- import { Typography as e } from "@mui/material";
1
+ import { jsxs as p, jsx as e } from "react/jsx-runtime";
2
+ import x from "lodash/camelCase";
3
+ import c from "lodash/upperFirst";
4
+ import { Box as u, Typography as i } from "@mui/material";
5
5
  import { styled as d } from "../Theme/index.js";
6
- function v({
6
+ function $({
7
7
  name: t,
8
- nameFormatter: a = (o) => typeof o == "string" ? o.split(" ").map((s) => x(c(s))).join(" ") : o,
8
+ nameFormatter: a = (o) => typeof o == "string" ? o.split(" ").map((s) => c(x(s))).join(" ") : o,
9
9
  layout: n = "horizontal",
10
10
  children: r,
11
11
  valueComponent: l = "div",
12
12
  nameWidth: m = 90,
13
13
  ...f
14
14
  }) {
15
- return /* @__PURE__ */ p(u, { layout: n, width: m, ...f, children: [
16
- /* @__PURE__ */ i(e, { color: "textSecondary", className: "info-row__name", children: a(t) }),
17
- r && /* @__PURE__ */ i(e, { color: "textPrimary", component: l, className: "info-row__value", children: r })
15
+ return /* @__PURE__ */ p(w, { layout: n, width: m, ...f, children: [
16
+ /* @__PURE__ */ e(i, { color: "textSecondary", className: "info-row__name", children: a(t) }),
17
+ r && /* @__PURE__ */ e(i, { color: "textPrimary", component: l, className: "info-row__value", children: r })
18
18
  ] });
19
19
  }
20
- const u = d("div")`
20
+ const w = d(u)`
21
21
  display: flex;
22
22
  flex-direction: ${(t) => t.layout === "vertical" ? "column" : "row"};
23
23
  justify-content: flex-start;
@@ -54,5 +54,5 @@ const u = d("div")`
54
54
  }
55
55
  `;
56
56
  export {
57
- v as default
57
+ $ as default
58
58
  };
@@ -2,7 +2,7 @@ import { jsx as r, jsxs as n } from "react/jsx-runtime";
2
2
  import { useMemo as M, useEffect as f } from "react";
3
3
  import { useLocation as p, matchPath as z } from "react-router-dom";
4
4
  import D from "react-helmet";
5
- import { useTheme as R, Box as d, Container as T } from "@mui/material";
5
+ import { Box as d, useTheme as R, Container as T } from "@mui/material";
6
6
  import V from "clsx";
7
7
  import { CloseFullscreen as B, OpenInFull as U } from "@mui/icons-material";
8
8
  import E from "../dashboard-legacy/index.js";
@@ -115,7 +115,7 @@ function Q({
115
115
  )
116
116
  ] });
117
117
  }
118
- const X = u("div", {
118
+ const X = u(d, {
119
119
  shouldForwardProp: (e) => e !== "sidebarWidth"
120
120
  })`
121
121
  &.dashboard {
@@ -1,39 +1,39 @@
1
1
  import { jsxs as o, jsx as t } from "react/jsx-runtime";
2
- import { Typography as x } from "@mui/material";
2
+ import { Box as x, Typography as b } from "@mui/material";
3
3
  import n from "clsx";
4
- import { styled as b } from "../../Theme/index.js";
5
- import { NavLink as c } from "./external-link.js";
4
+ import { styled as c } from "../../Theme/index.js";
5
+ import { NavLink as h } from "./external-link.js";
6
6
  function d(e, i) {
7
7
  if (e.children?.length)
8
- return h(e, i);
8
+ return m(e, i);
9
9
  const { url: a, icon: r, title: p, showBadge: s, external: l, active: u } = e;
10
10
  return /* @__PURE__ */ t("li", { className: "layout-sidebar-item", children: /* @__PURE__ */ o(
11
- c,
11
+ h,
12
12
  {
13
13
  external: l,
14
14
  to: a,
15
15
  className: ({ isActive: g }) => n("layout-sidebar-link", { "layout-sidebar-link--active": l ? u : g }),
16
16
  children: [
17
17
  r && /* @__PURE__ */ t("span", { className: `layout-sidebar-icon ${s ? "layout-sidebar-badge" : ""}`, children: r }),
18
- /* @__PURE__ */ t(x, { component: "span", className: "layout-sidebar-link-text", children: p })
18
+ /* @__PURE__ */ t(b, { component: "span", className: "layout-sidebar-link-text", children: p })
19
19
  ]
20
20
  }
21
21
  ) }, `${a}-${i}`);
22
22
  }
23
- function h(e, i) {
23
+ function m(e, i) {
24
24
  return /* @__PURE__ */ o("li", { className: "layout-sidebar-group", children: [
25
25
  /* @__PURE__ */ t("span", { className: "layout-sidebar-group-title", children: e.title }),
26
26
  /* @__PURE__ */ t("ul", { children: e.children.map(d) })
27
27
  ] }, `group-${e.title}-${i}`);
28
28
  }
29
- function N({ links: e, addons: i = void 0, dense: a = !1, ...r }) {
30
- return /* @__PURE__ */ o(y, { ...r, className: n({ "layout-sidebar-dense": a }), children: [
29
+ function z({ links: e, addons: i = void 0, dense: a = !1, ...r }) {
30
+ return /* @__PURE__ */ o(f, { ...r, className: n({ "layout-sidebar-dense": a }), children: [
31
31
  /* @__PURE__ */ t("ul", { children: e.map(d) }),
32
32
  /* @__PURE__ */ t("div", { style: { flex: 1 } }),
33
33
  i
34
34
  ] });
35
35
  }
36
- const m = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230, 0))", y = b("div")`
36
+ const y = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230, 0))", f = c(x)`
37
37
  display: flex;
38
38
  flex-direction: column;
39
39
  ul {
@@ -52,7 +52,7 @@ const m = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230,
52
52
  &:hover,
53
53
  &.layout-sidebar-link--active {
54
54
  color: ${(e) => e.theme.palette.primary.main};
55
- background: ${m};
55
+ background: ${y};
56
56
  border-left-color: ${(e) => e.theme.palette.primary.main};
57
57
  }
58
58
  }
@@ -160,5 +160,5 @@ const m = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230,
160
160
  }
161
161
  `;
162
162
  export {
163
- N as default
163
+ z as default
164
164
  };
@@ -1,13 +1,13 @@
1
1
  import { jsxs as a, jsx as e } from "react/jsx-runtime";
2
- import { useState as p, useEffect as $ } from "react";
2
+ import { useState as c, useEffect as $ } from "react";
3
3
  import P from "react-helmet";
4
- import { Box as c, Drawer as z, Container as H } from "@mui/material";
4
+ import { Box as t, Drawer as z, Container as H } from "@mui/material";
5
5
  import { useSize as S } from "ahooks";
6
6
  import W from "./sidebar.js";
7
7
  import j from "./header.js";
8
8
  import C from "../../Footer/index.js";
9
9
  import { styled as F } from "../../Theme/index.js";
10
- const O = F("div")`
10
+ const O = F(t)`
11
11
  &.dashboard {
12
12
  display: flex;
13
13
  flex-direction: column;
@@ -38,7 +38,7 @@ const O = F("div")`
38
38
  `;
39
39
  function R({
40
40
  links: o = [],
41
- brand: t = "",
41
+ brand: d = "",
42
42
  description: h = "",
43
43
  images: f,
44
44
  title: b = "Home",
@@ -49,35 +49,35 @@ function R({
49
49
  contentLayout: g = "column",
50
50
  className: y = "",
51
51
  homeUrl: v = "/",
52
- logo: d = void 0,
52
+ logo: s = void 0,
53
53
  children: N,
54
54
  ...k
55
55
  }) {
56
- const r = S(document.body)?.width || 0, [s, M] = p(r >= 960 ? "permanent" : "temporary"), [n, i] = p(s === "permanent");
56
+ const r = S(document.body)?.width || 0, [n, M] = c(r >= 960 ? "permanent" : "temporary"), [i, l] = c(n === "permanent");
57
57
  $(() => {
58
- const m = r >= 960 ? "permanent" : "temporary";
59
- M(m), i(m !== "temporary");
58
+ const p = r >= 960 ? "permanent" : "temporary";
59
+ M(p), l(p !== "temporary");
60
60
  }, [r]);
61
- const l = () => {
62
- i(!n);
61
+ const m = () => {
62
+ l(!i);
63
63
  }, D = _ || g === "row";
64
64
  return /* @__PURE__ */ a(O, { className: `dashboard ${y}`, ...k, children: [
65
- /* @__PURE__ */ e(P, { title: `${b}-${t}` }),
65
+ /* @__PURE__ */ e(P, { title: `${b}-${d}` }),
66
66
  /* @__PURE__ */ e(
67
67
  j,
68
68
  {
69
69
  className: "dashboard__header",
70
- onToggleMenu: l,
71
- brand: t,
70
+ onToggleMenu: m,
71
+ brand: d,
72
72
  brandAddon: u,
73
73
  description: h,
74
74
  addons: w,
75
75
  homeUrl: v,
76
- logo: d
76
+ logo: s
77
77
  }
78
78
  ),
79
79
  /* @__PURE__ */ a(
80
- c,
80
+ t,
81
81
  {
82
82
  className: "dashboard__body",
83
83
  sx: {
@@ -87,16 +87,16 @@ function R({
87
87
  /* @__PURE__ */ e(
88
88
  z,
89
89
  {
90
- variant: s,
90
+ variant: n,
91
91
  className: "drawer",
92
92
  classes: { paper: "drawerPaper" },
93
- open: n,
94
- onClose: l,
93
+ open: i,
94
+ onClose: m,
95
95
  ModalProps: { disablePortal: !0, keepMounted: !0 },
96
- children: /* @__PURE__ */ e(W, { className: "dashboard__sidebar", images: f, links: o, prefix: x, logo: d })
96
+ children: /* @__PURE__ */ e(W, { className: "dashboard__sidebar", images: f, links: o, prefix: x, logo: s })
97
97
  }
98
98
  ),
99
- /* @__PURE__ */ a(c, { className: "dashboard__main", children: [
99
+ /* @__PURE__ */ a(t, { className: "dashboard__main", children: [
100
100
  /* @__PURE__ */ e(H, { maxWidth: D ? !1 : "lg", className: "dashboard__content", children: N }),
101
101
  /* @__PURE__ */ e(C, {})
102
102
  ] })
@@ -1,12 +1,12 @@
1
1
  import { jsxs as a, jsx as t } from "react/jsx-runtime";
2
2
  import { memo as k } from "react";
3
3
  import { useLocation as $, Link as s } from "react-router-dom";
4
- import { Button as w, useTheme as z, Typography as v } from "@mui/material";
4
+ import { Box as w, Button as z, useTheme as v, Typography as I } from "@mui/material";
5
5
  import { teal as l } from "@mui/material/colors";
6
- import I from "../../Icon/image.js";
7
- import j from "../../Logo/index.js";
8
- import { styled as c } from "../../Theme/index.js";
9
- function q({
6
+ import j from "../../Icon/image.js";
7
+ import L from "../../Logo/index.js";
8
+ import { styled as d } from "../../Theme/index.js";
9
+ function C({
10
10
  images: e,
11
11
  links: m,
12
12
  prefix: p = "/images",
@@ -14,14 +14,14 @@ function q({
14
14
  logo: f = void 0,
15
15
  ...x
16
16
  }) {
17
- const u = z(), b = $(), h = (o, n) => new RegExp(`/${n}`).test(b.pathname);
18
- return /* @__PURE__ */ a(L, { ...x, children: [
19
- /* @__PURE__ */ t(s, { to: "/", className: "sidebar-logo", children: f || /* @__PURE__ */ t(j, { showText: !1, size: 20 }) }),
17
+ const u = v(), b = $(), h = (o, n) => new RegExp(`/${n}`).test(b.pathname);
18
+ return /* @__PURE__ */ a(T, { ...x, children: [
19
+ /* @__PURE__ */ t(s, { to: "/", className: "sidebar-logo", children: f || /* @__PURE__ */ t(L, { showText: !1, size: 20 }) }),
20
20
  m.map(({ url: o, name: n, title: r, showBadge: y }) => {
21
21
  const i = h(o, n);
22
- return /* @__PURE__ */ a(T, { component: s, selected: i, to: o, children: [
22
+ return /* @__PURE__ */ a(A, { component: s, selected: i, to: o, children: [
23
23
  /* @__PURE__ */ t(
24
- I,
24
+ j,
25
25
  {
26
26
  name: e[n],
27
27
  size: 36,
@@ -30,14 +30,14 @@ function q({
30
30
  showBadge: y
31
31
  }
32
32
  ),
33
- /* @__PURE__ */ t(v, { component: "span", className: "menu-title", children: r })
33
+ /* @__PURE__ */ t(I, { component: "span", className: "menu-title", children: r })
34
34
  ] }, o);
35
35
  }),
36
36
  /* @__PURE__ */ t("div", { style: { flex: 1 } }),
37
37
  g
38
38
  ] });
39
39
  }
40
- const L = k(c("div")`
40
+ const T = k(d(w)`
41
41
  flex: 1;
42
42
  display: flex;
43
43
  flex-direction: column;
@@ -58,7 +58,7 @@ const L = k(c("div")`
58
58
  display: block;
59
59
  }
60
60
  }
61
- `), d = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230, 0))", T = c(w)`
61
+ `), c = "linear-gradient(32deg, rgba(144, 255, 230, 0.1), rgba(144, 255, 230, 0))", A = d(z)`
62
62
  && {
63
63
  display: flex;
64
64
  flex-direction: column;
@@ -66,13 +66,13 @@ const L = k(c("div")`
66
66
  align-items: center;
67
67
  width: 100%;
68
68
  transition: all 200ms ease-in-out;
69
- background: ${(e) => e.selected ? d : ""};
69
+ background: ${(e) => e.selected ? c : ""};
70
70
  padding: 24px 0;
71
71
  border-left: 2px solid ${(e) => e.selected ? l.A700 : "transparent"};
72
72
  border-radius: 0;
73
73
 
74
74
  &:hover {
75
- background: ${d};
75
+ background: ${c};
76
76
  border-left-color: ${l.A700};
77
77
  }
78
78
 
@@ -89,5 +89,5 @@ const L = k(c("div")`
89
89
  }
90
90
  `;
91
91
  export {
92
- q as default
92
+ C as default
93
93
  };