@dskripchenko/laravel-admin 1.10.10 → 1.10.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { h as Ce, ref as S, computed as g, defineComponent as ae, openBlock as o, createElementBlock as h, createVNode as I, unref as l, createBlock as F, withCtx as w, Fragment as W, renderList as ee, createTextVNode as D, toDisplayString as x, createElementVNode as y, createCommentVNode as P, renderSlot as Ae, resolveDynamicComponent as Be, normalizeClass as ve, withKeys as b1, withModifiers as pe, watch as we, resolveComponent as x9, normalizeStyle as Ve, nextTick as a1, withDirectives as i1, vModelText as L1, onBeforeUnmount as f9, onMounted as Ee, onUnmounted as Q9, Teleport as eI, Transition as g9, inject as aI, normalizeProps as Vo, mergeProps as Gn, provide as Lw, vModelSelect as bw, createSlots as VI, guardReactiveProps as Cw, reactive as PI, createApp as _w } from "vue";
2
- import { defineStore as We, createPinia as Sw } from "pinia";
1
+ import { h as Ce, ref as S, computed as g, defineComponent as ae, openBlock as o, createElementBlock as h, createVNode as I, unref as l, createBlock as F, withCtx as w, Fragment as W, renderList as ee, createTextVNode as D, toDisplayString as x, createElementVNode as y, createCommentVNode as P, renderSlot as Ae, resolveDynamicComponent as Be, normalizeClass as ve, withKeys as b1, withModifiers as pe, watch as Ie, resolveComponent as x9, normalizeStyle as Ve, nextTick as a1, withDirectives as i1, vModelText as L1, onBeforeUnmount as f9, onMounted as Ne, onUnmounted as Q9, Teleport as eI, Transition as g9, inject as aI, normalizeProps as Vo, mergeProps as Gn, provide as Lw, vModelSelect as bw, createSlots as VI, guardReactiveProps as Cw, reactive as PI, createApp as _w } from "vue";
2
+ import { defineStore as Ze, createPinia as Sw } from "pinia";
3
3
  import { useRouter as Ue, useRoute as d1, createWebHistory as FI, createRouter as qw } from "vue-router";
4
4
  import { UidIcon as Q, UidMenu as je, UidMenuItem as De, UidMenuSeparator as Aw, UidAvatar as tI, UidSidebarItem as zw, UidSidebar as Hw, UidSidebarGroup as Vw, UidModal as Pw, UidSpinner as Fw, UidSidebarLayout as jw, useToast as Zo, UidToastProvider as Dw, UidAlert as Xe, UidInput as be, UidButton as oe, UidCard as Me, UidSkeleton as Qn, UidCheckbox as jI, UidErrorState as nI, UidEmptyState as oI, UidTreeView as Bw, UidTable as f2, UidPagination as Rw, UidGrid as DI, UidStack as $w, UidBadge as cI, UidSelect as M9, UidStat as Jo, UidGauge as Tw, UidFormField as Fo, UidTextarea as Uw, UidNumberInput as Ow, UidDatePicker as Ew, usePopover as Zw, UidTabs as BI, UidTabPanel as RI, UidTab as Yo, UidDescriptionList as Ww, UidDescriptionItem as Gw, UidDrawer as Nw, UidStepper as Xw, UidFileUpload as Kw, UidProgress as Jw } from "@dskripchenko/ui";
5
5
  import { t as Yw, p as L9, u as Pe } from "./formState-DC25j4xe.js";
@@ -2715,7 +2715,7 @@ const ha = e("CircleArrowUpIcon", [
2715
2715
  ["path", { d: "m16 12-4-4-4 4", key: "177agl" }],
2716
2716
  ["path", { d: "M12 16V8", key: "1sbj14" }]
2717
2717
  ]);
2718
- const Ne = e("CircleCheckBigIcon", [
2718
+ const Ge = e("CircleCheckBigIcon", [
2719
2719
  ["path", { d: "M21.801 10A10 10 0 1 1 17 3.335", key: "yps3ct" }],
2720
2720
  ["path", { d: "m9 11 3 3L22 4", key: "1pflzl" }]
2721
2721
  ]);
@@ -5743,7 +5743,7 @@ const Ya = e("Grid2x2Icon", [
5743
5743
  ["path", { d: "M3 12h18", key: "1i2n21" }],
5744
5744
  ["path", { d: "M12 3v18", key: "108xh3" }]
5745
5745
  ]);
5746
- const Ge = e("Grid3x3Icon", [
5746
+ const We = e("Grid3x3Icon", [
5747
5747
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
5748
5748
  ["path", { d: "M3 9h18", key: "1pudct" }],
5749
5749
  ["path", { d: "M3 15h18", key: "5xshup" }],
@@ -13053,7 +13053,7 @@ const tx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
13053
13053
  CircleArrowRight: sa,
13054
13054
  CircleArrowUp: ha,
13055
13055
  CircleCheck: ua,
13056
- CircleCheckBig: Ne,
13056
+ CircleCheckBig: Ge,
13057
13057
  CircleChevronDown: ya,
13058
13058
  CircleChevronLeft: pa,
13059
13059
  CircleChevronRight: ka,
@@ -13426,7 +13426,7 @@ const tx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
13426
13426
  Grid2x2Check: Jp,
13427
13427
  Grid2x2Plus: Ja,
13428
13428
  Grid2x2X: Yp,
13429
- Grid3x3: Ge,
13429
+ Grid3x3: We,
13430
13430
  Grip: ek,
13431
13431
  GripHorizontal: Qp,
13432
13432
  GripVertical: d2,
@@ -14958,10 +14958,10 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14958
14958
  Check: t1,
14959
14959
  CheckCheck: Nd,
14960
14960
  CheckCheckIcon: Nd,
14961
- CheckCircle: Ne,
14961
+ CheckCircle: Ge,
14962
14962
  CheckCircle2: ua,
14963
14963
  CheckCircle2Icon: ua,
14964
- CheckCircleIcon: Ne,
14964
+ CheckCircleIcon: Ge,
14965
14965
  CheckIcon: t1,
14966
14966
  CheckSquare: Wt,
14967
14967
  CheckSquare2: Gt,
@@ -15045,8 +15045,8 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
15045
15045
  CircleArrowUp: ha,
15046
15046
  CircleArrowUpIcon: ha,
15047
15047
  CircleCheck: ua,
15048
- CircleCheckBig: Ne,
15049
- CircleCheckBigIcon: Ne,
15048
+ CircleCheckBig: Ge,
15049
+ CircleCheckBigIcon: Ge,
15050
15050
  CircleCheckIcon: ua,
15051
15051
  CircleChevronDown: ya,
15052
15052
  CircleChevronDownIcon: ya,
@@ -15855,7 +15855,7 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
15855
15855
  GraduationCapIcon: Xp,
15856
15856
  Grape: Kp,
15857
15857
  GrapeIcon: Kp,
15858
- Grid: Ge,
15858
+ Grid: We,
15859
15859
  Grid2X2: Ya,
15860
15860
  Grid2X2Icon: Ya,
15861
15861
  Grid2X2Plus: Ja,
@@ -15868,11 +15868,11 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
15868
15868
  Grid2x2PlusIcon: Ja,
15869
15869
  Grid2x2X: Yp,
15870
15870
  Grid2x2XIcon: Yp,
15871
- Grid3X3: Ge,
15872
- Grid3X3Icon: Ge,
15873
- Grid3x3: Ge,
15874
- Grid3x3Icon: Ge,
15875
- GridIcon: Ge,
15871
+ Grid3X3: We,
15872
+ Grid3X3Icon: We,
15873
+ Grid3x3: We,
15874
+ Grid3x3Icon: We,
15875
+ GridIcon: We,
15876
15876
  Grip: ek,
15877
15877
  GripHorizontal: Qp,
15878
15878
  GripHorizontalIcon: Qp,
@@ -16548,7 +16548,7 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
16548
16548
  LucideChartSpline: Gd,
16549
16549
  LucideCheck: t1,
16550
16550
  LucideCheckCheck: Nd,
16551
- LucideCheckCircle: Ne,
16551
+ LucideCheckCircle: Ge,
16552
16552
  LucideCheckCircle2: ua,
16553
16553
  LucideCheckSquare: Wt,
16554
16554
  LucideCheckSquare2: Gt,
@@ -16592,7 +16592,7 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
16592
16592
  LucideCircleArrowRight: sa,
16593
16593
  LucideCircleArrowUp: ha,
16594
16594
  LucideCircleCheck: ua,
16595
- LucideCircleCheckBig: Ne,
16595
+ LucideCircleCheckBig: Ge,
16596
16596
  LucideCircleChevronDown: ya,
16597
16597
  LucideCircleChevronLeft: pa,
16598
16598
  LucideCircleChevronRight: ka,
@@ -16996,15 +16996,15 @@ const nx = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
16996
16996
  LucideGrab: Np,
16997
16997
  LucideGraduationCap: Xp,
16998
16998
  LucideGrape: Kp,
16999
- LucideGrid: Ge,
16999
+ LucideGrid: We,
17000
17000
  LucideGrid2X2: Ya,
17001
17001
  LucideGrid2X2Plus: Ja,
17002
17002
  LucideGrid2x2: Ya,
17003
17003
  LucideGrid2x2Check: Jp,
17004
17004
  LucideGrid2x2Plus: Ja,
17005
17005
  LucideGrid2x2X: Yp,
17006
- LucideGrid3X3: Ge,
17007
- LucideGrid3x3: Ge,
17006
+ LucideGrid3X3: We,
17007
+ LucideGrid3x3: We,
17008
17008
  LucideGrip: ek,
17009
17009
  LucideGripHorizontal: Qp,
17010
17010
  LucideGripVertical: d2,
@@ -19497,7 +19497,7 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19497
19497
  getAdminClient: ge,
19498
19498
  hasAdminClient: cx,
19499
19499
  setAdminClient: TI
19500
- }, Symbol.toStringTag, { value: "Module" })), iI = We("admin-theme", () => {
19500
+ }, Symbol.toStringTag, { value: "Module" })), iI = Ze("admin-theme", () => {
19501
19501
  const a = S("light"), t = S(["light", "dark"]), n = g(() => a.value === "dark");
19502
19502
  function r(s) {
19503
19503
  a.value = s.theme, t.value = s.availableThemes, i(s.theme);
@@ -19553,7 +19553,7 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19553
19553
  }, null, 8, ["icon", "data-icon"])
19554
19554
  ], 8, ix));
19555
19555
  }
19556
- }), b9 = We("admin-locale", () => {
19556
+ }), b9 = Ze("admin-locale", () => {
19557
19557
  const a = S("ru"), t = S(["ru", "en"]);
19558
19558
  function n(i) {
19559
19559
  a.value = i.locale, t.value = i.availableLocales, c(i.locale);
@@ -19625,7 +19625,7 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19625
19625
  _: 1
19626
19626
  }));
19627
19627
  }
