@fluid-app/fluid-cli-theme-dev 0.1.177 → 0.1.178

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/dist/dist-cli-preview/.vite/manifest.json +271 -282
  2. package/dist/dist-cli-preview/account-screens.js +1 -1
  3. package/dist/dist-cli-preview/chunks/{Breadcrumb-8-7shsB6.js → Breadcrumb-DLYQ2Vr1.js} +1 -1
  4. package/dist/dist-cli-preview/chunks/{Combobox-m3vSk0_A.js → Combobox-I60LziKt.js} +195 -163
  5. package/dist/dist-cli-preview/chunks/{ContactsScreen-CBjQOWmH.js → ContactsScreen-DWAUWpQz.js} +516 -547
  6. package/dist/dist-cli-preview/chunks/MediaScreen-BOQw5HIm.js +8 -0
  7. package/dist/dist-cli-preview/chunks/{MemberManagementProviders-WSjb3a8B.js → MemberManagementProviders-CYbE8v0N.js} +6 -6
  8. package/dist/dist-cli-preview/chunks/{MemberShareablesScreen-D-5-JyQq.js → MemberShareablesScreen-CzXDumR4.js} +1768 -1785
  9. package/dist/dist-cli-preview/chunks/{MessagingScreen-By-jZq6v.js → MessagingScreen-Ch9BYR8g.js} +8452 -11174
  10. package/dist/dist-cli-preview/chunks/{MobileActionSheet-ERpw3qUF.js → MobileActionSheet-k67c8wJk.js} +2 -2
  11. package/dist/dist-cli-preview/chunks/{MySiteScreen-JAGvVMx-.js → MySiteScreen-DnQNCsOZ.js} +40 -41
  12. package/dist/dist-cli-preview/chunks/{OrdersScreen-Cb32bBjd.js → OrdersScreen-Bwn7Je6W.js} +7 -7
  13. package/dist/dist-cli-preview/chunks/OrdersScreen-DJoXusa-.js +9 -0
  14. package/dist/dist-cli-preview/chunks/PlaylistsScreen-BoZ2Fver.js +8 -0
  15. package/dist/dist-cli-preview/chunks/{PortalTenantClientProvider-CguU_uRG.js → PortalTenantClientProvider-JAGrume8.js} +1 -1
  16. package/dist/dist-cli-preview/chunks/{ProfileScreen-CCWM6TBs.js → ProfileScreen-CUURwTbd.js} +193 -203
  17. package/dist/dist-cli-preview/chunks/{Select-5fzq5MB-.js → Select-97UR3puI.js} +204 -192
  18. package/dist/dist-cli-preview/chunks/{SubscriptionsScreen-DLdsaVJK.js → SubscriptionsScreen-D5TEWnpQ.js} +3 -3
  19. package/dist/dist-cli-preview/chunks/{Textarea-xoKqLVgY.js → Textarea-DlTzkeqw.js} +86 -67
  20. package/dist/dist-cli-preview/chunks/{account-screen-runtime-CCBl8DXt.js → account-screen-runtime-CVtcJ0Fb.js} +3867 -3911
  21. package/dist/dist-cli-preview/chunks/{arrow-left-CTYaRdTX.js → arrow-left-CVKbyXG0.js} +1 -1
  22. package/dist/dist-cli-preview/chunks/{cli-preview-CMcquUEN.js → cli-preview-S7GUnjUK.js} +9 -9
  23. package/dist/dist-cli-preview/chunks/{client.gen-B7RMYGYu.js → client.gen-CTq48a_5.js} +1 -1
  24. package/dist/dist-cli-preview/chunks/{copy-DHN1DxE_.js → copy-Cb0EF4FY.js} +1 -1
  25. package/dist/dist-cli-preview/chunks/{countries-api-adapter-B4TefdRP.js → countries-api-adapter-39yd7wyu.js} +2 -2
  26. package/dist/dist-cli-preview/chunks/{create-card-entry-container-5NqOQ4D_.js → create-card-entry-container-GUKP9hm9.js} +7779 -7949
  27. package/dist/dist-cli-preview/chunks/{eye-qMoMW7-Z.js → eye-Br576SOE.js} +1 -1
  28. package/dist/dist-cli-preview/chunks/{hey-api-client-JMNyZwcF.js → hey-api-client-ojYRPo91.js} +1 -1
  29. package/dist/dist-cli-preview/chunks/{index-BhMjUmAr.js → index-CpV8WNR4.js} +3 -3
  30. package/dist/dist-cli-preview/chunks/{index-Dor8vM2o.js → index-oaLlxtXm.js} +1 -1
  31. package/dist/dist-cli-preview/chunks/{index-BS4PnEcu.js → index-twP43mON.js} +74 -86
  32. package/dist/dist-cli-preview/chunks/isAfter-DAVNjOeD.js +1324 -0
  33. package/dist/dist-cli-preview/chunks/{log-out-DUdRJX4l.js → log-out-uqUyU7ZP.js} +1 -1
  34. package/dist/dist-cli-preview/chunks/{map-pin-DyIkpqP0.js → map-pin-FwB95jm4.js} +1 -1
  35. package/dist/dist-cli-preview/chunks/mount-account-screen-SGot0CzY.js +12595 -0
  36. package/dist/dist-cli-preview/chunks/{navigate-account-screen-mT0rqVLT.js → navigate-account-screen-CC9GJcTK.js} +1 -1
  37. package/dist/dist-cli-preview/chunks/{schemas-BTblatUV.js → schemas-CK5ZjT20.js} +541 -530
  38. package/dist/dist-cli-preview/chunks/{screen-route-slug-utils-DozJp-uc.js → screen-route-slug-utils-MtfouJSS.js} +1 -1
  39. package/dist/dist-cli-preview/chunks/{sheet-haptics-context-CYrEaGtf.js → sheet-haptics-context-N2vLfwOc.js} +1 -1
  40. package/dist/dist-cli-preview/chunks/{sidebar-9qopXeR1.js → sidebar-D8LwwiTr.js} +10 -10
  41. package/dist/dist-cli-preview/chunks/{sortable.esm-Dlen88Fc.js → sortable.esm-jbVNBxCA.js} +2 -2
  42. package/dist/dist-cli-preview/chunks/{store-api-context-B9pW_xao.js → store-api-context-DhtPESgY.js} +1 -1
  43. package/dist/dist-cli-preview/chunks/{trash-2-ClRyi9iY.js → trash-2-f4dJpepX.js} +9 -9
  44. package/dist/dist-cli-preview/chunks/{use-mobile-srOt50VV.js → use-mobile-C4O5e0kh.js} +3 -3
  45. package/dist/dist-cli-preview/chunks/{use-optional-store-BgrOjfZJ.js → use-optional-store-qUug8CSx.js} +2 -2
  46. package/dist/dist-cli-preview/chunks/{use-store-CUSQx1E-.js → use-store-B00K7G5q.js} +3 -3
  47. package/dist/dist-cli-preview/chunks/{useInfiniteQuery-DGc8fotv.js → useInfiniteQuery-pbRaLvNe.js} +1 -1
  48. package/dist/dist-cli-preview/chunks/{user-Ca2sKJ-h.js → user-CRiDn40l.js} +1 -1
  49. package/dist/dist-cli-preview/chunks/{users-Dh7zTrKY.js → users-BMdwEKKP.js} +1 -1
  50. package/package.json +2 -2
  51. package/dist/dist-cli-preview/chunks/MediaScreen-DlrLPYRf.js +0 -8
  52. package/dist/dist-cli-preview/chunks/OrdersScreen-B1HQVMZC.js +0 -9
  53. package/dist/dist-cli-preview/chunks/PlaylistsScreen-DgYA1qcv.js +0 -8
  54. package/dist/dist-cli-preview/chunks/lock-DQTMeEw0.js +0 -14
  55. package/dist/dist-cli-preview/chunks/mount-account-screen-BuQhxURX.js +0 -11113
  56. package/dist/dist-cli-preview/chunks/plus-DZjrp536.js +0 -14
@@ -1,94 +1,63 @@
1
- import { c as je, l as i, ac as cr, j as t, aa as dr, ab as ur, am as Ie, aW as mr, a9 as rn, a8 as wt, X as Ge, M as D, U as pt, aP as pr, Z as fr, K as q, N as gr, G as ve, R as an, J as W, E as O, bg as hr, aH as _r, $ as ue, a0 as me, a1 as pe, a2 as fe, a3 as ge, bh as xr, aL as sn, aM as on, bi as ln, aN as cn, C as br, bj as yt, O as dn, H, Y as yr, bk as vr, B as jr, ag as un, z as Nr } from "./account-screen-runtime-CCBl8DXt.js";
2
- import { c as Cr, a as kr, u as wr } from "./client.gen-B7RMYGYu.js";
3
- import { u as mn, a as Sr, c as Mr, C as Tr } from "./countries-api-adapter-B4TefdRP.js";
4
- import { T as tt, u as pn } from "./trash-2-ClRyi9iY.js";
5
- import { B as Er, Z as Dr, M as nt, u as re, o as Ar, r as Rt, s as ie, p as Pr, c as It, C as fn, R as Ae, j as Pe, P as gn } from "./schemas-BTblatUV.js";
6
- import { u as zr } from "./use-mobile-srOt50VV.js";
7
- import { a as Fr, c as Rr, b as Ir, u as Or, I as ae, S as De } from "./sheet-haptics-context-CYrEaGtf.js";
8
- import { B as Lr, a as qr, b as Ot, d as $r, e as Kr, c as Br } from "./Breadcrumb-8-7shsB6.js";
9
- import { o as hn, p as Ur, q as Gr, r as Hr, s as Yr, S as Qr, t as Vr, u as Wr, I as Xr, v as Zr, G as Jr, L as ea, w as ta, x as na, y as ra, z as aa, B as sa, P as _n, g as xn, h as bn, M as He, D as rt, a as at, b as st, c as $e, E as Ze } from "./MobileActionSheet-ERpw3qUF.js";
10
- import { u as oa, S as yn } from "./useInfiniteQuery-DGc8fotv.js";
11
- import { P as _e } from "./plus-DZjrp536.js";
12
- import { U as we } from "./users-Dh7zTrKY.js";
13
- import { E as Je, c as ia, U as la, d as ca, e as da, f as ua, S as ma, T as pa, a as fa, b as Lt, g as qt } from "./index-BS4PnEcu.js";
14
- import { S as ga, b as ha, I as Ke, a as Oe, s as vn, d as _a, e as xa } from "./screen-route-slug-utils-DozJp-uc.js";
15
- import { u as he } from "./sidebar-9qopXeR1.js";
16
- import { S as ba, a as ya, b as va, c as ja, d as Na } from "./Select-5fzq5MB-.js";
17
- import { C as Ca } from "./Combobox-m3vSk0_A.js";
18
- import { M as jn, c as Nn, S as ka, H as wa, P as Sa, u as Ma, T as Ta, L as Ea, b as Da, E as Aa, a as Pa } from "./index-Dor8vM2o.js";
19
- import { M as za } from "./map-pin-DyIkpqP0.js";
20
- import { C as Fa } from "./copy-DHN1DxE_.js";
1
+ import { c as ze, l as i, ac as cr, j as t, aa as dr, ab as ur, am as Ie, az as mr, a9 as rn, a8 as wt, X as Ge, M as D, U as pt, aw as pr, Z as fr, K as q, N as gr, G as ve, R as an, J as W, E as O, aM as hr, ap as _r, $ as ue, a0 as me, a1 as pe, a2 as fe, a3 as ge, aN as xr, at as sn, au as on, aO as ln, av as cn, C as br, aP as yt, O as dn, H, Y as yr, aQ as vr, B as jr, ag as un, z as Nr } from "./account-screen-runtime-CVtcJ0Fb.js";
2
+ import { c as Cr, a as kr, u as wr } from "./client.gen-CTq48a_5.js";
3
+ import { u as mn, a as Sr, c as Mr, C as Tr } from "./countries-api-adapter-39yd7wyu.js";
4
+ import { T as tt, u as pn } from "./trash-2-f4dJpepX.js";
5
+ import { E as Er, Z as Dr, P as _e, M as nt, u as re, o as Ar, r as Rt, s as ie, q as Pr, c as It, C as fn, R as De, j as Ae, k as gn } from "./schemas-CK5ZjT20.js";
6
+ import { u as zr } from "./use-mobile-C4O5e0kh.js";
7
+ import { a as Fr, c as Rr, b as Ir, u as Or, I as ae, S as Ee } from "./sheet-haptics-context-N2vLfwOc.js";
8
+ import { B as Lr, a as qr, b as Ot, d as $r, e as Kr, c as Br } from "./Breadcrumb-DLYQ2Vr1.js";
9
+ import { o as hn, p as Ur, q as Gr, r as Hr, s as Qr, S as Yr, t as Vr, u as Wr, I as Xr, v as Zr, G as Jr, L as ea, w as ta, x as na, y as ra, z as aa, B as sa, P as _n, g as xn, h as bn, M as He, D as rt, a as at, b as st, c as $e, E as Ze } from "./MobileActionSheet-k67c8wJk.js";
10
+ import { u as oa, S as yn } from "./useInfiniteQuery-pbRaLvNe.js";
11
+ import { U as ke } from "./users-BMdwEKKP.js";
12
+ import { E as Je, S as ia, a as la, b as ca, c as da, d as ua } from "./Select-97UR3puI.js";
13
+ import { S as ma, b as pa, I as Ke, a as Oe, s as vn, d as fa, e as ga } from "./screen-route-slug-utils-MtfouJSS.js";
14
+ import { c as ha, U as _a, d as xa, e as ba, f as ya, S as va, T as ja, a as Na, b as Lt, g as qt } from "./index-twP43mON.js";
15
+ import { u as he } from "./sidebar-D8LwwiTr.js";
16
+ import { g as Se, h as Ca, C as ka } from "./Combobox-I60LziKt.js";
17
+ import { M as jn, c as Nn, S as wa, H as Sa, P as Ma, u as Ta, T as Ea, L as Da, b as Aa, E as Pa, a as za } from "./index-oaLlxtXm.js";
18
+ import { M as Fa } from "./map-pin-FwB95jm4.js";
19
+ import { C as Ra } from "./copy-Cb0EF4FY.js";
21
20
  /**
22
21
  * @license lucide-react v0.575.0 - ISC
23
22
  *
24
23
  * This source code is licensed under the ISC license.
25
24
  * See the LICENSE file in the root directory of this source tree.
26
25
  */
27
- const Ra = [
28
- ["path", { d: "M8 2v4", key: "1cmpym" }],
29
- ["path", { d: "M16 2v4", key: "4m81vk" }],
30
- ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
31
- ["path", { d: "M3 10h18", key: "8toen8" }],
32
- ["path", { d: "M8 14h.01", key: "6423bh" }],
33
- ["path", { d: "M12 14h.01", key: "1etili" }],
34
- ["path", { d: "M16 14h.01", key: "1gbofw" }],
35
- ["path", { d: "M8 18h.01", key: "lrp35t" }],
36
- ["path", { d: "M12 18h.01", key: "mhygvu" }],
37
- ["path", { d: "M16 18h.01", key: "kzsmim" }]
38
- ], Ia = je("calendar-days", Ra);
39
- /**
40
- * @license lucide-react v0.575.0 - ISC
41
- *
42
- * This source code is licensed under the ISC license.
43
- * See the LICENSE file in the root directory of this source tree.
44
- */
45
- const Oa = [
46
- ["path", { d: "M8 2v4", key: "1cmpym" }],
47
- ["path", { d: "M16 2v4", key: "4m81vk" }],
48
- ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
49
- ["path", { d: "M3 10h18", key: "8toen8" }]
50
- ], Me = je("calendar", Oa);
51
- /**
52
- * @license lucide-react v0.575.0 - ISC
53
- *
54
- * This source code is licensed under the ISC license.
55
- * See the LICENSE file in the root directory of this source tree.
56
- */
57
- const La = [
26
+ const Ia = [
58
27
  ["path", { d: "m2 2 20 20", key: "1ooewy" }],
59
28
  ["path", { d: "M8.35 2.69A10 10 0 0 1 21.3 15.65", key: "1pfsoa" }],
60
29
  ["path", { d: "M19.08 19.08A10 10 0 1 1 4.92 4.92", key: "1ablyi" }]
61
- ], qa = je("circle-off", La);
30
+ ], Oa = ze("circle-off", Ia);
62
31
  /**
63
32
  * @license lucide-react v0.575.0 - ISC
64
33
  *
65
34
  * This source code is licensed under the ISC license.
66
35
  * See the LICENSE file in the root directory of this source tree.
67
36
  */
68
- const $a = [
37
+ const La = [
69
38
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
70
39
  ["path", { d: "M12 6v6l4 2", key: "mmk7yg" }]
71
- ], $t = je("clock", $a);
40
+ ], $t = ze("clock", La);
72
41
  /**
73
42
  * @license lucide-react v0.575.0 - ISC
74
43
  *
75
44
  * This source code is licensed under the ISC license.
76
45
  * See the LICENSE file in the root directory of this source tree.
77
46
  */
78
- const Ka = [
47
+ const qa = [
79
48
  ["path", { d: "M13 5h8", key: "a7qcls" }],
80
49
  ["path", { d: "M13 12h8", key: "h98zly" }],
81
50
  ["path", { d: "M13 19h8", key: "c3s6r1" }],
82
51
  ["path", { d: "m3 17 2 2 4-4", key: "1jhpwq" }],
83
52
  ["rect", { x: "3", y: "4", width: "6", height: "6", rx: "1", key: "cif1o7" }]
84
- ], Ba = je("list-todo", Ka);
53
+ ], $a = ze("list-todo", qa);
85
54
  /**
86
55
  * @license lucide-react v0.575.0 - ISC
87
56
  *
88
57
  * This source code is licensed under the ISC license.
89
58
  * See the LICENSE file in the root directory of this source tree.
90
59
  */
