elcrm 0.8.39 → 0.8.41

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.
@@ -19,7 +19,7 @@ export declare function useModule(fn?: string | ((name: string) => void)): strin
19
19
  export declare function setModule(module: string, reload?: boolean): void;
20
20
  export declare function getModule(): any;
21
21
  export declare function isModule(module: string): boolean;
22
- export declare function useTabs(fn?: string | ((name: string) => void)): (string | boolean)[] | undefined;
22
+ export declare function useTabs(fn?: string | ((name: string) => void)): string[] | undefined;
23
23
  export declare function setTabs(tabs: string, reload?: boolean): void;
24
24
  export declare function getTabs(): any;
25
25
  export declare function isTabs(tab: string): boolean;
package/dist/index.es.js CHANGED
@@ -5,7 +5,7 @@ import x, { createElement as Ea } from "react";
5
5
  let wt = {};
6
6
  const Na = (e) => {
7
7
  wt = e;
8
- }, Ra = (e) => wt.enCode(e), Ta = (e) => wt.deCode(e), F = { enCode: Ra, deCode: Ta, New: Na }, b = {}, V = {}, be = {}, mn = {}, ce = {};
8
+ }, Ra = (e) => wt.enCode(e), Ta = (e) => wt.deCode(e), F = { enCode: Ra, deCode: Ta, New: Na }, b = {}, V = {}, we = {}, mn = {}, ce = {};
9
9
  let St = "M06";