19628
- }), C9 = We("admin-notifications", () => {
19628
+ }), C9 = Ze("admin-notifications", () => {
19629
19629
  const a = S([]), t = S(0), n = S(!1), r = S("all"), d = S(null), c = S(!1), i = g(() => t.value > 0);
19630
19630
  function s() {
19631
19631
  c.value = !0;
@@ -19639,10 +19639,10 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19639
19639
  function p(k) {
19640
19640
  t.value = k.unread_notifications_count;
19641
19641
  }
19642
- async function f(k = "all", z = 1) {
19642
+ async function f(k = "all", A = 1) {
19643
19643
  n.value = !0;
19644
19644
  try {
19645
- const E = await ge().get(`/notifications/list?type=${k}&page=${z}`);
19645
+ const E = await ge().get(`/notifications/list?type=${k}&page=${A}`);
19646
19646
  a.value = E.data, t.value = E.meta.unread_count, d.value = {
19647
19647
  page: E.meta.page,
19648
19648
  per_page: E.meta.per_page,
@@ -19654,10 +19654,10 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19654
19654
  }
19655
19655
  }
19656
19656
  async function M() {
19657
- const z = await ge().get(
19657
+ const A = await ge().get(
19658
19658
  "/notifications/unread"
19659
19659
  );
19660
- t.value = z.count, r.value === "unread" && (a.value = z.data);
19660
+ t.value = A.count, r.value === "unread" && (a.value = A.data);
19661
19661
  }
19662
19662
  async function b(k) {
19663
19663
  await ge().post("/notifications/markAsRead", { id: k });
@@ -19666,9 +19666,9 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19666
19666
  }
19667
19667
  async function v() {
19668
19668
  await ge().post("/notifications/markAllAsRead");
19669
- const z = (/* @__PURE__ */ new Date()).toISOString();
19669
+ const A = (/* @__PURE__ */ new Date()).toISOString();
19670
19670
  for (const U of a.value)
19671
- U.read_at === null && (U.read_at = z);
19671
+ U.read_at === null && (U.read_at = A);
19672
19672
  t.value = 0;
19673
19673
  }
19674
19674
  async function L(k) {
@@ -19728,7 +19728,7 @@ const _e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
19728
19728
  ], 8, rx));
19729
19729
  }
19730
19730
  });
19731
- class Ze extends Error {
19731
+ class Ee extends Error {
19732
19732
  status;
19733
19733
  errorKey;
19734
19734
  payload;
@@ -19736,22 +19736,22 @@ class Ze extends Error {
19736
19736
  super(n.message ?? `API error ${t}`), this.name = "ApiError", this.status = t, this.errorKey = n.errorKey ?? "unknown", this.payload = n;
19737
19737
  }
19738
19738
  }
19739
- class EI extends Ze {
19739
+ class EI extends Ee {
19740
19740
  constructor(t) {
19741
19741
  super(401, t), this.name = "UnauthenticatedError";
19742
19742
  }
19743
19743
  }
19744
- class hx extends Ze {
19744
+ class hx extends Ee {
19745
19745
  constructor(t) {
19746
19746
  super(403, t), this.name = "ForbiddenError";
19747
19747
  }
19748
19748
  }
19749
- class ux extends Ze {
19749
+ class ux extends Ee {
19750
19750
  constructor(t) {
19751
19751
  super(404, t), this.name = "NotFoundError";
19752
19752
  }
19753
19753
  }
19754
- class jo extends Ze {
19754
+ class jo extends Ee {
19755
19755
  /** Field-keyed map of error messages. */
19756
19756
  fields;
19757
19757
  constructor(t) {
@@ -19781,10 +19781,10 @@ function fI(a, t) {
19781
19781
  case 422:
19782
19782
  return new jo(t);
19783
19783
  default:
19784
- return new Ze(a, t);
19784
+ return new Ee(a, t);
19785
19785
  }
19786
19786
  }
19787
- const Ke = We("admin-auth", () => {
19787
+ const Ke = Ze("admin-auth", () => {
19788
19788
  const a = S(null), t = S([]), n = S(null), r = g(() => a.value !== null), d = g(() => n.value !== null);
19789
19789
  function c(v) {
19790
19790
  a.value = v.user, t.value = v.permissions;
@@ -19792,7 +19792,7 @@ const Ke = We("admin-auth", () => {
19792
19792
  function i(v) {
19793
19793
  return t.value.includes("*") || t.value.includes(v) ? !0 : t.value.some((L) => {
19794
19794
  if (!L.includes("*")) return !1;
19795
- const k = L.split("*").map((z) => z.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")).join(".*");
19795
+ const k = L.split("*").map((A) => A.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")).join(".*");
19796
19796
  return new RegExp(`^${k}$`).test(v);
19797
19797
  });
19798
19798
  }
@@ -19811,10 +19811,10 @@ const Ke = We("admin-auth", () => {
19811
19811
  );
19812
19812
  return k?.user && (a.value = k.user), Array.isArray(k?.permissions) && (t.value = k.permissions), n.value = null, "authenticated";
19813
19813
  } catch (k) {
19814
- if (k instanceof Ze && k.errorKey === "two_factor_required") {
19815
- const z = k.payload.challenge_token;
19814
+ if (k instanceof Ee && k.errorKey === "two_factor_required") {
19815
+ const A = k.payload.challenge_token;
19816
19816
  return n.value = {
19817
- challengeToken: typeof z == "string" ? z : "",
19817
+ challengeToken: typeof A == "string" ? A : "",
19818
19818
  remember: v.remember ?? !1
19819
19819
  }, "two_factor_required";
19820
19820
  }
@@ -19991,7 +19991,7 @@ const Ke = We("admin-auth", () => {
19991
19991
  I(px)
19992
19992
  ]));
19993
19993
  }
19994
- }), lI = We("admin-menu", () => {
19994
+ }), lI = Ze("admin-menu", () => {
19995
19995
  const a = S([]), t = S(!1), n = S(null), r = S(!1), d = g(() => {
19996
19996
  const m = Ke(), p = (f) => {
19997
19997
  if (Array.isArray(f.permissions) && f.permissions.length > 0 && !m.hasAnyPermission(f.permissions))
@@ -20054,7 +20054,7 @@ const Ke = We("admin-auth", () => {
20054
20054
  box: t2,
20055
20055
  briefcase: A2,
20056
20056
  calendar: n2,
20057
- "check-circle": Ne,
20057
+ "check-circle": Ge,
20058
20058
  clock: V2,
20059
20059
  code: P2,
20060
20060
  cog: F2,
@@ -20070,10 +20070,10 @@ const Ke = We("admin-auth", () => {
20070
20070
  "folder-open": O2,
20071
20071
  gauge: Z2,
20072
20072
  globe: r2,
20073
- grid: Ge,
20073
+ grid: We,
20074
20074
  "hard-drive": W2,
20075
20075
  hash: G2,
20076
- "health-check": Ne,
20076
+ "health-check": Ge,
20077
20077
  heart: N2,
20078
20078
  "help-circle": k1,
20079
20079
  history: X2,
@@ -20162,7 +20162,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20162
20162
  return c(v) ? !0 : (v.children ?? []).some(i);
20163
20163
  }
20164
20164
  const s = g(() => i(t.item));
20165
- we(
20165
+ Ie(
20166
20166
  () => s.value,
20167
20167
  (v) => {
20168
20168
  v && (d.value = !0);
@@ -20239,9 +20239,9 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20239
20239
  _: 1
20240
20240
  }, 8, ["to", "active", "badge", "title"])),
20241
20241
  r.value && d.value ? (o(), h("div", Lx, [
20242
- (o(!0), h(W, null, ee(a.item.children, (z) => (o(), F(k, {
20243
- key: z.key,
20244
- item: z,
20242
+ (o(!0), h(W, null, ee(a.item.children, (A) => (o(), F(k, {
20243
+ key: A.key,
20244
+ item: A,
20245
20245
  depth: a.depth + 1,
20246
20246
  collapsed: a.collapsed,
20247
20247
  "stripe-at": a.stripeAt,
@@ -20374,7 +20374,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20374
20374
  }, 8, ["collapsed"]);
20375
20375
  };
20376
20376
  }
20377
- }), Do = We("admin-i18n", () => {
20377
+ }), Do = Ze("admin-i18n", () => {
20378
20378
  const a = S({}), t = S("ru");
20379
20379
  function n(i) {
20380
20380
  const s = i.translations;
@@ -20432,11 +20432,11 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20432
20432
  }), k = g(() => {
20433
20433
  const G = [];
20434
20434
  return L.value && G.push(L.value), G.push(...p.value), G;
20435
- }), z = g(() => k.value.flatMap((G) => G.items)), U = g(() => u.value.trim().length >= 2), E = g(
20436
- () => U.value && !m.value && z.value.length === 0
20435
+ }), A = g(() => k.value.flatMap((G) => G.items)), U = g(() => u.value.trim().length >= 2), E = g(
20436
+ () => U.value && !m.value && A.value.length === 0
20437
20437
  );
20438
20438
  let q = null, H = 0;
20439
- we(u, (G) => {
20439
+ Ie(u, (G) => {
20440
20440
  if (f.value = 0, q && clearTimeout(q), G.trim().length < 2) {
20441
20441
  p.value = [], m.value = !1;
20442
20442
  return;
@@ -20459,7 +20459,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20459
20459
  te === H && (m.value = !1);
20460
20460
  }
20461
20461
  }
20462
- function A(G, te) {
20462
+ function z(G, te) {
20463
20463
  let Z = 0;
20464
20464
  for (const K of k.value) {
20465
20465
  if (K === G) break;
@@ -20471,10 +20471,10 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20471
20471
  G && (b.value = !1, d.push(G.url));
20472
20472
  }
20473
20473
  function N(G) {
20474
- const te = z.value.length;
20474
+ const te = A.value.length;
20475
20475
  te !== 0 && (f.value = (f.value + G + te) % te);
20476
20476
  }
20477
- return we(b, (G) => {
20477
+ return Ie(b, (G) => {
20478
20478
  G && (u.value = "", p.value = [], f.value = 0, a1(() => M.value?.focus()));
20479
20479
  }), (G, te) => (o(), F(l(Pw), {
20480
20480
  modelValue: b.value,
@@ -20501,7 +20501,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20501
20501
  onKeydown: [
20502
20502
  te[1] || (te[1] = b1(pe((Z) => N(1), ["prevent"]), ["down"])),
20503
20503
  te[2] || (te[2] = b1(pe((Z) => N(-1), ["prevent"]), ["up"])),
20504
- te[3] || (te[3] = b1(pe((Z) => R(z.value[f.value]), ["prevent"]), ["enter"]))
20504
+ te[3] || (te[3] = b1(pe((Z) => R(A.value[f.value]), ["prevent"]), ["enter"]))
20505
20505
  ]
20506
20506
  }, null, 40, Dx), [
20507
20507
  [L1, u.value]
@@ -20528,13 +20528,13 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20528
20528
  (o(!0), h(W, null, ee(Z.items, (K) => (o(), h("button", {
20529
20529
  key: Z.label + K.url,
20530
20530
  type: "button",
20531
- class: ve(["admin-search__item", { "admin-search__item--active": A(Z, K) === f.value }]),
20531
+ class: ve(["admin-search__item", { "admin-search__item--active": z(Z, K) === f.value }]),
20532
20532
  onClick: (B) => R(K),
20533
- onMousemove: (B) => f.value = A(Z, K)
20533
+ onMousemove: (B) => f.value = z(Z, K)
20534
20534
  }, [
20535
20535
  y("span", Ox, x(K.title), 1),
20536
20536
  K.subtitle ? (o(), h("span", Ex, x(K.subtitle), 1)) : P("", !0),
20537
- A(Z, K) === f.value ? (o(), F(l(Q), {
20537
+ z(Z, K) === f.value ? (o(), F(l(Q), {
20538
20538
  key: 1,
20539
20539
  icon: l(D2),
20540
20540
  size: 13,
@@ -20572,7 +20572,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20572
20572
  function f() {
20573
20573
  i("exit-impersonation");
20574
20574
  }
20575
- we(
20575
+ Ie(
20576
20576
  () => n.impersonation,
20577
20577
  (v) => {
20578
20578
  typeof document > "u" || (v !== null ? document.documentElement.setAttribute(R9, "true") : document.documentElement.removeAttribute(R9));
@@ -20585,7 +20585,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20585
20585
  function b(v) {
20586
20586
  (v.metaKey || v.ctrlKey) && (v.key === "k" || v.key === "K") && (v.preventDefault(), M.value = !0);
20587
20587
  }
20588
- return Ee(() => {
20588
+ return Ne(() => {
20589
20589
  typeof window < "u" && window.addEventListener("keydown", b);
20590
20590
  }), f9(() => {
20591
20591
  typeof window < "u" && window.removeEventListener("keydown", b);
@@ -20644,7 +20644,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20644
20644
  }, null, 8, ["modelValue"])
20645
20645
  ]));
20646
20646
  }
20647
- }), rI = We("admin-navigation", () => {
20647
+ }), rI = Ze("admin-navigation", () => {
20648
20648
  const a = S(0), t = g(() => a.value > 0);
20649
20649
  function n() {
20650
20650
  a.value += 1;
@@ -20661,7 +20661,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20661
20661
  setup(a) {
20662
20662
  const t = rI(), n = S(!1);
20663
20663
  let r = null;
20664
- we(
20664
+ Ie(
20665
20665
  () => t.isLoading,
20666
20666
  (c) => {
20667
20667
  c ? (r !== null && (clearTimeout(r), r = null), n.value = !0) : r = setTimeout(() => {
@@ -20742,7 +20742,7 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20742
20742
  }
20743
20743
  function m(L) {
20744
20744
  const k = L.type.toLowerCase();
20745
- return k.includes("import") || k.includes("finished") || k.includes("success") ? Ne : k.includes("comment") || k.includes("message") || k.includes("mention") ? h2 : k.includes("user") || k.includes("member") || k.includes("role") ? qo : k.includes("warning") || k.includes("schedule") ? x1 : k.includes("delete") || k.includes("failed") || k.includes("error") ? $e : Ne;
20745
+ return k.includes("import") || k.includes("finished") || k.includes("success") ? Ge : k.includes("comment") || k.includes("message") || k.includes("mention") ? h2 : k.includes("user") || k.includes("member") || k.includes("role") ? qo : k.includes("warning") || k.includes("schedule") ? x1 : k.includes("delete") || k.includes("failed") || k.includes("error") ? $e : Ge;
20746
20746
  }
20747
20747
  function p(L) {
20748
20748
  const k = L.type.toLowerCase();
@@ -20752,18 +20752,18 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20752
20752
  if (!L) return "";
20753
20753
  const k = new Date(L).getTime();
20754
20754
  if (Number.isNaN(k)) return "";
20755
- const z = (Date.now() - k) / 1e3;
20756
- return z < 60 ? `${Math.max(1, Math.floor(z))} сек назад` : z < 3600 ? `${Math.floor(z / 60)} мин назад` : z < 86400 ? `${Math.floor(z / 3600)} ч назад` : z < 86400 * 2 ? "вчера" : z < 86400 * 7 ? `${Math.floor(z / 86400)} д назад` : new Date(L).toLocaleDateString("ru-RU");
20755
+ const A = (Date.now() - k) / 1e3;
20756
+ return A < 60 ? `${Math.max(1, Math.floor(A))} сек назад` : A < 3600 ? `${Math.floor(A / 60)} мин назад` : A < 86400 ? `${Math.floor(A / 3600)} ч назад` : A < 86400 * 2 ? "вчера" : A < 86400 * 7 ? `${Math.floor(A / 86400)} д назад` : new Date(L).toLocaleDateString("ru-RU");
20757
20757
  }
20758
20758
  function M(L) {
20759
- const k = L.data, z = typeof k.title == "string" ? k.title : typeof k.subject == "string" ? k.subject : "Уведомление", U = typeof k.description == "string" ? k.description : typeof k.message == "string" ? k.message : typeof k.text == "string" ? k.text : "";
20760
- return { title: z, description: U };
20759
+ const k = L.data, A = typeof k.title == "string" ? k.title : typeof k.subject == "string" ? k.subject : "Уведомление", U = typeof k.description == "string" ? k.description : typeof k.message == "string" ? k.message : typeof k.text == "string" ? k.text : "";
20760
+ return { title: A, description: U };
20761
20761
  }
20762
20762
  const b = g(() => {
20763
- const k = t.meta?.total ?? t.items.length, z = t.unreadCount, U = Math.max(0, k - z);
20764
- return { all: k, unread: z, read: U };
20763
+ const k = t.meta?.total ?? t.items.length, A = t.unreadCount, U = Math.max(0, k - A);
20764
+ return { all: k, unread: A, read: U };
20765
20765
  });
20766
- we(n, async (L) => {
20766
+ Ie(n, async (L) => {
20767
20767
  L ? (await t.load(t.lastFilter, 1).catch(() => {
20768
20768
  }), document.addEventListener("keydown", v)) : document.removeEventListener("keydown", v);
20769
20769
  });
@@ -20813,56 +20813,56 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20813
20813
  ])
20814
20814
  ]),
20815
20815
  y("nav", oL, [
20816
- (o(), h(W, null, ee(r, (z) => y("button", {
20817
- key: z.key,
20816
+ (o(), h(W, null, ee(r, (A) => y("button", {
20817
+ key: A.key,
20818
20818
  type: "button",
20819
20819
  role: "tab",
20820
20820
  class: ve([
20821
20821
  "admin-notif-drawer__tab",
20822
20822
  {
20823
- "admin-notif-drawer__tab--active": l(t).lastFilter === z.key
20823
+ "admin-notif-drawer__tab--active": l(t).lastFilter === A.key
20824
20824
  }
20825
20825
  ]),
20826
- "aria-selected": l(t).lastFilter === z.key,
20827
- onClick: (U) => d(z.key)
20826
+ "aria-selected": l(t).lastFilter === A.key,
20827
+ onClick: (U) => d(A.key)
20828
20828
  }, [
20829
- D(x(z.label) + " ", 1),
20830
- y("span", iL, x(b.value[z.key]), 1)
20829
+ D(x(A.label) + " ", 1),
20830
+ y("span", iL, x(b.value[A.key]), 1)
20831
20831
  ], 10, cL)), 64))
20832
20832
  ]),
20833
20833
  y("div", lL, [
20834
20834
  l(t).loading && l(t).items.length === 0 ? (o(), h("div", rL, " Загрузка… ")) : l(t).items.length === 0 ? (o(), h("div", dL, " Нет уведомлений ")) : (o(), h("ol", sL, [
20835
- (o(!0), h(W, null, ee(l(t).items, (z) => (o(), h("li", {
20836
- key: z.id,
20835
+ (o(!0), h(W, null, ee(l(t).items, (A) => (o(), h("li", {
20836
+ key: A.id,
20837
20837
  class: ve([
20838
20838
  "admin-notif-drawer__item",
20839
- { "admin-notif-drawer__item--unread": z.read_at === null }
20839
+ { "admin-notif-drawer__item--unread": A.read_at === null }
20840
20840
  ]),
20841
- onClick: (U) => i(z)
20841
+ onClick: (U) => i(A)
20842
20842
  }, [
20843
20843
  y("span", {
20844
20844
  class: "admin-notif-drawer__icon",
20845
- "data-variant": p(z),
20845
+ "data-variant": p(A),
20846
20846
  "aria-hidden": "true"
20847
20847
  }, [
20848
20848
  I(l(Q), {
20849
- icon: m(z),
20849
+ icon: m(A),
20850
20850
  size: 14
20851
20851
  }, null, 8, ["icon"])
20852
20852
  ], 8, uL),
20853
20853
  y("div", yL, [
20854
20854
  y("div", pL, [
20855
- y("span", kL, x(M(z).title), 1),
20856
- y("span", mL, x(f(z.created_at)), 1)
20855
+ y("span", kL, x(M(A).title), 1),
20856
+ y("span", mL, x(f(A.created_at)), 1)
20857
20857
  ]),
20858
- M(z).description ? (o(), h("div", vL, x(M(z).description), 1)) : P("", !0)
20858
+ M(A).description ? (o(), h("div", vL, x(M(A).description), 1)) : P("", !0)
20859
20859
  ]),
20860
- z.read_at === null ? (o(), h("span", fL)) : P("", !0),
20860
+ A.read_at === null ? (o(), h("span", fL)) : P("", !0),
20861
20861
  y("button", {
20862
20862
  type: "button",
20863
20863
  class: "admin-notif-drawer__item-delete",
20864
20864
  "aria-label": "Удалить",
20865
- onClick: pe((U) => s(z, U), ["stop"])
20865
+ onClick: pe((U) => s(A, U), ["stop"])
20866
20866
  }, [
20867
20867
  I(l(Q), {
20868
20868
  icon: l(He),
@@ -20879,16 +20879,16 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20879
20879
  })
20880
20880
  ]));
20881
20881
  }
20882
- }), Te = We("admin-manifest", () => {
20882
+ }), Te = Ze("admin-manifest", () => {
20883
20883
  const a = S(null), t = S(!1), n = S(null), r = S(!1), d = g(() => a.value !== null), c = g(() => a.value?.version ?? null), i = g(() => a.value?.resources ?? []), s = g(() => a.value?.screens ?? []), u = g(() => a.value?.settings ?? []), m = g(() => a.value?.plugins ?? []);
20884
- function p(z) {
20885
- return i.value.find((U) => U.slug === z) ?? null;
20884
+ function p(A) {
20885
+ return i.value.find((U) => U.slug === A) ?? null;
20886
20886
  }
20887
- function f(z) {
20888
- return s.value.find((U) => U.slug === z) ?? null;
20887
+ function f(A) {
20888
+ return s.value.find((U) => U.slug === A) ?? null;
20889
20889
  }
20890
- function M(z) {
20891
- return u.value.find((U) => U.slug === z) ?? null;
20890
+ function M(A) {
20891
+ return u.value.find((U) => U.slug === A) ?? null;
20892
20892
  }
20893
20893
  function b() {
20894
20894
  a.value = null;
@@ -20896,8 +20896,8 @@ const Mx = ["data-depth"], Ix = ["aria-expanded", "title"], wx = { class: "uid-s
20896
20896
  function v() {
20897
20897
  return L(!0);
20898
20898
  }
20899
- async function L(z = !1) {
20900
- if (a.value !== null && !z)
20899
+ async function L(A = !1) {
20900
+ if (a.value !== null && !A)
20901
20901
  return a.value;
20902
20902
  t.value = !0, n.value = null;
20903
20903
  try {
@@ -21023,16 +21023,16 @@ const wL = { class: "admin-page-host" }, xL = {
21023
21023
  ], 64);
21024
21024
  };
21025
21025
  }
21026
- }), WI = We("admin-dashboard", () => {
21026
+ }), WI = Ze("admin-dashboard", () => {
21027
21027
  const a = S(null), t = S(!1), n = S([]), r = S([]), d = S(!1), c = S(!1), i = S(null), s = g(() => JSON.stringify(n.value) !== JSON.stringify(r.value));
21028
21028
  async function u(H) {
21029
21029
  a.value = H, c.value = !0;
21030
21030
  try {
21031
- const A = await ge().get(
21031
+ const z = await ge().get(
21032
21032
  `/dashboard/get?key=${encodeURIComponent(H)}`
21033
21033
  );
21034
- i.value = A.period ?? null;
21035
- const R = (A.layout ?? []).map((N, G) => ({
21034
+ i.value = z.period ?? null;
21035
+ const R = (z.layout ?? []).map((N, G) => ({
21036
21036
  ...N,
21037
21037
  position: N.position ?? G
21038
21038
  }));
@@ -21056,15 +21056,15 @@ const wL = { class: "admin-page-host" }, xL = {
21056
21056
  if (a.value !== null) {
21057
21057
  d.value = !0;
21058
21058
  try {
21059
- const H = ge(), j = n.value.map((A, R) => ({
21060
- slug: A.slug,
21061
- size: A.size,
21059
+ const H = ge(), j = n.value.map((z, R) => ({
21060
+ slug: z.slug,
21061
+ size: z.size,
21062
21062
  position: R,
21063
- hidden: A.hidden ?? !1,
21064
- type: A.type,
21065
- config: A.config
21063
+ hidden: z.hidden ?? !1,
21064
+ type: z.type,
21065
+ config: z.config
21066
21066
  }));
21067
- await H.post("/dashboard/save", { key: a.value, widgets: j }), r.value = n.value.map((A) => ({ ...A })), t.value = !1;
21067
+ await H.post("/dashboard/save", { key: a.value, widgets: j }), r.value = n.value.map((z) => ({ ...z })), t.value = !1;
21068
21068
  } finally {
21069
21069
  d.value = !1;
21070
21070
  }
@@ -21091,13 +21091,13 @@ const wL = { class: "admin-page-host" }, xL = {
21091
21091
  }
21092
21092
  function k(H, j) {
21093
21093
  n.value = n.value.map(
21094
- (A) => A.slug === H ? { ...A, ...j } : A
21094
+ (z) => z.slug === H ? { ...z, ...j } : z
21095
21095
  );
21096
21096
  }
21097
- function z(H, j) {
21097
+ function A(H, j) {
21098
21098
  if (H === j) return;
21099
- const A = [...n.value], [R] = A.splice(H, 1);
21100
- A.splice(j, 0, R), n.value = A;
21099
+ const z = [...n.value], [R] = z.splice(H, 1);
21100
+ z.splice(j, 0, R), n.value = z;
21101
21101
  }
21102
21102
  function U(H) {
21103
21103
  n.value = H;
@@ -21131,7 +21131,7 @@ const wL = { class: "admin-page-host" }, xL = {
21131
21131
  addWidget: v,
21132
21132
  removeWidget: L,
21133
21133
  updateWidget: k,
21134
- moveWidget: z,
21134
+ moveWidget: A,
21135
21135
  setDraft: U,
21136
21136
  reset: E
21137
21137
  };
@@ -21295,24 +21295,24 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21295
21295
  const n = a, r = t, d = g(() => qL()), c = S(""), i = S(""), s = S("6"), u = S(`# Новая заметка
21296
21296
 
21297
21297
  Текст…`), m = S("LABEL"), p = S("0"), f = S("50"), M = S("Янв, Фев, Мар, Апр"), b = S("10, 20, 15, 30"), v = S(""), L = S("5");
21298
- we(
21298
+ Ie(
21299
21299
  () => n.open,
21300
21300
  (j) => {
21301
21301
  if (j)
21302
21302
  if (n.mode === "configure" && n.item) {
21303
- const A = n.item.config ?? {};
21304
- c.value = n.item.type ?? "", i.value = A.title ?? n.initialTitle, s.value = String(n.item.size ?? 6), u.value = A.content ?? u.value;
21305
- const R = A.stats?.[0];
21306
- R && (m.value = String(R.label ?? ""), p.value = String(R.value ?? "")), f.value = String(A.value ?? 50);
21307
- const N = A.labels, G = A.datasets;
21308
- N && N.length > 0 && (M.value = N.join(", ")), G && G[0]?.data && (b.value = G[0].data.join(", ")), v.value = A.resource ?? "", L.value = String(A.limit ?? 5);
21303
+ const z = n.item.config ?? {};
21304
+ c.value = n.item.type ?? "", i.value = z.title ?? n.initialTitle, s.value = String(n.item.size ?? 6), u.value = z.content ?? u.value;
21305
+ const R = z.stats?.[0];
21306
+ R && (m.value = String(R.label ?? ""), p.value = String(R.value ?? "")), f.value = String(z.value ?? 50);
21307
+ const N = z.labels, G = z.datasets;
21308
+ N && N.length > 0 && (M.value = N.join(", ")), G && G[0]?.data && (b.value = G[0].data.join(", ")), v.value = z.resource ?? "", L.value = String(z.limit ?? 5);
21309
21309
  } else
21310
21310
  c.value = "", i.value = "", s.value = "6";
21311
21311
  }
21312
21312
  );
21313
21313
  const k = g(
21314
21314
  () => c.value !== "" && i.value.trim() !== ""
21315
- ), z = {
21315
+ ), A = {
21316
21316
  stat: "Stat — карточка с числом",
21317
21317
  stats: "Stats overview — несколько метрик",
21318
21318
  chart: "Chart — линия / столбцы / донат",
@@ -21341,8 +21341,8 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21341
21341
  j.value = Number(f.value) || 0, j.min = 0, j.max = 100;
21342
21342
  break;
21343
21343
  case "chart": {
21344
- const A = M.value.split(",").map((N) => N.trim()).filter(Boolean), R = b.value.split(",").map((N) => Number(N.trim())).filter((N) => !Number.isNaN(N));
21345
- j.labels = A, j.datasets = [{ label: i.value, data: R }], j.type = c.value === "donut-chart" ? "doughnut" : "bar";
21344
+ const z = M.value.split(",").map((N) => N.trim()).filter(Boolean), R = b.value.split(",").map((N) => Number(N.trim())).filter((N) => !Number.isNaN(N));
21345
+ j.labels = z, j.datasets = [{ label: i.value, data: R }], j.type = c.value === "donut-chart" ? "doughnut" : "bar";
21346
21346
  break;
21347
21347
  }
21348
21348
  case "recent":
@@ -21353,16 +21353,16 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21353
21353
  }
21354
21354
  function q() {
21355
21355
  if (!k.value) return;
21356
- const j = Math.max(1, Math.min(12, Number(s.value) || 6)), A = E();
21356
+ const j = Math.max(1, Math.min(12, Number(s.value) || 6)), z = E();
21357
21357
  if (n.mode === "configure" && n.item)
21358
- r("save", { size: j, type: c.value, config: A });
21358
+ r("save", { size: j, type: c.value, config: z });
21359
21359
  else {
21360
21360
  const R = `custom.${c.value}.${Date.now()}`;
21361
21361
  r("add", {
21362
21362
  slug: R,
21363
21363
  type: c.value,
21364
21364
  size: j,
21365
- config: A
21365
+ config: z
21366
21366
  });
21367
21367
  }
21368
21368
  r("close");
@@ -21370,7 +21370,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21370
21370
  function H() {
21371
21371
  r("close");
21372
21372
  }
21373
- return (j, A) => (o(), F(eI, { to: "body" }, [
21373
+ return (j, z) => (o(), F(eI, { to: "body" }, [
21374
21374
  I(g9, { name: "admin-dialog" }, {
21375
21375
  default: w(() => [
21376
21376
  a.open ? (o(), h("div", PL, [
@@ -21395,7 +21395,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21395
21395
  ]),
21396
21396
  y("div", BL, [
21397
21397
  a.mode === "add" ? (o(), h("div", RL, [
21398
- A[10] || (A[10] = y("label", { class: "admin-dialog__label" }, [
21398
+ z[10] || (z[10] = y("label", { class: "admin-dialog__label" }, [
21399
21399
  D(" Тип виджета "),
21400
21400
  y("span", { class: "admin-dialog__required" }, "*")
21401
21401
  ], -1)),
@@ -21409,37 +21409,37 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21409
21409
  ]),
21410
21410
  onClick: (N) => c.value = R
21411
21411
  }, [
21412
- y("span", OL, x(z[R] ?? R), 1),
21412
+ y("span", OL, x(A[R] ?? R), 1),
21413
21413
  y("span", EL, x(R), 1)
21414
21414
  ], 10, UL))), 128))
21415
21415
  ]))
21416
21416
  ])) : (o(), h("div", ZL, [
21417
- A[11] || (A[11] = y("label", { class: "admin-dialog__label" }, "Тип", -1)),
21417
+ z[11] || (z[11] = y("label", { class: "admin-dialog__label" }, "Тип", -1)),
21418
21418
  y("div", WL, x(c.value || "unknown"), 1)
21419
21419
  ])),
21420
21420
  y("div", GL, [
21421
- A[12] || (A[12] = y("label", { class: "admin-dialog__label" }, [
21421
+ z[12] || (z[12] = y("label", { class: "admin-dialog__label" }, [
21422
21422
  D(" Заголовок "),
21423
21423
  y("span", { class: "admin-dialog__required" }, "*")
21424
21424
  ], -1)),
21425
21425
  I(l(be), {
21426
21426
  modelValue: i.value,
21427
- "onUpdate:modelValue": A[0] || (A[0] = (R) => i.value = R),
21427
+ "onUpdate:modelValue": z[0] || (z[0] = (R) => i.value = R),
21428
21428
  placeholder: "Название виджета"
21429
21429
  }, null, 8, ["modelValue"])
21430
21430
  ]),
21431
21431
  y("div", NL, [
21432
- A[13] || (A[13] = y("label", { class: "admin-dialog__label" }, "Ширина (1..12)", -1)),
21432
+ z[13] || (z[13] = y("label", { class: "admin-dialog__label" }, "Ширина (1..12)", -1)),
21433
21433
  I(l(be), {
21434
21434
  modelValue: s.value,
21435
- "onUpdate:modelValue": A[1] || (A[1] = (R) => s.value = R),
21435
+ "onUpdate:modelValue": z[1] || (z[1] = (R) => s.value = R),
21436
21436
  type: "number"
21437
21437
  }, null, 8, ["modelValue"])
21438
21438
  ]),
21439
21439
  U(c.value) === "markdown" ? (o(), h("div", XL, [
21440
- A[14] || (A[14] = y("label", { class: "admin-dialog__label" }, "Markdown содержимое", -1)),
21440
+ z[14] || (z[14] = y("label", { class: "admin-dialog__label" }, "Markdown содержимое", -1)),
21441
21441
  i1(y("textarea", {
21442
- "onUpdate:modelValue": A[2] || (A[2] = (R) => u.value = R),
21442
+ "onUpdate:modelValue": z[2] || (z[2] = (R) => u.value = R),
21443
21443
  class: "admin-dialog__textarea",
21444
21444
  rows: "6"
21445
21445
  }, null, 512), [
@@ -21447,64 +21447,64 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21447
21447
  ])
21448
21448
  ])) : U(c.value) === "stat" ? (o(), h(W, { key: 3 }, [
21449
21449
  y("div", KL, [
21450
- A[15] || (A[15] = y("label", { class: "admin-dialog__label" }, "Метка", -1)),
21450
+ z[15] || (z[15] = y("label", { class: "admin-dialog__label" }, "Метка", -1)),
21451
21451
  I(l(be), {
21452
21452
  modelValue: m.value,
21453
- "onUpdate:modelValue": A[3] || (A[3] = (R) => m.value = R)
21453
+ "onUpdate:modelValue": z[3] || (z[3] = (R) => m.value = R)
21454
21454
  }, null, 8, ["modelValue"])
21455
21455
  ]),
21456
21456
  y("div", JL, [
21457
- A[16] || (A[16] = y("label", { class: "admin-dialog__label" }, "Значение", -1)),
21457
+ z[16] || (z[16] = y("label", { class: "admin-dialog__label" }, "Значение", -1)),
21458
21458
  I(l(be), {
21459
21459
  modelValue: p.value,
21460
- "onUpdate:modelValue": A[4] || (A[4] = (R) => p.value = R)
21460
+ "onUpdate:modelValue": z[4] || (z[4] = (R) => p.value = R)
21461
21461
  }, null, 8, ["modelValue"])
21462
21462
  ])
21463
21463
  ], 64)) : U(c.value) === "gauge" ? (o(), h("div", YL, [
21464
- A[17] || (A[17] = y("label", { class: "admin-dialog__label" }, "Значение (0..100)", -1)),
21464
+ z[17] || (z[17] = y("label", { class: "admin-dialog__label" }, "Значение (0..100)", -1)),
21465
21465
  I(l(be), {
21466
21466
  modelValue: f.value,
21467
- "onUpdate:modelValue": A[5] || (A[5] = (R) => f.value = R),
21467
+ "onUpdate:modelValue": z[5] || (z[5] = (R) => f.value = R),
21468
21468
  type: "number"
21469
21469
  }, null, 8, ["modelValue"])
21470
21470
  ])) : U(c.value) === "chart" ? (o(), h(W, { key: 5 }, [
21471
21471
  y("div", QL, [
21472
- A[18] || (A[18] = y("label", { class: "admin-dialog__label" }, "Метки (через запятую)", -1)),
21472
+ z[18] || (z[18] = y("label", { class: "admin-dialog__label" }, "Метки (через запятую)", -1)),
21473
21473
  I(l(be), {
21474
21474
  modelValue: M.value,
21475
- "onUpdate:modelValue": A[6] || (A[6] = (R) => M.value = R),
21475
+ "onUpdate:modelValue": z[6] || (z[6] = (R) => M.value = R),
21476
21476
  placeholder: "Янв, Фев, Мар"
21477
21477
  }, null, 8, ["modelValue"])
21478
21478
  ]),
21479
21479
  y("div", eb, [
21480
- A[19] || (A[19] = y("label", { class: "admin-dialog__label" }, "Значения (через запятую)", -1)),
21480
+ z[19] || (z[19] = y("label", { class: "admin-dialog__label" }, "Значения (через запятую)", -1)),
21481
21481
  I(l(be), {
21482
21482
  modelValue: b.value,
21483
- "onUpdate:modelValue": A[7] || (A[7] = (R) => b.value = R),
21483
+ "onUpdate:modelValue": z[7] || (z[7] = (R) => b.value = R),
21484
21484
  placeholder: "10, 20, 15"
21485
21485
  }, null, 8, ["modelValue"])
21486
21486
  ])
21487
21487
  ], 64)) : U(c.value) === "recent" ? (o(), h(W, { key: 6 }, [
21488
21488
  y("div", ab, [
21489
- A[20] || (A[20] = y("label", { class: "admin-dialog__label" }, "Resource slug", -1)),
21489
+ z[20] || (z[20] = y("label", { class: "admin-dialog__label" }, "Resource slug", -1)),
21490
21490
  I(l(be), {
21491
21491
  modelValue: v.value,
21492
- "onUpdate:modelValue": A[8] || (A[8] = (R) => v.value = R),
21492
+ "onUpdate:modelValue": z[8] || (z[8] = (R) => v.value = R),
21493
21493
  placeholder: "articles"
21494
21494
  }, null, 8, ["modelValue"])
21495
21495
  ]),
21496
21496
  y("div", tb, [
21497
- A[21] || (A[21] = y("label", { class: "admin-dialog__label" }, "Limit", -1)),
21497
+ z[21] || (z[21] = y("label", { class: "admin-dialog__label" }, "Limit", -1)),
21498
21498
  I(l(be), {
21499
21499
  modelValue: L.value,
21500
- "onUpdate:modelValue": A[9] || (A[9] = (R) => L.value = R),
21500
+ "onUpdate:modelValue": z[9] || (z[9] = (R) => L.value = R),
21501
21501
  type: "number"
21502
21502
  }, null, 8, ["modelValue"])
21503
21503
  ])
21504
21504
  ], 64)) : P("", !0)
21505
21505
  ]),
21506
21506
  y("footer", nb, [
21507
- k.value ? P("", !0) : (o(), h("span", ob, [...A[22] || (A[22] = [
21507
+ k.value ? P("", !0) : (o(), h("span", ob, [...z[22] || (z[22] = [
21508
21508
  D(" Заполните ", -1),
21509
21509
  y("span", { class: "admin-dialog__required" }, "*", -1),
21510
21510
  D("-поля ", -1)
@@ -21513,7 +21513,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21513
21513
  variant: "ghost",
21514
21514
  onClick: H
21515
21515
  }, {
21516
- default: w(() => [...A[23] || (A[23] = [
21516
+ default: w(() => [...z[23] || (z[23] = [
21517
21517
  D("Отмена", -1)
21518
21518
  ])]),
21519
21519
  _: 1
@@ -21611,7 +21611,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21611
21611
  const Le = String(ce.type ?? "");
21612
21612
  return Le === "stats" || Le === "stat" ? 1 : Le === "gauge" || Le === "chart" || Le === "bar-chart" || Le === "donut-chart" || Le === "heatmap" || Le === "recent_list" || Le === "recent-list" || Le === "recent-table" || Le === "markdown" || Le === "iframe" || Le === "table" ? 2 : 1;
21613
21613
  }
21614
- const z = g(() => [
21614
+ const A = g(() => [
21615
21615
  { key: "7d", label: m("admin.dashboard.period.7d", "За 7 дней") },
21616
21616
  { key: "30d", label: m("admin.dashboard.period.30d", "За 30 дней") },
21617
21617
  { key: "90d", label: m("admin.dashboard.period.90d", "За 90 дней") },
@@ -21634,7 +21634,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21634
21634
  }
21635
21635
  }
21636
21636
  let j = null;
21637
- const A = g(() => {
21637
+ const z = g(() => {
21638
21638
  let J = 0;
21639
21639
  for (const ce of f.value) {
21640
21640
  const ie = ce.refresh;
@@ -21644,7 +21644,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21644
21644
  });
21645
21645
  function R() {
21646
21646
  N();
21647
- const J = A.value;
21647
+ const J = z.value;
21648
21648
  J <= 0 || (j = setInterval(() => {
21649
21649
  H();
21650
21650
  }, J * 1e3));
@@ -21652,10 +21652,10 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21652
21652
  function N() {
21653
21653
  j !== null && (clearInterval(j), j = null);
21654
21654
  }
21655
- we(
21656
- () => A.value,
21655
+ Ie(
21656
+ () => z.value,
21657
21657
  () => R()
21658
- ), Ee(async () => {
21658
+ ), Ne(async () => {
21659
21659
  d.manifest === null && await d.load().catch(() => {
21660
21660
  });
21661
21661
  const J = u.value;
@@ -21663,7 +21663,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21663
21663
  }), c.period && (U.value = c.period, await H())), R();
21664
21664
  }), Q9(() => {
21665
21665
  N();
21666
- }), we(
21666
+ }), Ie(
21667
21667
  () => u.value,
21668
21668
  async (J, ce) => {
21669
21669
  J !== ce && (J ? (await c.openDashboard(J).catch(() => {
@@ -21671,7 +21671,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21671
21671
  }
21672
21672
  );
21673
21673
  const G = g(
21674
- () => z.value.find((J) => J.key === U.value)?.label ?? m("admin.dashboard.period.label", "Период")
21674
+ () => A.value.find((J) => J.key === U.value)?.label ?? m("admin.dashboard.period.label", "Период")
21675
21675
  ), te = S(null), Z = S(null), K = S("");
21676
21676
  function B() {
21677
21677
  te.value = "add", Z.value = null, K.value = "";
@@ -21731,18 +21731,18 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21731
21731
  ...J
21732
21732
  });
21733
21733
  }
21734
- const se = S(null), le = S(null), Ie = S(!1);
21734
+ const se = S(null), le = S(null), we = S(!1);
21735
21735
  function ze(J) {
21736
21736
  if (!c.editMode) {
21737
- Ie.value = !1;
21737
+ we.value = !1;
21738
21738
  return;
21739
21739
  }
21740
21740
  const ce = J.target;
21741
- Ie.value = !!ce?.closest('[data-drag-handle="true"]');
21741
+ we.value = !!ce?.closest('[data-drag-handle="true"]');
21742
21742
  }
21743
21743
  function _1(J, ce) {
21744
21744
  if (c.editMode && ce.dataTransfer !== null) {
21745
- if (!Ie.value) {
21745
+ if (!we.value) {
21746
21746
  ce.preventDefault();
21747
21747
  return;
21748
21748
  }
@@ -21750,7 +21750,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21750
21750
  }
21751
21751
  }
21752
21752
  function z9() {
21753
- Ie.value = !1, se.value = null, le.value = null;
21753
+ we.value = !1, se.value = null, le.value = null;
21754
21754
  }
21755
21755
  function H9(J, ce) {
21756
21756
  c.editMode && se.value !== null && (ce.preventDefault(), le.value !== J && (le.value = J));
@@ -21847,7 +21847,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
21847
21847
  })
21848
21848
  ]),
21849
21849
  default: w(() => [
21850
- (o(!0), h(W, null, ee(z.value, (ie) => (o(), F(l(De), {
21850
+ (o(!0), h(W, null, ee(A.value, (ie) => (o(), F(l(De), {
21851
21851
  key: ie.key,
21852
21852
  onClick: (re) => q(ie.key)
21853
21853
  }, {
@@ -22014,7 +22014,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
22014
22014
  ), s = g(
22015
22015
  () => i.value[0]?.slug ?? null
22016
22016
  ), u = WI();
22017
- return we(
22017
+ return Ie(
22018
22018
  s,
22019
22019
  (m) => {
22020
22020
  m && u.openDashboard(m);
@@ -22125,21 +22125,21 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
22125
22125
  })
22126
22126
  ]));
22127
22127
  }
22128
- }), Vb = We("admin-screen", () => {
22128
+ }), Vb = Ze("admin-screen", () => {
22129
22129
  const a = S(null), t = S(""), n = S(null), r = S([]), d = S([]), c = S([]), i = S(null), s = S({}), u = S({}), m = S({}), p = S(!1), f = S(!1), M = S(null), b = S(null), v = g(() => M.value !== null);
22130
22130
  function L(R, N) {
22131
22131
  for (const G of Object.keys(R)) delete R[G];
22132
22132
  Object.assign(R, N);
22133
22133
  }
22134
22134
  function k(R) {
22135
- return R.map((N) => z(N));
22135
+ return R.map((N) => A(N));
22136
22136
  }
22137
- function z(R) {
22137
+ function A(R) {
22138
22138
  const N = { ...R };
22139
22139
  return Array.isArray(R.children) && R.items === void 0 ? N.items = R.children.map(
22140
- (G) => typeof G == "object" && G !== null ? z(G) : G
22140
+ (G) => typeof G == "object" && G !== null ? A(G) : G
22141
22141
  ) : Array.isArray(R.items) && (N.items = R.items.map(
22142
- (G) => typeof G == "object" && G !== null ? z(G) : G
22142
+ (G) => typeof G == "object" && G !== null ? A(G) : G
22143
22143
  )), R.props && typeof R.props == "object" && Object.assign(N, R.props), N;
22144
22144
  }
22145
22145
  function U() {
@@ -22172,7 +22172,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
22172
22172
  return Z.state && Object.keys(Z.state).length > 0 && (L(s.value, Z.state), L(u.value, { ...Z.state })), Z.message && (b.value = Z.message), Z.refresh && await E(a.value).catch(() => {
22173
22173
  }), Z;
22174
22174
  } catch (G) {
22175
- throw G instanceof jo ? m.value = { ...G.fields } : (G instanceof Ze || G instanceof Error) && (M.value = G), G;
22175
+ throw G instanceof jo ? m.value = { ...G.fields } : (G instanceof Ee || G instanceof Error) && (M.value = G), G;
22176
22176
  } finally {
22177
22177
  f.value = !1;
22178
22178
  }
@@ -22186,7 +22186,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
22186
22186
  function j(R) {
22187
22187
  m.value = { ...R };
22188
22188
  }
22189
- function A() {
22189
+ function z() {
22190
22190
  m.value = {};
22191
22191
  }
22192
22192
  return {
@@ -22213,7 +22213,7 @@ const g2 = q9(), CL = g2.register, _L = g2.get, SL = g2.has, qL = g2.list, SP =
22213
22213
  runMethod: q,
22214
22214
  setField: H,
22215
22215
  setErrors: j,
22216
- clearErrors: A
22216
+ clearErrors: z
22217
22217
  };
22218
22218
  }), dI = /* @__PURE__ */ Symbol("admin.infolist-record");
22219
22219
  function XI(a) {
@@ -22333,7 +22333,7 @@ const JI = /* @__PURE__ */ ae({
22333
22333
  },
22334
22334
  setup(a) {
22335
22335
  const t = a, n = d1(), r = Vb(), d = g(() => t.slug ? t.slug : String(n.params.slug ?? n.meta?.slug ?? "")), c = L9(r.state, r.errors);
22336
- XI(r.state), we(
22336
+ XI(r.state), Ie(
22337
22337
  () => r.errors,
22338
22338
  (p) => {
22339
22339
  c.setErrors({ ...p });
@@ -22343,10 +22343,10 @@ const JI = /* @__PURE__ */ ae({
22343
22343
  const i = g(
22344
22344
  () => r.layout.filter((p) => typeof p.type == "string").map((p) => p)
22345
22345
  ), s = g(() => !r.loading && d.value !== "");
22346
- Ee(async () => {
22346
+ Ne(async () => {
22347
22347
  d.value && await r.load(d.value).catch(() => {
22348
22348
  });
22349
- }), we(
22349
+ }), Ie(
22350
22350
  () => d.value,
22351
22351
  async (p) => {
22352
22352
  p ? await r.load(p).catch(() => {
@@ -22451,7 +22451,7 @@ const JI = /* @__PURE__ */ ae({
22451
22451
  });
22452
22452
  n("success", b);
22453
22453
  } catch (b) {
22454
- (b instanceof Ze ? b.status : b?.response?.status) === 429 ? u.value = "Слишком много попыток входа. Подождите минуту и попробуйте снова" : b instanceof jo ? (m.value = b.fields, u.value = b.firstFieldMessage()) : b instanceof _9 ? u.value = "Нет соединения с сервером" : b instanceof Ze ? u.value = b.message || "Не удалось войти" : u.value = b.message;
22454
+ (b instanceof Ee ? b.status : b?.response?.status) === 429 ? u.value = "Слишком много попыток входа. Подождите минуту и попробуйте снова" : b instanceof jo ? (m.value = b.fields, u.value = b.firstFieldMessage()) : b instanceof _9 ? u.value = "Нет соединения с сервером" : b instanceof Ee ? u.value = b.message || "Не удалось войти" : u.value = b.message;
22455
22455
  } finally {
22456
22456
  s.value = !1;
22457
22457
  }
@@ -22539,8 +22539,8 @@ const JI = /* @__PURE__ */ ae({
22539
22539
  H instanceof HTMLInputElement && (s.value[q] = H);
22540
22540
  }
22541
22541
  function v(q, H) {
22542
- const j = H.target, A = j.value.replace(/\D/g, "").slice(-1);
22543
- c.value[q] = A, j.value = A, A && q < c.value.length - 1 && a1(() => s.value[q + 1]?.focus()), f.value.length === c.value.length && z();
22542
+ const j = H.target, z = j.value.replace(/\D/g, "").slice(-1);
22543
+ c.value[q] = z, j.value = z, z && q < c.value.length - 1 && a1(() => s.value[q + 1]?.focus()), f.value.length === c.value.length && A();
22544
22544
  }
22545
22545
  function L(q, H) {
22546
22546
  H.key === "Backspace" && !c.value[q] && q > 0 ? a1(() => s.value[q - 1]?.focus()) : H.key === "ArrowLeft" && q > 0 ? (s.value[q - 1]?.focus(), H.preventDefault()) : H.key === "ArrowRight" && q < c.value.length - 1 && (s.value[q + 1]?.focus(), H.preventDefault());
@@ -22549,14 +22549,14 @@ const JI = /* @__PURE__ */ ae({
22549
22549
  const j = (q.clipboardData?.getData("text") ?? "").replace(/\D/g, "").slice(0, c.value.length);
22550
22550
  if (j.length !== 0) {
22551
22551
  q.preventDefault();
22552
- for (let A = 0; A < c.value.length; A++)
22553
- c.value[A] = j[A] ?? "";
22552
+ for (let z = 0; z < c.value.length; z++)
22553
+ c.value[z] = j[z] ?? "";
22554
22554
  a1(() => {
22555
- s.value[Math.min(j.length, c.value.length - 1)]?.focus(), j.length === c.value.length && z();
22555
+ s.value[Math.min(j.length, c.value.length - 1)]?.focus(), j.length === c.value.length && A();
22556
22556
  });
22557
22557
  }
22558
22558
  }
22559
- async function z() {
22559
+ async function A() {
22560
22560
  if (!(u.value || !M.value)) {
22561
22561
  u.value = !0, m.value = null;
22562
22562
  try {
@@ -22568,7 +22568,7 @@ const JI = /* @__PURE__ */ ae({
22568
22568
  }
22569
22569
  n("success");
22570
22570
  } catch (q) {
22571
- q instanceof jo ? m.value = q.firstFieldMessage() ?? "Неверный код" : q instanceof _9 ? m.value = "Нет соединения с сервером" : q instanceof Ze ? m.value = q.message || "Не удалось проверить код" : m.value = q.message;
22571
+ q instanceof jo ? m.value = q.firstFieldMessage() ?? "Неверный код" : q instanceof _9 ? m.value = "Нет соединения с сервером" : q instanceof Ee ? m.value = q.message || "Не удалось проверить код" : m.value = q.message;
22572
22572
  } finally {
22573
22573
  u.value = !1;
22574
22574
  }
@@ -22583,7 +22583,7 @@ const JI = /* @__PURE__ */ ae({
22583
22583
  return (q, H) => (o(), h("form", {
22584
22584
  class: "admin-auth-card__bd",
22585
22585
  novalidate: "",
22586
- onSubmit: pe(z, ["prevent"])
22586
+ onSubmit: pe(A, ["prevent"])
22587
22587
  }, [
22588
22588
  m.value ? (o(), F(l(Xe), {
22589
22589
  key: 0,
@@ -22612,19 +22612,19 @@ const JI = /* @__PURE__ */ ae({
22612
22612
  class: "admin-code-input",
22613
22613
  onPaste: k
22614
22614
  }, [
22615
- (o(!0), h(W, null, ee(c.value, (j, A) => (o(), h("input", {
22616
- key: A,
22615
+ (o(!0), h(W, null, ee(c.value, (j, z) => (o(), h("input", {
22616
+ key: z,
22617
22617
  ref_for: !0,
22618
- ref: (R) => b(A, R),
22619
- value: c.value[A],
22618
+ ref: (R) => b(z, R),
22619
+ value: c.value[z],
22620
22620
  type: "text",
22621
22621
  inputmode: "numeric",
22622
22622
  autocomplete: "one-time-code",
22623
22623
  maxlength: "1",
22624
22624
  disabled: u.value,
22625
- "aria-label": `Цифра ${A + 1}`,
22626
- onInput: (R) => v(A, R),
22627
- onKeydown: (R) => L(A, R)
22625
+ "aria-label": `Цифра ${z + 1}`,
22626
+ onInput: (R) => v(z, R),
22627
+ onKeydown: (R) => L(z, R)
22628
22628
  }, null, 40, Jb))), 128))
22629
22629
  ], 32)) : (o(), F(l(be), {
22630
22630
  key: 3,
@@ -22697,12 +22697,12 @@ const JI = /* @__PURE__ */ ae({
22697
22697
  }
22698
22698
  await r.push({ name: t.homeRouteName });
22699
22699
  }
22700
- return we(
22700
+ return Ie(
22701
22701
  () => n.isAuthenticated,
22702
22702
  (i) => {
22703
22703
  i && c();
22704
22704
  }
22705
- ), Ee(() => {
22705
+ ), Ne(() => {
22706
22706
  n.isAuthenticated && c();
22707
22707
  }), (i, s) => (o(), h("div", eC, [
22708
22708
  a.showCornerActions ? (o(), h("div", aC, [
@@ -22943,10 +22943,10 @@ const JI = /* @__PURE__ */ ae({
22943
22943
  })
22944
22944
  ]));
22945
22945
  }
22946
- }), MI = { page: 1, per_page: 20, total: 0, last_page: 1 }, YI = We("admin-resource-index", () => {
22946
+ }), MI = { page: 1, per_page: 20, total: 0, last_page: 1 }, YI = Ze("admin-resource-index", () => {
22947
22947
  const a = S(null), t = S([]), n = S({ ...MI }), r = S(!1), d = S(!1), c = S(null);
22948
22948
  let i = null;
22949
- const s = 200, u = S(""), m = S({}), p = S(null), f = S(null), M = S(/* @__PURE__ */ new Set()), b = g(() => !r.value && c.value === null && t.value.length === 0), v = g(() => M.value.size), L = g(() => M.value.size > 0), k = g(() => c.value !== null), z = g(() => M.value.size === 0 || t.value.length === 0 ? "none" : t.value.every(($) => M.value.has(U($))) ? "all" : "mixed");
22949
+ const s = 200, u = S(""), m = S({}), p = S(null), f = S(null), M = S(/* @__PURE__ */ new Set()), b = g(() => !r.value && c.value === null && t.value.length === 0), v = g(() => M.value.size), L = g(() => M.value.size > 0), k = g(() => c.value !== null), A = g(() => M.value.size === 0 || t.value.length === 0 ? "none" : t.value.every(($) => M.value.has(U($))) ? "all" : "mixed");
22950
22950
  function U(_) {
22951
22951
  return _.id ?? _.key ?? "";
22952
22952
  }
@@ -22984,7 +22984,7 @@ const JI = /* @__PURE__ */ ae({
22984
22984
  r.value = !1, d.value = !1, i !== null && (clearTimeout(i), i = null);
22985
22985
  }
22986
22986
  }
22987
- async function A(_) {
22987
+ async function z(_) {
22988
22988
  u.value = _, n.value.page = 1, await j();
22989
22989
  }
22990
22990
  async function R(_, $) {
@@ -23007,7 +23007,7 @@ const JI = /* @__PURE__ */ ae({
23007
23007
  $.has(_) ? $.delete(_) : $.add(_), M.value = $;
23008
23008
  }
23009
23009
  function B() {
23010
- if (z.value === "all") {
23010
+ if (A.value === "all") {
23011
23011
  M.value = /* @__PURE__ */ new Set();
23012
23012
  return;
23013
23013
  }
@@ -23039,12 +23039,12 @@ const JI = /* @__PURE__ */ ae({
23039
23039
  hasError: k,
23040
23040
  hasSelection: L,
23041
23041
  selectedCount: v,
23042
- selectionState: z,
23042
+ selectionState: A,
23043
23043
  // actions
23044
23044
  setSlug: E,
23045
23045
  reset: q,
23046
23046
  load: j,
23047
- setSearch: A,
23047
+ setSearch: z,
23048
23048
  setFilter: R,
23049
23049
  clearFilters: N,
23050
23050
  setSort: G,
@@ -23271,7 +23271,7 @@ const xI = ae({
23271
23271
  emits: ["update:search", "apply-filter", "reset", "group-by", "columns-visibility", "save-view"],
23272
23272
  setup(a, { emit: t }) {
23273
23273
  const n = a, r = t, d = S(n.search);
23274
- we(
23274
+ Ie(
23275
23275
  () => n.search,
23276
23276
  (C) => {
23277
23277
  d.value = C;
@@ -23321,7 +23321,7 @@ const xI = ae({
23321
23321
  return C.type === "switcher" ? `${C.label}: ${V ? "да" : "нет"}` : `${C.label}: ${String(V)}`;
23322
23322
  }
23323
23323
  const k = S({});
23324
- function z(C) {
23324
+ function A(C) {
23325
23325
  return C in k.value || (k.value[C] = n.values[C] ?? null), k.value[C];
23326
23326
  }
23327
23327
  function U(C, V) {
@@ -23335,17 +23335,17 @@ const xI = ae({
23335
23335
  U(C, V);
23336
23336
  return;
23337
23337
  }
23338
- const $ = z(C), ne = Array.isArray($) ? [...$] : [], me = ne.findIndex((ke) => String(ke) === String(V));
23338
+ const $ = A(C), ne = Array.isArray($) ? [...$] : [], me = ne.findIndex((ke) => String(ke) === String(V));
23339
23339
  me >= 0 ? ne.splice(me, 1) : ne.push(V), U(C, ne);
23340
23340
  }
23341
23341
  function H(C, V) {
23342
- const _ = z(C);
23342
+ const _ = A(C);
23343
23343
  return Array.isArray(_) ? _.some(($) => String($) === String(V)) : _ != null && String(_) === String(V);
23344
23344
  }
23345
23345
  const j = g(
23346
23346
  () => n.columns.filter((C) => C.groupable === !0 && (C.key ?? C.name))
23347
23347
  );
23348
- function A(C, V) {
23348
+ function z(C, V) {
23349
23349
  r("group-by", C), V();
23350
23350
  }
23351
23351
  function R(C) {
@@ -23423,7 +23423,7 @@ const xI = ae({
23423
23423
  }, [
23424
23424
  I(l(xI), {
23425
23425
  filter: _,
23426
- draft: z(_.name),
23426
+ draft: A(_.name),
23427
23427
  "is-checked": ($) => H(_.name, $),
23428
23428
  onToggleOption: ($) => q(_.name, $, _.multiple ?? !1),
23429
23429
  onSetDraft: ($) => U(_.name, $)
@@ -23476,7 +23476,7 @@ const xI = ae({
23476
23476
  }, [
23477
23477
  I(l(xI), {
23478
23478
  filter: _,
23479
- draft: z(_.name),
23479
+ draft: A(_.name),
23480
23480
  "is-checked": ($) => H(_.name, $),
23481
23481
  onToggleOption: ($) => q(_.name, $, _.multiple ?? !1),
23482
23482
  onSetDraft: ($) => U(_.name, $)
@@ -23581,7 +23581,7 @@ const xI = ae({
23581
23581
  type: "button",
23582
23582
  role: "menuitem",
23583
23583
  class: "admin-toolbar__list-item",
23584
- onClick: V[5] || (V[5] = (_) => A(null, () => {
23584
+ onClick: V[5] || (V[5] = (_) => z(null, () => {
23585
23585
  }))
23586
23586
  }, [
23587
23587
  a.groupBy ? P("", !0) : (o(), F(l(Q), {
@@ -23596,7 +23596,7 @@ const xI = ae({
23596
23596
  type: "button",
23597
23597
  role: "menuitem",
23598
23598
  class: "admin-toolbar__list-item",
23599
- onClick: ($) => A(R(_), () => {
23599
+ onClick: ($) => z(R(_), () => {
23600
23600
  })
23601
23601
  }, [
23602
23602
  a.groupBy === R(_) ? (o(), F(l(Q), {
@@ -23717,12 +23717,12 @@ const xI = ae({
23717
23717
  }
23718
23718
  i.value = !0;
23719
23719
  try {
23720
- const { getAdminClient: L } = await Promise.resolve().then(() => _e), k = L(), z = n.inputType === "switcher" ? c.value === "true" || c.value === "1" : c.value;
23720
+ const { getAdminClient: L } = await Promise.resolve().then(() => _e), k = L(), A = n.inputType === "switcher" ? c.value === "true" || c.value === "1" : c.value;
23721
23721
  await k.post(`/${n.resourceSlug}/inlineUpdate`, {
23722
23722
  id: n.rowId,
23723
23723
  column: n.column,
23724
- value: z
23725
- }), r("saved", z), d.value = !1;
23724
+ value: A
23725
+ }), r("saved", A), d.value = !1;
23726
23726
  } catch (L) {
23727
23727
  typeof console < "u" && console.error("[admin] inline-update failed:", L), ue.error(`Не удалось обновить «${n.column}».`);
23728
23728
  } finally {
@@ -23752,7 +23752,7 @@ const xI = ae({
23752
23752
  key: 1,
23753
23753
  ref_key: "inputRef",
23754
23754
  ref: s,
23755
- "onUpdate:modelValue": k[0] || (k[0] = (z) => c.value = z),
23755
+ "onUpdate:modelValue": k[0] || (k[0] = (A) => c.value = A),
23756
23756
  type: "number",
23757
23757
  class: "admin-inline-edit__input",
23758
23758
  disabled: i.value,
@@ -23766,7 +23766,7 @@ const xI = ae({
23766
23766
  key: 2,
23767
23767
  ref_key: "inputRef",
23768
23768
  ref: s,
23769
- "onUpdate:modelValue": k[2] || (k[2] = (z) => c.value = z),
23769
+ "onUpdate:modelValue": k[2] || (k[2] = (A) => c.value = A),
23770
23770
  type: "date",
23771
23771
  class: "admin-inline-edit__input",
23772
23772
  disabled: i.value,
@@ -23780,7 +23780,7 @@ const xI = ae({
23780
23780
  key: 3,
23781
23781
  ref_key: "inputRef",
23782
23782
  ref: s,
23783
- "onUpdate:modelValue": k[4] || (k[4] = (z) => c.value = z),
23783
+ "onUpdate:modelValue": k[4] || (k[4] = (A) => c.value = A),
23784
23784
  class: "admin-inline-edit__input",
23785
23785
  disabled: i.value,
23786
23786
  onKeydown: M,
@@ -23789,17 +23789,17 @@ const xI = ae({
23789
23789
  onClick: k[5] || (k[5] = pe(() => {
23790
23790
  }, ["stop"]))
23791
23791
  }, [
23792
- (o(!0), h(W, null, ee(v.value, (z) => (o(), h("option", {
23793
- key: z.value,
23794
- value: z.value
23795
- }, x(z.label), 9, e_))), 128))
23792
+ (o(!0), h(W, null, ee(v.value, (A) => (o(), h("option", {
23793
+ key: A.value,
23794
+ value: A.value
23795
+ }, x(A.label), 9, e_))), 128))
23796
23796
  ], 40, QC)), [
23797
23797
  [bw, c.value]
23798
23798
  ]) : a.inputType === "textarea" ? i1((o(), h("textarea", {
23799
23799
  key: 4,
23800
23800
  ref_key: "inputRef",
23801
23801
  ref: s,
23802
- "onUpdate:modelValue": k[6] || (k[6] = (z) => c.value = z),
23802
+ "onUpdate:modelValue": k[6] || (k[6] = (A) => c.value = A),
23803
23803
  class: "admin-inline-edit__input admin-inline-edit__input--textarea",
23804
23804
  rows: "3",
23805
23805
  disabled: i.value,
@@ -23813,7 +23813,7 @@ const xI = ae({
23813
23813
  key: 5,
23814
23814
  ref_key: "inputRef",
23815
23815
  ref: s,
23816
- "onUpdate:modelValue": k[8] || (k[8] = (z) => c.value = z),
23816
+ "onUpdate:modelValue": k[8] || (k[8] = (A) => c.value = A),
23817
23817
  type: "text",
23818
23818
  class: "admin-inline-edit__input",
23819
23819
  disabled: i.value,
@@ -23863,7 +23863,7 @@ const xI = ae({
23863
23863
  s.value = !1;
23864
23864
  }
23865
23865
  }
23866
- function z(_) {
23866
+ function A(_) {
23867
23867
  const $ = [], ne = (me) => {
23868
23868
  for (const ke of me)
23869
23869
  $.push(ke.key), ke.children?.length && ne(ke.children);
@@ -23871,7 +23871,7 @@ const xI = ae({
23871
23871
  return ne(_), $;
23872
23872
  }
23873
23873
  function U() {
23874
- p.value = z(c.value);
23874
+ p.value = A(c.value);
23875
23875
  }
23876
23876
  function E() {
23877
23877
  p.value = [];
@@ -23889,7 +23889,7 @@ const xI = ae({
23889
23889
  }
23890
23890
  const j = g(
23891
23891
  () => q.value === null ? null : H(c.value, q.value)
23892
- ), A = g(() => j.value?.slug ?? t.slug), R = g(() => {
23892
+ ), z = g(() => j.value?.slug ?? t.slug), R = g(() => {
23893
23893
  const _ = j.value;
23894
23894
  if (!_) return null;
23895
23895
  const $ = _.record?.id;
@@ -23900,13 +23900,13 @@ const xI = ae({
23900
23900
  }
23901
23901
  function G() {
23902
23902
  R.value !== null && n.push({
23903
- name: `admin.resource.${A.value}.edit`,
23903
+ name: `admin.resource.${z.value}.edit`,
23904
23904
  params: { id: String(R.value) }
23905
23905
  });
23906
23906
  }
23907
23907
  function te() {
23908
23908
  R.value !== null && n.push({
23909
- name: `admin.resource.${A.value}.view`,
23909
+ name: `admin.resource.${z.value}.view`,
23910
23910
  params: { id: String(R.value) }
23911
23911
  });
23912
23912
  }
@@ -23934,17 +23934,17 @@ const xI = ae({
23934
23934
  async function C() {
23935
23935
  if (R.value !== null && confirm("Удалить выбранный узел?"))
23936
23936
  try {
23937
- await ge().post(`/${A.value}/delete`, { id: R.value }), f.value = [], await k();
23937
+ await ge().post(`/${z.value}/delete`, { id: R.value }), f.value = [], await k();
23938
23938
  } catch (_) {
23939
23939
  u.value = _ instanceof Error ? _ : new Error(String(_));
23940
23940
  }
23941
23941
  }
23942
23942
  let V = null;
23943
- return we(m, () => {
23943
+ return Ie(m, () => {
23944
23944
  V !== null && clearTimeout(V), V = setTimeout(() => {
23945
23945
  k();
23946
23946
  }, 300);
23947
- }), Ee(k), (_, $) => (o(), h("div", n_, [
23947
+ }), Ne(k), (_, $) => (o(), h("div", n_, [
23948
23948
  y("header", o_, [
23949
23949
  y("div", null, [
23950
23950
  y("h1", c_, [
@@ -24174,11 +24174,11 @@ const xI = ae({
24174
24174
  }
24175
24175
  }
24176
24176
  }
24177
- const z = S(!1);
24177
+ const A = S(!1);
24178
24178
  async function U() {
24179
24179
  const T = [...i.selection];
24180
24180
  if (T.length !== 0 && window.confirm(`Удалить выбранные записи (${T.length})?`)) {
24181
- z.value = !0;
24181
+ A.value = !0;
24182
24182
  try {
24183
24183
  const { getAdminClient: O } = await Promise.resolve().then(() => _e), X = O();
24184
24184
  let Y = 0;
@@ -24190,7 +24190,7 @@ const xI = ae({
24190
24190
  i.clearSelection(), await i.load().catch(() => {
24191
24191
  }), Y === T.length ? ue.success(`Удалено записей: ${Y}.`) : ue.error(`Удалено ${Y} из ${T.length}; часть не удалена.`);
24192
24192
  } finally {
24193
- z.value = !1;
24193
+ A.value = !1;
24194
24194
  }
24195
24195
  }
24196
24196
  }
@@ -24234,7 +24234,7 @@ const xI = ae({
24234
24234
  upload_id: Uo.upload_id,
24235
24235
  mapping: L2.mapping
24236
24236
  }
24237
- ), Oo = await A(de, B9.process_id), Eo = Oo.imported ?? 0, vI = Oo.failed ?? 0;
24237
+ ), Oo = await z(de, B9.process_id), Eo = Oo.imported ?? 0, vI = Oo.failed ?? 0;
24238
24238
  vI > 0 ? ue.warning(`Импорт завершён с ошибками: ${Eo} записей, ${vI} ошибок.`) : ue.success(`Импортировано записей: ${Eo}.`), await i.load().catch(() => {
24239
24239
  });
24240
24240
  } catch (Y) {
@@ -24245,7 +24245,7 @@ const xI = ae({
24245
24245
  O.value = "", u.end();
24246
24246
  }
24247
24247
  }
24248
- async function A(T, O) {
24248
+ async function z(T, O) {
24249
24249
  const X = Date.now() + 9e4;
24250
24250
  for (; Date.now() < X; ) {
24251
24251
  await new Promise((de) => setTimeout(de, 800));
@@ -24274,7 +24274,7 @@ const xI = ae({
24274
24274
  align: de.align ?? "left",
24275
24275
  width: typeof de.width == "string" ? de.width : void 0
24276
24276
  };
24277
- }).filter((Y) => Y.key).filter((Y) => Ie.value[Y.key] !== !1);
24277
+ }).filter((Y) => Y.key).filter((Y) => we.value[Y.key] !== !1);
24278
24278
  return [
24279
24279
  ...R.value ? [{
24280
24280
  key: CI,
@@ -24342,7 +24342,7 @@ const xI = ae({
24342
24342
  () => p.value?.filters ?? []
24343
24343
  ), he = g(
24344
24344
  () => p.value?.columns ?? []
24345
- ), se = g(() => `Поиск по ${(p.value?.label ?? d.slug).toLowerCase()}…`), le = S(null), Ie = S({});
24345
+ ), se = g(() => `Поиск по ${(p.value?.label ?? d.slug).toLowerCase()}…`), le = S(null), we = S({});
24346
24346
  async function ze(T, O) {
24347
24347
  await i.setFilter(T, O);
24348
24348
  }
@@ -24356,7 +24356,7 @@ const xI = ae({
24356
24356
  le.value = T, await i.load({ group_by: T });
24357
24357
  }
24358
24358
  function V9(T) {
24359
- Ie.value = T;
24359
+ we.value = T;
24360
24360
  }
24361
24361
  const s1 = S([]), qe = S(null);
24362
24362
  async function S1() {
@@ -24370,10 +24370,10 @@ const xI = ae({
24370
24370
  async function P9(T) {
24371
24371
  qe.value = T.id;
24372
24372
  const O = T.state;
24373
- i.search = O.search ?? "", i.filters = { ...O.filters ?? {} }, i.sortKey = O.sort?.key ?? null, i.sortDirection = O.sort?.direction ?? null, le.value = O.group_by ?? null, Ie.value = { ...O.columns ?? {} }, i.meta.page = 1, await o1();
24373
+ i.search = O.search ?? "", i.filters = { ...O.filters ?? {} }, i.sortKey = O.sort?.key ?? null, i.sortDirection = O.sort?.direction ?? null, le.value = O.group_by ?? null, we.value = { ...O.columns ?? {} }, i.meta.page = 1, await o1();
24374
24374
  }
24375
24375
  async function Ro() {
24376
- qe.value = null, i.search = "", i.filters = {}, i.sortKey = null, i.sortDirection = null, le.value = null, Ie.value = {}, i.meta.page = 1, await o1();
24376
+ qe.value = null, i.search = "", i.filters = {}, i.sortKey = null, i.sortDirection = null, le.value = null, we.value = {}, i.meta.page = 1, await o1();
24377
24377
  }
24378
24378
  async function $o(T, O) {
24379
24379
  if (O?.stopPropagation(), !!T.owned && window.confirm(`Удалить view «${T.name}»?`))
@@ -24399,7 +24399,7 @@ const xI = ae({
24399
24399
  filters: i.filters,
24400
24400
  sort: { key: i.sortKey, direction: i.sortDirection },
24401
24401
  group_by: le.value,
24402
- columns: Ie.value
24402
+ columns: we.value
24403
24403
  }
24404
24404
  }
24405
24405
  );
@@ -24422,12 +24422,12 @@ const xI = ae({
24422
24422
  }
24423
24423
  const ie = S(null), re = S(0);
24424
24424
  let ye = null;
24425
- we(
24425
+ Ie(
24426
24426
  () => i.loading,
24427
24427
  (T, O) => {
24428
24428
  O && !T && i.error === null && (ie.value = Date.now());
24429
24429
  }
24430
- ), Ee(() => {
24430
+ ), Ne(() => {
24431
24431
  ye = setInterval(() => {
24432
24432
  re.value += 1;
24433
24433
  }, 3e4);
@@ -24458,10 +24458,10 @@ const xI = ae({
24458
24458
  u.end();
24459
24459
  }
24460
24460
  }
24461
- Ee(async () => {
24461
+ Ne(async () => {
24462
24462
  i.setSlug(d.slug), s.manifest === null && await s.load().catch(() => {
24463
24463
  }), S1(), await o1();
24464
- }), we(
24464
+ }), Ie(
24465
24465
  () => d.slug,
24466
24466
  async (T, O) => {
24467
24467
  T !== O && (i.setSlug(T), qe.value = null, S1(), await o1());
@@ -24806,7 +24806,7 @@ const xI = ae({
24806
24806
  key: 0,
24807
24807
  size: "sm",
24808
24808
  variant: "danger",
24809
- loading: z.value,
24809
+ loading: A.value,
24810
24810
  onClick: U
24811
24811
  }, {
24812
24812
  default: w(() => [...O[8] || (O[8] = [
@@ -24833,7 +24833,7 @@ const xI = ae({
24833
24833
  values: l(i).filters,
24834
24834
  columns: he.value,
24835
24835
  "group-by": le.value,
24836
- "column-visibility": Ie.value,
24836
+ "column-visibility": we.value,
24837
24837
  "onUpdate:search": _1,
24838
24838
  onApplyFilter: ze,
24839
24839
  onReset: z9,
@@ -25043,7 +25043,7 @@ const xI = ae({
25043
25043
  ])) : P("", !0)
25044
25044
  ]));
25045
25045
  }
25046
- }), hI = We("admin-resource-form", () => {
25046
+ }), hI = Ze("admin-resource-form", () => {
25047
25047
  const a = S(null), t = S("create"), n = S(null), r = S({}), d = S({}), c = S({}), i = S(!1), s = S(!1), u = S(!1), m = S(null), p = g(() => t.value === "create"), f = g(() => t.value === "edit"), M = g(() => t.value === "view"), b = g(() => m.value !== null), v = g(() => {
25048
25048
  const N = r.value, G = d.value, te = /* @__PURE__ */ new Set([...Object.keys(N), ...Object.keys(G)]);
25049
25049
  for (const Z of te)
@@ -25061,7 +25061,7 @@ const xI = ae({
25061
25061
  function k() {
25062
25062
  L(r.value, {}), L(d.value, {}), c.value = {}, i.value = !1, s.value = !1, u.value = !1, m.value = null, n.value = null;
25063
25063
  }
25064
- function z(N, G = {}) {
25064
+ function A(N, G = {}) {
25065
25065
  a.value = N, t.value = "create", n.value = null, L(r.value, G), L(d.value, G), c.value = {}, m.value = null;
25066
25066
  }
25067
25067
  async function U(N, G, te = "edit") {
@@ -25093,7 +25093,7 @@ const xI = ae({
25093
25093
  function j() {
25094
25094
  c.value = {};
25095
25095
  }
25096
- async function A() {
25096
+ async function z() {
25097
25097
  if (!a.value) throw new Error("useResourceFormStore.save() before slug set");
25098
25098
  if (s.value) throw new Error("Already saving");
25099
25099
  s.value = !0, m.value = null, c.value = {};
@@ -25104,7 +25104,7 @@ const xI = ae({
25104
25104
  return n.value = K, L(d.value, { ...r.value }), t.value = "edit", Te().refresh().catch(() => {
25105
25105
  }), K;
25106
25106
  } catch (N) {
25107
- throw N instanceof jo ? c.value = { ...N.fields } : (N instanceof Ze || N instanceof Error) && (m.value = N), N;
25107
+ throw N instanceof jo ? c.value = { ...N.fields } : (N instanceof Ee || N instanceof Error) && (m.value = N), N;
25108
25108
  } finally {
25109
25109
  s.value = !1;
25110
25110
  }
@@ -25143,13 +25143,13 @@ const xI = ae({
25143
25143
  hasError: b,
25144
25144
  // actions
25145
25145
  reset: k,
25146
- prepareCreate: z,
25146
+ prepareCreate: A,
25147
25147
  load: U,
25148
25148
  setField: E,
25149
25149
  setErrors: q,
25150
25150
  seedDefaults: H,
25151
25151
  clearErrors: j,
25152
- save: A,
25152
+ save: z,
25153
25153
  destroy: R
25154
25154
  };
25155
25155
  }), G9 = /* @__PURE__ */ ae({
@@ -25227,21 +25227,21 @@ const xI = ae({
25227
25227
  n.errors,
25228
25228
  t.id !== null && t.id !== void 0 ? "update" : "create"
25229
25229
  );
25230
- we(
25230
+ Ie(
25231
25231
  () => n.errors,
25232
25232
  (q) => {
25233
25233
  s.setErrors({ ...q });
25234
25234
  }
25235
25235
  );
25236
25236
  const u = g(() => r.getResource(t.slug)), m = g(
25237
- () => !n.isCreate && n.hasError && n.error instanceof Ze && n.error.status === 404
25237
+ () => !n.isCreate && n.hasError && n.error instanceof Ee && n.error.status === 404
25238
25238
  ), p = g(
25239
25239
  () => u.value?.fields ?? []
25240
25240
  );
25241
25241
  function f(q, H) {
25242
25242
  for (const j of q) {
25243
- const A = j;
25244
- Array.isArray(A.items) && f(A.items, H), !(A.kind !== "field" || typeof A.name != "string") && (A.defaultValue === null || A.defaultValue === void 0 || (H[A.name] = A.defaultValue));
25243
+ const z = j;
25244
+ Array.isArray(z.items) && f(z.items, H), !(z.kind !== "field" || typeof z.name != "string") && (z.defaultValue === null || z.defaultValue === void 0 || (H[z.name] = z.defaultValue));
25245
25245
  }
25246
25246
  }
25247
25247
  function M() {
@@ -25264,11 +25264,11 @@ const xI = ae({
25264
25264
  return "default";
25265
25265
  }
25266
25266
  });
25267
- Ee(async () => {
25267
+ Ne(async () => {
25268
25268
  r.manifest === null && await r.load().catch(() => {
25269
25269
  }), t.id !== null && t.id !== void 0 ? await n.load(t.slug, t.id, "edit").catch(() => {
25270
25270
  }) : (n.prepareCreate(t.slug, i()), M());
25271
- }), we(
25271
+ }), Ie(
25272
25272
  () => [t.slug, t.id],
25273
25273
  async ([q, H]) => {
25274
25274
  H != null ? await n.load(q, H, "edit").catch(() => {
@@ -25286,18 +25286,18 @@ const xI = ae({
25286
25286
  } catch {
25287
25287
  }
25288
25288
  }
25289
- const z = g(() => {
25289
+ const A = g(() => {
25290
25290
  if (t.indexRouteName) return t.indexRouteName;
25291
25291
  const q = r.getResource(t.slug)?.parent_slug;
25292
25292
  return q ? `admin.resource.${q}.index` : `admin.resource.${t.slug}.index`;
25293
25293
  });
25294
25294
  async function U() {
25295
25295
  confirm("Удалить запись?") && (await n.destroy().catch(() => {
25296
- }), n.hasError || d.push({ name: z.value }).catch(() => {
25296
+ }), n.hasError || d.push({ name: A.value }).catch(() => {
25297
25297
  }));
25298
25298
  }
25299
25299
  function E() {
25300
- n.isDirty && !confirm("Несохранённые изменения будут потеряны. Продолжить?") || d.push({ name: z.value }).catch(() => {
25300
+ n.isDirty && !confirm("Несохранённые изменения будут потеряны. Продолжить?") || d.push({ name: A.value }).catch(() => {
25301
25301
  });
25302
25302
  }
25303
25303
  return (q, H) => (o(), h("section", T_, [
@@ -25494,8 +25494,8 @@ const xI = ae({
25494
25494
  const p = N9(t.node.type);
25495
25495
  return p ? { kind: "entry", component: p } : { kind: "unknown" };
25496
25496
  }), d = g(() => {
25497
- const { type: p, kind: f, items: M, attributes: b, ...v } = t.node, L = b ?? {}, { preset: k, format: z, currency: U, decimals: E, ...q } = L, H = {};
25498
- return z !== void 0 && (H.format = z), U !== void 0 && (H.currency = U), E !== void 0 && (H.decimals = E), { ...v, ...q, preset: k, meta: H };
25497
+ const { type: p, kind: f, items: M, attributes: b, ...v } = t.node, L = b ?? {}, { preset: k, format: A, currency: U, decimals: E, ...q } = L, H = {};
25498
+ return A !== void 0 && (H.format = A), U !== void 0 && (H.currency = U), E !== void 0 && (H.decimals = E), { ...v, ...q, preset: k, meta: H };
25499
25499
  }), c = g(
25500
25500
  () => t.node.items ?? []
25501
25501
  ), i = g(() => t.node.title ?? null), s = g(
@@ -25607,7 +25607,7 @@ const xI = ae({
25607
25607
  r.value = !1;
25608
25608
  }
25609
25609
  }
25610
- Ee(c), we(() => [t.subjectType, t.subjectId], c);
25610
+ Ne(c), Ie(() => [t.subjectType, t.subjectId], c);
25611
25611
  const i = g(() => n.value.length > 0);
25612
25612
  function s(v) {
25613
25613
  return v === "created" ? Re : v === "deleted" || v === "destroyed" ? $e : v.includes("tag") || v.includes("label") ? k2 : Fe;
@@ -25682,25 +25682,25 @@ const xI = ae({
25682
25682
  y("span", gS, x(m(k.created_at)), 1)
25683
25683
  ]),
25684
25684
  p(k) ? (o(), h("ul", MS, [
25685
- (o(!0), h(W, null, ee(k.diff, (z) => (o(), h("li", {
25686
- key: z.field,
25685
+ (o(!0), h(W, null, ee(k.diff, (A) => (o(), h("li", {
25686
+ key: A.field,
25687
25687
  class: ve(["admin-audit-timeline__diff-row", `admin-audit-timeline__diff-row--${k.event}`])
25688
25688
  }, [
25689
- y("span", IS, x(z.field), 1),
25689
+ y("span", IS, x(A.field), 1),
25690
25690
  y("span", wS, [
25691
25691
  k.event === "created" || k.event === "restored" ? (o(), h(W, { key: 0 }, [
25692
25692
  L[0] || (L[0] = y("span", {
25693
25693
  class: "admin-audit-timeline__diff-arrow",
25694
25694
  "aria-hidden": "true"
25695
25695
  }, "→", -1)),
25696
- y("span", xS, x(b(z.after)), 1)
25697
- ], 64)) : k.event === "deleted" || k.event === "destroyed" ? (o(), h("span", LS, x(b(z.before)), 1)) : (o(), h(W, { key: 2 }, [
25698
- y("span", bS, x(b(z.before)), 1),
25696
+ y("span", xS, x(b(A.after)), 1)
25697
+ ], 64)) : k.event === "deleted" || k.event === "destroyed" ? (o(), h("span", LS, x(b(A.before)), 1)) : (o(), h(W, { key: 2 }, [
25698
+ y("span", bS, x(b(A.before)), 1),
25699
25699
  L[1] || (L[1] = y("span", {
25700
25700
  class: "admin-audit-timeline__diff-arrow",
25701
25701
  "aria-hidden": "true"
25702
25702
  }, "→", -1)),
25703
- y("span", CS, x(b(z.after)), 1)
25703
+ y("span", CS, x(b(A.after)), 1)
25704
25704
  ], 64))
25705
25705
  ])
25706
25706
  ], 2))), 128))
@@ -25733,7 +25733,7 @@ const xI = ae({
25733
25733
  const c = g(() => r.getResource(t.slug)), i = g(() => (c.value?.features ?? {}).editable !== !1), s = g(
25734
25734
  () => c.value?.infolist ?? c.value?.fields ?? []
25735
25735
  ), u = g(() => t.auditSubjectType !== null ? t.auditSubjectType : c.value?.subject_type ?? null), m = g(() => {
25736
- const j = n.state, A = [], R = (Z) => {
25736
+ const j = n.state, z = [], R = (Z) => {
25737
25737
  if (typeof Z != "string" || Z === "") return null;
25738
25738
  const K = new Date(Z);
25739
25739
  return Number.isNaN(K.getTime()) ? null : K.toLocaleString("ru-RU", {
@@ -25744,19 +25744,19 @@ const xI = ae({
25744
25744
  minute: "2-digit"
25745
25745
  });
25746
25746
  }, N = R(j.created_at);
25747
- N && A.push({ label: "Создано", value: N });
25747
+ N && z.push({ label: "Создано", value: N });
25748
25748
  const G = R(j.updated_at);
25749
- G && G !== N && A.push({ label: "Обновлено", value: G });
25749
+ G && G !== N && z.push({ label: "Обновлено", value: G });
25750
25750
  const te = typeof j.created_by_name == "string" && j.created_by_name !== "" ? j.created_by_name : typeof j.author == "string" ? j.author : null;
25751
- return te && A.push({ label: "Автор", value: te }), A;
25751
+ return te && z.push({ label: "Автор", value: te }), z;
25752
25752
  }), p = g(() => {
25753
- const j = n.state, A = j.title ?? j.name ?? j.label;
25754
- return typeof A == "string" && A.length > 0 ? A : `${c.value?.label ?? t.slug}: запись #${t.id}`;
25753
+ const j = n.state, z = j.title ?? j.name ?? j.label;
25754
+ return typeof z == "string" && z.length > 0 ? z : `${c.value?.label ?? t.slug}: запись #${t.id}`;
25755
25755
  }), f = g(
25756
25756
  () => c.value?.label ?? t.slug
25757
25757
  ), M = g(() => `${t.uidPrefix}${t.id}`), b = g(() => {
25758
- const A = n.state[t.statusField];
25759
- return typeof A == "string" && A.length > 0 ? A : null;
25758
+ const z = n.state[t.statusField];
25759
+ return typeof z == "string" && z.length > 0 ? z : null;
25760
25760
  }), v = {
25761
25761
  published: "success",
25762
25762
  active: "success",
@@ -25774,29 +25774,29 @@ const xI = ae({
25774
25774
  function L(j) {
25775
25775
  return v[j.toLowerCase()] ?? "neutral";
25776
25776
  }
25777
- const k = g(() => (c.value?.actions ?? []).map((A) => ({
25778
- key: String(A.key ?? A.name ?? ""),
25779
- label: String(A.label ?? A.name ?? A.key ?? ""),
25780
- confirm: typeof A.confirm == "string" ? A.confirm : void 0
25781
- })).filter((A) => A.key !== "" && A.label !== ""));
25782
- async function z(j) {
25777
+ const k = g(() => (c.value?.actions ?? []).map((z) => ({
25778
+ key: String(z.key ?? z.name ?? ""),
25779
+ label: String(z.label ?? z.name ?? z.key ?? ""),
25780
+ confirm: typeof z.confirm == "string" ? z.confirm : void 0
25781
+ })).filter((z) => z.key !== "" && z.label !== ""));
25782
+ async function A(j) {
25783
25783
  if (!(j.confirm && !window.confirm(j.confirm)))
25784
25784
  try {
25785
- const { getAdminClient: A } = await Promise.resolve().then(() => _e);
25786
- await A().post(`/${t.slug}/action/${j.key}`, { ids: [t.id] }), await n.load(t.slug, t.id, "view").catch(() => {
25785
+ const { getAdminClient: z } = await Promise.resolve().then(() => _e);
25786
+ await z().post(`/${t.slug}/action/${j.key}`, { ids: [t.id] }), await n.load(t.slug, t.id, "view").catch(() => {
25787
25787
  });
25788
- } catch (A) {
25789
- typeof console < "u" && console.error("[admin] action failed:", A);
25788
+ } catch (z) {
25789
+ typeof console < "u" && console.error("[admin] action failed:", z);
25790
25790
  }
25791
25791
  }
25792
- Ee(async () => {
25792
+ Ne(async () => {
25793
25793
  r.manifest === null && await r.load().catch(() => {
25794
25794
  }), await n.load(t.slug, t.id, "view").catch(() => {
25795
25795
  });
25796
- }), we(
25796
+ }), Ie(
25797
25797
  () => [t.slug, t.id],
25798
- async ([j, A]) => {
25799
- await n.load(j, A, "view").catch(() => {
25798
+ async ([j, z]) => {
25799
+ await n.load(j, z, "view").catch(() => {
25800
25800
  });
25801
25801
  }
25802
25802
  );
@@ -25824,7 +25824,7 @@ const xI = ae({
25824
25824
  }), n.hasError || d.push({ name: U.value }).catch(() => {
25825
25825
  }));
25826
25826
  }
25827
- return (j, A) => (o(), h("section", qS, [
25827
+ return (j, z) => (o(), h("section", qS, [
25828
25828
  y("header", AS, [
25829
25829
  y("div", zS, [
25830
25830
  y("button", {
@@ -25846,7 +25846,7 @@ const xI = ae({
25846
25846
  "data-variant": L(b.value),
25847
25847
  "data-status": b.value
25848
25848
  }, [
25849
- A[0] || (A[0] = y("span", {
25849
+ z[0] || (z[0] = y("span", {
25850
25850
  class: "admin-status-badge__dot",
25851
25851
  "aria-hidden": "true"
25852
25852
  }, null, -1)),
@@ -25869,7 +25869,7 @@ const xI = ae({
25869
25869
  }, null, 8, ["icon"])
25870
25870
  ]),
25871
25871
  default: w(() => [
25872
- A[1] || (A[1] = D(" Редактировать ", -1))
25872
+ z[1] || (z[1] = D(" Редактировать ", -1))
25873
25873
  ]),
25874
25874
  _: 1
25875
25875
  })) : P("", !0),
@@ -25893,7 +25893,7 @@ const xI = ae({
25893
25893
  default: w(() => [
25894
25894
  (o(!0), h(W, null, ee(k.value, (R) => (o(), F(l(De), {
25895
25895
  key: R.key,
25896
- onClick: (N) => z(R)
25896
+ onClick: (N) => A(R)
25897
25897
  }, {
25898
25898
  default: w(() => [
25899
25899
  D(x(R.label), 1)
@@ -25911,7 +25911,7 @@ const xI = ae({
25911
25911
  }, null, 8, ["icon"])
25912
25912
  ]),
25913
25913
  default: w(() => [
25914
- A[2] || (A[2] = D(" Удалить ", -1))
25914
+ z[2] || (z[2] = D(" Удалить ", -1))
25915
25915
  ]),
25916
25916
  _: 1
25917
25917
  })
@@ -25943,7 +25943,7 @@ const xI = ae({
25943
25943
  class: "admin-resource-view__card"
25944
25944
  }, {
25945
25945
  default: w(() => [
25946
- A[3] || (A[3] = y("h2", { class: "admin-resource-view__card-title" }, "Основные данные", -1)),
25946
+ z[3] || (z[3] = y("h2", { class: "admin-resource-view__card-title" }, "Основные данные", -1)),
25947
25947
  (o(!0), h(W, null, ee(s.value, (R, N) => (o(), F(rS, {
25948
25948
  key: N,
25949
25949
  node: R
@@ -25971,7 +25971,7 @@ const xI = ae({
25971
25971
  class: "admin-resource-view__card"
25972
25972
  }, {
25973
25973
  default: w(() => [
25974
- A[4] || (A[4] = y("h2", { class: "admin-resource-view__card-title" }, "Метрики", -1)),
25974
+ z[4] || (z[4] = y("h2", { class: "admin-resource-view__card-title" }, "Метрики", -1)),
25975
25975
  y("dl", TS, [
25976
25976
  (o(!0), h(W, null, ee(m.value, (R) => (o(), h(W, {
25977
25977
  key: R.label
@@ -26039,13 +26039,13 @@ const ow = [tw, nw, v2, yI, kI, pI], NS = { auto: (a, { modes: t = ow } = {}) =>
26039
26039
  if (!p || f !== u) {
26040
26040
  if (u !== -1) {
26041
26041
  const M = new Set(c.map((v) => v.D)), b = [];
26042
- for (const { m: v, C: L, S: k, h: z } of d) if (u & z) {
26042
+ for (const { m: v, C: L, S: k, h: A } of d) if (u & A) {
26043
26043
  const U = k(i, s);
26044
26044
  for (const E of v.eci ?? M) if (!v.u || !E) {
26045
26045
  let q;
26046
26046
  for (const H of c) if (H.D === E || v.eci) {
26047
- const j = H.m === v && H.D === E, A = j ? H.V : H, R = v._ && j ? H.v + U - L : A.v + 12 * (A.D !== E) + (j ? k(j ? H.$ : i, s) : U);
26048
- (!q || R < q.v) && (q = { $: j ? H.$ : i, V: A, m: v, D: E, A: s, v: R });
26047
+ const j = H.m === v && H.D === E, z = j ? H.V : H, R = v._ && j ? H.v + U - L : z.v + 12 * (z.D !== E) + (j ? k(j ? H.$ : i, s) : U);
26048
+ (!q || R < q.v) && (q = { $: j ? H.$ : i, V: z, m: v, D: E, A: s, v: R });
26049
26049
  }
26050
26050
  q && b.push(q);
26051
26051
  }
@@ -26178,10 +26178,10 @@ const YS = (a, t) => {
26178
26178
  if (8 * v.t < m) continue;
26179
26179
  for (M.I = m + 11 & -8; M.I < 8 * v.t; ) M.push(i, 16);
26180
26180
  const L = T9(p.size, p.K);
26181
- return aq(L, p.p, YS(M.F, v)), (U9[c ?? -1] ? [U9[c]] : U9).map((k, z) => {
26181
+ return aq(L, p.p, YS(M.F, v)), (U9[c ?? -1] ? [U9[c]] : U9).map((k, A) => {
26182
26182
  const U = T9(L.size, L.K);
26183
- return tq(U, k, c ?? z, b), U.s = nq(U), U;
26184
- }).reduce((k, z) => z.s < k.s ? z : k);
26183
+ return tq(U, k, c ?? A, b), U.s = nq(U), U;
26184
+ }).reduce((k, A) => A.s < k.s ? A : k);
26185
26185
  }
26186
26186
  }
26187
26187
  C2(4);
@@ -26304,7 +26304,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26304
26304
  ue.warning("Скопируйте вручную.");
26305
26305
  }
26306
26306
  }
26307
- async function z() {
26307
+ async function A() {
26308
26308
  try {
26309
26309
  await navigator.clipboard.writeText(u.value.join(`
26310
26310
  `)), ue.success("Recovery-коды скопированы.");
@@ -26406,7 +26406,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26406
26406
  ]),
26407
26407
  I(l(oe), {
26408
26408
  variant: "ghost",
26409
- onClick: z
26409
+ onClick: A
26410
26410
  }, {
26411
26411
  prepend: w(() => [
26412
26412
  I(l(Q), {
@@ -26511,7 +26511,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26511
26511
  ), M = g(
26512
26512
  () => c.available.map((E) => ({ value: E, label: E === "dark" ? "Тёмная" : E === "light" ? "Светлая" : E }))
26513
26513
  );
26514
- we(
26514
+ Ie(
26515
26515
  () => p.value.locale,
26516
26516
  (E, q) => {
26517
26517
  E === q || !E || i.setLocale(E).then(() => {
@@ -26519,7 +26519,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26519
26519
  }).catch(() => {
26520
26520
  });
26521
26521
  }
26522
- ), we(
26522
+ ), Ie(
26523
26523
  () => p.value.theme,
26524
26524
  (E, q) => {
26525
26525
  E === q || !E || c.setTheme(E).catch(() => {
@@ -26533,7 +26533,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26533
26533
  r("avatar-replace");
26534
26534
  }
26535
26535
  const L = S(!!d.user?.twoFactorEnabled), k = g(() => L.value);
26536
- function z() {
26536
+ function A() {
26537
26537
  L.value = !0, d.user && (d.user.twoFactorEnabled = !0), r("two-factor-regenerate");
26538
26538
  }
26539
26539
  function U() {
@@ -26654,7 +26654,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26654
26654
  Ae(E.$slots, "enable-2fa", {}, () => [
26655
26655
  I(Cq, {
26656
26656
  enabled: k.value,
26657
- onEnabled: z,
26657
+ onEnabled: A,
26658
26658
  onDisabled: U
26659
26659
  }, null, 8, ["enabled"])
26660
26660
  ])
@@ -26814,7 +26814,7 @@ const oq = "http://www.w3.org/2000/svg", cq = (a, t, n, r = []) => [`<${t}`, ...
26814
26814
  return t.data.map((s, u) => {
26815
26815
  const m = i / d.value * 2 * Math.PI;
26816
26816
  i += s.value;
26817
- const p = i / d.value * 2 * Math.PI, f = 50, M = 60, b = 60, v = M + f * Math.cos(m - Math.PI / 2), L = b + f * Math.sin(m - Math.PI / 2), k = M + f * Math.cos(p - Math.PI / 2), z = b + f * Math.sin(p - Math.PI / 2), U = p - m > Math.PI ? 1 : 0, E = t.data.length === 1 ? `M ${M - f} ${b} a ${f} ${f} 0 1 0 ${f * 2} 0 a ${f} ${f} 0 1 0 ${-f * 2} 0` : `M ${M} ${b} L ${v} ${L} A ${f} ${f} 0 ${U} 1 ${k} ${z} Z`;
26817
+ const p = i / d.value * 2 * Math.PI, f = 50, M = 60, b = 60, v = M + f * Math.cos(m - Math.PI / 2), L = b + f * Math.sin(m - Math.PI / 2), k = M + f * Math.cos(p - Math.PI / 2), A = b + f * Math.sin(p - Math.PI / 2), U = p - m > Math.PI ? 1 : 0, E = t.data.length === 1 ? `M ${M - f} ${b} a ${f} ${f} 0 1 0 ${f * 2} 0 a ${f} ${f} 0 1 0 ${-f * 2} 0` : `M ${M} ${b} L ${v} ${L} A ${f} ${f} 0 ${U} 1 ${k} ${A} Z`;
26818
26818
  return {
26819
26819
  ...s,
26820
26820
  path: E,
@@ -27818,12 +27818,12 @@ const Oe = /* @__PURE__ */ ae({
27818
27818
  L([...r.value, K]), c.value = "";
27819
27819
  }
27820
27820
  }
27821
- function z(Z) {
27821
+ function A(Z) {
27822
27822
  const K = [...r.value];
27823
27823
  K.splice(Z, 1), L(K);
27824
27824
  }
27825
27825
  function U(Z) {
27826
- Z.key === "Enter" ? (Z.preventDefault(), q.value >= 0 && A.value[q.value] ? k(A.value[q.value]) : c.value.trim() !== "" && k(c.value)) : Z.key === "Backspace" && c.value === "" && r.value.length > 0 ? z(r.value.length - 1) : Z.key === "ArrowDown" ? (Z.preventDefault(), q.value = Math.min(q.value + 1, A.value.length - 1)) : Z.key === "ArrowUp" ? (Z.preventDefault(), q.value = Math.max(q.value - 1, -1)) : Z.key === "Escape" && (i.value = !1, s.value?.blur());
27826
+ Z.key === "Enter" ? (Z.preventDefault(), q.value >= 0 && z.value[q.value] ? k(z.value[q.value]) : c.value.trim() !== "" && k(c.value)) : Z.key === "Backspace" && c.value === "" && r.value.length > 0 ? A(r.value.length - 1) : Z.key === "ArrowDown" ? (Z.preventDefault(), q.value = Math.min(q.value + 1, z.value.length - 1)) : Z.key === "ArrowUp" ? (Z.preventDefault(), q.value = Math.max(q.value - 1, -1)) : Z.key === "Escape" && (i.value = !1, s.value?.blur());
27827
27827
  }
27828
27828
  function E(Z) {
27829
27829
  const K = Z.target.value;
@@ -27844,7 +27844,7 @@ const Oe = /* @__PURE__ */ ae({
27844
27844
  (C) => !K.has(C) && (Z === "" || C.toLowerCase().includes(Z))
27845
27845
  )
27846
27846
  })).filter((B) => B.items.length > 0) : [];
27847
- }), A = g(() => {
27847
+ }), z = g(() => {
27848
27848
  if (H.value)
27849
27849
  return j.value.flatMap((B) => B.items);
27850
27850
  const Z = c.value.trim().toLowerCase(), K = new Set(r.value);
@@ -27853,7 +27853,7 @@ const Oe = /* @__PURE__ */ ae({
27853
27853
  function R(Z) {
27854
27854
  return Z === q.value;
27855
27855
  }
27856
- we(c, () => {
27856
+ Ie(c, () => {
27857
27857
  q.value = -1;
27858
27858
  });
27859
27859
  function N() {
@@ -27867,8 +27867,8 @@ const Oe = /* @__PURE__ */ ae({
27867
27867
  i.value = !1, c.value.trim() !== "" && k(c.value);
27868
27868
  }, 120);
27869
27869
  }
27870
- return we(
27871
- () => i.value && A.value.length > 0,
27870
+ return Ie(
27871
+ () => i.value && z.value.length > 0,
27872
27872
  async (Z) => {
27873
27873
  Z ? (b(), await a1(), f(), requestAnimationFrame(() => f()), window.addEventListener("resize", f), window.addEventListener("scroll", f, !0)) : (window.removeEventListener("resize", f), window.removeEventListener("scroll", f, !0));
27874
27874
  }
@@ -27901,7 +27901,7 @@ const Oe = /* @__PURE__ */ ae({
27901
27901
  type: "button",
27902
27902
  class: "admin-tags__chip-remove",
27903
27903
  "aria-label": "Удалить",
27904
- onClick: pe((V) => z(C), ["stop"])
27904
+ onClick: pe((V) => A(C), ["stop"])
27905
27905
  }, [
27906
27906
  I(l(Q), {
27907
27907
  icon: l(He),
@@ -27923,7 +27923,7 @@ const Oe = /* @__PURE__ */ ae({
27923
27923
  onBlur: te
27924
27924
  }, null, 40, nz),
27925
27925
  (o(), F(eI, { to: "body" }, [
27926
- i.value && A.value.length > 0 ? (o(), h("div", {
27926
+ i.value && z.value.length > 0 ? (o(), h("div", {
27927
27927
  key: 0,
27928
27928
  ref_key: "dropdownRef",
27929
27929
  ref: m,
@@ -27943,15 +27943,15 @@ const Oe = /* @__PURE__ */ ae({
27943
27943
  "admin-tags__option",
27944
27944
  {
27945
27945
  "admin-tags__option--active": R(
27946
- A.value.indexOf(V)
27946
+ z.value.indexOf(V)
27947
27947
  )
27948
27948
  }
27949
27949
  ]),
27950
- "aria-selected": R(A.value.indexOf(V)),
27950
+ "aria-selected": R(z.value.indexOf(V)),
27951
27951
  onMousedown: pe((_) => G(V), ["prevent"]),
27952
- onMouseenter: (_) => q.value = A.value.indexOf(V)
27952
+ onMouseenter: (_) => q.value = z.value.indexOf(V)
27953
27953
  }, x(V), 43, cz))), 128))
27954
- ], 64))), 128)) : (o(!0), h(W, { key: 1 }, ee(A.value, (B, C) => (o(), h("button", {
27954
+ ], 64))), 128)) : (o(!0), h(W, { key: 1 }, ee(z.value, (B, C) => (o(), h("button", {
27955
27955
  key: B,
27956
27956
  type: "button",
27957
27957
  role: "option",
@@ -28127,7 +28127,7 @@ const Oe = /* @__PURE__ */ ae({
28127
28127
  C !== null && i.value.chain().setLink(C.trim() === "" ? null : C.trim()).run();
28128
28128
  }
28129
28129
  const b = S(null), v = S(null), L = S(null);
28130
- let k = null, z = [];
28130
+ let k = null, A = [];
28131
28131
  function U() {
28132
28132
  k?.dispatchEvent(new Event("input", { bubbles: !0 }));
28133
28133
  }
@@ -28156,54 +28156,54 @@ const Oe = /* @__PURE__ */ ae({
28156
28156
  const le = he.target?.closest("img");
28157
28157
  le && k?.contains(le) ? q(le) : H();
28158
28158
  };
28159
- k.addEventListener("click", C), z.push(() => k?.removeEventListener("click", C));
28159
+ k.addEventListener("click", C), A.push(() => k?.removeEventListener("click", C));
28160
28160
  const V = (he) => {
28161
28161
  const se = he.target;
28162
28162
  u.value && !u.value.contains(se) && H();
28163
28163
  };
28164
- document.addEventListener("click", V), z.push(() => document.removeEventListener("click", V));
28164
+ document.addEventListener("click", V), A.push(() => document.removeEventListener("click", V));
28165
28165
  const _ = () => E();
28166
- window.addEventListener("scroll", _, !0), window.addEventListener("resize", _), z.push(() => window.removeEventListener("scroll", _, !0)), z.push(() => window.removeEventListener("resize", _));
28166
+ window.addEventListener("scroll", _, !0), window.addEventListener("resize", _), A.push(() => window.removeEventListener("scroll", _, !0)), A.push(() => window.removeEventListener("resize", _));
28167
28167
  const $ = (he) => {
28168
28168
  const se = he.target;
28169
28169
  if (!se || !k?.contains(se) || se.tagName !== "IMG") return;
28170
28170
  q(se), he.dataTransfer?.setData("text/plain", "img"), he.dataTransfer && (he.dataTransfer.effectAllowed = "move");
28171
28171
  };
28172
- k.addEventListener("dragstart", $), z.push(() => k?.removeEventListener("dragstart", $));
28172
+ k.addEventListener("dragstart", $), A.push(() => k?.removeEventListener("dragstart", $));
28173
28173
  const ne = (he) => {
28174
28174
  if (!b.value) return;
28175
28175
  he.preventDefault(), he.dataTransfer && (he.dataTransfer.dropEffect = "move");
28176
- const se = A(he.clientX, he.clientY);
28176
+ const se = z(he.clientX, he.clientY);
28177
28177
  if (se && u.value) {
28178
- const le = se.getBoundingClientRect(), Ie = u.value.getBoundingClientRect(), _1 = (he.clientY < le.top + le.height / 2 ? le.top : le.bottom) - Ie.top + u.value.scrollTop;
28178
+ const le = se.getBoundingClientRect(), we = u.value.getBoundingClientRect(), _1 = (he.clientY < le.top + le.height / 2 ? le.top : le.bottom) - we.top + u.value.scrollTop;
28179
28179
  L.value = {
28180
- x: le.left - Ie.left + u.value.scrollLeft,
28180
+ x: le.left - we.left + u.value.scrollLeft,
28181
28181
  y: _1,
28182
28182
  w: le.width
28183
28183
  };
28184
28184
  }
28185
28185
  };
28186
- k.addEventListener("dragover", ne), z.push(() => k?.removeEventListener("dragover", ne));
28186
+ k.addEventListener("dragover", ne), A.push(() => k?.removeEventListener("dragover", ne));
28187
28187
  const me = (he) => {
28188
28188
  if (!b.value || !k) return;
28189
28189
  he.preventDefault(), L.value = null;
28190
- const se = A(he.clientX, he.clientY);
28190
+ const se = z(he.clientX, he.clientY);
28191
28191
  if (!se || se.contains(b.value))
28192
28192
  return;
28193
- const le = se.getBoundingClientRect(), Ie = he.clientY < le.top + le.height / 2, ze = b.value;
28194
- ze.remove(), Ie ? se.parentNode?.insertBefore(ze, se) : se.parentNode?.insertBefore(ze, se.nextSibling), E(), U();
28193
+ const le = se.getBoundingClientRect(), we = he.clientY < le.top + le.height / 2, ze = b.value;
28194
+ ze.remove(), we ? se.parentNode?.insertBefore(ze, se) : se.parentNode?.insertBefore(ze, se.nextSibling), E(), U();
28195
28195
  };
28196
- k.addEventListener("drop", me), z.push(() => k?.removeEventListener("drop", me));
28196
+ k.addEventListener("drop", me), A.push(() => k?.removeEventListener("drop", me));
28197
28197
  const ke = () => {
28198
28198
  L.value = null;
28199
28199
  };
28200
- k.addEventListener("dragend", ke), z.push(() => k?.removeEventListener("dragend", ke));
28200
+ k.addEventListener("dragend", ke), A.push(() => k?.removeEventListener("dragend", ke));
28201
28201
  const xe = new MutationObserver(() => {
28202
28202
  b.value && !k?.contains(b.value) ? H() : E();
28203
28203
  });
28204
- xe.observe(k, { childList: !0, subtree: !0, attributes: !0, attributeFilter: ["src", "style", "width", "height"] }), z.push(() => xe.disconnect());
28204
+ xe.observe(k, { childList: !0, subtree: !0, attributes: !0, attributeFilter: ["src", "style", "width", "height"] }), A.push(() => xe.disconnect());
28205
28205
  }
28206
- function A(B, C) {
28206
+ function z(B, C) {
28207
28207
  if (!k) return null;
28208
28208
  const V = b.value?.style.pointerEvents ?? "";
28209
28209
  b.value && (b.value.style.pointerEvents = "none");
@@ -28241,8 +28241,8 @@ const Oe = /* @__PURE__ */ ae({
28241
28241
  return B === "nw" && ($ = C.x - 5, ne = C.y - 5), B === "ne" && ($ = C.x + C.w - 5, ne = C.y - 5), B === "sw" && ($ = C.x - 5, ne = C.y + C.h - 5), B === "se" && ($ = C.x + C.w - 5, ne = C.y + C.h - 5), { left: $ + "px", top: ne + "px", width: "10px", height: "10px" };
28242
28242
  }
28243
28243
  return f9(() => {
28244
- z.forEach((B) => B()), z = [], H();
28245
- }), we(r, () => {
28244
+ A.forEach((B) => B()), A = [], H();
28245
+ }), Ie(r, () => {
28246
28246
  b.value && k && !k.contains(b.value) && H();
28247
28247
  }), (B, C) => (o(), h("div", {
28248
28248
  class: ve(["admin-field", { "admin-field--invalid": d.value !== void 0 }])
@@ -28458,14 +28458,14 @@ const Oe = /* @__PURE__ */ ae({
28458
28458
  }
28459
28459
  function L(B) {
28460
28460
  const C = B.target.files?.[0];
28461
- C && z(C), B.target.value = "";
28461
+ C && A(C), B.target.value = "";
28462
28462
  }
28463
28463
  function k(B) {
28464
28464
  B.preventDefault(), i.value = !1;
28465
28465
  const C = B.dataTransfer?.files?.[0];
28466
- C && z(C);
28466
+ C && A(C);
28467
28467
  }
28468
- function z(B) {
28468
+ function A(B) {
28469
28469
  if (t.maxSize !== null && B.size > t.maxSize * 1024) {
28470
28470
  ue.error(`Файл больше ${t.maxSize} KB.`);
28471
28471
  return;
@@ -28511,9 +28511,9 @@ const Oe = /* @__PURE__ */ ae({
28511
28511
  cy: M.value.y,
28512
28512
  cw: M.value.w,
28513
28513
  ch: M.value.h
28514
- }, window.addEventListener("mousemove", A), window.addEventListener("mouseup", R), C.preventDefault();
28514
+ }, window.addEventListener("mousemove", z), window.addEventListener("mouseup", R), C.preventDefault();
28515
28515
  }
28516
- function A(B) {
28516
+ function z(B) {
28517
28517
  if (q.value === null) return;
28518
28518
  const C = B.clientX - H.value.mx, V = B.clientY - H.value.my, _ = H.value, $ = f.value, ne = (t.minCropWidth ?? 32) * p.value, me = (t.minCropHeight ?? 32) * p.value;
28519
28519
  if (q.value === "move") {
@@ -28523,15 +28523,15 @@ const Oe = /* @__PURE__ */ ae({
28523
28523
  }
28524
28524
  let ke = _.cx, xe = _.cy, he = _.cx + _.cw, se = _.cy + _.ch;
28525
28525
  q.value === "nw" && (ke = _.cx + C, xe = _.cy + V), q.value === "ne" && (he = _.cx + _.cw + C, xe = _.cy + V), q.value === "sw" && (ke = _.cx + C, se = _.cy + _.ch + V), q.value === "se" && (he = _.cx + _.cw + C, se = _.cy + _.ch + V), ke = Math.max(0, Math.min(ke, he - ne)), xe = Math.max(0, Math.min(xe, se - me)), he = Math.min($.w, Math.max(he, ke + ne)), se = Math.min($.h, Math.max(se, xe + me));
28526
- let le = he - ke, Ie = se - xe;
28526
+ let le = he - ke, we = se - xe;
28527
28527
  if (b.value !== null) {
28528
28528
  const ze = b.value;
28529
- Math.abs(le - _.cw) >= Math.abs(Ie - _.ch) ? Ie = le / ze : le = Ie * ze, q.value === "nw" && (ke = he - le, xe = se - Ie), q.value === "ne" && (xe = se - Ie), q.value === "sw" && (ke = he - le), ke < 0 && (le += ke, ke = 0, Ie = le / ze, xe = q.value === "nw" || q.value === "ne" ? se - Ie : xe), xe < 0 && (Ie += xe, xe = 0, le = Ie * ze, ke = q.value === "nw" || q.value === "sw" ? he - le : ke), ke + le > $.w && (le = $.w - ke, Ie = le / ze), xe + Ie > $.h && (Ie = $.h - xe, le = Ie * ze);
28529
+ Math.abs(le - _.cw) >= Math.abs(we - _.ch) ? we = le / ze : le = we * ze, q.value === "nw" && (ke = he - le, xe = se - we), q.value === "ne" && (xe = se - we), q.value === "sw" && (ke = he - le), ke < 0 && (le += ke, ke = 0, we = le / ze, xe = q.value === "nw" || q.value === "ne" ? se - we : xe), xe < 0 && (we += xe, xe = 0, le = we * ze, ke = q.value === "nw" || q.value === "sw" ? he - le : ke), ke + le > $.w && (le = $.w - ke, we = le / ze), xe + we > $.h && (we = $.h - xe, le = we * ze);
28530
28530
  }
28531
- M.value = { x: ke, y: xe, w: le, h: Ie };
28531
+ M.value = { x: ke, y: xe, w: le, h: we };
28532
28532
  }
28533
28533
  function R() {
28534
- q.value = null, window.removeEventListener("mousemove", A), window.removeEventListener("mouseup", R);
28534
+ q.value = null, window.removeEventListener("mousemove", z), window.removeEventListener("mouseup", R);
28535
28535
  }
28536
28536
  async function N() {
28537
28537
  if (!u.value) return;
@@ -28554,10 +28554,10 @@ const Oe = /* @__PURE__ */ ae({
28554
28554
  try {
28555
28555
  const le = new FormData();
28556
28556
  le.append("file", se, "crop.png");
28557
- const Ie = await ge().post("/uploads/image", le, {
28557
+ const we = await ge().post("/uploads/image", le, {
28558
28558
  headers: { "Content-Type": "multipart/form-data" }
28559
28559
  });
28560
- n.setField(t.name, Ie), G();
28560
+ n.setField(t.name, we), G();
28561
28561
  } catch (le) {
28562
28562
  typeof console < "u" && console.error("[admin] upload failed:", le), ue.error("Не удалось загрузить.");
28563
28563
  } finally {
@@ -28740,7 +28740,7 @@ const Oe = /* @__PURE__ */ ae({
28740
28740
  }));
28741
28741
  }
28742
28742
  const d = S(r());
28743
- we(
28743
+ Ie(
28744
28744
  () => n.getField(t.name),
28745
28745
  () => {
28746
28746
  const p = r(), f = JSON.stringify(Object.fromEntries(d.value.map((M) => [M.key, M.value])));
@@ -28846,7 +28846,7 @@ const Oe = /* @__PURE__ */ ae({
28846
28846
  emits: ["update:modelValue"],
28847
28847
  setup(a, { emit: t }) {
28848
28848
  const n = a, r = t, d = PI({ ...n.modelValue });
28849
- return L9(d), we(
28849
+ return L9(d), Ie(
28850
28850
  d,
28851
28851
  () => r("update:modelValue", { ...d }),
28852
28852
  { deep: !0 }
@@ -28892,7 +28892,7 @@ const Oe = /* @__PURE__ */ ae({
28892
28892
  return Array.isArray(b) ? b.map((v) => ({ ...v })) : [];
28893
28893
  }
28894
28894
  const d = S(r());
28895
- we(
28895
+ Ie(
28896
28896
  () => n.getField(t.name),
28897
28897
  (b) => {
28898
28898
  JSON.stringify(b ?? []) !== JSON.stringify(d.value) && (d.value = r());
@@ -28945,7 +28945,7 @@ const Oe = /* @__PURE__ */ ae({
28945
28945
  size: "sm",
28946
28946
  disabled: k === 0,
28947
28947
  "aria-label": "Выше",
28948
- onClick: (z) => f(k, -1)
28948
+ onClick: (A) => f(k, -1)
28949
28949
  }, {
28950
28950
  default: w(() => [
28951
28951
  I(l(Q), {
@@ -28961,7 +28961,7 @@ const Oe = /* @__PURE__ */ ae({
28961
28961
  size: "sm",
28962
28962
  disabled: k === d.value.length - 1,
28963
28963
  "aria-label": "Ниже",
28964
- onClick: (z) => f(k, 1)
28964
+ onClick: (A) => f(k, 1)
28965
28965
  }, {
28966
28966
  default: w(() => [
28967
28967
  I(l(Q), {
@@ -28976,7 +28976,7 @@ const Oe = /* @__PURE__ */ ae({
28976
28976
  variant: "ghost",
28977
28977
  size: "sm",
28978
28978
  "aria-label": "Удалить элемент",
28979
- onClick: (z) => p(k)
28979
+ onClick: (A) => p(k)
28980
28980
  }, {
28981
28981
  default: w(() => [
28982
28982
  I(l(Q), {
@@ -28991,7 +28991,7 @@ const Oe = /* @__PURE__ */ ae({
28991
28991
  I(sw, {
28992
28992
  fields: a.fields,
28993
28993
  "model-value": L,
28994
- "onUpdate:modelValue": (z) => i(k, z)
28994
+ "onUpdate:modelValue": (A) => i(k, A)
28995
28995
  }, null, 8, ["fields", "model-value", "onUpdate:modelValue"])
28996
28996
  ]),
28997
28997
  _: 2
@@ -29051,7 +29051,7 @@ const Oe = /* @__PURE__ */ ae({
29051
29051
  return Array.isArray(v) ? v.map((L) => ({ type: L.type, data: { ...L.data ?? {} } })) : [];
29052
29052
  }
29053
29053
  const d = S(r());
29054
- we(
29054
+ Ie(
29055
29055
  () => n.getField(t.name),
29056
29056
  (v) => {
29057
29057
  JSON.stringify(v ?? []) !== JSON.stringify(d.value) && (d.value = r());
@@ -29072,8 +29072,8 @@ const Oe = /* @__PURE__ */ ae({
29072
29072
  function p(v, L) {
29073
29073
  const k = v + L;
29074
29074
  if (k < 0 || k >= d.value.length) return;
29075
- const z = [...d.value];
29076
- [z[v], z[k]] = [z[k], z[v]], d.value = z, c();
29075
+ const A = [...d.value];
29076
+ [A[v], A[k]] = [A[k], A[v]], d.value = A, c();
29077
29077
  }
29078
29078
  function f(v, L) {
29079
29079
  d.value[v] = { ...d.value[v], data: L }, c();
@@ -29089,8 +29089,8 @@ const Oe = /* @__PURE__ */ ae({
29089
29089
  D(x(a.label), 1),
29090
29090
  a.required ? (o(), h("span", qH, "*")) : P("", !0)
29091
29091
  ])) : P("", !0),
29092
- (o(!0), h(W, null, ee(d.value, (k, z) => (o(), F(l(Me), {
29093
- key: z,
29092
+ (o(!0), h(W, null, ee(d.value, (k, A) => (o(), F(l(Me), {
29093
+ key: A,
29094
29094
  padding: "md",
29095
29095
  class: "admin-builder__block"
29096
29096
  }, {
@@ -29102,9 +29102,9 @@ const Oe = /* @__PURE__ */ ae({
29102
29102
  key: 0,
29103
29103
  variant: "ghost",
29104
29104
  size: "sm",
29105
- disabled: z === 0,
29105
+ disabled: A === 0,
29106
29106
  "aria-label": "Выше",
29107
- onClick: (U) => p(z, -1)
29107
+ onClick: (U) => p(A, -1)
29108
29108
  }, {
29109
29109
  default: w(() => [
29110
29110
  I(l(Q), {
@@ -29118,9 +29118,9 @@ const Oe = /* @__PURE__ */ ae({
29118
29118
  key: 1,
29119
29119
  variant: "ghost",
29120
29120
  size: "sm",
29121
- disabled: z === d.value.length - 1,
29121
+ disabled: A === d.value.length - 1,
29122
29122
  "aria-label": "Ниже",
29123
- onClick: (U) => p(z, 1)
29123
+ onClick: (U) => p(A, 1)
29124
29124
  }, {
29125
29125
  default: w(() => [
29126
29126
  I(l(Q), {
@@ -29134,7 +29134,7 @@ const Oe = /* @__PURE__ */ ae({
29134
29134
  variant: "ghost",
29135
29135
  size: "sm",
29136
29136
  "aria-label": "Удалить блок",
29137
- onClick: (U) => m(z)
29137
+ onClick: (U) => m(A)
29138
29138
  }, {
29139
29139
  default: w(() => [
29140
29140
  I(l(Q), {
@@ -29150,7 +29150,7 @@ const Oe = /* @__PURE__ */ ae({
29150
29150
  key: 0,
29151
29151
  fields: M(k.type).fields,
29152
29152
  "model-value": k.data,
29153
- "onUpdate:modelValue": (U) => f(z, U)
29153
+ "onUpdate:modelValue": (U) => f(A, U)
29154
29154
  }, null, 8, ["fields", "model-value", "onUpdate:modelValue"])) : (o(), h("p", VH, "Неизвестный тип блока: " + x(k.type), 1))
29155
29155
  ]),
29156
29156
  _: 2
@@ -29177,7 +29177,7 @@ const Oe = /* @__PURE__ */ ae({
29177
29177
  default: w(() => [
29178
29178
  (o(!0), h(W, null, ee(i.value, (k) => (o(), F(l(De), {
29179
29179
  key: k.type,
29180
- onClick: (z) => u(k.type)
29180
+ onClick: (A) => u(k.type)
29181
29181
  }, {
29182
29182
  default: w(() => [
29183
29183
  D(x(k.label), 1)
@@ -29265,27 +29265,32 @@ const Oe = /* @__PURE__ */ ae({
29265
29265
  },
29266
29266
  setup(a) {
29267
29267
  const t = a, n = Pe(), r = Do(), d = g(() => n.getField(t.name) ?? ""), c = g(() => n.errors[t.name]?.[0]), i = typeof globalThis.crypto?.getRandomValues == "function";
29268
- function s(p, f) {
29269
- const M = f.length, b = Math.floor(256 / M) * M;
29270
- let v = "";
29271
- const L = new Uint8Array(p * 2);
29272
- for (; v.length < p; ) {
29273
- globalThis.crypto.getRandomValues(L);
29274
- for (const k of L)
29275
- if (k < b && (v += f[k % M], v.length === p))
29268
+ function s(f, M) {
29269
+ const b = M.length, v = Math.floor(256 / b) * b;
29270
+ let L = "";
29271
+ const k = new Uint8Array(f * 2);
29272
+ for (; L.length < f; ) {
29273
+ globalThis.crypto.getRandomValues(k);
29274
+ for (const A of k)
29275
+ if (A < v && (L += M[A % b], L.length === f))
29276
29276
  break;
29277
29277
  }
29278
- return v;
29278
+ return L;
29279
29279
  }
29280
29280
  function u() {
29281
29281
  i && n.setField(t.name, s(t.length, t.charset));
29282
29282
  }
29283
- function m(p) {
29284
- n.setField(t.name, p);
29283
+ const m = S(!1);
29284
+ function p(f) {
29285
+ m.value = !0, n.setField(t.name, f);
29285
29286
  }
29286
- return Ee(() => {
29287
- t.autogenerate && !t.disabled && d.value === "" && u();
29288
- }), (p, f) => (o(), h("div", {
29287
+ return Ie(
29288
+ d,
29289
+ (f) => {
29290
+ t.autogenerate && !t.disabled && !m.value && f === "" && u();
29291
+ },
29292
+ { immediate: !0 }
29293
+ ), (f, M) => (o(), h("div", {
29289
29294
  class: ve(["uid-form-field admin-generated", { "uid-form-field--error": !!c.value }])
29290
29295
  }, [
29291
29296
  a.label ? (o(), h("label", UH, [
@@ -29301,7 +29306,7 @@ const Oe = /* @__PURE__ */ ae({
29301
29306
  disabled: a.disabled,
29302
29307
  name: a.name,
29303
29308
  class: "admin-generated__input",
29304
- "onUpdate:modelValue": m
29309
+ "onUpdate:modelValue": p
29305
29310
  }, null, 8, ["model-value", "error", "placeholder", "required", "disabled", "name"]),
29306
29311
  i ? (o(), F(l(oe), {
29307
29312
  key: 0,
@@ -29467,7 +29472,7 @@ const Oe = /* @__PURE__ */ ae({
29467
29472
  return B.editable ?? null;
29468
29473
  return null;
29469
29474
  }
29470
- async function z() {
29475
+ async function A() {
29471
29476
  if (p.value === null) {
29472
29477
  c.value = [];
29473
29478
  return;
@@ -29486,7 +29491,7 @@ const Oe = /* @__PURE__ */ ae({
29486
29491
  i.value = !1;
29487
29492
  }
29488
29493
  }
29489
- Ee(z), we(p, z);
29494
+ Ne(A), Ie(p, A);
29490
29495
  function U(K) {
29491
29496
  return K.id ?? "";
29492
29497
  }
@@ -29509,13 +29514,13 @@ const Oe = /* @__PURE__ */ ae({
29509
29514
  ue.error("Не удалось удалить строку.");
29510
29515
  }
29511
29516
  }
29512
- async function A() {
29517
+ async function z() {
29513
29518
  if (u.value.size === 0 || !confirm(`Удалить ${u.value.size} строк?`)) return;
29514
29519
  const K = [...u.value];
29515
29520
  try {
29516
- await Promise.all(K.map((B) => ge().post(`/${t.resource}/delete`, { id: B }))), u.value = /* @__PURE__ */ new Set(), await z();
29521
+ await Promise.all(K.map((B) => ge().post(`/${t.resource}/delete`, { id: B }))), u.value = /* @__PURE__ */ new Set(), await A();
29517
29522
  } catch {
29518
- ue.error("Не удалось удалить часть строк."), await z();
29523
+ ue.error("Не удалось удалить часть строк."), await A();
29519
29524
  }
29520
29525
  }
29521
29526
  function R() {
@@ -29529,7 +29534,7 @@ const Oe = /* @__PURE__ */ ae({
29529
29534
  async function G() {
29530
29535
  if (m.value !== null)
29531
29536
  try {
29532
- await ge().post(`/${t.resource}/create`, m.value), m.value = null, await z();
29537
+ await ge().post(`/${t.resource}/create`, m.value), m.value = null, await A();
29533
29538
  } catch {
29534
29539
  ue.error("Не удалось создать запись.");
29535
29540
  }
@@ -29560,7 +29565,7 @@ const Oe = /* @__PURE__ */ ae({
29560
29565
  key: 1,
29561
29566
  variant: "danger",
29562
29567
  size: "sm",
29563
- onClick: A
29568
+ onClick: z
29564
29569
  }, {
29565
29570
  default: w(() => [
29566
29571
  I(l(Q), { icon: l($e) }, null, 8, ["icon"]),
@@ -29572,7 +29577,7 @@ const Oe = /* @__PURE__ */ ae({
29572
29577
  i.value && c.value.length === 0 ? (o(), F(l(Qn), { key: 0 })) : s.value ? (o(), F(l(nI), {
29573
29578
  key: 1,
29574
29579
  message: s.value.message,
29575
- onRetry: z
29580
+ onRetry: A
29576
29581
  }, null, 8, ["message"])) : !i.value && c.value.length === 0 && m.value === null ? (o(), F(l(oI), {
29577
29582
  key: 2,
29578
29583
  title: "Нет данных",
@@ -30124,7 +30129,7 @@ function $P(a, t = {}) {
30124
30129
  p.bootResolved = !0;
30125
30130
  }
30126
30131
  };
30127
- f.isAuthenticated ? b() : p.bootResolved = !0, we(
30132
+ f.isAuthenticated ? b() : p.bootResolved = !0, Ie(
30128
30133
  () => f.user,
30129
30134
  (v, L) => {
30130
30135
  v && !L && (p.bootResolved = !1, b());
@@ -30218,7 +30223,7 @@ const DV = { class: "admin-notifs__hd" }, BV = { class: "admin-notifs__title" },
30218
30223
  function c(L) {
30219
30224
  r("update:open", L);
30220
30225
  }
30221
- we(
30226
+ Ie(
30222
30227
  () => n.open,
30223
30228
  async (L) => {
30224
30229
  L && await d.load(d.lastFilter ?? "all", 1).catch(() => {
@@ -30255,7 +30260,7 @@ const DV = { class: "admin-notifs__hd" }, BV = { class: "admin-notifs__title" },
30255
30260
  }
30256
30261
  function v(L) {
30257
30262
  if (!L) return "";
30258
- const k = new Date(L), z = Math.max(0, Date.now() - k.getTime()), U = Math.floor(z / 6e4);
30263
+ const k = new Date(L), A = Math.max(0, Date.now() - k.getTime()), U = Math.floor(A / 6e4);
30259
30264
  if (U < 1) return "только что";
30260
30265
  if (U < 60) return `${U} мин назад`;
30261
30266
  const E = Math.floor(U / 60);
@@ -30318,9 +30323,9 @@ const DV = { class: "admin-notifs__hd" }, BV = { class: "admin-notifs__title" },
30318
30323
  })
30319
30324
  ]),
30320
30325
  default: w(() => [
30321
- (o(), h(W, null, ee(["all", "unread", "read"], (z) => I(l(RI), {
30322
- key: z,
30323
- value: z
30326
+ (o(), h(W, null, ee(["all", "unread", "read"], (A) => I(l(RI), {
30327
+ key: A,
30328
+ value: A
30324
30329
  }, {
30325
30330
  default: w(() => [
30326
30331
  y("ul", $V, [
@@ -30431,7 +30436,7 @@ const DV = { class: "admin-notifs__hd" }, BV = { class: "admin-notifs__title" },
30431
30436
  default:
30432
30437
  return !1;
30433
30438
  }
30434
- }), z = g(() => [
30439
+ }), A = g(() => [
30435
30440
  { value: "", label: "Не импортировать" },
30436
30441
  ...n.fieldOptions
30437
30442
  ]);
@@ -30502,7 +30507,7 @@ const DV = { class: "admin-notifs__hd" }, BV = { class: "admin-notifs__title" },
30502
30507
  q[4] || (q[4] = y("span", { class: "admin-import-wizard__map-arrow" }, "→", -1)),
30503
30508
  I(l(M9), {
30504
30509
  "model-value": p.value[H.key] ?? "",
30505
- options: z.value,
30510
+ options: A.value,
30506
30511
  placeholder: "Не импортировать",
30507
30512
  "onUpdate:modelValue": (j) => f(H.key, j)
30508
30513
  }, null, 8, ["model-value", "options", "onUpdate:modelValue"])
@@ -30727,7 +30732,7 @@ export {
30727
30732
  Kx as AdminShell,
30728
30733
  Fx as AdminSidebar,
30729
30734
  fx as AdminTopBar,
30730
- Ze as ApiError,
30735
+ Ee as ApiError,
30731
30736
  ZI as BRAND_KEY,
30732
30737
  mV as BadgeEntry,
30733
30738
  rw as BarChartWidget,