91
- const Ua = [
60
+ const Ka = [
92
61
  [
93
62
  "path",
94
63
  {
@@ -96,14 +65,14 @@ const Ua = [
96
65
  key: "1miecu"
97
66
  }
98
67
  ]
99
- ], Ga = je("paperclip", Ua);
68
+ ], Ba = ze("paperclip", Ka);
100
69
  /**
101
70
  * @license lucide-react v0.575.0 - ISC
102
71
  *
103
72
  * This source code is licensed under the ISC license.
104
73
  * See the LICENSE file in the root directory of this source tree.
105
74
  */
106
- const Ha = [
75
+ const Ua = [
107
76
  ["circle", { cx: "12", cy: "12", r: "4", key: "4exip2" }],
108
77
  ["path", { d: "M12 2v2", key: "tus03m" }],
109
78
  ["path", { d: "M12 20v2", key: "1lh1kg" }],
@@ -113,14 +82,14 @@ const Ha = [
113
82
  ["path", { d: "M20 12h2", key: "1q8mjw" }],
114
83
  ["path", { d: "m6.34 17.66-1.41 1.41", key: "1m8zz5" }],
115
84
  ["path", { d: "m19.07 4.93-1.41 1.41", key: "1shlcs" }]
116
- ], Ya = je("sun", Ha);
85
+ ], Ga = ze("sun", Ua);
117
86
  /**
118
87
  * @license lucide-react v0.575.0 - ISC
119
88
  *
120
89
  * This source code is licensed under the ISC license.
121
90
  * See the LICENSE file in the root directory of this source tree.
122
91
  */
123
- const Qa = [
92
+ const Ha = [
124
93
  ["path", { d: "M12 2v8", key: "1q4o3n" }],
125
94
  ["path", { d: "m4.93 10.93 1.41 1.41", key: "2a7f42" }],
126
95
  ["path", { d: "M2 18h2", key: "j10viu" }],
@@ -129,10 +98,10 @@ const Qa = [
129
98
  ["path", { d: "M22 22H2", key: "19qnx5" }],
130
99
  ["path", { d: "m8 6 4-4 4 4", key: "ybng9g" }],
131
100
  ["path", { d: "M16 18a4 4 0 0 0-8 0", key: "1lzouq" }]
132
- ], Va = je("sunrise", Qa);
133
- var St = "ContextMenu", [Wa] = dr(St, [
101
+ ], Qa = ze("sunrise", Ha);
102
+ var St = "ContextMenu", [Ya] = dr(St, [
134
103
  hn
135
- ]), ee = hn(), [Xa, Cn] = Wa(St), kn = (e) => {
104
+ ]), ee = hn(), [Va, Cn] = Ya(St), kn = (e) => {
136
105
  const { __scopeContextMenu: n, children: r, onOpenChange: a, dir: s, modal: o = !0 } = e, [l, c] = i.useState(!1), d = ee(n), u = cr(a), m = i.useCallback(
137
106
  (g) => {
138
107
  c(g), u(g);
@@ -140,7 +109,7 @@ var St = "ContextMenu", [Wa] = dr(St, [
140
109
  [u]
141
110
  );
142
111
  return /* @__PURE__ */ t.jsx(
143
- Xa,
112
+ Va,
144
113
  {
145
114
  scope: n,
146
115
  open: l,
@@ -199,16 +168,16 @@ var wn = "ContextMenuTrigger", Sn = i.forwardRef(
199
168
  }
200
169
  );
201
170
  Sn.displayName = wn;
202
- var Za = "ContextMenuPortal", Mn = (e) => {
171
+ var Wa = "ContextMenuPortal", Mn = (e) => {
203
172
  const { __scopeContextMenu: n, ...r } = e, a = ee(n);
204
173
  return /* @__PURE__ */ t.jsx(Hr, { ...a, ...r });
205
174
  };
206
- Mn.displayName = Za;
175
+ Mn.displayName = Wa;
207
176
  var Tn = "ContextMenuContent", En = i.forwardRef(
208
177
  (e, n) => {
209
178
  const { __scopeContextMenu: r, ...a } = e, s = Cn(Tn, r), o = ee(r), l = i.useRef(!1);
210
179
  return /* @__PURE__ */ t.jsx(
211
- Yr,
180
+ Qr,
212
181
  {
213
182
  ...o,
214
183
  ...a,
@@ -235,59 +204,59 @@ var Tn = "ContextMenuContent", En = i.forwardRef(
235
204
  }
236
205
  );
237
206
  En.displayName = Tn;
238
- var Ja = "ContextMenuGroup", es = i.forwardRef(
207
+ var Xa = "ContextMenuGroup", Za = i.forwardRef(
239
208
  (e, n) => {
240
209
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
241
210
  return /* @__PURE__ */ t.jsx(Jr, { ...s, ...a, ref: n });
242
211
  }
243
212
  );
244
- es.displayName = Ja;
245
- var ts = "ContextMenuLabel", ns = i.forwardRef(
213
+ Za.displayName = Xa;
214
+ var Ja = "ContextMenuLabel", es = i.forwardRef(
246
215
  (e, n) => {
247
216
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
248
217
  return /* @__PURE__ */ t.jsx(ea, { ...s, ...a, ref: n });
249
218
  }
250
219
  );
251
- ns.displayName = ts;
252
- var rs = "ContextMenuItem", Dn = i.forwardRef(
220
+ es.displayName = Ja;
221
+ var ts = "ContextMenuItem", Dn = i.forwardRef(
253
222
  (e, n) => {
254
223
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
255
224
  return /* @__PURE__ */ t.jsx(Xr, { ...s, ...a, ref: n });
256
225
  }
257
226
  );
258
- Dn.displayName = rs;
259
- var as = "ContextMenuCheckboxItem", ss = i.forwardRef((e, n) => {
227
+ Dn.displayName = ts;
228
+ var ns = "ContextMenuCheckboxItem", rs = i.forwardRef((e, n) => {
260
229
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
261
230
  return /* @__PURE__ */ t.jsx(ta, { ...s, ...a, ref: n });
262
231
  });
263
- ss.displayName = as;
264
- var os = "ContextMenuRadioGroup", is = i.forwardRef((e, n) => {
232
+ rs.displayName = ns;
233
+ var as = "ContextMenuRadioGroup", ss = i.forwardRef((e, n) => {
265
234
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
266
235
  return /* @__PURE__ */ t.jsx(na, { ...s, ...a, ref: n });
267
236
  });
268
- is.displayName = os;
269
- var ls = "ContextMenuRadioItem", cs = i.forwardRef((e, n) => {
237
+ ss.displayName = as;
238
+ var os = "ContextMenuRadioItem", is = i.forwardRef((e, n) => {
270
239
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
271
240
  return /* @__PURE__ */ t.jsx(ra, { ...s, ...a, ref: n });
272
241
  });
273
- cs.displayName = ls;
274
- var ds = "ContextMenuItemIndicator", us = i.forwardRef((e, n) => {
242
+ is.displayName = os;
243
+ var ls = "ContextMenuItemIndicator", cs = i.forwardRef((e, n) => {
275
244
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
276
245
  return /* @__PURE__ */ t.jsx(aa, { ...s, ...a, ref: n });
277
246
  });
278
- us.displayName = ds;
279
- var ms = "ContextMenuSeparator", An = i.forwardRef((e, n) => {
247
+ cs.displayName = ls;
248
+ var ds = "ContextMenuSeparator", An = i.forwardRef((e, n) => {
280
249
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
281
250
  return /* @__PURE__ */ t.jsx(Zr, { ...s, ...a, ref: n });
282
251
  });
283
- An.displayName = ms;
284
- var ps = "ContextMenuArrow", fs = i.forwardRef(
252
+ An.displayName = ds;
253
+ var us = "ContextMenuArrow", ms = i.forwardRef(
285
254
  (e, n) => {
286
255
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
287
256
  return /* @__PURE__ */ t.jsx(sa, { ...s, ...a, ref: n });
288
257
  }
289
258
  );
290
- fs.displayName = ps;
259
+ ms.displayName = us;
291
260
  var Pn = "ContextMenuSub", zn = (e) => {
292
261
  const { __scopeContextMenu: n, children: r, onOpenChange: a, open: s, defaultOpen: o } = e, l = ee(n), [c, d] = mr({
293
262
  prop: s,
@@ -295,15 +264,15 @@ var Pn = "ContextMenuSub", zn = (e) => {
295
264
  onChange: a,
296
265
  caller: Pn
297
266
  });
298
- return /* @__PURE__ */ t.jsx(Qr, { ...l, open: c, onOpenChange: d, children: r });
267
+ return /* @__PURE__ */ t.jsx(Yr, { ...l, open: c, onOpenChange: d, children: r });
299
268
  };
300
269
  zn.displayName = Pn;
301
- var gs = "ContextMenuSubTrigger", Fn = i.forwardRef((e, n) => {
270
+ var ps = "ContextMenuSubTrigger", Fn = i.forwardRef((e, n) => {
302
271
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
303
272
  return /* @__PURE__ */ t.jsx(Vr, { ...s, ...a, ref: n });
304
273
  });
305
- Fn.displayName = gs;
306
- var hs = "ContextMenuSubContent", Rn = i.forwardRef((e, n) => {
274
+ Fn.displayName = ps;
275
+ var fs = "ContextMenuSubContent", Rn = i.forwardRef((e, n) => {
307
276
  const { __scopeContextMenu: r, ...a } = e, s = ee(r);
308
277
  return /* @__PURE__ */ t.jsx(
309
278
  Wr,
@@ -322,16 +291,16 @@ var hs = "ContextMenuSubContent", Rn = i.forwardRef((e, n) => {
322
291
  }
323
292
  );
324
293
  });
325
- Rn.displayName = hs;
294
+ Rn.displayName = fs;
326
295
  function Ve(e) {
327
296
  return (n) => n.pointerType !== "mouse" ? e(n) : void 0;
328
297
  }
329
- var _s = kn, xs = Sn, In = Mn, bs = En, ys = Dn, vs = An, js = zn, Ns = Fn, Cs = Rn;
298
+ var gs = kn, hs = Sn, In = Mn, _s = En, xs = Dn, bs = An, ys = zn, vs = Fn, js = Rn;
330
299
  function ft(e) {
331
300
  return e.replace(/_/g, " ").replace(/([A-Z])/g, " $1").split(" ").map((n) => n.charAt(0).toUpperCase() + n.slice(1).toLowerCase()).join(" ").trim();
332
301
  }
333
- const ks = "Request ID: ";
334
- function ke(e) {
302
+ const Ns = "Request ID: ";
303
+ function Ce(e) {
335
304
  if (typeof e != "string")
336
305
  return;
337
306
  const n = e.trim();
@@ -341,21 +310,21 @@ function et(e) {
341
310
  if (!e || typeof e != "object" || Array.isArray(e))
342
311
  return;
343
312
  const n = e, r = n.meta;
344
- return ke(n.request_id) ?? ke(n.requestId) ?? (r && typeof r == "object" && !Array.isArray(r) ? ke(r.request_id) ?? ke(r.requestId) : void 0);
313
+ return Ce(n.request_id) ?? Ce(n.requestId) ?? (r && typeof r == "object" && !Array.isArray(r) ? Ce(r.request_id) ?? Ce(r.requestId) : void 0);
345
314
  }
346
315
  function On(e, n) {
347
- return e === "request_id" || e === "requestId" ? ke(n) !== void 0 : e !== "meta" ? !1 : et(n) !== void 0;
316
+ return e === "request_id" || e === "requestId" ? Ce(n) !== void 0 : e !== "meta" ? !1 : et(n) !== void 0;
348
317
  }
349
- function Se(e) {
318
+ function we(e) {
350
319
  if (typeof e != "string")
351
320
  return;
352
321
  const n = e.trim();
353
322
  return n.length > 0 ? n : void 0;
354
323
  }
355
324
  function Ln(e, n) {
356
- return (e === "message" || e === "error_message" || e === "error") && Se(n) !== void 0;
325
+ return (e === "message" || e === "error_message" || e === "error") && we(n) !== void 0;
357
326
  }
358
- function ws(e) {
327
+ function Cs(e) {
359
328
  if (typeof e == "string")
360
329
  return e;
361
330
  try {
@@ -370,10 +339,10 @@ function Le(e, n) {
370
339
  return Object.prototype.hasOwnProperty.call(e, n);
371
340
  }
372
341
  function Mt(e) {
373
- return Se(e.message) ?? Se(e.error_message) ?? Se(e.error);
342
+ return we(e.message) ?? we(e.error_message) ?? we(e.error);
374
343
  }
375
- function Ss(e, n) {
376
- return Se(n) === e;
344
+ function ks(e, n) {
345
+ return we(n) === e;
377
346
  }
378
347
  function qn(e) {
379
348
  for (const [n, r] of Object.entries(e))
@@ -388,37 +357,37 @@ function qn(e) {
388
357
  }
389
358
  return !1;
390
359
  }
391
- function Ms(e) {
360
+ function ws(e) {
392
361
  return et(e) !== void 0 || Le(e, "errors") || Le(e, "details") || Le(e, "detail") || Le(e, "status") || Le(e, "code");
393
362
  }
394
363
  function $n(e, n) {
395
364
  const r = Mt(e);
396
- return r !== void 0 && (Ms(e) || qn(e) || Ss(r, n));
365
+ return r !== void 0 && (ws(e) || qn(e) || ks(r, n));
397
366
  }
398
367
  function Kn(e) {
399
368
  if (!e || typeof e != "object" || Array.isArray(e))
400
369
  return;
401
370
  const n = e;
402
- return Se(n.message) ?? Se(n.error_message);
371
+ return we(n.message) ?? we(n.error_message);
403
372
  }
404
- function Ts(e, n) {
373
+ function Ss(e, n) {
405
374
  if (!e || typeof e != "object" || Array.isArray(e))
406
375
  return;
407
376
  const r = e;
408
377
  return $n(r, n) ? Mt(r) : Kn(r.error);
409
378
  }
410
- function Es(e) {
379
+ function Ms(e) {
411
380
  return Kn(e) !== void 0;
412
381
  }
413
- function Ds(e, n) {
382
+ function Ts(e, n) {
414
383
  if (!n)
415
384
  return e;
416
- const r = `${ks}${n}`;
385
+ const r = `${Ns}${n}`;
417
386
  return !e || e.trim().length === 0 ? r : e.split(`
418
387
  `).includes(r) ? e : `${e}
419
388
  ${r}`;
420
389
  }
421
- function As(e) {
390
+ function Es(e) {
422
391
  if (!e || typeof e != "object")
423
392
  return !1;
424
393
  const n = e;
@@ -432,12 +401,12 @@ function Bn(e, { skipScalarEnvelopeKeys: n }) {
432
401
  for (const [s, o] of Object.entries(a))
433
402
  On(s, o) || n && Ln(s, o) || (Array.isArray(o) && o.length > 0 ? r.push({
434
403
  field: ft(s),
435
- messages: o.map(ws)
404
+ messages: o.map(Cs)
436
405
  }) : typeof o == "string" && o.length > 0 ? r.push({
437
406
  field: ft(s),
438
407
  messages: [o]
439
408
  }) : o && typeof o == "object" && !Array.isArray(o) && Bn(o, {
440
- skipScalarEnvelopeKeys: s === "error" && Es(o)
409
+ skipScalarEnvelopeKeys: s === "error" && Ms(o)
441
410
  }).forEach((c) => {
442
411
  r.push({
443
412
  field: `${ft(s)} → ${c.field}`,
@@ -446,7 +415,7 @@ function Bn(e, { skipScalarEnvelopeKeys: n }) {
446
415
  }));
447
416
  return r;
448
417
  }
449
- function Ps(e) {
418
+ function Ds(e) {
450
419
  if (e.length === 0)
451
420
  return "";
452
421
  if (e.length === 1) {
@@ -463,36 +432,36 @@ function Ps(e) {
463
432
  return `${n}
464
433
  ...and ${r} more ${r === 1 ? "error" : "errors"}`;
465
434
  }
466
- function zs(e, n) {
435
+ function As(e, n) {
467
436
  const r = e && typeof e == "object" && !Array.isArray(e) && $n(
468
437
  e,
469
438
  n
470
439
  ) ? Mt(e) : void 0, a = Bn(e, {
471
440
  skipScalarEnvelopeKeys: r !== void 0
472
- }), s = a.length > 0 ? Ps(a) : void 0, o = Ts(
441
+ }), s = a.length > 0 ? Ds(a) : void 0, o = Ss(
473
442
  e,
474
443
  n
475
444
  );
476
445
  return r && s ? s : o && s && s !== o ? `${o}
477
446
  ${s}` : s ?? o;
478
447
  }
479
- function Fs(e) {
448
+ function Ps(e) {
480
449
  if (!e || typeof e != "object")
481
450
  return;
482
451
  const n = e;
483
- return ke(n.requestId) ?? ke(n.request_id) ?? // `request_id` and `meta` are envelope keys, so they survive on `body`.
452
+ return Ce(n.requestId) ?? Ce(n.request_id) ?? // `request_id` and `meta` are envelope keys, so they survive on `body`.
484
453
  // `data` only carries them when the body had no `errors` key to unwrap.
485
454
  et(n.body) ?? et(n.data);
486
455
  }
487
456
  function V(e, n) {
488
- const r = Fs(e);
457
+ const r = Ps(e);
489
458
  let a;
490
- return As(e) ? (e.data && (a = zs(e.data, e.message)), !a && e.message && (a = e.message)) : e instanceof Error && (a = e.message), Ds(a ?? n, r);
459
+ return Es(e) ? (e.data && (a = As(e.data, e.message)), !a && e.message && (a = e.message)) : e instanceof Error && (a = e.message), Ts(a ?? n, r);
491
460
  }
492
461
  function Kt(e) {
493
462
  return Er(Dr, e);
494
463
  }
495
- const Un = i.createContext(null), Rs = Un.Provider;
464
+ const Un = i.createContext(null), zs = Un.Provider;
496
465
  function ot() {
497
466
  const e = i.use(Un);
498
467
  if (!e)
@@ -507,13 +476,13 @@ function xe() {
507
476
  function it() {
508
477
  return ot().notes;
509
478
  }
510
- function Ye() {
479
+ function Qe() {
511
480
  return ot().tasks;
512
481
  }
513
482
  function lt() {
514
483
  return ot().groups ?? null;
515
484
  }
516
- function Is(e) {
485
+ function Fs(e) {
517
486
  return e instanceof DOMException && e.name === "AbortError" || e instanceof Error && e.name === "AbortError";
518
487
  }
519
488
  function Gn(e) {
@@ -537,11 +506,11 @@ function Gn(e) {
537
506
  onResponseError: (r) => {
538
507
  r.status === 401 && e.onAuthError?.();
539
508
  },
540
- shouldPassThroughTransportError: Is
509
+ shouldPassThroughTransportError: Fs
541
510
  })
542
511
  ), n;
543
512
  }
544
- const Os = (e) => e.client.get({
513
+ const Rs = (e) => e.client.get({
545
514
  responseStyle: "data",
546
515
  security: [
547
516
  {
@@ -552,7 +521,7 @@ const Os = (e) => e.client.get({
552
521
  ],
553
522
  url: "/api/contacts",
554
523
  ...e
555
- }), Ls = (e) => e.client.post({
524
+ }), Is = (e) => e.client.post({
556
525
  responseStyle: "data",
557
526
  security: [
558
527
  {
@@ -567,7 +536,7 @@ const Os = (e) => e.client.get({
567
536
  "Content-Type": "application/json",
568
537
  ...e.headers
569
538
  }
570
- }), qs = (e) => e.client.delete({
539
+ }), Os = (e) => e.client.delete({
571
540
  responseStyle: "data",
572
541
  security: [
573
542
  {
@@ -578,7 +547,7 @@ const Os = (e) => e.client.get({
578
547
  ],
579
548
  url: "/api/contacts/{id}",
580
549
  ...e
581
- }), $s = (e) => e.client.get({
550
+ }), Ls = (e) => e.client.get({
582
551
  responseStyle: "data",
583
552
  security: [
584
553
  {
@@ -589,7 +558,7 @@ const Os = (e) => e.client.get({
589
558
  ],
590
559
  url: "/api/contacts/{id}",
591
560
  ...e
592
- }), Ks = (e) => e.client.patch({
561
+ }), qs = (e) => e.client.patch({
593
562
  responseStyle: "data",
594
563
  security: [
595
564
  {
@@ -604,7 +573,7 @@ const Os = (e) => e.client.get({
604
573
  "Content-Type": "application/json",
605
574
  ...e.headers
606
575
  }
607
- }), Bs = (e) => e.client.delete({
576
+ }), $s = (e) => e.client.delete({
608
577
  responseStyle: "data",
609
578
  security: [
610
579
  {
@@ -619,7 +588,7 @@ const Os = (e) => e.client.get({
619
588
  "Content-Type": "application/json",
620
589
  ...e.headers
621
590
  }
622
- }), Us = (e) => e.client.get({
591
+ }), Ks = (e) => e.client.get({
623
592
  responseStyle: "data",
624
593
  security: [
625
594
  {
@@ -630,7 +599,7 @@ const Os = (e) => e.client.get({
630
599
  ],
631
600
  url: "/api/contacts/groups",
632
601
  ...e
633
- }), Gs = (e) => e.client.post({
602
+ }), Bs = (e) => e.client.post({
634
603
  responseStyle: "data",
635
604
  security: [
636
605
  {
@@ -645,7 +614,7 @@ const Os = (e) => e.client.get({
645
614
  "Content-Type": "application/json",
646
615
  ...e.headers
647
616
  }
648
- }), Hs = (e) => e.client.delete({
617
+ }), Us = (e) => e.client.delete({
649
618
  responseStyle: "data",
650
619
  security: [
651
620
  {
@@ -656,7 +625,7 @@ const Os = (e) => e.client.get({
656
625
  ],
657
626
  url: "/api/contacts/groups/{id}",
658
627
  ...e
659
- }), Ys = (e) => e.client.patch({
628
+ }), Gs = (e) => e.client.patch({
660
629
  responseStyle: "data",
661
630
  security: [
662
631
  {
@@ -671,7 +640,7 @@ const Os = (e) => e.client.get({
671
640
  "Content-Type": "application/json",
672
641
  ...e.headers
673
642
  }
674
- }), Qs = (e) => e.client.get({
643
+ }), Hs = (e) => e.client.get({
675
644
  responseStyle: "data",
676
645
  security: [
677
646
  {
@@ -682,7 +651,7 @@ const Os = (e) => e.client.get({
682
651
  ],
683
652
  url: "/api/contacts/{contact_id}/notes",
684
653
  ...e
685
- }), Vs = (e) => e.client.post({
654
+ }), Qs = (e) => e.client.post({
686
655
  responseStyle: "data",
687
656
  security: [
688
657
  {
@@ -697,7 +666,7 @@ const Os = (e) => e.client.get({
697
666
  "Content-Type": "application/json",
698
667
  ...e.headers
699
668
  }
700
- }), Ws = (e) => e.client.get({
669
+ }), Ys = (e) => e.client.get({
701
670
  responseStyle: "data",
702
671
  security: [
703
672
  {
@@ -708,7 +677,7 @@ const Os = (e) => e.client.get({
708
677
  ],
709
678
  url: "/api/contacts/{contact_id}/tasks",
710
679
  ...e
711
- }), Xs = (e) => e.client.post({
680
+ }), Vs = (e) => e.client.post({
712
681
  responseStyle: "data",
713
682
  security: [
714
683
  {
@@ -723,7 +692,7 @@ const Os = (e) => e.client.get({
723
692
  "Content-Type": "application/json",
724
693
  ...e.headers
725
694
  }
726
- }), Zs = (e) => e.client.delete({
695
+ }), Ws = (e) => e.client.delete({
727
696
  responseStyle: "data",
728
697
  security: [
729
698
  {
@@ -734,7 +703,7 @@ const Os = (e) => e.client.get({
734
703
  ],
735
704
  url: "/api/contacts/{contact_id}/notes/{id}",
736
705
  ...e
737
- }), Js = (e) => e.client.patch({
706
+ }), Xs = (e) => e.client.patch({
738
707
  responseStyle: "data",
739
708
  security: [
740
709
  {
@@ -749,7 +718,7 @@ const Os = (e) => e.client.get({
749
718
  "Content-Type": "application/json",
750
719
  ...e.headers
751
720
  }
752
- }), eo = (e) => e.client.delete({
721
+ }), Zs = (e) => e.client.delete({
753
722
  responseStyle: "data",
754
723
  security: [
755
724
  {
@@ -760,7 +729,7 @@ const Os = (e) => e.client.get({
760
729
  ],
761
730
  url: "/api/contacts/{contact_id}/tasks/{id}",
762
731
  ...e
763
- }), to = (e) => e.client.patch({
732
+ }), Js = (e) => e.client.patch({
764
733
  responseStyle: "data",
765
734
  security: [
766
735
  {
@@ -775,7 +744,7 @@ const Os = (e) => e.client.get({
775
744
  "Content-Type": "application/json",
776
745
  ...e.headers
777
746
  }
778
- }), no = {
747
+ }), eo = {
779
748
  total_count: 0,
780
749
  total_pages: 0,
781
750
  current_page: 1,
@@ -785,7 +754,7 @@ function ce(e) {
785
754
  return Number(e);
786
755
  }
787
756
  function Bt(e, n, r, a) {
788
- if (!e) return no;
757
+ if (!e) return eo;
789
758
  const s = e.pagination?.next_cursor ?? null, o = e.total_count ?? (s ? (r + 1) * a : (r - 1) * a + n);
790
759
  return {
791
760
  total_count: o,
@@ -818,7 +787,7 @@ function Ut(e) {
818
787
  updated_at: e.updated_at ?? ""
819
788
  };
820
789
  }
821
- function ro(e) {
790
+ function to(e) {
822
791
  return {
823
792
  id: e.id ?? 0,
824
793
  title: e.title ?? "",
@@ -833,7 +802,7 @@ function ro(e) {
833
802
  assets: []
834
803
  };
835
804
  }
836
- function ao(e) {
805
+ function no(e) {
837
806
  const n = e;
838
807
  return {
839
808
  id: e.id ?? 0,
@@ -856,22 +825,22 @@ function gt(e) {
856
825
  };
857
826
  }
858
827
  const Gt = /* @__PURE__ */ new WeakMap();
859
- function so(e) {
828
+ function ro(e) {
860
829
  return JSON.stringify({
861
830
  limit: e?.per_page ?? e?.limit ?? null,
862
831
  search: e?.search_query ?? e?.search ?? e?.query ?? null,
863
832
  tags: e?.tags ?? null
864
833
  });
865
834
  }
866
- function oo(e, n) {
835
+ function ao(e, n) {
867
836
  let r = Gt.get(e);
868
837
  r || (r = /* @__PURE__ */ new Map(), Gt.set(e, r));
869
- const a = so(n), s = r.get(a);
838
+ const a = ro(n), s = r.get(a);
870
839
  if (s) return s;
871
840
  const o = /* @__PURE__ */ new Map();
872
841
  return r.set(a, o), o;
873
842
  }
874
- function io(e, n) {
843
+ function so(e, n) {
875
844
  if (!e) return;
876
845
  const r = typeof e.page == "number" ? e.page : 1, a = e.per_page ?? e.limit, s = e.search_query ?? e.search ?? e.query, o = Array.isArray(e.tags) ? e.tags.filter((c) => typeof c == "string") : void 0, l = r > 1 ? n.get(r) : void 0;
877
846
  return r > 1 && l === void 0 ? null : {
@@ -881,23 +850,23 @@ function io(e, n) {
881
850
  ...o ? { tags: o } : {}
882
851
  };
883
852
  }
884
- function lo(e) {
853
+ function oo(e) {
885
854
  return {
886
855
  getContact: async (n) => {
887
- const r = await $s({
856
+ const r = await Ls({
888
857
  client: e,
889
858
  path: { id: ce(n) }
890
859
  });
891
860
  return { contact: Ut(r.contact ?? {}) };
892
861
  },
893
862
  listContacts: async (n) => {
894
- const r = typeof n?.page == "number" ? n.page : 1, a = typeof n?.per_page == "number" ? n.per_page : 25, s = oo(e, n), o = io(n, s);
863
+ const r = typeof n?.page == "number" ? n.page : 1, a = typeof n?.per_page == "number" ? n.per_page : 25, s = ao(e, n), o = so(n, s);
895
864
  if (o === null)
896
865
  return {
897
866
  contacts: [],
898
867
  meta: Bt(void 0, 0, r, a)
899
868
  };
900
- const l = await Os({
869
+ const l = await Rs({
901
870
  client: e,
902
871
  ...o ? { query: o } : {}
903
872
  }), c = l.meta?.pagination?.next_cursor;
@@ -908,53 +877,53 @@ function lo(e) {
908
877
  meta: Bt(l.meta, d.length, r, a)
909
878
  };
910
879
  },
911
- createContact: (n) => Ls({
880
+ createContact: (n) => Is({
912
881
  client: e,
913
882
  body: { contact: n }
914
883
  }),
915
- updateContact: (n, r) => Ks({
884
+ updateContact: (n, r) => qs({
916
885
  client: e,
917
886
  path: { id: ce(n) },
918
887
  body: { contact: r }
919
888
  }),
920
- deleteContact: (n) => qs({ client: e, path: { id: ce(n) } }),
921
- bulkDeleteContacts: (n) => Bs({ client: e, body: { ids: n } })
889
+ deleteContact: (n) => Os({ client: e, path: { id: ce(n) } }),
890
+ bulkDeleteContacts: (n) => $s({ client: e, body: { ids: n } })
922
891
  };
923
892
  }
924
- function co(e) {
893
+ function io(e) {
925
894
  return {
926
- listNotes: async (n) => ({ notes: ((await Qs({
895
+ listNotes: async (n) => ({ notes: ((await Hs({
927
896
  client: e,
928
897
  path: { contact_id: ce(n) }
929
- })).notes ?? []).map(ro) }),
930
- createNote: (n, r) => Vs({
898
+ })).notes ?? []).map(to) }),
899
+ createNote: (n, r) => Qs({
931
900
  client: e,
932
901
  path: { contact_id: ce(n) },
933
902
  body: { note: { title: r.title, body: r.body } }
934
903
  }),
935
- updateNote: (n, r, a) => Js({
904
+ updateNote: (n, r, a) => Xs({
936
905
  client: e,
937
906
  path: { contact_id: ce(r), id: n },
938
907
  body: { note: { title: a.title, body: a.body } }
939
908
  }),
940
- deleteNote: (n, r) => Zs({
909
+ deleteNote: (n, r) => Ws({
941
910
  client: e,
942
911
  path: { contact_id: ce(r), id: n }
943
912
  })
944
913
  };
945
914
  }
946
- function uo(e) {
915
+ function lo(e) {
947
916
  return {
948
- listTasks: async (n) => ({ tasks: ((await Ws({
917
+ listTasks: async (n) => ({ tasks: ((await Ys({
949
918
  client: e,
950
919
  path: { contact_id: ce(n) }
951
- })).tasks ?? []).map(ao) }),
952
- createTask: (n, r) => Xs({
920
+ })).tasks ?? []).map(no) }),
921
+ createTask: (n, r) => Vs({
953
922
  client: e,
954
923
  path: { contact_id: ce(n) },
955
924
  body: { task: { title: r.body, due_date: r.due_at } }
956
925
  }),
957
- updateTask: (n, r, a) => to({
926
+ updateTask: (n, r, a) => Js({
958
927
  client: e,
959
928
  path: { contact_id: ce(r), id: n },
960
929
  body: {
@@ -965,42 +934,42 @@ function uo(e) {
965
934
  }
966
935
  }
967
936
  }),
968
- deleteTask: (n, r) => eo({
937
+ deleteTask: (n, r) => Zs({
969
938
  client: e,
970
939
  path: { contact_id: ce(r), id: n }
971
940
  })
972
941
  };
973
942
  }
974
- function mo(e) {
943
+ function co(e) {
975
944
  return {
976
- listGroups: async () => ({ groups: ((await Us({ client: e })).groups ?? []).map(gt) }),
945
+ listGroups: async () => ({ groups: ((await Ks({ client: e })).groups ?? []).map(gt) }),
977
946
  createGroup: async (n) => {
978
- const r = await Gs({
947
+ const r = await Bs({
979
948
  client: e,
980
949
  body: { group: n }
981
950
  });
982
951
  return { group: gt(r.group ?? {}) };
983
952
  },
984
953
  updateGroup: async (n, r) => {
985
- const a = await Ys({
954
+ const a = await Gs({
986
955
  client: e,
987
956
  path: { id: n },
988
957
  body: { group: r }
989
958
  });
990
959
  return { group: gt(a.group ?? {}) };
991
960
  },
992
- deleteGroup: (n) => Hs({ client: e, path: { id: n } })
961
+ deleteGroup: (n) => Us({ client: e, path: { id: n } })
993
962
  };
994
963
  }
995
964
  function Hn(e) {
996
965
  return {
997
- contacts: lo(e),
998
- notes: co(e),
999
- tasks: uo(e),
1000
- groups: mo(e)
966
+ contacts: oo(e),
967
+ notes: io(e),
968
+ tasks: lo(e),
969
+ groups: co(e)
1001
970
  };
1002
971
  }
1003
- function po({
972
+ function uo({
1004
973
  children: e,
1005
974
  api: n
1006
975
  }) {
@@ -1021,9 +990,9 @@ function po({
1021
990
  () => Hn(l),
1022
991
  [l]
1023
992
  );
1024
- return /* @__PURE__ */ t.jsx(Rs, { value: n ?? c, children: e });
993
+ return /* @__PURE__ */ t.jsx(zs, { value: n ?? c, children: e });
1025
994
  }
1026
- const fo = {
995
+ const mo = {
1027
996
  breadcrumb: "Contacts",
1028
997
  breadcrumb_new: "New Contact",
1029
998
  contact_label: "Contact",
@@ -1402,8 +1371,8 @@ const fo = {
1402
1371
  assign_rep_search_placeholder: "Search by name or email...",
1403
1372
  assign_rep_loading: "Loading…",
1404
1373
  assign_rep_no_results: 'No reps found matching "{{term}}"'
1405
- }, go = Rr({
1406
- fallback: fo,
1374
+ }, po = Rr({
1375
+ fallback: mo,
1407
1376
  loaders: {
1408
1377
  ar: () => import("./ar-DT9j-dOi.js").then(
1409
1378
  (e) => e.default
@@ -1509,27 +1478,27 @@ const fo = {
1509
1478
  )
1510
1479
  }
1511
1480
  });
1512
- function ho(e, n) {
1481
+ function fo(e, n) {
1513
1482
  return Fr(e, n);
1514
1483
  }
1515
1484
  const {
1516
- Context: _o,
1517
- Provider: xo,
1518
- useTranslation: bo
1519
- } = Ir("Contacts"), yo = xo, z = bo;
1520
- function Qe() {
1521
- return i.use(_o);
1485
+ Context: go,
1486
+ Provider: ho,
1487
+ useTranslation: _o
1488
+ } = Ir("Contacts"), xo = ho, z = _o;
1489
+ function Ye() {
1490
+ return i.use(go);
1522
1491
  }
1523
- function vo({
1492
+ function bo({
1524
1493
  children: e
1525
1494
  }) {
1526
- const { locale: n } = wt(), r = Or(go, n), a = i.useMemo(
1527
- () => ho(n, r),
1495
+ const { locale: n } = wt(), r = Or(po, n), a = i.useMemo(
1496
+ () => fo(n, r),
1528
1497
  [n, r]
1529
1498
  );
1530
- return /* @__PURE__ */ t.jsx(yo, { value: a, children: e });
1499
+ return /* @__PURE__ */ t.jsx(xo, { value: a, children: e });
1531
1500
  }
1532
- function Yn(e) {
1501
+ function Qn(e) {
1533
1502
  const n = e.indexOf(`
1534
1503
 
1535
1504
  `);
@@ -1538,7 +1507,7 @@ function Yn(e) {
1538
1507
  body: e.slice(n + 2)
1539
1508
  } : { title: e, body: "" };
1540
1509
  }
1541
- function Ee(e, n = /* @__PURE__ */ new Date()) {
1510
+ function Te(e, n = /* @__PURE__ */ new Date()) {
1542
1511
  const r = new Date(n);
1543
1512
  r.setDate(r.getDate() + e);
1544
1513
  const a = r.getFullYear(), s = String(r.getMonth() + 1).padStart(2, "0"), o = String(r.getDate()).padStart(2, "0");
@@ -1553,22 +1522,22 @@ function le(e) {
1553
1522
  const n = typeof e == "string" ? new Date(e) : e;
1554
1523
  return new Date(n.getFullYear(), n.getMonth(), n.getDate());
1555
1524
  }
1556
- const jo = /^\d{4}-\d{2}-\d{2}(?:$|T00:00(?::00(?:\.\d+)?)?(?:[+-]\d{2}:\d{2}|Z)?)$/, Qn = /^\d{4}-\d{2}-\d{2}T(\d{2}):(\d{2})(?::\d{2}(?:\.\d+)?)?(?:[+-]\d{2}:\d{2})?$/;
1525
+ const yo = /^\d{4}-\d{2}-\d{2}(?:$|T00:00(?::00(?:\.\d+)?)?(?:[+-]\d{2}:\d{2}|Z)?)$/, Yn = /^\d{4}-\d{2}-\d{2}T(\d{2}):(\d{2})(?::\d{2}(?:\.\d+)?)?(?:[+-]\d{2}:\d{2})?$/;
1557
1526
  function ct(e) {
1558
- return jo.test(e);
1527
+ return yo.test(e);
1559
1528
  }
1560
1529
  function Vn(e) {
1561
1530
  if (!e) return "";
1562
- if (Qn.test(e))
1531
+ if (Yn.test(e))
1563
1532
  return e.slice(0, 10);
1564
1533
  if (ct(e)) {
1565
1534
  const r = /^(\d{4})-(\d{2})-(\d{2})/.exec(e);
1566
1535
  return r?.[1] && r[2] && r[3] ? `${r[1]}-${r[2]}-${r[3]}` : "";
1567
1536
  }
1568
1537
  const n = new Date(e);
1569
- return Number.isNaN(n.getTime()) ? "" : Ee(0, n);
1538
+ return Number.isNaN(n.getTime()) ? "" : Te(0, n);
1570
1539
  }
1571
- function No(e, n = /* @__PURE__ */ new Date()) {
1540
+ function vo(e, n = /* @__PURE__ */ new Date()) {
1572
1541
  const r = le(e);
1573
1542
  if (Number.isNaN(r.getTime())) return null;
1574
1543
  const a = le(n), s = Date.UTC(r.getFullYear(), r.getMonth(), r.getDate()), o = Date.UTC(
@@ -1590,7 +1559,7 @@ const de = {
1590
1559
  all: (e) => [e],
1591
1560
  list: (e) => [...de.all(e), "list"],
1592
1561
  detail: (e, n) => [...de.all(e), "detail", n]
1593
- }, Y = {
1562
+ }, Q = {
1594
1563
  activities: (e) => ["portal-contacts", "activities", e],
1595
1564
  tasks: (e) => ["portal-contacts", "tasks", e],
1596
1565
  notes: (e) => ["portal-contacts", "notes", e],
@@ -1600,7 +1569,7 @@ const de = {
1600
1569
  groupMembers: (e) => ["portal-contacts", "group-members", e],
1601
1570
  groupAddSearch: (e, n) => ["portal-contacts", "group-add-search", e, n]
1602
1571
  };
1603
- function Co(e) {
1572
+ function jo(e) {
1604
1573
  const n = xe();
1605
1574
  return oa({
1606
1575
  queryKey: [...de.list("contacts"), e],
@@ -1616,14 +1585,14 @@ function Co(e) {
1616
1585
  initialPageParam: 1
1617
1586
  });
1618
1587
  }
1619
- const ko = 30, ht = "12:00", Tt = /^(\d{2}):(\d{2})$/;
1588
+ const No = 30, ht = "12:00", Tt = /^(\d{2}):(\d{2})$/;
1620
1589
  function Et(e) {
1621
1590
  const n = Tt.exec(e), r = n?.[1] ? Number(n[1]) : Number.NaN, a = n?.[2] ? Number(n[2]) : Number.NaN;
1622
1591
  return Number.isInteger(r) && Number.isInteger(a) && r >= 0 && r <= 23 && a >= 0 && a <= 59;
1623
1592
  }
1624
1593
  function Ht(e) {
1625
1594
  if (!e) return "";
1626
- const n = Qn.exec(e);
1595
+ const n = Yn.exec(e);
1627
1596
  if (n?.[1] && n[2]) {
1628
1597
  const a = `${n[1]}:${n[2]}`;
1629
1598
  return Et(a) ? a : "";
@@ -1634,7 +1603,7 @@ function Ht(e) {
1634
1603
  r.getMinutes()
1635
1604
  ).padStart(2, "0")}`;
1636
1605
  }
1637
- function wo(e, n) {
1606
+ function Co(e, n) {
1638
1607
  const r = Tt.exec(e), a = r?.[1] ? Number(r[1]) : Number.NaN, s = r?.[2] ? Number(r[2]) : Number.NaN;
1639
1608
  if (!Et(e)) return e;
1640
1609
  const o = /* @__PURE__ */ new Date();
@@ -1643,11 +1612,11 @@ function wo(e, n) {
1643
1612
  minute: "2-digit"
1644
1613
  }).format(o);
1645
1614
  }
1646
- function So(e) {
1615
+ function ko(e) {
1647
1616
  const n = -e.getTimezoneOffset(), r = n >= 0 ? "+" : "-", a = Math.abs(n), s = String(Math.floor(a / 60)).padStart(2, "0"), o = String(a % 60).padStart(2, "0");
1648
1617
  return `${r}${s}:${o}`;
1649
1618
  }
1650
- function Mo(e, n) {
1619
+ function wo(e, n) {
1651
1620
  if (!e) return null;
1652
1621
  if (Et(n)) {
1653
1622
  const r = /^(\d{4})-(\d{2})-(\d{2})$/.exec(e), a = Tt.exec(n);
@@ -1661,7 +1630,7 @@ function Mo(e, n) {
1661
1630
  0,
1662
1631
  0
1663
1632
  );
1664
- return `${e}T${n}:00${So(s)}`;
1633
+ return `${e}T${n}:00${ko(s)}`;
1665
1634
  }
1666
1635
  }
1667
1636
  return e;
@@ -1686,7 +1655,7 @@ function We({
1686
1655
  }
1687
1656
  );
1688
1657
  }
1689
- function To({
1658
+ function So({
1690
1659
  onSubmit: e,
1691
1660
  isSubmitting: n = !1,
1692
1661
  submitLabel: r,
@@ -1727,7 +1696,7 @@ function To({
1727
1696
  () => m?.replace(/_/g, "-") ?? "en-US",
1728
1697
  [m]
1729
1698
  ), B = i.useMemo(() => b ? b.getTime() < A.getTime() ? A : b : A, [b, A]), T = i.useMemo(() => {
1730
- const w = Ee(1, x), U = Ee(7, x), ne = new Intl.DateTimeFormat(M, {
1699
+ const w = Te(1, x), U = Te(7, x), ne = new Intl.DateTimeFormat(M, {
1731
1700
  weekday: "short"
1732
1701
  }), te = new Intl.DateTimeFormat(M, {
1733
1702
  weekday: "short",
@@ -1783,23 +1752,23 @@ function To({
1783
1752
  };
1784
1753
  }, [M, u]), oe = i.useMemo(() => {
1785
1754
  if (!S) return u("task_select_date");
1786
- const w = No(I, x);
1787
- return w === 0 ? u("quick_today") : w === 1 ? u("quick_tomorrow") : w != null && w >= 2 && w <= ko ? u("task_due_in_days", { count: w }) : dt(I, M);
1788
- }, [I, S, x, M, u]), Te = i.useMemo(
1789
- () => $ ? wo(p, M) : "",
1755
+ const w = vo(I, x);
1756
+ return w === 0 ? u("quick_today") : w === 1 ? u("quick_tomorrow") : w != null && w >= 2 && w <= No ? u("task_due_in_days", { count: w }) : dt(I, M);
1757
+ }, [I, S, x, M, u]), Me = i.useMemo(
1758
+ () => $ ? Co(p, M) : "",
1790
1759
  [p, $, M]
1791
- ), Ne = $ ? `${oe}, ${Te}` : oe, se = () => {
1760
+ ), je = $ ? `${oe}, ${Me}` : oe, se = () => {
1792
1761
  const w = g.trim();
1793
1762
  !w || n || e({
1794
1763
  body: w,
1795
- due_at: v ? Mo(I, p) : o ?? null
1764
+ due_at: v ? wo(I, p) : o ?? null
1796
1765
  });
1797
- }, Ce = g.trim().length > 0 && !n, E = (w) => {
1766
+ }, Ne = g.trim().length > 0 && !n, E = (w) => {
1798
1767
  C(!0), y(w), h((U) => U || ht);
1799
1768
  }, K = () => {
1800
1769
  C(!0), y(null), h(ht), j(!1);
1801
1770
  }, Z = (w) => {
1802
- C(!0), h(w), w && !S && y(Ee(0, x));
1771
+ C(!0), h(w), w && !S && y(Te(0, x));
1803
1772
  };
1804
1773
  return /* @__PURE__ */ t.jsxs("div", { className: "border-border/50 focus-within:border-foreground/30 rounded-xl border p-3 transition-colors", children: [
1805
1774
  /* @__PURE__ */ t.jsxs("div", { className: "flex items-start gap-3", children: [
@@ -1842,18 +1811,18 @@ function To({
1842
1811
  {
1843
1812
  type: "button",
1844
1813
  "aria-label": S ? u("task_custom_date_selected_aria", {
1845
- date: Ne
1814
+ date: je
1846
1815
  }) : u("task_custom_date_aria"),
1847
1816
  className: D(
1848
1817
  "flex shrink-0 items-center gap-1 rounded-full px-3 py-1 text-xs font-medium transition-colors",
1849
1818
  S ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-muted/70"
1850
1819
  ),
1851
1820
  children: [
1852
- /* @__PURE__ */ t.jsx(Me, { className: "size-3", "aria-hidden": "true" }),
1821
+ /* @__PURE__ */ t.jsx(Se, { className: "size-3", "aria-hidden": "true" }),
1853
1822
  /* @__PURE__ */ t.jsx("span", { children: oe }),
1854
1823
  $ && /* @__PURE__ */ t.jsxs("span", { className: "inline-flex items-center gap-0.5 text-current/80", children: [
1855
1824
  /* @__PURE__ */ t.jsx($t, { className: "size-3", "aria-hidden": "true" }),
1856
- /* @__PURE__ */ t.jsx("span", { children: Te })
1825
+ /* @__PURE__ */ t.jsx("span", { children: Me })
1857
1826
  ] })
1858
1827
  ]
1859
1828
  }
@@ -1870,15 +1839,15 @@ function To({
1870
1839
  /* @__PURE__ */ t.jsx(
1871
1840
  We,
1872
1841
  {
1873
- icon: Ya,
1842
+ icon: Ga,
1874
1843
  label: u("quick_today"),
1875
- onSelect: () => E(Ee(0, x))
1844
+ onSelect: () => E(Te(0, x))
1876
1845
  }
1877
1846
  ),
1878
1847
  /* @__PURE__ */ t.jsx(
1879
1848
  We,
1880
1849
  {
1881
- icon: Va,
1850
+ icon: Qa,
1882
1851
  label: u("quick_tomorrow"),
1883
1852
  rightLabel: T.tomorrowLabel,
1884
1853
  onSelect: () => E(T.tomorrow)
@@ -1887,7 +1856,7 @@ function To({
1887
1856
  /* @__PURE__ */ t.jsx(
1888
1857
  We,
1889
1858
  {
1890
- icon: Ia,
1859
+ icon: Ca,
1891
1860
  label: u("task_next_week"),
1892
1861
  rightLabel: T.nextWeekLabel,
1893
1862
  onSelect: () => E(T.nextWeek)
@@ -1896,7 +1865,7 @@ function To({
1896
1865
  /* @__PURE__ */ t.jsx(
1897
1866
  We,
1898
1867
  {
1899
- icon: qa,
1868
+ icon: Oa,
1900
1869
  label: u("task_no_date"),
1901
1870
  onSelect: K
1902
1871
  }
@@ -1915,7 +1884,7 @@ function To({
1915
1884
  onSelect: (w) => {
1916
1885
  if (!w) return;
1917
1886
  const U = le(w);
1918
- U.getTime() < A.getTime() || E(Ee(0, U));
1887
+ U.getTime() < A.getTime() || E(Te(0, U));
1919
1888
  },
1920
1889
  className: "p-0 pt-2",
1921
1890
  classNames: {
@@ -1971,7 +1940,7 @@ function To({
1971
1940
  {
1972
1941
  type: "button",
1973
1942
  onClick: se,
1974
- disabled: !Ce,
1943
+ disabled: !Ne,
1975
1944
  className: "bg-primary text-primary-foreground hover:bg-primary/90 disabled:bg-muted disabled:text-muted-foreground mt-1 -ml-(--row-indent) inline-flex h-10 w-[calc(100%+var(--row-indent))] items-center justify-center rounded-lg text-sm font-semibold transition-colors disabled:cursor-not-allowed sm:mt-0 sm:ml-auto sm:h-auto sm:w-auto sm:shrink-0 sm:gap-1.5 sm:rounded-full sm:px-4 sm:py-1.5 sm:text-xs",
1976
1945
  children: n ? a ?? u("adding") : r ?? u("add_task")
1977
1946
  }
@@ -1979,7 +1948,7 @@ function To({
1979
1948
  ] })
1980
1949
  ] });
1981
1950
  }
1982
- function ze(e) {
1951
+ function Pe(e) {
1983
1952
  e.invalidateQueries({
1984
1953
  queryKey: de.all("contacts")
1985
1954
  }), e.invalidateQueries({
@@ -1988,7 +1957,7 @@ function ze(e) {
1988
1957
  queryKey: ["portal-contacts"]
1989
1958
  });
1990
1959
  }
1991
- function Eo({
1960
+ function Mo({
1992
1961
  onNavigateToList: e,
1993
1962
  onSubmit: n,
1994
1963
  isPending: r,
@@ -2028,7 +1997,7 @@ function Eo({
2028
1997
  function Dt() {
2029
1998
  const e = lt();
2030
1999
  return ve({
2031
- queryKey: Y.groups(),
2000
+ queryKey: Q.groups(),
2032
2001
  queryFn: () => e.listGroups(),
2033
2002
  enabled: !!e,
2034
2003
  select: (n) => n.groups
@@ -2044,7 +2013,7 @@ function Wn(e) {
2044
2013
  const n = e.trim().split(/\s+/), r = n[0]?.[0] ?? "", a = n.length > 1 ? n[n.length - 1]?.[0] ?? "" : "";
2045
2014
  return (r + a).toUpperCase() || "?";
2046
2015
  }
2047
- function Do(e, n) {
2016
+ function To(e, n) {
2048
2017
  const r = typeof e.updated_at == "string" ? e.updated_at : null;
2049
2018
  if (!r) return null;
2050
2019
  const a = new Date(r);
@@ -2065,7 +2034,7 @@ function Do(e, n) {
2065
2034
  const c = Math.floor(l / 365);
2066
2035
  return c === 1 ? n?.("relative_years_ago_one") ?? "1 year ago" : n?.("relative_years_ago_other", { count: String(c) }) ?? `${c} years ago`;
2067
2036
  }
2068
- function Ao({
2037
+ function Eo({
2069
2038
  contact: e,
2070
2039
  isSelected: n,
2071
2040
  highlight: r,
@@ -2173,7 +2142,7 @@ function Ao({
2173
2142
  return;
2174
2143
  }
2175
2144
  l(f);
2176
- }, [a, s, l, f]), Te = i.useCallback(() => oe(), [oe]), Ne = i.useCallback(
2145
+ }, [a, s, l, f]), Me = i.useCallback(() => oe(), [oe]), je = i.useCallback(
2177
2146
  (E) => {
2178
2147
  c?.(E, e);
2179
2148
  },
@@ -2183,7 +2152,7 @@ function Ao({
2183
2152
  E.pointerType !== "mouse" && d?.(e);
2184
2153
  },
2185
2154
  [d, e]
2186
- ), Ce = i.useCallback(() => {
2155
+ ), Ne = i.useCallback(() => {
2187
2156
  a && (s?.(f, !1), u?.(e));
2188
2157
  }, [a, u, s, e, f]);
2189
2158
  return /* @__PURE__ */ t.jsxs("div", { className: "relative overflow-hidden rounded-xl", children: [
@@ -2203,7 +2172,7 @@ function Ao({
2203
2172
  E.stopPropagation();
2204
2173
  },
2205
2174
  onClick: (E) => {
2206
- E.stopPropagation(), Ce();
2175
+ E.stopPropagation(), Ne();
2207
2176
  },
2208
2177
  "aria-label": m("delete_contact_aria", { name: g }),
2209
2178
  children: [
@@ -2216,8 +2185,8 @@ function Ao({
2216
2185
  "div",
2217
2186
  {
2218
2187
  ref: y,
2219
- onClick: Te,
2220
- onContextMenu: Ne,
2188
+ onClick: Me,
2189
+ onContextMenu: je,
2221
2190
  onPointerDown: d ? se : void 0,
2222
2191
  onTouchStart: u ? A : void 0,
2223
2192
  onTouchMove: u ? M : void 0,
@@ -2269,22 +2238,22 @@ function Ao({
2269
2238
  )
2270
2239
  ] });
2271
2240
  }
2272
- function Po({
2241
+ function Do({
2273
2242
  ...e
2274
2243
  }) {
2275
- return /* @__PURE__ */ t.jsx(_s, { "data-slot": "context-menu", ...e });
2244
+ return /* @__PURE__ */ t.jsx(gs, { "data-slot": "context-menu", ...e });
2276
2245
  }
2277
- function zo({
2246
+ function Ao({
2278
2247
  ...e
2279
2248
  }) {
2280
- return /* @__PURE__ */ t.jsx(xs, { "data-slot": "context-menu-trigger", ...e });
2249
+ return /* @__PURE__ */ t.jsx(hs, { "data-slot": "context-menu-trigger", ...e });
2281
2250
  }
2282
- function Fo({
2251
+ function Po({
2283
2252
  className: e,
2284
2253
  ...n
2285
2254
  }) {
2286
2255
  return /* @__PURE__ */ t.jsx(In, { children: /* @__PURE__ */ t.jsx(
2287
- bs,
2256
+ _s,
2288
2257
  {
2289
2258
  "data-slot": "context-menu-content",
2290
2259
  className: D(
@@ -2302,7 +2271,7 @@ function _t({
2302
2271
  ...a
2303
2272
  }) {
2304
2273
  return /* @__PURE__ */ t.jsx(
2305
- ys,
2274
+ xs,
2306
2275
  {
2307
2276
  "data-slot": "context-menu-item",
2308
2277
  "data-inset": n,
@@ -2315,12 +2284,12 @@ function _t({
2315
2284
  }
2316
2285
  );
2317
2286
  }
2318
- function Ro({
2287
+ function zo({
2319
2288
  className: e,
2320
2289
  ...n
2321
2290
  }) {
2322
2291
  return /* @__PURE__ */ t.jsx(
2323
- vs,
2292
+ bs,
2324
2293
  {
2325
2294
  "data-slot": "context-menu-separator",
2326
2295
  className: D("bg-border -mx-1 my-1 h-px", e),
@@ -2328,19 +2297,19 @@ function Ro({
2328
2297
  }
2329
2298
  );
2330
2299
  }
2331
- function Io({
2300
+ function Fo({
2332
2301
  ...e
2333
2302
  }) {
2334
- return /* @__PURE__ */ t.jsx(js, { "data-slot": "context-menu-sub", ...e });
2303
+ return /* @__PURE__ */ t.jsx(ys, { "data-slot": "context-menu-sub", ...e });
2335
2304
  }
2336
- function Oo({
2305
+ function Ro({
2337
2306
  className: e,
2338
2307
  inset: n,
2339
2308
  children: r,
2340
2309
  ...a
2341
2310
  }) {
2342
2311
  return /* @__PURE__ */ t.jsxs(
2343
- Ns,
2312
+ vs,
2344
2313
  {
2345
2314
  "data-slot": "context-menu-sub-trigger",
2346
2315
  "data-inset": n,
@@ -2356,12 +2325,12 @@ function Oo({
2356
2325
  }
2357
2326
  );
2358
2327
  }
2359
- function Lo({
2328
+ function Io({
2360
2329
  className: e,
2361
2330
  ...n
2362
2331
  }) {
2363
2332
  return /* @__PURE__ */ t.jsx(In, { children: /* @__PURE__ */ t.jsx(
2364
- Cs,
2333
+ js,
2365
2334
  {
2366
2335
  "data-slot": "context-menu-sub-content",
2367
2336
  className: D(
@@ -2372,16 +2341,16 @@ function Lo({
2372
2341
  }
2373
2342
  ) });
2374
2343
  }
2375
- const Yt = 768;
2344
+ const Qt = 768;
2376
2345
  function Xn() {
2377
2346
  const [e, n] = i.useState(!1);
2378
2347
  return i.useEffect(() => {
2379
- const r = window.matchMedia(`(max-width: ${Yt - 1}px)`), a = () => n(window.innerWidth < Yt);
2348
+ const r = window.matchMedia(`(max-width: ${Qt - 1}px)`), a = () => n(window.innerWidth < Qt);
2380
2349
  return r.addEventListener("change", a), a(), () => r.removeEventListener("change", a);
2381
2350
  }, []), e;
2382
2351
  }
2383
- const qo = 200;
2384
- function $o() {
2352
+ const Oo = 200;
2353
+ function Lo() {
2385
2354
  const { t: e } = z();
2386
2355
  return i.useMemo(
2387
2356
  () => [
@@ -2400,10 +2369,10 @@ function $o() {
2400
2369
  [e]
2401
2370
  );
2402
2371
  }
2403
- function Ko(e) {
2372
+ function qo(e) {
2404
2373
  return e.kind === "all" ? "all" : e.kind === "status" ? `status:${e.status}` : `group:${e.tag}`;
2405
2374
  }
2406
- function Bo({
2375
+ function $o({
2407
2376
  selectedContactId: e,
2408
2377
  highlightContactId: n,
2409
2378
  onSelect: r,
@@ -2413,7 +2382,7 @@ function Bo({
2413
2382
  highlightGroupName: l,
2414
2383
  onDeleteContact: c
2415
2384
  }) {
2416
- const { t: d } = z(), u = $o(), [m, g] = i.useState(""), [f, _] = i.useState(""), [y, p] = i.useState(
2385
+ const { t: d } = z(), u = Lo(), [m, g] = i.useState(""), [f, _] = i.useState(""), [y, p] = i.useState(
2417
2386
  null
2418
2387
  ), h = i.useCallback(
2419
2388
  (N, J) => p(J ? N : null),
@@ -2425,7 +2394,7 @@ function Bo({
2425
2394
  i.useEffect(() => {
2426
2395
  const N = window.setTimeout(() => {
2427
2396
  _(m.trim());
2428
- }, qo);
2397
+ }, Oo);
2429
2398
  return () => window.clearTimeout(N);
2430
2399
  }, [m]);
2431
2400
  const { data: A = [] } = Dt(), M = i.useMemo(
@@ -2443,11 +2412,11 @@ function Bo({
2443
2412
  isFetchingNextPage: X,
2444
2413
  hasNextPage: be,
2445
2414
  fetchNextPage: oe,
2446
- isError: Te
2447
- } = Co(M), Ne = i.useMemo(
2415
+ isError: Me
2416
+ } = jo(M), je = i.useMemo(
2448
2417
  () => B?.pages.flatMap((N) => N.contacts ?? []) ?? [],
2449
2418
  [B]
2450
- ), se = i.useMemo(() => C.kind === "status" ? Ne.filter((N) => N.status === C.status) : Ne, [Ne, C]), Ce = i.useRef(null), E = i.useRef(!1);
2419
+ ), se = i.useMemo(() => C.kind === "status" ? je.filter((N) => N.status === C.status) : je, [je, C]), Ne = i.useRef(null), E = i.useRef(!1);
2451
2420
  i.useEffect(() => {
2452
2421
  if (E.current) return;
2453
2422
  if (e) {
@@ -2462,14 +2431,14 @@ function Bo({
2462
2431
  const J = se[0];
2463
2432
  J && (E.current = !0, r(String(J.id)));
2464
2433
  }, [e, T, se, r]), i.useEffect(() => {
2465
- const N = Ce.current;
2434
+ const N = Ne.current;
2466
2435
  if (!N || !be) return;
2467
2436
  const J = new IntersectionObserver((G) => {
2468
2437
  G[0]?.isIntersecting && !X && oe();
2469
2438
  });
2470
2439
  return J.observe(N), () => J.disconnect();
2471
2440
  }, [be, X, oe]);
2472
- const K = Ko(C), Z = i.useCallback(
2441
+ const K = qo(C), Z = i.useCallback(
2473
2442
  (N, J) => {
2474
2443
  x(String(J.id)), L && (N.preventDefault(), R(!0));
2475
2444
  },
@@ -2503,7 +2472,7 @@ function Bo({
2503
2472
  });
2504
2473
  });
2505
2474
  Promise.allSettled(Ft).then((ye) => {
2506
- ze(b);
2475
+ Pe(b);
2507
2476
  const Re = ye.filter((lr) => lr.status === "rejected").length, mt = G.length - Re;
2508
2477
  Re === 0 ? O({
2509
2478
  title: mt === 1 ? d("contacts_added_to_group_one", {
@@ -2550,7 +2519,7 @@ function Bo({
2550
2519
  ] })
2551
2520
  ] }) }),
2552
2521
  /* @__PURE__ */ t.jsx(
2553
- Uo,
2522
+ Ko,
2554
2523
  {
2555
2524
  activeId: K,
2556
2525
  builtInFilters: u,
@@ -2562,17 +2531,17 @@ function Bo({
2562
2531
  }
2563
2532
  ),
2564
2533
  /* @__PURE__ */ t.jsxs("div", { className: "flex-1 overflow-y-auto px-3 pb-8", children: [
2565
- Te ? /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground px-4 py-8 text-center text-sm", children: d("error_loading_list") }) : T ? /* @__PURE__ */ t.jsx(Go, {}) : se.length === 0 ? (
2534
+ Me ? /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground px-4 py-8 text-center text-sm", children: d("error_loading_list") }) : T ? /* @__PURE__ */ t.jsx(Bo, {}) : se.length === 0 ? (
2566
2535
  // Status filters apply client-side, so an empty visible list with
2567
2536
  // more pages still pending means matching contacts may be on later
2568
2537
  // pages. Keep the sentinel mounted so the IntersectionObserver can
2569
2538
  // continue paging until we either find matches or exhaust the data.
2570
2539
  /* @__PURE__ */ t.jsxs("div", { className: "space-y-2", children: [
2571
2540
  be || X ? /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground px-4 py-8 text-center text-sm", children: d("searching") }) : /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground px-4 py-8 text-center text-sm", children: f ? d("no_contacts_search", { term: f }) : C.kind === "all" ? d("no_contacts_yet") : d("no_contacts_filter") }),
2572
- be && /* @__PURE__ */ t.jsx("div", { ref: Ce, "aria-hidden": "true", className: "h-4" })
2541
+ be && /* @__PURE__ */ t.jsx("div", { ref: Ne, "aria-hidden": "true", className: "h-4" })
2573
2542
  ] })
2574
2543
  ) : /* @__PURE__ */ t.jsxs(
2575
- Po,
2544
+ Do,
2576
2545
  {
2577
2546
  onOpenChange: (N) => {
2578
2547
  if (N) {
@@ -2586,9 +2555,9 @@ function Bo({
2586
2555
  x(null);
2587
2556
  },
2588
2557
  children: [
2589
- /* @__PURE__ */ t.jsx(zo, { asChild: !0, children: /* @__PURE__ */ t.jsxs("div", { className: "space-y-1", children: [
2558
+ /* @__PURE__ */ t.jsx(Ao, { asChild: !0, children: /* @__PURE__ */ t.jsxs("div", { className: "space-y-1", children: [
2590
2559
  se.map((N) => /* @__PURE__ */ t.jsx(
2591
- Ao,
2560
+ Eo,
2592
2561
  {
2593
2562
  contact: N,
2594
2563
  isSelected: String(N.id) === e,
@@ -2603,16 +2572,16 @@ function Bo({
2603
2572
  },
2604
2573
  N.id
2605
2574
  )),
2606
- /* @__PURE__ */ t.jsx("div", { ref: Ce, "aria-hidden": "true", className: "h-4" }),
2575
+ /* @__PURE__ */ t.jsx("div", { ref: Ne, "aria-hidden": "true", className: "h-4" }),
2607
2576
  X && /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground py-3 text-center text-xs", children: d("loading_more") })
2608
2577
  ] }) }),
2609
- !L && /* @__PURE__ */ t.jsxs(Fo, { className: "min-w-48", children: [
2610
- /* @__PURE__ */ t.jsxs(Io, { children: [
2611
- /* @__PURE__ */ t.jsxs(Oo, { children: [
2612
- /* @__PURE__ */ t.jsx(we, { className: "size-4", "aria-hidden": "true" }),
2578
+ !L && /* @__PURE__ */ t.jsxs(Po, { className: "min-w-48", children: [
2579
+ /* @__PURE__ */ t.jsxs(Fo, { children: [
2580
+ /* @__PURE__ */ t.jsxs(Ro, { children: [
2581
+ /* @__PURE__ */ t.jsx(ke, { className: "size-4", "aria-hidden": "true" }),
2613
2582
  d("groups_add_to_group")
2614
2583
  ] }),
2615
- /* @__PURE__ */ t.jsx(Lo, { children: A.length === 0 ? /* @__PURE__ */ t.jsx(_t, { disabled: !0, children: d("groups_no_groups_yet") }) : A.map((N) => /* @__PURE__ */ t.jsxs(
2584
+ /* @__PURE__ */ t.jsx(Io, { children: A.length === 0 ? /* @__PURE__ */ t.jsx(_t, { disabled: !0, children: d("groups_no_groups_yet") }) : A.map((N) => /* @__PURE__ */ t.jsxs(
2616
2585
  _t,
2617
2586
  {
2618
2587
  onSelect: () => te(N.name),
@@ -2625,7 +2594,7 @@ function Bo({
2625
2594
  backgroundColor: N.avatar_background ?? "var(--color-muted)"
2626
2595
  },
2627
2596
  "aria-hidden": "true",
2628
- children: N.avatar ?? /* @__PURE__ */ t.jsx(we, { className: "text-muted-foreground size-3" })
2597
+ children: N.avatar ?? /* @__PURE__ */ t.jsx(ke, { className: "text-muted-foreground size-3" })
2629
2598
  }
2630
2599
  ),
2631
2600
  N.name
@@ -2635,7 +2604,7 @@ function Bo({
2635
2604
  )) })
2636
2605
  ] }),
2637
2606
  c && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
2638
- /* @__PURE__ */ t.jsx(Ro, {}),
2607
+ /* @__PURE__ */ t.jsx(zo, {}),
2639
2608
  /* @__PURE__ */ t.jsxs(
2640
2609
  _t,
2641
2610
  {
@@ -2704,7 +2673,7 @@ function Bo({
2704
2673
  backgroundColor: N.avatar_background ?? "var(--color-muted)"
2705
2674
  },
2706
2675
  "aria-hidden": "true",
2707
- children: N.avatar ?? /* @__PURE__ */ t.jsx(we, { className: "text-muted-foreground size-4" })
2676
+ children: N.avatar ?? /* @__PURE__ */ t.jsx(ke, { className: "text-muted-foreground size-4" })
2708
2677
  }
2709
2678
  ),
2710
2679
  N.name
@@ -2717,7 +2686,7 @@ function Bo({
2717
2686
  ] })
2718
2687
  ] });
2719
2688
  }
2720
- function Uo({
2689
+ function Ko({
2721
2690
  activeId: e,
2722
2691
  builtInFilters: n,
2723
2692
  groups: r,
@@ -2805,7 +2774,7 @@ function Uo({
2805
2774
  ) }),
2806
2775
  /* @__PURE__ */ t.jsxs(st, { align: "end", children: [
2807
2776
  s && /* @__PURE__ */ t.jsxs($e, { onClick: s, children: [
2808
- /* @__PURE__ */ t.jsx(ga, { className: "size-4", "aria-hidden": "true" }),
2777
+ /* @__PURE__ */ t.jsx(ma, { className: "size-4", "aria-hidden": "true" }),
2809
2778
  c("groups_manage_title")
2810
2779
  ] }),
2811
2780
  o && /* @__PURE__ */ t.jsxs($e, { onClick: o, children: [
@@ -2817,24 +2786,24 @@ function Uo({
2817
2786
  ] })
2818
2787
  ] });
2819
2788
  }
2820
- function Go() {
2789
+ function Bo() {
2821
2790
  return /* @__PURE__ */ t.jsx("div", { className: "space-y-1.5 px-1", children: [0, 1, 2, 3, 4].map((e) => /* @__PURE__ */ t.jsxs(
2822
2791
  "div",
2823
2792
  {
2824
2793
  className: "flex items-center gap-3 rounded-xl p-3",
2825
2794
  "aria-hidden": "true",
2826
2795
  children: [
2827
- /* @__PURE__ */ t.jsx(De, { className: "size-12 shrink-0 rounded-xl" }),
2796
+ /* @__PURE__ */ t.jsx(Ee, { className: "size-12 shrink-0 rounded-xl" }),
2828
2797
  /* @__PURE__ */ t.jsxs("div", { className: "flex-1 space-y-2", children: [
2829
- /* @__PURE__ */ t.jsx(De, { className: "h-3.5 w-3/5" }),
2830
- /* @__PURE__ */ t.jsx(De, { className: "h-3 w-4/5" })
2798
+ /* @__PURE__ */ t.jsx(Ee, { className: "h-3.5 w-3/5" }),
2799
+ /* @__PURE__ */ t.jsx(Ee, { className: "h-3 w-4/5" })
2831
2800
  ] })
2832
2801
  ]
2833
2802
  },
2834
2803
  e
2835
2804
  )) });
2836
2805
  }
2837
- const Ho = {
2806
+ const Uo = {
2838
2807
  label_first_name: "First Name",
2839
2808
  label_last_name: "Last Name",
2840
2809
  label_email: "Email",
@@ -2861,14 +2830,14 @@ const Ho = {
2861
2830
  status_cold: "Cold",
2862
2831
  status_lead: "Lead",
2863
2832
  status_customer: "Customer"
2864
- }, Yo = [], Qo = [
2833
+ }, Go = [], Ho = [
2865
2834
  "new",
2866
2835
  "active",
2867
2836
  "inactive",
2868
2837
  "cold",
2869
2838
  "lead",
2870
2839
  "customer"
2871
- ], Vo = {
2840
+ ], Qo = {
2872
2841
  new: "status_new",
2873
2842
  active: "status_active",
2874
2843
  inactive: "status_inactive",
@@ -2877,17 +2846,17 @@ const Ho = {
2877
2846
  customer: "status_customer"
2878
2847
  }, vt = ({
2879
2848
  className: e,
2880
- countries: n = Yo,
2849
+ countries: n = Go,
2881
2850
  renderAvatarPicker: r
2882
2851
  }) => {
2883
- const { control: a, watch: s, setValue: o } = hr(), l = Qe(), c = i.useCallback(
2852
+ const { control: a, watch: s, setValue: o } = hr(), l = Ye(), c = i.useCallback(
2884
2853
  (p, h) => {
2885
2854
  if (l)
2886
2855
  return l.t(
2887
2856
  p,
2888
2857
  h
2889
2858
  );
2890
- let v = Ho[p] ?? p;
2859
+ let v = Uo[p] ?? p;
2891
2860
  if (h)
2892
2861
  for (const [C, k] of Object.entries(h))
2893
2862
  v = v.replaceAll(`{{${C}}}`, k);
@@ -2895,8 +2864,8 @@ const Ho = {
2895
2864
  },
2896
2865
  [l]
2897
2866
  ), d = _r({ control: a, name: "status" }), u = s("avatar_url") ?? null, m = i.useMemo(
2898
- () => Qo.map((p) => ({
2899
- name: c(Vo[p]),
2867
+ () => Ho.map((p) => ({
2868
+ name: c(Qo[p]),
2900
2869
  value: p
2901
2870
  })),
2902
2871
  [c]
@@ -3011,15 +2980,15 @@ const Ho = {
3011
2980
  name: "status",
3012
2981
  render: ({ field: p }) => /* @__PURE__ */ t.jsxs(me, { children: [
3013
2982
  /* @__PURE__ */ t.jsx(pe, { className: "font-inter text-foreground font-medium", children: c("label_status") }),
3014
- /* @__PURE__ */ t.jsxs(ba, { value: p.value ?? "", onValueChange: p.onChange, children: [
3015
- /* @__PURE__ */ t.jsx(fe, { children: /* @__PURE__ */ t.jsx(ya, { className: "w-full", children: /* @__PURE__ */ t.jsx(va, { placeholder: c("placeholder_status") }) }) }),
2983
+ /* @__PURE__ */ t.jsxs(ia, { value: p.value ?? "", onValueChange: p.onChange, children: [
2984
+ /* @__PURE__ */ t.jsx(fe, { children: /* @__PURE__ */ t.jsx(la, { className: "w-full", children: /* @__PURE__ */ t.jsx(ca, { placeholder: c("placeholder_status") }) }) }),
3016
2985
  /* @__PURE__ */ t.jsx(
3017
- ja,
2986
+ da,
3018
2987
  {
3019
2988
  position: "popper",
3020
2989
  sideOffset: 4,
3021
2990
  className: "z-[1060]",
3022
- children: g.map((h) => /* @__PURE__ */ t.jsx(Na, { value: h.value, children: h.name }, h.value))
2991
+ children: g.map((h) => /* @__PURE__ */ t.jsx(ua, { value: h.value, children: h.name }, h.value))
3023
2992
  }
3024
2993
  )
3025
2994
  ] }),
@@ -3115,7 +3084,7 @@ const Ho = {
3115
3084
  render: ({ field: p }) => /* @__PURE__ */ t.jsxs(me, { children: [
3116
3085
  /* @__PURE__ */ t.jsx(pe, { className: "font-inter text-foreground font-medium", children: c("label_country") }),
3117
3086
  /* @__PURE__ */ t.jsx(fe, { children: /* @__PURE__ */ t.jsx(
3118
- Ca,
3087
+ ka,
3119
3088
  {
3120
3089
  options: n.map((h) => ({
3121
3090
  label: h.name,
@@ -3134,7 +3103,7 @@ const Ho = {
3134
3103
  ] })
3135
3104
  ] });
3136
3105
  };
3137
- function Wo(e, n = "contacts") {
3106
+ function Yo(e, n = "contacts") {
3138
3107
  const r = xe();
3139
3108
  return ve({
3140
3109
  queryKey: de.detail(n, e),
@@ -3142,7 +3111,7 @@ function Wo(e, n = "contacts") {
3142
3111
  enabled: !!e
3143
3112
  });
3144
3113
  }
3145
- function Xo(e = "contacts", n) {
3114
+ function Vo(e = "contacts", n) {
3146
3115
  const r = W(), a = xe();
3147
3116
  return re({
3148
3117
  mutationFn: ({ id: s, data: o }) => a.updateContact(s, o),
@@ -3156,9 +3125,9 @@ function Xo(e = "contacts", n) {
3156
3125
  }
3157
3126
  });
3158
3127
  }
3159
- function Zo(e, n = "contacts", r) {
3160
- const a = Qe();
3161
- return Xo(n, {
3128
+ function Wo(e, n = "contacts", r) {
3129
+ const a = Ye();
3130
+ return Vo(n, {
3162
3131
  onSuccess: () => {
3163
3132
  O({
3164
3133
  title: a?.t("contact_updated") ?? "Contact updated successfully",
@@ -3174,7 +3143,7 @@ function Zo(e, n = "contacts", r) {
3174
3143
  }
3175
3144
  });
3176
3145
  }
3177
- function Jo(e = "contacts", n) {
3146
+ function Xo(e = "contacts", n) {
3178
3147
  const r = W(), a = xe();
3179
3148
  return re({
3180
3149
  mutationFn: (s) => a.deleteContact(s),
@@ -3188,9 +3157,9 @@ function Jo(e = "contacts", n) {
3188
3157
  }
3189
3158
  });
3190
3159
  }
3191
- function ei(e = "contacts", n) {
3192
- const r = Qe();
3193
- return Jo(e, {
3160
+ function Zo(e = "contacts", n) {
3161
+ const r = Ye();
3162
+ return Xo(e, {
3194
3163
  onSuccess: () => {
3195
3164
  O({
3196
3165
  title: r?.t("contact_deleted") ?? "Contact deleted successfully",
@@ -3228,15 +3197,15 @@ function Zn(e) {
3228
3197
  });
3229
3198
  }
3230
3199
  const Pt = Zn();
3231
- function ti(e) {
3200
+ function Jo(e) {
3232
3201
  return Zn(e).passthrough();
3233
3202
  }
3234
3203
  Pt.passthrough();
3235
- const ni = Object.keys(
3204
+ const ei = Object.keys(
3236
3205
  Pt.shape
3237
3206
  );
3238
- function ri(e, n) {
3239
- const r = Qe(), a = n?.queryKeyPrefix ?? "contacts", { data: s, isLoading: o } = Wo(e, a), { data: l } = ve({
3207
+ function ti(e, n) {
3208
+ const r = Ye(), a = n?.queryKeyPrefix ?? "contacts", { data: s, isLoading: o } = Yo(e, a), { data: l } = ve({
3240
3209
  queryKey: n?.countriesQueryKey ?? ["countries"],
3241
3210
  queryFn: n?.getCountries ?? (() => Promise.resolve([])),
3242
3211
  enabled: !!n?.getCountries
@@ -3255,7 +3224,7 @@ function ri(e, n) {
3255
3224
  country_code: d.country?.iso ?? d.country_id?.toString() ?? null
3256
3225
  };
3257
3226
  }, [d]), m = i.useMemo(
3258
- () => ti(
3227
+ () => Jo(
3259
3228
  r ? {
3260
3229
  first_name_required: r.t("validation_first_name_required"),
3261
3230
  last_name_required: r.t("validation_last_name_required")
@@ -3265,11 +3234,11 @@ function ri(e, n) {
3265
3234
  ), g = pn(m, {
3266
3235
  values: u,
3267
3236
  mode: "onBlur"
3268
- }), f = Zo(e, a, {
3237
+ }), f = Wo(e, a, {
3269
3238
  onSuccess: () => {
3270
3239
  g.reset(g.getValues()), n?.onSaveSuccess?.();
3271
3240
  }
3272
- }), _ = ei(a, {
3241
+ }), _ = Zo(a, {
3273
3242
  onSuccess: () => {
3274
3243
  n?.onDeleteSuccess?.();
3275
3244
  }
@@ -3277,7 +3246,7 @@ function ri(e, n) {
3277
3246
  g.handleSubmit(
3278
3247
  (h) => {
3279
3248
  const v = {};
3280
- for (const C of ni)
3249
+ for (const C of ei)
3281
3250
  C in h && (v[C] = h[C]);
3282
3251
  f.mutate({
3283
3252
  id: e,
@@ -3311,19 +3280,19 @@ function ri(e, n) {
3311
3280
  onDelete: p
3312
3281
  };
3313
3282
  }
3314
- function ai(e) {
3315
- const n = Ye();
3283
+ function ni(e) {
3284
+ const n = Qe();
3316
3285
  return ve({
3317
- queryKey: Y.tasks(e),
3286
+ queryKey: Q.tasks(e),
3318
3287
  queryFn: () => n.listTasks(e),
3319
3288
  enabled: !!e,
3320
3289
  select: (r) => r.tasks
3321
3290
  });
3322
3291
  }
3323
- function si(e) {
3292
+ function ri(e) {
3324
3293
  const n = it();
3325
3294
  return ve({
3326
- queryKey: Y.notes(e),
3295
+ queryKey: Q.notes(e),
3327
3296
  queryFn: () => n.listNotes(e),
3328
3297
  enabled: !!e,
3329
3298
  select: (r) => r.notes
@@ -3337,7 +3306,7 @@ function Jn() {
3337
3306
  return e.createGroup(a);
3338
3307
  },
3339
3308
  onSuccess: () => {
3340
- n.invalidateQueries({ queryKey: Y.groups() });
3309
+ n.invalidateQueries({ queryKey: Q.groups() });
3341
3310
  },
3342
3311
  onError: (a) => {
3343
3312
  O({
@@ -3348,7 +3317,7 @@ function Jn() {
3348
3317
  }
3349
3318
  });
3350
3319
  }
3351
- function oi(e, n = "sdk-contacts", r) {
3320
+ function ai(e, n = "sdk-contacts", r) {
3352
3321
  const a = xe(), s = W();
3353
3322
  return re({
3354
3323
  mutationFn: (o) => a.updateContact(e, { tags: o }),
@@ -3362,7 +3331,7 @@ function oi(e, n = "sdk-contacts", r) {
3362
3331
  onError: r?.onError
3363
3332
  });
3364
3333
  }
3365
- const ii = {
3334
+ const si = {
3366
3335
  // Contact statuses
3367
3336
  new: "border-[var(--status-new-border)] bg-[var(--status-new)] text-[var(--status-new-foreground)]",
3368
3337
  active: "border-[var(--status-active-border)] bg-[var(--status-active)] text-[var(--status-active-foreground)]",
@@ -3377,11 +3346,11 @@ const ii = {
3377
3346
  neutral: "border-border bg-muted text-muted-foreground",
3378
3347
  notice: "border-[var(--badge-notice-border)] bg-[var(--badge-notice)] text-[var(--badge-notice-foreground)]",
3379
3348
  accent: "border-[var(--badge-accent-border)] bg-[var(--badge-accent)] text-[var(--badge-accent-foreground)]"
3380
- }, li = "border-border bg-muted text-muted-foreground";
3381
- function ci(e) {
3382
- return ii[e] ?? li;
3349
+ }, oi = "border-border bg-muted text-muted-foreground";
3350
+ function ii(e) {
3351
+ return si[e] ?? oi;
3383
3352
  }
3384
- function di({
3353
+ function li({
3385
3354
  status: e,
3386
3355
  label: n,
3387
3356
  className: r
@@ -3391,14 +3360,14 @@ function di({
3391
3360
  {
3392
3361
  className: D(
3393
3362
  "inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold capitalize",
3394
- ci(e),
3363
+ ii(e),
3395
3364
  r
3396
3365
  ),
3397
3366
  children: n ?? e
3398
3367
  }
3399
3368
  );
3400
3369
  }
3401
- const ui = [
3370
+ const ci = [
3402
3371
  "Customer",
3403
3372
  "Cold",
3404
3373
  "Hot",
@@ -3406,7 +3375,7 @@ const ui = [
3406
3375
  "Leaders",
3407
3376
  "Pros"
3408
3377
  ];
3409
- function mi({
3378
+ function di({
3410
3379
  contactTags: e,
3411
3380
  availableGroups: n,
3412
3381
  onSave: r,
@@ -3445,7 +3414,7 @@ function mi({
3445
3414
  return b;
3446
3415
  }, [n]), S = i.useMemo(() => {
3447
3416
  const b = n.map((A) => A.name);
3448
- return Array.from(/* @__PURE__ */ new Set([...b, ...ui]));
3417
+ return Array.from(/* @__PURE__ */ new Set([...b, ...ci]));
3449
3418
  }, [n]), L = i.useMemo(() => {
3450
3419
  const b = m.toLowerCase();
3451
3420
  return b ? S.filter((A) => A.toLowerCase().includes(b)) : S;
@@ -3567,7 +3536,7 @@ function mi({
3567
3536
  )
3568
3537
  ] });
3569
3538
  }
3570
- function pi({
3539
+ function ui({
3571
3540
  contact: e,
3572
3541
  tasksCount: n,
3573
3542
  notesCount: r,
@@ -3577,7 +3546,7 @@ function pi({
3577
3546
  onCreateGroup: l,
3578
3547
  isTagsSaving: c
3579
3548
  }) {
3580
- const { t: d } = z(), u = At(e, d), m = e.status?.trim(), g = Do(e, d);
3549
+ const { t: d } = z(), u = At(e, d), m = e.status?.trim(), g = To(e, d);
3581
3550
  return /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col gap-6 md:flex-row md:items-center md:justify-between md:gap-8", children: [
3582
3551
  /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col items-start gap-4 md:flex-row md:items-center md:gap-5", children: [
3583
3552
  /* @__PURE__ */ t.jsx("div", { className: "bg-muted relative flex size-20 shrink-0 items-center justify-center overflow-hidden rounded-2xl md:size-24", children: e.avatar_url ? /* @__PURE__ */ t.jsx(
@@ -3598,9 +3567,9 @@ function pi({
3598
3567
  /* @__PURE__ */ t.jsxs("div", { className: "min-w-0 flex-1", children: [
3599
3568
  /* @__PURE__ */ t.jsx("h2", { className: "text-foreground text-2xl leading-tight font-bold tracking-tight md:text-3xl", children: u }),
3600
3569
  /* @__PURE__ */ t.jsxs("div", { className: "mt-2.5 flex flex-wrap items-center gap-2", children: [
3601
- m && /* @__PURE__ */ t.jsx(di, { status: m }),
3570
+ m && /* @__PURE__ */ t.jsx(li, { status: m }),
3602
3571
  /* @__PURE__ */ t.jsx(
3603
- mi,
3572
+ di,
3604
3573
  {
3605
3574
  contactTags: a,
3606
3575
  availableGroups: s,
@@ -3614,13 +3583,13 @@ function pi({
3614
3583
  ] })
3615
3584
  ] }),
3616
3585
  /* @__PURE__ */ t.jsxs("div", { className: "flex shrink-0 items-center gap-6 md:gap-8", children: [
3617
- /* @__PURE__ */ t.jsx(Qt, { label: d("tab_tasks"), value: n, icon: Ba }),
3586
+ /* @__PURE__ */ t.jsx(Yt, { label: d("tab_tasks"), value: n, icon: $a }),
3618
3587
  /* @__PURE__ */ t.jsx("div", { className: "bg-border h-10 w-px", "aria-hidden": "true" }),
3619
- /* @__PURE__ */ t.jsx(Qt, { label: d("tab_notes"), value: r, icon: ha })
3588
+ /* @__PURE__ */ t.jsx(Yt, { label: d("tab_notes"), value: r, icon: pa })
3620
3589
  ] })
3621
3590
  ] });
3622
3591
  }
3623
- function Qt({ label: e, value: n, icon: r }) {
3592
+ function Yt({ label: e, value: n, icon: r }) {
3624
3593
  return /* @__PURE__ */ t.jsxs("div", { className: "flex flex-col items-start gap-1", children: [
3625
3594
  /* @__PURE__ */ t.jsxs("div", { className: "text-muted-foreground flex items-center gap-1.5", children: [
3626
3595
  /* @__PURE__ */ t.jsx(r, { className: "size-3.5", "aria-hidden": !0 }),
@@ -3629,7 +3598,7 @@ function Qt({ label: e, value: n, icon: r }) {
3629
3598
  /* @__PURE__ */ t.jsx("span", { className: "text-foreground text-2xl font-bold tracking-tight tabular-nums", children: n })
3630
3599
  ] });
3631
3600
  }
3632
- function fi(e) {
3601
+ function mi(e) {
3633
3602
  const n = [
3634
3603
  e.address,
3635
3604
  e.city,
@@ -3638,11 +3607,11 @@ function fi(e) {
3638
3607
  ].filter((r) => !!r?.trim());
3639
3608
  return n.length === 0 ? null : n.join(", ");
3640
3609
  }
3641
- function gi({
3610
+ function pi({
3642
3611
  contact: e,
3643
3612
  onEditEmpty: n
3644
3613
  }) {
3645
- const { t: r } = z(), a = fi(e);
3614
+ const { t: r } = z(), a = mi(e);
3646
3615
  return /* @__PURE__ */ t.jsxs("div", { className: "border-border/50 divide-border/50 mt-6 divide-y overflow-hidden rounded-2xl border", children: [
3647
3616
  /* @__PURE__ */ t.jsx(
3648
3617
  xt,
@@ -3667,7 +3636,7 @@ function gi({
3667
3636
  /* @__PURE__ */ t.jsx(
3668
3637
  xt,
3669
3638
  {
3670
- icon: za,
3639
+ icon: Fa,
3671
3640
  label: r("label_address"),
3672
3641
  value: a,
3673
3642
  href: a ? `https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(a)}` : void 0,
@@ -3753,13 +3722,13 @@ function xt({
3753
3722
  onClick: g,
3754
3723
  "aria-label": u ? l("copied_field", { field: n }) : l("copy_field", { field: n }),
3755
3724
  className: "text-muted-foreground hover:bg-muted hover:text-foreground mr-3 flex size-8 shrink-0 items-center justify-center rounded-md transition-colors",
3756
- children: u ? /* @__PURE__ */ t.jsx(fn, { className: "text-primary size-3.5", "aria-hidden": !0 }) : /* @__PURE__ */ t.jsx(Fa, { className: "size-3.5", "aria-hidden": !0 })
3725
+ children: u ? /* @__PURE__ */ t.jsx(fn, { className: "text-primary size-3.5", "aria-hidden": !0 }) : /* @__PURE__ */ t.jsx(Ra, { className: "size-3.5", "aria-hidden": !0 })
3757
3726
  }
3758
3727
  )
3759
3728
  ] });
3760
3729
  }
3761
- function hi(e) {
3762
- const n = W(), r = Ye(), { t: a } = z();
3730
+ function fi(e) {
3731
+ const n = W(), r = Qe(), { t: a } = z();
3763
3732
  return re({
3764
3733
  mutationFn: ({
3765
3734
  taskId: s,
@@ -3769,7 +3738,7 @@ function hi(e) {
3769
3738
  }),
3770
3739
  onSuccess: () => {
3771
3740
  n.invalidateQueries({
3772
- queryKey: Y.tasks(e)
3741
+ queryKey: Q.tasks(e)
3773
3742
  });
3774
3743
  },
3775
3744
  onError: (s) => {
@@ -3781,13 +3750,13 @@ function hi(e) {
3781
3750
  }
3782
3751
  });
3783
3752
  }
3784
- function _i(e, n) {
3785
- const r = W(), a = Ye(), { t: s } = z();
3753
+ function gi(e, n) {
3754
+ const r = W(), a = Qe(), { t: s } = z();
3786
3755
  return re({
3787
3756
  mutationFn: (o) => a.deleteTask(o, e),
3788
3757
  onSuccess: () => {
3789
3758
  O({ title: s("task_deleted"), type: "success" }), r.invalidateQueries({
3790
- queryKey: Y.tasks(e)
3759
+ queryKey: Q.tasks(e)
3791
3760
  }), n?.onSuccess?.();
3792
3761
  },
3793
3762
  onError: (o) => {
@@ -3799,8 +3768,8 @@ function _i(e, n) {
3799
3768
  }
3800
3769
  });
3801
3770
  }
3802
- function xi(e, n) {
3803
- const r = W(), a = Ye(), { t: s } = z();
3771
+ function hi(e, n) {
3772
+ const r = W(), a = Qe(), { t: s } = z();
3804
3773
  return re({
3805
3774
  mutationFn: ({
3806
3775
  taskId: o,
@@ -3808,7 +3777,7 @@ function xi(e, n) {
3808
3777
  }) => a.updateTask(o, e, l),
3809
3778
  onSuccess: () => {
3810
3779
  O({ title: s("task_updated"), type: "success" }), r.invalidateQueries({
3811
- queryKey: Y.tasks(e)
3780
+ queryKey: Q.tasks(e)
3812
3781
  }), n?.onSuccess?.();
3813
3782
  },
3814
3783
  onError: (o) => {
@@ -3844,7 +3813,7 @@ function Wt(e) {
3844
3813
  }), n.join(`
3845
3814
  `);
3846
3815
  }
3847
- function bi({
3816
+ function _i({
3848
3817
  titlePlaceholder: e,
3849
3818
  bodyPlaceholder: n,
3850
3819
  onChange: r,
@@ -3861,7 +3830,7 @@ function bi({
3861
3830
  p.current = _;
3862
3831
  }, [_]);
3863
3832
  const v = d ? s || o ? `<h1>${s ?? ""}</h1>${o ?? ""}` : void 0 : o || void 0, C = [
3864
- ka.configure({
3833
+ wa.configure({
3865
3834
  heading: d ? !1 : { levels: [] },
3866
3835
  bulletList: {
3867
3836
  keepMarks: !0,
@@ -3872,16 +3841,16 @@ function bi({
3872
3841
  keepAttributes: !1
3873
3842
  }
3874
3843
  }),
3875
- ...d ? [wa.configure({ levels: [1] })] : [],
3876
- Sa.configure({
3844
+ ...d ? [Sa.configure({ levels: [1] })] : [],
3845
+ Ma.configure({
3877
3846
  placeholder: ({ node: S }) => S.type.name === "heading" ? g : f
3878
3847
  }),
3879
- ia.configure({
3848
+ ha.configure({
3880
3849
  types: d ? ["heading", "paragraph"] : ["paragraph"],
3881
3850
  alignments: ["left", "center", "right", "justify"]
3882
3851
  }),
3883
- la
3884
- ], j = Ma({
3852
+ _a
3853
+ ], j = Ta({
3885
3854
  extensions: C,
3886
3855
  content: v ?? (d ? {
3887
3856
  type: "doc",
@@ -3977,7 +3946,7 @@ function bi({
3977
3946
  j?.isActive({ textAlign: "left" }) ? R : F
3978
3947
  ),
3979
3948
  title: m("toolbar_align_left"),
3980
- children: /* @__PURE__ */ t.jsx(Ta, { className: "size-3.5" })
3949
+ children: /* @__PURE__ */ t.jsx(Ea, { className: "size-3.5" })
3981
3950
  }
3982
3951
  ),
3983
3952
  /* @__PURE__ */ t.jsx(
@@ -3990,7 +3959,7 @@ function bi({
3990
3959
  j?.isActive({ textAlign: "center" }) ? R : F
3991
3960
  ),
3992
3961
  title: m("toolbar_align_center"),
3993
- children: /* @__PURE__ */ t.jsx(ca, { className: "size-3.5" })
3962
+ children: /* @__PURE__ */ t.jsx(xa, { className: "size-3.5" })
3994
3963
  }
3995
3964
  ),
3996
3965
  /* @__PURE__ */ t.jsx(
@@ -4003,7 +3972,7 @@ function bi({
4003
3972
  j?.isActive({ textAlign: "right" }) ? R : F
4004
3973
  ),
4005
3974
  title: m("toolbar_align_right"),
4006
- children: /* @__PURE__ */ t.jsx(da, { className: "size-3.5" })
3975
+ children: /* @__PURE__ */ t.jsx(ba, { className: "size-3.5" })
4007
3976
  }
4008
3977
  ),
4009
3978
  /* @__PURE__ */ t.jsx(
@@ -4016,7 +3985,7 @@ function bi({
4016
3985
  j?.isActive({ textAlign: "justify" }) ? R : F
4017
3986
  ),
4018
3987
  title: m("toolbar_justify"),
4019
- children: /* @__PURE__ */ t.jsx(ua, { className: "size-3.5" })
3988
+ children: /* @__PURE__ */ t.jsx(ya, { className: "size-3.5" })
4020
3989
  }
4021
3990
  ),
4022
3991
  I,
@@ -4030,7 +3999,7 @@ function bi({
4030
3999
  j?.isActive("bulletList") ? R : F
4031
4000
  ),
4032
4001
  title: m("toolbar_bullet_list"),
4033
- children: /* @__PURE__ */ t.jsx(Ea, { className: "size-3.5" })
4002
+ children: /* @__PURE__ */ t.jsx(Da, { className: "size-3.5" })
4034
4003
  }
4035
4004
  ),
4036
4005
  /* @__PURE__ */ t.jsx(
@@ -4043,13 +4012,13 @@ function bi({
4043
4012
  j?.isActive("orderedList") ? R : F
4044
4013
  ),
4045
4014
  title: m("toolbar_ordered_list"),
4046
- children: /* @__PURE__ */ t.jsx(Da, { className: "size-3.5" })
4015
+ children: /* @__PURE__ */ t.jsx(Aa, { className: "size-3.5" })
4047
4016
  }
4048
4017
  ),
4049
4018
  l && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
4050
4019
  I,
4051
4020
  _ ? /* @__PURE__ */ t.jsxs("div", { className: "bg-primary/10 flex items-center gap-1 rounded px-2 py-1", children: [
4052
- /* @__PURE__ */ t.jsx(Me, { className: "text-primary size-3.5" }),
4021
+ /* @__PURE__ */ t.jsx(Se, { className: "text-primary size-3.5" }),
4053
4022
  /* @__PURE__ */ t.jsx("span", { className: "text-primary text-xs font-medium", children: dt(_) }),
4054
4023
  /* @__PURE__ */ t.jsx(
4055
4024
  "button",
@@ -4069,7 +4038,7 @@ function bi({
4069
4038
  onClick: () => h.current?.showPicker(),
4070
4039
  className: "text-muted-foreground hover:bg-muted hover:text-foreground flex h-7 cursor-pointer items-center gap-1 rounded px-2 text-xs font-medium transition-colors",
4071
4040
  children: [
4072
- /* @__PURE__ */ t.jsx(Me, { className: "size-3.5" }),
4041
+ /* @__PURE__ */ t.jsx(Se, { className: "size-3.5" }),
4073
4042
  /* @__PURE__ */ t.jsx("span", { children: m("editor_due_date") })
4074
4043
  ]
4075
4044
  }
@@ -4092,7 +4061,7 @@ function bi({
4092
4061
  ] })
4093
4062
  ] }),
4094
4063
  /* @__PURE__ */ t.jsx(
4095
- Aa,
4064
+ Pa,
4096
4065
  {
4097
4066
  editor: j,
4098
4067
  className: u ?? "min-h-[60vh] flex-1 overflow-y-auto p-4"
@@ -4176,7 +4145,7 @@ function er({
4176
4145
  }
4177
4146
  ),
4178
4147
  /* @__PURE__ */ t.jsx(
4179
- bi,
4148
+ _i,
4180
4149
  {
4181
4150
  showTitle: !1,
4182
4151
  bodyPlaceholder: _("editor_start_writing"),
@@ -4188,7 +4157,7 @@ function er({
4188
4157
  }
4189
4158
  ),
4190
4159
  c && /* @__PURE__ */ t.jsx("div", { className: "flex items-center gap-2", children: x ? /* @__PURE__ */ t.jsxs("div", { className: "bg-primary/10 inline-flex items-center gap-1.5 rounded-md px-2.5 py-1.5", children: [
4191
- /* @__PURE__ */ t.jsx(Me, { className: "text-primary size-3.5" }),
4160
+ /* @__PURE__ */ t.jsx(Se, { className: "text-primary size-3.5" }),
4192
4161
  /* @__PURE__ */ t.jsxs("span", { className: "text-primary text-sm font-medium", children: [
4193
4162
  _("activity_due"),
4194
4163
  " ",
@@ -4226,7 +4195,7 @@ function er({
4226
4195
  },
4227
4196
  className: "text-muted-foreground hover:text-foreground hover:bg-muted inline-flex cursor-pointer items-center gap-1.5 rounded-md px-2.5 py-1.5 text-sm font-medium transition-colors",
4228
4197
  children: [
4229
- /* @__PURE__ */ t.jsx(Me, { className: "size-3.5" }),
4198
+ /* @__PURE__ */ t.jsx(Se, { className: "size-3.5" }),
4230
4199
  /* @__PURE__ */ t.jsx("span", { children: _("editor_add_due_date") })
4231
4200
  ]
4232
4201
  }
@@ -4281,14 +4250,14 @@ function er({
4281
4250
  function bt(e, n) {
4282
4251
  return dt(e, n);
4283
4252
  }
4284
- function yi(e, n) {
4253
+ function xi(e, n) {
4285
4254
  const r = new Date(e), s = (/* @__PURE__ */ new Date()).getTime() - r.getTime(), o = Math.floor(s / (1e3 * 60 * 60 * 24));
4286
4255
  return o === 0 ? r.toLocaleTimeString("en-US", {
4287
4256
  hour: "numeric",
4288
4257
  minute: "2-digit"
4289
4258
  }) : o === 1 ? n("task_yesterday") : o === 1 ? n("task_days_ago_one") : n("task_days_ago_other", { count: o });
4290
4259
  }
4291
- function vi(e, n, r, a) {
4260
+ function bi(e, n, r, a) {
4292
4261
  if (n)
4293
4262
  return {
4294
4263
  label: r("task_due", { date: bt(e, a) }),
@@ -4302,20 +4271,20 @@ function vi(e, n, r, a) {
4302
4271
  tone: "overdue"
4303
4272
  } : c === o.getTime() ? { label: r("quick_today"), tone: "today" } : c === l.getTime() ? { label: r("quick_tomorrow"), tone: "tomorrow" } : { label: bt(e, a), tone: "future" };
4304
4273
  }
4305
- const ji = {
4274
+ const yi = {
4306
4275
  overdue: "bg-destructive/10 text-destructive",
4307
4276
  today: "bg-primary/10 text-primary",
4308
4277
  tomorrow: "bg-primary/10 text-primary",
4309
4278
  future: "bg-muted text-muted-foreground",
4310
4279
  done: "bg-muted text-muted-foreground"
4311
4280
  };
4312
- function Ni({
4281
+ function vi({
4313
4282
  task: e,
4314
4283
  toggleCompletion: n,
4315
4284
  onEdit: r,
4316
4285
  onDeleteClick: a
4317
4286
  }) {
4318
- const { t: s, locale: o } = z(), { isMobile: l } = he(), [c, d] = i.useState(!1), u = !!e.completed_at, { title: m, body: g } = Yn(e.body ?? ""), f = e.created_at ? yi(e.created_at, s) : "", _ = e.due_at ? vi(e.due_at, u, s, o) : null;
4287
+ const { t: s, locale: o } = z(), { isMobile: l } = he(), [c, d] = i.useState(!1), u = !!e.completed_at, { title: m, body: g } = Qn(e.body ?? ""), f = e.created_at ? xi(e.created_at, s) : "", _ = e.due_at ? bi(e.due_at, u, s, o) : null;
4319
4288
  return /* @__PURE__ */ t.jsxs(
4320
4289
  "div",
4321
4290
  {
@@ -4371,10 +4340,10 @@ function Ni({
4371
4340
  {
4372
4341
  className: D(
4373
4342
  "inline-flex items-center gap-1 rounded-full px-2 py-0.5 text-xs font-medium",
4374
- ji[_.tone]
4343
+ yi[_.tone]
4375
4344
  ),
4376
4345
  children: [
4377
- /* @__PURE__ */ t.jsx(Me, { className: "size-3", "aria-hidden": "true" }),
4346
+ /* @__PURE__ */ t.jsx(Se, { className: "size-3", "aria-hidden": "true" }),
4378
4347
  _.label
4379
4348
  ]
4380
4349
  }
@@ -4447,14 +4416,14 @@ function Ni({
4447
4416
  }
4448
4417
  );
4449
4418
  }
4450
- function Ci({
4419
+ function ji({
4451
4420
  tasks: e,
4452
4421
  isLoading: n,
4453
4422
  contactId: r
4454
4423
  }) {
4455
- const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(null), [c, d] = i.useState(null), u = hi(r), m = _i(r, {
4424
+ const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(null), [c, d] = i.useState(null), u = fi(r), m = gi(r, {
4456
4425
  onSuccess: () => l(null)
4457
- }), g = xi(r, {
4426
+ }), g = hi(r, {
4458
4427
  onSuccess: () => d(null)
4459
4428
  }), f = (p) => {
4460
4429
  if (!c) return;
@@ -4465,7 +4434,7 @@ ${p.body}` : p.title;
4465
4434
  taskId: c.id,
4466
4435
  input: { body: h, due_at: p.dueDate ?? null }
4467
4436
  });
4468
- }, _ = c ? Yn(c.body ?? "") : null, y = (p) => {
4437
+ }, _ = c ? Qn(c.body ?? "") : null, y = (p) => {
4469
4438
  p || d(null);
4470
4439
  };
4471
4440
  return n ? /* @__PURE__ */ t.jsx("div", { className: "flex flex-col gap-3", children: [1, 2, 3].map((p) => /* @__PURE__ */ t.jsx(
@@ -4476,7 +4445,7 @@ ${p.body}` : p.title;
4476
4445
  p
4477
4446
  )) }) : e.length === 0 ? /* @__PURE__ */ t.jsx(t.Fragment, {}) : /* @__PURE__ */ t.jsxs("div", { className: "space-y-4", children: [
4478
4447
  /* @__PURE__ */ t.jsx("div", { className: "flex flex-col gap-3", children: e.map((p) => /* @__PURE__ */ t.jsx(
4479
- Ni,
4448
+ vi,
4480
4449
  {
4481
4450
  task: p,
4482
4451
  toggleCompletion: u,
@@ -4511,7 +4480,7 @@ ${p.body}` : p.title;
4511
4480
  c?.id ?? "edit"
4512
4481
  ),
4513
4482
  /* @__PURE__ */ t.jsx(
4514
- Ae,
4483
+ De,
4515
4484
  {
4516
4485
  open: o !== null,
4517
4486
  onOpenChange: (p) => {
@@ -4522,7 +4491,7 @@ ${p.body}` : p.title;
4522
4491
  role: "alertdialog",
4523
4492
  presentation: s ? "bottom-sheet" : "dialog",
4524
4493
  size: "compact",
4525
- children: /* @__PURE__ */ t.jsxs(Pe, { children: [
4494
+ children: /* @__PURE__ */ t.jsxs(Ae, { children: [
4526
4495
  /* @__PURE__ */ t.jsx(q, { variant: "secondary", onClick: () => l(null), children: a("cancel") }),
4527
4496
  /* @__PURE__ */ t.jsx(
4528
4497
  q,
@@ -4539,13 +4508,13 @@ ${p.body}` : p.title;
4539
4508
  )
4540
4509
  ] });
4541
4510
  }
4542
- function ki(e, n) {
4543
- const r = W(), a = Ye(), { t: s } = z();
4511
+ function Ni(e, n) {
4512
+ const r = W(), a = Qe(), { t: s } = z();
4544
4513
  return re({
4545
4514
  mutationFn: (o) => a.createTask(e, o),
4546
4515
  onSuccess: () => {
4547
4516
  O({ title: s("task_created"), type: "success" }), r.invalidateQueries({
4548
- queryKey: Y.tasks(e)
4517
+ queryKey: Q.tasks(e)
4549
4518
  }), n?.onSuccess?.();
4550
4519
  },
4551
4520
  onError: (o) => {
@@ -4558,12 +4527,12 @@ function ki(e, n) {
4558
4527
  }
4559
4528
  });
4560
4529
  }
4561
- function wi({
4530
+ function Ci({
4562
4531
  contactId: e
4563
4532
  }) {
4564
- const { t: n } = z(), [r, a] = i.useState(!1), s = () => a(!1), o = ki(e, { onSuccess: s });
4533
+ const { t: n } = z(), [r, a] = i.useState(!1), s = () => a(!1), o = Ni(e, { onSuccess: s });
4565
4534
  return r ? /* @__PURE__ */ t.jsx(
4566
- To,
4535
+ So,
4567
4536
  {
4568
4537
  onSubmit: (l) => o.mutate(l),
4569
4538
  isSubmitting: o.isPending,
@@ -4582,13 +4551,13 @@ function wi({
4582
4551
  }
4583
4552
  );
4584
4553
  }
4585
- function Si(e, n) {
4554
+ function ki(e, n) {
4586
4555
  const r = W(), a = it(), { t: s } = z();
4587
4556
  return re({
4588
4557
  mutationFn: (o) => a.deleteNote(o, e),
4589
4558
  onSuccess: () => {
4590
4559
  O({ title: s("note_deleted"), type: "success" }), r.invalidateQueries({
4591
- queryKey: Y.notes(e)
4560
+ queryKey: Q.notes(e)
4592
4561
  }), n?.onSuccess?.();
4593
4562
  },
4594
4563
  onError: (o) => {
@@ -4600,7 +4569,7 @@ function Si(e, n) {
4600
4569
  }
4601
4570
  });
4602
4571
  }
4603
- function Mi(e, n) {
4572
+ function wi(e, n) {
4604
4573
  const r = W(), a = it(), { t: s } = z();
4605
4574
  return re({
4606
4575
  mutationFn: ({
@@ -4609,7 +4578,7 @@ function Mi(e, n) {
4609
4578
  }) => a.updateNote(o, e, l),
4610
4579
  onSuccess: () => {
4611
4580
  O({ title: s("note_updated"), type: "success" }), r.invalidateQueries({
4612
- queryKey: Y.notes(e)
4581
+ queryKey: Q.notes(e)
4613
4582
  }), n?.onSuccess?.();
4614
4583
  },
4615
4584
  onError: (o) => {
@@ -4621,13 +4590,13 @@ function Mi(e, n) {
4621
4590
  }
4622
4591
  });
4623
4592
  }
4624
- function Ti(e, n) {
4593
+ function Si(e, n) {
4625
4594
  const r = W(), a = it(), { t: s } = z();
4626
4595
  return re({
4627
4596
  mutationFn: (o) => a.createNote(e, o),
4628
4597
  onSuccess: () => {
4629
4598
  O({ title: s("note_created"), type: "success" }), r.invalidateQueries({
4630
- queryKey: Y.notes(e)
4599
+ queryKey: Q.notes(e)
4631
4600
  }), n?.onSuccess?.();
4632
4601
  },
4633
4602
  onError: (o) => {
@@ -4639,19 +4608,19 @@ function Ti(e, n) {
4639
4608
  }
4640
4609
  });
4641
4610
  }
4642
- function Ei() {
4611
+ function Mi() {
4643
4612
  if (typeof navigator > "u") return !1;
4644
4613
  const n = navigator.userAgentData?.platform ?? navigator.userAgent ?? "";
4645
4614
  return /Mac|iPhone|iPad/i.test(n);
4646
4615
  }
4647
- function Di({
4616
+ function Ti({
4648
4617
  contactId: e
4649
4618
  }) {
4650
4619
  const { t: n } = z(), [r, a] = i.useState(""), [s, o] = i.useState(!1), [l, c] = i.useState(!1), d = i.useRef(null);
4651
4620
  i.useEffect(() => {
4652
- c(Ei());
4621
+ c(Mi());
4653
4622
  }, []);
4654
- const u = Ti(e, {
4623
+ const u = Si(e, {
4655
4624
  onSuccess: () => {
4656
4625
  a(""), d.current?.blur();
4657
4626
  }
@@ -4711,19 +4680,19 @@ function tr(e) {
4711
4680
  year: "numeric"
4712
4681
  });
4713
4682
  }
4714
- function Ai(e, n) {
4683
+ function Ei(e, n) {
4715
4684
  const r = new Date(e), s = (/* @__PURE__ */ new Date()).getTime() - r.getTime(), o = Math.floor(s / (1e3 * 60 * 60 * 24));
4716
4685
  return o === 0 ? r.toLocaleTimeString("en-US", {
4717
4686
  hour: "numeric",
4718
4687
  minute: "2-digit"
4719
4688
  }) : o === 1 ? n("task_yesterday") : o < 7 ? n("task_days_ago_other", { count: o }) : tr(e);
4720
4689
  }
4721
- function Pi({
4690
+ function Di({
4722
4691
  note: e,
4723
4692
  onEdit: n,
4724
4693
  onDelete: r
4725
4694
  }) {
4726
- const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(!1), c = e.assets?.length ?? 0, d = !!e.title?.trim() && e.title.trim() !== e.body?.trim(), u = e.due_at ?? e.due_date ?? null, m = e.created_at ? Ai(e.created_at, a) : null;
4695
+ const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(!1), c = e.assets?.length ?? 0, d = !!e.title?.trim() && e.title.trim() !== e.body?.trim(), u = e.due_at ?? e.due_date ?? null, m = e.created_at ? Ei(e.created_at, a) : null;
4727
4696
  return /* @__PURE__ */ t.jsxs(
4728
4697
  "div",
4729
4698
  {
@@ -4749,11 +4718,11 @@ function Pi({
4749
4718
  (m || u || c > 0) && /* @__PURE__ */ t.jsxs("div", { className: "mt-2.5 flex flex-wrap items-center gap-3", children: [
4750
4719
  m && /* @__PURE__ */ t.jsx("span", { className: "text-muted-foreground/70 text-xs", children: m }),
4751
4720
  u && /* @__PURE__ */ t.jsxs("span", { className: "bg-primary/10 text-primary inline-flex items-center gap-1 rounded-full px-2 py-0.5 text-xs font-medium", children: [
4752
- /* @__PURE__ */ t.jsx(Me, { className: "size-3", "aria-hidden": "true" }),
4721
+ /* @__PURE__ */ t.jsx(Se, { className: "size-3", "aria-hidden": "true" }),
4753
4722
  a("task_due", { date: tr(u) })
4754
4723
  ] }),
4755
4724
  c > 0 && /* @__PURE__ */ t.jsxs("span", { className: "text-muted-foreground inline-flex items-center gap-1 text-xs", children: [
4756
- /* @__PURE__ */ t.jsx(Ga, { className: "size-3", "aria-hidden": "true" }),
4725
+ /* @__PURE__ */ t.jsx(Ba, { className: "size-3", "aria-hidden": "true" }),
4757
4726
  c === 1 ? a("attachment_one") : a("attachment_other", { count: c })
4758
4727
  ] })
4759
4728
  ] }),
@@ -4821,14 +4790,14 @@ function Pi({
4821
4790
  }
4822
4791
  );
4823
4792
  }
4824
- function zi({
4793
+ function Ai({
4825
4794
  notes: e,
4826
4795
  isLoading: n,
4827
4796
  contactId: r
4828
4797
  }) {
4829
- const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(null), [c, d] = i.useState(null), u = Si(r, {
4798
+ const { t: a } = z(), { isMobile: s } = he(), [o, l] = i.useState(null), [c, d] = i.useState(null), u = ki(r, {
4830
4799
  onSuccess: () => l(null)
4831
- }), m = Mi(r, {
4800
+ }), m = wi(r, {
4832
4801
  onSuccess: () => d(null)
4833
4802
  }), g = (f) => {
4834
4803
  c && m.mutate({
@@ -4837,7 +4806,7 @@ function zi({
4837
4806
  });
4838
4807
  };
4839
4808
  return /* @__PURE__ */ t.jsxs("div", { className: "space-y-4", children: [
4840
- /* @__PURE__ */ t.jsx(Di, { contactId: r }),
4809
+ /* @__PURE__ */ t.jsx(Ti, { contactId: r }),
4841
4810
  n ? /* @__PURE__ */ t.jsx("div", { className: "flex flex-col gap-3", children: [1, 2, 3].map((f) => /* @__PURE__ */ t.jsx(
4842
4811
  "div",
4843
4812
  {
@@ -4845,7 +4814,7 @@ function zi({
4845
4814
  },
4846
4815
  f
4847
4816
  )) }) : e.length === 0 ? null : /* @__PURE__ */ t.jsx("div", { className: "flex flex-col gap-3", children: e.map((f) => /* @__PURE__ */ t.jsx(
4848
- Pi,
4817
+ Di,
4849
4818
  {
4850
4819
  note: f,
4851
4820
  onEdit: d,
@@ -4870,7 +4839,7 @@ function zi({
4870
4839
  c?.id ?? "edit"
4871
4840
  ),
4872
4841
  /* @__PURE__ */ t.jsx(
4873
- Ae,
4842
+ De,
4874
4843
  {
4875
4844
  open: !!o,
4876
4845
  onOpenChange: (f) => {
@@ -4881,7 +4850,7 @@ function zi({
4881
4850
  role: "alertdialog",
4882
4851
  presentation: s ? "bottom-sheet" : "dialog",
4883
4852
  size: "compact",
4884
- children: /* @__PURE__ */ t.jsxs(Pe, { children: [
4853
+ children: /* @__PURE__ */ t.jsxs(Ae, { children: [
4885
4854
  /* @__PURE__ */ t.jsx(q, { variant: "secondary", onClick: () => l(null), children: a("cancel") }),
4886
4855
  /* @__PURE__ */ t.jsx(
4887
4856
  q,
@@ -4898,8 +4867,8 @@ function zi({
4898
4867
  )
4899
4868
  ] });
4900
4869
  }
4901
- const Fi = ["Tasks", "Notes"];
4902
- function Ri({
4870
+ const Pi = ["Tasks", "Notes"];
4871
+ function zi({
4903
4872
  contactId: e,
4904
4873
  tasks: n,
4905
4874
  isLoadingTasks: r,
@@ -4913,7 +4882,7 @@ function Ri({
4913
4882
  Notes: c("tab_notes")
4914
4883
  };
4915
4884
  return /* @__PURE__ */ t.jsxs("div", { className: "mt-8", children: [
4916
- /* @__PURE__ */ t.jsx("div", { className: "border-border/50 flex items-center gap-1 border-b", children: Fi.map((u) => {
4885
+ /* @__PURE__ */ t.jsx("div", { className: "border-border/50 flex items-center gap-1 border-b", children: Pi.map((u) => {
4917
4886
  const m = u === "Tasks" ? n.length : a.length, g = o === u;
4918
4887
  return /* @__PURE__ */ t.jsxs(
4919
4888
  "button",
@@ -4950,9 +4919,9 @@ function Ri({
4950
4919
  }) }),
4951
4920
  /* @__PURE__ */ t.jsxs("div", { className: "pt-6", children: [
4952
4921
  o === "Tasks" && /* @__PURE__ */ t.jsxs("div", { className: "space-y-4", children: [
4953
- /* @__PURE__ */ t.jsx(wi, { contactId: e }),
4922
+ /* @__PURE__ */ t.jsx(Ci, { contactId: e }),
4954
4923
  /* @__PURE__ */ t.jsx(
4955
- Ci,
4924
+ ji,
4956
4925
  {
4957
4926
  tasks: n,
4958
4927
  isLoading: r,
@@ -4962,7 +4931,7 @@ function Ri({
4962
4931
  )
4963
4932
  ] }),
4964
4933
  o === "Notes" && /* @__PURE__ */ t.jsx(
4965
- zi,
4934
+ Ai,
4966
4935
  {
4967
4936
  notes: a,
4968
4937
  isLoading: s,
@@ -4972,7 +4941,7 @@ function Ri({
4972
4941
  ] })
4973
4942
  ] });
4974
4943
  }
4975
- function Ii({
4944
+ function Fi({
4976
4945
  contactId: e,
4977
4946
  queryKeyPrefix: n,
4978
4947
  countriesQueryKey: r,
@@ -4990,13 +4959,13 @@ function Ii({
4990
4959
  isDeleting: y,
4991
4960
  onSave: p,
4992
4961
  onDelete: h
4993
- } = ri(e, {
4962
+ } = ti(e, {
4994
4963
  queryKeyPrefix: n,
4995
4964
  countriesQueryKey: r,
4996
4965
  getCountries: a,
4997
4966
  onDeleteSuccess: s,
4998
4967
  onSaveSuccess: () => b(!1)
4999
- }), { data: v = [], isLoading: C } = ai(e), { data: k = [], isLoading: j } = si(e), { data: x = [] } = Dt(), P = oi(e, n, {
4968
+ }), { data: v = [], isLoading: C } = ni(e), { data: k = [], isLoading: j } = ri(e), { data: x = [] } = Dt(), P = ai(e, n, {
5000
4969
  onError: (B) => {
5001
4970
  O({
5002
4971
  title: l("groups_tags_save_failed"),
@@ -5009,7 +4978,7 @@ function Ii({
5009
4978
  }, [h]);
5010
4979
  if (u)
5011
4980
  return /* @__PURE__ */ t.jsx(
5012
- Oi,
4981
+ Ri,
5013
4982
  {
5014
4983
  onBack: s,
5015
4984
  showMobileBackButton: o
@@ -5048,7 +5017,7 @@ function Ii({
5048
5017
  ),
5049
5018
  /* @__PURE__ */ t.jsx("div", { className: "flex-1 overflow-y-auto", children: /* @__PURE__ */ t.jsxs("div", { className: "mx-auto w-full max-w-[900px] px-6 pt-8 pb-16 md:px-8 md:pt-10", children: [
5050
5019
  /* @__PURE__ */ t.jsx(
5051
- pi,
5020
+ ui,
5052
5021
  {
5053
5022
  contact: d,
5054
5023
  tasksCount: v.length,
@@ -5063,14 +5032,14 @@ function Ii({
5063
5032
  }
5064
5033
  ),
5065
5034
  /* @__PURE__ */ t.jsx(
5066
- gi,
5035
+ pi,
5067
5036
  {
5068
5037
  contact: d,
5069
5038
  onEditEmpty: () => b(!0)
5070
5039
  }
5071
5040
  ),
5072
5041
  /* @__PURE__ */ t.jsx(
5073
- Ri,
5042
+ zi,
5074
5043
  {
5075
5044
  contactId: e,
5076
5045
  tasks: v,
@@ -5083,7 +5052,7 @@ function Ii({
5083
5052
  )
5084
5053
  ] }) }),
5085
5054
  /* @__PURE__ */ t.jsxs(
5086
- Ae,
5055
+ De,
5087
5056
  {
5088
5057
  open: $,
5089
5058
  onOpenChange: (B) => {
@@ -5094,7 +5063,7 @@ function Ii({
5094
5063
  size: "wide",
5095
5064
  children: [
5096
5065
  /* @__PURE__ */ t.jsx(vt, { countries: g }),
5097
- /* @__PURE__ */ t.jsxs(Pe, { children: [
5066
+ /* @__PURE__ */ t.jsxs(Ae, { children: [
5098
5067
  /* @__PURE__ */ t.jsx(
5099
5068
  q,
5100
5069
  {
@@ -5113,7 +5082,7 @@ function Ii({
5113
5082
  disabled: !f || _,
5114
5083
  "aria-busy": _,
5115
5084
  children: [
5116
- _ && /* @__PURE__ */ t.jsx(ma, { className: "size-4" }),
5085
+ _ && /* @__PURE__ */ t.jsx(va, { className: "size-4" }),
5117
5086
  l(_ ? "saving" : "save_changes")
5118
5087
  ]
5119
5088
  }
@@ -5123,7 +5092,7 @@ function Ii({
5123
5092
  }
5124
5093
  ),
5125
5094
  /* @__PURE__ */ t.jsx(
5126
- Ae,
5095
+ De,
5127
5096
  {
5128
5097
  open: F,
5129
5098
  onOpenChange: I,
@@ -5132,7 +5101,7 @@ function Ii({
5132
5101
  role: "alertdialog",
5133
5102
  presentation: c ? "bottom-sheet" : "dialog",
5134
5103
  size: "compact",
5135
- children: /* @__PURE__ */ t.jsxs(Pe, { children: [
5104
+ children: /* @__PURE__ */ t.jsxs(Ae, { children: [
5136
5105
  /* @__PURE__ */ t.jsx(
5137
5106
  q,
5138
5107
  {
@@ -5283,7 +5252,7 @@ function Xt({ href: e, label: n, icon: r }) {
5283
5252
  }
5284
5253
  );
5285
5254
  }
5286
- function Oi({
5255
+ function Ri({
5287
5256
  onBack: e,
5288
5257
  showMobileBackButton: n = !0
5289
5258
  }) {
@@ -5312,15 +5281,15 @@ function Oi({
5312
5281
  ] })
5313
5282
  ] });
5314
5283
  }
5315
- function Li() {
5284
+ function Ii() {
5316
5285
  const { t: e } = z();
5317
5286
  return /* @__PURE__ */ t.jsxs("div", { className: "hidden h-full flex-1 flex-col items-center justify-center px-8 text-center md:flex", children: [
5318
- /* @__PURE__ */ t.jsx("div", { className: "bg-muted text-muted-foreground flex size-16 items-center justify-center rounded-xl", children: /* @__PURE__ */ t.jsx(we, { className: "size-7", "aria-hidden": "true" }) }),
5287
+ /* @__PURE__ */ t.jsx("div", { className: "bg-muted text-muted-foreground flex size-16 items-center justify-center rounded-xl", children: /* @__PURE__ */ t.jsx(ke, { className: "size-7", "aria-hidden": "true" }) }),
5319
5288
  /* @__PURE__ */ t.jsx("h2", { className: "text-foreground mt-5 text-base font-semibold", children: e("empty_select_contact") }),
5320
5289
  /* @__PURE__ */ t.jsx("p", { className: "text-muted-foreground mt-1 max-w-xs text-sm", children: e("empty_select_description") })
5321
5290
  ] });
5322
5291
  }
5323
- function qi({
5292
+ function Oi({
5324
5293
  selectedContactId: e,
5325
5294
  highlightContactId: n,
5326
5295
  onSelect: r,
@@ -5343,7 +5312,7 @@ function qi({
5343
5312
  e ? "hidden" : "flex flex-col"
5344
5313
  ),
5345
5314
  children: /* @__PURE__ */ t.jsx(
5346
- Bo,
5315
+ $o,
5347
5316
  {
5348
5317
  selectedContactId: e,
5349
5318
  highlightContactId: n,
@@ -5365,7 +5334,7 @@ function qi({
5365
5334
  e ? "flex flex-col" : "hidden md:flex"
5366
5335
  ),
5367
5336
  children: e ? /* @__PURE__ */ t.jsx(
5368
- Ii,
5337
+ Fi,
5369
5338
  {
5370
5339
  contactId: e,
5371
5340
  queryKeyPrefix: d,
@@ -5375,7 +5344,7 @@ function qi({
5375
5344
  showMobileBackButton: g
5376
5345
  },
5377
5346
  e
5378
- ) : /* @__PURE__ */ t.jsx(Li, {})
5347
+ ) : /* @__PURE__ */ t.jsx(Ii, {})
5379
5348
  }
5380
5349
  )
5381
5350
  ] });
@@ -5451,56 +5420,56 @@ var Ue = function(e, n, r) {
5451
5420
  }, rr = function(e) {
5452
5421
  var n = e.color, r = e.left, a = e.top, s = a === void 0 ? 0.5 : a, o = zt(["react-colorful__pointer", e.className]);
5453
5422
  return H.createElement("div", { className: o, style: { top: 100 * s + "%", left: 100 * r + "%" } }, H.createElement("div", { className: "react-colorful__pointer-fill", style: { backgroundColor: n } }));
5454
- }, Q = function(e, n, r) {
5423
+ }, Y = function(e, n, r) {
5455
5424
  return n === void 0 && (n = 0), r === void 0 && (r = Math.pow(10, n)), Math.round(r * e) / r;
5456
- }, $i = function(e) {
5457
- return Hi(Ct(e));
5425
+ }, Li = function(e) {
5426
+ return Ui(Ct(e));
5458
5427
  }, Ct = function(e) {
5459
- return e[0] === "#" && (e = e.substring(1)), e.length < 6 ? { r: parseInt(e[0] + e[0], 16), g: parseInt(e[1] + e[1], 16), b: parseInt(e[2] + e[2], 16), a: e.length === 4 ? Q(parseInt(e[3] + e[3], 16) / 255, 2) : 1 } : { r: parseInt(e.substring(0, 2), 16), g: parseInt(e.substring(2, 4), 16), b: parseInt(e.substring(4, 6), 16), a: e.length === 8 ? Q(parseInt(e.substring(6, 8), 16) / 255, 2) : 1 };
5460
- }, Ki = function(e) {
5461
- return Gi(Ui(e));
5462
- }, Bi = function(e) {
5428
+ return e[0] === "#" && (e = e.substring(1)), e.length < 6 ? { r: parseInt(e[0] + e[0], 16), g: parseInt(e[1] + e[1], 16), b: parseInt(e[2] + e[2], 16), a: e.length === 4 ? Y(parseInt(e[3] + e[3], 16) / 255, 2) : 1 } : { r: parseInt(e.substring(0, 2), 16), g: parseInt(e.substring(2, 4), 16), b: parseInt(e.substring(4, 6), 16), a: e.length === 8 ? Y(parseInt(e.substring(6, 8), 16) / 255, 2) : 1 };
5429
+ }, qi = function(e) {
5430
+ return Bi(Ki(e));
5431
+ }, $i = function(e) {
5463
5432
  var n = e.s, r = e.v, a = e.a, s = (200 - n) * r / 100;
5464
- return { h: Q(e.h), s: Q(s > 0 && s < 200 ? n * r / 100 / (s <= 100 ? s : 200 - s) * 100 : 0), l: Q(s / 2), a: Q(a, 2) };
5433
+ return { h: Y(e.h), s: Y(s > 0 && s < 200 ? n * r / 100 / (s <= 100 ? s : 200 - s) * 100 : 0), l: Y(s / 2), a: Y(a, 2) };
5465
5434
  }, kt = function(e) {
5466
- var n = Bi(e);
5435
+ var n = $i(e);
5467
5436
  return "hsl(" + n.h + ", " + n.s + "%, " + n.l + "%)";
5468
- }, Ui = function(e) {
5437
+ }, Ki = function(e) {
5469
5438
  var n = e.h, r = e.s, a = e.v, s = e.a;
5470
5439
  n = n / 360 * 6, r /= 100, a /= 100;
5471
5440
  var o = Math.floor(n), l = a * (1 - r), c = a * (1 - (n - o) * r), d = a * (1 - (1 - n + o) * r), u = o % 6;
5472
- return { r: Q(255 * [a, c, l, l, d, a][u]), g: Q(255 * [d, a, a, c, l, l][u]), b: Q(255 * [l, l, d, a, a, c][u]), a: Q(s, 2) };
5441
+ return { r: Y(255 * [a, c, l, l, d, a][u]), g: Y(255 * [d, a, a, c, l, l][u]), b: Y(255 * [l, l, d, a, a, c][u]), a: Y(s, 2) };
5473
5442
  }, Xe = function(e) {
5474
5443
  var n = e.toString(16);
5475
5444
  return n.length < 2 ? "0" + n : n;
5476
- }, Gi = function(e) {
5477
- var n = e.r, r = e.g, a = e.b, s = e.a, o = s < 1 ? Xe(Q(255 * s)) : "";
5445
+ }, Bi = function(e) {
5446
+ var n = e.r, r = e.g, a = e.b, s = e.a, o = s < 1 ? Xe(Y(255 * s)) : "";
5478
5447
  return "#" + Xe(n) + Xe(r) + Xe(a) + o;
5479
- }, Hi = function(e) {
5448
+ }, Ui = function(e) {
5480
5449
  var n = e.r, r = e.g, a = e.b, s = e.a, o = Math.max(n, r, a), l = o - Math.min(n, r, a), c = l ? o === n ? (r - a) / l : o === r ? 2 + (a - n) / l : 4 + (n - r) / l : 0;
5481
- return { h: Q(60 * (c < 0 ? c + 6 : c)), s: Q(o ? l / o * 100 : 0), v: Q(o / 255 * 100), a: s };
5482
- }, Yi = H.memo(function(e) {
5450
+ return { h: Y(60 * (c < 0 ? c + 6 : c)), s: Y(o ? l / o * 100 : 0), v: Y(o / 255 * 100), a: s };
5451
+ }, Gi = H.memo(function(e) {
5483
5452
  var n = e.hue, r = e.onChange, a = zt(["react-colorful__hue", e.className]);
5484
5453
  return H.createElement("div", { className: a }, H.createElement(nr, { onMove: function(s) {
5485
5454
  r({ h: 360 * s.left });
5486
5455
  }, onKey: function(s) {
5487
5456
  r({ h: Ue(n + 360 * s.left, 0, 360) });
5488
- }, "aria-label": "Hue", "aria-valuenow": Q(n), "aria-valuemax": "360", "aria-valuemin": "0" }, H.createElement(rr, { className: "react-colorful__hue-pointer", left: n / 360, color: kt({ h: n, s: 100, v: 100, a: 1 }) })));
5489
- }), Qi = H.memo(function(e) {
5457
+ }, "aria-label": "Hue", "aria-valuenow": Y(n), "aria-valuemax": "360", "aria-valuemin": "0" }, H.createElement(rr, { className: "react-colorful__hue-pointer", left: n / 360, color: kt({ h: n, s: 100, v: 100, a: 1 }) })));
5458
+ }), Hi = H.memo(function(e) {
5490
5459
  var n = e.hsva, r = e.onChange, a = { backgroundColor: kt({ h: n.h, s: 100, v: 100, a: 1 }) };
5491
5460
  return H.createElement("div", { className: "react-colorful__saturation", style: a }, H.createElement(nr, { onMove: function(s) {
5492
5461
  r({ s: 100 * s.left, v: 100 - 100 * s.top });
5493
5462
  }, onKey: function(s) {
5494
5463
  r({ s: Ue(n.s + 100 * s.left, 0, 100), v: Ue(n.v - 100 * s.top, 0, 100) });
5495
- }, "aria-label": "Color", "aria-valuetext": "Saturation " + Q(n.s) + "%, Brightness " + Q(n.v) + "%" }, H.createElement(rr, { className: "react-colorful__saturation-pointer", top: 1 - n.v / 100, left: n.s / 100, color: kt(n) })));
5464
+ }, "aria-label": "Color", "aria-valuetext": "Saturation " + Y(n.s) + "%, Brightness " + Y(n.v) + "%" }, H.createElement(rr, { className: "react-colorful__saturation-pointer", top: 1 - n.v / 100, left: n.s / 100, color: kt(n) })));
5496
5465
  }), ar = function(e, n) {
5497
5466
  if (e === n) return !0;
5498
5467
  for (var r in e) if (e[r] !== n[r]) return !1;
5499
5468
  return !0;
5500
- }, Vi = function(e, n) {
5469
+ }, Qi = function(e, n) {
5501
5470
  return e.toLowerCase() === n.toLowerCase() || ar(Ct(e), Ct(n));
5502
5471
  };
5503
- function Wi(e, n, r) {
5472
+ function Yi(e, n, r) {
5504
5473
  var a = Be(r), s = i.useState(function() {
5505
5474
  return e.toHsva(n);
5506
5475
  }), o = s[0], l = s[1], c = i.useRef({ color: n, hsva: o });
@@ -5520,28 +5489,28 @@ function Wi(e, n, r) {
5520
5489
  }, []);
5521
5490
  return [o, d];
5522
5491
  }
5523
- var Xi = typeof window < "u" ? i.useLayoutEffect : i.useEffect, Zi = function() {
5492
+ var Vi = typeof window < "u" ? i.useLayoutEffect : i.useEffect, Wi = function() {
5524
5493
  return typeof __webpack_nonce__ < "u" ? __webpack_nonce__ : void 0;
5525
- }, en = /* @__PURE__ */ new Map(), Ji = function(e) {
5526
- Xi(function() {
5494
+ }, en = /* @__PURE__ */ new Map(), Xi = function(e) {
5495
+ Vi(function() {
5527
5496
  var n = e.current ? e.current.ownerDocument : document;
5528
5497
  if (n !== void 0 && !en.has(n)) {
5529
5498
  var r = n.createElement("style");
5530
5499
  r.innerHTML = `.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill-opacity=".05"><path d="M8 0h8v8H8zM0 8h8v8H0z"/></svg>')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}`, en.set(n, r);
5531
- var a = Zi();
5500
+ var a = Wi();
5532
5501
  a && r.setAttribute("nonce", a), n.head.appendChild(r);
5533
5502
  }
5534
5503
  }, []);
5535
- }, el = function(e) {
5504
+ }, Zi = function(e) {
5536
5505
  var n = e.className, r = e.colorModel, a = e.color, s = a === void 0 ? r.defaultColor : a, o = e.onChange, l = ut(e, ["className", "colorModel", "color", "onChange"]), c = i.useRef(null);
5537
- Ji(c);
5538
- var d = Wi(r, s, o), u = d[0], m = d[1], g = zt(["react-colorful", n]);
5539
- return H.createElement("div", Fe({}, l, { ref: c, className: g }), H.createElement(Qi, { hsva: u, onChange: m }), H.createElement(Yi, { hue: u.h, onChange: m, className: "react-colorful__last-control" }));
5540
- }, tl = { defaultColor: "000", toHsva: $i, fromHsva: function(e) {
5541
- return Ki({ h: e.h, s: e.s, v: e.v, a: 1 });
5542
- }, equal: Vi }, nl = function(e) {
5543
- return H.createElement(el, Fe({}, e, { colorModel: tl }));
5544
- }, rl = /^#?([0-9A-F]{3,8})$/i, al = function(e) {
5506
+ Xi(c);
5507
+ var d = Yi(r, s, o), u = d[0], m = d[1], g = zt(["react-colorful", n]);
5508
+ return H.createElement("div", Fe({}, l, { ref: c, className: g }), H.createElement(Hi, { hsva: u, onChange: m }), H.createElement(Gi, { hue: u.h, onChange: m, className: "react-colorful__last-control" }));
5509
+ }, Ji = { defaultColor: "000", toHsva: Li, fromHsva: function(e) {
5510
+ return qi({ h: e.h, s: e.s, v: e.v, a: 1 });
5511
+ }, equal: Qi }, el = function(e) {
5512
+ return H.createElement(Zi, Fe({}, e, { colorModel: Ji }));
5513
+ }, tl = /^#?([0-9A-F]{3,8})$/i, nl = function(e) {
5545
5514
  var n = e.color, r = n === void 0 ? "" : n, a = e.onChange, s = e.onBlur, o = e.escape, l = e.validate, c = e.format, d = e.process, u = ut(e, ["color", "onChange", "onBlur", "escape", "validate", "format", "process"]), m = i.useState(function() {
5546
5515
  return o(r);
5547
5516
  }), g = m[0], f = m[1], _ = Be(a), y = Be(s), p = i.useCallback(function(v) {
@@ -5555,18 +5524,18 @@ var Xi = typeof window < "u" ? i.useLayoutEffect : i.useEffect, Zi = function()
5555
5524
  }, [r, o]), H.createElement("input", Fe({}, u, { value: c ? c(g) : g, spellCheck: "false", onChange: p, onBlur: h }));
5556
5525
  }, tn = function(e) {
5557
5526
  return "#" + e;
5558
- }, sl = function(e) {
5527
+ }, rl = function(e) {
5559
5528
  var n = e.prefixed, r = e.alpha, a = ut(e, ["prefixed", "alpha"]), s = i.useCallback(function(l) {
5560
5529
  return l.replace(/([^0-9A-F]+)/gi, "").substring(0, r ? 8 : 6);
5561
5530
  }, [r]), o = i.useCallback(function(l) {
5562
5531
  return (function(c, d) {
5563
- var u = rl.exec(c), m = u ? u[1].length : 0;
5532
+ var u = tl.exec(c), m = u ? u[1].length : 0;
5564
5533
  return m === 3 || m === 6 || !!d && m === 4 || !!d && m === 8;
5565
5534
  })(l, r);
5566
5535
  }, [r]);
5567
- return H.createElement(al, Fe({}, a, { escape: s, format: n ? tn : void 0, process: tn, validate: o }));
5536
+ return H.createElement(nl, Fe({}, a, { escape: s, format: n ? tn : void 0, process: tn, validate: o }));
5568
5537
  };
5569
- function ol() {
5538
+ function al() {
5570
5539
  const e = lt(), n = W(), { t: r } = z();
5571
5540
  return re({
5572
5541
  mutationFn: (a) => {
@@ -5574,7 +5543,7 @@ function ol() {
5574
5543
  return e.deleteGroup(a);
5575
5544
  },
5576
5545
  onSuccess: () => {
5577
- n.invalidateQueries({ queryKey: Y.groups() }), ze(n);
5546
+ n.invalidateQueries({ queryKey: Q.groups() }), Pe(n);
5578
5547
  },
5579
5548
  onError: (a) => {
5580
5549
  O({
@@ -5585,7 +5554,7 @@ function ol() {
5585
5554
  }
5586
5555
  });
5587
5556
  }
5588
- function il() {
5557
+ function sl() {
5589
5558
  const e = lt(), n = W(), { t: r } = z();
5590
5559
  return re({
5591
5560
  mutationFn: ({
@@ -5596,7 +5565,7 @@ function il() {
5596
5565
  return e.updateGroup(a, s);
5597
5566
  },
5598
5567
  onSuccess: () => {
5599
- n.invalidateQueries({ queryKey: Y.groups() }), ze(n);
5568
+ n.invalidateQueries({ queryKey: Q.groups() }), Pe(n);
5600
5569
  },
5601
5570
  onError: (a) => {
5602
5571
  O({
@@ -5607,7 +5576,7 @@ function il() {
5607
5576
  }
5608
5577
  });
5609
5578
  }
5610
- const ll = [
5579
+ const ol = [
5611
5580
  "#ef4444",
5612
5581
  "#f97316",
5613
5582
  "#eab308",
@@ -5618,7 +5587,7 @@ const ll = [
5618
5587
  "#6366f1",
5619
5588
  "#8b5cf6",
5620
5589
  "#ec4899"
5621
- ], cl = {
5590
+ ], il = {
5622
5591
  "#ef4444": "groups_color_red",
5623
5592
  "#f97316": "groups_color_orange",
5624
5593
  "#eab308": "groups_color_yellow",
@@ -5630,13 +5599,13 @@ const ll = [
5630
5599
  "#8b5cf6": "groups_color_purple",
5631
5600
  "#ec4899": "groups_color_pink"
5632
5601
  };
5633
- function dl({
5602
+ function ll({
5634
5603
  onBack: e,
5635
5604
  onSelectContact: n,
5636
5605
  initialCreateOpen: r,
5637
5606
  showMobileBackButton: a = !0
5638
5607
  }) {
5639
- const { t: s } = z(), { isMobile: o } = he(), { data: l = [], isLoading: c } = Dt(), d = ol(), [u, m] = i.useState(r ? { mode: "create" } : null), [g, f] = i.useState(null), [_, y] = i.useState(null);
5608
+ const { t: s } = z(), { isMobile: o } = he(), { data: l = [], isLoading: c } = Dt(), d = al(), [u, m] = i.useState(r ? { mode: "create" } : null), [g, f] = i.useState(null), [_, y] = i.useState(null);
5640
5609
  i.useEffect(() => {
5641
5610
  if (_ == null) return;
5642
5611
  const h = setTimeout(() => y(null), 2e3);
@@ -5677,8 +5646,8 @@ function dl({
5677
5646
  s("groups_new_group")
5678
5647
  ] })
5679
5648
  ] }),
5680
- /* @__PURE__ */ t.jsx("div", { className: "flex-1 overflow-y-auto px-6 py-6", children: /* @__PURE__ */ t.jsx("div", { className: "mx-auto max-w-[857px]", children: c ? /* @__PURE__ */ t.jsx(hl, {}) : l.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground py-16 text-center text-sm", children: s("groups_empty") }) : /* @__PURE__ */ t.jsx("div", { className: "space-y-2", children: l.map((h) => /* @__PURE__ */ t.jsx(
5681
- fl,
5649
+ /* @__PURE__ */ t.jsx("div", { className: "flex-1 overflow-y-auto px-6 py-6", children: /* @__PURE__ */ t.jsx("div", { className: "mx-auto max-w-[857px]", children: c ? /* @__PURE__ */ t.jsx(fl, {}) : l.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: "text-muted-foreground py-16 text-center text-sm", children: s("groups_empty") }) : /* @__PURE__ */ t.jsx("div", { className: "space-y-2", children: l.map((h) => /* @__PURE__ */ t.jsx(
5650
+ ml,
5682
5651
  {
5683
5652
  group: h,
5684
5653
  highlight: _ === h.id,
@@ -5702,7 +5671,7 @@ function dl({
5702
5671
  u.mode === "edit" ? u.group.id : "create"
5703
5672
  ),
5704
5673
  /* @__PURE__ */ t.jsx(
5705
- Ae,
5674
+ De,
5706
5675
  {
5707
5676
  open: !!g,
5708
5677
  onOpenChange: (h) => !h && f(null),
@@ -5713,7 +5682,7 @@ function dl({
5713
5682
  role: "alertdialog",
5714
5683
  presentation: o ? "bottom-sheet" : "dialog",
5715
5684
  size: "compact",
5716
- children: /* @__PURE__ */ t.jsxs(Pe, { children: [
5685
+ children: /* @__PURE__ */ t.jsxs(Ae, { children: [
5717
5686
  /* @__PURE__ */ t.jsx(
5718
5687
  q,
5719
5688
  {
@@ -5745,7 +5714,7 @@ function sr({
5745
5714
  onGroupCreated: s,
5746
5715
  onGroupCreatedWithName: o
5747
5716
  }) {
5748
- const { t: l } = z(), { isMobile: c } = he(), d = Jn(), u = il(), m = e === "create" ? d.isPending : u.isPending, [g, f] = i.useState(n?.name ?? ""), [_, y] = i.useState(n?.avatar ?? ""), [p, h] = i.useState(
5717
+ const { t: l } = z(), { isMobile: c } = he(), d = Jn(), u = sl(), m = e === "create" ? d.isPending : u.isPending, [g, f] = i.useState(n?.name ?? ""), [_, y] = i.useState(n?.avatar ?? ""), [p, h] = i.useState(
5749
5718
  n?.avatar_background ?? "#6366f1"
5750
5719
  ), v = i.useCallback(() => {
5751
5720
  const k = g.trim();
@@ -5792,7 +5761,7 @@ function sr({
5792
5761
  l
5793
5762
  ]), C = p || "#6366f1";
5794
5763
  return /* @__PURE__ */ t.jsxs(
5795
- Ae,
5764
+ De,
5796
5765
  {
5797
5766
  open: r,
5798
5767
  onOpenChange: a,
@@ -5808,7 +5777,7 @@ function sr({
5808
5777
  {
5809
5778
  className: "flex size-20 items-center justify-center rounded-full text-4xl transition-colors",
5810
5779
  style: { backgroundColor: C },
5811
- children: _ || /* @__PURE__ */ t.jsx(we, { className: "size-8 text-white/60" })
5780
+ children: _ || /* @__PURE__ */ t.jsx(ke, { className: "size-8 text-white/60" })
5812
5781
  }
5813
5782
  ),
5814
5783
  _ && /* @__PURE__ */ t.jsx(
@@ -5835,8 +5804,8 @@ function sr({
5835
5804
  )
5836
5805
  ] })
5837
5806
  ] }),
5838
- /* @__PURE__ */ t.jsxs(pa, { defaultValue: "emoji", children: [
5839
- /* @__PURE__ */ t.jsxs(fa, { className: "border-border h-auto w-full justify-center gap-6 rounded-none border-b bg-transparent p-0", children: [
5807
+ /* @__PURE__ */ t.jsxs(ja, { defaultValue: "emoji", children: [
5808
+ /* @__PURE__ */ t.jsxs(Na, { className: "border-border h-auto w-full justify-center gap-6 rounded-none border-b bg-transparent p-0", children: [
5840
5809
  /* @__PURE__ */ t.jsx(
5841
5810
  Lt,
5842
5811
  {
@@ -5860,16 +5829,16 @@ function sr({
5860
5829
  className: "bg-popover flex h-64 w-full flex-col overflow-hidden rounded-lg",
5861
5830
  onEmojiSelect: (k) => y(k.emoji),
5862
5831
  children: /* @__PURE__ */ t.jsxs(Oe.Viewport, { className: "relative flex-1 outline-hidden", children: [
5863
- /* @__PURE__ */ t.jsx(Oe.Loading, { className: "text-muted-foreground absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ t.jsx(Pa, { className: "size-4 animate-spin" }) }),
5832
+ /* @__PURE__ */ t.jsx(Oe.Loading, { className: "text-muted-foreground absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ t.jsx(za, { className: "size-4 animate-spin" }) }),
5864
5833
  /* @__PURE__ */ t.jsx(Oe.Empty, { className: "text-muted-foreground absolute inset-0 flex items-center justify-center text-sm", children: l("groups_no_emoji_found") }),
5865
5834
  /* @__PURE__ */ t.jsx(
5866
5835
  Oe.List,
5867
5836
  {
5868
5837
  className: "pb-1 select-none",
5869
5838
  components: {
5870
- Row: ul,
5871
- Emoji: ml,
5872
- CategoryHeader: pl
5839
+ Row: cl,
5840
+ Emoji: dl,
5841
+ CategoryHeader: ul
5873
5842
  }
5874
5843
  }
5875
5844
  )
@@ -5878,7 +5847,7 @@ function sr({
5878
5847
  ) }),
5879
5848
  /* @__PURE__ */ t.jsx(qt, { value: "color", className: "pt-4", children: /* @__PURE__ */ t.jsxs("div", { className: "space-y-4", children: [
5880
5849
  /* @__PURE__ */ t.jsx(
5881
- nl,
5850
+ el,
5882
5851
  {
5883
5852
  color: p || "#6366f1",
5884
5853
  onChange: h,
@@ -5888,7 +5857,7 @@ function sr({
5888
5857
  /* @__PURE__ */ t.jsx("div", { className: "flex items-center gap-3", children: /* @__PURE__ */ t.jsxs("div", { className: "border-input flex items-center gap-1 rounded-md border px-3 py-1.5", children: [
5889
5858
  /* @__PURE__ */ t.jsx("span", { className: "text-muted-foreground text-sm", children: "#" }),
5890
5859
  /* @__PURE__ */ t.jsx(
5891
- sl,
5860
+ rl,
5892
5861
  {
5893
5862
  color: p || "6366f1",
5894
5863
  onChange: h,
@@ -5896,7 +5865,7 @@ function sr({
5896
5865
  }
5897
5866
  )
5898
5867
  ] }) }),
5899
- /* @__PURE__ */ t.jsx("div", { className: "flex justify-between", children: ll.map((k) => /* @__PURE__ */ t.jsx(
5868
+ /* @__PURE__ */ t.jsx("div", { className: "flex justify-between", children: ol.map((k) => /* @__PURE__ */ t.jsx(
5900
5869
  "button",
5901
5870
  {
5902
5871
  type: "button",
@@ -5906,14 +5875,14 @@ function sr({
5906
5875
  p === k ? "ring-primary ring-2 ring-offset-2" : "hover:scale-110"
5907
5876
  ),
5908
5877
  style: { backgroundColor: k },
5909
- "aria-label": l(cl[k])
5878
+ "aria-label": l(il[k])
5910
5879
  },
5911
5880
  k
5912
5881
  )) })
5913
5882
  ] }) })
5914
5883
  ] })
5915
5884
  ] }),
5916
- /* @__PURE__ */ t.jsxs(Pe, { children: [
5885
+ /* @__PURE__ */ t.jsxs(Ae, { children: [
5917
5886
  /* @__PURE__ */ t.jsx(
5918
5887
  q,
5919
5888
  {
@@ -5929,14 +5898,14 @@ function sr({
5929
5898
  }
5930
5899
  );
5931
5900
  }
5932
- function ul({
5901
+ function cl({
5933
5902
  children: e,
5934
5903
  ref: n,
5935
5904
  ...r
5936
5905
  }) {
5937
5906
  return /* @__PURE__ */ t.jsx("div", { ...r, className: "flex scroll-my-1 justify-center px-1", children: e });
5938
5907
  }
5939
- function ml({
5908
+ function dl({
5940
5909
  emoji: e,
5941
5910
  className: n,
5942
5911
  ref: r,
@@ -5954,7 +5923,7 @@ function ml({
5954
5923
  }
5955
5924
  );
5956
5925
  }
5957
- function pl({
5926
+ function ul({
5958
5927
  category: e,
5959
5928
  ref: n,
5960
5929
  ...r
@@ -5968,7 +5937,7 @@ function pl({
5968
5937
  }
5969
5938
  );
5970
5939
  }
5971
- function fl({
5940
+ function ml({
5972
5941
  group: e,
5973
5942
  highlight: n,
5974
5943
  onEdit: r,
@@ -5996,7 +5965,7 @@ function fl({
5996
5965
  {
5997
5966
  className: "flex size-10 shrink-0 items-center justify-center rounded-full text-lg",
5998
5967
  style: { backgroundColor: l },
5999
- children: e.avatar ?? /* @__PURE__ */ t.jsx(we, { className: "text-muted-foreground size-4" })
5968
+ children: e.avatar ?? /* @__PURE__ */ t.jsx(ke, { className: "text-muted-foreground size-4" })
6000
5969
  }
6001
5970
  ),
6002
5971
  /* @__PURE__ */ t.jsxs("div", { className: "min-w-0 flex-1", children: [
@@ -6031,7 +6000,7 @@ function fl({
6031
6000
  }
6032
6001
  ),
6033
6002
  /* @__PURE__ */ t.jsx(
6034
- gl,
6003
+ pl,
6035
6004
  {
6036
6005
  group: e,
6037
6006
  open: c,
@@ -6042,7 +6011,7 @@ function fl({
6042
6011
  )
6043
6012
  ] });
6044
6013
  }
6045
- function gl({
6014
+ function pl({
6046
6015
  group: e,
6047
6016
  open: n,
6048
6017
  onOpenChange: r,
@@ -6056,14 +6025,14 @@ function gl({
6056
6025
  return () => clearTimeout(x);
6057
6026
  }, [f]);
6058
6027
  const { data: y, isLoading: p } = ve({
6059
- queryKey: Y.groupMembers(e.name),
6028
+ queryKey: Q.groupMembers(e.name),
6060
6029
  queryFn: async () => (await c.listContacts({
6061
6030
  tags: [e.name],
6062
6031
  per_page: 100
6063
6032
  })).contacts,
6064
6033
  enabled: n
6065
6034
  }), { data: h } = ve({
6066
- queryKey: Y.groupAddSearch(e.name, m),
6035
+ queryKey: Q.groupAddSearch(e.name, m),
6067
6036
  queryFn: () => c.listContacts({
6068
6037
  search_query: m,
6069
6038
  per_page: 10
@@ -6076,8 +6045,8 @@ function gl({
6076
6045
  const R = (Array.isArray(x.tags) ? x.tags : []).filter((F) => F !== e.name);
6077
6046
  c.updateContact(String(x.id), { tags: R }).then(() => {
6078
6047
  d.invalidateQueries({
6079
- queryKey: Y.groupMembers(e.name)
6080
- }), ze(d), O({
6048
+ queryKey: Q.groupMembers(e.name)
6049
+ }), Pe(d), O({
6081
6050
  title: o("groups_member_removed_toast", {
6082
6051
  contact: x.full_name ?? "",
6083
6052
  group: e.name
@@ -6103,8 +6072,8 @@ function gl({
6103
6072
  const R = [...P, e.name];
6104
6073
  c.updateContact(String(x.id), { tags: R }).then(() => {
6105
6074
  d.invalidateQueries({
6106
- queryKey: Y.groupMembers(e.name)
6107
- }), ze(d), g(""), _(x.id), O({
6075
+ queryKey: Q.groupMembers(e.name)
6076
+ }), Pe(d), g(""), _(x.id), O({
6108
6077
  title: o("groups_member_added_toast", {
6109
6078
  contact: x.full_name ?? "",
6110
6079
  group: e.name
@@ -6130,7 +6099,7 @@ function gl({
6130
6099
  {
6131
6100
  className: "flex size-12 shrink-0 items-center justify-center rounded-full text-xl",
6132
6101
  style: { backgroundColor: u },
6133
- children: e.avatar ?? /* @__PURE__ */ t.jsx(we, { className: "size-5 text-white/60" })
6102
+ children: e.avatar ?? /* @__PURE__ */ t.jsx(ke, { className: "size-5 text-white/60" })
6134
6103
  }
6135
6104
  ),
6136
6105
  /* @__PURE__ */ t.jsxs("div", { children: [
@@ -6226,24 +6195,24 @@ function gl({
6226
6195
  }
6227
6196
  ) : /* @__PURE__ */ t.jsx(sn, { open: n, onOpenChange: r, children: /* @__PURE__ */ t.jsx(on, { side: "right", className: "flex flex-col overflow-hidden p-0", children: j }) });
6228
6197
  }
6229
- function hl() {
6198
+ function fl() {
6230
6199
  return /* @__PURE__ */ t.jsx("div", { className: "space-y-2", children: [0, 1, 2, 3].map((e) => /* @__PURE__ */ t.jsxs(
6231
6200
  "div",
6232
6201
  {
6233
6202
  className: "flex items-center gap-4 rounded-lg px-4 py-3",
6234
6203
  "aria-hidden": "true",
6235
6204
  children: [
6236
- /* @__PURE__ */ t.jsx(De, { className: "size-10 rounded-full" }),
6205
+ /* @__PURE__ */ t.jsx(Ee, { className: "size-10 rounded-full" }),
6237
6206
  /* @__PURE__ */ t.jsxs("div", { className: "flex-1 space-y-2", children: [
6238
- /* @__PURE__ */ t.jsx(De, { className: "h-4 w-32" }),
6239
- /* @__PURE__ */ t.jsx(De, { className: "h-3 w-24" })
6207
+ /* @__PURE__ */ t.jsx(Ee, { className: "h-4 w-32" }),
6208
+ /* @__PURE__ */ t.jsx(Ee, { className: "h-3 w-24" })
6240
6209
  ] })
6241
6210
  ]
6242
6211
  },
6243
6212
  e
6244
6213
  )) });
6245
6214
  }
6246
- function _l(e = "contacts", n) {
6215
+ function gl(e = "contacts", n) {
6247
6216
  const r = W(), a = xe();
6248
6217
  return re({
6249
6218
  mutationFn: (s) => a.createContact(s),
@@ -6259,9 +6228,9 @@ function _l(e = "contacts", n) {
6259
6228
  }
6260
6229
  });
6261
6230
  }
6262
- function xl(e = "contacts", n) {
6263
- const r = Qe();
6264
- return _l(e, {
6231
+ function hl(e = "contacts", n) {
6232
+ const r = Ye();
6233
+ return gl(e, {
6265
6234
  onSuccess: (a) => {
6266
6235
  O({
6267
6236
  title: r?.t("contact_created") ?? "Contact created successfully",
@@ -6280,8 +6249,8 @@ function xl(e = "contacts", n) {
6280
6249
  function or(e) {
6281
6250
  return vn(e)[0] ?? "contacts";
6282
6251
  }
6283
- function bl(e) {
6284
- const [, n] = vn(e), r = n ? _a(n) : void 0;
6252
+ function _l(e) {
6253
+ const [, n] = vn(e), r = n ? fa(n) : void 0;
6285
6254
  return r === "manage-groups" ? {
6286
6255
  nav: { view: "browse", selectedContactId: null },
6287
6256
  subPage: "manage-groups"
@@ -6298,10 +6267,10 @@ function bl(e) {
6298
6267
  }
6299
6268
  function nn(e, n) {
6300
6269
  const r = or(e);
6301
- return n.view === "new" ? `${r}/new` : n.selectedContactId ? `${r}/${xa(n.selectedContactId)}` : r;
6270
+ return n.view === "new" ? `${r}/new` : n.selectedContactId ? `${r}/${ga(n.selectedContactId)}` : r;
6302
6271
  }
6303
6272
  const ir = "sdk-contacts";
6304
- function yl({
6273
+ function xl({
6305
6274
  selectedContactId: e,
6306
6275
  highlightContactId: n,
6307
6276
  onSelect: r,
@@ -6320,7 +6289,7 @@ function yl({
6320
6289
  (h) => {
6321
6290
  const v = h.full_name || d("contact_label");
6322
6291
  g.deleteContact(String(h.id)).then(() => {
6323
- ze(f), e === String(h.id) && r(null), O({
6292
+ Pe(f), e === String(h.id) && r(null), O({
6324
6293
  title: d("contact_deleted_toast", { name: v }),
6325
6294
  type: "success"
6326
6295
  });
@@ -6335,7 +6304,7 @@ function yl({
6335
6304
  [g, f, e, r, d]
6336
6305
  );
6337
6306
  return /* @__PURE__ */ t.jsx(
6338
- qi,
6307
+ Oi,
6339
6308
  {
6340
6309
  selectedContactId: e,
6341
6310
  highlightContactId: n,
@@ -6352,7 +6321,7 @@ function yl({
6352
6321
  }
6353
6322
  );
6354
6323
  }
6355
- const vl = {
6324
+ const bl = {
6356
6325
  first_name: "",
6357
6326
  last_name: "",
6358
6327
  email: "",
@@ -6367,7 +6336,7 @@ const vl = {
6367
6336
  metadata: {},
6368
6337
  affiliate: {}
6369
6338
  };
6370
- function jl({
6339
+ function yl({
6371
6340
  onNavigate: e,
6372
6341
  onCreateContact: n,
6373
6342
  asSheet: r = !1
@@ -6379,8 +6348,8 @@ function jl({
6379
6348
  () => (c?.countries ?? []).map((y) => ({ name: y.name, value: y.code })).sort((y, p) => y.name.localeCompare(p.name)),
6380
6349
  [c]
6381
6350
  ), u = pn(Pt, {
6382
- defaultValues: vl
6383
- }), m = xl(ir, {
6351
+ defaultValues: bl
6352
+ }), m = hl(ir, {
6384
6353
  onSuccess: (y) => {
6385
6354
  n?.();
6386
6355
  const p = y?.contact?.id;
@@ -6437,7 +6406,7 @@ function jl({
6437
6406
  ) })
6438
6407
  }
6439
6408
  ) : /* @__PURE__ */ t.jsx(
6440
- Eo,
6409
+ Mo,
6441
6410
  {
6442
6411
  onNavigateToList: _,
6443
6412
  onSubmit: () => s.current?.requestSubmit(),
@@ -6454,7 +6423,7 @@ function jl({
6454
6423
  }
6455
6424
  );
6456
6425
  }
6457
- function Nl({
6426
+ function vl({
6458
6427
  api: e,
6459
6428
  onContactSelect: n,
6460
6429
  onCreateContact: r,
@@ -6472,7 +6441,7 @@ function Nl({
6472
6441
  () => or(m),
6473
6442
  [m]
6474
6443
  ), { nav: _, subPage: y } = i.useMemo(
6475
- () => bl(m),
6444
+ () => _l(m),
6476
6445
  [m]
6477
6446
  ), p = zr(), [h, v] = i.useState(!1), [C, k] = i.useState(
6478
6447
  null
@@ -6521,9 +6490,9 @@ function Nl({
6521
6490
  const A = i.useCallback(() => {
6522
6491
  L(!0);
6523
6492
  }, []), M = h || _.view === "new", B = p || !M;
6524
- return /* @__PURE__ */ t.jsx(vo, { children: /* @__PURE__ */ t.jsx(po, { api: e, children: /* @__PURE__ */ t.jsxs("div", { ...u, className: D("h-full", u.className), children: [
6493
+ return /* @__PURE__ */ t.jsx(bo, { children: /* @__PURE__ */ t.jsx(uo, { api: e, children: /* @__PURE__ */ t.jsxs("div", { ...u, className: D("h-full", u.className), children: [
6525
6494
  y === "manage-groups" ? /* @__PURE__ */ t.jsx(
6526
- dl,
6495
+ ll,
6527
6496
  {
6528
6497
  onBack: () => g(f),
6529
6498
  onSelectContact: (T) => {
@@ -6538,7 +6507,7 @@ function Nl({
6538
6507
  }
6539
6508
  ) : /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
6540
6509
  B ? /* @__PURE__ */ t.jsx(
6541
- yl,
6510
+ xl,
6542
6511
  {
6543
6512
  selectedContactId: _.view === "browse" ? _.selectedContactId : null,
6544
6513
  highlightContactId: C,
@@ -6551,7 +6520,7 @@ function Nl({
6551
6520
  }
6552
6521
  ) : null,
6553
6522
  M ? /* @__PURE__ */ t.jsx(
6554
- jl,
6523
+ yl,
6555
6524
  {
6556
6525
  asSheet: p,
6557
6526
  onNavigate: I,
@@ -6573,7 +6542,7 @@ function Nl({
6573
6542
  )
6574
6543
  ] }) }) });
6575
6544
  }
6576
- function Ul() {
6545
+ function $l() {
6577
6546
  const { config: e } = rn(), { fetch: n } = Nr(), { baseUrl: r, defaultHeaders: a, onAuthError: s } = e, o = i.useMemo(
6578
6547
  () => Sr(
6579
6548
  Mr({
@@ -6597,8 +6566,8 @@ function Ul() {
6597
6566
  ),
6598
6567
  [r, a, s, n]
6599
6568
  );
6600
- return /* @__PURE__ */ t.jsx(Tr, { value: o, children: /* @__PURE__ */ t.jsx(Nl, { api: l }) });
6569
+ return /* @__PURE__ */ t.jsx(Tr, { value: o, children: /* @__PURE__ */ t.jsx(vl, { api: l }) });
6601
6570
  }
6602
6571
  export {
6603
- Ul as default
6572
+ $l as default
6604
6573
  };