10
10
  function Ia(e) {
11
11
  St = e;
@@ -100,10 +100,8 @@ function Ka(e) {
100
100
  }
101
101
  function Ua(e) {
102
102
  if (typeof e != "function") {
103
- const [t, a] = x.useState(e || Je()), [r, s] = x.useState(!1);
104
- return x.useEffect(() => {
105
- s(!0);
106
- }, []), V.tabs = a, [t, r];
103
+ const [t, a] = x.useState(e || Je());
104
+ return V.tabs = a, [t];
107
105
  } else
108
106
  V.tabs = e;
109
107
  }
@@ -145,10 +143,10 @@ function Qa(e, t, a) {
145
143
  b.module = e, b.id = a, b.tab = t, sessionStorage.setItem("f", F.enCode(b)), V.module(e), V.tabs(t);
146
144
  }
147
145
  function er(e) {
148
- be.data = e[0], delete be.data.id, document.body.dataset.theme = be.data.s15, localStorage.setItem("s", F.enCode(be.data));
146
+ we.data = e[0], delete we.data.id, document.body.dataset.theme = we.data.s15, localStorage.setItem("s", F.enCode(we.data));
149
147
  }
150
148
  function tr(e, t) {
151
- be.data[e] = t, localStorage.setItem("s", F.enCode(be.data));
149
+ we.data[e] = t, localStorage.setItem("s", F.enCode(we.data));
152
150
  }
153
151
  function nr(e) {
154
152
  let t = localStorage.getItem("s");
@@ -201,7 +199,7 @@ function Oe(e) {
201
199
  function sr(e, t) {
202
200
  ce.data = { ...ce.data, [e]: t }, localStorage.setItem("q", F.enCode(ce.data));
203
201
  }
204
- function ke(e, t) {
202
+ function je(e, t) {
205
203
  if (!ce.data) {
206
204
  let a = localStorage.getItem("q");
207
205
  a && (ce.data = F.deCode(a));
@@ -290,7 +288,7 @@ const ie = {
290
288
  getCompany: kn,
291
289
  setSelect: Oe,
292
290
  addSelect: sr,
293
- getSelect: ke,
291
+ getSelect: je,
294
292
  setApi: ir,
295
293
  getApi: or,
296
294
  setPayment: lr,
@@ -325,18 +323,18 @@ function bn(e) {
325
323
  t && (window.URL || window.webkitURL).revokeObjectURL(t);
326
324
  }
327
325
  }
328
- const me = {};
326
+ const he = {};
329
327
  function pr(e) {
330
- return e && (me.s = e), me.s;
328
+ return e && (he.s = e), he.s;
331
329
  }
332
330
  function gr(e) {
333
- return e && (me.a = e), me.a;
331
+ return e && (he.a = e), he.a;
334
332
  }
335
333
  function vr(e) {
336
- return e && (me.c = e), me.c;
334
+ return e && (he.c = e), he.c;
337
335
  }
338
336
  function Cr(e) {
339
- return e && (me.h = e), me.h;
337
+ return e && (he.h = e), he.h;
340
338
  }
341
339
  const Et = { version: { Api: gr, Server: pr, Client: vr }, Host: Cr };
342
340
  let kr = "api", jr = "elcrm", yr = "online";
@@ -692,8 +690,8 @@ function Ir() {
692
690
  } finally {
693
691
  rt = !1, nt.current = P, Qn(), Error.prepareStackTrace = B;
694
692
  }
695
- var ye = c ? c.displayName || c.name : "", pe = ye ? We(ye) : "";
696
- return typeof c == "function" && Ke.set(c, pe), pe;
693
+ var be = c ? c.displayName || c.name : "", ge = be ? We(be) : "";
694
+ return typeof c == "function" && Ke.set(c, ge), ge;
697
695
  }
698
696
  function ta(c, p, k) {
699
697
  return At(c, !1);
@@ -881,7 +879,7 @@ function Ir() {
881
879
  }
882
880
  }
883
881
  var ot = j.ReactCurrentOwner, Vt = j.ReactDebugCurrentFrame;
884
- function je(c) {
882
+ function ye(c) {
885
883
  if (c) {
886
884
  var p = c._owner, k = Ue(c.type, c._source, p ? p.type : null);
887
885
  Vt.setExtraStackFrame(k);
@@ -931,7 +929,7 @@ Check the top-level render call using <` + k + ">.");
931
929
  return;
932
930
  Ht[k] = !0;
933
931
  var T = "";
934
- c && c._owner && c._owner !== ot.current && (T = " It was passed a child from " + $(c._owner.type) + "."), je(c), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', k, T), je(null);
932
+ c && c._owner && c._owner !== ot.current && (T = " It was passed a child from " + $(c._owner.type) + "."), ye(c), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', k, T), ye(null);
935
933
  }
936
934
  }
937
935
  function Jt(c, p) {
@@ -983,11 +981,11 @@ Check the top-level render call using <` + k + ">.");
983
981
  for (var p = Object.keys(c.props), k = 0; k < p.length; k++) {
984
982
  var T = p[k];
985
983
  if (T !== "children" && T !== "key") {
986
- je(c), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", T), je(null);
984
+ ye(c), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", T), ye(null);
987
985
  break;
988
986
  }
989
987
  }
990
- c.ref !== null && (je(c), S("Invalid attribute `ref` supplied to `React.Fragment`."), je(null));
988
+ c.ref !== null && (ye(c), S("Invalid attribute `ref` supplied to `React.Fragment`."), ye(null));
991
989
  }
992
990
  }
993
991
  var Xt = {};
@@ -1010,8 +1008,8 @@ Check the top-level render call using <` + k + ">.");
1010
1008
  if (ne !== void 0)
1011
1009
  if (T)
1012
1010
  if (st(ne)) {
1013
- for (var ye = 0; ye < ne.length; ye++)
1014
- Jt(ne[ye], c);
1011
+ for (var be = 0; be < ne.length; be++)
1012
+ Jt(ne[be], c);
1015
1013
  Object.freeze && Object.freeze(ne);
1016
1014
  } else
1017
1015
  S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
@@ -1019,17 +1017,17 @@ Check the top-level render call using <` + k + ">.");
1019
1017
  Jt(ne, c);
1020
1018
  }
1021
1019
  if (Te.call(p, "key")) {
1022
- var pe = $(c), Q = Object.keys(p).filter(function(ba) {
1020
+ var ge = $(c), Q = Object.keys(p).filter(function(ba) {
1023
1021
  return ba !== "key";
1024
1022
  }), dt = Q.length > 0 ? "{key: someKey, " + Q.join(": ..., ") + ": ...}" : "{key: someKey}";
1025
- if (!Xt[pe + dt]) {
1023
+ if (!Xt[ge + dt]) {
1026
1024
  var ya = Q.length > 0 ? "{" + Q.join(": ..., ") + ": ...}" : "{}";
1027
1025
  S(`A props object containing a "key" prop is being spread into JSX:
1028
1026
  let props = %s;
1029
1027
  <%s {...props} />
1030
1028
  React keys must be passed directly to JSX without using spread:
1031
1029
  let props = %s;
1032
- <%s key={someKey} {...props} />`, dt, pe, ya, pe), Xt[pe + dt] = !0;
1030
+ <%s key={someKey} {...props} />`, dt, ge, ya, ge), Xt[ge + dt] = !0;
1033
1031
  }
1034
1032
  }
1035
1033
  return c === r ? ga(U) : pa(U), U;
@@ -1056,12 +1054,12 @@ const Dr = "_notice_9i5tr_2", Mr = "_error_9i5tr_9", Fr = "_success_9i5tr_12", L
1056
1054
  "show-notice": "_show-notice_9i5tr_1",
1057
1055
  "hide-notice": "_hide-notice_9i5tr_1"
1058
1056
  };
1059
- let he = {};
1057
+ let xe = {};
1060
1058
  function Pr() {
1061
1059
  let [e, t] = x.useState([]);
1062
- return he.set = (a) => {
1060
+ return xe.set = (a) => {
1063
1061
  t([...e, a]);
1064
- }, he.del = (a) => {
1062
+ }, xe.del = (a) => {
1065
1063
  t(e.filter((r) => r.key !== a));
1066
1064
  }, e.length === 0 ? "" : /* @__PURE__ */ n.jsx("ul", { className: Br.notice, children: e.map((a) => a.item) });
1067
1065
  }
@@ -1071,25 +1069,25 @@ function Ae({ data: e }) {
1071
1069
  setTimeout(function() {
1072
1070
  a("hide");
1073
1071
  }, 1800), setTimeout(function() {
1074
- he.del(e.key);
1072
+ xe.del(e.key);
1075
1073
  }, 2500);
1076
1074
  }, [e.key]);
1077
1075
  let r, s;
1078
1076
  switch (e.type) {
1079
1077
  case "error":
1080
- r = /* @__PURE__ */ n.jsx(ge.error, {}), s = "Ошибка:";
1078
+ r = /* @__PURE__ */ n.jsx(ve.error, {}), s = "Ошибка:";
1081
1079
  break;
1082
1080
  case "success":
1083
- r = /* @__PURE__ */ n.jsx(ge.success, {}), s = "Информация:";
1081
+ r = /* @__PURE__ */ n.jsx(ve.success, {}), s = "Информация:";
1084
1082
  break;
1085
1083
  case "copy":
1086
- r = /* @__PURE__ */ n.jsx(ge.success, {}), s = "Копирование:";
1084
+ r = /* @__PURE__ */ n.jsx(ve.success, {}), s = "Копирование:";
1087
1085
  break;
1088
1086
  case "remark":
1089
- r = /* @__PURE__ */ n.jsx(ge.success, {}), s = "Подсказка:";
1087
+ r = /* @__PURE__ */ n.jsx(ve.success, {}), s = "Подсказка:";
1090
1088
  break;
1091
1089
  default:
1092
- r = /* @__PURE__ */ n.jsx(ge.success, {}), s = "Предупреждение:";
1090
+ r = /* @__PURE__ */ n.jsx(ve.success, {}), s = "Предупреждение:";
1093
1091
  break;
1094
1092
  }
1095
1093
  return /* @__PURE__ */ n.jsxs("li", { className: "item " + e.type, "data-status": t, children: [
@@ -1100,26 +1098,26 @@ function Ae({ data: e }) {
1100
1098
  }
1101
1099
  function Or(e) {
1102
1100
  let t = Date.now(), a = { key: t, ...e };
1103
- he.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1101
+ xe.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1104
1102
  }
1105
1103
  function Ar(e) {
1106
1104
  let t = Date.now(), a = { key: t, text: e, type: "error" };
1107
- he.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1105
+ xe.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1108
1106
  }
1109
1107
  function Zr(e) {
1110
1108
  let t = Date.now(), a = { key: t, text: e, type: "success" };
1111
- he.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1109
+ xe.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1112
1110
  }
1113
1111
  function zr(e) {
1114
1112
  let t = Date.now(), a = { key: t, text: e, type: "remark" };
1115
- he.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1113
+ xe.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1116
1114
  }
1117
1115
  function Gr(e) {
1118
1116
  let t = Date.now(), a = { key: t, text: e, type: "copy" };
1119
- he.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1117
+ xe.set({ item: /* @__PURE__ */ n.jsx(Ae, { data: a }, t), key: t });
1120
1118
  }
1121
- const ge = {};
1122
- ge.error = () => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 24 24", fill: "none", children: [
1119
+ const ve = {};
1120
+ ve.error = () => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 24 24", fill: "none", children: [
1123
1121
  /* @__PURE__ */ n.jsx(
1124
1122
  "path",
1125
1123
  {
@@ -1135,7 +1133,7 @@ ge.error = () => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 24 24", fill: "no
1135
1133
  }
1136
1134
  )
1137
1135
  ] });
1138
- ge.success = () => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 24 24", fill: "none", children: [
1136
+ ve.success = () => /* @__PURE__ */ n.jsxs("svg", { viewBox: "0 0 24 24", fill: "none", children: [
1139
1137
  /* @__PURE__ */ n.jsx(
1140
1138
  "path",
1141
1139
  {
@@ -1484,7 +1482,7 @@ function us(e) {
1484
1482
  e.data.forEach((s) => {
1485
1483
  t[s.id] = { s: s.v, n: s.a }, a[s.id] = s;
1486
1484
  });
1487
- let r = { ...ke(), 901: t };
1485
+ let r = { ...je(), 901: t };
1488
1486
  Cn(a), Oe(r);
1489
1487
  }
1490
1488
  function fs() {
@@ -1573,7 +1571,7 @@ Y.users = (e) => {
1573
1571
  number: o
1574
1572
  };
1575
1573
  });
1576
- let a = { ...ke(), user: t };
1574
+ let a = { ...je(), user: t };
1577
1575
  Oe(a);
1578
1576
  };
1579
1577
  Y.api = (e) => {
@@ -1586,13 +1584,13 @@ Y.delete = () => {
1586
1584
  te();
1587
1585
  };
1588
1586
  Y.select = (e) => {
1589
- let t = { ...ke() };
1587
+ let t = { ...je() };
1590
1588
  e.data.forEach((a) => {
1591
1589
  t[a.n] = JSON.parse(a.s);
1592
1590
  }), Oe(t);
1593
1591
  };
1594
1592
  Y.job = (e) => {
1595
- let t = { ...ke() }, a = {};
1593
+ let t = { ...je() }, a = {};
1596
1594
  Object.keys(e.data).forEach((r) => {
1597
1595
  a[r] = { s: 1, n: e.data[r] };
1598
1596
  }), t[1] = a, Oe(t);
@@ -2027,7 +2025,7 @@ function Ts(e, t) {
2027
2025
  return e > 10 && e < 20 ? t[2] : a > 1 && a < 5 ? t[1] : a === 1 ? t[0] : t[2];
2028
2026
  }
2029
2027
  function Is(e, t, a) {
2030
- return ke(e, t) ? ke(e, t).n : a || "";
2028
+ return je(e, t) ? je(e, t).n : a || "";
2031
2029
  }
2032
2030
  function Ds(e, t) {
2033
2031
  return e.reduce(function(a, r) {
@@ -2126,12 +2124,12 @@ function fi({ onClick: e, onSend: t, label: a, onRef: r }) {
2126
2124
  }
2127
2125
  );
2128
2126
  }
2129
- let Ce = {};
2127
+ let ke = {};
2130
2128
  function mi({ config: e }) {
2131
2129
  let [t, a] = x.useState([]);
2132
- return Ce.x = (r) => {
2130
+ return ke.x = (r) => {
2133
2131
  r || a([]);
2134
- }, Ce.config = e, Ce.add = (r) => {
2132
+ }, ke.config = e, ke.add = (r) => {
2135
2133
  a([...t, r]);
2136
2134
  }, /* @__PURE__ */ n.jsx(n.Fragment, { children: t.map((r) => r) });
2137
2135
  }
@@ -2214,7 +2212,7 @@ function hi({
2214
2212
  ) : "" });
2215
2213
  }
2216
2214
  function xi(e) {
2217
- Ce.add(/* @__PURE__ */ n.jsx(pi, { children: e }, String(Date.now())));
2215
+ ke.add(/* @__PURE__ */ n.jsx(pi, { children: e }, String(Date.now())));
2218
2216
  }
2219
2217
  function pi({ children: e }) {
2220
2218
  return /* @__PURE__ */ n.jsx(n.Fragment, { children: e });
@@ -2230,14 +2228,14 @@ function gi(e) {
2230
2228
  function vi({ type: e, name: t, params: a }) {
2231
2229
  let [r, s] = x.useState(null);
2232
2230
  return x.useEffect(() => {
2233
- Ce.config(e, t, a, s);
2231
+ ke.config(e, t, a, s);
2234
2232
  }, [a.id]), /* @__PURE__ */ n.jsx(n.Fragment, { children: r });
2235
2233
  }
2236
2234
  function Ci(e, t, a) {
2237
- Ce.config(e, t, a);
2235
+ ke.config(e, t, a);
2238
2236
  }
2239
2237
  function ki(e) {
2240
- Ce.x(e);
2238
+ ke.x(e);
2241
2239
  }
2242
2240
  const Qe = {
2243
2241
  List: Fs,
@@ -2657,19 +2655,19 @@ y.connect = !1;
2657
2655
  y.offer = null;
2658
2656
  y.btnRefuse = null;
2659
2657
  y.time = !1;
2660
- let ve;
2661
- ve = document.createElement("audio");
2662
- ve.setAttribute("autoplay", "true");
2663
- ve.setAttribute("muted", "true");
2658
+ let Ce;
2659
+ Ce = document.createElement("audio");
2660
+ Ce.setAttribute("autoplay", "true");
2661
+ Ce.setAttribute("muted", "true");
2664
2662
  O.start = async (e) => {
2665
2663
  y.rtc = new RTCPeerConnection(y.config), y.other = [], y.remoute = !1, y.rtc.onicecandidate = (a) => {
2666
2664
  a.candidate && y.other.push(a.candidate);
2667
2665
  }, y.rtc.ontrack = (a) => {
2668
2666
  if (a.streams && a.streams[0])
2669
- ve.srcObject = a.streams[0];
2667
+ Ce.srcObject = a.streams[0];
2670
2668
  else {
2671
2669
  let r = new MediaStream(a.track);
2672
- ve.srcObject = r;
2670
+ Ce.srcObject = r;
2673
2671
  }
2674
2672
  };
2675
2673
  const t = await navigator.mediaDevices.getUserMedia({
@@ -2682,10 +2680,10 @@ O.start = async (e) => {
2682
2680
  y.rtc.connectionState;
2683
2681
  }, y.rtc.ontrack = async (a) => {
2684
2682
  if (a.streams && a.streams[0])
2685
- ve.srcObject = a.streams[0];
2683
+ Ce.srcObject = a.streams[0];
2686
2684
  else {
2687
2685
  let r = new MediaStream(a.track);
2688
- ve.srcObject = r;
2686
+ Ce.srcObject = r;
2689
2687
  }
2690
2688
  }, y.rtc.onaddstream = (a) => {
2691
2689
  }, y.rtc.onnegotiationneeded = (a) => {
@@ -2945,22 +2943,22 @@ function no(e, t) {
2945
2943
  function ao(e, t) {
2946
2944
  kt[e] !== void 0 && kt[e](t);
2947
2945
  }
2948
- const fe = {};
2946
+ const me = {};
2949
2947
  function ro(e, t) {
2950
2948
  const [a, r] = x.useState(t);
2951
2949
  return x.useEffect(() => {
2952
- if (fe[e])
2953
- return fe[e].push(r);
2954
- fe[e] = [r];
2950
+ if (me[e])
2951
+ return me[e].push(r);
2952
+ me[e] = [r];
2955
2953
  }, []), [a];
2956
2954
  }
2957
2955
  function so(e, t) {
2958
- if (fe[e])
2959
- return fe[e].push(t);
2960
- fe[e] = [t];
2956
+ if (me[e])
2957
+ return me[e].push(t);
2958
+ me[e] = [t];
2961
2959
  }
2962
2960
  function io(e, t) {
2963
- fe[e] && fe[e].forEach((a) => a(t));
2961
+ me[e] && me[e].forEach((a) => a(t));
2964
2962
  }
2965
2963
  const Ee = { setListener: ao, useListener: no, setEmitter: io, useEmitter: ro, subEmitter: so };
2966
2964
  function oo() {
@@ -3211,7 +3209,7 @@ class Go {
3211
3209
  }
3212
3210
  }
3213
3211
  let ut, W = {};
3214
- const Ne = () => (ut || (ut = new Go()), ut), xe = (e, t, a = Ne()) => a._withIDBStore("readwrite", (r) => {
3212
+ const Ne = () => (ut || (ut = new Go()), ut), pe = (e, t, a = Ne()) => a._withIDBStore("readwrite", (r) => {
3215
3213
  W[e] = t, r.put(F.enCode(t), e);
3216
3214
  }), de = (e, t = Ne()) => W[e] === void 0 ? new Promise((a, r) => {
3217
3215
  let s;
@@ -3280,21 +3278,21 @@ const Ne = () => (ut || (ut = new Go()), ut), xe = (e, t, a = Ne()) => a._withID
3280
3278
  });
3281
3279
  }, Yo = async (e, t, a, r) => {
3282
3280
  let s, i;
3283
- i = await de(a), i[e.id] = e, await xe(a, i), s !== null && (s = await de(t), s[e.id] = e.eDate, await xe(t, s)), r !== void 0 && r({ type: "load", page: s, base: i });
3281
+ i = await de(a), i[e.id] = e, await pe(a, i), s !== null && (s = await de(t), s[e.id] = e.eDate, await pe(t, s)), r !== void 0 && r({ type: "load", page: s, base: i });
3284
3282
  }, Ho = async (e, t, a, r) => {
3285
3283
  let s = await de(t), i = await de(a);
3286
3284
  for (let o in e)
3287
3285
  i[o] = e[o], s[o] = e[o].eDate;
3288
- await xe(t, s), await xe(a, i), r !== void 0 && r({ type: "load", page: s, base: i });
3286
+ await pe(t, s), await pe(a, i), r !== void 0 && r({ type: "load", page: s, base: i });
3289
3287
  }, qo = async (e, t, a, r) => {
3290
3288
  let s = await de(t), i = await de(a);
3291
- e.forEach((o) => delete s[o]), await xe(t, s), r !== void 0 && r({ type: "load", page: s, base: i });
3289
+ e.forEach((o) => delete s[o]), await pe(t, s), r !== void 0 && r({ type: "load", page: s, base: i });
3292
3290
  }, Jo = async (e, t, a) => {
3293
3291
  let r = await de(t);
3294
- e.forEach((s) => delete r[s]), await xe(t, r);
3292
+ e.forEach((s) => delete r[s]), await pe(t, r);
3295
3293
  }, Xo = async (e, t, a) => {
3296
3294
  let r = await de(t);
3297
- e.forEach((s) => r[s.id] = s.eDate), await xe(t, r);
3295
+ e.forEach((s) => r[s.id] = s.eDate), await pe(t, r);
3298
3296
  }, Qo = async (e, t, a) => {
3299
3297
  let r = await de(t);
3300
3298
  if (a !== void 0)
@@ -3304,7 +3302,7 @@ const Ne = () => (ut || (ut = new Go()), ut), xe = (e, t, a = Ne()) => a._withID
3304
3302
  }, el = (e) => W[e], ac = {
3305
3303
  id: Qo,
3306
3304
  get: de,
3307
- set: xe,
3305
+ set: pe,
3308
3306
  add: Yo,
3309
3307
  del: Wo,
3310
3308
  upd: Vo,
@@ -3782,7 +3780,7 @@ function Bn(e) {
3782
3780
  }
3783
3781
  ) });
3784
3782
  }
3785
- const ll = "_o_1kqkq_1", cl = "_c_1kqkq_11", we = {
3783
+ const ll = "_o_1kqkq_1", cl = "_c_1kqkq_11", Se = {
3786
3784
  o: ll,
3787
3785
  c: cl
3788
3786
  };
@@ -3875,7 +3873,7 @@ const dl = (e) => {
3875
3873
  /* @__PURE__ */ n.jsx(
3876
3874
  "div",
3877
3875
  {
3878
- className: we.o,
3876
+ className: Se.o,
3879
3877
  onClick: () => C()
3880
3878
  },
3881
3879
  (/* @__PURE__ */ new Date()).getTime()
@@ -3883,7 +3881,7 @@ const dl = (e) => {
3883
3881
  /* @__PURE__ */ n.jsxs(
3884
3882
  "div",
3885
3883
  {
3886
- className: we.c,
3884
+ className: Se.c,
3887
3885
  style: { top: I + "px", left: D + "px" },
3888
3886
  children: [
3889
3887
  /* @__PURE__ */ n.jsxs("s", { children: [
@@ -4090,7 +4088,7 @@ const _l = (e) => {
4090
4088
  /* @__PURE__ */ n.jsx(
4091
4089
  "div",
4092
4090
  {
4093
- className: we.o,
4091
+ className: Se.o,
4094
4092
  onClick: () => d()
4095
4093
  },
4096
4094
  (/* @__PURE__ */ new Date()).getTime()
@@ -4098,7 +4096,7 @@ const _l = (e) => {
4098
4096
  /* @__PURE__ */ n.jsxs(
4099
4097
  "div",
4100
4098
  {
4101
- className: we.c,
4099
+ className: Se.c,
4102
4100
  style: { top: v + "px", left: g + "px" },
4103
4101
  children: [
4104
4102
  /* @__PURE__ */ n.jsxs("s", { children: [
@@ -4130,7 +4128,7 @@ const _l = (e) => {
4130
4128
  function On(e) {
4131
4129
  let t = () => e.title ? /* @__PURE__ */ n.jsx("dt", { children: e.title }) : "", a = () => e.error ? /* @__PURE__ */ n.jsx("em", { children: e.error }) : "", [r, s] = x.useState(!1), i = e.edit !== void 0 ? e.edit : !0, o = e.active !== void 0 ? e.active : !0, _ = !!(e.hide && (e.value === "" || e.value === void 0)) && !(i && o);
4132
4130
  r = i ? !0 : r;
4133
- let d = e.placeholder !== void 0 ? e.placeholder : "Заметка пуста", u = (g) => {
4131
+ let d = e.placeholder !== void 0 ? e.placeholder : "", u = (g) => {
4134
4132
  e.onValue && e.onValue({ value: g.target.innerText, name: e.name });
4135
4133
  }, f = (g) => {
4136
4134
  g.preventDefault(), navigator.clipboard.readText().then((j) => {
@@ -6278,7 +6276,7 @@ const ml = ({ positions: e, onSave: t, onValue: a, date: r }) => {
6278
6276
  /* @__PURE__ */ n.jsx(
6279
6277
  "div",
6280
6278
  {
6281
- className: we.o,
6279
+ className: Se.o,
6282
6280
  onClick: () => I()
6283
6281
  },
6284
6282
  (/* @__PURE__ */ new Date()).getTime()
@@ -6286,7 +6284,7 @@ const ml = ({ positions: e, onSave: t, onValue: a, date: r }) => {
6286
6284
  /* @__PURE__ */ n.jsxs(
6287
6285
  "div",
6288
6286
  {
6289
- className: we.c,
6287
+ className: Se.c,
6290
6288
  onMouseDown: h,
6291
6289
  onMouseUp: C,
6292
6290
  onMouseMove: v,
@@ -6541,20 +6539,22 @@ function Vn({
6541
6539
  i && /* @__PURE__ */ n.jsx("em", { children: i })
6542
6540
  ] });
6543
6541
  }
6544
- const Se = {};
6542
+ const fe = {};
6545
6543
  function pl(e) {
6546
6544
  const [t, a] = x.useState({}), r = x.useRef(e);
6547
- return Se.u = (s) => {
6545
+ return fe.u = (s) => {
6548
6546
  r.current = { ...r.current, [s.name]: s.value };
6549
- }, Se.r = () => {
6547
+ }, fe.n = (s) => {
6548
+ r.current = s, a(Date.now());
6549
+ }, fe.r = () => {
6550
6550
  a(Date.now());
6551
- }, [r.current];
6551
+ }, [r.current, fe.n];
6552
6552
  }
6553
6553
  function gl(e) {
6554
- Se.u(e), e.reload && Se.r();
6554
+ fe.u(e), e.reload && fe.r();
6555
6555
  }
6556
6556
  function vl() {
6557
- Se.r && Se.r();
6557
+ fe.r && fe.r();
6558
6558
  }
6559
6559
  const ic = {
6560
6560
  Color: Bn,